@aceshooting/lyra-ui 23.0.0 → 24.0.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/CHANGELOG.md +9 -43
- package/README.md +72 -35
- package/custom-elements.json +1 -1
- package/design-tokens.json +1 -1
- package/dist/cli/lyra-rename-ledger.mjs +1 -1
- package/dist/cli/migration-contract.json +1 -1
- package/dist/cli/migration-contract.mjs +1 -1
- package/dist/cli/migration-renames.mjs +2 -2
- package/dist/cli/migration-transforms.mjs +2 -2
- package/dist/components/agent-tools/approval-queue/approval-queue.class.d.ts +1 -4
- package/dist/components/agent-tools/approval-queue/approval-queue.class.js +1 -3
- package/dist/components/agent-tools/compare-panel/compare-panel.class.d.ts +1 -4
- package/dist/components/agent-tools/compare-panel/compare-panel.class.js +1 -1
- package/dist/components/agent-tools/confirm-bar/confirm-bar.class.d.ts +1 -7
- package/dist/components/agent-tools/confirm-bar/confirm-bar.class.js +2 -2
- package/dist/components/agent-tools/context-inspector/context-inspector.class.d.ts +1 -1
- package/dist/components/agent-tools/evaluation-run/evaluation-run.class.d.ts +2 -5
- package/dist/components/agent-tools/evaluation-run/evaluation-run.class.js +1 -3
- package/dist/components/agent-tools/terminal/terminal.class.d.ts +1 -4
- package/dist/components/agent-tools/terminal/terminal.class.js +2 -2
- package/dist/components/agent-tools/tool-approval-dialog/tool-approval-dialog.class.d.ts +1 -7
- package/dist/components/agent-tools/tool-approval-dialog/tool-approval-dialog.class.js +1 -1
- package/dist/components/agent-tools/tool-timeline/tool-timeline.class.d.ts +1 -4
- package/dist/components/agent-tools/tool-timeline/tool-timeline.class.js +1 -3
- package/dist/components/charts/chart/lite-chart-axis-layout.d.ts +13 -0
- package/dist/components/charts/chart/lite-chart-axis-layout.js +1 -0
- package/dist/components/charts/chart/lite-chart.class.d.ts +1 -11
- package/dist/components/charts/chart/lite-chart.class.js +4 -4
- package/dist/components/conversation/agent-workspace/agent-workspace.class.d.ts +2 -2
- package/dist/components/conversation/agent-workspace/agent-workspace.class.js +0 -1
- package/dist/components/conversation/chat-message/chat-message.class.d.ts +3 -9
- package/dist/components/conversation/chat-message/chat-message.class.js +1 -1
- package/dist/components/conversation/code-block/code-block-base.class.js +1 -1
- package/dist/components/conversation/code-block/code-block-core.class.d.ts +6 -8
- package/dist/components/conversation/code-block/code-block-shared.d.ts +1 -4
- package/dist/components/conversation/code-block/code-block.class.d.ts +4 -6
- package/dist/components/conversation/markdown/markdown-base.class.d.ts +1 -3
- package/dist/components/conversation/markdown/markdown-base.class.js +1 -1
- package/dist/components/conversation/markdown/markdown-core.class.d.ts +1 -4
- package/dist/components/conversation/markdown/markdown.class.d.ts +1 -4
- package/dist/components/conversation/message-actions/message-actions.class.d.ts +1 -4
- package/dist/components/conversation/message-actions/message-actions.class.js +1 -1
- package/dist/components/conversation/message-feedback/message-feedback.class.d.ts +1 -4
- package/dist/components/conversation/message-feedback/message-feedback.class.js +2 -2
- package/dist/components/conversation/message-parts/message-parts.class.d.ts +2 -5
- package/dist/components/conversation/message-parts/message-parts.class.js +3 -3
- package/dist/components/conversation/streaming-text/streaming-text-base.class.d.ts +1 -1
- package/dist/components/conversation/streaming-text/streaming-text-core.class.d.ts +2 -0
- package/dist/components/conversation/streaming-text/streaming-text-core.class.js +0 -1
- package/dist/components/conversation/streaming-text/streaming-text.class.d.ts +2 -0
- package/dist/components/conversation/streaming-text/streaming-text.class.js +0 -1
- package/dist/components/conversation/thread-list/thread-list.class.d.ts +6 -17
- package/dist/components/conversation/thread-list/thread-list.class.js +6 -6
- package/dist/components/data/context-meter/context-meter.class.d.ts +1 -6
- package/dist/components/data/context-meter/context-meter.class.js +1 -1
- package/dist/components/data/data-grid/data-grid.class.d.ts +0 -1
- package/dist/components/data/data-grid/data-grid.class.js +2 -2
- package/dist/components/data/document-library/document-library.class.d.ts +6 -13
- package/dist/components/data/document-library/document-library.class.js +1 -2
- package/dist/components/data/heatmap/heatmap-grid-navigation.d.ts +7 -0
- package/dist/components/data/heatmap/heatmap-grid-navigation.js +1 -0
- package/dist/components/data/heatmap/heatmap.class.d.ts +3 -23
- package/dist/components/data/heatmap/heatmap.class.js +2 -2
- package/dist/components/data/sequence-strip/sequence-strip.class.d.ts +3 -9
- package/dist/components/data/sequence-strip/sequence-strip.class.js +3 -3
- package/dist/components/data/table/table.class.d.ts +5 -14
- package/dist/components/data/table/table.class.js +6 -6
- package/dist/components/forms/button/button.class.d.ts +2 -2
- package/dist/components/forms/button/button.class.js +9 -9
- package/dist/components/forms/combobox/combobox.class.d.ts +1 -4
- package/dist/components/forms/combobox/combobox.class.js +2 -2
- package/dist/components/forms/input/time-input.class.d.ts +1 -1
- package/dist/components/forms/input/time-input.class.js +1 -1
- package/dist/components/forms/select/select.class.d.ts +1 -2
- package/dist/components/layout/app-rail/app-rail-item.class.d.ts +3 -6
- package/dist/components/layout/app-rail/app-rail-item.class.js +1 -1
- package/dist/components/layout/app-rail/app-rail.class.d.ts +2 -4
- package/dist/components/layout/app-rail/app-rail.class.js +1 -1
- package/dist/components/layout/app-rail-group/app-rail-group.class.d.ts +2 -6
- package/dist/components/layout/app-rail-group/app-rail-group.class.js +1 -1
- package/dist/components/layout/carousel/carousel.class.d.ts +1 -4
- package/dist/components/layout/carousel/carousel.class.js +2 -2
- package/dist/components/layout/command-palette/command-palette.class.js +1 -1
- package/dist/components/layout/details/details.class.d.ts +2 -4
- package/dist/components/layout/details/details.class.js +1 -1
- package/dist/components/layout/dock-panel/dock-panel.class.d.ts +3 -7
- package/dist/components/layout/dock-panel/dock-panel.class.js +1 -1
- package/dist/components/layout/menu/menu.class.js +1 -1
- package/dist/components/layout/multi-split/multi-split.class.d.ts +2 -4
- package/dist/components/layout/multi-split/multi-split.class.js +1 -1
- package/dist/components/layout/navigation-menu-item/navigation-menu-item.class.d.ts +2 -4
- package/dist/components/layout/navigation-menu-item/navigation-menu-item.class.js +1 -1
- package/dist/components/layout/reorder-list/reorder-item.class.d.ts +1 -4
- package/dist/components/layout/reorder-list/reorder-item.class.js +2 -2
- package/dist/components/media/attachment-trigger/attachment-trigger.class.d.ts +5 -9
- package/dist/components/media/attachment-trigger/attachment-trigger.class.js +5 -5
- package/dist/components/media/av-player/av-player.class.js +3 -3
- package/dist/components/media/file-input/file-input.class.d.ts +3 -6
- package/dist/components/media/file-input/file-input.class.js +3 -3
- package/dist/components/media/lightbox/lightbox.class.d.ts +11 -20
- package/dist/components/media/lightbox/lightbox.class.js +1 -1
- package/dist/components/media/map/map-data-layers.d.ts +20 -0
- package/dist/components/media/map/map-data-layers.js +1 -0
- package/dist/components/media/map/map.class.js +3 -3
- package/dist/components/media/media-time.d.ts +2 -0
- package/dist/components/media/media-time.js +1 -0
- package/dist/components/media/video/video.class.js +5 -5
- package/dist/components/media/video-playlist/video-playlist.class.js +2 -2
- package/dist/components/overlays/callout/callout.class.d.ts +2 -5
- package/dist/components/overlays/callout/callout.class.js +2 -2
- package/dist/components/overlays/dialog/dialog.class.d.ts +4 -7
- package/dist/components/overlays/dialog/dialog.class.js +2 -2
- package/dist/components/overlays/overlay/dropdown.class.d.ts +5 -10
- package/dist/components/overlays/overlay/dropdown.class.js +2 -2
- package/dist/components/overlays/overlay/popover.class.d.ts +2 -3
- package/dist/components/overlays/popup/popup.class.js +1 -1
- package/dist/components/overlays/progress/progress-bar.class.d.ts +1 -4
- package/dist/components/overlays/progress/progress-bar.class.js +2 -2
- package/dist/components/overlays/progress/progress-ring.class.d.ts +1 -4
- package/dist/components/overlays/progress/progress-ring.class.js +2 -2
- package/dist/components/overlays/progress/progress-shared.d.ts +3 -3
- package/dist/components/overlays/progress/progress-shared.js +1 -1
- package/dist/components/overlays/toast/toast-item.class.js +1 -1
- package/dist/components/retrieval/graph/graph.class.d.ts +5 -10
- package/dist/components/retrieval/graph/graph.class.js +1 -1
- package/dist/components/retrieval/knowledge-base/knowledge-base.class.d.ts +7 -14
- package/dist/components/retrieval/knowledge-base/knowledge-base.class.js +2 -3
- package/dist/components/retrieval/knowledge-graph-explorer/knowledge-graph-explorer.class.d.ts +2 -8
- package/dist/components/retrieval/memory-panel/memory-panel.class.js +0 -4
- package/dist/components/retrieval/rag-answer/rag-answer.class.js +1 -1
- package/dist/components/utility/export-button/export-button.class.d.ts +6 -10
- package/dist/components/utility/export-button/export-button.class.js +1 -1
- package/dist/components/utility/mention-popover/mention-popover.class.js +1 -1
- package/dist/components/viewers/geojson-view/geojson-view.class.d.ts +1 -1
- package/dist/components/viewers/highlight-layer/highlight-layer-timing.js +1 -1
- package/dist/components/viewers/pdf-viewer/pdf-viewer.class.js +4 -4
- package/dist/events.d.ts +17 -78
- package/dist/framework-types.d.ts +1 -1
- package/dist/internal/catalog-picker.js +1 -1
- package/dist/internal/css-motion-time.d.ts +7 -0
- package/dist/internal/css-motion-time.js +1 -0
- package/dist/internal/data-state-renderer.d.ts +1 -3
- package/dist/internal/data-state-renderer.js +1 -1
- package/dist/internal/localization-runtime.d.ts +2 -0
- package/dist/internal/localization-runtime.js +1 -1
- package/dist/internal/lyra-element.js +2 -2
- package/dist/internal/package-metadata.d.ts +1 -1
- package/dist/internal/package-metadata.js +1 -1
- package/dist/looks/data.css +1 -1
- package/dist/looks/terminal.css +1 -1
- package/dist/lyra.d.ts +1 -592
- package/dist/lyra.js +1 -1
- package/dist/testing/event-factory.d.ts +2 -2
- package/dist/testing/interaction-drivers.d.ts +5 -3
- package/dist/testing/lyra-tag-event-map.js +1 -1
- package/dist/theme/looks/data.d.ts +1 -1
- package/dist/theme/looks/data.js +1 -1
- package/dist/theme/looks/terminal.d.ts +1 -1
- package/dist/theme/looks/terminal.js +1 -1
- package/dist/theme/theme.d.ts +2 -80
- package/dist/theme/theme.js +1 -1
- package/llms/components/lr-agent-workspace.md +1 -1
- package/llms/components/lr-alert.md +1 -1
- package/llms/components/lr-animation.md +1 -1
- package/llms/components/lr-app-rail.md +8 -10
- package/llms/components/lr-approval-queue.md +2 -4
- package/llms/components/lr-attachment-trigger.md +3 -4
- package/llms/components/lr-badge.md +2 -2
- package/llms/components/lr-button.md +45 -99
- package/llms/components/lr-callout.md +3 -4
- package/llms/components/lr-carousel.md +3 -5
- package/llms/components/lr-chat-message.md +1 -2
- package/llms/components/lr-claim-evidence.md +1 -1
- package/llms/components/lr-code-block-core.md +2 -2
- package/llms/components/lr-code-block.md +5 -6
- package/llms/components/lr-color-picker.md +1 -1
- package/llms/components/lr-combobox.md +5 -6
- package/llms/components/lr-compare-panel.md +2 -4
- package/llms/components/lr-confirm-bar.md +3 -7
- package/llms/components/lr-context-inspector.md +3 -2
- package/llms/components/lr-context-menu.md +2 -2
- package/llms/components/lr-context-meter.md +2 -4
- package/llms/components/lr-copy-button.md +1 -1
- package/llms/components/lr-data-grid.md +4 -7
- package/llms/components/lr-details.md +3 -3
- package/llms/components/lr-dialog.md +4 -6
- package/llms/components/lr-dock-panel.md +5 -6
- package/llms/components/lr-document-library.md +5 -7
- package/llms/components/lr-drawer.md +3 -3
- package/llms/components/lr-dropdown.md +4 -5
- package/llms/components/lr-eval-run.md +3 -5
- package/llms/components/lr-export-button.md +4 -7
- package/llms/components/lr-file-input.md +0 -5
- package/llms/components/lr-funnel.md +1 -1
- package/llms/components/lr-graph.md +3 -7
- package/llms/components/lr-icon.md +1 -1
- package/llms/components/lr-include.md +1 -1
- package/llms/components/lr-input.md +31 -79
- package/llms/components/lr-json-viewer.md +1 -1
- package/llms/components/lr-knowledge-base.md +4 -6
- package/llms/components/lr-knowledge-graph-explorer.md +2 -5
- package/llms/components/lr-known-date.md +1 -1
- package/llms/components/lr-lightbox.md +9 -7
- package/llms/components/lr-lite-chart.md +1 -5
- package/llms/components/lr-markdown-core.md +3 -4
- package/llms/components/lr-markdown.md +3 -5
- package/llms/components/lr-mcp-app.md +1 -1
- package/llms/components/lr-message-actions.md +2 -3
- package/llms/components/lr-message-feedback.md +1 -3
- package/llms/components/lr-message-parts.md +4 -5
- package/llms/components/lr-multi-split.md +8 -7
- package/llms/components/lr-native-time-input.md +1 -1
- package/llms/components/lr-navigation-menu.md +5 -5
- package/llms/components/lr-number-input.md +3 -1
- package/llms/components/lr-otp-input.md +2 -0
- package/llms/components/lr-page.md +1 -1
- package/llms/components/lr-pan-zoom.md +1 -1
- package/llms/components/lr-phone-input.md +3 -1
- package/llms/components/lr-popover.md +2 -2
- package/llms/components/lr-progress-bar.md +3 -5
- package/llms/components/lr-progress-ring.md +5 -7
- package/llms/components/lr-prompt-input.md +1 -1
- package/llms/components/lr-prompt-queue.md +1 -1
- package/llms/components/lr-prompt-studio.md +1 -1
- package/llms/components/lr-rag-eval-dashboard.md +1 -1
- package/llms/components/lr-rating.md +2 -2
- package/llms/components/lr-realtime-session.md +1 -1
- package/llms/components/lr-reorder-item.md +1 -1
- package/llms/components/lr-reorder-list.md +2 -3
- package/llms/components/lr-retrieval-compare.md +1 -1
- package/llms/components/lr-select.md +3 -1
- package/llms/components/lr-selection-toolbar.md +1 -1
- package/llms/components/lr-sequence-strip.md +3 -8
- package/llms/components/lr-span-waterfall.md +1 -1
- package/llms/components/lr-split-panel.md +1 -1
- package/llms/components/lr-streaming-text-core.md +2 -1
- package/llms/components/lr-streaming-text.md +3 -2
- package/llms/components/lr-subagent-panel.md +1 -1
- package/llms/components/lr-swatch-picker.md +4 -4
- package/llms/components/lr-switch.md +3 -1
- package/llms/components/lr-table.md +33 -85
- package/llms/components/lr-terminal.md +2 -5
- package/llms/components/lr-textarea.md +1 -1
- package/llms/components/lr-thread-list.md +8 -14
- package/llms/components/lr-time-input.md +1 -1
- package/llms/components/lr-toggle-group.md +2 -2
- package/llms/components/lr-toggle.md +1 -1
- package/llms/components/lr-tool-approval-dialog.md +4 -7
- package/llms/components/lr-tool-call-block.md +1 -1
- package/llms/components/lr-tool-timeline.md +2 -5
- package/llms/components/lr-video-playlist.md +1 -1
- package/llms/components/lr-video.md +1 -1
- package/llms/components/lr-widget-renderer.md +7 -6
- package/llms/components/lr-zoomable-frame.md +1 -1
- package/llms/index.md +3 -618
- package/llms/migration.md +614 -614
- package/llms/shared/events-and-types.md +25 -24
- package/llms/shared/frameworks-and-ssr.md +7 -3
- package/llms/shared/imports-and-registration.md +22 -22
- package/llms/shared/localization-and-rtl.md +2 -2
- package/llms/shared/native-styles-and-utilities.md +263 -0
- package/llms/shared/styles-and-tokens.md +85 -676
- package/llms/shared/testing-and-utilities.md +12 -11
- package/llms/shared/v23-to-v24-migration.md +167 -0
- package/llms/shared.md +142 -487
- package/llms/tokens.md +3 -3
- package/llms.txt +9 -4
- package/package.json +7 -311
- package/registrations.json +1 -1
- package/vscode-html-data.json +1 -1
- package/web-types.json +1 -1
- package/dist/ssr-loader.d.ts +0 -2
- package/dist/ssr-loader.js +0 -1
- package/dist/theme/presets/shadcn.d.ts +0 -22
- package/dist/theme/presets/shadcn.js +0 -1
- package/dist/theme/presets.d.ts +0 -49
- package/dist/theme/presets.js +0 -1
- package/dist/themes/shadcn.css +0 -1
|
@@ -63,7 +63,8 @@ share one implementation.
|
|
|
63
63
|
`<lr-streaming-text>`'s own, including the markdown-mode double-fire avoidance (here the composed
|
|
64
64
|
`<lr-markdown-core>` emits it instead of `<lr-markdown>`).
|
|
65
65
|
The forwarded Markdown surface also emits `lr-copy` and `lr-copy-error` for code-block clipboard
|
|
66
|
-
outcomes.
|
|
66
|
+
outcomes. With `internal-link-prefix` set, its intercepted links also pass through
|
|
67
|
+
`lr-link-activate` (`detail: { href: string }`); navigation is prevented.
|
|
67
68
|
|
|
68
69
|
**Slots:** none — content renders from `content`, not a slot.
|
|
69
70
|
|
|
@@ -97,7 +97,8 @@ listener either way. A consumer composing this element inside a free-form contai
|
|
|
97
97
|
renders into its own shadow root and a plain light-DOM `MutationObserver` on the container can
|
|
98
98
|
never see that update happen. See `<lr-thinking-panel>`'s own reference at `llms/components/lr-thinking-panel.md`.
|
|
99
99
|
The forwarded Markdown surface also emits `lr-copy` and `lr-copy-error` for code-block clipboard
|
|
100
|
-
outcomes.
|
|
100
|
+
outcomes. With `internal-link-prefix` set, its intercepted links also pass through
|
|
101
|
+
`lr-link-activate` (`detail: { href: string }`); navigation is prevented.
|
|
101
102
|
|
|
102
103
|
**Slots:** none — content renders from `content`, not a slot.
|
|
103
104
|
|
|
@@ -137,7 +138,7 @@ sets `math` here.
|
|
|
137
138
|
code-block-header
|
|
138
139
|
></lr-streaming-text>
|
|
139
140
|
<script type="module">
|
|
140
|
-
import "@aceshooting/lyra-ui/components/
|
|
141
|
+
import "@aceshooting/lyra-ui/components/lr-streaming-text.js";
|
|
141
142
|
|
|
142
143
|
const out = document.getElementById("out");
|
|
143
144
|
let text = "";
|
|
@@ -58,7 +58,7 @@ and clamped. **Slots:** none.
|
|
|
58
58
|
**Optional peer deps:** none.
|
|
59
59
|
|
|
60
60
|
```ts
|
|
61
|
-
import "@aceshooting/lyra-ui/components/
|
|
61
|
+
import "@aceshooting/lyra-ui/components/lr-subagent-panel.js";
|
|
62
62
|
```
|
|
63
63
|
|
|
64
64
|
**Additional API surface:**
|
|
@@ -143,7 +143,7 @@ do not need to load Lit. The consumer still owns localized labels, display order
|
|
|
143
143
|
value:
|
|
144
144
|
|
|
145
145
|
```ts
|
|
146
|
-
import "@aceshooting/lyra-ui/components/
|
|
146
|
+
import "@aceshooting/lyra-ui/components/lr-swatch-picker.js";
|
|
147
147
|
import { GEMSTONES } from "@aceshooting/lyra-ui/theme/gemstones-data.js";
|
|
148
148
|
|
|
149
149
|
const order = ["emerald", "ruby", "sapphire", "hematite"] as const;
|
|
@@ -227,9 +227,9 @@ The consuming Lit component imports these granular entries and lists
|
|
|
227
227
|
button in the application uses `icon` or `src`:
|
|
228
228
|
|
|
229
229
|
```ts
|
|
230
|
-
import '@aceshooting/lyra-ui/components/
|
|
231
|
-
import '@aceshooting/lyra-ui/components/
|
|
232
|
-
import '@aceshooting/lyra-ui/components/
|
|
230
|
+
import '@aceshooting/lyra-ui/components/lr-icon-button.js';
|
|
231
|
+
import '@aceshooting/lyra-ui/components/lr-popover.js';
|
|
232
|
+
import '@aceshooting/lyra-ui/components/lr-swatch-picker.js';
|
|
233
233
|
import {
|
|
234
234
|
GEMSTONE_KEYS,
|
|
235
235
|
GEMSTONES,
|
|
@@ -163,7 +163,7 @@ Plus shared tokens
|
|
|
163
163
|
```html
|
|
164
164
|
<lr-switch name="notifications" checked>Enable notifications</lr-switch>
|
|
165
165
|
<script type="module">
|
|
166
|
-
import "@aceshooting/lyra-ui/components/
|
|
166
|
+
import "@aceshooting/lyra-ui/components/lr-switch.js";
|
|
167
167
|
const sw = document.querySelector("lr-switch");
|
|
168
168
|
sw.addEventListener("lr-change", (e) => console.log(e.detail.checked)); // prefixed alias
|
|
169
169
|
sw.addEventListener("change", (e) => console.log(e.target.checked)); // native-style, no detail
|
|
@@ -187,3 +187,5 @@ checkbox and does not emit `lr-change`.
|
|
|
187
187
|
neither that nor slotted label text, the control has no accessible name.
|
|
188
188
|
|
|
189
189
|
---
|
|
190
|
+
|
|
191
|
+
<a id="range-controls"></a>
|
|
@@ -7,9 +7,7 @@
|
|
|
7
7
|
- **Family** `components/data/` — see `llms/index.md` for its siblings
|
|
8
8
|
- **Status** `stable` since `4.0.0` — see the maturity and deprecation policy in `llms/shared.md`
|
|
9
9
|
- **Release history** [CHANGELOG.md](../../CHANGELOG.md); family-wide breaking-change summaries: [data](https://github.com/aceshooting/lyra-ui/blob/main/packages/lyra-ui/llms/data.md)
|
|
10
|
-
- **
|
|
11
|
-
- **Deprecated event** `lr-retry` since `22.0.0`; use event `addEventListener('lr-retry-request', event => { /* Call preventDefault() to veto the proposed action. */ })`; removal not before `24.0.0` — Cancelable proposals use request event names. The historical event remains a veto alias during its compatibility window.
|
|
12
|
-
- **Deprecated property** `accessibleLabel` since `22.0.0`; use attribute `Use element.ariaLabel or setAttribute('aria-label', label); host attribute presence takes precedence over the compatibility fallback.`; removal not before `24.0.0` — The native host accessible-name API replaces the component-specific fallback while preserving its existing runtime behavior throughout the compatibility window.
|
|
10
|
+
- **Deprecations** none
|
|
13
11
|
- **Optional peers** none
|
|
14
12
|
- **Themeable via** 46 parts, 25 custom properties — see this component's own `@csspart`/`@cssprop` list below
|
|
15
13
|
- **Library-wide behavior** (events, form association, `locale`/`strings`, tokens, TS types): `llms/shared.md`
|
|
@@ -18,15 +16,10 @@
|
|
|
18
16
|
|
|
19
17
|
## `lr-table`
|
|
20
18
|
|
|
21
|
-
Sort/select-aware
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
`columns[].heatValue`-opted-in heat-tint mode paints a shared, normalized color-mix background across
|
|
26
|
-
every tinted cell (auto-derived domain, or overridden via `heatTintScale`); `rowTotal`/`grandTotal`
|
|
27
|
-
add a trailing totals column mirroring `expandedContent`'s leading one — `rowTotal(row)` renders
|
|
28
|
-
per-row, `grandTotal(rows)` renders at its intersection with the footer row — both sharing `footer`'s
|
|
29
|
-
own "consumer computes/renders" contract rather than assuming addition.
|
|
19
|
+
Sort/select-aware table with a bounded 100-row default page, filtering, pagination, and loading
|
|
20
|
+
states. Sort requests are cancelable; accepted client requests update `sortKey`/`sortDir` and order
|
|
21
|
+
rows, while server mode leaves that state controlled. `columns[].heatValue` opts into a shared heat
|
|
22
|
+
scale; `rowTotal`/`grandTotal` position caller-computed totals in a trailing column.
|
|
30
23
|
|
|
31
24
|
Effective locale changes recollate and filter the current view while keeping activation and edit
|
|
32
25
|
lookups aligned with the rendered page. Direct row focus uses the same stable-key restoration rules;
|
|
@@ -38,15 +31,8 @@ it survives and otherwise clamps focus to the nearest surviving index. Moving fo
|
|
|
38
31
|
table before the update is applied always wins; nested editors and controls keep their independent
|
|
39
32
|
focus contracts.
|
|
40
33
|
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
`hasHiddenPriorityColumns`, `showAllColumns` with `priorityColumnsVisible`, and the two former
|
|
44
|
-
column-visibility events with `lr-priority-columns-visibility-change { visible }`. Column
|
|
45
|
-
`sticky: true` becomes `sticky: 'start'`; `editable: true` becomes
|
|
46
|
-
`editTrigger: 'double-click'`, and `editable: 'always'` becomes `editTrigger: 'always'`. Sort
|
|
47
|
-
listeners now receive phased readonly `{ phase, sortKey, sortDir }` details from
|
|
48
|
-
`lr-sort-request`/`lr-sort`. A bare table now projects 100 rows per page (with inputs bounded to
|
|
49
|
-
1..500); set an explicit finite `page-size` when a different window is required.
|
|
34
|
+
For historical migration mappings, see the [release history archive](https://github.com/aceshooting/lyra-ui/tree/main/docs/changelog).
|
|
35
|
+
Current property and event contracts follow.
|
|
50
36
|
|
|
51
37
|
**TypeScript:** `LyraTable<T, K extends string | number = string | number>` takes a second type
|
|
52
38
|
parameter for the row-key type. `K` types `rowKey`'s return value,
|
|
@@ -306,7 +292,8 @@ cell: (row) => unknown }` — `cell` is required for every `editTrigger` except
|
|
|
306
292
|
grouped table on a column unrelated to the group key reorders rows inside their groups and
|
|
307
293
|
leaves the grouping intact. The one exception: when the sorted column's value is constant inside
|
|
308
294
|
every group — the group column itself, most obviously — there is nothing to reorder within a
|
|
309
|
-
group, so the **groups** are ordered by that value instead.
|
|
295
|
+
group, so the **groups** are ordered by that value instead. To force another group order,
|
|
296
|
+
pre-sort `rows` or use `sort-mode="server"`.
|
|
310
297
|
- `groupLabel?: (key: string | number, rows: readonly T[]) => unknown` (attribute: false) — custom group
|
|
311
298
|
header content; without it, the group key is rendered as text
|
|
312
299
|
- `expandedContent?: (row: T) => unknown` (attribute: false) — enables a leading expand toggle and
|
|
@@ -489,13 +476,10 @@ The internal filter input's composed native `input`/`change` events are containe
|
|
|
489
476
|
`lr-filter-change` crosses the host boundary. Cell-editor `input`/`change` events are likewise
|
|
490
477
|
contained while an accepted edit publishes `lr-cell-edit`. Internal filter/cell-editor native
|
|
491
478
|
`focus` and `blur` are re-dispatched from the host as bubbling, composed events (the native ones
|
|
492
|
-
are neither). `lr-retry-request`
|
|
479
|
+
are neither). `lr-retry-request` — the built-in `[part='retry-button']` was activated, only rendered while
|
|
493
480
|
`error` is set. **Cancelable**: the default action clears `error`; calling `preventDefault()` leaves
|
|
494
481
|
it set, for a consumer that owns its own retry timing (e.g. it wants to keep the banner up until a
|
|
495
482
|
fresh load has actually started, or failed again immediately).
|
|
496
|
-
`lr-retry` is the deprecated cancelable alias, dispatched after `lr-retry-request` with the same
|
|
497
|
-
null detail. Either event can veto clearing the error; subscribe to one spelling. Removal of the
|
|
498
|
-
alias is not before 24.0.0.
|
|
499
483
|
|
|
500
484
|
**Slots:** `empty` — replaces the built-in empty state on the two _data_-empty branches (no rows at
|
|
501
485
|
all, and filtered/paginated down to zero). Left unfilled, the built-in `[part='empty']` `<lr-empty>`
|
|
@@ -579,41 +563,33 @@ body's `max-block-size`). `--lr-table-heat-tint-lo` (default `var(--lr-color-bra
|
|
|
579
563
|
`--lr-table-heat-tint-hi` (default `var(--lr-color-brand)`) — the `color-mix()` ramp endpoints
|
|
580
564
|
for heat-tint mode's per-cell background, consulted only on columns/rows that define `heatValue`;
|
|
581
565
|
`--lr-table-resize-min-width` (default `var(--lr-size-3rem)`) and
|
|
582
|
-
`--lr-table-resize-handle-opacity` (default `0.12`) control resizable-column behavior.
|
|
583
|
-
|
|
584
|
-
`var(--lr-color-brand)`), `--lr-table-resize-handle-hover-opacity` (defaulting to
|
|
566
|
+
`--lr-table-resize-handle-opacity` (default `0.12`) control resizable-column behavior.
|
|
567
|
+
`--lr-table-resize-handle-hover-bg` (default
|
|
568
|
+
`var(--lr-color-brand)`), `--lr-table-resize-handle-hover-opacity` (defaulting to that
|
|
585
569
|
opacity), `--lr-table-resize-handle-active-bg` (defaulting to the hover background), and
|
|
586
570
|
`--lr-table-resize-handle-active-opacity` (defaulting to twice the hover opacity) independently
|
|
587
571
|
retune the rendered interaction states. These heat-tint/resize hooks are not redeclared on the component host: set them on
|
|
588
572
|
`lr-table` or on a theme ancestor, and a table-level value wins through the normal cascade.
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
`
|
|
593
|
-
element _or on any ancestor_ and still reach the rule that reads it. It exists because Shadow Parts
|
|
594
|
-
forbids an attribute selector after `::part()` — `::part(row)[aria-selected='true']` is invalid CSS —
|
|
595
|
-
so the only prior lever for restyling the selected row was overriding the library-wide
|
|
596
|
-
`--lr-color-brand-quiet` token, which repaints everything else reading it.
|
|
573
|
+
State-scoped hooks below use inline `var()` fallbacks, so values on `lr-table` or an ancestor remain
|
|
574
|
+
effective. Shadow Parts cannot select an attribute after `::part()`.
|
|
575
|
+
`--lr-table-row-selected-bg` (default `var(--lr-color-brand-quiet)`) paints a selected row and its
|
|
576
|
+
own `sticky` cell when `aria-selected="true"`.
|
|
597
577
|
`--lr-table-row-stripe-bg` (default `transparent`) — the background of alternating body rows,
|
|
598
578
|
including each row's own `sticky` column cell. The
|
|
599
|
-
component marks the alternating rows itself
|
|
600
|
-
or structural-pseudo-class selector and does not affect group, expanded, hover, or selected rows. A
|
|
579
|
+
component marks the alternating rows itself; this does not affect group, expanded, hover, or selected rows. A
|
|
601
580
|
row's hover and pressed fills reach its `sticky` column cell the same way, through an internal
|
|
602
581
|
custom property rather than a themeable token, since neither state has a public hook today.
|
|
603
582
|
`--lr-table-header-sorted-bg` (default `var(--lr-color-surface)`) and `--lr-table-header-sorted-color` (default
|
|
604
583
|
`inherit`) restyle the **currently-sorted** column's header cell (`[aria-sort]` other than `none`),
|
|
605
584
|
including a `sticky` column's own header cell. The opaque surface default prevents body rows from
|
|
606
585
|
showing through the sticky header while it scrolls.
|
|
607
|
-
|
|
608
|
-
because `::part(header-cell)[aria-sort]` is invalid CSS. The `sort-icon` part styles only the
|
|
609
|
-
indicator; these tokens style the header cell itself. Use `::part(sort-icon-inactive)` and
|
|
586
|
+
The `sort-icon` part styles only the indicator; these tokens style the header cell. Use `::part(sort-icon-inactive)` and
|
|
610
587
|
`::part(sort-icon-active)` to style the two indicator states without private selectors.
|
|
611
588
|
`--lr-table-sticky-offset` (default `0`) is measured and written inline per column by the component
|
|
612
589
|
so multiple `sticky` columns stack instead of overlapping; it is a read-out, not a knob you set.
|
|
613
590
|
`--lr-table-heat-t` is likewise component-written (each `[data-heat]` cell's position on the ramp).
|
|
614
591
|
`[part="base"]`, the table's own scroll container, also honors the opt-in theme-level
|
|
615
|
-
`--lr-theme-scrollbar-width`/`--lr-theme-scrollbar-gutter` hooks (defaults `auto`/`auto
|
|
616
|
-
its previous unconditional `scrollbar-width: auto`) — set either on `:root` or any ancestor for one
|
|
592
|
+
`--lr-theme-scrollbar-width`/`--lr-theme-scrollbar-gutter` hooks (defaults `auto`/`auto`) — set either on `:root` or any ancestor for one
|
|
617
593
|
declaration to retheme every internal scroll container in the library, including
|
|
618
594
|
`lr-virtual-list`, `lr-scroller`, `lr-carousel`, `lr-code-block`, and `lr-code-editor`.
|
|
619
595
|
|
|
@@ -660,31 +636,18 @@ declaration to retheme every internal scroll container in the library, including
|
|
|
660
636
|
|
|
661
637
|
**Known gotchas:**
|
|
662
638
|
|
|
663
|
-
-
|
|
664
|
-
|
|
665
|
-
`lr-sort-request` to suppress both state change and commit. The built-in transaction toggles only
|
|
666
|
-
between two directions, so a tri-state header (asc → desc → unsorted) remains consumer-owned.
|
|
639
|
+
- The built-in sort transaction toggles between `asc` and `desc`; a tri-state header with an
|
|
640
|
+
unsorted state remains consumer-owned. Veto `lr-sort-request` to suppress state change and commit.
|
|
667
641
|
- `sortValue`/`cell` are read off the column object by identity. Mutating a column **in place**
|
|
668
642
|
(`t.columns[0].sortValue = …`) neither re-renders nor re-sorts; assign a new `columns` array.
|
|
669
|
-
- `groupBy` + client sorting are **not** in conflict: the sort runs per group, not across the whole
|
|
670
|
-
set, so group rows stay contiguous. The consequence is that the group order is normally yours to
|
|
671
|
-
control — it follows first appearance in `rows`. The single exception is a sort on a column whose
|
|
672
|
-
value is constant inside every group (the group column itself, a column functionally determined
|
|
673
|
-
by the group key, or any column at all when every group holds one row): the within-group sort
|
|
674
|
-
would be a provable no-op, so the groups are ordered by that constant value instead. That is what
|
|
675
|
-
keeps `aria-sort` and the header chevron honest — otherwise clicking the group column would flip
|
|
676
|
-
both while changing nothing. To force a group order in any other case, sort `rows` into it before
|
|
677
|
-
assigning them (or set `sort-mode="server"` and own the whole ordering).
|
|
678
643
|
- both single and multiple row selection use `selectedRowKeys`; the component does not synthesize a
|
|
679
644
|
checkbox column, so a bulk-select UI still belongs in `headerCell()`/`cell()` callbacks.
|
|
680
645
|
- A host `aria-label` (or native `ariaLabel` property) names the internal `<table role="grid">`.
|
|
681
|
-
Presence wins, including an explicitly empty string.
|
|
682
|
-
`accessible-label`) remains a deprecated fallback, with removal not before 24.0.0; an explicit
|
|
683
|
-
empty fallback stays empty when the host name is absent. Caller text bypasses localization.
|
|
646
|
+
Presence wins, including an explicitly empty string. Caller text in the host `aria-label` bypasses localization.
|
|
684
647
|
- `caption: string = ''` — an optional visible `<caption>` (exposed as the `caption` CSS part). When
|
|
685
|
-
no
|
|
648
|
+
no host `aria-label` is present the caption also names the grid via
|
|
686
649
|
`aria-labelledby`.
|
|
687
|
-
- A grid with **none** of
|
|
650
|
+
- A grid with **none** of host `aria-label` or `caption` logs a one-time
|
|
688
651
|
`console.warn` on first render in development builds only — an unnamed grid is an accessibility
|
|
689
652
|
defect that otherwise renders silently. Production and unknown/unbundled runtimes do not log it.
|
|
690
653
|
- `revealColumnsLabel`/`columnsHideLabel` only ever reach the DOM on
|
|
@@ -692,11 +655,10 @@ declaration to retheme every internal scroll container in the library, including
|
|
|
692
655
|
`priority`. Setting either label with no `priority` column is therefore always inert — it logs
|
|
693
656
|
the same shape of one-time, development-only, production-silent `console.warn` as the missing
|
|
694
657
|
accessible-name check above, rather than failing silently.
|
|
695
|
-
-
|
|
696
|
-
|
|
697
|
-
body,
|
|
698
|
-
|
|
699
|
-
this family. A `priority`-hidden header/cell is skipped when computing the visible header stops,
|
|
658
|
+
- The grid has one roving `tabindex="0"` stop among header cells and one among body rows.
|
|
659
|
+
Left/Right/Home/End navigate headers; Up/Down/Home/End navigate rows. Down from a header enters
|
|
660
|
+
the body, Up from its first row returns to the header, and Enter/Space sort or activate.
|
|
661
|
+
A `priority`-hidden header/cell is skipped when computing visible header stops,
|
|
700
662
|
so arrow-key navigation never strands the roving stop on a hidden column.
|
|
701
663
|
- a `cell()` template can render its own interactive content without it being swallowed by
|
|
702
664
|
row/column activation. Delegated clicks and Enter/Space inspect the event's composed path for
|
|
@@ -730,23 +692,9 @@ declaration to retheme every internal scroll container in the library, including
|
|
|
730
692
|
as the cell's accessible _name_, replacing the cell's content rather than supplementing it (the
|
|
731
693
|
same caveat `lr-stat`'s `exactValue` carries). Use it for a longer form of what the cell already
|
|
732
694
|
shows, never for information that exists nowhere else.
|
|
733
|
-
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
opposite — an authoritative external value that always wins — do not use `'always'`; re-key the
|
|
738
|
-
row (`rowKey`) so the editor is recreated rather than updated, or use `editTrigger: 'double-click'` and let
|
|
739
|
-
the short-lived double-click editor's property binding re-assert. Also note the two things
|
|
740
|
-
`'always'` intentionally does _not_ do: it never sets the roving `tabindex` (its editors are
|
|
741
|
-
ordinary tab stops, so Tab order in that column interleaves with the grid's two roving stops,
|
|
742
|
-
the same way the row-expand toggle's already does), and it never cancels Escape.
|
|
743
|
-
- `editType: 'select'` renders a native `<select>`, populated from `columns[].editOptions`
|
|
744
|
-
(`{ value: string; label: string }[]`, one `<option>` per entry in order); a `'select'` column
|
|
745
|
-
with no `editOptions` renders an empty, valueless `<select>` rather than throwing. Unlike the
|
|
746
|
-
`'text'`/`'number'` editors, `<select>`/`<option>` carry no native dirty-value flag, so the
|
|
747
|
-
protection described above for a persistent `'always'` editor does not extend to a `'select'`
|
|
748
|
-
one — a background `rows` refresh re-applies the selection to a persistent select editor even
|
|
749
|
-
after the user has picked a different, uncommitted option. The double-click flavor is unaffected
|
|
750
|
-
by this distinction either way, since it is always short-lived.
|
|
695
|
+
- For an externally authoritative value, re-key the row (`rowKey`) to recreate an `'always'`
|
|
696
|
+
editor, or use the transient `editTrigger: 'double-click'` editor. Persistent text/number editors
|
|
697
|
+
otherwise retain dirty drafts; persistent select editors re-apply refreshed selections, as
|
|
698
|
+
described under `columns[].editTrigger` above.
|
|
751
699
|
|
|
752
700
|
---
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
- **Family** `components/agent-tools/` — see `llms/index.md` for its siblings
|
|
8
8
|
- **Status** `stable` since `4.0.0` — see the maturity and deprecation policy in `llms/shared.md`
|
|
9
9
|
- **Release history** [CHANGELOG.md](../../CHANGELOG.md); family-wide breaking-change summaries: [agent-tools](https://github.com/aceshooting/lyra-ui/blob/main/packages/lyra-ui/llms/agent-tools.md)
|
|
10
|
-
- **
|
|
10
|
+
- **Deprecations** none
|
|
11
11
|
- **Optional peers** none
|
|
12
12
|
- **Themeable via** 16 parts, 18 custom properties — see this component's own `@csspart`/`@cssprop` list below
|
|
13
13
|
- **Library-wide behavior** (events, form association, `locale`/`strings`, tokens, TS types): `llms/shared.md`
|
|
@@ -65,7 +65,7 @@ plain text of the whole buffer.
|
|
|
65
65
|
|
|
66
66
|
**Events:** `lr-copy` (`detail: { ok: true, text }`, emitted only after a successful clipboard write),
|
|
67
67
|
`lr-error` (no detail) and `lr-copy-error` (`detail: { ok: false, text, reason, error }`) on clipboard failure,
|
|
68
|
-
`lr-download-request`
|
|
68
|
+
`lr-download-request` (`detail: { filename }`, cancelable — by
|
|
69
69
|
default the component creates a plain-text `Blob`/object URL and activates a synthetic
|
|
70
70
|
`<a download>`; `preventDefault()` suppresses that built-in download so the host can substitute
|
|
71
71
|
server-side or other handling),
|
|
@@ -74,9 +74,6 @@ matchCountExact, activeIndex }`; `matchCountExact` is `false` once a search hits
|
|
|
74
74
|
ceiling, marking `matchCount` as a lower bound rather than an exact total),
|
|
75
75
|
`lr-highlight-activate` (`detail: { highlightId }`), and `lr-text-select` (`detail: {
|
|
76
76
|
text, anchor, rects }`).
|
|
77
|
-
`lr-download` is the deprecated cancelable alias, dispatched after `lr-download-request` with the
|
|
78
|
-
same filename detail. Either event can suppress the built-in download; it is not a completion
|
|
79
|
-
notification. Subscribe to one spelling.
|
|
80
77
|
|
|
81
78
|
|
|
82
79
|
**CSS parts:** `base`, `toolbar` (only rendered when copy/download are enabled), `copy-button`,
|
|
@@ -41,7 +41,7 @@ disabled state.
|
|
|
41
41
|
resize="auto"
|
|
42
42
|
></lr-textarea>
|
|
43
43
|
<script type="module">
|
|
44
|
-
import "@aceshooting/lyra-ui/components/
|
|
44
|
+
import "@aceshooting/lyra-ui/components/lr-textarea.js";
|
|
45
45
|
const bio = document.querySelector('lr-textarea[label="Bio"]');
|
|
46
46
|
await bio.updateComplete; // both calls are no-ops before the first render
|
|
47
47
|
bio.scrollPosition({ top: 0 }); // pin a restored draft back to the top
|
|
@@ -7,8 +7,7 @@
|
|
|
7
7
|
- **Family** `components/conversation/` — see `llms/index.md` for its siblings
|
|
8
8
|
- **Status** `stable` since `4.0.0` — see the maturity and deprecation policy in `llms/shared.md`
|
|
9
9
|
- **Release history** [CHANGELOG.md](../../CHANGELOG.md); family-wide breaking-change summaries: [conversation](https://github.com/aceshooting/lyra-ui/blob/main/packages/lyra-ui/llms/conversation.md)
|
|
10
|
-
- **
|
|
11
|
-
- **Deprecated property** `compact` / `compact` since `22.0.0`; use property `Use size="s" for compact rows and size="m" for the default row density.`; removal not before `24.0.0` — The shared size vocabulary describes row density and search-control scale together. The boolean compatibility spelling remains mapped to the small and medium size tiers throughout its deprecation window.
|
|
10
|
+
- **Deprecations** none
|
|
12
11
|
- **Optional peers** none
|
|
13
12
|
- **Themeable via** 42 parts, 20 custom properties — see this component's own `@csspart`/`@cssprop` list below
|
|
14
13
|
- **Library-wide behavior** (events, form association, `locale`/`strings`, tokens, TS types): `llms/shared.md`
|
|
@@ -42,9 +41,9 @@ string | number; pinned?: boolean; archived?: boolean }`; `ThreadRowAction = 'pi
|
|
|
42
41
|
'delete'`; `ThreadListGrouping = 'date' | 'custom' | 'none'`; `ThreadBucketKey = 'pinned' |
|
|
43
42
|
'today' | 'yesterday' | 'previous7' | 'previous30' | `month:${string}` | 'archived'`;
|
|
44
43
|
`ThreadGroupContext { id: string; threads: readonly LyraChatThread[]; bucket?: ThreadBucketKey;
|
|
45
|
-
date?: Date }`; and `ThreadGroupToggleDetail { groupId: string; expanded
|
|
46
|
-
|
|
47
|
-
`
|
|
44
|
+
date?: Date }`; and `ThreadGroupToggleDetail { groupId: string; expanded?: boolean }` (the shared
|
|
45
|
+
payload type for the `lr-group-toggle-request`/`lr-group-toggle` pair; this component supplies
|
|
46
|
+
`expanded` on emitted events, though the type keeps it optional). `LyraThreadList` and
|
|
48
47
|
`LyraThreadListEventMap` are exported alongside them. The class
|
|
49
48
|
module, normal and stable tag-shaped registration entries, conversation family entry, and package
|
|
50
49
|
root all retain this complete thread-list surface; the former `ChatThread` name is not retained.
|
|
@@ -92,9 +91,7 @@ data mode only: built-in icon buttons rendered into each row's `actions` slot. `
|
|
|
92
91
|
= false` (attribute `with-archived`, reflected) — data mode: include `archived` threads (in their own
|
|
93
92
|
trailing group). `withoutRename: boolean = false` (attribute `without-rename`, reflected) — forwarded to
|
|
94
93
|
each data-mode row, turning its inline rename off.
|
|
95
|
-
`
|
|
96
|
-
alias of `size="s"` when true and `size="m"` when false. Use `size` for both search and data rows;
|
|
97
|
-
slotted rows retain their own size. `stickyGroups: boolean = false` (attribute `sticky-groups`, reflected) — data mode: pins
|
|
94
|
+
`stickyGroups: boolean = false` (attribute `sticky-groups`, reflected) — data mode: pins
|
|
98
95
|
the current date/custom group's header to the top of the scroll viewport while its rows are in view,
|
|
99
96
|
pushing it off as the next group's header arrives. Group headers are ordinary virtualized rows, so
|
|
100
97
|
this renders an `aria-hidden` copy of the header into the internal `lr-virtual-list`'s sticky layer:
|
|
@@ -172,11 +169,10 @@ including its retry button, while `error` is set.
|
|
|
172
169
|
built-in confirmation), `lr-thread-rename` (`detail: { conversationId, label }`, correlated and
|
|
173
170
|
re-emitted from the owned row), `lr-filter-change` (`detail: { text, matchCount }`). Slotted mode
|
|
174
171
|
instead emits `lr-query-change` (`detail: { text }`) and never claims a match count it cannot own.
|
|
175
|
-
`lr-group-toggle-request` (`detail: { groupId, expanded
|
|
176
|
-
the canonical key and the deprecated `collapsed` its inverse) — proposed before a
|
|
172
|
+
`lr-group-toggle-request` (`detail: { groupId, expanded }`, cancelable) — proposed before a
|
|
177
173
|
custom/date group's collapse state changes; calling `preventDefault()` skips the built-in
|
|
178
174
|
`collapsedGroupIds` write and suppresses the following `lr-group-toggle`, leaving the group's
|
|
179
|
-
collapse state fully controlled. `lr-group-toggle` (`detail: { groupId, expanded
|
|
175
|
+
collapse state fully controlled. `lr-group-toggle` (`detail: { groupId, expanded }`) — the
|
|
180
176
|
change was accepted and, unless `lr-group-toggle-request` was prevented, already applied to
|
|
181
177
|
`collapsedGroupIds`; native group buttons provide Enter/Space activation and explicit
|
|
182
178
|
`aria-expanded="true"|"false"` regardless. A consumer that already listens for `lr-group-toggle`
|
|
@@ -186,9 +182,7 @@ assignment simply wins last. `searchable` only: `blur`/`focus` (no detail) — r
|
|
|
186
182
|
the internal search `<input>`'s own `blur`/`focus`, bubbling and composed unlike the native events,
|
|
187
183
|
which are neither. `lr-retry-request` (`detail: null`, cancelable) — the built-in `[part='retry-button']`
|
|
188
184
|
was activated, only rendered while `error` is set; the default action clears `error`,
|
|
189
|
-
`preventDefault()` leaves it set instead.
|
|
190
|
-
emitted after `lr-retry-request` and before the default action; canceling either event keeps the
|
|
191
|
-
error state.
|
|
185
|
+
`preventDefault()` leaves it set instead.
|
|
192
186
|
**CSS parts:** `base`, `search`/`search-input` (the search field wrapper and `<input
|
|
193
187
|
type="search">`), `clear-button` (clears the search field; rendered only while it has a value,
|
|
194
188
|
mirroring `<lr-input>`'s own `clearable` contract's part name), `list` (the list region), `empty`,
|
|
@@ -195,6 +195,6 @@ ancestor to change every unset time input beneath it.
|
|
|
195
195
|
></lr-time-input>
|
|
196
196
|
<lr-time-input label="Precise time" step="15" value="09:30:15"></lr-time-input>
|
|
197
197
|
<script type="module">
|
|
198
|
-
import "@aceshooting/lyra-ui/components/
|
|
198
|
+
import "@aceshooting/lyra-ui/components/lr-time-input.js";
|
|
199
199
|
</script>
|
|
200
200
|
```
|
|
@@ -116,8 +116,8 @@ toggles join, and `var(--lr-space-2xs)` when vertical) and `--lr-toggle-group-wr
|
|
|
116
116
|
|
|
117
117
|
```html
|
|
118
118
|
<script type="module">
|
|
119
|
-
import '@aceshooting/lyra-ui/components/
|
|
120
|
-
import '@aceshooting/lyra-ui/components/
|
|
119
|
+
import '@aceshooting/lyra-ui/components/lr-toggle-group.js';
|
|
120
|
+
import '@aceshooting/lyra-ui/components/lr-toggle.js';
|
|
121
121
|
</script>
|
|
122
122
|
|
|
123
123
|
<lr-toggle-group label="Text formatting" appearance="outlined">
|
|
@@ -115,7 +115,7 @@ and press get outline affordances, and disabled toggles read as `GrayText` at fu
|
|
|
115
115
|
|
|
116
116
|
```html
|
|
117
117
|
<script type="module">
|
|
118
|
-
import '@aceshooting/lyra-ui/components/
|
|
118
|
+
import '@aceshooting/lyra-ui/components/lr-toggle.js';
|
|
119
119
|
</script>
|
|
120
120
|
|
|
121
121
|
<lr-toggle value="bold">Bold</lr-toggle>
|
|
@@ -7,8 +7,7 @@
|
|
|
7
7
|
- **Family** `components/agent-tools/` — see `llms/index.md` for its siblings
|
|
8
8
|
- **Status** `stable` since `4.0.0` — see the maturity and deprecation policy in `llms/shared.md`
|
|
9
9
|
- **Release history** [CHANGELOG.md](../../CHANGELOG.md); family-wide breaking-change summaries: [agent-tools](https://github.com/aceshooting/lyra-ui/blob/main/packages/lyra-ui/llms/agent-tools.md)
|
|
10
|
-
- **
|
|
11
|
-
- **Deprecated event** `lr-deny` since `22.0.0`; use event `addEventListener('lr-deny-request', event => { /* Call preventDefault() to veto the proposed action. */ })`; removal not before `24.0.0` — Cancelable proposals use request event names. The historical event remains a veto alias during its compatibility window.
|
|
10
|
+
- **Deprecations** none
|
|
12
11
|
- **Optional peers** none
|
|
13
12
|
- **Themeable via** 22 parts, 4 custom properties — see this component's own `@csspart`/`@cssprop` list below
|
|
14
13
|
- **Library-wide behavior** (events, form association, `locale`/`strings`, tokens, TS types): `llms/shared.md`
|
|
@@ -83,10 +82,10 @@ renders at the start of the action row, before Deny/Edit/Approve.
|
|
|
83
82
|
void` and `close(reason = 'api'): void` close through the same reasoned lifecycle, emit `lr-close`,
|
|
84
83
|
and return focus to whatever had it before opening; all are no-ops when already in the target state.
|
|
85
84
|
|
|
86
|
-
**Events:** `lr-approve-request`
|
|
85
|
+
**Events:** `lr-approve-request` (`detail: { args: unknown }` — the current, already-parsed arguments: the
|
|
87
86
|
original `args` prop, or the user's edited-and-validated version if an edit was in progress.
|
|
88
87
|
Cancelable: a listener calling `preventDefault()` sets `pendingAction` to `'approve'` instead of
|
|
89
|
-
closing; otherwise followed by `lr-close` with reason `'approve'`), `lr-deny-request`
|
|
88
|
+
closing; otherwise followed by `lr-close` with reason `'approve'`), `lr-deny-request`
|
|
90
89
|
(`detail: null`, cancelable, with the same `pendingAction` mechanism,
|
|
91
90
|
setting `pendingAction` to `'deny'`; otherwise followed by `lr-close` with reason `'deny'`), `lr-close`
|
|
92
91
|
(`detail: { reason: ToolApprovalDialogCloseReason }` — fired exactly once per dismissal, via Escape, an opted-in
|
|
@@ -95,9 +94,7 @@ dialog inside a consumer's own `<lr-dialog>` means that dialog's `lr-close` list
|
|
|
95
94
|
this event, see `<lr-dialog>`'s `lr-close` section in `overlays.md` for the full list of emitters
|
|
96
95
|
and the target-filtering guard), and no-detail `focus`/`blur` events
|
|
97
96
|
re-dispatched when the raw-JSON editor gains or loses focus.
|
|
98
|
-
`lr-
|
|
99
|
-
follows its request with the same detail; preventing either spelling holds that decision pending.
|
|
100
|
-
Subscribe to one spelling per action. `lr-close` remains the non-cancelable dismissal notification.
|
|
97
|
+
`lr-close` remains the non-cancelable dismissal notification.
|
|
101
98
|
|
|
102
99
|
`waitUntil()` is `<lr-confirm-bar>`-only and this dialog does not carry it. The two components share
|
|
103
100
|
the `lr-approve-request`/`lr-deny-request` event *names*, so the generated `HTMLElementEventMap['lr-approve-request']` is the
|
|
@@ -106,7 +106,7 @@ The running glyph spins and the pending glyph pulses at `--lr-transition-ambient
|
|
|
106
106
|
|
|
107
107
|
```html
|
|
108
108
|
<script type="module">
|
|
109
|
-
import '@aceshooting/lyra-ui/components/
|
|
109
|
+
import '@aceshooting/lyra-ui/components/lr-tool-call-block.js';
|
|
110
110
|
</script>
|
|
111
111
|
|
|
112
112
|
<lr-tool-call-block name="web_search" call-id="call-1" status="success" duration-ms="1450"></lr-tool-call-block>
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
- **Family** `components/agent-tools/` — see `llms/index.md` for its siblings
|
|
8
8
|
- **Status** `stable` since `4.1.0` — see the maturity and deprecation policy in `llms/shared.md`
|
|
9
9
|
- **Release history** [CHANGELOG.md](../../CHANGELOG.md); family-wide breaking-change summaries: [agent-tools](https://github.com/aceshooting/lyra-ui/blob/main/packages/lyra-ui/llms/agent-tools.md)
|
|
10
|
-
- **
|
|
10
|
+
- **Deprecations** none
|
|
11
11
|
- **Optional peers** none
|
|
12
12
|
- **Themeable via** 17 parts, 14 custom properties — see this component's own `@csspart`/`@cssprop` list below
|
|
13
13
|
- **Library-wide behavior** (events, form association, `locale`/`strings`, tokens, TS types): `llms/shared.md`
|
|
@@ -73,7 +73,7 @@ data or exhausting the page.
|
|
|
73
73
|
non-approval entry activation and `lr-tool-render-error` (`detail: { invocationId: string;
|
|
74
74
|
sourceKey?: string; toolName: string; error: unknown }`) for a contained nested renderer failure.
|
|
75
75
|
The raw child chip-selection, renderer-error, details, and dialog events do not leak across the
|
|
76
|
-
timeline boundary. `lr-tool-approval-decide-request`
|
|
76
|
+
timeline boundary. `lr-tool-approval-decide-request` (`detail: ToolTimelineApprovalDetail` =
|
|
77
77
|
`ToolApprovalEventDetail & { args?: unknown; sourceKey?: string }` = `{ invocationId: string;
|
|
78
78
|
approved: boolean; args?: unknown; sourceKey?: string }`, extending the shared detail from
|
|
79
79
|
`@aceshooting/lyra-ui/ai`). `args` is present only when
|
|
@@ -88,9 +88,6 @@ A host may instead resolve the decision synchronously by reassigning `entries` (
|
|
|
88
88
|
`finalizePendingApproval()`: the entry's live state is re-checked immediately after dispatch, so
|
|
89
89
|
`pendingApproval` — and the shared dialog's pending presentation — is never set or left set for
|
|
90
90
|
an entry that no longer needs a decision.
|
|
91
|
-
`lr-tool-approval-decide` is the deprecated cancelable alias, dispatched after its request with
|
|
92
|
-
the same detail. Either spelling can hold the pending decision; subscribe to one spelling. It is
|
|
93
|
-
not a completed-decision notification.
|
|
94
91
|
|
|
95
92
|
```ts
|
|
96
93
|
timeline.addEventListener("lr-tool-approval-decide-request", async (event) => {
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
Experimental direct-child `<lr-video>` playlist with a visible current-video stage and
|
|
20
20
|
keyboard-navigable item list. It mirrors the public Web Awesome Video Playlist API under the `lr-`
|
|
21
21
|
prefix. Import the granular registration entry with
|
|
22
|
-
`import '@aceshooting/lyra-ui/components/
|
|
22
|
+
`import '@aceshooting/lyra-ui/components/lr-video-playlist.js'`.
|
|
23
23
|
|
|
24
24
|
**Properties:** `controls: 'none' | 'standard' | 'full' = 'full'` (reflected and forwarded to every
|
|
25
25
|
direct child), and `iconLibrary: string = 'system'` (attribute `icon-library`, non-reflected and
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
Experimental inline native video player with custom controls, safe declarative sources/tracks,
|
|
20
20
|
selectable captions, and bounded WebVTT thumbnail previews. It mirrors the public Web Awesome Video
|
|
21
21
|
API under the `lr-` prefix. Import the granular registration entry with
|
|
22
|
-
`import '@aceshooting/lyra-ui/components/
|
|
22
|
+
`import '@aceshooting/lyra-ui/components/lr-video.js'`.
|
|
23
23
|
|
|
24
24
|
When progress is unavailable, the disabled native range input and its visible timeline track retain
|
|
25
25
|
resting paint under hover and press. Once media duration makes progress available, the track retains
|
|
@@ -58,9 +58,10 @@ readonly slot?: string; readonly actionId?: string; readonly payload?: unknown }
|
|
|
58
58
|
structure throws `TypeError`. Node records, child arrays, and prop records are copied and frozen,
|
|
59
59
|
while opaque prop values and action payloads intentionally retain caller identity.
|
|
60
60
|
|
|
61
|
-
The
|
|
62
|
-
`LyraWidgetRenderer
|
|
63
|
-
|
|
61
|
+
The `widget-renderer.class.js` class entry and stable `components/lr-widget-renderer.js` registration
|
|
62
|
+
entry expose `LyraWidgetRenderer`; its event-map type and stable authoring contracts remain available from
|
|
63
|
+
the curated package root: `LyraWidgetRendererEventMap`, `LyraWidgetNode`, `LyraWidgetBinding`,
|
|
64
|
+
`LyraWidgetDocument`, `createWidgetDocument`,
|
|
64
65
|
`LyraWidgetPropType`, `LyraWidgetInteraction`, `LyraWidgetTypeDefinition`,
|
|
65
66
|
`LyraWidgetTypeRegistry`, `createWidgetTypeRegistry`, `isWidgetTypeRegistry`, and
|
|
66
67
|
`DEFAULT_WIDGET_TYPE_REGISTRY`. Advanced consumers that need `resolveTree`, `ResolveContext`,
|
|
@@ -145,8 +146,8 @@ import {
|
|
|
145
146
|
createWidgetDocument,
|
|
146
147
|
createWidgetTypeRegistry,
|
|
147
148
|
DEFAULT_WIDGET_TYPE_REGISTRY,
|
|
148
|
-
} from "@aceshooting/lyra-ui/components/
|
|
149
|
-
import "@aceshooting/lyra-ui/components/
|
|
149
|
+
} from "@aceshooting/lyra-ui/components/lr-widget-renderer.js";
|
|
150
|
+
import "@aceshooting/lyra-ui/components/lr-sparkline.js";
|
|
150
151
|
import { tag } from "@aceshooting/lyra-ui/utilities/prefix.js";
|
|
151
152
|
|
|
152
153
|
const registry = createWidgetTypeRegistry([
|
|
@@ -180,7 +181,7 @@ import { LyraWidgetRenderer } from "@aceshooting/lyra-ui/components/conversation
|
|
|
180
181
|
import { createWidgetDocument } from "@aceshooting/lyra-ui/components/conversation/widget-renderer/resolve.js";
|
|
181
182
|
import { createWidgetTypeRegistry } from "@aceshooting/lyra-ui/components/conversation/widget-renderer/registry.js";
|
|
182
183
|
import { defineElement, tag } from "@aceshooting/lyra-ui/utilities/prefix.js";
|
|
183
|
-
import "@aceshooting/lyra-ui/components/
|
|
184
|
+
import "@aceshooting/lyra-ui/components/lr-input.js";
|
|
184
185
|
|
|
185
186
|
defineElement("widget-renderer", LyraWidgetRenderer);
|
|
186
187
|
|
|
@@ -107,7 +107,7 @@ attributes, and inline properties Lyra changed, preserving any later iframe-owne
|
|
|
107
107
|
a watched host-page theme attribute syncs again.
|
|
108
108
|
|
|
109
109
|
```js
|
|
110
|
-
import "@aceshooting/lyra-ui/components/
|
|
110
|
+
import "@aceshooting/lyra-ui/components/lr-zoomable-frame.js";
|
|
111
111
|
```
|
|
112
112
|
|
|
113
113
|
```html
|