@leavepulse/ui 0.12.0 → 0.14.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.
Files changed (162) hide show
  1. package/dist/assets/LpCommandPalette-D315B47-.css +16 -0
  2. package/dist/chunks/LayoutCanvas-Dd20boUG.js +50 -0
  3. package/dist/chunks/LayoutNode-DGpZA9LX.js +225 -0
  4. package/dist/chunks/LpAlert-BAYHDSS1.js +69 -0
  5. package/dist/chunks/LpAppShell-DBTsNQaM.js +170 -0
  6. package/dist/chunks/LpAutocomplete-B9uoCs4t.js +196 -0
  7. package/dist/chunks/LpAvatar-B1Ez0ZAx.js +88 -0
  8. package/dist/chunks/LpBadge-CXzBPnwO.js +42 -0
  9. package/dist/chunks/LpBreadcrumbs-B7Aqatzw.js +42 -0
  10. package/dist/chunks/LpButton-5VXXCjwF.js +101 -0
  11. package/dist/chunks/LpCalendar-B7ZL0ty3.js +150 -0
  12. package/dist/chunks/LpCard-1yvWT9fx.js +66 -0
  13. package/dist/chunks/LpCheckbox-BO0zuuPh.js +55 -0
  14. package/dist/chunks/LpCodeBlock-CSiOSPs8.js +253 -0
  15. package/dist/chunks/LpConfirmDialog-KLtTtCiT.js +62 -0
  16. package/dist/chunks/LpContextMenu-D0mzXqA7.js +151 -0
  17. package/dist/chunks/LpDatePicker-dY2q4dr4.js +122 -0
  18. package/dist/chunks/LpDisclosure-DP6yfgfM.js +76 -0
  19. package/dist/chunks/LpDivider-CUX46KR0.js +43 -0
  20. package/dist/chunks/LpDrawer-Ce6g9ZMr.js +310 -0
  21. package/dist/chunks/LpDropdownMenu-DJpoqRCb.js +65 -0
  22. package/dist/chunks/LpEmptyState-CrfyRJUG.js +47 -0
  23. package/dist/chunks/LpFormField-Bn-ZwC6z.js +47 -0
  24. package/dist/chunks/LpIcon-CCnX5_2j.js +41 -0
  25. package/dist/chunks/LpInfraNode-C_PHcthC.js +99 -0
  26. package/dist/chunks/LpInput-BauZRyzm.js +136 -0
  27. package/dist/chunks/LpLaneNode-HtnQf2FF.js +33 -0
  28. package/dist/chunks/LpLink-DHwOEp4e.js +36 -0
  29. package/dist/chunks/LpLogViewer-hC0OKkeE.js +482 -0
  30. package/dist/chunks/LpModal-CWoOExzT.js +128 -0
  31. package/dist/chunks/LpNotificationBell-BDy0tQwr.js +232 -0
  32. package/dist/chunks/LpNumberField-C5ar-OwE.js +55 -0
  33. package/dist/chunks/LpOtpInput-DqaT0Z75.js +65 -0
  34. package/dist/chunks/LpPagination-CeGuNe_q.js +132 -0
  35. package/dist/chunks/LpPasswordInput-DIHFw4u0.js +64 -0
  36. package/dist/chunks/LpPhoneInput-LQvVFGMw.js +199 -0
  37. package/dist/chunks/LpPopover-8268UmlC.js +54 -0
  38. package/dist/chunks/LpProgress-BhI0IbjC.js +37 -0
  39. package/dist/chunks/LpRadio-CL-pI0_O.js +39 -0
  40. package/dist/chunks/LpRadioGroup-B4yDTmi6.js +52 -0
  41. package/dist/chunks/LpScrollArea-K1x-azgY.js +67 -0
  42. package/dist/chunks/LpSegmented-BmpanyAo.js +74 -0
  43. package/dist/chunks/LpSelect-DznhPEWX.js +222 -0
  44. package/dist/chunks/LpServiceNode-Dc-Ut5RS.js +51 -0
  45. package/dist/chunks/LpSidebar-BPQabjae.js +152 -0
  46. package/dist/chunks/LpSidebarNav-CpF7rZxx.js +126 -0
  47. package/dist/chunks/LpSkeleton-eSFIo4kD.js +22 -0
  48. package/dist/chunks/LpSlider-B1SF3pRV.js +53 -0
  49. package/dist/chunks/LpStat-CdbEFOvn.js +88 -0
  50. package/dist/chunks/LpStepper-5dFTrW21.js +53 -0
  51. package/dist/chunks/LpSwitch-v6fnccSM.js +28 -0
  52. package/dist/chunks/LpTable-CJ4Zt1UH.js +229 -0
  53. package/dist/chunks/LpTableOfContents-CjvxPMpU.js +155 -0
  54. package/dist/chunks/LpTabs-D7aTVPOb.js +115 -0
  55. package/dist/chunks/LpTextarea-CRAkhemZ.js +44 -0
  56. package/dist/chunks/LpThemeSwitcher-BgWwfkxs.js +601 -0
  57. package/dist/chunks/LpTilt-DuyKbpkA.js +49 -0
  58. package/dist/chunks/LpToaster-gDB1EaU3.js +196 -0
  59. package/dist/chunks/LpTooltip-CIwoRCag.js +49 -0
  60. package/dist/chunks/LpTopologyCanvas-DVwyQfKa.js +237 -0
  61. package/dist/chunks/LpUptimeBar-CB366k0O.js +127 -0
  62. package/dist/component-names.d.ts +1 -1
  63. package/dist/components/LayoutCanvas.vue.js +4 -0
  64. package/dist/components/LayoutNode.vue.js +4 -0
  65. package/dist/components/LpAlert.vue.js +4 -0
  66. package/dist/components/LpAppShell.vue.js +4 -0
  67. package/dist/components/LpAutocomplete.vue.js +4 -0
  68. package/dist/components/LpAvatar.vue.js +4 -0
  69. package/dist/components/LpBadge.vue.js +4 -0
  70. package/dist/components/LpBreadcrumbs.vue.js +4 -0
  71. package/dist/components/LpButton.vue.js +4 -0
  72. package/dist/components/LpCalendar.vue.js +4 -0
  73. package/dist/components/LpCard.vue.js +4 -0
  74. package/dist/components/LpCheckbox.vue.js +4 -0
  75. package/dist/components/LpCodeBlock.vue.js +4 -0
  76. package/dist/components/LpCommandPalette.vue.js +310 -0
  77. package/dist/components/LpConfirmDialog.vue.js +4 -0
  78. package/dist/components/LpContextMenu.vue.d.ts +7 -0
  79. package/dist/components/LpContextMenu.vue.js +4 -0
  80. package/dist/components/LpDatePicker.vue.js +4 -0
  81. package/dist/components/LpDisclosure.vue.js +4 -0
  82. package/dist/components/LpDivider.vue.js +4 -0
  83. package/dist/components/LpDrawer.vue.d.ts +8 -0
  84. package/dist/components/LpDrawer.vue.js +4 -0
  85. package/dist/components/LpDropdownMenu.vue.js +4 -0
  86. package/dist/components/LpEmptyState.vue.js +4 -0
  87. package/dist/components/LpFormField.vue.js +4 -0
  88. package/dist/components/LpIcon.vue.js +4 -0
  89. package/dist/components/LpInfraNode.vue.js +4 -0
  90. package/dist/components/LpInput.vue.js +4 -0
  91. package/dist/components/LpLaneNode.vue.js +4 -0
  92. package/dist/components/LpLink.vue.js +4 -0
  93. package/dist/components/LpLogViewer.vue.js +4 -0
  94. package/dist/components/LpModal.vue.js +4 -0
  95. package/dist/components/LpNotificationBell.vue.js +4 -0
  96. package/dist/components/LpNumberField.vue.js +4 -0
  97. package/dist/components/LpOtpInput.vue.js +4 -0
  98. package/dist/components/LpPagination.vue.js +4 -0
  99. package/dist/components/LpPasswordInput.vue.js +4 -0
  100. package/dist/components/LpPhoneInput.vue.js +4 -0
  101. package/dist/components/LpPopover.vue.js +4 -0
  102. package/dist/components/LpProgress.vue.js +4 -0
  103. package/dist/components/LpRadio.vue.js +4 -0
  104. package/dist/components/LpRadioGroup.vue.js +4 -0
  105. package/dist/components/LpScrollArea.vue.d.ts +2 -2
  106. package/dist/components/LpScrollArea.vue.js +4 -0
  107. package/dist/components/LpSegmented.vue.js +4 -0
  108. package/dist/components/LpSelect.vue.d.ts +2 -0
  109. package/dist/components/LpSelect.vue.js +4 -0
  110. package/dist/components/LpServiceNode.vue.js +4 -0
  111. package/dist/components/LpSidebar.vue.js +4 -0
  112. package/dist/components/LpSidebarNav.vue.js +4 -0
  113. package/dist/components/LpSkeleton.vue.js +4 -0
  114. package/dist/components/LpSlider.vue.js +4 -0
  115. package/dist/components/LpStat.vue.js +4 -0
  116. package/dist/components/LpStepper.vue.js +4 -0
  117. package/dist/components/LpSwitch.vue.js +4 -0
  118. package/dist/components/LpTable.vue.js +4 -0
  119. package/dist/components/LpTableOfContents.vue.js +4 -0
  120. package/dist/components/LpTabs.vue.d.ts +4 -2
  121. package/dist/components/LpTabs.vue.js +4 -0
  122. package/dist/components/LpTextarea.vue.js +4 -0
  123. package/dist/components/LpThemeSwitcher.vue.js +4 -0
  124. package/dist/components/LpTilt.vue.d.ts +31 -0
  125. package/dist/components/LpTilt.vue.js +4 -0
  126. package/dist/components/LpToaster.vue.js +4 -0
  127. package/dist/components/LpTooltip.vue.js +4 -0
  128. package/dist/components/LpTopologyCanvas.vue.js +4 -0
  129. package/dist/components/LpUptimeBar.vue.js +4 -0
  130. package/dist/components/codeHighlight.js +230 -0
  131. package/dist/{countries-data-9rgqJWHo.js → components/countries-data.js} +2 -2
  132. package/dist/components/countries.js +38 -0
  133. package/dist/components/dropdown.js +14 -0
  134. package/dist/components/sidebar.js +1 -0
  135. package/dist/composables/useInputFilter.js +44 -0
  136. package/dist/composables/usePillTransition.js +11 -0
  137. package/dist/composables/useTilt.d.ts +23 -0
  138. package/dist/composables/useTilt.js +57 -0
  139. package/dist/composables/useToast.d.ts +2 -0
  140. package/dist/composables/useToast.js +49 -0
  141. package/dist/index.d.ts +3 -0
  142. package/dist/index.js +197 -17596
  143. package/dist/layout/registry.js +10 -0
  144. package/dist/layout/tree.js +192 -0
  145. package/dist/layout/useLayout.js +61 -0
  146. package/package.json +5 -3
  147. package/src/component-names.ts +1 -0
  148. package/src/components/LpContextMenu.vue +14 -4
  149. package/src/components/LpDrawer.vue +29 -1
  150. package/src/components/LpLogViewer.vue +180 -31
  151. package/src/components/LpScrollArea.vue +20 -15
  152. package/src/components/LpSelect.vue +0 -0
  153. package/src/components/LpSidebar.vue +5 -2
  154. package/src/components/LpTabs.vue +19 -6
  155. package/src/components/LpThemeSwitcher.vue +13 -2
  156. package/src/components/LpTilt.vue +61 -0
  157. package/src/components/LpToaster.vue +11 -4
  158. package/src/composables/useTilt.ts +103 -0
  159. package/src/composables/useToast.ts +2 -0
  160. package/src/index.ts +3 -0
  161. package/src/nuxt.ts +10 -1
  162. package/dist/index.css +0 -1
