@kabmo-labs/kabmo 0.18.0 → 0.21.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.
- package/README.md +43 -13
- package/dist/client/index.html +3 -3
- package/dist/client/index.js +485 -484
- package/dist/client/static/js/index-0721wrkf.css +1 -0
- package/dist/client/static/js/{index-tc09dtca.js → index-zg32n2sk.js} +778 -777
- package/dist/client/static/{manifest-42r8wcmg.webmanifest → manifest-q6h8k9e0.webmanifest} +1 -1
- package/index.html +1 -1
- package/marketplace/plugins/command-runner/package.json +3 -2
- package/marketplace/plugins/git-forge/package.json +3 -2
- package/marketplace/plugins/session-info/package.json +3 -2
- package/marketplace/plugins/stats/package.json +3 -2
- package/package.json +3 -1
- package/public/manifest.webmanifest +1 -1
- package/src/client/components/auth/login-screen/index.tsx +2 -1
- package/src/client/components/common/ComposerPicker.tsx +1 -1
- package/src/client/components/common/FolderPicker.tsx +2 -2
- package/src/client/components/common/Modal.tsx +2 -2
- package/src/client/components/common/PWAInstallButton.tsx +2 -2
- package/src/client/components/common/ViewportSelector.tsx +1 -1
- package/src/client/components/common/anchored-menu/index.tsx +5 -1
- package/src/client/components/common/batch-selection/SelectionCheckbox.tsx +2 -1
- package/src/client/components/common/brand-wordmark/index.test.tsx +13 -2
- package/src/client/components/common/brand-wordmark/index.tsx +13 -2
- package/src/client/components/common/checkbox/style.test.ts +142 -0
- package/src/client/components/common/checkbox/style.ts +51 -0
- package/src/client/components/common/context-usage-button/index.tsx +2 -2
- package/src/client/components/common/file-icon/index.tsx +23 -9
- package/src/client/components/common/header-controls/MoreMenu.tsx +1 -1
- package/src/client/components/common/markdown-review/ReviewPopover.tsx +1 -1
- package/src/client/components/common/panel-mark/index.test.tsx +124 -0
- package/src/client/components/common/panel-mark/index.tsx +105 -0
- package/src/client/components/common/provider-icon/glyphs.test.ts +1 -1
- package/src/client/components/common/provider-icon/index.test.ts +14 -0
- package/src/client/components/common/provider-icon/index.tsx +4 -0
- package/src/client/components/common/provider-icon/resolve.test.ts +8 -7
- package/src/client/components/common/provider-icon/resolve.ts +16 -3
- package/src/client/components/common/session-actions-menu/index.tsx +1 -1
- package/src/client/components/common/toolbar-row/index.tsx +1 -1
- package/src/client/components/layout/ActivityBar.tsx +22 -3
- package/src/client/components/layout/LeftDock.tsx +9 -2
- package/src/client/components/layout/PanelVisibilityMenu.tsx +1 -1
- package/src/client/components/layout/WindowAura.tsx +27 -0
- package/src/client/components/layout/desktop-layout/LeftColumn.tsx +1 -1
- package/src/client/components/layout/desktop-layout/TopNavbar.tsx +2 -2
- package/src/client/components/layout/desktop-layout/WorkspacePanels.tsx +11 -2
- package/src/client/components/layout/desktop-layout/index.tsx +3 -1
- package/src/client/components/layout/session-sidebar/CategoryHeader.tsx +3 -3
- package/src/client/components/layout/session-sidebar/Header.tsx +1 -1
- package/src/client/components/layout/session-sidebar/OverflowMenu.tsx +1 -1
- package/src/client/components/layout/session-sidebar/Toolbar.tsx +1 -1
- package/src/client/components/layout/session-sidebar/about-modal/index.tsx +2 -2
- package/src/client/components/layout/session-sidebar/modern/ActionRow.tsx +1 -1
- package/src/client/components/layout/session-sidebar/modern/WorkspaceHeader.tsx +13 -5
- package/src/client/components/layout/session-sidebar/new-workspace-modal/index.tsx +2 -2
- package/src/client/components/layout/session-sidebar/scheduler-modal/TaskForm.tsx +2 -1
- package/src/client/components/layout/session-sidebar/scheduler-modal/index.tsx +2 -2
- package/src/client/components/mobile/LayoutWrapper.tsx +3 -1
- package/src/client/components/mobile/mobile-main-view/Header.tsx +2 -2
- package/src/client/components/mobile/mobile-session-sidebar/Header.tsx +1 -1
- package/src/client/components/mobile/mobile-session-sidebar/Toolbar.tsx +1 -1
- package/src/client/components/mobile/panel-chips.tsx +10 -2
- package/src/client/components/settings/Modal.tsx +4 -4
- package/src/client/components/settings/ProjectSelectorDropdown.tsx +2 -2
- package/src/client/components/settings/apply-side-effects.test.ts +30 -0
- package/src/client/components/settings/apply-side-effects.ts +14 -0
- package/src/client/components/settings/categories/AppearanceSettings.tsx +6 -0
- package/src/client/components/settings/categories/appearance-settings/EditorBlameSection.tsx +2 -1
- package/src/client/components/settings/categories/appearance-settings/EditorTypingSection.tsx +2 -1
- package/src/client/components/settings/categories/appearance-settings/IconStyleSection.tsx +144 -0
- package/src/client/components/settings/categories/appearance-settings/SurfaceStyleSection.test.tsx +120 -0
- package/src/client/components/settings/categories/appearance-settings/SurfaceStyleSection.tsx +180 -0
- package/src/client/components/settings/categories/mcp-settings/DetailPane.tsx +2 -1
- package/src/client/components/settings/categories/mcp-settings/ImportModal.tsx +2 -2
- package/src/client/components/settings/categories/omp-settings/OrderedChips.tsx +1 -1
- package/src/client/components/settings/categories/panel-plugins/AvailableList.tsx +1 -1
- package/src/client/components/settings/categories/panel-plugins/BuiltinList.tsx +21 -3
- package/src/client/components/settings/categories/panel-plugins/GitFreshness.test.tsx +46 -0
- package/src/client/components/settings/categories/panel-plugins/GitFreshness.tsx +1 -1
- package/src/client/components/settings/categories/panel-plugins/InstalledList.tsx +7 -9
- package/src/client/components/settings/categories/panel-plugins/PluginCard.test.tsx +149 -0
- package/src/client/components/settings/categories/panel-plugins/PluginCard.tsx +34 -7
- package/src/client/components/settings/categories/panel-plugins/PluginMark.test.ts +66 -2
- package/src/client/components/settings/categories/panel-plugins/PluginMark.tsx +47 -10
- package/src/client/components/settings/categories/panel-plugins/Section.tsx +7 -1
- package/src/client/components/settings/categories/panel-plugins/Toolbar.tsx +35 -2
- package/src/client/components/settings/categories/plugin-settings/DetailPane.tsx +2 -1
- package/src/client/components/settings/categories/plugin-settings/SettingsSection.tsx +2 -1
- package/src/client/components/settings/categories/project-settings/ModelDropdown.tsx +1 -1
- package/src/client/components/settings/categories/project-settings/WorktreeSettings.tsx +2 -1
- package/src/client/components/settings/categories/provider-settings/DeleteProviderModal.tsx +2 -2
- package/src/client/components/settings/categories/provider-settings/EntryAdvanced.tsx +3 -2
- package/src/client/components/settings/categories/provider-settings/LogoutProviderModal.tsx +2 -2
- package/src/client/components/settings/categories/skill-catalog/GitImportPanel.tsx +3 -2
- package/src/client/components/settings/categories/skill-settings/DetailHeader.tsx +2 -1
- package/src/client/components/settings/categories/token-usage-settings/Controls.tsx +1 -1
- package/src/client/components/workspace/btw-panel/TopicMenu.tsx +1 -1
- package/src/client/components/workspace/chat-timeline/AiMessageFooter.tsx +2 -2
- package/src/client/components/workspace/chat-timeline/NewChatModal.tsx +3 -3
- package/src/client/components/workspace/chat-timeline/UndoConfirmModal.tsx +2 -2
- package/src/client/components/workspace/chat-timeline/chat-input/AccessDropdown.tsx +1 -1
- package/src/client/components/workspace/chat-timeline/chat-input/GoalModal.tsx +4 -3
- package/src/client/components/workspace/chat-timeline/chat-input/ThinkingLevelDropdown.tsx +1 -1
- package/src/client/components/workspace/chat-timeline/chat-input/WaitingDependencyPicker.tsx +1 -1
- package/src/client/components/workspace/chat-timeline/plan-review/index.tsx +2 -2
- package/src/client/components/workspace/chat-timeline/target-picker/WorkspacePicker.tsx +1 -1
- package/src/client/components/workspace/chat-timeline/target-picker/WorktreePicker.tsx +1 -1
- package/src/client/components/workspace/chat-timeline/tool-renderers/extension-dialog/index.tsx +2 -6
- package/src/client/components/workspace/context-panel/CostBreakdownPopover.tsx +1 -1
- package/src/client/components/workspace/diff-panel/index.tsx +2 -2
- package/src/client/components/workspace/editor/PluginRail.tsx +1 -1
- package/src/client/components/workspace/editor/SaveDeletedFileModal.tsx +2 -2
- package/src/client/components/workspace/editor/TabContextMenu.tsx +1 -1
- package/src/client/components/workspace/editor/Tabs.tsx +1 -1
- package/src/client/components/workspace/file-explorer/ContextMenu.tsx +1 -1
- package/src/client/components/workspace/file-explorer/Modals.tsx +10 -10
- package/src/client/components/workspace/file-explorer/RootMenu.tsx +1 -1
- package/src/client/components/workspace/git-panel/BranchToolbar.test.tsx +130 -0
- package/src/client/components/workspace/git-panel/BranchToolbar.tsx +21 -11
- package/src/client/components/workspace/git-panel/CommitBox.tsx +2 -1
- package/src/client/components/workspace/git-panel/Modals.tsx +2 -2
- package/src/client/components/workspace/git-panel/StashSection.tsx +2 -1
- package/src/client/components/workspace/git-panel/branch-modal/DeleteDialog.tsx +2 -1
- package/src/client/components/workspace/git-panel/branch-modal/RenameDialog.tsx +2 -1
- package/src/client/components/workspace/git-panel/commit-modal/index.tsx +2 -2
- package/src/client/components/workspace/git-panel/index.tsx +7 -0
- package/src/client/components/workspace/model-dropdown/Panel.tsx +1 -1
- package/src/client/components/workspace/model-dropdown/SpecsTooltip.tsx +1 -1
- package/src/client/components/workspace/plugin-panel/catalog.tsx +7 -0
- package/src/client/components/workspace/plugin-panel/resolve.tsx +4 -0
- package/src/client/components/workspace/search-panel/Body.tsx +1 -1
- package/src/client/components/workspace/usage-panel/ProviderSelect.tsx +1 -1
- package/src/client/glass-sticky.test.ts +46 -0
- package/src/client/glass.css +795 -0
- package/src/client/glass.test.ts +306 -0
- package/src/client/hooks/ui/glass-support.ts +57 -0
- package/src/client/hooks/ui/icon-style.ts +59 -0
- package/src/client/hooks/ui/stuck-header.test.ts +213 -0
- package/src/client/hooks/ui/stuck-header.ts +122 -0
- package/src/client/hooks/ui/style-attributes.test.ts +120 -0
- package/src/client/hooks/ui/surface-style.ts +56 -0
- package/src/client/hooks/workspace/panel-hues.ts +23 -0
- package/src/client/hooks/workspace/panel-registry.ts +8 -4
- package/src/client/main.tsx +10 -0
- package/src/client/tailwind.css +264 -11
- package/src/server/lib/assets/shell-attributes.server.ts +80 -0
- package/src/server/lib/assets/shell-attributes.test.ts +86 -0
- package/src/server/lib/lifecycle/tls.test.ts +6 -1
- package/src/server/lib/omp/rpc/frame-fold-host.test-util.ts +1 -0
- package/src/server/lib/omp/rpc/frame-fold-signals.test.ts +2 -30
- package/src/server/lib/omp/rpc/frame-fold.test.ts +55 -0
- package/src/server/lib/omp/rpc/frame-fold.ts +4 -0
- package/src/server/lib/omp/rpc/manager.ts +2 -2
- package/src/server/lib/omp/rpc/process-helpers.ts +11 -0
- package/src/server/lib/omp/rpc/process.test.ts +106 -0
- package/src/server/lib/omp/rpc/process.ts +28 -4
- package/src/server/lib/omp/rpc/run-settle.server.ts +12 -0
- package/src/server/lib/omp/rpc/run-settle.test.ts +22 -0
- package/src/server/lib/omp/rpc/session-command-guards.ts +5 -0
- package/src/server/lib/omp/rpc/session-commands.test.ts +9 -1
- package/src/server/lib/omp/rpc/session-commands.ts +11 -0
- package/src/server/lib/omp/rpc/terminal-settle.ts +29 -7
- package/src/server/lib/panels/bundled-catalog.server.ts +1 -0
- package/src/server/lib/panels/git-update.server.test.ts +20 -0
- package/src/server/lib/panels/git-update.server.ts +20 -4
- package/src/server/lib/panels/manifest.test.ts +20 -0
- package/src/server/lib/panels/manifest.ts +12 -0
- package/src/server/lib/panels/scan.server.ts +4 -0
- package/src/server/lib/panels/sync.server.ts +9 -1
- package/src/server/lib/panels/update.server.test.ts +193 -0
- package/src/server/lib/panels/update.server.ts +210 -0
- package/src/server/lib/plugins/server-half.server.ts +42 -0
- package/src/server/lib/queue/delivery-dispatch.server.test.ts +48 -0
- package/src/server/lib/queue/delivery-harness.ts +8 -4
- package/src/server/lib/queue/delivery.server.test.ts +29 -0
- package/src/server/lib/queue/delivery.server.ts +39 -0
- package/src/server/lib/queue/store.server.test.ts +22 -2
- package/src/server/lib/queue/store.server.ts +33 -11
- package/src/server/lib/terminal/attach-replay.test.ts +26 -8
- package/src/server/plugins/ssr.ts +22 -5
- package/src/server/routes/panels/install-route.test.ts +238 -0
- package/src/server/routes/panels/install.ts +36 -64
- package/src/server/routes/panels/panel-routes.test-util.ts +6 -1
- package/src/server/routes/panels/routes.test.ts +1 -118
- package/src/shared/lib/icons/file-brand-color.ts +38 -0
- package/src/shared/lib/icons/icon-paint-css.test.ts +235 -0
- package/src/shared/lib/icons/icon-paint-css.ts +285 -0
- package/src/shared/lib/icons/icon-paint-panel.ts +109 -0
- package/src/shared/lib/icons/icon-tone.ts +166 -0
- package/src/shared/lib/icons/tint-hues.generated.ts +277 -0
- package/src/shared/lib/icons/tint.test.ts +333 -0
- package/src/shared/lib/icons/tint.ts +248 -0
- package/src/shared/lib/models/provider/brand-color.test.ts +116 -0
- package/src/shared/lib/models/provider/brand-color.ts +103 -0
- package/src/shared/lib/omp/rpc/frame.test.ts +65 -0
- package/src/shared/lib/omp/rpc/frame.ts +58 -3
- package/src/shared/lib/panels/update.test.ts +107 -0
- package/src/shared/lib/panels/update.ts +73 -0
- package/src/shared/lib/settings/defaults.ts +4 -0
- package/src/shared/lib/theme/catalog.test.ts +5 -4
- package/src/shared/lib/theme/catalog.ts +18 -3
- package/src/shared/lib/theme/color.ts +50 -0
- package/src/shared/lib/theme/glass-support.test.ts +38 -0
- package/src/shared/lib/theme/glass-support.ts +73 -0
- package/src/shared/lib/theme/icon-style.test.ts +74 -0
- package/src/shared/lib/theme/icon-style.ts +90 -0
- package/src/shared/lib/theme/legibility.ts +91 -0
- package/src/shared/lib/theme/palettes/dark-extended.ts +152 -0
- package/src/shared/lib/theme/palettes/light-extended.ts +157 -0
- package/src/shared/lib/theme/surface-style.test.ts +68 -0
- package/src/shared/lib/theme/surface-style.ts +91 -0
- package/src/shared/lib/theme/theme.test.ts +11 -7
- package/src/shared/lib/workspace/panel-hues.test.ts +68 -0
- package/src/shared/lib/workspace/panel-hues.ts +57 -0
- package/src/shared/types/panels-registry.ts +6 -0
- package/src/shared/types/panels.ts +14 -0
- package/src/shared/types/settings/state.ts +26 -0
- package/src/test-support/fake-omp-frames.ts +163 -0
- package/dist/client/static/js/index-hp75vsv9.css +0 -1
- /package/src/{client/components/common/file-icon/brand-paths.ts → shared/lib/icons/file-brand-paths.ts} +0 -0
|
@@ -21,6 +21,7 @@ import { h, render } from 'preact';
|
|
|
21
21
|
import type { ComponentChild } from 'preact';
|
|
22
22
|
import { act } from 'preact/test-utils';
|
|
23
23
|
import { PluginMark } from '@/client/components/settings/categories/panel-plugins/PluginMark';
|
|
24
|
+
import { ICON_TONES } from '@/shared/lib/icons/tint-hues.generated';
|
|
24
25
|
|
|
25
26
|
const DOM_GLOBALS = ['window', 'document', 'navigator', 'Node', 'Element', 'HTMLElement', 'Event'] as const;
|
|
26
27
|
/** The runner's own globals, restored on teardown — deleting them would strip
|
|
@@ -74,8 +75,11 @@ describe('PluginMark', () => {
|
|
|
74
75
|
expect(el.querySelector('img')).toBeNull();
|
|
75
76
|
expect(span?.style.width).toBe('16px');
|
|
76
77
|
expect(span?.style.height).toBe('16px');
|
|
77
|
-
//
|
|
78
|
-
|
|
78
|
+
// The paint is a VARIABLE, so the mode decides it: monochrome leaves
|
|
79
|
+
// `--plugin-color` undefined and the mark keeps the ink it always used.
|
|
80
|
+
expect(span?.style.backgroundColor).toBe('var(--plugin-color, currentColor)');
|
|
81
|
+
expect(span?.getAttribute('data-plugin-mark')).toBe('');
|
|
82
|
+
expect(span?.style.getPropertyValue('--icon-hue')).not.toBe('');
|
|
79
83
|
// The extension is read off the PATH; the registry's URL carries a `?v=` hash.
|
|
80
84
|
expect(span?.style.maskImage).toContain('/api/panels/icon/demo/icon.svg?v=abc');
|
|
81
85
|
expect(span?.style.maskSize).toBe('contain');
|
|
@@ -109,6 +113,66 @@ describe('PluginMark', () => {
|
|
|
109
113
|
expect(el.querySelector('span')).toBeNull();
|
|
110
114
|
});
|
|
111
115
|
|
|
116
|
+
test('a plugin mark carries its own hue, stable across renders', () => {
|
|
117
|
+
const first = paint(h(PluginMark, { name: 'Demo Plugin', iconUrl: '/api/panels/icon/demo/icon.svg' }))
|
|
118
|
+
.querySelector('span');
|
|
119
|
+
const hue = first?.style.getPropertyValue('--icon-hue');
|
|
120
|
+
render(null, container);
|
|
121
|
+
const second = paint(h(PluginMark, { name: 'Demo Plugin', iconUrl: '/api/panels/icon/demo/icon.svg' }))
|
|
122
|
+
.querySelector('span');
|
|
123
|
+
|
|
124
|
+
expect(hue).toMatch(/^\d+$/);
|
|
125
|
+
expect(second?.style.getPropertyValue('--icon-hue')).toBe(hue);
|
|
126
|
+
expect(paint(h(PluginMark, { name: 'Another Plugin' })).querySelector('span')?.style.getPropertyValue('--icon-hue')).not.toBe(hue);
|
|
127
|
+
});
|
|
128
|
+
|
|
129
|
+
test('a plugin mark stamps the LIGHT tone for its hue, not just the hue', () => {
|
|
130
|
+
// The hue alone is enough for dark (one `hsl()` pair) but not for light: the
|
|
131
|
+
// light paint is a solved per-hue hex, and a plugin's hue exists only at
|
|
132
|
+
// runtime, so no generated CSS row can carry it. Without this stamp a plugin
|
|
133
|
+
// would fall back to the dated `hsl(H 60% 30%)` while every glyph beside it
|
|
134
|
+
// got the brighter tone — the reported muddiness, on one icon only.
|
|
135
|
+
const badge = paint(h(PluginMark, { name: 'Demo Plugin' })).querySelector('span');
|
|
136
|
+
const hue = Number(badge?.style.getPropertyValue('--icon-hue'));
|
|
137
|
+
const tone = badge?.style.getPropertyValue('--icon-tone') ?? '';
|
|
138
|
+
|
|
139
|
+
expect(tone).toMatch(/^#[0-9a-f]{6}$/);
|
|
140
|
+
expect(tone).toBe(ICON_TONES[hue]);
|
|
141
|
+
});
|
|
142
|
+
|
|
143
|
+
test('the initials fallback takes the same colour hook as a vector mark', () => {
|
|
144
|
+
const badge = paint(h(PluginMark, { name: 'Session Info' })).querySelector('span');
|
|
145
|
+
|
|
146
|
+
expect(badge?.getAttribute('data-plugin-mark')).toBe('');
|
|
147
|
+
// 45% of the palette ink is what `text-ink/45` meant, restated as a value so
|
|
148
|
+
// the colour mode can replace it without a second class.
|
|
149
|
+
expect(badge?.style.color).toBe('var(--plugin-color, color-mix(in srgb, var(--theme-ink) 45%, transparent))');
|
|
150
|
+
});
|
|
151
|
+
|
|
152
|
+
test('a declared colour rides as a clamped pair, so the mode still gates it', () => {
|
|
153
|
+
// The manifest's `color` is the plugin's own brand. It is set as custom
|
|
154
|
+
// properties rather than as a colour, because `monochrome` must still paint
|
|
155
|
+
// the palette ink — the stylesheet reads them only under
|
|
156
|
+
// `[data-icon-style="color"]`. Two values, because `#34d399` is 1.9:1 on
|
|
157
|
+
// white paper and 7:1 on dark: `legiblePair` derives the light one.
|
|
158
|
+
const el = paint(h(PluginMark, { name: 'Demo', iconUrl: '/api/panels/icon/demo/icon.svg', color: '#34d399' }));
|
|
159
|
+
const span = el.querySelector('span');
|
|
160
|
+
const light = span?.style.getPropertyValue('--plugin-declared-light') ?? '';
|
|
161
|
+
|
|
162
|
+
expect(light).toMatch(/^#[0-9a-f]{6}$/);
|
|
163
|
+
expect(light).not.toBe('#34d399');
|
|
164
|
+
expect(span?.style.getPropertyValue('--plugin-declared-dark')).toBe('#34d399');
|
|
165
|
+
expect(span?.style.backgroundColor).toBe('var(--plugin-color, currentColor)');
|
|
166
|
+
});
|
|
167
|
+
|
|
168
|
+
test('no declared colour leaves both variables unset, so the hue applies', () => {
|
|
169
|
+
const span = paint(h(PluginMark, { name: 'Demo' })).querySelector('span');
|
|
170
|
+
|
|
171
|
+
expect(span?.style.getPropertyValue('--plugin-declared-light')).toBe('');
|
|
172
|
+
expect(span?.style.getPropertyValue('--plugin-declared-dark')).toBe('');
|
|
173
|
+
expect(span?.style.getPropertyValue('--icon-hue')).not.toBe('');
|
|
174
|
+
});
|
|
175
|
+
|
|
112
176
|
test('falls back to the plugin initials when no icon is declared', () => {
|
|
113
177
|
const el = paint(h(PluginMark, { name: 'Session Info', size: 16 }));
|
|
114
178
|
|
|
@@ -26,11 +26,13 @@
|
|
|
26
26
|
* `rgb(138,138,138)` in both the inactive and the active state, against a
|
|
27
27
|
* built-in's `text-ink/40` → `text-ink`.
|
|
28
28
|
*
|
|
29
|
-
* A mask has no document to inherit into, so the host supplies the paint
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
*
|
|
33
|
-
*
|
|
29
|
+
* A mask has no document to inherit into, so the host supplies the paint and the
|
|
30
|
+
* file supplies only its alpha channel. That paint is `var(--plugin-color,
|
|
31
|
+
* currentColor)`: monochrome resolves to the ink the mask always used, and
|
|
32
|
+
* `[data-icon-style="color"]` defines `--plugin-color` from a hue derived from
|
|
33
|
+
* the plugin's own name — so a marketplace mark gets its own colour without the
|
|
34
|
+
* host guessing one at build time, and without the component reading the mode
|
|
35
|
+
* from JavaScript.
|
|
34
36
|
*
|
|
35
37
|
* A RASTER mark keeps the `<img>`. Masking a PNG or a JPEG would throw away its
|
|
36
38
|
* colour — a brand logo the plugin chose to ship — and a JPEG has no alpha to
|
|
@@ -38,17 +40,45 @@
|
|
|
38
40
|
*/
|
|
39
41
|
|
|
40
42
|
import { providerInitials } from '@/shared/lib/models/provider/glyph';
|
|
43
|
+
import { hashHue, iconTone } from '@/shared/lib/icons/tint';
|
|
44
|
+
import { legiblePair } from '@/shared/lib/theme/legibility';
|
|
41
45
|
|
|
42
46
|
interface PluginMarkProps {
|
|
43
47
|
name: string;
|
|
44
48
|
/** The registry's content-addressed icon URL, when the plugin declares one. */
|
|
45
49
|
iconUrl?: string;
|
|
50
|
+
/**
|
|
51
|
+
* The mark colour the plugin's manifest declares (`color`), when it does.
|
|
52
|
+
*
|
|
53
|
+
* Set as a custom property pair (`--plugin-declared-light`/`-dark`), not as a
|
|
54
|
+
* colour, so the STYLE still decides whether it is used: `monochrome` leaves
|
|
55
|
+
* the mark in the palette ink, and the declared brand colour only appears under
|
|
56
|
+
* `[data-icon-style="color"]`. Two values because a brand hex is legible on one
|
|
57
|
+
* variant and not the other; `legiblePair` derives both.
|
|
58
|
+
*/
|
|
59
|
+
color?: string;
|
|
46
60
|
size?: number;
|
|
47
61
|
/** Filled background behind the fallback, for a card that wants a tile. */
|
|
48
62
|
tile?: boolean;
|
|
49
63
|
}
|
|
50
64
|
|
|
51
|
-
export function PluginMark({ name, iconUrl, size = 16, tile = false }: PluginMarkProps) {
|
|
65
|
+
export function PluginMark({ name, iconUrl, color, size = 16, tile = false }: PluginMarkProps) {
|
|
66
|
+
// The mark's own colour, on the same wheel as every functional glyph. Set as a
|
|
67
|
+
// custom property rather than a colour so the STYLE decides whether it is used:
|
|
68
|
+
// monochrome leaves `--plugin-color` undefined and the mark keeps the ink.
|
|
69
|
+
// A declared brand colour is clamped the way every other brand mark is
|
|
70
|
+
// (`legiblePair`): a bright hex like `#34d399` is 1.9:1 on white paper, so the
|
|
71
|
+
// light and dark values are derived instead of trusted.
|
|
72
|
+
const declared = color ? legiblePair(color) : null;
|
|
73
|
+
const hueValue = hashHue(name);
|
|
74
|
+
const hue = {
|
|
75
|
+
'--icon-hue': String(hueValue),
|
|
76
|
+
// The LIGHT tone for that hue, from the same solved table the glyph rows
|
|
77
|
+
// emit: a plugin's hue is runtime-only, so it cannot be a generated CSS row.
|
|
78
|
+
'--icon-tone': iconTone(hueValue),
|
|
79
|
+
...(declared ? { '--plugin-declared-light': declared.light } : {}),
|
|
80
|
+
...(declared?.dark ? { '--plugin-declared-dark': declared.dark } : {}),
|
|
81
|
+
} as Record<string, string>;
|
|
52
82
|
if (iconUrl) {
|
|
53
83
|
// The QUERY is stripped before the extension is read: the registry's URL is
|
|
54
84
|
// `/api/panels/icon/<plugin>/<path>?v=<hash>`, so the extension is on the
|
|
@@ -59,13 +89,15 @@ export function PluginMark({ name, iconUrl, size = 16, tile = false }: PluginMar
|
|
|
59
89
|
return (
|
|
60
90
|
<span
|
|
61
91
|
aria-hidden="true"
|
|
92
|
+
data-plugin-mark=""
|
|
62
93
|
className="inline-block flex-shrink-0"
|
|
63
94
|
style={{
|
|
95
|
+
...hue,
|
|
64
96
|
width: size,
|
|
65
97
|
height: size,
|
|
66
|
-
// The ink the mask is cut out of
|
|
67
|
-
//
|
|
68
|
-
backgroundColor: 'currentColor',
|
|
98
|
+
// The ink the mask is cut out of — or the plugin's own colour, which
|
|
99
|
+
// `[data-icon-style="color"]` supplies through `--plugin-color`.
|
|
100
|
+
backgroundColor: 'var(--plugin-color, currentColor)',
|
|
69
101
|
maskImage: `url("${iconUrl}")`,
|
|
70
102
|
maskSize: 'contain',
|
|
71
103
|
maskRepeat: 'no-repeat',
|
|
@@ -98,10 +130,15 @@ export function PluginMark({ name, iconUrl, size = 16, tile = false }: PluginMar
|
|
|
98
130
|
return (
|
|
99
131
|
<span
|
|
100
132
|
aria-hidden="true"
|
|
101
|
-
|
|
133
|
+
data-plugin-mark=""
|
|
134
|
+
className={`inline-flex flex-shrink-0 items-center justify-center font-semibold lowercase leading-none ${
|
|
102
135
|
tile ? 'rounded bg-ink/5' : ''
|
|
103
136
|
}`}
|
|
104
137
|
style={{
|
|
138
|
+
...hue,
|
|
139
|
+
// 45% of the palette ink is what `text-ink/45` meant; stated as a value
|
|
140
|
+
// so the colour mode can replace it without a second class.
|
|
141
|
+
color: 'var(--plugin-color, color-mix(in srgb, var(--theme-ink) 45%, transparent))',
|
|
105
142
|
height: size,
|
|
106
143
|
minWidth: size,
|
|
107
144
|
paddingInline: Math.max(1, Math.round(size * 0.12)),
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { AlertTriangle, Trash2, X } from 'lucide-preact';
|
|
2
2
|
import type { PanelPluginError } from '@/shared/types';
|
|
3
|
+
import { countPluginUpdates } from '@/shared/lib/panels/update';
|
|
3
4
|
import {
|
|
4
5
|
refreshPanelRegistry,
|
|
5
6
|
usePanelPluginActions,
|
|
@@ -99,6 +100,9 @@ export function PanelPluginsSection() {
|
|
|
99
100
|
const iconUrls = new Map(panels.map((panel) => [panel.pluginId, panel.iconUrl]));
|
|
100
101
|
const readmeUrls = new Map(panels.map((panel) => [panel.pluginId, panel.readmeUrl]));
|
|
101
102
|
const gitCount = plugins.filter((plugin) => plugin.gitOrigin).length;
|
|
103
|
+
// The same predicate the cards use — one answer for the count, the buttons
|
|
104
|
+
// and the Installed header, so they cannot disagree about what is waiting.
|
|
105
|
+
const updateCount = countPluginUpdates(plugins, gitStatus);
|
|
102
106
|
|
|
103
107
|
return (
|
|
104
108
|
<div className="space-y-4">
|
|
@@ -115,8 +119,10 @@ export function PanelPluginsSection() {
|
|
|
115
119
|
autoUpdate={autoUpdate}
|
|
116
120
|
busy={actions.busy}
|
|
117
121
|
gitCount={gitCount}
|
|
122
|
+
updateCount={updateCount}
|
|
118
123
|
onSetAutoUpdate={actions.setAutoUpdate}
|
|
119
124
|
onCheckUpdates={actions.checkUpdates}
|
|
125
|
+
onUpdateAll={actions.updateAll}
|
|
120
126
|
onRefresh={refresh}
|
|
121
127
|
/>
|
|
122
128
|
|
|
@@ -183,7 +189,7 @@ export function PanelPluginsSection() {
|
|
|
183
189
|
onRemove={actions.remove}
|
|
184
190
|
onSetEnabled={actions.setEnabled}
|
|
185
191
|
gitStatus={gitStatus}
|
|
186
|
-
|
|
192
|
+
onUpdate={actions.update}
|
|
187
193
|
/>
|
|
188
194
|
) : null}
|
|
189
195
|
|
|
@@ -16,20 +16,33 @@
|
|
|
16
16
|
* a write. It is the latter, and the sentence says so.
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
|
-
import { CheckSquare, RefreshCw, Square } from 'lucide-preact';
|
|
19
|
+
import { ArrowDownToLine, CheckSquare, Loader2, RefreshCw, Square } from 'lucide-preact';
|
|
20
20
|
|
|
21
21
|
interface PluginToolbarProps {
|
|
22
22
|
autoUpdate: boolean;
|
|
23
23
|
busy: string | null;
|
|
24
24
|
/** How many installed plugins are git clones — the check's own subject. */
|
|
25
25
|
gitCount: number;
|
|
26
|
+
/** How many installed plugins have an update waiting, from any source. */
|
|
27
|
+
updateCount: number;
|
|
26
28
|
onSetAutoUpdate: (enabled: boolean) => Promise<boolean>;
|
|
27
29
|
onCheckUpdates: () => Promise<boolean>;
|
|
30
|
+
onUpdateAll: () => Promise<boolean>;
|
|
28
31
|
onRefresh: () => void;
|
|
29
32
|
}
|
|
30
33
|
|
|
31
|
-
export function PluginToolbar({
|
|
34
|
+
export function PluginToolbar({
|
|
35
|
+
autoUpdate,
|
|
36
|
+
busy,
|
|
37
|
+
gitCount,
|
|
38
|
+
updateCount,
|
|
39
|
+
onSetAutoUpdate,
|
|
40
|
+
onCheckUpdates,
|
|
41
|
+
onUpdateAll,
|
|
42
|
+
onRefresh,
|
|
43
|
+
}: PluginToolbarProps) {
|
|
32
44
|
const checking = busy === 'check_updates';
|
|
45
|
+
const updatingAll = busy === 'update_all';
|
|
33
46
|
return (
|
|
34
47
|
<div className="flex flex-wrap items-center gap-2">
|
|
35
48
|
<button
|
|
@@ -64,6 +77,25 @@ export function PluginToolbar({ autoUpdate, busy, gitCount, onSetAutoUpdate, onC
|
|
|
64
77
|
Check for updates
|
|
65
78
|
</button>
|
|
66
79
|
|
|
80
|
+
{/* The count is on the button because it is the button's subject: one
|
|
81
|
+
action for every waiting update, whatever the plugin's source. A
|
|
82
|
+
plugin whose files were edited is refused and reported, never
|
|
83
|
+
overwritten — that is what the blocked notice exists for. */}
|
|
84
|
+
<button
|
|
85
|
+
type="button"
|
|
86
|
+
onClick={() => void onUpdateAll()}
|
|
87
|
+
disabled={busy !== null || updateCount === 0}
|
|
88
|
+
title={
|
|
89
|
+
updateCount === 0
|
|
90
|
+
? 'No updates to apply — press Check for updates to ask the git plugins\u2019 remotes'
|
|
91
|
+
: `Apply ${updateCount} update${updateCount === 1 ? '' : 's'} — a plugin with local edits is refused and reported, never overwritten`
|
|
92
|
+
}
|
|
93
|
+
className="flex items-center gap-1.5 px-2.5 py-1.5 text-xs rounded border border-warning/50 text-warning hover:bg-warning/10 disabled:opacity-50"
|
|
94
|
+
>
|
|
95
|
+
{updatingAll ? <Loader2 size={13} className="animate-spin" /> : <ArrowDownToLine size={13} />}
|
|
96
|
+
Update all{updateCount > 0 ? ` (${updateCount})` : ''}
|
|
97
|
+
</button>
|
|
98
|
+
|
|
67
99
|
<button
|
|
68
100
|
type="button"
|
|
69
101
|
onClick={onRefresh}
|
|
@@ -83,3 +115,4 @@ export function PluginToolbar({ autoUpdate, busy, gitCount, onSetAutoUpdate, onC
|
|
|
83
115
|
</div>
|
|
84
116
|
);
|
|
85
117
|
}
|
|
118
|
+
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { CHECKBOX_CLASS } from '@/client/components/common/checkbox/style';
|
|
1
2
|
import { useEffect, useState } from 'preact/hooks';
|
|
2
3
|
import { ExternalLink, RotateCcw, Trash2 } from 'lucide-preact';
|
|
3
4
|
import type { PluginFeatureSpec, PluginItem } from '@/shared/types';
|
|
@@ -268,7 +269,7 @@ function FeaturesSection({
|
|
|
268
269
|
: prev.filter((name) => name !== feature.name),
|
|
269
270
|
)
|
|
270
271
|
}
|
|
271
|
-
className=
|
|
272
|
+
className={`${CHECKBOX_CLASS} mt-0.5 accent-ink cursor-pointer disabled:opacity-60`}
|
|
272
273
|
/>
|
|
273
274
|
<span className="min-w-0">
|
|
274
275
|
<span className="text-xs font-medium text-ink font-mono">{feature.name}</span>
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { CHECKBOX_CLASS } from '@/client/components/common/checkbox/style';
|
|
1
2
|
import { useEffect, useState } from 'preact/hooks';
|
|
2
3
|
import { Check, ChevronDown, ChevronRight, KeyRound } from 'lucide-preact';
|
|
3
4
|
import type { PluginItem, PluginSettingSpec } from '@/shared/types';
|
|
@@ -172,7 +173,7 @@ function SettingInput({
|
|
|
172
173
|
checked={value === 'true'}
|
|
173
174
|
disabled={disabled}
|
|
174
175
|
onChange={(event) => onChange(event.currentTarget.checked ? 'true' : 'false')}
|
|
175
|
-
className=
|
|
176
|
+
className={`${CHECKBOX_CLASS} accent-ink cursor-pointer`}
|
|
176
177
|
/>
|
|
177
178
|
<span className="text-[11px] text-ink/70">{value === 'true' ? 'true' : 'false'}</span>
|
|
178
179
|
</label>
|
|
@@ -95,7 +95,7 @@ export function ProjectModelDropdown({
|
|
|
95
95
|
</button>
|
|
96
96
|
|
|
97
97
|
{isOpen && (
|
|
98
|
-
<div className="absolute right-0 mt-1 w-[288px] bg-paper border border-ink/15 rounded-lg shadow-xl z-50 overflow-hidden">
|
|
98
|
+
<div className="glass-popover absolute right-0 mt-1 w-[288px] bg-paper border border-ink/15 rounded-lg shadow-xl z-50 overflow-hidden">
|
|
99
99
|
<div className="flex items-center gap-1.5 px-2.5 py-2 border-b border-ink/10">
|
|
100
100
|
<Search size={12} className="text-ink/40 shrink-0" />
|
|
101
101
|
<input
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
* the next create uses — including one started by a scheduled task.
|
|
19
19
|
*/
|
|
20
20
|
|
|
21
|
+
import { CHECKBOX_CLASS } from '@/client/components/common/checkbox/style';
|
|
21
22
|
import { useState } from 'preact/hooks';
|
|
22
23
|
import { readKabmoSetting, writeSetting } from '@/shared/lib/settings/client';
|
|
23
24
|
import { useWorktrees } from '@/client/hooks/workspace/worktree/index';
|
|
@@ -131,7 +132,7 @@ export function WorktreeSettings({ root, folderId, onReport }: WorktreeSettingsP
|
|
|
131
132
|
setCarry(next);
|
|
132
133
|
writeSetting(WORKTREE_CARRY_SETTING, next);
|
|
133
134
|
}}
|
|
134
|
-
className=
|
|
135
|
+
className={`${CHECKBOX_CLASS} mt-0.5`}
|
|
135
136
|
/>
|
|
136
137
|
<span className="flex flex-col gap-0.5">
|
|
137
138
|
<span className="text-xs font-semibold text-ink">Copy ignored files into new worktrees</span>
|
|
@@ -56,14 +56,14 @@ export function DeleteProviderModal({
|
|
|
56
56
|
|
|
57
57
|
return (
|
|
58
58
|
<div
|
|
59
|
-
className="fixed inset-0 z-[70] flex items-center justify-center
|
|
59
|
+
className="fixed inset-0 z-[70] flex items-center justify-center modal-scrim backdrop-blur-[2px] p-4"
|
|
60
60
|
onClick={isDeleting ? undefined : onClose}
|
|
61
61
|
role="dialog"
|
|
62
62
|
aria-modal="true"
|
|
63
63
|
aria-label="Confirm provider deletion"
|
|
64
64
|
>
|
|
65
65
|
<div
|
|
66
|
-
className="bg-paper border border-ink/20 rounded-xl shadow-2xl w-[min(94vw,460px)] max-h-full overflow-y-auto scrollbar-overlay-container text-ink"
|
|
66
|
+
className="glass-overlay bg-paper border border-ink/20 rounded-xl shadow-2xl w-[min(94vw,460px)] max-h-full overflow-y-auto scrollbar-overlay-container text-ink"
|
|
67
67
|
onClick={(e) => e.stopPropagation()}
|
|
68
68
|
>
|
|
69
69
|
<div className="flex items-center gap-3 px-5 py-4 border-b border-ink/10">
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { CHECKBOX_CLASS } from '@/client/components/common/checkbox/style';
|
|
1
2
|
import { Plus, X } from 'lucide-preact';
|
|
2
3
|
import { PROVIDER_DISCOVERY_TYPES } from '@/shared/lib/models/provider/dialect';
|
|
3
4
|
import type { ProviderDiscoveryType } from '@/shared/types/settings/provider';
|
|
@@ -95,7 +96,7 @@ export function EntryAdvanced({
|
|
|
95
96
|
type="checkbox"
|
|
96
97
|
checked={discovery.injectV1 === true}
|
|
97
98
|
onChange={(e) => patch({ injectV1: e.currentTarget.checked })}
|
|
98
|
-
className=
|
|
99
|
+
className={`${CHECKBOX_CLASS} mt-0.5`}
|
|
99
100
|
/>
|
|
100
101
|
<span>
|
|
101
102
|
Skip the forced <span className="font-mono">/v1</span> prefix — for a gateway rooted at a
|
|
@@ -109,7 +110,7 @@ export function EntryAdvanced({
|
|
|
109
110
|
type="checkbox"
|
|
110
111
|
checked={discovery.advertisedReasoning === true}
|
|
111
112
|
onChange={(e) => patch({ advertisedReasoning: e.currentTarget.checked })}
|
|
112
|
-
className=
|
|
113
|
+
className={`${CHECKBOX_CLASS} mt-0.5`}
|
|
113
114
|
/>
|
|
114
115
|
<span>Trust the reasoning ladder the endpoint advertises in its model rows.</span>
|
|
115
116
|
</label>
|
|
@@ -79,14 +79,14 @@ export function LogoutProviderModal({ isOpen, provider, onClose, onSignedOut }:
|
|
|
79
79
|
|
|
80
80
|
return (
|
|
81
81
|
<div
|
|
82
|
-
className="fixed inset-0 z-[70] flex items-center justify-center
|
|
82
|
+
className="fixed inset-0 z-[70] flex items-center justify-center modal-scrim backdrop-blur-[2px] p-4"
|
|
83
83
|
onClick={busyId !== null ? undefined : onClose}
|
|
84
84
|
role="dialog"
|
|
85
85
|
aria-modal="true"
|
|
86
86
|
aria-label="Confirm sign out"
|
|
87
87
|
>
|
|
88
88
|
<div
|
|
89
|
-
className="bg-paper border border-ink/20 rounded-xl shadow-2xl w-[min(94vw,480px)] max-h-full overflow-y-auto scrollbar-overlay-container text-ink"
|
|
89
|
+
className="glass-overlay bg-paper border border-ink/20 rounded-xl shadow-2xl w-[min(94vw,480px)] max-h-full overflow-y-auto scrollbar-overlay-container text-ink"
|
|
90
90
|
onClick={(e) => e.stopPropagation()}
|
|
91
91
|
>
|
|
92
92
|
<div className="flex items-center gap-3 px-5 py-4 border-b border-ink/10">
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { CHECKBOX_CLASS } from '@/client/components/common/checkbox/style';
|
|
1
2
|
import { useEffect, useState } from 'preact/hooks';
|
|
2
3
|
import type { ComponentChildren } from 'preact';
|
|
3
4
|
import { AlertCircle, Check, GitBranch, Loader2, Search } from 'lucide-preact';
|
|
@@ -123,7 +124,7 @@ export function GitImportPanel({ controller, onInstalled }: GitImportPanelProps)
|
|
|
123
124
|
checked={isSelected}
|
|
124
125
|
disabled={Boolean(blocked)}
|
|
125
126
|
onChange={() => controller.toggle(skill.path)}
|
|
126
|
-
className=
|
|
127
|
+
className={`${CHECKBOX_CLASS} mt-0.5 accent-ink cursor-pointer disabled:cursor-not-allowed`}
|
|
127
128
|
/>
|
|
128
129
|
<div className="min-w-0 flex-1">
|
|
129
130
|
<div className="flex items-center gap-2 min-w-0">
|
|
@@ -190,7 +191,7 @@ export function GitImportPanel({ controller, onInstalled }: GitImportPanelProps)
|
|
|
190
191
|
type="checkbox"
|
|
191
192
|
checked={overwrite}
|
|
192
193
|
onChange={(event) => controller.setOverwrite(event.currentTarget.checked)}
|
|
193
|
-
className=
|
|
194
|
+
className={`${CHECKBOX_CLASS} mt-0.5 accent-ink cursor-pointer`}
|
|
194
195
|
/>
|
|
195
196
|
<span className="text-[11px] text-ink/70 leading-relaxed">
|
|
196
197
|
Replace skills that already have the same name
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { CHECKBOX_CLASS } from '@/client/components/common/checkbox/style';
|
|
1
2
|
import type { ComponentChildren } from 'preact';
|
|
2
3
|
import { AlertCircle, Check, Eye, EyeOff, Loader2, Lock, RefreshCw, Save, Sparkles, Trash2 } from 'lucide-preact';
|
|
3
4
|
import type { SkillItem } from '@/shared/types';
|
|
@@ -147,7 +148,7 @@ export function SkillDetailHeader({
|
|
|
147
148
|
checked={hidden}
|
|
148
149
|
disabled={readOnly}
|
|
149
150
|
onChange={(event) => onHiddenChange(event.currentTarget.checked)}
|
|
150
|
-
className=
|
|
151
|
+
className={`${CHECKBOX_CLASS} mt-0.5 accent-ink cursor-pointer disabled:cursor-not-allowed`}
|
|
151
152
|
/>
|
|
152
153
|
<span className="text-[11px] text-ink/75 leading-relaxed">
|
|
153
154
|
<span className="inline-flex items-center gap-1">
|
|
@@ -75,7 +75,7 @@ export function TokenUsageControls({
|
|
|
75
75
|
// `right-0` menu hung off its right edge landed at x=-157. From
|
|
76
76
|
// `sm` up the trigger is narrow and right-aligned, so the menu
|
|
77
77
|
// follows it.
|
|
78
|
-
<div className="absolute left-0 top-full z-30 mt-1 w-64 max-w-[calc(100vw-2rem)] divide-y divide-ink/5 rounded-md border border-ink/15 bg-paper py-1 text-[11px] shadow-lg sm:left-auto sm:right-0">
|
|
78
|
+
<div className="glass-popover absolute left-0 top-full z-30 mt-1 w-64 max-w-[calc(100vw-2rem)] divide-y divide-ink/5 rounded-md border border-ink/15 bg-paper py-1 text-[11px] shadow-lg sm:left-auto sm:right-0">
|
|
79
79
|
{ranges.map((entry) => (
|
|
80
80
|
<button
|
|
81
81
|
key={entry.id}
|
|
@@ -59,7 +59,7 @@ export function BtwTopicMenu({ topics, activeTopicId, onSelectTopic, onDeleteTop
|
|
|
59
59
|
ref={menuRef}
|
|
60
60
|
role="menu"
|
|
61
61
|
aria-label="Side question history"
|
|
62
|
-
className="absolute left-0 top-full mt-1 z-50 bg-paper border border-ink/15 rounded-lg shadow-xl min-w-[280px] max-h-72 overflow-y-auto scrollbar-overlay-container p-1"
|
|
62
|
+
className="glass-popover absolute left-0 top-full mt-1 z-50 bg-paper border border-ink/15 rounded-lg shadow-xl min-w-[280px] max-h-72 overflow-y-auto scrollbar-overlay-container p-1"
|
|
63
63
|
>
|
|
64
64
|
{topics.length === 0 && (
|
|
65
65
|
<div className="px-2.5 py-2 text-[12px] text-ink/50">No side questions yet.</div>
|
|
@@ -149,12 +149,12 @@ export function AiMessageFooter({
|
|
|
149
149
|
|
|
150
150
|
{isMenuOpen && (
|
|
151
151
|
<div
|
|
152
|
-
className="fixed inset-0 z-[70] flex items-end
|
|
152
|
+
className="fixed inset-0 z-[70] flex items-end modal-scrim backdrop-blur-[1px] animate-in fade-in duration-150"
|
|
153
153
|
role="presentation"
|
|
154
154
|
onClick={() => setIsMenuOpen(false)}
|
|
155
155
|
>
|
|
156
156
|
<div
|
|
157
|
-
className="w-full max-h-[80vh] overflow-y-auto rounded-t-2xl border border-ink/15 bg-paper pb-[max(0.75rem,env(safe-area-inset-bottom,0px))] shadow-2xl animate-in slide-in-from-bottom-4 duration-200"
|
|
157
|
+
className="glass-overlay w-full max-h-[80vh] overflow-y-auto rounded-t-2xl border border-ink/15 bg-paper pb-[max(0.75rem,env(safe-area-inset-bottom,0px))] shadow-2xl animate-in slide-in-from-bottom-4 duration-200"
|
|
158
158
|
role="dialog"
|
|
159
159
|
aria-modal="true"
|
|
160
160
|
aria-labelledby={`message-actions-${msgId}`}
|
|
@@ -69,13 +69,13 @@ export function NewChatModal({
|
|
|
69
69
|
};
|
|
70
70
|
|
|
71
71
|
return (
|
|
72
|
-
<div className="fixed inset-0 z-50 flex items-center justify-center
|
|
72
|
+
<div className="fixed inset-0 z-50 flex items-center justify-center modal-scrim animate-in fade-in duration-200 p-4">
|
|
73
73
|
<div
|
|
74
|
-
className="bg-canvas border border-ink/15 rounded-xl shadow-xl w-full flex flex-col overflow-hidden"
|
|
74
|
+
className="glass-overlay bg-canvas border border-ink/15 rounded-xl shadow-xl w-full flex flex-col overflow-hidden"
|
|
75
75
|
style={maximized ? MODAL_EXPANDED_STYLE : MODAL_DEFAULT_STYLE}
|
|
76
76
|
onClick={(e) => e.stopPropagation()}
|
|
77
77
|
>
|
|
78
|
-
<div className="flex items-center justify-between px-4 py-3 border-b border-ink/10
|
|
78
|
+
<div className="flex items-center justify-between px-4 py-3 border-b border-ink/10">
|
|
79
79
|
<h2 className="text-[13px] font-semibold text-ink">New Chat</h2>
|
|
80
80
|
<div className="flex items-center gap-0.5">
|
|
81
81
|
<button
|
|
@@ -35,14 +35,14 @@ export function UndoConfirmModal({ content, isOmpSession, undoing, error, onClos
|
|
|
35
35
|
|
|
36
36
|
return (
|
|
37
37
|
<div
|
|
38
|
-
className="fixed inset-0 z-50 flex items-center justify-center
|
|
38
|
+
className="fixed inset-0 z-50 flex items-center justify-center modal-scrim animate-in fade-in duration-200 p-4"
|
|
39
39
|
onClick={undoing ? undefined : onClose}
|
|
40
40
|
role="dialog"
|
|
41
41
|
aria-modal="true"
|
|
42
42
|
aria-label="Confirm undo"
|
|
43
43
|
>
|
|
44
44
|
<div
|
|
45
|
-
className="bg-paper border border-ink/20 rounded-xl shadow-xl w-[min(94vw,420px)] overflow-hidden"
|
|
45
|
+
className="glass-overlay bg-paper border border-ink/20 rounded-xl shadow-xl w-[min(94vw,420px)] overflow-hidden"
|
|
46
46
|
onClick={(e) => e.stopPropagation()}
|
|
47
47
|
>
|
|
48
48
|
<div className="flex items-center gap-3 px-4 py-3 border-b border-ink/10">
|
|
@@ -32,7 +32,7 @@ export function AccessDropdown({ value, onSelect }: AccessDropdownProps) {
|
|
|
32
32
|
<span className="hidden lg:inline">{ACCESS_LEVEL_LABELS[value]}</span>
|
|
33
33
|
</button>
|
|
34
34
|
{showAccess && (
|
|
35
|
-
<div className="absolute bottom-full left-0 mb-1 w-40 bg-paper border border-ink/20 rounded-md shadow-lg z-50 py-1 text-xs">
|
|
35
|
+
<div className="glass-popover absolute bottom-full left-0 mb-1 w-40 bg-paper border border-ink/20 rounded-md shadow-lg z-50 py-1 text-xs">
|
|
36
36
|
<div className="px-3 py-1 text-[10px] uppercase tracking-wider text-ink/40 font-semibold mb-1">Access Control</div>
|
|
37
37
|
{APPROVAL_MODES.map(mode => (
|
|
38
38
|
<button
|
|
@@ -21,6 +21,7 @@
|
|
|
21
21
|
* accepts the same vocabulary.
|
|
22
22
|
*/
|
|
23
23
|
|
|
24
|
+
import { CHECKBOX_CLASS } from '@/client/components/common/checkbox/style';
|
|
24
25
|
import { useEffect, useRef, useState } from 'preact/hooks';
|
|
25
26
|
import type { ComponentChildren } from 'preact';
|
|
26
27
|
import { Target, X } from 'lucide-preact';
|
|
@@ -121,9 +122,9 @@ export function GoalModal({ open, goal, goalRecord, pending, defaultBudget = nul
|
|
|
121
122
|
};
|
|
122
123
|
|
|
123
124
|
return (
|
|
124
|
-
<div className="fixed inset-0 z-[60] flex items-center justify-center
|
|
125
|
+
<div className="fixed inset-0 z-[60] flex items-center justify-center modal-scrim p-4" onClick={onClose}>
|
|
125
126
|
<div
|
|
126
|
-
className="w-full max-w-lg overflow-hidden rounded-xl border border-ink/15 bg-paper shadow-xl"
|
|
127
|
+
className="glass-overlay w-full max-w-lg overflow-hidden rounded-xl border border-ink/15 bg-paper shadow-xl"
|
|
127
128
|
onClick={(event) => event.stopPropagation()}
|
|
128
129
|
>
|
|
129
130
|
<div className="flex items-center justify-between border-b border-ink/10 px-4 py-3">
|
|
@@ -258,7 +259,7 @@ export function GoalModal({ open, goal, goalRecord, pending, defaultBudget = nul
|
|
|
258
259
|
type="checkbox"
|
|
259
260
|
checked={guided}
|
|
260
261
|
onChange={(event) => setGuided(event.currentTarget.checked)}
|
|
261
|
-
className=
|
|
262
|
+
className={`${CHECKBOX_CLASS} mt-0.5`}
|
|
262
263
|
/>
|
|
263
264
|
<span>
|
|
264
265
|
Let the agent interview me first — it asks one question per turn, then writes the objective itself.
|
|
@@ -30,7 +30,7 @@ export function ThinkingLevelDropdown({ thinkingLevels, currentThinking, onSelec
|
|
|
30
30
|
<span className="hidden lg:inline">{currentThinking}</span>
|
|
31
31
|
</button>
|
|
32
32
|
{showThinking && thinkingLevels.length > 0 && (
|
|
33
|
-
<div className="absolute bottom-full left-0 mb-1 w-40 bg-paper border border-ink/20 rounded-md shadow-lg z-50 py-1 text-xs">
|
|
33
|
+
<div className="glass-popover absolute bottom-full left-0 mb-1 w-40 bg-paper border border-ink/20 rounded-md shadow-lg z-50 py-1 text-xs">
|
|
34
34
|
<div className="px-3 py-1 text-[10px] uppercase tracking-wider text-ink/40 font-semibold mb-1">Thinking Level</div>
|
|
35
35
|
{thinkingLevels.map(level => (
|
|
36
36
|
<button
|
package/src/client/components/workspace/chat-timeline/chat-input/WaitingDependencyPicker.tsx
CHANGED
|
@@ -127,7 +127,7 @@ export function WaitingDependencyPicker({
|
|
|
127
127
|
</button>
|
|
128
128
|
|
|
129
129
|
{open && (
|
|
130
|
-
<div className="absolute bottom-full left-0 mb-1.5 w-72 bg-paper border border-ink/10 rounded-lg shadow-lg z-50 flex flex-col overflow-hidden text-xs py-1">
|
|
130
|
+
<div className="glass-popover absolute bottom-full left-0 mb-1.5 w-72 bg-paper border border-ink/10 rounded-lg shadow-lg z-50 flex flex-col overflow-hidden text-xs py-1">
|
|
131
131
|
<div className="flex items-center justify-between px-3 py-1.5 border-b border-ink/5">
|
|
132
132
|
<span className="text-[10px] uppercase tracking-wider text-ink/40 font-semibold">Wait for session</span>
|
|
133
133
|
{value && (
|
|
@@ -67,8 +67,8 @@ export function PlanReviewPanel({ proposal, deciding, error, onDecide, onDismiss
|
|
|
67
67
|
.join('\n\n');
|
|
68
68
|
|
|
69
69
|
return (
|
|
70
|
-
<div className="fixed inset-0 z-[70] flex items-center justify-center
|
|
71
|
-
<div className="flex h-[88vh] w-full max-w-5xl flex-col overflow-hidden rounded-xl border border-ink/15 bg-paper shadow-2xl">
|
|
70
|
+
<div className="fixed inset-0 z-[70] flex items-center justify-center modal-scrim p-4">
|
|
71
|
+
<div className="glass-overlay flex h-[88vh] w-full max-w-5xl flex-col overflow-hidden rounded-xl border border-ink/15 bg-paper shadow-2xl">
|
|
72
72
|
<div className="flex items-center justify-between border-b border-ink/10 px-4 py-3">
|
|
73
73
|
<div className="flex min-w-0 items-center gap-2">
|
|
74
74
|
<FileText size={15} className="shrink-0 text-ink/60" />
|
|
@@ -81,7 +81,7 @@ export function WorkspacePicker({
|
|
|
81
81
|
{open && (
|
|
82
82
|
<div
|
|
83
83
|
role="menu"
|
|
84
|
-
className="absolute bottom-full left-0 mb-1.5 w-64 bg-paper border border-ink/10 rounded-lg shadow-lg z-50 flex flex-col overflow-hidden text-xs py-1"
|
|
84
|
+
className="glass-popover absolute bottom-full left-0 mb-1.5 w-64 bg-paper border border-ink/10 rounded-lg shadow-lg z-50 flex flex-col overflow-hidden text-xs py-1"
|
|
85
85
|
>
|
|
86
86
|
<div className="px-3 py-1.5 text-[10px] uppercase tracking-wider text-ink/40 font-semibold border-b border-ink/5">
|
|
87
87
|
Target Workspace
|
|
@@ -172,7 +172,7 @@ export function WorktreePicker({ folders, selectedFolderId, target, setTarget, o
|
|
|
172
172
|
{open && (
|
|
173
173
|
<div
|
|
174
174
|
role="menu"
|
|
175
|
-
className="absolute bottom-full left-0 mb-1.5 w-72 bg-paper border border-ink/10 rounded-lg shadow-lg z-50 flex flex-col overflow-hidden text-xs py-1"
|
|
175
|
+
className="glass-popover absolute bottom-full left-0 mb-1.5 w-72 bg-paper border border-ink/10 rounded-lg shadow-lg z-50 flex flex-col overflow-hidden text-xs py-1"
|
|
176
176
|
>
|
|
177
177
|
<div className="px-3 py-1.5 text-[10px] uppercase tracking-wider text-ink/40 font-semibold border-b border-ink/5">
|
|
178
178
|
Project root
|