@threadlabs/looma 0.1.13 → 0.1.15
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/dist/{chunk-DQZJTDIB.js → chunk-SVINNT3E.js} +29 -27
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/looma.cjs.js +1 -1
- package/dist/cjs/ui-tree-item.cjs.entry.js +694 -0
- package/dist/cjs/ui-tree.cjs.entry.js +257 -0
- package/dist/collection/collection-manifest.json +3 -1
- package/dist/collection/components/ui-tree/ui-tree.css +11 -0
- package/dist/collection/components/ui-tree/ui-tree.js +252 -0
- package/dist/collection/components/ui-tree-item/ui-tree-item.css +213 -0
- package/dist/collection/components/ui-tree-item/ui-tree-item.js +347 -0
- package/dist/collection/utils/drag-drop.js +51 -0
- package/dist/components/index.d.ts +4 -0
- package/dist/components/index.js +1 -1
- package/dist/components/ui-tree-item.d.ts +11 -0
- package/dist/components/ui-tree-item.js +13 -0
- package/dist/components/ui-tree.d.ts +11 -0
- package/dist/components/ui-tree.js +1 -0
- package/dist/esm/loader.js +1 -1
- package/dist/esm/looma.js +1 -1
- package/dist/esm/ui-tree-item.entry.js +692 -0
- package/dist/esm/ui-tree.entry.js +255 -0
- package/dist/index.cjs +687 -15
- package/dist/index.d.cts +17 -1
- package/dist/index.d.ts +17 -1
- package/dist/index.js +44 -3
- package/dist/looma/looma.esm.js +1 -1
- package/dist/looma/p-95368dee.entry.js +1 -0
- package/dist/looma/p-ef9ca2ed.entry.js +13 -0
- package/dist/types/components/ui-tree/ui-tree.d.ts +28 -0
- package/dist/types/components/ui-tree-item/ui-tree-item.d.ts +36 -0
- package/dist/types/components.d.ts +176 -0
- package/dist/types/utils/drag-drop.d.ts +15 -0
- package/dist/{ui-affordance-scope.entry-SWTDTGGU.js → ui-affordance-scope.entry-PFP2TDKO.js} +1 -1
- package/dist/{ui-avatar-group.entry-VUYE2XOM.js → ui-avatar-group.entry-DQDP325O.js} +1 -1
- package/dist/{ui-avatar.entry-2CKHEJTS.js → ui-avatar.entry-WYIDMOFE.js} +1 -1
- package/dist/{ui-badge.entry-4SWSD3R5.js → ui-badge.entry-VGHXPEDT.js} +1 -1
- package/dist/{ui-button.entry-SS3AS32R.js → ui-button.entry-LKPLOJ22.js} +1 -1
- package/dist/{ui-checkbox.entry-V7OYTOLW.js → ui-checkbox.entry-J74HEA22.js} +1 -1
- package/dist/{ui-context-menu.entry-UCLTQESP.js → ui-context-menu.entry-MQM2FCLI.js} +1 -1
- package/dist/{ui-dialog.entry-PXIVZF7D.js → ui-dialog.entry-DQMMDO4Z.js} +1 -1
- package/dist/{ui-disclosure.entry-ZADBPM2D.js → ui-disclosure.entry-ONF7UZDC.js} +1 -1
- package/dist/{ui-floating-action-button.entry-WNBWY36T.js → ui-floating-action-button.entry-FKTGVC5T.js} +1 -1
- package/dist/{ui-form-field.entry-RZPSWN6Y.js → ui-form-field.entry-M3ISWQNU.js} +1 -1
- package/dist/{ui-icon-button.entry-ILU7RD7M.js → ui-icon-button.entry-AWFIQUHM.js} +1 -1
- package/dist/{ui-input.entry-FEIUK4EE.js → ui-input.entry-JZ6RETMT.js} +1 -1
- package/dist/{ui-menu-item.entry-UJVECPSK.js → ui-menu-item.entry-5MFR5LFL.js} +1 -1
- package/dist/{ui-menu.entry-MTCE3F5U.js → ui-menu.entry-IOEIDATQ.js} +1 -1
- package/dist/{ui-popover.entry-OAME35VB.js → ui-popover.entry-ELCMKO6Y.js} +1 -1
- package/dist/{ui-radio-group.entry-CPFX4LVA.js → ui-radio-group.entry-RJHUPPEM.js} +1 -1
- package/dist/{ui-radio.entry-44OTRYPB.js → ui-radio.entry-3VRDPOY4.js} +1 -1
- package/dist/{ui-search-result-row.entry-ZU5SL5OP.js → ui-search-result-row.entry-J34YPAV7.js} +1 -1
- package/dist/{ui-search-shell.entry-G7HG4RKU.js → ui-search-shell.entry-IJ4UUP27.js} +1 -1
- package/dist/{ui-select.entry-NAONXMFG.js → ui-select.entry-C6YD3HQ5.js} +1 -1
- package/dist/{ui-switch.entry-SE4ZTCS2.js → ui-switch.entry-UZDF5QTI.js} +1 -1
- package/dist/{ui-tabs.entry-2YG2JE3K.js → ui-tabs.entry-YRAKWOMR.js} +1 -1
- package/dist/{ui-textarea.entry-PV3APDLY.js → ui-textarea.entry-JLDKFT3K.js} +1 -1
- package/dist/{ui-toast-region.entry-WH2OL3FR.js → ui-toast-region.entry-GC7C7KXF.js} +1 -1
- package/dist/{ui-tooltip.entry-FY563DP4.js → ui-tooltip.entry-F26XDTYX.js} +1 -1
- package/dist/{ui-top-bar.entry-LJSZXFAH.js → ui-top-bar.entry-5W5UA5KV.js} +1 -1
- package/dist/ui-tree-item.entry-3LM7IXIK.js +385 -0
- package/dist/ui-tree.entry-X4FU42A6.js +244 -0
- package/editor.css +42 -0
- package/package.json +1 -1
- package/styles.css +18 -6
- package/vue/{chunk-YN4IUYVY.js → chunk-IITL6UBR.js} +7 -1
- package/vue/editor/index.d.ts +41 -3
- package/vue/editor/index.js +273 -4
- package/vue/index.d.ts +24 -1
- package/vue/index.js +5 -1
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
getElement,
|
|
12
12
|
h,
|
|
13
13
|
registerInstance
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-SVINNT3E.js";
|
|
15
15
|
|
|
16
16
|
// dist/esm/ui-context-menu.entry.js
|
|
17
17
|
var uiContextMenuCss = () => `:host{display:contents}.menu{position:fixed;z-index:var(--ui-z-overlay, 1000);min-width:12rem}.menu[data-open]{display:block}.menu:not([data-open]){display:none !important}`;
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
getElement,
|
|
12
12
|
h,
|
|
13
13
|
registerInstance
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-SVINNT3E.js";
|
|
15
15
|
|
|
16
16
|
// dist/esm/ui-dialog.entry.js
|
|
17
17
|
var uiDialogCss = () => `:host{display:block}:host:not([data-open]){display:none}:host dialog{--ui-dialog-duration:var(--ui-motion-base);--ui-dialog-viewport-gap:var(--ui-space-4, 1rem);position:fixed;inset:0;inline-size:min( calc(100% - (var(--ui-dialog-viewport-gap) * 2)), var(--ui-dialog-max-width, 440px) );max-inline-size:none;max-block-size:calc(100dvh - (var(--ui-dialog-viewport-gap) * 2));margin:auto;padding:var(--ui-space-4);overflow:auto;background:var(--ui-surface-elevated);border:1px solid var(--ui-border-default);border-radius:var(--ui-radius-dialog);box-shadow:var(--ui-shadow-dialog);visibility:hidden;pointer-events:none;opacity:0;transform:scale(0.96);transition:opacity var(--ui-dialog-duration) var(--ui-motion-ease), transform var(--ui-dialog-duration) var(--ui-motion-ease), visibility var(--ui-dialog-duration), display var(--ui-dialog-duration) var(--ui-motion-ease) allow-discrete, overlay var(--ui-dialog-duration) var(--ui-motion-ease) allow-discrete}:host dialog[open]{visibility:visible;pointer-events:auto;opacity:1;transform:scale(1);animation:ui-dialog-enter var(--ui-dialog-duration) var(--ui-motion-ease)}@keyframes ui-dialog-enter{from{opacity:0;transform:scale(0.96)}}:host dialog::backdrop{background-color:transparent;transition:background-color var(--ui-dialog-duration) var(--ui-motion-ease), display var(--ui-dialog-duration) var(--ui-motion-ease) allow-discrete, overlay var(--ui-dialog-duration) var(--ui-motion-ease) allow-discrete}:host dialog[open]::backdrop{background-color:var(--ui-overlay-backdrop);animation:ui-dialog-backdrop-enter var(--ui-dialog-duration) var(--ui-motion-ease)}@keyframes ui-dialog-backdrop-enter{from{background-color:transparent}}`;
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
Host,
|
|
3
3
|
h,
|
|
4
4
|
registerInstance
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-SVINNT3E.js";
|
|
6
6
|
|
|
7
7
|
// dist/esm/ui-floating-action-button.entry.js
|
|
8
8
|
var uiFloatingActionButtonCss = () => `:host{position:fixed;inset-block-end:calc( var(--ui-floating-action-button-bottom, var(--ui-space-6, 1.5rem)) + env(safe-area-inset-bottom) );inset-inline-end:max( var(--ui-floating-action-button-inline-end, var(--ui-space-5, 1.25rem)), env(safe-area-inset-right) );inline-size:var(--ui-floating-action-button-size, 56px);block-size:var(--ui-floating-action-button-size, 56px);display:inline-flex;z-index:var(--ui-floating-action-button-z-index, 100)}button{appearance:none;inline-size:100%;block-size:100%;border:none;border-radius:999px;margin:0;padding:0;display:inline-flex;align-items:center;justify-content:center;background:var(--ui-floating-action-button-bg, var(--ui-accent-solid));color:var(--ui-floating-action-button-color, var(--ui-text-on-accent));box-shadow:var( --ui-floating-action-button-shadow, 0 4px 12px color-mix(in srgb, var(--ui-accent-solid) 40%, transparent) );cursor:pointer;transition:background-color var(--ui-motion-fast, 160ms) var(--ui-motion-ease, ease), transform var(--ui-motion-fast, 160ms) var(--ui-motion-ease, ease), box-shadow var(--ui-motion-fast, 160ms) var(--ui-motion-ease, ease)}button:hover:enabled{background:var(--ui-floating-action-button-hover-bg, var(--ui-accent-hover));box-shadow:var( --ui-floating-action-button-hover-shadow, 0 6px 16px color-mix(in srgb, var(--ui-accent-solid) 50%, transparent) )}button:active:enabled{transform:scale(var(--ui-floating-action-button-active-scale, 0.94))}button:focus-visible{outline:2px solid var(--ui-focus-ring);outline-offset:2px}button:disabled,:host([disabled]){opacity:0.6;cursor:not-allowed}::slotted(svg){inline-size:var(--ui-floating-action-button-icon-size, 24px);block-size:var(--ui-floating-action-button-icon-size, 24px);flex-shrink:0}@media (min-width: 768px){:host([mobile-only]){display:none}}`;
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
getElement,
|
|
7
7
|
h,
|
|
8
8
|
registerInstance
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-SVINNT3E.js";
|
|
10
10
|
|
|
11
11
|
// dist/esm/ui-form-field.entry.js
|
|
12
12
|
var uiFormFieldCss = () => `:host{display:grid;gap:var(--ui-space-2);color:var(--ui-text-primary)}::slotted(label){color:var(--ui-text-secondary);font-size:0.95rem}::slotted([data-slot='help']){color:var(--ui-text-muted);font-size:0.875rem}::slotted([data-slot='error']),::slotted([role='alert']){color:var(--ui-accent-active);font-size:0.875rem}`;
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
Host,
|
|
3
3
|
h,
|
|
4
4
|
registerInstance
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-SVINNT3E.js";
|
|
6
6
|
|
|
7
7
|
// dist/esm/ui-icon-button.entry.js
|
|
8
8
|
var uiIconButtonCss = () => `:host{display:inline-flex;color:var(--ui-text-secondary)}:host([anticipatory]){position:relative}:host([anticipatory])::before{content:'';position:absolute;inset:50% auto auto 50%;z-index:1;inline-size:var(--ui-affordance-guide-size, 0.25rem);block-size:var(--ui-affordance-guide-size, 0.25rem);border-radius:var(--ui-radius-round, 999px);background:var(--ui-affordance-guide-color, var(--ui-border-strong));opacity:var(--ui-affordance-guide-opacity, 0.42);transform:translate(-50%, -50%);transition:opacity var(--ui-affordance-motion, var(--ui-motion-fast)) var(--ui-motion-ease);pointer-events:none}:host([anticipatory]) button{opacity:0;transform:scale(0.72);pointer-events:none}:host([anticipatory][data-ui-proximity='near'])::before,:host([anticipatory]:focus-within)::before,:host([anticipatory]:hover)::before,:host([anticipatory][variant='solid'])::before{opacity:0}:host([anticipatory][data-ui-proximity='near']) button,:host([anticipatory]:focus-within) button,:host([anticipatory]:hover) button,:host([anticipatory][variant='solid']) button{opacity:1;transform:scale(1);pointer-events:auto}button{appearance:none;inline-size:var(--ui-icon-button-size, 2.5rem);block-size:var(--ui-icon-button-size, 2.5rem);min-inline-size:var(--ui-icon-button-size, 2.5rem);min-block-size:var(--ui-icon-button-size, 2.5rem);padding:0;margin:0;border:1px solid transparent;border-radius:var(--ui-icon-button-radius, var(--ui-radius-2));background:var(--ui-icon-button-bg, transparent);color:inherit;display:inline-flex;align-items:center;justify-content:center;cursor:pointer;transition:background-color var(--ui-motion-fast) var(--ui-motion-ease), border-color var(--ui-motion-fast) var(--ui-motion-ease), color var(--ui-motion-fast) var(--ui-motion-ease), box-shadow var(--ui-motion-fast) var(--ui-motion-ease), transform var(--ui-motion-fast) var(--ui-motion-ease)}@media (hover: none), (pointer: coarse){:host([anticipatory])::before{opacity:0}:host([anticipatory]) button{opacity:1;transform:none;pointer-events:auto}}:host([size='sm']) button{inline-size:var(--ui-icon-button-size-sm, 2rem);block-size:var(--ui-icon-button-size-sm, 2rem);min-inline-size:var(--ui-icon-button-size-sm, 2rem);min-block-size:var(--ui-icon-button-size-sm, 2rem)}:host([size='lg']) button{inline-size:var(--ui-icon-button-size-lg, 2.75rem);block-size:var(--ui-icon-button-size-lg, 2.75rem);min-inline-size:var(--ui-icon-button-size-lg, 2.75rem);min-block-size:var(--ui-icon-button-size-lg, 2.75rem)}:host([variant='outline']) button{border-color:var(--ui-icon-button-border, var(--ui-border-default));background:var(--ui-icon-button-outline-bg, var(--ui-surface-default));color:var(--ui-icon-button-outline-color, var(--ui-text-primary))}:host([variant='solid']) button{background:var(--ui-icon-button-solid-bg, var(--ui-accent-solid));color:var(--ui-icon-button-solid-color, var(--ui-text-on-accent));box-shadow:var( --ui-icon-button-solid-shadow, 0 1px 2px color-mix(in srgb, var(--ui-accent-solid) 18%, transparent) )}button:hover:enabled{background:var(--ui-icon-button-hover-bg, var(--ui-surface-muted));color:var(--ui-icon-button-hover-color, var(--ui-text-primary))}:host([variant='outline']) button:hover:enabled{border-color:var(--ui-icon-button-hover-border, var(--ui-border-strong))}:host([variant='solid']) button:hover:enabled{background:var(--ui-icon-button-solid-hover-bg, var(--ui-accent-hover))}button:active:enabled{transform:scale(var(--ui-icon-button-active-scale, 0.96))}button:focus-visible{outline:2px solid var(--ui-focus-ring);outline-offset:2px}button:disabled,:host([disabled]){opacity:0.6;cursor:not-allowed}::slotted(svg){inline-size:var(--ui-icon-button-icon-size, 1.125rem);block-size:var(--ui-icon-button-icon-size, 1.125rem);flex-shrink:0;stroke-width:var(--ui-icon-button-icon-stroke-width, 1.75)}`;
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
getElement,
|
|
8
8
|
h,
|
|
9
9
|
registerInstance
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-SVINNT3E.js";
|
|
11
11
|
|
|
12
12
|
// dist/esm/ui-input.entry.js
|
|
13
13
|
var uiInputCss = () => `:host{display:inline-flex;color:var(--ui-text-primary)}::slotted(input){width:100%;appearance:none;border:1px solid var(--ui-border-default);border-radius:var(--ui-radius-2);background:var(--ui-surface-default);color:inherit;font:inherit;line-height:var(--ui-line-height-md);padding:var(--ui-space-2) var(--ui-space-3);margin:0;transition:border-color var(--ui-motion-fast) var(--ui-motion-ease), box-shadow var(--ui-motion-fast) var(--ui-motion-ease), background-color var(--ui-motion-fast) var(--ui-motion-ease)}::slotted(input:hover:not(:focus):not(:disabled)){border-color:var(--ui-border-strong)}::slotted(input:focus){border-color:var(--ui-focus-ring);box-shadow:0 0 0 3px var(--ui-accent-soft)}:host([data-invalid='true'])::slotted(input),::slotted(input[aria-invalid='true']){border-color:var(--ui-accent-active)}::slotted(input:disabled){background:var(--ui-surface-muted);color:var(--ui-text-muted);cursor:not-allowed}::slotted(input:focus-visible){outline:2px solid var(--ui-focus-ring);outline-offset:2px}`;
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
Host,
|
|
3
3
|
h,
|
|
4
4
|
registerInstance
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-SVINNT3E.js";
|
|
6
6
|
|
|
7
7
|
// dist/esm/ui-menu-item.entry.js
|
|
8
8
|
var uiMenuItemCss = () => `:host{display:block;width:100%;padding:var(--ui-space-2) var(--ui-space-3);text-align:left;background:none;border:none;border-radius:var(--ui-radius-2);color:var(--ui-text-primary);font-size:var(--ui-font-size-md);font-weight:var(--ui-font-medium, 500);cursor:pointer;transition:background-color var(--ui-motion-fast) var(--ui-motion-ease), color var(--ui-motion-fast) var(--ui-motion-ease)}:host(:hover:not([aria-disabled='true']):not([disabled])){background:var(--ui-surface-subtle)}:host([aria-disabled='true']),:host([disabled]){opacity:0.6;cursor:not-allowed}`;
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
getElement,
|
|
8
8
|
h,
|
|
9
9
|
registerInstance
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-SVINNT3E.js";
|
|
11
11
|
|
|
12
12
|
// dist/esm/ui-menu.entry.js
|
|
13
13
|
var uiMenuCss = () => `:host{--ui-menu-viewport-gap:var(--ui-space-2, 0.5rem);display:flex;flex-direction:column;inline-size:max-content;min-inline-size:min(12rem, calc(100vw - (var(--ui-menu-viewport-gap) * 2)));max-inline-size:calc(100vw - (var(--ui-menu-viewport-gap) * 2));padding:var(--ui-space-1);background:var(--ui-surface-elevated);border:1px solid var(--ui-border-default);border-radius:var(--ui-radius-3);box-shadow:var(--ui-shadow-lg)}::slotted(ui-menu-item){display:block;width:100%;padding:var(--ui-space-2) var(--ui-space-3);text-align:left;background:none;border:none;border-radius:var(--ui-radius-2);color:var(--ui-text-primary);font-size:var(--ui-font-size-md);font-weight:var(--ui-font-medium, 500);cursor:pointer;transition:background-color var(--ui-motion-fast) var(--ui-motion-ease), color var(--ui-motion-fast) var(--ui-motion-ease)}::slotted(ui-menu-item:hover:not([aria-disabled='true']):not([disabled])){background:var(--ui-surface-subtle)}::slotted(ui-menu-item[aria-disabled='true']),::slotted(ui-menu-item[disabled]){opacity:0.6;cursor:not-allowed}`;
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
getElement,
|
|
12
12
|
h,
|
|
13
13
|
registerInstance
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-SVINNT3E.js";
|
|
15
15
|
|
|
16
16
|
// dist/esm/ui-popover.entry.js
|
|
17
17
|
var uiPopoverCss = () => `:host{--ui-popover-viewport-gap:var(--ui-space-2, 0.5rem);padding:var(--ui-space-3);background:var(--ui-surface-elevated);border:1px solid var(--ui-border-default);border-radius:var(--ui-radius-3);box-shadow:var(--ui-shadow-lg);max-inline-size:min( 20rem, calc(100vw - (var(--ui-popover-viewport-gap) * 2)) );max-block-size:calc(100dvh - (var(--ui-popover-viewport-gap) * 2));overflow:auto}`;
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
getElement,
|
|
8
8
|
h,
|
|
9
9
|
registerInstance
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-SVINNT3E.js";
|
|
11
11
|
|
|
12
12
|
// dist/esm/ui-radio-group.entry.js
|
|
13
13
|
var uiRadioGroupCss = () => `:host{display:inline-flex;align-items:center;gap:var(--ui-space-2)}:host([data-orientation='vertical']){display:inline-grid;justify-items:start}`;
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
getElement,
|
|
8
8
|
h,
|
|
9
9
|
registerInstance
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-SVINNT3E.js";
|
|
11
11
|
|
|
12
12
|
// dist/esm/ui-radio.entry.js
|
|
13
13
|
var uiRadioCss = () => `:host{display:inline-flex;align-items:center;gap:var(--ui-space-2);color:var(--ui-text-primary)}:host([data-disabled='true']),:host([aria-disabled='true']){opacity:0.6;cursor:not-allowed}::slotted(input[type='radio']){accent-color:var(--ui-accent-solid);cursor:pointer}::slotted(input[type='radio']:focus-visible){outline:2px solid var(--ui-accent-solid);outline-offset:2px}`;
|
package/dist/{ui-search-result-row.entry-ZU5SL5OP.js → ui-search-result-row.entry-J34YPAV7.js}
RENAMED
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
Host,
|
|
3
3
|
h,
|
|
4
4
|
registerInstance
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-SVINNT3E.js";
|
|
6
6
|
|
|
7
7
|
// dist/esm/ui-search-result-row.entry.js
|
|
8
8
|
var uiSearchResultRowCss = () => `:host{display:block}.search-result-row{appearance:none;inline-size:100%;min-block-size:var(--ui-search-result-row-min-height, 56px);margin:0;padding-block:var(--ui-search-result-row-padding-block, var(--ui-space-3, 0.75rem));padding-inline:var(--ui-search-result-row-padding-inline, var(--ui-space-4, 1rem));display:flex;align-items:flex-start;gap:var(--ui-search-result-row-gap, var(--ui-space-3, 0.75rem));background:var(--ui-search-result-row-bg, transparent);border:none;border-block-end:1px solid var(--ui-search-result-row-border, var(--ui-border, #e5e7eb));color:inherit;cursor:pointer;text-align:left;transition:background-color var(--ui-motion-fast, 160ms) var(--ui-motion-ease, ease)}:host(:last-child) .search-result-row{border-block-end:none}.search-result-row:hover:enabled{background:var(--ui-search-result-row-hover-bg, color-mix(in srgb, var(--ui-surface, #ffffff) 85%, black 3%))}:host([selected]) .search-result-row{background:var( --ui-search-result-row-selected-bg, var(--ui-search-result-row-hover-bg, color-mix(in srgb, var(--ui-surface, #ffffff) 85%, black 3%)) )}.search-result-row:focus-visible{outline:2px solid var(--ui-focus-ring, #2563eb);outline-offset:-2px}.search-result-row:disabled,:host([disabled]) .search-result-row{opacity:0.6;cursor:not-allowed}.search-result-row__leading,.search-result-row__trailing{display:inline-flex;align-items:flex-start;flex-shrink:0}.search-result-row__content{min-inline-size:0;flex:1;display:flex;flex-direction:column}.search-result-row__title,.search-result-row__meta,.search-result-row__excerpt{display:block;min-inline-size:0}[hidden]{display:none}::slotted([slot='title']),::slotted([slot='meta']),::slotted([slot='excerpt']){display:block;margin:0}`;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
h,
|
|
3
3
|
registerInstance
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-SVINNT3E.js";
|
|
5
5
|
|
|
6
6
|
// dist/esm/ui-search-shell.entry.js
|
|
7
7
|
var uiSearchShellCss = () => `:host{position:fixed;inset:0;z-index:var(--ui-search-shell-z-index, 400);display:block}.search-shell{position:absolute;inset:0;display:flex;align-items:flex-start;justify-content:center;padding-block-start:var(--ui-search-shell-padding-top, 10vh)}.search-shell__panel{position:relative;inline-size:min( calc(100% - (var(--ui-search-shell-margin-inline, var(--ui-space-4, 1rem)) * 2)), var(--ui-search-shell-max-width, 640px) );max-block-size:var(--ui-search-shell-max-height, 80vh);display:flex;flex-direction:column;overflow:hidden;background:var(--ui-search-shell-bg, var(--ui-surface, #ffffff));border:1px solid var(--ui-search-shell-border, var(--ui-border, #e5e7eb));border-radius:var(--ui-search-shell-radius, var(--ui-radius-xl, 1rem));box-shadow:var(--ui-search-shell-shadow, var(--ui-shadow-lg, 0 8px 24px rgba(0, 0, 0, 0.12)))}.search-shell__search,.search-shell__status,.search-shell__footer{flex-shrink:0}.search-shell__body{flex:1;min-block-size:0}[hidden]{display:none}@media (max-width: 767px){.search-shell{padding-block-start:0;align-items:stretch}.search-shell__panel{inline-size:100%;block-size:100vh;block-size:100dvh;max-block-size:none;border-radius:0;border-inline:none;border-block-start:none}}`;
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
getElement,
|
|
8
8
|
h,
|
|
9
9
|
registerInstance
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-SVINNT3E.js";
|
|
11
11
|
|
|
12
12
|
// dist/esm/ui-select.entry.js
|
|
13
13
|
var uiSelectCss = () => `:host{display:inline-flex;color:var(--ui-text-primary)}::slotted(select){width:100%;appearance:none;border:1px solid var(--ui-border-default);border-radius:var(--ui-radius-2);background-color:var(--ui-surface-default);color:inherit;font:inherit;line-height:var(--ui-line-height-md);padding-block:var(--ui-select-padding-block, var(--ui-space-2));padding-inline-start:var(--ui-select-padding-inline-start, var(--ui-space-3));padding-inline-end:var(--ui-select-padding-inline-end, calc(var(--ui-space-6) + var(--ui-space-3)));margin:0;background-image:linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);background-position:calc(100% - 1rem) calc(50% - 2px), calc(100% - 0.7rem) calc(50% - 2px);background-size:0.35rem 0.35rem, 0.35rem 0.35rem;background-repeat:no-repeat;transition:border-color var(--ui-motion-fast) var(--ui-motion-ease), box-shadow var(--ui-motion-fast) var(--ui-motion-ease), background-color var(--ui-motion-fast) var(--ui-motion-ease)}::slotted(select:hover:not(:focus):not(:disabled)){border-color:var(--ui-border-strong)}::slotted(select:focus){border-color:var(--ui-focus-ring);box-shadow:0 0 0 3px var(--ui-accent-soft)}:host([data-invalid='true'])::slotted(select),::slotted(select[aria-invalid='true']){border-color:var(--ui-accent-active)}::slotted(select:disabled){background-color:var(--ui-surface-muted);color:var(--ui-text-muted);cursor:not-allowed}::slotted(select:focus-visible){outline:2px solid var(--ui-focus-ring);outline-offset:2px}::slotted(select[multiple]),::slotted(select[size]:not([size='1'])){background-image:none;padding-inline-end:var(--ui-select-padding-inline-start, var(--ui-space-3))}`;
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
getElement,
|
|
7
7
|
h,
|
|
8
8
|
registerInstance
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-SVINNT3E.js";
|
|
10
10
|
|
|
11
11
|
// dist/esm/ui-switch.entry.js
|
|
12
12
|
var uiSwitchCss = () => `:host{display:inline-flex;align-items:center;gap:var(--ui-space-2);color:var(--ui-text-primary)}:host([aria-disabled='true']),:host([data-disabled='true']){opacity:0.6;cursor:not-allowed}:host([role='switch']){cursor:pointer}:host input[type='checkbox']{appearance:none;-webkit-appearance:none;display:block;position:relative;width:2.25rem;height:1.25rem;padding:0;border:1px solid var(--ui-border-default);border-radius:999px;background:var(--ui-surface-muted);cursor:pointer;transition:background-color var(--ui-motion-fast) var(--ui-motion-ease), border-color var(--ui-motion-fast) var(--ui-motion-ease);margin:0}:host input[type='checkbox']::after{content:'';position:absolute;top:2px;left:2px;width:0.875rem;height:0.875rem;border-radius:999px;background:var(--ui-surface-default);border:1px solid var(--ui-border-default);transition:transform var(--ui-motion-fast) var(--ui-motion-ease)}:host input[type='checkbox']:checked{background:var(--ui-accent-solid);border-color:var(--ui-accent-solid)}:host input[type='checkbox']:checked::after{transform:translateX(calc(2.25rem - 0.875rem - 4px));background:var(--ui-text-on-accent);border-color:var(--ui-text-on-accent)}:host input[type='checkbox']:focus-visible{outline:2px solid var(--ui-accent-solid);outline-offset:2px}`;
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
getElement,
|
|
8
8
|
h,
|
|
9
9
|
registerInstance
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-SVINNT3E.js";
|
|
11
11
|
|
|
12
12
|
// dist/esm/ui-tabs.entry.js
|
|
13
13
|
var uiTabsCss = () => `:host{display:flex;flex-direction:column;gap:0}:host([data-orientation='vertical']){flex-direction:row}::slotted([role='tablist']){display:flex;gap:0;max-inline-size:100%;overflow-x:auto;overscroll-behavior-inline:contain;border-bottom:1px solid var(--ui-border-default)}:host([data-orientation='vertical']) ::slotted([role='tablist']){flex-direction:column;border-bottom:none;border-inline-end:1px solid var(--ui-border-default)}::slotted(button[role='tab']),::slotted([role='tab']),::slotted(ui-button) button[role='tab']{padding:var(--ui-space-2) var(--ui-space-3);font-size:var(--ui-font-size-sm);font-weight:var(--ui-font-medium, 500);color:var(--ui-text-secondary);background:none;border:none;border-bottom:2px solid transparent;margin-bottom:-1px;cursor:pointer;transition:color var(--ui-motion-fast) var(--ui-motion-ease);box-shadow:none}::slotted(button[role='tab']:hover),::slotted([role='tab']:hover){color:var(--ui-text-primary)}::slotted(button[role='tab'][aria-selected='true']),::slotted([role='tab'][aria-selected='true']){color:var(--ui-accent-solid);border-bottom-color:var(--ui-accent-solid)}:host([data-orientation='vertical']) ::slotted(button[role='tab']),:host([data-orientation='vertical']) ::slotted([role='tab']){border-bottom:none;border-inline-end:2px solid transparent;margin-bottom:0;margin-inline-end:-1px}:host([data-orientation='vertical']) ::slotted(button[role='tab'][aria-selected='true']),:host([data-orientation='vertical']) ::slotted([role='tab'][aria-selected='true']){border-inline-end-color:var(--ui-accent-solid)}::slotted([role='tabpanel']){padding:var(--ui-space-4)}`;
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
getElement,
|
|
8
8
|
h,
|
|
9
9
|
registerInstance
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-SVINNT3E.js";
|
|
11
11
|
|
|
12
12
|
// dist/esm/ui-textarea.entry.js
|
|
13
13
|
var uiTextareaCss = () => `:host{display:inline-flex;color:var(--ui-text-primary)}::slotted(textarea){width:100%;appearance:none;border:1px solid var(--ui-border-default);border-radius:var(--ui-radius-2);background:var(--ui-surface-default);color:inherit;font:inherit;line-height:var(--ui-line-height-md);min-block-size:calc(var(--ui-space-12, 3rem) * 2);padding:var(--ui-space-2) var(--ui-space-3);margin:0;resize:vertical;transition:border-color var(--ui-motion-fast) var(--ui-motion-ease), box-shadow var(--ui-motion-fast) var(--ui-motion-ease), background-color var(--ui-motion-fast) var(--ui-motion-ease)}::slotted(textarea:hover:not(:focus):not(:disabled)){border-color:var(--ui-border-strong)}::slotted(textarea:focus){border-color:var(--ui-focus-ring);box-shadow:0 0 0 3px var(--ui-accent-soft)}:host([data-invalid='true'])::slotted(textarea),::slotted(textarea[aria-invalid='true']){border-color:var(--ui-accent-active)}::slotted(textarea:disabled){background:var(--ui-surface-muted);color:var(--ui-text-muted);cursor:not-allowed}::slotted(textarea:focus-visible){outline:2px solid var(--ui-focus-ring);outline-offset:2px}`;
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
getElement,
|
|
8
8
|
h,
|
|
9
9
|
registerInstance
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-SVINNT3E.js";
|
|
11
11
|
|
|
12
12
|
// dist/esm/ui-toast-region.entry.js
|
|
13
13
|
var uiToastRegionCss = () => `:host{position:fixed;top:calc(var(--ui-space-4) + env(safe-area-inset-top));left:50%;transform:translateX(-50%);z-index:9999;display:grid;gap:var(--ui-space-2);inline-size:min(24rem, calc(100vw - (var(--ui-space-4) * 2)));max-inline-size:100%;pointer-events:none}:host>*{pointer-events:auto}::slotted([data-ui-toast]){display:grid;grid-template-columns:1fr auto;gap:var(--ui-space-2);align-items:start;border:1px solid var(--ui-border-default);border-radius:var(--ui-radius-3);padding:var(--ui-space-3) var(--ui-space-4);background:var(--ui-surface-elevated);color:var(--ui-text-primary);box-shadow:var(--ui-shadow-lg);animation:ui-toast-enter 0.25s var(--ui-motion-ease) forwards}@keyframes ui-toast-enter{from{opacity:0;transform:translateY(-0.5rem)}to{opacity:1;transform:translateY(0)}}::slotted([data-ui-toast][aria-hidden='true']){display:none}::slotted([data-ui-toast-dismiss]){border:0;background:transparent;color:var(--ui-text-secondary);cursor:pointer;font:inherit}`;
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
getElement,
|
|
12
12
|
h,
|
|
13
13
|
registerInstance
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-SVINNT3E.js";
|
|
15
15
|
|
|
16
16
|
// dist/esm/ui-tooltip.entry.js
|
|
17
17
|
var uiTooltipCss = () => `:host{display:inline-block;border:1px solid var(--ui-border-default);border-radius:var(--ui-radius-2);background:var(--ui-surface-elevated);color:var(--ui-text-primary);padding:var(--ui-space-2) var(--ui-space-3);font-size:var(--ui-font-size-sm);box-shadow:var(--ui-shadow-md)}:host([hidden]){display:none !important}`;
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
getElement,
|
|
4
4
|
h,
|
|
5
5
|
registerInstance
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-SVINNT3E.js";
|
|
7
7
|
|
|
8
8
|
// dist/esm/ui-top-bar.entry.js
|
|
9
9
|
var uiTopBarCss = () => `:host{position:sticky;inset-block-start:0;z-index:var(--ui-top-bar-z-index, 100);display:block}.top-bar{min-block-size:calc(var(--ui-top-bar-height, 56px) + env(safe-area-inset-top));display:flex;align-items:center;gap:var(--ui-top-bar-gap, var(--ui-space-3, 0.75rem));padding-block-start:env(safe-area-inset-top);padding-inline-start:max( var(--ui-top-bar-padding-inline, var(--ui-space-4, 1rem)), env(safe-area-inset-left) );padding-inline-end:max( var(--ui-top-bar-padding-inline, var(--ui-space-4, 1rem)), env(safe-area-inset-right) );background:var(--ui-top-bar-bg, var(--ui-surface, #ffffff));border-block-end:1px solid var(--ui-top-bar-border, var(--ui-border, #e5e7eb))}.top-bar__leading,.top-bar__search,.top-bar__actions{display:flex;align-items:center;flex-shrink:0}.top-bar__actions{gap:var(--ui-top-bar-actions-gap, var(--ui-space-1, 0.25rem))}.top-bar__title{min-inline-size:0;flex:1}[hidden]{display:none}@media (min-width: 768px){:host{display:none}}`;
|
|
@@ -0,0 +1,385 @@
|
|
|
1
|
+
import {
|
|
2
|
+
dispatchDetail,
|
|
3
|
+
eventToTrigger
|
|
4
|
+
} from "./chunk-UL7UIUJZ.js";
|
|
5
|
+
import {
|
|
6
|
+
Host,
|
|
7
|
+
getElement,
|
|
8
|
+
h,
|
|
9
|
+
registerInstance
|
|
10
|
+
} from "./chunk-SVINNT3E.js";
|
|
11
|
+
|
|
12
|
+
// dist/esm/ui-tree-item.entry.js
|
|
13
|
+
var Bold = [
|
|
14
|
+
["path", { d: "M6 12h9a4 4 0 0 1 0 8H7a1 1 0 0 1-1-1V5a1 1 0 0 1 1-1h7a4 4 0 0 1 0 8" }]
|
|
15
|
+
];
|
|
16
|
+
var Braces = [
|
|
17
|
+
["path", { d: "M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1" }],
|
|
18
|
+
["path", { d: "M16 21h1a2 2 0 0 0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1" }]
|
|
19
|
+
];
|
|
20
|
+
var ChevronDown = [["path", { d: "m6 9 6 6 6-6" }]];
|
|
21
|
+
var ChevronLeft = [["path", { d: "m15 18-6-6 6-6" }]];
|
|
22
|
+
var CodeXml = [
|
|
23
|
+
["path", { d: "m18 16 4-4-4-4" }],
|
|
24
|
+
["path", { d: "m6 8-4 4 4 4" }],
|
|
25
|
+
["path", { d: "m14.5 4-5 16" }]
|
|
26
|
+
];
|
|
27
|
+
var Columns3 = [
|
|
28
|
+
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }],
|
|
29
|
+
["path", { d: "M9 3v18" }],
|
|
30
|
+
["path", { d: "M15 3v18" }]
|
|
31
|
+
];
|
|
32
|
+
var Ellipsis = [
|
|
33
|
+
["circle", { cx: "12", cy: "12", r: "1" }],
|
|
34
|
+
["circle", { cx: "19", cy: "12", r: "1" }],
|
|
35
|
+
["circle", { cx: "5", cy: "12", r: "1" }]
|
|
36
|
+
];
|
|
37
|
+
var Eraser = [
|
|
38
|
+
[
|
|
39
|
+
"path",
|
|
40
|
+
{
|
|
41
|
+
d: "M21 21H8a2 2 0 0 1-1.42-.587l-3.994-3.999a2 2 0 0 1 0-2.828l10-10a2 2 0 0 1 2.829 0l5.999 6a2 2 0 0 1 0 2.828L12.834 21"
|
|
42
|
+
}
|
|
43
|
+
],
|
|
44
|
+
["path", { d: "m5.082 11.09 8.828 8.828" }]
|
|
45
|
+
];
|
|
46
|
+
var GripHorizontal = [
|
|
47
|
+
["circle", { cx: "12", cy: "9", r: "1" }],
|
|
48
|
+
["circle", { cx: "19", cy: "9", r: "1" }],
|
|
49
|
+
["circle", { cx: "5", cy: "9", r: "1" }],
|
|
50
|
+
["circle", { cx: "12", cy: "15", r: "1" }],
|
|
51
|
+
["circle", { cx: "19", cy: "15", r: "1" }],
|
|
52
|
+
["circle", { cx: "5", cy: "15", r: "1" }]
|
|
53
|
+
];
|
|
54
|
+
var GripVertical = [
|
|
55
|
+
["circle", { cx: "9", cy: "12", r: "1" }],
|
|
56
|
+
["circle", { cx: "9", cy: "5", r: "1" }],
|
|
57
|
+
["circle", { cx: "9", cy: "19", r: "1" }],
|
|
58
|
+
["circle", { cx: "15", cy: "12", r: "1" }],
|
|
59
|
+
["circle", { cx: "15", cy: "5", r: "1" }],
|
|
60
|
+
["circle", { cx: "15", cy: "19", r: "1" }]
|
|
61
|
+
];
|
|
62
|
+
var Heading1 = [
|
|
63
|
+
["path", { d: "M4 12h8" }],
|
|
64
|
+
["path", { d: "M4 18V6" }],
|
|
65
|
+
["path", { d: "M12 18V6" }],
|
|
66
|
+
["path", { d: "m17 12 3-2v8" }]
|
|
67
|
+
];
|
|
68
|
+
var Heading2 = [
|
|
69
|
+
["path", { d: "M4 12h8" }],
|
|
70
|
+
["path", { d: "M4 18V6" }],
|
|
71
|
+
["path", { d: "M12 18V6" }],
|
|
72
|
+
["path", { d: "M21 18h-4c0-4 4-3 4-6 0-1.5-2-2.5-4-1" }]
|
|
73
|
+
];
|
|
74
|
+
var Heading3 = [
|
|
75
|
+
["path", { d: "M4 12h8" }],
|
|
76
|
+
["path", { d: "M4 18V6" }],
|
|
77
|
+
["path", { d: "M12 18V6" }],
|
|
78
|
+
["path", { d: "M17.5 10.5c1.7-1 3.5 0 3.5 1.5a2 2 0 0 1-2 2" }],
|
|
79
|
+
["path", { d: "M17 17.5c2 1.5 4 .3 4-1.5a2 2 0 0 0-2-2" }]
|
|
80
|
+
];
|
|
81
|
+
var Highlighter = [
|
|
82
|
+
["path", { d: "m9 11-6 6v3h9l3-3" }],
|
|
83
|
+
["path", { d: "m22 12-4.6 4.6a2 2 0 0 1-2.8 0l-5.2-5.2a2 2 0 0 1 0-2.8L14 4" }]
|
|
84
|
+
];
|
|
85
|
+
var Image = [
|
|
86
|
+
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", ry: "2" }],
|
|
87
|
+
["circle", { cx: "9", cy: "9", r: "2" }],
|
|
88
|
+
["path", { d: "m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21" }]
|
|
89
|
+
];
|
|
90
|
+
var Italic = [
|
|
91
|
+
["line", { x1: "19", x2: "10", y1: "4", y2: "4" }],
|
|
92
|
+
["line", { x1: "14", x2: "5", y1: "20", y2: "20" }],
|
|
93
|
+
["line", { x1: "15", x2: "9", y1: "4", y2: "20" }]
|
|
94
|
+
];
|
|
95
|
+
var ListOrdered = [
|
|
96
|
+
["path", { d: "M11 5h10" }],
|
|
97
|
+
["path", { d: "M11 12h10" }],
|
|
98
|
+
["path", { d: "M11 19h10" }],
|
|
99
|
+
["path", { d: "M4 4h1v5" }],
|
|
100
|
+
["path", { d: "M4 9h2" }],
|
|
101
|
+
["path", { d: "M6.5 20H3.4c0-1 2.6-1.925 2.6-3.5a1.5 1.5 0 0 0-2.6-1.02" }]
|
|
102
|
+
];
|
|
103
|
+
var ListTodo = [
|
|
104
|
+
["path", { d: "M13 5h8" }],
|
|
105
|
+
["path", { d: "M13 12h8" }],
|
|
106
|
+
["path", { d: "M13 19h8" }],
|
|
107
|
+
["path", { d: "m3 17 2 2 4-4" }],
|
|
108
|
+
["rect", { x: "3", y: "4", width: "6", height: "6", rx: "1" }]
|
|
109
|
+
];
|
|
110
|
+
var List = [
|
|
111
|
+
["path", { d: "M3 5h.01" }],
|
|
112
|
+
["path", { d: "M3 12h.01" }],
|
|
113
|
+
["path", { d: "M3 19h.01" }],
|
|
114
|
+
["path", { d: "M8 5h13" }],
|
|
115
|
+
["path", { d: "M8 12h13" }],
|
|
116
|
+
["path", { d: "M8 19h13" }]
|
|
117
|
+
];
|
|
118
|
+
var Merge = [
|
|
119
|
+
["path", { d: "m8 6 4-4 4 4" }],
|
|
120
|
+
["path", { d: "M12 2v10.3a4 4 0 0 1-1.172 2.872L4 22" }],
|
|
121
|
+
["path", { d: "m20 22-5-5" }]
|
|
122
|
+
];
|
|
123
|
+
var Minus = [["path", { d: "M5 12h14" }]];
|
|
124
|
+
var PaintBucket = [
|
|
125
|
+
["path", { d: "m19 11-8-8-8.6 8.6a2 2 0 0 0 0 2.8l5.2 5.2c.8.8 2 .8 2.8 0L19 11Z" }],
|
|
126
|
+
["path", { d: "m5 2 5 5" }],
|
|
127
|
+
["path", { d: "M2 13h15" }],
|
|
128
|
+
["path", { d: "M22 20a2 2 0 1 1-4 0c0-1.6 1.7-2.4 2-4 .3 1.6 2 2.4 2 4Z" }]
|
|
129
|
+
];
|
|
130
|
+
var PanelBottom = [
|
|
131
|
+
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }],
|
|
132
|
+
["path", { d: "M3 15h18" }]
|
|
133
|
+
];
|
|
134
|
+
var PanelLeft = [
|
|
135
|
+
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }],
|
|
136
|
+
["path", { d: "M9 3v18" }]
|
|
137
|
+
];
|
|
138
|
+
var PanelRight = [
|
|
139
|
+
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }],
|
|
140
|
+
["path", { d: "M15 3v18" }]
|
|
141
|
+
];
|
|
142
|
+
var PanelTop = [
|
|
143
|
+
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }],
|
|
144
|
+
["path", { d: "M3 9h18" }]
|
|
145
|
+
];
|
|
146
|
+
var Pilcrow = [
|
|
147
|
+
["path", { d: "M13 4v16" }],
|
|
148
|
+
["path", { d: "M17 4v16" }],
|
|
149
|
+
["path", { d: "M19 4H9.5a4.5 4.5 0 0 0 0 9H13" }]
|
|
150
|
+
];
|
|
151
|
+
var Plus = [
|
|
152
|
+
["path", { d: "M5 12h14" }],
|
|
153
|
+
["path", { d: "M12 5v14" }]
|
|
154
|
+
];
|
|
155
|
+
var Quote = [
|
|
156
|
+
[
|
|
157
|
+
"path",
|
|
158
|
+
{
|
|
159
|
+
d: "M16 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z"
|
|
160
|
+
}
|
|
161
|
+
],
|
|
162
|
+
[
|
|
163
|
+
"path",
|
|
164
|
+
{
|
|
165
|
+
d: "M5 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z"
|
|
166
|
+
}
|
|
167
|
+
]
|
|
168
|
+
];
|
|
169
|
+
var Redo2 = [
|
|
170
|
+
["path", { d: "m15 14 5-5-5-5" }],
|
|
171
|
+
["path", { d: "M20 9H9.5A5.5 5.5 0 0 0 4 14.5A5.5 5.5 0 0 0 9.5 20H13" }]
|
|
172
|
+
];
|
|
173
|
+
var Rows3 = [
|
|
174
|
+
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }],
|
|
175
|
+
["path", { d: "M21 9H3" }],
|
|
176
|
+
["path", { d: "M21 15H3" }]
|
|
177
|
+
];
|
|
178
|
+
var Split = [
|
|
179
|
+
["path", { d: "M16 3h5v5" }],
|
|
180
|
+
["path", { d: "M8 3H3v5" }],
|
|
181
|
+
["path", { d: "M12 22v-8.3a4 4 0 0 0-1.172-2.872L3 3" }],
|
|
182
|
+
["path", { d: "m15 9 6-6" }]
|
|
183
|
+
];
|
|
184
|
+
var Strikethrough = [
|
|
185
|
+
["path", { d: "M16 4H9a3 3 0 0 0-2.83 4" }],
|
|
186
|
+
["path", { d: "M14 12a4 4 0 0 1 0 8H6" }],
|
|
187
|
+
["line", { x1: "4", x2: "20", y1: "12", y2: "12" }]
|
|
188
|
+
];
|
|
189
|
+
var Table2 = [
|
|
190
|
+
[
|
|
191
|
+
"path",
|
|
192
|
+
{
|
|
193
|
+
d: "M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18"
|
|
194
|
+
}
|
|
195
|
+
]
|
|
196
|
+
];
|
|
197
|
+
var TextAlignCenter = [
|
|
198
|
+
["path", { d: "M21 5H3" }],
|
|
199
|
+
["path", { d: "M17 12H7" }],
|
|
200
|
+
["path", { d: "M19 19H5" }]
|
|
201
|
+
];
|
|
202
|
+
var TextAlignEnd = [
|
|
203
|
+
["path", { d: "M21 5H3" }],
|
|
204
|
+
["path", { d: "M21 12H9" }],
|
|
205
|
+
["path", { d: "M21 19H7" }]
|
|
206
|
+
];
|
|
207
|
+
var TextAlignStart = [
|
|
208
|
+
["path", { d: "M21 5H3" }],
|
|
209
|
+
["path", { d: "M15 12H3" }],
|
|
210
|
+
["path", { d: "M17 19H3" }]
|
|
211
|
+
];
|
|
212
|
+
var Trash2 = [
|
|
213
|
+
["path", { d: "M10 11v6" }],
|
|
214
|
+
["path", { d: "M14 11v6" }],
|
|
215
|
+
["path", { d: "M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6" }],
|
|
216
|
+
["path", { d: "M3 6h18" }],
|
|
217
|
+
["path", { d: "M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2" }]
|
|
218
|
+
];
|
|
219
|
+
var Underline = [
|
|
220
|
+
["path", { d: "M6 4v6a6 6 0 0 0 12 0V4" }],
|
|
221
|
+
["line", { x1: "4", x2: "20", y1: "20", y2: "20" }]
|
|
222
|
+
];
|
|
223
|
+
var Undo2 = [
|
|
224
|
+
["path", { d: "M9 14 4 9l5-5" }],
|
|
225
|
+
["path", { d: "M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11" }]
|
|
226
|
+
];
|
|
227
|
+
var LOOMA_ICONS = {
|
|
228
|
+
"align-center": TextAlignCenter,
|
|
229
|
+
"align-left": TextAlignStart,
|
|
230
|
+
"align-right": TextAlignEnd,
|
|
231
|
+
bold: Bold,
|
|
232
|
+
braces: Braces,
|
|
233
|
+
"chevron-down": ChevronDown,
|
|
234
|
+
"chevron-left": ChevronLeft,
|
|
235
|
+
"code-xml": CodeXml,
|
|
236
|
+
columns: Columns3,
|
|
237
|
+
ellipsis: Ellipsis,
|
|
238
|
+
eraser: Eraser,
|
|
239
|
+
"grip-horizontal": GripHorizontal,
|
|
240
|
+
"grip-vertical": GripVertical,
|
|
241
|
+
"heading-1": Heading1,
|
|
242
|
+
"heading-2": Heading2,
|
|
243
|
+
"heading-3": Heading3,
|
|
244
|
+
highlighter: Highlighter,
|
|
245
|
+
image: Image,
|
|
246
|
+
italic: Italic,
|
|
247
|
+
list: List,
|
|
248
|
+
"list-ordered": ListOrdered,
|
|
249
|
+
"list-todo": ListTodo,
|
|
250
|
+
merge: Merge,
|
|
251
|
+
minus: Minus,
|
|
252
|
+
"paint-bucket": PaintBucket,
|
|
253
|
+
"panel-bottom": PanelBottom,
|
|
254
|
+
"panel-left": PanelLeft,
|
|
255
|
+
"panel-right": PanelRight,
|
|
256
|
+
"panel-top": PanelTop,
|
|
257
|
+
pilcrow: Pilcrow,
|
|
258
|
+
plus: Plus,
|
|
259
|
+
quote: Quote,
|
|
260
|
+
redo: Redo2,
|
|
261
|
+
rows: Rows3,
|
|
262
|
+
split: Split,
|
|
263
|
+
strikethrough: Strikethrough,
|
|
264
|
+
table: Table2,
|
|
265
|
+
trash: Trash2,
|
|
266
|
+
underline: Underline,
|
|
267
|
+
undo: Undo2
|
|
268
|
+
};
|
|
269
|
+
function serializeAttributes(attributes) {
|
|
270
|
+
return Object.entries(attributes).map(([name, value]) => ` ${name}="${escapeAttribute(value)}"`).join("");
|
|
271
|
+
}
|
|
272
|
+
function escapeAttribute(value) {
|
|
273
|
+
return String(value).replaceAll("&", "&").replaceAll('"', """);
|
|
274
|
+
}
|
|
275
|
+
function serializeIconNode(node) {
|
|
276
|
+
const [tag, attributes] = node;
|
|
277
|
+
return `<${tag}${serializeAttributes(attributes)}></${tag}>`;
|
|
278
|
+
}
|
|
279
|
+
function loomaIconMarkup(name, className = "looma-icon") {
|
|
280
|
+
return [
|
|
281
|
+
`<svg class="${escapeAttribute(className)}" data-looma-icon="${name}" aria-hidden="true" focusable="false"`,
|
|
282
|
+
' viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"',
|
|
283
|
+
' stroke-linecap="round" stroke-linejoin="round">',
|
|
284
|
+
LOOMA_ICONS[name].map(serializeIconNode).join(""),
|
|
285
|
+
"</svg>"
|
|
286
|
+
].join("");
|
|
287
|
+
}
|
|
288
|
+
var uiTreeItemCss = () => `:host{--ui-tree-indent:16px;--ui-tree-row-min-height:44px;--ui-tree-drop-color:var(--ui-accent-solid);position:relative;display:block;min-inline-size:0;margin-inline-start:calc(var(--ui-tree-item-depth, 0) * var(--ui-tree-indent))}.row{position:relative;display:grid;grid-template-columns:20px auto minmax(0, 1fr) auto;align-items:center;min-block-size:var(--ui-tree-row-min-height);min-inline-size:0;border-radius:var(--ui-radius-md);color:var(--ui-text-secondary);transition:background-color var(--ui-motion-fast) var(--ui-motion-ease), color var(--ui-motion-fast) var(--ui-motion-ease), opacity var(--ui-motion-fast) var(--ui-motion-ease), box-shadow var(--ui-motion-fast) var(--ui-motion-ease)}.row:hover,:host([data-selected]) .row,.row:focus-within{color:var(--ui-text-primary);background:var(--ui-surface-muted)}:host([data-disabled]) .row{opacity:0.55}:host([data-dragging]) .row{opacity:0.42}:host(:focus){outline:none}:host(:focus-visible) .row{box-shadow:0 0 0 2px var(--ui-focus-ring)}:host([data-drop-position='inside']) .row{background:var(--ui-accent-subtle);box-shadow:inset 0 0 0 1px var(--ui-tree-drop-color)}.disclosure,.disclosure-spacer{grid-column:1;grid-row:1;inline-size:20px;block-size:28px}.disclosure{display:grid;place-items:center;padding:0;color:var(--ui-text-muted);background:transparent;border:0;border-radius:var(--ui-radius-sm);cursor:pointer}.disclosure:hover{color:var(--ui-text-primary);background:var(--ui-surface-elevated)}.disclosure-icon{display:block;inline-size:14px;block-size:14px;transform:rotate(-90deg);transition:transform var(--ui-motion-fast) var(--ui-motion-ease)}.disclosure-icon--expanded{transform:rotate(0deg)}.disclosure-icon :is(svg),.drag-handle :is(svg){display:block;inline-size:100%;block-size:100%}.leading{display:none}.leading:has(*){display:inline-grid;place-items:center;grid-column:2;grid-row:1;inline-size:16px;block-size:16px;margin-inline-start:var(--ui-space-1)}.label{grid-column:3;grid-row:1;min-inline-size:0;padding:var(--ui-space-1) var(--ui-space-2)}.actions{grid-column:4;grid-row:1;display:inline-flex;align-items:center;min-inline-size:0}.drag-handle{position:absolute;z-index:2;inset-block-start:50%;inset-inline-start:-22px;inline-size:20px;block-size:32px;display:grid;place-items:center;padding:7px 3px;color:var(--ui-text-muted);background:var(--ui-surface-elevated);border:1px solid transparent;border-radius:var(--ui-radius-sm);cursor:grab;opacity:0;pointer-events:none;transform:translateY(-50%);transition:opacity var(--ui-motion-fast) var(--ui-motion-ease)}.row:hover .drag-handle,.drag-handle:focus-visible,:host([data-dragging]) .drag-handle{opacity:1;pointer-events:auto}.drag-handle:active{cursor:grabbing}.drop-indicator{position:absolute;z-index:3;inset-inline:1px;display:none;block-size:2px;border-radius:999px;background:var(--ui-tree-drop-color);pointer-events:none}.drop-indicator::before,.drop-indicator::after{content:'';position:absolute;inset-block-start:50%;inline-size:7px;block-size:7px;border:2px solid var(--ui-tree-drop-color);border-radius:999px;background:var(--ui-surface-elevated);transform:translateY(-50%)}.drop-indicator::before{inset-inline-start:-1px}.drop-indicator::after{inset-inline-end:-1px}:host([data-drop-position='before']) .drop-indicator{display:block;inset-block-start:-1px}:host([data-drop-position='after']) .drop-indicator{display:block;inset-block-end:-1px}.children[hidden]{display:none}@media (hover: none), (pointer: coarse){.drag-handle{display:none}}@media (prefers-reduced-motion: reduce){.row,.disclosure-icon,.drag-handle{transition:none}}`;
|
|
289
|
+
var UITreeItem = class {
|
|
290
|
+
constructor(hostRef) {
|
|
291
|
+
registerInstance(this, hostRef);
|
|
292
|
+
}
|
|
293
|
+
get host() {
|
|
294
|
+
return getElement(this);
|
|
295
|
+
}
|
|
296
|
+
/** Stable application identifier emitted by tree interaction events. */
|
|
297
|
+
itemId = "";
|
|
298
|
+
/** Accessible name used by the disclosure and drag handle. */
|
|
299
|
+
label = "";
|
|
300
|
+
/** One-based visual and semantic nesting level. */
|
|
301
|
+
depth = 1;
|
|
302
|
+
/** Whether this item accepts children and exposes disclosure behavior. */
|
|
303
|
+
container = false;
|
|
304
|
+
/** Whether this item participates in pointer drag and drop. */
|
|
305
|
+
sortable = false;
|
|
306
|
+
/** Application-defined kind used to reject incompatible sibling drops. */
|
|
307
|
+
dragType = "item";
|
|
308
|
+
/** Application-defined parent/list identity included with reorder events. */
|
|
309
|
+
dropScope = "";
|
|
310
|
+
/** Comma-separated drag kinds accepted as children. Empty accepts every kind. */
|
|
311
|
+
accepts = "";
|
|
312
|
+
/** Initial controlled expansion value. */
|
|
313
|
+
expanded = false;
|
|
314
|
+
/** Initial uncontrolled expansion value. */
|
|
315
|
+
defaultExpanded = false;
|
|
316
|
+
selected = false;
|
|
317
|
+
disabled = false;
|
|
318
|
+
internalExpanded = false;
|
|
319
|
+
syncExpandedFromProp() {
|
|
320
|
+
this.internalExpanded = this.expanded;
|
|
321
|
+
}
|
|
322
|
+
componentWillLoad() {
|
|
323
|
+
this.internalExpanded = this.expanded || this.defaultExpanded;
|
|
324
|
+
}
|
|
325
|
+
componentDidLoad() {
|
|
326
|
+
this.host.addEventListener("ui-tree-auto-expand", this.onAutoExpand);
|
|
327
|
+
}
|
|
328
|
+
disconnectedCallback() {
|
|
329
|
+
this.host.removeEventListener("ui-tree-auto-expand", this.onAutoExpand);
|
|
330
|
+
}
|
|
331
|
+
setExpanded(expanded, trigger) {
|
|
332
|
+
if (!this.container || this.disabled || this.internalExpanded === expanded)
|
|
333
|
+
return;
|
|
334
|
+
this.internalExpanded = expanded;
|
|
335
|
+
dispatchDetail(this.host, "expand", { id: this.itemId, expanded, trigger });
|
|
336
|
+
}
|
|
337
|
+
onAutoExpand = () => {
|
|
338
|
+
this.setExpanded(true, "pointer");
|
|
339
|
+
};
|
|
340
|
+
onDisclosureClick = (event) => {
|
|
341
|
+
event.stopPropagation();
|
|
342
|
+
this.setExpanded(!this.internalExpanded, eventToTrigger(event));
|
|
343
|
+
};
|
|
344
|
+
onDisclosureKeydown = (event) => {
|
|
345
|
+
if (event.key !== "ArrowRight" && event.key !== "ArrowLeft")
|
|
346
|
+
return;
|
|
347
|
+
event.preventDefault();
|
|
348
|
+
event.stopPropagation();
|
|
349
|
+
this.setExpanded(event.key === "ArrowRight", "keyboard");
|
|
350
|
+
};
|
|
351
|
+
onRowClick = (event) => {
|
|
352
|
+
if (!this.container || this.disabled)
|
|
353
|
+
return;
|
|
354
|
+
const path = event.composedPath();
|
|
355
|
+
const interactive = path.some((node) => node instanceof HTMLElement && (node.matches('a, button, input, select, textarea, [role="button"], [role="link"]') || node.getAttribute("slot") === "actions"));
|
|
356
|
+
if (!interactive)
|
|
357
|
+
this.setExpanded(!this.internalExpanded, eventToTrigger(event));
|
|
358
|
+
};
|
|
359
|
+
render() {
|
|
360
|
+
const level = Math.max(1, Math.floor(this.depth));
|
|
361
|
+
const disclosureLabel = `${this.internalExpanded ? "Collapse" : "Expand"} ${this.label || "item"}`;
|
|
362
|
+
const dragLabel = `Drag ${this.label || "item"} to reorder`;
|
|
363
|
+
return h(Host, { key: "ea8ed538aa3883c87257a25614a066965364693f", role: "treeitem", "aria-level": String(level), "aria-expanded": this.container ? String(this.internalExpanded) : void 0, "aria-selected": String(this.selected), "aria-disabled": this.disabled ? "true" : void 0, "data-container": this.container ? "" : void 0, "data-selected": this.selected ? "" : void 0, "data-disabled": this.disabled ? "" : void 0, "data-drag-type": this.dragType || "item", "data-drop-scope": this.dropScope || void 0, "data-accepts": this.accepts || void 0, tabIndex: this.disabled ? -1 : 0, style: {
|
|
364
|
+
"--ui-tree-item-depth": String(level - 1),
|
|
365
|
+
"margin-inline-start": level > 1 ? "var(--ui-tree-indent, 16px)" : "0px"
|
|
366
|
+
} }, h("div", { key: "740b93aa47e65d8a1cb899d4b9c966d9ad1d456f", class: "row", part: "row", onClick: this.onRowClick }, this.sortable && !this.disabled ? h("button", { class: "drag-handle", part: "drag-handle", type: "button", draggable: true, "aria-label": dragLabel, title: dragLabel }, h("span", { innerHTML: loomaIconMarkup("grip-vertical") })) : null, this.container ? h("button", { class: "disclosure", part: "disclosure", type: "button", "aria-label": disclosureLabel, "aria-expanded": String(this.internalExpanded), disabled: this.disabled, onClick: this.onDisclosureClick, onKeyDown: this.onDisclosureKeydown }, h("span", { class: { "disclosure-icon": true, "disclosure-icon--expanded": this.internalExpanded }, innerHTML: loomaIconMarkup("chevron-down") })) : h("span", { class: "disclosure-spacer", "aria-hidden": "true" }), h("span", { key: "37e1b7f1cdddf623734becef465ffde83d8b86f2", class: "leading", part: "leading" }, h("slot", { key: "0ab3a60c98628f009918d0d720772154912d2709", name: "leading" })), h("span", { key: "defdd343f25a0f4354110e981f3889e1d09c27ee", class: "label", part: "label" }, h("slot", { key: "bde46ccacc1a620348062fc300503c4f1736316b" })), h("span", { key: "caff9ada38c41be90aeb6e331f4c54a51f31d26c", class: "actions", part: "actions" }, h("slot", { key: "e11704d6871445c91eaa29c99302d8b751be69d3", name: "actions" })), h("span", { key: "7e40559d6c5ba56710bc705083ad2ede3046e0b1", class: "drop-indicator", part: "drop-indicator", "aria-hidden": "true" })), this.container ? h("div", { class: "children", part: "children", role: "group", hidden: !this.internalExpanded }, h("slot", { name: "children" })) : null);
|
|
367
|
+
}
|
|
368
|
+
static get watchers() {
|
|
369
|
+
return {
|
|
370
|
+
"expanded": [{
|
|
371
|
+
"syncExpandedFromProp": 0
|
|
372
|
+
}]
|
|
373
|
+
};
|
|
374
|
+
}
|
|
375
|
+
};
|
|
376
|
+
UITreeItem.style = uiTreeItemCss();
|
|
377
|
+
export {
|
|
378
|
+
UITreeItem as ui_tree_item
|
|
379
|
+
};
|
|
380
|
+
/**
|
|
381
|
+
* @license lucide v0.554.0 - ISC
|
|
382
|
+
*
|
|
383
|
+
* This source code is licensed under the ISC license.
|
|
384
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
385
|
+
*/
|