@@ -0,0 +1,47 @@
1
+ import { defineComponent, useId, openBlock, createElementBlock, createBlock, unref, withCtx, createTextVNode, toDisplayString, createCommentVNode, renderSlot } from "vue";
2
+ import { Label } from "reka-ui";
3
+ const _hoisted_1 = { class: "flex flex-col gap-1.5" };
4
+ const _hoisted_2 = {
5
+ key: 0,
6
+ class: "text-danger"
7
+ };
8
+ const _hoisted_3 = {
9
+ key: 1,
10
+ class: "text-xs text-danger"
11
+ };
12
+ const _hoisted_4 = {
13
+ key: 2,
14
+ class: "text-xs text-muted"
15
+ };
16
+ const _sfc_main = /* @__PURE__ */ defineComponent({
17
+ __name: "LpFormField",
18
+ props: {
19
+ label: {},
20
+ hint: {},
21
+ error: {},
22
+ required: { type: Boolean }
23
+ },
24
+ setup(__props) {
25
+ const id = useId();
26
+ return (_ctx, _cache) => {
27
+ return openBlock(), createElementBlock("div", _hoisted_1, [
28
+ __props.label ? (openBlock(), createBlock(unref(Label), {
29
+ key: 0,
30
+ for: unref(id),
31
+ class: "text-sm font-medium text-ink"
32
+ }, {
33
+ default: withCtx(() => [
34
+ createTextVNode(toDisplayString(__props.label) + " ", 1),
35
+ __props.required ? (openBlock(), createElementBlock("span", _hoisted_2, "*")) : createCommentVNode("", true)
36
+ ]),
37
+ _: 1
38
+ }, 8, ["for"])) : createCommentVNode("", true),
39
+ renderSlot(_ctx.$slots, "default", { id: unref(id) }),
40
+ __props.error ? (openBlock(), createElementBlock("p", _hoisted_3, toDisplayString(__props.error), 1)) : __props.hint ? (openBlock(), createElementBlock("p", _hoisted_4, toDisplayString(__props.hint), 1)) : createCommentVNode("", true)
41
+ ]);
42
+ };
43
+ }
44
+ });
45
+ export {
46
+ _sfc_main as _
47
+ };
@@ -0,0 +1,41 @@
1
+ import { defineComponent, computed, openBlock, createElementBlock, createBlock, unref } from "vue";
2
+ import { addCollection, getIcon, Icon } from "@iconify/vue";
3
+ import lucide from "@iconify-json/lucide/icons.json";
4
+ addCollection(lucide);
5
+ const _hoisted_1 = ["width", "height", "viewBox", "innerHTML"];
6
+ const _sfc_main = /* @__PURE__ */ defineComponent({
7
+ __name: "LpIcon",
8
+ props: {
9
+ name: {},
10
+ size: {}
11
+ },
12
+ setup(__props) {
13
+ const props = __props;
14
+ function resolve(name) {
15
+ return name.includes(":") ? name : `lucide:${name}`;
16
+ }
17
+ const fullName = computed(() => resolve(props.name));
18
+ const data = computed(() => getIcon(fullName.value));
19
+ const dim = computed(() => props.size ?? "1em");
20
+ return (_ctx, _cache) => {
21
+ return data.value ? (openBlock(), createElementBlock("svg", {
22
+ key: 0,
23
+ xmlns: "http://www.w3.org/2000/svg",
24
+ width: dim.value,
25
+ height: dim.value,
26
+ viewBox: `0 0 ${data.value.width} ${data.value.height}`,
27
+ "aria-hidden": "true",
28
+ innerHTML: data.value.body
29
+ }, null, 8, _hoisted_1)) : (openBlock(), createBlock(unref(Icon), {
30
+ key: 1,
31
+ icon: fullName.value,
32
+ width: dim.value,
33
+ height: dim.value,
34
+ "aria-hidden": "true"
35
+ }, null, 8, ["icon", "width", "height"]));
36
+ };
37
+ }
38
+ });
39
+ export {
40
+ _sfc_main as _
41
+ };
@@ -0,0 +1,99 @@
1
+ import { defineComponent, computed, openBlock, createElementBlock, normalizeStyle, normalizeClass, createVNode, unref, createElementVNode, toDisplayString, createCommentVNode, createTextVNode } from "vue";
2
+ import { Handle, Position } from "@vue-flow/core";
3
+ const _hoisted_1 = { class: "px-[11px] pb-2.5 pt-[9px]" };
4
+ const _hoisted_2 = { class: "flex items-center gap-[7px]" };
5
+ const _hoisted_3 = { class: "text-[13px] text-[var(--accent)]" };
6
+ const _hoisted_4 = { class: "flex-1 truncate text-[13px] font-semibold text-ink" };
7
+ const _hoisted_5 = { class: "mt-1.5 flex items-center justify-between" };
8
+ const _hoisted_6 = { class: "text-[10px] font-semibold uppercase tracking-wide text-[var(--accent)]" };
9
+ const _hoisted_7 = {
10
+ key: 0,
11
+ class: "font-mono text-[10px] text-muted"
12
+ };
13
+ const _hoisted_8 = {
14
+ key: 0,
15
+ class: "mt-1.5 flex items-center gap-1.5"
16
+ };
17
+ const _hoisted_9 = ["title"];
18
+ const _hoisted_10 = ["title"];
19
+ const _sfc_main = /* @__PURE__ */ defineComponent({
20
+ __name: "LpInfraNode",
21
+ props: {
22
+ data: {},
23
+ selected: { type: Boolean }
24
+ },
25
+ setup(__props) {
26
+ const props = __props;
27
+ const roleVar = {
28
+ hypervisor: "var(--color-accent)",
29
+ game: "var(--color-action)",
30
+ router: "var(--color-muted-strong)",
31
+ edge: "var(--color-brand)"
32
+ };
33
+ const accent = computed(() => roleVar[props.data.role] ?? "var(--color-line-strong)");
34
+ const roleIcon = {
35
+ hypervisor: "▣",
36
+ game: "◈",
37
+ router: "⇄",
38
+ edge: "☁"
39
+ };
40
+ const icon = computed(() => roleIcon[props.data.role] ?? "●");
41
+ return (_ctx, _cache) => {
42
+ return openBlock(), createElementBlock("div", {
43
+ class: normalizeClass(["w-[168px] overflow-hidden rounded-card border bg-surface-raised shadow-panel transition-[border-color,box-shadow]", __props.selected ? "border-[var(--accent)]" : "border-line"]),
44
+ style: normalizeStyle({
45
+ "--accent": accent.value,
46
+ opacity: __props.data.dimmed ? 0.3 : __props.data.online === false ? 0.5 : 1,
47
+ ...__props.selected ? { boxShadow: "0 0 0 2px color-mix(in srgb, var(--accent) 40%, transparent), var(--shadow-panel)" } : {}
48
+ })
49
+ }, [
50
+ createVNode(unref(Handle), {
51
+ type: "target",
52
+ position: unref(Position).Left,
53
+ class: "!size-2 !border-2 !border-[var(--accent)] !bg-surface"
54
+ }, null, 8, ["position"]),
55
+ createVNode(unref(Handle), {
56
+ type: "source",
57
+ position: unref(Position).Right,
58
+ class: "!size-2 !border-2 !border-[var(--accent)] !bg-surface"
59
+ }, null, 8, ["position"]),
60
+ _cache[2] || (_cache[2] = createElementVNode("div", { class: "h-[3px] bg-[var(--accent)]" }, null, -1)),
61
+ createElementVNode("div", _hoisted_1, [
62
+ createElementVNode("div", _hoisted_2, [
63
+ createElementVNode("span", _hoisted_3, toDisplayString(icon.value), 1),
64
+ createElementVNode("span", _hoisted_4, toDisplayString(__props.data.name), 1),
65
+ __props.data.online !== void 0 ? (openBlock(), createElementBlock("span", {
66
+ key: 0,
67
+ class: normalizeClass(["size-[7px] rounded-full", __props.data.online ? "bg-action shadow-[0_0_6px_var(--color-action)]" : "bg-danger"])
68
+ }, null, 2)) : createCommentVNode("", true)
69
+ ]),
70
+ createElementVNode("div", _hoisted_5, [
71
+ createElementVNode("span", _hoisted_6, toDisplayString(__props.data.role), 1),
72
+ __props.data.overlay ? (openBlock(), createElementBlock("span", _hoisted_7, toDisplayString(__props.data.overlay), 1)) : createCommentVNode("", true)
73
+ ]),
74
+ __props.data.firewallCount || __props.data.serviceCount !== void 0 ? (openBlock(), createElementBlock("div", _hoisted_8, [
75
+ __props.data.firewallCount ? (openBlock(), createElementBlock("span", {
76
+ key: 0,
77
+ class: "inline-flex items-center gap-1 rounded-pill bg-danger-soft px-1.5 py-0.5 text-[9px] font-medium text-danger",
78
+ title: `${__props.data.firewallCount} firewall rule(s)`
79
+ }, [
80
+ _cache[0] || (_cache[0] = createElementVNode("span", null, "⛨", -1)),
81
+ createTextVNode(toDisplayString(__props.data.firewallCount), 1)
82
+ ], 8, _hoisted_9)) : createCommentVNode("", true),
83
+ __props.data.serviceCount !== void 0 ? (openBlock(), createElementBlock("span", {
84
+ key: 1,
85
+ class: "inline-flex items-center gap-1 rounded-pill bg-surface-soft px-1.5 py-0.5 text-[9px] font-medium text-muted",
86
+ title: `${__props.data.serviceCount} service(s)`
87
+ }, [
88
+ _cache[1] || (_cache[1] = createElementVNode("span", null, "◇", -1)),
89
+ createTextVNode(toDisplayString(__props.data.serviceCount), 1)
90
+ ], 8, _hoisted_10)) : createCommentVNode("", true)
91
+ ])) : createCommentVNode("", true)
92
+ ])
93
+ ], 6);
94
+ };
95
+ }
96
+ });
97
+ export {
98
+ _sfc_main as _
99
+ };
@@ -0,0 +1,136 @@
1
+ import { defineComponent, computed, useSlots, useAttrs, ref, openBlock, createBlock, resolveDynamicComponent, normalizeStyle, normalizeClass, withCtx, createElementVNode, createElementBlock, renderSlot, createCommentVNode, mergeProps, unref } from "vue";
2
+ import { tv } from "tailwind-variants";
3
+ import { useInputFilter } from "../composables/useInputFilter.js";
4
+ import { _ as _sfc_main$1 } from "./LpFormField-Bn-ZwC6z.js";
5
+ import { _ as _sfc_main$2 } from "./LpIcon-CCnX5_2j.js";
6
+ const _hoisted_1 = {
7
+ key: 0,
8
+ class: "flex shrink-0 items-center text-muted"
9
+ };
10
+ const _hoisted_2 = ["type", "value", "placeholder", "disabled", "aria-invalid"];
11
+ const __default__ = { inheritAttrs: false };
12
+ const _sfc_main = /* @__PURE__ */ defineComponent({
13
+ ...__default__,
14
+ __name: "LpInput",
15
+ props: {
16
+ modelValue: {},
17
+ size: { default: "md" },
18
+ invalid: { type: Boolean },
19
+ placeholder: {},
20
+ type: { default: "text" },
21
+ disabled: { type: Boolean },
22
+ label: {},
23
+ hint: {},
24
+ error: {},
25
+ icon: {},
26
+ pattern: {},
27
+ restrict: {}
28
+ },
29
+ emits: ["update:modelValue"],
30
+ setup(__props, { expose: __expose }) {
31
+ const shell = tv({
32
+ base: [
33
+ "flex w-full items-center bg-surface-soft text-ink",
34
+ "rounded-control border border-line",
35
+ "transition-colors duration-[var(--duration-fast)]",
36
+ "focus-within:border-brand focus-within:ring-2 focus-within:ring-ring",
37
+ "has-[:disabled]:cursor-not-allowed has-[:disabled]:opacity-55"
38
+ ],
39
+ variants: {
40
+ size: {
41
+ sm: "h-(--size-control-sm) text-xs",
42
+ md: "h-(--size-control-md) text-sm",
43
+ lg: "h-(--size-control-lg) text-sm"
44
+ },
45
+ invalid: {
46
+ true: "border-danger focus-within:border-danger focus-within:ring-danger-soft"
47
+ }
48
+ },
49
+ defaultVariants: { size: "md" }
50
+ });
51
+ const padX = { sm: "px-2.5", md: "px-3", lg: "px-3.5" };
52
+ const props = __props;
53
+ const { isInvalid, onBeforeInput, onPaste } = useInputFilter({
54
+ pattern: () => props.pattern,
55
+ restrict: () => props.restrict
56
+ });
57
+ const patternInvalid = computed(() => isInvalid(props.modelValue));
58
+ const slots = useSlots();
59
+ const attrs = useAttrs();
60
+ const hasLeading = computed(() => !!slots.leading || !!props.icon);
61
+ const hasTrailing = computed(() => !!slots.trailing);
62
+ const hasField = computed(
63
+ () => !!props.label || !!props.hint || !!props.error
64
+ );
65
+ const isInvalidState = computed(
66
+ () => props.invalid || !!props.error || patternInvalid.value
67
+ );
68
+ const shellClass = computed(
69
+ () => shell({ size: props.size, invalid: isInvalidState.value })
70
+ );
71
+ const rootClass = computed(() => attrs.class);
72
+ const rootStyle = computed(() => attrs.style);
73
+ const inputAttrs = computed(() => {
74
+ const { class: _c, style: _s, ...rest } = attrs;
75
+ return rest;
76
+ });
77
+ const inputEl = ref(null);
78
+ __expose({
79
+ focus: (options) => inputEl.value?.focus(options),
80
+ blur: () => inputEl.value?.blur(),
81
+ select: () => inputEl.value?.select(),
82
+ input: inputEl
83
+ });
84
+ return (_ctx, _cache) => {
85
+ return openBlock(), createBlock(resolveDynamicComponent(hasField.value ? _sfc_main$1 : "div"), {
86
+ label: hasField.value ? __props.label : void 0,
87
+ hint: hasField.value ? __props.hint : void 0,
88
+ error: hasField.value ? __props.error : void 0,
89
+ class: normalizeClass(hasField.value ? rootClass.value : void 0),
90
+ style: normalizeStyle(hasField.value ? rootStyle.value : void 0)
91
+ }, {
92
+ default: withCtx(() => [
93
+ createElementVNode("div", {
94
+ class: normalizeClass([shellClass.value, hasLeading.value ? "pl-2.5" : "", hasTrailing.value ? "pr-1.5" : "", hasField.value ? "" : rootClass.value]),
95
+ style: normalizeStyle(hasField.value ? void 0 : rootStyle.value)
96
+ }, [
97
+ hasLeading.value ? (openBlock(), createElementBlock("span", _hoisted_1, [
98
+ renderSlot(_ctx.$slots, "leading", {}, () => [
99
+ __props.icon ? (openBlock(), createBlock(_sfc_main$2, {
100
+ key: 0,
101
+ name: __props.icon,
102
+ size: 16
103
+ }, null, 8, ["name"])) : createCommentVNode("", true)
104
+ ])
105
+ ])) : createCommentVNode("", true),
106
+ createElementVNode("input", mergeProps({
107
+ ref_key: "inputEl",
108
+ ref: inputEl
109
+ }, inputAttrs.value, {
110
+ type: __props.type,
111
+ value: __props.modelValue,
112
+ placeholder: __props.placeholder,
113
+ disabled: __props.disabled,
114
+ "aria-invalid": isInvalidState.value || void 0,
115
+ class: [
116
+ "min-w-0 flex-1 bg-transparent outline-none placeholder:text-muted",
117
+ hasLeading.value ? "pl-2" : padX[__props.size ?? "md"],
118
+ hasTrailing.value ? "" : padX[__props.size ?? "md"]
119
+ ],
120
+ onBeforeinput: _cache[0] || (_cache[0] = //@ts-ignore
121
+ (...args) => unref(onBeforeInput) && unref(onBeforeInput)(...args)),
122
+ onPaste: _cache[1] || (_cache[1] = //@ts-ignore
123
+ (...args) => unref(onPaste) && unref(onPaste)(...args)),
124
+ onInput: _cache[2] || (_cache[2] = ($event) => _ctx.$emit("update:modelValue", $event.target.value))
125
+ }), null, 16, _hoisted_2),
126
+ renderSlot(_ctx.$slots, "trailing")
127
+ ], 6)
128
+ ]),
129
+ _: 3
130
+ }, 8, ["label", "hint", "error", "class", "style"]);
131
+ };
132
+ }
133
+ });
134
+ export {
135
+ _sfc_main as _
136
+ };
@@ -0,0 +1,33 @@
1
+ import { defineComponent, openBlock, createElementBlock, normalizeStyle, createElementVNode, toDisplayString } from "vue";
2
+ const _sfc_main = /* @__PURE__ */ defineComponent({
3
+ __name: "LpLaneNode",
4
+ props: {
5
+ data: {}
6
+ },
7
+ setup(__props) {
8
+ const props = __props;
9
+ return (_ctx, _cache) => {
10
+ return openBlock(), createElementBlock("div", {
11
+ class: "pointer-events-none rounded-card border border-dashed",
12
+ style: normalizeStyle({
13
+ width: `${props.data.width}px`,
14
+ height: `${props.data.height}px`,
15
+ borderColor: props.data.accent ?? "var(--color-line)",
16
+ background: "color-mix(in srgb, " + (props.data.accent ?? "var(--color-line-strong)") + " 6%, transparent)"
17
+ })
18
+ }, [
19
+ createElementVNode("div", {
20
+ class: "inline-flex translate-y-[-50%] items-center gap-1.5 rounded-pill border bg-surface px-2.5 py-0.5 text-[11px] font-semibold tracking-wide",
21
+ style: normalizeStyle({
22
+ borderColor: props.data.accent ?? "var(--color-line)",
23
+ color: props.data.accent ?? "var(--color-muted-strong)",
24
+ marginLeft: "14px"
25
+ })
26
+ }, toDisplayString(props.data.label), 5)
27
+ ], 4);
28
+ };
29
+ }
30
+ });
31
+ export {
32
+ _sfc_main as _
33
+ };
@@ -0,0 +1,36 @@
1
+ import { defineComponent, computed, openBlock, createElementBlock, normalizeClass, renderSlot } from "vue";
2
+ const _hoisted_1 = ["href", "target", "rel"];
3
+ const revealClass = "relative after:absolute after:inset-x-0 after:-bottom-0.5 after:h-px after:origin-left after:scale-x-0 after:bg-current after:transition-transform after:duration-[var(--duration-medium)] hover:after:scale-x-100 focus-visible:after:scale-x-100";
4
+ const _sfc_main = /* @__PURE__ */ defineComponent({
5
+ __name: "LpLink",
6
+ props: {
7
+ href: {},
8
+ external: { type: Boolean },
9
+ muted: { type: Boolean },
10
+ variant: { default: "default" }
11
+ },
12
+ setup(__props) {
13
+ const props = __props;
14
+ const rel = computed(() => props.external ? "noopener noreferrer" : void 0);
15
+ const target = computed(() => props.external ? "_blank" : void 0);
16
+ const colorClass = computed(
17
+ () => props.muted ? "text-muted hover:text-ink" : "text-brand hover:text-brand-hover"
18
+ );
19
+ return (_ctx, _cache) => {
20
+ return openBlock(), createElementBlock("a", {
21
+ href: __props.href,
22
+ target: target.value,
23
+ rel: rel.value,
24
+ class: normalizeClass(["inline-flex items-center gap-1 underline-offset-2 outline-none transition-colors focus-visible:ring-2 focus-visible:ring-ring", [
25
+ colorClass.value,
26
+ __props.variant === "reveal" ? revealClass : "hover:underline"
27
+ ]])
28
+ }, [
29
+ renderSlot(_ctx.$slots, "default")
30
+ ], 10, _hoisted_1);
31
+ };
32
+ }
33
+ });
34
+ export {
35
+ _sfc_main as _
36
+ };