@lostgradient/cinder 0.1.1 → 0.2.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 +62 -0
- package/README.md +163 -0
- package/components.json +390 -3
- package/dist/_internal/chart/chart-focus-ring.d.ts +57 -0
- package/dist/_internal/chart/chart-utilities.d.ts +2 -0
- package/dist/_internal/chart/heatmap-utilities.d.ts +60 -0
- package/dist/components/accordion/index.js +14 -1
- package/dist/components/alert/alert.schema.js +3 -3
- package/dist/components/alert/alert.types.d.ts +3 -2
- package/dist/components/alert/index.js +3 -2
- package/dist/components/alert-dialog/index.js +11 -2
- package/dist/components/area-chart/area-chart.css +57 -7
- package/dist/components/area-chart/index.js +283 -40
- package/dist/components/avatar-group/avatar-group.css +2 -3
- package/dist/components/badge/badge.css +17 -0
- package/dist/components/badge/badge.schema.js +6 -1
- package/dist/components/badge/badge.types.d.ts +7 -0
- package/dist/components/badge/index.js +4 -2
- package/dist/components/bar-chart/bar-chart.css +57 -7
- package/dist/components/bar-chart/index.js +233 -45
- package/dist/components/button/button.css +5 -3
- package/dist/components/button/index.js +11 -2
- package/dist/components/capability-gate/capability-gate.css +131 -0
- package/dist/components/capability-gate/capability-gate.schema.d.ts +3 -0
- package/dist/components/capability-gate/capability-gate.schema.js +128 -0
- package/dist/components/capability-gate/capability-gate.svelte.d.ts +19 -0
- package/dist/components/capability-gate/capability-gate.types.d.ts +70 -0
- package/dist/components/capability-gate/capability-gate.variables.d.ts +2 -0
- package/dist/components/capability-gate/capability-gate.variables.js +61 -0
- package/dist/components/capability-gate/index.d.ts +5 -0
- package/dist/components/capability-gate/index.js +285 -0
- package/dist/components/card/card.css +4 -0
- package/dist/components/card/card.schema.js +5 -1
- package/dist/components/card/card.svelte.d.ts +1 -1
- package/dist/components/card/card.types.d.ts +4 -0
- package/dist/components/card/index.d.ts +1 -1
- package/dist/components/card/index.js +8 -4
- package/dist/components/chat/index.css +2 -2
- package/dist/components/chat/index.js +159 -81
- package/dist/components/choice-grid/choice-grid-context.d.ts +23 -0
- package/dist/components/choice-grid/choice-grid.css +27 -0
- package/dist/components/choice-grid/choice-grid.schema.d.ts +3 -0
- package/dist/components/choice-grid/choice-grid.schema.js +121 -0
- package/dist/components/choice-grid/choice-grid.svelte.d.ts +20 -0
- package/dist/components/choice-grid/choice-grid.types.d.ts +122 -0
- package/dist/components/choice-grid/choice-grid.variables.d.ts +2 -0
- package/dist/components/choice-grid/choice-grid.variables.js +61 -0
- package/dist/components/choice-grid/index.d.ts +13 -0
- package/dist/components/choice-grid/index.js +466 -0
- package/dist/components/choice-grid-item/choice-grid-item.css +139 -0
- package/dist/components/choice-grid-item/choice-grid-item.schema.d.ts +3 -0
- package/dist/components/choice-grid-item/choice-grid-item.schema.js +93 -0
- package/dist/components/choice-grid-item/choice-grid-item.svelte.d.ts +17 -0
- package/dist/components/choice-grid-item/choice-grid-item.types.d.ts +24 -0
- package/dist/components/choice-grid-item/choice-grid-item.variables.d.ts +2 -0
- package/dist/components/choice-grid-item/choice-grid-item.variables.js +61 -0
- package/dist/components/choice-grid-item/index.d.ts +5 -0
- package/dist/components/choice-grid-item/index.js +203 -0
- package/dist/components/color-field/color-field.css +6 -9
- package/dist/components/color-picker/color-picker.css +31 -24
- package/dist/components/color-swatch-picker/color-swatch-picker.css +6 -9
- package/dist/components/confirm-dialog/index.js +11 -2
- package/dist/components/context-menu/index.js +114 -43
- package/dist/components/context-menu-trigger/index.js +6 -4
- package/dist/components/data-table/data-table.css +30 -0
- package/dist/components/data-table/data-table.schema.d.ts +3 -0
- package/dist/components/data-table/data-table.schema.js +103 -0
- package/dist/components/data-table/data-table.svelte.d.ts +39 -0
- package/dist/components/data-table/data-table.types.d.ts +86 -0
- package/dist/components/data-table/data-table.variables.d.ts +2 -0
- package/dist/components/data-table/data-table.variables.js +61 -0
- package/dist/components/data-table/index.d.ts +5 -0
- package/dist/components/data-table/index.js +591 -0
- package/dist/components/diff-viewer/index.js +14 -3
- package/dist/components/dropdown/index.js +115 -46
- package/dist/components/dropdown-item/dropdown-item.schema.js +13 -1
- package/dist/components/dropdown-item/dropdown-item.svelte.d.ts +1 -1
- package/dist/components/dropdown-item/dropdown-item.types.d.ts +46 -2
- package/dist/components/dropdown-item/index.d.ts +1 -1
- package/dist/components/dropdown-item/index.js +97 -28
- package/dist/components/floating-action-button/floating-action-button.css +4 -2
- package/dist/components/json-schema-editor/index.js +29 -4
- package/dist/components/keyboard-shortcuts/index.d.ts +5 -0
- package/dist/components/keyboard-shortcuts/index.js +238 -0
- package/dist/components/keyboard-shortcuts/keyboard-shortcuts.css +84 -0
- package/dist/components/keyboard-shortcuts/keyboard-shortcuts.schema.d.ts +3 -0
- package/dist/components/keyboard-shortcuts/keyboard-shortcuts.schema.js +87 -0
- package/dist/components/keyboard-shortcuts/keyboard-shortcuts.svelte.d.ts +17 -0
- package/dist/components/keyboard-shortcuts/keyboard-shortcuts.types.d.ts +42 -0
- package/dist/components/keyboard-shortcuts/keyboard-shortcuts.variables.d.ts +2 -0
- package/dist/components/keyboard-shortcuts/keyboard-shortcuts.variables.js +61 -0
- package/dist/components/line-chart/index.js +283 -40
- package/dist/components/line-chart/line-chart.css +57 -8
- package/dist/components/markdown-editor/index.js +129 -51
- package/dist/components/matrix-chart/index.d.ts +5 -0
- package/dist/components/matrix-chart/index.js +1232 -0
- package/dist/components/matrix-chart/matrix-chart.css +50 -0
- package/dist/components/matrix-chart/matrix-chart.schema.d.ts +3 -0
- package/dist/components/matrix-chart/matrix-chart.schema.js +123 -0
- package/dist/components/matrix-chart/matrix-chart.svelte.d.ts +20 -0
- package/dist/components/matrix-chart/matrix-chart.types.d.ts +52 -0
- package/dist/components/matrix-chart/matrix-chart.variables.d.ts +2 -0
- package/dist/components/matrix-chart/matrix-chart.variables.js +61 -0
- package/dist/components/media-controls/index.d.ts +5 -0
- package/dist/components/media-controls/index.js +338 -0
- package/dist/components/media-controls/media-controls.css +112 -0
- package/dist/components/media-controls/media-controls.schema.d.ts +3 -0
- package/dist/components/media-controls/media-controls.schema.js +125 -0
- package/dist/components/media-controls/media-controls.svelte.d.ts +18 -0
- package/dist/components/media-controls/media-controls.types.d.ts +77 -0
- package/dist/components/media-controls/media-controls.variables.d.ts +2 -0
- package/dist/components/media-controls/media-controls.variables.js +61 -0
- package/dist/components/navigation-bar/navigation-bar.schema.js +5 -5
- package/dist/components/navigation-bar/navigation-bar.types.d.ts +2 -1
- package/dist/components/pricing-card/index.d.ts +5 -0
- package/dist/components/pricing-card/index.js +406 -0
- package/dist/components/pricing-card/pricing-card.css +173 -0
- package/dist/components/pricing-card/pricing-card.schema.d.ts +3 -0
- package/dist/components/pricing-card/pricing-card.schema.js +100 -0
- package/dist/components/pricing-card/pricing-card.svelte.d.ts +18 -0
- package/dist/components/pricing-card/pricing-card.types.d.ts +47 -0
- package/dist/components/pricing-card/pricing-card.variables.d.ts +2 -0
- package/dist/components/pricing-card/pricing-card.variables.js +61 -0
- package/dist/components/review-editor/index.js +212 -132
- package/dist/components/share-card/index.d.ts +5 -0
- package/dist/components/share-card/index.js +446 -0
- package/dist/components/share-card/share-card.css +115 -0
- package/dist/components/share-card/share-card.schema.d.ts +3 -0
- package/dist/components/share-card/share-card.schema.js +113 -0
- package/dist/components/share-card/share-card.svelte.d.ts +18 -0
- package/dist/components/share-card/share-card.types.d.ts +66 -0
- package/dist/components/share-card/share-card.variables.d.ts +2 -0
- package/dist/components/share-card/share-card.variables.js +61 -0
- package/dist/components/shortcut-hint/index.d.ts +5 -0
- package/dist/components/shortcut-hint/index.js +197 -0
- package/dist/components/shortcut-hint/shortcut-hint.css +26 -0
- package/dist/components/shortcut-hint/shortcut-hint.schema.d.ts +3 -0
- package/dist/components/shortcut-hint/shortcut-hint.schema.js +96 -0
- package/dist/components/shortcut-hint/shortcut-hint.svelte.d.ts +17 -0
- package/dist/components/shortcut-hint/shortcut-hint.types.d.ts +33 -0
- package/dist/components/shortcut-hint/shortcut-hint.variables.d.ts +2 -0
- package/dist/components/shortcut-hint/shortcut-hint.variables.js +61 -0
- package/dist/components/skip-link/index.d.ts +4 -0
- package/dist/components/skip-link/index.js +180 -0
- package/dist/components/skip-link/skip-link.schema.d.ts +3 -0
- package/dist/components/skip-link/skip-link.schema.js +76 -0
- package/dist/components/skip-link/skip-link.svelte.d.ts +19 -0
- package/dist/components/skip-link/skip-link.types.d.ts +38 -0
- package/dist/components/skip-link/skip-link.variables.d.ts +2 -0
- package/dist/components/skip-link/skip-link.variables.js +61 -0
- package/dist/components/spectrogram/index.d.ts +5 -0
- package/dist/components/spectrogram/index.js +1156 -0
- package/dist/components/spectrogram/spectrogram.css +43 -0
- package/dist/components/spectrogram/spectrogram.schema.d.ts +3 -0
- package/dist/components/spectrogram/spectrogram.schema.js +103 -0
- package/dist/components/spectrogram/spectrogram.svelte.d.ts +21 -0
- package/dist/components/spectrogram/spectrogram.types.d.ts +60 -0
- package/dist/components/spectrogram/spectrogram.variables.d.ts +2 -0
- package/dist/components/spectrogram/spectrogram.variables.js +61 -0
- package/dist/components/spectrum-chart/index.d.ts +5 -0
- package/dist/components/spectrum-chart/index.js +1056 -0
- package/dist/components/spectrum-chart/spectrum-chart.css +49 -0
- package/dist/components/spectrum-chart/spectrum-chart.schema.d.ts +3 -0
- package/dist/components/spectrum-chart/spectrum-chart.schema.js +97 -0
- package/dist/components/spectrum-chart/spectrum-chart.svelte.d.ts +21 -0
- package/dist/components/spectrum-chart/spectrum-chart.types.d.ts +41 -0
- package/dist/components/spectrum-chart/spectrum-chart.variables.d.ts +2 -0
- package/dist/components/spectrum-chart/spectrum-chart.variables.js +61 -0
- package/dist/components/status-dot/status-dot.css +8 -0
- package/dist/components/status-dot/status-dot.schema.js +3 -3
- package/dist/components/status-dot/status-dot.types.d.ts +5 -2
- package/dist/components/subscription-badge/index.d.ts +5 -0
- package/dist/components/subscription-badge/index.js +383 -0
- package/dist/components/subscription-badge/subscription-badge.css +18 -0
- package/dist/components/subscription-badge/subscription-badge.schema.d.ts +3 -0
- package/dist/components/subscription-badge/subscription-badge.schema.js +77 -0
- package/dist/components/subscription-badge/subscription-badge.svelte.d.ts +19 -0
- package/dist/components/subscription-badge/subscription-badge.types.d.ts +28 -0
- package/dist/components/subscription-badge/subscription-badge.variables.d.ts +2 -0
- package/dist/components/subscription-badge/subscription-badge.variables.js +61 -0
- package/dist/components/tab/index.js +14 -1
- package/dist/components/table/index.js +26 -17
- package/dist/components/table-cell/index.js +18 -9
- package/dist/components/table-cell/table-cell.schema.js +5 -1
- package/dist/components/table-cell/table-cell.types.d.ts +16 -1
- package/dist/components/tabs/index.js +14 -1
- package/dist/components/waveform/index.d.ts +5 -0
- package/dist/components/waveform/index.js +1075 -0
- package/dist/components/waveform/waveform.css +53 -0
- package/dist/components/waveform/waveform.schema.d.ts +3 -0
- package/dist/components/waveform/waveform.schema.js +98 -0
- package/dist/components/waveform/waveform.svelte.d.ts +20 -0
- package/dist/components/waveform/waveform.types.d.ts +42 -0
- package/dist/components/waveform/waveform.variables.d.ts +2 -0
- package/dist/components/waveform/waveform.variables.js +61 -0
- package/dist/index.d.ts +33 -2
- package/dist/index.js +144 -115
- package/dist/server/components/accordion/index.js +14 -1
- package/dist/server/components/alert/alert.schema.js +3 -3
- package/dist/server/components/alert/index.js +3 -2
- package/dist/server/components/alert-dialog/index.js +12 -3
- package/dist/server/components/area-chart/index.css +50 -3
- package/dist/server/components/area-chart/index.js +181 -2
- package/dist/server/components/avatar-group/index.css +1 -1
- package/dist/server/components/badge/badge.schema.js +6 -1
- package/dist/server/components/badge/index.css +4 -0
- package/dist/server/components/badge/index.js +3 -1
- package/dist/server/components/bar-chart/index.css +50 -3
- package/dist/server/components/bar-chart/index.js +166 -2
- package/dist/server/components/button/index.css +1 -1
- package/dist/server/components/button/index.js +12 -3
- package/dist/server/components/capability-gate/capability-gate.schema.js +110 -0
- package/dist/server/components/capability-gate/capability-gate.variables.js +43 -0
- package/dist/server/components/capability-gate/index.css +121 -0
- package/dist/server/components/capability-gate/index.js +168 -0
- package/dist/server/components/card/card.schema.js +5 -1
- package/dist/server/components/card/index.css +9 -1
- package/dist/server/components/card/index.js +3 -2
- package/dist/server/components/chat/index.css +2 -2
- package/dist/server/components/chat/index.js +78 -19
- package/dist/server/components/choice-grid/choice-grid.schema.js +103 -0
- package/dist/server/components/choice-grid/choice-grid.variables.js +43 -0
- package/dist/server/components/choice-grid/index.css +103 -0
- package/dist/server/components/choice-grid/index.js +383 -0
- package/dist/server/components/choice-grid-item/choice-grid-item.schema.js +75 -0
- package/dist/server/components/choice-grid-item/choice-grid-item.variables.js +43 -0
- package/dist/server/components/choice-grid-item/index.css +86 -0
- package/dist/server/components/choice-grid-item/index.js +139 -0
- package/dist/server/components/color-field/index.css +2 -4
- package/dist/server/components/color-picker/index.css +14 -10
- package/dist/server/components/color-swatch-picker/index.css +2 -4
- package/dist/server/components/confirm-dialog/index.js +12 -3
- package/dist/server/components/context-menu/index.js +72 -20
- package/dist/server/components/context-menu-trigger/index.js +6 -4
- package/dist/server/components/data-table/data-table.schema.js +85 -0
- package/dist/server/components/data-table/data-table.variables.js +43 -0
- package/dist/server/components/data-table/index.css +182 -0
- package/dist/server/components/data-table/index.js +469 -0
- package/dist/server/components/diff-viewer/index.js +14 -3
- package/dist/server/components/dropdown/index.js +67 -17
- package/dist/server/components/dropdown-item/dropdown-item.schema.js +13 -1
- package/dist/server/components/dropdown-item/index.js +67 -17
- package/dist/server/components/floating-action-button/index.css +1 -1
- package/dist/server/components/json-schema-editor/index.js +29 -4
- package/dist/server/components/keyboard-shortcuts/index.css +86 -0
- package/dist/server/components/keyboard-shortcuts/index.js +149 -0
- package/dist/server/components/keyboard-shortcuts/keyboard-shortcuts.schema.js +69 -0
- package/dist/server/components/keyboard-shortcuts/keyboard-shortcuts.variables.js +43 -0
- package/dist/server/components/line-chart/index.css +50 -3
- package/dist/server/components/line-chart/index.js +181 -2
- package/dist/server/components/markdown-editor/index.js +78 -19
- package/dist/server/components/matrix-chart/index.css +52 -0
- package/dist/server/components/matrix-chart/index.js +1026 -0
- package/dist/server/components/matrix-chart/matrix-chart.schema.js +105 -0
- package/dist/server/components/matrix-chart/matrix-chart.variables.js +43 -0
- package/dist/server/components/media-controls/index.css +109 -0
- package/dist/server/components/media-controls/index.js +192 -0
- package/dist/server/components/media-controls/media-controls.schema.js +107 -0
- package/dist/server/components/media-controls/media-controls.variables.js +43 -0
- package/dist/server/components/navigation-bar/navigation-bar.schema.js +5 -5
- package/dist/server/components/pricing-card/index.css +131 -0
- package/dist/server/components/pricing-card/index.js +258 -0
- package/dist/server/components/pricing-card/pricing-card.schema.js +82 -0
- package/dist/server/components/pricing-card/pricing-card.variables.js +43 -0
- package/dist/server/components/review-editor/index.css +2 -2
- package/dist/server/components/review-editor/index.js +80 -19
- package/dist/server/components/share-card/index.css +113 -0
- package/dist/server/components/share-card/index.js +270 -0
- package/dist/server/components/share-card/share-card.schema.js +95 -0
- package/dist/server/components/share-card/share-card.variables.js +43 -0
- package/dist/server/components/shortcut-hint/index.css +28 -0
- package/dist/server/components/shortcut-hint/index.js +134 -0
- package/dist/server/components/shortcut-hint/shortcut-hint.schema.js +78 -0
- package/dist/server/components/shortcut-hint/shortcut-hint.variables.js +43 -0
- package/dist/server/components/skip-link/index.js +141 -0
- package/dist/server/components/skip-link/skip-link.schema.js +58 -0
- package/dist/server/components/skip-link/skip-link.variables.js +43 -0
- package/dist/server/components/spectrogram/index.css +45 -0
- package/dist/server/components/spectrogram/index.js +970 -0
- package/dist/server/components/spectrogram/spectrogram.schema.js +85 -0
- package/dist/server/components/spectrogram/spectrogram.variables.js +43 -0
- package/dist/server/components/spectrum-chart/index.css +51 -0
- package/dist/server/components/spectrum-chart/index.js +871 -0
- package/dist/server/components/spectrum-chart/spectrum-chart.schema.js +79 -0
- package/dist/server/components/spectrum-chart/spectrum-chart.variables.js +43 -0
- package/dist/server/components/status-dot/index.css +8 -0
- package/dist/server/components/status-dot/status-dot.schema.js +3 -3
- package/dist/server/components/subscription-badge/index.css +2 -0
- package/dist/server/components/subscription-badge/index.js +339 -0
- package/dist/server/components/subscription-badge/subscription-badge.schema.js +59 -0
- package/dist/server/components/subscription-badge/subscription-badge.variables.js +43 -0
- package/dist/server/components/tab/index.js +14 -1
- package/dist/server/components/table/index.js +13 -8
- package/dist/server/components/table-cell/index.js +13 -8
- package/dist/server/components/table-cell/table-cell.schema.js +5 -1
- package/dist/server/components/tabs/index.js +14 -1
- package/dist/server/components/waveform/index.css +55 -0
- package/dist/server/components/waveform/index.js +907 -0
- package/dist/server/components/waveform/waveform.schema.js +80 -0
- package/dist/server/components/waveform/waveform.variables.js +43 -0
- package/dist/server/index.css +1137 -55
- package/dist/server/index.js +4225 -1750
- package/package.json +380 -2
- package/src/_internal/chart/chart-focus-ring.ts +209 -0
- package/src/_internal/chart/chart-utilities.ts +4 -0
- package/src/_internal/chart/heatmap-utilities.ts +159 -0
- package/src/components/accordion/accordion.examples.json +1 -0
- package/src/components/alert/README.md +5 -5
- package/src/components/alert/alert.schema.json +2 -2
- package/src/components/alert/alert.schema.ts +3 -2
- package/src/components/alert/alert.svelte +5 -1
- package/src/components/alert/alert.types.ts +3 -2
- package/src/components/area-chart/README.md +62 -0
- package/src/components/area-chart/area-chart.css +57 -7
- package/src/components/area-chart/area-chart.svelte +128 -10
- package/src/components/avatar-group/avatar-group.css +2 -3
- package/src/components/avatar-group/avatar-group.examples.json +1 -0
- package/src/components/backdrop/README.md +56 -0
- package/src/components/badge/README.md +6 -5
- package/src/components/badge/badge.css +17 -0
- package/src/components/badge/badge.schema.json +5 -0
- package/src/components/badge/badge.schema.ts +6 -0
- package/src/components/badge/badge.svelte +2 -0
- package/src/components/badge/badge.types.ts +7 -0
- package/src/components/bar-chart/README.md +65 -0
- package/src/components/bar-chart/bar-chart.css +57 -7
- package/src/components/bar-chart/bar-chart.svelte +94 -13
- package/src/components/button/button.css +5 -3
- package/src/components/button/button.examples.json +1 -0
- package/src/components/button/button.svelte +15 -0
- package/src/components/capability-gate/README.md +60 -0
- package/src/components/capability-gate/capability-gate.css +131 -0
- package/src/components/capability-gate/capability-gate.examples.json +19 -0
- package/src/components/capability-gate/capability-gate.schema.json +68 -0
- package/src/components/capability-gate/capability-gate.schema.ts +72 -0
- package/src/components/capability-gate/capability-gate.svelte +186 -0
- package/src/components/capability-gate/capability-gate.types.ts +83 -0
- package/src/components/capability-gate/capability-gate.variables.json +1 -0
- package/src/components/capability-gate/capability-gate.variables.ts +3 -0
- package/src/components/capability-gate/index.ts +10 -0
- package/src/components/card/README.md +1 -0
- package/src/components/card/card.css +4 -0
- package/src/components/card/card.examples.json +6 -0
- package/src/components/card/card.schema.json +4 -0
- package/src/components/card/card.schema.ts +5 -0
- package/src/components/card/card.svelte +9 -2
- package/src/components/card/card.types.ts +4 -0
- package/src/components/card/index.ts +1 -1
- package/src/components/chat/README.md +81 -0
- package/src/components/chat/container/chat-jump-controls.svelte +12 -9
- package/src/components/chat/input/chat-input.svelte +7 -8
- package/src/components/chat/message/chat-message.svelte +15 -20
- package/src/components/chat/message/tool-call-group.svelte +10 -4
- package/src/components/choice-grid/README.md +66 -0
- package/src/components/choice-grid/choice-grid-context.ts +30 -0
- package/src/components/choice-grid/choice-grid.css +27 -0
- package/src/components/choice-grid/choice-grid.examples.json +31 -0
- package/src/components/choice-grid/choice-grid.schema.json +61 -0
- package/src/components/choice-grid/choice-grid.schema.ts +70 -0
- package/src/components/choice-grid/choice-grid.svelte +272 -0
- package/src/components/choice-grid/choice-grid.types.ts +152 -0
- package/src/components/choice-grid/choice-grid.variables.json +1 -0
- package/src/components/choice-grid/choice-grid.variables.ts +3 -0
- package/src/components/choice-grid/index.ts +22 -0
- package/src/components/choice-grid-item/README.md +41 -0
- package/src/components/choice-grid-item/choice-grid-item.css +139 -0
- package/src/components/choice-grid-item/choice-grid-item.schema.json +32 -0
- package/src/components/choice-grid-item/choice-grid-item.schema.ts +38 -0
- package/src/components/choice-grid-item/choice-grid-item.svelte +139 -0
- package/src/components/choice-grid-item/choice-grid-item.types.ts +30 -0
- package/src/components/choice-grid-item/choice-grid-item.variables.json +1 -0
- package/src/components/choice-grid-item/choice-grid-item.variables.ts +3 -0
- package/src/components/choice-grid-item/index.ts +6 -0
- package/src/components/click-away-listener/README.md +50 -0
- package/src/components/color-field/color-field.css +6 -9
- package/src/components/color-picker/color-picker.css +31 -24
- package/src/components/color-swatch-picker/color-swatch-picker.css +6 -9
- package/src/components/command-menu/README.md +61 -0
- package/src/components/confirm-dialog/confirm-dialog.examples.json +6 -0
- package/src/components/context-menu/README.md +55 -0
- package/src/components/context-menu-trigger/README.md +50 -0
- package/src/components/context-menu-trigger/context-menu-trigger.svelte +5 -3
- package/src/components/data-table/README.md +67 -0
- package/src/components/data-table/data-table.css +30 -0
- package/src/components/data-table/data-table.examples.json +19 -0
- package/src/components/data-table/data-table.schema.json +43 -0
- package/src/components/data-table/data-table.schema.ts +50 -0
- package/src/components/data-table/data-table.svelte +106 -0
- package/src/components/data-table/data-table.types.ts +89 -0
- package/src/components/data-table/data-table.variables.json +1 -0
- package/src/components/data-table/data-table.variables.ts +3 -0
- package/src/components/data-table/index.ts +6 -0
- package/src/components/diff-viewer/README.md +59 -0
- package/src/components/diff-viewer/front-matter-header.svelte +20 -4
- package/src/components/dropdown-group/README.md +52 -0
- package/src/components/dropdown-item/README.md +10 -7
- package/src/components/dropdown-item/dropdown-item.schema.json +12 -0
- package/src/components/dropdown-item/dropdown-item.schema.ts +14 -0
- package/src/components/dropdown-item/dropdown-item.svelte +108 -25
- package/src/components/dropdown-item/dropdown-item.types.ts +58 -2
- package/src/components/dropdown-item/index.ts +6 -1
- package/src/components/floating-action-button/README.md +53 -0
- package/src/components/floating-action-button/floating-action-button.css +4 -2
- package/src/components/form-section/form-section.examples.json +6 -0
- package/src/components/hover-card/README.md +60 -0
- package/src/components/json-schema-editor/README.md +59 -0
- package/src/components/kanban-board/README.md +62 -0
- package/src/components/keyboard-shortcuts/README.md +51 -0
- package/src/components/keyboard-shortcuts/index.ts +10 -0
- package/src/components/keyboard-shortcuts/keyboard-shortcuts.css +84 -0
- package/src/components/keyboard-shortcuts/keyboard-shortcuts.examples.json +13 -0
- package/src/components/keyboard-shortcuts/keyboard-shortcuts.schema.json +27 -0
- package/src/components/keyboard-shortcuts/keyboard-shortcuts.schema.ts +31 -0
- package/src/components/keyboard-shortcuts/keyboard-shortcuts.svelte +91 -0
- package/src/components/keyboard-shortcuts/keyboard-shortcuts.types.ts +46 -0
- package/src/components/keyboard-shortcuts/keyboard-shortcuts.variables.json +1 -0
- package/src/components/keyboard-shortcuts/keyboard-shortcuts.variables.ts +3 -0
- package/src/components/line-chart/README.md +61 -0
- package/src/components/line-chart/line-chart.css +57 -8
- package/src/components/line-chart/line-chart.svelte +128 -10
- package/src/components/link/README.md +55 -0
- package/src/components/markdown-editor/README.md +70 -0
- package/src/components/markdown-editor/editor-toolbar/toolbar-button.svelte +9 -4
- package/src/components/markdown-editor/editor-toolbar/toolbar-dropdown.svelte +9 -4
- package/src/components/markdown-editor/prosemirror.css +4 -2
- package/src/components/matrix-chart/README.md +61 -0
- package/src/components/matrix-chart/index.ts +10 -0
- package/src/components/matrix-chart/matrix-chart.css +50 -0
- package/src/components/matrix-chart/matrix-chart.examples.json +19 -0
- package/src/components/matrix-chart/matrix-chart.schema.json +63 -0
- package/src/components/matrix-chart/matrix-chart.schema.ts +67 -0
- package/src/components/matrix-chart/matrix-chart.svelte +336 -0
- package/src/components/matrix-chart/matrix-chart.types.ts +56 -0
- package/src/components/matrix-chart/matrix-chart.variables.json +1 -0
- package/src/components/matrix-chart/matrix-chart.variables.ts +3 -0
- package/src/components/media-controls/README.md +60 -0
- package/src/components/media-controls/index.ts +6 -0
- package/src/components/media-controls/media-controls.css +112 -0
- package/src/components/media-controls/media-controls.examples.json +19 -0
- package/src/components/media-controls/media-controls.schema.json +65 -0
- package/src/components/media-controls/media-controls.schema.ts +69 -0
- package/src/components/media-controls/media-controls.svelte +238 -0
- package/src/components/media-controls/media-controls.types.ts +80 -0
- package/src/components/media-controls/media-controls.variables.json +1 -0
- package/src/components/media-controls/media-controls.variables.ts +3 -0
- package/src/components/menu-bar/README.md +53 -0
- package/src/components/navigation-bar/README.md +1 -1
- package/src/components/navigation-bar/navigation-bar.schema.json +4 -4
- package/src/components/navigation-bar/navigation-bar.schema.ts +4 -4
- package/src/components/navigation-bar/navigation-bar.types.ts +2 -1
- package/src/components/pricing-card/README.md +55 -0
- package/src/components/pricing-card/index.ts +6 -0
- package/src/components/pricing-card/pricing-card.css +173 -0
- package/src/components/pricing-card/pricing-card.examples.json +19 -0
- package/src/components/pricing-card/pricing-card.schema.json +40 -0
- package/src/components/pricing-card/pricing-card.schema.ts +44 -0
- package/src/components/pricing-card/pricing-card.svelte +70 -0
- package/src/components/pricing-card/pricing-card.types.ts +49 -0
- package/src/components/pricing-card/pricing-card.variables.json +1 -0
- package/src/components/pricing-card/pricing-card.variables.ts +3 -0
- package/src/components/review-editor/README.md +64 -0
- package/src/components/review-editor/comment-composer.svelte +8 -8
- package/src/components/review-editor/comment-list.svelte +10 -1
- package/src/components/search-field/search-field.examples.json +13 -0
- package/src/components/segment/README.md +55 -0
- package/src/components/share-card/README.md +58 -0
- package/src/components/share-card/index.ts +6 -0
- package/src/components/share-card/share-card.css +115 -0
- package/src/components/share-card/share-card.examples.json +19 -0
- package/src/components/share-card/share-card.schema.json +53 -0
- package/src/components/share-card/share-card.schema.ts +57 -0
- package/src/components/share-card/share-card.svelte +330 -0
- package/src/components/share-card/share-card.types.ts +69 -0
- package/src/components/share-card/share-card.variables.json +1 -0
- package/src/components/share-card/share-card.variables.ts +3 -0
- package/src/components/shortcut-hint/README.md +52 -0
- package/src/components/shortcut-hint/index.ts +6 -0
- package/src/components/shortcut-hint/shortcut-hint.css +26 -0
- package/src/components/shortcut-hint/shortcut-hint.examples.json +13 -0
- package/src/components/shortcut-hint/shortcut-hint.schema.json +36 -0
- package/src/components/shortcut-hint/shortcut-hint.schema.ts +40 -0
- package/src/components/shortcut-hint/shortcut-hint.svelte +62 -0
- package/src/components/shortcut-hint/shortcut-hint.types.ts +35 -0
- package/src/components/shortcut-hint/shortcut-hint.variables.json +1 -0
- package/src/components/shortcut-hint/shortcut-hint.variables.ts +3 -0
- package/src/components/side-navigation/side-navigation.examples.json +6 -0
- package/src/components/skip-link/README.md +50 -0
- package/src/components/skip-link/index.ts +5 -0
- package/src/components/skip-link/skip-link.examples.json +13 -0
- package/src/components/skip-link/skip-link.schema.json +16 -0
- package/src/components/skip-link/skip-link.schema.ts +20 -0
- package/src/components/skip-link/skip-link.svelte +86 -0
- package/src/components/skip-link/skip-link.types.ts +40 -0
- package/src/components/skip-link/skip-link.variables.json +1 -0
- package/src/components/skip-link/skip-link.variables.ts +3 -0
- package/src/components/spectrogram/README.md +58 -0
- package/src/components/spectrogram/index.ts +10 -0
- package/src/components/spectrogram/spectrogram.css +43 -0
- package/src/components/spectrogram/spectrogram.examples.json +13 -0
- package/src/components/spectrogram/spectrogram.schema.json +43 -0
- package/src/components/spectrogram/spectrogram.schema.ts +47 -0
- package/src/components/spectrogram/spectrogram.svelte +284 -0
- package/src/components/spectrogram/spectrogram.types.ts +63 -0
- package/src/components/spectrogram/spectrogram.variables.json +1 -0
- package/src/components/spectrogram/spectrogram.variables.ts +3 -0
- package/src/components/spectrum-chart/README.md +57 -0
- package/src/components/spectrum-chart/index.ts +10 -0
- package/src/components/spectrum-chart/spectrum-chart.css +49 -0
- package/src/components/spectrum-chart/spectrum-chart.examples.json +13 -0
- package/src/components/spectrum-chart/spectrum-chart.schema.json +37 -0
- package/src/components/spectrum-chart/spectrum-chart.schema.ts +41 -0
- package/src/components/spectrum-chart/spectrum-chart.svelte +247 -0
- package/src/components/spectrum-chart/spectrum-chart.types.ts +44 -0
- package/src/components/spectrum-chart/spectrum-chart.variables.json +1 -0
- package/src/components/spectrum-chart/spectrum-chart.variables.ts +3 -0
- package/src/components/status-dot/README.md +7 -7
- package/src/components/status-dot/status-dot.css +8 -0
- package/src/components/status-dot/status-dot.schema.json +2 -2
- package/src/components/status-dot/status-dot.schema.ts +3 -2
- package/src/components/status-dot/status-dot.types.ts +13 -2
- package/src/components/subscription-badge/README.md +50 -0
- package/src/components/subscription-badge/index.ts +6 -0
- package/src/components/subscription-badge/subscription-badge.css +18 -0
- package/src/components/subscription-badge/subscription-badge.examples.json +19 -0
- package/src/components/subscription-badge/subscription-badge.schema.json +16 -0
- package/src/components/subscription-badge/subscription-badge.schema.ts +21 -0
- package/src/components/subscription-badge/subscription-badge.svelte +69 -0
- package/src/components/subscription-badge/subscription-badge.types.ts +37 -0
- package/src/components/subscription-badge/subscription-badge.variables.json +1 -0
- package/src/components/subscription-badge/subscription-badge.variables.ts +3 -0
- package/src/components/table-cell/README.md +6 -5
- package/src/components/table-cell/table-cell.schema.json +4 -0
- package/src/components/table-cell/table-cell.schema.ts +5 -0
- package/src/components/table-cell/table-cell.svelte +9 -3
- package/src/components/table-cell/table-cell.types.ts +16 -1
- package/src/components/tag-input/README.md +75 -0
- package/src/components/typography/README.md +51 -0
- package/src/components/waveform/README.md +57 -0
- package/src/components/waveform/index.ts +6 -0
- package/src/components/waveform/waveform.css +53 -0
- package/src/components/waveform/waveform.examples.json +19 -0
- package/src/components/waveform/waveform.schema.json +38 -0
- package/src/components/waveform/waveform.schema.ts +42 -0
- package/src/components/waveform/waveform.svelte +286 -0
- package/src/components/waveform/waveform.types.ts +45 -0
- package/src/components/waveform/waveform.variables.json +1 -0
- package/src/components/waveform/waveform.variables.ts +3 -0
- package/src/index.ts +85 -2
- package/src/styles/components.css +13 -0
- package/src/styles/shell.css +3 -0
- package/src/styles/tokens-base.css +59 -22
|
@@ -361,6 +361,7 @@ function createBarModel(options) {
|
|
|
361
361
|
const categoryTicks = sortedCategories.map((category, index) => {
|
|
362
362
|
const categoryPosition = categoryScale(category.key) ?? 0;
|
|
363
363
|
return {
|
|
364
|
+
categoryKey: category.key,
|
|
364
365
|
label: formatXValue(category, orientation === "vertical" ? xAxis : yAxis, { index }),
|
|
365
366
|
x: orientation === "vertical" ? categoryPosition + categoryScale.bandwidth() / 2 : -8,
|
|
366
367
|
y: orientation === "vertical" ? geometry.plotHeight + 20 : categoryPosition + categoryScale.bandwidth() / 2
|
|
@@ -446,6 +447,7 @@ function createBarModel(options) {
|
|
|
446
447
|
});
|
|
447
448
|
if (rowValues.length > 0) {
|
|
448
449
|
tableRows.push({
|
|
450
|
+
categoryKey: category.key,
|
|
449
451
|
categoryLabel: formatXValue(category, orientation === "vertical" ? xAxis : yAxis, {
|
|
450
452
|
index: tableRows.length
|
|
451
453
|
}),
|
|
@@ -686,6 +688,125 @@ function formatPathNumber(value) {
|
|
|
686
688
|
return Number(value.toFixed(3)).toString();
|
|
687
689
|
}
|
|
688
690
|
|
|
691
|
+
// src/_internal/chart/chart-focus-ring.ts
|
|
692
|
+
var DEFAULT_CHART_FOCUS_RING_STROKE_PADDING = 8;
|
|
693
|
+
var DEFAULT_POINT_FOCUS_RING_RADIUS = 10;
|
|
694
|
+
var MINIMUM_FOCUS_RING_SIZE = 2;
|
|
695
|
+
var MINIMUM_BAR_FOCUS_RING_SIZE = 12;
|
|
696
|
+
var FOCUS_RING_DOT_RADIUS = 2.5;
|
|
697
|
+
function createPointFocusRingGeometry(options) {
|
|
698
|
+
const {
|
|
699
|
+
target,
|
|
700
|
+
plotWidth,
|
|
701
|
+
plotHeight,
|
|
702
|
+
strokePadding = DEFAULT_CHART_FOCUS_RING_STROKE_PADDING,
|
|
703
|
+
radius = DEFAULT_POINT_FOCUS_RING_RADIUS
|
|
704
|
+
} = options;
|
|
705
|
+
if (plotWidth <= 0 || plotHeight <= 0)
|
|
706
|
+
return null;
|
|
707
|
+
const drawableWidth = plotWidth - strokePadding * 2;
|
|
708
|
+
const drawableHeight = plotHeight - strokePadding * 2;
|
|
709
|
+
const largestDrawableRadius = Math.min(drawableWidth, drawableHeight) / 2;
|
|
710
|
+
if (largestDrawableRadius < MINIMUM_FOCUS_RING_SIZE || drawableWidth < FOCUS_RING_DOT_RADIUS * 2 || drawableHeight < FOCUS_RING_DOT_RADIUS * 2) {
|
|
711
|
+
return createPlotFrameFocusRingGeometry(plotWidth, plotHeight, strokePadding);
|
|
712
|
+
}
|
|
713
|
+
const resolvedRadius = Math.min(Math.max(radius, MINIMUM_FOCUS_RING_SIZE), largestDrawableRadius);
|
|
714
|
+
const minimumCenterX = strokePadding + resolvedRadius;
|
|
715
|
+
const maximumCenterX = plotWidth - strokePadding - resolvedRadius;
|
|
716
|
+
const minimumCenterY = strokePadding + resolvedRadius;
|
|
717
|
+
const maximumCenterY = plotHeight - strokePadding - resolvedRadius;
|
|
718
|
+
const cx = clamp(target.x, minimumCenterX, maximumCenterX);
|
|
719
|
+
const cy = clamp(target.y, minimumCenterY, maximumCenterY);
|
|
720
|
+
const dotInset = strokePadding + FOCUS_RING_DOT_RADIUS;
|
|
721
|
+
let targetX = clamp(target.x, dotInset, plotWidth - dotInset);
|
|
722
|
+
let targetY = clamp(target.y, dotInset, plotHeight - dotInset);
|
|
723
|
+
const initialOffsetX = targetX - cx;
|
|
724
|
+
const initialOffsetY = targetY - cy;
|
|
725
|
+
const initialOffsetDistance = Math.hypot(initialOffsetX, initialOffsetY);
|
|
726
|
+
if (initialOffsetDistance > resolvedRadius) {
|
|
727
|
+
const scale = resolvedRadius / initialOffsetDistance;
|
|
728
|
+
targetX = cx + initialOffsetX * scale;
|
|
729
|
+
targetY = cy + initialOffsetY * scale;
|
|
730
|
+
}
|
|
731
|
+
const offsetX = targetX - cx;
|
|
732
|
+
const offsetY = targetY - cy;
|
|
733
|
+
const offsetDistance = Math.hypot(offsetX, offsetY);
|
|
734
|
+
const geometry = {
|
|
735
|
+
kind: "point",
|
|
736
|
+
cx,
|
|
737
|
+
cy,
|
|
738
|
+
radius: resolvedRadius,
|
|
739
|
+
targetX,
|
|
740
|
+
targetY,
|
|
741
|
+
offsetX,
|
|
742
|
+
offsetY,
|
|
743
|
+
offsetDistance
|
|
744
|
+
};
|
|
745
|
+
if (offsetDistance <= 0)
|
|
746
|
+
return geometry;
|
|
747
|
+
return {
|
|
748
|
+
...geometry,
|
|
749
|
+
connector: {
|
|
750
|
+
x1: targetX,
|
|
751
|
+
y1: targetY,
|
|
752
|
+
x2: cx,
|
|
753
|
+
y2: cy
|
|
754
|
+
},
|
|
755
|
+
dot: {
|
|
756
|
+
cx: targetX,
|
|
757
|
+
cy: targetY,
|
|
758
|
+
radius: FOCUS_RING_DOT_RADIUS
|
|
759
|
+
}
|
|
760
|
+
};
|
|
761
|
+
}
|
|
762
|
+
function createBarFocusRingGeometry(options) {
|
|
763
|
+
const {
|
|
764
|
+
target,
|
|
765
|
+
plotWidth,
|
|
766
|
+
plotHeight,
|
|
767
|
+
strokePadding = DEFAULT_CHART_FOCUS_RING_STROKE_PADDING,
|
|
768
|
+
minimumWidth = MINIMUM_BAR_FOCUS_RING_SIZE,
|
|
769
|
+
minimumHeight = MINIMUM_BAR_FOCUS_RING_SIZE
|
|
770
|
+
} = options;
|
|
771
|
+
if (plotWidth <= 0 || plotHeight <= 0)
|
|
772
|
+
return null;
|
|
773
|
+
const requestedWidth = Math.max(target.width ?? 0, minimumWidth);
|
|
774
|
+
const requestedHeight = Math.max(target.height ?? 0, minimumHeight);
|
|
775
|
+
const drawableWidth = plotWidth - strokePadding * 2;
|
|
776
|
+
const drawableHeight = plotHeight - strokePadding * 2;
|
|
777
|
+
if (drawableWidth < MINIMUM_FOCUS_RING_SIZE || drawableHeight < MINIMUM_FOCUS_RING_SIZE) {
|
|
778
|
+
return createPlotFrameFocusRingGeometry(plotWidth, plotHeight, strokePadding);
|
|
779
|
+
}
|
|
780
|
+
const width = Math.min(requestedWidth, drawableWidth);
|
|
781
|
+
const height = Math.min(requestedHeight, drawableHeight);
|
|
782
|
+
const x = clamp(target.x - width / 2, strokePadding, plotWidth - width - strokePadding);
|
|
783
|
+
const y = clamp(target.y - height / 2, strokePadding, plotHeight - height - strokePadding);
|
|
784
|
+
return {
|
|
785
|
+
kind: "bar",
|
|
786
|
+
x,
|
|
787
|
+
y,
|
|
788
|
+
width,
|
|
789
|
+
height,
|
|
790
|
+
radius: Math.min(4, width / 2, height / 2)
|
|
791
|
+
};
|
|
792
|
+
}
|
|
793
|
+
function createPlotFrameFocusRingGeometry(plotWidth, plotHeight, strokePadding) {
|
|
794
|
+
const inset = Math.min(strokePadding, Math.max(0, plotWidth - MINIMUM_FOCUS_RING_SIZE) / 2, Math.max(0, plotHeight - MINIMUM_FOCUS_RING_SIZE) / 2);
|
|
795
|
+
return {
|
|
796
|
+
kind: "plot-frame",
|
|
797
|
+
x: inset,
|
|
798
|
+
y: inset,
|
|
799
|
+
width: Math.max(0, plotWidth - inset * 2),
|
|
800
|
+
height: Math.max(0, plotHeight - inset * 2),
|
|
801
|
+
radius: 0
|
|
802
|
+
};
|
|
803
|
+
}
|
|
804
|
+
function clamp(value, minimum, maximum) {
|
|
805
|
+
if (maximum < minimum)
|
|
806
|
+
return (minimum + maximum) / 2;
|
|
807
|
+
return Math.min(Math.max(value, minimum), maximum);
|
|
808
|
+
}
|
|
809
|
+
|
|
689
810
|
// src/_internal/chart/chart-interaction.svelte.ts
|
|
690
811
|
import * as $ from "svelte/internal/server";
|
|
691
812
|
class ChartInteraction {
|
|
@@ -823,6 +944,42 @@ function Area_chart($$renderer, $$props) {
|
|
|
823
944
|
const keyboardEnabled = $2.derived(() => model().targets.length > 0 && model().targets.length <= maximumInteractivePoints);
|
|
824
945
|
const hasDataTable = $2.derived(() => dataTableVisibility !== "hidden");
|
|
825
946
|
const guidanceId = $2.derived(() => !keyboardEnabled() && hasDataTable() && model().targets.length > 0 ? `${rootId()}-table-guidance` : undefined);
|
|
947
|
+
const focusedTarget = $2.derived(() => {
|
|
948
|
+
const currentTarget = interaction.focusedTarget;
|
|
949
|
+
if (!currentTarget)
|
|
950
|
+
return;
|
|
951
|
+
return model().targets.find((target) => target.id === currentTarget.id);
|
|
952
|
+
});
|
|
953
|
+
let keyboardFocusModality = false;
|
|
954
|
+
let focusVisibleTargetId = undefined;
|
|
955
|
+
const focusRingTarget = $2.derived(() => keyboardFocusModality && focusedTarget() && focusVisibleTargetId === focusedTarget().id ? focusedTarget() : undefined);
|
|
956
|
+
const pointFocusRing = $2.derived(() => focusRingTarget() ? createPointFocusRingGeometry({
|
|
957
|
+
target: focusRingTarget(),
|
|
958
|
+
plotWidth: model().geometry.plotWidth,
|
|
959
|
+
plotHeight: model().geometry.plotHeight,
|
|
960
|
+
strokePadding: DEFAULT_CHART_FOCUS_RING_STROKE_PADDING
|
|
961
|
+
}) : null);
|
|
962
|
+
function rememberKeyboardFocusModality(event) {
|
|
963
|
+
if (event.key === "Tab" || event.key === "Home" || event.key === "End" || event.key.startsWith("Arrow")) {
|
|
964
|
+
keyboardFocusModality = true;
|
|
965
|
+
}
|
|
966
|
+
}
|
|
967
|
+
function clearKeyboardFocusModality() {
|
|
968
|
+
keyboardFocusModality = false;
|
|
969
|
+
focusVisibleTargetId = undefined;
|
|
970
|
+
}
|
|
971
|
+
function handleTargetFocus(target) {
|
|
972
|
+
interaction.focusedTarget = target;
|
|
973
|
+
focusVisibleTargetId = keyboardFocusModality ? target.id : undefined;
|
|
974
|
+
}
|
|
975
|
+
function handleTargetBlur() {
|
|
976
|
+
interaction.focusedTarget = undefined;
|
|
977
|
+
focusVisibleTargetId = undefined;
|
|
978
|
+
}
|
|
979
|
+
function handleTargetKeydown(event) {
|
|
980
|
+
rememberKeyboardFocusModality(event);
|
|
981
|
+
interaction.activateByKeyboard(event, rootElement, model().targets, keyboardEnabled());
|
|
982
|
+
}
|
|
826
983
|
$$renderer2.push(`<figure${$2.attributes({
|
|
827
984
|
...rest,
|
|
828
985
|
id: rootId(),
|
|
@@ -927,7 +1084,7 @@ function Area_chart($$renderer, $$props) {
|
|
|
927
1084
|
const each_array_4 = $2.ensure_array_like(model().targets);
|
|
928
1085
|
for (let $$index_4 = 0, $$length = each_array_4.length;$$index_4 < $$length; $$index_4++) {
|
|
929
1086
|
let target = each_array_4[$$index_4];
|
|
930
|
-
$$renderer2.push(`<circle class="cinder-area-chart__focus-target"${$2.attr("cx", target.x)}${$2.attr("cy", target.y)} r="8" tabindex="0" role="button"${$2.attr("data-cinder-target-id", target.id)}${$2.attr("aria-label", `${target.seriesLabel}, ${target.xLabel}, ${target.valueLabel}`)}${$2.attr("aria-describedby", interaction.activeTarget?.id === target.id ? `${rootId()}-tooltip` : undefined)}></circle>`);
|
|
1087
|
+
$$renderer2.push(`<circle class="cinder-area-chart__focus-target"${$2.attr("cx", target.x)}${$2.attr("cy", target.y)} r="8" tabindex="0" role="button"${$2.attr("data-cinder-target-id", target.id)}${$2.attr("data-cinder-series-id", target.seriesId)}${$2.attr("data-cinder-focus-ring-active", pointFocusRing() && focusRingTarget()?.id === target.id ? "true" : undefined)}${$2.attr("aria-label", `${target.seriesLabel}, ${target.xLabel}, ${target.valueLabel}`)}${$2.attr("aria-describedby", interaction.activeTarget?.id === target.id ? `${rootId()}-tooltip` : undefined)}></circle>`);
|
|
931
1088
|
}
|
|
932
1089
|
$$renderer2.push(`<!--]-->`);
|
|
933
1090
|
} else {
|
|
@@ -937,6 +1094,28 @@ function Area_chart($$renderer, $$props) {
|
|
|
937
1094
|
} else {
|
|
938
1095
|
$$renderer2.push("<!--[-1-->");
|
|
939
1096
|
}
|
|
1097
|
+
$$renderer2.push(`<!--]-->`);
|
|
1098
|
+
if (pointFocusRing()) {
|
|
1099
|
+
$$renderer2.push("<!--[0-->");
|
|
1100
|
+
$$renderer2.push(`<g class="cinder-area-chart__focus-ring-layer" aria-hidden="true">`);
|
|
1101
|
+
if (pointFocusRing().kind === "point") {
|
|
1102
|
+
$$renderer2.push("<!--[0-->");
|
|
1103
|
+
$$renderer2.push(`<circle class="cinder-area-chart__focus-ring-halo"${$2.attr("cx", pointFocusRing().cx)}${$2.attr("cy", pointFocusRing().cy)}${$2.attr("r", pointFocusRing().radius)}></circle><circle class="cinder-area-chart__focus-ring"${$2.attr("cx", pointFocusRing().cx)}${$2.attr("cy", pointFocusRing().cy)}${$2.attr("r", pointFocusRing().radius)}></circle>`);
|
|
1104
|
+
if (pointFocusRing().connector && pointFocusRing().dot) {
|
|
1105
|
+
$$renderer2.push("<!--[0-->");
|
|
1106
|
+
$$renderer2.push(`<path class="cinder-area-chart__focus-ring-connector cinder-area-chart__focus-ring-halo"${$2.attr("d", `M ${pointFocusRing().connector.x1} ${pointFocusRing().connector.y1} L ${pointFocusRing().connector.x2} ${pointFocusRing().connector.y2}`)}></path><path class="cinder-area-chart__focus-ring-connector cinder-area-chart__focus-ring"${$2.attr("d", `M ${pointFocusRing().connector.x1} ${pointFocusRing().connector.y1} L ${pointFocusRing().connector.x2} ${pointFocusRing().connector.y2}`)}></path><circle class="cinder-area-chart__focus-ring-dot cinder-area-chart__focus-ring-halo"${$2.attr("cx", pointFocusRing().dot.cx)}${$2.attr("cy", pointFocusRing().dot.cy)}${$2.attr("r", pointFocusRing().dot.radius)}></circle><circle class="cinder-area-chart__focus-ring-dot cinder-area-chart__focus-ring"${$2.attr("cx", pointFocusRing().dot.cx)}${$2.attr("cy", pointFocusRing().dot.cy)}${$2.attr("r", pointFocusRing().dot.radius)}></circle>`);
|
|
1107
|
+
} else {
|
|
1108
|
+
$$renderer2.push("<!--[-1-->");
|
|
1109
|
+
}
|
|
1110
|
+
$$renderer2.push(`<!--]-->`);
|
|
1111
|
+
} else {
|
|
1112
|
+
$$renderer2.push("<!--[-1-->");
|
|
1113
|
+
$$renderer2.push(`<rect class="cinder-area-chart__focus-ring-halo"${$2.attr("x", pointFocusRing().x)}${$2.attr("y", pointFocusRing().y)}${$2.attr("width", pointFocusRing().width)}${$2.attr("height", pointFocusRing().height)}${$2.attr("rx", pointFocusRing().radius)}></rect><rect class="cinder-area-chart__focus-ring"${$2.attr("x", pointFocusRing().x)}${$2.attr("y", pointFocusRing().y)}${$2.attr("width", pointFocusRing().width)}${$2.attr("height", pointFocusRing().height)}${$2.attr("rx", pointFocusRing().radius)}></rect>`);
|
|
1114
|
+
}
|
|
1115
|
+
$$renderer2.push(`<!--]--></g>`);
|
|
1116
|
+
} else {
|
|
1117
|
+
$$renderer2.push("<!--[-1-->");
|
|
1118
|
+
}
|
|
940
1119
|
$$renderer2.push(`<!--]--></g></svg> `);
|
|
941
1120
|
if (interaction.activeTarget) {
|
|
942
1121
|
$$renderer2.push("<!--[0-->");
|
|
@@ -992,4 +1171,4 @@ export {
|
|
|
992
1171
|
Area_chart as AreaChart
|
|
993
1172
|
};
|
|
994
1173
|
|
|
995
|
-
//# debugId=
|
|
1174
|
+
//# debugId=E7297D751F5AECD664756E2164756E21
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
|
|
40
40
|
.cinder-avatar-group__trigger:focus-visible {
|
|
41
41
|
outline: none;
|
|
42
|
-
box-shadow: 0 0 0 var(--cinder-ring-offset
|
|
42
|
+
box-shadow: 0 0 0 var(--cinder-ring-offset, 1px) var(--cinder-ring-offset-color), 0 0 0 calc(var(--cinder-ring-offset, 1px) + var(--cinder-ring-width)) var(--cinder-ring-color);
|
|
43
43
|
}
|
|
44
44
|
|
|
45
45
|
.cinder-avatar-group__overflow {
|
|
@@ -48,6 +48,11 @@ var schema = {
|
|
|
48
48
|
description: "Size of the badge.",
|
|
49
49
|
default: "md"
|
|
50
50
|
},
|
|
51
|
+
mono: {
|
|
52
|
+
type: "boolean",
|
|
53
|
+
description: "Render the badge label in a monospace font. Useful for version strings, error codes, or other technical labels.",
|
|
54
|
+
default: false
|
|
55
|
+
},
|
|
51
56
|
class: {
|
|
52
57
|
type: "string",
|
|
53
58
|
description: "Custom class merged with `.cinder-badge`."
|
|
@@ -60,4 +65,4 @@ export {
|
|
|
60
65
|
badge_schema_default as default
|
|
61
66
|
};
|
|
62
67
|
|
|
63
|
-
//# debugId=
|
|
68
|
+
//# debugId=6425DE8D416AB0F664756E2164756E21
|
|
@@ -70,4 +70,8 @@
|
|
|
70
70
|
color: var(--cinder-accent-text);
|
|
71
71
|
border-color: color-mix(in oklch, var(--cinder-accent), transparent 60%);
|
|
72
72
|
}
|
|
73
|
+
|
|
74
|
+
.cinder-badge[data-cinder-mono] {
|
|
75
|
+
font-family: var(--cinder-font-mono, ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace);
|
|
76
|
+
}
|
|
73
77
|
}
|
|
@@ -47,6 +47,7 @@ function Badge($$renderer, $$props) {
|
|
|
47
47
|
let {
|
|
48
48
|
variant = "neutral",
|
|
49
49
|
size = "md",
|
|
50
|
+
mono = false,
|
|
50
51
|
class: customClassName,
|
|
51
52
|
children,
|
|
52
53
|
$$slots,
|
|
@@ -57,6 +58,7 @@ function Badge($$renderer, $$props) {
|
|
|
57
58
|
class: $.clsx(classNames("cinder-badge", customClassName)),
|
|
58
59
|
"data-cinder-variant": variant,
|
|
59
60
|
"data-cinder-size": size,
|
|
61
|
+
"data-cinder-mono": mono ? "" : undefined,
|
|
60
62
|
...rest
|
|
61
63
|
})}>`);
|
|
62
64
|
children?.($$renderer2);
|
|
@@ -71,4 +73,4 @@ export {
|
|
|
71
73
|
Badge
|
|
72
74
|
};
|
|
73
75
|
|
|
74
|
-
//# debugId=
|
|
76
|
+
//# debugId=176AC4B1E993469764756E2164756E21
|
|
@@ -73,10 +73,57 @@
|
|
|
73
73
|
pointer-events: none;
|
|
74
74
|
}
|
|
75
75
|
|
|
76
|
-
.cinder-bar-chart__focus-target:focus-visible {
|
|
77
|
-
|
|
76
|
+
.cinder-bar-chart__focus-target:focus-visible:not([data-cinder-focus-ring-active="true"]) {
|
|
77
|
+
fill: transparent;
|
|
78
|
+
stroke: var(--cinder-ring-color);
|
|
79
|
+
stroke-width: var(--cinder-ring-width);
|
|
80
|
+
vector-effect: non-scaling-stroke;
|
|
81
|
+
filter: none;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.cinder-bar-chart__focus-ring-layer {
|
|
85
|
+
pointer-events: none;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.cinder-bar-chart__focus-ring, .cinder-bar-chart__focus-ring-halo, .cinder-bar-chart__focus-ring-connector, .cinder-bar-chart__focus-ring-dot {
|
|
89
|
+
fill: none;
|
|
90
|
+
pointer-events: none;
|
|
91
|
+
vector-effect: non-scaling-stroke;
|
|
92
|
+
stroke-linecap: round;
|
|
93
|
+
stroke-linejoin: round;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.cinder-bar-chart__focus-ring {
|
|
97
|
+
stroke: var(--cinder-ring-color);
|
|
78
98
|
stroke-width: var(--cinder-ring-width);
|
|
79
|
-
filter:
|
|
99
|
+
filter: none;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.cinder-bar-chart__focus-ring-halo {
|
|
103
|
+
stroke: var(--cinder-ring-offset-color);
|
|
104
|
+
stroke-width: calc(var(--cinder-ring-width) + var(--cinder-ring-offset) + var(--cinder-ring-offset));
|
|
105
|
+
filter: none;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
@media (forced-colors: active) {
|
|
109
|
+
.cinder-bar-chart__focus-ring-halo {
|
|
110
|
+
display: none;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
.cinder-bar-chart__focus-ring, .cinder-bar-chart__focus-ring-connector, .cinder-bar-chart__focus-ring-dot {
|
|
114
|
+
fill: none;
|
|
115
|
+
stroke: ButtonText;
|
|
116
|
+
stroke-width: var(--cinder-ring-width);
|
|
117
|
+
filter: none;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.cinder-bar-chart__focus-target:focus-visible:not([data-cinder-focus-ring-active="true"]) {
|
|
121
|
+
fill: transparent;
|
|
122
|
+
stroke: ButtonText;
|
|
123
|
+
stroke-width: var(--cinder-ring-width);
|
|
124
|
+
vector-effect: non-scaling-stroke;
|
|
125
|
+
filter: none;
|
|
126
|
+
}
|
|
80
127
|
}
|
|
81
128
|
|
|
82
129
|
.cinder-bar-chart__tick-label {
|
|
@@ -361,6 +361,7 @@ function createBarModel(options) {
|
|
|
361
361
|
const categoryTicks = sortedCategories.map((category, index) => {
|
|
362
362
|
const categoryPosition = categoryScale(category.key) ?? 0;
|
|
363
363
|
return {
|
|
364
|
+
categoryKey: category.key,
|
|
364
365
|
label: formatXValue(category, orientation === "vertical" ? xAxis : yAxis, { index }),
|
|
365
366
|
x: orientation === "vertical" ? categoryPosition + categoryScale.bandwidth() / 2 : -8,
|
|
366
367
|
y: orientation === "vertical" ? geometry.plotHeight + 20 : categoryPosition + categoryScale.bandwidth() / 2
|
|
@@ -446,6 +447,7 @@ function createBarModel(options) {
|
|
|
446
447
|
});
|
|
447
448
|
if (rowValues.length > 0) {
|
|
448
449
|
tableRows.push({
|
|
450
|
+
categoryKey: category.key,
|
|
449
451
|
categoryLabel: formatXValue(category, orientation === "vertical" ? xAxis : yAxis, {
|
|
450
452
|
index: tableRows.length
|
|
451
453
|
}),
|
|
@@ -686,6 +688,125 @@ function formatPathNumber(value) {
|
|
|
686
688
|
return Number(value.toFixed(3)).toString();
|
|
687
689
|
}
|
|
688
690
|
|
|
691
|
+
// src/_internal/chart/chart-focus-ring.ts
|
|
692
|
+
var DEFAULT_CHART_FOCUS_RING_STROKE_PADDING = 8;
|
|
693
|
+
var DEFAULT_POINT_FOCUS_RING_RADIUS = 10;
|
|
694
|
+
var MINIMUM_FOCUS_RING_SIZE = 2;
|
|
695
|
+
var MINIMUM_BAR_FOCUS_RING_SIZE = 12;
|
|
696
|
+
var FOCUS_RING_DOT_RADIUS = 2.5;
|
|
697
|
+
function createPointFocusRingGeometry(options) {
|
|
698
|
+
const {
|
|
699
|
+
target,
|
|
700
|
+
plotWidth,
|
|
701
|
+
plotHeight,
|
|
702
|
+
strokePadding = DEFAULT_CHART_FOCUS_RING_STROKE_PADDING,
|
|
703
|
+
radius = DEFAULT_POINT_FOCUS_RING_RADIUS
|
|
704
|
+
} = options;
|
|
705
|
+
if (plotWidth <= 0 || plotHeight <= 0)
|
|
706
|
+
return null;
|
|
707
|
+
const drawableWidth = plotWidth - strokePadding * 2;
|
|
708
|
+
const drawableHeight = plotHeight - strokePadding * 2;
|
|
709
|
+
const largestDrawableRadius = Math.min(drawableWidth, drawableHeight) / 2;
|
|
710
|
+
if (largestDrawableRadius < MINIMUM_FOCUS_RING_SIZE || drawableWidth < FOCUS_RING_DOT_RADIUS * 2 || drawableHeight < FOCUS_RING_DOT_RADIUS * 2) {
|
|
711
|
+
return createPlotFrameFocusRingGeometry(plotWidth, plotHeight, strokePadding);
|
|
712
|
+
}
|
|
713
|
+
const resolvedRadius = Math.min(Math.max(radius, MINIMUM_FOCUS_RING_SIZE), largestDrawableRadius);
|
|
714
|
+
const minimumCenterX = strokePadding + resolvedRadius;
|
|
715
|
+
const maximumCenterX = plotWidth - strokePadding - resolvedRadius;
|
|
716
|
+
const minimumCenterY = strokePadding + resolvedRadius;
|
|
717
|
+
const maximumCenterY = plotHeight - strokePadding - resolvedRadius;
|
|
718
|
+
const cx = clamp(target.x, minimumCenterX, maximumCenterX);
|
|
719
|
+
const cy = clamp(target.y, minimumCenterY, maximumCenterY);
|
|
720
|
+
const dotInset = strokePadding + FOCUS_RING_DOT_RADIUS;
|
|
721
|
+
let targetX = clamp(target.x, dotInset, plotWidth - dotInset);
|
|
722
|
+
let targetY = clamp(target.y, dotInset, plotHeight - dotInset);
|
|
723
|
+
const initialOffsetX = targetX - cx;
|
|
724
|
+
const initialOffsetY = targetY - cy;
|
|
725
|
+
const initialOffsetDistance = Math.hypot(initialOffsetX, initialOffsetY);
|
|
726
|
+
if (initialOffsetDistance > resolvedRadius) {
|
|
727
|
+
const scale = resolvedRadius / initialOffsetDistance;
|
|
728
|
+
targetX = cx + initialOffsetX * scale;
|
|
729
|
+
targetY = cy + initialOffsetY * scale;
|
|
730
|
+
}
|
|
731
|
+
const offsetX = targetX - cx;
|
|
732
|
+
const offsetY = targetY - cy;
|
|
733
|
+
const offsetDistance = Math.hypot(offsetX, offsetY);
|
|
734
|
+
const geometry = {
|
|
735
|
+
kind: "point",
|
|
736
|
+
cx,
|
|
737
|
+
cy,
|
|
738
|
+
radius: resolvedRadius,
|
|
739
|
+
targetX,
|
|
740
|
+
targetY,
|
|
741
|
+
offsetX,
|
|
742
|
+
offsetY,
|
|
743
|
+
offsetDistance
|
|
744
|
+
};
|
|
745
|
+
if (offsetDistance <= 0)
|
|
746
|
+
return geometry;
|
|
747
|
+
return {
|
|
748
|
+
...geometry,
|
|
749
|
+
connector: {
|
|
750
|
+
x1: targetX,
|
|
751
|
+
y1: targetY,
|
|
752
|
+
x2: cx,
|
|
753
|
+
y2: cy
|
|
754
|
+
},
|
|
755
|
+
dot: {
|
|
756
|
+
cx: targetX,
|
|
757
|
+
cy: targetY,
|
|
758
|
+
radius: FOCUS_RING_DOT_RADIUS
|
|
759
|
+
}
|
|
760
|
+
};
|
|
761
|
+
}
|
|
762
|
+
function createBarFocusRingGeometry(options) {
|
|
763
|
+
const {
|
|
764
|
+
target,
|
|
765
|
+
plotWidth,
|
|
766
|
+
plotHeight,
|
|
767
|
+
strokePadding = DEFAULT_CHART_FOCUS_RING_STROKE_PADDING,
|
|
768
|
+
minimumWidth = MINIMUM_BAR_FOCUS_RING_SIZE,
|
|
769
|
+
minimumHeight = MINIMUM_BAR_FOCUS_RING_SIZE
|
|
770
|
+
} = options;
|
|
771
|
+
if (plotWidth <= 0 || plotHeight <= 0)
|
|
772
|
+
return null;
|
|
773
|
+
const requestedWidth = Math.max(target.width ?? 0, minimumWidth);
|
|
774
|
+
const requestedHeight = Math.max(target.height ?? 0, minimumHeight);
|
|
775
|
+
const drawableWidth = plotWidth - strokePadding * 2;
|
|
776
|
+
const drawableHeight = plotHeight - strokePadding * 2;
|
|
777
|
+
if (drawableWidth < MINIMUM_FOCUS_RING_SIZE || drawableHeight < MINIMUM_FOCUS_RING_SIZE) {
|
|
778
|
+
return createPlotFrameFocusRingGeometry(plotWidth, plotHeight, strokePadding);
|
|
779
|
+
}
|
|
780
|
+
const width = Math.min(requestedWidth, drawableWidth);
|
|
781
|
+
const height = Math.min(requestedHeight, drawableHeight);
|
|
782
|
+
const x = clamp(target.x - width / 2, strokePadding, plotWidth - width - strokePadding);
|
|
783
|
+
const y = clamp(target.y - height / 2, strokePadding, plotHeight - height - strokePadding);
|
|
784
|
+
return {
|
|
785
|
+
kind: "bar",
|
|
786
|
+
x,
|
|
787
|
+
y,
|
|
788
|
+
width,
|
|
789
|
+
height,
|
|
790
|
+
radius: Math.min(4, width / 2, height / 2)
|
|
791
|
+
};
|
|
792
|
+
}
|
|
793
|
+
function createPlotFrameFocusRingGeometry(plotWidth, plotHeight, strokePadding) {
|
|
794
|
+
const inset = Math.min(strokePadding, Math.max(0, plotWidth - MINIMUM_FOCUS_RING_SIZE) / 2, Math.max(0, plotHeight - MINIMUM_FOCUS_RING_SIZE) / 2);
|
|
795
|
+
return {
|
|
796
|
+
kind: "plot-frame",
|
|
797
|
+
x: inset,
|
|
798
|
+
y: inset,
|
|
799
|
+
width: Math.max(0, plotWidth - inset * 2),
|
|
800
|
+
height: Math.max(0, plotHeight - inset * 2),
|
|
801
|
+
radius: 0
|
|
802
|
+
};
|
|
803
|
+
}
|
|
804
|
+
function clamp(value, minimum, maximum) {
|
|
805
|
+
if (maximum < minimum)
|
|
806
|
+
return (minimum + maximum) / 2;
|
|
807
|
+
return Math.min(Math.max(value, minimum), maximum);
|
|
808
|
+
}
|
|
809
|
+
|
|
689
810
|
// src/_internal/chart/chart-interaction.svelte.ts
|
|
690
811
|
import * as $ from "svelte/internal/server";
|
|
691
812
|
class ChartInteraction {
|
|
@@ -828,6 +949,42 @@ function Bar_chart($$renderer, $$props) {
|
|
|
828
949
|
const keyboardEnabled = $2.derived(() => model().targets.length > 0 && model().targets.length <= maximumInteractivePoints);
|
|
829
950
|
const hasDataTable = $2.derived(() => dataTableVisibility !== "hidden");
|
|
830
951
|
const guidanceId = $2.derived(() => !keyboardEnabled() && hasDataTable() && model().targets.length > 0 ? `${rootId()}-table-guidance` : undefined);
|
|
952
|
+
const focusedTarget = $2.derived(() => {
|
|
953
|
+
const currentTarget = interaction.focusedTarget;
|
|
954
|
+
if (!currentTarget)
|
|
955
|
+
return;
|
|
956
|
+
return model().targets.find((target) => target.id === currentTarget.id);
|
|
957
|
+
});
|
|
958
|
+
let keyboardFocusModality = false;
|
|
959
|
+
let focusVisibleTargetId = undefined;
|
|
960
|
+
const focusRingTarget = $2.derived(() => keyboardFocusModality && focusedTarget() && focusVisibleTargetId === focusedTarget().id ? focusedTarget() : undefined);
|
|
961
|
+
const barFocusRing = $2.derived(() => focusRingTarget() ? createBarFocusRingGeometry({
|
|
962
|
+
target: focusRingTarget(),
|
|
963
|
+
plotWidth: model().geometry.plotWidth,
|
|
964
|
+
plotHeight: model().geometry.plotHeight,
|
|
965
|
+
strokePadding: DEFAULT_CHART_FOCUS_RING_STROKE_PADDING
|
|
966
|
+
}) : null);
|
|
967
|
+
function rememberKeyboardFocusModality(event) {
|
|
968
|
+
if (event.key === "Tab" || event.key === "Home" || event.key === "End" || event.key.startsWith("Arrow")) {
|
|
969
|
+
keyboardFocusModality = true;
|
|
970
|
+
}
|
|
971
|
+
}
|
|
972
|
+
function clearKeyboardFocusModality() {
|
|
973
|
+
keyboardFocusModality = false;
|
|
974
|
+
focusVisibleTargetId = undefined;
|
|
975
|
+
}
|
|
976
|
+
function handleTargetFocus(target) {
|
|
977
|
+
interaction.focusedTarget = target;
|
|
978
|
+
focusVisibleTargetId = keyboardFocusModality ? target.id : undefined;
|
|
979
|
+
}
|
|
980
|
+
function handleTargetBlur() {
|
|
981
|
+
interaction.focusedTarget = undefined;
|
|
982
|
+
focusVisibleTargetId = undefined;
|
|
983
|
+
}
|
|
984
|
+
function handleTargetKeydown(event) {
|
|
985
|
+
rememberKeyboardFocusModality(event);
|
|
986
|
+
interaction.activateByKeyboard(event, rootElement, model().targets, keyboardEnabled());
|
|
987
|
+
}
|
|
831
988
|
$$renderer2.push(`<figure${$2.attributes({
|
|
832
989
|
...rest,
|
|
833
990
|
id: rootId(),
|
|
@@ -933,7 +1090,7 @@ function Bar_chart($$renderer, $$props) {
|
|
|
933
1090
|
const each_array_4 = $2.ensure_array_like(model().targets);
|
|
934
1091
|
for (let $$index_4 = 0, $$length = each_array_4.length;$$index_4 < $$length; $$index_4++) {
|
|
935
1092
|
let target = each_array_4[$$index_4];
|
|
936
|
-
$$renderer2.push(`<rect class="cinder-bar-chart__focus-target"${$2.attr("x", (target.x ?? 0) - 6)}${$2.attr("y", (target.y ?? 0) - 6)} width="12" height="12" tabindex="0" role="button"${$2.attr("data-cinder-target-id", target.id)}${$2.attr("aria-label", `${target.seriesLabel}, ${target.xLabel}, ${target.valueLabel}`)}${$2.attr("aria-describedby", interaction.activeTarget?.id === target.id ? `${rootId()}-tooltip` : undefined)}></rect>`);
|
|
1093
|
+
$$renderer2.push(`<rect class="cinder-bar-chart__focus-target"${$2.attr("x", (target.x ?? 0) - 6)}${$2.attr("y", (target.y ?? 0) - 6)} width="12" height="12" tabindex="0" role="button"${$2.attr("data-cinder-target-id", target.id)}${$2.attr("data-cinder-series-id", target.seriesId)}${$2.attr("data-cinder-focus-ring-active", barFocusRing() && focusRingTarget()?.id === target.id ? "true" : undefined)}${$2.attr("aria-label", `${target.seriesLabel}, ${target.xLabel}, ${target.valueLabel}`)}${$2.attr("aria-describedby", interaction.activeTarget?.id === target.id ? `${rootId()}-tooltip` : undefined)}></rect>`);
|
|
937
1094
|
}
|
|
938
1095
|
$$renderer2.push(`<!--]-->`);
|
|
939
1096
|
} else {
|
|
@@ -943,6 +1100,13 @@ function Bar_chart($$renderer, $$props) {
|
|
|
943
1100
|
} else {
|
|
944
1101
|
$$renderer2.push("<!--[-1-->");
|
|
945
1102
|
}
|
|
1103
|
+
$$renderer2.push(`<!--]-->`);
|
|
1104
|
+
if (barFocusRing()) {
|
|
1105
|
+
$$renderer2.push("<!--[0-->");
|
|
1106
|
+
$$renderer2.push(`<g class="cinder-bar-chart__focus-ring-layer" aria-hidden="true"><rect class="cinder-bar-chart__focus-ring-halo"${$2.attr("x", barFocusRing().x)}${$2.attr("y", barFocusRing().y)}${$2.attr("width", barFocusRing().width)}${$2.attr("height", barFocusRing().height)}${$2.attr("rx", barFocusRing().radius)}></rect><rect class="cinder-bar-chart__focus-ring"${$2.attr("x", barFocusRing().x)}${$2.attr("y", barFocusRing().y)}${$2.attr("width", barFocusRing().width)}${$2.attr("height", barFocusRing().height)}${$2.attr("rx", barFocusRing().radius)}></rect></g>`);
|
|
1107
|
+
} else {
|
|
1108
|
+
$$renderer2.push("<!--[-1-->");
|
|
1109
|
+
}
|
|
946
1110
|
$$renderer2.push(`<!--]--></g></svg> `);
|
|
947
1111
|
if (interaction.activeTarget) {
|
|
948
1112
|
$$renderer2.push("<!--[0-->");
|
|
@@ -1004,4 +1168,4 @@ export {
|
|
|
1004
1168
|
Bar_chart as BarChart
|
|
1005
1169
|
};
|
|
1006
1170
|
|
|
1007
|
-
//# debugId=
|
|
1171
|
+
//# debugId=27A4544116DE7F0F64756E2164756E21
|
|
@@ -317,7 +317,7 @@
|
|
|
317
317
|
}
|
|
318
318
|
|
|
319
319
|
.cinder-button[data-cinder-variant="primary"]:active:not(:disabled):not([aria-disabled="true"]) {
|
|
320
|
-
background: var(--cinder-accent-active);
|
|
320
|
+
background: var(--cinder-accent-active-on-fill);
|
|
321
321
|
}
|
|
322
322
|
|
|
323
323
|
.cinder-button[data-cinder-variant="secondary"]:active:not(:disabled):not([aria-disabled="true"]) {
|
|
@@ -72,6 +72,9 @@ function Button($$renderer, $$props) {
|
|
|
72
72
|
"aria-busy": consumerAriaBusy,
|
|
73
73
|
"aria-label": ariaLabel,
|
|
74
74
|
"aria-labelledby": ariaLabelledBy,
|
|
75
|
+
"aria-expanded": ariaExpanded,
|
|
76
|
+
"aria-controls": ariaControls,
|
|
77
|
+
"aria-haspopup": ariaHaspopup,
|
|
75
78
|
$$slots,
|
|
76
79
|
$$events,
|
|
77
80
|
...rest
|
|
@@ -160,7 +163,10 @@ function Button($$renderer, $$props) {
|
|
|
160
163
|
"aria-disabled": resolvedAriaDisabled(),
|
|
161
164
|
"aria-busy": resolvedAriaBusy(),
|
|
162
165
|
"aria-label": resolvedAriaLabel(),
|
|
163
|
-
"aria-labelledby": resolvedAriaLabelledBy()
|
|
166
|
+
"aria-labelledby": resolvedAriaLabelledBy(),
|
|
167
|
+
"aria-expanded": ariaExpanded,
|
|
168
|
+
"aria-controls": ariaControls,
|
|
169
|
+
"aria-haspopup": ariaHaspopup
|
|
164
170
|
})}>`);
|
|
165
171
|
buttonContent($$renderer2);
|
|
166
172
|
$$renderer2.push(`<!----></a>`);
|
|
@@ -175,7 +181,10 @@ function Button($$renderer, $$props) {
|
|
|
175
181
|
"aria-disabled": resolvedAriaDisabled(),
|
|
176
182
|
"aria-busy": resolvedAriaBusy(),
|
|
177
183
|
"aria-label": resolvedAriaLabel(),
|
|
178
|
-
"aria-labelledby": resolvedAriaLabelledBy()
|
|
184
|
+
"aria-labelledby": resolvedAriaLabelledBy(),
|
|
185
|
+
"aria-expanded": ariaExpanded,
|
|
186
|
+
"aria-controls": ariaControls,
|
|
187
|
+
"aria-haspopup": ariaHaspopup
|
|
179
188
|
})}>`);
|
|
180
189
|
buttonContent($$renderer2);
|
|
181
190
|
$$renderer2.push(`<!----></button>`);
|
|
@@ -191,4 +200,4 @@ export {
|
|
|
191
200
|
Button
|
|
192
201
|
};
|
|
193
202
|
|
|
194
|
-
//# debugId=
|
|
203
|
+
//# debugId=D630EA8F1061F9B564756E2164756E21
|