Skip to content

Invoke is a leading creative engine that uses image and video generation models to empower professionals, artists, and enthusiasts to generate and create visual media using the latest AI-driven technologies. The solution offers an industry-leading application interface, and serves as the foundation for multiple commercial products.

docs: design canvas context menu groups

joshistoast866289b46ac6
diff --git a/docs/superpowers/specs/2026-07-15-canvas-context-menu-groups-design.md b/docs/superpowers/specs/2026-07-15-canvas-context-menu-groups-design.md
new file mode 100644
index 0000000000..b8485c4e75
--- /dev/null
+++ b/docs/superpowers/specs/2026-07-15-canvas-context-menu-groups-design.md
@@ -0,0 +1,27 @@
+# Canvas Context Menu Groups Design
+
+## Goal
+
+Restore the legacy canvas context-menu organization with labeled layer and canvas groups while keeping Delete as the final action.
+
+## Design
+
+- Canvas-surface context menus use Chakra `Menu.ItemGroup` and `Menu.ItemGroupLabel` primitives with the established uppercase, subtle label styling.
+- A context menu opened over a layer labels the layer-scoped actions with the singular layer type: Raster Layer, Control Layer, Inpaint Mask, or Regional Guidance.
+- Canvas-wide actions are labeled Canvas. Save to Gallery remains in this canvas group and appears before the terminal Delete action.
+- Delete remains a separated standalone danger action at the bottom so no non-destructive action appears beneath it.
+- A context menu opened over empty canvas space shows only the Canvas group.
+- Layer-panel kebab and row context menus remain unchanged because the legacy panel menus were ungrouped.
+
+## Boundaries
+
+- Reuse existing translations for Canvas and singular layer types.
+- Preserve all existing handlers, disabled states, submenu behavior, and menu positioning.
+- Add no state, effects, dependencies, or action-registry coupling.
+
+## Verification
+
+- Add regression coverage for the surface-menu group model and render order.
+- Verify each layer type resolves to the matching legacy label.
+- Verify the optional Canvas group precedes the terminal danger section and panel menus remain ungrouped when labels are omitted.
+- Run the focused context-menu tests, frontend typecheck, formatting check, and full frontend test suite.