@aceshooting/lyra-ui 9.1.1 → 11.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 +785 -0
- package/custom-elements.json +1 -1
- package/design-tokens.json +13 -0
- package/dist/cli/migrate-wa.mjs +216 -1
- package/dist/cli/migration-contract.json +1 -1
- package/dist/components/agent-tools/activity-feed/activity-feed.class.js +1 -1
- package/dist/components/agent-tools/activity-feed/activity-feed.styles.js +0 -16
- package/dist/components/agent-tools/agent-eval-dashboard/agent-eval-dashboard.class.js +1 -1
- package/dist/components/agent-tools/agent-eval-dashboard/agent-eval-dashboard.styles.js +7 -5
- package/dist/components/agent-tools/agent-run/agent-run.class.js +2 -2
- package/dist/components/agent-tools/agent-run/agent-run.styles.js +0 -13
- package/dist/components/agent-tools/agent-trace/agent-trace.styles.js +7 -4
- package/dist/components/agent-tools/approval-queue/approval-queue.styles.js +7 -5
- package/dist/components/agent-tools/artifact-panel/artifact-panel.styles.js +0 -3
- package/dist/components/agent-tools/browser-frame/browser-frame.styles.js +3 -5
- package/dist/components/agent-tools/commit-card/commit-card.styles.js +0 -10
- package/dist/components/agent-tools/compare-panel/compare-panel.styles.js +11 -6
- package/dist/components/agent-tools/confirm-bar/confirm-bar.styles.js +0 -46
- package/dist/components/agent-tools/eval-dataset/eval-dataset.styles.js +0 -7
- package/dist/components/agent-tools/evaluation-run/evaluation-run.class.js +2 -2
- package/dist/components/agent-tools/prompt-studio/prompt-studio.styles.js +0 -15
- package/dist/components/agent-tools/result-card/result-card.styles.js +0 -7
- package/dist/components/agent-tools/result-card/result-field.styles.js +0 -5
- package/dist/components/agent-tools/schema-viewer/schema-viewer.styles.js +0 -3
- package/dist/components/agent-tools/span-waterfall/span-waterfall.styles.js +0 -15
- package/dist/components/agent-tools/stack-trace/stack-trace.styles.js +0 -20
- package/dist/components/agent-tools/subagent-panel/subagent-panel.class.js +2 -2
- package/dist/components/agent-tools/subagent-panel/subagent-panel.styles.js +0 -3
- package/dist/components/agent-tools/task-list/task-list.styles.js +0 -15
- package/dist/components/agent-tools/terminal/terminal.class.d.ts +11 -6
- package/dist/components/agent-tools/terminal/terminal.class.js +4 -4
- package/dist/components/agent-tools/terminal/terminal.styles.js +0 -46
- package/dist/components/agent-tools/test-results/test-results.class.js +2 -2
- package/dist/components/agent-tools/test-results/test-results.styles.js +0 -5
- package/dist/components/agent-tools/thinking-panel/thinking-panel.styles.js +0 -41
- package/dist/components/agent-tools/tool-approval-dialog/tool-approval-dialog.styles.js +0 -41
- package/dist/components/agent-tools/tool-call-chip/tool-call-chip.styles.js +0 -30
- package/dist/components/agent-tools/tool-param-form/tool-param-form.class.js +6 -6
- package/dist/components/agent-tools/tool-param-form/tool-param-form.styles.js +0 -5
- package/dist/components/agent-tools/tool-result-dialog/tool-result-dialog.styles.js +0 -20
- package/dist/components/agent-tools/tool-result-view/tool-result-view.styles.js +0 -4
- package/dist/components/agent-tools/tool-select-dialog/tool-select-dialog.styles.js +0 -21
- package/dist/components/agent-tools/trace-tree/trace-tree.styles.js +7 -31
- package/dist/components/charts/chart/box-plot.class.d.ts +27 -0
- package/dist/components/charts/chart/box-plot.class.js +14 -4
- package/dist/components/charts/chart/box-plot.styles.js +28 -20
- package/dist/components/charts/chart/chart-colors.d.ts +1 -1
- package/dist/components/charts/chart/chart-colors.js +1 -1
- package/dist/components/charts/chart/chart-core-loader.d.ts +1 -0
- package/dist/components/charts/chart/chart-core-loader.js +1 -1
- package/dist/components/charts/chart/chart-feature-loader.d.ts +35 -0
- package/dist/components/charts/chart/chart-feature-loader.js +1 -1
- package/dist/components/charts/chart/chart.class.d.ts +120 -0
- package/dist/components/charts/chart/chart.class.js +16 -6
- package/dist/components/charts/chart/chart.styles.js +28 -27
- package/dist/components/charts/chart/lite-chart.class.d.ts +20 -1
- package/dist/components/charts/chart/lite-chart.class.js +4 -4
- package/dist/components/charts/chart/lite-chart.styles.js +0 -27
- package/dist/components/conversation/agent-workspace/agent-workspace.class.d.ts +20 -0
- package/dist/components/conversation/agent-workspace/agent-workspace.class.js +3 -1
- package/dist/components/conversation/agent-workspace/agent-workspace.styles.js +3 -0
- package/dist/components/conversation/audio-visualizer/audio-visualizer.styles.js +0 -7
- package/dist/components/conversation/branch-picker/branch-picker.styles.js +0 -3
- package/dist/components/conversation/chat-composer/chat-composer.styles.js +0 -51
- package/dist/components/conversation/chat-message/chat-message.styles.js +7 -35
- package/dist/components/conversation/chat-viewport/chat-viewport.class.js +1 -1
- package/dist/components/conversation/chat-viewport/chat-viewport.styles.js +0 -33
- package/dist/components/conversation/checkpoint/checkpoint.class.js +1 -1
- package/dist/components/conversation/checkpoint/checkpoint.styles.js +0 -3
- package/dist/components/conversation/code-block/code-block-shared.d.ts +5 -2
- package/dist/components/conversation/code-block/code-block.class.js +1 -1
- package/dist/components/conversation/code-block/code-block.styles.js +4 -95
- package/dist/components/conversation/code-block/code-loader.d.ts +11 -0
- package/dist/components/conversation/code-block/code-loader.js +1 -1
- package/dist/components/conversation/code-block/shiki-types.d.ts +12 -0
- package/dist/components/conversation/code-block/shiki-types.js +1 -1
- package/dist/components/conversation/conversation-item/conversation-item.styles.js +8 -54
- package/dist/components/conversation/generation-metrics/generation-metrics.class.js +2 -2
- package/dist/components/conversation/generation-metrics/generation-metrics.styles.js +0 -17
- package/dist/components/conversation/markdown/markdown-base.class.js +1 -1
- package/dist/components/conversation/markdown/markdown.styles.js +0 -41
- package/dist/components/conversation/message-actions/message-actions.styles.js +0 -3
- package/dist/components/conversation/message-feedback/message-feedback.styles.js +0 -35
- package/dist/components/conversation/message-parts/message-parts.class.d.ts +1 -1
- package/dist/components/conversation/message-parts/message-parts.styles.js +0 -5
- package/dist/components/conversation/model-select/model-select.class.js +3 -3
- package/dist/components/conversation/model-select/model-select.styles.js +12 -47
- package/dist/components/conversation/model-settings-panel/model-settings-panel.styles.js +0 -6
- package/dist/components/conversation/prompt-input/prompt-input.class.d.ts +3 -0
- package/dist/components/conversation/prompt-input/prompt-input.styles.js +0 -10
- package/dist/components/conversation/push-to-talk/push-to-talk.styles.js +0 -8
- package/dist/components/conversation/selection-toolbar/selection-toolbar.styles.js +1 -11
- package/dist/components/conversation/stream-status/stream-status.styles.js +0 -16
- package/dist/components/conversation/streaming-text/streaming-text.styles.js +0 -15
- package/dist/components/conversation/suggestion-chips/suggestion-chips.styles.js +0 -5
- package/dist/components/conversation/thread-list/thread-list.styles.js +0 -23
- package/dist/components/conversation/transcript-feed/transcript-feed.class.d.ts +16 -4
- package/dist/components/conversation/transcript-feed/transcript-feed.class.js +1 -1
- package/dist/components/conversation/transcript-feed/transcript-feed.styles.js +0 -1
- package/dist/components/conversation/typing-indicator/typing-indicator.styles.js +0 -23
- package/dist/components/conversation/usage-badge/usage-badge.styles.js +0 -3
- package/dist/components/conversation/voice-picker/voice-picker.class.js +3 -3
- package/dist/components/conversation/voice-picker/voice-picker.styles.js +9 -29
- package/dist/components/conversation/widget-renderer/resolve.d.ts +2 -0
- package/dist/components/conversation/widget-renderer/resolve.js +1 -1
- package/dist/components/data/calendar/calendar.class.d.ts +15 -2
- package/dist/components/data/calendar/calendar.class.js +2 -2
- package/dist/components/data/calendar/calendar.styles.js +2 -28
- package/dist/components/data/condition-builder/condition-builder.class.d.ts +10 -6
- package/dist/components/data/condition-builder/condition-builder.class.js +2 -2
- package/dist/components/data/condition-builder/condition-builder.styles.js +0 -6
- package/dist/components/data/context-meter/context-meter.styles.js +0 -24
- package/dist/components/data/data-grid/data-grid.class.js +3 -3
- package/dist/components/data/data-grid/data-grid.styles.js +0 -22
- package/dist/components/data/document-library/document-library.class.js +2 -2
- package/dist/components/data/document-library/document-library.styles.js +0 -4
- package/dist/components/data/env-list/env-list.class.js +1 -1
- package/dist/components/data/env-list/env-list.styles.js +7 -4
- package/dist/components/data/file-tree/file-tree.class.d.ts +12 -0
- package/dist/components/data/flow-canvas/flow-canvas.styles.js +12 -19
- package/dist/components/data/flow-controls/flow-controls.class.js +2 -2
- package/dist/components/data/flow-controls/flow-controls.styles.js +3 -36
- package/dist/components/data/flow-minimap/flow-minimap.class.js +1 -1
- package/dist/components/data/flow-minimap/flow-minimap.styles.js +0 -9
- package/dist/components/data/flow-node/flow-node.styles.js +0 -23
- package/dist/components/data/flow-run-status/flow-run-status.class.js +1 -1
- package/dist/components/data/flow-run-status/flow-run-status.styles.js +0 -7
- package/dist/components/data/graph-query-builder/graph-query-builder.class.d.ts +0 -7
- package/dist/components/data/graph-query-builder/graph-query-builder.class.js +1 -1
- package/dist/components/data/graph-query-builder/graph-query-builder.styles.js +0 -10
- package/dist/components/data/heatmap/heatmap-scale.d.ts +20 -0
- package/dist/components/data/heatmap/heatmap-scale.js +1 -1
- package/dist/components/data/heatmap/heatmap.class.d.ts +117 -1
- package/dist/components/data/heatmap/heatmap.class.js +2 -2
- package/dist/components/data/heatmap/heatmap.styles.js +0 -54
- package/dist/components/data/pagination/pagination.styles.js +23 -46
- package/dist/components/data/sequence-strip/sequence-strip.class.d.ts +34 -1
- package/dist/components/data/sequence-strip/sequence-strip.class.js +5 -2
- package/dist/components/data/sequence-strip/sequence-strip.styles.js +14 -20
- package/dist/components/data/sparkline/sparkline.class.js +1 -1
- package/dist/components/data/stat/stat.styles.js +0 -67
- package/dist/components/data/table/table.class.d.ts +42 -3
- package/dist/components/data/table/table.class.js +4 -4
- package/dist/components/data/table/table.styles.js +20 -91
- package/dist/components/data/timeline/timeline-item.styles.js +0 -30
- package/dist/components/data/timeline/timeline.class.d.ts +89 -1
- package/dist/components/data/timeline/timeline.class.js +2 -2
- package/dist/components/data/timeline/timeline.styles.js +111 -31
- package/dist/components/data/tree/tree-item.styles.js +1 -28
- package/dist/components/data/tree/tree.class.js +2 -2
- package/dist/components/data/tree/tree.styles.js +0 -6
- package/dist/components/data/word-cloud/word-cloud.styles.js +0 -5
- package/dist/components/forms/button/button.class.js +1 -1
- package/dist/components/forms/button/button.styles.js +0 -105
- package/dist/components/forms/checkbox/checkbox.class.d.ts +3 -0
- package/dist/components/forms/checkbox/checkbox.class.js +1 -1
- package/dist/components/forms/checkbox/checkbox.styles.js +0 -39
- package/dist/components/forms/checkbox-group/checkbox-group.class.d.ts +21 -2
- package/dist/components/forms/checkbox-group/checkbox-group.class.js +1 -1
- package/dist/components/forms/checkbox-group/checkbox-group.styles.js +0 -18
- package/dist/components/forms/code-editor/code-editor.styles.js +0 -30
- package/dist/components/forms/color-picker/color-picker.class.js +2 -2
- package/dist/components/forms/color-picker/color-picker.styles.js +0 -69
- package/dist/components/forms/combobox/combobox.class.d.ts +71 -3
- package/dist/components/forms/combobox/combobox.class.js +5 -3
- package/dist/components/forms/combobox/combobox.styles.js +31 -111
- package/dist/components/forms/combobox/option.styles.js +7 -1
- package/dist/components/forms/date-picker/date-input.class.js +1 -1
- package/dist/components/forms/date-picker/date-input.styles.js +12 -67
- package/dist/components/forms/date-picker/date-picker.class.d.ts +47 -0
- package/dist/components/forms/date-picker/date-picker.class.js +36 -22
- package/dist/components/forms/date-picker/date-picker.styles.js +82 -29
- package/dist/components/forms/emoji-picker/emoji-data-loader.d.ts +6 -3
- package/dist/components/forms/emoji-picker/emoji-data-loader.js +1 -1
- package/dist/components/forms/emoji-picker/emoji-picker.class.d.ts +8 -1
- package/dist/components/forms/emoji-picker/emoji-picker.class.js +1 -1
- package/dist/components/forms/emoji-picker/emoji-picker.styles.js +3 -41
- package/dist/components/forms/icon-button/icon-button.class.js +1 -1
- package/dist/components/forms/icon-button/icon-button.styles.js +0 -16
- package/dist/components/forms/input/input.styles.js +0 -54
- package/dist/components/forms/input/number-input.styles.d.ts +4 -5
- package/dist/components/forms/input/number-input.styles.js +0 -11
- package/dist/components/forms/input/time-input-shared.d.ts +11 -0
- package/dist/components/forms/input/time-input-shared.js +1 -1
- package/dist/components/forms/input/time-input.class.d.ts +11 -2
- package/dist/components/forms/input/time-input.class.js +1 -1
- package/dist/components/forms/input/time-input.styles.js +0 -6
- package/dist/components/forms/locale-picker/locale-picker.class.js +2 -2
- package/dist/components/forms/locale-picker/locale-picker.styles.js +1 -26
- package/dist/components/forms/otp-input/otp-input.class.js +3 -3
- package/dist/components/forms/otp-input/otp-input.styles.js +0 -16
- package/dist/components/forms/phone-input/phone-input.class.d.ts +9 -1
- package/dist/components/forms/phone-input/phone-input.class.js +2 -2
- package/dist/components/forms/phone-input/phone-input.styles.js +0 -37
- package/dist/components/forms/radio/radio-button.styles.js +1 -30
- package/dist/components/forms/radio/radio-group.styles.js +0 -4
- package/dist/components/forms/radio/radio.styles.js +0 -44
- package/dist/components/forms/rubric-form/rubric-form.styles.js +0 -5
- package/dist/components/forms/select/select.class.js +1 -1
- package/dist/components/forms/select/select.styles.js +14 -114
- package/dist/components/forms/slider/slider.styles.js +0 -55
- package/dist/components/forms/swatch-picker/swatch-picker.class.d.ts +0 -11
- package/dist/components/forms/swatch-picker/swatch-picker.class.js +2 -2
- package/dist/components/forms/swatch-picker/swatch-picker.styles.js +0 -77
- package/dist/components/forms/switch/switch.class.d.ts +3 -0
- package/dist/components/forms/switch/switch.class.js +1 -1
- package/dist/components/forms/switch/switch.styles.js +0 -37
- package/dist/components/forms/textarea/textarea.styles.js +0 -28
- package/dist/components/forms/time-range/time-range.styles.js +12 -84
- package/dist/components/forms/token-input/token-input.class.d.ts +23 -9
- package/dist/components/forms/token-input/token-input.class.js +1 -1
- package/dist/components/forms/token-input/token-input.styles.js +1 -54
- package/dist/components/layout/app-rail/app-rail-item.class.js +2 -2
- package/dist/components/layout/app-rail/app-rail-item.styles.js +0 -13
- package/dist/components/layout/app-rail/app-rail.class.d.ts +5 -0
- package/dist/components/layout/app-rail/app-rail.class.js +1 -1
- package/dist/components/layout/app-rail/app-rail.styles.js +0 -46
- package/dist/components/layout/button-group/button-group.styles.js +0 -6
- package/dist/components/layout/card/card.class.d.ts +12 -0
- package/dist/components/layout/card/card.styles.js +3 -11
- package/dist/components/layout/carousel/carousel.styles.js +0 -1
- package/dist/components/layout/command-palette/command-palette.class.d.ts +8 -0
- package/dist/components/layout/command-palette/command-palette.class.js +3 -1
- package/dist/components/layout/command-palette/command-palette.styles.js +1 -13
- package/dist/components/layout/control-group/control-group.styles.js +0 -7
- package/dist/components/layout/dashboard-grid/dashboard-grid.styles.js +6 -25
- package/dist/components/layout/details/accordion.class.d.ts +13 -0
- package/dist/components/layout/details/accordion.class.js +1 -1
- package/dist/components/layout/details/details.class.js +1 -1
- package/dist/components/layout/details/details.styles.js +0 -12
- package/dist/components/layout/dock-panel/dock-panel.styles.js +0 -45
- package/dist/components/layout/drilldown-panel/drilldown-panel.class.d.ts +2 -0
- package/dist/components/layout/drilldown-panel/drilldown-panel.class.js +2 -2
- package/dist/components/layout/drilldown-panel/drilldown-panel.styles.js +0 -4
- package/dist/components/layout/filter-bar/filter-bar.class.js +1 -1
- package/dist/components/layout/filter-bar/filter-bar.styles.js +0 -9
- package/dist/components/layout/menu/menu-item.class.d.ts +5 -0
- package/dist/components/layout/menu/menu-item.class.js +1 -1
- package/dist/components/layout/menu/menu-item.styles.js +0 -49
- package/dist/components/layout/menu/menu-label.styles.js +0 -2
- package/dist/components/layout/menu/menu.styles.js +0 -18
- package/dist/components/layout/multi-split/multi-split.styles.js +0 -63
- package/dist/components/layout/page/page.class.d.ts +4 -0
- package/dist/components/layout/page/page.class.js +1 -1
- package/dist/components/layout/reorder-list/reorder-item.styles.js +0 -4
- package/dist/components/layout/responsive-panel/responsive-panel.styles.js +0 -27
- package/dist/components/layout/scroller/scroller.styles.js +0 -20
- package/dist/components/layout/segmented/segmented.class.d.ts +7 -1
- package/dist/components/layout/segmented/segmented.class.js +1 -1
- package/dist/components/layout/segmented/segmented.styles.js +69 -37
- package/dist/components/layout/split-panel/split-panel.styles.js +1 -7
- package/dist/components/layout/stepper/stepper.class.d.ts +8 -1
- package/dist/components/layout/stepper/stepper.class.js +1 -1
- package/dist/components/layout/stepper/stepper.styles.js +140 -41
- package/dist/components/layout/tab-group/tab-group.class.d.ts +4 -1
- package/dist/components/layout/tab-group/tab-group.styles.js +9 -75
- package/dist/components/layout/tab-group/tab.styles.js +0 -2
- package/dist/components/layout/virtual-list/virtual-list.class.d.ts +4 -4
- package/dist/components/layout/virtual-list/virtual-list.class.js +1 -1
- package/dist/components/layout/virtual-list/virtual-list.styles.js +0 -68
- package/dist/components/layout/widget/widget.class.d.ts +5 -1
- package/dist/components/layout/widget/widget.class.js +1 -1
- package/dist/components/layout/widget/widget.styles.js +97 -40
- package/dist/components/media/animated-image/animated-image.class.d.ts +3 -0
- package/dist/components/media/animated-image/animated-image.class.js +1 -1
- package/dist/components/media/animated-image/animated-image.styles.js +0 -28
- package/dist/components/media/attachment-chip/attachment-chip.class.d.ts +1 -1
- package/dist/components/media/attachment-chip/attachment-chip.class.js +1 -1
- package/dist/components/media/attachment-chip/attachment-chip.styles.js +0 -31
- package/dist/components/media/attachment-trigger/attachment-trigger.class.js +3 -3
- package/dist/components/media/attachment-trigger/attachment-trigger.styles.js +0 -40
- package/dist/components/media/av-player/av-player.class.d.ts +5 -6
- package/dist/components/media/av-player/av-player.class.js +1 -1
- package/dist/components/media/av-player/av-player.styles.js +0 -45
- package/dist/components/media/avatar/avatar.styles.js +3 -16
- package/dist/components/media/file-icon/file-icon.class.d.ts +1 -2
- package/dist/components/media/file-icon/file-icon.class.js +1 -1
- package/dist/components/media/file-input/file-input.class.d.ts +12 -0
- package/dist/components/media/file-input/file-input.styles.js +3 -24
- package/dist/components/media/flag/flag.class.d.ts +23 -1
- package/dist/components/media/flag/flag.class.js +4 -2
- package/dist/components/media/flag/flag.styles.js +7 -1
- package/dist/components/media/flag/language-map.d.ts +10 -0
- package/dist/components/media/flag/language-map.js +1 -1
- package/dist/components/media/image-comparer/image-comparer.styles.js +4 -33
- package/dist/components/media/image-viewer/image-viewer.class.js +0 -2
- package/dist/components/media/image-viewer/image-viewer.styles.js +7 -27
- package/dist/components/media/lightbox/lightbox.class.js +0 -2
- package/dist/components/media/lightbox/lightbox.styles.js +0 -21
- package/dist/components/media/map/map-loader.d.ts +19 -1
- package/dist/components/media/map/map-loader.js +1 -1
- package/dist/components/media/map/map.class.d.ts +178 -1
- package/dist/components/media/map/map.class.js +15 -3
- package/dist/components/media/map/map.styles.js +20 -17
- package/dist/components/media/media-card/media-card.class.d.ts +14 -3
- package/dist/components/media/media-card/media-card.class.js +1 -1
- package/dist/components/media/media-card/media-card.styles.js +2 -28
- package/dist/components/media/pan-zoom/pan-zoom.styles.js +0 -3
- package/dist/components/media/qr-code/qr-code.class.d.ts +3 -2
- package/dist/components/media/qr-code/qr-code.class.js +2 -2
- package/dist/components/media/qr-code/qr-code.styles.js +0 -3
- package/dist/components/media/sequence-playback/sequence-playback.class.d.ts +2 -0
- package/dist/components/media/sequence-playback/sequence-playback.class.js +2 -1
- package/dist/components/media/sequence-playback/sequence-playback.styles.js +0 -19
- package/dist/components/media/video/video.class.d.ts +23 -2
- package/dist/components/media/video/video.class.js +3 -3
- package/dist/components/media/video/video.styles.js +4 -2
- package/dist/components/media/zoomable-frame/zoomable-frame.class.d.ts +3 -2
- package/dist/components/media/zoomable-frame/zoomable-frame.class.js +2 -2
- package/dist/components/media/zoomable-frame/zoomable-frame.styles.js +0 -5
- package/dist/components/overlays/alert/alert.styles.js +4 -2
- package/dist/components/overlays/badge/badge.styles.js +4 -48
- package/dist/components/overlays/badge/tag.styles.js +0 -14
- package/dist/components/overlays/callout/callout.styles.js +0 -11
- package/dist/components/overlays/chip/chip-group.styles.js +0 -18
- package/dist/components/overlays/chip/chip.styles.js +6 -69
- package/dist/components/overlays/dialog/confirm.d.ts +1 -4
- package/dist/components/overlays/dialog/confirm.js +1 -1
- package/dist/components/overlays/dialog/dialog.class.d.ts +32 -9
- package/dist/components/overlays/dialog/dialog.class.js +1 -1
- package/dist/components/overlays/dialog/dialog.styles.js +0 -43
- package/dist/components/overlays/drawer/drawer.class.d.ts +2 -2
- package/dist/components/overlays/drawer/drawer.styles.js +0 -9
- package/dist/components/overlays/empty/empty.styles.js +0 -12
- package/dist/components/overlays/kbd/kbd.styles.js +0 -8
- package/dist/components/overlays/overlay/dropdown.class.d.ts +1 -6
- package/dist/components/overlays/overlay/dropdown.class.js +2 -2
- package/dist/components/overlays/overlay/overlay.styles.js +0 -28
- package/dist/components/overlays/overlay/popover.class.d.ts +28 -4
- package/dist/components/overlays/overlay/popover.class.js +2 -2
- package/dist/components/overlays/overlay/tooltip.class.d.ts +10 -0
- package/dist/components/overlays/overlay/tooltip.class.js +1 -1
- package/dist/components/overlays/popup/popup.class.d.ts +1 -0
- package/dist/components/overlays/popup/popup.class.js +1 -1
- package/dist/components/overlays/popup/popup.styles.js +0 -15
- package/dist/components/overlays/progress/progress-ring.class.d.ts +9 -1
- package/dist/components/overlays/progress/progress-ring.class.js +3 -3
- package/dist/components/overlays/progress/progress.styles.js +0 -21
- package/dist/components/overlays/rating/rating.styles.js +0 -25
- package/dist/components/overlays/skeleton/skeleton.styles.js +0 -4
- package/dist/components/overlays/spinner/spinner.styles.js +0 -3
- package/dist/components/overlays/toast/toast-item.styles.js +3 -45
- package/dist/components/retrieval/chunk-inspector/chunk-inspector.styles.js +0 -35
- package/dist/components/retrieval/citation-badge/citation-badge.class.d.ts +2 -2
- package/dist/components/retrieval/citation-badge/citation-badge.class.js +3 -3
- package/dist/components/retrieval/citation-badge/citation-badge.styles.js +0 -20
- package/dist/components/retrieval/claim-evidence/claim-evidence.styles.js +0 -8
- package/dist/components/retrieval/community-card/community-card.class.d.ts +1 -0
- package/dist/components/retrieval/community-card/community-card.styles.js +0 -6
- package/dist/components/retrieval/embedding-explorer/embedding-explorer.styles.js +8 -12
- package/dist/components/retrieval/entity-card/entity-card.class.d.ts +4 -3
- package/dist/components/retrieval/entity-card/entity-card.class.js +1 -1
- package/dist/components/retrieval/entity-card/entity-card.styles.js +0 -12
- package/dist/components/retrieval/entity-chip/entity-chip.class.d.ts +10 -4
- package/dist/components/retrieval/entity-chip/entity-chip.class.js +3 -3
- package/dist/components/retrieval/entity-chip/entity-chip.styles.js +6 -9
- package/dist/components/retrieval/entity-dossier/entity-dossier.class.d.ts +19 -5
- package/dist/components/retrieval/graph/graph.class.d.ts +5 -0
- package/dist/components/retrieval/graph/graph.class.js +1 -1
- package/dist/components/retrieval/graph/graph.styles.js +0 -30
- package/dist/components/retrieval/graph-legend/graph-legend.styles.js +0 -3
- package/dist/components/retrieval/ingestion-queue/ingestion-queue.styles.js +0 -25
- package/dist/components/retrieval/knowledge-base-admin/knowledge-base-admin.class.d.ts +2 -0
- package/dist/components/retrieval/knowledge-base-admin/knowledge-base-admin.styles.js +0 -7
- package/dist/components/retrieval/knowledge-graph-explorer/knowledge-graph-explorer.class.d.ts +20 -6
- package/dist/components/retrieval/knowledge-graph-explorer/knowledge-graph-explorer.class.js +2 -2
- package/dist/components/retrieval/knowledge-graph-explorer/knowledge-graph-explorer.styles.js +0 -16
- package/dist/components/retrieval/mind-map/mind-map.class.d.ts +5 -3
- package/dist/components/retrieval/mind-map/mind-map.class.js +1 -1
- package/dist/components/retrieval/mind-map/mind-map.styles.js +0 -2
- package/dist/components/retrieval/neighbor-list/neighbor-list.class.d.ts +3 -2
- package/dist/components/retrieval/neighbor-list/neighbor-list.class.js +1 -1
- package/dist/components/retrieval/neighbor-list/neighbor-list.styles.js +0 -30
- package/dist/components/retrieval/node-palette/node-palette.styles.js +0 -11
- package/dist/components/retrieval/path-strip/path-strip.styles.js +0 -10
- package/dist/components/retrieval/provenance-panel/provenance-panel.class.d.ts +12 -3
- package/dist/components/retrieval/provenance-panel/provenance-panel.styles.js +0 -2
- package/dist/components/retrieval/rag-eval-dashboard/rag-eval-dashboard.class.d.ts +3 -2
- package/dist/components/retrieval/rag-eval-dashboard/rag-eval-dashboard.class.js +2 -2
- package/dist/components/retrieval/retrieval-results/retrieval-results.styles.js +0 -28
- package/dist/components/retrieval/retrieval-search/retrieval-search.styles.js +0 -4
- package/dist/components/retrieval/retrieval-trace/retrieval-trace.styles.js +0 -2
- package/dist/components/retrieval/source-card/source-card.styles.js +0 -13
- package/dist/components/retrieval/source-list/source-list.styles.js +0 -7
- package/dist/components/retrieval/source-picker/source-picker.styles.js +0 -7
- package/dist/components/utility/copy-button/copy-button.styles.js +0 -10
- package/dist/components/utility/diff-view/diff-view.styles.js +0 -14
- package/dist/components/utility/export-button/export-button.styles.js +0 -22
- package/dist/components/utility/icon/icon.styles.js +0 -6
- package/dist/components/utility/json-viewer/json-viewer.styles.js +2 -48
- package/dist/components/utility/known-date/known-date.class.d.ts +7 -3
- package/dist/components/utility/known-date/known-date.styles.js +10 -51
- package/dist/components/utility/live-region/live-region.styles.js +0 -4
- package/dist/components/utility/mention-popover/mention-popover.styles.js +0 -25
- package/dist/components/utility/poll-status/poll-status.styles.js +0 -4
- package/dist/components/utility/random-content/random-content.class.d.ts +22 -0
- package/dist/components/utility/random-content/random-content.class.js +3 -2
- package/dist/components/utility/random-content/random-content.styles.js +6 -13
- package/dist/components/utility/tour/tour.class.d.ts +4 -2
- package/dist/components/utility/tour/tour.class.js +3 -3
- package/dist/components/utility/tour/tour.styles.js +0 -13
- package/dist/components/utility/visually-hidden/visually-hidden.styles.js +0 -5
- package/dist/components/viewers/archive-viewer/archive-viewer.class.js +1 -1
- package/dist/components/viewers/archive-viewer/archive-viewer.styles.d.ts +2 -2
- package/dist/components/viewers/archive-viewer/archive-viewer.styles.js +0 -10
- package/dist/components/viewers/csv-viewer/csv-viewer.class.js +1 -1
- package/dist/components/viewers/csv-viewer/csv-viewer.styles.js +0 -19
- package/dist/components/viewers/dataset-viewer/dataset-viewer.class.js +1 -1
- package/dist/components/viewers/dataset-viewer/dataset-viewer.styles.js +0 -15
- package/dist/components/viewers/document-compare/document-compare.styles.js +0 -3
- package/dist/components/viewers/document-preview/document-preview.styles.js +0 -25
- package/dist/components/viewers/document-viewer/document-viewer.class.d.ts +2 -1
- package/dist/components/viewers/document-viewer/document-viewer.class.js +1 -1
- package/dist/components/viewers/document-viewer/document-viewer.styles.js +0 -5
- package/dist/components/viewers/docx-viewer/docx-viewer.styles.js +0 -17
- package/dist/components/viewers/ebook-viewer/ebook-viewer.styles.js +0 -4
- package/dist/components/viewers/email-viewer/email-viewer.styles.js +0 -7
- package/dist/components/viewers/geojson-view/geojson-view.styles.js +0 -5
- package/dist/components/viewers/highlight-layer/highlight-layer.styles.js +0 -3
- package/dist/components/viewers/notebook-viewer/notebook-viewer.class.js +1 -1
- package/dist/components/viewers/notebook-viewer/notebook-viewer.styles.js +0 -38
- package/dist/components/viewers/page-rail/page-rail.class.js +1 -1
- package/dist/components/viewers/page-rail/page-rail.styles.js +0 -13
- package/dist/components/viewers/pdf-viewer/pdf-loader.d.ts +13 -2
- package/dist/components/viewers/pdf-viewer/pdf-loader.js +1 -1
- package/dist/components/viewers/pdf-viewer/pdf-viewer.class.d.ts +32 -2
- package/dist/components/viewers/pdf-viewer/pdf-viewer.class.js +4 -4
- package/dist/components/viewers/pdf-viewer/pdf-viewer.styles.js +1 -27
- package/dist/components/viewers/pptx-viewer/pptx-viewer.styles.js +0 -3
- package/dist/components/viewers/spreadsheet-viewer/spreadsheet-viewer.class.js +1 -1
- package/dist/components/viewers/spreadsheet-viewer/spreadsheet-viewer.styles.js +0 -14
- package/dist/components/viewers/svg-viewer/svg-viewer.styles.js +0 -7
- package/dist/components/viewers/xml-viewer/xml-viewer.styles.js +2 -24
- package/dist/custom-elements-jsx.d.ts +72 -40
- package/dist/events.d.ts +43 -33
- package/dist/internal/agent-status-variants.d.ts +18 -0
- package/dist/internal/agent-status-variants.js +1 -0
- package/dist/internal/announcer.d.ts +8 -3
- package/dist/internal/announcer.js +1 -1
- package/dist/internal/autoloader-manifest.js +1 -1
- package/dist/internal/canvas-color.d.ts +16 -0
- package/dist/internal/canvas-color.js +1 -1
- package/dist/internal/catalog-picker.d.ts +0 -1
- package/dist/internal/catalog-picker.js +1 -1
- package/dist/internal/default-strings.generated.d.ts +1 -0
- package/dist/internal/default-strings.generated.js +1 -1
- package/dist/internal/dev-mode-attribute-warning.d.ts +27 -4
- package/dist/internal/dev-mode-attribute-warning.js +1 -1
- package/dist/internal/localization-runtime.js +1 -1
- package/dist/internal/localization-types.d.ts +1 -1
- package/dist/internal/localization.js +1 -1
- package/dist/internal/lyra-element.d.ts +13 -0
- package/dist/internal/lyra-element.js +1 -1
- package/dist/internal/media-controller.js +1 -1
- package/dist/internal/package-metadata.d.ts +1 -1
- package/dist/internal/package-metadata.js +1 -1
- package/dist/internal/scroll-overflow.d.ts +35 -13
- package/dist/internal/scroll-overflow.js +1 -1
- package/dist/internal/sizes.styles.js +0 -2
- package/dist/internal/specialist-tokens.styles.js +6 -11
- package/dist/internal/text-highlights.d.ts +4 -1
- package/dist/internal/text-highlights.js +1 -1
- package/dist/internal/tokens/palette.styles.js +0 -15
- package/dist/internal/tokens.styles.js +20 -113
- package/dist/lyra.d.ts +9 -6
- package/dist/styles/reservations.css +82 -0
- package/dist/svelte.d.ts +72 -40
- package/dist/translations/ar.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/pt-BR.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/zh-CN.js +1 -1
- package/dist/vue.d.ts +72 -40
- package/llms/components/lr-accordion-item.md +12 -3
- package/llms/components/lr-accordion.md +11 -2
- package/llms/components/lr-agent-eval-dashboard.md +1 -1
- package/llms/components/lr-agent-trace.md +3 -1
- package/llms/components/lr-agent-workspace.md +20 -0
- package/llms/components/lr-artifact-panel.md +10 -4
- package/llms/components/lr-attachment-chip.md +7 -4
- package/llms/components/lr-attachment-trigger.md +7 -4
- package/llms/components/lr-av-player.md +3 -1
- package/llms/components/lr-avatar.md +6 -6
- package/llms/components/lr-bar-chart.md +8 -6
- package/llms/components/lr-box-plot.md +15 -4
- package/llms/components/lr-browser-frame.md +7 -3
- package/llms/components/lr-bubble-chart.md +8 -6
- package/llms/components/lr-calendar.md +9 -2
- package/llms/components/lr-card.md +24 -0
- package/llms/components/lr-chart.md +45 -11
- package/llms/components/lr-chat-viewport.md +7 -2
- package/llms/components/lr-checkbox-group.md +13 -5
- package/llms/components/lr-checkbox.md +5 -2
- package/llms/components/lr-checkpoint.md +6 -2
- package/llms/components/lr-combobox.md +47 -8
- package/llms/components/lr-command-palette.md +4 -1
- package/llms/components/lr-confirm-bar.md +7 -3
- package/llms/components/lr-context-meter.md +12 -11
- package/llms/components/lr-conversation-item.md +7 -4
- package/llms/components/lr-date-input.md +22 -2
- package/llms/components/lr-date-picker.md +23 -3
- package/llms/components/lr-details.md +11 -2
- package/llms/components/lr-dialog.md +16 -10
- package/llms/components/lr-dock-panel.md +7 -10
- package/llms/components/lr-document-preview.md +6 -1
- package/llms/components/lr-document-viewer.md +3 -2
- package/llms/components/lr-doughnut-chart.md +8 -6
- package/llms/components/lr-drawer.md +3 -3
- package/llms/components/lr-entity-card.md +3 -3
- package/llms/components/lr-entity-chip.md +1 -1
- package/llms/components/lr-entity-dossier.md +4 -1
- package/llms/components/lr-file-input.md +2 -2
- package/llms/components/lr-flag.md +30 -8
- package/llms/components/lr-heatmap.md +46 -0
- package/llms/components/lr-histogram.md +7 -4
- package/llms/components/lr-icon.md +1 -1
- package/llms/components/lr-json-schema-viewer.md +2 -1
- package/llms/components/lr-knowledge-graph-explorer.md +8 -3
- package/llms/components/lr-known-date.md +4 -2
- package/llms/components/lr-line-chart.md +8 -6
- package/llms/components/lr-lite-chart.md +16 -6
- package/llms/components/lr-map.md +91 -10
- package/llms/components/lr-markdown-core.md +3 -2
- package/llms/components/lr-media-card.md +28 -12
- package/llms/components/lr-message-parts.md +2 -1
- package/llms/components/lr-model-select.md +9 -10
- package/llms/components/lr-model-settings-panel.md +9 -9
- package/llms/components/lr-neighbor-list.md +1 -1
- package/llms/components/lr-notebook-viewer.md +6 -3
- package/llms/components/lr-option.md +46 -7
- package/llms/components/lr-pdf-viewer.md +62 -2
- package/llms/components/lr-pie-chart.md +8 -6
- package/llms/components/lr-polar-area-chart.md +8 -6
- package/llms/components/lr-popover.md +25 -1
- package/llms/components/lr-progress-ring.md +8 -1
- package/llms/components/lr-prompt-studio.md +1 -1
- package/llms/components/lr-provenance-panel.md +4 -2
- package/llms/components/lr-qr-code.md +1 -1
- package/llms/components/lr-radar-chart.md +8 -6
- package/llms/components/lr-rag-eval-dashboard.md +2 -2
- package/llms/components/lr-random-content.md +13 -0
- package/llms/components/lr-reorder-item.md +6 -1
- package/llms/components/lr-reorder-list.md +6 -1
- package/llms/components/lr-responsive-panel.md +11 -7
- package/llms/components/lr-scatter-chart.md +8 -6
- package/llms/components/lr-sequence-strip.md +16 -2
- package/llms/components/lr-slider.md +12 -5
- package/llms/components/lr-sparkline.md +1 -1
- package/llms/components/lr-suggestion-chips.md +7 -2
- package/llms/components/lr-swatch-picker.md +5 -5
- package/llms/components/lr-switch.md +5 -2
- package/llms/components/lr-table.md +30 -4
- package/llms/components/lr-terminal.md +3 -1
- package/llms/components/lr-thread-list.md +8 -8
- package/llms/components/lr-time-input.md +6 -1
- package/llms/components/lr-timeline-item.md +24 -0
- package/llms/components/lr-timeline.md +25 -1
- package/llms/components/lr-token-input.md +7 -2
- package/llms/components/lr-tool-approval-dialog.md +7 -8
- package/llms/components/lr-tool-call-chip.md +5 -1
- package/llms/components/lr-tool-param-form.md +14 -12
- package/llms/components/lr-tool-result-dialog.md +11 -9
- package/llms/components/lr-tool-result-view.md +7 -6
- package/llms/components/lr-tool-select-dialog.md +18 -16
- package/llms/components/lr-trace-tree.md +3 -1
- package/llms/components/lr-usage-badge.md +4 -1
- package/llms/components/lr-video-playlist.md +1 -1
- package/llms/components/lr-virtual-list.md +22 -14
- package/llms/components/lr-voice-picker.md +8 -5
- package/llms/components/lr-widget-renderer.md +3 -3
- package/llms/components/lr-widget.md +1 -1
- package/llms/components/lr-word-cloud.md +6 -2
- package/llms/peers.md +12 -2
- package/llms/shared.md +70 -2
- package/llms/tokens.md +15 -1
- package/llms-full.txt +1335 -306
- package/package.json +17 -5
- package/vscode-css-data.json +93 -2
- package/vscode-html-data.json +513 -59
- package/web-types.json +457 -72
|
@@ -8,14 +8,6 @@ import{css}from"lit";import{forcedColorLegendSwatchStyles}from"./chart-forced-co
|
|
|
8
8
|
block-size: auto;
|
|
9
9
|
container-type: inline-size;
|
|
10
10
|
contain-intrinsic-inline-size: var(--lr-size-20rem);
|
|
11
|
-
/* Same theme tokens as chart.styles.ts's :host — Chart.js renders to
|
|
12
|
-
canvas, not the DOM, so it can't consume CSS var() directly;
|
|
13
|
-
box-plot.ts's themeColors() resolves these once per draw() via
|
|
14
|
-
getComputedStyle, mirroring chart.ts. Each is its own token (rather
|
|
15
|
-
than reusing the semantic ones directly) so a host can retheme just
|
|
16
|
-
the chart's grid/ticks/legend/tooltip without affecting unrelated
|
|
17
|
-
text/border/surface colors elsewhere in the component, while still
|
|
18
|
-
defaulting to those semantic tokens. */
|
|
19
11
|
--_lr-chart-grid-color: var(--lr-color-border);
|
|
20
12
|
--_lr-chart-tick-color: var(--lr-color-text-quiet);
|
|
21
13
|
--_lr-chart-legend-color: var(--lr-color-text);
|
|
@@ -80,9 +72,6 @@ import{css}from"lit";import{forcedColorLegendSwatchStyles}from"./chart-forced-co
|
|
|
80
72
|
[part~='legend-item'] {
|
|
81
73
|
display: inline-flex;
|
|
82
74
|
align-items: center;
|
|
83
|
-
/* Both axes, matching <lr-chart>'s legend item: a short series name leaves the swatch+label
|
|
84
|
-
pair narrower than the min-inline-size hit-area floor below, and the default
|
|
85
|
-
justify-content (normal => flex-start) dumped that slack on the trailing side. */
|
|
86
75
|
justify-content: center;
|
|
87
76
|
min-inline-size: var(--lr-icon-button-size);
|
|
88
77
|
min-block-size: var(--lr-icon-button-size);
|
|
@@ -101,8 +90,6 @@ import{css}from"lit";import{forcedColorLegendSwatchStyles}from"./chart-forced-co
|
|
|
101
90
|
[part~='legend-item']:where(:hover) {
|
|
102
91
|
background: var(--lr-chart-legend-item-hover-bg, var(--lr-color-brand-quiet));
|
|
103
92
|
}
|
|
104
|
-
/* Pressed, matching <lr-chart>'s legend item: the same quiet brand tint pushed further toward
|
|
105
|
-
the text colour, so the mousedown that toggles the series reads as distinct from hovering. */
|
|
106
93
|
[part~='legend-item']:where(:active) {
|
|
107
94
|
background: var(
|
|
108
95
|
--lr-chart-legend-item-active-bg,
|
|
@@ -172,14 +159,7 @@ import{css}from"lit";import{forcedColorLegendSwatchStyles}from"./chart-forced-co
|
|
|
172
159
|
min-inline-size: var(--lr-icon-button-size);
|
|
173
160
|
min-block-size: var(--lr-icon-button-size);
|
|
174
161
|
}
|
|
175
|
-
/* no-pressed-state: the canvas is a role="application" keyboard surface with no click handler of
|
|
176
|
-
its own -- pressing it activates a box *inside* the bitmap, which no CSS rule can reach, and
|
|
177
|
-
re-outlining the whole plot on mousedown would read as the entire chart being the target.
|
|
178
|
-
Same treatment, and same rationale, as chart.styles.ts's canvas. */
|
|
179
162
|
[part='canvas']:hover {
|
|
180
|
-
/* Scoped so a consumer can retint/resize just this hover outline without also affecting every
|
|
181
|
-
other --lr-border-width-thin consumer on the page -- the same indirection rationale as the
|
|
182
|
-
--lr-chart-grid-color/-tick-color/etc. block above, applied to a state-specific rule. */
|
|
183
163
|
outline: var(--lr-chart-canvas-hover-outline-width, var(--lr-border-width-thin)) solid
|
|
184
164
|
var(--lr-chart-grid-color, var(--_lr-chart-grid-color));
|
|
185
165
|
outline-offset: var(--lr-focus-ring-offset);
|
|
@@ -197,4 +177,32 @@ import{css}from"lit";import{forcedColorLegendSwatchStyles}from"./chart-forced-co
|
|
|
197
177
|
max-inline-size: 100%;
|
|
198
178
|
overflow-wrap: anywhere;
|
|
199
179
|
}
|
|
180
|
+
[part='data-table-toggle'] {
|
|
181
|
+
align-self: flex-start;
|
|
182
|
+
font: inherit;
|
|
183
|
+
font-size: var(--lr-font-size-xs);
|
|
184
|
+
min-block-size: var(--lr-icon-button-size);
|
|
185
|
+
padding: var(--lr-size-0-15rem) var(--lr-size-0-5rem);
|
|
186
|
+
border: var(--lr-border-width-thin) solid var(--lr-color-border);
|
|
187
|
+
border-radius: var(--lr-radius);
|
|
188
|
+
background: var(--lr-color-surface);
|
|
189
|
+
color: var(--lr-color-text);
|
|
190
|
+
max-inline-size: 100%;
|
|
191
|
+
white-space: normal;
|
|
192
|
+
overflow-wrap: break-word;
|
|
193
|
+
cursor: pointer;
|
|
194
|
+
}
|
|
195
|
+
[part='data-table-toggle']:hover {
|
|
196
|
+
background: var(--lr-box-plot-data-table-toggle-hover-bg, var(--lr-color-brand-quiet));
|
|
197
|
+
}
|
|
198
|
+
[part='data-table-toggle']:active {
|
|
199
|
+
background: var(
|
|
200
|
+
--lr-box-plot-data-table-toggle-active-bg,
|
|
201
|
+
color-mix(in oklab, var(--lr-color-brand-quiet), var(--lr-color-mix-partner) var(--lr-color-mix-active))
|
|
202
|
+
);
|
|
203
|
+
}
|
|
204
|
+
[part='data-table-toggle']:focus-visible {
|
|
205
|
+
outline: var(--lr-focus-ring-width) solid var(--lr-focus-ring-color);
|
|
206
|
+
outline-offset: var(--lr-focus-ring-offset);
|
|
207
|
+
}
|
|
200
208
|
`;export{styles};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { resolveCanvasColor } from '../../../internal/canvas-color.js';
|
|
1
|
+
export { resolveCanvasColor, resolveCanvasColors } from '../../../internal/canvas-color.js';
|
|
2
2
|
/**
|
|
3
3
|
* Resolves the categorical chart ramp to concrete canvas-safe colors. Passing `null` selects the
|
|
4
4
|
* deterministic fallback directly; omitting the argument reads the document theme.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{resolveCanvasColor}from"../../../internal/canvas-color.js";const FALLBACK_SERIES_PALETTE=["#0e006e","#4d011a","#862002","#503983","#315fdd","#935e7c","#de6906","#8f81d3"],AREA_FILL_PERCENT=28;import{resolveCanvasColor as resolveCanvasColor2}from"../../../internal/canvas-color.js";function seriesPalette(element){const target=element===void 0&&typeof document<"u"?document.documentElement:element;if(!target||typeof getComputedStyle!="function")return[...FALLBACK_SERIES_PALETTE];const cs=getComputedStyle(target);return FALLBACK_SERIES_PALETTE.map((fallback,index)=>{const number=index+1,color=cs.getPropertyValue(`--lr-color-chart-${number}`).trim()||cs.getPropertyValue(`--lr-theme-color-chart-${number}`).trim()||fallback;return resolveCanvasColor(target,color,fallback)})}function translucentAreaColor(scope,color){if(typeof document>"u"||typeof getComputedStyle!="function")return color;const concrete=resolveCanvasColor(scope,color,color);return resolveCanvasColor(scope,`color-mix(in srgb, ${concrete} ${AREA_FILL_PERCENT}%, transparent)`,concrete)}export{resolveCanvasColor2 as resolveCanvasColor,seriesPalette,translucentAreaColor};
|
|
1
|
+
import{resolveCanvasColor}from"../../../internal/canvas-color.js";const FALLBACK_SERIES_PALETTE=["#0e006e","#4d011a","#862002","#503983","#315fdd","#935e7c","#de6906","#8f81d3"],AREA_FILL_PERCENT=28;import{resolveCanvasColor as resolveCanvasColor2,resolveCanvasColors}from"../../../internal/canvas-color.js";function seriesPalette(element){const target=element===void 0&&typeof document<"u"?document.documentElement:element;if(!target||typeof getComputedStyle!="function")return[...FALLBACK_SERIES_PALETTE];const cs=getComputedStyle(target);return FALLBACK_SERIES_PALETTE.map((fallback,index)=>{const number=index+1,color=cs.getPropertyValue(`--lr-color-chart-${number}`).trim()||cs.getPropertyValue(`--lr-theme-color-chart-${number}`).trim()||fallback;return resolveCanvasColor(target,color,fallback)})}function translucentAreaColor(scope,color){if(typeof document>"u"||typeof getComputedStyle!="function")return color;const concrete=resolveCanvasColor(scope,color,color);return resolveCanvasColor(scope,`color-mix(in srgb, ${concrete} ${AREA_FILL_PERCENT}%, transparent)`,concrete)}export{resolveCanvasColor2 as resolveCanvasColor,resolveCanvasColors,seriesPalette,translucentAreaColor};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{resolveOptionalPeerCapability,unwrapOptionalPeerDefault}from"../../../internal/optional-peer-capabilities.js";const CHART_REGISTERABLE_KEYS=["LineController","BarController","ScatterController","DoughnutController","PieController","RadarController","PolarAreaController","BubbleController","LineElement","PointElement","BarElement","ArcElement","LinearScale","CategoryScale","RadialLinearScale","Filler","Tooltip","Legend"];function isObjectLike(value){return(typeof value=="object"||typeof value=="function")&&value!==null}function isConstructor(value){if(typeof value!="function")return!1;try{return Reflect.construct(Object,[],value),!0}catch{return!1}}function missingChartCapability(candidate){if(!isObjectLike(candidate))return"module namespace";if(!isConstructor(candidate.Chart))return"Chart";if(typeof candidate.Chart.register!="function")return"Chart.register";if(!isObjectLike(candidate.defaults))return"defaults";for(const key of CHART_REGISTERABLE_KEYS)if(!isObjectLike(candidate[key]))return key}function isChartJsModule(candidate){return missingChartCapability(candidate)===void 0}function resolveChartJsModule(value){const module=resolveOptionalPeerCapability(value,isChartJsModule);if(module)return module;const candidate=unwrapOptionalPeerDefault(value),missing=missingChartCapability(candidate)??"module namespace";throw new Error(`Invalid optional peer \`chart.js\`: missing or invalid \`${missing}\` capability.`)}let chartJs,registered=!1;async function loadChartModule(importChart=()=>import("chart.js")){try{return resolveChartJsModule(await importChart())}catch(err){return console.warn("<lr-chart> needs the optional peer dependency `chart.js` \u2014 install it with `pnpm add chart.js`:",err),null}}function registerCore(mod){registered||(mod.Chart.register(mod.LineController,mod.BarController,mod.ScatterController,mod.DoughnutController,mod.PieController,mod.RadarController,mod.PolarAreaController,mod.BubbleController,mod.LineElement,mod.PointElement,mod.BarElement,mod.ArcElement,mod.LinearScale,mod.CategoryScale,mod.RadialLinearScale,mod.Filler,mod.Tooltip,mod.Legend),registered=!0)}async function loadAndRegisterChartModule(importChart=()=>import("chart.js"),register=registerCore){const mod=await loadChartModule(importChart);if(!mod)return null;try{return register(mod),mod}catch(error){return console.warn("<lr-chart> could not register the optional `chart.js` peer:",error),null}}function loadChartJs(){return chartJs||(chartJs=loadAndRegisterChartModule()),chartJs}export{loadAndRegisterChartModule,loadChartJs,loadChartModule};
|
|
1
|
+
import{resolveOptionalPeerCapability,unwrapOptionalPeerDefault}from"../../../internal/optional-peer-capabilities.js";const CHART_REGISTERABLE_KEYS=["LineController","BarController","ScatterController","DoughnutController","PieController","RadarController","PolarAreaController","BubbleController","LineElement","PointElement","BarElement","ArcElement","LinearScale","CategoryScale","RadialLinearScale","LogarithmicScale","Filler","Tooltip","Legend"];function isObjectLike(value){return(typeof value=="object"||typeof value=="function")&&value!==null}function isConstructor(value){if(typeof value!="function")return!1;try{return Reflect.construct(Object,[],value),!0}catch{return!1}}function missingChartCapability(candidate){if(!isObjectLike(candidate))return"module namespace";if(!isConstructor(candidate.Chart))return"Chart";if(typeof candidate.Chart.register!="function")return"Chart.register";if(!isObjectLike(candidate.defaults))return"defaults";for(const key of CHART_REGISTERABLE_KEYS)if(!isObjectLike(candidate[key]))return key}function isChartJsModule(candidate){return missingChartCapability(candidate)===void 0}function resolveChartJsModule(value){const module=resolveOptionalPeerCapability(value,isChartJsModule);if(module)return module;const candidate=unwrapOptionalPeerDefault(value),missing=missingChartCapability(candidate)??"module namespace";throw new Error(`Invalid optional peer \`chart.js\`: missing or invalid \`${missing}\` capability.`)}let chartJs,registered=!1;async function loadChartModule(importChart=()=>import("chart.js")){try{return resolveChartJsModule(await importChart())}catch(err){return console.warn("<lr-chart> needs the optional peer dependency `chart.js` \u2014 install it with `pnpm add chart.js`:",err),null}}function registerCore(mod){registered||(mod.Chart.register(mod.LineController,mod.BarController,mod.ScatterController,mod.DoughnutController,mod.PieController,mod.RadarController,mod.PolarAreaController,mod.BubbleController,mod.LineElement,mod.PointElement,mod.BarElement,mod.ArcElement,mod.LinearScale,mod.CategoryScale,mod.RadialLinearScale,mod.LogarithmicScale,mod.Filler,mod.Tooltip,mod.Legend),registered=!0)}async function loadAndRegisterChartModule(importChart=()=>import("chart.js"),register=registerCore){const mod=await loadChartModule(importChart);if(!mod)return null;try{return register(mod),mod}catch(error){return console.warn("<lr-chart> could not register the optional `chart.js` peer:",error),null}}function loadChartJs(){return chartJs||(chartJs=loadAndRegisterChartModule()),chartJs}export{loadAndRegisterChartModule,loadChartJs,loadChartModule};
|
|
@@ -6,6 +6,7 @@ export interface ChartPluginCapability {
|
|
|
6
6
|
}
|
|
7
7
|
export type ZoomPlugin = ChartPluginCapability;
|
|
8
8
|
export type DataLabelsPlugin = ChartPluginCapability;
|
|
9
|
+
export type AnnotationPlugin = ChartPluginCapability;
|
|
9
10
|
/**
|
|
10
11
|
* The outcome of loading an opt-in Chart.js feature after attempting to load
|
|
11
12
|
* the core module. Callers can distinguish an unavailable core from an
|
|
@@ -122,3 +123,37 @@ export declare function loadChartJsWithDataLabels(importDataLabels?: () => Promi
|
|
|
122
123
|
mod: ChartJsModule;
|
|
123
124
|
plugin: DataLabelsPlugin | undefined;
|
|
124
125
|
} | null>;
|
|
126
|
+
/**
|
|
127
|
+
* Loads `chartjs-plugin-annotation`, validating that the module really exposes a Chart.js plugin
|
|
128
|
+
* before it is handed to a chart — registering a wrapper namespace or a malformed object would
|
|
129
|
+
* silently no-op, which is the failure mode `resolveChartPlugin` exists to prevent. Un-memoized so
|
|
130
|
+
* both the success and the degrade-with-a-warning paths stay directly testable.
|
|
131
|
+
*/
|
|
132
|
+
export declare function loadAnnotationPlugin(importAnnotation?: () => Promise<unknown>): Promise<AnnotationPlugin | undefined>;
|
|
133
|
+
/**
|
|
134
|
+
* Loads Chart.js plus the annotation plugin and **registers it globally**, preserving a usable core
|
|
135
|
+
* when the feature peer is absent. Un-memoized twin of `loadChartJsWithAnnotationResult()`, for
|
|
136
|
+
* failure-path tests.
|
|
137
|
+
*
|
|
138
|
+
* Global registration here, per-instance for `chartjs-plugin-datalabels`, and the difference is not
|
|
139
|
+
* arbitrary. Datalabels draws on every dataset the moment it is globally registered, so registering
|
|
140
|
+
* it globally would visibly change every other chart on the page. `chartjs-plugin-annotation` is
|
|
141
|
+
* the `chartjs-plugin-zoom` shape instead: it draws nothing at all unless a chart supplies
|
|
142
|
+
* `options.plugins.annotation.annotations`, so a global registration is unobservable to a chart
|
|
143
|
+
* that sets none. It also has to be global -- registration is what installs the plugin's own
|
|
144
|
+
* element types and their defaults, and an inline `config.plugins` entry skips that, leaving the
|
|
145
|
+
* plugin to throw on missing `borderWidth`/`borderCapStyle` defaults the moment it draws.
|
|
146
|
+
*/
|
|
147
|
+
export declare function loadChartAndAnnotation(loadChart: () => Promise<ChartJsModule | null>, importAnnotation?: () => Promise<unknown>): Promise<ChartFeatureLoadResult<AnnotationPlugin>>;
|
|
148
|
+
/**
|
|
149
|
+
* Loads `chart.js` (reusing the cached core load) plus `chartjs-plugin-annotation`, on first actual
|
|
150
|
+
* demand — most charts set no annotations.
|
|
151
|
+
*
|
|
152
|
+
* Registered globally, like `chartjs-plugin-zoom` and unlike `chartjs-plugin-datalabels` — see
|
|
153
|
+
* `loadChartAndAnnotation()` for why the two differ. The load itself still happens only on first
|
|
154
|
+
* actual demand, so a page whose charts set no annotations never downloads the peer at all.
|
|
155
|
+
*
|
|
156
|
+
* Memoized behind a single promise assigned synchronously before any `await`, closing the
|
|
157
|
+
* check-then-act race across the `await` boundary that the zoom loader's doc describes.
|
|
158
|
+
*/
|
|
159
|
+
export declare function loadChartJsWithAnnotationResult(importAnnotation?: () => Promise<unknown>): Promise<ChartFeatureLoadResult<AnnotationPlugin>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{resolveOptionalPeerCapability}from"../../../internal/optional-peer-capabilities.js";import{loadChartJs,loadChartModule}from"./chart-core-loader.js";function isObjectLike(value){return(typeof value=="object"||typeof value=="function")&&value!==null}function isChartPlugin(candidate){return isObjectLike(candidate)&&typeof candidate.id=="string"&&candidate.id.trim().length>0}function resolveChartPlugin(value,packageName){const plugin=resolveOptionalPeerCapability(value,isChartPlugin);if(plugin)return plugin;throw new Error(`Invalid optional peer \`${packageName}\`: expected a plugin with a non-empty string \`id\`.`)}let zoomResultLoad,dataLabelsResultLoad,zoomLoad,dataLabelsLoad;async function loadChartAndZoom(importChart=()=>import("chart.js"),importZoom=()=>import("chartjs-plugin-zoom"),needsZoom=!1){const mod=await loadChartModule(importChart);if(!mod)return null;if(!needsZoom)return{mod,zoomPlugin:void 0};let zoomPlugin;try{zoomPlugin=resolveChartPlugin(await importZoom(),"chartjs-plugin-zoom")}catch(err){console.warn("<lr-chart> zoom support needs the optional peer dependency `chartjs-plugin-zoom` \u2014 charts still render without it, but the `zoom` attribute has no effect until it is installed with `pnpm add chartjs-plugin-zoom`:",err)}return{mod,zoomPlugin}}async function loadChartAndRegisterZoom(loadChart,importZoom=()=>import("chartjs-plugin-zoom")){const mod=await loadChart();if(!mod)return{kind:"core-unavailable"};const zoomPlugin=(await loadChartAndZoom(()=>Promise.resolve(mod),importZoom,!0))?.zoomPlugin;if(!zoomPlugin)return{kind:"feature-unavailable",mod};try{mod.Chart.register(zoomPlugin)}catch(err){return console.warn("<lr-chart> zoom support could not be enabled \u2014 charts still render without it, but the `zoom` attribute has no effect:",err),{kind:"feature-unavailable",mod}}return{kind:"available",mod,plugin:zoomPlugin}}function loadChartJsWithZoomResult(importZoom=()=>import("chartjs-plugin-zoom")){return zoomResultLoad??=loadChartAndRegisterZoom(loadChartJs,importZoom)}function loadChartJsWithZoom(importZoom=()=>import("chartjs-plugin-zoom")){return zoomLoad??=loadChartJsWithZoomResult(importZoom).then(result=>result.kind==="core-unavailable"?null:result.mod)}async function loadDataLabelsPlugin(importDataLabels=()=>import("chartjs-plugin-datalabels")){try{return resolveChartPlugin(await importDataLabels(),"chartjs-plugin-datalabels")}catch(err){console.warn("<lr-chart> data labels need the optional peer dependency `chartjs-plugin-datalabels` \u2014 charts still render without it, but the `data-labels`/`stack-totals` attributes have no effect until it is installed with `pnpm add chartjs-plugin-datalabels`:",err);return}}async function loadChartAndDataLabels(loadChart,importDataLabels=()=>import("chartjs-plugin-datalabels")){const mod=await loadChart();if(!mod)return{kind:"core-unavailable"};const plugin=await loadDataLabelsPlugin(importDataLabels);return plugin?{kind:"available",mod,plugin}:{kind:"feature-unavailable",mod}}function loadChartJsWithDataLabelsResult(importDataLabels=()=>import("chartjs-plugin-datalabels")){return dataLabelsResultLoad??=loadChartAndDataLabels(loadChartJs,importDataLabels)}function loadChartJsWithDataLabels(importDataLabels=()=>import("chartjs-plugin-datalabels")){return dataLabelsLoad??=loadChartJsWithDataLabelsResult(importDataLabels).then(result=>result.kind==="core-unavailable"?null:{mod:result.mod,plugin:result.kind==="available"?result.plugin:void 0})}export{loadChartAndDataLabels,loadChartAndRegisterZoom,loadChartAndZoom,loadChartJsWithDataLabels,loadChartJsWithDataLabelsResult,loadChartJsWithZoom,loadChartJsWithZoomResult,loadDataLabelsPlugin};
|
|
1
|
+
import{resolveOptionalPeerCapability}from"../../../internal/optional-peer-capabilities.js";import{loadChartJs,loadChartModule}from"./chart-core-loader.js";function isObjectLike(value){return(typeof value=="object"||typeof value=="function")&&value!==null}function isChartPlugin(candidate){return isObjectLike(candidate)&&typeof candidate.id=="string"&&candidate.id.trim().length>0}function resolveChartPlugin(value,packageName){const plugin=resolveOptionalPeerCapability(value,isChartPlugin);if(plugin)return plugin;throw new Error(`Invalid optional peer \`${packageName}\`: expected a plugin with a non-empty string \`id\`.`)}let zoomResultLoad,dataLabelsResultLoad,annotationResultLoad,zoomLoad,dataLabelsLoad;async function loadChartAndZoom(importChart=()=>import("chart.js"),importZoom=()=>import("chartjs-plugin-zoom"),needsZoom=!1){const mod=await loadChartModule(importChart);if(!mod)return null;if(!needsZoom)return{mod,zoomPlugin:void 0};let zoomPlugin;try{zoomPlugin=resolveChartPlugin(await importZoom(),"chartjs-plugin-zoom")}catch(err){console.warn("<lr-chart> zoom support needs the optional peer dependency `chartjs-plugin-zoom` \u2014 charts still render without it, but the `zoom` attribute has no effect until it is installed with `pnpm add chartjs-plugin-zoom`:",err)}return{mod,zoomPlugin}}async function loadChartAndRegisterZoom(loadChart,importZoom=()=>import("chartjs-plugin-zoom")){const mod=await loadChart();if(!mod)return{kind:"core-unavailable"};const zoomPlugin=(await loadChartAndZoom(()=>Promise.resolve(mod),importZoom,!0))?.zoomPlugin;if(!zoomPlugin)return{kind:"feature-unavailable",mod};try{mod.Chart.register(zoomPlugin)}catch(err){return console.warn("<lr-chart> zoom support could not be enabled \u2014 charts still render without it, but the `zoom` attribute has no effect:",err),{kind:"feature-unavailable",mod}}return{kind:"available",mod,plugin:zoomPlugin}}function loadChartJsWithZoomResult(importZoom=()=>import("chartjs-plugin-zoom")){return zoomResultLoad??=loadChartAndRegisterZoom(loadChartJs,importZoom)}function loadChartJsWithZoom(importZoom=()=>import("chartjs-plugin-zoom")){return zoomLoad??=loadChartJsWithZoomResult(importZoom).then(result=>result.kind==="core-unavailable"?null:result.mod)}async function loadDataLabelsPlugin(importDataLabels=()=>import("chartjs-plugin-datalabels")){try{return resolveChartPlugin(await importDataLabels(),"chartjs-plugin-datalabels")}catch(err){console.warn("<lr-chart> data labels need the optional peer dependency `chartjs-plugin-datalabels` \u2014 charts still render without it, but the `data-labels`/`stack-totals` attributes have no effect until it is installed with `pnpm add chartjs-plugin-datalabels`:",err);return}}async function loadChartAndDataLabels(loadChart,importDataLabels=()=>import("chartjs-plugin-datalabels")){const mod=await loadChart();if(!mod)return{kind:"core-unavailable"};const plugin=await loadDataLabelsPlugin(importDataLabels);return plugin?{kind:"available",mod,plugin}:{kind:"feature-unavailable",mod}}function loadChartJsWithDataLabelsResult(importDataLabels=()=>import("chartjs-plugin-datalabels")){return dataLabelsResultLoad??=loadChartAndDataLabels(loadChartJs,importDataLabels)}function loadChartJsWithDataLabels(importDataLabels=()=>import("chartjs-plugin-datalabels")){return dataLabelsLoad??=loadChartJsWithDataLabelsResult(importDataLabels).then(result=>result.kind==="core-unavailable"?null:{mod:result.mod,plugin:result.kind==="available"?result.plugin:void 0})}async function loadAnnotationPlugin(importAnnotation=()=>import("chartjs-plugin-annotation")){try{return resolveChartPlugin(await importAnnotation(),"chartjs-plugin-annotation")}catch(err){console.warn("<lr-chart> annotations need the optional peer dependency `chartjs-plugin-annotation` \u2014 charts still render without it, but the `annotations` property has no effect until it is installed with `pnpm add chartjs-plugin-annotation`:",err);return}}async function loadChartAndAnnotation(loadChart,importAnnotation=()=>import("chartjs-plugin-annotation")){const mod=await loadChart();if(!mod)return{kind:"core-unavailable"};const plugin=await loadAnnotationPlugin(importAnnotation);if(!plugin)return{kind:"feature-unavailable",mod};try{mod.Chart.register(plugin)}catch(err){return console.warn("<lr-chart> annotations could not be enabled \u2014 charts still render without them, but the `annotations` property has no effect:",err),{kind:"feature-unavailable",mod}}return{kind:"available",mod,plugin}}function loadChartJsWithAnnotationResult(importAnnotation=()=>import("chartjs-plugin-annotation")){return annotationResultLoad??=loadChartAndAnnotation(loadChartJs,importAnnotation)}export{loadAnnotationPlugin,loadChartAndAnnotation,loadChartAndDataLabels,loadChartAndRegisterZoom,loadChartAndZoom,loadChartJsWithAnnotationResult,loadChartJsWithDataLabels,loadChartJsWithDataLabelsResult,loadChartJsWithZoom,loadChartJsWithZoomResult,loadDataLabelsPlugin};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { type TemplateResult, type PropertyValues } from 'lit';
|
|
2
2
|
import { LyraElement } from '../../../internal/lyra-element.js';
|
|
3
3
|
import '../../overlays/skeleton/skeleton.class.js';
|
|
4
|
+
import type { LyraVariant } from '../../../internal/variants.js';
|
|
4
5
|
import { type LyraChartLegendVisibilityChangeDetail } from './chart-legend-visibility.js';
|
|
5
6
|
export type { LyraChartLegendVisibilityChangeDetail } from './chart-legend-visibility.js';
|
|
6
7
|
export { seriesPalette } from './chart-colors.js';
|
|
@@ -44,6 +45,24 @@ export interface LyraChartSeries {
|
|
|
44
45
|
export type LyraChartType = 'line' | 'bar' | 'scatter' | 'pie' | 'doughnut' | 'radar' | 'polarArea' | 'bubble';
|
|
45
46
|
export type LyraChartGrid = 'x' | 'y' | 'both' | 'none';
|
|
46
47
|
export type LyraChartIndexAxis = 'x' | 'y';
|
|
48
|
+
/** Scale type for a chart's value axis. The categorical axis is never affected. */
|
|
49
|
+
export type LyraChartScaleType = 'linear' | 'logarithmic';
|
|
50
|
+
/**
|
|
51
|
+
* One declarative chart annotation: a reference line (`value`) or a shaded band (`from`/`to`) on
|
|
52
|
+
* the named axis.
|
|
53
|
+
*
|
|
54
|
+
* `value` and `from`/`to` are mutually exclusive; an entry supplying neither, or non-finite
|
|
55
|
+
* numbers, is dropped rather than handed to Chart.js, where it would silently render nothing or
|
|
56
|
+
* throw. `axis` defaults to `'y'`, the value axis for the common threshold case.
|
|
57
|
+
*/
|
|
58
|
+
export interface LyraChartAnnotation {
|
|
59
|
+
readonly axis?: LyraChartIndexAxis;
|
|
60
|
+
readonly value?: number;
|
|
61
|
+
readonly from?: number;
|
|
62
|
+
readonly to?: number;
|
|
63
|
+
readonly label?: string;
|
|
64
|
+
readonly tone?: LyraVariant;
|
|
65
|
+
}
|
|
47
66
|
export type LyraChartLayoutPosition = 'left' | 'top' | 'right' | 'bottom' | 'center' | 'chartArea' | {
|
|
48
67
|
[scaleId: string]: number;
|
|
49
68
|
};
|
|
@@ -212,6 +231,7 @@ export interface LyraChartEventMap {
|
|
|
212
231
|
* @csspart reset-zoom-button - The reset-zoom control when zoom is active.
|
|
213
232
|
* @csspart description - The accessible chart summary.
|
|
214
233
|
* @csspart data-table - The optional generated or slotted data table.
|
|
234
|
+
* @csspart data-table-toggle - The disclosure button rendered by `dataTableToggle`.
|
|
215
235
|
* @csspart center - The chart-area-centered overlay wrapper for the `center` slot.
|
|
216
236
|
* @csspart error - Static visible error shown instead of `canvas` when the optional `chart.js`
|
|
217
237
|
* peer dependency is not installed; its transition is announced through a shared light-DOM alert.
|
|
@@ -241,6 +261,11 @@ export interface LyraChartEventMap {
|
|
|
241
261
|
* of an actionable generated-table value.
|
|
242
262
|
* @cssprop --lr-chart-data-table-button-active-bg - Pressed background of an actionable generated-
|
|
243
263
|
* table value; defaults to the standard active mix of `--lr-color-brand-quiet`.
|
|
264
|
+
* @cssprop [--lr-chart-data-table-toggle-hover-bg=var(--lr-color-brand-quiet)] - Hover background
|
|
265
|
+
* of the `dataTableToggle` disclosure button.
|
|
266
|
+
* @cssprop --lr-chart-data-table-toggle-active-bg - Pressed background of the `dataTableToggle`
|
|
267
|
+
* disclosure button; defaults to a mix of the hover background with the shared active mix
|
|
268
|
+
* partner.
|
|
244
269
|
* @cssprop [--lr-chart-reset-zoom-button-hover-bg=var(--lr-color-brand-quiet)] - Hover background
|
|
245
270
|
* of the reset-zoom button.
|
|
246
271
|
* @cssprop --lr-chart-reset-zoom-button-active-bg - Pressed background of the reset-zoom button;
|
|
@@ -308,6 +333,33 @@ export declare class LyraChart extends LyraElement<LyraChartEventMap> {
|
|
|
308
333
|
label: string | null;
|
|
309
334
|
/** Legend placement. `auto` uses a right legend above 480px and a bottom legend below it. */
|
|
310
335
|
legendPosition: LyraChartLegendPosition;
|
|
336
|
+
/**
|
|
337
|
+
* Scale type for the **value** axis (the categorical axis is unaffected). `'logarithmic'` plots
|
|
338
|
+
* a dataset spanning several orders of magnitude honestly, where a linear axis collapses
|
|
339
|
+
* everything below the maximum into the baseline. Inherited by `lr-line-chart`,
|
|
340
|
+
* `lr-scatter-chart` and `lr-bar-chart`.
|
|
341
|
+
*
|
|
342
|
+
* A logarithmic axis cannot represent zero or negative values (`log(0)` is `-Infinity`), so
|
|
343
|
+
* `beginAtZero` is not forwarded in that mode -- Chart.js would otherwise be handed a bound it
|
|
344
|
+
* cannot place. Non-positive data points are dropped by Chart.js's own log scale.
|
|
345
|
+
*/
|
|
346
|
+
scaleType: LyraChartScaleType;
|
|
347
|
+
/**
|
|
348
|
+
* Declarative reference lines and shaded bands — a threshold, an event year, a regime change, a
|
|
349
|
+
* highlighted period. Each entry marks either a single `value` or a `from`/`to` range on `axis`
|
|
350
|
+
* (default `'y'`), with an optional `label` and semantic `tone`.
|
|
351
|
+
*
|
|
352
|
+
* Needs the optional `chartjs-plugin-annotation` peer, loaded on first actual demand so a page
|
|
353
|
+
* with no annotated charts never downloads it. The plugin is registered globally, like
|
|
354
|
+
* `chartjs-plugin-zoom` and unlike `chartjs-plugin-datalabels`: it draws nothing unless a chart
|
|
355
|
+
* supplies annotation options, so the registration is unobservable to charts that set none, and
|
|
356
|
+
* registration is also what installs the plugin's own element defaults. Without the peer
|
|
357
|
+
* installed the chart still renders and a single console warning explains the no-op — the same
|
|
358
|
+
* fail-closed contract `data-labels` uses.
|
|
359
|
+
*
|
|
360
|
+
* Entries are included in the generated accessible description, mirroring `lr-heatmap`.
|
|
361
|
+
*/
|
|
362
|
+
annotations: readonly LyraChartAnnotation[];
|
|
311
363
|
/** Maximum value-axis bound. Non-finite values are ignored. */
|
|
312
364
|
max: number | null;
|
|
313
365
|
/** Minimum value-axis bound. Non-finite values are ignored. */
|
|
@@ -334,6 +386,27 @@ export declare class LyraChart extends LyraElement<LyraChartEventMap> {
|
|
|
334
386
|
beginAtZero: boolean;
|
|
335
387
|
/** Makes the generated data table visible; it remains screen-reader available when false. */
|
|
336
388
|
showDataTable: boolean;
|
|
389
|
+
/**
|
|
390
|
+
* Render a disclosure button above the accessible data table so a sighted reader can reveal the
|
|
391
|
+
* numbers behind the chart on demand. `showDataTable` alone is all-or-nothing -- the table is
|
|
392
|
+
* either permanently screen-reader-only or permanently visible -- which left a consumer wrapping
|
|
393
|
+
* a duplicated table in their own `<details>`.
|
|
394
|
+
*
|
|
395
|
+
* With this set, `showDataTable` becomes the disclosure's *initial* state rather than its whole
|
|
396
|
+
* behavior. The table stays in the DOM in both states, so assistive technology never loses it.
|
|
397
|
+
* @default false
|
|
398
|
+
*/
|
|
399
|
+
dataTableToggle: boolean;
|
|
400
|
+
/**
|
|
401
|
+
* Live disclosure state. Null until the reader actually toggles, so an untouched control keeps
|
|
402
|
+
* following `showDataTable` (including a later change to it) instead of freezing a seeded copy.
|
|
403
|
+
*/
|
|
404
|
+
private dataTableExpandedOverride;
|
|
405
|
+
private readonly dataTableId;
|
|
406
|
+
/** Whether the data table is currently visible. Identical to `showDataTable` whenever
|
|
407
|
+
* `dataTableToggle` is off, which is what keeps the unset path byte-identical to before. */
|
|
408
|
+
private get dataTableVisible();
|
|
409
|
+
private toggleDataTable;
|
|
337
410
|
/** Stacks the `x`/`y`(/`y2`) scale entries `buildScales()` returns; only meaningful for `bar` and `line` types. */
|
|
338
411
|
stacked: boolean;
|
|
339
412
|
/** Disables Chart.js animation. */
|
|
@@ -422,12 +495,15 @@ export declare class LyraChart extends LyraElement<LyraChartEventMap> {
|
|
|
422
495
|
private loadLibrary;
|
|
423
496
|
private loadZoomFeature;
|
|
424
497
|
private loadDataLabelsFeature;
|
|
498
|
+
private loadAnnotationFeature;
|
|
425
499
|
private loadGeneration;
|
|
426
500
|
private zoomLoadGeneration;
|
|
427
501
|
private dataLabelsLoadGeneration;
|
|
502
|
+
private annotationLoadGeneration;
|
|
428
503
|
private zoomFeatureState;
|
|
429
504
|
private dataLabelsFeatureState;
|
|
430
505
|
private dataLabelsPlugin?;
|
|
506
|
+
private annotationPlugin?;
|
|
431
507
|
private zoomed;
|
|
432
508
|
private visible;
|
|
433
509
|
private intersectionObserver?;
|
|
@@ -488,6 +564,14 @@ export declare class LyraChart extends LyraElement<LyraChartEventMap> {
|
|
|
488
564
|
private get zoomFeatureAvailable();
|
|
489
565
|
private featureWarningMessages;
|
|
490
566
|
private requestZoomFeature;
|
|
567
|
+
private requestAnnotationFeature;
|
|
568
|
+
/**
|
|
569
|
+
* Same constraint as `applyDataLabelsPlugin()`: Chart.js reads a config's inline `plugins: [...]`
|
|
570
|
+
* array ONLY at construction, so a live chart built before the peer resolved cannot gain it
|
|
571
|
+
* through `chart.update()`. Force reconstruction so the next `draw()` takes the `new Chart()`
|
|
572
|
+
* branch that reads `config.plugins`.
|
|
573
|
+
*/
|
|
574
|
+
private applyAnnotationPlugin;
|
|
491
575
|
private requestDataLabelsFeature;
|
|
492
576
|
/**
|
|
493
577
|
* Resets a stale `zoomed` flag before the render pass that's about to call
|
|
@@ -533,6 +617,24 @@ export declare class LyraChart extends LyraElement<LyraChartEventMap> {
|
|
|
533
617
|
/** Whether this chart wants the optional `chartjs-plugin-datalabels` peer loaded — either to draw
|
|
534
618
|
* per-point data labels or per-stack totals. */
|
|
535
619
|
private get needsDataLabels();
|
|
620
|
+
private get needsAnnotations();
|
|
621
|
+
/**
|
|
622
|
+
* The usable annotations: a finite single `value`, or a finite `from`/`to` pair. An entry
|
|
623
|
+
* supplying neither (or non-finite numbers) is dropped rather than handed to Chart.js, where it
|
|
624
|
+
* renders nothing at best. A reversed range is normalized rather than rejected — the author's
|
|
625
|
+
* intent is unambiguous.
|
|
626
|
+
*/
|
|
627
|
+
private normalizedAnnotations;
|
|
628
|
+
/** Resolves an annotation tone to a canvas-ready color, through the same
|
|
629
|
+
* `getComputedStyle`-then-`resolveCanvasColor` path every other chart color takes — canvas
|
|
630
|
+
* silently ignores an unparseable `strokeStyle`/`fillStyle`. */
|
|
631
|
+
private annotationColor;
|
|
632
|
+
/**
|
|
633
|
+
* The `chartjs-plugin-annotation` options for this chart, keyed by a stable synthetic id.
|
|
634
|
+
* A single `value` becomes a `line` on that axis's scale; a `from`/`to` pair becomes a `box`
|
|
635
|
+
* bounded on that axis and unbounded on the other.
|
|
636
|
+
*/
|
|
637
|
+
private annotationOptions;
|
|
536
638
|
/**
|
|
537
639
|
* `options.plugins.datalabels`. Always emitted so the chart also stays inert if
|
|
538
640
|
* a consumer independently registers the peer globally — returns `{ display: false }`
|
|
@@ -578,6 +680,10 @@ export declare class LyraChart extends LyraElement<LyraChartEventMap> {
|
|
|
578
680
|
seriesPalette(): string[];
|
|
579
681
|
private tickOptions;
|
|
580
682
|
private effectiveIndexAxis;
|
|
683
|
+
/** The resolved Chart.js scale type for a value axis, honoring `scaleType`. */
|
|
684
|
+
private valueScaleType;
|
|
685
|
+
/** `beginAtZero` for a value axis, suppressed on a logarithmic scale which cannot place zero. */
|
|
686
|
+
private valueBeginAtZero;
|
|
581
687
|
private scaleBounds;
|
|
582
688
|
private gridAxisVisible;
|
|
583
689
|
/**
|
|
@@ -673,6 +779,20 @@ export declare class LyraChart extends LyraElement<LyraChartEventMap> {
|
|
|
673
779
|
private summarizeSeries;
|
|
674
780
|
private formatSummaryValue;
|
|
675
781
|
private formatTableValue;
|
|
782
|
+
/**
|
|
783
|
+
* The `'export'` surface, for CSV cells. `LyraChartFormatSurface` has always declared it and
|
|
784
|
+
* `<lr-lite-chart>` has always emitted it, but this component never did -- so one formatter
|
|
785
|
+
* written against the documented contract behaved differently depending on which chart rendered
|
|
786
|
+
* it, silently, in exactly the place unit formatting matters most.
|
|
787
|
+
*
|
|
788
|
+
* Deliberately NOT falling back to `formatSummaryValue()`: with no formatter installed a CSV cell
|
|
789
|
+
* must stay the raw machine-readable number, not a locale-grouped string a spreadsheet would
|
|
790
|
+
* misparse. `undefined` means "leave the cell as it was".
|
|
791
|
+
*/
|
|
792
|
+
private formatExportValue;
|
|
793
|
+
/** The `'spoken'` surface, for the live announcement a keyboard user hears. Falls back to the
|
|
794
|
+
* locale number format, which is what it always used. */
|
|
795
|
+
private formatSpokenValue;
|
|
676
796
|
private tableStackAxes;
|
|
677
797
|
private tableStackTotalLabel;
|
|
678
798
|
private accessibleName;
|