@aceshooting/lyra-ui 1.2.0 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +98 -14
- package/custom-elements.json +30279 -12124
- package/dist/components/app-rail/app-rail-item.d.ts +30 -0
- package/dist/components/app-rail/app-rail-item.js +68 -0
- package/dist/components/app-rail/app-rail-item.styles.d.ts +1 -0
- package/dist/components/app-rail/app-rail-item.styles.js +65 -0
- package/dist/components/app-rail/app-rail.d.ts +168 -0
- package/dist/components/app-rail/app-rail.js +419 -0
- package/dist/components/app-rail/app-rail.styles.d.ts +1 -0
- package/dist/components/app-rail/app-rail.styles.js +128 -0
- package/dist/components/attachment-chip/attachment-chip.d.ts +141 -0
- package/dist/components/attachment-chip/attachment-chip.js +356 -0
- package/dist/components/attachment-chip/attachment-chip.styles.d.ts +1 -0
- package/dist/components/attachment-chip/attachment-chip.styles.js +184 -0
- package/dist/components/attachment-trigger/attachment-trigger.d.ts +96 -0
- package/dist/components/attachment-trigger/attachment-trigger.js +270 -0
- package/dist/components/attachment-trigger/attachment-trigger.styles.d.ts +1 -0
- package/dist/components/attachment-trigger/attachment-trigger.styles.js +90 -0
- package/dist/components/chart/bar-chart.js +2 -18
- package/dist/components/chart/box-plot.d.ts +25 -1
- package/dist/components/chart/box-plot.js +147 -7
- package/dist/components/chart/box-plot.styles.js +13 -0
- package/dist/components/chart/bubble-chart.js +2 -18
- package/dist/components/chart/chart-loader.d.ts +44 -13
- package/dist/components/chart/chart-loader.js +65 -18
- package/dist/components/chart/chart.d.ts +55 -12
- package/dist/components/chart/chart.js +247 -49
- package/dist/components/chart/doughnut-chart.js +2 -18
- package/dist/components/chart/histogram-bin.d.ts +7 -1
- package/dist/components/chart/histogram-bin.js +32 -14
- package/dist/components/chart/histogram.js +8 -16
- package/dist/components/chart/line-chart.js +2 -18
- package/dist/components/chart/lite-chart.d.ts +134 -3
- package/dist/components/chart/lite-chart.js +382 -67
- package/dist/components/chart/lite-chart.styles.js +9 -0
- package/dist/components/chart/pie-chart.js +2 -18
- package/dist/components/chart/polar-area-chart.js +2 -18
- package/dist/components/chart/radar-chart.js +2 -18
- package/dist/components/chart/scatter-chart.js +2 -18
- package/dist/components/chat-composer/chat-composer.d.ts +133 -0
- package/dist/components/chat-composer/chat-composer.js +366 -0
- package/dist/components/chat-composer/chat-composer.styles.d.ts +1 -0
- package/dist/components/chat-composer/chat-composer.styles.js +145 -0
- package/dist/components/chat-message/chat-message.d.ts +141 -0
- package/dist/components/chat-message/chat-message.js +331 -0
- package/dist/components/chat-message/chat-message.styles.d.ts +1 -0
- package/dist/components/chat-message/chat-message.styles.js +203 -0
- package/dist/components/checkbox/checkbox.d.ts +117 -0
- package/dist/components/checkbox/checkbox.js +353 -0
- package/dist/components/checkbox/checkbox.styles.d.ts +1 -0
- package/dist/components/checkbox/checkbox.styles.js +77 -0
- package/dist/components/chip/chip-group.d.ts +56 -0
- package/dist/components/chip/chip-group.js +130 -0
- package/dist/components/chip/chip-group.styles.d.ts +1 -0
- package/dist/components/chip/chip-group.styles.js +57 -0
- package/dist/components/chip/chip.d.ts +64 -0
- package/dist/components/chip/chip.js +122 -0
- package/dist/components/chip/chip.styles.d.ts +1 -0
- package/dist/components/chip/chip.styles.js +115 -0
- package/dist/components/citation-badge/citation-badge.d.ts +113 -0
- package/dist/components/citation-badge/citation-badge.js +318 -0
- package/dist/components/citation-badge/citation-badge.styles.d.ts +1 -0
- package/dist/components/citation-badge/citation-badge.styles.js +96 -0
- package/dist/components/code-block/code-block.d.ts +127 -0
- package/dist/components/code-block/code-block.js +382 -0
- package/dist/components/code-block/code-block.styles.d.ts +1 -0
- package/dist/components/code-block/code-block.styles.js +187 -0
- package/dist/components/code-block/code-loader.d.ts +87 -0
- package/dist/components/code-block/code-loader.js +142 -0
- package/dist/components/combobox/combobox.d.ts +65 -6
- package/dist/components/combobox/combobox.js +258 -48
- package/dist/components/combobox/combobox.styles.js +3 -3
- package/dist/components/combobox/option.d.ts +5 -1
- package/dist/components/combobox/option.js +35 -0
- package/dist/components/context-meter/context-meter.d.ts +53 -0
- package/dist/components/context-meter/context-meter.js +159 -0
- package/dist/components/context-meter/context-meter.styles.d.ts +1 -0
- package/dist/components/context-meter/context-meter.styles.js +114 -0
- package/dist/components/conversation-item/conversation-item.d.ts +125 -0
- package/dist/components/conversation-item/conversation-item.js +331 -0
- package/dist/components/conversation-item/conversation-item.styles.d.ts +1 -0
- package/dist/components/conversation-item/conversation-item.styles.js +155 -0
- package/dist/components/date-picker/calendar-core.d.ts +24 -0
- package/dist/components/date-picker/calendar-core.js +51 -4
- package/dist/components/date-picker/date-input.d.ts +100 -9
- package/dist/components/date-picker/date-input.js +383 -66
- package/dist/components/date-picker/date-picker.d.ts +35 -4
- package/dist/components/date-picker/date-picker.js +171 -44
- package/dist/components/dialog/confirm.d.ts +40 -0
- package/dist/components/dialog/confirm.js +76 -0
- package/dist/components/dialog/dialog.d.ts +129 -0
- package/dist/components/dialog/dialog.js +288 -0
- package/dist/components/dialog/dialog.styles.d.ts +1 -0
- package/dist/components/dialog/dialog.styles.js +96 -0
- package/dist/components/dock-panel/dock-panel.d.ts +142 -0
- package/dist/components/dock-panel/dock-panel.js +359 -0
- package/dist/components/dock-panel/dock-panel.styles.d.ts +1 -0
- package/dist/components/dock-panel/dock-panel.styles.js +159 -0
- package/dist/components/document-preview/document-preview.d.ts +143 -0
- package/dist/components/document-preview/document-preview.js +388 -0
- package/dist/components/document-preview/document-preview.styles.d.ts +1 -0
- package/dist/components/document-preview/document-preview.styles.js +191 -0
- package/dist/components/empty/empty.d.ts +1 -2
- package/dist/components/empty/empty.js +18 -12
- package/dist/components/empty/empty.styles.js +0 -3
- package/dist/components/export-button/csv.js +1 -1
- package/dist/components/export-button/export-button.d.ts +12 -0
- package/dist/components/export-button/export-button.js +35 -5
- package/dist/components/export-button/export-button.styles.js +5 -1
- package/dist/components/file-input/accept.js +2 -0
- package/dist/components/file-input/file-input.d.ts +10 -1
- package/dist/components/file-input/file-input.js +36 -5
- package/dist/components/flag/flag.d.ts +29 -13
- package/dist/components/flag/flag.js +54 -14
- package/dist/components/flag/flag.styles.js +1 -1
- package/dist/components/flag/language-map.d.ts +4 -1
- package/dist/components/flag/language-map.js +6 -3
- package/dist/components/gauge/gauge.d.ts +10 -1
- package/dist/components/gauge/gauge.js +41 -13
- package/dist/components/generation-status/generation-status.d.ts +117 -0
- package/dist/components/generation-status/generation-status.js +327 -0
- package/dist/components/generation-status/generation-status.styles.d.ts +1 -0
- package/dist/components/generation-status/generation-status.styles.js +84 -0
- package/dist/components/graph/graph.d.ts +37 -3
- package/dist/components/graph/graph.js +132 -20
- package/dist/components/heatmap/calendar-grid.d.ts +19 -7
- package/dist/components/heatmap/calendar-grid.js +42 -18
- package/dist/components/heatmap/heatmap-scale.d.ts +11 -1
- package/dist/components/heatmap/heatmap-scale.js +14 -2
- package/dist/components/heatmap/heatmap.d.ts +227 -12
- package/dist/components/heatmap/heatmap.js +488 -93
- package/dist/components/json-viewer/json-viewer.d.ts +70 -0
- package/dist/components/json-viewer/json-viewer.js +361 -0
- package/dist/components/json-viewer/json-viewer.styles.d.ts +1 -0
- package/dist/components/json-viewer/json-viewer.styles.js +177 -0
- package/dist/components/kbd/kbd.d.ts +77 -0
- package/dist/components/kbd/kbd.js +231 -0
- package/dist/components/kbd/kbd.styles.d.ts +1 -0
- package/dist/components/kbd/kbd.styles.js +52 -0
- package/dist/components/live-region/live-region.d.ts +90 -0
- package/dist/components/live-region/live-region.js +189 -0
- package/dist/components/live-region/live-region.styles.d.ts +1 -0
- package/dist/components/live-region/live-region.styles.js +10 -0
- package/dist/components/map/map.d.ts +32 -7
- package/dist/components/map/map.js +133 -32
- package/dist/components/markdown/markdown-loader.d.ts +58 -0
- package/dist/components/markdown/markdown-loader.js +77 -0
- package/dist/components/markdown/markdown.d.ts +119 -0
- package/dist/components/markdown/markdown.js +389 -0
- package/dist/components/markdown/markdown.styles.d.ts +1 -0
- package/dist/components/markdown/markdown.styles.js +88 -0
- package/dist/components/media-card/media-card.d.ts +130 -0
- package/dist/components/media-card/media-card.js +273 -0
- package/dist/components/media-card/media-card.styles.d.ts +1 -0
- package/dist/components/media-card/media-card.styles.js +132 -0
- package/dist/components/mention-popover/mention-popover.d.ts +203 -0
- package/dist/components/mention-popover/mention-popover.js +493 -0
- package/dist/components/mention-popover/mention-popover.styles.d.ts +1 -0
- package/dist/components/mention-popover/mention-popover.styles.js +101 -0
- package/dist/components/menu/menu-item.d.ts +91 -0
- package/dist/components/menu/menu-item.js +206 -0
- package/dist/components/menu/menu-item.styles.d.ts +1 -0
- package/dist/components/menu/menu-item.styles.js +75 -0
- package/dist/components/menu/menu.d.ts +167 -0
- package/dist/components/menu/menu.js +461 -0
- package/dist/components/menu/menu.styles.d.ts +1 -0
- package/dist/components/menu/menu.styles.js +67 -0
- package/dist/components/model-select/model-select.d.ts +170 -0
- package/dist/components/model-select/model-select.js +588 -0
- package/dist/components/model-select/model-select.styles.d.ts +1 -0
- package/dist/components/model-select/model-select.styles.js +203 -0
- package/dist/components/model-settings-panel/model-settings-panel.d.ts +93 -0
- package/dist/components/model-settings-panel/model-settings-panel.js +209 -0
- package/dist/components/model-settings-panel/model-settings-panel.styles.d.ts +1 -0
- package/dist/components/model-settings-panel/model-settings-panel.styles.js +82 -0
- package/dist/components/playback/playback.d.ts +19 -3
- package/dist/components/playback/playback.js +109 -33
- package/dist/components/playback/playback.styles.js +6 -1
- package/dist/components/responsive-panel/responsive-panel.d.ts +163 -0
- package/dist/components/responsive-panel/responsive-panel.js +363 -0
- package/dist/components/responsive-panel/responsive-panel.styles.d.ts +1 -0
- package/dist/components/responsive-panel/responsive-panel.styles.js +103 -0
- package/dist/components/result-card/result-card.d.ts +50 -0
- package/dist/components/result-card/result-card.js +89 -0
- package/dist/components/result-card/result-card.styles.d.ts +1 -0
- package/dist/components/result-card/result-card.styles.js +49 -0
- package/dist/components/result-card/result-field.d.ts +36 -0
- package/dist/components/result-card/result-field.js +87 -0
- package/dist/components/result-card/result-field.styles.d.ts +1 -0
- package/dist/components/result-card/result-field.styles.js +32 -0
- package/dist/components/select/select.d.ts +84 -4
- package/dist/components/select/select.js +251 -36
- package/dist/components/skeleton/skeleton.d.ts +3 -0
- package/dist/components/skeleton/skeleton.js +7 -1
- package/dist/components/skeleton/skeleton.styles.js +5 -4
- package/dist/components/slider/slider.d.ts +141 -0
- package/dist/components/slider/slider.js +467 -0
- package/dist/components/slider/slider.styles.d.ts +1 -0
- package/dist/components/slider/slider.styles.js +87 -0
- package/dist/components/source-card/source-card.d.ts +104 -0
- package/dist/components/source-card/source-card.js +195 -0
- package/dist/components/source-card/source-card.styles.d.ts +1 -0
- package/dist/components/source-card/source-card.styles.js +69 -0
- package/dist/components/source-list/source-list.d.ts +63 -0
- package/dist/components/source-list/source-list.js +130 -0
- package/dist/components/source-list/source-list.styles.d.ts +1 -0
- package/dist/components/source-list/source-list.styles.js +59 -0
- package/dist/components/sparkline/sparkline.js +58 -20
- package/dist/components/split/split.d.ts +224 -5
- package/dist/components/split/split.js +617 -43
- package/dist/components/split/split.styles.js +47 -0
- package/dist/components/stat/stat.d.ts +15 -4
- package/dist/components/stat/stat.js +53 -12
- package/dist/components/stream-status/stream-status.d.ts +126 -0
- package/dist/components/stream-status/stream-status.js +292 -0
- package/dist/components/stream-status/stream-status.styles.d.ts +1 -0
- package/dist/components/stream-status/stream-status.styles.js +103 -0
- package/dist/components/streaming-text/streaming-text.d.ts +104 -0
- package/dist/components/streaming-text/streaming-text.js +224 -0
- package/dist/components/streaming-text/streaming-text.styles.d.ts +1 -0
- package/dist/components/streaming-text/streaming-text.styles.js +63 -0
- package/dist/components/switch/switch.d.ts +103 -0
- package/dist/components/switch/switch.js +250 -0
- package/dist/components/switch/switch.styles.d.ts +1 -0
- package/dist/components/switch/switch.styles.js +75 -0
- package/dist/components/table/table.d.ts +89 -5
- package/dist/components/table/table.js +243 -26
- package/dist/components/table/table.styles.js +6 -1
- package/dist/components/tabs/tabs.d.ts +74 -0
- package/dist/components/tabs/tabs.js +254 -0
- package/dist/components/tabs/tabs.styles.d.ts +1 -0
- package/dist/components/tabs/tabs.styles.js +74 -0
- package/dist/components/thinking-panel/thinking-panel.d.ts +123 -0
- package/dist/components/thinking-panel/thinking-panel.js +260 -0
- package/dist/components/thinking-panel/thinking-panel.styles.d.ts +1 -0
- package/dist/components/thinking-panel/thinking-panel.styles.js +123 -0
- package/dist/components/time-range/time-range.d.ts +59 -2
- package/dist/components/time-range/time-range.js +163 -67
- package/dist/components/toast/toast-item.d.ts +12 -2
- package/dist/components/toast/toast-item.js +106 -44
- package/dist/components/toast/toast-item.styles.js +59 -28
- package/dist/components/toast/toast.js +17 -5
- package/dist/components/toast/toaster.js +10 -1
- package/dist/components/tool-approval-dialog/tool-approval-dialog.d.ts +131 -0
- package/dist/components/tool-approval-dialog/tool-approval-dialog.js +329 -0
- package/dist/components/tool-approval-dialog/tool-approval-dialog.styles.d.ts +1 -0
- package/dist/components/tool-approval-dialog/tool-approval-dialog.styles.js +160 -0
- package/dist/components/tool-call-chip/tool-call-chip.d.ts +105 -0
- package/dist/components/tool-call-chip/tool-call-chip.js +349 -0
- package/dist/components/tool-call-chip/tool-call-chip.styles.d.ts +1 -0
- package/dist/components/tool-call-chip/tool-call-chip.styles.js +203 -0
- package/dist/components/tool-param-form/tool-param-form.d.ts +206 -0
- package/dist/components/tool-param-form/tool-param-form.js +610 -0
- package/dist/components/tool-param-form/tool-param-form.styles.d.ts +1 -0
- package/dist/components/tool-param-form/tool-param-form.styles.js +75 -0
- package/dist/components/tool-result-dialog/tool-result-dialog.d.ts +122 -0
- package/dist/components/tool-result-dialog/tool-result-dialog.js +358 -0
- package/dist/components/tool-result-dialog/tool-result-dialog.styles.d.ts +1 -0
- package/dist/components/tool-result-dialog/tool-result-dialog.styles.js +176 -0
- package/dist/components/tool-result-view/registry.d.ts +73 -0
- package/dist/components/tool-result-view/registry.js +89 -0
- package/dist/components/tool-result-view/tool-result-view.d.ts +58 -0
- package/dist/components/tool-result-view/tool-result-view.js +152 -0
- package/dist/components/tool-result-view/tool-result-view.styles.d.ts +1 -0
- package/dist/components/tool-result-view/tool-result-view.styles.js +13 -0
- package/dist/components/tool-select-dialog/tool-select-dialog.d.ts +151 -0
- package/dist/components/tool-select-dialog/tool-select-dialog.js +350 -0
- package/dist/components/tool-select-dialog/tool-select-dialog.styles.d.ts +1 -0
- package/dist/components/tool-select-dialog/tool-select-dialog.styles.js +191 -0
- package/dist/components/tree/tree-node.d.ts +15 -3
- package/dist/components/tree/tree-node.js +20 -7
- package/dist/components/tree/tree.d.ts +25 -10
- package/dist/components/tree/tree.js +39 -31
- package/dist/components/typing-indicator/typing-indicator.d.ts +70 -0
- package/dist/components/typing-indicator/typing-indicator.js +108 -0
- package/dist/components/typing-indicator/typing-indicator.styles.d.ts +1 -0
- package/dist/components/typing-indicator/typing-indicator.styles.js +132 -0
- package/dist/components/virtual-list/virtual-list.d.ts +210 -0
- package/dist/components/virtual-list/virtual-list.js +607 -0
- package/dist/components/virtual-list/virtual-list.styles.d.ts +1 -0
- package/dist/components/virtual-list/virtual-list.styles.js +56 -0
- package/dist/components/widget/widget.d.ts +5 -4
- package/dist/components/widget/widget.js +54 -120
- package/dist/components/widget/widget.styles.js +8 -2
- package/dist/components/word-cloud/word-cloud-layout.d.ts +7 -0
- package/dist/components/word-cloud/word-cloud-layout.js +29 -2
- package/dist/components/word-cloud/word-cloud.d.ts +28 -2
- package/dist/components/word-cloud/word-cloud.js +69 -19
- package/dist/components/word-cloud/word-cloud.styles.js +16 -3
- package/dist/internal/anchored-validity.d.ts +1 -0
- package/dist/internal/anchored-validity.js +86 -0
- package/dist/internal/announcer.d.ts +57 -0
- package/dist/internal/announcer.js +71 -0
- package/dist/internal/form-associated.d.ts +8 -0
- package/dist/internal/form-associated.js +98 -15
- package/dist/internal/group-by-recency.d.ts +50 -0
- package/dist/internal/group-by-recency.js +80 -0
- package/dist/internal/numbers.d.ts +12 -0
- package/dist/internal/numbers.js +26 -0
- package/dist/internal/overlay-manager.d.ts +51 -0
- package/dist/internal/overlay-manager.js +523 -0
- package/dist/internal/positioner.js +27 -3
- package/dist/internal/rtl.d.ts +23 -0
- package/dist/internal/rtl.js +28 -0
- package/dist/internal/safe-url.d.ts +12 -0
- package/dist/internal/safe-url.js +41 -0
- package/dist/internal/scroll-lock.d.ts +10 -5
- package/dist/internal/scroll-lock.js +30 -14
- package/dist/internal/tokens.styles.js +22 -10
- package/dist/lyra.d.ts +133 -31
- package/dist/lyra.js +96 -26
- package/llms-full.txt +4546 -183
- package/llms.txt +21 -5
- package/package.json +41 -6
- package/dist/components/chart/bar-chart.stories.d.ts +0 -5
- package/dist/components/chart/bar-chart.stories.js +0 -20
- package/dist/components/chart/box-plot.stories.d.ts +0 -5
- package/dist/components/chart/box-plot.stories.js +0 -29
- package/dist/components/chart/bubble-chart.stories.d.ts +0 -5
- package/dist/components/chart/bubble-chart.stories.js +0 -26
- package/dist/components/chart/chart.stories.d.ts +0 -32
- package/dist/components/chart/chart.stories.js +0 -141
- package/dist/components/chart/doughnut-chart.stories.d.ts +0 -5
- package/dist/components/chart/doughnut-chart.stories.js +0 -26
- package/dist/components/chart/histogram.stories.d.ts +0 -5
- package/dist/components/chart/histogram.stories.js +0 -17
- package/dist/components/chart/line-chart.stories.d.ts +0 -22
- package/dist/components/chart/line-chart.stories.js +0 -99
- package/dist/components/chart/lite-chart.stories.d.ts +0 -14
- package/dist/components/chart/lite-chart.stories.js +0 -114
- package/dist/components/chart/pie-chart.stories.d.ts +0 -5
- package/dist/components/chart/pie-chart.stories.js +0 -26
- package/dist/components/chart/polar-area-chart.stories.d.ts +0 -5
- package/dist/components/chart/polar-area-chart.stories.js +0 -20
- package/dist/components/chart/radar-chart.stories.d.ts +0 -5
- package/dist/components/chart/radar-chart.stories.js +0 -20
- package/dist/components/chart/scatter-chart.stories.d.ts +0 -5
- package/dist/components/chart/scatter-chart.stories.js +0 -31
- package/dist/components/combobox/combobox.stories.d.ts +0 -24
- package/dist/components/combobox/combobox.stories.js +0 -102
- package/dist/components/date-picker/date-input.stories.d.ts +0 -10
- package/dist/components/date-picker/date-input.stories.js +0 -48
- package/dist/components/date-picker/date-picker.stories.d.ts +0 -10
- package/dist/components/date-picker/date-picker.stories.js +0 -25
- package/dist/components/empty/empty.stories.d.ts +0 -7
- package/dist/components/empty/empty.stories.js +0 -34
- package/dist/components/export-button/export-button.stories.d.ts +0 -7
- package/dist/components/export-button/export-button.stories.js +0 -37
- package/dist/components/file-input/file-input.stories.d.ts +0 -7
- package/dist/components/file-input/file-input.stories.js +0 -19
- package/dist/components/flag/flag.stories.d.ts +0 -6
- package/dist/components/flag/flag.stories.js +0 -31
- package/dist/components/gauge/gauge.stories.d.ts +0 -8
- package/dist/components/gauge/gauge.stories.js +0 -19
- package/dist/components/graph/graph.stories.d.ts +0 -8
- package/dist/components/graph/graph.stories.js +0 -68
- package/dist/components/heatmap/heatmap.stories.d.ts +0 -27
- package/dist/components/heatmap/heatmap.stories.js +0 -179
- package/dist/components/map/map.stories.d.ts +0 -15
- package/dist/components/map/map.stories.js +0 -135
- package/dist/components/playback/playback.stories.d.ts +0 -7
- package/dist/components/playback/playback.stories.js +0 -16
- package/dist/components/select/select.stories.d.ts +0 -21
- package/dist/components/select/select.stories.js +0 -91
- package/dist/components/skeleton/skeleton.stories.d.ts +0 -5
- package/dist/components/skeleton/skeleton.stories.js +0 -16
- package/dist/components/sparkline/sparkline.stories.d.ts +0 -11
- package/dist/components/sparkline/sparkline.stories.js +0 -39
- package/dist/components/split/split.stories.d.ts +0 -7
- package/dist/components/split/split.stories.js +0 -36
- package/dist/components/stat/stat.stories.d.ts +0 -9
- package/dist/components/stat/stat.stories.js +0 -81
- package/dist/components/table/table.stories.d.ts +0 -12
- package/dist/components/table/table.stories.js +0 -67
- package/dist/components/time-range/time-range.stories.d.ts +0 -8
- package/dist/components/time-range/time-range.stories.js +0 -26
- package/dist/components/toast/toast.stories.d.ts +0 -8
- package/dist/components/toast/toast.stories.js +0 -72
- package/dist/components/tree/tree.stories.d.ts +0 -9
- package/dist/components/tree/tree.stories.js +0 -52
- package/dist/components/widget/widget.stories.d.ts +0 -9
- package/dist/components/widget/widget.stories.js +0 -74
- package/dist/components/word-cloud/word-cloud.stories.d.ts +0 -10
- package/dist/components/word-cloud/word-cloud.stories.js +0 -55
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import { type PropertyValues, type TemplateResult } from 'lit';
|
|
2
2
|
import { LyraElement } from '../../internal/lyra-element.js';
|
|
3
3
|
import { type CalendarDay } from './calendar-grid.js';
|
|
4
|
+
/**
|
|
5
|
+
* A linear RGB ramp cannot contain more than 256 visually distinct integer
|
|
6
|
+
* steps on any channel. Keeping the bucket count within that bound avoids an
|
|
7
|
+
* untrusted attribute/property value turning the ramp into an unbounded
|
|
8
|
+
* allocation without discarding any useful color resolution.
|
|
9
|
+
*/
|
|
10
|
+
export declare const MAX_BUCKET_COUNT = 256;
|
|
4
11
|
/** A cell cursor in matrix mode. */
|
|
5
12
|
export interface MatrixCellPos {
|
|
6
13
|
row: number;
|
|
@@ -30,6 +37,13 @@ export interface HeatmapAnnotation {
|
|
|
30
37
|
* string to `0` via `Number.parseInt(..., 16)` returning `NaN`).
|
|
31
38
|
*/
|
|
32
39
|
export declare function hexToRgb(hex: string): [number, number, number] | null;
|
|
40
|
+
/**
|
|
41
|
+
* Normalizes a bucket count to the safe, renderable range. Non-finite values
|
|
42
|
+
* restore the public default; finite values are floored and clamped to
|
|
43
|
+
* `[2, MAX_BUCKET_COUNT]`. Flooring keeps the ramp array's length in exact
|
|
44
|
+
* agreement with the count used by `quartileBucket()`.
|
|
45
|
+
*/
|
|
46
|
+
export declare function normalizeBucketCount(bucketCount: number): number;
|
|
33
47
|
/**
|
|
34
48
|
* Resolves any syntactically valid CSS `<color>` — hex, `rgb()`, `hsl()`,
|
|
35
49
|
* `oklch()`, a named color, etc. — to an `[r, g, b]` triple.
|
|
@@ -54,12 +68,16 @@ export declare function mixColor(fromColor: string, toColor: string, t: number):
|
|
|
54
68
|
* - `"matrix"` (default): a `rowLabels` x `colLabels` grid of `values`. `-1`
|
|
55
69
|
* (or any non-finite value) is treated as "no data". `scale="sqrt"`
|
|
56
70
|
* compresses the ramp via `sqrtStep()` so one heavy cell doesn't wash out
|
|
57
|
-
* the rest; the default `"linear"` scale maps linearly instead.
|
|
58
|
-
*
|
|
59
|
-
*
|
|
60
|
-
* `
|
|
61
|
-
*
|
|
62
|
-
*
|
|
71
|
+
* the rest; the default `"linear"` scale maps linearly instead.
|
|
72
|
+
* - `"calendar"`: a GitHub-style Sunday-Saturday (or `firstDayOfWeek`-anchored
|
|
73
|
+
* — see below) x week grid built from `days`. `scale` governs its
|
|
74
|
+
* bucketing too: the default `"linear"` buckets by `quartileBucket()`
|
|
75
|
+
* (today's original behavior, unchanged); `"sqrt"` instead compresses via
|
|
76
|
+
* the same `sqrtStep()` magnitude compression matrix mode uses, so one
|
|
77
|
+
* heavy day doesn't wash out the rest. As in matrix mode, a cell whose
|
|
78
|
+
* `value` is negative or non-finite is treated as "no data" rather than
|
|
79
|
+
* being bucketed — as is a grid position with no matching entry in `days`
|
|
80
|
+
* at all (a gap in a sparse calendar).
|
|
63
81
|
*
|
|
64
82
|
* The sequential color ramp's endpoints are read from the
|
|
65
83
|
* `--lyra-heatmap-scale-lo`/`-hi` custom properties (declared in
|
|
@@ -79,45 +97,150 @@ export declare function mixColor(fromColor: string, toColor: string, t: number):
|
|
|
79
97
|
* specific cells (e.g. to call out an anomaly), each one optionally
|
|
80
98
|
* surfaced in the legend too via `[part="legend-annotation"]`.
|
|
81
99
|
*
|
|
100
|
+
* `columnX` (calendar mode only) overrides the x-origin computed for each
|
|
101
|
+
* week column — drawing, hit-testing, the focus ring, and month-label
|
|
102
|
+
* positioning all consult it consistently, so a consumer can pixel-align a
|
|
103
|
+
* calendar's week columns with a sibling chart's coordinate system. Unset
|
|
104
|
+
* (the default) keeps the original evenly-spaced formula. `rowY` is its
|
|
105
|
+
* calendar-mode vertical analogue — overrides the y-origin computed for each
|
|
106
|
+
* weekday row, consulted consistently by drawing, hit-testing, and the focus
|
|
107
|
+
* ring via the private `rowYFor()` helper (mirroring `columnXFor()` exactly).
|
|
108
|
+
*
|
|
109
|
+
* `firstDayOfWeek` (calendar mode only, default `0`/Sunday, no-op in matrix
|
|
110
|
+
* mode) anchors the calendar grid at a different weekday — `0`-`6`, same
|
|
111
|
+
* numbering as `CalendarCellPos.weekday` (`0` Sunday .. `6` Saturday) —
|
|
112
|
+
* threaded into `buildCalendarGrid()`.
|
|
113
|
+
*
|
|
114
|
+
* `cellSize`/`fitToWidth` (previously matrix-mode only) also drive calendar
|
|
115
|
+
* mode's per-cell size: unset, calendar mode keeps today's original 11px
|
|
116
|
+
* cell size unchanged; explicitly set, the same fixed size (or, with
|
|
117
|
+
* `fitToWidth`, the same host-width-derived size matrix mode already
|
|
118
|
+
* supports) governs calendar mode's grid too.
|
|
119
|
+
*
|
|
82
120
|
* @customElement lyra-heatmap
|
|
83
121
|
* @event lyra-cell-click - Fired on click, or Enter/Space on the
|
|
84
122
|
* focused/hovered cell. `detail: { row, col, value }` in matrix mode,
|
|
85
123
|
* `detail: { date, value }` in calendar mode. `cellText` overrides the
|
|
86
124
|
* built-in English "Row X, Col Y: value" / "Mon DD: value" template used for
|
|
87
125
|
* both the hover tooltip and the keyboard live-region announcement.
|
|
88
|
-
* @csspart base
|
|
126
|
+
* @csspart base - The heatmap wrapper.
|
|
127
|
+
* @csspart canvas - The heatmap canvas.
|
|
128
|
+
* @csspart tooltip - The hover tooltip.
|
|
129
|
+
* @csspart live-region - The visually hidden keyboard announcement region.
|
|
130
|
+
* @csspart legend - The color legend.
|
|
131
|
+
* @csspart legend-lo - The low legend endpoint.
|
|
132
|
+
* @csspart legend-hi - The high legend endpoint.
|
|
133
|
+
* @csspart legend-annotation - An annotation label.
|
|
89
134
|
*/
|
|
90
135
|
export declare class LyraHeatmap extends LyraElement {
|
|
91
136
|
static styles: import("lit").CSSResultGroup[];
|
|
92
137
|
rowLabels: string[];
|
|
93
138
|
colLabels: string[];
|
|
94
139
|
values: number[][];
|
|
95
|
-
|
|
140
|
+
private _cellSize?;
|
|
141
|
+
/**
|
|
142
|
+
* Effective per-cell size (CSS px). Originally matrix-mode only; now also
|
|
143
|
+
* governs calendar mode's cell size (replacing the previously hardcoded
|
|
144
|
+
* 11px constant there) once explicitly set. Left unset, each mode keeps
|
|
145
|
+
* its own original default — `DEFAULT_MATRIX_CELL_SIZE` (22) in matrix
|
|
146
|
+
* mode, `CAL_CELL` (11) in calendar mode — so an existing consumer who
|
|
147
|
+
* never touches `cellSize` sees no change in either mode. Set explicitly
|
|
148
|
+
* (attribute or property), the same value governs both modes alike.
|
|
149
|
+
*/
|
|
150
|
+
get cellSize(): number;
|
|
151
|
+
set cellSize(value: number);
|
|
96
152
|
valueLabel: string;
|
|
153
|
+
/**
|
|
154
|
+
* `"linear"` (default) maps values linearly to the color ramp in matrix
|
|
155
|
+
* mode, and buckets calendar-mode values via `quartileBucket()` — both
|
|
156
|
+
* unchanged from before this property governed calendar mode too.
|
|
157
|
+
* `"sqrt"` compresses via `sqrtStep()`'s square-root magnitude compression
|
|
158
|
+
* instead, in *both* modes, so one heavy cell/day doesn't wash out the
|
|
159
|
+
* rest of a skewed dataset.
|
|
160
|
+
*/
|
|
97
161
|
scale: 'linear' | 'sqrt';
|
|
98
162
|
/**
|
|
99
163
|
* When set, `cellSize` is derived from the host's measured `clientWidth`
|
|
100
164
|
* on every draw (including ResizeObserver-triggered redraws) instead of
|
|
101
165
|
* the fixed `cell-size` attribute, so the grid actually fills the
|
|
102
166
|
* available width. Without this, canvas dimensions are computed purely
|
|
103
|
-
* from `PAD_LEFT + cols * cellSize
|
|
104
|
-
*
|
|
167
|
+
* from `PAD_LEFT + cols * cellSize` (matrix mode) or
|
|
168
|
+
* `CAL_PAD_LEFT + weekCount * cellSize` (calendar mode), so a
|
|
169
|
+
* resize-triggered redraw is a geometric no-op. Originally matrix-mode
|
|
170
|
+
* only; now applies to calendar mode too.
|
|
105
171
|
*/
|
|
106
172
|
fitToWidth: boolean;
|
|
107
173
|
mode: 'matrix' | 'calendar';
|
|
108
174
|
days: CalendarDay[];
|
|
109
|
-
|
|
175
|
+
/**
|
|
176
|
+
* Calendar mode only (no-op in matrix mode): anchors the calendar grid at
|
|
177
|
+
* a different weekday instead of always Sunday — `0`-`6`, same numbering
|
|
178
|
+
* as `CalendarCellPos.weekday` (`0` Sunday .. `6` Saturday, matching
|
|
179
|
+
* `CalendarCell.weekday`'s existing convention). Threaded into
|
|
180
|
+
* `buildCalendarGrid()`. Defaults to `0` (Sunday), unchanged from before
|
|
181
|
+
* this property existed.
|
|
182
|
+
*/
|
|
183
|
+
firstDayOfWeek: number;
|
|
184
|
+
private _bucketCount;
|
|
185
|
+
get bucketCount(): number;
|
|
186
|
+
set bucketCount(value: number);
|
|
110
187
|
/** Cells to ring-highlight — `row`/`col` in matrix mode, `date` in calendar mode. See `HeatmapAnnotation`. */
|
|
111
188
|
annotations: HeatmapAnnotation[];
|
|
112
189
|
/** Formats the per-cell tooltip and keyboard live-region text — receives the cell position
|
|
113
190
|
* (`MatrixCellPos` in matrix mode, `CalendarCellPos` in calendar mode) and its value. Falls back to
|
|
114
191
|
* the built-in English "Row X, Col Y: value" / "Mon DD: value" template when unset. */
|
|
115
192
|
cellText?: (pos: MatrixCellPos | CalendarCellPos, value: number) => string;
|
|
193
|
+
/**
|
|
194
|
+
* Calendar mode only: overrides the x-origin (canvas-local CSS px) of week
|
|
195
|
+
* column `index` (0-based, same indexing as `CalendarCellPos.week`).
|
|
196
|
+
* Consulted consistently by every calendar-mode geometry call site —
|
|
197
|
+
* drawing, hit-testing, the keyboard focus ring, and month-label
|
|
198
|
+
* positioning — via the private `columnXFor()` helper, so painted
|
|
199
|
+
* geometry and pointer hit-testing never disagree. Lets a consumer
|
|
200
|
+
* pixel-align a calendar's week columns with a sibling chart's bars by
|
|
201
|
+
* supplying that chart the same coordinate function. Unset (the default)
|
|
202
|
+
* keeps today's evenly-spaced `CAL_PAD_LEFT + week * (CAL_CELL + CAL_GAP)`
|
|
203
|
+
* formula unchanged. Ignored in matrix mode.
|
|
204
|
+
*/
|
|
205
|
+
columnX?: (index: number) => number;
|
|
206
|
+
/**
|
|
207
|
+
* Calendar mode only: overrides the y-origin (canvas-local CSS px) of
|
|
208
|
+
* weekday row `weekday` (0-based, same indexing as
|
|
209
|
+
* `CalendarCellPos.weekday`). The vertical analogue of `columnX` — consulted
|
|
210
|
+
* consistently by every calendar-mode geometry call site that computes a
|
|
211
|
+
* cell's y-coordinate from its weekday — drawing, hit-testing, and the
|
|
212
|
+
* keyboard focus ring — via the private `rowYFor()` helper (mirroring
|
|
213
|
+
* `columnXFor()`'s exact dispatch-with-computed-fallback shape). Also
|
|
214
|
+
* consulted at `weekday = 7` (one past the last row) to size the canvas's
|
|
215
|
+
* height, mirroring how `columnX` is consulted at `week = weekCount` to
|
|
216
|
+
* size its width — so a function that spaces rows out further than the
|
|
217
|
+
* default formula still gets a canvas tall enough to paint every row.
|
|
218
|
+
* Unset (the default) keeps today's evenly-spaced `CAL_LABEL_H + weekday *
|
|
219
|
+
* (cellSize + CAL_GAP)` formula unchanged. Ignored in matrix mode.
|
|
220
|
+
*/
|
|
221
|
+
rowY?: (weekday: number) => number;
|
|
116
222
|
private canvas?;
|
|
117
223
|
private resizeObserver?;
|
|
224
|
+
private drawRafId?;
|
|
118
225
|
private dprQuery?;
|
|
226
|
+
private colorSchemeQuery?;
|
|
227
|
+
private themeObserver?;
|
|
228
|
+
private themeRefreshQueued;
|
|
119
229
|
/** The current value range, refreshed once per update cycle by `willUpdate()`. See `computeValueRange()`. */
|
|
120
230
|
private cachedValueRange;
|
|
231
|
+
/**
|
|
232
|
+
* The calendar-mode grid layout, refreshed by `willUpdate()` only when
|
|
233
|
+
* `days` actually changes (see `computeValueRange()`'s twin comment above)
|
|
234
|
+
* — `buildCalendarGrid()` parses every date, filters invalid ones, and does
|
|
235
|
+
* a full `.slice().sort()` for month labels, so recomputing it from
|
|
236
|
+
* `drawCalendar()`, `hitTestCalendar()`, `calendarCellAt()`, and
|
|
237
|
+
* `onCalendarKeyDown()` independently would redo that work 2-4x for a
|
|
238
|
+
* single hover/click/keydown.
|
|
239
|
+
*/
|
|
240
|
+
private cachedCalendarGrid;
|
|
241
|
+
private cachedCalendarSortedValues;
|
|
242
|
+
private cachedCalendarCellsByPos;
|
|
243
|
+
private cachedRamp;
|
|
121
244
|
/** The cell currently under the pointer (`null` when not hovering one) — drives `[part="tooltip"]`. */
|
|
122
245
|
private hoverCell;
|
|
123
246
|
/** The roving keyboard-focus cell cursor, moved by arrow keys — drives the
|
|
@@ -125,10 +248,26 @@ export declare class LyraHeatmap extends LyraElement {
|
|
|
125
248
|
private focusedCell;
|
|
126
249
|
/** Text of the visually-hidden `aria-live="polite"` status announcement, refreshed on every focus move. */
|
|
127
250
|
private liveText;
|
|
251
|
+
/**
|
|
252
|
+
* Whether `role`/`aria-label` were present on the host *before* this
|
|
253
|
+
* element's own code ever wrote to them — snapshotted once, in the very
|
|
254
|
+
* first `willUpdate()` (guarded by `hasUpdated`, which Lit only flips to
|
|
255
|
+
* `true` after that first update commits). Re-checking `hasAttribute()` on
|
|
256
|
+
* every update instead would self-poison: once this element writes its own
|
|
257
|
+
* default `aria-label` on the first render, `hasAttribute('aria-label')`
|
|
258
|
+
* is permanently `true` afterwards, which would wrongly look like an
|
|
259
|
+
* author-supplied value and freeze the label instead of refreshing it as
|
|
260
|
+
* `values`/`days` change on later updates.
|
|
261
|
+
*/
|
|
262
|
+
private authorSuppliedRole;
|
|
263
|
+
private authorSuppliedAriaLabel;
|
|
128
264
|
connectedCallback(): void;
|
|
129
265
|
disconnectedCallback(): void;
|
|
130
266
|
private watchDpr;
|
|
131
267
|
private onDprChange;
|
|
268
|
+
private onColorSchemeChange;
|
|
269
|
+
private queueThemeRefresh;
|
|
270
|
+
private watchTheme;
|
|
132
271
|
protected willUpdate(changed: PropertyValues): void;
|
|
133
272
|
/**
|
|
134
273
|
* The real (non-no-data) value range across `values` (or `days` in
|
|
@@ -140,7 +279,9 @@ export declare class LyraHeatmap extends LyraElement {
|
|
|
140
279
|
* suffices instead of one per consumer.
|
|
141
280
|
*/
|
|
142
281
|
private computeValueRange;
|
|
143
|
-
protected updated(): void;
|
|
282
|
+
protected updated(changed: PropertyValues): void;
|
|
283
|
+
/** Redraws canvas content after an upstream token or theme change. */
|
|
284
|
+
refreshTheme(): void;
|
|
144
285
|
/** Reads the customizable ramp endpoints off the host's computed style. */
|
|
145
286
|
private scaleEndpoints;
|
|
146
287
|
/** Resolves the `--lyra-color-text-quiet` chrome token for axis labels. */
|
|
@@ -154,6 +295,72 @@ export declare class LyraHeatmap extends LyraElement {
|
|
|
154
295
|
/** Reads the customizable canvas-drawn annotation-ring stroke color off the host's computed style. */
|
|
155
296
|
private annotationColor;
|
|
156
297
|
private draw;
|
|
298
|
+
private scheduleDraw;
|
|
299
|
+
private colorRamp;
|
|
300
|
+
/**
|
|
301
|
+
* Effective per-cell size in calendar mode — mirrors `matrixCellSize()`
|
|
302
|
+
* exactly: `fitToWidth` derives it from the host's measured width,
|
|
303
|
+
* otherwise it's the (possibly explicitly-set) `cellSize` property, which
|
|
304
|
+
* itself falls back to today's original 11px calendar default when left
|
|
305
|
+
* unset (see `cellSize`'s accessor doc comment). Shared by `columnXFor()`,
|
|
306
|
+
* `rowYFor()`, `drawCalendar()`, and the hit-testing below (`weekAtX()`,
|
|
307
|
+
* `weekdayAtY()`, `cellRect()`) so they always agree on exactly the same
|
|
308
|
+
* geometry as what's actually painted.
|
|
309
|
+
*/
|
|
310
|
+
private calendarCellSize;
|
|
311
|
+
/**
|
|
312
|
+
* Calendar-mode week-column x-origin (canvas-local CSS px) — `columnX(week)`
|
|
313
|
+
* when set, otherwise the original evenly-spaced formula (now derived from
|
|
314
|
+
* `calendarCellSize()` rather than the fixed `CAL_CELL` constant). Shared
|
|
315
|
+
* by every calendar-mode drawing and hit-testing call site (`drawCalendar()`,
|
|
316
|
+
* `hitTestCalendar()`/`weekAtX()`, `cellRect()`) so painted geometry and
|
|
317
|
+
* interactive hit-testing never disagree — mirrors the existing
|
|
318
|
+
* `matrixCellSize()` invariant for matrix mode's
|
|
319
|
+
* `drawMatrix()`/`hitTestMatrix()`/`cellRect()`.
|
|
320
|
+
*/
|
|
321
|
+
private columnXFor;
|
|
322
|
+
/**
|
|
323
|
+
* Calendar-mode weekday-row y-origin (canvas-local CSS px) — `rowY(weekday)`
|
|
324
|
+
* when set, otherwise the original evenly-spaced formula (now derived from
|
|
325
|
+
* `calendarCellSize()` rather than the fixed `CAL_CELL` constant). The
|
|
326
|
+
* vertical analogue of `columnXFor()`, mirroring its exact
|
|
327
|
+
* dispatch-with-computed-fallback shape and shared by the same
|
|
328
|
+
* drawing/hit-testing/focus-ring call sites.
|
|
329
|
+
*/
|
|
330
|
+
private rowYFor;
|
|
331
|
+
/**
|
|
332
|
+
* Inverse of `columnXFor()`: resolves an x position (canvas-local CSS px)
|
|
333
|
+
* to the week column it falls in, or `null` if it's outside every column
|
|
334
|
+
* (`weekCount` is 0, or `x` doesn't land inside `[0, weekCount)`'s span).
|
|
335
|
+
* The default spacing has a closed-form inverse (division); an arbitrary
|
|
336
|
+
* `columnX` override doesn't, so that case instead scans each column's
|
|
337
|
+
* `[columnXFor(week), columnXFor(week + 1))` span — algebraically the same
|
|
338
|
+
* span the default formula's division derives — so hit-testing always
|
|
339
|
+
* agrees with wherever `columnXFor()` actually painted that column.
|
|
340
|
+
*/
|
|
341
|
+
private weekAtX;
|
|
342
|
+
/**
|
|
343
|
+
* Inverse of `rowYFor()`: resolves a y position (canvas-local CSS px) to
|
|
344
|
+
* the weekday row it falls in (0-6), or `null` if it's outside every row.
|
|
345
|
+
* Mirrors `weekAtX()`'s closed-form-vs-scan split for the same reason: the
|
|
346
|
+
* default spacing has a closed-form inverse; an arbitrary `rowY` override
|
|
347
|
+
* doesn't.
|
|
348
|
+
*/
|
|
349
|
+
private weekdayAtY;
|
|
350
|
+
/**
|
|
351
|
+
* Locale-derived weekday-axis labels for the 7 rows drawn down the left of
|
|
352
|
+
* the calendar grid. Only indices 1, 3, and 5 (relative to `firstWeekStart`)
|
|
353
|
+
* are filled in — matching today's sparse every-other-day label density —
|
|
354
|
+
* the rest stay blank. `firstWeekStart` is always the UTC
|
|
355
|
+
* `firstDayOfWeek`-weekday by construction (see `buildCalendarGrid()`), so
|
|
356
|
+
* weekday index 0..6 is a fixed positional mapping relative to it (with the
|
|
357
|
+
* default `firstDayOfWeek` of 0, that's the original Sun..Sat mapping,
|
|
358
|
+
* unchanged); only the label *text* for indices 1/3/5 is derived here, via
|
|
359
|
+
* `Intl.DateTimeFormat` on a real UTC date that actually falls on that
|
|
360
|
+
* weekday, so it follows the runtime locale instead of a hardcoded English
|
|
361
|
+
* array (see `calendarCellText()`'s tooltip text for the same pattern).
|
|
362
|
+
*/
|
|
363
|
+
private weekdayLabels;
|
|
157
364
|
private drawCalendar;
|
|
158
365
|
/**
|
|
159
366
|
* Effective per-cell size in matrix mode — `fitToWidth` derives it from
|
|
@@ -207,6 +414,14 @@ export declare class LyraHeatmap extends LyraElement {
|
|
|
207
414
|
private emitCellClick;
|
|
208
415
|
/** Inline `style` for `[part="tooltip"]`, centered above the given cell. */
|
|
209
416
|
private tooltipStyle;
|
|
417
|
+
/**
|
|
418
|
+
* Value-equality check for a `CellPos`, since `hoverCell` is assigned a
|
|
419
|
+
* fresh object literal on every `pointermove` — Lit's `@state()`
|
|
420
|
+
* change-detection only no-ops an identical *reference*, so without this,
|
|
421
|
+
* `{row,col} !== {row,col}` by reference triggers a full canvas clear +
|
|
422
|
+
* redraw on every pixel of pointer movement, even within the same cell.
|
|
423
|
+
*/
|
|
424
|
+
private samePos;
|
|
210
425
|
private onPointerMove;
|
|
211
426
|
private onPointerLeave;
|
|
212
427
|
private onCanvasClick;
|