@kabmo-labs/kabmo 0.21.1 → 0.22.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 (295) hide show
  1. package/README.md +7 -2
  2. package/dist/client/index.html +9 -8
  3. package/dist/client/index.js +334 -334
  4. package/dist/client/static/js/{index-thwqf24c.js → index-297dck9a.js} +784 -791
  5. package/dist/client/static/js/index-7ppta1pb.css +1 -0
  6. package/extensions/kabmo-modes/commands.ts +17 -3
  7. package/extensions/kabmo-modes/goal-start.ts +101 -0
  8. package/extensions/kabmo-modes/goal.test.ts +80 -5
  9. package/extensions/kabmo-modes/goal.ts +13 -38
  10. package/extensions/kabmo-modes/prompts.test.ts +12 -0
  11. package/extensions/kabmo-modes/prompts.ts +9 -2
  12. package/index.html +8 -7
  13. package/package.json +2 -2
  14. package/src/cli/lib/args.js +9 -0
  15. package/src/cli/lib/args.test.js +26 -0
  16. package/src/cli/lib/commands/doctor.js +153 -0
  17. package/src/cli/lib/commands/doctor.test.js +139 -0
  18. package/src/cli/lib/commands/serve.js +23 -10
  19. package/src/cli/lib/commands/status.js +22 -3
  20. package/src/cli/lib/omp-setup.js +131 -0
  21. package/src/cli/lib/omp-setup.test.js +115 -0
  22. package/src/cli/main.js +1 -1
  23. package/src/client/components/common/DemoDataBadge.tsx +52 -0
  24. package/src/client/components/common/FolderPicker.tsx +2 -2
  25. package/src/client/components/common/Modal.tsx +15 -1
  26. package/src/client/components/common/code-surface/blame-panel.ts +1 -1
  27. package/src/client/components/common/context-usage-button/index.test.tsx +1 -1
  28. package/src/client/components/common/context-usage-button/index.tsx +4 -4
  29. package/src/client/components/common/demo-data-badge.test.tsx +58 -0
  30. package/src/client/components/common/diagram-viewer/index.tsx +2 -2
  31. package/src/client/components/common/editor-view-buttons/index.tsx +2 -2
  32. package/src/client/components/common/header-controls/MoreMenu.tsx +1 -1
  33. package/src/client/components/common/header-controls/index.tsx +4 -1
  34. package/src/client/components/common/markdown-review/ReviewPopover.tsx +2 -2
  35. package/src/client/components/common/markdown-review/ReviewSummary.tsx +1 -1
  36. package/src/client/components/common/panel-mark/index.tsx +2 -1
  37. package/src/client/components/common/server-control/Panel.tsx +3 -3
  38. package/src/client/components/common/server-control/index.tsx +1 -1
  39. package/src/client/components/common/shell-update-button/Modal.tsx +1 -1
  40. package/src/client/components/common/todo-row/index.tsx +1 -1
  41. package/src/client/components/layout/ActivityBar.tsx +4 -0
  42. package/src/client/components/layout/ShellNotice.tsx +33 -0
  43. package/src/client/components/layout/desktop-layout/index.tsx +14 -16
  44. package/src/client/components/layout/desktop-layout/resizer/index.tsx +14 -1
  45. package/src/client/components/layout/session-sidebar/CategoryHeader.tsx +2 -1
  46. package/src/client/components/layout/session-sidebar/ClassicView.tsx +5 -1
  47. package/src/client/components/layout/session-sidebar/SessionList.tsx +1 -1
  48. package/src/client/components/layout/session-sidebar/SessionListNotice.tsx +56 -0
  49. package/src/client/components/layout/session-sidebar/SessionsView.tsx +2 -0
  50. package/src/client/components/layout/session-sidebar/about-modal/UpdateSection.tsx +1 -1
  51. package/src/client/components/layout/session-sidebar/about-modal/index.tsx +12 -1
  52. package/src/client/components/layout/session-sidebar/modern/WorkspaceHeader.tsx +2 -1
  53. package/src/client/components/layout/session-sidebar/modern/index.tsx +6 -2
  54. package/src/client/components/layout/session-sidebar/new-workspace-modal/CloneField.tsx +1 -1
  55. package/src/client/components/layout/session-sidebar/new-workspace-modal/index.tsx +2 -2
  56. package/src/client/components/layout/session-sidebar/scheduler-modal/TaskForm.tsx +1 -1
  57. package/src/client/components/layout/session-sidebar/scheduler-modal/TaskList.tsx +3 -3
  58. package/src/client/components/layout/session-sidebar/scheduler-modal/index.tsx +1 -1
  59. package/src/client/components/layout/session-sidebar/session-list-states.test.tsx +150 -0
  60. package/src/client/components/layout/session-sidebar/variant-props.ts +6 -0
  61. package/src/client/components/mobile/LayoutWrapper.tsx +20 -30
  62. package/src/client/components/mobile/MainView.tsx +5 -2
  63. package/src/client/components/mobile/RightSidebar.tsx +1 -1
  64. package/src/client/components/mobile/SessionSidebar.tsx +3 -0
  65. package/src/client/components/mobile/mobile-main-view/Header.tsx +2 -2
  66. package/src/client/components/mobile/mobile-session-sidebar/ClassicDrawer.tsx +7 -1
  67. package/src/client/components/mobile/mobile-session-sidebar/Toolbar.tsx +1 -1
  68. package/src/client/components/settings/Modal.tsx +15 -1
  69. package/src/client/components/settings/ProjectSelectorDropdown.tsx +1 -1
  70. package/src/client/components/settings/Sidebar.tsx +2 -2
  71. package/src/client/components/settings/categories/OmpSettings.tsx +1 -1
  72. package/src/client/components/settings/categories/TokenUsageSettings.tsx +1 -1
  73. package/src/client/components/settings/categories/agent-settings/DetailPane.tsx +3 -3
  74. package/src/client/components/settings/categories/appearance-settings/EditorFontSection.tsx +1 -1
  75. package/src/client/components/settings/categories/appearance-settings/EditorThemeSection.tsx +2 -2
  76. package/src/client/components/settings/categories/appearance-settings/IconStyleSection.tsx +5 -5
  77. package/src/client/components/settings/categories/appearance-settings/SidebarStyleSection.tsx +1 -1
  78. package/src/client/components/settings/categories/appearance-settings/SurfaceStyleSection.tsx +1 -1
  79. package/src/client/components/settings/categories/appearance-settings/ThemeCard.tsx +1 -1
  80. package/src/client/components/settings/categories/chat-settings/ComposerStyleSection.tsx +1 -1
  81. package/src/client/components/settings/categories/chat-settings/GoalSection.tsx +1 -1
  82. package/src/client/components/settings/categories/command-settings/DetailPane.tsx +2 -2
  83. package/src/client/components/settings/categories/omp-settings/ConfigTabs.tsx +5 -5
  84. package/src/client/components/settings/categories/omp-settings/EngineHeader.tsx +3 -3
  85. package/src/client/components/settings/categories/omp-settings/RoleRow.tsx +2 -2
  86. package/src/client/components/settings/categories/panel-plugins/LeftDockSettings.tsx +1 -1
  87. package/src/client/components/settings/categories/panel-plugins/PluginCard.tsx +1 -1
  88. package/src/client/components/settings/categories/panel-plugins/PluginMark.tsx +4 -3
  89. package/src/client/components/settings/categories/plugin-settings/SidebarList.tsx +2 -2
  90. package/src/client/components/settings/categories/project-settings/AddProjectModal.tsx +1 -1
  91. package/src/client/components/settings/categories/project-settings/NameInput.tsx +1 -1
  92. package/src/client/components/settings/categories/project-settings/PathField.tsx +1 -1
  93. package/src/client/components/settings/categories/provider-settings/AddModelModal.tsx +3 -3
  94. package/src/client/components/settings/categories/provider-settings/AddProviderModal.tsx +1 -1
  95. package/src/client/components/settings/categories/provider-settings/AuthSection.tsx +2 -2
  96. package/src/client/components/settings/categories/provider-settings/DeleteProviderModal.tsx +1 -1
  97. package/src/client/components/settings/categories/provider-settings/EntryAdvanced.tsx +4 -4
  98. package/src/client/components/settings/categories/provider-settings/EntryModal.tsx +2 -2
  99. package/src/client/components/settings/categories/provider-settings/LoginModal.tsx +1 -1
  100. package/src/client/components/settings/categories/provider-settings/ModelCapabilitiesModal.tsx +1 -1
  101. package/src/client/components/settings/categories/provider-settings/ModelsList.tsx +2 -2
  102. package/src/client/components/settings/categories/provider-settings/PriceFields.tsx +1 -1
  103. package/src/client/components/settings/categories/token-usage-settings/Breakdown.tsx +4 -4
  104. package/src/client/components/settings/categories/token-usage-settings/Chart.tsx +2 -2
  105. package/src/client/components/settings/categories/token-usage-settings/Controls.tsx +1 -1
  106. package/src/client/components/settings/categories/token-usage-settings/MetricsGrid.tsx +1 -1
  107. package/src/client/components/settings/categories/usage-settings/KenariCard.tsx +5 -5
  108. package/src/client/components/workspace/browser-panel/AddressBar.tsx +1 -1
  109. package/src/client/components/workspace/browser-panel/Screencast.tsx +6 -6
  110. package/src/client/components/workspace/browser-panel/TabStrip.tsx +1 -1
  111. package/src/client/components/workspace/browser-panel/index.tsx +1 -1
  112. package/src/client/components/workspace/browser-toolbar/index.tsx +5 -5
  113. package/src/client/components/workspace/chat-timeline/AttachmentChips.tsx +1 -1
  114. package/src/client/components/workspace/chat-timeline/GeneratingIndicator.tsx +13 -26
  115. package/src/client/components/workspace/chat-timeline/GoalNotice.tsx +2 -2
  116. package/src/client/components/workspace/chat-timeline/MessageItem.tsx +1 -1
  117. package/src/client/components/workspace/chat-timeline/MinimapShortcuts.tsx +1 -1
  118. package/src/client/components/workspace/chat-timeline/QueueList.tsx +1 -1
  119. package/src/client/components/workspace/chat-timeline/SubagentView.tsx +1 -1
  120. package/src/client/components/workspace/chat-timeline/SystemNotice.tsx +5 -5
  121. package/src/client/components/workspace/chat-timeline/TaskResultContent.tsx +2 -2
  122. package/src/client/components/workspace/chat-timeline/ThinkingSection.tsx +4 -4
  123. package/src/client/components/workspace/chat-timeline/ToolCallingSection.tsx +1 -1
  124. package/src/client/components/workspace/chat-timeline/chat-input/AccessDropdown.tsx +1 -1
  125. package/src/client/components/workspace/chat-timeline/chat-input/ArmedGoalStrip.tsx +71 -0
  126. package/src/client/components/workspace/chat-timeline/chat-input/AttachmentToolbar.tsx +4 -3
  127. package/src/client/components/workspace/chat-timeline/chat-input/GoalBanner.test.ts +1 -1
  128. package/src/client/components/workspace/chat-timeline/chat-input/GoalBanner.tsx +3 -3
  129. package/src/client/components/workspace/chat-timeline/chat-input/GoalModal.test.ts +176 -0
  130. package/src/client/components/workspace/chat-timeline/chat-input/GoalModal.tsx +70 -81
  131. package/src/client/components/workspace/chat-timeline/chat-input/GoalSurfaces.tsx +10 -1
  132. package/src/client/components/workspace/chat-timeline/chat-input/ModeToggles.test.ts +20 -0
  133. package/src/client/components/workspace/chat-timeline/chat-input/ModeToggles.tsx +13 -7
  134. package/src/client/components/workspace/chat-timeline/chat-input/ThinkingLevelDropdown.tsx +1 -1
  135. package/src/client/components/workspace/chat-timeline/chat-input/Toolbar.test.ts +65 -3
  136. package/src/client/components/workspace/chat-timeline/chat-input/Toolbar.tsx +69 -19
  137. package/src/client/components/workspace/chat-timeline/chat-input/WaitingDependencyPicker.tsx +2 -2
  138. package/src/client/components/workspace/chat-timeline/chat-input/composer-portal.test.tsx +174 -0
  139. package/src/client/components/workspace/chat-timeline/chat-input/goal-modal-parts.tsx +80 -0
  140. package/src/client/components/workspace/chat-timeline/chat-input/modes-props.ts +15 -3
  141. package/src/client/components/workspace/chat-timeline/chat-input/styles.test.tsx +3 -1
  142. package/src/client/components/workspace/chat-timeline/plan-review/index.tsx +1 -1
  143. package/src/client/components/workspace/chat-timeline/target-picker/WorkspacePicker.tsx +1 -1
  144. package/src/client/components/workspace/chat-timeline/target-picker/WorktreePicker.tsx +1 -1
  145. package/src/client/components/workspace/chat-timeline/tool-renderers/ask-panel/FrameControl.tsx +1 -1
  146. package/src/client/components/workspace/chat-timeline/tool-renderers/ask-panel/OptionRow.tsx +1 -1
  147. package/src/client/components/workspace/chat-timeline/tool-renderers/ask-panel/OrphanAsks.tsx +1 -1
  148. package/src/client/components/workspace/chat-timeline/tool-renderers/ask-panel/QuestionBlock.tsx +2 -2
  149. package/src/client/components/workspace/chat-timeline/tool-renderers/ask-panel/QuestionCard.tsx +4 -4
  150. package/src/client/components/workspace/chat-timeline/tool-renderers/ask-panel/index.tsx +2 -2
  151. package/src/client/components/workspace/chat-timeline/tool-renderers/extension-dialog/Header.tsx +1 -1
  152. package/src/client/components/workspace/chat-timeline/tool-renderers/extension-dialog/SelectBody.tsx +1 -1
  153. package/src/client/components/workspace/chat-timeline/tool-renderers/hashline-patch/index.tsx +4 -4
  154. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/AstEdit.tsx +6 -6
  155. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Bash.tsx +13 -13
  156. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Checkpoint.tsx +1 -1
  157. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/ContextNotes.tsx +2 -2
  158. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Debug.tsx +3 -3
  159. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Edit.tsx +9 -9
  160. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Eval.tsx +10 -10
  161. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/FileMatches.tsx +1 -1
  162. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Goal.tsx +5 -5
  163. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/GoalRecord.tsx +5 -5
  164. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Lsp.tsx +6 -6
  165. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/ManageSkill.tsx +5 -5
  166. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Mcp.tsx +2 -2
  167. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Memory.tsx +3 -3
  168. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Proc.tsx +15 -15
  169. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Read.tsx +2 -2
  170. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Resolve.tsx +4 -4
  171. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/SearchFs.tsx +2 -2
  172. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/SearchTool.tsx +1 -1
  173. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/SecurityScan.tsx +4 -4
  174. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/TaskResult.tsx +7 -7
  175. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Think.tsx +2 -2
  176. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Todo.tsx +2 -2
  177. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Wait.missing.test.ts +4 -2
  178. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Wait.tsx +17 -17
  179. package/src/client/components/workspace/chat-timeline/tool-renderers/panels/WebSearch.tsx +3 -3
  180. package/src/client/components/workspace/chat-timeline/tool-renderers/shared/ArtifactChip.tsx +1 -1
  181. package/src/client/components/workspace/chat-timeline/tool-renderers/shared/EnvelopeHeader.tsx +2 -2
  182. package/src/client/components/workspace/chat-timeline/tool-renderers/shared/ExcerptCode.tsx +3 -3
  183. package/src/client/components/workspace/chat-timeline/tool-renderers/shared/FallbackOutput.tsx +3 -3
  184. package/src/client/components/workspace/chat-timeline/tool-renderers/shared/JsonCodeBlock.tsx +3 -3
  185. package/src/client/components/workspace/chat-timeline/tool-renderers/shared/OutputWindow.tsx +2 -2
  186. package/src/client/components/workspace/chat-timeline/tool-renderers/shared/ToolBody.tsx +2 -2
  187. package/src/client/components/workspace/chat-timeline/tool-renderers/shared/ToolFactChips.tsx +2 -2
  188. package/src/client/components/workspace/chat-timeline/tool-renderers/shared/ToolPanelHeader.tsx +1 -1
  189. package/src/client/components/workspace/chat-timeline/tool-renderers/styles/Minimal.tsx +1 -1
  190. package/src/client/components/workspace/context-panel/RawJsonViewer.tsx +2 -2
  191. package/src/client/components/workspace/context-panel/StatsGrid.tsx +1 -1
  192. package/src/client/components/workspace/context-panel/index.tsx +1 -1
  193. package/src/client/components/workspace/diff-panel/ConflictBanner.tsx +1 -1
  194. package/src/client/components/workspace/editor/EmptyEditor.tsx +1 -1
  195. package/src/client/components/workspace/editor/FindWidget.tsx +1 -1
  196. package/src/client/components/workspace/editor/Tabs.tsx +1 -1
  197. package/src/client/components/workspace/editor/Toolbar.tsx +1 -1
  198. package/src/client/components/workspace/file-explorer/OutlineSection.tsx +2 -2
  199. package/src/client/components/workspace/file-explorer/RowLabel.tsx +1 -1
  200. package/src/client/components/workspace/file-explorer/index.tsx +1 -1
  201. package/src/client/components/workspace/git-panel/BranchToolbar.tsx +2 -2
  202. package/src/client/components/workspace/git-panel/ChangesList.tsx +3 -3
  203. package/src/client/components/workspace/git-panel/ConflictItem.tsx +3 -3
  204. package/src/client/components/workspace/git-panel/FileItem.tsx +2 -2
  205. package/src/client/components/workspace/git-panel/StashSection.tsx +5 -5
  206. package/src/client/components/workspace/git-panel/TreeItem.tsx +2 -2
  207. package/src/client/components/workspace/git-panel/branch-modal/BranchRow.tsx +4 -4
  208. package/src/client/components/workspace/git-panel/branch-modal/DeleteDialog.tsx +2 -2
  209. package/src/client/components/workspace/git-panel/index.tsx +1 -1
  210. package/src/client/components/workspace/model-dropdown/Item.tsx +3 -3
  211. package/src/client/components/workspace/model-dropdown/Section.tsx +1 -1
  212. package/src/client/components/workspace/model-dropdown/index.tsx +3 -3
  213. package/src/client/components/workspace/plan-panel/index.tsx +2 -2
  214. package/src/client/components/workspace/repo-picker/Modal.tsx +1 -1
  215. package/src/client/components/workspace/repo-picker/Row.tsx +6 -6
  216. package/src/client/components/workspace/search-panel/Body.tsx +2 -2
  217. package/src/client/components/workspace/search-panel/Results.tsx +1 -1
  218. package/src/client/components/workspace/search-panel/index.tsx +1 -1
  219. package/src/client/components/workspace/terminal-panel/index.tsx +1 -1
  220. package/src/client/components/workspace/todo-panel/PhaseGroup.tsx +1 -1
  221. package/src/client/components/workspace/todo-panel/index.tsx +2 -2
  222. package/src/client/components/workspace/user-browser-panel/AddressBar.tsx +5 -5
  223. package/src/client/components/workspace/user-browser-panel/AnnotateBar.test.tsx +13 -13
  224. package/src/client/components/workspace/user-browser-panel/AnnotateBar.tsx +4 -4
  225. package/src/client/components/workspace/user-browser-panel/AnnotateLayer.tsx +1 -1
  226. package/src/client/components/workspace/user-browser-panel/AnnotateTarget.tsx +7 -7
  227. package/src/client/components/workspace/user-browser-panel/Frame.tsx +1 -1
  228. package/src/client/components/workspace/wiki-panel/Nav.tsx +1 -1
  229. package/src/client/components/workspace/wiki-panel/index.tsx +2 -2
  230. package/src/client/glass.css +50 -0
  231. package/src/client/glass.test.ts +68 -24
  232. package/src/client/hooks/chat/composer/browser-context.test.ts +6 -6
  233. package/src/client/hooks/chat/composer/use-draft.test.ts +2 -2
  234. package/src/client/hooks/chat/omp/prompt-send.test.ts +36 -0
  235. package/src/client/hooks/chat/omp/prompt-send.ts +24 -18
  236. package/src/client/hooks/chat/omp/session-list.tsx +24 -70
  237. package/src/client/hooks/chat/omp/session-merges.ts +89 -0
  238. package/src/client/hooks/chat/omp/session-sidebar-controller.ts +4 -1
  239. package/src/client/hooks/chat/timeline/armed-goal-send.test.ts +168 -0
  240. package/src/client/hooks/chat/timeline/armed-goal.test.ts +178 -0
  241. package/src/client/hooks/chat/timeline/goal-command.ts +57 -27
  242. package/src/client/hooks/chat/timeline/index.ts +7 -4
  243. package/src/client/hooks/chat/timeline/mode-post.ts +46 -0
  244. package/src/client/hooks/chat/timeline/modes-contract.ts +94 -0
  245. package/src/client/hooks/chat/timeline/modes.ts +60 -95
  246. package/src/client/hooks/chat/timeline/send-props.ts +97 -0
  247. package/src/client/hooks/chat/timeline/send-steer.test.ts +6 -0
  248. package/src/client/hooks/chat/timeline/send.test-util.ts +55 -8
  249. package/src/client/hooks/chat/timeline/send.test.ts +17 -1
  250. package/src/client/hooks/chat/timeline/send.ts +64 -72
  251. package/src/client/hooks/ui/dialog-behaviour.ts +143 -0
  252. package/src/client/hooks/ui/theme.ts +17 -0
  253. package/src/client/hooks/workspace/copy-tab-path.ts +23 -0
  254. package/src/client/hooks/workspace/mobile-back.ts +71 -0
  255. package/src/client/palette-class.test.ts +93 -0
  256. package/src/client/tailwind-contrast.test.ts +194 -0
  257. package/src/client/tailwind.css +327 -8
  258. package/src/server/lib/assets/theme-shell.server.ts +4 -10
  259. package/src/server/lib/omp/config/provider-seeds.test.ts +39 -1
  260. package/src/server/lib/omp/config/provider-seeds.ts +32 -3
  261. package/src/server/lib/omp/config/provider-vision-compat.test.ts +140 -0
  262. package/src/server/lib/omp/core/host-resolution.test.ts +1 -55
  263. package/src/server/lib/omp/core/install-hint.test.ts +48 -0
  264. package/src/server/lib/omp/core/install-hint.ts +64 -0
  265. package/src/server/lib/omp/core/startup.test.ts +125 -0
  266. package/src/server/lib/omp/core/startup.ts +5 -1
  267. package/src/server/lib/omp/mode/request.ts +14 -6
  268. package/src/server/plugins/ssr.ts +2 -1
  269. package/src/shared/lib/browser/annotate.test.ts +22 -22
  270. package/src/shared/lib/browser/annotate.ts +14 -14
  271. package/src/shared/lib/browser/page-context.ts +6 -6
  272. package/src/shared/lib/icons/icon-paint-authority.test.ts +86 -0
  273. package/src/shared/lib/icons/icon-paint-authority.ts +94 -0
  274. package/src/shared/lib/icons/icon-paint-css.test.ts +44 -8
  275. package/src/shared/lib/icons/icon-paint-css.ts +18 -1
  276. package/src/shared/lib/icons/icon-paint-panel.ts +15 -18
  277. package/src/shared/lib/icons/icon-paint-weight.ts +20 -1
  278. package/src/shared/lib/icons/icon-tone.ts +58 -13
  279. package/src/shared/lib/icons/tint-hues.generated.ts +51 -6
  280. package/src/shared/lib/icons/tint-tones.test.ts +257 -0
  281. package/src/shared/lib/icons/tint.test.ts +3 -211
  282. package/src/shared/lib/icons/tint.ts +23 -25
  283. package/src/shared/lib/omp/mode/actions.ts +40 -0
  284. package/src/shared/lib/omp/mode/types.ts +12 -0
  285. package/src/shared/lib/theme/css.ts +21 -0
  286. package/src/shared/lib/theme/first-frame.ts +38 -0
  287. package/src/shared/lib/theme/ink-scale.test.ts +151 -0
  288. package/src/shared/lib/theme/ink-scale.ts +103 -0
  289. package/src/shared/lib/theme/shell-palette.test.ts +22 -5
  290. package/src/shared/lib/theme/shell-palette.ts +9 -4
  291. package/src/shared/lib/theme/theme.test.ts +28 -3
  292. package/src/shared/lib/workspace/project-accent.test.ts +33 -1
  293. package/src/shared/lib/workspace/project-accent.ts +23 -0
  294. package/src/shared/types/omp/agent.ts +24 -9
  295. package/dist/client/static/js/index-0721wrkf.css +0 -1
