@agent-native/core 0.165.3 → 0.167.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (249) hide show
  1. package/corpus/README.md +1 -1
  2. package/corpus/templates/analytics/.agents/skills/secrets/SKILL.md +5 -1
  3. package/corpus/templates/analytics/.agents/skills/workspace-conventions/SKILL.md +4 -1
  4. package/corpus/templates/analytics/CHANGELOG.md +740 -2
  5. package/corpus/templates/analytics/app/components/layout/Sidebar.tsx +93 -56
  6. package/corpus/templates/analytics/app/i18n-data.ts +23 -20
  7. package/corpus/templates/analytics/app/pages/Settings.tsx +0 -1
  8. package/corpus/templates/analytics/app/pages/adhoc/explorer/index.tsx +0 -1
  9. package/corpus/templates/analytics/app/pages/adhoc/explorer-dashboard/index.tsx +1 -1
  10. package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/SqlChartCard.tsx +2 -1
  11. package/corpus/templates/analytics/app/pages/sessions/SessionsPage.tsx +0 -1
  12. package/corpus/templates/analytics/server/lib/first-party-analytics-backend.ts +0 -32
  13. package/corpus/templates/analytics/server/lib/session-replay.ts +1 -5
  14. package/corpus/templates/assets/.agents/skills/secrets/SKILL.md +5 -1
  15. package/corpus/templates/assets/.agents/skills/workspace-conventions/SKILL.md +4 -1
  16. package/corpus/templates/assets/CHANGELOG.md +204 -2
  17. package/corpus/templates/assets/actions/navigate.ts +2 -2
  18. package/corpus/templates/assets/actions/save-generated-image.ts +0 -5
  19. package/corpus/templates/assets/app/routes/brand-kits.$id.tsx +2 -262
  20. package/corpus/templates/assets/app/routes/library.tsx +1 -1
  21. package/corpus/templates/assets/app/routes/settings.tsx +0 -3
  22. package/corpus/templates/brain/.agents/skills/secrets/SKILL.md +5 -1
  23. package/corpus/templates/brain/.agents/skills/workspace-conventions/SKILL.md +4 -1
  24. package/corpus/templates/brain/CHANGELOG.md +145 -2
  25. package/corpus/templates/brain/actions/ask-brain.ts +0 -1
  26. package/corpus/templates/brain/actions/navigate.ts +2 -2
  27. package/corpus/templates/brain/app/routes/sources.tsx +0 -4
  28. package/corpus/templates/brain/server/lib/capture-sanitization.ts +0 -11
  29. package/corpus/templates/calendar/.agents/skills/secrets/SKILL.md +5 -1
  30. package/corpus/templates/calendar/.agents/skills/workspace-conventions/SKILL.md +4 -1
  31. package/corpus/templates/calendar/CHANGELOG.md +272 -2
  32. package/corpus/templates/calendar/app/components/calendar/EventDetailPopover.tsx +0 -20
  33. package/corpus/templates/calendar/app/pages/CalendarView.tsx +0 -1
  34. package/corpus/templates/chat/.agents/skills/secrets/SKILL.md +5 -1
  35. package/corpus/templates/chat/.agents/skills/workspace-conventions/SKILL.md +4 -1
  36. package/corpus/templates/chat/CHANGELOG.md +89 -2
  37. package/corpus/templates/chat/actions/navigate.ts +2 -2
  38. package/corpus/templates/clips/.agents/skills/secrets/SKILL.md +5 -1
  39. package/corpus/templates/clips/.agents/skills/workspace-conventions/SKILL.md +4 -1
  40. package/corpus/templates/clips/CHANGELOG.md +865 -2
  41. package/corpus/templates/clips/actions/import-loom-recording.ts +16 -4
  42. package/corpus/templates/clips/actions/navigate.ts +2 -2
  43. package/corpus/templates/clips/app/components/editor/stitch-manager.tsx +0 -1
  44. package/corpus/templates/clips/app/components/library/space-dialogs.tsx +0 -1
  45. package/corpus/templates/clips/app/components/meetings/share-meeting-dialog.tsx +0 -1
  46. package/corpus/templates/clips/app/components/player/clips-share-trigger.tsx +17 -0
  47. package/corpus/templates/clips/app/components/player/delete-recording-menu.tsx +3 -3
  48. package/corpus/templates/clips/app/components/player/video-player.tsx +2 -2
  49. package/corpus/templates/clips/app/components/recorder/recorder-engine.ts +0 -1
  50. package/corpus/templates/clips/app/components/settings/ai-setup-section.tsx +0 -1
  51. package/corpus/templates/clips/app/global.css +31 -0
  52. package/corpus/templates/clips/app/hooks/use-playback-position.ts +0 -2
  53. package/corpus/templates/clips/app/lib/download-release-channel.ts +10 -0
  54. package/corpus/templates/clips/app/routes/_app.meetings.$meetingId.tsx +1 -3
  55. package/corpus/templates/clips/app/routes/download.tsx +67 -44
  56. package/corpus/templates/clips/app/routes/r.$recordingId.tsx +7 -12
  57. package/corpus/templates/clips/app/routes/record.tsx +6 -6
  58. package/corpus/templates/clips/app/routes/share.$shareId.tsx +26 -29
  59. package/corpus/templates/clips/changelog/2026-08-20-clip-viewer-share-actions.md +6 -0
  60. package/corpus/templates/clips/changelog/2026-08-20-preparing-recording-countdown-overlay.md +6 -0
  61. package/corpus/templates/clips/chrome-extension/src/background.ts +0 -13
  62. package/corpus/templates/clips/chrome-extension/src/overlay.ts +0 -1
  63. package/corpus/templates/clips/chrome-extension/src/popup.ts +0 -20
  64. package/corpus/templates/clips/desktop/src/app.tsx +6 -18
  65. package/corpus/templates/clips/desktop/src/hooks/useMediaDevices.ts +0 -1
  66. package/corpus/templates/clips/desktop/src/lib/recorder.ts +0 -8
  67. package/corpus/templates/clips/desktop/src/overlays/preparing.tsx +4 -6
  68. package/corpus/templates/clips/desktop/src/styles.css +18 -20
  69. package/corpus/templates/clips/desktop/src-tauri/src/clips/mod.rs +9 -17
  70. package/corpus/templates/content/.agents/skills/secrets/SKILL.md +5 -1
  71. package/corpus/templates/content/.agents/skills/workspace-conventions/SKILL.md +4 -1
  72. package/corpus/templates/content/CHANGELOG.md +503 -2
  73. package/corpus/templates/content/actions/_database-source-utils.ts +0 -3
  74. package/corpus/templates/content/actions/attach-content-database-source.ts +1 -4
  75. package/corpus/templates/content/actions/navigate.ts +2 -2
  76. package/corpus/templates/content/actions/prepare-builder-source-execution.ts +1 -1
  77. package/corpus/templates/content/app/components/editor/DocumentProperties.tsx +0 -6
  78. package/corpus/templates/content/app/components/editor/database/DatabaseView.tsx +0 -580
  79. package/corpus/templates/content/app/components/editor/database/FormView.tsx +2 -2
  80. package/corpus/templates/content/app/components/editor/database/filter-sort.ts +1 -1
  81. package/corpus/templates/content/app/components/editor/database/settings.tsx +0 -23
  82. package/corpus/templates/content/app/components/editor/database/sidebar.tsx +0 -1
  83. package/corpus/templates/content/app/components/sidebar/DocumentSidebar.tsx +8 -304
  84. package/corpus/templates/content/app/hooks/use-documents.ts +0 -1
  85. package/corpus/templates/content/shared/api.ts +0 -1
  86. package/corpus/templates/content/shared/builder-mdx.ts +0 -1
  87. package/corpus/templates/content/shared/nfm.ts +1 -7
  88. package/corpus/templates/crm/.agents/skills/secrets/SKILL.md +5 -1
  89. package/corpus/templates/crm/.agents/skills/workspace-conventions/SKILL.md +4 -1
  90. package/corpus/templates/crm/CHANGELOG.md +31 -2
  91. package/corpus/templates/crm/actions/merge-crm-records.ts +0 -4
  92. package/corpus/templates/crm/app/components/crm/record/RecordLists.tsx +0 -1
  93. package/corpus/templates/crm/server/crm/hubspot-adapter.ts +0 -1
  94. package/corpus/templates/crm/server/crm/salesforce-adapter.ts +0 -1
  95. package/corpus/templates/crm/server/db/crm-store.ts +1 -1
  96. package/corpus/templates/design/.agents/skills/secrets/SKILL.md +5 -1
  97. package/corpus/templates/design/.agents/skills/workspace-conventions/SKILL.md +4 -1
  98. package/corpus/templates/design/.generated/bridge/editor-chrome.generated.ts +1 -14
  99. package/corpus/templates/design/AGENTS.md +2 -1
  100. package/corpus/templates/design/CHANGELOG.md +870 -2
  101. package/corpus/templates/design/actions/apply-component-prop-edit.ts +1 -5
  102. package/corpus/templates/design/actions/generate-design.ts +0 -1
  103. package/corpus/templates/design/actions/generate-screens.ts +5 -2
  104. package/corpus/templates/design/actions/go-to-main-component.ts +2 -2
  105. package/corpus/templates/design/actions/list-design-systems.ts +10 -0
  106. package/corpus/templates/design/actions/navigate.ts +2 -2
  107. package/corpus/templates/design/actions/open-component-source.ts +4 -4
  108. package/corpus/templates/design/actions/present-design-variants.ts +1 -2
  109. package/corpus/templates/design/actions/run-design-audit.ts +0 -22
  110. package/corpus/templates/design/actions/show-design-questions.ts +5 -2
  111. package/corpus/templates/design/app/components/design/DesignCanvas.tsx +19 -8
  112. package/corpus/templates/design/app/components/design/EditPanel.tsx +11 -183
  113. package/corpus/templates/design/app/components/design/MultiScreenCanvas.tsx +21 -4
  114. package/corpus/templates/design/app/components/design/QuestionFlow.tsx +1 -5
  115. package/corpus/templates/design/app/components/design/bridge/codegen.ts +1 -1
  116. package/corpus/templates/design/app/components/design/bridge/editor-chrome.bridge.ts +10 -19
  117. package/corpus/templates/design/app/components/design/edit-panel/appearance-properties.tsx +1 -1
  118. package/corpus/templates/design/app/components/design/edit-panel/layout-properties.tsx +13 -3
  119. package/corpus/templates/design/app/components/design/edit-panel/panel-primitives.tsx +38 -32
  120. package/corpus/templates/design/app/components/design/edit-panel/position-layout-properties.tsx +1 -4
  121. package/corpus/templates/design/app/components/design/inspector/AlignmentMatrix.tsx +0 -4
  122. package/corpus/templates/design/app/components/design/inspector/AutoLayoutMatrix.tsx +15 -6
  123. package/corpus/templates/design/app/components/design/inspector/DesignColorPicker.tsx +2 -2
  124. package/corpus/templates/design/app/components/visual-editor/NodeRewriteProposal.tsx +0 -1
  125. package/corpus/templates/design/app/components/visual-editor/ReviewCanvasPins.tsx +1 -1
  126. package/corpus/templates/design/app/i18n-data.ts +122 -0
  127. package/corpus/templates/design/app/lib/clipboard-content-lineage.ts +11 -1
  128. package/corpus/templates/design/app/pages/DesignEditor.tsx +50 -254
  129. package/corpus/templates/design/app/pages/DesignSystemSetup.tsx +163 -8
  130. package/corpus/templates/design/app/pages/Index.tsx +17 -0
  131. package/corpus/templates/design/app/pages/design-editor/canvas-primitive-insert.ts +44 -32
  132. package/corpus/templates/design/app/pages/design-editor/canvas-primitives.ts +10 -0
  133. package/corpus/templates/design/app/pages/design-editor/clone-and-pen-edit.ts +49 -3
  134. package/corpus/templates/design/app/pages/design-editor/clone-idrefs.ts +31 -0
  135. package/corpus/templates/design/app/pages/design-editor/code-layer-state.ts +28 -0
  136. package/corpus/templates/design/app/pages/design-editor/commands/add-auto-layout.ts +3 -3
  137. package/corpus/templates/design/app/pages/design-editor/commands/align-selection.ts +44 -14
  138. package/corpus/templates/design/app/pages/design-editor/commands/apply-local-content-update.ts +16 -5
  139. package/corpus/templates/design/app/pages/design-editor/commands/change-selected-z-index.ts +1 -1
  140. package/corpus/templates/design/app/pages/design-editor/commands/frame-selection.ts +1 -1
  141. package/corpus/templates/design/app/pages/design-editor/commands/group-selection.ts +1 -1
  142. package/corpus/templates/design/app/pages/design-editor/commands/nudge-selection.ts +1 -1
  143. package/corpus/templates/design/app/pages/design-editor/commands/paste-selection.ts +142 -17
  144. package/corpus/templates/design/app/pages/design-editor/commands/screen-visual-duplicate-change.ts +1 -0
  145. package/corpus/templates/design/app/pages/design-editor/commands/ungroup-selection.ts +1 -1
  146. package/corpus/templates/design/app/pages/design-editor/commands/visual-duplicate-change.ts +1 -0
  147. package/corpus/templates/design/app/pages/design-editor/cross-screen-text-color.ts +25 -9
  148. package/corpus/templates/design/app/pages/design-editor/editor-state.ts +1 -0
  149. package/corpus/templates/design/app/pages/design-editor/measure-child-rects.ts +83 -0
  150. package/corpus/templates/design/app/pages/design-editor/paste-placement.ts +66 -0
  151. package/corpus/templates/design/server/routes/[...page].get.ts +0 -1
  152. package/corpus/templates/design/shared/code-layer.ts +120 -70
  153. package/corpus/templates/design/shared/design-surface-index.ts +0 -1
  154. package/corpus/templates/design/shared/pen-path.ts +0 -4
  155. package/corpus/templates/dispatch/.agents/skills/secrets/SKILL.md +5 -1
  156. package/corpus/templates/dispatch/.agents/skills/workspace-conventions/SKILL.md +4 -1
  157. package/corpus/templates/dispatch/CHANGELOG.md +196 -2
  158. package/corpus/templates/dispatch/app/routes/integrations.tsx +0 -109
  159. package/corpus/templates/factory/.agents/skills/secrets/SKILL.md +5 -1
  160. package/corpus/templates/factory/.agents/skills/workspace-conventions/SKILL.md +4 -1
  161. package/corpus/templates/factory/CHANGELOG.md +121 -2
  162. package/corpus/templates/factory/actions/navigate.ts +2 -2
  163. package/corpus/templates/factory/app/components/factory/FactoryAuditView.tsx +0 -13
  164. package/corpus/templates/factory/app/routes/factory.tsx +0 -1
  165. package/corpus/templates/factory/server/factory-graph/store.ts +0 -1
  166. package/corpus/templates/forms/.agents/skills/secrets/SKILL.md +5 -1
  167. package/corpus/templates/forms/.agents/skills/workspace-conventions/SKILL.md +4 -1
  168. package/corpus/templates/forms/CHANGELOG.md +166 -2
  169. package/corpus/templates/macros/.agents/skills/secrets/SKILL.md +5 -1
  170. package/corpus/templates/macros/.agents/skills/workspace-conventions/SKILL.md +4 -1
  171. package/corpus/templates/macros/CHANGELOG.md +49 -2
  172. package/corpus/templates/macros/app/components/layout/AppLayout.tsx +0 -1
  173. package/corpus/templates/mail/.agents/skills/secrets/SKILL.md +5 -1
  174. package/corpus/templates/mail/.agents/skills/workspace-conventions/SKILL.md +4 -1
  175. package/corpus/templates/mail/CHANGELOG.md +201 -2
  176. package/corpus/templates/mail/app/components/email/EmailList.tsx +0 -1
  177. package/corpus/templates/mail/app/components/layout/AppLayout.tsx +2 -2
  178. package/corpus/templates/mail/shared/markdown.ts +3 -0
  179. package/corpus/templates/plan/.agents/skills/secrets/SKILL.md +5 -1
  180. package/corpus/templates/plan/.agents/skills/workspace-conventions/SKILL.md +4 -1
  181. package/corpus/templates/plan/CHANGELOG.md +277 -2
  182. package/corpus/templates/slides/.agents/skills/secrets/SKILL.md +5 -1
  183. package/corpus/templates/slides/.agents/skills/workspace-conventions/SKILL.md +4 -1
  184. package/corpus/templates/slides/CHANGELOG.md +437 -2
  185. package/corpus/templates/slides/actions/add-slide.ts +0 -1
  186. package/corpus/templates/slides/actions/list-decks.ts +1 -1
  187. package/corpus/templates/slides/app/components/editor/EditorSidebar.tsx +1 -4
  188. package/corpus/templates/slides/app/components/editor/SlideContextToolbar.tsx +0 -1
  189. package/corpus/templates/slides/app/components/editor/SlideEditor.tsx +1 -1
  190. package/corpus/templates/slides/app/pages/DeckEditor.tsx +1 -6
  191. package/corpus/templates/tasks/.agents/skills/secrets/SKILL.md +5 -1
  192. package/corpus/templates/tasks/.agents/skills/workspace-conventions/SKILL.md +4 -1
  193. package/corpus/templates/tasks/CHANGELOG.md +32 -2
  194. package/corpus/templates/tasks/app/components/layout/Layout.tsx +0 -1
  195. package/corpus/templates/tasks/app/hooks/use-visible-task-fields.ts +1 -4
  196. package/corpus/templates/tasks/server/custom-fields/store.ts +1 -6
  197. package/corpus/templates/tasks/shared/list-screen-snapshot.ts +2 -2
  198. package/dist/agent/engine/registry.js +27 -14
  199. package/dist/agent/index.d.ts +1 -1
  200. package/dist/agent/production-agent.d.ts +19 -6
  201. package/dist/agent/production-agent.js +57 -16
  202. package/dist/agent/types.d.ts +3 -0
  203. package/dist/changelog/parse.d.ts +3 -3
  204. package/dist/changelog/parse.js +35 -16
  205. package/dist/client/EnvironmentBadge.d.ts +1 -0
  206. package/dist/client/EnvironmentBadge.js +7 -0
  207. package/dist/collab/awareness.d.ts +2 -2
  208. package/dist/collab/routes.d.ts +1 -1
  209. package/dist/collab/struct-routes.d.ts +1 -1
  210. package/dist/config.d.ts +11 -0
  211. package/dist/config.js +248 -0
  212. package/dist/deploy/build.js +12 -1
  213. package/dist/index.d.ts +1 -1
  214. package/dist/notifications/routes.d.ts +3 -3
  215. package/dist/observability/routes.d.ts +6 -6
  216. package/dist/resources/handlers.d.ts +2 -2
  217. package/dist/secrets/routes.d.ts +9 -9
  218. package/dist/server/agent-chat/plugin-options.d.ts +3 -2
  219. package/dist/server/agent-chat-plugin.js +5 -2
  220. package/dist/server/index.d.ts +1 -1
  221. package/dist/server/realtime-token.d.ts +1 -1
  222. package/dist/server/transcribe-voice.d.ts +1 -1
  223. package/dist/templates/chat/.agents/skills/secrets/SKILL.md +5 -1
  224. package/dist/templates/chat/.agents/skills/workspace-conventions/SKILL.md +4 -1
  225. package/dist/templates/chat/CHANGELOG.md +89 -2
  226. package/dist/templates/chat/actions/navigate.ts +2 -2
  227. package/dist/templates/default/.agents/skills/secrets/SKILL.md +5 -1
  228. package/dist/templates/default/.agents/skills/workspace-conventions/SKILL.md +4 -1
  229. package/dist/templates/headless/.agents/skills/secrets/SKILL.md +5 -1
  230. package/dist/templates/workspace-core/.agents/skills/secrets/SKILL.md +5 -1
  231. package/dist/templates/workspace-core/.agents/skills/workspace-conventions/SKILL.md +4 -1
  232. package/dist/vite/agent-native-config-loader.d.ts +1 -0
  233. package/dist/vite/agent-native-config-loader.js +3 -3
  234. package/dist/vite/agents-bundle-plugin.d.ts +1 -1
  235. package/dist/vite/agents-bundle-plugin.js +13 -1
  236. package/dist/vite/client.js +14 -14
  237. package/docs/content/agent-native-config.mdx +62 -11
  238. package/docs/content/agent-surfaces.mdx +6 -0
  239. package/docs/content/environment-variables.mdx +5 -2
  240. package/package.json +3 -3
  241. package/src/templates/chat/.agents/skills/secrets/SKILL.md +5 -1
  242. package/src/templates/chat/.agents/skills/workspace-conventions/SKILL.md +4 -1
  243. package/src/templates/chat/CHANGELOG.md +89 -2
  244. package/src/templates/chat/actions/navigate.ts +2 -2
  245. package/src/templates/default/.agents/skills/secrets/SKILL.md +5 -1
  246. package/src/templates/default/.agents/skills/workspace-conventions/SKILL.md +4 -1
  247. package/src/templates/headless/.agents/skills/secrets/SKILL.md +5 -1
  248. package/src/templates/workspace-core/.agents/skills/secrets/SKILL.md +5 -1
  249. package/src/templates/workspace-core/.agents/skills/workspace-conventions/SKILL.md +4 -1
