Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

fix(today): use quill drawer defaults in phone sheets (#111644)

Shy Alter7fd39be748be
diff --git a/frontend/src/layout/today/TodayRecentRadioSubmenu.tsx b/frontend/src/layout/today/TodayRecentRadioSubmenu.tsx
index 7998f426c5b2..2df1269b02b9 100644
--- a/frontend/src/layout/today/TodayRecentRadioSubmenu.tsx
+++ b/frontend/src/layout/today/TodayRecentRadioSubmenu.tsx
@@ -39,7 +39,6 @@ export function TodayRecentRadioSubmenu<T extends string>({
options.map((option) => (
<ItemRadio
key={option.value}
- className="text-base"
aria-checked={option.value === value}
onClick={() => {
onChange(option.value)
diff --git a/frontend/src/layout/today/TodaySheetMenu.tsx b/frontend/src/layout/today/TodaySheetMenu.tsx
index ca44730f9cf7..2d1d1bb1c3df 100644
--- a/frontend/src/layout/today/TodaySheetMenu.tsx
+++ b/frontend/src/layout/today/TodaySheetMenu.tsx
@@ -1,17 +1,7 @@
import { ReactNode, useMemo, useState } from 'react'
import { IconChevronLeft } from '@posthog/icons'
-import {
- Button,
- Drawer,
- DrawerContent,
- DrawerDescription,
- DrawerHeader,
- DrawerTitle,
- Tooltip,
- TooltipContent,
- TooltipTrigger,
-} from '@posthog/quill'
+import { Button, Drawer, DrawerContent, DrawerDescription, DrawerHeader, DrawerTitle } from '@posthog/quill'
import { TodaySheetMenuContext, TodaySheetMenuControls } from './todaySheetMenuContext'
@@ -58,37 +48,25 @@ export function TodaySheetMenu({ open, onOpenChange, title, description, childre
<DrawerContent data-attr="today-sheet-menu">
<TodaySheetMenuContext.Provider value={controls}>
{page ? (
- <div className="flex items-center gap-1 px-2 pt-1 pb-2">
- <Tooltip>
- <TooltipTrigger
- delay={0}
- render={
- <Button
- size="icon-lg"
- className="rounded-full"
- aria-label="Back"
- onClick={() => setPage(null)}
- data-attr="today-sheet-menu-back"
- />
- }
- >
- <IconChevronLeft />
- </TooltipTrigger>
- <TooltipContent>Back</TooltipContent>
- </Tooltip>
- <DrawerTitle className="truncate text-base font-semibold">{page.title}</DrawerTitle>
- </div>
+ <DrawerHeader className="flex-row items-center gap-2">
+ <Button
+ size="icon"
+ aria-label="Back"
+ onClick={() => setPage(null)}
+ data-attr="today-sheet-menu-back"
+ >
+ <IconChevronLeft />
+ </Button>
+ <DrawerTitle className="min-w-0 flex-1 truncate">{page.title}</DrawerTitle>
+ <span aria-hidden className="size-7 shrink-0" />
+ </DrawerHeader>
) : (
- <DrawerHeader className="gap-0.5 border-b border-border px-4 pt-1 pb-3">
- <DrawerTitle className="truncate text-base font-semibold">{title}</DrawerTitle>
- {description && (
- <DrawerDescription className="truncate text-sm text-muted-foreground">
- {description}
- </DrawerDescription>
- )}
+ <DrawerHeader>
+ <DrawerTitle>{title}</DrawerTitle>
+ {description && <DrawerDescription>{description}</DrawerDescription>}
</DrawerHeader>
)}
- <div className="flex min-h-0 flex-col overflow-y-auto px-2 pt-1 pb-3" hidden={page !== null}>
+ <div className="flex min-h-0 flex-col overflow-y-auto px-2 pb-3" hidden={page !== null}>
{children}
</div>
<div
diff --git a/frontend/src/layout/today/TodaySheetSub.tsx b/frontend/src/layout/today/TodaySheetSub.tsx
index 77041509c244..ae5f2cb62690 100644
--- a/frontend/src/layout/today/TodaySheetSub.tsx
+++ b/frontend/src/layout/today/TodaySheetSub.tsx
@@ -30,7 +30,7 @@ export function TodaySheetSub({
return (
<>
<ItemMenuItem
- className="flex-nowrap text-base"
+ className="flex-nowrap"
aria-haspopup="menu"
onClick={() => sheet?.openPage(pageId, title)}
data-attr={dataAttr}
diff --git a/frontend/src/layout/today/TodaySpaceFileList.tsx b/frontend/src/layout/today/TodaySpaceFileList.tsx
index e203f8e4d4fd..2013ce2f3a26 100644
--- a/frontend/src/layout/today/TodaySpaceFileList.tsx
+++ b/frontend/src/layout/today/TodaySpaceFileList.tsx
@@ -54,7 +54,7 @@ export function TodaySpaceFileList({
targets.map((space) => (
<ItemRadio
key={space.id}
- className="flex-nowrap text-base"
+ className="flex-nowrap"
aria-checked={space.id === currentSpaceId}
onClick={() => {
onSelect(space.id)
diff --git a/frontend/src/layout/today/todayMenuParts.tsx b/frontend/src/layout/today/todayMenuParts.tsx
index cec3e4b1ae22..b32ee9575d7b 100644
--- a/frontend/src/layout/today/todayMenuParts.tsx
+++ b/frontend/src/layout/today/todayMenuParts.tsx
@@ -19,6 +19,7 @@ import {
DropdownMenuSubTrigger,
DropdownMenuTrigger,
ItemMenuItem,
+ ItemSeparator,
cn,
} from '@posthog/quill'
@@ -107,7 +108,7 @@ function SheetItem({ children, dataAttr, onClick, to, disabled, variant }: Today
return (
<ItemMenuItem
className={cn(
- 'text-base no-underline',
+ 'no-underline',
variant === 'destructive' ? 'text-destructive-foreground' : 'text-foreground'
)}
disabled={disabled}
@@ -125,7 +126,7 @@ function SheetItem({ children, dataAttr, onClick, to, disabled, variant }: Today
export const SHEET_PARTS: TodayMenuParts = {
Item: SheetItem,
- Separator: () => <div role="separator" className="my-1 border-t border-border" />,
+ Separator: () => <ItemSeparator className="my-1" />,
Shortcut: () => <></>,
Sub: ({ label, title, dataAttr, children }) => (
<TodaySheetSub label={label} title={title} dataAttr={dataAttr}>