@threadlabs/looma 0.14.8 → 0.15.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/icons.js +5 -0
- package/components/shared/menu-navigation.js +49 -0
- package/components/shared/overlay.js +33 -60
- package/components/ui-avatar/ui-avatar.html +19 -2
- package/components/ui-avatar/ui-avatar.js +7 -1
- package/components/ui-avatar-group/ui-avatar-group.html +8 -3
- package/components/ui-avatar-group/ui-avatar-group.js +6 -2
- package/components/ui-badge/ui-badge.html +70 -4
- package/components/ui-button/ui-button.html +21 -5
- package/components/ui-button/ui-button.js +10 -0
- package/components/ui-callout/ui-callout.html +13 -5
- package/components/ui-checkbox/ui-checkbox.html +11 -0
- package/components/ui-combobox/ui-combobox.html +46 -10
- package/components/ui-combobox/ui-combobox.js +5 -5
- package/components/ui-context-menu/ui-context-menu.html +33 -5
- package/components/ui-context-menu/ui-context-menu.js +26 -17
- package/components/ui-dialog/ui-dialog.html +51 -8
- package/components/ui-dialog/ui-dialog.js +28 -7
- package/components/ui-disclosure/ui-disclosure.html +14 -5
- package/components/ui-disclosure/ui-disclosure.js +51 -4
- package/components/ui-editable/ui-editable.html +17 -3
- package/components/ui-editable/ui-editable.js +7 -0
- package/components/ui-editor-insert-table-grid/ui-editor-insert-table-grid.html +48 -14
- package/components/ui-editor-insert-table-grid/ui-editor-insert-table-grid.js +40 -6
- package/components/ui-editor-mention-menu/ui-editor-mention-menu.html +22 -9
- package/components/ui-editor-mention-menu/ui-editor-mention-menu.js +33 -11
- package/components/ui-editor-mention-menu-item/ui-editor-mention-menu-item.html +67 -0
- package/components/ui-editor-slash-menu/ui-editor-slash-menu.html +33 -30
- package/components/ui-editor-slash-menu/ui-editor-slash-menu.js +42 -8
- package/components/ui-editor-slash-menu-group/ui-editor-slash-menu-group.html +31 -0
- package/components/ui-editor-slash-menu-item/ui-editor-slash-menu-item.html +75 -0
- package/components/ui-editor-table-context-menu/ui-editor-table-context-menu.html +16 -5
- package/components/ui-editor-table-context-menu/ui-editor-table-context-menu.js +10 -2
- package/components/ui-editor-table-overlay/ui-editor-table-overlay.html +5 -5
- package/components/ui-editor-table-overlay/ui-editor-table-overlay.js +5 -2
- package/components/ui-editor-table-toolbar/ui-editor-table-toolbar.html +14 -4
- package/components/ui-editor-table-toolbar/ui-editor-table-toolbar.js +2 -2
- package/components/ui-editor-toolbar/ui-editor-toolbar.html +1 -1
- package/components/ui-editor-toolbar/ui-editor-toolbar.js +46 -0
- package/components/ui-floating-action-button/ui-floating-action-button.html +1 -1
- package/components/ui-form-field/ui-form-field.html +16 -3
- package/components/ui-form-field/ui-form-field.js +1 -1
- package/components/ui-grid/ui-grid.html +17 -2
- package/components/ui-icon/ui-icon.html +5 -0
- package/components/ui-icon-button/ui-icon-button.html +25 -6
- package/components/ui-icon-button/ui-icon-button.js +11 -1
- package/components/ui-input/ui-input.html +3 -3
- package/components/ui-input-group/ui-input-group.html +18 -4
- package/components/ui-listbox/ui-listbox.html +81 -0
- package/components/ui-listbox/ui-listbox.js +27 -0
- package/components/ui-menu/ui-menu.html +33 -5
- package/components/ui-menu/ui-menu.js +18 -12
- package/components/ui-menu-group/ui-menu-group.html +27 -0
- package/components/ui-menu-item/ui-menu-item.html +80 -8
- package/components/ui-menu-item/ui-menu-item.js +47 -0
- package/components/ui-popover/ui-popover.html +33 -5
- package/components/ui-popover/ui-popover.js +9 -1
- package/components/ui-radio-group/ui-radio-group.html +13 -1
- package/components/ui-search-shell/ui-search-shell.html +6 -6
- package/components/ui-search-shell/ui-search-shell.js +21 -5
- package/components/ui-select/ui-select.html +14 -4
- package/components/ui-switch/ui-switch.html +2 -2
- package/components/ui-switcher/ui-switcher.html +8 -1
- package/components/ui-switcher/ui-switcher.js +15 -0
- package/components/ui-tabs/ui-tabs.html +17 -12
- package/components/ui-tabs/ui-tabs.js +43 -7
- package/components/ui-textarea/ui-textarea.html +28 -5
- package/components/ui-toast/ui-toast.html +88 -0
- package/components/ui-toast/ui-toast.js +68 -0
- package/components/ui-toast-region/ui-toast-region.html +102 -19
- package/components/ui-toast-region/ui-toast-region.js +10 -18
- package/components/ui-tooltip/ui-tooltip.html +51 -7
- package/components/ui-tooltip/ui-tooltip.js +29 -3
- package/components/ui-tree/ui-tree.html +12 -0
- package/components/ui-tree/ui-tree.js +191 -12
- package/components/ui-tree-item/ui-tree-item.html +87 -8
- package/components/ui-tree-item/ui-tree-item.js +3 -1
- package/dist/index.js +38 -32
- package/editor/chunks/extensions.js +82 -2
- package/editor/extensions/table-commands.d.ts +8 -0
- package/editor/icons.d.ts +5 -0
- package/editor/index.js +7 -2
- package/editor/insert-table-grid.d.ts +1 -1
- package/editor/mention-menu.d.ts +2 -0
- package/editor/slash-menu.d.ts +3 -0
- package/editor/table-context-menu.d.ts +1 -1
- package/editor/table-overlay.d.ts +2 -2
- package/package.json +1 -1
- package/styles/ui-avatar-group.css +1 -2
- package/styles/ui-avatar.css +11 -1
- package/styles/ui-badge.css +73 -1
- package/styles/ui-button.css +9 -1
- package/styles/ui-callout.css +1 -1
- package/styles/ui-checkbox.css +9 -0
- package/styles/ui-combobox.css +38 -7
- package/styles/ui-context-menu.css +32 -4
- package/styles/ui-dialog.css +42 -5
- package/styles/ui-editor-insert-table-grid.css +48 -11
- package/styles/ui-editor-mention-menu-item.css +57 -0
- package/styles/ui-editor-mention-menu.css +11 -1
- package/styles/ui-editor-slash-menu-group.css +21 -0
- package/styles/ui-editor-slash-menu-item.css +62 -0
- package/styles/ui-editor-slash-menu.css +10 -21
- package/styles/ui-editor-table-context-menu.css +1 -1
- package/styles/ui-floating-action-button.css +1 -1
- package/styles/ui-form-field.css +14 -1
- package/styles/ui-grid.css +14 -1
- package/styles/ui-icon-button.css +17 -5
- package/styles/ui-input-group.css +18 -4
- package/styles/ui-input.css +3 -3
- package/styles/ui-listbox.css +69 -0
- package/styles/ui-menu-group.css +19 -0
- package/styles/ui-menu-item.css +48 -9
- package/styles/ui-menu.css +32 -4
- package/styles/ui-popover.css +28 -4
- package/styles/ui-radio-group.css +9 -0
- package/styles/ui-search-shell.css +5 -5
- package/styles/ui-select.css +14 -4
- package/styles/ui-switch.css +2 -2
- package/styles/ui-switcher.css +4 -0
- package/styles/ui-textarea.css +27 -4
- package/styles/ui-toast-region.css +88 -4
- package/styles/ui-toast.css +74 -0
- package/styles/ui-tooltip.css +46 -6
- package/styles/ui-tree-item.css +72 -4
- package/styles/ui-tree.css +8 -0
- package/tokens.css +3 -0
- package/vanilla/UiAvatar.d.ts +2 -0
- package/vanilla/UiAvatar.js +8 -1
- package/vanilla/UiAvatarGroup.d.ts +2 -0
- package/vanilla/UiAvatarGroup.js +1 -1
- package/vanilla/UiBadge.d.ts +1 -1
- package/vanilla/UiBadge.js +1 -1
- package/vanilla/UiButton.d.ts +1 -0
- package/vanilla/UiButton.js +22 -6
- package/vanilla/UiCallout.d.ts +1 -1
- package/vanilla/UiCallout.js +1 -1
- package/vanilla/UiCheckbox.d.ts +1 -0
- package/vanilla/UiCheckbox.js +12 -9
- package/vanilla/UiCombobox.d.ts +3 -0
- package/vanilla/UiCombobox.js +30 -15
- package/vanilla/UiContextMenu.d.ts +1 -1
- package/vanilla/UiContextMenu.js +1 -1
- package/vanilla/UiDialog.d.ts +5 -2
- package/vanilla/UiDialog.js +1 -1
- package/vanilla/UiDisclosure.d.ts +2 -0
- package/vanilla/UiDisclosure.js +32 -18
- package/vanilla/UiEditable.d.ts +5 -0
- package/vanilla/UiEditable.js +7 -3
- package/vanilla/UiEditorInsertTableGrid.js +1 -6
- package/vanilla/UiEditorMentionMenu.d.ts +4 -2
- package/vanilla/UiEditorMentionMenu.js +49 -31
- package/vanilla/UiEditorMentionMenuItem.d.ts +16 -0
- package/vanilla/UiEditorMentionMenuItem.js +56 -0
- package/vanilla/UiEditorSlashMenu.d.ts +4 -3
- package/vanilla/UiEditorSlashMenu.js +59 -46
- package/vanilla/UiEditorSlashMenuGroup.d.ts +14 -0
- package/vanilla/UiEditorSlashMenuGroup.js +48 -0
- package/vanilla/UiEditorSlashMenuItem.d.ts +18 -0
- package/vanilla/UiEditorSlashMenuItem.js +57 -0
- package/vanilla/UiEditorTableContextMenu.d.ts +5 -2
- package/vanilla/UiEditorTableContextMenu.js +1 -2
- package/vanilla/UiEditorTableOverlay.d.ts +1 -1
- package/vanilla/UiEditorTableOverlay.js +5 -5
- package/vanilla/UiEditorTableToolbar.d.ts +4 -2
- package/vanilla/UiEditorTableToolbar.js +1 -2
- package/vanilla/UiEditorToolbar.js +2 -0
- package/vanilla/UiGrid.d.ts +1 -0
- package/vanilla/UiGrid.js +8 -7
- package/vanilla/UiIcon.js +1 -1
- package/vanilla/UiIconButton.d.ts +1 -0
- package/vanilla/UiIconButton.js +11 -2
- package/vanilla/UiListbox.d.ts +20 -0
- package/vanilla/UiListbox.js +45 -0
- package/vanilla/UiMenu.d.ts +1 -1
- package/vanilla/UiMenu.js +1 -1
- package/vanilla/UiMenuGroup.d.ts +14 -0
- package/vanilla/UiMenuGroup.js +35 -0
- package/vanilla/UiMenuItem.d.ts +5 -1
- package/vanilla/UiMenuItem.js +91 -30
- package/vanilla/UiPopover.d.ts +1 -1
- package/vanilla/UiPopover.js +1 -1
- package/vanilla/UiRadioGroup.d.ts +1 -0
- package/vanilla/UiRadioGroup.js +6 -3
- package/vanilla/UiSwitcher.d.ts +1 -0
- package/vanilla/UiSwitcher.js +7 -9
- package/vanilla/UiTabs.d.ts +1 -0
- package/vanilla/UiTabs.js +9 -1
- package/vanilla/UiTextarea.d.ts +1 -0
- package/vanilla/UiTextarea.js +4 -1
- package/vanilla/UiToast.d.ts +16 -0
- package/vanilla/UiToast.js +53 -0
- package/vanilla/UiToastRegion.d.ts +1 -4
- package/vanilla/UiToastRegion.js +3 -11
- package/vanilla/UiTooltip.d.ts +1 -1
- package/vanilla/UiTooltip.js +1 -1
- package/vanilla/UiTree.d.ts +2 -0
- package/vanilla/UiTree.js +1 -1
- package/vanilla/UiTreeItem.d.ts +1 -0
- package/vanilla/UiTreeItem.js +45 -31
- package/vanilla/index.js +6 -0
- package/vue/UiAvatar.d.ts +4 -0
- package/vue/UiAvatar.vue +23 -3
- package/vue/UiAvatarGroup.d.ts +3 -0
- package/vue/UiAvatarGroup.vue +7 -4
- package/vue/UiBadge.d.ts +2 -2
- package/vue/UiBadge.vue +74 -2
- package/vue/UiButton.d.ts +5 -3
- package/vue/UiButton.vue +41 -7
- package/vue/UiCallout.d.ts +2 -2
- package/vue/UiCallout.vue +3 -2
- package/vue/UiCheckbox.d.ts +2 -0
- package/vue/UiCheckbox.vue +16 -0
- package/vue/UiCombobox.d.ts +11 -3
- package/vue/UiCombobox.vue +60 -11
- package/vue/UiContextMenu.d.ts +2 -0
- package/vue/UiContextMenu.vue +47 -6
- package/vue/UiDialog.d.ts +18 -4
- package/vue/UiDialog.vue +86 -11
- package/vue/UiDisclosure.d.ts +8 -2
- package/vue/UiDisclosure.vue +38 -14
- package/vue/UiEditable.d.ts +10 -0
- package/vue/UiEditable.vue +14 -2
- package/vue/UiEditorInsertTableGrid.vue +52 -15
- package/vue/UiEditorMentionMenu.d.ts +24 -2
- package/vue/UiEditorMentionMenu.vue +27 -11
- package/vue/UiEditorMentionMenuItem.d.ts +24 -0
- package/vue/UiEditorMentionMenuItem.js +2 -0
- package/vue/UiEditorMentionMenuItem.vue +88 -0
- package/vue/UiEditorSlashMenu.d.ts +24 -1
- package/vue/UiEditorSlashMenu.vue +33 -33
- package/vue/UiEditorSlashMenuGroup.d.ts +18 -0
- package/vue/UiEditorSlashMenuGroup.js +2 -0
- package/vue/UiEditorSlashMenuGroup.vue +43 -0
- package/vue/UiEditorSlashMenuItem.d.ts +26 -0
- package/vue/UiEditorSlashMenuItem.js +2 -0
- package/vue/UiEditorSlashMenuItem.vue +101 -0
- package/vue/UiEditorTableContextMenu.d.ts +9 -3
- package/vue/UiEditorTableContextMenu.vue +53 -3
- package/vue/UiEditorTableOverlay.d.ts +2 -2
- package/vue/UiEditorTableOverlay.vue +8 -6
- package/vue/UiEditorTableToolbar.d.ts +7 -3
- package/vue/UiEditorTableToolbar.vue +50 -2
- package/vue/UiEditorToolbar.vue +14 -1
- package/vue/UiFloatingActionButton.vue +1 -1
- package/vue/UiFormField.vue +28 -3
- package/vue/UiGrid.d.ts +1 -0
- package/vue/UiGrid.vue +26 -2
- package/vue/UiIcon.vue +16 -0
- package/vue/UiIconButton.d.ts +5 -3
- package/vue/UiIconButton.vue +40 -6
- package/vue/UiInput.vue +10 -3
- package/vue/UiInputGroup.vue +32 -11
- package/vue/UiListbox.d.ts +33 -0
- package/vue/UiListbox.js +2 -0
- package/vue/UiListbox.vue +131 -0
- package/vue/UiMenu.d.ts +2 -0
- package/vue/UiMenu.vue +43 -6
- package/vue/UiMenuGroup.d.ts +18 -0
- package/vue/UiMenuGroup.js +2 -0
- package/vue/UiMenuGroup.vue +39 -0
- package/vue/UiMenuItem.d.ts +34 -2
- package/vue/UiMenuItem.vue +145 -9
- package/vue/UiPopover.d.ts +2 -2
- package/vue/UiPopover.vue +44 -5
- package/vue/UiRadioGroup.d.ts +2 -0
- package/vue/UiRadioGroup.vue +17 -0
- package/vue/UiSearchShell.vue +12 -5
- package/vue/UiSelect.vue +18 -4
- package/vue/UiSwitch.vue +2 -2
- package/vue/UiSwitcher.d.ts +1 -0
- package/vue/UiSwitcher.vue +22 -1
- package/vue/UiTabs.d.ts +6 -2
- package/vue/UiTabs.vue +14 -12
- package/vue/UiTextarea.d.ts +2 -0
- package/vue/UiTextarea.vue +32 -4
- package/vue/UiToast.d.ts +34 -0
- package/vue/UiToast.js +2 -0
- package/vue/UiToast.vue +173 -0
- package/vue/UiToastRegion.d.ts +2 -18
- package/vue/UiToastRegion.vue +123 -48
- package/vue/UiTooltip.d.ts +2 -2
- package/vue/UiTooltip.vue +67 -12
- package/vue/UiTree.d.ts +10 -0
- package/vue/UiTree.vue +27 -0
- package/vue/UiTreeItem.d.ts +2 -0
- package/vue/UiTreeItem.vue +96 -4
- package/vue/chunks/UiAvatar.js +19 -5
- package/vue/chunks/UiAvatarGroup.js +10 -4
- package/vue/chunks/UiBadge.js +1 -1
- package/vue/chunks/UiButton.js +58 -11
- package/vue/chunks/UiCallout.js +2 -2
- package/vue/chunks/UiCheckbox.js +12 -2
- package/vue/chunks/UiCombobox.js +29 -13
- package/vue/chunks/UiContextMenu.js +6 -2
- package/vue/chunks/UiDialog.js +25 -8
- package/vue/chunks/UiDisclosure.js +36 -12
- package/vue/chunks/UiEditable.js +22 -8
- package/vue/chunks/UiEditorInsertTableGrid.js +11 -14
- package/vue/chunks/UiEditorMentionMenu.js +30 -19
- package/vue/chunks/UiEditorMentionMenuItem.js +36 -0
- package/vue/chunks/UiEditorSlashMenu.js +33 -35
- package/vue/chunks/UiEditorSlashMenuGroup.js +26 -0
- package/vue/chunks/UiEditorSlashMenuItem.js +51 -0
- package/vue/chunks/UiEditorTableContextMenu.js +39 -5
- package/vue/chunks/UiEditorTableOverlay.js +6 -6
- package/vue/chunks/UiEditorTableToolbar.js +37 -4
- package/vue/chunks/UiEditorToolbar.js +18 -4
- package/vue/chunks/UiFloatingActionButton.js +1 -1
- package/vue/chunks/UiFormField.js +13 -9
- package/vue/chunks/UiGrid.js +6 -2
- package/vue/chunks/UiIcon.js +40 -2
- package/vue/chunks/UiIconButton.js +35 -4
- package/vue/chunks/UiInput.js +1 -1
- package/vue/chunks/UiInputGroup.js +1 -1
- package/vue/chunks/UiListbox.js +70 -0
- package/vue/chunks/UiMenu.js +6 -2
- package/vue/chunks/UiMenuGroup.js +25 -0
- package/vue/chunks/UiMenuItem.js +128 -7
- package/vue/chunks/UiPopover.js +1 -1
- package/vue/chunks/UiRadioGroup.js +8 -2
- package/vue/chunks/UiSearchShell.js +1 -1
- package/vue/chunks/UiSelect.js +1 -1
- package/vue/chunks/UiSwitch.js +1 -1
- package/vue/chunks/UiSwitcher.js +20 -3
- package/vue/chunks/UiTabs.js +4 -3
- package/vue/chunks/UiTextarea.js +7 -2
- package/vue/chunks/UiToast.js +81 -0
- package/vue/chunks/UiToastRegion.js +25 -49
- package/vue/chunks/UiTooltip.js +3 -7
- package/vue/chunks/UiTree.js +8 -4
- package/vue/chunks/UiTreeItem.js +28 -10
- package/vue/components.css +1840 -851
- package/vue/editor/index.js +263 -2
- package/vue/index.d.ts +6 -0
- package/vue/index.js +9 -3
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper.js";
|
|
2
|
+
import { n as useComponentHost, t as createDispatch } from "./host.js";
|
|
3
|
+
import { t as UiIcon_default } from "./UiIcon.js";
|
|
4
|
+
import { t as UiIconButton_default } from "./UiIconButton.js";
|
|
5
|
+
import { computed, createElementBlock, createElementVNode, createVNode, defineComponent, mergeProps, openBlock, ref, renderSlot, useTemplateRef, withCtx } from "vue";
|
|
6
|
+
import * as controllerModule from "@threadlabs/looma/components/ui-toast/ui-toast.js";
|
|
7
|
+
//#region .build/vue/UiToast.vue?vue&type=script&setup=true&lang.ts
|
|
8
|
+
var _hoisted_1 = ["role", "data-ui-toast-state"];
|
|
9
|
+
var _hoisted_2 = { class: "message" };
|
|
10
|
+
var _hoisted_3 = {
|
|
11
|
+
class: "action",
|
|
12
|
+
ref: "action"
|
|
13
|
+
};
|
|
14
|
+
//#endregion
|
|
15
|
+
//#region .build/vue/UiToast.vue
|
|
16
|
+
var UiToast_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
17
|
+
inheritAttrs: false,
|
|
18
|
+
__name: "UiToast",
|
|
19
|
+
props: {
|
|
20
|
+
duration: { default: 0 },
|
|
21
|
+
tone: { default: "neutral" }
|
|
22
|
+
},
|
|
23
|
+
emits: ["dismiss"],
|
|
24
|
+
setup(__props, { emit: __emit }) {
|
|
25
|
+
const props = __props;
|
|
26
|
+
const emit = __emit;
|
|
27
|
+
const root = ref(null);
|
|
28
|
+
const actionElement = useTemplateRef("action");
|
|
29
|
+
/** The values the styles' :host-state() rules test. */
|
|
30
|
+
const hostState = computed(() => [props.tone && `tone tone=${props.tone}`].filter(Boolean).join(" "));
|
|
31
|
+
const isDismissDetail = (detail) => detail !== null && typeof detail === "object" && !Array.isArray(detail) && typeof detail["id"] === "string" && (detail["reason"] === "action" || detail["reason"] === "timeout") && (detail["trigger"] === "keyboard" || detail["trigger"] === "pointer" || detail["trigger"] === "programmatic") && Object.keys(detail).every((key) => [
|
|
32
|
+
"id",
|
|
33
|
+
"reason",
|
|
34
|
+
"trigger"
|
|
35
|
+
].includes(key));
|
|
36
|
+
const dispatch = createDispatch(root, emit, { checks: { dismiss: isDismissDetail } });
|
|
37
|
+
useComponentHost(controllerModule.default, {
|
|
38
|
+
root,
|
|
39
|
+
dispatch,
|
|
40
|
+
props,
|
|
41
|
+
refs: { action: actionElement }
|
|
42
|
+
});
|
|
43
|
+
function text(value) {
|
|
44
|
+
if (Array.isArray(value)) return value.map(text).join(" ");
|
|
45
|
+
return value === null || value === void 0 || typeof value === "object" ? "" : String(value);
|
|
46
|
+
}
|
|
47
|
+
function attribute(value) {
|
|
48
|
+
if (value === null || value === void 0 || value === false || typeof value === "object" && !Array.isArray(value)) return void 0;
|
|
49
|
+
return value === true ? "" : text(value);
|
|
50
|
+
}
|
|
51
|
+
return (_ctx, _cache) => {
|
|
52
|
+
return openBlock(), createElementBlock("div", mergeProps({ "data-component": "ui-toast" }, _ctx.$attrs, {
|
|
53
|
+
role: attribute({
|
|
54
|
+
neutral: "status",
|
|
55
|
+
info: "status",
|
|
56
|
+
success: "status",
|
|
57
|
+
warning: "status",
|
|
58
|
+
danger: "alert"
|
|
59
|
+
}[__props.tone]),
|
|
60
|
+
"data-ui-toast-state": hostState.value || void 0,
|
|
61
|
+
ref_key: "root",
|
|
62
|
+
ref: root
|
|
63
|
+
}), [
|
|
64
|
+
createElementVNode("div", _hoisted_2, [renderSlot(_ctx.$slots, "default", {}, void 0, true)]),
|
|
65
|
+
createElementVNode("div", _hoisted_3, [renderSlot(_ctx.$slots, "action", {}, void 0, true)], 512),
|
|
66
|
+
createVNode(UiIconButton_default, {
|
|
67
|
+
class: "dismiss",
|
|
68
|
+
size: "sm",
|
|
69
|
+
variant: "ghost",
|
|
70
|
+
label: "Dismiss notification",
|
|
71
|
+
round: true
|
|
72
|
+
}, {
|
|
73
|
+
default: withCtx(() => [createVNode(UiIcon_default, { name: "x" })]),
|
|
74
|
+
_: 1
|
|
75
|
+
})
|
|
76
|
+
], 16, _hoisted_1);
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
}), [["__scopeId", "data-v-fdef5729"]]);
|
|
80
|
+
//#endregion
|
|
81
|
+
export { UiToast_default as t };
|
|
@@ -1,65 +1,46 @@
|
|
|
1
1
|
import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper.js";
|
|
2
2
|
import { n as useComponentHost, t as createDispatch } from "./host.js";
|
|
3
|
+
import { t as UiIcon_default } from "./UiIcon.js";
|
|
3
4
|
import { t as UiIconButton_default } from "./UiIconButton.js";
|
|
4
|
-
import { Fragment, createElementBlock, createElementVNode, createVNode, defineComponent, mergeProps, normalizeClass, openBlock, ref, renderList, renderSlot, toDisplayString, withCtx } from "vue";
|
|
5
|
+
import { Fragment, computed, createElementBlock, createElementVNode, createVNode, defineComponent, mergeProps, normalizeClass, openBlock, ref, renderList, renderSlot, toDisplayString, withCtx } from "vue";
|
|
5
6
|
import * as controllerModule from "@threadlabs/looma/components/ui-toast-region/ui-toast-region.js";
|
|
6
7
|
//#region .build/vue/UiToastRegion.vue?vue&type=script&setup=true&lang.ts
|
|
7
|
-
var _hoisted_1 = ["
|
|
8
|
-
var _hoisted_2 =
|
|
9
|
-
|
|
8
|
+
var _hoisted_1 = ["data-ui-toast-region-state"];
|
|
9
|
+
var _hoisted_2 = [
|
|
10
|
+
"id",
|
|
11
|
+
"role",
|
|
12
|
+
"data-tone"
|
|
13
|
+
];
|
|
14
|
+
var _hoisted_3 = { class: "message" };
|
|
15
|
+
var _hoisted_4 = ["data-toast"];
|
|
10
16
|
//#endregion
|
|
11
17
|
//#region .build/vue/UiToastRegion.vue
|
|
12
18
|
var UiToastRegion_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
13
19
|
inheritAttrs: false,
|
|
14
20
|
__name: "UiToastRegion",
|
|
15
21
|
props: {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
default: false
|
|
19
|
-
},
|
|
20
|
-
duration: { default: 5e3 },
|
|
21
|
-
message: { default: "Notification" },
|
|
22
|
-
open: {
|
|
23
|
-
type: Boolean,
|
|
24
|
-
default: false
|
|
25
|
-
}
|
|
22
|
+
duration: { default: 0 },
|
|
23
|
+
placement: { default: "top" }
|
|
26
24
|
},
|
|
27
|
-
emits: [
|
|
28
|
-
"update:open",
|
|
29
|
-
"close",
|
|
30
|
-
"dismiss"
|
|
31
|
-
],
|
|
25
|
+
emits: ["dismiss"],
|
|
32
26
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
33
27
|
const props = __props;
|
|
34
28
|
const emit = __emit;
|
|
35
29
|
const root = ref(null);
|
|
36
|
-
const internalOpen = ref(false);
|
|
37
30
|
const toasts = ref([]);
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
"reason",
|
|
41
|
-
"trigger"
|
|
42
|
-
].includes(key));
|
|
31
|
+
/** The values the styles' :host-state() rules test. */
|
|
32
|
+
const hostState = computed(() => [props.placement && `placement placement=${props.placement}`].filter(Boolean).join(" "));
|
|
43
33
|
const isDismissDetail = (detail) => detail !== null && typeof detail === "object" && !Array.isArray(detail) && typeof detail["id"] === "string" && (detail["reason"] === "action" || detail["reason"] === "timeout") && (detail["trigger"] === "keyboard" || detail["trigger"] === "pointer" || detail["trigger"] === "programmatic") && Object.keys(detail).every((key) => [
|
|
44
34
|
"id",
|
|
45
35
|
"reason",
|
|
46
36
|
"trigger"
|
|
47
37
|
].includes(key));
|
|
48
|
-
const dispatch = createDispatch(root, emit, {
|
|
49
|
-
checks: {
|
|
50
|
-
close: isCloseDetail,
|
|
51
|
-
dismiss: isDismissDetail
|
|
52
|
-
},
|
|
53
|
-
modeled: ["open"]
|
|
54
|
-
});
|
|
38
|
+
const dispatch = createDispatch(root, emit, { checks: { dismiss: isDismissDetail } });
|
|
55
39
|
const { host, ready } = useComponentHost(controllerModule.default, {
|
|
56
40
|
root,
|
|
57
41
|
dispatch,
|
|
58
42
|
props,
|
|
59
|
-
state: {
|
|
60
|
-
internalOpen,
|
|
61
|
-
toasts
|
|
62
|
-
}
|
|
43
|
+
state: { toasts }
|
|
63
44
|
});
|
|
64
45
|
__expose({ show: async (...args) => {
|
|
65
46
|
await ready();
|
|
@@ -73,6 +54,7 @@ var UiToastRegion_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @
|
|
|
73
54
|
"aria-live": "polite",
|
|
74
55
|
popover: "manual"
|
|
75
56
|
}, _ctx.$attrs, {
|
|
57
|
+
"data-ui-toast-region-state": hostState.value || void 0,
|
|
76
58
|
ref_key: "root",
|
|
77
59
|
ref: root
|
|
78
60
|
}), [renderSlot(_ctx.$slots, "default"), (openBlock(true), createElementBlock(Fragment, null, renderList(toasts.value, (toast) => {
|
|
@@ -80,8 +62,9 @@ var UiToastRegion_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @
|
|
|
80
62
|
key: toast.id,
|
|
81
63
|
class: normalizeClass(["toast", { closing: toast.closing }]),
|
|
82
64
|
id: toast.id,
|
|
83
|
-
role: toast.role
|
|
84
|
-
|
|
65
|
+
role: toast.role,
|
|
66
|
+
"data-tone": toast.tone
|
|
67
|
+
}, [createElementVNode("span", _hoisted_3, toDisplayString(toast.message), 1), createElementVNode("span", {
|
|
85
68
|
class: "dismiss",
|
|
86
69
|
"data-toast": toast.id
|
|
87
70
|
}, [createVNode(UiIconButton_default, {
|
|
@@ -90,19 +73,12 @@ var UiToastRegion_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @
|
|
|
90
73
|
round: true,
|
|
91
74
|
label: `Dismiss ${toast.message}`
|
|
92
75
|
}, {
|
|
93
|
-
default: withCtx(() => [
|
|
94
|
-
viewBox: "0 0 24 24",
|
|
95
|
-
fill: "none",
|
|
96
|
-
stroke: "currentColor",
|
|
97
|
-
"stroke-width": "2",
|
|
98
|
-
"stroke-linecap": "round",
|
|
99
|
-
"aria-hidden": "true"
|
|
100
|
-
}, [createElementVNode("path", { d: "M18 6 6 18M6 6l12 12" })], -1)])]),
|
|
76
|
+
default: withCtx(() => [createVNode(UiIcon_default, { name: "x" })]),
|
|
101
77
|
_: 1
|
|
102
|
-
}, 8, ["label"])], 8,
|
|
103
|
-
}), 128))], 16);
|
|
78
|
+
}, 8, ["label"])], 8, _hoisted_4)], 10, _hoisted_2);
|
|
79
|
+
}), 128))], 16, _hoisted_1);
|
|
104
80
|
};
|
|
105
81
|
}
|
|
106
|
-
}), [["__scopeId", "data-v-
|
|
82
|
+
}), [["__scopeId", "data-v-a4727935"]]);
|
|
107
83
|
//#endregion
|
|
108
84
|
export { UiToastRegion_default as t };
|
package/vue/chunks/UiTooltip.js
CHANGED
|
@@ -21,7 +21,7 @@ var UiTooltip_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PU
|
|
|
21
21
|
type: Boolean,
|
|
22
22
|
default: false
|
|
23
23
|
},
|
|
24
|
-
placement: { default: "top
|
|
24
|
+
placement: { default: "top" },
|
|
25
25
|
showDelay: { default: 500 },
|
|
26
26
|
trigger: { default: "hover" }
|
|
27
27
|
},
|
|
@@ -37,11 +37,7 @@ var UiTooltip_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PU
|
|
|
37
37
|
const root = ref(null);
|
|
38
38
|
const internalOpen = ref(false);
|
|
39
39
|
/** The values the styles' :host-state() rules test. */
|
|
40
|
-
const hostState = computed(() => [
|
|
41
|
-
props.inverse && "inverse",
|
|
42
|
-
props.placement && "placement",
|
|
43
|
-
`placement=${encodeURIComponent(props.placement)}`
|
|
44
|
-
].filter(Boolean).join(" "));
|
|
40
|
+
const hostState = computed(() => [props.inverse && "inverse"].filter(Boolean).join(" "));
|
|
45
41
|
const isOpenDetail = (detail) => detail !== null && typeof detail === "object" && !Array.isArray(detail) && typeof detail["open"] === "boolean" && (detail["reason"] === "action" || detail["reason"] === "programmatic" || detail["reason"] === "light-dismiss" || detail["reason"] === "escape") && (detail["trigger"] === "keyboard" || detail["trigger"] === "pointer" || detail["trigger"] === "programmatic") && Object.keys(detail).every((key) => [
|
|
46
42
|
"open",
|
|
47
43
|
"reason",
|
|
@@ -72,6 +68,6 @@ var UiTooltip_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PU
|
|
|
72
68
|
}), [createElementVNode("div", _hoisted_2, [renderSlot(_ctx.$slots, "default", {}, void 0, true)])], 16, _hoisted_1);
|
|
73
69
|
};
|
|
74
70
|
}
|
|
75
|
-
}), [["__scopeId", "data-v-
|
|
71
|
+
}), [["__scopeId", "data-v-bb92970c"]]);
|
|
76
72
|
//#endregion
|
|
77
73
|
export { UiTooltip_default as t };
|
package/vue/chunks/UiTree.js
CHANGED
|
@@ -17,12 +17,14 @@ var UiTree_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE_
|
|
|
17
17
|
type: Boolean,
|
|
18
18
|
default: false
|
|
19
19
|
},
|
|
20
|
-
maxDepth: { default: 0 }
|
|
20
|
+
maxDepth: { default: 0 },
|
|
21
|
+
selection: { default: "none" }
|
|
21
22
|
},
|
|
22
23
|
emits: [
|
|
23
24
|
"update:maxDepth",
|
|
24
25
|
"reorder",
|
|
25
|
-
"reorder-rejected"
|
|
26
|
+
"reorder-rejected",
|
|
27
|
+
"select"
|
|
26
28
|
],
|
|
27
29
|
setup(__props, { emit: __emit }) {
|
|
28
30
|
const props = __props;
|
|
@@ -49,10 +51,12 @@ var UiTree_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE_
|
|
|
49
51
|
"resultingDepth",
|
|
50
52
|
"trigger"
|
|
51
53
|
].includes(key));
|
|
54
|
+
const isSelectDetail = (detail) => detail !== null && typeof detail === "object" && !Array.isArray(detail) && Array.isArray(detail["ids"]) && detail["ids"].every((item) => typeof item === "string") && (detail["trigger"] === "keyboard" || detail["trigger"] === "pointer" || detail["trigger"] === "programmatic") && Object.keys(detail).every((key) => ["ids", "trigger"].includes(key));
|
|
52
55
|
const dispatch = createDispatch(root, emit, {
|
|
53
56
|
checks: {
|
|
54
57
|
reorder: isReorderDetail,
|
|
55
|
-
"reorder-rejected": isReorderRejectedDetail
|
|
58
|
+
"reorder-rejected": isReorderRejectedDetail,
|
|
59
|
+
select: isSelectDetail
|
|
56
60
|
},
|
|
57
61
|
modeled: ["maxDepth"]
|
|
58
62
|
});
|
|
@@ -72,6 +76,6 @@ var UiTree_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE_
|
|
|
72
76
|
}), [renderSlot(_ctx.$slots, "default", {}, void 0, true)], 16, _hoisted_1);
|
|
73
77
|
};
|
|
74
78
|
}
|
|
75
|
-
}), [["__scopeId", "data-v-
|
|
79
|
+
}), [["__scopeId", "data-v-3dab8614"]]);
|
|
76
80
|
//#endregion
|
|
77
81
|
export { UiTree_default as t };
|
package/vue/chunks/UiTreeItem.js
CHANGED
|
@@ -22,23 +22,29 @@ var _hoisted_2 = {
|
|
|
22
22
|
};
|
|
23
23
|
var _hoisted_3 = ["aria-label"];
|
|
24
24
|
var _hoisted_4 = ["disabled", "hidden"];
|
|
25
|
-
var _hoisted_5 = {
|
|
25
|
+
var _hoisted_5 = { class: "selection-hit" };
|
|
26
|
+
var _hoisted_6 = [
|
|
27
|
+
"checked",
|
|
28
|
+
"disabled",
|
|
29
|
+
"aria-label"
|
|
30
|
+
];
|
|
31
|
+
var _hoisted_7 = {
|
|
26
32
|
class: "leading",
|
|
27
33
|
ref: "leading"
|
|
28
34
|
};
|
|
29
|
-
var
|
|
35
|
+
var _hoisted_8 = {
|
|
30
36
|
class: "label",
|
|
31
37
|
ref: "label"
|
|
32
38
|
};
|
|
33
|
-
var
|
|
39
|
+
var _hoisted_9 = {
|
|
34
40
|
class: "label-text",
|
|
35
41
|
ref: "labelText"
|
|
36
42
|
};
|
|
37
|
-
var
|
|
43
|
+
var _hoisted_10 = {
|
|
38
44
|
class: "actions",
|
|
39
45
|
ref: "actions"
|
|
40
46
|
};
|
|
41
|
-
var
|
|
47
|
+
var _hoisted_11 = ["hidden"];
|
|
42
48
|
//#endregion
|
|
43
49
|
//#region .build/vue/UiTreeItem.vue
|
|
44
50
|
var UiTreeItem_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
@@ -63,6 +69,10 @@ var UiTreeItem_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
63
69
|
},
|
|
64
70
|
itemId: { default: "" },
|
|
65
71
|
label: { default: "" },
|
|
72
|
+
lazy: {
|
|
73
|
+
type: Boolean,
|
|
74
|
+
default: false
|
|
75
|
+
},
|
|
66
76
|
marquee: {
|
|
67
77
|
type: Boolean,
|
|
68
78
|
default: false
|
|
@@ -213,9 +223,17 @@ var UiTreeItem_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
213
223
|
class: "disclosure-icon",
|
|
214
224
|
"aria-hidden": "true"
|
|
215
225
|
}, null, -1)])], 8, _hoisted_4),
|
|
216
|
-
createElementVNode("
|
|
217
|
-
|
|
218
|
-
|
|
226
|
+
createElementVNode("label", _hoisted_5, [createElementVNode("input", {
|
|
227
|
+
class: "selection-checkbox",
|
|
228
|
+
type: "checkbox",
|
|
229
|
+
tabindex: "-1",
|
|
230
|
+
checked: __props.selected,
|
|
231
|
+
disabled: __props.disabled,
|
|
232
|
+
"aria-label": `Select ${__props.label}`
|
|
233
|
+
}, null, 8, _hoisted_6)]),
|
|
234
|
+
createElementVNode("span", _hoisted_7, [renderSlot(_ctx.$slots, "leading")], 512),
|
|
235
|
+
createElementVNode("span", _hoisted_8, [createElementVNode("span", _hoisted_9, [renderSlot(_ctx.$slots, "label", {}, () => [createTextVNode(toDisplayString(__props.label), 1)])], 512)], 512),
|
|
236
|
+
createElementVNode("span", _hoisted_10, [renderSlot(_ctx.$slots, "actions")], 512),
|
|
219
237
|
_cache[2] || (_cache[2] = createElementVNode("span", {
|
|
220
238
|
class: "drop-indicator row-drop-indicator",
|
|
221
239
|
"aria-hidden": "true"
|
|
@@ -226,7 +244,7 @@ var UiTreeItem_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
226
244
|
role: "group",
|
|
227
245
|
hidden: !(isContainer.value && internalExpanded.value),
|
|
228
246
|
ref: "children"
|
|
229
|
-
}, [renderSlot(_ctx.$slots, "default")], 8,
|
|
247
|
+
}, [renderSlot(_ctx.$slots, "default")], 8, _hoisted_11),
|
|
230
248
|
_cache[3] || (_cache[3] = createElementVNode("span", {
|
|
231
249
|
class: "drop-indicator subtree-drop-indicator",
|
|
232
250
|
"aria-hidden": "true"
|
|
@@ -234,6 +252,6 @@ var UiTreeItem_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
234
252
|
], 16, _hoisted_1);
|
|
235
253
|
};
|
|
236
254
|
}
|
|
237
|
-
}), [["__scopeId", "data-v-
|
|
255
|
+
}), [["__scopeId", "data-v-ad0fbbba"]]);
|
|
238
256
|
//#endregion
|
|
239
257
|
export { UiTreeItem_default as t };
|