@@ -2937,7 +2937,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
2937
2937
  } | null = null;
2938
2938
  var suppressNextShieldClick = false;
2939
2939
  var suppressNextShieldClickTimer: ReturnType<typeof setTimeout> | null = null;
2940
- var selectedSpacingHovered = false;
2941
2940
  var hoveredSpacingHandleKey = "";
2942
2941
  var spacingHoverClearTimer: ReturnType<typeof setTimeout> | null = null;
2943
2942
  var lastSpacingPointerPoint: { x: number; y: number } | null = null;
@@ -2971,7 +2970,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
2971
2970
  clearHoverGate();
2972
2971
  setPassiveSelectionElements([]);
2973
2972
  clearSpacingHoverTimer();
2974
- selectedSpacingHovered = false;
2975
2973
  hoveredSpacingHandleKey = "";
2976
2974
  lastSpacingPointerPoint = null;
2977
2975
  spacingDrag = null;
@@ -3291,7 +3289,13 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
3291
3289
  lastSourceHeadHtml = nextHeadHtml;
3292
3290
  }
3293
3291
  var currentHeadHtml = lastSourceHeadHtml;
3294
- if (nextHeadHtml === currentHeadHtml && activeCandidates.length > 0) {
3292
+ // The subtree path rewrites one selector's match. A forced replacement can
3293
+ // have changed any number of nodes, so taking it leaves the rest stale.
3294
+ if (
3295
+ !forceFullDocument &&
3296
+ nextHeadHtml === currentHeadHtml &&
3297
+ activeCandidates.length > 0
3298
+ ) {
3295
3299
  var currentMatch = null;
3296
3300
  var nextMatch = null;
3297
3301
  var matchedSelector = "";
@@ -4244,7 +4248,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
4244
4248
  function activateSpacingHandle(spacingKey: string): void {
4245
4249
  if (!spacingKey) return;
4246
4250
  clearSpacingHoverTimer();
4247
- selectedSpacingHovered = true;
4248
4251
  setHoverToSelectedElementFromSpacingSurface();
4249
4252
  if (
4250
4253
  hoveredSpacingHandleKey !== spacingKey ||
@@ -4336,7 +4339,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
4336
4339
  hit &&
4337
4340
  (hit === selectedEl || (selectedEl.contains && selectedEl.contains(hit)))
4338
4341
  ) {
4339
- selectedSpacingHovered = true;
4340
4342
  return true;
4341
4343
  }
4342
4344
  return false;
@@ -4355,7 +4357,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
4355
4357
  updateSpacingOverlay(selectedEl);
4356
4358
  return;
4357
4359
  }
4358
- selectedSpacingHovered = false;
4359
4360
  hoveredSpacingHandleKey = "";
4360
4361
  updateSpacingOverlay(selectedEl);
4361
4362
  }, 80);
