From c4f5b69e15ef2fc91bf919f2b0497e81f3ee020b Mon Sep 17 00:00:00 2001 From: zhc Date: Thu, 22 Oct 2026 15:37:07 +0800 Subject: [PATCH] docs(context-menu): explain mixed slot icon alignment --- packages/client/ui-primitives/src/Menu.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/client/ui-primitives/src/Menu.tsx b/packages/client/ui-primitives/src/Menu.tsx index 2f1fb28549..c754865192 100644 --- a/packages/client/ui-primitives/src/Menu.tsx +++ b/packages/client/ui-primitives/src/Menu.tsx @@ -522,6 +522,9 @@ export function Menu({ open, anchor, items = [], children, selectedId, selectedI ) } + // Legacy Slot rows and separators are opaque React children. Inspect this popup before paint + // to align mixed groups without a first-frame shift; CSS cannot group siblings by separators. + // Child-list changes rescan only the open popup, including its mounted submenu. useLayoutEffect(() => { const list = listRef.current if (!open || !contextual || list === null) return