@jini-ai/ui 0.7.3-next.2 → 0.7.3-next.3
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 +3 -3
- package/dist/browser/index.d.ts +2 -0
- package/dist/browser/index.js +2 -0
- package/dist/browser/mount-renderer.d.ts +33 -0
- package/dist/browser/mount-renderer.js +14 -0
- package/dist/browser/useDismissibleDropdown.d.ts +50 -0
- package/dist/browser/useDismissibleDropdown.js +49 -0
- package/dist/core.d.ts +4 -4
- package/dist/core.js +4 -1
- package/dist/features/admin-widgets/components/InfoTip.js +5 -5
- package/dist/features/admin-widgets/components/InfoTip.rules.d.ts +1 -1
- package/dist/features/admin-widgets/components/InfoTip.rules.js +1 -1
- package/dist/features/admin-widgets/components/SeeMore/SeeMore.js +3 -3
- package/dist/features/admin-widgets/components/Select/Select.js +7 -7
- package/dist/features/app-shell/SiteToast.d.ts +24 -0
- package/dist/features/app-shell/SiteToast.js +9 -0
- package/dist/features/app-shell/copyable-details.d.ts +12 -0
- package/dist/features/app-shell/copyable-details.js +17 -0
- package/dist/features/app-shell/expanded-mode.d.ts +76 -0
- package/dist/features/app-shell/expanded-mode.js +70 -0
- package/dist/features/app-shell/index.d.ts +8 -0
- package/dist/features/app-shell/index.js +8 -0
- package/dist/features/app-shell/use-delete-confirmation.hooks.d.ts +48 -0
- package/dist/features/app-shell/use-delete-confirmation.hooks.js +57 -0
- package/dist/features/app-shell/use-expanded-mode.hooks.d.ts +19 -0
- package/dist/features/app-shell/use-expanded-mode.hooks.js +39 -0
- package/dist/features/app-shell/use-site-toast.hooks.d.ts +56 -0
- package/dist/features/app-shell/use-site-toast.hooks.js +44 -0
- package/dist/features/app-shell/use-theme-preference.hooks.d.ts +30 -0
- package/dist/features/app-shell/use-theme-preference.hooks.js +42 -0
- package/dist/features/app-version/use-app-version.d.ts +53 -0
- package/dist/features/app-version/use-app-version.js +42 -0
- package/dist/features/asset-grid/react/components/AssetGrid.d.ts +1 -1
- package/dist/features/asset-grid/react/components/AssetGrid.js +1 -1
- package/dist/features/asset-grid/react/components/DeleteConfirmDialog.d.ts +1 -1
- package/dist/features/asset-grid/react/components/DeleteConfirmDialog.js +1 -1
- package/dist/features/asset-tree-browser/react/components/AssetTreeBrowser.d.ts +2 -2
- package/dist/features/asset-tree-browser/react/components/AssetTreeBrowser.js +1 -1
- package/dist/features/asset-tree-browser/react/components/FilePreviewPane.d.ts +1 -1
- package/dist/features/browser-chrome/react/components/BrowserViewportControls.d.ts +1 -1
- package/dist/features/browser-chrome/react/components/BrowserViewportControls.js +1 -1
- package/dist/features/charts/table.js +4 -4
- package/dist/features/command-palette/index.d.ts +1 -0
- package/dist/features/command-palette/index.js +1 -0
- package/dist/features/command-palette/react/components/CommandPalette.d.ts +9 -9
- package/dist/features/command-palette/react/components/CommandPalette.hooks.js +28 -1
- package/dist/features/command-palette/react/components/CommandPalette.js +3 -5
- package/dist/features/connectors/ConnectorsBrowser.d.ts +1 -1
- package/dist/features/connectors/ConnectorsBrowser.js +2 -2
- package/dist/features/connectors/components/ConnectorCard.hooks.js +2 -2
- package/dist/features/connectors/components/ConnectorCard.js +4 -4
- package/dist/features/connectors/components/ConnectorDetailDrawer.d.ts +1 -1
- package/dist/features/connectors/components/ConnectorDetailDrawer.js +7 -7
- package/dist/features/connectors/components/ConnectorGrid.js +1 -1
- package/dist/features/connectors/components/ConnectorLogo.js +1 -1
- package/dist/features/connectors/components/ConnectorSearchBar.js +1 -1
- package/dist/features/connectors/components/ProviderTabBar.js +1 -1
- package/dist/features/execution/claude/env-fields.d.ts +1 -1
- package/dist/features/execution/codex/env-fields.d.ts +1 -1
- package/dist/features/execution/constants.d.ts +2 -2
- package/dist/features/execution/constants.js +1 -1
- package/dist/features/execution/dependencies.d.ts +2 -3
- package/dist/features/execution/http-adapter.d.ts +2 -3
- package/dist/features/execution/index.d.ts +0 -2
- package/dist/features/execution/react/components/AgentCliEnvFields.d.ts +1 -1
- package/dist/features/execution/react/components/AgentDiagnosticRow.d.ts +1 -1
- package/dist/features/execution/react/components/AgentDiagnosticRow.js +3 -1
- package/dist/features/execution/react/components/ByokProviderForm.d.ts +10 -2
- package/dist/features/execution/react/components/ByokProviderForm.hooks.d.ts +2 -2
- package/dist/features/execution/react/components/ByokProviderForm.js +15 -4
- package/dist/features/execution/react/components/ExecutionTab.d.ts +2 -3
- package/dist/features/execution/react/components/ExecutionTab.hooks.d.ts +14 -4
- package/dist/features/execution/react/components/ExecutionTab.hooks.js +66 -9
- package/dist/features/execution/react/components/ExecutionTab.js +27 -10
- package/dist/features/execution/react/components/LocalCliAgentCard.d.ts +4 -4
- package/dist/features/execution/react/components/LocalCliAgentList.d.ts +4 -4
- package/dist/features/execution/react/components/LocalCliAgentList.hooks.d.ts +3 -3
- package/dist/features/execution/react/components/LocalCliAgentSettings.d.ts +2 -2
- package/dist/features/execution/react/components/ProviderChipGroup.d.ts +1 -1
- package/dist/features/execution/react/components/SearchableModelSelect.d.ts +1 -1
- package/dist/features/execution/react/hooks/use-byok-field-validation.hooks.d.ts +2 -2
- package/dist/features/execution/react/hooks/use-execution-credential.hooks.d.ts +1 -1
- package/dist/features/execution/react/hooks/useExecutionTab.d.ts +2 -3
- package/dist/features/execution/react/hooks/useLocalCliAgentCard.d.ts +4 -4
- package/dist/features/execution/react/hooks/useLocalCliAgentList.d.ts +4 -4
- package/dist/features/execution/react/hooks/useReasoningControl.d.ts +3 -3
- package/dist/features/execution/rules.d.ts +6 -6
- package/dist/features/execution/rules.js +1 -1
- package/dist/features/external-mcp/react/components/ExternalMcpTab.js +4 -4
- package/dist/features/file-dropzone/react/components/FileDropzone.d.ts +1 -1
- package/dist/features/file-dropzone/react/components/FileDropzone.js +1 -1
- package/dist/features/find/find-bar-state.d.ts +58 -0
- package/dist/features/find/find-bar-state.js +45 -0
- package/dist/features/find/find-focus-clock.d.ts +19 -0
- package/dist/features/find/find-focus-clock.js +9 -0
- package/dist/features/find/find-input-focus.d.ts +88 -0
- package/dist/features/find/find-input-focus.js +88 -0
- package/dist/features/find/find-target.d.ts +141 -0
- package/dist/features/find/find-target.js +160 -0
- package/dist/features/find/index.d.ts +10 -0
- package/dist/features/find/index.js +10 -0
- package/dist/features/find/use-find-bar-effects.hooks.d.ts +14 -0
- package/dist/features/find/use-find-bar-effects.hooks.js +92 -0
- package/dist/features/find/use-find-bar-state.hooks.d.ts +43 -0
- package/dist/features/find/use-find-bar-state.hooks.js +49 -0
- package/dist/features/find/use-find-focus-reclaim.hooks.d.ts +21 -0
- package/dist/features/find/use-find-focus-reclaim.hooks.js +64 -0
- package/dist/features/find/use-find-input-binding.hooks.d.ts +18 -0
- package/dist/features/find/use-find-input-binding.hooks.js +76 -0
- package/dist/features/find-bar/FindBar.d.ts +41 -0
- package/dist/features/find-bar/FindBar.js +31 -0
- package/dist/features/find-bar/index.d.ts +2 -0
- package/dist/features/find-bar/index.js +2 -0
- package/dist/features/folder-path-drop/index.d.ts +3 -1
- package/dist/features/folder-path-drop/index.js +1 -0
- package/dist/features/folder-path-drop/react/hooks/useClassifiedPathDrop.d.ts +50 -0
- package/dist/features/folder-path-drop/react/hooks/useClassifiedPathDrop.js +50 -0
- package/dist/features/folder-path-drop/types.d.ts +14 -0
- package/dist/features/i18n/context.d.ts +1 -1
- package/dist/features/i18n/context.js +1 -1
- package/dist/features/iframe-pool/react/dom-sync.d.ts +13 -3
- package/dist/features/iframe-pool/react/dom-sync.js +7 -7
- package/dist/features/import-handoff/use-import-handoff.d.ts +38 -0
- package/dist/features/import-handoff/use-import-handoff.js +40 -0
- package/dist/features/integrations/rules.js +39 -41
- package/dist/features/interactive-ui/interactive-ui.css +1 -1
- package/dist/features/interactive-ui/providers/native/data-table.js +1 -1
- package/dist/features/interactive-ui/providers/shadcn/checkbox-field.js +1 -1
- package/dist/features/interactive-ui/providers/shadcn/data-table.js +3 -3
- package/dist/features/interactive-ui/providers/shadcn/radio-group-field.js +1 -1
- package/dist/features/live-views/index.d.ts +6 -0
- package/dist/features/live-views/index.js +6 -0
- package/dist/features/live-views/use-live-views.d.ts +31 -0
- package/dist/features/live-views/use-live-views.js +88 -0
- package/dist/features/live-views/use-site-view-preference.d.ts +33 -0
- package/dist/features/live-views/use-site-view-preference.js +32 -0
- package/dist/features/live-views/use-webview-load-failure.d.ts +90 -0
- package/dist/features/live-views/use-webview-load-failure.js +122 -0
- package/dist/features/mcp-ui/credential-card.d.ts +1 -0
- package/dist/features/mcp-ui/credential-card.js +1 -1
- package/dist/features/mcp-ui/surfaces/tool-approval.d.ts +10 -0
- package/dist/features/mcp-ui/surfaces/tool-approval.js +15 -0
- package/dist/features/media-providers/dependencies.d.ts +7 -1
- package/dist/features/media-providers/dependencies.js +43 -0
- package/dist/features/media-providers/index.d.ts +2 -2
- package/dist/features/media-providers/index.js +1 -1
- package/dist/features/media-providers/ports.d.ts +39 -5
- package/dist/features/media-providers/react/components/MediaProvidersTab.d.ts +4 -3
- package/dist/features/media-providers/react/components/MediaProvidersTab.js +1 -1
- package/dist/features/media-providers/react/hooks/useMediaProvidersTab.d.ts +3 -2
- package/dist/features/media-providers/react/hooks/useMediaProvidersTab.js +41 -3
- package/dist/features/memory/react/components/MemoryConnectedPanel.js +2 -2
- package/dist/features/memory/react/components/MemoryEntryCard.js +1 -1
- package/dist/features/memory/react/components/MemoryHooksPanel.js +2 -2
- package/dist/features/memory/react/components/MemoryList.js +2 -2
- package/dist/features/memory/react/components/MemorySettingsPanel.js +2 -2
- package/dist/features/memory/react/components/MemorySuggestionPanel.js +1 -1
- package/dist/features/memory/react/hooks/useMemoryConnectors.hooks.js +3 -3
- package/dist/features/memory/react/hooks/useMemoryConnectors.rules.d.ts +4 -1
- package/dist/features/memory/react/hooks/useMemoryConnectors.rules.js +1 -1
- package/dist/features/memory/react/render-markdown.js +1 -1
- package/dist/features/nav-availability/nav-availability.d.ts +18 -0
- package/dist/features/nav-availability/nav-availability.js +12 -0
- package/dist/features/number-stepper/NumberStepper.d.ts +39 -0
- package/dist/features/number-stepper/NumberStepper.js +16 -0
- package/dist/features/number-stepper/index.d.ts +5 -0
- package/dist/features/number-stepper/index.js +5 -0
- package/dist/features/number-stepper/number-stepper.d.ts +34 -0
- package/dist/features/number-stepper/number-stepper.js +32 -0
- package/dist/features/number-stepper/use-number-stepper.hooks.d.ts +20 -0
- package/dist/features/number-stepper/use-number-stepper.hooks.js +29 -0
- package/dist/features/number-stepper/use-optimistic-number-setting.hooks.d.ts +36 -0
- package/dist/features/number-stepper/use-optimistic-number-setting.hooks.js +25 -0
- package/dist/features/panel-kit/ErrorNotice.js +8 -1
- package/dist/features/panel-kit/helpers/standing-draft-local-backup.d.ts +1 -1
- package/dist/features/panel-kit/helpers/standing-draft-recovery-message.d.ts +1 -1
- package/dist/features/panel-kit/hooks/use-standing-draft-autosave.hooks.d.ts +1 -37
- package/dist/features/panel-kit/hooks/use-standing-draft-recovery.hooks.d.ts +2 -1
- package/dist/features/panel-kit/hooks/use-standing-draft-state.hooks.d.ts +2 -1
- package/dist/features/panel-kit/hooks/use-standing-draft-writes.hooks.d.ts +2 -1
- package/dist/features/panel-kit/index.d.ts +2 -1
- package/dist/features/privacy/react/components/PrivacyTab.d.ts +1 -1
- package/dist/features/privacy/react/components/PrivacyTab.js +1 -1
- package/dist/features/progress-card/components/ProgressCard.d.ts +1 -1
- package/dist/features/progress-card/components/ProgressCard.js +1 -1
- package/dist/features/resource-dashboard/react/components/ResourceBoard.d.ts +1 -1
- package/dist/features/resource-dashboard/react/components/ResourceBoardToolbar.d.ts +1 -1
- package/dist/features/resource-dashboard/react/components/ResourceBoardToolbar.js +1 -1
- package/dist/features/resource-dashboard/react/components/ResourceCardParts.d.ts +1 -1
- package/dist/features/resource-dashboard/react/components/ResourceCardParts.js +7 -2
- package/dist/features/resource-dashboard/react/components/ResourceRowListView.d.ts +1 -1
- package/dist/features/resource-dashboard/react/components/ResourceRowListView.js +1 -1
- package/dist/features/resource-dashboard/react/components/ResourceRunHistoryList.d.ts +1 -1
- package/dist/features/resource-dashboard/react/components/ResourceRunHistoryList.js +1 -1
- package/dist/features/resource-dashboard/react/components/StatusPill.d.ts +1 -1
- package/dist/features/resource-dashboard/react/components/StatusPill.js +1 -1
- package/dist/features/resource-dashboard/react/hooks/useResourceBoard.js +6 -1
- package/dist/features/resource-monitor/ResourceTable.d.ts +67 -0
- package/dist/features/resource-monitor/ResourceTable.js +25 -0
- package/dist/features/resource-monitor/index.d.ts +4 -0
- package/dist/features/resource-monitor/index.js +4 -0
- package/dist/features/resource-monitor/resource-stop.d.ts +16 -0
- package/dist/features/resource-monitor/resource-stop.js +11 -0
- package/dist/features/resource-monitor/use-resource-readings.hooks.d.ts +44 -0
- package/dist/features/resource-monitor/use-resource-readings.hooks.js +91 -0
- package/dist/features/settings/dialog/styles/settings-dialog.css +251 -251
- package/dist/features/site-card/index.d.ts +4 -1
- package/dist/features/site-card/index.js +3 -0
- package/dist/features/site-card/use-created-site-return.hooks.d.ts +36 -0
- package/dist/features/site-card/use-created-site-return.hooks.js +43 -0
- package/dist/features/site-card/use-site-card-preview.hooks.d.ts +39 -0
- package/dist/features/site-card/use-site-card-preview.hooks.js +31 -0
- package/dist/features/site-card/use-site-list-prefs.hooks.d.ts +29 -8
- package/dist/features/site-card/use-site-list-prefs.hooks.js +56 -9
- package/dist/features/site-card/use-site-preview.hooks.d.ts +67 -0
- package/dist/features/site-card/use-site-preview.hooks.js +94 -0
- package/dist/features/sketch-editor/react/components/SketchEditor.d.ts +2 -2
- package/dist/features/sketch-editor/react/components/SketchEditor.js +1 -1
- package/dist/features/skills/react/components/SkillRow.js +1 -1
- package/dist/features/source-config-list/react/components/SourceConfigAddForm.js +2 -2
- package/dist/features/source-config-list/react/components/SourceConfigField.js +1 -1
- package/dist/features/source-config-list/react/components/SourceConfigItemCard.js +5 -5
- package/dist/features/source-config-list/react/components/SourceConfigList.d.ts +1 -1
- package/dist/features/source-config-list/react/components/SourceConfigList.js +1 -1
- package/dist/features/source-config-list/react/components/SourceConfigListView.js +3 -3
- package/dist/features/source-config-list/react/components/SourceConfigTestControl.d.ts +1 -1
- package/dist/features/source-config-list/react/components/SourceConfigTestControl.js +1 -1
- package/dist/features/tab-launcher-menu/react/components/TabLauncherMenu.d.ts +1 -1
- package/dist/features/tab-launcher-menu/react/components/TabLauncherMenu.js +1 -1
- package/dist/features/tab-strip/react/components/TabBar.js +2 -2
- package/dist/features/tab-strip/react/components/TabStrip.d.ts +1 -1
- package/dist/features/tab-strip/react/components/TabStrip.js +1 -1
- package/dist/features/tab-strip/scrollable.js +0 -2
- package/dist/features/tabbed-dialog/react/components/TabbedDialog.d.ts +1 -1
- package/dist/features/tabbed-dialog/react/components/TabbedDialog.js +1 -1
- package/dist/features/version-manager/react/components/VersionManagerModal.d.ts +1 -1
- package/dist/features/version-manager/react/components/VersionManagerModal.js +1 -1
- package/dist/features/viewer-shell/react/components/CommentSidePanel.d.ts +2 -2
- package/dist/features/viewer-shell/react/components/CommentSidePanel.js +1 -1
- package/dist/features/viewer-shell/react/components/MarkdownSplitPane.d.ts +1 -1
- package/dist/features/viewer-shell/react/components/MarkdownSplitPane.js +1 -1
- package/dist/features/viewer-shell/react/components/SegmentedToggle.d.ts +1 -1
- package/dist/features/viewer-shell/react/components/SegmentedToggle.js +1 -1
- package/dist/features/viewer-shell/react/components/ViewportSwitcher.d.ts +1 -1
- package/dist/features/viewer-shell/react/components/ViewportSwitcher.js +1 -1
- package/dist/features/viewer-shell/react/components/ViewportToggleGroup.d.ts +1 -1
- package/dist/features/viewer-shell/react/components/ViewportToggleGroup.js +1 -1
- package/dist/features/zoom/use-zoom.d.ts +141 -0
- package/dist/features/zoom/use-zoom.js +204 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/react/components/ComponentKitPreview.d.ts +1 -1
- package/dist/react/components/ComponentKitPreview.js +1 -1
- package/dist/react/components/CustomSelect.js +1 -1
- package/dist/react/components/ExportDiagnosticsButton.d.ts +6 -2
- package/dist/react/components/ExportDiagnosticsButton.js +3 -3
- package/dist/react/components/FileImportPanel.js +1 -1
- package/dist/react/components/IconFrame.d.ts +15 -0
- package/dist/react/components/IconFrame.js +11 -0
- package/dist/react/components/ImportChoice.js +1 -1
- package/dist/react/components/Notice.js +1 -1
- package/dist/react/components/OnboardingDropdown.js +1 -1
- package/dist/react/components/PaletteTweaks.js +1 -1
- package/dist/react/components/TooltipLayer.d.ts +13 -3
- package/dist/react/components/TooltipLayer.js +12 -12
- package/dist/react/mcp-ui/host-message-source.d.ts +3 -1
- package/dist/react/mcp-ui/host-message-source.js +1 -1
- package/dist/react/testing.js +3 -1
- package/dist/renderers/annotation-canvas/rules.js +30 -27
- package/dist/renderers/react/components/ArtifactView.js +1 -1
- package/dist/renderers/renderers/markdown.d.ts +3 -1
- package/dist/renderers/renderers/markdown.js +2 -2
- package/dist/styles/admin.css +54 -54
- package/dist/utils/zip.js +43 -36
- package/package.json +66 -9
- package/dist/features/execution/ports.d.ts +0 -71
- package/dist/features/execution/ports.js +0 -2
- package/dist/features/execution/types.d.ts +0 -472
- package/dist/features/execution/types.js +0 -2
- package/dist/react/components/CustomSelectMarkup.d.ts +0 -27
- package/dist/react/components/CustomSelectMarkup.js +0 -35
|
@@ -17,7 +17,7 @@ function rowHandles({ agentHandle, action, ids }) {
|
|
|
17
17
|
}
|
|
18
18
|
function MemoryListCounts({ savedCount, extractionCount, useTHook = useT }) {
|
|
19
19
|
const t = useTHook();
|
|
20
|
-
return (_jsxs("div", { className: "jini-memory-management-counts", children: [_jsxs("span", { className: "memory-source-badge", children: [savedCount, " ", t('saved')] }), extractionCount > 0 ? (_jsxs("span", { className: "memory-source-badge", children: [extractionCount, " ", extractionCount === 1 ? t('extraction') : t('extractions')] })) : null] }));
|
|
20
|
+
return (_jsxs("div", { className: "jini-memory-management-counts", children: [_jsxs("span", { className: "jini-ui-memory-source-badge", children: [savedCount, " ", t('saved')] }), extractionCount > 0 ? (_jsxs("span", { className: "jini-ui-memory-source-badge", children: [extractionCount, " ", extractionCount === 1 ? t('extraction') : t('extractions')] })) : null] }));
|
|
21
21
|
}
|
|
22
22
|
function MemoryFilterPills({ entries, extractionCount, filter, onFilterChange, agentHandle, useTHook = useT, }) {
|
|
23
23
|
const t = useTHook();
|
|
@@ -52,6 +52,6 @@ function MemoryListToolbar({ entries, extractionCount, filter, onFilterChange, o
|
|
|
52
52
|
}
|
|
53
53
|
export function MemoryList({ sectionRef, entries, filtered, visibleExtractions, filter, onFilterChange, unifiedMemoryCount, onClearExtractions, onRefreshExtractions, isRefreshing, previewId, previewBody, nowClock, onOpenPreview, onStartEdit, onDeleteEntry, onDeleteExtraction, agentHandle, useTHook = useT, }) {
|
|
54
54
|
const t = useTHook();
|
|
55
|
-
return (_jsx("section", { ref: sectionRef, className: "settings-section settings-section-card memory-records-section", children: _jsxs("div", { className: "memory-management-panel", children: [_jsxs("div", { className: "memory-subsection-head", children: [_jsxs("div", { children: [_jsx("h4", { children: t('Saved memory') }), _jsx("p", { className: "hint", children: t('Saved facts, preferences, and project context available to future chats.') })] }), _jsx(MemoryListCounts, { savedCount: entries.length, extractionCount: visibleExtractions.length })] }), _jsx(MemoryListToolbar, { entries: entries, extractionCount: visibleExtractions.length, filter: filter, onFilterChange: onFilterChange, onClearExtractions: onClearExtractions, onRefreshExtractions: onRefreshExtractions, isRefreshing: isRefreshing, agentHandle: agentHandle }), _jsx("div", { className: "library-content memory-unified-list", children: unifiedMemoryCount === 0 ? (_jsx(MemoryListEmpty, {})) : (_jsx(MemoryListRows, { filtered: filtered, visibleExtractions: visibleExtractions, previewId: previewId, previewBody: previewBody, nowClock: nowClock, onOpenPreview: onOpenPreview, onStartEdit: onStartEdit, onDeleteEntry: onDeleteEntry, onDeleteExtraction: onDeleteExtraction, agentHandle: agentHandle })) })] }) }));
|
|
55
|
+
return (_jsx("section", { ref: sectionRef, className: "settings-section jini-ui-settings-section-card jini-ui-memory-records-section", children: _jsxs("div", { className: "jini-ui-memory-management-panel", children: [_jsxs("div", { className: "jini-ui-memory-subsection-head", children: [_jsxs("div", { children: [_jsx("h4", { children: t('Saved memory') }), _jsx("p", { className: "hint", children: t('Saved facts, preferences, and project context available to future chats.') })] }), _jsx(MemoryListCounts, { savedCount: entries.length, extractionCount: visibleExtractions.length })] }), _jsx(MemoryListToolbar, { entries: entries, extractionCount: visibleExtractions.length, filter: filter, onFilterChange: onFilterChange, onClearExtractions: onClearExtractions, onRefreshExtractions: onRefreshExtractions, isRefreshing: isRefreshing, agentHandle: agentHandle }), _jsx("div", { className: "jini-ui-library-content memory-unified-list", children: unifiedMemoryCount === 0 ? (_jsx(MemoryListEmpty, {})) : (_jsx(MemoryListRows, { filtered: filtered, visibleExtractions: visibleExtractions, previewId: previewId, previewBody: previewBody, nowClock: nowClock, onOpenPreview: onOpenPreview, onStartEdit: onStartEdit, onDeleteEntry: onDeleteEntry, onDeleteExtraction: onDeleteExtraction, agentHandle: agentHandle })) })] }) }));
|
|
56
56
|
}
|
|
57
57
|
//# sourceMappingURL=MemoryList.js.map
|
|
@@ -23,7 +23,7 @@ import { MemoryHowPanel } from './MemoryHowPanel.js';
|
|
|
23
23
|
import { MemoryList } from './MemoryList.js';
|
|
24
24
|
/** The "Memories" / "How it works" segmented view switch. */
|
|
25
25
|
function MemoryViewSwitch({ topTab, onTopTabChange, agentHandle, t }) {
|
|
26
|
-
return (_jsxs("div", { className: "jini-seg-control memory-panel-seg", role: "tablist", "aria-label": t('Memory view'), style: { '--seg-cols': 2 }, children: [_jsx("button", { type: "button", role: "tab", "aria-selected": topTab === 'memories', className: 'jini-seg-btn' + (topTab === 'memories' ? ' active' : ''), onClick: () => onTopTabChange('memories'), ...agentHandleProps({}, { base: agentHandle, ...({ action: 'view-memories', role: 'button', label: t('Memories') }) }), children: _jsx("span", { className: "jini-seg-title", children: t('Memories') }) }), _jsx("button", { type: "button", role: "tab", "aria-selected": topTab === 'how', className: 'jini-seg-btn' + (topTab === 'how' ? ' active' : ''), onClick: () => onTopTabChange('how'), ...agentHandleProps({}, { base: agentHandle, ...({ action: 'view-how', role: 'button', label: t('How it works') }) }), children: _jsx("span", { className: "jini-seg-title", children: t('How it works') }) })] }));
|
|
26
|
+
return (_jsxs("div", { className: "jini-seg-control jini-ui-memory-panel-seg", role: "tablist", "aria-label": t('Memory view'), style: { '--seg-cols': 2 }, children: [_jsx("button", { type: "button", role: "tab", "aria-selected": topTab === 'memories', className: 'jini-seg-btn' + (topTab === 'memories' ? ' active' : ''), onClick: () => onTopTabChange('memories'), ...agentHandleProps({}, { base: agentHandle, ...({ action: 'view-memories', role: 'button', label: t('Memories') }) }), children: _jsx("span", { className: "jini-seg-title", children: t('Memories') }) }), _jsx("button", { type: "button", role: "tab", "aria-selected": topTab === 'how', className: 'jini-seg-btn' + (topTab === 'how' ? ' active' : ''), onClick: () => onTopTabChange('how'), ...agentHandleProps({}, { base: agentHandle, ...({ action: 'view-how', role: 'button', label: t('How it works') }) }), children: _jsx("span", { className: "jini-seg-title", children: t('How it works') }) })] }));
|
|
27
27
|
}
|
|
28
28
|
export function MemorySettingsPanel({ enabled, onToggleEnabled, topTab, onTopTabChange, onAdd, onOpenAdvanced, savedMemory, howItWorks, agentHandle, useTHook = useT, }) {
|
|
29
29
|
const t = useTHook();
|
|
@@ -32,6 +32,6 @@ export function MemorySettingsPanel({ enabled, onToggleEnabled, topTab, onTopTab
|
|
|
32
32
|
const sectionRef = useRef(null);
|
|
33
33
|
const savedHandleProps = agentHandle ? { agentHandle: agentSubHandle({ base: agentHandle, action: 'saved' }) } : {};
|
|
34
34
|
const howHandleProps = agentHandle ? { agentHandle: agentSubHandle({ base: agentHandle, action: 'how' }) } : {};
|
|
35
|
-
return (_jsxs("div", { className: "memory-settings-panel", children: [_jsxs("section", { className: "memory-panel-head-card", children: [_jsxs("div", { className: "memory-panel-head-copy", children: [_jsx("h4", { children: t('Memory') }), _jsx("p", { className: "hint", children: t('Control whether saved facts, preferences, and project context are reused in future chats.') })] }), _jsxs("div", { className: "memory-panel-head-controls", children: [_jsx(MemoryViewSwitch, { topTab: topTab, onTopTabChange: onTopTabChange, agentHandle: agentHandle, t: t }), _jsx("button", { type: "button", className: "memory-icon-btn", onClick: onAdd, disabled: !onAdd, "aria-label": t('Add memory'), title: t('Add memory'), ...agentHandleProps({}, { base: agentHandle, ...({ action: 'add', role: 'button', label: t('Add memory') }) }), children: _jsx(Icon, { name: "plus", size: 14 }) }), _jsx("button", { type: "button", className: "memory-icon-btn", onClick: onOpenAdvanced, disabled: !onOpenAdvanced, "aria-label": t('Advanced'), title: t('Advanced'), ...agentHandleProps({}, { base: agentHandle, ...({ action: 'advanced', role: 'button', label: t('Advanced') }) }), children: _jsx(Icon, { name: "settings", size: 14 }) }), _jsxs("label", { className: "toggle-switch memory-panel-master-toggle", title: enabled ? t('On') : t('Off'), children: [_jsx("input", { type: "checkbox", "aria-label": t('Enable memory'), checked: enabled, onChange: (event) => onToggleEnabled(event.target.checked), ...agentHandleProps({}, { base: agentHandle, ...({ action: 'enabled', role: 'checkbox', label: t('Enable memory') }) }) }), _jsx("span", { className: "toggle-slider" })] })] })] }), topTab === 'memories' ? (_jsx(MemoryList, { sectionRef: sectionRef, ...savedMemory, ...savedHandleProps })) : (_jsx(MemoryHowPanel, { ...howItWorks, ...howHandleProps }))] }));
|
|
35
|
+
return (_jsxs("div", { className: "jini-ui-memory-settings-panel", children: [_jsxs("section", { className: "jini-ui-memory-panel-head-card", children: [_jsxs("div", { className: "jini-ui-memory-panel-head-copy", children: [_jsx("h4", { children: t('Memory') }), _jsx("p", { className: "hint", children: t('Control whether saved facts, preferences, and project context are reused in future chats.') })] }), _jsxs("div", { className: "jini-ui-memory-panel-head-controls", children: [_jsx(MemoryViewSwitch, { topTab: topTab, onTopTabChange: onTopTabChange, agentHandle: agentHandle, t: t }), _jsx("button", { type: "button", className: "jini-ui-memory-icon-btn", onClick: onAdd, disabled: !onAdd, "aria-label": t('Add memory'), title: t('Add memory'), ...agentHandleProps({}, { base: agentHandle, ...({ action: 'add', role: 'button', label: t('Add memory') }) }), children: _jsx(Icon, { name: "plus", size: 14 }) }), _jsx("button", { type: "button", className: "jini-ui-memory-icon-btn", onClick: onOpenAdvanced, disabled: !onOpenAdvanced, "aria-label": t('Advanced'), title: t('Advanced'), ...agentHandleProps({}, { base: agentHandle, ...({ action: 'advanced', role: 'button', label: t('Advanced') }) }), children: _jsx(Icon, { name: "settings", size: 14 }) }), _jsxs("label", { className: "jini-ui-toggle-switch memory-panel-master-toggle", title: enabled ? t('On') : t('Off'), children: [_jsx("input", { type: "checkbox", "aria-label": t('Enable memory'), checked: enabled, onChange: (event) => onToggleEnabled(event.target.checked), ...agentHandleProps({}, { base: agentHandle, ...({ action: 'enabled', role: 'checkbox', label: t('Enable memory') }) }) }), _jsx("span", { className: "jini-ui-toggle-slider" })] })] })] }), topTab === 'memories' ? (_jsx(MemoryList, { sectionRef: sectionRef, ...savedMemory, ...savedHandleProps })) : (_jsx(MemoryHowPanel, { ...howItWorks, ...howHandleProps }))] }));
|
|
36
36
|
}
|
|
37
37
|
//# sourceMappingURL=MemorySettingsPanel.js.map
|
|
@@ -13,6 +13,6 @@ function MemorySuggestionCard({ suggestion, selected, typeLabel, toggleConnector
|
|
|
13
13
|
export function MemorySuggestionPanel({ connectorSuggestions, selectedSuggestionIds, selectedConnectorSuggestions, connectorSaving, toggleConnectorSuggestion, onSaveConnectorSuggestions, onDiscardConnectorSuggestions, useTHook = useT, }) {
|
|
14
14
|
const t = useTHook();
|
|
15
15
|
const typeLabel = useMemo(() => memoryTypeLabels({ t }), [t]);
|
|
16
|
-
return (_jsxs("div", { className: "memory-suggestion-panel", children: [_jsxs("div", { className: "memory-subsection-head", children: [_jsxs("div", { children: [_jsx("h4", { children: t('Suggested memories') }), _jsx("p", { className: "hint", children: t('Review design-related memories before saving them.') })] }), _jsxs("span", { className: "memory-source-badge", children: [selectedConnectorSuggestions.length, " ", t('selected')] })] }), _jsx("div", { className: "memory-suggestion-list", children: connectorSuggestions.map((suggestion) => (_jsx(MemorySuggestionCard, { suggestion: suggestion, selected: selectedSuggestionIds.has(suggestion.id), typeLabel: typeLabel[suggestion.type], toggleConnectorSuggestion: toggleConnectorSuggestion }, suggestion.id))) }), _jsxs("div", { className: "memory-connector-actions", children: [_jsxs("button", { type: "button", className: "primary memory-source-action", onClick: () => void onSaveConnectorSuggestions(), disabled: connectorSaving || selectedConnectorSuggestions.length === 0, children: [_jsx(Icon, { name: connectorSaving ? 'refresh' : 'check', size: 14, className: connectorSaving ? 'icon-spin' : '' }), _jsx("span", { children: connectorSaving ? t('Saving') : t('Save selected') })] }), _jsx("button", { type: "button", className: "ghost memory-source-action", onClick: onDiscardConnectorSuggestions, disabled: connectorSaving, children: t('Discard') })] })] }));
|
|
16
|
+
return (_jsxs("div", { className: "memory-suggestion-panel", children: [_jsxs("div", { className: "jini-ui-memory-subsection-head", children: [_jsxs("div", { children: [_jsx("h4", { children: t('Suggested memories') }), _jsx("p", { className: "hint", children: t('Review design-related memories before saving them.') })] }), _jsxs("span", { className: "jini-ui-memory-source-badge", children: [selectedConnectorSuggestions.length, " ", t('selected')] })] }), _jsx("div", { className: "memory-suggestion-list", children: connectorSuggestions.map((suggestion) => (_jsx(MemorySuggestionCard, { suggestion: suggestion, selected: selectedSuggestionIds.has(suggestion.id), typeLabel: typeLabel[suggestion.type], toggleConnectorSuggestion: toggleConnectorSuggestion }, suggestion.id))) }), _jsxs("div", { className: "memory-connector-actions", children: [_jsxs("button", { type: "button", className: "primary memory-source-action", onClick: () => void onSaveConnectorSuggestions(), disabled: connectorSaving || selectedConnectorSuggestions.length === 0, children: [_jsx(Icon, { name: connectorSaving ? 'refresh' : 'check', size: 14, className: connectorSaving ? 'icon-spin' : '' }), _jsx("span", { children: connectorSaving ? t('Saving') : t('Save selected') })] }), _jsx("button", { type: "button", className: "ghost memory-source-action", onClick: onDiscardConnectorSuggestions, disabled: connectorSaving, children: t('Discard') })] })] }));
|
|
17
17
|
}
|
|
18
18
|
//# sourceMappingURL=MemorySuggestionPanel.js.map
|
|
@@ -50,7 +50,7 @@ export { saveSelectedConnectorSuggestions };
|
|
|
50
50
|
* barrel. */
|
|
51
51
|
export function applyMemoryConnectorConnectThrown({ connectorId, err }, { setConnectorConnectErrors, setPendingConnectorAuthIds, }) {
|
|
52
52
|
setConnectorConnectErrors((prev) => ({ ...prev, [connectorId]: err instanceof Error ? err.message : String(err) }));
|
|
53
|
-
setPendingConnectorAuthIds((prev) => withoutSetMember(prev, connectorId));
|
|
53
|
+
setPendingConnectorAuthIds((prev) => withoutSetMember({ set: prev, value: connectorId }));
|
|
54
54
|
}
|
|
55
55
|
/** `onConnectMemoryConnector`'s "the port call resolved" path: decides and
|
|
56
56
|
* applies the connector upsert, pending-auth membership, and connect-error
|
|
@@ -71,10 +71,10 @@ export function applyMemoryConnectorConnectResult({ connectorId, result, port, }
|
|
|
71
71
|
invalidateCatalogueGuard();
|
|
72
72
|
if (result.error) {
|
|
73
73
|
setConnectorConnectErrors((prev) => ({ ...prev, [connectorId]: result.error }));
|
|
74
|
-
setPendingConnectorAuthIds((prev) => withoutSetMember(prev, connectorId));
|
|
74
|
+
setPendingConnectorAuthIds((prev) => withoutSetMember({ set: prev, value: connectorId }));
|
|
75
75
|
return false;
|
|
76
76
|
}
|
|
77
|
-
setPendingConnectorAuthIds((prev) => requiresAuthorizationCompletion ? new Set(prev).add(connectorId) : withoutSetMember(prev, connectorId));
|
|
77
|
+
setPendingConnectorAuthIds((prev) => requiresAuthorizationCompletion ? new Set(prev).add(connectorId) : withoutSetMember({ set: prev, value: connectorId }));
|
|
78
78
|
return true;
|
|
79
79
|
}
|
|
80
80
|
/** The per-connector connect flow (OAuth start), guarded against re-entrancy per connector id. */
|
|
@@ -5,7 +5,10 @@ import type { ConnectorMemorySuggestionResponse, FriendlyExtractionFailure, Memo
|
|
|
5
5
|
export { withoutKey } from '../../../connectors/rules.js';
|
|
6
6
|
/** `Set` counterpart to {@link withoutKey}: removes `value`, preserving
|
|
7
7
|
* referential identity when it was already absent. */
|
|
8
|
-
export declare function withoutSetMember<T>(set
|
|
8
|
+
export declare function withoutSetMember<T>({ set, value }: {
|
|
9
|
+
set: Set<T>;
|
|
10
|
+
value: T;
|
|
11
|
+
}, _optional?: Record<string, never>): Set<T>;
|
|
9
12
|
/** What `onSuggestConnectorMemory` should show once a scan attempt resolves:
|
|
10
13
|
* a friendly extraction failure wins over any suggestions found, followed by
|
|
11
14
|
* suggestions, a read-issue error, and finally a benign "nothing new" status. */
|
|
@@ -10,7 +10,7 @@ import { withoutKey } from '../../../connectors/rules.js';
|
|
|
10
10
|
export { withoutKey } from '../../../connectors/rules.js';
|
|
11
11
|
/** `Set` counterpart to {@link withoutKey}: removes `value`, preserving
|
|
12
12
|
* referential identity when it was already absent. */
|
|
13
|
-
export function withoutSetMember(set, value) {
|
|
13
|
+
export function withoutSetMember({ set, value }, _optional = {}) {
|
|
14
14
|
if (!set.has(value))
|
|
15
15
|
return set;
|
|
16
16
|
const next = new Set(set);
|
|
@@ -3,7 +3,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
3
3
|
// body. OD's real `runtime/markdown.tsx` (2,881 lines) is chat/artifact
|
|
4
4
|
// rendering territory, explicitly deferred to `@jini-ai/chat`'s `./react` subpath (formerly
|
|
5
5
|
// this package's own `./chat` export, extracted 2026-08-03)/this package's own `./renderers`
|
|
6
|
-
// subpath (see `
|
|
6
|
+
// subpath (see `070311a07^:packages/ui/source-map.md` (section "features/memory/")) — this is a
|
|
7
7
|
// scoped-down local reimplementation covering just this slice's one need:
|
|
8
8
|
// render a memory body's GFM Markdown as read-only preview text. Built on
|
|
9
9
|
// `micromark`, already a real dependency of this package (see
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Hover and accessible attributes for a navigation button that may be unavailable. Keep hover
|
|
3
|
+
* explanations on aria-disabled buttons: native disabled suppresses their tooltips.
|
|
4
|
+
* @param required.labels.unavailable the host's copy for an unavailable destination.
|
|
5
|
+
* @complexity O(1).
|
|
6
|
+
*/
|
|
7
|
+
export declare function navAvailability({ label, disabled, labels }: {
|
|
8
|
+
label: string;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
labels: {
|
|
11
|
+
readonly unavailable: string;
|
|
12
|
+
};
|
|
13
|
+
}, _optional?: {}): {
|
|
14
|
+
'data-tip': string;
|
|
15
|
+
title?: string;
|
|
16
|
+
'aria-description'?: string;
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=nav-availability.d.ts.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Hover and accessible attributes for a navigation button that may be unavailable. Keep hover
|
|
3
|
+
* explanations on aria-disabled buttons: native disabled suppresses their tooltips.
|
|
4
|
+
* @param required.labels.unavailable the host's copy for an unavailable destination.
|
|
5
|
+
* @complexity O(1).
|
|
6
|
+
*/
|
|
7
|
+
export function navAvailability({ label, disabled, labels }, _optional = {}) {
|
|
8
|
+
if (!disabled)
|
|
9
|
+
return { 'data-tip': label };
|
|
10
|
+
return { 'data-tip': `${label} — ${labels.unavailable}`, title: labels.unavailable, 'aria-description': labels.unavailable };
|
|
11
|
+
}
|
|
12
|
+
//# sourceMappingURL=nav-availability.js.map
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import type { StepperBounds } from "./number-stepper.js";
|
|
2
|
+
import type { useNumberStepper } from "./use-number-stepper.hooks.js";
|
|
3
|
+
import type { NumberSetting } from "./use-optimistic-number-setting.hooks.js";
|
|
4
|
+
/** Every visible or spoken string the stepper shows; product copy comes from the host. */
|
|
5
|
+
export interface NumberStepperLabels {
|
|
6
|
+
decrease: string;
|
|
7
|
+
increase: string;
|
|
8
|
+
field: string;
|
|
9
|
+
tip: string;
|
|
10
|
+
}
|
|
11
|
+
/** Host classes added beside the stepper's own `jini-number-stepper*` classes. */
|
|
12
|
+
export interface NumberStepperClassNames {
|
|
13
|
+
group?: string;
|
|
14
|
+
step?: string;
|
|
15
|
+
value?: string;
|
|
16
|
+
tip?: string;
|
|
17
|
+
}
|
|
18
|
+
export interface NumberStepperProps {
|
|
19
|
+
setting: NumberSetting;
|
|
20
|
+
bounds: StepperBounds;
|
|
21
|
+
labels: NumberStepperLabels;
|
|
22
|
+
/** Id of the element that names the control (the row's visible label). */
|
|
23
|
+
labelledBy: string;
|
|
24
|
+
/** The host passes `useNumberStepper` (or a stand-in); the component never picks one itself. */
|
|
25
|
+
/** REQUIRED host-supplied hooks (owner rule: hooks reach a Jini component as props). */
|
|
26
|
+
hooks: {
|
|
27
|
+
useNumberStepper: typeof useNumberStepper;
|
|
28
|
+
};
|
|
29
|
+
classNames?: NumberStepperClassNames;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* − / number / +, saving every step and every typed digit at once. The field is the one tab stop (a
|
|
33
|
+
* spinbutton); − and + are pointer and touch targets, as in the WAI spinbutton pattern. The tip hangs
|
|
34
|
+
* on the whole control for hover and keyboard focus, and on the field itself because a tapped text
|
|
35
|
+
* field is `:focus-visible`, which is what the `jini-tooltip` layer needs to show a tip after a touch
|
|
36
|
+
* (a tapped button is not).
|
|
37
|
+
*/
|
|
38
|
+
export declare function NumberStepper({ setting, bounds, labels, labelledBy, hooks, classNames }: NumberStepperProps): import("react").JSX.Element;
|
|
39
|
+
//# sourceMappingURL=NumberStepper.d.ts.map
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
const join = (own, host) => (host ? `${own} ${host}` : own);
|
|
3
|
+
/**
|
|
4
|
+
* − / number / +, saving every step and every typed digit at once. The field is the one tab stop (a
|
|
5
|
+
* spinbutton); − and + are pointer and touch targets, as in the WAI spinbutton pattern. The tip hangs
|
|
6
|
+
* on the whole control for hover and keyboard focus, and on the field itself because a tapped text
|
|
7
|
+
* field is `:focus-visible`, which is what the `jini-tooltip` layer needs to show a tip after a touch
|
|
8
|
+
* (a tapped button is not).
|
|
9
|
+
*/
|
|
10
|
+
export function NumberStepper({ setting, bounds, labels, labelledBy, hooks, classNames = {} }) {
|
|
11
|
+
const { draft, setDraft, value, save, onChange, onKeyDown } = hooks.useNumberStepper({ setting, bounds });
|
|
12
|
+
const tipId = `${labelledBy}-tip`;
|
|
13
|
+
const stepClass = join("jini-number-stepper__step", classNames.step);
|
|
14
|
+
return (_jsxs("div", { className: `${join("jini-number-stepper", classNames.group)} jini-tooltip`, role: "group", "aria-labelledby": labelledBy, "data-tooltip": labels.tip, "data-tooltip-placement": "bottom", children: [_jsx("button", { type: "button", className: stepClass, tabIndex: -1, "aria-label": labels.decrease, disabled: value <= bounds.min, onClick: () => save({ next: value - 1 }), children: _jsx("svg", { viewBox: "0 0 12 12", "aria-hidden": "true", children: _jsx("path", { d: "M2.5 6h7" }) }) }), _jsx("input", { className: `${join("jini-number-stepper__value", classNames.value)} jini-tooltip`, "data-tooltip": labels.tip, "data-tooltip-placement": "bottom", type: "text", inputMode: "numeric", role: "spinbutton", "aria-label": labels.field, "aria-describedby": tipId, "aria-valuemin": bounds.min, "aria-valuemax": bounds.max, "aria-valuenow": value, value: draft ?? String(value), onFocus: (event) => event.currentTarget.select(), onChange: (event) => onChange({ text: event.currentTarget.value }), onBlur: () => setDraft(null), onKeyDown: onKeyDown }), _jsx("button", { type: "button", className: stepClass, tabIndex: -1, "aria-label": labels.increase, disabled: value >= bounds.max, onClick: () => save({ next: value + 1 }), children: _jsx("svg", { viewBox: "0 0 12 12", "aria-hidden": "true", children: _jsx("path", { d: "M2.5 6h7M6 2.5v7" }) }) }), _jsx("span", { id: tipId, className: join("jini-number-stepper__tip", classNames.tip), children: labels.tip })] }));
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=NumberStepper.js.map
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { NumberStepper, type NumberStepperClassNames, type NumberStepperLabels, type NumberStepperProps } from "./NumberStepper.js";
|
|
2
|
+
export { useNumberStepper, type NumberStepperController } from "./use-number-stepper.hooks.js";
|
|
3
|
+
export { useOptimisticNumberSetting, type NumberSetting, type NumberSettingWrite } from "./use-optimistic-number-setting.hooks.js";
|
|
4
|
+
export { acceptedSavedValue, clampToBounds, numberFromTypedDigit, stepperKeyTarget, type StepperBounds } from "./number-stepper.js";
|
|
5
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { NumberStepper } from "./NumberStepper.js";
|
|
2
|
+
export { useNumberStepper } from "./use-number-stepper.hooks.js";
|
|
3
|
+
export { useOptimisticNumberSetting } from "./use-optimistic-number-setting.hooks.js";
|
|
4
|
+
export { acceptedSavedValue, clampToBounds, numberFromTypedDigit, stepperKeyTarget } from "./number-stepper.js";
|
|
5
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file Pure rules for a small whole-number stepper (− / field / +) over host-injected bounds.
|
|
3
|
+
* The typed-field rule reads one digit, so it is meant for ranges whose upper limit is a single digit.
|
|
4
|
+
*/
|
|
5
|
+
/** The inclusive range a stepper allows. The host owns the numbers (they are product policy). */
|
|
6
|
+
export interface StepperBounds {
|
|
7
|
+
readonly min: number;
|
|
8
|
+
readonly max: number;
|
|
9
|
+
}
|
|
10
|
+
/** `value` pulled into `bounds`. O(1). */
|
|
11
|
+
export declare function clampToBounds({ value, bounds }: {
|
|
12
|
+
value: number;
|
|
13
|
+
bounds: StepperBounds;
|
|
14
|
+
}, _options?: {}): number;
|
|
15
|
+
/** The spinbutton keys and where each one goes from `value`; `null` for any other key. O(1). */
|
|
16
|
+
export declare function stepperKeyTarget({ key, value, bounds }: {
|
|
17
|
+
key: string;
|
|
18
|
+
value: number;
|
|
19
|
+
bounds: StepperBounds;
|
|
20
|
+
}, _options?: {}): number | null;
|
|
21
|
+
/** A typed field's number: its last digit, clamped (the range is single digits, so typing after the
|
|
22
|
+
* digit already there means the new one). `null` while the field holds no digit. O(text). */
|
|
23
|
+
export declare function numberFromTypedDigit({ text, bounds }: {
|
|
24
|
+
text: string;
|
|
25
|
+
bounds: StepperBounds;
|
|
26
|
+
}, _options?: {}): number | null;
|
|
27
|
+
/** The store's answer to a save as a whole number at or above the lower limit, clamped to the upper
|
|
28
|
+
* one; anything else keeps what is shown (`current`). O(1). */
|
|
29
|
+
export declare function acceptedSavedValue({ value, current, bounds }: {
|
|
30
|
+
value: unknown;
|
|
31
|
+
current: number;
|
|
32
|
+
bounds: StepperBounds;
|
|
33
|
+
}, _options?: {}): number;
|
|
34
|
+
//# sourceMappingURL=number-stepper.d.ts.map
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file Pure rules for a small whole-number stepper (− / field / +) over host-injected bounds.
|
|
3
|
+
* The typed-field rule reads one digit, so it is meant for ranges whose upper limit is a single digit.
|
|
4
|
+
*/
|
|
5
|
+
/** `value` pulled into `bounds`. O(1). */
|
|
6
|
+
export function clampToBounds({ value, bounds }, _options = {}) {
|
|
7
|
+
return Math.min(bounds.max, Math.max(bounds.min, value));
|
|
8
|
+
}
|
|
9
|
+
/** The spinbutton keys and where each one goes from `value`; `null` for any other key. O(1). */
|
|
10
|
+
export function stepperKeyTarget({ key, value, bounds }, _options = {}) {
|
|
11
|
+
if (key === "ArrowUp")
|
|
12
|
+
return Math.min(bounds.max, value + 1);
|
|
13
|
+
if (key === "ArrowDown")
|
|
14
|
+
return Math.max(bounds.min, value - 1);
|
|
15
|
+
if (key === "Home")
|
|
16
|
+
return bounds.min;
|
|
17
|
+
if (key === "End")
|
|
18
|
+
return bounds.max;
|
|
19
|
+
return null;
|
|
20
|
+
}
|
|
21
|
+
/** A typed field's number: its last digit, clamped (the range is single digits, so typing after the
|
|
22
|
+
* digit already there means the new one). `null` while the field holds no digit. O(text). */
|
|
23
|
+
export function numberFromTypedDigit({ text, bounds }, _options = {}) {
|
|
24
|
+
const digit = text.replace(/\D/g, "").slice(-1);
|
|
25
|
+
return digit === "" ? null : clampToBounds({ value: Number(digit), bounds });
|
|
26
|
+
}
|
|
27
|
+
/** The store's answer to a save as a whole number at or above the lower limit, clamped to the upper
|
|
28
|
+
* one; anything else keeps what is shown (`current`). O(1). */
|
|
29
|
+
export function acceptedSavedValue({ value, current, bounds }, _options = {}) {
|
|
30
|
+
return typeof value === "number" && Number.isInteger(value) && value >= bounds.min ? clampToBounds({ value, bounds }) : current;
|
|
31
|
+
}
|
|
32
|
+
//# sourceMappingURL=number-stepper.js.map
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { type KeyboardEvent } from "react";
|
|
2
|
+
import { type StepperBounds } from "./number-stepper.js";
|
|
3
|
+
import type { NumberSetting } from "./use-optimistic-number-setting.hooks.js";
|
|
4
|
+
/** What {@link useNumberStepper} hands the stepper: the field's draft and its handlers. */
|
|
5
|
+
export interface NumberStepperController {
|
|
6
|
+
draft: string | null;
|
|
7
|
+
setDraft: (draft: string | null) => void;
|
|
8
|
+
value: number;
|
|
9
|
+
save: NumberSetting["save"];
|
|
10
|
+
onChange: (input: {
|
|
11
|
+
text: string;
|
|
12
|
+
}) => void;
|
|
13
|
+
onKeyDown: (event: KeyboardEvent<HTMLInputElement>) => void;
|
|
14
|
+
}
|
|
15
|
+
/** Manage the editable value and spinbutton keys of a {@link NumberSetting} within `bounds`. */
|
|
16
|
+
export declare function useNumberStepper({ setting, bounds }: {
|
|
17
|
+
setting: NumberSetting;
|
|
18
|
+
bounds: StepperBounds;
|
|
19
|
+
}, _options?: {}): NumberStepperController;
|
|
20
|
+
//# sourceMappingURL=use-number-stepper.hooks.d.ts.map
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { useState } from "react";
|
|
2
|
+
import { numberFromTypedDigit, stepperKeyTarget } from "./number-stepper.js";
|
|
3
|
+
/** Manage the editable value and spinbutton keys of a {@link NumberSetting} within `bounds`. */
|
|
4
|
+
export function useNumberStepper({ setting, bounds }, _options = {}) {
|
|
5
|
+
// `null` shows the saved value; a string is the field mid-edit (cleared, or a non-digit typed).
|
|
6
|
+
const [draft, setDraft] = useState(null);
|
|
7
|
+
const { value, save } = setting;
|
|
8
|
+
const onChange = ({ text }, _options = {}) => {
|
|
9
|
+
const next = numberFromTypedDigit({ text, bounds });
|
|
10
|
+
if (next === null) {
|
|
11
|
+
setDraft("");
|
|
12
|
+
return;
|
|
13
|
+
}
|
|
14
|
+
setDraft(null);
|
|
15
|
+
save({ next });
|
|
16
|
+
};
|
|
17
|
+
const onKeyDown = (event) => {
|
|
18
|
+
const next = stepperKeyTarget({ key: event.key, value, bounds });
|
|
19
|
+
if (next === null)
|
|
20
|
+
return;
|
|
21
|
+
// A surrounding menu's own Up/Down/Home/End would move focus to another row; here they change the number.
|
|
22
|
+
event.preventDefault();
|
|
23
|
+
event.stopPropagation();
|
|
24
|
+
setDraft(null);
|
|
25
|
+
save({ next });
|
|
26
|
+
};
|
|
27
|
+
return { draft, setDraft, value, save, onChange, onKeyDown };
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=use-number-stepper.hooks.js.map
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { type StepperBounds } from "./number-stepper.js";
|
|
2
|
+
/** A persisted whole-number setting as a stepper consumes it. */
|
|
3
|
+
export interface NumberSetting {
|
|
4
|
+
/** False when the host has no way to persist the value: the host leaves the control out. */
|
|
5
|
+
available: boolean;
|
|
6
|
+
value: number;
|
|
7
|
+
/** Set after a failed save, cleared by the next one. */
|
|
8
|
+
error: string | null;
|
|
9
|
+
save: (input: {
|
|
10
|
+
next: number;
|
|
11
|
+
}) => void;
|
|
12
|
+
}
|
|
13
|
+
/** Persists a value and resolves with the store's own answer (which may differ, e.g. clamped). */
|
|
14
|
+
export type NumberSettingWrite = (input: {
|
|
15
|
+
next: number;
|
|
16
|
+
}) => Promise<unknown>;
|
|
17
|
+
/**
|
|
18
|
+
* The shown value moves at once on a save; a failed save puts the last value back and shows the
|
|
19
|
+
* host's `saveError` copy. `value`/`setValue` are the host's live view of the stored value (it may
|
|
20
|
+
* also change from elsewhere); `write` is undefined when the host cannot persist at all.
|
|
21
|
+
* @complexity O(1) per save, one write.
|
|
22
|
+
*/
|
|
23
|
+
export declare function useOptimisticNumberSetting({ value, setValue, write, bounds, saveError }: {
|
|
24
|
+
value: number;
|
|
25
|
+
setValue: (input: {
|
|
26
|
+
next: number;
|
|
27
|
+
}) => void;
|
|
28
|
+
write: NumberSettingWrite | undefined;
|
|
29
|
+
bounds: StepperBounds;
|
|
30
|
+
saveError: string;
|
|
31
|
+
}, { onSaveFailure }?: {
|
|
32
|
+
onSaveFailure?: (input: {
|
|
33
|
+
failure: unknown;
|
|
34
|
+
}) => void;
|
|
35
|
+
}): NumberSetting;
|
|
36
|
+
//# sourceMappingURL=use-optimistic-number-setting.hooks.d.ts.map
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { useState } from "react";
|
|
2
|
+
import { acceptedSavedValue } from "./number-stepper.js";
|
|
3
|
+
/**
|
|
4
|
+
* The shown value moves at once on a save; a failed save puts the last value back and shows the
|
|
5
|
+
* host's `saveError` copy. `value`/`setValue` are the host's live view of the stored value (it may
|
|
6
|
+
* also change from elsewhere); `write` is undefined when the host cannot persist at all.
|
|
7
|
+
* @complexity O(1) per save, one write.
|
|
8
|
+
*/
|
|
9
|
+
export function useOptimisticNumberSetting({ value, setValue, write, bounds, saveError }, { onSaveFailure } = {}) {
|
|
10
|
+
const [error, setError] = useState(null);
|
|
11
|
+
const save = ({ next }, _options = {}) => {
|
|
12
|
+
if (!write || next === value)
|
|
13
|
+
return;
|
|
14
|
+
const previous = value;
|
|
15
|
+
setValue({ next });
|
|
16
|
+
setError(null);
|
|
17
|
+
void write({ next }).then((saved) => setValue({ next: acceptedSavedValue({ value: saved, current: next, bounds }) }), (failure) => {
|
|
18
|
+
onSaveFailure?.({ failure });
|
|
19
|
+
setValue({ next: previous });
|
|
20
|
+
setError(saveError);
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
return { available: write !== undefined, value, error, save };
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=use-optimistic-number-setting.hooks.js.map
|
|
@@ -8,6 +8,13 @@ import {} from '@jini-ai/core/text';
|
|
|
8
8
|
*/
|
|
9
9
|
export function ErrorNotice({ failure, disclosure = 'full', t = text => text, className = 'notice error', role = 'alert', useErrorNoticeHook = useErrorNotice, ...ports }) {
|
|
10
10
|
const { feedback, copy } = useErrorNoticeHook({ failure, ports });
|
|
11
|
-
|
|
11
|
+
const feedbackText = copyFeedbackText({ feedback, copyText: failure.copyText });
|
|
12
|
+
return (_jsxs("div", { className: className, role: role, children: [_jsx("p", { children: failure.message }), _jsx("p", { children: failure.action }), disclosure === 'id-only' ? (failure.errorId ? _jsxs("p", { children: [failure.errorId, " \u2014 ", t('Report this error ID.')] }) : null) : _jsxs("details", { children: [_jsx("summary", { children: t('Show details') }), _jsx("pre", { style: { whiteSpace: 'pre-wrap', overflowWrap: 'anywhere', userSelect: 'text' }, children: failure.copyText }), _jsx("button", { type: "button", onClick: () => void copy(), children: t('Copy details') }), feedbackText !== null ? _jsx("p", { role: "status", children: t(feedbackText) }) : null] })] }));
|
|
13
|
+
}
|
|
14
|
+
/** Feedback only describes the incident it copied; a stale result from an earlier incident shows nothing. */
|
|
15
|
+
function copyFeedbackText({ feedback, copyText }, _optional = {}) {
|
|
16
|
+
if (!feedback || feedback.text !== copyText)
|
|
17
|
+
return null;
|
|
18
|
+
return feedback.copied ? 'Copied' : 'Copy failed. Select the details and copy them manually.';
|
|
12
19
|
}
|
|
13
20
|
//# sourceMappingURL=ErrorNotice.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { StandingDraftAutosaveInput, StandingDraftAutosaveSnapshot } from "
|
|
1
|
+
import type { StandingDraftAutosaveInput, StandingDraftAutosaveSnapshot } from "@jini-ai/core/contracts/standing-draft";
|
|
2
2
|
/**
|
|
3
3
|
* @file Last-resort per-tab mirror for a standing draft the SERVER REFUSED (2026-09-06 stale-basis
|
|
4
4
|
* fix). Deliberately NOT a general autosave backend — browser storage was explicitly rejected for
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { StandingDraftAutosaveSnapshot } from "
|
|
1
|
+
import type { StandingDraftAutosaveSnapshot } from "@jini-ai/core/contracts/standing-draft";
|
|
2
2
|
/** Compare timestamps explicitly; restoration only changes the working copy, never the server. */
|
|
3
3
|
export declare function standingDraftRecoveryMessage({ draft, t, serverUpdatedAt }: {
|
|
4
4
|
draft: StandingDraftAutosaveSnapshot;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { StandingDraftAutosaveInput, StandingDraftAutosaveSnapshot, StandingDraftStaleBasis } from "@jini-ai/core/contracts/standing-draft";
|
|
1
2
|
import type { createStandingDraftLocalBackup } from "../helpers/standing-draft-local-backup.js";
|
|
2
3
|
import { useStandingDraftState as useStandingDraftStateDefault, useStandingDraftTimer as useStandingDraftTimerDefault, useStandingDraftQueue as useStandingDraftQueueDefault } from "./use-standing-draft-state.hooks.js";
|
|
3
4
|
import { useStandingDraftStaleBasis as useStandingDraftStaleBasisDefault, useStandingDraftRecovery as useStandingDraftRecoveryDefault, useStandingDraftFailedSave as useStandingDraftFailedSaveDefault } from "./use-standing-draft-recovery.hooks.js";
|
|
@@ -45,33 +46,6 @@ import { useStandingDraftWriter as useStandingDraftWriterDefault, useStandingDra
|
|
|
45
46
|
* tab. Collapsing the two back into one "clear it all" step reintroduces a window in which a failed
|
|
46
47
|
* request loses the work.
|
|
47
48
|
*/
|
|
48
|
-
/** The fields a standing draft carries — see `PostAutosaveSnapshot`'s own server-side doc for why
|
|
49
|
-
* `status` is deliberately absent (a draft must never change whether a row is live). */
|
|
50
|
-
export type StandingDraftAutosaveInput = {
|
|
51
|
-
bodyFormat: "doc";
|
|
52
|
-
bodyJson: Record<string, unknown>;
|
|
53
|
-
title: string;
|
|
54
|
-
slug: string;
|
|
55
|
-
baseVersion: number;
|
|
56
|
-
} | {
|
|
57
|
-
bodyFormat: "html";
|
|
58
|
-
bodyHtml: string;
|
|
59
|
-
title: string;
|
|
60
|
-
slug: string;
|
|
61
|
-
baseVersion: number;
|
|
62
|
-
};
|
|
63
|
-
export interface StandingDraftAutosaveSnapshot {
|
|
64
|
-
bodyFormat: "doc" | "html";
|
|
65
|
-
bodyJson?: Record<string, unknown>;
|
|
66
|
-
bodyHtml?: string;
|
|
67
|
-
title: string;
|
|
68
|
-
slug: string;
|
|
69
|
-
baseVersion: number;
|
|
70
|
-
savedAt: string;
|
|
71
|
-
savedByPrincipalId: string;
|
|
72
|
-
/** Fresh server timestamp used only for the explicit recovery comparison. */
|
|
73
|
-
serverUpdatedAt?: string | undefined;
|
|
74
|
-
}
|
|
75
49
|
/** What this hook needs from the outside world — see this file's header for why it is declared
|
|
76
50
|
* here rather than imported from either feature's own port. */
|
|
77
51
|
export interface StandingDraftAutosavePort {
|
|
@@ -106,16 +80,6 @@ export interface StandingDraftAutosavePort {
|
|
|
106
80
|
ok: boolean;
|
|
107
81
|
}>;
|
|
108
82
|
}
|
|
109
|
-
/** A write the server refused because the row moved on — see this file's header. Carries the
|
|
110
|
-
* operator's refused text itself, not just a flag: it is the copy nothing else on the client has
|
|
111
|
-
* a claim to, and a conflict notice that drops the work would be worse than the silent drop. */
|
|
112
|
-
export interface StandingDraftStaleBasis {
|
|
113
|
-
/** The `baseVersion` the refused draft was built on. The gate lifts when a later
|
|
114
|
-
* `scheduleAutosave` arrives on a different one. */
|
|
115
|
-
baseVersion: number;
|
|
116
|
-
/** Exactly what was refused. */
|
|
117
|
-
draft: StandingDraftAutosaveInput;
|
|
118
|
-
}
|
|
119
83
|
export interface StandingDraftAutosaveController {
|
|
120
84
|
/** Non-null once the mount-time recovery check resolves and finds a parked draft. Stays exactly
|
|
121
85
|
* as read until {@link dismissRecoverable}/{@link clearStandingDraft} clears it — never
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import type { StandingDraftAutosaveOptions
|
|
1
|
+
import type { StandingDraftAutosaveOptions } from "./use-standing-draft-autosave.hooks.js";
|
|
2
|
+
import type { StandingDraftAutosaveInput } from "@jini-ai/core/contracts/standing-draft";
|
|
2
3
|
import type { useStandingDraftState } from "./use-standing-draft-state.hooks.js";
|
|
3
4
|
export declare function useStandingDraftStaleBasis(state: ReturnType<typeof useStandingDraftState>, deps: StandingDraftAutosaveOptions): {
|
|
4
5
|
markStaleBasis: (id: string, draft: StandingDraftAutosaveInput) => void;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import type { StandingDraftAutosaveOptions
|
|
1
|
+
import type { StandingDraftAutosaveOptions } from "./use-standing-draft-autosave.hooks.js";
|
|
2
|
+
import type { StandingDraftAutosaveInput, StandingDraftAutosaveSnapshot, StandingDraftStaleBasis } from "@jini-ai/core/contracts/standing-draft";
|
|
2
3
|
import { useSerialWrites as useSerialWritesDefault } from "./use-serial-writes.hooks.js";
|
|
3
4
|
export declare function useStandingDraftState(deps: StandingDraftAutosaveOptions, { useSerialWrites }?: {
|
|
4
5
|
useSerialWrites?: typeof useSerialWritesDefault;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import type { StandingDraftAutosaveOptions
|
|
1
|
+
import type { StandingDraftAutosaveOptions } from "./use-standing-draft-autosave.hooks.js";
|
|
2
|
+
import type { StandingDraftAutosaveInput } from "@jini-ai/core/contracts/standing-draft";
|
|
2
3
|
import type { useStandingDraftState, useStandingDraftTimer, useStandingDraftQueue } from "./use-standing-draft-state.hooks.js";
|
|
3
4
|
import type { useStandingDraftStaleBasis, useStandingDraftFailedSave } from "./use-standing-draft-recovery.hooks.js";
|
|
4
5
|
export declare function useStandingDraftWriter(state: ReturnType<typeof useStandingDraftState>, deps: StandingDraftAutosaveOptions, actions: ReturnType<typeof useStandingDraftStaleBasis> & {
|
|
@@ -21,7 +21,8 @@ export { useSettingsSlice } from './hooks/use-settings-slice.hooks.js';
|
|
|
21
21
|
export { mergeSaveStates, commitQueuedSave, canAcceptRefresh, SAVE_DEBOUNCE_MS } from './hooks/settings-slice.helpers.js';
|
|
22
22
|
export type { SaveState, SettingsSlice, SettingsSliceOptions, SettingsSliceRefreshPort, SettingsRefreshScope } from './hooks/settings-slice.helpers.js';
|
|
23
23
|
export { useStandingDraftAutosave } from './hooks/use-standing-draft-autosave.hooks.js';
|
|
24
|
-
export type { StandingDraftAutosavePort,
|
|
24
|
+
export type { StandingDraftAutosavePort, StandingDraftAutosaveController, StandingDraftAutosaveOptions } from './hooks/use-standing-draft-autosave.hooks.js';
|
|
25
|
+
export type { StandingDraftAutosaveInput, StandingDraftAutosaveSnapshot, StandingDraftStaleBasis } from "@jini-ai/core/contracts/standing-draft";
|
|
25
26
|
export { createStandingDraftLocalBackup, LOCAL_BACKUP_PRINCIPAL_ID } from './helpers/standing-draft-local-backup.js';
|
|
26
27
|
export { standingDraftRecoveryMessage } from './helpers/standing-draft-recovery-message.js';
|
|
27
28
|
export { createFailureChannel } from './failure-channel.js';
|
|
@@ -35,7 +35,7 @@ export interface PrivacyTabProps {
|
|
|
35
35
|
* mounted by `SettingsDialog.tsx`'s `privacy` tab — flagged "likely
|
|
36
36
|
* generic, not fully verified" by
|
|
37
37
|
* `ADS-memory/reports/jini-port/recon/r6-god-component-internals.md` §1.3; this task is
|
|
38
|
-
* the first full verification (see `
|
|
38
|
+
* the first full verification (see `070311a07^:packages/ui/source-map.md` (section "features/settings-dialog/")).
|
|
39
39
|
*/
|
|
40
40
|
export declare function PrivacyTab({ state, onChange, labels, now, agentHandle, useTHook }: PrivacyTabProps & {
|
|
41
41
|
useTHook?: typeof useT;
|
|
@@ -32,7 +32,7 @@ function resolveInstallationLabels({ labels }, { t }) {
|
|
|
32
32
|
* mounted by `SettingsDialog.tsx`'s `privacy` tab — flagged "likely
|
|
33
33
|
* generic, not fully verified" by
|
|
34
34
|
* `ADS-memory/reports/jini-port/recon/r6-god-component-internals.md` §1.3; this task is
|
|
35
|
-
* the first full verification (see `
|
|
35
|
+
* the first full verification (see `070311a07^:packages/ui/source-map.md` (section "features/settings-dialog/")).
|
|
36
36
|
*/
|
|
37
37
|
export function PrivacyTab({ state, onChange, labels, now = Date.now, agentHandle, useTHook = useT }) {
|
|
38
38
|
const t = useTHook();
|
|
@@ -13,7 +13,7 @@ export interface ProgressCardProps {
|
|
|
13
13
|
* Generic "run/job in progress" card — a status icon + headline, a progress
|
|
14
14
|
* bar (determinate or indeterminate), a primary step list, and an optional
|
|
15
15
|
* secondary item list. Unifies the source `WorkspaceActivityCard` and
|
|
16
|
-
* `GenerationStatusCard` occurrences; see `
|
|
16
|
+
* `GenerationStatusCard` occurrences; see `070311a07^:packages/ui/source-map.md` (section "features/progress-card/") for
|
|
17
17
|
* provenance and what was dropped.
|
|
18
18
|
*/
|
|
19
19
|
export declare function ProgressCard({ data, maxSteps, maxSecondaryItems, useTHook }: ProgressCardProps & {
|
|
@@ -6,7 +6,7 @@ import { Icon } from '../../../react/components/Icon.js';
|
|
|
6
6
|
* Generic "run/job in progress" card — a status icon + headline, a progress
|
|
7
7
|
* bar (determinate or indeterminate), a primary step list, and an optional
|
|
8
8
|
* secondary item list. Unifies the source `WorkspaceActivityCard` and
|
|
9
|
-
* `GenerationStatusCard` occurrences; see `
|
|
9
|
+
* `GenerationStatusCard` occurrences; see `070311a07^:packages/ui/source-map.md` (section "features/progress-card/") for
|
|
10
10
|
* provenance and what was dropped.
|
|
11
11
|
*/
|
|
12
12
|
export function ProgressCard({ data, maxSteps = 6, maxSecondaryItems = 5, useTHook = useT }) {
|
|
@@ -19,7 +19,7 @@ export interface ResourceBoardProps<TItem extends ResourceBoardItem<TBody>, TBod
|
|
|
19
19
|
onOpenItem: (id: string) => void;
|
|
20
20
|
onCreate?: () => void;
|
|
21
21
|
createLabel?: string;
|
|
22
|
-
/** Fired when a kebab menu action with `kind === 'rename'` is clicked — this primitive never collects the new name itself (no `Dialog` is ported, see `
|
|
22
|
+
/** Fired when a kebab menu action with `kind === 'rename'` is clicked — this primitive never collects the new name itself (no `Dialog` is ported, see `070311a07^:packages/ui/source-map.md` (section "features/resource-dashboard/")). */
|
|
23
23
|
onRenameRequest?: (id: string, currentTitle: string) => void;
|
|
24
24
|
/** Fired for any menu action kind other than the three this primitive natively understands (`rename`/`duplicate`/`delete`). */
|
|
25
25
|
onCustomItemAction?: (id: string, kind: string) => void;
|
|
@@ -31,7 +31,7 @@ export interface ResourceBoardToolbarProps {
|
|
|
31
31
|
* DesignsTab's toolbar: sub-tab sort pills + a create button + search +
|
|
32
32
|
* select-mode/bulk-delete bar (grid view only) + the grid/kanban view
|
|
33
33
|
* toggle. The origin's manual-refresh button and 15s auto-refresh polling
|
|
34
|
-
* are deliberately NOT ported — see `
|
|
34
|
+
* are deliberately NOT ported — see `070311a07^:packages/ui/source-map.md` (section "features/resource-dashboard/"), its "Dropped"
|
|
35
35
|
* list; a host wanting that composes its own refresh affordance around the
|
|
36
36
|
* hook's `reload()`.
|
|
37
37
|
*/
|