chore(sidebar): document labels menu invariants and remove dead code (#707)

Document the hidden constraints that PR #706 left in the codebase so they
are not accidentally removed in a future cleanup pass:

- DropdownMenuSubContent and ContextMenuSubContent must stay Portal-wrapped
  so sub-menus escape ancestors with overflow-x-hidden.
- refreshLabels must stay stable via useCallback because it is captured by
  buildMenuCtx's memoization and passed as a prop.

Also delete LabelAssignPopover.tsx, which had zero consumers after the
create-and-assign flow moved into the menu-layer inline form.
This commit is contained in:
Anso
2026-04-20 10:34:45 -04:00
committed by GitHub
parent 75370d8fce
commit af59836538
4 changed files with 3 additions and 157 deletions
+1
View File
@@ -597,6 +597,7 @@ export default function EditorLayout() {
setStackStatuses(prev => ({ ...prev, [stackFile]: status }));
};
// Stable identity required: captured by buildMenuCtx's memoization and passed as a prop; unstable refs cause descendant re-render churn.
const refreshLabels = useCallback(async () => {
if (!isPaid) return;
try {