@@ -5532,7 +5533,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
5532
5533
  (window.parent as Window).postMessage({ type: "clear-selection" }, "*");
5533
5534
  return;
5534
5535
  }
5535
- selectedSpacingHovered = false;
5536
5536
  hoveredSpacingHandleKey = "";
5537
5537
  var previousSelectedEl = selectedEl;
5538
5538
  selectedEl = selectionTargetForHit(target);
@@ -5844,7 +5844,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
5844
5844
  var target = candidateElements[0] || null;
5845
5845
  var info = null;
5846
5846
  if (target) {
5847
- selectedSpacingHovered = false;
5848
5847
  hoveredSpacingHandleKey = "";
5849
5848
  selectedEl = selectionTargetForHit(target);
5850
5849
  if (selectedEl && !isLayerInteractionBlocked(selectedEl)) {
@@ -6825,7 +6824,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
6825
6824
  var startY = e.clientY;
6826
6825
  lastSpacingPointerPoint = { x: startX, y: startY };
6827
6826
  hoveredSpacingHandleKey = key;
6828
- selectedSpacingHovered = true;
6829
6827
  spacingDrag = {
6830
6828
  handle: handle,
6831
6829
  currentValue: originValue,
@@ -9292,10 +9290,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
9292
9290
  ctrl: Boolean(e.ctrlKey),
9293
9291
  target: dndTarget(currentTarget),
9294
9292
  });
9295
- // Cross-screen drag state: true when the pointer is outside this iframe's
9296
- // viewport bounds. The host frame renders the ghost + highlight and owns
9297
- // the drop when this is true; the bridge suppresses its in-iframe reorder.
9298
- var pointerOutsideIframe = false;
9299
9293
  var reorderSelector = getSelector(reorderEl);
9300
9294
  var reorderSourceId = getSourceId(reorderEl);
9301
9295
  var reorderStyleSnapshot = collectPortableStyleSnapshot(reorderEl);
@@ -9655,7 +9649,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
9655
9649
  var dx = cx - reorderPointerStart.clientX;
9656
9650
  var dy = cy - reorderPointerStart.clientY;
9657
9651
  var outside = cx < 0 || cy < 0 || cx > vw || cy > vh;
9658
- pointerOutsideIframe = outside;
9659
9652
  // Always notify the host frame so it can track the cursor position,
9660
9653
  // render the ghost, and highlight the target screen. Group drags stay
9661
9654
  // in-iframe (the host's cross-screen drop moves a single element and
@@ -9806,8 +9799,8 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
9806
9799
  // avoid a ghost element left in screen A's DOM. For group drags an
9807
9800
  // outside release is simply a no-op (nothing moved during a flow
9808
9801
  // reorder drag, so there is nothing to restore).
9809
- // Use outsideOnDrop only — pointerOutsideIframe is stale when the user
9810
- // briefly exits the iframe and re-enters before releasing. The host
9802
+ // Use outsideOnDrop only — a live pointer-outside flag is stale when the
9803
+ // user briefly exits the iframe and re-enters before releasing. The host
9811
9804
  // already clears cross-screen state on re-entry so checking the
9812
9805
  // momentary excursion flag here would wrongly drop the element nowhere.
9813
9806
  if (outsideOnDrop) return;
@@ -9959,7 +9952,7 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
9959
9952
  });
