mirror of
https://github.com/Studio-Saelix/sencho.git
synced 2026-08-21 07:36:40 +00:00
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:
@@ -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 {
|
||||
|
||||
Reference in New Issue
Block a user