@theoremjs/react 0.3.0 → 0.3.1
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 +728 -202
- package/client/composer-hints.js +1 -1
- package/client/decision-images.d.ts +76 -0
- package/client/decision-images.js +139 -0
- package/client/decision-transport.d.ts +26 -4
- package/client/decision-transport.js +79 -6
- package/client/embedding-input.d.ts +84 -0
- package/client/embedding-input.js +194 -0
- package/client/embedding-space.d.ts +82 -0
- package/client/embedding-space.js +389 -0
- package/client/embedding-transport.d.ts +40 -0
- package/client/embedding-transport.js +71 -0
- package/client/failure.d.ts +7 -10
- package/client/failure.js +9 -9
- package/client/host-call.d.ts +1 -1
- package/client/host-call.js +7 -2
- package/client/host-transport.d.ts +2 -0
- package/client/host-transport.js +3 -2
- package/client/index.d.ts +19 -11
- package/client/index.js +14 -10
- package/client/ink-waveform.d.ts +1 -1
- package/client/ink-waveform.js +1 -2
- package/client/live/apply-live-turn-tool-event.js +1 -1
- package/client/live/live-captions.d.ts +30 -0
- package/client/live/live-captions.js +105 -1
- package/client/live/live-mic-forward.d.ts +1 -0
- package/client/live/live-mic-forward.js +11 -2
- package/client/live/live-page-tool.d.ts +34 -0
- package/client/live/live-page-tool.js +11 -0
- package/client/live/live-state.d.ts +4 -2
- package/client/live/live-state.js +2 -0
- package/client/live/live-video.js +1 -1
- package/client/live/run-live-tool-call.d.ts +7 -2
- package/client/live/run-live-tool-call.js +48 -10
- package/client/live/use-live-caption-log.d.ts +17 -0
- package/client/live/use-live-caption-log.js +51 -0
- package/client/live-client.d.ts +52 -4
- package/client/live-client.js +250 -59
- package/client/live-messages.d.ts +51 -13
- package/client/live-messages.js +42 -9
- package/client/page-dispatch.d.ts +15 -0
- package/client/page-dispatch.js +63 -0
- package/client/run-commit.d.ts +16 -43
- package/client/run-commit.js +26 -101
- package/client/run-session.d.ts +40 -41
- package/client/run-session.js +104 -112
- package/client/schema-fields.js +27 -6
- package/client/shaped-data.js +37 -8
- package/client/source-citations.js +1 -1
- package/client/space-geometry.d.ts +39 -0
- package/client/space-geometry.js +183 -0
- package/client/state-fields.js +1 -1
- package/client/tool-result.js +30 -12
- package/client/tool-resume.d.ts +18 -1
- package/client/tool-resume.js +4 -1
- package/client/trace-feed.d.ts +1 -1
- package/client/trace-story.d.ts +2 -2
- package/client/trace-story.js +43 -19
- package/client/trace-view.d.ts +2 -2
- package/client/trace-view.js +56 -16
- package/client/transcript-groups.d.ts +28 -2
- package/client/transcript-groups.js +63 -13
- package/client/transcript-schema.d.ts +10 -0
- package/client/transcript-schema.js +120 -0
- package/client/transport.d.ts +114 -26
- package/client/transport.js +106 -32
- package/client/turn-client.d.ts +17 -8
- package/client/turn-client.js +26 -31
- package/client/voice-recorder.d.ts +1 -1
- package/client/voice-recorder.js +2 -5
- package/client/wire-line.js +5 -5
- package/client/worklets/mic-capture.js +9 -9
- package/components/InkWaveform.d.ts +12 -1
- package/components/InkWaveform.js +65 -42
- package/components/live/use-live-runner-controls.d.ts +3 -4
- package/components/live/use-live-runner-controls.js +6 -10
- package/components/live/use-live-runner-model.d.ts +10 -6
- package/components/live/use-live-runner-model.js +29 -14
- package/components/live/use-live-runner-ui.d.ts +10 -8
- package/components/live/use-live-runner-ui.js +19 -11
- package/components/live/use-live-session-client.d.ts +4 -4
- package/components/live/use-live-session-client.js +11 -8
- package/components/use-composer-voice.d.ts +4 -4
- package/components/use-composer-voice.js +8 -8
- package/components/use-editor-selection.js +4 -1
- package/components/use-voice-playback.d.ts +2 -1
- package/components/use-voice-playback.js +4 -4
- package/hooks/use-described.d.ts +5 -1
- package/hooks/use-described.js +11 -9
- package/hooks/use-embedding-index.d.ts +27 -0
- package/hooks/use-embedding-index.js +43 -0
- package/hooks/use-one-call.d.ts +31 -0
- package/hooks/use-one-call.js +76 -0
- package/hooks/use-page-tool-warnings.d.ts +6 -0
- package/hooks/use-page-tool-warnings.js +25 -0
- package/hooks/use-second-ticker.d.ts +2 -0
- package/hooks/use-second-ticker.js +13 -0
- package/hooks/use-theorem-chat-actions.d.ts +25 -21
- package/hooks/use-theorem-chat-actions.js +67 -45
- package/hooks/use-theorem-chat-state.d.ts +6 -6
- package/hooks/use-theorem-chat-state.js +13 -9
- package/hooks/use-theorem-chat.d.ts +48 -14
- package/hooks/use-theorem-chat.js +329 -141
- package/hooks/use-theorem-decision.d.ts +5 -10
- package/hooks/use-theorem-decision.js +4 -67
- package/hooks/use-theorem-embedding.d.ts +18 -0
- package/hooks/use-theorem-embedding.js +12 -0
- package/hooks/use-theorem-host.d.ts +5 -4
- package/hooks/use-theorem-host.js +26 -8
- package/hooks/use-theorem-interface.d.ts +6 -3
- package/hooks/use-theorem-interface.js +12 -22
- package/index.d.ts +6 -3
- package/index.js +5 -2
- package/live.d.ts +1 -0
- package/live.js +1 -1
- package/package.json +6 -5
- package/server/checkpoint-ownership.d.ts +6 -0
- package/server/checkpoint-ownership.js +42 -0
- package/server/conversation-store.d.ts +92 -0
- package/server/conversation-store.js +131 -0
- package/server/conversation.d.ts +193 -0
- package/server/conversation.js +552 -0
- package/server/decision-handler.d.ts +12 -4
- package/server/decision-handler.js +29 -38
- package/server/embedding-handler.d.ts +33 -0
- package/server/embedding-handler.js +45 -0
- package/server/handler.d.ts +58 -20
- package/server/handler.js +441 -238
- package/server/mod.d.ts +15 -6
- package/server/mod.js +13 -5
- package/server/page-dispatch.d.ts +22 -0
- package/server/page-dispatch.js +127 -0
- package/server/request-body.d.ts +2 -0
- package/server/request-body.js +42 -0
- package/server/request-check.d.ts +6 -1
- package/server/request-check.js +27 -12
- package/server/session-authority.d.ts +8 -0
- package/server/session-authority.js +78 -0
- package/server/session-boundary.d.ts +26 -0
- package/server/session-boundary.js +64 -0
- package/server/session-identity.d.ts +16 -0
- package/server/session-identity.js +41 -0
- package/server/session-limits.d.ts +12 -0
- package/server/session-limits.js +59 -0
- package/server/session-store.d.ts +69 -20
- package/server/session-store.js +220 -5
- package/server/single-action.d.ts +21 -0
- package/server/single-action.js +30 -0
- package/server/steer-inbox.js +1 -1
- package/server/tool-operations.d.ts +6 -0
- package/server/tool-operations.js +132 -0
- package/server/turn-input.d.ts +10 -0
- package/server/turn-input.js +29 -0
- package/styles/ink-controls.css +78 -78
- package/ui/CardWall.d.ts +10 -0
- package/ui/CardWall.js +61 -0
- package/ui/ChatComposerBar.d.ts +28 -5
- package/ui/ChatComposerBar.js +85 -30
- package/ui/ChatTranscript.d.ts +14 -1
- package/ui/ChatTranscript.js +110 -57
- package/ui/ConsoleFrame.d.ts +61 -4
- package/ui/ConsoleFrame.js +109 -9
- package/ui/DecisionAnswers.d.ts +40 -2
- package/ui/DecisionAnswers.js +166 -35
- package/ui/DecisionImages.d.ts +16 -0
- package/ui/DecisionImages.js +46 -0
- package/ui/EmbeddingDocuments.d.ts +78 -0
- package/ui/EmbeddingDocuments.js +278 -0
- package/ui/EmbeddingQuery.d.ts +27 -0
- package/ui/EmbeddingQuery.js +95 -0
- package/ui/EmbeddingResults.d.ts +41 -0
- package/ui/EmbeddingResults.js +165 -0
- package/ui/EmbeddingSpace.d.ts +26 -0
- package/ui/EmbeddingSpace.js +106 -0
- package/ui/LiveCaptionsPanel.d.ts +22 -0
- package/ui/LiveCaptionsPanel.js +27 -0
- package/ui/LiveRunner.d.ts +6 -4
- package/ui/LiveRunner.js +42 -55
- package/ui/PaneState.d.ts +33 -0
- package/ui/PaneState.js +50 -0
- package/ui/SchemaFields.d.ts +1 -1
- package/ui/SchemaFields.js +54 -26
- package/ui/ShapedData.js +73 -28
- package/ui/SidePanel.d.ts +74 -5
- package/ui/SidePanel.js +82 -9
- package/ui/StateFields.d.ts +10 -2
- package/ui/StateFields.js +56 -13
- package/ui/TheoremChat.d.ts +65 -14
- package/ui/TheoremChat.js +66 -78
- package/ui/TheoremDecision.d.ts +12 -20
- package/ui/TheoremDecision.js +78 -35
- package/ui/TheoremEmbedding.d.ts +27 -0
- package/ui/TheoremEmbedding.js +122 -0
- package/ui/TheoremHost.d.ts +22 -5
- package/ui/TheoremHost.js +127 -37
- package/ui/ToolGateCard.d.ts +5 -1
- package/ui/ToolGateCard.js +30 -23
- package/ui/ToolResult.js +12 -10
- package/ui/ToolResultCharts.js +29 -12
- package/ui/TraceCharts.d.ts +2 -2
- package/ui/TraceCharts.js +48 -17
- package/ui/TraceGuardrails.d.ts +3 -2
- package/ui/TraceGuardrails.js +24 -6
- package/ui/TraceInspector.d.ts +11 -1
- package/ui/TraceInspector.js +45 -28
- package/ui/TraceInspectorPanel.d.ts +31 -9
- package/ui/TraceInspectorPanel.js +77 -39
- package/ui/TraceOverview.d.ts +7 -3
- package/ui/TraceOverview.js +44 -14
- package/ui/TraceSpanDetail.js +24 -22
- package/ui/TraceStory.js +9 -8
- package/ui/TraceValues.js +19 -9
- package/ui/TraceWaterfall.js +12 -9
- package/ui/VoiceNote.js +4 -4
- package/ui/approval-heading.d.ts +4 -0
- package/ui/approval-heading.js +9 -0
- package/ui/arrive.d.ts +18 -0
- package/ui/arrive.js +46 -0
- package/ui/built/theme.css +86 -68
- package/ui/built/theme.css.d.ts +9 -0
- package/ui/built/theorem.d.ts +3 -3
- package/ui/built/theorem.js +34 -5
- package/ui/built/theorem.variants.d.ts +8 -2
- package/ui/code-language.d.ts +12 -0
- package/ui/code-language.js +50 -0
- package/ui/disclosure-motion.js +53 -9
- package/ui/embedding-space-gl.d.ts +37 -0
- package/ui/embedding-space-gl.js +663 -0
- package/ui/embedding-space-view.d.ts +8 -0
- package/ui/embedding-space-view.js +8 -0
- package/ui/glide.d.ts +7 -0
- package/ui/glide.js +44 -0
- package/ui/icons.js +2 -1
- package/ui/index.d.ts +20 -9
- package/ui/index.js +20 -10
- package/ui/labels-provider.js +5 -2
- package/ui/labels.d.ts +374 -85
- package/ui/labels.js +1028 -188
- package/ui/markdown-plugins.d.ts +9 -0
- package/ui/markdown-plugins.js +13 -0
- package/ui/mcp-icon.d.ts +6 -0
- package/ui/mcp-icon.js +8 -0
- package/ui/row-keys.d.ts +19 -0
- package/ui/row-keys.js +33 -0
- package/ui/theme.d.ts +1 -1
- package/ui/theme.js +2 -2
- package/ui/theorem-theme.js +32 -10
- package/ui/trace-palette.d.ts +2 -16
- package/ui/trace-palette.js +2 -16
- package/ui/trace-patterns.d.ts +11 -3
- package/ui/trace-patterns.js +16 -3
- package/ui/transcript-copy-text.js +1 -0
- package/ui/wall-columns.d.ts +8 -0
- package/ui/wall-columns.js +19 -0
- package/client/walk-away.d.ts +0 -34
- package/client/walk-away.js +0 -48
- package/server/walk-away.d.ts +0 -22
- package/server/walk-away.js +0 -41
package/ui/glide.js
ADDED
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { useLayoutEffect, useRef } from 'react';
|
|
2
|
+
/** Reads an Astryx duration token ("410ms" / "0.4s") as milliseconds. */
|
|
3
|
+
function tokenMs(value, fallback) {
|
|
4
|
+
const n = Number.parseFloat(value);
|
|
5
|
+
if (Number.isNaN(n))
|
|
6
|
+
return fallback;
|
|
7
|
+
return value.trim().endsWith('ms') ? n : n * 1_000;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Eases an element from where it sat while `held` to where it lands once `held`
|
|
11
|
+
* turns false (FLIP). Astryx has no layout-transition helper, so this uses its
|
|
12
|
+
* `--duration-medium` / `--ease-standard` tokens. `onLand` runs as it lands.
|
|
13
|
+
*/
|
|
14
|
+
export function useGlide(held, onLand) {
|
|
15
|
+
const ref = useRef(null);
|
|
16
|
+
const heldTop = useRef(null);
|
|
17
|
+
useLayoutEffect(() => {
|
|
18
|
+
const el = ref.current;
|
|
19
|
+
if (!el)
|
|
20
|
+
return;
|
|
21
|
+
if (held) {
|
|
22
|
+
heldTop.current = el.getBoundingClientRect().top;
|
|
23
|
+
return;
|
|
24
|
+
}
|
|
25
|
+
const from = heldTop.current;
|
|
26
|
+
if (from === null)
|
|
27
|
+
return;
|
|
28
|
+
heldTop.current = null;
|
|
29
|
+
onLand?.();
|
|
30
|
+
glideFrom(el, from);
|
|
31
|
+
});
|
|
32
|
+
return ref;
|
|
33
|
+
}
|
|
34
|
+
/** Slides `el` from where it was held, `from`, to where it now sits, unless motion is reduced. */
|
|
35
|
+
function glideFrom(el, from) {
|
|
36
|
+
const delta = from - el.getBoundingClientRect().top;
|
|
37
|
+
if (delta === 0 || globalThis.matchMedia?.('(prefers-reduced-motion: reduce)').matches)
|
|
38
|
+
return;
|
|
39
|
+
const tokens = getComputedStyle(el);
|
|
40
|
+
el.animate([{ transform: `translateY(${String(delta)}px)` }, { transform: 'none' }], {
|
|
41
|
+
duration: tokenMs(tokens.getPropertyValue('--duration-medium'), 410),
|
|
42
|
+
easing: tokens.getPropertyValue('--ease-standard').trim() || 'ease-out',
|
|
43
|
+
});
|
|
44
|
+
}
|
package/ui/icons.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IconAlertTriangle, IconArrowDown, IconArrowsSort, IconArrowUp, IconCalendar, IconCheck, IconChecks, IconChevronDown, IconChevronLeft, IconChevronRight, IconChevronsLeft, IconChevronsRight, IconCircleCheck, IconCircleX, IconClock, IconColumns, IconCopy, IconDots, IconExternalLink, IconEyeOff, IconFilter, IconInfoCircle, IconMenu2, IconMicrophone, IconPlayerStopFilled, IconSearch, IconTool, IconX, } from '@tabler/icons-react';
|
|
1
|
+
import { IconAlertTriangle, IconArrowDown, IconArrowsSort, IconArrowUp, IconCalendar, IconCheck, IconChecks, IconChevronDown, IconChevronLeft, IconChevronRight, IconChevronsLeft, IconChevronsRight, IconCircleCheck, IconCircleX, IconClock, IconColumns, IconCopy, IconDots, IconExternalLink, IconEyeOff, IconFilter, IconInfoCircle, IconMenu2, IconMicrophone, IconPlayerStopFilled, IconSearch, IconTool, IconUpload, IconX, } from '@tabler/icons-react';
|
|
2
2
|
import { createElement } from 'react';
|
|
3
3
|
const TABLER_BY_NAME = {
|
|
4
4
|
close: IconX,
|
|
@@ -29,6 +29,7 @@ const TABLER_BY_NAME = {
|
|
|
29
29
|
wrench: IconTool,
|
|
30
30
|
stop: IconPlayerStopFilled,
|
|
31
31
|
microphone: IconMicrophone,
|
|
32
|
+
upload: IconUpload,
|
|
32
33
|
};
|
|
33
34
|
/** Astryx semantic icon registry drawn from Tabler (replaces neutral's lucide set). */
|
|
34
35
|
export const tablerIcons = Object.fromEntries(Object.entries(TABLER_BY_NAME).map(([name, Glyph]) => [
|
package/ui/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Astryx UI for Theorem — `<TheoremChat />` plus the pieces it is built from,
|
|
3
|
-
* `<TheoremDecision />` for decision profiles,
|
|
4
|
-
* profiles.
|
|
3
|
+
* `<TheoremDecision />` for decision profiles, `<TheoremEmbedding />` for
|
|
4
|
+
* embedding profiles, and `<TheoremHost />` for host profiles.
|
|
5
5
|
*
|
|
6
6
|
* Styling is Astryx: pass `theme` (any `defineTheme` result, e.g. one that
|
|
7
7
|
* `extends: theoremTheme`) or wrap your app in your own `<Theme>`.
|
|
@@ -9,17 +9,28 @@
|
|
|
9
9
|
* @module
|
|
10
10
|
*/
|
|
11
11
|
export type { InkWaveStatus } from '../client/ink-waveform.ts';
|
|
12
|
-
export {
|
|
13
|
-
export {
|
|
12
|
+
export type { LiveCallOptions, PageTool, PageToolAnswer, PageTools, } from '../client/live/live-page-tool.ts';
|
|
13
|
+
export { useLiveCaptionLog } from '../client/live/use-live-caption-log.ts';
|
|
14
|
+
export { InkWaveform, type InkWaveformProps, type InkWaveLevels, } from '../components/InkWaveform.tsx';
|
|
15
|
+
export { useLiveRunnerModel } from '../components/live/use-live-runner-model.ts';
|
|
16
|
+
export { theoremTheme } from './built/theorem.js';
|
|
17
|
+
export { ChatComposerBar, type ChatComposerBarProps, EFFORT_ICON, type LiveComposerBarProps, } from './ChatComposerBar.tsx';
|
|
14
18
|
export { ChatTranscript, type ChatTranscriptProps } from './ChatTranscript.tsx';
|
|
19
|
+
export { ConsoleFrame, type ConsoleFrameProps, type ConsolePageProps, RequestCard, ResponseColumn, RunBar, useBytes, } from './ConsoleFrame.tsx';
|
|
15
20
|
export { TheoremDecisionAnswers, type TheoremDecisionAnswersProps } from './DecisionAnswers.tsx';
|
|
21
|
+
export { useDisclosureMotion } from './disclosure-motion.ts';
|
|
22
|
+
export { EmbeddingSpaceView, type EmbeddingSpaceViewProps } from './EmbeddingSpace.tsx';
|
|
23
|
+
export { tablerIcons } from './icons.ts';
|
|
24
|
+
export { LiveCaptionsPanel, type LiveCaptionsPanelProps } from './LiveCaptionsPanel.tsx';
|
|
25
|
+
export { composerDrawerLabel, type LabelText, liveStateLabel, THEOREM_UI_CATALOG, type TheoremLabelKey, type TheoremLabelOverrides, type TheoremLabels, type TheoremLabelValues, type TheoremUiCatalog, voiceNoteName, workStatusLabel, } from './labels.ts';
|
|
26
|
+
export { TheoremLabelsProvider, type TheoremLabelsProviderProps, useLabels, } from './labels-provider.tsx';
|
|
27
|
+
export { PaneFailure, PaneLoading, PaneState } from './PaneState.tsx';
|
|
28
|
+
export { InPlace, PaneLayout, PanePanel, Prose, RaisedPane } from './SidePanel.tsx';
|
|
29
|
+
export { DEFAULT_CHAT_MAX_WIDTH, TheoremChat, type TheoremChatHandle, type TheoremChatProps, } from './TheoremChat.tsx';
|
|
16
30
|
export { TheoremDecision, type TheoremDecisionProps } from './TheoremDecision.tsx';
|
|
31
|
+
export { TheoremEmbedding, type TheoremEmbeddingProps } from './TheoremEmbedding.tsx';
|
|
17
32
|
export { TheoremHost, type TheoremHostProps } from './TheoremHost.tsx';
|
|
18
|
-
export { DEFAULT_CHAT_MAX_WIDTH, TheoremChat, type TheoremChatHandle, type TheoremChatProps, } from './TheoremChat.tsx';
|
|
19
33
|
export { ApprovalCard, type ApprovalCardProps, AuthChallengeCard, type AuthChallengeCardProps, type ToolDecision, } from './ToolGateCard.tsx';
|
|
20
34
|
export { ToolResult } from './ToolResult.tsx';
|
|
21
|
-
export {
|
|
22
|
-
export { useDisclosureMotion } from './disclosure-motion.ts';
|
|
23
|
-
export { composerDrawerLabel, type LabelText, liveStateLabel, THEOREM_UI_CATALOG, type TheoremLabelKey, type TheoremLabelOverrides, type TheoremLabels, type TheoremLabelValues, type TheoremUiCatalog, voiceNoteName, workStatusLabel, } from './labels.ts';
|
|
24
|
-
export { TheoremLabelsProvider, type TheoremLabelsProviderProps, useLabels } from './labels-provider.tsx';
|
|
35
|
+
export { TraceGuardrailsView, TracePlacement, useTraceInspector } from './TraceInspectorPanel.tsx';
|
|
25
36
|
export { TheoremThemeProvider, type TheoremThemeProviderProps } from './theme.tsx';
|
package/ui/index.js
CHANGED
|
@@ -1,29 +1,39 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Astryx UI for Theorem — `<TheoremChat />` plus the pieces it is built from,
|
|
3
|
-
* `<TheoremDecision />` for decision profiles,
|
|
4
|
-
* profiles.
|
|
3
|
+
* `<TheoremDecision />` for decision profiles, `<TheoremEmbedding />` for
|
|
4
|
+
* embedding profiles, and `<TheoremHost />` for host profiles.
|
|
5
5
|
*
|
|
6
6
|
* Styling is Astryx: pass `theme` (any `defineTheme` result, e.g. one that
|
|
7
7
|
* `extends: theoremTheme`) or wrap your app in your own `<Theme>`.
|
|
8
8
|
*
|
|
9
9
|
* @module
|
|
10
10
|
*/
|
|
11
|
-
// Astryx's documented order: reset → components → theme. The reset lives in
|
|
11
|
+
// why: Astryx's documented order: reset → components → theme. The reset lives in
|
|
12
12
|
// `@layer reset`, so any unlayered host CSS still wins over it.
|
|
13
13
|
import '@astryxdesign/core/reset.css';
|
|
14
14
|
import '@astryxdesign/core/astryx.css';
|
|
15
15
|
import './built/theme.css';
|
|
16
|
-
export {
|
|
17
|
-
export {
|
|
16
|
+
export { useLiveCaptionLog } from "../client/live/use-live-caption-log.js";
|
|
17
|
+
export { InkWaveform, } from "../components/InkWaveform.js";
|
|
18
|
+
export { useLiveRunnerModel } from "../components/live/use-live-runner-model.js";
|
|
19
|
+
export { theoremTheme } from './built/theorem.js';
|
|
20
|
+
export { ChatComposerBar, EFFORT_ICON, } from "./ChatComposerBar.js";
|
|
18
21
|
export { ChatTranscript } from "./ChatTranscript.js";
|
|
22
|
+
export { ConsoleFrame, RequestCard, ResponseColumn, RunBar, useBytes, } from "./ConsoleFrame.js";
|
|
19
23
|
export { TheoremDecisionAnswers } from "./DecisionAnswers.js";
|
|
24
|
+
export { useDisclosureMotion } from "./disclosure-motion.js";
|
|
25
|
+
export { EmbeddingSpaceView } from "./EmbeddingSpace.js";
|
|
26
|
+
export { tablerIcons } from "./icons.js";
|
|
27
|
+
export { LiveCaptionsPanel } from "./LiveCaptionsPanel.js";
|
|
28
|
+
export { composerDrawerLabel, liveStateLabel, THEOREM_UI_CATALOG, voiceNoteName, workStatusLabel, } from "./labels.js";
|
|
29
|
+
export { TheoremLabelsProvider, useLabels, } from "./labels-provider.js";
|
|
30
|
+
export { PaneFailure, PaneLoading, PaneState } from "./PaneState.js";
|
|
31
|
+
export { InPlace, PaneLayout, PanePanel, Prose, RaisedPane } from "./SidePanel.js";
|
|
32
|
+
export { DEFAULT_CHAT_MAX_WIDTH, TheoremChat, } from "./TheoremChat.js";
|
|
20
33
|
export { TheoremDecision } from "./TheoremDecision.js";
|
|
34
|
+
export { TheoremEmbedding } from "./TheoremEmbedding.js";
|
|
21
35
|
export { TheoremHost } from "./TheoremHost.js";
|
|
22
|
-
export { DEFAULT_CHAT_MAX_WIDTH, TheoremChat, } from "./TheoremChat.js";
|
|
23
36
|
export { ApprovalCard, AuthChallengeCard, } from "./ToolGateCard.js";
|
|
24
37
|
export { ToolResult } from "./ToolResult.js";
|
|
25
|
-
export {
|
|
26
|
-
export { useDisclosureMotion } from "./disclosure-motion.js";
|
|
27
|
-
export { composerDrawerLabel, liveStateLabel, THEOREM_UI_CATALOG, voiceNoteName, workStatusLabel, } from "./labels.js";
|
|
28
|
-
export { TheoremLabelsProvider, useLabels } from "./labels-provider.js";
|
|
38
|
+
export { TraceGuardrailsView, TracePlacement, useTraceInspector } from "./TraceInspectorPanel.js";
|
|
29
39
|
export { TheoremThemeProvider } from "./theme.js";
|
package/ui/labels-provider.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Fragment as _Fragment, jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { InternationalizationContext, InternationalizationProvider, useTranslator, } from '@astryxdesign/core/i18n';
|
|
3
3
|
import { use, useMemo } from 'react';
|
|
4
|
-
import { assertLabelOverrides, THEOREM_UI_CATALOG } from "./labels.js";
|
|
4
|
+
import { assertLabelOverrides, THEOREM_UI_CATALOG, } from "./labels.js";
|
|
5
5
|
/** Message tables this module built, by the base language their catalog sits under. */
|
|
6
6
|
const WITH_CATALOG = new WeakMap();
|
|
7
7
|
/** `en-GB` → `en`: the last step of Astryx's locale fallback chain. */
|
|
@@ -22,7 +22,10 @@ function withCatalog(messages, locale) {
|
|
|
22
22
|
const base = baseLanguage(locale);
|
|
23
23
|
if (WITH_CATALOG.get(messages) === base)
|
|
24
24
|
return messages;
|
|
25
|
-
const next = {
|
|
25
|
+
const next = {
|
|
26
|
+
...messages,
|
|
27
|
+
[base]: { ...THEOREM_UI_CATALOG, ...messages[base] },
|
|
28
|
+
};
|
|
26
29
|
WITH_CATALOG.set(next, base);
|
|
27
30
|
return next;
|
|
28
31
|
}
|