Skip to content

Commit

Permalink
chore: remove theme in dashboard
Browse files Browse the repository at this point in the history
  • Loading branch information
bepyan committed Aug 23, 2024
1 parent 922689d commit 2e0b06d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
4 changes: 1 addition & 3 deletions src/app/(main)/dashboard/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { redirect } from "next/navigation";
import InvitationItem from "~/app/(main)/dashboard/invitation-item";
import TemplateItem from "~/app/(main)/dashboard/template-item";
import ProfileDropDown from "~/components/profile-dropdown";
import ThemeDropdown from "~/components/theme-dropdown";
import { getAuth } from "~/lib/auth/utils";
import { getInvitationsByAuth } from "~/lib/db/schema/invitations.query";
import { getAllTemplates } from "~/lib/db/schema/templates.query";
Expand Down Expand Up @@ -40,13 +39,12 @@ export default async function Page() {
return (
<div>
{/* header */}
<header className="sticky inset-x-0 top-0 z-50 mx-auto flex h-20 w-full max-w-7xl items-center bg-background/70 px-7 backdrop-blur sm:px-14">
<header className="sticky inset-x-0 top-0 z-50 mx-auto flex h-20 w-full max-w-7xl items-center bg-[#FFFCF970] px-7 backdrop-blur sm:px-14">
<Link className="flex items-center justify-center" href="/">
<Image src="/landing-logo.png" alt="logo" width={85} height={29} />
<span className="sr-only">Invi</span>
</Link>
<nav className="ml-auto flex items-center gap-3">
<ThemeDropdown />
<ProfileDropDown user={auth.user} />
</nav>
</header>
Expand Down
5 changes: 3 additions & 2 deletions src/components/providers.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,9 @@ export default function Providers({ children }: { children: ReactNode }) {
const queryClient = getQueryClient();

const pathname = usePathname();
const forcedThemeFromPathname =
pathname === "/" || pathname === "/sign-in" ? "light" : undefined;
const forcedThemeFromPathname = !pathname.startsWith("/i/")
? "light"
: undefined;

return (
<QueryClientProvider client={queryClient}>
Expand Down

0 comments on commit 2e0b06d

Please sign in to comment.