9960
9953
  var gestureState =
9961
9954
  memberStates[groupEls.indexOf(gestureEl)] || memberStates[0];
9962
- var originalInlineOpacity = gestureState.originalOpacity;
9955
+
9963
9956
  var originLeft = gestureState.originLeft;
9964
9957
  var originTop = gestureState.originTop;
9965
9958
  function setMembersOpacity(value: string | null): void {
@@ -12023,7 +12016,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
12023
12016
  );
12024
12017
  if (hoveringSelectedSpacingSurface) {
12025
12018
  clearSpacingHoverTimer();
12026
- selectedSpacingHovered = true;
12027
12019
  lastSpacingPointerPoint = { x: e.clientX, y: e.clientY };
12028
12020
  updateSpacingOverlay(selectedEl);
12029
12021
  // Reliable padding/gap hover: hit-test the handle geometry
@@ -12580,7 +12572,6 @@ declare var __SELECTED_LAYER_DRAG_PRIORITY__: boolean;
12580
12572
  // replay must be a no-op for hover state.
12581
12573
  var selectionChangedByHost = target !== selectedEl;
12582
12574
  if (selectionChangedByHost) {
12583
- selectedSpacingHovered = false;
12584
12575
  hoveredSpacingHandleKey = "";
12585
12576
  }
12586
12577
  selectedEl = target;
@@ -12,7 +12,7 @@ import {
12
12
  IconRadiusTopLeft,
13
13
  IconRadiusTopRight,
14
14
  } from "@tabler/icons-react";
15
- import { useEffect, useState, type ReactNode } from "react";
15
+ import { useState, type ReactNode } from "react";
16
16
 
17
17
  import { Button } from "@/components/ui/button";
18
18
  import {
@@ -17,7 +17,6 @@ import { cn } from "@/lib/utils";
17
17
 
18
18
  import {
19
19
  AutoLayoutMatrix,
20
- ScrubInput,
21
20
  SizingField,
22
21
  type AutoLayoutFlow,
23
22
  type AutoLayoutGridTrackSizing,
@@ -45,7 +44,7 @@ import {
45
44
  elementStableKey,
46
45
  useAspectRatioLock,
47
46
  } from "./element-identity";
48
- import { FieldTrailer, ScrubStyleInput } from "./field-primitives";
47
+ import { FieldTrailer } from "./field-primitives";
49
48
  import { joinCssLayers, splitCssLayers } from "./fill-gradient-helpers";
50
49
  import { SectionIconButton } from "./inspector-controls";
51
50
  import {
@@ -213,12 +212,13 @@ function FlexContainerControls({
213
212
  element,
214
213
  onStyleChange,
215
214
  onStylesChange,
215
+ onDisableAutoLayout,
216
216
  }: {
217
217
  element: ElementInfo;
218
218
  onStyleChange: StyleChangeHandler;
219
219
  onStylesChange?: StylesChangeHandler;
220
+ onDisableAutoLayout?: (nodeId: string) => void;
220
221
  }) {
221
- const t = useT();
222
222
  const styles = element.computedStyles;
223
223
  // The element's CURRENT layout flow as authored in code, read from its own
224
224
  // computed `display`: block/flow-root/grid/etc. = "normal flow",
@@ -372,6 +372,13 @@ function FlexContainerControls({
372
372
  <AutoLayoutMatrix
373
373
  value={autoLayoutValue}
374
374
  onFlowChange={(flow) => {
375
+ const nodeId = element.sourceId ?? element.pendingNodeId;
376
+ // A raw display:block leaves the children in flow, so they re-stack
377
+ // and stop being draggable. The command measures and pins them.
378
+ if (flow === "normal" && onDisableAutoLayout && nodeId) {
379
+ onDisableAutoLayout(nodeId);
380
+ return;
381
+ }
375
382
  const patch = autoLayoutStylesForFlow(flow, {
376
383
  ...styles,
377
384
  ...element.inlineStyles,
@@ -641,12 +648,14 @@ export function LayoutContextProperties({
641
648
  element,
642
649
  onStyleChange,
643
650
  onStylesChange,
651
+ onDisableAutoLayout,
644
652
  motionKeyframeContext,
645
653
  breakpointOverrideContext,
646
654
  }: {
647
655
  element: ElementInfo;
648
656
  onStyleChange: StyleChangeHandler;
649
657
  onStylesChange?: StylesChangeHandler;
658
+ onDisableAutoLayout?: (nodeId: string) => void;
650
659
  motionKeyframeContext?: MotionKeyframeFieldContext;
651
660
  breakpointOverrideContext?: BreakpointOverrideFieldContext;
652
661
  }) {
@@ -875,6 +884,7 @@ export function LayoutContextProperties({
875
884
  element={element}
876
885
  onStyleChange={onStyleChange}
877
886
  onStylesChange={onStylesChange}
887
+ onDisableAutoLayout={onDisableAutoLayout}
878
888
  />
879
889
  {childControls}
880
890
  </PanelSection>
@@ -1,10 +1,6 @@
1
- import {
2
- parseCssColor,
3
- rgbaToCss,
4
- withColorOpacity,
5
- } from "@shared/color-utils";
1
+ import { parseCssColor } from "@shared/color-utils";
6
2
  import { IconChevronDown, IconChevronRight } from "@tabler/icons-react";
7
- import { useEffect, useRef, useState, type ReactNode } from "react";
3
+ import { Children, useEffect, useRef, useState, type ReactNode } from "react";
8
4
 
9
5
  import { Input } from "@/components/ui/input";
10
6
  import { Label } from "@/components/ui/label";
@@ -28,7 +24,6 @@ import type { DesignPaintType } from "../inspector/DesignColorPicker";
28
24
  import type { GlslShaderPanelContext } from "../inspector/GlslShaderPanel";
29
25
  import {
30
26
  buildGradientLayer,
31
- defaultGradientLayer,
32
27
  defaultGradientStops,
33
28
  fillLayerId,
34
29
  fillLayerIndex,
@@ -654,8 +649,9 @@ export function PropSlider({
654
649
 
655
650
  /**
656
651
  * design-editor inspector section: divider above, title left, actions right.
657
- * Without the leading chevron a collapsed section is indistinguishable from a
658
- * section with nothing to show, so the panel reads as fixed, not expandable.
652
+ * The chevron appears only when there is content, so a collapsed section is
653
+ * never mistaken for an empty one — and an empty section offers no control
654
+ * that does nothing.
659
655
  */
660
656
  export function PanelSection({
661
657
  title,
@@ -669,41 +665,51 @@ export function PanelSection({
669
665
  defaultCollapsed?: boolean;
670
666
  }) {
671
667
  const [collapsed, setCollapsed] = useState(defaultCollapsed);
668
+ const hasContent = Children.toArray(children).length > 0;
669
+ const heading = (
670
+ <h3 className="min-w-0 flex-1 truncate !text-[11px] font-semibold text-foreground">
671
+ {title}
672
+ </h3>
673
+ );
672
674
 
673
675
  return (
674
676
  <section className="shrink-0 border-t border-[var(--design-editor-control-border)] first:border-t-0">
675
677
  <div className="flex min-h-9 items-center gap-2 px-3">
676
- <button
677
- type="button"
678
- className="flex min-w-0 flex-1 cursor-pointer items-center gap-1 bg-transparent text-left"
679
- onClick={() => setCollapsed((c) => !c)}
680
- aria-expanded={!collapsed}
681
- >
682
- {collapsed ? (
683
- <IconChevronRight className="size-3 shrink-0 text-muted-foreground/50 rtl:-scale-x-100" />
684
- ) : (
685
- <IconChevronDown className="size-3 shrink-0 text-muted-foreground/50" />
686
- )}
687
- <h3 className="min-w-0 flex-1 truncate !text-[11px] font-semibold text-foreground">
688
- {title}
689
- </h3>
690
- </button>
678
+ {hasContent ? (
679
+ <button
680
+ type="button"
681
+ className="flex min-w-0 flex-1 cursor-pointer items-center gap-1 bg-transparent text-left"
682
+ onClick={() => setCollapsed((c) => !c)}
683
+ aria-expanded={!collapsed}
684
+ >
685
+ {collapsed ? (
686
+ <IconChevronRight className="size-3 shrink-0 text-muted-foreground/50 rtl:-scale-x-100" />
687
+ ) : (
688
+ <IconChevronDown className="size-3 shrink-0 text-muted-foreground/50" />
689
+ )}
690
+ {heading}
691
+ </button>
692
+ ) : (
693
+ <div className="flex min-w-0 flex-1 items-center gap-1 pl-4">
694
+ {heading}
695
+ </div>
696
+ )}
691
697
  {actions ? (
692
698
  <div className="flex shrink-0 items-center gap-0.5">{actions}</div>
693
699
  ) : null}
694
700
  </div>
695
- <div
696
- className="grid transition-[grid-template-rows] duration-200 ease-[cubic-bezier(0.2,0,0,1)] motion-reduce:transition-none"
697
- style={{ gridTemplateRows: collapsed ? "0fr" : "1fr" }}
698
- >
699
- <div className="overflow-hidden">
700
- {children ? (
701
+ {hasContent ? (
702
+ <div
703
+ className="grid transition-[grid-template-rows] duration-200 ease-[cubic-bezier(0.2,0,0,1)] motion-reduce:transition-none"
704
+ style={{ gridTemplateRows: collapsed ? "0fr" : "1fr" }}
705
+ >
706
+ <div className="overflow-hidden">
701
707
  <div className="space-y-1.5 px-3 pb-3 pt-0.5 !text-[11px]">
702
708
  {children}
703
709
  </div>
704
- ) : null}
710
+ </div>
705
711
  </div>
706
- </div>
712
+ ) : null}
707
713
  </section>
708
714
  );
709
715
  }
@@ -39,10 +39,7 @@ import {
39
39
  type ScrubInputChangeMeta,
40
40
  } from "../inspector";
41
41
  import type { ElementInfo } from "../types";
42
- import {
43
- AppearanceScrubField,
44
- CornerRadiusControl,
45
- } from "./appearance-properties";
42
+ import { AppearanceScrubField } from "./appearance-properties";
46
43
  import {
47
44
  commitStylePatch,
48
45
  FieldTrailer,
@@ -1,5 +1,3 @@
1
- import type { ComponentType } from "react";
2
-
3
1
  import {
4
2
  Tooltip,
5
3
  TooltipContent,
@@ -41,8 +39,6 @@ export interface AlignmentMatrixProps {
41
39
  direction?: FlowDirection;
42
40
  }
43
41
 
44
- type MatrixIcon = ComponentType<{ className?: string }>;
45
-
46
42
  const DEFAULT_LABELS: AlignmentMatrixLabels = {
47
43
  title: "Align", // i18n-ignore fallback component label
48
44
  alignTopLeft: "Align top left", // i18n-ignore fallback component label
@@ -1,5 +1,5 @@
1
1
  import { IconArrowBackUp } from "@tabler/icons-react";
2
- import { type ReactNode, useState } from "react";
2
+ import { type ReactNode } from "react";
3
3
 
4
4
  import { Button } from "@/components/ui/button";
5
5
  import { Checkbox } from "@/components/ui/checkbox";
@@ -379,6 +379,13 @@ export function AutoLayoutMatrix({
379
379
  );
380
380
 
381
381
  const activeFlow = getFlowOption(value);
382
+ const activeFlowLabel = {
383
+ normal: "Normal flow" /* i18n-ignore design inspector label */,
384
+ vertical: copy.vertical,
385
+ horizontal: copy.horizontal,
386
+ grid: "Grid" /* i18n-ignore design inspector label */,
387
+ mixed: "Mixed" /* i18n-ignore design mixed value */,
388
+ }[activeFlow];
382
389
  const isBlock = activeFlow === "normal";
383
390
 
384
391
  /** Apply a flow choice, coordinating display + direction + wrap. */
@@ -414,11 +421,13 @@ export function AutoLayoutMatrix({
414
421
  <ControlLabel>
415
422
  {"Flow" /* i18n-ignore design inspector label */}
416
423
  </ControlLabel>
417
- {value.flowMixed ? (
418
- <span className="!text-[11px] text-muted-foreground">
419
- {"Mixed" /* i18n-ignore design mixed value */}
420
- </span>
421
- ) : null}
424
+ {/* The icon highlight alone does not say which flow is active,
425
+ so a Tailwind-named layer reads as "flex" and nothing else. */}
426
+ <span className="!text-[11px] text-muted-foreground">
427
+ {value.flowMixed
428
+ ? "Mixed" /* i18n-ignore design mixed value */
429
+ : activeFlowLabel}
430
+ </span>
422
431
  </div>
423
432
  <div className="flex items-center gap-1.5">
424
433
  {/* 4-segment flow bar: normal / vertical / horizontal / grid */}
@@ -61,7 +61,7 @@ import {
61
61
  parseImageFillCss,
62
62
  type ImageFillValue,
63
63
  } from "./ImageFillControls";
64
- import { ShaderFillsPanel, shaderDescriptorToCss } from "./ShaderFillsPanel";
64
+ import { ShaderFillsPanel } from "./ShaderFillsPanel";
65
65
 
66
66
  // ─── Public types ──────────────────────────────────────────────────────────────
67
67
 
@@ -716,7 +716,7 @@ export function DesignColorPicker({
716
716
  const copy = { ...DEFAULT_LABELS, ...labels };
717
717
  const color = parseCssColorExtended(value) ?? FALLBACK_COLOR;
718
718
  const hsv = rgbaToHsv(color);
719
- const hsl = rgbaToHsl(color);
719
+
720
720
  const effectiveOpacity = opacity ?? alphaToOpacity(color.a);
721
721
  const blendModeValue = BLEND_MODE_OPTIONS.some(
722
722
  (option) => option.value === blendMode,
@@ -21,7 +21,6 @@ import {
21
21
  useCallback,
22
22
  useEffect,
23
23
  useLayoutEffect,
24
- useMemo,
25
24
  useRef,
26
25
  useState,
27
26
  } from "react";
@@ -1,4 +1,4 @@
1
- import { callAction, setClientAppState } from "@agent-native/core/client/hooks";
1
+ import { callAction } from "@agent-native/core/client/hooks";
2
2
  import { useT } from "@agent-native/core/client/i18n";
3
3
  import {
4
4
  buildReviewThreads,