Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions apps/X/app/lib/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ declare module "next-auth" {
name?: string | null;
email?: string | null;
image?: string | null;
username?: string | null;
};
}
}
Expand Down
4 changes: 2 additions & 2 deletions apps/X/src/components/ui/TweetComp.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,9 @@ export const TweetComp = ({ tweet }: TweetProps) => {
</div>
<div className="flex flex-col">
<div className="list-inside">{tweet.content}</div>
<div className="cursor-pointer">Image Part</div>
{/* <div className="cursor-pointer">Image Part</div> */}
</div>
<div className="flex space-x-24 text-slate-600">
<div className="flex space-x-24 text-slate-600 mt-5">
<FaRegComment className="cursor-pointer" />
<BiRepost className="cursor-pointer" />
<FiHeart className="cursor-pointer" />
Expand Down
19 changes: 12 additions & 7 deletions apps/X/src/components/ui/home/HomeLeft.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
"use client";

import { getSession } from "next-auth/react";
import Link from "next/link";
import { useRouter } from "next/navigation";
import { AiOutlineThunderbolt } from "react-icons/ai";
Expand All @@ -15,15 +14,16 @@ import { TbOctagonPlus } from "react-icons/tb";
import { Button, UserAvatar, X_logo } from "..";
import GrokIcon from "../Grok";
import X_Icon from "../X_Icon";
import { useSession } from "next-auth/react";
import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar";

export const HomeLeft = () => {
const router = useRouter();
const session = getSession();
const { data: session } = useSession();

const onPostClick = () => {
console.log("Click");
router.push("/post");
console.log(session, "This is the session");
};
return (
<div>
Expand Down Expand Up @@ -143,15 +143,20 @@ export const HomeLeft = () => {
</div>
<div className="mt-28">
<div className="flex gap-2">
<UserAvatar />
<Avatar>
<AvatarImage src={session?.user?.image || ''} alt={session?.user?.name || 'User'} />
<AvatarFallback>{session?.user?.name?.[0]}</AvatarFallback>
</Avatar>
<div>
<p className="font-bold">mscode</p>
<p className="text-slate-600 font-semibold">@mscode07</p>
<p className="font-bold">{session?.user?.name}</p>
<p className="text-slate-600 font-semibold">
@{session?.user?.username}
</p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
);
Expand Down