Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

fix(ui): remove bg-menu from overlay child elements (#8898)

Jacob Beckermane7a1bcfb188d
diff --git a/.agents/rules/web/design-system.md b/.agents/rules/web/design-system.md
index ca07aa70e2..f88d68e91a 100644
--- a/.agents/rules/web/design-system.md
+++ b/.agents/rules/web/design-system.md
@@ -62,7 +62,9 @@ construction. Browse them at `/app/component/ui` (Foundations → Controls).
control fill) with `overlay-*` hovers, never raw `ink/5` tints.
- **FE-67** Overlays share two surfaces: menus, popovers, floating toolbars, and
editor panels use `menu-surface`; dialogs use `Dialog` (`elevated-surface`).
- Never give overlay content its own fill, border, or shadow. On a `Surface` or
+ Never give overlay content its own fill, border, or shadow, and never paint a
+ fill on a child that reaches the overlay's edge: it covers the dark-mode bevel
+ (`menu-surface`'s inset edges). On a `Surface` or
`Panel`, pass `hideBorder` and keep `rounded-xl bg-surface` (core utilities
outrank `@utility` classes). Enforced for Kobalte `.Content` and
`bg-menu-glass` by ast-grep `tsx-overlay-canonical-surface`, CI error; the
diff --git a/apps/web/src/components/ui/components/Dropdown.tsx b/apps/web/src/components/ui/components/Dropdown.tsx
index 5a29b95d73..f50205941c 100644
--- a/apps/web/src/components/ui/components/Dropdown.tsx
+++ b/apps/web/src/components/ui/components/Dropdown.tsx
@@ -318,7 +318,7 @@ function DropdownGroup(props: DropdownGroupProps) {
const [local, rest] = splitProps(props, ['class']);
return (
<KobalteDropdownMenu.Group
- class={cn('flex flex-col p-1.5 bg-menu', local.class)}
+ class={cn('flex flex-col p-1.5', local.class)}
{...rest}
/>
);
diff --git a/apps/web/src/features/agents-view/views/AgentPicker.tsx b/apps/web/src/features/agents-view/views/AgentPicker.tsx
index fa509c0f13..9ad5301539 100644
--- a/apps/web/src/features/agents-view/views/AgentPicker.tsx
+++ b/apps/web/src/features/agents-view/views/AgentPicker.tsx
@@ -173,7 +173,7 @@ function DesktopAgentPicker(props: AgentPickerProps) {
</Show>
<For each={groups()}>
{(group) => (
- <Dropdown.Group class="bg-transparent py-0">
+ <Dropdown.Group class="py-0">
<Dropdown.GroupLabel class="h-6 font-medium text-ink-muted">
{group.label}
</Dropdown.GroupLabel>
@@ -215,14 +215,11 @@ function DesktopAgentPicker(props: AgentPickerProps) {
</p>
</Show>
<Show when={props.loading}>
- <div
- role="status"
- class="bg-menu px-3 py-2 text-xs text-ink-muted"
- >
+ <div role="status" class="px-3 py-2 text-xs text-ink-muted">
Loading agents…
</div>
</Show>
- <Dropdown.Group class="items-end bg-transparent px-1.5 pt-1 pb-0">
+ <Dropdown.Group class="items-end px-1.5 pt-1 pb-0">
<Dropdown.Item
closeOnSelect
class={buttonClasses({
diff --git a/apps/web/src/lib/core/component/AI/component/input/ModelCatalogPicker.tsx b/apps/web/src/lib/core/component/AI/component/input/ModelCatalogPicker.tsx
index 9a344cc826..4144b62703 100644
--- a/apps/web/src/lib/core/component/AI/component/input/ModelCatalogPicker.tsx
+++ b/apps/web/src/lib/core/component/AI/component/input/ModelCatalogPicker.tsx
@@ -105,7 +105,7 @@ function ModelList(props: {
}) {
const Row = props.row;
return (
- <Dropdown.Group class="bg-transparent py-0">
+ <Dropdown.Group class="py-0">
<Dropdown.GroupLabel class="h-6 font-medium text-ink-muted">
{props.label}
</Dropdown.GroupLabel>
@@ -519,7 +519,8 @@ export function ModelCatalogMenu(
return (
<>
- <div class="sticky top-0 z-10 bg-menu py-1">
+ {/* A transparent edge keeps the menu's bevel visible above the fill. */}
+ <div class="sticky top-0 z-10 border-x border-t border-transparent bg-menu bg-clip-padding py-1">
<div class="flex h-8 items-center gap-2 px-3">
<MagnifyingGlassIcon
aria-hidden="true"
@@ -549,7 +550,7 @@ export function ModelCatalogMenu(
{props.children}
<Show when={props.options.length === 0}>
- <div class="bg-menu px-3 py-2 text-xs text-ink-muted" role="status">
+ <div class="px-3 py-2 text-xs text-ink-muted" role="status">
{props.emptyMessage ?? 'No models available.'}
</div>
</Show>