@threadlabs/looma 0.2.5 → 0.2.6
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-3K45IWIJ.js +4733 -0
- package/dist/chunk-MLKGABMK.js +9 -0
- package/dist/chunk-UHHA4WT5.js +2916 -0
- package/dist/declarative-generated.cjs +135 -0
- package/dist/declarative-generated.d.cts +10 -0
- package/dist/declarative-generated.d.ts +10 -0
- package/dist/declarative-generated.js +111 -0
- package/dist/declarative.cjs +2944 -0
- package/dist/declarative.d.cts +27 -0
- package/dist/declarative.d.ts +27 -0
- package/dist/declarative.js +13 -0
- package/dist/index.cjs +7480 -6457
- package/dist/index.d.cts +4 -58
- package/dist/index.d.ts +4 -58
- package/dist/index.js +15 -27
- package/dist/loader.cjs +7654 -0
- package/dist/loader.d.cts +4 -0
- package/dist/loader.d.ts +4 -0
- package/dist/loader.js +16 -0
- package/dist/valibot.cjs +31 -0
- package/dist/valibot.d.cts +10 -0
- package/dist/valibot.d.ts +1 -43
- package/dist/valibot.js +2 -0
- package/dist/{types/field/validation.d.ts → validation-bxcou-l-.d.cts} +13 -11
- package/dist/validation-bxcou-l-.d.ts +58 -0
- package/editor/{chunk-B5WVJOPV.js → chunk-BXICJBWS.js} +118 -8
- package/editor/{chunk-ZOUKEZ77.js → chunk-JK53ENSG.js} +8 -21
- package/editor/chunk-WI7ZA44X.js +2558 -0
- package/editor/extensions/index.d.ts +11 -2
- package/editor/extensions/index.js +9 -7
- package/editor/index.d.ts +1 -1
- package/editor/index.js +10 -8
- package/editor/ui.js +2 -2
- package/editor.css +32 -0
- package/layout/index.cjs +466 -400
- package/layout/index.d.cts +1 -2
- package/layout/index.d.ts +1 -2
- package/layout/index.js +471 -395
- package/package.json +14 -5
- package/vue/chunk-4DPYH3IT.js +3538 -0
- package/vue/editor/index.d.ts +17 -7
- package/vue/editor/index.js +53 -35
- package/vue/index.d.ts +48 -31
- package/vue/index.js +1 -1
- package/dist/chunk-24OTMNIU.js +0 -1617
- package/dist/chunk-D5WRORG6.js +0 -366
- package/dist/chunk-HNFCGIBP.js +0 -8
- package/dist/chunk-NB6DBRXQ.js +0 -323
- package/dist/chunk-OF57X5AR.js +0 -10
- package/dist/chunk-TL4FIE7X.js +0 -93
- package/dist/chunk-UL7UIUJZ.js +0 -20
- package/dist/cjs/app-globals-V2Kpy_OQ.js +0 -5
- package/dist/cjs/controlled-state-BFya8rAX.js +0 -9
- package/dist/cjs/events-TcQIzpNv.js +0 -19
- package/dist/cjs/icons-BAdjrnhS.js +0 -680
- package/dist/cjs/id-CYbKpaYr.js +0 -9
- package/dist/cjs/index-BHG9Rpil.js +0 -1602
- package/dist/cjs/index.cjs.js +0 -2
- package/dist/cjs/loader.cjs.js +0 -13
- package/dist/cjs/looma.cjs.js +0 -25
- package/dist/cjs/manager-Ce25WRtl.js +0 -95
- package/dist/cjs/positioning-CCR6ifPj.js +0 -426
- package/dist/cjs/ui-affordance-scope.cjs.entry.js +0 -43
- package/dist/cjs/ui-avatar-group.cjs.entry.js +0 -43
- package/dist/cjs/ui-avatar.cjs.entry.js +0 -50
- package/dist/cjs/ui-badge.cjs.entry.js +0 -19
- package/dist/cjs/ui-button.cjs.entry.js +0 -75
- package/dist/cjs/ui-callout.cjs.entry.js +0 -27
- package/dist/cjs/ui-checkbox.cjs.entry.js +0 -97
- package/dist/cjs/ui-chip_2.cjs.entry.js +0 -258
- package/dist/cjs/ui-combobox.cjs.entry.js +0 -708
- package/dist/cjs/ui-context-menu.cjs.entry.js +0 -239
- package/dist/cjs/ui-dialog.cjs.entry.js +0 -131
- package/dist/cjs/ui-disclosure.cjs.entry.js +0 -112
- package/dist/cjs/ui-editable.cjs.entry.js +0 -100
- package/dist/cjs/ui-floating-action-button.cjs.entry.js +0 -20
- package/dist/cjs/ui-form-field.cjs.entry.js +0 -114
- package/dist/cjs/ui-icon-button.cjs.entry.js +0 -23
- package/dist/cjs/ui-input.cjs.entry.js +0 -106
- package/dist/cjs/ui-menu-item.cjs.entry.js +0 -19
- package/dist/cjs/ui-menu.cjs.entry.js +0 -182
- package/dist/cjs/ui-popover.cjs.entry.js +0 -135
- package/dist/cjs/ui-radio-group.cjs.entry.js +0 -134
- package/dist/cjs/ui-radio.cjs.entry.js +0 -94
- package/dist/cjs/ui-search-result-row.cjs.entry.js +0 -47
- package/dist/cjs/ui-search-shell.cjs.entry.js +0 -39
- package/dist/cjs/ui-select.cjs.entry.js +0 -108
- package/dist/cjs/ui-switch.cjs.entry.js +0 -74
- package/dist/cjs/ui-tabs.cjs.entry.js +0 -118
- package/dist/cjs/ui-textarea.cjs.entry.js +0 -110
- package/dist/cjs/ui-toast-region.cjs.entry.js +0 -93
- package/dist/cjs/ui-top-bar.cjs.entry.js +0 -43
- package/dist/cjs/ui-tree-item.cjs.entry.js +0 -135
- package/dist/cjs/ui-tree.cjs.entry.js +0 -500
- package/dist/collection/collection-manifest.json +0 -45
- package/dist/collection/components/ui-affordance-scope/ui-affordance-scope.css +0 -8
- package/dist/collection/components/ui-affordance-scope/ui-affordance-scope.js +0 -70
- package/dist/collection/components/ui-avatar/ui-avatar.css +0 -35
- package/dist/collection/components/ui-avatar/ui-avatar.js +0 -130
- package/dist/collection/components/ui-avatar-group/ui-avatar-group.css +0 -32
- package/dist/collection/components/ui-avatar-group/ui-avatar-group.js +0 -95
- package/dist/collection/components/ui-badge/ui-badge.css +0 -90
- package/dist/collection/components/ui-badge/ui-badge.js +0 -62
- package/dist/collection/components/ui-button/ui-button.css +0 -121
- package/dist/collection/components/ui-button/ui-button.js +0 -141
- package/dist/collection/components/ui-callout/ui-callout.css +0 -74
- package/dist/collection/components/ui-callout/ui-callout.js +0 -59
- package/dist/collection/components/ui-checkbox/ui-checkbox.css +0 -24
- package/dist/collection/components/ui-checkbox/ui-checkbox.js +0 -228
- package/dist/collection/components/ui-chip/ui-chip.css +0 -57
- package/dist/collection/components/ui-chip/ui-chip.js +0 -67
- package/dist/collection/components/ui-combobox/ui-combobox.css +0 -47
- package/dist/collection/components/ui-combobox/ui-combobox.js +0 -1295
- package/dist/collection/components/ui-context-menu/ui-context-menu.css +0 -34
- package/dist/collection/components/ui-context-menu/ui-context-menu.js +0 -311
- package/dist/collection/components/ui-dialog/ui-dialog.css +0 -72
- package/dist/collection/components/ui-dialog/ui-dialog.js +0 -242
- package/dist/collection/components/ui-disclosure/ui-disclosure.css +0 -7
- package/dist/collection/components/ui-disclosure/ui-disclosure.js +0 -184
- package/dist/collection/components/ui-editable/ui-editable.css +0 -2
- package/dist/collection/components/ui-editable/ui-editable.js +0 -196
- package/dist/collection/components/ui-floating-action-button/ui-floating-action-button.css +0 -73
- package/dist/collection/components/ui-floating-action-button/ui-floating-action-button.js +0 -85
- package/dist/collection/components/ui-form-field/ui-form-field.css +0 -25
- package/dist/collection/components/ui-form-field/ui-form-field.js +0 -180
- package/dist/collection/components/ui-icon-button/ui-icon-button.css +0 -145
- package/dist/collection/components/ui-icon-button/ui-icon-button.js +0 -128
- package/dist/collection/components/ui-input/ui-input.css +0 -48
- package/dist/collection/components/ui-input/ui-input.js +0 -217
- package/dist/collection/components/ui-menu/ui-menu.css +0 -73
- package/dist/collection/components/ui-menu/ui-menu.js +0 -280
- package/dist/collection/components/ui-menu-item/ui-menu-item.css +0 -32
- package/dist/collection/components/ui-menu-item/ui-menu-item.js +0 -64
- package/dist/collection/components/ui-popover/ui-popover.css +0 -58
- package/dist/collection/components/ui-popover/ui-popover.js +0 -232
- package/dist/collection/components/ui-radio/ui-radio.css +0 -22
- package/dist/collection/components/ui-radio/ui-radio.js +0 -226
- package/dist/collection/components/ui-radio-group/ui-radio-group.css +0 -10
- package/dist/collection/components/ui-radio-group/ui-radio-group.js +0 -247
- package/dist/collection/components/ui-search-result-row/ui-search-result-row.css +0 -80
- package/dist/collection/components/ui-search-result-row/ui-search-result-row.js +0 -100
- package/dist/collection/components/ui-search-shell/ui-search-shell.css +0 -63
- package/dist/collection/components/ui-search-shell/ui-search-shell.js +0 -46
- package/dist/collection/components/ui-select/ui-select.css +0 -64
- package/dist/collection/components/ui-select/ui-select.js +0 -218
- package/dist/collection/components/ui-switch/ui-switch.css +0 -63
- package/dist/collection/components/ui-switch/ui-switch.js +0 -185
- package/dist/collection/components/ui-tabs/ui-tabs.css +0 -68
- package/dist/collection/components/ui-tabs/ui-tabs.js +0 -190
- package/dist/collection/components/ui-textarea/ui-textarea.css +0 -49
- package/dist/collection/components/ui-textarea/ui-textarea.js +0 -241
- package/dist/collection/components/ui-toast-region/ui-toast-region.css +0 -59
- package/dist/collection/components/ui-toast-region/ui-toast-region.js +0 -126
- package/dist/collection/components/ui-tooltip/ui-tooltip.css +0 -43
- package/dist/collection/components/ui-tooltip/ui-tooltip.js +0 -430
- package/dist/collection/components/ui-top-bar/ui-top-bar.css +0 -51
- package/dist/collection/components/ui-top-bar/ui-top-bar.js +0 -52
- package/dist/collection/components/ui-tree/ui-tree.css +0 -12
- package/dist/collection/components/ui-tree/ui-tree.js +0 -515
- package/dist/collection/components/ui-tree-item/ui-tree-item.css +0 -217
- package/dist/collection/components/ui-tree-item/ui-tree-item.js +0 -406
- package/dist/collection/field/combobox.js +0 -4
- package/dist/collection/field/editable.js +0 -1
- package/dist/collection/field/multi-combobox.js +0 -1
- package/dist/collection/field/valibot.js +0 -5
- package/dist/collection/field/validation.js +0 -62
- package/dist/collection/icons.js +0 -71
- package/dist/collection/input-modality.js +0 -24
- package/dist/collection/overlay/manager.js +0 -92
- package/dist/collection/overlay/positioning.js +0 -424
- package/dist/collection/utils/controlled-state.js +0 -4
- package/dist/collection/utils/drag-drop.js +0 -51
- package/dist/collection/utils/events.js +0 -13
- package/dist/collection/utils/id.js +0 -5
- package/dist/collection/utils/initials.js +0 -11
- package/dist/components/index.d.ts +0 -102
- package/dist/components/index.js +0 -1
- package/dist/components/p-6SWSrfmW.js +0 -1
- package/dist/components/p-B_DaIVEY.js +0 -1
- package/dist/components/p-Bh_1GxOD.js +0 -1
- package/dist/components/p-BnGhGgTH.js +0 -1
- package/dist/components/p-BzaB_bXo.js +0 -1
- package/dist/components/p-C-0syqXZ.js +0 -1
- package/dist/components/p-CoFximGM.js +0 -13
- package/dist/components/p-JwSoedEO.js +0 -1
- package/dist/components/p-Vc4ExHFc.js +0 -1
- package/dist/components/p-hgBUJRDa.js +0 -1
- package/dist/components/ui-affordance-scope.d.ts +0 -11
- package/dist/components/ui-affordance-scope.js +0 -1
- package/dist/components/ui-avatar-group.d.ts +0 -11
- package/dist/components/ui-avatar-group.js +0 -1
- package/dist/components/ui-avatar.d.ts +0 -11
- package/dist/components/ui-avatar.js +0 -1
- package/dist/components/ui-badge.d.ts +0 -11
- package/dist/components/ui-badge.js +0 -1
- package/dist/components/ui-button.d.ts +0 -11
- package/dist/components/ui-button.js +0 -1
- package/dist/components/ui-callout.d.ts +0 -11
- package/dist/components/ui-callout.js +0 -1
- package/dist/components/ui-checkbox.d.ts +0 -11
- package/dist/components/ui-checkbox.js +0 -1
- package/dist/components/ui-chip.d.ts +0 -11
- package/dist/components/ui-chip.js +0 -1
- package/dist/components/ui-combobox.d.ts +0 -11
- package/dist/components/ui-combobox.js +0 -1
- package/dist/components/ui-context-menu.d.ts +0 -11
- package/dist/components/ui-context-menu.js +0 -1
- package/dist/components/ui-dialog.d.ts +0 -11
- package/dist/components/ui-dialog.js +0 -1
- package/dist/components/ui-disclosure.d.ts +0 -11
- package/dist/components/ui-disclosure.js +0 -1
- package/dist/components/ui-editable.d.ts +0 -11
- package/dist/components/ui-editable.js +0 -1
- package/dist/components/ui-floating-action-button.d.ts +0 -11
- package/dist/components/ui-floating-action-button.js +0 -1
- package/dist/components/ui-form-field.d.ts +0 -11
- package/dist/components/ui-form-field.js +0 -1
- package/dist/components/ui-icon-button.d.ts +0 -11
- package/dist/components/ui-icon-button.js +0 -1
- package/dist/components/ui-input.d.ts +0 -11
- package/dist/components/ui-input.js +0 -1
- package/dist/components/ui-menu-item.d.ts +0 -11
- package/dist/components/ui-menu-item.js +0 -1
- package/dist/components/ui-menu.d.ts +0 -11
- package/dist/components/ui-menu.js +0 -1
- package/dist/components/ui-popover.d.ts +0 -11
- package/dist/components/ui-popover.js +0 -1
- package/dist/components/ui-radio-group.d.ts +0 -11
- package/dist/components/ui-radio-group.js +0 -1
- package/dist/components/ui-radio.d.ts +0 -11
- package/dist/components/ui-radio.js +0 -1
- package/dist/components/ui-search-result-row.d.ts +0 -11
- package/dist/components/ui-search-result-row.js +0 -1
- package/dist/components/ui-search-shell.d.ts +0 -11
- package/dist/components/ui-search-shell.js +0 -1
- package/dist/components/ui-select.d.ts +0 -11
- package/dist/components/ui-select.js +0 -1
- package/dist/components/ui-switch.d.ts +0 -11
- package/dist/components/ui-switch.js +0 -1
- package/dist/components/ui-tabs.d.ts +0 -11
- package/dist/components/ui-tabs.js +0 -1
- package/dist/components/ui-textarea.d.ts +0 -11
- package/dist/components/ui-textarea.js +0 -1
- package/dist/components/ui-toast-region.d.ts +0 -11
- package/dist/components/ui-toast-region.js +0 -1
- package/dist/components/ui-tooltip.d.ts +0 -11
- package/dist/components/ui-tooltip.js +0 -1
- package/dist/components/ui-top-bar.d.ts +0 -11
- package/dist/components/ui-top-bar.js +0 -1
- package/dist/components/ui-tree-item.d.ts +0 -11
- package/dist/components/ui-tree-item.js +0 -1
- package/dist/components/ui-tree.d.ts +0 -11
- package/dist/components/ui-tree.js +0 -1
- package/dist/esm/app-globals-DQuL1Twl.js +0 -3
- package/dist/esm/controlled-state-BnGhGgTH.js +0 -6
- package/dist/esm/events-JwSoedEO.js +0 -15
- package/dist/esm/icons-CoFximGM.js +0 -678
- package/dist/esm/id-hgBUJRDa.js +0 -7
- package/dist/esm/index-8BGiMGQ0.js +0 -1593
- package/dist/esm/index.js +0 -1
- package/dist/esm/loader.js +0 -11
- package/dist/esm/looma.js +0 -21
- package/dist/esm/manager-C-0syqXZ.js +0 -91
- package/dist/esm/positioning-ZOr-2PSe.js +0 -421
- package/dist/esm/ui-affordance-scope.entry.js +0 -41
- package/dist/esm/ui-avatar-group.entry.js +0 -41
- package/dist/esm/ui-avatar.entry.js +0 -48
- package/dist/esm/ui-badge.entry.js +0 -17
- package/dist/esm/ui-button.entry.js +0 -73
- package/dist/esm/ui-callout.entry.js +0 -25
- package/dist/esm/ui-checkbox.entry.js +0 -95
- package/dist/esm/ui-chip_2.entry.js +0 -255
- package/dist/esm/ui-combobox.entry.js +0 -706
- package/dist/esm/ui-context-menu.entry.js +0 -237
- package/dist/esm/ui-dialog.entry.js +0 -129
- package/dist/esm/ui-disclosure.entry.js +0 -110
- package/dist/esm/ui-editable.entry.js +0 -98
- package/dist/esm/ui-floating-action-button.entry.js +0 -18
- package/dist/esm/ui-form-field.entry.js +0 -112
- package/dist/esm/ui-icon-button.entry.js +0 -21
- package/dist/esm/ui-input.entry.js +0 -104
- package/dist/esm/ui-menu-item.entry.js +0 -17
- package/dist/esm/ui-menu.entry.js +0 -180
- package/dist/esm/ui-popover.entry.js +0 -133
- package/dist/esm/ui-radio-group.entry.js +0 -132
- package/dist/esm/ui-radio.entry.js +0 -92
- package/dist/esm/ui-search-result-row.entry.js +0 -45
- package/dist/esm/ui-search-shell.entry.js +0 -37
- package/dist/esm/ui-select.entry.js +0 -106
- package/dist/esm/ui-switch.entry.js +0 -72
- package/dist/esm/ui-tabs.entry.js +0 -116
- package/dist/esm/ui-textarea.entry.js +0 -108
- package/dist/esm/ui-toast-region.entry.js +0 -91
- package/dist/esm/ui-top-bar.entry.js +0 -41
- package/dist/esm/ui-tree-item.entry.js +0 -133
- package/dist/esm/ui-tree.entry.js +0 -498
- package/dist/index.cjs.js +0 -1
- package/dist/looma/index.esm.js +0 -0
- package/dist/looma/looma.esm.js +0 -1
- package/dist/looma/p-08f80207.entry.js +0 -1
- package/dist/looma/p-0b5b8d9e.entry.js +0 -1
- package/dist/looma/p-1249a806.entry.js +0 -1
- package/dist/looma/p-16e0669d.entry.js +0 -1
- package/dist/looma/p-1c00670f.entry.js +0 -1
- package/dist/looma/p-1c5a7522.entry.js +0 -1
- package/dist/looma/p-22842f8c.entry.js +0 -1
- package/dist/looma/p-2915d5c0.entry.js +0 -1
- package/dist/looma/p-3b2961a6.entry.js +0 -1
- package/dist/looma/p-3f60f4c8.entry.js +0 -1
- package/dist/looma/p-424d6719.entry.js +0 -1
- package/dist/looma/p-4caccfce.entry.js +0 -1
- package/dist/looma/p-5fdcee1d.entry.js +0 -1
- package/dist/looma/p-6d8b99ee.entry.js +0 -1
- package/dist/looma/p-6f20d470.entry.js +0 -1
- package/dist/looma/p-7c0b5364.entry.js +0 -1
- package/dist/looma/p-8BGiMGQ0.js +0 -2
- package/dist/looma/p-8bdd9495.entry.js +0 -1
- package/dist/looma/p-99116a72.entry.js +0 -1
- package/dist/looma/p-9cfbf722.entry.js +0 -1
- package/dist/looma/p-9d2662ca.entry.js +0 -1
- package/dist/looma/p-9ff2fa19.entry.js +0 -1
- package/dist/looma/p-BnGhGgTH.js +0 -1
- package/dist/looma/p-C-0syqXZ.js +0 -1
- package/dist/looma/p-CoFximGM.js +0 -13
- package/dist/looma/p-DQuL1Twl.js +0 -1
- package/dist/looma/p-JwSoedEO.js +0 -1
- package/dist/looma/p-ZOr-2PSe.js +0 -1
- package/dist/looma/p-a2dd4c6c.entry.js +0 -1
- package/dist/looma/p-add67e4c.entry.js +0 -1
- package/dist/looma/p-b6ede6bb.entry.js +0 -1
- package/dist/looma/p-b76e2111.entry.js +0 -1
- package/dist/looma/p-ca2a54fd.entry.js +0 -1
- package/dist/looma/p-d372b0db.entry.js +0 -1
- package/dist/looma/p-d4825822.entry.js +0 -1
- package/dist/looma/p-d56571a2.entry.js +0 -1
- package/dist/looma/p-d5c3954f.entry.js +0 -1
- package/dist/looma/p-e604e906.entry.js +0 -1
- package/dist/looma/p-f1f7c5cb.entry.js +0 -1
- package/dist/looma/p-hgBUJRDa.js +0 -1
- package/dist/types/components/ui-affordance-scope/ui-affordance-scope.d.ts +0 -11
- package/dist/types/components/ui-avatar/ui-avatar.d.ts +0 -11
- package/dist/types/components/ui-avatar-group/ui-avatar-group.d.ts +0 -11
- package/dist/types/components/ui-badge/ui-badge.d.ts +0 -5
- package/dist/types/components/ui-button/ui-button.d.ts +0 -13
- package/dist/types/components/ui-callout/ui-callout.d.ts +0 -6
- package/dist/types/components/ui-checkbox/ui-checkbox.d.ts +0 -20
- package/dist/types/components/ui-chip/ui-chip.d.ts +0 -8
- package/dist/types/components/ui-combobox/ui-combobox.d.ts +0 -128
- package/dist/types/components/ui-context-menu/ui-context-menu.d.ts +0 -43
- package/dist/types/components/ui-dialog/ui-dialog.d.ts +0 -27
- package/dist/types/components/ui-disclosure/ui-disclosure.d.ts +0 -21
- package/dist/types/components/ui-editable/ui-editable.d.ts +0 -24
- package/dist/types/components/ui-floating-action-button/ui-floating-action-button.d.ts +0 -6
- package/dist/types/components/ui-form-field/ui-form-field.d.ts +0 -18
- package/dist/types/components/ui-icon-button/ui-icon-button.d.ts +0 -9
- package/dist/types/components/ui-input/ui-input.d.ts +0 -19
- package/dist/types/components/ui-menu/ui-menu.d.ts +0 -28
- package/dist/types/components/ui-menu-item/ui-menu-item.d.ts +0 -5
- package/dist/types/components/ui-popover/ui-popover.d.ts +0 -26
- package/dist/types/components/ui-radio/ui-radio.d.ts +0 -20
- package/dist/types/components/ui-radio-group/ui-radio-group.d.ts +0 -21
- package/dist/types/components/ui-search-result-row/ui-search-result-row.d.ts +0 -15
- package/dist/types/components/ui-search-shell/ui-search-shell.d.ts +0 -9
- package/dist/types/components/ui-select/ui-select.d.ts +0 -20
- package/dist/types/components/ui-switch/ui-switch.d.ts +0 -16
- package/dist/types/components/ui-tabs/ui-tabs.d.ts +0 -18
- package/dist/types/components/ui-textarea/ui-textarea.d.ts +0 -20
- package/dist/types/components/ui-toast-region/ui-toast-region.d.ts +0 -16
- package/dist/types/components/ui-tooltip/ui-tooltip.d.ts +0 -57
- package/dist/types/components/ui-top-bar/ui-top-bar.d.ts +0 -12
- package/dist/types/components/ui-tree/ui-tree.d.ts +0 -53
- package/dist/types/components/ui-tree-item/ui-tree-item.d.ts +0 -44
- package/dist/types/components.d.ts +0 -1889
- package/dist/types/field/combobox.d.ts +0 -46
- package/dist/types/field/editable.d.ts +0 -5
- package/dist/types/field/multi-combobox.d.ts +0 -11
- package/dist/types/field/valibot.d.ts +0 -7
- package/dist/types/icons.d.ts +0 -53
- package/dist/types/input-modality.d.ts +0 -6
- package/dist/types/overlay/manager.d.ts +0 -17
- package/dist/types/overlay/positioning.d.ts +0 -74
- package/dist/types/stencil-public-runtime.d.ts +0 -1860
- package/dist/types/utils/controlled-state.d.ts +0 -4
- package/dist/types/utils/drag-drop.d.ts +0 -15
- package/dist/types/utils/events.d.ts +0 -4
- package/dist/types/utils/id.d.ts +0 -1
- package/dist/types/utils/initials.d.ts +0 -1
- package/dist/ui-affordance-scope.entry-L6TIXYOP.js +0 -54
- package/dist/ui-avatar-group.entry-TCAA6P72.js +0 -51
- package/dist/ui-avatar.entry-52DQ7VXA.js +0 -51
- package/dist/ui-badge.entry-2XCAA6LL.js +0 -22
- package/dist/ui-button.entry-MNFBMNSX.js +0 -83
- package/dist/ui-callout.entry-SSHT5TH2.js +0 -32
- package/dist/ui-checkbox.entry-LOWIWIWI.js +0 -111
- package/dist/ui-chip_2.entry-BIMTSF6C.js +0 -272
- package/dist/ui-combobox.entry-25Z4MN7N.js +0 -717
- package/dist/ui-context-menu.entry-YZDL5Y4M.js +0 -248
- package/dist/ui-dialog.entry-HIXZX5AB.js +0 -146
- package/dist/ui-disclosure.entry-2JZHZNDQ.js +0 -126
- package/dist/ui-editable.entry-U3VR3XPT.js +0 -110
- package/dist/ui-floating-action-button.entry-6S3QN3KJ.js +0 -23
- package/dist/ui-form-field.entry-GQOSMLHT.js +0 -120
- package/dist/ui-icon-button.entry-QJXKVDM6.js +0 -26
- package/dist/ui-input.entry-UWMQ6JMP.js +0 -114
- package/dist/ui-menu-item.entry-NHNZKKJS.js +0 -22
- package/dist/ui-menu.entry-D53RUJND.js +0 -192
- package/dist/ui-popover.entry-7ZSIWCFQ.js +0 -152
- package/dist/ui-radio-group.entry-37MSYIH4.js +0 -142
- package/dist/ui-radio.entry-7YGCDHXT.js +0 -108
- package/dist/ui-search-result-row.entry-6FCCLGAS.js +0 -50
- package/dist/ui-search-shell.entry-HSBEXPER.js +0 -41
- package/dist/ui-select.entry-GIDIAYRD.js +0 -117
- package/dist/ui-switch.entry-MYAL6XPC.js +0 -87
- package/dist/ui-tabs.entry-R4TEXQSD.js +0 -128
- package/dist/ui-textarea.entry-FW32JNDV.js +0 -119
- package/dist/ui-toast-region.entry-BTMFPKZF.js +0 -104
- package/dist/ui-top-bar.entry-5DQGJF3B.js +0 -49
- package/dist/ui-tree-item.entry-ADT7DSOS.js +0 -145
- package/dist/ui-tree.entry-7PYQ5RIN.js +0 -470
- package/editor/chunk-64GLF274.js +0 -1271
- package/layout/index.css +0 -387
- package/loader/cdn.js +0 -1
- package/loader/index.cjs.js +0 -1
- package/loader/index.d.ts +0 -24
- package/loader/index.es2017.js +0 -1
- package/loader/index.js +0 -2
- package/vue/chunk-ROMBQS2L.js +0 -352
|
@@ -1,190 +0,0 @@
|
|
|
1
|
-
import { Host, h } from "@stencil/core";
|
|
2
|
-
import { eventToTrigger } from "../../utils/events";
|
|
3
|
-
import { dispatchDetail } from "../../utils/events";
|
|
4
|
-
import { controlledOrDefault, isControlled } from "../../utils/controlled-state";
|
|
5
|
-
export class UITabs {
|
|
6
|
-
host;
|
|
7
|
-
/** Controlled selected tab value. Omit it to use defaultValue and local interaction state. */
|
|
8
|
-
value;
|
|
9
|
-
defaultValue = '';
|
|
10
|
-
orientation = 'horizontal';
|
|
11
|
-
internalValue = '';
|
|
12
|
-
syncFromProp() {
|
|
13
|
-
if (isControlled(this.value))
|
|
14
|
-
this.internalValue = this.value;
|
|
15
|
-
}
|
|
16
|
-
syncState() {
|
|
17
|
-
const tabs = this.getTabs();
|
|
18
|
-
if (tabs.length === 0)
|
|
19
|
-
return;
|
|
20
|
-
tabs.forEach((tab) => {
|
|
21
|
-
const tabId = tab.id ?? tab.getAttribute('aria-controls') ?? '';
|
|
22
|
-
const isSelected = tabId === this.internalValue;
|
|
23
|
-
tab.setAttribute('aria-selected', String(isSelected));
|
|
24
|
-
tab.tabIndex = isSelected ? 0 : -1;
|
|
25
|
-
const controlsId = tab.getAttribute('aria-controls');
|
|
26
|
-
if (controlsId) {
|
|
27
|
-
const panel = this.host.querySelector(`#${CSS.escape(controlsId)}`) ?? document.getElementById(controlsId);
|
|
28
|
-
if (panel) {
|
|
29
|
-
panel.hidden = !isSelected;
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
});
|
|
33
|
-
}
|
|
34
|
-
componentDidLoad() {
|
|
35
|
-
this.internalValue = controlledOrDefault(this.value, this.defaultValue);
|
|
36
|
-
if (!isControlled(this.value) && !this.internalValue) {
|
|
37
|
-
const tabs = this.getTabs();
|
|
38
|
-
if (tabs.length > 0) {
|
|
39
|
-
this.internalValue = tabs[0]?.id ?? tabs[0]?.getAttribute('aria-controls') ?? '';
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
this.syncState();
|
|
43
|
-
this.host.addEventListener('keydown', this.onKeydown);
|
|
44
|
-
this.host.addEventListener('click', this.onClick);
|
|
45
|
-
}
|
|
46
|
-
disconnectedCallback() {
|
|
47
|
-
this.host.removeEventListener('keydown', this.onKeydown);
|
|
48
|
-
this.host.removeEventListener('click', this.onClick);
|
|
49
|
-
}
|
|
50
|
-
componentDidUpdate() {
|
|
51
|
-
this.syncState();
|
|
52
|
-
}
|
|
53
|
-
getTabs() {
|
|
54
|
-
return Array.from(this.host.querySelectorAll('[role="tab"]'));
|
|
55
|
-
}
|
|
56
|
-
setValueFromTab(tab, trigger) {
|
|
57
|
-
const newValue = tab.id ?? tab.getAttribute('aria-controls') ?? '';
|
|
58
|
-
if (!newValue)
|
|
59
|
-
return;
|
|
60
|
-
const prev = this.internalValue;
|
|
61
|
-
if (!isControlled(this.value))
|
|
62
|
-
this.internalValue = newValue;
|
|
63
|
-
this.syncState();
|
|
64
|
-
dispatchDetail(this.host, 'select', { value: newValue, previousValue: prev || undefined, trigger });
|
|
65
|
-
}
|
|
66
|
-
onClick = (e) => {
|
|
67
|
-
const tab = e.target.closest?.('[role="tab"]');
|
|
68
|
-
if (!tab || !this.host.contains(tab))
|
|
69
|
-
return;
|
|
70
|
-
this.setValueFromTab(tab, eventToTrigger(e));
|
|
71
|
-
};
|
|
72
|
-
onKeydown = (e) => {
|
|
73
|
-
const tab = e.target.closest?.('[role="tab"]');
|
|
74
|
-
if (!tab || !this.host.contains(tab))
|
|
75
|
-
return;
|
|
76
|
-
const tabs = this.getTabs();
|
|
77
|
-
if (tabs.length === 0)
|
|
78
|
-
return;
|
|
79
|
-
const currentIndex = tabs.indexOf(tab);
|
|
80
|
-
const isVertical = this.orientation === 'vertical';
|
|
81
|
-
const prevKey = isVertical ? 'ArrowUp' : 'ArrowLeft';
|
|
82
|
-
const nextKey = isVertical ? 'ArrowDown' : 'ArrowRight';
|
|
83
|
-
if (e.key === nextKey || e.key === prevKey) {
|
|
84
|
-
e.preventDefault();
|
|
85
|
-
const nextIndex = e.key === nextKey
|
|
86
|
-
? Math.min(currentIndex + 1, tabs.length - 1)
|
|
87
|
-
: currentIndex <= 0
|
|
88
|
-
? tabs.length - 1
|
|
89
|
-
: currentIndex - 1;
|
|
90
|
-
this.setValueFromTab(tabs[nextIndex], 'keyboard');
|
|
91
|
-
tabs[nextIndex].focus();
|
|
92
|
-
}
|
|
93
|
-
};
|
|
94
|
-
render() {
|
|
95
|
-
return (h(Host, { key: '61044ac3f2fcb0f766d931416f42ff17ec94c00d', orientation: this.orientation, "data-orientation": this.orientation }, h("slot", { key: '3260c95bdd24581045b1c4e4d1b8f4d08daf02b4' })));
|
|
96
|
-
}
|
|
97
|
-
static get is() { return "ui-tabs"; }
|
|
98
|
-
static get encapsulation() { return "shadow"; }
|
|
99
|
-
static get originalStyleUrls() {
|
|
100
|
-
return {
|
|
101
|
-
"$": ["ui-tabs.css"]
|
|
102
|
-
};
|
|
103
|
-
}
|
|
104
|
-
static get styleUrls() {
|
|
105
|
-
return {
|
|
106
|
-
"$": ["ui-tabs.css"]
|
|
107
|
-
};
|
|
108
|
-
}
|
|
109
|
-
static get properties() {
|
|
110
|
-
return {
|
|
111
|
-
"value": {
|
|
112
|
-
"type": "string",
|
|
113
|
-
"mutable": false,
|
|
114
|
-
"complexType": {
|
|
115
|
-
"original": "string",
|
|
116
|
-
"resolved": "string",
|
|
117
|
-
"references": {}
|
|
118
|
-
},
|
|
119
|
-
"required": false,
|
|
120
|
-
"optional": true,
|
|
121
|
-
"docs": {
|
|
122
|
-
"tags": [],
|
|
123
|
-
"text": "Controlled selected tab value. Omit it to use defaultValue and local interaction state."
|
|
124
|
-
},
|
|
125
|
-
"getter": false,
|
|
126
|
-
"setter": false,
|
|
127
|
-
"reflect": false,
|
|
128
|
-
"attribute": "value"
|
|
129
|
-
},
|
|
130
|
-
"defaultValue": {
|
|
131
|
-
"type": "string",
|
|
132
|
-
"mutable": false,
|
|
133
|
-
"complexType": {
|
|
134
|
-
"original": "string",
|
|
135
|
-
"resolved": "string",
|
|
136
|
-
"references": {}
|
|
137
|
-
},
|
|
138
|
-
"required": false,
|
|
139
|
-
"optional": false,
|
|
140
|
-
"docs": {
|
|
141
|
-
"tags": [],
|
|
142
|
-
"text": ""
|
|
143
|
-
},
|
|
144
|
-
"getter": false,
|
|
145
|
-
"setter": false,
|
|
146
|
-
"reflect": false,
|
|
147
|
-
"attribute": "default-value",
|
|
148
|
-
"defaultValue": "''"
|
|
149
|
-
},
|
|
150
|
-
"orientation": {
|
|
151
|
-
"type": "string",
|
|
152
|
-
"mutable": false,
|
|
153
|
-
"complexType": {
|
|
154
|
-
"original": "'horizontal' | 'vertical'",
|
|
155
|
-
"resolved": "\"horizontal\" | \"vertical\"",
|
|
156
|
-
"references": {}
|
|
157
|
-
},
|
|
158
|
-
"required": false,
|
|
159
|
-
"optional": false,
|
|
160
|
-
"docs": {
|
|
161
|
-
"tags": [],
|
|
162
|
-
"text": ""
|
|
163
|
-
},
|
|
164
|
-
"getter": false,
|
|
165
|
-
"setter": false,
|
|
166
|
-
"reflect": false,
|
|
167
|
-
"attribute": "orientation",
|
|
168
|
-
"defaultValue": "'horizontal'"
|
|
169
|
-
}
|
|
170
|
-
};
|
|
171
|
-
}
|
|
172
|
-
static get states() {
|
|
173
|
-
return {
|
|
174
|
-
"internalValue": {}
|
|
175
|
-
};
|
|
176
|
-
}
|
|
177
|
-
static get elementRef() { return "host"; }
|
|
178
|
-
static get watchers() {
|
|
179
|
-
return [{
|
|
180
|
-
"propName": "value",
|
|
181
|
-
"methodName": "syncFromProp"
|
|
182
|
-
}, {
|
|
183
|
-
"propName": "internalValue",
|
|
184
|
-
"methodName": "syncState"
|
|
185
|
-
}, {
|
|
186
|
-
"propName": "orientation",
|
|
187
|
-
"methodName": "syncState"
|
|
188
|
-
}];
|
|
189
|
-
}
|
|
190
|
-
}
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
:host {
|
|
2
|
-
display: inline-flex;
|
|
3
|
-
min-inline-size: 0;
|
|
4
|
-
color: var(--ui-text-primary);
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
::slotted(textarea) {
|
|
8
|
-
width: 100%;
|
|
9
|
-
appearance: none;
|
|
10
|
-
border: 1px solid var(--ui-control-border, var(--ui-border-default));
|
|
11
|
-
border-radius: var(--ui-radius-2);
|
|
12
|
-
background: var(--ui-control-surface, var(--ui-surface-default));
|
|
13
|
-
color: inherit;
|
|
14
|
-
font: inherit;
|
|
15
|
-
line-height: var(--ui-line-height-md);
|
|
16
|
-
min-block-size: calc(var(--ui-space-12, 3rem) * 2);
|
|
17
|
-
padding: var(--ui-space-2) var(--ui-space-3);
|
|
18
|
-
margin: 0;
|
|
19
|
-
resize: vertical;
|
|
20
|
-
transition:
|
|
21
|
-
border-color var(--ui-motion-fast) var(--ui-motion-ease),
|
|
22
|
-
box-shadow var(--ui-motion-fast) var(--ui-motion-ease),
|
|
23
|
-
background-color var(--ui-motion-fast) var(--ui-motion-ease);
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
::slotted(textarea:hover:not(:focus):not(:disabled)) {
|
|
27
|
-
border-color: var(--ui-control-border-hover, var(--ui-border-strong));
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
::slotted(textarea:focus) {
|
|
31
|
-
border-color: var(--ui-control-focus, var(--ui-focus-ring));
|
|
32
|
-
box-shadow: 0 0 0 3px var(--ui-control-focus-halo, var(--ui-accent-soft));
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
:host([data-invalid='true'])::slotted(textarea),
|
|
36
|
-
::slotted(textarea[aria-invalid='true']) {
|
|
37
|
-
border-color: var(--ui-accent-active);
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
::slotted(textarea:disabled) {
|
|
41
|
-
background: var(--ui-control-surface-disabled, var(--ui-surface-muted));
|
|
42
|
-
color: var(--ui-text-muted);
|
|
43
|
-
cursor: not-allowed;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
::slotted(textarea:focus-visible) {
|
|
47
|
-
outline: 2px solid var(--ui-focus-ring);
|
|
48
|
-
outline-offset: 2px;
|
|
49
|
-
}
|
|
@@ -1,241 +0,0 @@
|
|
|
1
|
-
import { Host, h } from "@stencil/core";
|
|
2
|
-
import { dispatchDetail, eventToTrigger } from "../../utils/events";
|
|
3
|
-
export class UITextarea {
|
|
4
|
-
host;
|
|
5
|
-
value;
|
|
6
|
-
defaultValue = '';
|
|
7
|
-
disabled = false;
|
|
8
|
-
invalid = false;
|
|
9
|
-
readOnly = false;
|
|
10
|
-
rows = 4;
|
|
11
|
-
internalValue = '';
|
|
12
|
-
slotRef;
|
|
13
|
-
syncFromProp() {
|
|
14
|
-
if (this.value !== undefined)
|
|
15
|
-
this.internalValue = this.value;
|
|
16
|
-
}
|
|
17
|
-
syncToTextarea() {
|
|
18
|
-
const textarea = this.getTextarea();
|
|
19
|
-
if (!textarea)
|
|
20
|
-
return;
|
|
21
|
-
this.host.dataset.invalid = this.invalid ? 'true' : '';
|
|
22
|
-
// An omitted host value leaves the slotted textarea under framework or
|
|
23
|
-
// native-form control instead of resetting it during component updates.
|
|
24
|
-
if (this.value !== undefined)
|
|
25
|
-
textarea.value = this.internalValue;
|
|
26
|
-
textarea.defaultValue = this.defaultValue;
|
|
27
|
-
textarea.disabled = this.disabled;
|
|
28
|
-
textarea.readOnly = this.readOnly;
|
|
29
|
-
textarea.rows = this.rows;
|
|
30
|
-
textarea.setAttribute('aria-invalid', this.invalid ? 'true' : 'false');
|
|
31
|
-
}
|
|
32
|
-
componentDidLoad() {
|
|
33
|
-
this.syncFromProp();
|
|
34
|
-
this.slotRef?.addEventListener('slotchange', () => this.syncToTextarea());
|
|
35
|
-
this.syncToTextarea();
|
|
36
|
-
const textarea = this.getTextarea();
|
|
37
|
-
textarea?.addEventListener('input', this.onInput);
|
|
38
|
-
textarea?.addEventListener('change', this.onChange);
|
|
39
|
-
}
|
|
40
|
-
disconnectedCallback() {
|
|
41
|
-
const textarea = this.getTextarea();
|
|
42
|
-
textarea?.removeEventListener('input', this.onInput);
|
|
43
|
-
textarea?.removeEventListener('change', this.onChange);
|
|
44
|
-
}
|
|
45
|
-
componentDidUpdate() {
|
|
46
|
-
this.syncToTextarea();
|
|
47
|
-
}
|
|
48
|
-
getTextarea() {
|
|
49
|
-
const slot = this.host.shadowRoot?.querySelector('slot');
|
|
50
|
-
const nodes = slot?.assignedElements() ?? Array.from(this.host.children);
|
|
51
|
-
return nodes.find((el) => el.tagName === 'TEXTAREA') ?? null;
|
|
52
|
-
}
|
|
53
|
-
onInput = (e) => {
|
|
54
|
-
const textarea = e.target;
|
|
55
|
-
if (!textarea)
|
|
56
|
-
return;
|
|
57
|
-
this.internalValue = textarea.value;
|
|
58
|
-
dispatchDetail(this.host, 'input', {
|
|
59
|
-
value: this.internalValue,
|
|
60
|
-
trigger: eventToTrigger(e),
|
|
61
|
-
});
|
|
62
|
-
};
|
|
63
|
-
onChange = (e) => {
|
|
64
|
-
const textarea = this.getTextarea();
|
|
65
|
-
if (!textarea)
|
|
66
|
-
return;
|
|
67
|
-
this.internalValue = textarea.value;
|
|
68
|
-
dispatchDetail(this.host, 'change', {
|
|
69
|
-
value: this.internalValue,
|
|
70
|
-
trigger: eventToTrigger(e),
|
|
71
|
-
});
|
|
72
|
-
};
|
|
73
|
-
render() {
|
|
74
|
-
return (h(Host, { key: 'a554edb1a0ef40a2c116e3064e52af7474e065e4', "data-invalid": this.invalid ? '' : undefined }, h("slot", { key: 'a4eb8034ec11f8b3b06ace7287410fd839004593', ref: (el) => (this.slotRef = el) })));
|
|
75
|
-
}
|
|
76
|
-
static get is() { return "ui-textarea"; }
|
|
77
|
-
static get encapsulation() { return "shadow"; }
|
|
78
|
-
static get originalStyleUrls() {
|
|
79
|
-
return {
|
|
80
|
-
"$": ["ui-textarea.css"]
|
|
81
|
-
};
|
|
82
|
-
}
|
|
83
|
-
static get styleUrls() {
|
|
84
|
-
return {
|
|
85
|
-
"$": ["ui-textarea.css"]
|
|
86
|
-
};
|
|
87
|
-
}
|
|
88
|
-
static get properties() {
|
|
89
|
-
return {
|
|
90
|
-
"value": {
|
|
91
|
-
"type": "string",
|
|
92
|
-
"mutable": false,
|
|
93
|
-
"complexType": {
|
|
94
|
-
"original": "string",
|
|
95
|
-
"resolved": "string",
|
|
96
|
-
"references": {}
|
|
97
|
-
},
|
|
98
|
-
"required": false,
|
|
99
|
-
"optional": true,
|
|
100
|
-
"docs": {
|
|
101
|
-
"tags": [],
|
|
102
|
-
"text": ""
|
|
103
|
-
},
|
|
104
|
-
"getter": false,
|
|
105
|
-
"setter": false,
|
|
106
|
-
"reflect": false,
|
|
107
|
-
"attribute": "value"
|
|
108
|
-
},
|
|
109
|
-
"defaultValue": {
|
|
110
|
-
"type": "string",
|
|
111
|
-
"mutable": false,
|
|
112
|
-
"complexType": {
|
|
113
|
-
"original": "string",
|
|
114
|
-
"resolved": "string",
|
|
115
|
-
"references": {}
|
|
116
|
-
},
|
|
117
|
-
"required": false,
|
|
118
|
-
"optional": false,
|
|
119
|
-
"docs": {
|
|
120
|
-
"tags": [],
|
|
121
|
-
"text": ""
|
|
122
|
-
},
|
|
123
|
-
"getter": false,
|
|
124
|
-
"setter": false,
|
|
125
|
-
"reflect": false,
|
|
126
|
-
"attribute": "default-value",
|
|
127
|
-
"defaultValue": "''"
|
|
128
|
-
},
|
|
129
|
-
"disabled": {
|
|
130
|
-
"type": "boolean",
|
|
131
|
-
"mutable": false,
|
|
132
|
-
"complexType": {
|
|
133
|
-
"original": "boolean",
|
|
134
|
-
"resolved": "boolean",
|
|
135
|
-
"references": {}
|
|
136
|
-
},
|
|
137
|
-
"required": false,
|
|
138
|
-
"optional": false,
|
|
139
|
-
"docs": {
|
|
140
|
-
"tags": [],
|
|
141
|
-
"text": ""
|
|
142
|
-
},
|
|
143
|
-
"getter": false,
|
|
144
|
-
"setter": false,
|
|
145
|
-
"reflect": false,
|
|
146
|
-
"attribute": "disabled",
|
|
147
|
-
"defaultValue": "false"
|
|
148
|
-
},
|
|
149
|
-
"invalid": {
|
|
150
|
-
"type": "boolean",
|
|
151
|
-
"mutable": false,
|
|
152
|
-
"complexType": {
|
|
153
|
-
"original": "boolean",
|
|
154
|
-
"resolved": "boolean",
|
|
155
|
-
"references": {}
|
|
156
|
-
},
|
|
157
|
-
"required": false,
|
|
158
|
-
"optional": false,
|
|
159
|
-
"docs": {
|
|
160
|
-
"tags": [],
|
|
161
|
-
"text": ""
|
|
162
|
-
},
|
|
163
|
-
"getter": false,
|
|
164
|
-
"setter": false,
|
|
165
|
-
"reflect": false,
|
|
166
|
-
"attribute": "invalid",
|
|
167
|
-
"defaultValue": "false"
|
|
168
|
-
},
|
|
169
|
-
"readOnly": {
|
|
170
|
-
"type": "boolean",
|
|
171
|
-
"mutable": false,
|
|
172
|
-
"complexType": {
|
|
173
|
-
"original": "boolean",
|
|
174
|
-
"resolved": "boolean",
|
|
175
|
-
"references": {}
|
|
176
|
-
},
|
|
177
|
-
"required": false,
|
|
178
|
-
"optional": false,
|
|
179
|
-
"docs": {
|
|
180
|
-
"tags": [],
|
|
181
|
-
"text": ""
|
|
182
|
-
},
|
|
183
|
-
"getter": false,
|
|
184
|
-
"setter": false,
|
|
185
|
-
"reflect": false,
|
|
186
|
-
"attribute": "readonly",
|
|
187
|
-
"defaultValue": "false"
|
|
188
|
-
},
|
|
189
|
-
"rows": {
|
|
190
|
-
"type": "number",
|
|
191
|
-
"mutable": false,
|
|
192
|
-
"complexType": {
|
|
193
|
-
"original": "number",
|
|
194
|
-
"resolved": "number",
|
|
195
|
-
"references": {}
|
|
196
|
-
},
|
|
197
|
-
"required": false,
|
|
198
|
-
"optional": false,
|
|
199
|
-
"docs": {
|
|
200
|
-
"tags": [],
|
|
201
|
-
"text": ""
|
|
202
|
-
},
|
|
203
|
-
"getter": false,
|
|
204
|
-
"setter": false,
|
|
205
|
-
"reflect": false,
|
|
206
|
-
"attribute": "rows",
|
|
207
|
-
"defaultValue": "4"
|
|
208
|
-
}
|
|
209
|
-
};
|
|
210
|
-
}
|
|
211
|
-
static get states() {
|
|
212
|
-
return {
|
|
213
|
-
"internalValue": {}
|
|
214
|
-
};
|
|
215
|
-
}
|
|
216
|
-
static get elementRef() { return "host"; }
|
|
217
|
-
static get watchers() {
|
|
218
|
-
return [{
|
|
219
|
-
"propName": "value",
|
|
220
|
-
"methodName": "syncFromProp"
|
|
221
|
-
}, {
|
|
222
|
-
"propName": "internalValue",
|
|
223
|
-
"methodName": "syncToTextarea"
|
|
224
|
-
}, {
|
|
225
|
-
"propName": "defaultValue",
|
|
226
|
-
"methodName": "syncToTextarea"
|
|
227
|
-
}, {
|
|
228
|
-
"propName": "disabled",
|
|
229
|
-
"methodName": "syncToTextarea"
|
|
230
|
-
}, {
|
|
231
|
-
"propName": "invalid",
|
|
232
|
-
"methodName": "syncToTextarea"
|
|
233
|
-
}, {
|
|
234
|
-
"propName": "readOnly",
|
|
235
|
-
"methodName": "syncToTextarea"
|
|
236
|
-
}, {
|
|
237
|
-
"propName": "rows",
|
|
238
|
-
"methodName": "syncToTextarea"
|
|
239
|
-
}];
|
|
240
|
-
}
|
|
241
|
-
}
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
:host {
|
|
2
|
-
position: fixed;
|
|
3
|
-
top: calc(var(--ui-space-4) + env(safe-area-inset-top));
|
|
4
|
-
left: 50%;
|
|
5
|
-
transform: translateX(-50%);
|
|
6
|
-
z-index: 9999;
|
|
7
|
-
display: grid;
|
|
8
|
-
gap: var(--ui-space-2);
|
|
9
|
-
inline-size: min(24rem, calc(100vw - (var(--ui-space-4) * 2)));
|
|
10
|
-
max-inline-size: 100%;
|
|
11
|
-
pointer-events: none;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
:host([popover]) {
|
|
15
|
-
right: auto;
|
|
16
|
-
bottom: auto;
|
|
17
|
-
margin: 0;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
:host > * {
|
|
21
|
-
pointer-events: auto;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
::slotted([data-ui-toast]) {
|
|
25
|
-
display: grid;
|
|
26
|
-
grid-template-columns: 1fr auto;
|
|
27
|
-
gap: var(--ui-space-2);
|
|
28
|
-
align-items: start;
|
|
29
|
-
border: 1px solid var(--ui-border-default);
|
|
30
|
-
border-radius: var(--ui-radius-3);
|
|
31
|
-
padding: var(--ui-space-3) var(--ui-space-4);
|
|
32
|
-
background: var(--ui-surface-elevated);
|
|
33
|
-
color: var(--ui-text-primary);
|
|
34
|
-
box-shadow: var(--ui-shadow-lg);
|
|
35
|
-
animation: ui-toast-enter 0.25s var(--ui-motion-ease) forwards;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
@keyframes ui-toast-enter {
|
|
39
|
-
from {
|
|
40
|
-
opacity: 0;
|
|
41
|
-
transform: translateY(-0.5rem);
|
|
42
|
-
}
|
|
43
|
-
to {
|
|
44
|
-
opacity: 1;
|
|
45
|
-
transform: translateY(0);
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
::slotted([data-ui-toast][aria-hidden='true']) {
|
|
50
|
-
display: none;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
::slotted([data-ui-toast-dismiss]) {
|
|
54
|
-
border: 0;
|
|
55
|
-
background: transparent;
|
|
56
|
-
color: var(--ui-text-secondary);
|
|
57
|
-
cursor: pointer;
|
|
58
|
-
font: inherit;
|
|
59
|
-
}
|
|
@@ -1,126 +0,0 @@
|
|
|
1
|
-
import { Host, h } from "@stencil/core";
|
|
2
|
-
import { eventToTrigger } from "../../utils/events";
|
|
3
|
-
import { dispatchDetail } from "../../utils/events";
|
|
4
|
-
import { createViewportSurface } from "../../overlay/positioning";
|
|
5
|
-
export class UIToastRegion {
|
|
6
|
-
host;
|
|
7
|
-
open = true;
|
|
8
|
-
internalOpen = false;
|
|
9
|
-
surface = null;
|
|
10
|
-
contentObserver = null;
|
|
11
|
-
pendingDismiss = null;
|
|
12
|
-
syncFromProp() {
|
|
13
|
-
this.syncContents();
|
|
14
|
-
}
|
|
15
|
-
syncSurface() {
|
|
16
|
-
if (this.internalOpen)
|
|
17
|
-
this.surface?.show();
|
|
18
|
-
else
|
|
19
|
-
this.surface?.hide();
|
|
20
|
-
}
|
|
21
|
-
componentDidLoad() {
|
|
22
|
-
this.surface = createViewportSurface(this.host);
|
|
23
|
-
this.contentObserver = new MutationObserver(this.syncContents);
|
|
24
|
-
this.contentObserver.observe(this.host, { childList: true, subtree: true });
|
|
25
|
-
this.syncContents();
|
|
26
|
-
this.syncSurface();
|
|
27
|
-
this.host.addEventListener('click', this.onClick);
|
|
28
|
-
}
|
|
29
|
-
disconnectedCallback() {
|
|
30
|
-
this.host.removeEventListener('click', this.onClick);
|
|
31
|
-
this.contentObserver?.disconnect();
|
|
32
|
-
this.contentObserver = null;
|
|
33
|
-
this.surface?.destroy();
|
|
34
|
-
this.surface = null;
|
|
35
|
-
}
|
|
36
|
-
getToasts() {
|
|
37
|
-
return Array.from(this.host.querySelectorAll('[data-ui-toast]'));
|
|
38
|
-
}
|
|
39
|
-
syncContents = () => {
|
|
40
|
-
const nextOpen = this.open && this.getToasts().length > 0;
|
|
41
|
-
const wasOpen = this.internalOpen;
|
|
42
|
-
const completedDismiss = this.pendingDismiss && !this.host.contains(this.pendingDismiss.toast)
|
|
43
|
-
? this.pendingDismiss
|
|
44
|
-
: null;
|
|
45
|
-
this.internalOpen = nextOpen;
|
|
46
|
-
if (wasOpen && !nextOpen && completedDismiss) {
|
|
47
|
-
dispatchDetail(this.host, 'close', {
|
|
48
|
-
open: false,
|
|
49
|
-
reason: 'action',
|
|
50
|
-
trigger: completedDismiss.trigger,
|
|
51
|
-
});
|
|
52
|
-
}
|
|
53
|
-
if (completedDismiss || !this.open)
|
|
54
|
-
this.pendingDismiss = null;
|
|
55
|
-
};
|
|
56
|
-
onClick = (e) => {
|
|
57
|
-
const dismissBtn = e.target.closest?.('[data-ui-toast-dismiss]');
|
|
58
|
-
if (!dismissBtn)
|
|
59
|
-
return;
|
|
60
|
-
const toast = dismissBtn.closest?.('[data-ui-toast]');
|
|
61
|
-
if (!toast)
|
|
62
|
-
return;
|
|
63
|
-
const id = toast.id ?? '';
|
|
64
|
-
const trigger = eventToTrigger(e);
|
|
65
|
-
this.pendingDismiss = { toast: toast, trigger };
|
|
66
|
-
dispatchDetail(this.host, 'dismiss', {
|
|
67
|
-
id,
|
|
68
|
-
reason: 'action',
|
|
69
|
-
trigger,
|
|
70
|
-
});
|
|
71
|
-
};
|
|
72
|
-
render() {
|
|
73
|
-
return (h(Host, { key: '9f9c2e14150c631c0f7cb427c693dcd52c20897d', role: "region", "aria-label": "Notifications", "aria-live": "polite", "data-open": this.internalOpen ? '' : undefined }, h("slot", { key: '9e1d9ebb6b587afab2c4302241cecb03a321cee1' })));
|
|
74
|
-
}
|
|
75
|
-
static get is() { return "ui-toast-region"; }
|
|
76
|
-
static get encapsulation() { return "shadow"; }
|
|
77
|
-
static get originalStyleUrls() {
|
|
78
|
-
return {
|
|
79
|
-
"$": ["ui-toast-region.css"]
|
|
80
|
-
};
|
|
81
|
-
}
|
|
82
|
-
static get styleUrls() {
|
|
83
|
-
return {
|
|
84
|
-
"$": ["ui-toast-region.css"]
|
|
85
|
-
};
|
|
86
|
-
}
|
|
87
|
-
static get properties() {
|
|
88
|
-
return {
|
|
89
|
-
"open": {
|
|
90
|
-
"type": "boolean",
|
|
91
|
-
"mutable": false,
|
|
92
|
-
"complexType": {
|
|
93
|
-
"original": "boolean",
|
|
94
|
-
"resolved": "boolean",
|
|
95
|
-
"references": {}
|
|
96
|
-
},
|
|
97
|
-
"required": false,
|
|
98
|
-
"optional": false,
|
|
99
|
-
"docs": {
|
|
100
|
-
"tags": [],
|
|
101
|
-
"text": ""
|
|
102
|
-
},
|
|
103
|
-
"getter": false,
|
|
104
|
-
"setter": false,
|
|
105
|
-
"reflect": false,
|
|
106
|
-
"attribute": "open",
|
|
107
|
-
"defaultValue": "true"
|
|
108
|
-
}
|
|
109
|
-
};
|
|
110
|
-
}
|
|
111
|
-
static get states() {
|
|
112
|
-
return {
|
|
113
|
-
"internalOpen": {}
|
|
114
|
-
};
|
|
115
|
-
}
|
|
116
|
-
static get elementRef() { return "host"; }
|
|
117
|
-
static get watchers() {
|
|
118
|
-
return [{
|
|
119
|
-
"propName": "open",
|
|
120
|
-
"methodName": "syncFromProp"
|
|
121
|
-
}, {
|
|
122
|
-
"propName": "internalOpen",
|
|
123
|
-
"methodName": "syncSurface"
|
|
124
|
-
}];
|
|
125
|
-
}
|
|
126
|
-
}
|