Skip to content

Commit

Permalink
fix: mobile navbar and refactor update profile into new page
Browse files Browse the repository at this point in the history
  • Loading branch information
thenicekat committed Mar 31, 2024
1 parent 9842b4f commit 8905859
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 18 deletions.
13 changes: 0 additions & 13 deletions frontend/app/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import { ArchiveBoxIcon, BookmarkIcon, HomeIcon, PlusCircleIcon, UserIcon } from
import MyPosts from "./tabs/MyPosts";
import SentRequests from "./tabs/SentRequests";
import { Tab, Tabs } from "@nextui-org/tabs";
import UpdateProfile from "./tabs/UpdateProfile";

axios.defaults.withCredentials = true;

Expand Down Expand Up @@ -145,18 +144,6 @@ export default function Home() {
>
<SentRequests />
</Tab>

<Tab
key="profile"
title={
<div className="flex items-center space-x-2">
<UserIcon className="h-5 w-5" />
<span>Profile</span>
</div>
}
>
<UpdateProfile />
</Tab>
</Tabs>
</div>
</>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ type UserProfile = {
isPublic: boolean;
};

export default function UpdateProfile() {
export default function UserProfile() {
const { register, handleSubmit, formState: { errors }, control, setValue, watch } = useForm();

const [message, setMessage] = useState<string | null>(null);
Expand Down
5 changes: 2 additions & 3 deletions frontend/components/Navbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ import clsx from "clsx";

import { ThemeSwitch } from "@/components/theme-switch";
import { GithubIcon } from "@/components/icons";
import { NotificationsDropdown } from "@/components/NotificationsDropDown";

export const Navbar = () => {
return (
Expand Down Expand Up @@ -51,7 +50,7 @@ export const Navbar = () => {
className="hidden sm:flex basis-1/5 sm:basis-full"
justify="end"
>
<NotificationsDropdown />
{/* <NotificationsDropdown /> */}
<NavbarItem className="hidden sm:flex gap-2">
<Link
isExternal
Expand Down Expand Up @@ -89,7 +88,7 @@ export const Navbar = () => {
? "danger"
: "foreground"
}
href="#"
href={item.href}
size="lg"
>
{item.label}
Expand Down
2 changes: 1 addition & 1 deletion frontend/config/site.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export const siteConfig = {
server_url: process.env.NEXT_PUBLIC_SERVER_URL,
description: "Get things done.",
navItems: [
{ label: "Dashboard", href: "/user/dashboard" },
{ label: "Profile", href: "/user/profile" },
],
links: {
github: "https://github.com/divyateja04/geddit",
Expand Down

0 comments on commit 8905859

Please sign in to comment.