@@ -0,0 +1,150 @@
1
+ /**
2
+ * The session list's three states, which used to be two.
3
+ *
4
+ * The failure this guards was measured on the running app: with `/api/**`
5
+ * aborted, the drawer kept drawing placeholders after seven seconds, with no
6
+ * text, no `role="alert"` and no retry — a failed read was indistinguishable
7
+ * from a slow one, forever. The suite drives the two shared chromes (desktop
8
+ * `classic` and the phone drawer's `classic`) and asserts the third state names
9
+ * the cause AND offers the action.
10
+ */
11
+
12
+ import { afterAll, afterEach, beforeAll, describe, expect, test } from 'bun:test';
13
+ import { Window } from 'happy-dom';
14
+ import { h, render } from 'preact';
15
+
16
+ import { SessionListNotice } from '@/client/components/layout/session-sidebar/SessionListNotice';
17
+ import { ClassicSidebarView } from '@/client/components/layout/session-sidebar/ClassicView';
18
+ import { ClassicDrawer } from '@/client/components/mobile/mobile-session-sidebar/ClassicDrawer';
19
+
20
+ const DOM_GLOBALS = [
21
+ 'window',
22
+ 'document',
23
+ 'navigator',
24
+ 'Node',
25
+ 'Element',
26
+ 'HTMLElement',
27
+ 'Event',
28
+ 'MouseEvent',
29
+ 'KeyboardEvent',
30
+ ] as const;
31
+ const nativeGlobals: Partial<Record<(typeof DOM_GLOBALS)[number], unknown>> = {};
32
+ let container: HTMLElement;
33
+
34
+ beforeAll(() => {
35
+ const win = new Window({ url: 'http://localhost' });
36
+ const target = globalThis as unknown as Record<string, unknown>;
37
+ for (const key of DOM_GLOBALS) {
38
+ nativeGlobals[key] = target[key];
39
+ target[key] = (win as unknown as Record<string, unknown>)[key];
40
+ }
41
+ container = document.createElement('div');
42
+ document.body.appendChild(container);
43
+ });
44
+
45
+ afterAll(() => {
46
+ const target = globalThis as unknown as Record<string, unknown>;
47
+ for (const key of DOM_GLOBALS) {
48
+ if (nativeGlobals[key] === undefined) delete target[key];
49
+ else target[key] = nativeGlobals[key];
50
+ }
51
+ });
52
+
53
+ afterEach(() => {
54
+ render(null, container);
55
+ });
56
+
57
+ /** Every prop the chrome needs, with the state under test in it. */
58
+ function props(overrides: Record<string, unknown> = {}) {
59
+ return {
60
+ folders: [],
61
+ initializing: false,
62
+ failed: false,
63
+ activeSessionId: null,
64
+ sessionStatus: {},
65
+ searchQuery: '',
66
+ onSearchChange: () => {},
67
+ showArchived: false,
68
+ onToggleArchived: () => {},
69
+ sortOption: 'LATEST_SESSION' as const,
70
+ optionsOpen: false,
71
+ onToggleOptions: () => {},
72
+ onCloseOptions: () => {},
73
+ onSortChange: () => {},
74
+ onRefresh: () => {},
75
+ refreshing: false,
76
+ scheduledCount: 0,
77
+ onNewSession: () => {},
78
+ onNewWorkspace: () => {},
79
+ onScheduler: () => {},
80
+ onSelectSession: () => {},
81
+ onNewSessionForFolder: () => {},
82
+ onToast: () => {},
83
+ onSelectWorkspaces: () => {},
84
+ onStartSessionSelection: () => {},
85
+ ...overrides,
86
+ };
87
+ }
88
+
89
+ describe('SessionListNotice', () => {
90
+ test('names the cause, states the data still exists, and offers the retry', () => {
91
+ let retried = 0;
92
+ render(h(SessionListNotice, { onRetry: () => { retried += 1; } }), container);
93
+
94
+ const alert = container.querySelector('[role="alert"]');
95
+ expect(alert).not.toBeNull();
96
+ expect(alert!.textContent).toContain('could not be loaded');
97
+ // The cause, not just the symptom: a closed connection is why nothing came.
98
+ expect(alert!.textContent).toContain('connection closed');
99
+ // It must not claim the sessions are gone, because they are not.
100
+ expect(alert!.textContent).toContain('still on disk');
101
+
102
+ const button = container.querySelector('button')!;
103
+ expect(button.textContent).toContain('Try again');
104
+ button.click();
105
+ expect(retried).toBe(1);
106
+ });
107
+
108
+ test('the phone variant keeps a 44px target', () => {
109
+ render(h(SessionListNotice, { touch: true, onRetry: () => {} }), container);
110
+ expect(container.querySelector('button')!.className).toContain('h-11');
111
+ });
112
+ });
113
+
114
+ describe('ClassicSidebarView states', () => {
115
+ test('failed draws the notice instead of the skeleton', () => {
116
+ render(h(ClassicSidebarView, props({ failed: true })), container);
117
+ expect(container.querySelector('[role="alert"]')).not.toBeNull();
118
+ expect(container.querySelector('[aria-hidden="true"].space-y-4')).toBeNull();
119
+ });
120
+
121
+ test('initializing still draws the skeleton, because a reply is still coming', () => {
122
+ render(h(ClassicSidebarView, props({ initializing: true })), container);
123
+ expect(container.querySelector('[role="alert"]')).toBeNull();
124
+ expect(container.querySelector('[aria-hidden="true"]')).not.toBeNull();
125
+ });
126
+
127
+ test('loaded and empty says why it is empty rather than failing', () => {
128
+ render(h(ClassicSidebarView, props()), container);
129
+ expect(container.querySelector('[role="alert"]')).toBeNull();
130
+ expect(container.textContent).toContain('No workspaces available.');
131
+ });
132
+ });
133
+
134
+ describe('ClassicDrawer states', () => {
135
+ const base = {
136
+ expandedFolders: {},
137
+ onToggleFolder: () => {},
138
+ onResetSort: () => {},
139
+ onHideArchived: () => {},
140
+ onClearSearch: () => {},
141
+ selecting: false,
142
+ optionsRef: { current: null },
143
+ };
144
+
145
+ test('failed draws the notice with the phone target size', () => {
146
+ render(h(ClassicDrawer, { ...props({ failed: true }), ...base } as never), container);
147
+ expect(container.querySelector('[role="alert"]')).not.toBeNull();
148
+ expect(container.querySelector('[role="alert"] button')!.className).toContain('h-11');
149
+ });
150
+ });
@@ -30,6 +30,12 @@ export interface SessionSidebarVariantProps {
30
30
  folders: WorkspaceFolderData[];
31
31
  /** True until the first list fetch settles (drives the skeleton). */
32
32
  initializing: boolean;
33
+ /**
34
+ * The first list read failed and no answer is coming on its own. Distinct from
35
+ * `initializing`, which promises that a reply is still on its way; this draws
36
+ * the cause and a retry instead of a skeleton that never resolves.
37
+ */
38
+ failed: boolean;
33
39
  activeSessionId: number | string | null;
34
40
  sessionStatus: SessionStatusMap;
35
41
 
@@ -1,10 +1,11 @@
1
- import { useCallback, useEffect, useState } from 'preact/hooks';
1
+ import { useCallback, useState } from 'preact/hooks';
2
2
  import { useSearchParams } from '@/client/lib/router/search-params';
3
3
  import { useKabmoEvent } from '@/client/hooks/ui/window-event';
4
- import { registerBackHandler } from '@/client/lib/native/back';
4
+ import { useMobileBackStack } from '@/client/hooks/workspace/mobile-back';
5
5
  import type { SettingsCategoryId } from '@/shared/types';
6
6
  import { MobileMainView } from '@/client/components/mobile/MainView';
7
7
  import { WindowAura } from '@/client/components/layout/WindowAura';
8
+ import { ShellNotice } from '@/client/components/layout/ShellNotice';
8
9
  import { MobileSessionSidebar } from '@/client/components/mobile/SessionSidebar';
9
10
  import { MobileRightSidebar } from '@/client/components/mobile/RightSidebar';
10
11
  import { MobileFullEditor } from '@/client/components/mobile/mobile-right-sidebar/FullEditor';
@@ -35,7 +36,7 @@ interface MobileLayoutWrapperProps {
35
36
  export type MobileScreen = 'main' | 'session' | 'right';
36
37
 
37
38
  export function MobileLayoutWrapper({ onDesktopToggle, appSettings = {} }: MobileLayoutWrapperProps) {
38
- const { folders } = useSidebarData();
39
+ const { folders, isMock } = useSidebarData();
39
40
  // The placement state the panel-open event resolves against, and the session
40
41
  // the tab it writes belongs to — read once here rather than per drawer,
41
42
  // because the drawer that receives the selection is not mounted yet.
@@ -76,33 +77,21 @@ export function MobileLayoutWrapper({ onDesktopToggle, appSettings = {} }: Mobil
76
77
 
77
78
  // The Android shell's back button asks this layout first.
78
79
  //
79
- // Order is what the user sees, innermost first: the full-screen editor and
80
- // diff cover everything, then the settings modal, then the drawer screens,
81
- // and only then does the shell walk WebView history. Without this, back
82
- // reopened the previous session while leaving the drawer that opened it on
83
- // screen — the screens live in React state, not in the URL.
84
- useEffect(() => {
85
- return registerBackHandler(() => {
86
- if (mobileEditorFile) {
87
- setMobileEditorFile(null);
88
- return true;
89
- }
90
- if (mobileDiff) {
91
- setMobileDiff(null);
92
- return true;
93
- }
94
- if (settingsOpen) {
95
- setSettingsOpen(false);
96
- setAutoOpenAddProvider(false);
97
- return true;
98
- }
99
- if (currentScreen !== 'main') {
100
- setCurrentScreen('main');
101
- return true;
102
- }
103
- return false;
104
- });
105
- }, [mobileEditorFile, mobileDiff, settingsOpen, currentScreen]);
80
+ // The back gesture walks the screens innermost first. The hook owns the
81
+ // subscription; the order is the layout's, because the layout owns the state.
82
+ useMobileBackStack({
83
+ editorOpen: mobileEditorFile !== null,
84
+ diffOpen: mobileDiff !== null,
85
+ settingsOpen,
86
+ offMainScreen: currentScreen !== 'main',
87
+ onCloseEditor: () => setMobileEditorFile(null),
88
+ onCloseDiff: () => setMobileDiff(null),
89
+ onCloseSettings: () => {
90
+ setSettingsOpen(false);
91
+ setAutoOpenAddProvider(false);
92
+ },
93
+ onReturnToMain: () => setCurrentScreen('main'),
94
+ });
106
95
 
107
96
  const { folder: sessionFolder } = activeProjectForSession(folders, sessionId);
108
97
  const contextFolder = sessionFolder ?? (folderId ? folders.find(f => String(f.id) === String(folderId)) ?? null : null);
@@ -246,6 +235,7 @@ export function MobileLayoutWrapper({ onDesktopToggle, appSettings = {} }: Mobil
246
235
  className="app-window flex flex-col h-dvh w-screen overflow-hidden bg-canvas text-ink font-sans selection:bg-ink selection:text-canvas relative"
247
236
  >
248
237
  <WindowAura />
238
+ <ShellNotice isMock={isMock} />
249
239
  {/* The plugin system's boot, on the PHONE too. It is mounted at the top of
250
240
  the workspace on the desktop (`desktop-layout/index.tsx`), and without
251
241
  it here a phone had no plugin CONTEXT (so `usePanelInfo()` answered
@@ -56,13 +56,16 @@ export function MobileMainView({
56
56
  onSelectSession={onSelectSession}
57
57
  />
58
58
 
59
- <div className="flex-1 min-h-0">
59
+ {/* The document's main content on a phone, so the chat is reachable by
60
+ landmark. The header above is a `banner`, the drawers are their own
61
+ screens. */}
62
+ <main className="flex-1 min-h-0">
60
63
  <ChatTimeline
61
64
  appSettings={appSettings}
62
65
  onSessionTitle={setLiveTitle}
63
66
  variant="mobile"
64
67
  />
65
- </div>
68
+ </main>
66
69
  </div>
67
70
  );
68
71
  }
@@ -150,7 +150,7 @@ export function MobileRightSidebar({
150
150
  </Suspense>
151
151
  ) : (
152
152
  <div className="h-full flex items-center justify-center text-ink/40">
153
- <span className="text-xs font-mono">No session selected</span>
153
+ <span className="text-xs font-mono text-muted">No session selected</span>
154
154
  </div>
155
155
  )}
156
156
  </div>
@@ -83,6 +83,7 @@ export function MobileSessionSidebar({
83
83
  });
84
84
  const {
85
85
  initializing,
86
+ failed,
86
87
  refreshNow,
87
88
  isRefreshing,
88
89
  searchQuery,
@@ -173,6 +174,7 @@ export function MobileSessionSidebar({
173
174
  className: 'flex-1 min-h-0 w-full',
174
175
  folders: processedFolders,
175
176
  initializing,
177
+ failed,
176
178
  activeSessionId,
177
179
  sessionStatus,
178
180
  searchQuery,
@@ -228,6 +230,7 @@ export function MobileSessionSidebar({
228
230
  <ClassicDrawer
229
231
  folders={processedFolders}
230
232
  initializing={initializing}
233
+ failed={failed}
231
234
  activeSessionId={activeSessionId}
232
235
  expandedFolders={expandedFolders}
233
236
  sessionStatus={sessionStatus}
@@ -126,7 +126,7 @@ export function MobileHeader({
126
126
  <button
127
127
  type="button"
128
128
  onClick={onOpenSessionSidebar}
129
- className="p-1.5 rounded-lg hover:bg-ink/5 active:bg-ink/10 text-ink transition-colors flex-shrink-0"
129
+ className="tap-target p-1.5 rounded-lg hover:bg-ink/5 active:bg-ink/10 text-ink transition-colors flex-shrink-0"
130
130
  title="Open Sessions"
131
131
  aria-label="Open Sessions"
132
132
  >
@@ -154,7 +154,7 @@ export function MobileHeader({
154
154
  <button
155
155
  type="button"
156
156
  onClick={() => setShowSessionPicker(!showSessionPicker)}
157
- className="flex w-full items-center space-x-1 text-xs font-semibold text-ink hover:text-ink/80 transition-colors py-1 min-w-0"
157
+ className="tap-chip flex w-full items-center space-x-1 text-xs font-semibold text-ink hover:text-ink/80 transition-colors py-1 min-w-0"
158
158
  title={displayTitle}
159
159
  >
160
160
  <span className="truncate">{displayTitle}</span>
@@ -17,12 +17,15 @@ import type { RefObject } from 'preact/compat';
17
17
  import { MobileSessionToolbar } from '@/client/components/mobile/mobile-session-sidebar/Toolbar';
18
18
  import { MobileSessionList } from '@/client/components/mobile/mobile-session-sidebar/List';
19
19
  import { MobileSessionListSkeleton } from '@/client/components/mobile/mobile-session-sidebar/Skeleton';
20
+ import { SessionListNotice } from '@/client/components/layout/session-sidebar/SessionListNotice';
20
21
  import type { BatchBinding } from '@/client/components/common/batch-selection/types';
21
22
  import type { SessionSortOption, WorkspaceFolderData } from '@/shared/types';
22
23
 
23
24
  export interface ClassicDrawerProps {
24
25
  folders: WorkspaceFolderData[];
25
26
  initializing: boolean;
27
+ /** The first read failed: say so and offer the retry, do not draw a skeleton. */
28
+ failed: boolean;
26
29
  activeSessionId: number | string | null;
27
30
  expandedFolders: Record<number, boolean>;
28
31
  sessionStatus: Record<string, 'stream' | 'finish' | 'abort'>;
@@ -59,6 +62,7 @@ export interface ClassicDrawerProps {
59
62
  export function ClassicDrawer({
60
63
  folders,
61
64
  initializing,
65
+ failed,
62
66
  activeSessionId,
63
67
  expandedFolders,
64
68
  sessionStatus,
@@ -116,7 +120,9 @@ export function ClassicDrawer({
116
120
  selecting={selecting}
117
121
  />
118
122
 
119
- {initializing ? (
123
+ {failed ? (
124
+ <SessionListNotice touch onRetry={onRefresh} />
125
+ ) : initializing ? (
120
126
  <MobileSessionListSkeleton />
121
127
  ) : (
122
128
  <MobileSessionList
@@ -154,7 +154,7 @@ export function MobileSessionToolbar({
154
154
  >
155
155
  <Calendar size={16} strokeWidth={1.8} />
156
156
  {scheduledCount > 0 && (
157
- <span className="absolute -top-0.5 -right-0.5 min-w-[13px] h-[13px] px-[3px] rounded-full bg-ink text-canvas text-[8px] leading-[13px] text-center font-semibold">
157
+ <span className="absolute -top-0.5 -right-0.5 min-w-[13px] h-[13px] px-[3px] rounded-full bg-ink text-canvas text-[10px] leading-[13px] text-center font-semibold">
158
158
  {scheduledCount > 9 ? '9+' : scheduledCount}
159
159
  </span>
160
160
  )}
@@ -1,4 +1,4 @@
1
- import { useEffect, useState } from 'preact/hooks';
1
+ import { useEffect, useRef, useState } from 'preact/hooks';
2
2
  import { AlertCircle, Check, ChevronLeft, X } from 'lucide-preact';
3
3
  import type { SettingsCategoryId, SettingsState } from '@/shared/types';
4
4
  import { mergeKabmoSettings } from '@/shared/lib/settings/client';
@@ -9,6 +9,7 @@ import { useReloadOmpEngine } from '@/client/hooks/settings/reload-engine';
9
9
  import { useRestartKabmo } from '@/client/hooks/settings/restart-kabmo';
10
10
  import { applySettingsSideEffects } from '@/client/components/settings/apply-side-effects';
11
11
  import { useKabmoEvent } from '@/client/hooks/ui/window-event';
12
+ import { useDialogBehaviour } from '@/client/hooks/ui/dialog-behaviour';
12
13
  import { SETTINGS_CATEGORIES, SettingsSidebar } from '@/client/components/settings/Sidebar';
13
14
  import { AppearanceSettings } from '@/client/components/settings/categories/AppearanceSettings';
14
15
  import { ChatSettings } from '@/client/components/settings/categories/ChatSettings';
@@ -69,6 +70,14 @@ export function SettingsModal({
69
70
  mergeKabmoSettings(DEFAULT_SETTINGS, appSettings),
70
71
  );
71
72
 
73
+ // The sheet is a dialog: it carries the role, traps Tab, closes on Escape and
74
+ // returns focus to the Settings button. Measured before this, focus stayed on
75
+ // `<body>` when it opened and the first Tab went to the page behind the veil.
76
+ // Focus lands on the search field, which is the first control in BOTH layouts
77
+ // and is the fastest way to the category the user came for.
78
+ const panelRef = useRef<HTMLDivElement | null>(null);
79
+ useDialogBehaviour(panelRef, { open: isOpen, onClose });
80
+
72
81
  useEffect(() => {
73
82
  if (isOpen) {
74
83
  setActiveCategory(initialCategory);
@@ -193,6 +202,11 @@ export function SettingsModal({
193
202
  onClick={onClose}
194
203
  >
195
204
  <div
205
+ ref={panelRef}
206
+ role="dialog"
207
+ aria-modal="true"
208
+ aria-label="Settings"
209
+ tabIndex={-1}
196
210
  className="glass-overlay relative bg-paper border border-ink/15 md:rounded-2xl shadow-2xl w-full h-full md:max-w-5xl lg:max-w-6xl xl:max-w-[1280px] md:h-[min(90vh,900px)] md:max-h-[92vh] flex flex-col md:flex-row overflow-hidden text-ink"
197
211
  onClick={(e) => e.stopPropagation()}
198
212
  >
@@ -101,7 +101,7 @@ export const ProjectSelectorDropdown: FunctionComponent<ProjectSelectorDropdownP
101
101
  <div className={variant === 'compact' ? 'p-2.5 border-b border-ink/10' : 'p-3 border-b border-ink/10'}>
102
102
  <div className="flex items-center gap-2 px-2.5 py-1.5 rounded-lg border border-dashed border-ink/15 text-[11px] text-ink/50">
103
103
  <Folder size={13} className="text-ink/40 flex-shrink-0" />
104
- <span className="truncate">No projects yet — add one in Settings → Projects</span>
104
+ <span className="truncate">No projects yet. Add one in Settings, Projects</span>
105
105
  </div>
106
106
  </div>
107
107
  );
@@ -25,7 +25,7 @@ export const SETTINGS_CATEGORIES: CategoryDef[] = [
25
25
  { id: 'omp', label: 'OMP Engine', icon: Cpu, section: 'OMP', description: 'Live agent state and native omp config keys.' },
26
26
  { id: 'providers', label: 'Providers', icon: Cloud, section: 'OMP', description: 'AI model engines, endpoints, and credentials.' },
27
27
  { id: 'agents', label: 'Agents', icon: Bot, section: 'OMP', description: 'Autonomous agent persona, self-healing, and reasoning.' },
28
- { id: 'behavior', label: 'Behavior', icon: Sliders, section: 'OMP', description: 'Native AGENTS.md and RULES.md — global instructions, permission gates, and safety filters.' },
28
+ { id: 'behavior', label: 'Behavior', icon: Sliders, section: 'OMP', description: 'Native AGENTS.md and RULES.md: global instructions, permission gates, and safety filters.' },
29
29
  { id: 'commands', label: 'Commands', icon: Terminal, section: 'OMP', description: 'Slash command macros and terminal shortcuts.' },
30
30
  { id: 'mcp', label: 'MCP', icon: Boxes, section: 'OMP', description: 'Model Context Protocol servers and dynamic tools.' },
31
31
  // LIBRARY
@@ -128,7 +128,7 @@ export function SettingsSidebar({
128
128
  <span className="truncate">{item.label}</span>
129
129
  </div>
130
130
  {item.badge && (
131
- <span className="px-1.5 py-0.2 text-[9px] font-mono font-medium rounded bg-amber-500/15 text-amber-900 border border-amber-500/20">
131
+ <span className="px-1.5 py-0.2 text-[10px] font-mono font-medium rounded border border-warning/30 bg-warning/15 text-warning">
132
132
  {item.badge}
133
133
  </span>
134
134
  )}
@@ -221,7 +221,7 @@ export function OmpSettings(_props: OmpSettingsProps) {
221
221
  <h3 className="text-sm font-semibold text-ink">Config</h3>
222
222
  <p className="text-ink/50 mt-0.5">
223
223
  Schema-driven settings backed by <span className="font-mono">omp config</span>.
224
- {searchQuery.trim() && ' — matching keys only'}
224
+ {searchQuery.trim() && ', matching keys only'}
225
225
  </p>
226
226
  </div>
227
227
  {savedKey && savedKey !== 'role-map' && !savedKey.startsWith('ext-') && (
@@ -176,7 +176,7 @@ export function TokenUsageSettings({ settings: _settings, onUpdate: _onUpdate }:
176
176
  role="tab"
177
177
  aria-selected={metric === entry.id}
178
178
  onClick={() => setMetric(entry.id)}
179
- className={`rounded px-2 py-0.5 text-[9px] font-bold tracking-wider transition-colors ${
179
+ className={`rounded px-2 py-0.5 text-[10px] font-bold tracking-wider transition-colors ${
180
180
  metric === entry.id ? 'bg-paper text-ink shadow-xs' : 'text-ink/50 hover:text-ink'
181
181
  }`}
182
182
  >
@@ -137,7 +137,7 @@ export const AgentDetailPane: FunctionComponent<AgentDetailPaneProps> = ({
137
137
  placeholder="What does this agent do? Shown when omp lists it."
138
138
  rows={2}
139
139
  disabled={readOnly || feedback.saving}
140
- className="w-full rounded-lg border border-ink/20 bg-paper p-3 text-xs text-ink transition-colors hover:border-ink/40 focus:border-ink focus:outline-none placeholder:text-ink/30 disabled:opacity-60"
140
+ className="w-full rounded-lg border border-ink/20 bg-paper p-3 text-xs text-ink transition-colors hover:border-ink/40 focus:border-ink focus:outline-none placeholder:text-ink/35 disabled:opacity-60"
141
141
  />
142
142
  <p className="mt-1 text-[10px] text-ink/45">
143
143
  Required by omp: a definition without a description is not loaded at all.
@@ -198,7 +198,7 @@ export const AgentDetailPane: FunctionComponent<AgentDetailPaneProps> = ({
198
198
  onInput={(e) => setToolsText(e.currentTarget.value)}
199
199
  placeholder="read, grep, glob, edit"
200
200
  disabled={readOnly || feedback.saving}
201
- className="w-full rounded-lg border border-ink/20 bg-paper px-3 py-2 font-mono text-xs text-ink transition-colors hover:border-ink/40 focus:border-ink focus:outline-none placeholder:text-ink/30 disabled:opacity-60"
201
+ className="w-full rounded-lg border border-ink/20 bg-paper px-3 py-2 font-mono text-xs text-ink transition-colors hover:border-ink/40 focus:border-ink focus:outline-none placeholder:text-ink/35 disabled:opacity-60"
202
202
  />
203
203
  </div>
204
204
 
@@ -215,7 +215,7 @@ export const AgentDetailPane: FunctionComponent<AgentDetailPaneProps> = ({
215
215
  onInput={(e) => setFormData({ ...formData, spawns: e.currentTarget.value || undefined })}
216
216
  placeholder="*"
217
217
  disabled={readOnly || feedback.saving}
218
- className="w-full rounded-lg border border-ink/20 bg-paper px-3 py-2 font-mono text-xs text-ink transition-colors hover:border-ink/40 focus:border-ink focus:outline-none placeholder:text-ink/30 disabled:opacity-60"
218
+ className="w-full rounded-lg border border-ink/20 bg-paper px-3 py-2 font-mono text-xs text-ink transition-colors hover:border-ink/40 focus:border-ink focus:outline-none placeholder:text-ink/35 disabled:opacity-60"
219
219
  />
220
220
  </div>
221
221
  </div>
@@ -62,7 +62,7 @@ export function EditorFontSection({ settings, onUpdate }: EditorFontSectionProps
62
62
  <span className="mt-0.5 flex items-center gap-1.5 text-[10px] text-ink/50">
63
63
  <span>{choice.label}</span>
64
64
  {choice.bundled && (
65
- <span className="rounded bg-ink/8 px-1 py-px text-[9px] uppercase tracking-wide">
65
+ <span className="rounded bg-ink/8 px-1 py-px text-[10px] uppercase tracking-wide">
66
66
  Bundled
67
67
  </span>
68
68
  )}
@@ -140,7 +140,7 @@ export function EditorThemeSection({ settings, onUpdate }: EditorThemeSectionPro
140
140
  >
141
141
  <span className="flex items-center gap-2">
142
142
  <span className="truncate font-semibold text-ink">Auto</span>
143
- <span className="shrink-0 rounded-full border border-ink/15 px-1.5 py-px text-[9px] font-semibold uppercase tracking-wider text-ink/50">
143
+ <span className="shrink-0 rounded-full border border-ink/15 px-1.5 py-px text-[10px] font-semibold uppercase tracking-wider text-ink/50">
144
144
  app palette
145
145
  </span>
146
146
  {active === EDITOR_AUTO_THEME_ID && <Check size={14} className="ml-auto shrink-0 text-ink" />}
@@ -169,7 +169,7 @@ export function EditorThemeSection({ settings, onUpdate }: EditorThemeSectionPro
169
169
  <span className="truncate font-semibold text-ink" title={theme.label}>
170
170
  {theme.label}
171
171
  </span>
172
- <span className="shrink-0 rounded-full border border-ink/15 px-1.5 py-px text-[9px] font-semibold uppercase tracking-wider text-ink/50">
172
+ <span className="shrink-0 rounded-full border border-ink/15 px-1.5 py-px text-[10px] font-semibold uppercase tracking-wider text-ink/50">
173
173
  {theme.variant}
174
174
  </span>
175
175
  {selected && <Check size={14} className="ml-auto shrink-0 text-ink" />}
@@ -17,7 +17,7 @@
17
17
  * components: those paint from the document attribute, so both cards would show
18
18
  * the user's current choice and neither would preview its own. The colour values
19
19
  * come from the SAME tables and formula the stylesheet uses (`ICON_TINT_TOKENS`,
20
- * `iconHueColor`, `BRAND_COLORS`, `FILE_BRAND_COLORS`), so a preview cannot
20
+ * `iconTone`, `BRAND_COLORS`, `FILE_BRAND_COLORS`), so a preview cannot
21
21
  * promise a look the shell does not ship.
22
22
  */
23
23
 
@@ -32,7 +32,7 @@ import {
32
32
  } from '@/shared/lib/theme/icon-style';
33
33
  import { BRAND_COLORS } from '@/shared/lib/models/provider/brand-color';
34
34
  import { FILE_BRAND_COLORS } from '@/shared/lib/icons/file-brand-color';
35
- import { ICON_TINT_TOKENS, iconHue, iconHueColor, iconTintRole } from '@/shared/lib/icons/tint';
35
+ import { ICON_TINT_TOKENS, iconHue, iconTintRole, iconTone } from '@/shared/lib/icons/tint';
36
36
 
37
37
  interface IconStyleSectionProps {
38
38
  settings: SettingsState;
@@ -44,12 +44,12 @@ function GlyphSample({ name, Icon, colored }: { name: string; Icon: typeof Check
44
44
  const role = iconTintRole(name);
45
45
  // The role wins over the hue, exactly as the stylesheet orders its rules.
46
46
  // Same formula as the stylesheet's light paint, through the same helper: the
47
- // sample reads the hue table and the ONE saturation/lightness pair.
47
+ // sample reads the hue table and the solved light tone.
48
48
  const color = !colored
49
49
  ? undefined
50
50
  : role
51
51
  ? ICON_TINT_TOKENS[role]
52
- : iconHueColor(iconHue(name), 'light');
52
+ : iconTone(iconHue(name), 'light');
53
53
  return <Icon size={13} strokeWidth={2} style={color ? { color } : undefined} aria-hidden="true" />;
54
54
  }
55
55
 
@@ -129,7 +129,7 @@ export function IconStyleSection({ settings, onUpdate }: IconStyleSectionProps)
129
129
  <span className="text-xs font-semibold text-ink">{copy.label}</span>
130
130
  <span className="font-mono text-[10px] text-ink/40">{copy.caption}</span>
131
131
  {isSelected && (
132
- <span className="ml-auto rounded-full bg-ink px-1.5 py-[1px] text-[9px] font-semibold text-paper">
132
+ <span className="ml-auto rounded-full bg-ink px-1.5 py-[1px] text-[10px] font-semibold text-paper">
133
133
  active
134
134
  </span>
135
135
  )}
@@ -142,7 +142,7 @@ export function SidebarStyleSection({ settings, onUpdate }: SidebarStyleSectionP
142
142
  <span className="text-xs font-semibold text-ink">{copy.label}</span>
143
143
  <span className="font-mono text-[10px] text-ink/40">{copy.caption}</span>
144
144
  {isSelected && (
145
- <span className="ml-auto rounded-full bg-ink px-1.5 py-[1px] text-[9px] font-semibold text-paper">
145
+ <span className="ml-auto rounded-full bg-ink px-1.5 py-[1px] text-[10px] font-semibold text-paper">
146
146
  active
147
147
  </span>
148
148
  )}
@@ -163,7 +163,7 @@ export function SurfaceStyleSection({ settings, onUpdate }: SurfaceStyleSectionP
163
163
  <span className="text-xs font-semibold text-ink">{copy.label}</span>
164
164
  <span className="font-mono text-[10px] text-ink/40">{copy.caption}</span>
165
165
  {isSelected && (
166
- <span className="ml-auto rounded-full bg-ink px-1.5 py-[1px] text-[9px] font-semibold text-paper">
166
+ <span className="ml-auto rounded-full bg-ink px-1.5 py-[1px] text-[10px] font-semibold text-paper">
167
167
  active
168
168
  </span>
169
169
  )}
@@ -40,7 +40,7 @@ export function ThemeCard({ theme, selected, onSelect }: ThemeCardProps) {
40
40
  <span className="truncate font-semibold text-ink" title={theme.name}>
41
41
  {theme.name}
42
42
  </span>
43
- <span className="shrink-0 rounded-full border border-ink/15 px-1.5 py-px text-[9px] font-semibold uppercase tracking-wider text-ink/50">
43
+ <span className="shrink-0 rounded-full border border-ink/15 px-1.5 py-px text-[10px] font-semibold uppercase tracking-wider text-ink/50">
44
44
  {theme.variant}
45
45
  </span>
46
46
  {selected && <Check size={14} className="ml-auto shrink-0 text-ink" />}
@@ -162,7 +162,7 @@ export function ComposerStyleSection({ settings, onUpdate }: ComposerStyleSectio
162
162
  <span className="flex items-center gap-1.5">
163
163
  <span className="text-xs font-semibold text-ink">{copy.label}</span>
164
164
  {isSelected && (
165
- <span className="ml-auto rounded-full bg-ink px-1.5 py-[1px] text-[9px] font-semibold text-paper">
165
+ <span className="ml-auto rounded-full bg-ink px-1.5 py-[1px] text-[10px] font-semibold text-paper">
166
166
  active
167
167
  </span>
168
168
  )}
@@ -174,7 +174,7 @@ export function ChatGoalSection({ settings, onUpdate }: ChatGoalSectionProps) {
174
174
  onKeyDown={(event) => {
175
175
  if (event.key === 'Enter') commitBudget();
176
176
  }}
177
- placeholder="none — the turn ceiling is then the only stop"
177
+ placeholder="none: the turn ceiling is then the only stop"
178
178
  inputMode="numeric"
179
179
  aria-label="Default goal token budget"
180
180
  className="w-56 rounded border border-ink/15 bg-paper px-2 py-1.5 font-mono text-[11.5px] outline-none focus:border-ink"
@@ -167,7 +167,7 @@ export const CommandDetailPane: FunctionComponent<CommandDetailPaneProps> = ({
167
167
  disabled={readOnlyNow}
168
168
  placeholder="What does this command do?"
169
169
  rows={2}
170
- className="w-full text-xs p-3 rounded-lg border border-ink/20 hover:border-ink/40 bg-paper focus:outline-none focus:border-ink placeholder:text-ink/30 text-ink transition-colors disabled:opacity-60"
170
+ className="w-full text-xs p-3 rounded-lg border border-ink/20 hover:border-ink/40 bg-paper focus:outline-none focus:border-ink placeholder:text-ink/35 text-ink transition-colors disabled:opacity-60"
171
171
  />
172
172
  </div>
173
173
 
@@ -181,7 +181,7 @@ export const CommandDetailPane: FunctionComponent<CommandDetailPaneProps> = ({
181
181
  onChange={(e) => setFormData({ ...formData, inputHint: e.currentTarget.value })}
182
182
  disabled={readOnlyNow}
183
183
  placeholder="[on|off|status]"
184
- className="w-full text-xs font-mono p-2.5 rounded-lg border border-ink/20 hover:border-ink/40 bg-paper focus:outline-none focus:border-ink placeholder:text-ink/30 text-ink transition-colors disabled:opacity-60"
184
+ className="w-full text-xs font-mono p-2.5 rounded-lg border border-ink/20 hover:border-ink/40 bg-paper focus:outline-none focus:border-ink placeholder:text-ink/35 text-ink transition-colors disabled:opacity-60"
185
185
  />
186
186
  <p className="text-[11px] text-ink/60 mt-1">
187
187
  Shown as ghost text after <span className="font-mono">/{formData.name || 'name'}</span> in the composer.