@leavepulse/ui 0.31.1 → 0.32.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/dist/assets/{LpDropzone-DVDC-ABU.css → LpDropzone-BBoWvi-J.css} +12 -12
- package/dist/assets/{LpImageEditor-DqP5JKCy.css → LpImageEditor-BsSwej47.css} +6 -6
- package/dist/chunks/{LpAddressInput-BDkp3-Bp.js → LpAddressInput-C35TsJXt.js} +19 -14
- package/dist/chunks/{LpAppShell-Chz8Vbtu.js → LpAppShell-lVvpENMH.js} +18 -13
- package/dist/chunks/{LpBreadcrumbs-5uvViCXi.js → LpBreadcrumbs-p4jHe_V-.js} +9 -7
- package/dist/chunks/{LpCalendar-B7ZL0ty3.js → LpCalendar-B7Ko5RdR.js} +12 -7
- package/dist/chunks/{LpCard-D0M2ZCnB.js → LpCard-1SeUYPBT.js} +36 -9
- package/dist/chunks/{LpCheckbox-BO0zuuPh.js → LpCheckbox-CVccKYaH.js} +9 -4
- package/dist/chunks/{LpCodeBlock-BWX1KZwk.js → LpCodeBlock-Bo0B4TFR.js} +37 -32
- package/dist/chunks/{LpDatePicker-dY2q4dr4.js → LpDatePicker-6JFXllj5.js} +1 -1
- package/dist/chunks/{LpDisclosure-B4kVAWfg.js → LpDisclosure-y7wDBgLa.js} +11 -6
- package/dist/chunks/{LpEmptyState-BV3q7Qyi.js → LpEmptyState-Dsdqz1Wj.js} +13 -5
- package/dist/chunks/{LpFileTree-DfFqY__1.js → LpFileTree-C-NFRT0H.js} +19 -14
- package/dist/chunks/{LpFileTreeNode-COchUMNn.js → LpFileTreeNode-DNJUJiiB.js} +13 -6
- package/dist/chunks/{LpFormField-fV_2ZdCk.js → LpFormField-CazBc2-a.js} +14 -9
- package/dist/chunks/{LpInput-Bt4J71xn.js → LpInput-9EXWUM9B.js} +1 -1
- package/dist/chunks/{LpLightbox-Ci35Y_xP.js → LpLightbox-Cixfxezw.js} +29 -6
- package/dist/chunks/{LpLink-BHZ1CLlF.js → LpLink-DCND-zyu.js} +16 -9
- package/dist/chunks/{LpLogViewer-TSRyt3t9.js → LpLogViewer-y53ZqSVq.js} +20 -10
- package/dist/chunks/{LpMapPicker-CXvoTrAe.js → LpMapPicker-ul4oYno6.js} +14 -9
- package/dist/chunks/LpMediaGallery-t1z3bQcY.js +187 -0
- package/dist/chunks/{LpNotificationBell-gdvQY89m.js → LpNotificationBell-lHePf89W.js} +1 -1
- package/dist/chunks/{LpNumberField-NPE8Bumx.js → LpNumberField-CWuX08iX.js} +12 -5
- package/dist/chunks/{LpOtpInput-DqaT0Z75.js → LpOtpInput-y2v-pmiN.js} +11 -6
- package/dist/chunks/{LpPagination-CeGuNe_q.js → LpPagination-5FxjmmB5.js} +21 -19
- package/dist/chunks/{LpPasswordInput-BqMAc5HA.js → LpPasswordInput--sjYCkLS.js} +1 -1
- package/dist/chunks/{LpPhoneInput-NXXjciJJ.js → LpPhoneInput-BDSKVl_z.js} +16 -9
- package/dist/chunks/{LpPie-BL1vTDSM.js → LpPie-c2-q4DJu.js} +14 -8
- package/dist/chunks/{LpRadio-CL-pI0_O.js → LpRadio-B5AfqTpZ.js} +13 -5
- package/dist/chunks/{LpRadioGroup-B4yDTmi6.js → LpRadioGroup-xPIuVDO_.js} +12 -5
- package/dist/chunks/{LpSegmented-BmpanyAo.js → LpSegmented-fV0Sk92p.js} +16 -6
- package/dist/chunks/{LpSidebar-BiWM_lDB.js → LpSidebar-DcYavim2.js} +2 -2
- package/dist/chunks/{LpSidebarNav-CsgeuGAu.js → LpSidebarNav-CqwvT4H8.js} +21 -16
- package/dist/chunks/{LpSlider-B1SF3pRV.js → LpSlider-BwNIBkAK.js} +12 -5
- package/dist/chunks/{LpStat-CDanpzU0.js → LpStat-CQaW8R--.js} +23 -18
- package/dist/chunks/{LpStepper-Wtl-6nUh.js → LpStepper-Bk-XaQYU.js} +15 -10
- package/dist/chunks/{LpSwitch-v6fnccSM.js → LpSwitch-xgnRU2k0.js} +12 -5
- package/dist/chunks/{LpTextarea-BMIOfw5l.js → LpTextarea-t7F6gv8E.js} +1 -1
- package/dist/chunks/{LpUptimeBar-DcQ8HikG.js → LpUptimeBar-DvAMno0S.js} +26 -21
- package/dist/component-names.d.ts +1 -1
- package/dist/components/LpAddressInput.vue.d.ts +34 -17
- package/dist/components/LpAddressInput.vue.js +1 -1
- package/dist/components/LpAppShell.vue.d.ts +65 -31
- package/dist/components/LpAppShell.vue.js +1 -1
- package/dist/components/LpBreadcrumbs.vue.d.ts +12 -6
- package/dist/components/LpBreadcrumbs.vue.js +1 -1
- package/dist/components/LpCalendar.vue.d.ts +15 -6
- package/dist/components/LpCalendar.vue.js +1 -1
- package/dist/components/LpCard.vue.d.ts +26 -0
- package/dist/components/LpCard.vue.js +1 -1
- package/dist/components/LpChart.vue.d.ts +54 -12
- package/dist/components/LpChart.vue.js +15 -9
- package/dist/components/LpCheckbox.vue.d.ts +16 -12
- package/dist/components/LpCheckbox.vue.js +1 -1
- package/dist/components/LpCodeBlock.vue.d.ts +25 -6
- package/dist/components/LpCodeBlock.vue.js +1 -1
- package/dist/components/LpDatePicker.vue.js +1 -1
- package/dist/components/LpDisclosure.vue.d.ts +24 -14
- package/dist/components/LpDisclosure.vue.js +1 -1
- package/dist/components/LpDropzone.vue.d.ts +38 -14
- package/dist/components/LpDropzone.vue.js +17 -11
- package/dist/components/LpEmptyState.vue.d.ts +15 -10
- package/dist/components/LpEmptyState.vue.js +1 -1
- package/dist/components/LpFileTree.vue.d.ts +51 -31
- package/dist/components/LpFileTree.vue.js +1 -1
- package/dist/components/LpFileTreeNode.vue.d.ts +31 -16
- package/dist/components/LpFileTreeNode.vue.js +1 -1
- package/dist/components/LpFormField.vue.d.ts +14 -13
- package/dist/components/LpFormField.vue.js +1 -1
- package/dist/components/LpImageEditor.vue.d.ts +33 -10
- package/dist/components/LpImageEditor.vue.js +13 -7
- package/dist/components/LpInput.vue.js +1 -1
- package/dist/components/LpLightbox.vue.js +1 -1
- package/dist/components/LpLink.vue.d.ts +46 -11
- package/dist/components/LpLink.vue.js +1 -1
- package/dist/components/LpLogViewer.vue.d.ts +63 -6
- package/dist/components/LpLogViewer.vue.js +1 -1
- package/dist/components/LpMapPicker.vue.d.ts +25 -10
- package/dist/components/LpMapPicker.vue.js +1 -1
- package/dist/components/LpMediaGallery.vue.d.ts +76 -0
- package/dist/components/LpMediaGallery.vue.js +4 -0
- package/dist/components/LpNotificationBell.vue.js +1 -1
- package/dist/components/LpNumberField.vue.d.ts +12 -6
- package/dist/components/LpNumberField.vue.js +1 -1
- package/dist/components/LpOtpInput.vue.d.ts +18 -6
- package/dist/components/LpOtpInput.vue.js +1 -1
- package/dist/components/LpPagination.vue.d.ts +16 -6
- package/dist/components/LpPagination.vue.js +1 -1
- package/dist/components/LpPasswordInput.vue.js +1 -1
- package/dist/components/LpPhoneInput.vue.d.ts +18 -6
- package/dist/components/LpPhoneInput.vue.js +1 -1
- package/dist/components/LpPie.vue.d.ts +96 -34
- package/dist/components/LpPie.vue.js +1 -1
- package/dist/components/LpRadio.vue.d.ts +10 -10
- package/dist/components/LpRadio.vue.js +1 -1
- package/dist/components/LpRadioGroup.vue.d.ts +12 -12
- package/dist/components/LpRadioGroup.vue.js +1 -1
- package/dist/components/LpSegmented.vue.d.ts +12 -6
- package/dist/components/LpSegmented.vue.js +1 -1
- package/dist/components/LpSidebar.vue.js +1 -1
- package/dist/components/LpSidebarNav.vue.d.ts +28 -17
- package/dist/components/LpSidebarNav.vue.js +1 -1
- package/dist/components/LpSlider.vue.d.ts +13 -6
- package/dist/components/LpSlider.vue.js +1 -1
- package/dist/components/LpStat.vue.d.ts +35 -11
- package/dist/components/LpStat.vue.js +1 -1
- package/dist/components/LpStepper.vue.d.ts +17 -5
- package/dist/components/LpStepper.vue.js +1 -1
- package/dist/components/LpSwitch.vue.d.ts +8 -6
- package/dist/components/LpSwitch.vue.js +1 -1
- package/dist/components/LpTable.vue.js +1 -1
- package/dist/components/LpTextarea.vue.js +1 -1
- package/dist/components/LpUptimeBar.vue.d.ts +21 -5
- package/dist/components/LpUptimeBar.vue.js +1 -1
- package/dist/composables/useMergedClass.d.ts +20 -0
- package/dist/composables/useMergedClass.js +11 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +95 -89
- package/package.json +1 -3
- package/src/component-names.ts +1 -0
- package/src/components/LpAddressInput.vue +16 -1
- package/src/components/LpAppShell.vue +16 -1
- package/src/components/LpBreadcrumbs.vue +16 -1
- package/src/components/LpCalendar.vue +15 -1
- package/src/components/LpCard.vue +50 -5
- package/src/components/LpChart.vue +16 -1
- package/src/components/LpCheckbox.vue +16 -1
- package/src/components/LpCodeBlock.vue +16 -1
- package/src/components/LpDisclosure.vue +15 -1
- package/src/components/LpDropzone.vue +21 -6
- package/src/components/LpEmptyState.vue +21 -3
- package/src/components/LpFileTree.vue +16 -1
- package/src/components/LpFileTreeNode.vue +15 -1
- package/src/components/LpFormField.vue +16 -1
- package/src/components/LpImageEditor.vue +16 -1
- package/src/components/LpLightbox.vue +54 -2
- package/src/components/LpLink.vue +25 -9
- package/src/components/LpLogViewer.vue +20 -2
- package/src/components/LpMapPicker.vue +15 -1
- package/src/components/LpMediaGallery.vue +280 -0
- package/src/components/LpNumberField.vue +15 -1
- package/src/components/LpOtpInput.vue +15 -1
- package/src/components/LpPagination.vue +16 -1
- package/src/components/LpPhoneInput.vue +23 -8
- package/src/components/LpPie.vue +16 -1
- package/src/components/LpRadio.vue +20 -3
- package/src/components/LpRadioGroup.vue +15 -1
- package/src/components/LpSegmented.vue +21 -2
- package/src/components/LpSidebarNav.vue +16 -1
- package/src/components/LpSlider.vue +15 -1
- package/src/components/LpStat.vue +16 -1
- package/src/components/LpStepper.vue +16 -1
- package/src/components/LpSwitch.vue +15 -1
- package/src/components/LpUptimeBar.vue +16 -1
- package/src/composables/useMergedClass.ts +30 -0
- package/src/index.ts +2 -0
- package/src/tokens/tokens.css +29 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
|
|
2
|
-
.lp-dropzone__frame rect[data-v-
|
|
2
|
+
.lp-dropzone__frame rect[data-v-5e560a6d] {
|
|
3
3
|
stroke: var(--color-line);
|
|
4
4
|
transition: stroke var(--duration-fast) linear;
|
|
5
5
|
}
|
|
6
|
-
.lp-dropzone:hover .lp-dropzone__frame rect[data-v-
|
|
6
|
+
.lp-dropzone:hover .lp-dropzone__frame rect[data-v-5e560a6d] {
|
|
7
7
|
stroke: var(--color-line-strong);
|
|
8
8
|
}
|
|
9
9
|
|
|
@@ -12,33 +12,33 @@
|
|
|
12
12
|
with every other thing on it; under a drag it is the answer to "can I let go
|
|
13
13
|
here". One dash period per cycle, so the travel is continuous rather than
|
|
14
14
|
jumping back at the seam. */
|
|
15
|
-
.lp-dropzone--over .lp-dropzone__frame rect[data-v-
|
|
15
|
+
.lp-dropzone--over .lp-dropzone__frame rect[data-v-5e560a6d] {
|
|
16
16
|
stroke: var(--color-brand);
|
|
17
|
-
animation: lp-dropzone-ants-
|
|
17
|
+
animation: lp-dropzone-ants-5e560a6d 500ms linear infinite;
|
|
18
18
|
}
|
|
19
|
-
@keyframes lp-dropzone-ants-
|
|
19
|
+
@keyframes lp-dropzone-ants-5e560a6d {
|
|
20
20
|
to {
|
|
21
21
|
stroke-dashoffset: -11;
|
|
22
22
|
}
|
|
23
23
|
}
|
|
24
24
|
|
|
25
25
|
/* The dashes fade in and the block settles up a few pixels. */
|
|
26
|
-
.lp-dropzone[data-v-
|
|
27
|
-
animation: lp-dropzone-in-
|
|
26
|
+
.lp-dropzone[data-v-5e560a6d] {
|
|
27
|
+
animation: lp-dropzone-in-5e560a6d var(--duration-slow) var(--ease-settle) both;
|
|
28
28
|
}
|
|
29
|
-
.lp-dropzone--waiting[data-v-
|
|
29
|
+
.lp-dropzone--waiting[data-v-5e560a6d] {
|
|
30
30
|
opacity: 0;
|
|
31
31
|
animation: none;
|
|
32
32
|
}
|
|
33
|
-
@keyframes lp-dropzone-in-
|
|
33
|
+
@keyframes lp-dropzone-in-5e560a6d {
|
|
34
34
|
from {
|
|
35
35
|
opacity: 0;
|
|
36
36
|
transform: translateY(6px);
|
|
37
37
|
}
|
|
38
38
|
}
|
|
39
39
|
@media (prefers-reduced-motion: reduce) {
|
|
40
|
-
.lp-dropzone[data-v-
|
|
41
|
-
.lp-dropzone--waiting[data-v-
|
|
40
|
+
.lp-dropzone[data-v-5e560a6d],
|
|
41
|
+
.lp-dropzone--waiting[data-v-5e560a6d] {
|
|
42
42
|
opacity: 1;
|
|
43
43
|
transform: none;
|
|
44
44
|
animation: none;
|
|
@@ -46,7 +46,7 @@ from {
|
|
|
46
46
|
|
|
47
47
|
/* The ants stop, the colour stays: the brand stroke is what says "drop
|
|
48
48
|
here", and it says it standing still. */
|
|
49
|
-
.lp-dropzone--over .lp-dropzone__frame rect[data-v-
|
|
49
|
+
.lp-dropzone--over .lp-dropzone__frame rect[data-v-5e560a6d] {
|
|
50
50
|
animation: none;
|
|
51
51
|
}
|
|
52
52
|
}
|
|
@@ -2,22 +2,22 @@
|
|
|
2
2
|
/* The picture settles into the frame instead of appearing in it. Scale rather
|
|
3
3
|
than a slide: the frame is the fixed thing here and the image lives inside
|
|
4
4
|
it, so anything that moved would read as a crop that had shifted. */
|
|
5
|
-
.lp-editor__image[data-v-
|
|
6
|
-
animation: lp-editor-in-
|
|
5
|
+
.lp-editor__image[data-v-3587f639] {
|
|
6
|
+
animation: lp-editor-in-3587f639 var(--duration-slow) var(--ease-settle) both;
|
|
7
7
|
}
|
|
8
|
-
.lp-editor__image--waiting[data-v-
|
|
8
|
+
.lp-editor__image--waiting[data-v-3587f639] {
|
|
9
9
|
opacity: 0;
|
|
10
10
|
animation: none;
|
|
11
11
|
}
|
|
12
|
-
@keyframes lp-editor-in-
|
|
12
|
+
@keyframes lp-editor-in-3587f639 {
|
|
13
13
|
from {
|
|
14
14
|
opacity: 0;
|
|
15
15
|
scale: 1.04;
|
|
16
16
|
}
|
|
17
17
|
}
|
|
18
18
|
@media (prefers-reduced-motion: reduce) {
|
|
19
|
-
.lp-editor__image[data-v-
|
|
20
|
-
.lp-editor__image--waiting[data-v-
|
|
19
|
+
.lp-editor__image[data-v-3587f639],
|
|
20
|
+
.lp-editor__image--waiting[data-v-3587f639] {
|
|
21
21
|
opacity: 1;
|
|
22
22
|
scale: 1;
|
|
23
23
|
animation: none;
|
|
@@ -1,25 +1,27 @@
|
|
|
1
|
-
import { defineComponent, defineAsyncComponent, computed, ref, onMounted, watch, openBlock, createElementBlock, createVNode, withCtx, createElementVNode,
|
|
1
|
+
import { defineComponent, defineAsyncComponent, computed, ref, onMounted, watch, openBlock, createElementBlock, mergeProps, unref, createVNode, withCtx, createElementVNode, createBlock, createCommentVNode, createTextVNode, toDisplayString, renderSlot, normalizeClass } from "vue";
|
|
2
2
|
import { OSM_TILES, createNominatimProvider, emptyAddress, formatAddress } from "../components/address.js";
|
|
3
3
|
import { flagEmoji, loadCountries } from "../components/countries.js";
|
|
4
4
|
import { _ as _sfc_main$2 } from "./LpAutocomplete-DExlIZe_.js";
|
|
5
5
|
import { _ as _sfc_main$3 } from "./LpButton-5VXXCjwF.js";
|
|
6
|
-
import { _ as _sfc_main$1 } from "./LpFormField-
|
|
6
|
+
import { _ as _sfc_main$1 } from "./LpFormField-CazBc2-a.js";
|
|
7
7
|
import { _ as _sfc_main$4 } from "./LpIcon-CCnX5_2j.js";
|
|
8
|
-
import { _ as _sfc_main$5 } from "./LpInput-
|
|
8
|
+
import { _ as _sfc_main$5 } from "./LpInput-9EXWUM9B.js";
|
|
9
9
|
import { _ as _sfc_main$7 } from "./LpModal-D_o-56To.js";
|
|
10
10
|
import { _ as _sfc_main$6 } from "./LpSelect-ANIVtrpM.js";
|
|
11
|
-
|
|
12
|
-
const
|
|
13
|
-
const
|
|
14
|
-
const
|
|
11
|
+
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
12
|
+
const _hoisted_1 = { class: "flex items-stretch gap-2" };
|
|
13
|
+
const _hoisted_2 = { class: "grid gap-3 sm:grid-cols-[minmax(0,1fr)_10rem]" };
|
|
14
|
+
const _hoisted_3 = {
|
|
15
15
|
key: 1,
|
|
16
16
|
class: "flex items-center gap-2"
|
|
17
17
|
};
|
|
18
|
-
const
|
|
18
|
+
const _hoisted_4 = {
|
|
19
19
|
key: 0,
|
|
20
20
|
class: "text-xs text-muted"
|
|
21
21
|
};
|
|
22
|
+
const __default__ = { inheritAttrs: false };
|
|
22
23
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
24
|
+
...__default__,
|
|
23
25
|
__name: "LpAddressInput",
|
|
24
26
|
props: {
|
|
25
27
|
modelValue: {},
|
|
@@ -185,13 +187,16 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
185
187
|
emit("pick", point.value);
|
|
186
188
|
mapOpen.value = false;
|
|
187
189
|
}
|
|
190
|
+
const { class: rootClass, attrs: rest } = useMergedAttrs(
|
|
191
|
+
"flex flex-col gap-3"
|
|
192
|
+
);
|
|
188
193
|
return (_ctx, _cache) => {
|
|
189
|
-
return openBlock(), createElementBlock("div",
|
|
194
|
+
return openBlock(), createElementBlock("div", mergeProps({ class: unref(rootClass) }, unref(rest)), [
|
|
190
195
|
createVNode(_sfc_main$1, {
|
|
191
196
|
label: text.value.line
|
|
192
197
|
}, {
|
|
193
198
|
default: withCtx(() => [
|
|
194
|
-
createElementVNode("div",
|
|
199
|
+
createElementVNode("div", _hoisted_1, [
|
|
195
200
|
createVNode(_sfc_main$2, {
|
|
196
201
|
class: "min-w-0 flex-1",
|
|
197
202
|
"model-value": value.value.line,
|
|
@@ -243,7 +248,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
243
248
|
autocomplete: "address-line2",
|
|
244
249
|
"onUpdate:modelValue": _cache[2] || (_cache[2] = (next) => patch({ line2: next }))
|
|
245
250
|
}, null, 8, ["model-value", "label", "placeholder", "disabled", "size"])) : createCommentVNode("", true),
|
|
246
|
-
createElementVNode("div",
|
|
251
|
+
createElementVNode("div", _hoisted_2, [
|
|
247
252
|
createVNode(_sfc_main$1, {
|
|
248
253
|
label: text.value.city
|
|
249
254
|
}, {
|
|
@@ -295,7 +300,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
295
300
|
]),
|
|
296
301
|
_: 1
|
|
297
302
|
}, 8, ["label"]),
|
|
298
|
-
!__props.hideMap ? (openBlock(), createElementBlock("div",
|
|
303
|
+
!__props.hideMap ? (openBlock(), createElementBlock("div", _hoisted_3, [
|
|
299
304
|
createVNode(_sfc_main$3, {
|
|
300
305
|
variant: "soft",
|
|
301
306
|
size: __props.size === "lg" ? "md" : "sm",
|
|
@@ -311,7 +316,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
311
316
|
]),
|
|
312
317
|
_: 1
|
|
313
318
|
}, 8, ["size", "disabled"]),
|
|
314
|
-
value.value.lat != null && value.value.lon != null ? (openBlock(), createElementBlock("span",
|
|
319
|
+
value.value.lat != null && value.value.lon != null ? (openBlock(), createElementBlock("span", _hoisted_4, toDisplayString(value.value.lat.toFixed(5)) + ", " + toDisplayString(value.value.lon.toFixed(5)), 1)) : createCommentVNode("", true)
|
|
315
320
|
])) : createCommentVNode("", true),
|
|
316
321
|
createVNode(_sfc_main$7, {
|
|
317
322
|
open: mapOpen.value,
|
|
@@ -357,7 +362,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
357
362
|
]),
|
|
358
363
|
_: 3
|
|
359
364
|
}, 8, ["open", "title"])
|
|
360
|
-
]);
|
|
365
|
+
], 16);
|
|
361
366
|
};
|
|
362
367
|
}
|
|
363
368
|
});
|
|
@@ -1,18 +1,20 @@
|
|
|
1
|
-
import { defineComponent, computed, watch, openBlock, createElementBlock, createVNode, createSlots, withCtx, renderSlot, normalizeProps, guardReactiveProps, createElementVNode, normalizeClass, toDisplayString, createBlock } from "vue";
|
|
1
|
+
import { defineComponent, computed, watch, openBlock, createElementBlock, mergeProps, unref, createVNode, createSlots, withCtx, renderSlot, normalizeProps, guardReactiveProps, createElementVNode, normalizeClass, toDisplayString, createBlock } from "vue";
|
|
2
2
|
import { _ as _sfc_main$2 } from "./LpButton-5VXXCjwF.js";
|
|
3
3
|
import { _ as _sfc_main$3 } from "./LpIcon-CCnX5_2j.js";
|
|
4
4
|
import { _ as _sfc_main$5 } from "./LpScrollArea-D8xyKXcF.js";
|
|
5
5
|
import { _ as _sfc_main$4 } from "./LpShift-DXNsauQZ.js";
|
|
6
|
-
import { _ as _sfc_main$1 } from "./LpSidebar-
|
|
7
|
-
|
|
8
|
-
const
|
|
9
|
-
const
|
|
10
|
-
const
|
|
11
|
-
const
|
|
6
|
+
import { _ as _sfc_main$1 } from "./LpSidebar-DcYavim2.js";
|
|
7
|
+
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
8
|
+
const _hoisted_1 = { class: "flex min-w-0 flex-1 flex-col" };
|
|
9
|
+
const _hoisted_2 = { class: "relative flex h-16 shrink-0 items-center gap-3 border-b border-line bg-surface px-4 md:px-6" };
|
|
10
|
+
const _hoisted_3 = { class: "truncate text-lg font-semibold" };
|
|
11
|
+
const _hoisted_4 = {
|
|
12
12
|
key: 0,
|
|
13
13
|
class: "min-h-0 flex-1 overflow-hidden"
|
|
14
14
|
};
|
|
15
|
+
const __default__ = { inheritAttrs: false };
|
|
15
16
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
17
|
+
...__default__,
|
|
16
18
|
__name: "LpAppShell",
|
|
17
19
|
props: {
|
|
18
20
|
items: {},
|
|
@@ -80,8 +82,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
80
82
|
const burgerClass = computed(() => burgerHidden[props.mobileBreakpoint]);
|
|
81
83
|
const _openDrawer = () => emit("update:open", true);
|
|
82
84
|
__expose({ openDrawer: _openDrawer });
|
|
85
|
+
const { class: rootClass, attrs: rest } = useMergedAttrs(
|
|
86
|
+
"flex h-dvh overflow-hidden bg-surface text-ink"
|
|
87
|
+
);
|
|
83
88
|
return (_ctx, _cache) => {
|
|
84
|
-
return openBlock(), createElementBlock("div",
|
|
89
|
+
return openBlock(), createElementBlock("div", mergeProps({ class: unref(rootClass) }, unref(rest)), [
|
|
85
90
|
createVNode(_sfc_main$1, {
|
|
86
91
|
"model-value": __props.modelValue,
|
|
87
92
|
items: __props.items,
|
|
@@ -130,8 +135,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
130
135
|
key: "3"
|
|
131
136
|
} : void 0
|
|
132
137
|
]), 1032, ["model-value", "items", "sections", "is-active", "open", "mobile-breakpoint", "divider", "loading", "collapsed", "auto-collapse-after"]),
|
|
133
|
-
createElementVNode("div",
|
|
134
|
-
createElementVNode("header",
|
|
138
|
+
createElementVNode("div", _hoisted_1, [
|
|
139
|
+
createElementVNode("header", _hoisted_2, [
|
|
135
140
|
createVNode(_sfc_main$2, {
|
|
136
141
|
class: normalizeClass(burgerClass.value),
|
|
137
142
|
variant: "ghost",
|
|
@@ -154,7 +159,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
154
159
|
}, {
|
|
155
160
|
default: withCtx(() => [
|
|
156
161
|
renderSlot(_ctx.$slots, "header-title", {}, () => [
|
|
157
|
-
createElementVNode("h1",
|
|
162
|
+
createElementVNode("h1", _hoisted_3, toDisplayString(pageTitle.value), 1)
|
|
158
163
|
])
|
|
159
164
|
]),
|
|
160
165
|
_: 3
|
|
@@ -169,7 +174,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
169
174
|
_: 3
|
|
170
175
|
})
|
|
171
176
|
]),
|
|
172
|
-
__props.fullBleed ? (openBlock(), createElementBlock("div",
|
|
177
|
+
__props.fullBleed ? (openBlock(), createElementBlock("div", _hoisted_4, [
|
|
173
178
|
renderSlot(_ctx.$slots, "default")
|
|
174
179
|
])) : (openBlock(), createBlock(_sfc_main$5, {
|
|
175
180
|
key: 1,
|
|
@@ -183,7 +188,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
183
188
|
}, 8, ["content-class"]))
|
|
184
189
|
]),
|
|
185
190
|
renderSlot(_ctx.$slots, "overlays")
|
|
186
|
-
]);
|
|
191
|
+
], 16);
|
|
187
192
|
};
|
|
188
193
|
}
|
|
189
194
|
});
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import { defineComponent, openBlock, createElementBlock, Fragment, renderList, createBlock, createCommentVNode, resolveDynamicComponent, withCtx, createTextVNode, toDisplayString, normalizeClass } from "vue";
|
|
1
|
+
import { defineComponent, openBlock, createElementBlock, mergeProps, unref, Fragment, renderList, createBlock, createCommentVNode, resolveDynamicComponent, withCtx, createTextVNode, toDisplayString, normalizeClass } from "vue";
|
|
2
2
|
import { _ as _sfc_main$1 } from "./LpIcon-CCnX5_2j.js";
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
"aria-label": "Breadcrumb"
|
|
6
|
-
};
|
|
3
|
+
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
4
|
+
const __default__ = { inheritAttrs: false };
|
|
7
5
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
6
|
+
...__default__,
|
|
8
7
|
__name: "LpBreadcrumbs",
|
|
9
8
|
props: {
|
|
10
9
|
items: {},
|
|
@@ -12,8 +11,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
12
11
|
},
|
|
13
12
|
emits: ["navigate"],
|
|
14
13
|
setup(__props) {
|
|
14
|
+
const { class: rootClass, attrs: rest } = useMergedAttrs(
|
|
15
|
+
"flex items-center gap-1.5 text-sm"
|
|
16
|
+
);
|
|
15
17
|
return (_ctx, _cache) => {
|
|
16
|
-
return openBlock(), createElementBlock("nav",
|
|
18
|
+
return openBlock(), createElementBlock("nav", mergeProps({ class: unref(rootClass) }, unref(rest), { "aria-label": "Breadcrumb" }), [
|
|
17
19
|
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.items, (item, i) => {
|
|
18
20
|
return openBlock(), createElementBlock(Fragment, { key: i }, [
|
|
19
21
|
i > 0 ? (openBlock(), createBlock(_sfc_main$1, {
|
|
@@ -51,7 +53,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
51
53
|
], 2))
|
|
52
54
|
], 64);
|
|
53
55
|
}), 128))
|
|
54
|
-
]);
|
|
56
|
+
], 16);
|
|
55
57
|
};
|
|
56
58
|
}
|
|
57
59
|
});
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
import { defineComponent, computed, openBlock, createBlock, unref, withCtx, createVNode, normalizeClass, createElementBlock, Fragment, renderList, createTextVNode, toDisplayString } from "vue";
|
|
1
|
+
import { defineComponent, computed, openBlock, createBlock, unref, mergeProps, withCtx, createVNode, normalizeClass, createElementBlock, Fragment, renderList, createTextVNode, toDisplayString } from "vue";
|
|
2
2
|
import { today, getLocalTimeZone, parseDate } from "@internationalized/date";
|
|
3
3
|
import { CalendarRoot, CalendarHeader, CalendarPrev, CalendarHeading, CalendarNext, CalendarGrid, CalendarGridHead, CalendarGridRow, CalendarHeadCell, CalendarGridBody, CalendarCell, CalendarCellTrigger } from "reka-ui";
|
|
4
4
|
import { _ as _sfc_main$1 } from "./LpIcon-CCnX5_2j.js";
|
|
5
|
-
|
|
5
|
+
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
6
|
+
const __default__ = { inheritAttrs: false };
|
|
6
7
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
8
|
+
...__default__,
|
|
7
9
|
__name: "LpCalendar",
|
|
8
10
|
props: {
|
|
9
11
|
modelValue: {},
|
|
@@ -34,8 +36,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
34
36
|
function disabledFor(date) {
|
|
35
37
|
return props.isDisabled?.(date.toString()) ?? false;
|
|
36
38
|
}
|
|
39
|
+
const navBtn = "flex size-8 items-center justify-center rounded-control text-muted outline-none transition-[color,background-color,scale] duration-[var(--duration-fast)] ease-[var(--ease-emphasized)] hover:bg-surface-soft hover:text-ink active:scale-90 motion-reduce:active:scale-100 focus-visible:ring-2 focus-visible:ring-ring";
|
|
40
|
+
const { class: rootClass, attrs: rest } = useMergedAttrs(
|
|
41
|
+
"inline-block rounded-card border border-line bg-surface-raised p-3"
|
|
42
|
+
);
|
|
37
43
|
return (_ctx, _cache) => {
|
|
38
|
-
return openBlock(), createBlock(unref(CalendarRoot), {
|
|
44
|
+
return openBlock(), createBlock(unref(CalendarRoot), mergeProps({
|
|
39
45
|
"model-value": value.value,
|
|
40
46
|
"min-value": minValue.value,
|
|
41
47
|
"max-value": maxValue.value,
|
|
@@ -43,9 +49,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
43
49
|
"weekday-format": __props.weekdayFormat,
|
|
44
50
|
"is-date-disabled": disabledFor,
|
|
45
51
|
"fixed-weeks": "",
|
|
46
|
-
class:
|
|
47
|
-
|
|
48
|
-
}, {
|
|
52
|
+
class: unref(rootClass)
|
|
53
|
+
}, unref(rest), { "onUpdate:modelValue": onUpdate }), {
|
|
49
54
|
default: withCtx(({ weekDays, grid }) => [
|
|
50
55
|
createVNode(unref(CalendarHeader), { class: "mb-2 flex items-center justify-between gap-2" }, {
|
|
51
56
|
default: withCtx(() => [
|
|
@@ -141,7 +146,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
141
146
|
}), 128))
|
|
142
147
|
]),
|
|
143
148
|
_: 1
|
|
144
|
-
},
|
|
149
|
+
}, 16, ["model-value", "min-value", "max-value", "placeholder", "weekday-format", "class"]);
|
|
145
150
|
};
|
|
146
151
|
}
|
|
147
152
|
});
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { defineComponent, computed, openBlock, createBlock, withCtx, resolveDynamicComponent, mergeProps, renderSlot } from "vue";
|
|
1
|
+
import { defineComponent, computed, openBlock, createBlock, withCtx, resolveDynamicComponent, mergeProps, unref, renderSlot } from "vue";
|
|
2
2
|
import { tv } from "tailwind-variants";
|
|
3
|
+
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
3
4
|
import { _ as _sfc_main$1 } from "./LpContextMenu-B6WBLleS.js";
|
|
4
5
|
const __default__ = { inheritAttrs: false };
|
|
5
6
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
@@ -10,7 +11,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
10
11
|
padded: { type: Boolean, default: true },
|
|
11
12
|
interactive: { type: Boolean, default: false },
|
|
12
13
|
menuItems: {},
|
|
13
|
-
as: { default: "div" }
|
|
14
|
+
as: { default: "div" },
|
|
15
|
+
accent: {},
|
|
16
|
+
accentWidth: {}
|
|
14
17
|
},
|
|
15
18
|
setup(__props) {
|
|
16
19
|
const card = tv({
|
|
@@ -38,6 +41,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
38
41
|
ghost: "border-transparent bg-transparent"
|
|
39
42
|
},
|
|
40
43
|
padded: { true: "p-5", false: "" },
|
|
44
|
+
// The stripe itself lives in .lp-card-accent (tokens.css), which composes
|
|
45
|
+
// it with the skin painter's shadows instead of overwriting them.
|
|
46
|
+
accent: { true: "lp-card-accent", false: "" },
|
|
41
47
|
// Lift on hover with a BRAND-tinted glow + brand border (a black drop-shadow
|
|
42
48
|
// was invisible on dark themes — it only showed on light). We write the glow
|
|
43
49
|
// through `--surface-panel-shadow`, the very variable the skin-painter feeds
|
|
@@ -48,6 +54,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
48
54
|
// (not `transform`), so the transition list MUST name `translate` explicitly
|
|
49
55
|
// or the lift snaps while the rest eases.
|
|
50
56
|
//
|
|
57
|
+
// `hover:shadow-*` sets box-shadow whole, which on an accented card dropped
|
|
58
|
+
// the stripe on hover — the card lit up and its colour went with it.
|
|
59
|
+
// .lp-card-accent is declared outside @layer, so it outranks the utility and
|
|
60
|
+
// keeps the stripe; the `--surface-panel-shadow` swap on the same line is
|
|
61
|
+
// what actually carries the glow there. See tokens.css.
|
|
62
|
+
//
|
|
51
63
|
// The glow reaches past the card, so a clipping ancestor (scroll area,
|
|
52
64
|
// dialog body) will slice it unless the list reserves room — see the
|
|
53
65
|
// `.lp-glow-room` helper in tokens.css, whose spread tokens describe exactly
|
|
@@ -58,8 +70,19 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
58
70
|
}
|
|
59
71
|
});
|
|
60
72
|
const props = __props;
|
|
61
|
-
const classes =
|
|
62
|
-
() => card({
|
|
73
|
+
const { class: classes, attrs: rest } = useMergedAttrs(
|
|
74
|
+
() => card({
|
|
75
|
+
variant: props.variant,
|
|
76
|
+
padded: props.padded,
|
|
77
|
+
interactive: props.interactive,
|
|
78
|
+
accent: Boolean(props.accent)
|
|
79
|
+
})
|
|
80
|
+
);
|
|
81
|
+
const accentStyle = computed(
|
|
82
|
+
() => props.accent ? {
|
|
83
|
+
"--lp-card-accent": props.accent,
|
|
84
|
+
...props.accentWidth ? { "--lp-card-accent-width": props.accentWidth } : {}
|
|
85
|
+
} : void 0
|
|
63
86
|
);
|
|
64
87
|
return (_ctx, _cache) => {
|
|
65
88
|
return __props.menuItems?.length ? (openBlock(), createBlock(_sfc_main$1, {
|
|
@@ -67,23 +90,27 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
67
90
|
items: __props.menuItems
|
|
68
91
|
}, {
|
|
69
92
|
default: withCtx(() => [
|
|
70
|
-
(openBlock(), createBlock(resolveDynamicComponent(__props.as), mergeProps({
|
|
93
|
+
(openBlock(), createBlock(resolveDynamicComponent(__props.as), mergeProps({
|
|
94
|
+
class: unref(classes),
|
|
95
|
+
style: accentStyle.value
|
|
96
|
+
}, unref(rest)), {
|
|
71
97
|
default: withCtx(() => [
|
|
72
98
|
renderSlot(_ctx.$slots, "default")
|
|
73
99
|
]),
|
|
74
100
|
_: 3
|
|
75
|
-
}, 16, ["class"]))
|
|
101
|
+
}, 16, ["class", "style"]))
|
|
76
102
|
]),
|
|
77
103
|
_: 3
|
|
78
104
|
}, 8, ["items"])) : (openBlock(), createBlock(resolveDynamicComponent(__props.as), mergeProps({
|
|
79
105
|
key: 1,
|
|
80
|
-
class: classes
|
|
81
|
-
|
|
106
|
+
class: unref(classes),
|
|
107
|
+
style: accentStyle.value
|
|
108
|
+
}, unref(rest)), {
|
|
82
109
|
default: withCtx(() => [
|
|
83
110
|
renderSlot(_ctx.$slots, "default")
|
|
84
111
|
]),
|
|
85
112
|
_: 3
|
|
86
|
-
}, 16, ["class"]));
|
|
113
|
+
}, 16, ["class", "style"]));
|
|
87
114
|
};
|
|
88
115
|
}
|
|
89
116
|
});
|
|
@@ -1,8 +1,10 @@
|
|
|
1
|
-
import { defineComponent, openBlock, createElementBlock,
|
|
1
|
+
import { defineComponent, openBlock, createElementBlock, mergeProps, unref, createVNode, withCtx, renderSlot, createTextVNode, toDisplayString } from "vue";
|
|
2
2
|
import { CheckboxRoot, CheckboxIndicator } from "reka-ui";
|
|
3
3
|
import { _ as _sfc_main$1 } from "./LpIcon-CCnX5_2j.js";
|
|
4
|
-
|
|
4
|
+
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
5
|
+
const __default__ = { inheritAttrs: false };
|
|
5
6
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
7
|
+
...__default__,
|
|
6
8
|
__name: "LpCheckbox",
|
|
7
9
|
props: {
|
|
8
10
|
modelValue: { type: Boolean },
|
|
@@ -20,8 +22,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
20
22
|
emit("update:modelValue", checked);
|
|
21
23
|
emit("change", checked);
|
|
22
24
|
}
|
|
25
|
+
const { class: rootClass, attrs: rest } = useMergedAttrs(
|
|
26
|
+
"group inline-flex cursor-pointer items-center gap-2 text-sm text-ink"
|
|
27
|
+
);
|
|
23
28
|
return (_ctx, _cache) => {
|
|
24
|
-
return openBlock(), createElementBlock("label",
|
|
29
|
+
return openBlock(), createElementBlock("label", mergeProps({ class: unref(rootClass) }, unref(rest)), [
|
|
25
30
|
createVNode(unref(CheckboxRoot), {
|
|
26
31
|
id: __props.id,
|
|
27
32
|
name: __props.name,
|
|
@@ -46,7 +51,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
46
51
|
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
47
52
|
createTextVNode(toDisplayString(__props.label), 1)
|
|
48
53
|
])
|
|
49
|
-
]);
|
|
54
|
+
], 16);
|
|
50
55
|
};
|
|
51
56
|
}
|
|
52
57
|
});
|
|
@@ -1,42 +1,44 @@
|
|
|
1
|
-
import { defineComponent, computed, reactive, watch, openBlock, createElementBlock, toDisplayString, createCommentVNode, createElementVNode, createVNode,
|
|
1
|
+
import { defineComponent, computed, reactive, watch, openBlock, createElementBlock, mergeProps, unref, toDisplayString, createCommentVNode, createElementVNode, createVNode, normalizeClass, normalizeStyle, Fragment, renderList } from "vue";
|
|
2
2
|
import { useClipboard } from "../composables/useClipboard.js";
|
|
3
3
|
import { tokenizeLine } from "../components/codeHighlight.js";
|
|
4
4
|
import { _ as _sfc_main$1 } from "./LpIcon-CCnX5_2j.js";
|
|
5
|
-
|
|
6
|
-
const
|
|
5
|
+
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
6
|
+
const _hoisted_1 = {
|
|
7
7
|
key: 0,
|
|
8
8
|
class: "flex items-center gap-2 border-b border-line bg-surface-soft px-3 py-1.5 text-muted"
|
|
9
9
|
};
|
|
10
|
-
const
|
|
10
|
+
const _hoisted_2 = {
|
|
11
11
|
key: 0,
|
|
12
12
|
class: "truncate text-ink"
|
|
13
13
|
};
|
|
14
|
-
const
|
|
14
|
+
const _hoisted_3 = {
|
|
15
15
|
key: 1,
|
|
16
16
|
class: "rounded bg-surface px-1.5 py-0.5 text-[10px] uppercase tracking-wide"
|
|
17
17
|
};
|
|
18
|
-
const
|
|
18
|
+
const _hoisted_4 = { class: "ml-auto flex items-center gap-1" };
|
|
19
|
+
const _hoisted_5 = ["aria-label"];
|
|
19
20
|
const _hoisted_6 = ["aria-label"];
|
|
20
|
-
const _hoisted_7 = ["
|
|
21
|
-
const _hoisted_8 =
|
|
22
|
-
const _hoisted_9 = {
|
|
23
|
-
const _hoisted_10 = {
|
|
21
|
+
const _hoisted_7 = ["value"];
|
|
22
|
+
const _hoisted_8 = { class: "block" };
|
|
23
|
+
const _hoisted_9 = {
|
|
24
24
|
key: 0,
|
|
25
25
|
class: "mr-3 inline-block w-7 select-none text-right text-muted/60",
|
|
26
26
|
"aria-hidden": "true"
|
|
27
27
|
};
|
|
28
|
-
const
|
|
29
|
-
const
|
|
30
|
-
const
|
|
28
|
+
const _hoisted_10 = ["aria-expanded", "onClick"];
|
|
29
|
+
const _hoisted_11 = { class: "select-none" };
|
|
30
|
+
const _hoisted_12 = {
|
|
31
31
|
key: 0,
|
|
32
32
|
class: "select-none text-muted/50"
|
|
33
33
|
};
|
|
34
|
-
const
|
|
34
|
+
const _hoisted_13 = {
|
|
35
35
|
key: 0,
|
|
36
36
|
class: "mr-3 inline-block w-7 select-none text-right text-muted/60",
|
|
37
37
|
"aria-hidden": "true"
|
|
38
38
|
};
|
|
39
|
+
const __default__ = { inheritAttrs: false };
|
|
39
40
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
41
|
+
...__default__,
|
|
40
42
|
__name: "LpCodeBlock",
|
|
41
43
|
props: {
|
|
42
44
|
modelValue: {},
|
|
@@ -92,9 +94,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
92
94
|
const startMatch = line.match(REGION_START);
|
|
93
95
|
if (startMatch) {
|
|
94
96
|
flushPlain();
|
|
95
|
-
const
|
|
96
|
-
const defaultOpen = /\bopen\b/.test(
|
|
97
|
-
const label =
|
|
97
|
+
const rest2 = startMatch[1] ?? "";
|
|
98
|
+
const defaultOpen = /\bopen\b/.test(rest2);
|
|
99
|
+
const label = rest2.replace(/\bopen\b/, "").trim() || "details";
|
|
98
100
|
const lines = [];
|
|
99
101
|
i++;
|
|
100
102
|
for (; i < src.length; i++) {
|
|
@@ -139,12 +141,15 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
139
141
|
function onInput(e) {
|
|
140
142
|
emit("update:modelValue", e.target.value);
|
|
141
143
|
}
|
|
144
|
+
const { class: rootClass, attrs: rest } = useMergedAttrs(
|
|
145
|
+
"overflow-hidden rounded-card border border-line bg-surface font-mono text-xs"
|
|
146
|
+
);
|
|
142
147
|
return (_ctx, _cache) => {
|
|
143
|
-
return openBlock(), createElementBlock("div",
|
|
144
|
-
showHeader.value ? (openBlock(), createElementBlock("div",
|
|
145
|
-
__props.title ? (openBlock(), createElementBlock("span",
|
|
146
|
-
__props.lang !== "plain" ? (openBlock(), createElementBlock("span",
|
|
147
|
-
createElementVNode("div",
|
|
148
|
+
return openBlock(), createElementBlock("div", mergeProps({ class: unref(rootClass) }, unref(rest)), [
|
|
149
|
+
showHeader.value ? (openBlock(), createElementBlock("div", _hoisted_1, [
|
|
150
|
+
__props.title ? (openBlock(), createElementBlock("span", _hoisted_2, toDisplayString(__props.title), 1)) : createCommentVNode("", true),
|
|
151
|
+
__props.lang !== "plain" ? (openBlock(), createElementBlock("span", _hoisted_3, toDisplayString(__props.lang), 1)) : createCommentVNode("", true),
|
|
152
|
+
createElementVNode("div", _hoisted_4, [
|
|
148
153
|
__props.lockToggle ? (openBlock(), createElementBlock("button", {
|
|
149
154
|
key: 0,
|
|
150
155
|
type: "button",
|
|
@@ -157,7 +162,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
157
162
|
size: 13,
|
|
158
163
|
class: "transition-transform duration-[var(--duration-fast)] ease-[var(--ease-emphasized)] group-active/lock:scale-90"
|
|
159
164
|
}, null, 8, ["name"])
|
|
160
|
-
], 8,
|
|
165
|
+
], 8, _hoisted_5)) : createCommentVNode("", true),
|
|
161
166
|
__props.copyable ? (openBlock(), createElementBlock("button", {
|
|
162
167
|
key: 1,
|
|
163
168
|
type: "button",
|
|
@@ -170,7 +175,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
170
175
|
size: 13,
|
|
171
176
|
class: normalizeClass(unref(copied) ? "text-action" : "")
|
|
172
177
|
}, null, 8, ["name", "class"])
|
|
173
|
-
], 8,
|
|
178
|
+
], 8, _hoisted_6)) : createCommentVNode("", true)
|
|
174
179
|
])
|
|
175
180
|
])) : createCommentVNode("", true),
|
|
176
181
|
createElementVNode("div", {
|
|
@@ -183,11 +188,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
183
188
|
spellcheck: "false",
|
|
184
189
|
class: normalizeClass(["lp-scrollbar-none absolute inset-0 size-full resize-none overflow-auto whitespace-pre bg-transparent p-3 leading-relaxed text-transparent caret-brand outline-none", [__props.wrap ? "whitespace-pre-wrap break-words" : "whitespace-pre", __props.lineNumbers ? "pl-12" : ""]]),
|
|
185
190
|
onInput
|
|
186
|
-
}, null, 42,
|
|
191
|
+
}, null, 42, _hoisted_7)) : createCommentVNode("", true),
|
|
187
192
|
createElementVNode("pre", {
|
|
188
193
|
class: normalizeClass(["lp-scrollbar-none m-0 overflow-auto p-3 leading-relaxed", [__props.wrap ? "whitespace-pre-wrap break-words" : "whitespace-pre", !__props.locked && !hasFolds.value ? "pointer-events-none" : ""]])
|
|
189
194
|
}, [
|
|
190
|
-
createElementVNode("code",
|
|
195
|
+
createElementVNode("code", _hoisted_8, [
|
|
191
196
|
(openBlock(true), createElementBlock(Fragment, null, renderList(segments.value, (seg, s) => {
|
|
192
197
|
return openBlock(), createElementBlock(Fragment, { key: s }, [
|
|
193
198
|
seg.kind === "lines" ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(seg.lines, (ln) => {
|
|
@@ -195,7 +200,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
195
200
|
key: "l" + ln.n,
|
|
196
201
|
class: "block min-h-[1.4em]"
|
|
197
202
|
}, [
|
|
198
|
-
__props.lineNumbers ? (openBlock(), createElementBlock("span",
|
|
203
|
+
__props.lineNumbers ? (openBlock(), createElementBlock("span", _hoisted_9, toDisplayString(ln.n), 1)) : createCommentVNode("", true),
|
|
199
204
|
(openBlock(true), createElementBlock(Fragment, null, renderList(tokens(ln.text), (tok, j) => {
|
|
200
205
|
return openBlock(), createElementBlock("span", {
|
|
201
206
|
key: j,
|
|
@@ -215,15 +220,15 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
215
220
|
size: 12,
|
|
216
221
|
class: "shrink-0"
|
|
217
222
|
}, null, 8, ["name"]),
|
|
218
|
-
createElementVNode("span",
|
|
219
|
-
!openState[seg.id] ? (openBlock(), createElementBlock("span",
|
|
220
|
-
], 8,
|
|
223
|
+
createElementVNode("span", _hoisted_11, toDisplayString(openState[seg.id] ? seg.label : seg.label + " …"), 1),
|
|
224
|
+
!openState[seg.id] ? (openBlock(), createElementBlock("span", _hoisted_12, "(" + toDisplayString(seg.lines.length) + " lines)", 1)) : createCommentVNode("", true)
|
|
225
|
+
], 8, _hoisted_10),
|
|
221
226
|
openState[seg.id] ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(seg.lines, (ln) => {
|
|
222
227
|
return openBlock(), createElementBlock("span", {
|
|
223
228
|
key: "f" + ln.n,
|
|
224
229
|
class: "block min-h-[1.4em]"
|
|
225
230
|
}, [
|
|
226
|
-
__props.lineNumbers ? (openBlock(), createElementBlock("span",
|
|
231
|
+
__props.lineNumbers ? (openBlock(), createElementBlock("span", _hoisted_13, toDisplayString(ln.n), 1)) : createCommentVNode("", true),
|
|
227
232
|
(openBlock(true), createElementBlock(Fragment, null, renderList(tokens(ln.text), (tok, j) => {
|
|
228
233
|
return openBlock(), createElementBlock("span", {
|
|
229
234
|
key: j,
|
|
@@ -238,7 +243,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
238
243
|
])
|
|
239
244
|
], 2)
|
|
240
245
|
], 6)
|
|
241
|
-
]);
|
|
246
|
+
], 16);
|
|
242
247
|
};
|
|
243
248
|
}
|
|
244
249
|
});
|