@leavepulse/ui 0.44.0 → 0.45.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +49 -3
- package/dist/assets/{LpCommandPalette-DCP5g2ik.css → LpCommandPalette-nGNnzXqQ.css} +21 -21
- package/dist/assets/{LpRollingText-CR1mb0Vt.css → LpRollingText-BGnE6q9j.css} +3 -0
- package/dist/assets/{LpShortcutsDialog-ChUyU7oV.css → LpShortcutsDialog-CqYX3yy6.css} +28 -7
- package/dist/assets/{LpTable-DDQNdf86.css → LpTable-CPwWxTJS.css} +49 -9
- package/dist/chunks/{ContextMenuItems-CrfeNPWT.js → ContextMenuItems-BtKU7074.js} +2 -1
- package/dist/chunks/{LayoutCanvas-D-jPOAvg.js → LayoutCanvas-BkaGXTjx.js} +1 -1
- package/dist/chunks/{LayoutNode-D8Xy9N-o.js → LayoutNode-B3_9E1Xa.js} +9 -5
- package/dist/chunks/{LpActionBar-BbwCF6l5.js → LpActionBar-CnfFVIwC.js} +3 -3
- package/dist/chunks/{LpAddressInput-BrOqkZqg.js → LpAddressInput-BwX8uo4_.js} +7 -7
- package/dist/chunks/{LpAlert-DkOIjsbq.js → LpAlert-B6ilrM7T.js} +1 -1
- package/dist/chunks/{LpAppShell-BUKPcHco.js → LpAppShell-C53_RaGF.js} +4 -4
- package/dist/chunks/{LpAutocomplete-DxV3Y9h4.js → LpAutocomplete-C8IgSMsi.js} +2 -1
- package/dist/chunks/{LpAvatar-ClBbEYZN.js → LpAvatar-C1XStdOo.js} +3 -3
- package/dist/chunks/{LpBreadcrumbs-B8IJgFIc.js → LpBreadcrumbs-CQJd73Gm.js} +1 -1
- package/dist/chunks/{LpButton-kqJBHIIb.js → LpButton-CKSwC6Mu.js} +1 -1
- package/dist/chunks/{LpCalendar-B7Ko5RdR.js → LpCalendar-DrA2McTU.js} +1 -1
- package/dist/chunks/{LpCard-CpRByR0q.js → LpCard-C2IvucmX.js} +1 -1
- package/dist/chunks/{LpCheckbox-DpqchzH4.js → LpCheckbox-Bkj13CbW.js} +1 -1
- package/dist/chunks/{LpCodeBlock-DeHJPq7p.js → LpCodeBlock-ca7ANFyW.js} +1 -1
- package/dist/chunks/{LpColorPicker-Bhf1qxhB.js → LpColorPicker-zz4VGkG4.js} +46 -20
- package/dist/chunks/{LpConfirmDialog-CIUOSnWo.js → LpConfirmDialog-DCw5jR1t.js} +3 -3
- package/dist/chunks/{LpConfirmHost-CDm0Wtpv.js → LpConfirmHost-CbywMpMP.js} +1 -1
- package/dist/chunks/{LpContextMenu-DQw5dGfG.js → LpContextMenu-BqkAYa9X.js} +2 -1
- package/dist/chunks/{LpDatePicker-Drirx1AK.js → LpDatePicker-DuusgT69.js} +13 -9
- package/dist/chunks/LpDateRangePicker-DHeuznfC.js +208 -0
- package/dist/chunks/{LpDisclosure-ChQYmjlR.js → LpDisclosure-Cc23-JOT.js} +1 -1
- package/dist/chunks/{LpDrawer-bScx-KMO.js → LpDrawer-Dt4aB4Fr.js} +2 -2
- package/dist/chunks/{LpDropdownMenu-DJpoqRCb.js → LpDropdownMenu-DdJGQzPn.js} +2 -1
- package/dist/chunks/{LpEmptyState-Dsdqz1Wj.js → LpEmptyState-BJbZXC8D.js} +1 -1
- package/dist/chunks/LpFieldNotice-wtieLUTj.js +64 -0
- package/dist/chunks/{LpFileTree-CSI_5SK2.js → LpFileTree-CNurOvkV.js} +3 -3
- package/dist/chunks/{LpFileTreeNode-B4MiSQX2.js → LpFileTreeNode-D_qRRdsH.js} +3 -3
- package/dist/chunks/{LpFormField-CIk5qosh.js → LpFormField-CtVYj6tO.js} +29 -15
- package/dist/chunks/{LpIcon-CCnX5_2j.js → LpIcon-DYtaid0K.js} +20 -6
- package/dist/chunks/{LpInput-C0e8y8_d.js → LpInput-D-YGQbEv.js} +39 -16
- package/dist/chunks/{LpLightbox-Mr0W_6HK.js → LpLightbox-DSDahF23.js} +1 -1
- package/dist/chunks/{LpLogViewer-YBOaFnc_.js → LpLogViewer-KypbgOyo.js} +252 -58
- package/dist/chunks/{LpMapPicker-NUzS9e37.js → LpMapPicker-Cc84LaM3.js} +1 -1
- package/dist/chunks/{LpMediaGallery-DfJmMW0I.js → LpMediaGallery-YKr-cQPN.js} +2 -2
- package/dist/chunks/{LpModal-DPwGKBPv.js → LpModal-DMMDQHAu.js} +3 -3
- package/dist/chunks/{LpModalNav-DPg5H9f3.js → LpModalNav-BVPDyIup.js} +4 -4
- package/dist/chunks/{LpNotificationBell-t5yn-siX.js → LpNotificationBell-CCwyJP5C.js} +26 -14
- package/dist/chunks/{LpNumberField-DWnQKktS.js → LpNumberField-B77O-z28.js} +1 -1
- package/dist/chunks/{LpPagination-DFngX7Xo.js → LpPagination-BcDlo3r_.js} +1 -1
- package/dist/chunks/{LpPasswordInput-CWVDuBJ5.js → LpPasswordInput-eKzQhbQP.js} +2 -2
- package/dist/chunks/{LpPhoneInput-CD-ZTeSd.js → LpPhoneInput-BCbrrhgE.js} +126 -23
- package/dist/chunks/{LpPie-BLco31Nx.js → LpPie-BEJ2SfI6.js} +9 -10
- package/dist/chunks/{LpPopover-p_e_shN3.js → LpPopover-DCKeqiVn.js} +1 -0
- package/dist/chunks/LpRangeCalendar-DZuaRV0W.js +331 -0
- package/dist/chunks/{LpRollingText-CM5gkSeF.js → LpRollingText-DB7upf-5.js} +1 -1
- package/dist/chunks/{LpScrollArea-D8xyKXcF.js → LpScrollArea-Bry1fdOM.js} +14 -2
- package/dist/chunks/{LpSection-aM6J_u51.js → LpSection-tKEH0jYf.js} +1 -1
- package/dist/chunks/{LpSegmented-Dejd7cIx.js → LpSegmented-C09EEam2.js} +1 -1
- package/dist/chunks/{LpSelect-DrRD9I7L.js → LpSelect-DNIL6MB9.js} +20 -23
- package/dist/chunks/{LpSidebar-BgwUNWpJ.js → LpSidebar-CQNB0-yU.js} +3 -3
- package/dist/chunks/{LpSidebarNav-Bqxz8aWT.js → LpSidebarNav-kx-LdqNU.js} +3 -3
- package/dist/chunks/{LpStat-dXtyrdX9.js → LpStat-B-7udBRP.js} +1 -1
- package/dist/chunks/{LpStepper-Bk-XaQYU.js → LpStepper-C7XiVKZj.js} +34 -19
- package/dist/chunks/{LpSwitch-B1aLKulj.js → LpSwitch-OrcOJX9m.js} +1 -1
- package/dist/chunks/LpTableFilter-BV8PpLM9.js +158 -0
- package/dist/chunks/{LpTabs-_qMVaZJ6.js → LpTabs-29iW1XOx.js} +1 -1
- package/dist/chunks/LpTagsInput-D1SuqbhB.js +300 -0
- package/dist/chunks/{LpTextarea-yP8hGedR.js → LpTextarea-uuScWo6-.js} +1 -1
- package/dist/chunks/{LpThemeProvider-Wjm7Tuit.js → LpThemeProvider-Be4r2TQX.js} +1 -1
- package/dist/chunks/{LpThemeSwitcher-CKLc10KZ.js → LpThemeSwitcher-B4aVPbNC.js} +19 -22
- package/dist/chunks/{LpTimeField-C5HRgS5H.js → LpTimeField-Cqe7fXnh.js} +1 -1
- package/dist/chunks/{LpToaster--oT6lfhL.js → LpToaster-DpJvoCOh.js} +37 -3
- package/dist/chunks/{LpTooltip-CBdzeKNf.js → LpTooltip-CXVKcOXT.js} +3 -2
- package/dist/chunks/{LpTopologyCanvas-DocsLal3.js → LpTopologyCanvas-6ozNrQKh.js} +2 -1
- package/dist/chunks/{LpUptimeBar-DLtxOMRy.js → LpUptimeBar-ugcv25xj.js} +2 -2
- package/dist/chunks/icons-CkA0njzm.js +43 -0
- package/dist/chunks/{useTheme-C8JHUlPM.js → useTheme-DJm1JSsY.js} +47 -50
- package/dist/component-names.d.ts +1 -1
- package/dist/components/ContextMenuItems.vue.js +1 -1
- package/dist/components/LayoutCanvas.vue.js +1 -1
- package/dist/components/LayoutNode.vue.js +1 -1
- package/dist/components/LpActionBar.vue.js +1 -1
- package/dist/components/LpAddressInput.vue.js +1 -1
- package/dist/components/LpAlert.vue.js +1 -1
- package/dist/components/LpAppShell.vue.js +1 -1
- package/dist/components/LpAutocomplete.vue.js +1 -1
- package/dist/components/LpAvatar.vue.js +1 -1
- package/dist/components/LpBreadcrumbs.vue.js +1 -1
- package/dist/components/LpButton.vue.d.ts +2 -2
- package/dist/components/LpButton.vue.js +1 -1
- package/dist/components/LpCalendar.vue.js +1 -1
- package/dist/components/LpCard.vue.js +1 -1
- package/dist/components/LpChart.vue.d.ts +16 -1
- package/dist/components/LpChart.vue.js +63 -5
- package/dist/components/LpCheckbox.vue.js +1 -1
- package/dist/components/LpCodeBlock.vue.js +1 -1
- package/dist/components/LpColorPicker.vue.d.ts +2 -2
- package/dist/components/LpColorPicker.vue.js +1 -1
- package/dist/components/LpCommandPalette.vue.d.ts +6 -0
- package/dist/components/LpCommandPalette.vue.js +61 -10
- package/dist/components/LpConfirmDialog.vue.js +1 -1
- package/dist/components/LpConfirmHost.vue.js +1 -1
- package/dist/components/LpContextMenu.vue.js +1 -1
- package/dist/components/LpDatePicker.vue.js +1 -1
- package/dist/components/LpDateRangePicker.vue.d.ts +60 -0
- package/dist/components/LpDateRangePicker.vue.js +4 -0
- package/dist/components/LpDisclosure.vue.js +1 -1
- package/dist/components/LpDrawer.vue.js +1 -1
- package/dist/components/LpDropdownMenu.vue.js +1 -1
- package/dist/components/LpDropzone.vue.js +1 -1
- package/dist/components/LpEmptyState.vue.js +1 -1
- package/dist/components/LpFieldNotice.vue.d.ts +8 -0
- package/dist/components/LpFieldNotice.vue.js +4 -0
- package/dist/components/LpFileTree.vue.js +1 -1
- package/dist/components/LpFileTreeNode.vue.js +1 -1
- package/dist/components/LpFormField.vue.d.ts +4 -1
- package/dist/components/LpFormField.vue.js +1 -1
- package/dist/components/LpIcon.vue.d.ts +0 -1
- package/dist/components/LpIcon.vue.js +1 -1
- package/dist/components/LpImageEditor.vue.js +2 -2
- package/dist/components/LpInput.vue.d.ts +19 -0
- package/dist/components/LpInput.vue.js +1 -1
- package/dist/components/LpLightbox.vue.js +1 -1
- package/dist/components/LpLogViewer.vue.d.ts +52 -1
- package/dist/components/LpLogViewer.vue.js +1 -1
- package/dist/components/LpMapPicker.vue.js +1 -1
- package/dist/components/LpMediaGallery.vue.js +1 -1
- package/dist/components/LpModal.vue.js +1 -1
- package/dist/components/LpModalNav.vue.js +1 -1
- package/dist/components/LpNotificationBell.vue.js +1 -1
- package/dist/components/LpNumberField.vue.js +1 -1
- package/dist/components/LpPagination.vue.js +1 -1
- package/dist/components/LpPasswordInput.vue.js +1 -1
- package/dist/components/LpPhoneInput.vue.d.ts +13 -0
- package/dist/components/LpPhoneInput.vue.js +1 -1
- package/dist/components/LpPie.vue.js +1 -1
- package/dist/components/LpPopover.vue.js +1 -1
- package/dist/components/LpProgress.vue.d.ts +1 -1
- package/dist/components/LpRangeCalendar.vue.d.ts +51 -0
- package/dist/components/LpRangeCalendar.vue.js +4 -0
- package/dist/components/LpRollingText.vue.d.ts +1 -1
- package/dist/components/LpRollingText.vue.js +1 -1
- package/dist/components/LpScrollArea.vue.d.ts +2 -2
- package/dist/components/LpScrollArea.vue.js +1 -1
- package/dist/components/LpSection.vue.js +1 -1
- package/dist/components/LpSegmented.vue.js +1 -1
- package/dist/components/LpSelect.vue.js +1 -1
- package/dist/components/LpShortcutsDialog.vue.d.ts +6 -0
- package/dist/components/LpShortcutsDialog.vue.js +56 -14
- package/dist/components/LpSidebar.vue.js +1 -1
- package/dist/components/LpSidebarNav.vue.js +1 -1
- package/dist/components/LpStat.vue.js +1 -1
- package/dist/components/LpStepper.vue.js +1 -1
- package/dist/components/LpSwitch.vue.js +1 -1
- package/dist/components/LpTable.vue.d.ts +84 -2
- package/dist/components/LpTable.vue.js +481 -107
- package/dist/components/LpTableFilter.vue.d.ts +31 -0
- package/dist/components/LpTableFilter.vue.js +4 -0
- package/dist/components/LpTabs.vue.js +1 -1
- package/dist/components/LpTagsInput.vue.d.ts +77 -0
- package/dist/components/LpTagsInput.vue.js +4 -0
- package/dist/components/LpTextarea.vue.js +1 -1
- package/dist/components/LpThemeProvider.vue.js +1 -1
- package/dist/components/LpThemeSwitcher.vue.d.ts +2 -2
- package/dist/components/LpThemeSwitcher.vue.js +1 -1
- package/dist/components/LpTimeField.vue.js +1 -1
- package/dist/components/LpToaster.vue.js +1 -1
- package/dist/components/LpTooltip.vue.js +1 -1
- package/dist/components/LpTopologyCanvas.vue.js +1 -1
- package/dist/components/LpUptimeBar.vue.js +1 -1
- package/dist/components/chart.js +3 -2
- package/dist/components/commandSearch.js +3 -0
- package/dist/components/dateRange.d.ts +43 -0
- package/dist/components/dateRange.js +76 -0
- package/dist/components/exportData.d.ts +58 -0
- package/dist/components/exportData.js +165 -0
- package/dist/components/logSearch.d.ts +18 -0
- package/dist/components/logSearch.js +36 -0
- package/dist/components/phone.d.ts +41 -0
- package/dist/components/phone.js +80 -0
- package/dist/components/tableFilter.d.ts +36 -0
- package/dist/components/tableFilter.js +84 -0
- package/dist/components/tags.d.ts +20 -0
- package/dist/components/tags.js +37 -0
- package/dist/composables/useField.d.ts +4 -0
- package/dist/composables/useFieldNotice.d.ts +17 -0
- package/dist/composables/useFieldNotice.js +28 -0
- package/dist/composables/useForm.d.ts +53 -0
- package/dist/composables/useForm.js +207 -0
- package/dist/composables/useHotkeys.d.ts +65 -5
- package/dist/composables/useHotkeys.js +170 -9
- package/dist/composables/useInputMask.d.ts +59 -0
- package/dist/composables/useInputMask.js +170 -0
- package/dist/composables/usePaintSelect.d.ts +22 -0
- package/dist/composables/usePaintSelect.js +169 -0
- package/dist/composables/useShift.js +7 -2
- package/dist/icons-all.d.ts +1 -0
- package/dist/icons-all.js +3 -0
- package/dist/icons.d.ts +14 -1
- package/dist/index.d.ts +29 -3
- package/dist/index.js +195 -138
- package/dist/kit-icons.d.ts +2 -0
- package/dist/theme/backdrop.d.ts +12 -0
- package/dist/theme/presets.d.ts +0 -2
- package/package.json +13 -4
- package/src/component-names.ts +4 -0
- package/src/components/ContextMenuItems.vue +1 -1
- package/src/components/LayoutNode.vue +11 -2
- package/src/components/LpActionBar.vue +1 -1
- package/src/components/LpAutocomplete.vue +1 -0
- package/src/components/LpAvatar.vue +2 -2
- package/src/components/LpButton.vue +1 -1
- package/src/components/LpChart.vue +80 -1
- package/src/components/LpColorPicker.vue +34 -1
- package/src/components/LpCommandPalette.vue +81 -7
- package/src/components/LpContextMenu.vue +1 -1
- package/src/components/LpDatePicker.vue +8 -3
- package/src/components/LpDateRangePicker.vue +224 -0
- package/src/components/LpDropdownMenu.vue +1 -0
- package/src/components/LpFieldNotice.vue +65 -0
- package/src/components/LpFormField.vue +33 -4
- package/src/components/LpIcon.vue +22 -4
- package/src/components/LpInput.vue +46 -6
- package/src/components/LpLogViewer.vue +225 -22
- package/src/components/LpModal.vue +1 -1
- package/src/components/LpNotificationBell.vue +15 -7
- package/src/components/LpPhoneInput.vue +179 -20
- package/src/components/LpPie.vue +8 -5
- package/src/components/LpPopover.vue +1 -0
- package/src/components/LpRangeCalendar.vue +365 -0
- package/src/components/LpRollingText.vue +3 -0
- package/src/components/LpScrollArea.vue +22 -2
- package/src/components/LpSelect.vue +0 -0
- package/src/components/LpShortcutsDialog.vue +77 -8
- package/src/components/LpStepper.vue +23 -10
- package/src/components/LpSwitch.vue +1 -1
- package/src/components/LpTable.vue +584 -65
- package/src/components/LpTableFilter.vue +175 -0
- package/src/components/LpTagsInput.vue +364 -0
- package/src/components/LpThemeSwitcher.vue +19 -23
- package/src/components/LpToaster.vue +49 -1
- package/src/components/LpTooltip.vue +9 -2
- package/src/components/LpTopologyCanvas.vue +7 -1
- package/src/components/chart.ts +5 -3
- package/src/components/commandSearch.ts +6 -0
- package/src/components/dateRange.ts +134 -0
- package/src/components/exportData.ts +228 -0
- package/src/components/logSearch.ts +46 -0
- package/src/components/phone.ts +140 -0
- package/src/components/tableFilter.ts +122 -0
- package/src/components/tags.ts +62 -0
- package/src/composables/useField.ts +4 -0
- package/src/composables/useFieldNotice.ts +59 -0
- package/src/composables/useForm.ts +314 -0
- package/src/composables/useHotkeys.ts +269 -13
- package/src/composables/useInputMask.ts +254 -0
- package/src/composables/usePaintSelect.ts +243 -0
- package/src/composables/useShift.ts +13 -2
- package/src/iconSubset.d.mts +10 -0
- package/src/iconSubset.mjs +51 -0
- package/src/icons-all.ts +10 -0
- package/src/icons.ts +59 -8
- package/src/index.ts +37 -3
- package/src/kit-icons.ts +5 -0
- package/src/nuxt.ts +30 -2
- package/src/runtime/theme.plugin.ts +2 -2
- package/src/theme/backdrop.ts +69 -0
- package/src/theme/presets.ts +6 -64
- package/src/tokens/tokens.css +46 -0
|
@@ -19,6 +19,13 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
19
19
|
() => viewportRef.value?.viewportElement ?? null
|
|
20
20
|
);
|
|
21
21
|
__expose({ viewportEl });
|
|
22
|
+
const pointerFocus = ref(false);
|
|
23
|
+
function onViewportPointerDown() {
|
|
24
|
+
pointerFocus.value = true;
|
|
25
|
+
}
|
|
26
|
+
function onViewportBlur() {
|
|
27
|
+
pointerFocus.value = false;
|
|
28
|
+
}
|
|
22
29
|
const dragging = ref(false);
|
|
23
30
|
const atTop = ref(true);
|
|
24
31
|
const atBottom = ref(true);
|
|
@@ -124,9 +131,14 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
124
131
|
createVNode(unref(ScrollAreaViewport), {
|
|
125
132
|
ref_key: "viewportRef",
|
|
126
133
|
ref: viewportRef,
|
|
127
|
-
class: normalizeClass(["w-full min-h-0 min-w-0 flex-1 [&>div]:!block [&>div]:!min-w-0",
|
|
134
|
+
class: normalizeClass(["w-full min-h-0 min-w-0 flex-1 rounded-[inherit] outline-none [&>div]:!block [&>div]:!min-w-0", [
|
|
135
|
+
__props.instant ? "" : "scroll-smooth motion-reduce:scroll-auto",
|
|
136
|
+
pointerFocus.value ? "" : "focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-inset"
|
|
137
|
+
]]),
|
|
128
138
|
style: normalizeStyle(__props.fade ? { maskImage: fadeMask.value, WebkitMaskImage: fadeMask.value } : void 0),
|
|
129
|
-
onScrollPassive: onViewportScroll
|
|
139
|
+
onScrollPassive: onViewportScroll,
|
|
140
|
+
onPointerdown: onViewportPointerDown,
|
|
141
|
+
onFocusout: _cache[0] || (_cache[0] = (e) => e.target === e.currentTarget && onViewportBlur())
|
|
130
142
|
}, {
|
|
131
143
|
default: withCtx(() => [
|
|
132
144
|
createElementVNode("div", {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent, useSlots, computed, openBlock, createElementBlock, normalizeClass, createElementVNode, createBlock, createCommentVNode, resolveDynamicComponent, withCtx, renderSlot, createTextVNode, toDisplayString } from "vue";
|
|
2
2
|
import { tv } from "tailwind-variants";
|
|
3
|
-
import { _ as _sfc_main$1 } from "./LpIcon-
|
|
3
|
+
import { _ as _sfc_main$1 } from "./LpIcon-DYtaid0K.js";
|
|
4
4
|
const _hoisted_1 = { class: "min-w-0 flex-1 break-words" };
|
|
5
5
|
const _hoisted_2 = { class: "flex flex-wrap items-center gap-2" };
|
|
6
6
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
@@ -4,7 +4,7 @@ import { ToggleGroupRoot, ToggleGroupItem } from "reka-ui";
|
|
|
4
4
|
import { useFieldControl } from "../composables/useField.js";
|
|
5
5
|
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
6
6
|
import { usePillTransition } from "../composables/usePillTransition.js";
|
|
7
|
-
import { _ as _sfc_main$1 } from "./LpIcon-
|
|
7
|
+
import { _ as _sfc_main$1 } from "./LpIcon-DYtaid0K.js";
|
|
8
8
|
const _hoisted_1 = {
|
|
9
9
|
key: 2,
|
|
10
10
|
class: "relative z-10"
|
|
@@ -1,28 +1,21 @@
|
|
|
1
|
-
import { defineComponent, computed, ref, openBlock, createBlock, unref, withCtx, createVNode, normalizeClass, createElementBlock,
|
|
1
|
+
import { defineComponent, computed, ref, openBlock, createBlock, unref, withCtx, createVNode, normalizeClass, createElementBlock, withModifiers, createCommentVNode, toDisplayString, createTextVNode, Fragment, renderList, normalizeStyle, createElementVNode } from "vue";
|
|
2
2
|
import { ComboboxRoot, ComboboxAnchor, ComboboxTrigger, ComboboxPortal, ComboboxContent, ComboboxInput, ComboboxViewport, ComboboxEmpty, ComboboxItem, ComboboxItemIndicator } from "reka-ui";
|
|
3
3
|
import { useFieldControl } from "../composables/useField.js";
|
|
4
4
|
import { useLabels } from "../composables/useLpConfig.js";
|
|
5
5
|
import { POPOVER_PANEL, OPTION_ITEM } from "../components/dropdown.js";
|
|
6
|
-
import { _ as _sfc_main$
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
class: "truncate"
|
|
10
|
-
};
|
|
6
|
+
import { _ as _sfc_main$2 } from "./LpIcon-DYtaid0K.js";
|
|
7
|
+
import { _ as _sfc_main$1 } from "./LpRollingText-DB7upf-5.js";
|
|
8
|
+
const _hoisted_1 = ["aria-label"];
|
|
11
9
|
const _hoisted_2 = {
|
|
12
|
-
key: 1,
|
|
13
|
-
class: "truncate text-muted"
|
|
14
|
-
};
|
|
15
|
-
const _hoisted_3 = ["aria-label"];
|
|
16
|
-
const _hoisted_4 = {
|
|
17
10
|
key: 0,
|
|
18
11
|
class: "border-b border-line p-2"
|
|
19
12
|
};
|
|
20
|
-
const
|
|
13
|
+
const _hoisted_3 = {
|
|
21
14
|
key: 0,
|
|
22
15
|
class: "px-3 py-4 text-center text-sm italic text-muted"
|
|
23
16
|
};
|
|
24
|
-
const
|
|
25
|
-
const
|
|
17
|
+
const _hoisted_4 = { class: "flex flex-col" };
|
|
18
|
+
const _hoisted_5 = {
|
|
26
19
|
key: 0,
|
|
27
20
|
class: "text-xs text-muted"
|
|
28
21
|
};
|
|
@@ -146,7 +139,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
146
139
|
class: "flex min-w-0 flex-1 items-center gap-2 outline-none"
|
|
147
140
|
}, {
|
|
148
141
|
default: withCtx(() => [
|
|
149
|
-
|
|
142
|
+
createVNode(_sfc_main$1, {
|
|
143
|
+
value: displayLabel.value || __props.placeholder || "",
|
|
144
|
+
align: "start",
|
|
145
|
+
class: normalizeClass(["min-w-0", displayLabel.value ? "" : "text-muted"])
|
|
146
|
+
}, null, 8, ["value", "class"])
|
|
150
147
|
]),
|
|
151
148
|
_: 1
|
|
152
149
|
}, 8, ["id", "aria-invalid", "aria-describedby"]),
|
|
@@ -159,19 +156,19 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
159
156
|
}, ["prevent"])),
|
|
160
157
|
onClick: clear
|
|
161
158
|
}, [
|
|
162
|
-
createVNode(_sfc_main$
|
|
159
|
+
createVNode(_sfc_main$2, {
|
|
163
160
|
name: "lucide:x",
|
|
164
161
|
size: 16,
|
|
165
162
|
class: "transition-transform duration-200 ease-[var(--ease-emphasized)] group-hover:rotate-90 group-active:scale-90 motion-reduce:group-hover:rotate-0"
|
|
166
163
|
})
|
|
167
|
-
], 40,
|
|
164
|
+
], 40, _hoisted_1)) : createCommentVNode("", true),
|
|
168
165
|
createVNode(unref(ComboboxTrigger), {
|
|
169
166
|
tabindex: "-1",
|
|
170
167
|
"aria-hidden": "true",
|
|
171
168
|
class: "group/trig flex shrink-0 items-center text-muted transition-[rotate,color] duration-200 ease-[var(--ease-emphasized)] group-hover:text-ink data-[state=open]:rotate-180"
|
|
172
169
|
}, {
|
|
173
170
|
default: withCtx(() => [
|
|
174
|
-
createVNode(_sfc_main$
|
|
171
|
+
createVNode(_sfc_main$2, {
|
|
175
172
|
name: "lucide:chevron-down",
|
|
176
173
|
size: 16,
|
|
177
174
|
class: "transition-transform duration-200 ease-[var(--ease-emphasized)] group-data-[state=closed]/trig:group-hover:translate-y-1"
|
|
@@ -190,7 +187,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
190
187
|
class: normalizeClass([unref(POPOVER_PANEL), "z-(--z-popover) max-h-72 w-(--reka-combobox-trigger-width) overflow-hidden"])
|
|
191
188
|
}, {
|
|
192
189
|
default: withCtx(() => [
|
|
193
|
-
__props.searchable || serverSide.value ? (openBlock(), createElementBlock("div",
|
|
190
|
+
__props.searchable || serverSide.value ? (openBlock(), createElementBlock("div", _hoisted_2, [
|
|
194
191
|
createVNode(unref(ComboboxInput), {
|
|
195
192
|
modelValue: query.value,
|
|
196
193
|
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => query.value = $event),
|
|
@@ -200,7 +197,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
200
197
|
])) : createCommentVNode("", true),
|
|
201
198
|
createVNode(unref(ComboboxViewport), { class: "max-h-56 overflow-y-auto p-1" }, {
|
|
202
199
|
default: withCtx(() => [
|
|
203
|
-
__props.loading ? (openBlock(), createElementBlock("div",
|
|
200
|
+
__props.loading ? (openBlock(), createElementBlock("div", _hoisted_3, toDisplayString(__props.loadingText), 1)) : (openBlock(), createBlock(unref(ComboboxEmpty), {
|
|
204
201
|
key: 1,
|
|
205
202
|
class: "px-3 py-4 text-center text-sm italic text-muted"
|
|
206
203
|
}, {
|
|
@@ -217,13 +214,13 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
217
214
|
class: normalizeClass([unref(OPTION_ITEM), "justify-between"])
|
|
218
215
|
}, {
|
|
219
216
|
default: withCtx(() => [
|
|
220
|
-
createElementVNode("span",
|
|
217
|
+
createElementVNode("span", _hoisted_4, [
|
|
221
218
|
createElementVNode("span", null, toDisplayString(opt.label), 1),
|
|
222
|
-
opt.description ? (openBlock(), createElementBlock("span",
|
|
219
|
+
opt.description ? (openBlock(), createElementBlock("span", _hoisted_5, toDisplayString(opt.description), 1)) : createCommentVNode("", true)
|
|
223
220
|
]),
|
|
224
221
|
createVNode(unref(ComboboxItemIndicator), { class: "flex shrink-0 items-center text-brand" }, {
|
|
225
222
|
default: withCtx(() => [
|
|
226
|
-
createVNode(_sfc_main$
|
|
223
|
+
createVNode(_sfc_main$2, {
|
|
227
224
|
name: "lucide:check",
|
|
228
225
|
size: 16
|
|
229
226
|
})
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { defineComponent, computed, ref, useId, openBlock, createElementBlock, Fragment, createElementVNode, mergeProps, unref, normalizeClass, renderSlot, createCommentVNode, createBlock, createVNode, createSlots, withCtx, normalizeProps, guardReactiveProps } from "vue";
|
|
2
2
|
import { useLabels } from "../composables/useLpConfig.js";
|
|
3
|
-
import { _ as _sfc_main$3 } from "./LpDrawer-
|
|
4
|
-
import { _ as _sfc_main$1 } from "./LpInput-
|
|
5
|
-
import { _ as _sfc_main$2 } from "./LpSidebarNav-
|
|
3
|
+
import { _ as _sfc_main$3 } from "./LpDrawer-Dt4aB4Fr.js";
|
|
4
|
+
import { _ as _sfc_main$1 } from "./LpInput-D-YGQbEv.js";
|
|
5
|
+
import { _ as _sfc_main$2 } from "./LpSidebarNav-kx-LdqNU.js";
|
|
6
6
|
const _hoisted_1 = ["aria-label"];
|
|
7
7
|
const _hoisted_2 = {
|
|
8
8
|
key: 2,
|
|
@@ -3,9 +3,9 @@ import { Motion } from "motion-v";
|
|
|
3
3
|
import { CollapsibleRoot, CollapsibleTrigger, CollapsibleContent } from "reka-ui";
|
|
4
4
|
import { usePillTransition } from "../composables/usePillTransition.js";
|
|
5
5
|
import { _ as _sfc_main$3 } from "./LpBadge-Fe0D1bYx.js";
|
|
6
|
-
import { _ as _sfc_main$4 } from "./LpContextMenu-
|
|
7
|
-
import { _ as _sfc_main$2 } from "./LpIcon-
|
|
8
|
-
import { _ as _sfc_main$1 } from "./LpScrollArea-
|
|
6
|
+
import { _ as _sfc_main$4 } from "./LpContextMenu-BqkAYa9X.js";
|
|
7
|
+
import { _ as _sfc_main$2 } from "./LpIcon-DYtaid0K.js";
|
|
8
|
+
import { _ as _sfc_main$1 } from "./LpScrollArea-Bry1fdOM.js";
|
|
9
9
|
import { resolveLink } from "../components/link.js";
|
|
10
10
|
import { useLinkComponent } from "../composables/useLpConfig.js";
|
|
11
11
|
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent, computed, openBlock, createElementBlock, mergeProps, unref, createElementVNode, createCommentVNode, createBlock, toDisplayString, Fragment, createTextVNode, normalizeClass, createVNode, renderSlot } from "vue";
|
|
2
|
-
import { _ as _sfc_main$1 } from "./LpIcon-
|
|
2
|
+
import { _ as _sfc_main$1 } from "./LpIcon-DYtaid0K.js";
|
|
3
3
|
import { _ as _sfc_main$2 } from "./LpNumberFlow-z4WPZcZu.js";
|
|
4
4
|
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
5
5
|
const _hoisted_1 = { class: "flex items-center gap-2" };
|
|
@@ -1,9 +1,14 @@
|
|
|
1
|
-
import { defineComponent, computed, openBlock, createElementBlock, mergeProps, unref, Fragment, renderList, createElementVNode, normalizeClass, createBlock, createTextVNode, toDisplayString, createCommentVNode } from "vue";
|
|
2
|
-
import { _ as _sfc_main$
|
|
1
|
+
import { defineComponent, computed, openBlock, createElementBlock, mergeProps, unref, Fragment, renderList, createElementVNode, normalizeClass, createVNode, withCtx, createBlock, createTextVNode, toDisplayString, createCommentVNode } from "vue";
|
|
2
|
+
import { _ as _sfc_main$2 } from "./LpIcon-DYtaid0K.js";
|
|
3
|
+
import { _ as _sfc_main$1 } from "./LpRollingText-DB7upf-5.js";
|
|
3
4
|
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
4
5
|
const _hoisted_1 = ["aria-current"];
|
|
5
6
|
const _hoisted_2 = { class: "flex items-center gap-2" };
|
|
6
7
|
const _hoisted_3 = { class: "sr-only" };
|
|
8
|
+
const _hoisted_4 = {
|
|
9
|
+
key: 0,
|
|
10
|
+
class: "relative h-px flex-1 overflow-hidden bg-line"
|
|
11
|
+
};
|
|
7
12
|
const __default__ = { inheritAttrs: false };
|
|
8
13
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
9
14
|
...__default__,
|
|
@@ -39,31 +44,41 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
39
44
|
}, [
|
|
40
45
|
createElementVNode("div", _hoisted_2, [
|
|
41
46
|
createElementVNode("span", {
|
|
42
|
-
class: normalizeClass(["flex size-7 shrink-0 items-center justify-center rounded-pill border text-xs font-semibold transition-colors", isCompleted(step, i) ? "border-transparent bg-brand text-ink-inverse" : isCurrent(i) ? "border-brand text-brand" : "border-line text-muted"])
|
|
47
|
+
class: normalizeClass(["flex size-7 shrink-0 items-center justify-center rounded-pill border text-xs font-semibold transition-colors duration-[var(--duration-medium)]", isCompleted(step, i) ? "border-transparent bg-brand text-ink-inverse" : isCurrent(i) ? "border-brand text-brand" : "border-line text-muted"])
|
|
43
48
|
}, [
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
49
|
+
createVNode(_sfc_main$1, {
|
|
50
|
+
mode: "flip",
|
|
51
|
+
duration: 260,
|
|
52
|
+
value: isCompleted(step, i) ? "done" : step.icon ? "icon" : String(i + 1)
|
|
53
|
+
}, {
|
|
54
|
+
default: withCtx(({ value }) => [
|
|
55
|
+
value === "done" ? (openBlock(), createBlock(_sfc_main$2, {
|
|
56
|
+
key: 0,
|
|
57
|
+
name: "lucide:check",
|
|
58
|
+
size: 14
|
|
59
|
+
})) : value === "icon" && step.icon ? (openBlock(), createBlock(_sfc_main$2, {
|
|
60
|
+
key: 1,
|
|
61
|
+
name: step.icon,
|
|
62
|
+
size: 14
|
|
63
|
+
}, null, 8, ["name"])) : (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
64
|
+
createTextVNode(toDisplayString(value), 1)
|
|
65
|
+
], 64))
|
|
66
|
+
]),
|
|
67
|
+
_: 2
|
|
68
|
+
}, 1032, ["value"])
|
|
55
69
|
], 2),
|
|
56
70
|
createElementVNode("span", {
|
|
57
|
-
class: normalizeClass(["text-sm", isCompleted(step, i) || isCurrent(i) ? "text-ink" : "text-muted"])
|
|
71
|
+
class: normalizeClass(["text-sm transition-colors duration-[var(--duration-medium)]", isCompleted(step, i) || isCurrent(i) ? "text-ink" : "text-muted"])
|
|
58
72
|
}, [
|
|
59
73
|
createTextVNode(toDisplayString(step.label) + " ", 1),
|
|
60
74
|
createElementVNode("span", _hoisted_3, toDisplayString(isCompleted(step, i) ? "(completed)" : isCurrent(i) ? "(current step)" : ""), 1)
|
|
61
75
|
], 2)
|
|
62
76
|
]),
|
|
63
|
-
i < __props.steps.length - 1 ? (openBlock(), createElementBlock("span",
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
77
|
+
i < __props.steps.length - 1 ? (openBlock(), createElementBlock("span", _hoisted_4, [
|
|
78
|
+
createElementVNode("span", {
|
|
79
|
+
class: normalizeClass(["absolute inset-0 origin-left bg-brand transition-transform duration-[var(--duration-medium)] ease-[var(--ease-emphasized)] motion-reduce:transition-none rtl:origin-right", isCompleted(step, i) ? "scale-x-100" : "scale-x-0"])
|
|
80
|
+
}, null, 2)
|
|
81
|
+
])) : createCommentVNode("", true)
|
|
67
82
|
], 8, _hoisted_1);
|
|
68
83
|
}), 128))
|
|
69
84
|
], 16);
|
|
@@ -28,7 +28,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
28
28
|
const slots = useSlots();
|
|
29
29
|
const labelled = computed(() => Boolean(props.label || props.description || slots.default));
|
|
30
30
|
const TRACK = "group inline-flex h-5 w-9 shrink-0 items-center rounded-pill border border-line bg-surface-soft px-0.5 outline-none transition-colors duration-[var(--duration-fast)] focus-visible:ring-2 focus-visible:ring-ring data-[state=checked]:border-transparent data-[state=checked]:bg-brand disabled:cursor-not-allowed disabled:opacity-55";
|
|
31
|
-
const THUMB = "h-3.5 w-3.5 rounded-full bg-ink shadow transition-[translate,width,background-color] duration-[var(--duration-fast)] ease-[var(--ease-emphasized)] group-active:w-5 group-data-[state=checked]:translate-x-4 group-data-[state=checked]:bg-ink-inverse group-data-[state=checked]:group-active
|
|
31
|
+
const THUMB = "h-3.5 w-3.5 rounded-full bg-ink shadow transition-[translate,width,background-color] duration-[var(--duration-fast)] ease-[var(--ease-emphasized)] group-active:w-5 group-data-[state=checked]:translate-x-4 group-data-[state=checked]:bg-ink-inverse group-data-[state=checked]:group-active:translate-x-2.5 motion-reduce:group-active:w-3.5";
|
|
32
32
|
const { class: rootClass, attrs: rest } = useMergedAttrs(() => {
|
|
33
33
|
if (!labelled.value) return TRACK;
|
|
34
34
|
return props.labelPosition === "start" ? "flex w-full cursor-pointer items-center justify-between gap-3 text-sm text-ink" : "inline-flex cursor-pointer items-center gap-2 text-sm text-ink";
|
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
import { defineComponent, ref, computed, openBlock, createElementBlock, createBlock, createCommentVNode, createElementVNode, Fragment, unref, normalizeClass, toDisplayString, createVNode, withCtx, renderList } from "vue";
|
|
2
|
+
import { _ as _sfc_main$3 } from "./LpCheckbox-Bkj13CbW.js";
|
|
3
|
+
import { _ as _sfc_main$1 } from "./LpInput-D-YGQbEv.js";
|
|
4
|
+
import { _ as _sfc_main$2 } from "./LpShift-DXNsauQZ.js";
|
|
5
|
+
import { usePaintSelect } from "../composables/usePaintSelect.js";
|
|
6
|
+
import { matchesQuery, onlyValues, unhideValues, hideAllValues, invertHidden } from "../components/tableFilter.js";
|
|
7
|
+
const _hoisted_1 = { class: "flex flex-col gap-2" };
|
|
8
|
+
const _hoisted_2 = { class: "flex flex-wrap items-center gap-1" };
|
|
9
|
+
const _hoisted_3 = ["disabled"];
|
|
10
|
+
const _hoisted_4 = ["disabled"];
|
|
11
|
+
const _hoisted_5 = ["disabled"];
|
|
12
|
+
const _hoisted_6 = ["disabled"];
|
|
13
|
+
const _hoisted_7 = ["data-paint-key"];
|
|
14
|
+
const _hoisted_8 = { class: "truncate" };
|
|
15
|
+
const _hoisted_9 = {
|
|
16
|
+
key: 0,
|
|
17
|
+
class: "text-xs text-muted tabular-nums"
|
|
18
|
+
};
|
|
19
|
+
const _hoisted_10 = ["onClick"];
|
|
20
|
+
const _hoisted_11 = {
|
|
21
|
+
key: 0,
|
|
22
|
+
class: "px-1.5 py-2 text-xs text-muted"
|
|
23
|
+
};
|
|
24
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
25
|
+
__name: "LpTableFilter",
|
|
26
|
+
props: {
|
|
27
|
+
options: {},
|
|
28
|
+
hidden: {},
|
|
29
|
+
labels: {}
|
|
30
|
+
},
|
|
31
|
+
emits: ["update:hidden"],
|
|
32
|
+
setup(__props, { emit: __emit }) {
|
|
33
|
+
const props = __props;
|
|
34
|
+
const emit = __emit;
|
|
35
|
+
const SEARCH_FROM = 8;
|
|
36
|
+
const query = ref("");
|
|
37
|
+
const values = computed(() => props.options.map((o) => o.value));
|
|
38
|
+
const shown = computed(() => props.options.filter((o) => matchesQuery(o.label, query.value)));
|
|
39
|
+
function set(next) {
|
|
40
|
+
emit("update:hidden", next);
|
|
41
|
+
}
|
|
42
|
+
function toggle(value) {
|
|
43
|
+
const next = new Set(props.hidden);
|
|
44
|
+
if (next.has(value)) next.delete(value);
|
|
45
|
+
else next.add(value);
|
|
46
|
+
set(next);
|
|
47
|
+
}
|
|
48
|
+
const list = ref(null);
|
|
49
|
+
const byKey = computed(() => new Map(props.options.map((o) => [String(o.value), o.value])));
|
|
50
|
+
const paint = usePaintSelect({
|
|
51
|
+
root: list,
|
|
52
|
+
selection: () => values.value.filter((v) => !props.hidden.has(v)),
|
|
53
|
+
set: (shownValues) => {
|
|
54
|
+
const keep = new Set(shownValues);
|
|
55
|
+
set(new Set(values.value.filter((v) => !keep.has(v))));
|
|
56
|
+
},
|
|
57
|
+
resolve: (raw) => byKey.value.has(raw) ? byKey.value.get(raw) : void 0
|
|
58
|
+
});
|
|
59
|
+
function onListKeydown(event) {
|
|
60
|
+
if (event.key !== "ArrowDown" && event.key !== "ArrowUp") return;
|
|
61
|
+
const boxes = [...list.value?.querySelectorAll("[role=checkbox]") ?? []];
|
|
62
|
+
const at = boxes.indexOf(document.activeElement);
|
|
63
|
+
const next = boxes[at + (event.key === "ArrowDown" ? 1 : -1)];
|
|
64
|
+
if (!next) return;
|
|
65
|
+
event.preventDefault();
|
|
66
|
+
next.focus();
|
|
67
|
+
}
|
|
68
|
+
const action = "rounded-control px-1.5 py-0.5 text-xs font-medium text-muted outline-none transition-colors duration-fast hover:bg-surface-soft hover:text-ink focus-visible:ring-2 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-40";
|
|
69
|
+
return (_ctx, _cache) => {
|
|
70
|
+
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
71
|
+
__props.options.length >= SEARCH_FROM ? (openBlock(), createBlock(_sfc_main$1, {
|
|
72
|
+
key: 0,
|
|
73
|
+
modelValue: query.value,
|
|
74
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => query.value = $event),
|
|
75
|
+
size: "sm",
|
|
76
|
+
icon: "lucide:search",
|
|
77
|
+
placeholder: __props.labels.search,
|
|
78
|
+
"aria-label": __props.labels.search
|
|
79
|
+
}, null, 8, ["modelValue", "placeholder", "aria-label"])) : createCommentVNode("", true),
|
|
80
|
+
createElementVNode("div", _hoisted_2, [
|
|
81
|
+
query.value ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
82
|
+
createElementVNode("button", {
|
|
83
|
+
type: "button",
|
|
84
|
+
class: normalizeClass(action),
|
|
85
|
+
disabled: !shown.value.length,
|
|
86
|
+
onClick: _cache[1] || (_cache[1] = ($event) => set(unref(onlyValues)(values.value, shown.value.map((o) => o.value))))
|
|
87
|
+
}, toDisplayString(__props.labels.onlyShown.replace("{count}", String(shown.value.length))), 9, _hoisted_3),
|
|
88
|
+
createElementVNode("button", {
|
|
89
|
+
type: "button",
|
|
90
|
+
class: normalizeClass(action),
|
|
91
|
+
disabled: !shown.value.length,
|
|
92
|
+
onClick: _cache[2] || (_cache[2] = ($event) => set(unref(unhideValues)(__props.hidden, shown.value.map((o) => o.value))))
|
|
93
|
+
}, toDisplayString(__props.labels.addShown.replace("{count}", String(shown.value.length))), 9, _hoisted_4)
|
|
94
|
+
], 64)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
95
|
+
createElementVNode("button", {
|
|
96
|
+
type: "button",
|
|
97
|
+
class: normalizeClass(action),
|
|
98
|
+
disabled: !__props.hidden.size,
|
|
99
|
+
onClick: _cache[3] || (_cache[3] = ($event) => set(/* @__PURE__ */ new Set()))
|
|
100
|
+
}, toDisplayString(__props.labels.all), 9, _hoisted_5),
|
|
101
|
+
createElementVNode("button", {
|
|
102
|
+
type: "button",
|
|
103
|
+
class: normalizeClass(action),
|
|
104
|
+
disabled: __props.hidden.size === __props.options.length,
|
|
105
|
+
onClick: _cache[4] || (_cache[4] = ($event) => set(unref(hideAllValues)(values.value)))
|
|
106
|
+
}, toDisplayString(__props.labels.none), 9, _hoisted_6),
|
|
107
|
+
createElementVNode("button", {
|
|
108
|
+
type: "button",
|
|
109
|
+
class: normalizeClass(action),
|
|
110
|
+
onClick: _cache[5] || (_cache[5] = ($event) => set(unref(invertHidden)(values.value, __props.hidden)))
|
|
111
|
+
}, toDisplayString(__props.labels.invert), 1)
|
|
112
|
+
], 64))
|
|
113
|
+
]),
|
|
114
|
+
createVNode(_sfc_main$2, null, {
|
|
115
|
+
default: withCtx(() => [
|
|
116
|
+
createElementVNode("div", {
|
|
117
|
+
ref_key: "list",
|
|
118
|
+
ref: list,
|
|
119
|
+
class: "-mx-1 flex max-h-64 flex-col overflow-y-auto overscroll-contain",
|
|
120
|
+
onKeydown: onListKeydown
|
|
121
|
+
}, [
|
|
122
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(shown.value, (option) => {
|
|
123
|
+
return openBlock(), createElementBlock("div", {
|
|
124
|
+
key: String(option.value),
|
|
125
|
+
class: "group/opt flex items-center gap-2 rounded-control px-1.5 py-1 transition-colors duration-fast select-none hover:bg-surface-soft",
|
|
126
|
+
"data-paint-key": String(option.value)
|
|
127
|
+
}, [
|
|
128
|
+
createVNode(_sfc_main$3, {
|
|
129
|
+
"model-value": !__props.hidden.has(option.value),
|
|
130
|
+
class: "min-w-0 flex-1",
|
|
131
|
+
onPointerdown: ($event) => unref(paint).onPointerDown($event, option.value),
|
|
132
|
+
"onUpdate:modelValue": ($event) => toggle(option.value)
|
|
133
|
+
}, {
|
|
134
|
+
default: withCtx(() => [
|
|
135
|
+
createElementVNode("span", _hoisted_8, toDisplayString(option.label), 1)
|
|
136
|
+
]),
|
|
137
|
+
_: 2
|
|
138
|
+
}, 1032, ["model-value", "onPointerdown", "onUpdate:modelValue"]),
|
|
139
|
+
option.count !== void 0 ? (openBlock(), createElementBlock("span", _hoisted_9, toDisplayString(option.count), 1)) : createCommentVNode("", true),
|
|
140
|
+
createElementVNode("button", {
|
|
141
|
+
type: "button",
|
|
142
|
+
class: "rounded-control px-1.5 py-0.5 text-xs font-medium text-brand opacity-0 outline-none transition-opacity duration-fast group-hover/opt:opacity-100 hover:bg-brand-soft focus-visible:opacity-100 focus-visible:ring-2 focus-visible:ring-ring",
|
|
143
|
+
onClick: ($event) => set(unref(onlyValues)(values.value, [option.value]))
|
|
144
|
+
}, toDisplayString(__props.labels.only), 9, _hoisted_10)
|
|
145
|
+
], 8, _hoisted_7);
|
|
146
|
+
}), 128)),
|
|
147
|
+
!shown.value.length ? (openBlock(), createElementBlock("p", _hoisted_11, toDisplayString(__props.labels.noValues), 1)) : createCommentVNode("", true)
|
|
148
|
+
], 544)
|
|
149
|
+
]),
|
|
150
|
+
_: 1
|
|
151
|
+
})
|
|
152
|
+
]);
|
|
153
|
+
};
|
|
154
|
+
}
|
|
155
|
+
});
|
|
156
|
+
export {
|
|
157
|
+
_sfc_main as _
|
|
158
|
+
};
|
|
@@ -2,7 +2,7 @@ import { defineComponent, ref, watch, useId, computed, openBlock, createBlock, u
|
|
|
2
2
|
import { useReducedMotion, Motion } from "motion-v";
|
|
3
3
|
import { TabsRoot, TabsList, TabsTrigger, TabsContent } from "reka-ui";
|
|
4
4
|
import { usePillTransition } from "../composables/usePillTransition.js";
|
|
5
|
-
import { _ as _sfc_main$1 } from "./LpIcon-
|
|
5
|
+
import { _ as _sfc_main$1 } from "./LpIcon-DYtaid0K.js";
|
|
6
6
|
const _hoisted_1 = { class: "relative z-10" };
|
|
7
7
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
8
8
|
__name: "LpTabs",
|