diff --git a/app/(content)/(home)/explore/page.tsx b/app/(content)/(home)/explore/page.tsx new file mode 100644 index 0000000000000000000000000000000000000000..4c2630f5a36275a9a870df61c6d54f85d744a36d --- /dev/null +++ b/app/(content)/(home)/explore/page.tsx @@ -0,0 +1,23 @@ +import { BackHeader } from "@/components/back-header" +import { GlobalLayout } from "@/components/global-layout" +import { Connect } from "@/components/profile/components/connect" +import { Trends } from "@/components/trends/components/trends" +import { Card } from "@/components/ui/card" +import { Separator } from "@/components/ui/separator" +import { getCurrentUser } from "@/lib/session" + +export default async function PeoplePage() { + const session = await getCurrentUser() + + return ( + <GlobalLayout + mainContent={ + <Card className="w-full overflow-hidden p-6 md:p-12"> + <Trends min={0} max={5} /> + <Separator className="my-6 p-0.5" /> + <Connect session={session} min={0} max={5} /> + </Card> + } + /> + ) +} \ No newline at end of file diff --git a/app/(content)/(user)/help/page.tsx b/app/(content)/(user)/help/page.tsx index b7ccf79aba0bcebd5d6bae02bed5931768ba0ae1..facc79dcc92a4a50eb5aa8440d9ffe762808f413 100644 --- a/app/(content)/(user)/help/page.tsx +++ b/app/(content)/(user)/help/page.tsx @@ -15,45 +15,51 @@ export default function HelpPage() { <p className="font-bold">1. How do I create an account?</p> <p> To create an account, click on the "Sign Up" button on the homepage. - Fill in the required information and follow the prompts to complete the registration process. + Fill in the required information and follow the prompts to complete the registration process, but you will have to verify you email to Login. </p> - <p className="font-bold pt-6">2. How can I create a new post?</p> + <p className="font-bold pt-6">2. How do I verify my Email?</p> <p> - To create a new post, you have multiple options depending on where you are on the website. - If you're on the homepage, or your profile page, you'll find a text field where you can write your post. + After you "Sign Up" and create a Account, we will send you a Email. + Click on the Link that is Provided to Verify your Account (Note: You Have to Verify your Email within 24h). + </p> + + <p className="font-bold pt-6">3. How can I create a new post?</p> + <p> + To create a new post, you have to go to the Homepage, at the Top you'll find a Text field where you can write your post or upload Images and Clips. Once you're done, simply click the "Post" button to publish your content and share it with others. </p> - <p className="font-bold pt-6">3. How can I delete my post?</p> + <p className="font-bold pt-6">4. How can I edit or delete my post?</p> <p> - To delete your post, go to the Home page or your profile page and locate your post. - Depending on the platform, there may be options to delete the post. - Click on the respective option and follow the prompts to make the desired changes. + To edit or delete your post, go to the Homepage or your profile page and locate your post. + Depending on the platform, there may be options to edit or delete the post. + Click on three dots, where you will see the option Delete, an edit option is currently not provided we are working on it. </p> - <p className="font-bold pt-6">4. How do I follow a user?</p> + <p className="font-bold pt-6">5. How do I Search and follow a User?</p> <p> - To follow a user, visit their profile page and look for the "Follow" button. - Click on it, and you'll start receiving updates and notifications from them. + To Search a User, go to the Homepage where you find a Search bar and type in the Name of the User you try to find. + To Follow a User visit their profile page and look for the "Follow" button, click on it, to "Follow" and a second time to "Unfollow". </p> - <p className="font-bold pt-6">5. How do I customize my profile?</p> + <p className="font-bold pt-6">6. How do I Search Games and add them to my List?</p> <p> - To customize your profile, go to the settings of your account. - There, you can upload a profile picture, add a bio, update your personal information, and adjust privacy settings according to your preferences. + To Search a Game, go to the Games-Page where you find a Search bar and type in the Name of the Game you try to find. + To Add the Game to your list visit the Game page and look for "Status", click on it, you will see all list you have and add the game to the list you want to. + To add the Game to your favorites you will find a button under "Status". </p> - <p className="font-bold pt-6">6. Can I change my username?</p> + <p className="font-bold pt-6">7. How do I customize my profile?</p> <p> - In most cases, you can change your username by going to the account settings. - Look for the option to edit your name and follow the provided instructions to make the change. + To customize your profile, go to the settings of your account. + There, you can upload a profile picture, add a bio, update your personal information, and adjust privacy settings according to your preferences. </p> - <p className="font-bold pt-6">7. How do I delete my account?</p> + <p className="font-bold pt-6">8. Can I change my username?</p> <p> - If you wish to delete your account, go to the account settings “Account Settings†section and look for the option to delete your account. - Follow the provided steps and confirm your decision to permanently delete your account. Please note that this action is irreversible and will result in the loss of all associated data. + In most cases, you can change your username by going to the Settings. + Look for the option to edit your name and follow the provided instructions to make the change. </p> </CardContent> <CardFooter className="flex flex-wrap items-center justify-between pt-6"> diff --git a/components/icons.tsx b/components/icons.tsx index 26fc3bd2f9cd9d0b2a81dc2a62eb871a3967e80c..b117294c4b62733a6b84abb11d38ca0b8fa53235 100644 --- a/components/icons.tsx +++ b/components/icons.tsx @@ -26,6 +26,7 @@ import { Moon, MoreHorizontal, Repeat2, + Rocket, Settings, SunMedium, SwitchCamera, @@ -92,6 +93,7 @@ export const Icons = { menu: Menu, // Mobile Menu Icon media: Image, // Media Gweet Icon filter: Filter, // Filter Games Icon + rocket: Rocket, // Explore Icon warning: AlertTriangle, arrowRight: ArrowRight, laptop: Laptop, diff --git a/components/nav-mobile.tsx b/components/nav-mobile.tsx index 3d24e889f59170e57073e342c621db4790893903..cd8e499d14f6c5b1ad1bbd34f4ae25b380d24009 100644 --- a/components/nav-mobile.tsx +++ b/components/nav-mobile.tsx @@ -14,7 +14,7 @@ export const MobileNav = ({ items, user }: { items: SidebarNavItem[], user: User return null } - const visibleItems = user ? items : items.slice(0, 2) + const visibleItems = user ? items : items.slice(0, 3) return ( <nav className={`container flex flex-row items-center h-full w-full max-w-lg justify-between mx-auto`}> diff --git a/components/nav-sidebar.tsx b/components/nav-sidebar.tsx index 14da27066916d8d69de0ccd0e1cde91ec153a6cb..171ae66b03c401112c0a1592e6f567dd42eb3697 100644 --- a/components/nav-sidebar.tsx +++ b/components/nav-sidebar.tsx @@ -17,7 +17,7 @@ export const Sidebar = ({ items, user }: { items: SidebarNavItem[], user: User | return null } - const visibleItems = user ? items : items.slice(0, 2) + const visibleItems = user ? items : items.slice(0, 3) return ( <nav className="grid items-start gap-2"> diff --git a/components/profile/components/connect.tsx b/components/profile/components/connect.tsx index fe00a65e436833ac63dc075bb11d0e7a502498a3..5911e25159e5444291bcb5da8c6f12aab584ee9a 100644 --- a/components/profile/components/connect.tsx +++ b/components/profile/components/connect.tsx @@ -8,9 +8,12 @@ import Link from "next/link" import { useUsers } from "../hooks/use-users" import { UserItem } from "./user-item" -export const Connect = ({ title = "Who to follow", session }: { title?: string, session: User | undefined }) => { +export const Connect = ({ title = "Who to follow", session, min, max }: { title?: string, session: User | undefined, min?: number, max?: number }) => { const { data: people, isLoading, isError, isSuccess } = useUsers() + min = !min ? title ? 0 : undefined : min + max = !max ? title ? 3 : undefined : max + return ( <div className="space-y-5 flex flex-col"> {title && <h1 className="font-bold p-1">{title}</h1>} @@ -23,7 +26,7 @@ export const Connect = ({ title = "Who to follow", session }: { title?: string, <h1 className="text-center">{"Empty :("}</h1> </Card> ) : isSuccess && - people?.slice(title ? 0 : undefined, title ? 3 : undefined).map((person) => { + people?.slice(min, max).map((person) => { return <UserItem key={person?.id} user={person} diff --git a/components/trends/components/trends.tsx b/components/trends/components/trends.tsx index 27fd41cd44729207658098104bba1dcb492708a0..7204af04bd5f7d398dd3ead18bc380c8ac749ff1 100644 --- a/components/trends/components/trends.tsx +++ b/components/trends/components/trends.tsx @@ -7,9 +7,12 @@ import Link from "next/link" import { useHashtags } from "../hooks/use-hashtags" import { Trend } from "./trend" -export const Trends = ({ title = "Trends" }: { title?: string }) => { +export const Trends = ({ title = "Trends", min, max }: { title?: string, min?: number, max?: number }) => { const { data: hashtags, isLoading, isError, isSuccess } = useHashtags() + min = !min ? title ? 0 : undefined : min + max = !max ? title ? 3 : undefined : max + return ( <div className="space-y-5 flex flex-col"> {title && <h1 className="font-bold p-1">{title}</h1>} @@ -22,7 +25,7 @@ export const Trends = ({ title = "Trends" }: { title?: string }) => { <h1 className="text-center">No trends yet</h1> </Card> ) : isSuccess && - hashtags?.slice(title ? 0 : undefined, title ? 3 : undefined).map((hashtag, index) => { + hashtags?.slice(min, max).map((hashtag, index) => { return ( <Trend key={hashtag.id} diff --git a/lib/config/dashboard.ts b/lib/config/dashboard.ts index bdc91b9e5cff013c1825f4f37840658a3bbf836f..c3a8992b61c36797b48eb318e0128e0cec2b02db 100644 --- a/lib/config/dashboard.ts +++ b/lib/config/dashboard.ts @@ -27,6 +27,11 @@ export const dashboardConfig: DashboardConfig = { // href: "/followers", // icon: "users", // }, + { + title: "Explore", + href: "/explore", + icon: "rocket", + }, { title: "My Profile", href: "",