@metamorph-labs/polymorph-vue-ui 1.0.16 → 1.0.18
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 +300 -0
- package/dist/ai/ArtifactPane.js.map +1 -1
- package/dist/ai/ArtifactPane.vue_vue_type_script_setup_true_lang.js +80 -72
- package/dist/ai/ArtifactPane.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/ai/PromptInput.js.map +1 -1
- package/dist/ai/PromptInput.vue_vue_type_script_setup_true_lang.js +105 -105
- package/dist/ai/PromptInput.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/ai/ReasoningDisclosure.js.map +1 -1
- package/dist/ai/ReasoningDisclosure.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/ai/ReasoningDisclosure.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/ai/ToolCall.js.map +1 -1
- package/dist/ai/ToolCall.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/ai/ToolCall.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/ai/artifact-pane.css +1 -1
- package/dist/ai/artifact-pane.module.js +1 -1
- package/dist/ai/attachment-chip.css +1 -1
- package/dist/ai/attachment-chip.module.js +1 -1
- package/dist/ai/attachment-chip.module.js.map +1 -1
- package/dist/ai/chat-thread.css +1 -1
- package/dist/ai/chat-thread.module.js +1 -1
- package/dist/ai/citation.css +1 -1
- package/dist/ai/citation.module.js +1 -1
- package/dist/ai/prompt-input.css +1 -1
- package/dist/ai/prompt-input.module.js +1 -1
- package/dist/ai/prompt-input.module.js.map +1 -1
- package/dist/ai/reasoning-disclosure.css +1 -1
- package/dist/ai/reasoning-disclosure.module.js +5 -5
- package/dist/ai/reasoning-disclosure.module.js.map +1 -1
- package/dist/ai/source-list.css +1 -1
- package/dist/ai/source-list.module.js +1 -1
- package/dist/ai/source-list.module.js.map +1 -1
- package/dist/ai/tool-call.css +1 -1
- package/dist/ai/tool-call.module.js +1 -1
- package/dist/archetypes/AppShell.js.map +1 -1
- package/dist/archetypes/AppShell.vue_vue_type_script_setup_true_lang.js +139 -88
- package/dist/archetypes/AppShell.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/archetypes/FormPage.js.map +1 -1
- package/dist/archetypes/FormPage.vue_vue_type_script_setup_true_lang.js +43 -21
- package/dist/archetypes/FormPage.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/archetypes/MasterDetailPage.js.map +1 -1
- package/dist/archetypes/MasterDetailPage.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/archetypes/MasterDetailPage.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/archetypes/app-shell.css +1 -1
- package/dist/archetypes/app-shell.module.js +9 -8
- package/dist/archetypes/app-shell.module.js.map +1 -1
- package/dist/archetypes/form-page.css +1 -1
- package/dist/archetypes/form-page.module.js +5 -3
- package/dist/archetypes/form-page.module.js.map +1 -1
- package/dist/archetypes/master-detail-page.css +1 -1
- package/dist/archetypes/master-detail-page.module.js +1 -1
- package/dist/archetypes/master-detail-page.module.js.map +1 -1
- package/dist/charts/area-chart.css +1 -1
- package/dist/charts/area-chart.module.js +1 -1
- package/dist/charts/bar-chart.css +1 -1
- package/dist/charts/bar-chart.module.js +1 -1
- package/dist/charts/donut-chart.css +1 -1
- package/dist/charts/donut-chart.module.js +1 -1
- package/dist/charts/frame/chart-frame.css +1 -1
- package/dist/charts/frame/chart-frame.module.js +1 -1
- package/dist/charts/frame/chart-legend.css +1 -1
- package/dist/charts/frame/chart-legend.module.js +1 -1
- package/dist/charts/frame/chart-legend.module.js.map +1 -1
- package/dist/charts/funnel-chart.css +1 -1
- package/dist/charts/funnel-chart.module.js +1 -1
- package/dist/charts/heatmap.css +1 -1
- package/dist/charts/heatmap.module.js +1 -1
- package/dist/charts/histogram.css +1 -1
- package/dist/charts/histogram.module.js +1 -1
- package/dist/charts/line-chart.css +1 -1
- package/dist/charts/line-chart.module.js +1 -1
- package/dist/charts/radar-chart.css +1 -1
- package/dist/charts/radar-chart.module.js +1 -1
- package/dist/charts/scatter-chart.css +1 -1
- package/dist/charts/scatter-chart.module.js +1 -1
- package/dist/charts/treemap.css +1 -1
- package/dist/charts/treemap.module.js +1 -1
- package/dist/controls/AvatarButton.js.map +1 -1
- package/dist/controls/AvatarButton.vue_vue_type_script_setup_true_lang.js +43 -35
- package/dist/controls/AvatarButton.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/Button.js.map +1 -1
- package/dist/controls/Button.vue_vue_type_script_setup_true_lang.js +74 -62
- package/dist/controls/Button.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/Calendar.js.map +1 -1
- package/dist/controls/Calendar.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/Calendar.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/Checkbox.js.map +1 -1
- package/dist/controls/Checkbox.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/Checkbox.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/ColorInput.js.map +1 -1
- package/dist/controls/ColorInput.vue_vue_type_script_setup_true_lang.js +95 -95
- package/dist/controls/ColorInput.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/Combobox.js.map +1 -1
- package/dist/controls/Combobox.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/Combobox.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/CopyButton.js.map +1 -1
- package/dist/controls/CopyButton.vue_vue_type_script_setup_true_lang.js +44 -30
- package/dist/controls/CopyButton.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/DatePicker.js.map +1 -1
- package/dist/controls/DatePicker.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/DatePicker.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/DateRangePicker.js.map +1 -1
- package/dist/controls/DateRangePicker.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/DateRangePicker.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/FileUpload.js.map +1 -1
- package/dist/controls/FileUpload.vue_vue_type_script_setup_true_lang.js +98 -89
- package/dist/controls/FileUpload.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/InlineEdit.js.map +1 -1
- package/dist/controls/InlineEdit.vue_vue_type_script_setup_true_lang.js +71 -63
- package/dist/controls/InlineEdit.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/MultiSelect.js.map +1 -1
- package/dist/controls/MultiSelect.vue_vue_type_script_setup_true_lang.js +188 -177
- package/dist/controls/MultiSelect.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/NumberInput.js.map +1 -1
- package/dist/controls/NumberInput.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/NumberInput.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/PhoneInput.js.map +1 -1
- package/dist/controls/PhoneInput.vue_vue_type_script_setup_true_lang.js +39 -39
- package/dist/controls/PhoneInput.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/RadioGroup.js.map +1 -1
- package/dist/controls/RadioGroup.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/RadioGroup.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/RichTextInput.js +7 -0
- package/dist/controls/RichTextInput.js.map +1 -0
- package/dist/controls/RichTextInput.vue_vue_type_script_setup_true_lang.js +1123 -0
- package/dist/controls/RichTextInput.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/controls/SegmentedControl.js.map +1 -1
- package/dist/controls/SegmentedControl.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/SegmentedControl.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/Select.js.map +1 -1
- package/dist/controls/Select.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/Select.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/Slider.js.map +1 -1
- package/dist/controls/Slider.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/Slider.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/SplitButton.js.map +1 -1
- package/dist/controls/SplitButton.vue_vue_type_script_setup_true_lang.js +102 -87
- package/dist/controls/SplitButton.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/SplitButtonSubmenu.js.map +1 -1
- package/dist/controls/SplitButtonSubmenu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/SplitButtonSubmenu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/Switch.js.map +1 -1
- package/dist/controls/Switch.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/controls/Switch.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/TagInput.js.map +1 -1
- package/dist/controls/TagInput.vue_vue_type_script_setup_true_lang.js +122 -111
- package/dist/controls/TagInput.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/TreeSelect.js.map +1 -1
- package/dist/controls/TreeSelect.vue_vue_type_script_setup_true_lang.js +56 -56
- package/dist/controls/TreeSelect.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/controls/avatar-button.css +1 -1
- package/dist/controls/avatar-button.module.js +5 -4
- package/dist/controls/avatar-button.module.js.map +1 -1
- package/dist/controls/button.css +1 -1
- package/dist/controls/button.module.js +4 -3
- package/dist/controls/button.module.js.map +1 -1
- package/dist/controls/calendar.css +1 -1
- package/dist/controls/calendar.module.js +3 -3
- package/dist/controls/calendar.module.js.map +1 -1
- package/dist/controls/checkbox-group.css +1 -1
- package/dist/controls/checkbox-group.module.js +1 -1
- package/dist/controls/checkbox.css +1 -1
- package/dist/controls/checkbox.module.js +2 -2
- package/dist/controls/checkbox.module.js.map +1 -1
- package/dist/controls/choice-card.css +1 -1
- package/dist/controls/choice-card.module.js +2 -2
- package/dist/controls/choice-card.module.js.map +1 -1
- package/dist/controls/color-input.css +1 -1
- package/dist/controls/color-input.module.js +1 -1
- package/dist/controls/color-input.module.js.map +1 -1
- package/dist/controls/combobox.css +1 -1
- package/dist/controls/combobox.module.js +5 -5
- package/dist/controls/combobox.module.js.map +1 -1
- package/dist/controls/copy-button.css +1 -1
- package/dist/controls/copy-button.module.js +8 -7
- package/dist/controls/copy-button.module.js.map +1 -1
- package/dist/controls/date-picker.css +1 -1
- package/dist/controls/date-picker.module.js +1 -1
- package/dist/controls/date-range-picker.css +1 -1
- package/dist/controls/date-range-picker.module.js +6 -6
- package/dist/controls/date-range-picker.module.js.map +1 -1
- package/dist/controls/duration-input.css +1 -1
- package/dist/controls/duration-input.module.js +1 -1
- package/dist/controls/file-upload.css +1 -1
- package/dist/controls/file-upload.module.js +1 -1
- package/dist/controls/file-upload.module.js.map +1 -1
- package/dist/controls/input.css +1 -1
- package/dist/controls/input.module.js +2 -2
- package/dist/controls/input.module.js.map +1 -1
- package/dist/controls/link.css +1 -1
- package/dist/controls/link.module.js +1 -1
- package/dist/controls/link.module.js.map +1 -1
- package/dist/controls/month-input.css +1 -1
- package/dist/controls/month-input.module.js +1 -1
- package/dist/controls/multi-select.css +1 -1
- package/dist/controls/multi-select.module.js +5 -5
- package/dist/controls/multi-select.module.js.map +1 -1
- package/dist/controls/number-input.css +1 -1
- package/dist/controls/number-input.module.js +1 -1
- package/dist/controls/number-input.module.js.map +1 -1
- package/dist/controls/otp-input.css +1 -1
- package/dist/controls/otp-input.module.js +2 -2
- package/dist/controls/otp-input.module.js.map +1 -1
- package/dist/controls/password-input.css +1 -1
- package/dist/controls/password-input.module.js +2 -2
- package/dist/controls/password-input.module.js.map +1 -1
- package/dist/controls/provider-button.css +1 -1
- package/dist/controls/provider-button.module.js +1 -1
- package/dist/controls/radio-group.css +1 -1
- package/dist/controls/radio-group.module.js +2 -2
- package/dist/controls/radio-group.module.js.map +1 -1
- package/dist/controls/rating.css +1 -1
- package/dist/controls/rating.module.js +1 -1
- package/dist/controls/rich-text-input.css +1 -0
- package/dist/controls/rich-text-input.module.js +47 -0
- package/dist/controls/rich-text-input.module.js.map +1 -0
- package/dist/controls/segmented-control.css +1 -1
- package/dist/controls/segmented-control.module.js +1 -1
- package/dist/controls/select.css +1 -1
- package/dist/controls/select.module.js +3 -3
- package/dist/controls/select.module.js.map +1 -1
- package/dist/controls/selection-bar.css +1 -0
- package/dist/controls/selection-bar.module.js +11 -0
- package/dist/controls/selection-bar.module.js.map +1 -0
- package/dist/controls/slider.css +1 -1
- package/dist/controls/slider.module.js +1 -1
- package/dist/controls/slider.module.js.map +1 -1
- package/dist/controls/split-button.css +1 -1
- package/dist/controls/split-button.module.js +20 -19
- package/dist/controls/split-button.module.js.map +1 -1
- package/dist/controls/switch.css +1 -1
- package/dist/controls/switch.module.js +1 -1
- package/dist/controls/switch.module.js.map +1 -1
- package/dist/controls/tag-input.css +1 -1
- package/dist/controls/tag-input.module.js +1 -1
- package/dist/controls/textarea.css +1 -1
- package/dist/controls/textarea.module.js +1 -1
- package/dist/controls/time-input.css +1 -1
- package/dist/controls/time-input.module.js +1 -1
- package/dist/controls/tree-select.css +1 -1
- package/dist/controls/tree-select.module.js +1 -1
- package/dist/index.js +41 -39
- package/dist/index.js.map +1 -1
- package/dist/layout/split-pane.css +1 -1
- package/dist/layout/split-pane.module.js +1 -1
- package/dist/layout/split-pane.module.js.map +1 -1
- package/dist/node/ai/ArtifactPane.js.map +1 -1
- package/dist/node/ai/ArtifactPane.vue_vue_type_script_setup_true_lang.js +80 -72
- package/dist/node/ai/ArtifactPane.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/ai/PromptInput.js.map +1 -1
- package/dist/node/ai/PromptInput.vue_vue_type_script_setup_true_lang.js +105 -105
- package/dist/node/ai/PromptInput.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/ai/ReasoningDisclosure.js.map +1 -1
- package/dist/node/ai/ReasoningDisclosure.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/ai/ReasoningDisclosure.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/ai/ToolCall.js.map +1 -1
- package/dist/node/ai/ToolCall.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/ai/ToolCall.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/ai/artifact-pane.module.js +1 -1
- package/dist/node/ai/attachment-chip.module.js +1 -1
- package/dist/node/ai/attachment-chip.module.js.map +1 -1
- package/dist/node/ai/chat-thread.module.js +1 -1
- package/dist/node/ai/citation.module.js +1 -1
- package/dist/node/ai/prompt-input.module.js +1 -1
- package/dist/node/ai/prompt-input.module.js.map +1 -1
- package/dist/node/ai/reasoning-disclosure.module.js +5 -5
- package/dist/node/ai/reasoning-disclosure.module.js.map +1 -1
- package/dist/node/ai/source-list.module.js +1 -1
- package/dist/node/ai/source-list.module.js.map +1 -1
- package/dist/node/ai/tool-call.module.js +1 -1
- package/dist/node/archetypes/AppShell.js.map +1 -1
- package/dist/node/archetypes/AppShell.vue_vue_type_script_setup_true_lang.js +139 -88
- package/dist/node/archetypes/AppShell.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/archetypes/FormPage.js.map +1 -1
- package/dist/node/archetypes/FormPage.vue_vue_type_script_setup_true_lang.js +43 -21
- package/dist/node/archetypes/FormPage.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/archetypes/MasterDetailPage.js.map +1 -1
- package/dist/node/archetypes/MasterDetailPage.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/archetypes/MasterDetailPage.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/archetypes/app-shell.module.js +9 -8
- package/dist/node/archetypes/app-shell.module.js.map +1 -1
- package/dist/node/archetypes/form-page.module.js +5 -3
- package/dist/node/archetypes/form-page.module.js.map +1 -1
- package/dist/node/archetypes/master-detail-page.module.js +1 -1
- package/dist/node/archetypes/master-detail-page.module.js.map +1 -1
- package/dist/node/charts/area-chart.module.js +1 -1
- package/dist/node/charts/bar-chart.module.js +1 -1
- package/dist/node/charts/donut-chart.module.js +1 -1
- package/dist/node/charts/frame/chart-frame.module.js +1 -1
- package/dist/node/charts/frame/chart-legend.module.js +1 -1
- package/dist/node/charts/frame/chart-legend.module.js.map +1 -1
- package/dist/node/charts/funnel-chart.module.js +1 -1
- package/dist/node/charts/heatmap.module.js +1 -1
- package/dist/node/charts/histogram.module.js +1 -1
- package/dist/node/charts/line-chart.module.js +1 -1
- package/dist/node/charts/radar-chart.module.js +1 -1
- package/dist/node/charts/scatter-chart.module.js +1 -1
- package/dist/node/charts/treemap.module.js +1 -1
- package/dist/node/controls/AvatarButton.js.map +1 -1
- package/dist/node/controls/AvatarButton.vue_vue_type_script_setup_true_lang.js +43 -35
- package/dist/node/controls/AvatarButton.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/Button.js.map +1 -1
- package/dist/node/controls/Button.vue_vue_type_script_setup_true_lang.js +74 -62
- package/dist/node/controls/Button.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/Calendar.js.map +1 -1
- package/dist/node/controls/Calendar.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/Calendar.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/Checkbox.js.map +1 -1
- package/dist/node/controls/Checkbox.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/Checkbox.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/ColorInput.js.map +1 -1
- package/dist/node/controls/ColorInput.vue_vue_type_script_setup_true_lang.js +95 -95
- package/dist/node/controls/ColorInput.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/Combobox.js.map +1 -1
- package/dist/node/controls/Combobox.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/Combobox.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/CopyButton.js.map +1 -1
- package/dist/node/controls/CopyButton.vue_vue_type_script_setup_true_lang.js +44 -30
- package/dist/node/controls/CopyButton.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/DatePicker.js.map +1 -1
- package/dist/node/controls/DatePicker.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/DatePicker.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/DateRangePicker.js.map +1 -1
- package/dist/node/controls/DateRangePicker.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/DateRangePicker.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/FileUpload.js.map +1 -1
- package/dist/node/controls/FileUpload.vue_vue_type_script_setup_true_lang.js +98 -89
- package/dist/node/controls/FileUpload.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/InlineEdit.js.map +1 -1
- package/dist/node/controls/InlineEdit.vue_vue_type_script_setup_true_lang.js +71 -63
- package/dist/node/controls/InlineEdit.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/MultiSelect.js.map +1 -1
- package/dist/node/controls/MultiSelect.vue_vue_type_script_setup_true_lang.js +188 -177
- package/dist/node/controls/MultiSelect.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/NumberInput.js.map +1 -1
- package/dist/node/controls/NumberInput.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/NumberInput.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/PhoneInput.js.map +1 -1
- package/dist/node/controls/PhoneInput.vue_vue_type_script_setup_true_lang.js +39 -39
- package/dist/node/controls/PhoneInput.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/RadioGroup.js.map +1 -1
- package/dist/node/controls/RadioGroup.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/RadioGroup.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/RichTextInput.js +7 -0
- package/dist/node/controls/RichTextInput.js.map +1 -0
- package/dist/node/controls/RichTextInput.vue_vue_type_script_setup_true_lang.js +1123 -0
- package/dist/node/controls/RichTextInput.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/node/controls/SegmentedControl.js.map +1 -1
- package/dist/node/controls/SegmentedControl.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/SegmentedControl.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/Select.js.map +1 -1
- package/dist/node/controls/Select.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/Select.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/Slider.js.map +1 -1
- package/dist/node/controls/Slider.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/Slider.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/SplitButton.js.map +1 -1
- package/dist/node/controls/SplitButton.vue_vue_type_script_setup_true_lang.js +102 -87
- package/dist/node/controls/SplitButton.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/SplitButtonSubmenu.js.map +1 -1
- package/dist/node/controls/SplitButtonSubmenu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/SplitButtonSubmenu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/Switch.js.map +1 -1
- package/dist/node/controls/Switch.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/controls/Switch.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/TagInput.js.map +1 -1
- package/dist/node/controls/TagInput.vue_vue_type_script_setup_true_lang.js +122 -111
- package/dist/node/controls/TagInput.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/TreeSelect.js.map +1 -1
- package/dist/node/controls/TreeSelect.vue_vue_type_script_setup_true_lang.js +56 -56
- package/dist/node/controls/TreeSelect.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/controls/avatar-button.module.js +5 -4
- package/dist/node/controls/avatar-button.module.js.map +1 -1
- package/dist/node/controls/button.module.js +4 -3
- package/dist/node/controls/button.module.js.map +1 -1
- package/dist/node/controls/calendar.module.js +3 -3
- package/dist/node/controls/calendar.module.js.map +1 -1
- package/dist/node/controls/checkbox-group.module.js +1 -1
- package/dist/node/controls/checkbox.module.js +2 -2
- package/dist/node/controls/checkbox.module.js.map +1 -1
- package/dist/node/controls/choice-card.module.js +2 -2
- package/dist/node/controls/choice-card.module.js.map +1 -1
- package/dist/node/controls/color-input.module.js +1 -1
- package/dist/node/controls/color-input.module.js.map +1 -1
- package/dist/node/controls/combobox.module.js +5 -5
- package/dist/node/controls/combobox.module.js.map +1 -1
- package/dist/node/controls/copy-button.module.js +8 -7
- package/dist/node/controls/copy-button.module.js.map +1 -1
- package/dist/node/controls/date-picker.module.js +1 -1
- package/dist/node/controls/date-range-picker.module.js +6 -6
- package/dist/node/controls/date-range-picker.module.js.map +1 -1
- package/dist/node/controls/duration-input.module.js +1 -1
- package/dist/node/controls/file-upload.module.js +1 -1
- package/dist/node/controls/file-upload.module.js.map +1 -1
- package/dist/node/controls/input.module.js +2 -2
- package/dist/node/controls/input.module.js.map +1 -1
- package/dist/node/controls/link.module.js +1 -1
- package/dist/node/controls/link.module.js.map +1 -1
- package/dist/node/controls/month-input.module.js +1 -1
- package/dist/node/controls/multi-select.module.js +5 -5
- package/dist/node/controls/multi-select.module.js.map +1 -1
- package/dist/node/controls/number-input.module.js +1 -1
- package/dist/node/controls/number-input.module.js.map +1 -1
- package/dist/node/controls/otp-input.module.js +2 -2
- package/dist/node/controls/otp-input.module.js.map +1 -1
- package/dist/node/controls/password-input.module.js +2 -2
- package/dist/node/controls/password-input.module.js.map +1 -1
- package/dist/node/controls/provider-button.module.js +1 -1
- package/dist/node/controls/radio-group.module.js +2 -2
- package/dist/node/controls/radio-group.module.js.map +1 -1
- package/dist/node/controls/rating.module.js +1 -1
- package/dist/node/controls/rich-text-input.module.js +46 -0
- package/dist/node/controls/rich-text-input.module.js.map +1 -0
- package/dist/node/controls/segmented-control.module.js +1 -1
- package/dist/node/controls/select.module.js +3 -3
- package/dist/node/controls/select.module.js.map +1 -1
- package/dist/node/controls/selection-bar.module.js +10 -0
- package/dist/node/controls/selection-bar.module.js.map +1 -0
- package/dist/node/controls/slider.module.js +1 -1
- package/dist/node/controls/slider.module.js.map +1 -1
- package/dist/node/controls/split-button.module.js +20 -19
- package/dist/node/controls/split-button.module.js.map +1 -1
- package/dist/node/controls/switch.module.js +1 -1
- package/dist/node/controls/switch.module.js.map +1 -1
- package/dist/node/controls/tag-input.module.js +1 -1
- package/dist/node/controls/textarea.module.js +1 -1
- package/dist/node/controls/time-input.module.js +1 -1
- package/dist/node/controls/tree-select.module.js +1 -1
- package/dist/node/index.js +41 -39
- package/dist/node/index.js.map +1 -1
- package/dist/node/layout/split-pane.module.js +1 -1
- package/dist/node/layout/split-pane.module.js.map +1 -1
- package/dist/node/overlays/Command.js.map +1 -1
- package/dist/node/overlays/Command.vue_vue_type_script_setup_true_lang.js +50 -45
- package/dist/node/overlays/Command.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/CommandPanel.js.map +1 -1
- package/dist/node/overlays/CommandPanel.vue_vue_type_script_setup_true_lang.js +82 -82
- package/dist/node/overlays/CommandPanel.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/ContextMenu.js.map +1 -1
- package/dist/node/overlays/ContextMenu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/overlays/ContextMenu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/ContextMenuSubmenu.js.map +1 -1
- package/dist/node/overlays/ContextMenuSubmenu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/overlays/ContextMenuSubmenu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/Dialog.js.map +1 -1
- package/dist/node/overlays/Dialog.vue_vue_type_script_setup_true_lang.js +47 -43
- package/dist/node/overlays/Dialog.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/Drawer.js.map +1 -1
- package/dist/node/overlays/Drawer.vue_vue_type_script_setup_true_lang.js +58 -53
- package/dist/node/overlays/Drawer.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/Lightbox.js.map +1 -1
- package/dist/node/overlays/Lightbox.vue_vue_type_script_setup_true_lang.js +65 -61
- package/dist/node/overlays/Lightbox.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/Menu.js.map +1 -1
- package/dist/node/overlays/Menu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/overlays/Menu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/MenuSubmenu.js.map +1 -1
- package/dist/node/overlays/MenuSubmenu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/overlays/MenuSubmenu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/Menubar.js.map +1 -1
- package/dist/node/overlays/Menubar.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/overlays/Menubar.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/MenubarSubmenu.js.map +1 -1
- package/dist/node/overlays/MenubarSubmenu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/overlays/MenubarSubmenu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/Popover.js.map +1 -1
- package/dist/node/overlays/Popover.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/overlays/Popover.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/Tabs.js.map +1 -1
- package/dist/node/overlays/Tabs.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/node/overlays/Tabs.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/Toast.js.map +1 -1
- package/dist/node/overlays/Toast.vue_vue_type_script_setup_true_lang.js +27 -27
- package/dist/node/overlays/Toast.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/ToastCard.js.map +1 -1
- package/dist/node/overlays/ToastCard.vue_vue_type_script_setup_true_lang.js +74 -71
- package/dist/node/overlays/ToastCard.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/ToastViewport.js.map +1 -1
- package/dist/node/overlays/ToastViewport.vue_vue_type_script_setup_true_lang.js +70 -59
- package/dist/node/overlays/ToastViewport.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/Tooltip.js.map +1 -1
- package/dist/node/overlays/Tooltip.vue_vue_type_script_setup_true_lang.js +46 -26
- package/dist/node/overlays/Tooltip.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/Tour.js.map +1 -1
- package/dist/node/overlays/Tour.vue_vue_type_script_setup_true_lang.js +74 -69
- package/dist/node/overlays/Tour.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/overlays/context-menu.module.js +4 -4
- package/dist/node/overlays/context-menu.module.js.map +1 -1
- package/dist/node/overlays/dialog.module.js +1 -1
- package/dist/node/overlays/dialog.module.js.map +1 -1
- package/dist/node/overlays/drawer.module.js +1 -1
- package/dist/node/overlays/drawer.module.js.map +1 -1
- package/dist/node/overlays/lightbox.module.js +1 -1
- package/dist/node/overlays/menu.module.js +4 -4
- package/dist/node/overlays/menu.module.js.map +1 -1
- package/dist/node/overlays/menubar.module.js +1 -1
- package/dist/node/overlays/menubar.module.js.map +1 -1
- package/dist/node/overlays/popover.module.js +3 -3
- package/dist/node/overlays/popover.module.js.map +1 -1
- package/dist/node/overlays/sheet.module.js +1 -1
- package/dist/node/overlays/sheet.module.js.map +1 -1
- package/dist/node/overlays/tabs.module.js +4 -4
- package/dist/node/overlays/tabs.module.js.map +1 -1
- package/dist/node/overlays/toast.module.js +1 -1
- package/dist/node/overlays/toast.module.js.map +1 -1
- package/dist/node/overlays/tour.module.js +1 -1
- package/dist/node/overlays/tour.module.js.map +1 -1
- package/dist/node/structure/Accordion.js.map +1 -1
- package/dist/node/structure/Accordion.vue_vue_type_script_setup_true_lang.js +5 -1
- package/dist/node/structure/Accordion.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/structure/Alert.js.map +1 -1
- package/dist/node/structure/Alert.vue_vue_type_script_setup_true_lang.js +62 -54
- package/dist/node/structure/Alert.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/structure/Banner.js.map +1 -1
- package/dist/node/structure/Banner.vue_vue_type_script_setup_true_lang.js +42 -34
- package/dist/node/structure/Banner.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/structure/Carousel.js.map +1 -1
- package/dist/node/structure/Carousel.vue_vue_type_script_setup_true_lang.js +8 -8
- package/dist/node/structure/Carousel.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/structure/Collapsible.js.map +1 -1
- package/dist/node/structure/Collapsible.vue_vue_type_script_setup_true_lang.js +5 -1
- package/dist/node/structure/Collapsible.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/structure/CursorPagination.js.map +1 -1
- package/dist/node/structure/CursorPagination.vue_vue_type_script_setup_true_lang.js +140 -93
- package/dist/node/structure/CursorPagination.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/structure/DataTable.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/structure/Image.js.map +1 -1
- package/dist/node/structure/Image.vue_vue_type_script_setup_true_lang.js +30 -18
- package/dist/node/structure/Image.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/structure/Pagination.js.map +1 -1
- package/dist/node/structure/Pagination.vue_vue_type_script_setup_true_lang.js +154 -71
- package/dist/node/structure/Pagination.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/structure/RichTextContent.js +7 -0
- package/dist/node/structure/RichTextContent.js.map +1 -0
- package/dist/node/structure/RichTextContent.vue_vue_type_script_setup_true_lang.js +298 -0
- package/dist/node/structure/RichTextContent.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/node/structure/RichTextContentBlocks.js +7 -0
- package/dist/node/structure/RichTextContentBlocks.js.map +1 -0
- package/dist/node/structure/RichTextContentBlocks.vue_vue_type_script_setup_true_lang.js +94 -0
- package/dist/node/structure/RichTextContentBlocks.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/node/structure/RichTextContentInlines.js +7 -0
- package/dist/node/structure/RichTextContentInlines.js.map +1 -0
- package/dist/node/structure/RichTextContentInlines.vue_vue_type_script_setup_true_lang.js +69 -0
- package/dist/node/structure/RichTextContentInlines.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/node/structure/RichTextContentItem.js +7 -0
- package/dist/node/structure/RichTextContentItem.js.map +1 -0
- package/dist/node/structure/RichTextContentItem.vue_vue_type_script_setup_true_lang.js +94 -0
- package/dist/node/structure/RichTextContentItem.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/node/structure/ScrollArea.js.map +1 -1
- package/dist/node/structure/ScrollArea.vue_vue_type_script_setup_true_lang.js +30 -27
- package/dist/node/structure/ScrollArea.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/structure/Table.js.map +1 -1
- package/dist/node/structure/Table.vue_vue_type_script_setup_true_lang.js +71 -61
- package/dist/node/structure/Table.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/node/structure/accordion.module.js +5 -5
- package/dist/node/structure/accordion.module.js.map +1 -1
- package/dist/node/structure/breadcrumbs.module.js +1 -1
- package/dist/node/structure/breadcrumbs.module.js.map +1 -1
- package/dist/node/structure/card.module.js +1 -1
- package/dist/node/structure/card.module.js.map +1 -1
- package/dist/node/structure/carousel.module.js +1 -1
- package/dist/node/structure/carousel.module.js.map +1 -1
- package/dist/node/structure/code-block.module.js +2 -2
- package/dist/node/structure/code-block.module.js.map +1 -1
- package/dist/node/structure/collapsible.module.js +5 -5
- package/dist/node/structure/collapsible.module.js.map +1 -1
- package/dist/node/structure/cursor-pagination.module.js +6 -3
- package/dist/node/structure/cursor-pagination.module.js.map +1 -1
- package/dist/node/structure/data-table.module.js +1 -1
- package/dist/node/structure/error-summary.module.js +1 -1
- package/dist/node/structure/error-summary.module.js.map +1 -1
- package/dist/node/structure/json-tree.module.js +1 -1
- package/dist/node/structure/json-tree.module.js.map +1 -1
- package/dist/node/structure/list.module.js +1 -1
- package/dist/node/structure/list.module.js.map +1 -1
- package/dist/node/structure/log-view.module.js +1 -1
- package/dist/node/structure/pagination.module.js +7 -3
- package/dist/node/structure/pagination.module.js.map +1 -1
- package/dist/node/structure/rich-text-content.module.js +18 -0
- package/dist/node/structure/rich-text-content.module.js.map +1 -0
- package/dist/node/structure/section-nav.module.js +1 -1
- package/dist/node/structure/section-nav.module.js.map +1 -1
- package/dist/node/structure/stepper.module.js +2 -2
- package/dist/node/structure/stepper.module.js.map +1 -1
- package/dist/node/structure/table-of-contents.module.js +1 -1
- package/dist/node/structure/table-of-contents.module.js.map +1 -1
- package/dist/node/structure/table.module.js +1 -1
- package/dist/node/structure/table.module.js.map +1 -1
- package/dist/node/structure/tree.module.js +1 -1
- package/dist/node/structure/tree.module.js.map +1 -1
- package/dist/overlays/Command.js.map +1 -1
- package/dist/overlays/Command.vue_vue_type_script_setup_true_lang.js +50 -45
- package/dist/overlays/Command.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/CommandPanel.js.map +1 -1
- package/dist/overlays/CommandPanel.vue_vue_type_script_setup_true_lang.js +82 -82
- package/dist/overlays/CommandPanel.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/ContextMenu.js.map +1 -1
- package/dist/overlays/ContextMenu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/overlays/ContextMenu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/ContextMenuSubmenu.js.map +1 -1
- package/dist/overlays/ContextMenuSubmenu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/overlays/ContextMenuSubmenu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/Dialog.js.map +1 -1
- package/dist/overlays/Dialog.vue_vue_type_script_setup_true_lang.js +47 -43
- package/dist/overlays/Dialog.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/Drawer.js.map +1 -1
- package/dist/overlays/Drawer.vue_vue_type_script_setup_true_lang.js +58 -53
- package/dist/overlays/Drawer.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/Lightbox.js.map +1 -1
- package/dist/overlays/Lightbox.vue_vue_type_script_setup_true_lang.js +65 -61
- package/dist/overlays/Lightbox.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/Menu.js.map +1 -1
- package/dist/overlays/Menu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/overlays/Menu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/MenuSubmenu.js.map +1 -1
- package/dist/overlays/MenuSubmenu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/overlays/MenuSubmenu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/Menubar.js.map +1 -1
- package/dist/overlays/Menubar.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/overlays/Menubar.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/MenubarSubmenu.js.map +1 -1
- package/dist/overlays/MenubarSubmenu.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/overlays/MenubarSubmenu.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/Popover.js.map +1 -1
- package/dist/overlays/Popover.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/overlays/Popover.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/Tabs.js.map +1 -1
- package/dist/overlays/Tabs.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/overlays/Tabs.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/Toast.js.map +1 -1
- package/dist/overlays/Toast.vue_vue_type_script_setup_true_lang.js +27 -27
- package/dist/overlays/Toast.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/ToastCard.js.map +1 -1
- package/dist/overlays/ToastCard.vue_vue_type_script_setup_true_lang.js +74 -71
- package/dist/overlays/ToastCard.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/ToastViewport.js.map +1 -1
- package/dist/overlays/ToastViewport.vue_vue_type_script_setup_true_lang.js +70 -59
- package/dist/overlays/ToastViewport.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/Tooltip.js.map +1 -1
- package/dist/overlays/Tooltip.vue_vue_type_script_setup_true_lang.js +46 -26
- package/dist/overlays/Tooltip.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/Tour.js.map +1 -1
- package/dist/overlays/Tour.vue_vue_type_script_setup_true_lang.js +74 -69
- package/dist/overlays/Tour.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/overlays/context-menu.css +1 -1
- package/dist/overlays/context-menu.module.js +4 -4
- package/dist/overlays/context-menu.module.js.map +1 -1
- package/dist/overlays/dialog.css +1 -1
- package/dist/overlays/dialog.module.js +1 -1
- package/dist/overlays/dialog.module.js.map +1 -1
- package/dist/overlays/drawer.css +1 -1
- package/dist/overlays/drawer.module.js +1 -1
- package/dist/overlays/drawer.module.js.map +1 -1
- package/dist/overlays/lightbox.css +1 -1
- package/dist/overlays/lightbox.module.js +1 -1
- package/dist/overlays/menu.css +1 -1
- package/dist/overlays/menu.module.js +4 -4
- package/dist/overlays/menu.module.js.map +1 -1
- package/dist/overlays/menubar.css +1 -1
- package/dist/overlays/menubar.module.js +1 -1
- package/dist/overlays/menubar.module.js.map +1 -1
- package/dist/overlays/popover.css +1 -1
- package/dist/overlays/popover.module.js +3 -3
- package/dist/overlays/popover.module.js.map +1 -1
- package/dist/overlays/sheet.css +1 -1
- package/dist/overlays/sheet.module.js +1 -1
- package/dist/overlays/sheet.module.js.map +1 -1
- package/dist/overlays/tabs.css +1 -1
- package/dist/overlays/tabs.module.js +4 -4
- package/dist/overlays/tabs.module.js.map +1 -1
- package/dist/overlays/toast.css +1 -1
- package/dist/overlays/toast.module.js +1 -1
- package/dist/overlays/toast.module.js.map +1 -1
- package/dist/overlays/tour.css +1 -1
- package/dist/overlays/tour.module.js +1 -1
- package/dist/overlays/tour.module.js.map +1 -1
- package/dist/structure/Accordion.js.map +1 -1
- package/dist/structure/Accordion.vue_vue_type_script_setup_true_lang.js +5 -1
- package/dist/structure/Accordion.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/structure/Alert.js.map +1 -1
- package/dist/structure/Alert.vue_vue_type_script_setup_true_lang.js +62 -54
- package/dist/structure/Alert.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/structure/Banner.js.map +1 -1
- package/dist/structure/Banner.vue_vue_type_script_setup_true_lang.js +42 -34
- package/dist/structure/Banner.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/structure/Carousel.js.map +1 -1
- package/dist/structure/Carousel.vue_vue_type_script_setup_true_lang.js +8 -8
- package/dist/structure/Carousel.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/structure/Collapsible.js.map +1 -1
- package/dist/structure/Collapsible.vue_vue_type_script_setup_true_lang.js +5 -1
- package/dist/structure/Collapsible.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/structure/CursorPagination.js.map +1 -1
- package/dist/structure/CursorPagination.vue_vue_type_script_setup_true_lang.js +140 -93
- package/dist/structure/CursorPagination.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/structure/DataTable.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/structure/Image.js.map +1 -1
- package/dist/structure/Image.vue_vue_type_script_setup_true_lang.js +30 -18
- package/dist/structure/Image.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/structure/Pagination.js.map +1 -1
- package/dist/structure/Pagination.vue_vue_type_script_setup_true_lang.js +154 -71
- package/dist/structure/Pagination.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/structure/RichTextContent.js +7 -0
- package/dist/structure/RichTextContent.js.map +1 -0
- package/dist/structure/RichTextContent.vue_vue_type_script_setup_true_lang.js +298 -0
- package/dist/structure/RichTextContent.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/structure/RichTextContentBlocks.js +7 -0
- package/dist/structure/RichTextContentBlocks.js.map +1 -0
- package/dist/structure/RichTextContentBlocks.vue_vue_type_script_setup_true_lang.js +94 -0
- package/dist/structure/RichTextContentBlocks.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/structure/RichTextContentInlines.js +7 -0
- package/dist/structure/RichTextContentInlines.js.map +1 -0
- package/dist/structure/RichTextContentInlines.vue_vue_type_script_setup_true_lang.js +69 -0
- package/dist/structure/RichTextContentInlines.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/structure/RichTextContentItem.js +7 -0
- package/dist/structure/RichTextContentItem.js.map +1 -0
- package/dist/structure/RichTextContentItem.vue_vue_type_script_setup_true_lang.js +94 -0
- package/dist/structure/RichTextContentItem.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/structure/ScrollArea.js.map +1 -1
- package/dist/structure/ScrollArea.vue_vue_type_script_setup_true_lang.js +30 -27
- package/dist/structure/ScrollArea.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/structure/Table.js.map +1 -1
- package/dist/structure/Table.vue_vue_type_script_setup_true_lang.js +71 -61
- package/dist/structure/Table.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/structure/accordion.css +1 -1
- package/dist/structure/accordion.module.js +5 -5
- package/dist/structure/accordion.module.js.map +1 -1
- package/dist/structure/breadcrumbs.css +1 -1
- package/dist/structure/breadcrumbs.module.js +1 -1
- package/dist/structure/breadcrumbs.module.js.map +1 -1
- package/dist/structure/card.css +1 -1
- package/dist/structure/card.module.js +1 -1
- package/dist/structure/card.module.js.map +1 -1
- package/dist/structure/carousel.css +1 -1
- package/dist/structure/carousel.module.js +1 -1
- package/dist/structure/carousel.module.js.map +1 -1
- package/dist/structure/code-block.css +1 -1
- package/dist/structure/code-block.module.js +2 -2
- package/dist/structure/code-block.module.js.map +1 -1
- package/dist/structure/collapsible.css +1 -1
- package/dist/structure/collapsible.module.js +5 -5
- package/dist/structure/collapsible.module.js.map +1 -1
- package/dist/structure/cursor-pagination.css +1 -1
- package/dist/structure/cursor-pagination.module.js +6 -3
- package/dist/structure/cursor-pagination.module.js.map +1 -1
- package/dist/structure/data-table.css +1 -1
- package/dist/structure/data-table.module.js +1 -1
- package/dist/structure/error-summary.css +1 -1
- package/dist/structure/error-summary.module.js +1 -1
- package/dist/structure/error-summary.module.js.map +1 -1
- package/dist/structure/json-tree.css +1 -1
- package/dist/structure/json-tree.module.js +1 -1
- package/dist/structure/json-tree.module.js.map +1 -1
- package/dist/structure/list.css +1 -1
- package/dist/structure/list.module.js +1 -1
- package/dist/structure/list.module.js.map +1 -1
- package/dist/structure/log-view.css +1 -1
- package/dist/structure/log-view.module.js +1 -1
- package/dist/structure/pagination.css +1 -1
- package/dist/structure/pagination.module.js +7 -3
- package/dist/structure/pagination.module.js.map +1 -1
- package/dist/structure/rich-text-content.css +1 -0
- package/dist/structure/rich-text-content.module.js +19 -0
- package/dist/structure/rich-text-content.module.js.map +1 -0
- package/dist/structure/section-nav.css +1 -1
- package/dist/structure/section-nav.module.js +1 -1
- package/dist/structure/section-nav.module.js.map +1 -1
- package/dist/structure/stepper.css +1 -1
- package/dist/structure/stepper.module.js +2 -2
- package/dist/structure/stepper.module.js.map +1 -1
- package/dist/structure/table-of-contents.css +1 -1
- package/dist/structure/table-of-contents.module.js +1 -1
- package/dist/structure/table-of-contents.module.js.map +1 -1
- package/dist/structure/table.css +1 -1
- package/dist/structure/table.module.js +1 -1
- package/dist/structure/table.module.js.map +1 -1
- package/dist/structure/tree.css +1 -1
- package/dist/structure/tree.module.js +1 -1
- package/dist/structure/tree.module.js.map +1 -1
- package/dist/types/ai/ArtifactPane.vue.d.ts +1 -1
- package/dist/types/ai/AttachmentChip.vue.d.ts +1 -1
- package/dist/types/ai/ToolCall.vue.d.ts +1 -1
- package/dist/types/archetypes/FormPage.vue.d.ts +1 -0
- package/dist/types/charts/BarChart.vue.d.ts +1 -1
- package/dist/types/controls/FileUpload.vue.d.ts +1 -1
- package/dist/types/controls/RecordButton.vue.d.ts +2 -2
- package/dist/types/controls/RichTextInput.vue.d.ts +210 -0
- package/dist/types/controls/Slider.vue.d.ts +1 -1
- package/dist/types/index.d.ts +4 -0
- package/dist/types/layout/Grid.vue.d.ts +1 -1
- package/dist/types/layout/Inline.vue.d.ts +2 -2
- package/dist/types/layout/Stack.vue.d.ts +2 -2
- package/dist/types/overlays/CommandPanel.vue.d.ts +2 -2
- package/dist/types/overlays/Drawer.vue.d.ts +1 -1
- package/dist/types/overlays/HoverCard.vue.d.ts +1 -1
- package/dist/types/overlays/Menu.vue.d.ts +1 -1
- package/dist/types/overlays/Popover.vue.d.ts +1 -1
- package/dist/types/overlays/Toast.vue.d.ts +3 -1
- package/dist/types/overlays/Tooltip.vue.d.ts +1 -1
- package/dist/types/structure/Accordion.vue.d.ts +7 -0
- package/dist/types/structure/Collapsible.vue.d.ts +7 -0
- package/dist/types/structure/CursorPagination.vue.d.ts +13 -0
- package/dist/types/structure/EmptyState.vue.d.ts +1 -1
- package/dist/types/structure/Hero.vue.d.ts +1 -1
- package/dist/types/structure/Image.vue.d.ts +13 -0
- package/dist/types/structure/Pagination.vue.d.ts +8 -0
- package/dist/types/structure/RelativeTime.vue.d.ts +1 -1
- package/dist/types/structure/RichTextContent.vue.d.ts +59 -0
- package/dist/types/structure/RichTextContentBlocks.vue.d.ts +7 -0
- package/dist/types/structure/RichTextContentInlines.vue.d.ts +7 -0
- package/dist/types/structure/RichTextContentItem.vue.d.ts +7 -0
- package/package.json +17 -4
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import e from "./CodeBlock.js";
|
|
2
|
+
import t from "./Heading.js";
|
|
3
|
+
import n from "./Text.js";
|
|
4
|
+
import r from "./rich-text-content.module.js";
|
|
5
|
+
import i from "./RichTextContentInlines.js";
|
|
6
|
+
import a from "./RichTextContentBlocks.js";
|
|
7
|
+
import { richTextPositionAttrs as o } from "@polymorph/vue";
|
|
8
|
+
import { Fragment as s, createBlock as c, createCommentVNode as l, createElementBlock as u, createElementVNode as d, createTextVNode as f, createVNode as p, defineComponent as m, inject as h, mergeProps as g, normalizeClass as _, openBlock as v, renderList as y, resolveComponent as b, toDisplayString as x, unref as S, withCtx as C } from "vue";
|
|
9
|
+
//#region src/structure/RichTextContentItem.vue?vue&type=script&setup=true&lang.ts
|
|
10
|
+
var w = ["data-level"], T = ["data-level"], E = ["data-level"], D = ["start"], O = /*@__PURE__*/ m({
|
|
11
|
+
name: "RichTextContentItem",
|
|
12
|
+
inheritAttrs: !1,
|
|
13
|
+
__name: "RichTextContentItem",
|
|
14
|
+
props: { blocks: {} },
|
|
15
|
+
setup(m) {
|
|
16
|
+
let O = h("polymorph:RichTextContent", {});
|
|
17
|
+
return (h, k) => {
|
|
18
|
+
let A = b("RichTextContentItem", !0);
|
|
19
|
+
return v(), u("li", { class: _(S(r).item) }, [(v(!0), u(s, null, y(m.blocks, (m, h) => (v(), u(s, { key: h }, [m.kind === "paragraph" ? (v(), c(n, {
|
|
20
|
+
key: 0,
|
|
21
|
+
size: S(O).size
|
|
22
|
+
}, {
|
|
23
|
+
default: C(() => [p(i, { inlines: m.inlines }, null, 8, ["inlines"])]),
|
|
24
|
+
_: 2
|
|
25
|
+
}, 1032, ["size"])) : m.kind === "heading" ? (v(), c(t, {
|
|
26
|
+
key: 1,
|
|
27
|
+
level: m.level
|
|
28
|
+
}, {
|
|
29
|
+
default: C(() => [f(x(m.text), 1)]),
|
|
30
|
+
_: 2
|
|
31
|
+
}, 1032, ["level"])) : m.kind === "ownHeading" && m.level === 4 ? (v(), u("h4", {
|
|
32
|
+
key: 2,
|
|
33
|
+
class: _(S(r).heading),
|
|
34
|
+
"data-level": String(m.level)
|
|
35
|
+
}, [p(i, { inlines: m.inlines }, null, 8, ["inlines"])], 10, w)) : m.kind === "ownHeading" && m.level === 3 ? (v(), u("h3", {
|
|
36
|
+
key: 3,
|
|
37
|
+
class: _(S(r).heading),
|
|
38
|
+
"data-level": String(m.level)
|
|
39
|
+
}, [p(i, { inlines: m.inlines }, null, 8, ["inlines"])], 10, T)) : m.kind === "ownHeading" ? (v(), u("h2", {
|
|
40
|
+
key: 4,
|
|
41
|
+
class: _(S(r).heading),
|
|
42
|
+
"data-level": String(m.level)
|
|
43
|
+
}, [p(i, { inlines: m.inlines }, null, 8, ["inlines"])], 10, E)) : m.kind === "list" && m.ordered ? (v(), u("ol", {
|
|
44
|
+
key: 5,
|
|
45
|
+
class: _(S(r).list),
|
|
46
|
+
start: m.start
|
|
47
|
+
}, [(v(!0), u(s, null, y(m.items, (e, t) => (v(), c(A, {
|
|
48
|
+
key: t,
|
|
49
|
+
blocks: e
|
|
50
|
+
}, null, 8, ["blocks"]))), 128))], 10, D)) : m.kind === "list" ? (v(), u("ul", {
|
|
51
|
+
key: 6,
|
|
52
|
+
class: _(S(r).list)
|
|
53
|
+
}, [(v(!0), u(s, null, y(m.items, (e, t) => (v(), c(A, {
|
|
54
|
+
key: t,
|
|
55
|
+
blocks: e
|
|
56
|
+
}, null, 8, ["blocks"]))), 128))], 2)) : m.kind === "quote" ? (v(), u("blockquote", {
|
|
57
|
+
key: 7,
|
|
58
|
+
class: _(S(r).quote)
|
|
59
|
+
}, [p(a, { blocks: m.blocks }, null, 8, ["blocks"])], 2)) : m.kind === "codeBlock" && m.at === null ? (v(), c(e, {
|
|
60
|
+
key: 8,
|
|
61
|
+
copyable: m.copyable,
|
|
62
|
+
label: m.language
|
|
63
|
+
}, {
|
|
64
|
+
default: C(() => [f(x(m.text), 1)]),
|
|
65
|
+
_: 2
|
|
66
|
+
}, 1032, ["copyable", "label"])) : m.kind === "codeBlock" ? (v(), u("div", g({
|
|
67
|
+
key: 9,
|
|
68
|
+
ref_for: !0
|
|
69
|
+
}, S(o)(m.at, !0, !0)), [p(e, {
|
|
70
|
+
copyable: m.copyable,
|
|
71
|
+
label: m.language
|
|
72
|
+
}, {
|
|
73
|
+
default: C(() => [f(x(m.text), 1)]),
|
|
74
|
+
_: 2
|
|
75
|
+
}, 1032, ["copyable", "label"])], 16)) : m.kind === "later" && m.at === null ? (v(), c(n, {
|
|
76
|
+
key: 10,
|
|
77
|
+
size: S(O).size
|
|
78
|
+
}, {
|
|
79
|
+
default: C(() => [f(x(m.text), 1)]),
|
|
80
|
+
_: 2
|
|
81
|
+
}, 1032, ["size"])) : m.kind === "later" ? (v(), c(n, {
|
|
82
|
+
key: 11,
|
|
83
|
+
size: S(O).size
|
|
84
|
+
}, {
|
|
85
|
+
default: C(() => [d("span", g({ ref_for: !0 }, S(o)(m.at, !0)), x(m.text), 17)]),
|
|
86
|
+
_: 2
|
|
87
|
+
}, 1032, ["size"])) : l("", !0)], 64))), 128))], 2);
|
|
88
|
+
};
|
|
89
|
+
}
|
|
90
|
+
});
|
|
91
|
+
//#endregion
|
|
92
|
+
export { O as default };
|
|
93
|
+
|
|
94
|
+
//# sourceMappingURL=RichTextContentItem.vue_vue_type_script_setup_true_lang.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RichTextContentItem.vue_vue_type_script_setup_true_lang.js","names":[],"sources":["../../src/structure/RichTextContentItem.vue"],"sourcesContent":["<script setup lang=\"ts\">\n/**\n * RichTextContent.Item: a list’s item and its drawn blocks.\n *\n * Generated by `pnpm shells` from `packages/shells/src/members/rich-text-content.ts`, the member's\n * framework-neutral description. Never edit it by hand: change the description and\n * run `pnpm shells`.\n */\nimport { inject } from 'vue'\n\nimport { richTextPositionAttrs, type RichTextDrawnBlock } from '@polymorph/vue'\nimport styles from '@polymorph/recipes/structure/rich-text-content.module.css'\nimport CodeBlock from './CodeBlock.vue'\nimport Heading from './Heading.vue'\nimport RichTextContentBlocks from './RichTextContentBlocks.vue'\nimport RichTextContentInlines from './RichTextContentInlines.vue'\nimport Text from './Text.vue'\n\nexport interface RichTextContentItemProps {\n blocks: RichTextDrawnBlock[]\n}\n\ndefineOptions({ name: 'RichTextContentItem', inheritAttrs: false })\n\ndefineProps<RichTextContentItemProps>()\nconst owner = inject<Record<string, any>>('polymorph:RichTextContent', {})\n</script>\n\n<template>\n <li :class=\"styles.item\">\n <template v-for=\"(block, index) in blocks\" :key=\"index\">\n <Text v-if=\"block.kind === 'paragraph'\" :size=\"owner.size\">\n <RichTextContentInlines :inlines=\"block.inlines\" />\n </Text>\n <Heading v-else-if=\"block.kind === 'heading'\" :level=\"block.level\">\n {{ block.text }}\n </Heading>\n <h4\n v-else-if=\"block.kind === 'ownHeading' && block.level === 4\"\n :class=\"styles.heading\"\n :data-level=\"String(block.level)\"\n >\n <RichTextContentInlines :inlines=\"block.inlines\" />\n </h4>\n <h3\n v-else-if=\"block.kind === 'ownHeading' && block.level === 3\"\n :class=\"styles.heading\"\n :data-level=\"String(block.level)\"\n >\n <RichTextContentInlines :inlines=\"block.inlines\" />\n </h3>\n <h2\n v-else-if=\"block.kind === 'ownHeading'\"\n :class=\"styles.heading\"\n :data-level=\"String(block.level)\"\n >\n <RichTextContentInlines :inlines=\"block.inlines\" />\n </h2>\n <!-- list -->\n <ol\n v-else-if=\"block.kind === 'list' && block.ordered\"\n :class=\"styles.list\"\n :start=\"block.start\"\n >\n <template v-for=\"(entry, position) in block.items\" :key=\"position\">\n <RichTextContentItem :blocks=\"entry\" />\n </template>\n </ol>\n <!-- list -->\n <ul v-else-if=\"block.kind === 'list'\" :class=\"styles.list\">\n <template v-for=\"(entry, position) in block.items\" :key=\"position\">\n <RichTextContentItem :blocks=\"entry\" />\n </template>\n </ul>\n <!-- quote -->\n <blockquote v-else-if=\"block.kind === 'quote'\" :class=\"styles.quote\">\n <RichTextContentBlocks :blocks=\"block.blocks\" />\n </blockquote>\n <CodeBlock\n v-else-if=\"block.kind === 'codeBlock' && block.at === null\"\n :copyable=\"block.copyable\"\n :label=\"block.language\"\n >\n {{ block.text }}\n </CodeBlock>\n <div\n v-else-if=\"block.kind === 'codeBlock'\"\n v-bind=\"richTextPositionAttrs(block.at, true, true)\"\n >\n <CodeBlock :copyable=\"block.copyable\" :label=\"block.language\">\n {{ block.text }}\n </CodeBlock>\n </div>\n <Text v-else-if=\"block.kind === 'later' && block.at === null\" :size=\"owner.size\">\n {{ block.text }}\n </Text>\n <Text v-else-if=\"block.kind === 'later'\" :size=\"owner.size\">\n <span v-bind=\"richTextPositionAttrs(block.at, true)\">\n {{ block.text }}\n </span>\n </Text>\n </template>\n </li>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;EAyBA,IAAM,IAAQ,EAA4B,6BAA6B,CAAC,CAAC;;;eAIvE,EAyEK,MAAA,EAzEA,OAAK,EAAE,EAAA,CAAA,CAAM,CAAC,IAAI,EAAA,GAAA,EAAA,EAAA,EAAA,GACrB,EAuEW,GAAA,MAAA,EAvEwB,EAAA,SAAjB,GAAO,wBAAwB,EAAK,GAAA,CACxC,EAAM,SAAI,eAAA,EAAA,GAAtB,EAEO,GAAA;;IAFkC,MAAM,EAAA,CAAA,CAAK,CAAC;;qBACA,CAAnD,EAAmD,GAAA,EAA1B,SAAS,EAAM,QAAA,GAAA,MAAA,GAAA,CAAA,SAAA,CAAA,CAAA,CAAA;;yBAEtB,EAAM,SAAI,aAAA,EAAA,GAA9B,EAEU,GAAA;;IAFqC,OAAO,EAAM;;qBAC1C,CAAA,EAAA,EAAb,EAAM,IAAI,GAAA,CAAA,CAAA,CAAA;;0BAGF,EAAM,SAAI,gBAAqB,EAAM,UAAK,KAAA,EAAA,GADvD,EAMK,MAAA;;IAJF,OAAK,EAAE,EAAA,CAAA,CAAM,CAAC,OAAO;IACrB,cAAY,OAAO,EAAM,KAAK;OAE/B,EAAmD,GAAA,EAA1B,SAAS,EAAM,QAAA,GAAA,MAAA,GAAA,CAAA,SAAA,CAAA,CAAA,GAAA,IAAA,CAAA,KAG7B,EAAM,SAAI,gBAAqB,EAAM,UAAK,KAAA,EAAA,GADvD,EAMK,MAAA;;IAJF,OAAK,EAAE,EAAA,CAAA,CAAM,CAAC,OAAO;IACrB,cAAY,OAAO,EAAM,KAAK;OAE/B,EAAmD,GAAA,EAA1B,SAAS,EAAM,QAAA,GAAA,MAAA,GAAA,CAAA,SAAA,CAAA,CAAA,GAAA,IAAA,CAAA,KAG7B,EAAM,SAAI,gBAAA,EAAA,GADvB,EAMK,MAAA;;IAJF,OAAK,EAAE,EAAA,CAAA,CAAM,CAAC,OAAO;IACrB,cAAY,OAAO,EAAM,KAAK;OAE/B,EAAmD,GAAA,EAA1B,SAAS,EAAM,QAAA,GAAA,MAAA,GAAA,CAAA,SAAA,CAAA,CAAA,GAAA,IAAA,CAAA,KAI7B,EAAM,SAAI,UAAe,EAAM,WAAA,EAAA,GAD5C,EAQK,MAAA;;IANF,OAAK,EAAE,EAAA,CAAA,CAAM,CAAC,IAAI;IAClB,OAAO,EAAM;eAEd,EAEW,GAAA,MAAA,EAF2B,EAAM,QAA1B,GAAO,YACvB,EAAuC,GAAA;SADgB;IACjC,QAAQ;gDAInB,EAAM,SAAI,UAAA,EAAA,GAAzB,EAIK,MAAA;;IAJkC,OAAK,EAAE,EAAA,CAAA,CAAM,CAAC,IAAI;eACvD,EAEW,GAAA,MAAA,EAF2B,EAAM,QAA1B,GAAO,YACvB,EAAuC,GAAA;SADgB;IACjC,QAAQ;4CAIX,EAAM,SAAI,WAAA,EAAA,GAAjC,EAEa,cAAA;;IAFmC,OAAK,EAAE,EAAA,CAAA,CAAM,CAAC,KAAK;OACjE,EAAgD,GAAA,EAAxB,QAAQ,EAAM,OAAA,GAAA,MAAA,GAAA,CAAA,QAAA,CAAA,CAAA,GAAA,CAAA,KAG3B,EAAM,SAAI,eAAoB,EAAM,OAAE,QAAA,EAAA,GADnD,EAMY,GAAA;;IAJT,UAAU,EAAM;IAChB,OAAO,EAAM;;qBAEE,CAAA,EAAA,EAAb,EAAM,IAAI,GAAA,CAAA,CAAA,CAAA;;sCAGF,EAAM,SAAI,eAAA,EAAA,GADvB,EAOM,OAPN,EAOM;;;MALI,EAAA,CAAA,CAAqB,CAAC,EAAM,IAAE,IAAA,EAAA,CAAA,GAAA,CAEtC,EAEY,GAAA;IAFA,UAAU,EAAM;IAAW,OAAO,EAAM;;qBAClC,CAAA,EAAA,EAAb,EAAM,IAAI,GAAA,CAAA,CAAA,CAAA;;4CAGA,EAAM,SAAI,WAAgB,EAAM,OAAE,QAAA,EAAA,GAAnD,EAEO,GAAA;;IAFwD,MAAM,EAAA,CAAA,CAAK,CAAC;;qBACzD,CAAA,EAAA,EAAb,EAAM,IAAI,GAAA,CAAA,CAAA,CAAA;;yBAEE,EAAM,SAAI,WAAA,EAAA,GAA3B,EAIO,GAAA;;IAJmC,MAAM,EAAA,CAAA,CAAK,CAAC;;qBAG7C,CAFP,EAEO,QAFP,EAEO,EAAA,SAAA,GAAA,GAFO,EAAA,CAAA,CAAqB,CAAC,EAAM,IAAE,EAAA,CAAA,GAAA,EACvC,EAAM,IAAI,GAAA,EAAA,CAAA,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ScrollArea.js","names":[],"sources":["../../src/structure/ScrollArea.vue"],"sourcesContent":["<script setup lang=\"ts\">\n/**\n * Token-styled scrollbar for a region that already scrolls (`design/components/scroll-area.md`).\n *\n * Generated by `pnpm shells` from `packages/shells/src/members/scroll-area.ts`, the member's\n * framework-neutral description. Never edit it by hand: change the description and\n * run `pnpm shells`.\n */\nimport { computed, useId } from 'vue'\n\nimport * as zag from '@zag-js/scroll-area'\nimport { normalizeProps, useMachine } from '@zag-js/vue'\n\nimport { useDirection } from '@polymorph/vue'\nimport styles from '@polymorph/recipes/structure/scroll-area.module.css'\n\nexport type ScrollAreaOrientation = NonNullable<ScrollAreaProps['orientation']>\n\nexport type ScrollAreaType = NonNullable<ScrollAreaProps['type']>\n\nexport interface ScrollAreaProps {\n /**\n * Names the region for keyboard users once it overflows, as in CodeBlock. Required rather than\n * defaulted. The content identifies the region, but a default name would be in one fixed\n * language, and the app's language is unknown here.\n */\n label: string\n /**\n * Which axes may pan; `'both'` draws two rails and the corner.\n */\n orientation?: 'horizontal' | 'vertical' | 'both'\n type?: 'hover' | 'always'\n}\n\ndefineOptions({ name: 'ScrollArea', inheritAttrs: false })\n\nconst props = withDefaults(defineProps<ScrollAreaProps>(), {\n orientation: 'vertical',\n type: 'always',\n})\ndefineSlots<{ default: (props: Record<string, never>) => unknown }>()\nconst uid = useId()\nconst fades = computed(() => props.type === 'hover')\nconst documentDirection = useDirection()\nconst service = useMachine(\n zag.machine,\n computed(() => ({ id: uid, dir: documentDirection.value })),\n)\nconst api = computed(() => zag.connect(service, normalizeProps))\nconst overflowing = computed(() => api.value.hasOverflowX || api.value.hasOverflowY)\n</script>\n\n<template>\n <div v-bind=\"api.getRootProps()\" :class=\"styles.root\" data-member=\"scroll-area\">\n <div\n v-bind=\"api.getViewportProps()\"\n :class=\"styles.viewport\"\n :style=\"{\n overflowX: orientation === 'vertical' ? 'hidden' : 'scroll',\n overflowY: orientation === 'horizontal' ? 'hidden' : 'scroll',\n scrollbarWidth: 'none',\n }\"\n :tabindex=\"overflowing ? 0 : undefined\"\n :role=\"overflowing ? 'region' : undefined\"\n :aria-label=\"overflowing ? label : undefined\"\n >\n <div v-bind=\"api.getContentProps()\">\n <slot />\n </div>\n </div>\n <template v-if=\"orientation === 'both' || orientation === 'vertical'\">\n <div\n v-if=\"api.hasOverflowY\"\n v-bind=\"api.getScrollbarProps({ orientation: 'vertical' })\"\n :class=\"[styles.rail, fades ? styles.hover : undefined, !fades ? styles.always : undefined]\"\n aria-hidden=\"true\"\n :data-state=\"\n fades\n ? api.getScrollbarState({ orientation: 'vertical' }).hovering ||\n api.getScrollbarState({ orientation: 'vertical' }).scrolling\n ? 'visible'\n : 'hidden'\n : undefined\n \"\n >\n <div v-bind=\"api.getThumbProps({ orientation: 'vertical' })\" :class=\"styles.thumb\" />\n </div>\n </template>\n <template v-if=\"orientation === 'both' || orientation === 'horizontal'\">\n <div\n v-if=\"api.hasOverflowX\"\n v-bind=\"api.getScrollbarProps({ orientation: 'horizontal' })\"\n :class=\"[styles.rail, fades ? styles.hover : undefined, !fades ? styles.always : undefined]\"\n aria-hidden=\"true\"\n :data-state=\"\n fades\n ? api.getScrollbarState({ orientation: 'horizontal' }).hovering ||\n api.getScrollbarState({ orientation: 'horizontal' }).scrolling\n ? 'visible'\n : 'hidden'\n : undefined\n \"\n >\n <div v-bind=\"api.getThumbProps({ orientation: 'horizontal' })\" :class=\"styles.thumb\" />\n </div>\n </template>\n <div\n v-if=\"orientation === 'both'\"\n v-bind=\"api.getCornerProps()\"\n :class=\"styles.corner\"\n aria-hidden=\"true\"\n />\n </div>\n</template>\n"],"mappings":""}
|
|
1
|
+
{"version":3,"file":"ScrollArea.js","names":[],"sources":["../../src/structure/ScrollArea.vue"],"sourcesContent":["<script setup lang=\"ts\">\n/**\n * Token-styled scrollbar for a region that already scrolls (`design/components/scroll-area.md`).\n *\n * Generated by `pnpm shells` from `packages/shells/src/members/scroll-area.ts`, the member's\n * framework-neutral description. Never edit it by hand: change the description and\n * run `pnpm shells`.\n */\nimport { computed, useId, useTemplateRef } from 'vue'\n\nimport * as zag from '@zag-js/scroll-area'\nimport { normalizeProps, useMachine } from '@zag-js/vue'\n\nimport { useDirection } from '@polymorph/vue'\nimport styles from '@polymorph/recipes/structure/scroll-area.module.css'\n\nexport type ScrollAreaOrientation = NonNullable<ScrollAreaProps['orientation']>\n\nexport type ScrollAreaType = NonNullable<ScrollAreaProps['type']>\n\nexport interface ScrollAreaProps {\n /**\n * Names the region for keyboard users once it overflows, as in CodeBlock. Required rather than\n * defaulted. The content identifies the region, but a default name would be in one fixed\n * language, and the app's language is unknown here.\n */\n label: string\n /**\n * Which axes may pan; `'both'` draws two rails and the corner.\n */\n orientation?: 'horizontal' | 'vertical' | 'both'\n type?: 'hover' | 'always'\n}\n\ndefineOptions({ name: 'ScrollArea', inheritAttrs: false })\n\nconst props = withDefaults(defineProps<ScrollAreaProps>(), {\n orientation: 'vertical',\n type: 'always',\n})\ndefineSlots<{ default: (props: Record<string, never>) => unknown }>()\nconst uid = useId()\nconst root = useTemplateRef<HTMLElement>('root')\nconst fades = computed(() => props.type === 'hover')\nconst documentDirection = useDirection(() => root.value)\nconst service = useMachine(\n zag.machine,\n computed(() => ({ id: uid, dir: documentDirection.value })),\n)\nconst api = computed(() => zag.connect(service, normalizeProps))\nconst overflowing = computed(() => api.value.hasOverflowX || api.value.hasOverflowY)\n</script>\n\n<template>\n <div ref=\"root\" v-bind=\"api.getRootProps()\" :class=\"styles.root\" data-member=\"scroll-area\">\n <div\n v-bind=\"api.getViewportProps()\"\n :class=\"styles.viewport\"\n :style=\"{\n overflowX: orientation === 'vertical' ? 'hidden' : 'scroll',\n overflowY: orientation === 'horizontal' ? 'hidden' : 'scroll',\n scrollbarWidth: 'none',\n }\"\n :tabindex=\"overflowing ? 0 : undefined\"\n :role=\"overflowing ? 'region' : undefined\"\n :aria-label=\"overflowing ? label : undefined\"\n >\n <div v-bind=\"api.getContentProps()\">\n <slot />\n </div>\n </div>\n <template v-if=\"orientation === 'both' || orientation === 'vertical'\">\n <div\n v-if=\"api.hasOverflowY\"\n v-bind=\"api.getScrollbarProps({ orientation: 'vertical' })\"\n :class=\"[styles.rail, fades ? styles.hover : undefined, !fades ? styles.always : undefined]\"\n aria-hidden=\"true\"\n :data-state=\"\n fades\n ? api.getScrollbarState({ orientation: 'vertical' }).hovering ||\n api.getScrollbarState({ orientation: 'vertical' }).scrolling\n ? 'visible'\n : 'hidden'\n : undefined\n \"\n >\n <div v-bind=\"api.getThumbProps({ orientation: 'vertical' })\" :class=\"styles.thumb\" />\n </div>\n </template>\n <template v-if=\"orientation === 'both' || orientation === 'horizontal'\">\n <div\n v-if=\"api.hasOverflowX\"\n v-bind=\"api.getScrollbarProps({ orientation: 'horizontal' })\"\n :class=\"[styles.rail, fades ? styles.hover : undefined, !fades ? styles.always : undefined]\"\n aria-hidden=\"true\"\n :data-state=\"\n fades\n ? api.getScrollbarState({ orientation: 'horizontal' }).hovering ||\n api.getScrollbarState({ orientation: 'horizontal' }).scrolling\n ? 'visible'\n : 'hidden'\n : undefined\n \"\n >\n <div v-bind=\"api.getThumbProps({ orientation: 'horizontal' })\" :class=\"styles.thumb\" />\n </div>\n </template>\n <div\n v-if=\"orientation === 'both'\"\n v-bind=\"api.getCornerProps()\"\n :class=\"styles.corner\"\n aria-hidden=\"true\"\n />\n </div>\n</template>\n"],"mappings":""}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import e from "./scroll-area.module.js";
|
|
2
2
|
import { useDirection as t } from "@polymorph/vue";
|
|
3
|
-
import { Fragment as n, computed as r, createCommentVNode as i, createElementBlock as a, createElementVNode as o, defineComponent as s, guardReactiveProps as c, mergeProps as l, normalizeProps as u, openBlock as d, renderSlot as f, unref as p, useId as m } from "vue";
|
|
4
|
-
import { normalizeProps as
|
|
5
|
-
import * as
|
|
3
|
+
import { Fragment as n, computed as r, createCommentVNode as i, createElementBlock as a, createElementVNode as o, defineComponent as s, guardReactiveProps as c, mergeProps as l, normalizeProps as u, openBlock as d, renderSlot as f, unref as p, useId as m, useTemplateRef as h } from "vue";
|
|
4
|
+
import { normalizeProps as g, useMachine as _ } from "@zag-js/vue";
|
|
5
|
+
import * as v from "@zag-js/scroll-area";
|
|
6
6
|
//#region src/structure/ScrollArea.vue?vue&type=script&setup=true&lang.ts
|
|
7
|
-
var
|
|
7
|
+
var y = [
|
|
8
8
|
"tabindex",
|
|
9
9
|
"role",
|
|
10
10
|
"aria-label"
|
|
11
|
-
],
|
|
11
|
+
], b = ["data-state"], x = ["data-state"], S = /*@__PURE__*/ s({
|
|
12
12
|
name: "ScrollArea",
|
|
13
13
|
inheritAttrs: !1,
|
|
14
14
|
__name: "ScrollArea",
|
|
@@ -18,44 +18,47 @@ var v = [
|
|
|
18
18
|
type: { default: "always" }
|
|
19
19
|
},
|
|
20
20
|
setup(s) {
|
|
21
|
-
let
|
|
22
|
-
id:
|
|
23
|
-
dir:
|
|
24
|
-
}))),
|
|
25
|
-
return (t, r) => (d(), a("div", l(
|
|
21
|
+
let S = s, C = m(), w = h("root"), T = r(() => S.type === "hover"), E = t(() => w.value), D = _(v.machine, r(() => ({
|
|
22
|
+
id: C,
|
|
23
|
+
dir: E.value
|
|
24
|
+
}))), O = r(() => v.connect(D, g)), k = r(() => O.value.hasOverflowX || O.value.hasOverflowY);
|
|
25
|
+
return (t, r) => (d(), a("div", l({
|
|
26
|
+
ref_key: "root",
|
|
27
|
+
ref: w
|
|
28
|
+
}, O.value.getRootProps(), {
|
|
26
29
|
class: p(e).root,
|
|
27
30
|
"data-member": "scroll-area"
|
|
28
31
|
}), [
|
|
29
|
-
o("div", l(
|
|
32
|
+
o("div", l(O.value.getViewportProps(), {
|
|
30
33
|
class: p(e).viewport,
|
|
31
34
|
style: {
|
|
32
35
|
overflowX: s.orientation === "vertical" ? "hidden" : "scroll",
|
|
33
36
|
overflowY: s.orientation === "horizontal" ? "hidden" : "scroll",
|
|
34
37
|
scrollbarWidth: "none"
|
|
35
38
|
},
|
|
36
|
-
tabindex:
|
|
37
|
-
role:
|
|
38
|
-
"aria-label":
|
|
39
|
-
}), [o("div", u(c(
|
|
40
|
-
s.orientation === "both" || s.orientation === "vertical" ? (d(), a(n, { key: 0 }, [
|
|
39
|
+
tabindex: k.value ? 0 : void 0,
|
|
40
|
+
role: k.value ? "region" : void 0,
|
|
41
|
+
"aria-label": k.value ? s.label : void 0
|
|
42
|
+
}), [o("div", u(c(O.value.getContentProps())), [f(t.$slots, "default")], 16)], 16, y),
|
|
43
|
+
s.orientation === "both" || s.orientation === "vertical" ? (d(), a(n, { key: 0 }, [O.value.hasOverflowY ? (d(), a("div", l({ key: 0 }, O.value.getScrollbarProps({ orientation: "vertical" }), {
|
|
41
44
|
class: [
|
|
42
45
|
p(e).rail,
|
|
43
|
-
|
|
44
|
-
|
|
46
|
+
T.value ? p(e).hover : void 0,
|
|
47
|
+
T.value ? void 0 : p(e).always
|
|
45
48
|
],
|
|
46
49
|
"aria-hidden": "true",
|
|
47
|
-
"data-state":
|
|
48
|
-
}), [o("div", l(
|
|
49
|
-
s.orientation === "both" || s.orientation === "horizontal" ? (d(), a(n, { key: 1 }, [
|
|
50
|
+
"data-state": T.value ? O.value.getScrollbarState({ orientation: "vertical" }).hovering || O.value.getScrollbarState({ orientation: "vertical" }).scrolling ? "visible" : "hidden" : void 0
|
|
51
|
+
}), [o("div", l(O.value.getThumbProps({ orientation: "vertical" }), { class: p(e).thumb }), null, 16)], 16, b)) : i("", !0)], 64)) : i("", !0),
|
|
52
|
+
s.orientation === "both" || s.orientation === "horizontal" ? (d(), a(n, { key: 1 }, [O.value.hasOverflowX ? (d(), a("div", l({ key: 0 }, O.value.getScrollbarProps({ orientation: "horizontal" }), {
|
|
50
53
|
class: [
|
|
51
54
|
p(e).rail,
|
|
52
|
-
|
|
53
|
-
|
|
55
|
+
T.value ? p(e).hover : void 0,
|
|
56
|
+
T.value ? void 0 : p(e).always
|
|
54
57
|
],
|
|
55
58
|
"aria-hidden": "true",
|
|
56
|
-
"data-state":
|
|
57
|
-
}), [o("div", l(
|
|
58
|
-
s.orientation === "both" ? (d(), a("div", l({ key: 2 },
|
|
59
|
+
"data-state": T.value ? O.value.getScrollbarState({ orientation: "horizontal" }).hovering || O.value.getScrollbarState({ orientation: "horizontal" }).scrolling ? "visible" : "hidden" : void 0
|
|
60
|
+
}), [o("div", l(O.value.getThumbProps({ orientation: "horizontal" }), { class: p(e).thumb }), null, 16)], 16, x)) : i("", !0)], 64)) : i("", !0),
|
|
61
|
+
s.orientation === "both" ? (d(), a("div", l({ key: 2 }, O.value.getCornerProps(), {
|
|
59
62
|
class: p(e).corner,
|
|
60
63
|
"aria-hidden": "true"
|
|
61
64
|
}), null, 16)) : i("", !0)
|
|
@@ -63,6 +66,6 @@ var v = [
|
|
|
63
66
|
}
|
|
64
67
|
});
|
|
65
68
|
//#endregion
|
|
66
|
-
export {
|
|
69
|
+
export { S as default };
|
|
67
70
|
|
|
68
71
|
//# sourceMappingURL=ScrollArea.vue_vue_type_script_setup_true_lang.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ScrollArea.vue_vue_type_script_setup_true_lang.js","names":[],"sources":["../../src/structure/ScrollArea.vue"],"sourcesContent":["<script setup lang=\"ts\">\n/**\n * Token-styled scrollbar for a region that already scrolls (`design/components/scroll-area.md`).\n *\n * Generated by `pnpm shells` from `packages/shells/src/members/scroll-area.ts`, the member's\n * framework-neutral description. Never edit it by hand: change the description and\n * run `pnpm shells`.\n */\nimport { computed, useId } from 'vue'\n\nimport * as zag from '@zag-js/scroll-area'\nimport { normalizeProps, useMachine } from '@zag-js/vue'\n\nimport { useDirection } from '@polymorph/vue'\nimport styles from '@polymorph/recipes/structure/scroll-area.module.css'\n\nexport type ScrollAreaOrientation = NonNullable<ScrollAreaProps['orientation']>\n\nexport type ScrollAreaType = NonNullable<ScrollAreaProps['type']>\n\nexport interface ScrollAreaProps {\n /**\n * Names the region for keyboard users once it overflows, as in CodeBlock. Required rather than\n * defaulted. The content identifies the region, but a default name would be in one fixed\n * language, and the app's language is unknown here.\n */\n label: string\n /**\n * Which axes may pan; `'both'` draws two rails and the corner.\n */\n orientation?: 'horizontal' | 'vertical' | 'both'\n type?: 'hover' | 'always'\n}\n\ndefineOptions({ name: 'ScrollArea', inheritAttrs: false })\n\nconst props = withDefaults(defineProps<ScrollAreaProps>(), {\n orientation: 'vertical',\n type: 'always',\n})\ndefineSlots<{ default: (props: Record<string, never>) => unknown }>()\nconst uid = useId()\nconst fades = computed(() => props.type === 'hover')\nconst documentDirection = useDirection()\nconst service = useMachine(\n zag.machine,\n computed(() => ({ id: uid, dir: documentDirection.value })),\n)\nconst api = computed(() => zag.connect(service, normalizeProps))\nconst overflowing = computed(() => api.value.hasOverflowX || api.value.hasOverflowY)\n</script>\n\n<template>\n <div v-bind=\"api.getRootProps()\" :class=\"styles.root\" data-member=\"scroll-area\">\n <div\n v-bind=\"api.getViewportProps()\"\n :class=\"styles.viewport\"\n :style=\"{\n overflowX: orientation === 'vertical' ? 'hidden' : 'scroll',\n overflowY: orientation === 'horizontal' ? 'hidden' : 'scroll',\n scrollbarWidth: 'none',\n }\"\n :tabindex=\"overflowing ? 0 : undefined\"\n :role=\"overflowing ? 'region' : undefined\"\n :aria-label=\"overflowing ? label : undefined\"\n >\n <div v-bind=\"api.getContentProps()\">\n <slot />\n </div>\n </div>\n <template v-if=\"orientation === 'both' || orientation === 'vertical'\">\n <div\n v-if=\"api.hasOverflowY\"\n v-bind=\"api.getScrollbarProps({ orientation: 'vertical' })\"\n :class=\"[styles.rail, fades ? styles.hover : undefined, !fades ? styles.always : undefined]\"\n aria-hidden=\"true\"\n :data-state=\"\n fades\n ? api.getScrollbarState({ orientation: 'vertical' }).hovering ||\n api.getScrollbarState({ orientation: 'vertical' }).scrolling\n ? 'visible'\n : 'hidden'\n : undefined\n \"\n >\n <div v-bind=\"api.getThumbProps({ orientation: 'vertical' })\" :class=\"styles.thumb\" />\n </div>\n </template>\n <template v-if=\"orientation === 'both' || orientation === 'horizontal'\">\n <div\n v-if=\"api.hasOverflowX\"\n v-bind=\"api.getScrollbarProps({ orientation: 'horizontal' })\"\n :class=\"[styles.rail, fades ? styles.hover : undefined, !fades ? styles.always : undefined]\"\n aria-hidden=\"true\"\n :data-state=\"\n fades\n ? api.getScrollbarState({ orientation: 'horizontal' }).hovering ||\n api.getScrollbarState({ orientation: 'horizontal' }).scrolling\n ? 'visible'\n : 'hidden'\n : undefined\n \"\n >\n <div v-bind=\"api.getThumbProps({ orientation: 'horizontal' })\" :class=\"styles.thumb\" />\n </div>\n </template>\n <div\n v-if=\"orientation === 'both'\"\n v-bind=\"api.getCornerProps()\"\n :class=\"styles.corner\"\n aria-hidden=\"true\"\n />\n </div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;EAoCA,IAAM,IAAQ,GAKR,IAAM,EAAM,GACZ,IAAQ,QAAe,EAAM,SAAS,OAAO,GAC7C,IAAoB,
|
|
1
|
+
{"version":3,"file":"ScrollArea.vue_vue_type_script_setup_true_lang.js","names":[],"sources":["../../src/structure/ScrollArea.vue"],"sourcesContent":["<script setup lang=\"ts\">\n/**\n * Token-styled scrollbar for a region that already scrolls (`design/components/scroll-area.md`).\n *\n * Generated by `pnpm shells` from `packages/shells/src/members/scroll-area.ts`, the member's\n * framework-neutral description. Never edit it by hand: change the description and\n * run `pnpm shells`.\n */\nimport { computed, useId, useTemplateRef } from 'vue'\n\nimport * as zag from '@zag-js/scroll-area'\nimport { normalizeProps, useMachine } from '@zag-js/vue'\n\nimport { useDirection } from '@polymorph/vue'\nimport styles from '@polymorph/recipes/structure/scroll-area.module.css'\n\nexport type ScrollAreaOrientation = NonNullable<ScrollAreaProps['orientation']>\n\nexport type ScrollAreaType = NonNullable<ScrollAreaProps['type']>\n\nexport interface ScrollAreaProps {\n /**\n * Names the region for keyboard users once it overflows, as in CodeBlock. Required rather than\n * defaulted. The content identifies the region, but a default name would be in one fixed\n * language, and the app's language is unknown here.\n */\n label: string\n /**\n * Which axes may pan; `'both'` draws two rails and the corner.\n */\n orientation?: 'horizontal' | 'vertical' | 'both'\n type?: 'hover' | 'always'\n}\n\ndefineOptions({ name: 'ScrollArea', inheritAttrs: false })\n\nconst props = withDefaults(defineProps<ScrollAreaProps>(), {\n orientation: 'vertical',\n type: 'always',\n})\ndefineSlots<{ default: (props: Record<string, never>) => unknown }>()\nconst uid = useId()\nconst root = useTemplateRef<HTMLElement>('root')\nconst fades = computed(() => props.type === 'hover')\nconst documentDirection = useDirection(() => root.value)\nconst service = useMachine(\n zag.machine,\n computed(() => ({ id: uid, dir: documentDirection.value })),\n)\nconst api = computed(() => zag.connect(service, normalizeProps))\nconst overflowing = computed(() => api.value.hasOverflowX || api.value.hasOverflowY)\n</script>\n\n<template>\n <div ref=\"root\" v-bind=\"api.getRootProps()\" :class=\"styles.root\" data-member=\"scroll-area\">\n <div\n v-bind=\"api.getViewportProps()\"\n :class=\"styles.viewport\"\n :style=\"{\n overflowX: orientation === 'vertical' ? 'hidden' : 'scroll',\n overflowY: orientation === 'horizontal' ? 'hidden' : 'scroll',\n scrollbarWidth: 'none',\n }\"\n :tabindex=\"overflowing ? 0 : undefined\"\n :role=\"overflowing ? 'region' : undefined\"\n :aria-label=\"overflowing ? label : undefined\"\n >\n <div v-bind=\"api.getContentProps()\">\n <slot />\n </div>\n </div>\n <template v-if=\"orientation === 'both' || orientation === 'vertical'\">\n <div\n v-if=\"api.hasOverflowY\"\n v-bind=\"api.getScrollbarProps({ orientation: 'vertical' })\"\n :class=\"[styles.rail, fades ? styles.hover : undefined, !fades ? styles.always : undefined]\"\n aria-hidden=\"true\"\n :data-state=\"\n fades\n ? api.getScrollbarState({ orientation: 'vertical' }).hovering ||\n api.getScrollbarState({ orientation: 'vertical' }).scrolling\n ? 'visible'\n : 'hidden'\n : undefined\n \"\n >\n <div v-bind=\"api.getThumbProps({ orientation: 'vertical' })\" :class=\"styles.thumb\" />\n </div>\n </template>\n <template v-if=\"orientation === 'both' || orientation === 'horizontal'\">\n <div\n v-if=\"api.hasOverflowX\"\n v-bind=\"api.getScrollbarProps({ orientation: 'horizontal' })\"\n :class=\"[styles.rail, fades ? styles.hover : undefined, !fades ? styles.always : undefined]\"\n aria-hidden=\"true\"\n :data-state=\"\n fades\n ? api.getScrollbarState({ orientation: 'horizontal' }).hovering ||\n api.getScrollbarState({ orientation: 'horizontal' }).scrolling\n ? 'visible'\n : 'hidden'\n : undefined\n \"\n >\n <div v-bind=\"api.getThumbProps({ orientation: 'horizontal' })\" :class=\"styles.thumb\" />\n </div>\n </template>\n <div\n v-if=\"orientation === 'both'\"\n v-bind=\"api.getCornerProps()\"\n :class=\"styles.corner\"\n aria-hidden=\"true\"\n />\n </div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;EAoCA,IAAM,IAAQ,GAKR,IAAM,EAAM,GACZ,IAAO,EAA4B,MAAM,GACzC,IAAQ,QAAe,EAAM,SAAS,OAAO,GAC7C,IAAoB,QAAmB,EAAK,KAAK,GACjD,IAAU,EACd,EAAI,SACJ,SAAgB;GAAE,IAAI;GAAK,KAAK,EAAkB;EAAM,EAAE,CAC5D,GACM,IAAM,QAAe,EAAI,QAAQ,GAAS,CAAc,CAAC,GACzD,IAAc,QAAe,EAAI,MAAM,gBAAgB,EAAI,MAAM,YAAY;yBAIjF,EA2DM,OA3DN,EA2DM;YA3DG;GAAJ,KAAI;KAAe,EAAA,MAAI,aAAY,GAAA;GAAK,OAAO,EAAA,CAAA,CAAM,CAAC;GAAM,eAAY;;GAC3E,EAeM,OAfN,EACU,EAcJ,MAdQ,iBAAgB,GAAA;IAC3B,OAAO,EAAA,CAAA,CAAM,CAAC;IACd,OAAK;gBAAuB,EAAA,gBAAW,aAAA,WAAA;gBAA0D,EAAA,gBAAW,eAAA,WAAA;;;IAK5G,UAAU,EAAA,QAAW,IAAO,KAAA;IAC5B,MAAM,EAAA,QAAW,WAAc,KAAA;IAC/B,cAAY,EAAA,QAAc,EAAA,QAAQ,KAAA;QAEnC,EAEM,OAAA,EAAA,EAFO,EAAA,MAAI,gBAAe,CAAA,CAAA,GAAA,CAC9B,EAAQ,EAAA,QAAA,SAAA,CAAA,GAAA,EAAA,CAAA,GAAA,IAAA,CAAA;GAGI,EAAA,gBAAW,UAAe,EAAA,gBAAW,cAAA,EAAA,GAArD,EAiBW,GAAA,EAAA,KAAA,EAAA,GAAA,CAfD,EAAA,MAAI,gBAAA,EAAA,GADZ,EAeM,OAfN,EAeM,EAAA,KAAA,EAAA,GAbI,EAAA,MAAI,kBAAiB,EAAA,aAAA,WAAA,CAAA,GAAA;IAC5B,OAAK;KAAG,EAAA,CAAA,CAAM,CAAC;KAAM,EAAA,QAAQ,EAAA,CAAA,CAAM,CAAC,QAAQ,KAAA;KAAY,EAAA,QAAwB,KAAA,IAAhB,EAAA,CAAA,CAAM,CAAC;IAAkB;IAC1F,eAAY;IACX,cAAuB,EAAA,QAAoB,EAAA,MAAI,kBAAiB,EAAA,aAAA,WAAA,CAAA,CAAA,CAA8B,YAA0B,EAAA,MAAI,kBAAiB,EAAA,aAAA,WAAA,CAAA,CAAA,CAA8B,YAAA,YAAA,WAA2E,KAAA;QASvP,EAAqF,OAArF,EAAa,EAAwE,MAApE,cAAa,EAAA,aAAA,WAAA,CAAA,GAAA,EAAgC,OAAO,EAAA,CAAA,CAAM,CAAC,MAAA,CAAA,GAAA,MAAA,EAAA,CAAA,GAAA,IAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,GAAA,EAAA,KAAA,EAAA,IAAA,EAAA;GAGhE,EAAA,gBAAW,UAAe,EAAA,gBAAW,gBAAA,EAAA,GAArD,EAiBW,GAAA,EAAA,KAAA,EAAA,GAAA,CAfD,EAAA,MAAI,gBAAA,EAAA,GADZ,EAeM,OAfN,EAeM,EAAA,KAAA,EAAA,GAbI,EAAA,MAAI,kBAAiB,EAAA,aAAA,aAAA,CAAA,GAAA;IAC5B,OAAK;KAAG,EAAA,CAAA,CAAM,CAAC;KAAM,EAAA,QAAQ,EAAA,CAAA,CAAM,CAAC,QAAQ,KAAA;KAAY,EAAA,QAAwB,KAAA,IAAhB,EAAA,CAAA,CAAM,CAAC;IAAkB;IAC1F,eAAY;IACX,cAAuB,EAAA,QAAoB,EAAA,MAAI,kBAAiB,EAAA,aAAA,aAAA,CAAA,CAAA,CAAgC,YAA0B,EAAA,MAAI,kBAAiB,EAAA,aAAA,aAAA,CAAA,CAAA,CAAgC,YAAA,YAAA,WAA2E,KAAA;QAS3P,EAAuF,OAAvF,EAAa,EAA0E,MAAtE,cAAa,EAAA,aAAA,aAAA,CAAA,GAAA,EAAkC,OAAO,EAAA,CAAA,CAAM,CAAC,MAAA,CAAA,GAAA,MAAA,EAAA,CAAA,GAAA,IAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,GAAA,EAAA,KAAA,EAAA,IAAA,EAAA;GAI1E,EAAA,gBAAW,UAAA,EAAA,GADnB,EAKE,OALF,EAKE,EAAA,KAAA,EAAA,GAHQ,EAAA,MAAI,eAAc,GAAA;IACzB,OAAO,EAAA,CAAA,CAAM,CAAC;IACf,eAAY"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Table.js","names":[],"sources":["../../src/structure/Table.vue"],"sourcesContent":["<script setup lang=\"ts\">\n/**\n * A styled native table, the main data display in ListPage (`design/components/table.md`).\n *\n * Generated by `pnpm shells` from `packages/shells/src/members/table.ts`, the member's\n * framework-neutral description. Never edit it by hand: change the description and\n * run `pnpm shells`.\n */\nimport { computed, onBeforeUnmount, onMounted, provide, ref, useTemplateRef, watch } from 'vue'\n\nimport { agentMember, pressTableSort, tableSort, tableSortColumns } from '@polymorph/vue'\nimport styles from '@polymorph/recipes/structure/table.module.css'\nimport type { TableCellProps } from './TableCell.vue'\nimport type { TableHeaderProps } from './TableHeader.vue'\nimport type { TableRowProps } from './TableRow.vue'\n\nexport type CellProps = TableCellProps\n\nexport type HeaderProps = TableHeaderProps\n\nexport type RowProps = TableRowProps\n\nexport type SortDirection = 'asc' | 'desc'\n\nexport interface TableProps {\n /**\n * Names the **table** with a real `<caption>`, its first child. `label` names the *scroll\n * region*, which exists only while the columns overflow, so a table that fits has no name.\n * That is fine for a page's main table, but a dashboard's chart twin tables would be announced\n * as \"table, table, table\". Announced but not drawn unless `captionVisible`, because most\n * tables already have their name on screen: a page title, or the chart they are the twin of.\n */\n caption?: string\n /**\n * Draws the caption above the table as well as announcing it, for a table whose name is not\n * already beside it. Not left to composition as Heading's caption is, because a `Text` above\n * the table would not be connected to it, and `<caption>` is the element for a table's name.\n */\n captionVisible?: boolean\n /**\n * The table is a **grid**: one tab stop, arrow keys between cells, and rows that may carry\n * `aria-selected`. Only for a component that owns every cell, in practice DataTable. A\n * hand-composed table is a document of prose and links, browsed with the reader's own keys,\n * and taking the arrow keys for a focus ring would only cost them.\n */\n grid?: boolean\n /**\n * Names the scroll region for keyboard users, usually the page's title.\n */\n label?: string\n /**\n * Rows can be selected in bulk. Only meaningful inside a grid, where it tells a screen reader\n * whether \"selected\" means one of many or the only one.\n */\n multiselectable?: boolean\n stickyHeader?: boolean\n}\n\ndefineOptions({ name: 'Table', inheritAttrs: false })\n\nconst props = withDefaults(defineProps<TableProps>(), {\n captionVisible: false,\n grid: false,\n multiselectable: false,\n stickyHeader: false,\n})\ndefineSlots<{ default?: (props: Record<string, never>) => unknown }>()\nconst overflowing = ref(false)\nconst at = ref({ row: 0, column: 0, detail: false })\nconst placed = ref(false)\nconst table = useTemplateRef<HTMLElement>('table')\nconst wrapper = useTemplateRef<HTMLElement>('wrapper')\nconst stopIn = computed(() => (cell: HTMLTableCellElement): HTMLElement => {\n for (const node of Array.from(\n cell.querySelectorAll<HTMLElement>('button, a[href], input, select, textarea'),\n )) {\n if (node.hasAttribute('disabled') || node.getAttribute('aria-hidden') === 'true') continue\n return node\n }\n return cell\n})\nconst gridRows = computed(\n () =>\n (element: HTMLTableElement): HTMLTableRowElement[] =>\n Array.from(element.rows).filter((row) => !row.hasAttribute('data-detail')),\n)\nconst detailUnder = computed(\n () =>\n (row: HTMLTableRowElement | undefined): HTMLTableCellElement | null => {\n const next = row?.nextElementSibling\n return next instanceof HTMLTableRowElement && next.hasAttribute('data-detail')\n ? (next.cells[0] ?? null)\n : null\n },\n)\nconst gridCellOf = computed(\n () =>\n (element: HTMLTableElement, target: EventTarget | null): HTMLTableCellElement | null => {\n let cell =\n target instanceof HTMLElement ? target.closest<HTMLTableCellElement>('th, td') : null\n while (cell !== null && cell.closest('table') !== element) {\n cell = cell.parentElement?.closest<HTMLTableCellElement>('th, td') ?? null\n }\n if (cell === null || cell.parentElement === null) return null\n return cell.parentElement.hasAttribute('data-detail') && cell !== target ? null : cell\n },\n)\nconst positionOf = computed(\n () =>\n (\n element: HTMLTableElement,\n cell: HTMLTableCellElement,\n column: number,\n ): { row: number; column: number; detail: boolean } => {\n const row = cell.parentElement as HTMLTableRowElement\n const rows = gridRows.value(element)\n return row.hasAttribute('data-detail')\n ? {\n row: rows.indexOf(row.previousElementSibling as HTMLTableRowElement),\n column,\n detail: true,\n }\n : { row: rows.indexOf(row), column: cell.cellIndex, detail: false }\n },\n)\nconst clampCell = computed(\n () =>\n (\n element: HTMLTableElement,\n to: { row: number; column: number; detail: boolean },\n ): { row: number; column: number; detail: boolean } | null => {\n const rows = gridRows.value(element)\n const row = Math.min(Math.max(to.row, 0), rows.length - 1)\n const cells = rows[row]?.cells\n if (cells === undefined || cells.length === 0) return null\n return {\n row,\n column: Math.min(Math.max(to.column, 0), cells.length - 1),\n detail: to.detail && row === to.row && detailUnder.value(rows[row]) !== null,\n }\n },\n)\nconst startOf = computed(\n () =>\n (element: HTMLTableElement): { row: number; column: number; detail: boolean } => {\n const cells = Array.from(gridRows.value(element)[0]?.cells ?? [])\n const column = cells.findIndex((cell) => cell.querySelector('[data-undrawn]') === null)\n return { row: 0, column: Math.max(column, 0), detail: false }\n },\n)\nconst whereIn = computed(\n () =>\n (element: HTMLTableElement): { row: number; column: number; detail: boolean } =>\n placed.value ? at.value : startOf.value(element),\n)\nconst stopAt = computed(\n () =>\n (\n element: HTMLTableElement,\n to: { row: number; column: number; detail: boolean },\n ): HTMLElement | null => {\n const row = gridRows.value(element)[to.row]\n if (to.detail) return detailUnder.value(row)\n const cell = row?.cells[to.column]\n return cell === undefined ? null : stopIn.value(cell)\n },\n)\nconst rove = computed(\n () => (element: HTMLTableElement, to: { row: number; column: number; detail: boolean }) => {\n at.value = to\n for (const [index, row] of gridRows.value(element).entries()) {\n for (const cell of Array.from(row.cells)) {\n const stop = stopIn.value(cell)\n const wanted = !to.detail && index === to.row && cell.cellIndex === to.column ? '0' : '-1'\n if (stop !== cell && cell.getAttribute('tabindex') !== '-1')\n cell.setAttribute('tabindex', '-1')\n if (stop.getAttribute('tabindex') !== wanted) stop.setAttribute('tabindex', wanted)\n }\n const under = detailUnder.value(row)\n const held = to.detail && index === to.row ? '0' : '-1'\n if (under !== null && under.getAttribute('tabindex') !== held)\n under.setAttribute('tabindex', held)\n }\n },\n)\nconst focusIn = computed(() => (event: FocusEvent) => {\n const element = table.value as HTMLTableElement | null\n if (element === null) return\n const cell = gridCellOf.value(element, event.target)\n if (cell === null) return\n const to = clampCell.value(\n element,\n positionOf.value(element, cell, whereIn.value(element).column),\n )\n if (to === null) return\n placed.value = true\n rove.value(element, to)\n})\nconst keyDown = computed(() => (event: KeyboardEvent) => {\n const element = table.value as HTMLTableElement | null\n const target = event.target instanceof HTMLElement ? event.target : null\n if (\n element === null ||\n target === null ||\n target.closest(\n 'input:not([type=\"checkbox\"]):not([type=\"radio\"]), textarea, [contenteditable]',\n ) !== null\n )\n return\n const cell = gridCellOf.value(element, target)\n if (cell === null) return\n const rows = gridRows.value(element)\n const here = positionOf.value(element, cell, whereIn.value(element).column)\n const forward = getComputedStyle(element).direction === 'rtl' ? -1 : 1\n const far = event.ctrlKey || event.metaKey\n const last = Number.MAX_SAFE_INTEGER\n let next: { row: number; column: number; detail: boolean } | null\n if (here.detail) {\n switch (event.key) {\n case 'ArrowDown':\n next = here.row + 1 < rows.length ? { ...here, row: here.row + 1, detail: false } : null\n break\n case 'ArrowUp':\n next = { ...here, detail: false }\n break\n case 'ArrowRight':\n case 'ArrowLeft':\n next = null\n break\n case 'Home':\n next = far ? { row: 0, column: 0, detail: false } : null\n break\n case 'End':\n next = far ? { row: last, column: last, detail: false } : null\n break\n default:\n return\n }\n } else {\n switch (event.key) {\n case 'ArrowRight':\n next = { ...here, column: here.column + forward }\n break\n case 'ArrowLeft':\n next = { ...here, column: here.column - forward }\n break\n case 'ArrowDown':\n next =\n detailUnder.value(rows[here.row]) !== null\n ? { ...here, detail: true }\n : { ...here, row: here.row + 1 }\n break\n case 'ArrowUp':\n next =\n detailUnder.value(rows[here.row - 1]) !== null\n ? { ...here, row: here.row - 1, detail: true }\n : { ...here, row: here.row - 1 }\n break\n case 'Home':\n next = far ? { row: 0, column: 0, detail: false } : { ...here, column: 0 }\n break\n case 'End':\n next = far ? { row: last, column: last, detail: false } : { ...here, column: last }\n break\n default:\n return\n }\n }\n event.preventDefault()\n const to = next === null ? null : clampCell.value(element, next)\n if (to === null) return\n placed.value = true\n rove.value(element, to)\n stopAt.value(element, to)?.focus()\n})\nconst reclamp = computed(() => () => {\n const element = table.value as HTMLTableElement | null\n if (element === null || !props.grid) return\n const to = clampCell.value(element, whereIn.value(element))\n if (to !== null) rove.value(element, to)\n})\nprovide('polymorph:Table', {\n get grid() {\n return props.grid\n },\n})\nlet release1: (() => void) | undefined\nconst effect1 = () => {\n release1?.()\n const run = () => {\n overflowing.value =\n wrapper.value !== null && wrapper.value.scrollWidth > wrapper.value.clientWidth\n }\n const resize = typeof ResizeObserver === 'undefined' ? undefined : new ResizeObserver(run)\n for (const element of [wrapper.value, wrapper.value?.firstElementChild])\n if (element) resize?.observe(element)\n release1 = () => {\n resize?.disconnect()\n }\n run()\n}\nonMounted(effect1)\nonBeforeUnmount(() => release1?.())\nlet release2: (() => void) | undefined\nconst effect2 = () => {\n release2?.()\n const run = () => {\n reclamp.value()\n }\n const mutation = typeof MutationObserver === 'undefined' ? undefined : new MutationObserver(run)\n for (const element of [table.value])\n if (element)\n mutation?.observe(element, {\n childList: true,\n characterData: true,\n subtree: true,\n attributeFilter: ['disabled'],\n })\n release2 = () => {\n mutation?.disconnect()\n }\n run()\n}\nonMounted(effect2)\nwatch(() => props.grid, effect2, { flush: 'post' })\nonBeforeUnmount(() => release2?.())\nlet release3: (() => void) | undefined\nconst effect3 = () => {\n release3?.()\n const ran =\n wrapper.value?.parentElement?.closest('[data-member]')?.getAttribute('data-member') ===\n 'data-table'\n ? () => {}\n : agentMember({\n member: 'Table',\n element: () => wrapper.value,\n state: () => ({\n 'sort-key': tableSort(table.value).key,\n 'sort-direction': tableSort(table.value).direction,\n columns: tableSortColumns(table.value),\n }),\n actions: { sort: { argument: 'id', run: (value) => pressTableSort(table.value, value) } },\n })\n release3 = () => {\n ran()\n }\n}\nonMounted(effect3)\nonBeforeUnmount(() => release3?.())\n</script>\n\n<template>\n <div\n ref=\"wrapper\"\n :class=\"styles.wrapper\"\n :data-sticky-header=\"stickyHeader ? '' : undefined\"\n :data-overflowing=\"overflowing ? '' : undefined\"\n :tabindex=\"overflowing && !grid ? '0' : undefined\"\n :role=\"overflowing && label !== undefined ? 'region' : undefined\"\n :aria-label=\"overflowing ? label : undefined\"\n data-member=\"table\"\n >\n <!-- table -->\n <table\n ref=\"table\"\n :class=\"styles.table\"\n :role=\"grid ? 'grid' : undefined\"\n :aria-multiselectable=\"grid && multiselectable ? 'true' : undefined\"\n @focusin=\"grid && focusIn($event)\"\n @keydown=\"grid && keyDown($event)\"\n >\n <!-- caption -->\n <caption\n v-if=\"caption !== undefined\"\n :class=\"[\n captionVisible ? styles.caption : undefined,\n !captionVisible ? styles.captionHidden : undefined,\n ]\"\n >\n {{\n caption\n }}\n </caption>\n <slot />\n </table>\n </div>\n</template>\n"],"mappings":""}
|
|
1
|
+
{"version":3,"file":"Table.js","names":[],"sources":["../../src/structure/Table.vue"],"sourcesContent":["<script setup lang=\"ts\">\n/**\n * A styled native table, the main data display in ListPage (`design/components/table.md`).\n *\n * Generated by `pnpm shells` from `packages/shells/src/members/table.ts`, the member's\n * framework-neutral description. Never edit it by hand: change the description and\n * run `pnpm shells`.\n */\nimport { computed, onBeforeUnmount, onMounted, provide, ref, useTemplateRef, watch } from 'vue'\n\nimport { agentMember, pressTableSort, tableSort, tableSortColumns } from '@polymorph/vue'\nimport styles from '@polymorph/recipes/structure/table.module.css'\nimport type { TableCellProps } from './TableCell.vue'\nimport type { TableHeaderProps } from './TableHeader.vue'\nimport type { TableRowProps } from './TableRow.vue'\n\nexport type CellProps = TableCellProps\n\nexport type HeaderProps = TableHeaderProps\n\nexport type RowProps = TableRowProps\n\nexport type SortDirection = 'asc' | 'desc'\n\nexport interface TableProps {\n /**\n * Names the **table** with a real `<caption>`, its first child. `label` names the *scroll\n * region*, which exists only while the columns overflow, so a table that fits has no name.\n * That is fine for a page's main table, but a dashboard's chart twin tables would be announced\n * as \"table, table, table\". Announced but not drawn unless `captionVisible`, because most\n * tables already have their name on screen: a page title, or the chart they are the twin of.\n */\n caption?: string\n /**\n * Draws the caption above the table as well as announcing it, for a table whose name is not\n * already beside it. Not left to composition as Heading's caption is, because a `Text` above\n * the table would not be connected to it, and `<caption>` is the element for a table's name.\n */\n captionVisible?: boolean\n /**\n * The table is a **grid**: one tab stop, arrow keys between cells, and rows that may carry\n * `aria-selected`. Only for a component that owns every cell, in practice DataTable. A\n * hand-composed table is a document of prose and links, browsed with the reader's own keys,\n * and taking the arrow keys for a focus ring would only cost them.\n */\n grid?: boolean\n /**\n * Names the scroll region for keyboard users, usually the page's title.\n */\n label?: string\n /**\n * Rows can be selected in bulk. Only meaningful inside a grid, where it tells a screen reader\n * whether \"selected\" means one of many or the only one.\n */\n multiselectable?: boolean\n stickyHeader?: boolean\n}\n\ndefineOptions({ name: 'Table', inheritAttrs: false })\n\nconst props = withDefaults(defineProps<TableProps>(), {\n captionVisible: false,\n grid: false,\n multiselectable: false,\n stickyHeader: false,\n})\ndefineSlots<{ default?: (props: Record<string, never>) => unknown }>()\nconst overflowing = ref(false)\nconst at = ref({ row: 0, column: 0, detail: false })\nconst placed = ref(false)\nconst holds = ref(false)\nconst table = useTemplateRef<HTMLElement>('table')\nconst wrapper = useTemplateRef<HTMLElement>('wrapper')\nconst stopIn = computed(() => (cell: HTMLTableCellElement): HTMLElement => {\n for (const node of Array.from(\n cell.querySelectorAll<HTMLElement>('button, a[href], input, select, textarea'),\n )) {\n if (node.hasAttribute('disabled') || node.getAttribute('aria-hidden') === 'true') continue\n return node\n }\n return cell\n})\nconst gridRows = computed(\n () =>\n (element: HTMLTableElement): HTMLTableRowElement[] =>\n Array.from(element.rows).filter((row) => !row.hasAttribute('data-detail')),\n)\nconst detailUnder = computed(\n () =>\n (row: HTMLTableRowElement | undefined): HTMLTableCellElement | null => {\n const next = row?.nextElementSibling\n return next instanceof HTMLTableRowElement && next.hasAttribute('data-detail')\n ? (next.cells[0] ?? null)\n : null\n },\n)\nconst gridCellOf = computed(\n () =>\n (element: HTMLTableElement, target: EventTarget | null): HTMLTableCellElement | null => {\n let cell =\n target instanceof HTMLElement ? target.closest<HTMLTableCellElement>('th, td') : null\n while (cell !== null && cell.closest('table') !== element) {\n cell = cell.parentElement?.closest<HTMLTableCellElement>('th, td') ?? null\n }\n if (cell === null || cell.parentElement === null) return null\n return cell.parentElement.hasAttribute('data-detail') && cell !== target ? null : cell\n },\n)\nconst positionOf = computed(\n () =>\n (\n element: HTMLTableElement,\n cell: HTMLTableCellElement,\n column: number,\n ): { row: number; column: number; detail: boolean } => {\n const row = cell.parentElement as HTMLTableRowElement\n const rows = gridRows.value(element)\n return row.hasAttribute('data-detail')\n ? {\n row: rows.indexOf(row.previousElementSibling as HTMLTableRowElement),\n column,\n detail: true,\n }\n : { row: rows.indexOf(row), column: cell.cellIndex, detail: false }\n },\n)\nconst clampCell = computed(\n () =>\n (\n element: HTMLTableElement,\n to: { row: number; column: number; detail: boolean },\n ): { row: number; column: number; detail: boolean } | null => {\n const rows = gridRows.value(element)\n const row = Math.min(Math.max(to.row, 0), rows.length - 1)\n const cells = rows[row]?.cells\n if (cells === undefined || cells.length === 0) return null\n return {\n row,\n column: Math.min(Math.max(to.column, 0), cells.length - 1),\n detail: to.detail && row === to.row && detailUnder.value(rows[row]) !== null,\n }\n },\n)\nconst startOf = computed(\n () =>\n (element: HTMLTableElement): { row: number; column: number; detail: boolean } => {\n const cells = Array.from(gridRows.value(element)[0]?.cells ?? [])\n const column = cells.findIndex((cell) => cell.querySelector('[data-undrawn]') === null)\n return { row: 0, column: Math.max(column, 0), detail: false }\n },\n)\nconst whereIn = computed(\n () =>\n (element: HTMLTableElement): { row: number; column: number; detail: boolean } =>\n placed.value ? at.value : startOf.value(element),\n)\nconst stopAt = computed(\n () =>\n (\n element: HTMLTableElement,\n to: { row: number; column: number; detail: boolean },\n ): HTMLElement | null => {\n const row = gridRows.value(element)[to.row]\n if (to.detail) return detailUnder.value(row)\n const cell = row?.cells[to.column]\n return cell === undefined ? null : stopIn.value(cell)\n },\n)\nconst rove = computed(\n () => (element: HTMLTableElement, to: { row: number; column: number; detail: boolean }) => {\n at.value = to\n for (const [index, row] of gridRows.value(element).entries()) {\n for (const cell of Array.from(row.cells)) {\n const stop = stopIn.value(cell)\n const wanted = !to.detail && index === to.row && cell.cellIndex === to.column ? '0' : '-1'\n if (stop !== cell && cell.getAttribute('tabindex') !== '-1')\n cell.setAttribute('tabindex', '-1')\n if (stop.getAttribute('tabindex') !== wanted) stop.setAttribute('tabindex', wanted)\n }\n const under = detailUnder.value(row)\n const held = to.detail && index === to.row ? '0' : '-1'\n if (under !== null && under.getAttribute('tabindex') !== held)\n under.setAttribute('tabindex', held)\n }\n },\n)\nconst focusIn = computed(() => (event: FocusEvent) => {\n const element = table.value as HTMLTableElement | null\n if (element === null) return\n if (!holds.value) holds.value = true\n const cell = gridCellOf.value(element, event.target)\n if (cell === null) return\n const to = clampCell.value(\n element,\n positionOf.value(element, cell, whereIn.value(element).column),\n )\n if (to === null) return\n placed.value = true\n rove.value(element, to)\n})\nconst focusOut = computed(() => (event: FocusEvent) => {\n const element = table.value as HTMLTableElement | null\n const left = event.target\n queueMicrotask(() => {\n if (\n element !== null &&\n left instanceof Node &&\n left.isConnected &&\n !element.contains(document.activeElement)\n )\n holds.value = false\n })\n})\nconst keyDown = computed(() => (event: KeyboardEvent) => {\n const element = table.value as HTMLTableElement | null\n const target = event.target instanceof HTMLElement ? event.target : null\n if (\n element === null ||\n target === null ||\n target.closest(\n 'input:not([type=\"checkbox\"]):not([type=\"radio\"]), textarea, [contenteditable]',\n ) !== null\n )\n return\n const cell = gridCellOf.value(element, target)\n if (cell === null) return\n const rows = gridRows.value(element)\n const here = positionOf.value(element, cell, whereIn.value(element).column)\n const forward = getComputedStyle(element).direction === 'rtl' ? -1 : 1\n const far = event.ctrlKey || event.metaKey\n const last = Number.MAX_SAFE_INTEGER\n let next: { row: number; column: number; detail: boolean } | null\n if (here.detail) {\n switch (event.key) {\n case 'ArrowDown':\n next = here.row + 1 < rows.length ? { ...here, row: here.row + 1, detail: false } : null\n break\n case 'ArrowUp':\n next = { ...here, detail: false }\n break\n case 'ArrowRight':\n case 'ArrowLeft':\n next = null\n break\n case 'Home':\n next = far ? { row: 0, column: 0, detail: false } : null\n break\n case 'End':\n next = far ? { row: last, column: last, detail: false } : null\n break\n default:\n return\n }\n } else {\n switch (event.key) {\n case 'ArrowRight':\n next = { ...here, column: here.column + forward }\n break\n case 'ArrowLeft':\n next = { ...here, column: here.column - forward }\n break\n case 'ArrowDown':\n next =\n detailUnder.value(rows[here.row]) !== null\n ? { ...here, detail: true }\n : { ...here, row: here.row + 1 }\n break\n case 'ArrowUp':\n next =\n detailUnder.value(rows[here.row - 1]) !== null\n ? { ...here, row: here.row - 1, detail: true }\n : { ...here, row: here.row - 1 }\n break\n case 'Home':\n next = far ? { row: 0, column: 0, detail: false } : { ...here, column: 0 }\n break\n case 'End':\n next = far ? { row: last, column: last, detail: false } : { ...here, column: last }\n break\n default:\n return\n }\n }\n event.preventDefault()\n const to = next === null ? null : clampCell.value(element, next)\n if (to === null) return\n placed.value = true\n rove.value(element, to)\n stopAt.value(element, to)?.focus()\n})\nconst reclamp = computed(() => () => {\n const element = table.value as HTMLTableElement | null\n if (element === null || !props.grid) return\n const to = clampCell.value(element, whereIn.value(element))\n if (to === null) return\n rove.value(element, to)\n const fell = document.activeElement === null || document.activeElement === document.body\n if (holds.value && fell) stopAt.value(element, to)?.focus()\n})\nprovide('polymorph:Table', {\n get grid() {\n return props.grid\n },\n})\nlet release1: (() => void) | undefined\nconst effect1 = () => {\n release1?.()\n const run = () => {\n overflowing.value =\n wrapper.value !== null && wrapper.value.scrollWidth > wrapper.value.clientWidth\n }\n const resize = typeof ResizeObserver === 'undefined' ? undefined : new ResizeObserver(run)\n for (const element of [wrapper.value, wrapper.value?.firstElementChild])\n if (element) resize?.observe(element)\n release1 = () => {\n resize?.disconnect()\n }\n run()\n}\nonMounted(effect1)\nonBeforeUnmount(() => release1?.())\nlet release2: (() => void) | undefined\nconst effect2 = () => {\n release2?.()\n const run = () => {\n reclamp.value()\n }\n const mutation = typeof MutationObserver === 'undefined' ? undefined : new MutationObserver(run)\n for (const element of [table.value])\n if (element)\n mutation?.observe(element, {\n childList: true,\n characterData: true,\n subtree: true,\n attributeFilter: ['disabled'],\n })\n release2 = () => {\n mutation?.disconnect()\n }\n run()\n}\nonMounted(effect2)\nwatch(() => props.grid, effect2, { flush: 'post' })\nonBeforeUnmount(() => release2?.())\nlet release3: (() => void) | undefined\nconst effect3 = () => {\n release3?.()\n const ran =\n wrapper.value?.parentElement?.closest('[data-member]')?.getAttribute('data-member') ===\n 'data-table'\n ? () => {}\n : agentMember({\n member: 'Table',\n element: () => wrapper.value,\n state: () => ({\n 'sort-key': tableSort(table.value).key,\n 'sort-direction': tableSort(table.value).direction,\n columns: tableSortColumns(table.value),\n }),\n actions: { sort: { argument: 'id', run: (value) => pressTableSort(table.value, value) } },\n })\n release3 = () => {\n ran()\n }\n}\nonMounted(effect3)\nonBeforeUnmount(() => release3?.())\n</script>\n\n<template>\n <div\n ref=\"wrapper\"\n :class=\"styles.wrapper\"\n :data-sticky-header=\"stickyHeader ? '' : undefined\"\n :data-overflowing=\"overflowing ? '' : undefined\"\n :tabindex=\"overflowing && !grid ? '0' : undefined\"\n :role=\"overflowing && label !== undefined ? 'region' : undefined\"\n :aria-label=\"overflowing ? label : undefined\"\n data-member=\"table\"\n >\n <!-- table -->\n <table\n ref=\"table\"\n :class=\"styles.table\"\n :role=\"grid ? 'grid' : undefined\"\n :aria-multiselectable=\"grid && multiselectable ? 'true' : undefined\"\n @focusin=\"grid && focusIn($event)\"\n @focusout=\"grid && focusOut($event)\"\n @keydown=\"grid && keyDown($event)\"\n >\n <!-- caption -->\n <caption\n v-if=\"caption !== undefined\"\n :class=\"[\n captionVisible ? styles.caption : undefined,\n !captionVisible ? styles.captionHidden : undefined,\n ]\"\n >\n {{\n caption\n }}\n </caption>\n <slot />\n </table>\n </div>\n</template>\n"],"mappings":""}
|
|
@@ -37,18 +37,18 @@ var x = [
|
|
|
37
37
|
row: 0,
|
|
38
38
|
column: 0,
|
|
39
39
|
detail: !1
|
|
40
|
-
}), E = h(!1), D = y("table"),
|
|
40
|
+
}), E = h(!1), D = h(!1), O = y("table"), k = y("wrapper"), A = a(() => (e) => {
|
|
41
41
|
for (let t of Array.from(e.querySelectorAll("button, a[href], input, select, textarea"))) if (!(t.hasAttribute("disabled") || t.getAttribute("aria-hidden") === "true")) return t;
|
|
42
42
|
return e;
|
|
43
|
-
}),
|
|
43
|
+
}), j = a(() => (e) => Array.from(e.rows).filter((e) => !e.hasAttribute("data-detail"))), M = a(() => (e) => {
|
|
44
44
|
let t = e?.nextElementSibling;
|
|
45
45
|
return t instanceof HTMLTableRowElement && t.hasAttribute("data-detail") ? t.cells[0] ?? null : null;
|
|
46
|
-
}),
|
|
46
|
+
}), N = a(() => (e, t) => {
|
|
47
47
|
let n = t instanceof HTMLElement ? t.closest("th, td") : null;
|
|
48
48
|
for (; n !== null && n.closest("table") !== e;) n = n.parentElement?.closest("th, td") ?? null;
|
|
49
49
|
return n === null || n.parentElement === null || n.parentElement.hasAttribute("data-detail") && n !== t ? null : n;
|
|
50
|
-
}),
|
|
51
|
-
let r = t.parentElement, i =
|
|
50
|
+
}), P = a(() => (e, t, n) => {
|
|
51
|
+
let r = t.parentElement, i = j.value(e);
|
|
52
52
|
return r.hasAttribute("data-detail") ? {
|
|
53
53
|
row: i.indexOf(r.previousElementSibling),
|
|
54
54
|
column: n,
|
|
@@ -58,48 +58,54 @@ var x = [
|
|
|
58
58
|
column: t.cellIndex,
|
|
59
59
|
detail: !1
|
|
60
60
|
};
|
|
61
|
-
}),
|
|
62
|
-
let n =
|
|
61
|
+
}), F = a(() => (e, t) => {
|
|
62
|
+
let n = j.value(e), r = Math.min(Math.max(t.row, 0), n.length - 1), i = n[r]?.cells;
|
|
63
63
|
return i === void 0 || i.length === 0 ? null : {
|
|
64
64
|
row: r,
|
|
65
65
|
column: Math.min(Math.max(t.column, 0), i.length - 1),
|
|
66
|
-
detail: t.detail && r === t.row &&
|
|
66
|
+
detail: t.detail && r === t.row && M.value(n[r]) !== null
|
|
67
67
|
};
|
|
68
|
-
}),
|
|
69
|
-
let t = Array.from(
|
|
68
|
+
}), I = a(() => (e) => {
|
|
69
|
+
let t = Array.from(j.value(e)[0]?.cells ?? []).findIndex((e) => e.querySelector("[data-undrawn]") === null);
|
|
70
70
|
return {
|
|
71
71
|
row: 0,
|
|
72
72
|
column: Math.max(t, 0),
|
|
73
73
|
detail: !1
|
|
74
74
|
};
|
|
75
|
-
}),
|
|
76
|
-
let n =
|
|
77
|
-
if (t.detail) return
|
|
75
|
+
}), L = a(() => (e) => E.value ? T.value : I.value(e)), R = a(() => (e, t) => {
|
|
76
|
+
let n = j.value(e)[t.row];
|
|
77
|
+
if (t.detail) return M.value(n);
|
|
78
78
|
let r = n?.cells[t.column];
|
|
79
|
-
return r === void 0 ? null :
|
|
80
|
-
}),
|
|
79
|
+
return r === void 0 ? null : A.value(r);
|
|
80
|
+
}), z = a(() => (e, t) => {
|
|
81
81
|
T.value = t;
|
|
82
|
-
for (let [n, r] of
|
|
82
|
+
for (let [n, r] of j.value(e).entries()) {
|
|
83
83
|
for (let e of Array.from(r.cells)) {
|
|
84
|
-
let r =
|
|
84
|
+
let r = A.value(e), i = !t.detail && n === t.row && e.cellIndex === t.column ? "0" : "-1";
|
|
85
85
|
r !== e && e.getAttribute("tabindex") !== "-1" && e.setAttribute("tabindex", "-1"), r.getAttribute("tabindex") !== i && r.setAttribute("tabindex", i);
|
|
86
86
|
}
|
|
87
|
-
let e =
|
|
87
|
+
let e = M.value(r), i = t.detail && n === t.row ? "0" : "-1";
|
|
88
88
|
e !== null && e.getAttribute("tabindex") !== i && e.setAttribute("tabindex", i);
|
|
89
89
|
}
|
|
90
|
-
}),
|
|
91
|
-
let t =
|
|
90
|
+
}), B = a(() => (e) => {
|
|
91
|
+
let t = O.value;
|
|
92
92
|
if (t === null) return;
|
|
93
|
-
|
|
93
|
+
D.value ||= !0;
|
|
94
|
+
let n = N.value(t, e.target);
|
|
94
95
|
if (n === null) return;
|
|
95
|
-
let r =
|
|
96
|
-
r !== null && (E.value = !0,
|
|
97
|
-
}),
|
|
98
|
-
let t =
|
|
96
|
+
let r = F.value(t, P.value(t, n, L.value(t).column));
|
|
97
|
+
r !== null && (E.value = !0, z.value(t, r));
|
|
98
|
+
}), V = a(() => (e) => {
|
|
99
|
+
let t = O.value, n = e.target;
|
|
100
|
+
queueMicrotask(() => {
|
|
101
|
+
t !== null && n instanceof Node && n.isConnected && !t.contains(document.activeElement) && (D.value = !1);
|
|
102
|
+
});
|
|
103
|
+
}), H = a(() => (e) => {
|
|
104
|
+
let t = O.value, n = e.target instanceof HTMLElement ? e.target : null;
|
|
99
105
|
if (t === null || n === null || n.closest("input:not([type=\"checkbox\"]):not([type=\"radio\"]), textarea, [contenteditable]") !== null) return;
|
|
100
|
-
let r =
|
|
106
|
+
let r = N.value(t, n);
|
|
101
107
|
if (r === null) return;
|
|
102
|
-
let i =
|
|
108
|
+
let i = j.value(t), a = P.value(t, r, L.value(t).column), o = getComputedStyle(t).direction === "rtl" ? -1 : 1, s = e.ctrlKey || e.metaKey, c = 2 ** 53 - 1, l;
|
|
103
109
|
if (a.detail) switch (e.key) {
|
|
104
110
|
case "ArrowDown":
|
|
105
111
|
l = a.row + 1 < i.length ? {
|
|
@@ -148,7 +154,7 @@ var x = [
|
|
|
148
154
|
};
|
|
149
155
|
break;
|
|
150
156
|
case "ArrowDown":
|
|
151
|
-
l =
|
|
157
|
+
l = M.value(i[a.row]) === null ? {
|
|
152
158
|
...a,
|
|
153
159
|
row: a.row + 1
|
|
154
160
|
} : {
|
|
@@ -157,7 +163,7 @@ var x = [
|
|
|
157
163
|
};
|
|
158
164
|
break;
|
|
159
165
|
case "ArrowUp":
|
|
160
|
-
l =
|
|
166
|
+
l = M.value(i[a.row - 1]) === null ? {
|
|
161
167
|
...a,
|
|
162
168
|
row: a.row - 1
|
|
163
169
|
} : {
|
|
@@ -189,66 +195,69 @@ var x = [
|
|
|
189
195
|
default: return;
|
|
190
196
|
}
|
|
191
197
|
e.preventDefault();
|
|
192
|
-
let u = l === null ? null :
|
|
193
|
-
u !== null && (E.value = !0,
|
|
194
|
-
}),
|
|
195
|
-
let e =
|
|
198
|
+
let u = l === null ? null : F.value(t, l);
|
|
199
|
+
u !== null && (E.value = !0, z.value(t, u), R.value(t, u)?.focus());
|
|
200
|
+
}), U = a(() => () => {
|
|
201
|
+
let e = O.value;
|
|
196
202
|
if (e === null || !C.grid) return;
|
|
197
|
-
let t =
|
|
198
|
-
t
|
|
203
|
+
let t = F.value(e, L.value(e));
|
|
204
|
+
if (t === null) return;
|
|
205
|
+
z.value(e, t);
|
|
206
|
+
let n = document.activeElement === null || document.activeElement === document.body;
|
|
207
|
+
D.value && n && R.value(e, t)?.focus();
|
|
199
208
|
});
|
|
200
209
|
m("polymorph:Table", { get grid() {
|
|
201
210
|
return C.grid;
|
|
202
211
|
} });
|
|
203
|
-
let
|
|
212
|
+
let W;
|
|
204
213
|
f(() => {
|
|
205
|
-
|
|
214
|
+
W?.();
|
|
206
215
|
let e = () => {
|
|
207
|
-
w.value =
|
|
216
|
+
w.value = k.value !== null && k.value.scrollWidth > k.value.clientWidth;
|
|
208
217
|
}, t = typeof ResizeObserver > "u" ? void 0 : new ResizeObserver(e);
|
|
209
|
-
for (let e of [
|
|
210
|
-
|
|
218
|
+
for (let e of [k.value, k.value?.firstElementChild]) e && t?.observe(e);
|
|
219
|
+
W = () => {
|
|
211
220
|
t?.disconnect();
|
|
212
221
|
}, e();
|
|
213
|
-
}), d(() =>
|
|
214
|
-
let
|
|
215
|
-
|
|
222
|
+
}), d(() => W?.());
|
|
223
|
+
let G, K = () => {
|
|
224
|
+
G?.();
|
|
216
225
|
let e = () => {
|
|
217
|
-
|
|
226
|
+
U.value();
|
|
218
227
|
}, t = typeof MutationObserver > "u" ? void 0 : new MutationObserver(e);
|
|
219
|
-
for (let e of [
|
|
228
|
+
for (let e of [O.value]) e && t?.observe(e, {
|
|
220
229
|
childList: !0,
|
|
221
230
|
characterData: !0,
|
|
222
231
|
subtree: !0,
|
|
223
232
|
attributeFilter: ["disabled"]
|
|
224
233
|
});
|
|
225
|
-
|
|
234
|
+
G = () => {
|
|
226
235
|
t?.disconnect();
|
|
227
236
|
}, e();
|
|
228
237
|
};
|
|
229
|
-
f(
|
|
230
|
-
let
|
|
238
|
+
f(K), b(() => C.grid, K, { flush: "post" }), d(() => G?.());
|
|
239
|
+
let q;
|
|
231
240
|
return f(() => {
|
|
232
|
-
|
|
233
|
-
let e =
|
|
241
|
+
q?.();
|
|
242
|
+
let e = k.value?.parentElement?.closest("[data-member]")?.getAttribute("data-member") === "data-table" ? () => {} : t({
|
|
234
243
|
member: "Table",
|
|
235
|
-
element: () =>
|
|
244
|
+
element: () => k.value,
|
|
236
245
|
state: () => ({
|
|
237
|
-
"sort-key": r(
|
|
238
|
-
"sort-direction": r(
|
|
239
|
-
columns: i(
|
|
246
|
+
"sort-key": r(O.value).key,
|
|
247
|
+
"sort-direction": r(O.value).direction,
|
|
248
|
+
columns: i(O.value)
|
|
240
249
|
}),
|
|
241
250
|
actions: { sort: {
|
|
242
251
|
argument: "id",
|
|
243
|
-
run: (e) => n(
|
|
252
|
+
run: (e) => n(O.value, e)
|
|
244
253
|
} }
|
|
245
254
|
});
|
|
246
|
-
|
|
255
|
+
q = () => {
|
|
247
256
|
e();
|
|
248
257
|
};
|
|
249
|
-
}), d(() =>
|
|
258
|
+
}), d(() => q?.()), (t, n) => (p(), s("div", {
|
|
250
259
|
ref_key: "wrapper",
|
|
251
|
-
ref:
|
|
260
|
+
ref: k,
|
|
252
261
|
class: u(v(e).wrapper),
|
|
253
262
|
"data-sticky-header": l.stickyHeader ? "" : void 0,
|
|
254
263
|
"data-overflowing": w.value ? "" : void 0,
|
|
@@ -258,12 +267,13 @@ var x = [
|
|
|
258
267
|
"data-member": "table"
|
|
259
268
|
}, [c("table", {
|
|
260
269
|
ref_key: "table",
|
|
261
|
-
ref:
|
|
270
|
+
ref: O,
|
|
262
271
|
class: u(v(e).table),
|
|
263
272
|
role: l.grid ? "grid" : void 0,
|
|
264
273
|
"aria-multiselectable": l.grid && l.multiselectable ? "true" : void 0,
|
|
265
|
-
onFocusin: n[0] ||= (e) => l.grid &&
|
|
266
|
-
|
|
274
|
+
onFocusin: n[0] ||= (e) => l.grid && B.value(e),
|
|
275
|
+
onFocusout: n[1] ||= (e) => l.grid && V.value(e),
|
|
276
|
+
onKeydown: n[2] ||= (e) => l.grid && H.value(e)
|
|
267
277
|
}, [l.caption === void 0 ? o("", !0) : (p(), s("caption", {
|
|
268
278
|
key: 0,
|
|
269
279
|
class: u([l.captionVisible ? v(e).caption : void 0, l.captionVisible ? void 0 : v(e).captionHidden])
|