calcom/apps/web/components/AppsShell.tsx
Peer Richelsen 2104624633
fixed a app store layout shift bugs (#2279)
* fixed a ton of app store layout shift bugs

* Sync submodules to main

* Update yarn.lock

Co-authored-by: zomars <zomars@me.com>
2022-03-25 19:23:03 +00:00

30 lines
689 B
TypeScript

import { useSession } from "next-auth/react";
import React from "react";
import { useLocale } from "@calcom/lib/hooks/useLocale";
import NavTabs from "./NavTabs";
export default function AppsShell({ children }: { children: React.ReactNode }) {
const { t } = useLocale();
const { status } = useSession();
const tabs = [
{
name: t("app_store"),
href: "/apps",
},
{
name: t("installed_apps"),
href: "/apps/installed",
},
];
return (
<>
<div className="mb-12 block lg:hidden">
{status === "authenticated" && <NavTabs tabs={tabs} linkProps={{ shallow: true }} />}
</div>
<main>{children}</main>
</>
);
}