@threadlabs/looma 0.19.1 → 0.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/shared/trigger.js +9 -4
- package/components/ui-affordance-scope/ui-affordance-scope.html +1 -1
- package/components/ui-avatar/ui-avatar.html +2 -2
- package/components/ui-avatar-group/ui-avatar-group.html +1 -1
- package/components/ui-avatar-group/ui-avatar-group.js +1 -1
- package/components/ui-badge/ui-badge.html +3 -3
- package/components/ui-button/ui-button.html +7 -6
- package/components/ui-callout/ui-callout.html +1 -1
- package/components/ui-card/ui-card.html +5 -4
- package/components/ui-checkbox/ui-checkbox.html +6 -2
- package/components/ui-cluster/ui-cluster.html +4 -4
- package/components/ui-combobox/ui-combobox.html +257 -34
- package/components/ui-combobox/ui-combobox.js +21 -20
- package/components/ui-container/ui-container.html +2 -2
- package/components/ui-context-menu/ui-context-menu.html +17 -5
- package/components/ui-cover/ui-cover.html +1 -1
- package/components/ui-description-list/ui-description-list.html +3 -3
- package/components/ui-dialog/ui-dialog.html +14 -6
- package/components/ui-disclosure/ui-disclosure.html +14 -5
- package/components/ui-editable/ui-editable.html +15 -4
- package/components/ui-editor-mention-menu/ui-editor-mention-menu.html +1 -1
- package/components/ui-editor-slash-menu/ui-editor-slash-menu.html +1 -1
- package/components/ui-editor-table-context-menu/ui-editor-table-context-menu.html +26 -6
- package/components/ui-editor-table-overlay/ui-editor-table-overlay.html +90 -12
- package/components/ui-editor-table-overlay/ui-editor-table-overlay.js +5 -5
- package/components/ui-editor-table-toolbar/ui-editor-table-toolbar.html +33 -7
- package/components/ui-grid/ui-grid.html +2 -2
- package/components/ui-icon-button/ui-icon-button.html +2 -2
- package/components/ui-input/ui-input.html +28 -6
- package/components/ui-list/ui-list.html +5 -4
- package/components/ui-list-item/ui-list-item.html +1 -1
- package/components/ui-listbox/ui-listbox.html +7 -1
- package/components/ui-menu/ui-menu.html +18 -5
- package/components/ui-menu-item/ui-menu-item.html +7 -2
- package/components/ui-meter/ui-meter.html +2 -2
- package/components/ui-nav-item/ui-nav-item.html +5 -4
- package/components/ui-page-header/ui-page-header.html +1 -1
- package/components/ui-popover/ui-popover.html +14 -5
- package/components/ui-radio/ui-radio.html +6 -2
- package/components/ui-radio-group/ui-radio-group.html +11 -3
- package/components/ui-reel/ui-reel.html +3 -3
- package/components/ui-scroll-area/ui-scroll-area.html +1 -1
- package/components/ui-search-shell/ui-search-shell.html +6 -2
- package/components/ui-section/ui-section.html +2 -2
- package/components/ui-select/ui-select.html +1 -1
- package/components/ui-separator/ui-separator.html +1 -1
- package/components/ui-sidebar/ui-sidebar.html +11 -4
- package/components/ui-spinner/ui-spinner.html +1 -1
- package/components/ui-stack/ui-stack.html +3 -3
- package/components/ui-status-message/ui-status-message.html +2 -2
- package/components/ui-switch/ui-switch.html +6 -2
- package/components/ui-switcher/ui-switcher.html +3 -3
- package/components/ui-table/ui-table.html +1 -1
- package/components/ui-tabs/ui-tabs.html +9 -4
- package/components/ui-text/ui-text.html +6 -6
- package/components/ui-textarea/ui-textarea.html +1 -1
- package/components/ui-toast/ui-toast.html +6 -2
- package/components/ui-toast-region/ui-toast-region.html +16 -4
- package/components/ui-tooltip/ui-tooltip.html +15 -6
- package/components/ui-tree/ui-tree.html +30 -7
- package/components/ui-tree-item/ui-tree-item.html +5 -1
- package/dist/index.js +1 -1
- package/editor/table-overlay.d.ts +1 -1
- package/package.json +3 -3
- package/styles/ui-action-bar.css +1 -1
- package/styles/ui-affordance-scope.css +1 -1
- package/styles/ui-avatar-group.css +1 -1
- package/styles/ui-avatar.css +1 -1
- package/styles/ui-badge.css +1 -1
- package/styles/ui-breadcrumb-item.css +1 -1
- package/styles/ui-breadcrumbs.css +1 -1
- package/styles/ui-button.css +1 -1
- package/styles/ui-callout.css +1 -1
- package/styles/ui-card.css +1 -1
- package/styles/ui-checkbox.css +1 -1
- package/styles/ui-cluster.css +1 -1
- package/styles/ui-combobox.css +1 -1
- package/styles/ui-container.css +1 -1
- package/styles/ui-context-menu.css +1 -1
- package/styles/ui-cover.css +1 -1
- package/styles/ui-description-item.css +1 -1
- package/styles/ui-description-list.css +1 -1
- package/styles/ui-dialog.css +1 -1
- package/styles/ui-disclosure.css +1 -1
- package/styles/ui-editable.css +1 -1
- package/styles/ui-editor-insert-table-grid.css +1 -1
- package/styles/ui-editor-mention-menu-item.css +1 -1
- package/styles/ui-editor-mention-menu.css +1 -1
- package/styles/ui-editor-slash-menu-group.css +1 -1
- package/styles/ui-editor-slash-menu-item.css +1 -1
- package/styles/ui-editor-slash-menu.css +1 -1
- package/styles/ui-editor-table-context-menu.css +1 -1
- package/styles/ui-editor-table-overlay.css +1 -1
- package/styles/ui-editor-table-toolbar.css +1 -1
- package/styles/ui-editor-toolbar.css +1 -1
- package/styles/ui-floating-action-button.css +1 -1
- package/styles/ui-form-field.css +1 -1
- package/styles/ui-grid.css +1 -1
- package/styles/ui-icon-button.css +1 -1
- package/styles/ui-icon.css +1 -1
- package/styles/ui-input-group.css +1 -1
- package/styles/ui-input.css +1 -1
- package/styles/ui-list-item.css +1 -1
- package/styles/ui-list.css +1 -1
- package/styles/ui-listbox.css +1 -1
- package/styles/ui-menu-group.css +1 -1
- package/styles/ui-menu-item.css +1 -1
- package/styles/ui-menu.css +1 -1
- package/styles/ui-meter.css +1 -1
- package/styles/ui-nav-item.css +1 -1
- package/styles/ui-page-header.css +1 -1
- package/styles/ui-popover.css +1 -1
- package/styles/ui-radio-group.css +1 -1
- package/styles/ui-radio.css +1 -1
- package/styles/ui-reel.css +1 -1
- package/styles/ui-scroll-area.css +1 -1
- package/styles/ui-search-result-row.css +1 -1
- package/styles/ui-search-shell.css +1 -1
- package/styles/ui-section.css +1 -1
- package/styles/ui-select.css +1 -1
- package/styles/ui-separator.css +1 -1
- package/styles/ui-sidebar.css +1 -1
- package/styles/ui-spinner.css +1 -1
- package/styles/ui-stack.css +1 -1
- package/styles/ui-status-message.css +1 -1
- package/styles/ui-switch.css +1 -1
- package/styles/ui-switcher.css +1 -1
- package/styles/ui-table.css +1 -1
- package/styles/ui-tabs.css +1 -1
- package/styles/ui-text.css +1 -1
- package/styles/ui-textarea.css +1 -1
- package/styles/ui-toast-region.css +1 -1
- package/styles/ui-toast.css +1 -1
- package/styles/ui-tooltip.css +1 -1
- package/styles/ui-top-bar.css +1 -1
- package/styles/ui-tree-item.css +1 -1
- package/styles/ui-tree.css +1 -1
- package/vanilla/UiActionBar.d.ts +1 -1
- package/vanilla/UiActionBar.js +5 -1
- package/vanilla/UiAffordanceScope.d.ts +1 -1
- package/vanilla/UiAffordanceScope.js +3 -2
- package/vanilla/UiAvatar.d.ts +1 -1
- package/vanilla/UiAvatar.js +4 -3
- package/vanilla/UiAvatarGroup.d.ts +1 -1
- package/vanilla/UiAvatarGroup.js +3 -2
- package/vanilla/UiBadge.d.ts +1 -1
- package/vanilla/UiBadge.js +2 -1
- package/vanilla/UiBreadcrumbItem.d.ts +1 -1
- package/vanilla/UiBreadcrumbItem.js +2 -1
- package/vanilla/UiBreadcrumbs.d.ts +1 -1
- package/vanilla/UiBreadcrumbs.js +4 -7
- package/vanilla/UiButton.d.ts +1 -1
- package/vanilla/UiButton.js +6 -4
- package/vanilla/UiCallout.d.ts +1 -1
- package/vanilla/UiCallout.js +3 -2
- package/vanilla/UiCard.d.ts +1 -1
- package/vanilla/UiCard.js +6 -2
- package/vanilla/UiCheckbox.d.ts +1 -1
- package/vanilla/UiCheckbox.js +4 -2
- package/vanilla/UiCluster.d.ts +1 -1
- package/vanilla/UiCluster.js +2 -1
- package/vanilla/UiCombobox.d.ts +3 -2
- package/vanilla/UiCombobox.js +8 -2
- package/vanilla/UiContainer.d.ts +1 -1
- package/vanilla/UiContainer.js +2 -1
- package/vanilla/UiContextMenu.d.ts +1 -1
- package/vanilla/UiContextMenu.js +3 -2
- package/vanilla/UiCover.d.ts +1 -1
- package/vanilla/UiCover.js +4 -5
- package/vanilla/UiDescriptionItem.d.ts +1 -1
- package/vanilla/UiDescriptionItem.js +4 -7
- package/vanilla/UiDescriptionList.d.ts +1 -1
- package/vanilla/UiDescriptionList.js +2 -1
- package/vanilla/UiDialog.d.ts +1 -1
- package/vanilla/UiDialog.js +4 -2
- package/vanilla/UiDisclosure.d.ts +1 -1
- package/vanilla/UiDisclosure.js +4 -2
- package/vanilla/UiEditable.d.ts +1 -1
- package/vanilla/UiEditable.js +2 -2
- package/vanilla/UiEditorInsertTableGrid.d.ts +1 -1
- package/vanilla/UiEditorInsertTableGrid.js +1 -1
- package/vanilla/UiEditorMentionMenu.d.ts +1 -1
- package/vanilla/UiEditorMentionMenu.js +5 -2
- package/vanilla/UiEditorMentionMenuItem.d.ts +1 -1
- package/vanilla/UiEditorMentionMenuItem.js +3 -1
- package/vanilla/UiEditorSlashMenu.d.ts +1 -1
- package/vanilla/UiEditorSlashMenu.js +6 -2
- package/vanilla/UiEditorSlashMenuGroup.d.ts +1 -1
- package/vanilla/UiEditorSlashMenuGroup.js +4 -7
- package/vanilla/UiEditorSlashMenuItem.d.ts +1 -1
- package/vanilla/UiEditorSlashMenuItem.js +2 -1
- package/vanilla/UiEditorTableContextMenu.d.ts +1 -1
- package/vanilla/UiEditorTableContextMenu.js +2 -2
- package/vanilla/UiEditorTableOverlay.d.ts +12 -2
- package/vanilla/UiEditorTableOverlay.js +2 -2
- package/vanilla/UiEditorTableToolbar.d.ts +1 -1
- package/vanilla/UiEditorTableToolbar.js +2 -2
- package/vanilla/UiEditorToolbar.d.ts +1 -1
- package/vanilla/UiEditorToolbar.js +2 -1
- package/vanilla/UiFloatingActionButton.d.ts +1 -1
- package/vanilla/UiFloatingActionButton.js +2 -1
- package/vanilla/UiFormField.d.ts +1 -1
- package/vanilla/UiFormField.js +6 -1
- package/vanilla/UiGrid.d.ts +1 -1
- package/vanilla/UiGrid.js +4 -3
- package/vanilla/UiIcon.d.ts +1 -1
- package/vanilla/UiIcon.js +1 -1
- package/vanilla/UiIconButton.d.ts +1 -1
- package/vanilla/UiIconButton.js +4 -3
- package/vanilla/UiInput.d.ts +5 -4
- package/vanilla/UiInput.js +16 -13
- package/vanilla/UiInputGroup.d.ts +1 -1
- package/vanilla/UiInputGroup.js +5 -1
- package/vanilla/UiList.d.ts +1 -1
- package/vanilla/UiList.js +4 -2
- package/vanilla/UiListItem.d.ts +1 -1
- package/vanilla/UiListItem.js +5 -1
- package/vanilla/UiListbox.d.ts +1 -1
- package/vanilla/UiListbox.js +3 -2
- package/vanilla/UiMenu.d.ts +1 -1
- package/vanilla/UiMenu.js +3 -2
- package/vanilla/UiMenuGroup.d.ts +1 -1
- package/vanilla/UiMenuGroup.js +2 -1
- package/vanilla/UiMenuItem.d.ts +1 -1
- package/vanilla/UiMenuItem.js +6 -2
- package/vanilla/UiMeter.d.ts +1 -1
- package/vanilla/UiMeter.js +2 -2
- package/vanilla/UiNavItem.d.ts +2 -2
- package/vanilla/UiNavItem.js +11 -5
- package/vanilla/UiPageHeader.d.ts +1 -1
- package/vanilla/UiPageHeader.js +8 -5
- package/vanilla/UiPopover.d.ts +1 -1
- package/vanilla/UiPopover.js +3 -2
- package/vanilla/UiRadio.d.ts +1 -1
- package/vanilla/UiRadio.js +4 -2
- package/vanilla/UiRadioGroup.d.ts +1 -1
- package/vanilla/UiRadioGroup.js +3 -2
- package/vanilla/UiReel.d.ts +1 -1
- package/vanilla/UiReel.js +2 -1
- package/vanilla/UiScrollArea.d.ts +1 -1
- package/vanilla/UiScrollArea.js +3 -2
- package/vanilla/UiSearchResultRow.d.ts +1 -1
- package/vanilla/UiSearchResultRow.js +6 -1
- package/vanilla/UiSearchShell.d.ts +1 -1
- package/vanilla/UiSearchShell.js +6 -2
- package/vanilla/UiSection.d.ts +1 -1
- package/vanilla/UiSection.js +5 -2
- package/vanilla/UiSelect.d.ts +1 -1
- package/vanilla/UiSelect.js +3 -2
- package/vanilla/UiSeparator.d.ts +1 -1
- package/vanilla/UiSeparator.js +3 -7
- package/vanilla/UiSidebar.d.ts +1 -1
- package/vanilla/UiSidebar.js +3 -2
- package/vanilla/UiSpinner.d.ts +1 -1
- package/vanilla/UiSpinner.js +2 -2
- package/vanilla/UiStack.d.ts +1 -1
- package/vanilla/UiStack.js +2 -1
- package/vanilla/UiStatusMessage.d.ts +1 -1
- package/vanilla/UiStatusMessage.js +4 -2
- package/vanilla/UiSwitch.d.ts +1 -1
- package/vanilla/UiSwitch.js +4 -2
- package/vanilla/UiSwitcher.d.ts +1 -1
- package/vanilla/UiSwitcher.js +3 -2
- package/vanilla/UiTable.d.ts +1 -1
- package/vanilla/UiTable.js +3 -2
- package/vanilla/UiTabs.d.ts +1 -1
- package/vanilla/UiTabs.js +4 -2
- package/vanilla/UiText.d.ts +1 -1
- package/vanilla/UiText.js +13 -2
- package/vanilla/UiTextarea.d.ts +1 -1
- package/vanilla/UiTextarea.js +3 -3
- package/vanilla/UiToast.d.ts +1 -1
- package/vanilla/UiToast.js +4 -2
- package/vanilla/UiToastRegion.d.ts +1 -1
- package/vanilla/UiToastRegion.js +3 -2
- package/vanilla/UiTooltip.d.ts +1 -1
- package/vanilla/UiTooltip.js +3 -2
- package/vanilla/UiTopBar.d.ts +1 -1
- package/vanilla/UiTopBar.js +5 -1
- package/vanilla/UiTree.d.ts +1 -1
- package/vanilla/UiTree.js +3 -2
- package/vanilla/UiTreeItem.d.ts +1 -1
- package/vanilla/UiTreeItem.js +8 -4
- package/vue/UiActionBar.vue +33 -2
- package/vue/UiAffordanceScope.d.ts +23 -8
- package/vue/UiAffordanceScope.vue +90 -17
- package/vue/UiAvatar.d.ts +77 -19
- package/vue/UiAvatar.vue +151 -31
- package/vue/UiAvatarGroup.d.ts +50 -13
- package/vue/UiAvatarGroup.vue +121 -23
- package/vue/UiBadge.d.ts +32 -10
- package/vue/UiBadge.vue +104 -17
- package/vue/UiBreadcrumbItem.d.ts +14 -6
- package/vue/UiBreadcrumbItem.vue +82 -15
- package/vue/UiBreadcrumbs.d.ts +14 -6
- package/vue/UiBreadcrumbs.vue +78 -10
- package/vue/UiButton.d.ts +122 -27
- package/vue/UiButton.vue +288 -64
- package/vue/UiCallout.d.ts +14 -6
- package/vue/UiCallout.vue +84 -16
- package/vue/UiCard.d.ts +41 -12
- package/vue/UiCard.vue +149 -25
- package/vue/UiCheckbox.d.ts +85 -28
- package/vue/UiCheckbox.vue +173 -43
- package/vue/UiCluster.d.ts +41 -7
- package/vue/UiCluster.vue +122 -13
- package/vue/UiCombobox.d.ts +303 -110
- package/vue/UiCombobox.vue +723 -412
- package/vue/UiContainer.d.ts +23 -5
- package/vue/UiContainer.vue +89 -9
- package/vue/UiContextMenu.d.ts +38 -23
- package/vue/UiContextMenu.vue +113 -38
- package/vue/UiCover.d.ts +14 -6
- package/vue/UiCover.vue +76 -12
- package/vue/UiDescriptionItem.d.ts +14 -6
- package/vue/UiDescriptionItem.vue +78 -11
- package/vue/UiDescriptionList.d.ts +32 -9
- package/vue/UiDescriptionList.vue +106 -16
- package/vue/UiDialog.d.ts +89 -30
- package/vue/UiDialog.vue +168 -38
- package/vue/UiDisclosure.d.ts +70 -27
- package/vue/UiDisclosure.vue +149 -36
- package/vue/UiEditable.d.ts +119 -41
- package/vue/UiEditable.vue +220 -62
- package/vue/UiEditorInsertTableGrid.d.ts +46 -17
- package/vue/UiEditorInsertTableGrid.vue +215 -40
- package/vue/UiEditorMentionMenu.d.ts +128 -41
- package/vue/UiEditorMentionMenu.vue +211 -37
- package/vue/UiEditorMentionMenuItem.d.ts +32 -10
- package/vue/UiEditorMentionMenuItem.vue +98 -17
- package/vue/UiEditorSlashMenu.d.ts +110 -37
- package/vue/UiEditorSlashMenu.vue +189 -31
- package/vue/UiEditorSlashMenuGroup.d.ts +14 -6
- package/vue/UiEditorSlashMenuGroup.vue +80 -12
- package/vue/UiEditorSlashMenuItem.d.ts +50 -14
- package/vue/UiEditorSlashMenuItem.vue +120 -23
- package/vue/UiEditorTableContextMenu.d.ts +64 -20
- package/vue/UiEditorTableContextMenu.vue +326 -91
- package/vue/UiEditorTableOverlay.d.ts +170 -44
- package/vue/UiEditorTableOverlay.vue +420 -149
- package/vue/UiEditorTableToolbar.d.ts +64 -20
- package/vue/UiEditorTableToolbar.vue +344 -107
- package/vue/UiEditorToolbar.d.ts +14 -6
- package/vue/UiEditorToolbar.vue +79 -15
- package/vue/UiFloatingActionButton.d.ts +32 -10
- package/vue/UiFloatingActionButton.vue +96 -18
- package/vue/UiFormField.d.ts +32 -10
- package/vue/UiFormField.vue +99 -19
- package/vue/UiGrid.d.ts +32 -6
- package/vue/UiGrid.vue +95 -11
- package/vue/UiIcon.d.ts +14 -6
- package/vue/UiIcon.vue +99 -14
- package/vue/UiIconButton.d.ts +77 -19
- package/vue/UiIconButton.vue +176 -39
- package/vue/UiInput.d.ts +50 -19
- package/vue/UiInput.vue +326 -33
- package/vue/UiInputGroup.d.ts +14 -6
- package/vue/UiInputGroup.vue +79 -15
- package/vue/UiList.d.ts +41 -12
- package/vue/UiList.vue +125 -22
- package/vue/UiListItem.d.ts +23 -8
- package/vue/UiListItem.vue +88 -16
- package/vue/UiListbox.d.ts +86 -27
- package/vue/UiListbox.vue +272 -64
- package/vue/UiMenu.d.ts +69 -33
- package/vue/UiMenu.vue +142 -38
- package/vue/UiMenuGroup.d.ts +14 -6
- package/vue/UiMenuGroup.vue +80 -11
- package/vue/UiMenuItem.d.ts +61 -25
- package/vue/UiMenuItem.vue +174 -45
- package/vue/UiMeter.d.ts +68 -18
- package/vue/UiMeter.vue +215 -41
- package/vue/UiNavItem.d.ts +50 -11
- package/vue/UiNavItem.vue +163 -29
- package/vue/UiPageHeader.d.ts +14 -6
- package/vue/UiPageHeader.vue +75 -12
- package/vue/UiPopover.d.ts +43 -21
- package/vue/UiPopover.vue +147 -27
- package/vue/UiRadio.d.ts +67 -24
- package/vue/UiRadio.vue +147 -36
- package/vue/UiRadioGroup.d.ts +79 -29
- package/vue/UiRadioGroup.vue +162 -41
- package/vue/UiReel.d.ts +32 -6
- package/vue/UiReel.vue +97 -11
- package/vue/UiScrollArea.d.ts +14 -6
- package/vue/UiScrollArea.vue +83 -14
- package/vue/UiSearchResultRow.d.ts +23 -8
- package/vue/UiSearchResultRow.vue +86 -16
- package/vue/UiSearchShell.d.ts +48 -19
- package/vue/UiSearchShell.vue +120 -26
- package/vue/UiSection.d.ts +32 -10
- package/vue/UiSection.vue +103 -17
- package/vue/UiSelect.d.ts +59 -17
- package/vue/UiSelect.vue +140 -29
- package/vue/UiSeparator.d.ts +14 -6
- package/vue/UiSeparator.vue +80 -9
- package/vue/UiSidebar.d.ts +95 -31
- package/vue/UiSidebar.vue +172 -39
- package/vue/UiSpinner.d.ts +23 -8
- package/vue/UiSpinner.vue +115 -24
- package/vue/UiStack.d.ts +32 -6
- package/vue/UiStack.vue +107 -11
- package/vue/UiStatusMessage.d.ts +32 -10
- package/vue/UiStatusMessage.vue +109 -19
- package/vue/UiSwitch.d.ts +67 -24
- package/vue/UiSwitch.vue +147 -36
- package/vue/UiSwitcher.d.ts +41 -7
- package/vue/UiSwitcher.vue +118 -15
- package/vue/UiTable.d.ts +23 -8
- package/vue/UiTable.vue +91 -17
- package/vue/UiTabs.d.ts +66 -23
- package/vue/UiTabs.vue +230 -44
- package/vue/UiText.d.ts +68 -18
- package/vue/UiText.vue +308 -48
- package/vue/UiTextarea.d.ts +84 -21
- package/vue/UiTextarea.vue +172 -38
- package/vue/UiToast.d.ts +28 -13
- package/vue/UiToast.vue +103 -24
- package/vue/UiToastRegion.d.ts +29 -14
- package/vue/UiToastRegion.vue +202 -47
- package/vue/UiTooltip.d.ts +81 -31
- package/vue/UiTooltip.vue +192 -37
- package/vue/UiTopBar.vue +33 -2
- package/vue/UiTree.d.ts +72 -29
- package/vue/UiTree.vue +170 -49
- package/vue/UiTreeItem.d.ts +136 -35
- package/vue/UiTreeItem.vue +227 -61
- package/vue/chunks/UiActionBar.js +16 -3
- package/vue/chunks/UiAffordanceScope.js +66 -11
- package/vue/chunks/UiAvatar.js +121 -20
- package/vue/chunks/UiAvatarGroup.js +94 -15
- package/vue/chunks/UiBadge.js +82 -10
- package/vue/chunks/UiBreadcrumbItem.js +43 -9
- package/vue/chunks/UiBreadcrumbs.js +41 -5
- package/vue/chunks/UiButton.js +237 -51
- package/vue/chunks/UiCallout.js +53 -11
- package/vue/chunks/UiCard.js +145 -18
- package/vue/chunks/UiCheckbox.js +130 -30
- package/vue/chunks/UiCluster.js +99 -12
- package/vue/chunks/UiCombobox.js +545 -162
- package/vue/chunks/UiContainer.js +65 -7
- package/vue/chunks/UiContextMenu.js +56 -11
- package/vue/chunks/UiCover.js +41 -6
- package/vue/chunks/UiDescriptionItem.js +39 -4
- package/vue/chunks/UiDescriptionList.js +80 -10
- package/vue/chunks/UiDialog.js +125 -18
- package/vue/chunks/UiDisclosure.js +102 -17
- package/vue/chunks/UiEditable.js +154 -29
- package/vue/chunks/UiEditorInsertTableGrid.js +154 -31
- package/vue/chunks/UiEditorMentionMenu.js +221 -18
- package/vue/chunks/UiEditorMentionMenuItem.js +64 -7
- package/vue/chunks/UiEditorSlashMenu.js +201 -14
- package/vue/chunks/UiEditorSlashMenuGroup.js +43 -9
- package/vue/chunks/UiEditorSlashMenuItem.js +80 -14
- package/vue/chunks/UiEditorTableContextMenu.js +220 -49
- package/vue/chunks/UiEditorTableOverlay.js +390 -85
- package/vue/chunks/UiEditorTableToolbar.js +248 -71
- package/vue/chunks/UiEditorToolbar.js +44 -10
- package/vue/chunks/UiFloatingActionButton.js +57 -9
- package/vue/chunks/UiFormField.js +63 -12
- package/vue/chunks/UiGrid.js +80 -9
- package/vue/chunks/UiIcon.js +73 -16
- package/vue/chunks/UiIconButton.js +126 -28
- package/vue/chunks/UiInput.js +328 -22
- package/vue/chunks/UiInputGroup.js +44 -10
- package/vue/chunks/UiList.js +104 -15
- package/vue/chunks/UiListItem.js +57 -8
- package/vue/chunks/UiListbox.js +208 -49
- package/vue/chunks/UiMenu.js +88 -15
- package/vue/chunks/UiMenuGroup.js +41 -5
- package/vue/chunks/UiMenuItem.js +111 -32
- package/vue/chunks/UiMeter.js +166 -36
- package/vue/chunks/UiNavItem.js +133 -37
- package/vue/chunks/UiPageHeader.js +41 -6
- package/vue/chunks/UiPopover.js +81 -11
- package/vue/chunks/UiRadio.js +115 -24
- package/vue/chunks/UiRadioGroup.js +108 -19
- package/vue/chunks/UiReel.js +81 -10
- package/vue/chunks/UiScrollArea.js +47 -10
- package/vue/chunks/UiSearchResultRow.js +47 -8
- package/vue/chunks/UiSearchShell.js +84 -24
- package/vue/chunks/UiSection.js +77 -10
- package/vue/chunks/UiSelect.js +108 -20
- package/vue/chunks/UiSeparator.js +41 -5
- package/vue/chunks/UiSidebar.js +136 -20
- package/vue/chunks/UiSpinner.js +64 -19
- package/vue/chunks/UiStack.js +87 -10
- package/vue/chunks/UiStatusMessage.js +82 -12
- package/vue/chunks/UiSwitch.js +115 -24
- package/vue/chunks/UiSwitcher.js +103 -15
- package/vue/chunks/UiTable.js +63 -11
- package/vue/chunks/UiTabs.js +170 -30
- package/vue/chunks/UiText.js +365 -38
- package/vue/chunks/UiTextarea.js +132 -26
- package/vue/chunks/UiToast.js +70 -12
- package/vue/chunks/UiToastRegion.js +154 -33
- package/vue/chunks/UiTooltip.js +124 -16
- package/vue/chunks/UiTopBar.js +16 -3
- package/vue/chunks/UiTree.js +107 -15
- package/vue/chunks/UiTreeItem.js +167 -43
- package/vue/chunks/control.js +171 -0
- package/vue/chunks/host.js +170 -27
- package/vue/chunks/props.js +477 -0
- package/vue/components.css +1192 -1192
- package/vue/editor/index.js +58 -15
- package/vue/editor/primitives.d.ts +52 -2
- package/vue/host.ts +370 -39
|
@@ -10,11 +10,12 @@ let comboboxes = 0;
|
|
|
10
10
|
function authoredOptions(container) {
|
|
11
11
|
return Array.from(container.querySelectorAll("option")).map((option, index) => {
|
|
12
12
|
const { description, tag, tagTone, tagColor } = option.dataset;
|
|
13
|
+
const group = option.closest("optgroup")?.label;
|
|
13
14
|
return {
|
|
14
15
|
id: option.id || option.value || `option-${index}`,
|
|
15
16
|
value: option.value,
|
|
16
17
|
label: option.label || option.textContent?.trim() || option.value,
|
|
17
|
-
group:
|
|
18
|
+
...(group ? { group } : {}),
|
|
18
19
|
disabled: option.disabled,
|
|
19
20
|
...(description ? { description } : {}),
|
|
20
21
|
...(tag ? { tag: { label: tag, ...(tagTone ? { tone: tagTone } : {}), ...(tagColor ? { color: tagColor } : {}) } } : {}),
|
|
@@ -141,7 +142,7 @@ export default function controller(host) {
|
|
|
141
142
|
if (controller.signal.aborted || !alive) return;
|
|
142
143
|
for (const option of options) knownOptions.set(option.value, option);
|
|
143
144
|
const selectedOption = host.state.selected == null ? undefined : knownOptions.get(host.state.selected);
|
|
144
|
-
if (host.state.query
|
|
145
|
+
if (host.state.query == null && awaitingLabel === host.state.selected && selectedOption) {
|
|
145
146
|
host.state.raw = selectedOption.label;
|
|
146
147
|
host.state.display = selectedOption.label;
|
|
147
148
|
awaitingLabel = null;
|
|
@@ -193,8 +194,8 @@ export default function controller(host) {
|
|
|
193
194
|
awaitingLabel = null;
|
|
194
195
|
if (kind === "selection") lastSelection = option;
|
|
195
196
|
const queryChanged = query !== host.state.raw;
|
|
196
|
-
if (host.state.value
|
|
197
|
-
if (host.state.query
|
|
197
|
+
if (host.state.value == null) host.state.selected = value;
|
|
198
|
+
if (host.state.query == null && queryChanged) {
|
|
198
199
|
host.state.raw = query;
|
|
199
200
|
host.state.display = query;
|
|
200
201
|
}
|
|
@@ -208,20 +209,20 @@ export default function controller(host) {
|
|
|
208
209
|
if (kind === "free-entry") host.dispatch("free-entry", detail);
|
|
209
210
|
queueMicrotask(() => {
|
|
210
211
|
if (proposedChange !== proposal) return;
|
|
211
|
-
if (host.state.value
|
|
212
|
-
if (host.state.query
|
|
212
|
+
if (host.state.value != null && host.state.value !== proposal.value) syncValue();
|
|
213
|
+
if (host.state.query != null && host.state.query !== proposal.query) syncQuery();
|
|
213
214
|
proposedChange = undefined;
|
|
214
215
|
});
|
|
215
216
|
};
|
|
216
217
|
const emitItems = (next, trigger) => {
|
|
217
218
|
if (!controlledValues()) host.state.internalItems = next;
|
|
218
|
-
host.dispatch("
|
|
219
|
-
// Not `values`: Vue's adapter reads a modeled prop with `in`, and
|
|
220
|
-
//
|
|
219
|
+
host.dispatch("items-change", next);
|
|
220
|
+
// Not `values`: Vue's adapter reads a modeled prop with `in`, and list-shaped details have
|
|
221
|
+
// Array.prototype.values, so it would emit update:values wrongly.
|
|
221
222
|
host.dispatch("selected-values-change", { selectedValues: next.map((item) => item.value), trigger });
|
|
222
223
|
};
|
|
223
224
|
const setMultiQuery = (query, trigger) => {
|
|
224
|
-
if (host.state.query
|
|
225
|
+
if (host.state.query == null) {
|
|
225
226
|
host.state.raw = query;
|
|
226
227
|
host.state.display = query;
|
|
227
228
|
}
|
|
@@ -281,7 +282,7 @@ export default function controller(host) {
|
|
|
281
282
|
?? knownOptions.get(host.state.selected) ?? lastSelection;
|
|
282
283
|
if (selectedOption && selectedOption.label === typed) return;
|
|
283
284
|
const restoreDraft = (label) => {
|
|
284
|
-
if (host.state.query
|
|
285
|
+
if (host.state.query != null || label === host.state.raw) return;
|
|
285
286
|
host.state.raw = label;
|
|
286
287
|
host.state.display = label;
|
|
287
288
|
resetValidation();
|
|
@@ -352,9 +353,9 @@ export default function controller(host) {
|
|
|
352
353
|
return host.state.validation;
|
|
353
354
|
};
|
|
354
355
|
const syncValue = () => {
|
|
355
|
-
if (host.state.multiple || host.state.value
|
|
356
|
+
if (host.state.multiple || host.state.value == null) return;
|
|
356
357
|
host.state.selected = host.state.value;
|
|
357
|
-
if (host.state.query
|
|
358
|
+
if (host.state.query == null) {
|
|
358
359
|
const proposal = proposedChange;
|
|
359
360
|
const option = config().options?.find((row) => row.value === host.state.selected) ?? (host.state.selected == null ? undefined : knownOptions.get(host.state.selected));
|
|
360
361
|
const nextRaw = proposal?.value === host.state.selected ? proposal.query : option?.label ?? host.state.selected ?? "";
|
|
@@ -367,8 +368,8 @@ export default function controller(host) {
|
|
|
367
368
|
resetValidation();
|
|
368
369
|
};
|
|
369
370
|
const syncQuery = () => {
|
|
370
|
-
if (host.state.query
|
|
371
|
-
if (host.state.value
|
|
371
|
+
if (host.state.query == null || host.state.query === host.state.raw) return;
|
|
372
|
+
if (host.state.value == null && proposedChange?.query !== host.state.query) host.state.selected = null;
|
|
372
373
|
awaitingLabel = null;
|
|
373
374
|
host.state.raw = host.state.query;
|
|
374
375
|
host.state.display = host.state.query;
|
|
@@ -421,7 +422,7 @@ export default function controller(host) {
|
|
|
421
422
|
commit(null, host.state.raw, null, "clear", "keyboard");
|
|
422
423
|
}
|
|
423
424
|
open();
|
|
424
|
-
queueMicrotask(() => { if (host.state.query
|
|
425
|
+
queueMicrotask(() => { if (host.state.query != null && host.state.query !== host.state.raw) syncQuery(); });
|
|
425
426
|
};
|
|
426
427
|
const onKeydown = (event) => {
|
|
427
428
|
const item = event.target.closest?.(".item");
|
|
@@ -483,12 +484,12 @@ export default function controller(host) {
|
|
|
483
484
|
host.state.selected = null;
|
|
484
485
|
host.state.raw = host.state.query ?? "";
|
|
485
486
|
} else {
|
|
486
|
-
host.state.selected = host.state.value
|
|
487
|
+
host.state.selected = host.state.value != null ? host.state.value : authoredDefaults()[0]?.value ?? null;
|
|
487
488
|
host.state.raw = host.state.query ?? "";
|
|
488
|
-
if (host.state.query
|
|
489
|
+
if (host.state.query == null && !host.state.raw && host.state.selected !== null) {
|
|
489
490
|
host.state.raw = config().options?.find((row) => row.value === host.state.selected)?.label ?? host.state.selected;
|
|
490
491
|
}
|
|
491
|
-
if (host.state.query
|
|
492
|
+
if (host.state.query == null && host.state.selected !== null && host.state.raw === host.state.selected) awaitingLabel = host.state.selected;
|
|
492
493
|
}
|
|
493
494
|
host.state.display = host.state.raw;
|
|
494
495
|
};
|
|
@@ -504,7 +505,7 @@ export default function controller(host) {
|
|
|
504
505
|
// Authored options can change after mount (renamed, replaced, or arriving late). A selected value
|
|
505
506
|
// then shows its current label, unless the user is editing the text.
|
|
506
507
|
const relabel = () => {
|
|
507
|
-
if (host.state.multiple || host.state.query
|
|
508
|
+
if (host.state.multiple || host.state.query != null || host.state.selected == null) return;
|
|
508
509
|
if (element.ownerDocument.activeElement === input) return;
|
|
509
510
|
const label = config().options?.find((row) => row.value === host.state.selected)?.label;
|
|
510
511
|
if (label === undefined || label === host.state.raw) return;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
<template component="ui-container">
|
|
2
2
|
<defs>
|
|
3
|
-
<prop name="measure" type="narrow
|
|
3
|
+
<prop name="measure" type="keyword" values="narrow, wide"
|
|
4
4
|
>The container's maximum width, in characters of the current font: narrow is 45ch, wide is 80ch, and unset is 65ch, a comfortable reading line. The
|
|
5
5
|
container centres itself when its parent is wider. The --ui-container-measure custom property, set on the container itself, overrides it; set on an
|
|
6
6
|
ancestor, it does nothing.</prop>
|
|
7
|
-
<prop name="gutters" type="s
|
|
7
|
+
<prop name="gutters" type="keyword" values="s, m, l"
|
|
8
8
|
>Inline padding on both sides, which keeps content off the edges of a narrow screen: s is 0.75rem, m is 1rem (also the default), and l is 1.5rem.</prop>
|
|
9
9
|
</defs>
|
|
10
10
|
<div><slot></slot></div>
|
|
@@ -5,13 +5,25 @@
|
|
|
5
5
|
<state name="internalOpen" :value="false"></state>
|
|
6
6
|
<event
|
|
7
7
|
name="open"
|
|
8
|
-
type="object
|
|
9
|
-
|
|
8
|
+
type="object"
|
|
9
|
+
>
|
|
10
|
+
<prop name="open" required type="boolean"></prop>
|
|
11
|
+
<prop name="reason" required type="keyword" values="action, programmatic, light-dismiss, escape"></prop>
|
|
12
|
+
<prop name="trigger" required type="keyword" values="keyboard, pointer, programmatic"></prop>
|
|
13
|
+
</event>
|
|
10
14
|
<event
|
|
11
15
|
name="close"
|
|
12
|
-
type="object
|
|
13
|
-
|
|
14
|
-
|
|
16
|
+
type="object"
|
|
17
|
+
>
|
|
18
|
+
<prop name="open" required type="boolean"></prop>
|
|
19
|
+
<prop name="reason" required type="keyword" values="action, programmatic, light-dismiss, escape"></prop>
|
|
20
|
+
<prop name="trigger" required type="keyword" values="keyboard, pointer, programmatic"></prop>
|
|
21
|
+
</event>
|
|
22
|
+
<event name="select" type="object">
|
|
23
|
+
<prop name="value" required type="string"></prop>
|
|
24
|
+
<prop name="checked" type="boolean"></prop>
|
|
25
|
+
<prop name="trigger" required type="keyword" values="keyboard, pointer, programmatic"></prop>
|
|
26
|
+
</event>
|
|
15
27
|
</defs>
|
|
16
28
|
<span><div class="menu" $ref="menu" role="menu" aria-orientation="vertical"><slot></slot></div></span>
|
|
17
29
|
<style>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template component="ui-cover">
|
|
2
2
|
<defs>
|
|
3
|
-
<prop name="size" type="screen
|
|
3
|
+
<prop name="size" type="keyword" values="screen, fill" default="screen"
|
|
4
4
|
>How tall the cover is. screen is at least the viewport's height, for a view that is one centred card, such as sign-in; fill takes the space its parent
|
|
5
5
|
gives it.</prop>
|
|
6
6
|
</defs>
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
<template component="ui-description-list">
|
|
2
2
|
<defs>
|
|
3
|
-
<prop name="layout" type="rows
|
|
3
|
+
<prop name="layout" type="keyword" values="rows, stacked, grid, tiles" default="rows"
|
|
4
4
|
>rows sets each term beside its value, one per line, for a short summary; stacked sets every term above its value, one pair per line, for a narrow space;
|
|
5
5
|
grid sets the pairs, term above value, in as many columns as fit, for facts to scan across; tiles sets each pair on its own bordered tile in a grid, for
|
|
6
6
|
figures to compare.</prop>
|
|
7
|
-
<prop name="columns" type="
|
|
7
|
+
<prop name="columns" type="keyword" values="2, 3, 4"
|
|
8
8
|
>The most columns grid and tiles set on a wide list; a narrow list still drops to fewer. Left unset, they fit as many as the width allows.</prop>
|
|
9
|
-
<prop name="density" type="comfortable
|
|
9
|
+
<prop name="density" type="keyword" values="comfortable, compact" default="comfortable"
|
|
10
10
|
>How much room each pair takes. comfortable spaces the pairs apart to read; compact sets them close together, for facts inside other content such as a card
|
|
11
11
|
or a table's detail row.</prop>
|
|
12
12
|
</defs>
|
|
@@ -8,24 +8,32 @@
|
|
|
8
8
|
<prop name="modeless" type="boolean" default="false"
|
|
9
9
|
>Deprecated: does nothing, since dialogs are non-modal unless modal is set. Accepted so markup written for 0.15 keeps working; modal wins when both are
|
|
10
10
|
set.</prop>
|
|
11
|
-
<prop name="closedby" type="any
|
|
11
|
+
<prop name="closedby" type="keyword" values="any, closerequest, none"
|
|
12
12
|
>Which user close requests work: any includes outside presses, closerequest includes Escape, and none requires an action. Unset follows native dialog:
|
|
13
13
|
closerequest when modal, none when not.</prop>
|
|
14
14
|
<prop name="alert" type="boolean" default="false"
|
|
15
15
|
>Use alert dialog semantics and require an explicit action instead of the header close button. An alert dialog is always modal.</prop>
|
|
16
|
-
<prop name="size" type="sm
|
|
16
|
+
<prop name="size" type="keyword" values="sm, md, lg, fullscreen" default="md">Choose a compact, standard, wide, or viewport-filling dialog.</prop>
|
|
17
17
|
<prop name="label" type="string">Visible title in the dialog header; also its accessible name.</prop>
|
|
18
18
|
<prop name="for" type="string" default="">ID of the control that opens the dialog.</prop>
|
|
19
19
|
<state name="internalOpen" :value="false"></state>
|
|
20
20
|
<state name="accessibleLabel" :value="'Dialog'"></state>
|
|
21
21
|
<event
|
|
22
22
|
name="open"
|
|
23
|
-
type="object
|
|
24
|
-
|
|
23
|
+
type="object"
|
|
24
|
+
>
|
|
25
|
+
<prop name="open" required type="boolean"></prop>
|
|
26
|
+
<prop name="reason" required type="keyword" values="action, programmatic"></prop>
|
|
27
|
+
<prop name="trigger" required type="keyword" values="keyboard, pointer, programmatic"></prop>
|
|
28
|
+
</event>
|
|
25
29
|
<event
|
|
26
30
|
name="close"
|
|
27
|
-
type="object
|
|
28
|
-
|
|
31
|
+
type="object"
|
|
32
|
+
>
|
|
33
|
+
<prop name="open" required type="boolean"></prop>
|
|
34
|
+
<prop name="reason" required type="keyword" values="action, programmatic, light-dismiss, escape"></prop>
|
|
35
|
+
<prop name="trigger" required type="keyword" values="keyboard, pointer, programmatic"></prop>
|
|
36
|
+
</event>
|
|
29
37
|
</defs>
|
|
30
38
|
<dialog :aria-label="accessibleLabel">
|
|
31
39
|
<header>
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
<template component="ui-disclosure" controller="./ui-disclosure.js">
|
|
2
2
|
<defs>
|
|
3
|
-
<prop name="density" type="comfortable
|
|
3
|
+
<prop name="density" type="keyword" values="comfortable, compact" default="comfortable"
|
|
4
|
+
>Compact trades padding and type size for rows that fit more on screen.</prop>
|
|
4
5
|
<prop name="summary" type="string" default="Details"
|
|
5
6
|
>The text of the trigger row that opens and closes the disclosure. It is the trigger button's accessible name, so name what the content is.</prop>
|
|
6
7
|
<prop name="open" type="boolean" default="false"
|
|
@@ -18,12 +19,20 @@
|
|
|
18
19
|
<state name="headingAriaLevel" :value="null"></state>
|
|
19
20
|
<event
|
|
20
21
|
name="open"
|
|
21
|
-
type="object
|
|
22
|
-
|
|
22
|
+
type="object"
|
|
23
|
+
>
|
|
24
|
+
<prop name="open" required type="boolean"></prop>
|
|
25
|
+
<prop name="reason" required type="keyword" values="action, programmatic, light-dismiss, escape"></prop>
|
|
26
|
+
<prop name="trigger" required type="keyword" values="keyboard, pointer, programmatic"></prop>
|
|
27
|
+
</event>
|
|
23
28
|
<event
|
|
24
29
|
name="close"
|
|
25
|
-
type="object
|
|
26
|
-
|
|
30
|
+
type="object"
|
|
31
|
+
>
|
|
32
|
+
<prop name="open" required type="boolean"></prop>
|
|
33
|
+
<prop name="reason" required type="keyword" values="action, programmatic, light-dismiss, escape"></prop>
|
|
34
|
+
<prop name="trigger" required type="keyword" values="keyboard, pointer, programmatic"></prop>
|
|
35
|
+
</event>
|
|
27
36
|
</defs>
|
|
28
37
|
<div>
|
|
29
38
|
<div class="heading" :role="headingRole" :aria-level="headingAriaLevel">
|
|
@@ -17,12 +17,23 @@
|
|
|
17
17
|
<state name="internalEdit" :value="false"></state>
|
|
18
18
|
<state name="internalValue" :value="''"></state>
|
|
19
19
|
<state name="draft" :value="''"></state>
|
|
20
|
-
<event name="input" type="object
|
|
21
|
-
|
|
20
|
+
<event name="input" type="object">
|
|
21
|
+
<prop name="value" required type="string"></prop>
|
|
22
|
+
<prop name="trigger" required type="keyword" values="keyboard, pointer, programmatic"></prop>
|
|
23
|
+
</event>
|
|
24
|
+
<event name="change" type="object">
|
|
25
|
+
<prop name="value" required type="string"></prop>
|
|
26
|
+
<prop name="previousValue" required type="string"></prop>
|
|
27
|
+
<prop name="trigger" required type="keyword" values="keyboard, pointer, programmatic"></prop>
|
|
28
|
+
</event>
|
|
22
29
|
<event
|
|
23
30
|
name="edit-change"
|
|
24
|
-
type="object
|
|
25
|
-
|
|
31
|
+
type="object"
|
|
32
|
+
>
|
|
33
|
+
<prop name="edit" required type="boolean"></prop>
|
|
34
|
+
<prop name="reason" required type="keyword" values="activate, commit, cancel, light-dismiss, escape, programmatic"></prop>
|
|
35
|
+
<prop name="trigger" required type="keyword" values="keyboard, pointer, programmatic"></prop>
|
|
36
|
+
</event>
|
|
26
37
|
</defs>
|
|
27
38
|
<div>
|
|
28
39
|
<div class="field">
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<prop name="loadingLabel" type="string" default="Searching…">Status text shown while loading an empty result list.</prop>
|
|
13
13
|
<prop
|
|
14
14
|
name="anchorRect"
|
|
15
|
-
type="object({ left?: number, top?: number, right?: number, bottom?: number, x?: number, y?: number, width?: number, height?: number })
|
|
15
|
+
type="object({ left?: number, top?: number, right?: number, bottom?: number, x?: number, y?: number, width?: number, height?: number })"
|
|
16
16
|
>Where the @ was typed, in viewport coordinates.</prop>
|
|
17
17
|
<state name="visible" :value="false"></state>
|
|
18
18
|
<state name="rows" type="list(object({ id: string, label: string, detail?: string, initials: string }))" :value="[]"></state>
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
highlights it and reports a highlight event.</prop>
|
|
15
15
|
<prop
|
|
16
16
|
name="anchorRect"
|
|
17
|
-
type="object({ left?: number, top?: number, right?: number, bottom?: number, x?: number, y?: number, width?: number, height?: number })
|
|
17
|
+
type="object({ left?: number, top?: number, right?: number, bottom?: number, x?: number, y?: number, width?: number, height?: number })"
|
|
18
18
|
>Where the slash was typed, in viewport coordinates.</prop>
|
|
19
19
|
<state name="visible" :value="false"></state>
|
|
20
20
|
<state name="active" :value="0"></state>
|
|
@@ -2,15 +2,28 @@
|
|
|
2
2
|
<template component="ui-editor-table-context-menu" controller="./ui-editor-table-context-menu.js">
|
|
3
3
|
<defs>
|
|
4
4
|
<prop name="open" type="boolean" default="false">Shows the menu at the position owned by the editor integration.</prop>
|
|
5
|
-
<prop name="scope" type="cell
|
|
5
|
+
<prop name="scope" type="keyword" values="cell, row, column" default="cell">Keeps structure actions relevant to a cell, row handle, or column handle.</prop>
|
|
6
6
|
<prop name="cellBackground" type="string" default="">Identifies the background choice that is active for the current cell.</prop>
|
|
7
7
|
<prop name="headerRow" type="boolean" default="false">Whether the table's first row currently uses header cells.</prop>
|
|
8
8
|
<prop name="headerColumn" type="boolean" default="false">Whether the table's first column currently uses header cells.</prop>
|
|
9
9
|
<prop
|
|
10
10
|
name="actions"
|
|
11
|
-
type="
|
|
12
|
-
>
|
|
13
|
-
|
|
11
|
+
type="array"
|
|
12
|
+
>
|
|
13
|
+
<prop
|
|
14
|
+
type="keyword"
|
|
15
|
+
values="align-left, align-center, align-right, background-none, background-gray, background-yellow, background-blue, background-green, background-red, add-row-before, add-row-after, add-column-before, add-column-after, toggle-header-row, toggle-header-column, move-row-up, move-row-down, move-column-left, move-column-right, clear-cells, merge-cells, split-cell, delete-row, delete-column, delete-table"
|
|
16
|
+
></prop>
|
|
17
|
+
The complete set of commands the current selection permits.
|
|
18
|
+
</prop>
|
|
19
|
+
<state name="swatches" type="array" :value="[]" nullable>
|
|
20
|
+
<prop type="object">
|
|
21
|
+
<prop name="action" required type="string"></prop>
|
|
22
|
+
<prop name="label" required type="string"></prop>
|
|
23
|
+
<prop name="color" required type="string"></prop>
|
|
24
|
+
<prop name="selected" required type="boolean"></prop>
|
|
25
|
+
</prop>
|
|
26
|
+
</state>
|
|
14
27
|
<state
|
|
15
28
|
name="sections"
|
|
16
29
|
type="list(object({ heading: string, items: list(object({ action: string, label: string, icon: string, danger: boolean, checkable: boolean, checked: boolean })) }))"
|
|
@@ -18,8 +31,15 @@
|
|
|
18
31
|
></state>
|
|
19
32
|
<event
|
|
20
33
|
name="action"
|
|
21
|
-
type="object
|
|
22
|
-
|
|
34
|
+
type="object"
|
|
35
|
+
>
|
|
36
|
+
<prop
|
|
37
|
+
name="action"
|
|
38
|
+
required
|
|
39
|
+
type="keyword"
|
|
40
|
+
values="align-left, align-center, align-right, background-none, background-gray, background-yellow, background-blue, background-green, background-red, add-row-before, add-row-after, add-column-before, add-column-after, toggle-header-row, toggle-header-column, move-row-up, move-row-down, move-column-left, move-column-right, clear-cells, merge-cells, split-cell, delete-row, delete-column, delete-table"
|
|
41
|
+
></prop>
|
|
42
|
+
</event>
|
|
23
43
|
</defs>
|
|
24
44
|
<div role="menu" :hidden="not open">
|
|
25
45
|
<div $if="swatches" class="section" role="none">
|
|
@@ -4,32 +4,110 @@
|
|
|
4
4
|
<prop name="open" type="boolean" default="false">Shows the controls after the editor has supplied current geometry.</prop>
|
|
5
5
|
<prop
|
|
6
6
|
name="geometry"
|
|
7
|
-
type="object
|
|
8
|
-
>
|
|
7
|
+
type="object"
|
|
8
|
+
>
|
|
9
|
+
<prop name="rowBoundaries" required type="array">
|
|
10
|
+
<prop type="number"></prop>
|
|
11
|
+
</prop>
|
|
12
|
+
<prop name="columnBoundaries" required type="array">
|
|
13
|
+
<prop type="number"></prop>
|
|
14
|
+
</prop>
|
|
15
|
+
<prop name="activeCell" required nullable type="object">
|
|
16
|
+
<prop name="left" required type="number"></prop>
|
|
17
|
+
<prop name="top" required type="number"></prop>
|
|
18
|
+
<prop name="width" required type="number"></prop>
|
|
19
|
+
<prop name="height" required type="number"></prop>
|
|
20
|
+
<prop name="rowIndex" required type="integer"></prop>
|
|
21
|
+
<prop name="columnIndex" required type="integer"></prop>
|
|
22
|
+
</prop>
|
|
23
|
+
<prop name="hoveredCell" nullable type="object">
|
|
24
|
+
<prop name="left" required type="number"></prop>
|
|
25
|
+
<prop name="top" required type="number"></prop>
|
|
26
|
+
<prop name="width" required type="number"></prop>
|
|
27
|
+
<prop name="height" required type="number"></prop>
|
|
28
|
+
<prop name="rowIndex" required type="integer"></prop>
|
|
29
|
+
<prop name="columnIndex" required type="integer"></prop>
|
|
30
|
+
</prop>
|
|
31
|
+
The authoritative editor-measured table boundaries and active or hovered cell rectangles.
|
|
32
|
+
</prop>
|
|
9
33
|
<state
|
|
10
34
|
name="rows"
|
|
11
|
-
type="
|
|
35
|
+
type="array"
|
|
12
36
|
:value="[]"
|
|
13
|
-
|
|
37
|
+
>
|
|
38
|
+
<prop type="object">
|
|
39
|
+
<prop name="key" required type="string"></prop>
|
|
40
|
+
<prop name="index" required type="integer"></prop>
|
|
41
|
+
<prop name="offset" required type="string"></prop>
|
|
42
|
+
<prop name="affordance" required type="keyword" values="insert-row, insert-column"></prop>
|
|
43
|
+
<prop name="action" required type="keyword" values="add-row-before, add-row-after, add-column-before, add-column-after"></prop>
|
|
44
|
+
<prop name="label" required type="string"></prop>
|
|
45
|
+
</prop>
|
|
46
|
+
</state>
|
|
14
47
|
<state
|
|
15
48
|
name="cols"
|
|
16
|
-
type="
|
|
49
|
+
type="array"
|
|
17
50
|
:value="[]"
|
|
18
|
-
|
|
51
|
+
>
|
|
52
|
+
<prop type="object">
|
|
53
|
+
<prop name="key" required type="string"></prop>
|
|
54
|
+
<prop name="index" required type="integer"></prop>
|
|
55
|
+
<prop name="offset" required type="string"></prop>
|
|
56
|
+
<prop name="affordance" required type="keyword" values="insert-row, insert-column"></prop>
|
|
57
|
+
<prop name="action" required type="keyword" values="add-row-before, add-row-after, add-column-before, add-column-after"></prop>
|
|
58
|
+
<prop name="label" required type="string"></prop>
|
|
59
|
+
</prop>
|
|
60
|
+
</state>
|
|
19
61
|
<state
|
|
20
62
|
name="hovered"
|
|
21
|
-
type="object
|
|
63
|
+
type="object"
|
|
22
64
|
:value="null"
|
|
23
|
-
|
|
65
|
+
nullable
|
|
66
|
+
>
|
|
67
|
+
<prop name="left" required type="number"></prop>
|
|
68
|
+
<prop name="top" required type="number"></prop>
|
|
69
|
+
<prop name="width" required type="number"></prop>
|
|
70
|
+
<prop name="height" required type="number"></prop>
|
|
71
|
+
<prop name="rowIndex" required type="integer"></prop>
|
|
72
|
+
<prop name="columnIndex" required type="integer"></prop>
|
|
73
|
+
<prop name="rowOffset" required type="string"></prop>
|
|
74
|
+
<prop name="columnOffset" required type="string"></prop>
|
|
75
|
+
</state>
|
|
24
76
|
<state
|
|
25
77
|
name="active"
|
|
26
|
-
type="object
|
|
78
|
+
type="object"
|
|
27
79
|
:value="null"
|
|
28
|
-
|
|
80
|
+
nullable
|
|
81
|
+
>
|
|
82
|
+
<prop name="left" required type="number"></prop>
|
|
83
|
+
<prop name="top" required type="number"></prop>
|
|
84
|
+
<prop name="width" required type="number"></prop>
|
|
85
|
+
<prop name="height" required type="number"></prop>
|
|
86
|
+
<prop name="rowIndex" required type="integer"></prop>
|
|
87
|
+
<prop name="columnIndex" required type="integer"></prop>
|
|
88
|
+
<prop name="menuLeft" required type="string"></prop>
|
|
89
|
+
<prop name="menuTop" required type="string"></prop>
|
|
90
|
+
</state>
|
|
29
91
|
<state name="activeKey" :value="''"></state>
|
|
92
|
+
<event name="add-row-before" type="object({ boundaryIndex: integer })"></event>
|
|
93
|
+
<event name="add-row-after" type="object({ boundaryIndex: integer })"></event>
|
|
94
|
+
<event name="add-column-before" type="object({ boundaryIndex: integer })"></event>
|
|
95
|
+
<event name="add-column-after" type="object({ boundaryIndex: integer })"></event>
|
|
96
|
+
<event name="select-row" type="object({ rowIndex: integer, columnIndex: integer })"></event>
|
|
97
|
+
<event name="select-column" type="object({ rowIndex: integer, columnIndex: integer })"></event>
|
|
98
|
+
<event name="reorder-row" type="object({ fromIndex: integer, toIndex: integer })"></event>
|
|
99
|
+
<event name="reorder-column" type="object({ fromIndex: integer, toIndex: integer })"></event>
|
|
100
|
+
<event
|
|
101
|
+
name="open-cell-menu"
|
|
102
|
+
type="object({ rowIndex: integer, columnIndex: integer, anchor: object({ left: number, top: number, right: number, bottom: number }) })"
|
|
103
|
+
></event>
|
|
104
|
+
<event
|
|
105
|
+
name="open-row-menu"
|
|
106
|
+
type="object({ rowIndex: integer, columnIndex: integer, anchor: object({ left: number, top: number, right: number, bottom: number }) })"
|
|
107
|
+
></event>
|
|
30
108
|
<event
|
|
31
|
-
name="
|
|
32
|
-
type="object({
|
|
109
|
+
name="open-column-menu"
|
|
110
|
+
type="object({ rowIndex: integer, columnIndex: integer, anchor: object({ left: number, top: number, right: number, bottom: number }) })"
|
|
33
111
|
></event>
|
|
34
112
|
</defs>
|
|
35
113
|
<div aria-label="Table controls" :hidden="not open">
|
|
@@ -96,7 +96,7 @@ export default function controller(host) {
|
|
|
96
96
|
if (to === null) return;
|
|
97
97
|
suppressClick = true;
|
|
98
98
|
setTimeout(() => { suppressClick = false; }, 0);
|
|
99
|
-
if (to !== from) host.dispatch(
|
|
99
|
+
if (to !== from) host.dispatch(axis === "row" ? "reorder-row" : "reorder-column", { fromIndex: from, toIndex: to });
|
|
100
100
|
};
|
|
101
101
|
const boundaries = (axis) => {
|
|
102
102
|
const values = host.state.geometry?.[axis === "row" ? "rowBoundaries" : "columnBoundaries"];
|
|
@@ -141,13 +141,13 @@ export default function controller(host) {
|
|
|
141
141
|
const action = button.dataset.action;
|
|
142
142
|
const cell = { rowIndex: Number(button.dataset.rowIndex), columnIndex: Number(button.dataset.columnIndex) };
|
|
143
143
|
if (action === "select-row" || action === "select-column") {
|
|
144
|
-
host.dispatch(
|
|
144
|
+
host.dispatch(action, cell);
|
|
145
145
|
const rect = button.getBoundingClientRect();
|
|
146
|
-
host.dispatch(
|
|
146
|
+
host.dispatch(action === "select-row" ? "open-row-menu" : "open-column-menu", { ...cell, anchor: { left: rect.left, top: rect.top, right: rect.right, bottom: rect.bottom } });
|
|
147
147
|
} else if (action === "open-cell-menu") {
|
|
148
148
|
const rect = button.getBoundingClientRect();
|
|
149
|
-
host.dispatch(
|
|
150
|
-
} else host.dispatch(
|
|
149
|
+
host.dispatch(action, { ...cell, anchor: { left: rect.left, top: rect.top, right: rect.right, bottom: rect.bottom } });
|
|
150
|
+
} else host.dispatch(action, { boundaryIndex: Number(button.dataset.boundaryIndex) });
|
|
151
151
|
};
|
|
152
152
|
const keyOf = (target) => target instanceof Element ? target.closest("[data-control-key]")?.dataset.controlKey ?? "" : "";
|
|
153
153
|
const enter = (event) => { host.state.activeKey = keyOf(event.target); };
|
|
@@ -2,16 +2,35 @@
|
|
|
2
2
|
<template component="ui-editor-table-toolbar" controller="./ui-editor-table-toolbar.js">
|
|
3
3
|
<defs>
|
|
4
4
|
<prop name="open" type="boolean" default="false">Shows the toolbar while a table selection is active.</prop>
|
|
5
|
-
<prop name="cellAlignment" type="left
|
|
5
|
+
<prop name="cellAlignment" type="keyword" values="left, center, right" default="left"
|
|
6
|
+
>Marks the alignment command that is active for the current cell.</prop>
|
|
6
7
|
<prop name="cellBackground" type="string" default="">Identifies the background choice that is active for the current cell.</prop>
|
|
7
8
|
<prop name="headerRow" type="boolean" default="false">Whether the table's first row currently uses header cells.</prop>
|
|
8
9
|
<prop name="headerColumn" type="boolean" default="false">Whether the table's first column currently uses header cells.</prop>
|
|
9
10
|
<prop
|
|
10
11
|
name="actions"
|
|
11
|
-
type="
|
|
12
|
-
>
|
|
13
|
-
|
|
14
|
-
|
|
12
|
+
type="array"
|
|
13
|
+
>
|
|
14
|
+
<prop
|
|
15
|
+
type="keyword"
|
|
16
|
+
values="align-left, align-center, align-right, background-none, background-gray, background-yellow, background-blue, background-green, background-red, add-row-before, add-row-after, add-column-before, add-column-after, toggle-header-row, toggle-header-column, move-row-up, move-row-down, move-column-left, move-column-right, clear-cells, merge-cells, split-cell, delete-row, delete-column, delete-table"
|
|
17
|
+
></prop>
|
|
18
|
+
The complete set of commands the current selection permits.
|
|
19
|
+
</prop>
|
|
20
|
+
<state name="alignments" type="array" :value="[]">
|
|
21
|
+
<prop type="object">
|
|
22
|
+
<prop name="action" required type="keyword" values="align-left, align-center, align-right"></prop>
|
|
23
|
+
<prop name="label" required type="string"></prop>
|
|
24
|
+
<prop name="active" required type="boolean"></prop>
|
|
25
|
+
</prop>
|
|
26
|
+
</state>
|
|
27
|
+
<state name="structure" type="array" :value="[]">
|
|
28
|
+
<prop type="object">
|
|
29
|
+
<prop name="action" required type="keyword" values="add-row-after, add-column-after"></prop>
|
|
30
|
+
<prop name="label" required type="string"></prop>
|
|
31
|
+
<prop name="icon" required type="string"></prop>
|
|
32
|
+
</prop>
|
|
33
|
+
</state>
|
|
15
34
|
<state name="swatches" type="list(object({ action: string, label: string, color: string, selected: boolean }))" :value="[]"></state>
|
|
16
35
|
<state
|
|
17
36
|
name="sections"
|
|
@@ -22,8 +41,15 @@
|
|
|
22
41
|
<state name="overflowOpen" :value="false"></state>
|
|
23
42
|
<event
|
|
24
43
|
name="action"
|
|
25
|
-
type="object
|
|
26
|
-
|
|
44
|
+
type="object"
|
|
45
|
+
>
|
|
46
|
+
<prop
|
|
47
|
+
name="action"
|
|
48
|
+
required
|
|
49
|
+
type="keyword"
|
|
50
|
+
values="align-left, align-center, align-right, background-none, background-gray, background-yellow, background-blue, background-green, background-red, add-row-before, add-row-after, add-column-before, add-column-after, toggle-header-row, toggle-header-column, move-row-up, move-row-down, move-column-left, move-column-right, clear-cells, merge-cells, split-cell, delete-row, delete-column, delete-table"
|
|
51
|
+
></prop>
|
|
52
|
+
</event>
|
|
27
53
|
</defs>
|
|
28
54
|
<div role="toolbar" aria-label="Table actions" :hidden="not open">
|
|
29
55
|
<div $if="alignments" class="group" role="group" aria-label="Cell alignment">
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
<template component="ui-grid">
|
|
2
2
|
<defs>
|
|
3
|
-
<prop name="gap" type="xs
|
|
3
|
+
<prop name="gap" type="keyword" values="xs, s, m, l, xl"
|
|
4
4
|
>Space between cells, on the spacing scale: xs is 0.5rem, s 0.75rem, m 1rem (also the default), l 1.5rem, and xl 2rem. The --ui-grid-gap custom property,
|
|
5
5
|
set on the grid itself, overrides it; set on an ancestor, it does nothing.</prop>
|
|
6
|
-
<prop name="min" type="sm
|
|
6
|
+
<prop name="min" type="keyword" values="sm, md, lg"
|
|
7
7
|
>The narrowest a column may get before the grid drops to fewer columns: sm is 12rem (also the default), md is 16rem, and lg is 20rem. The grid fits as many
|
|
8
8
|
equal columns as its width allows, and a single column never overflows a narrower container.</prop>
|
|
9
9
|
<prop name="columns" type="integer"
|