Skip to content

Scheduling infrastructure for absolutely everyone.

Revert "fix: prevent layout shift in sticky navbar (#27256)"

Alex van Andelee1748dbee5f
diff --git a/apps/web/components/apps/layouts/AppsLayout.tsx b/apps/web/components/apps/layouts/AppsLayout.tsx
index 68ab006cfa3..0a89da77103 100644
--- a/apps/web/components/apps/layouts/AppsLayout.tsx
+++ b/apps/web/components/apps/layouts/AppsLayout.tsx
@@ -19,7 +19,7 @@ export default function AppsLayout({ children, actions, emptyStore, isAdmin, ...
const router = useRouter();
return (
- <Shell {...rest} disableSticky={true} actions={actions?.("block")}>
+ <Shell {...rest} actions={actions?.("block")}>
<div className="flex flex-col xl:flex-row">
<main className="w-full">
{emptyStore ? (
diff --git a/apps/web/modules/shell/Shell.tsx b/apps/web/modules/shell/Shell.tsx
index eaf62deb400..f861cb3df7b 100644
--- a/apps/web/modules/shell/Shell.tsx
+++ b/apps/web/modules/shell/Shell.tsx
@@ -127,22 +127,15 @@ export default function Shell(props: LayoutProps) {
export function ShellMain(props: LayoutProps) {
const router = useRouter();
const { isLocaleReady } = useLocale();
- const { bannersHeight } = useBanners();
-
- const headerStyle =
- !props.disableSticky && bannersHeight
- ? { top: `${bannersHeight}px` as const }
- : undefined;
return (
<>
{(props.heading || !!props.backPath) && (
<div
- style={headerStyle}
className={classNames(
"bg-default mb-0 flex items-center md:mb-6 md:mt-0",
props.smallHeading ? "lg:mb-7" : "lg:mb-8",
- !props.disableSticky && "sticky top-0 z-10 md:fixed md:w-[calc(100%-3.5rem)] md:pt-3 md:pb-2 md:pl-5 md:left-14 lg:left-56 lg:w-[calc(100%-14rem)]"
+ !props.disableSticky && "sticky top-0 z-10"
)}>
{!!props.backPath && (
<Button
@@ -196,9 +189,6 @@ export function ShellMain(props: LayoutProps) {
)}
</div>
)}
- {(props.heading || !!props.backPath) && !props.disableSticky && (
- <div className="hidden md:block md:h-14" aria-hidden="true" />
- )}
{props.afterHeading && <>{props.afterHeading}</>}
<div className={classNames(props.flexChildrenContainer && "flex flex-1 flex-col")}>
{props.children}