veloce-vue 0.20.0 → 0.22.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.
Files changed (255) hide show
  1. package/_virtual/_plugin-vue_export-helper.js +9 -0
  2. package/components/Accordion.vue.d.ts +19 -1
  3. package/components/Accordion.vue.js +91 -0
  4. package/components/Accordion.vue2.js +4 -0
  5. package/components/Badge.vue.d.ts +1 -0
  6. package/components/Badge.vue.js +47 -0
  7. package/components/Badge.vue2.js +4 -0
  8. package/components/Button.vue.d.ts +16 -8
  9. package/components/Button.vue.js +7 -0
  10. package/components/Button.vue2.js +114 -0
  11. package/components/Checkbox.vue.d.ts +6 -7
  12. package/components/Checkbox.vue.js +98 -0
  13. package/components/Checkbox.vue2.js +4 -0
  14. package/components/Chip.vue.d.ts +6 -7
  15. package/components/Chip.vue.js +61 -0
  16. package/components/Chip.vue2.js +4 -0
  17. package/components/Drawer.vue.js +94 -0
  18. package/components/Drawer.vue2.js +4 -0
  19. package/components/Fieldset.vue.d.ts +6 -7
  20. package/components/Fieldset.vue.js +49 -0
  21. package/components/Fieldset.vue2.js +4 -0
  22. package/components/Input.vue.d.ts +11 -12
  23. package/components/Input.vue.js +106 -0
  24. package/components/Input.vue2.js +4 -0
  25. package/components/JsonRenderer.vue.d.ts +14 -0
  26. package/components/JsonRenderer.vue.js +63 -0
  27. package/components/JsonRenderer.vue2.js +4 -0
  28. package/components/Layout.vue.js +83 -0
  29. package/components/Layout.vue2.js +4 -0
  30. package/components/Message.vue.d.ts +97 -8
  31. package/components/Message.vue.js +109 -0
  32. package/components/Message.vue2.js +4 -0
  33. package/components/MiniEditor.vue.d.ts +12 -0
  34. package/components/MiniEditor.vue.js +132 -0
  35. package/components/MiniEditor.vue2.js +4 -0
  36. package/components/Modal.vue.js +73 -0
  37. package/components/Modal.vue2.js +4 -0
  38. package/components/Popover.vue.js +78 -0
  39. package/components/Popover.vue2.js +4 -0
  40. package/components/ProgressBar.vue.js +51 -0
  41. package/components/ProgressBar.vue2.js +4 -0
  42. package/components/ProgressSpinner.vue.js +47 -0
  43. package/components/ProgressSpinner.vue2.js +4 -0
  44. package/components/RangeSlider.vue.js +61 -0
  45. package/components/RangeSlider.vue2.js +4 -0
  46. package/components/Select.vue.js +129 -0
  47. package/components/Select.vue2.js +4 -0
  48. package/components/Separator.vue.d.ts +8 -9
  49. package/components/Separator.vue.js +74 -0
  50. package/components/Separator.vue2.js +4 -0
  51. package/components/Skeleton.vue.d.ts +1 -1
  52. package/components/Skeleton.vue.js +7 -0
  53. package/components/Skeleton.vue2.js +24 -0
  54. package/components/Switch.vue.js +48 -0
  55. package/components/Switch.vue2.js +4 -0
  56. package/components/Tooltip.vue.js +35 -0
  57. package/components/Tooltip.vue2.js +4 -0
  58. package/components/icon/Icon.vue.d.ts +2 -3
  59. package/components/icon/Icon.vue.js +21 -0
  60. package/components/icon/Icon.vue2.js +4 -0
  61. package/components/icon/icons.d.ts +139 -139
  62. package/components/typography/Blockquote.vue.d.ts +151 -0
  63. package/components/typography/Blockquote.vue.js +55 -0
  64. package/components/typography/Blockquote.vue2.js +4 -0
  65. package/components/typography/Code.vue.d.ts +160 -0
  66. package/components/typography/Code.vue.js +74 -0
  67. package/components/typography/Code.vue2.js +4 -0
  68. package/components/typography/H1.vue.d.ts +151 -0
  69. package/components/typography/H1.vue.js +55 -0
  70. package/components/typography/H1.vue2.js +4 -0
  71. package/components/typography/H2.vue.d.ts +151 -0
  72. package/components/typography/H2.vue.js +55 -0
  73. package/components/typography/H2.vue2.js +4 -0
  74. package/components/typography/H3.vue.d.ts +151 -0
  75. package/components/typography/H3.vue.js +55 -0
  76. package/components/typography/H3.vue2.js +4 -0
  77. package/components/typography/H4.vue.d.ts +151 -0
  78. package/components/typography/H4.vue.js +55 -0
  79. package/components/typography/H4.vue2.js +4 -0
  80. package/components/typography/H5.vue.d.ts +151 -0
  81. package/components/typography/H5.vue.js +55 -0
  82. package/components/typography/H5.vue2.js +4 -0
  83. package/components/typography/H6.vue.d.ts +151 -0
  84. package/components/typography/H6.vue.js +55 -0
  85. package/components/typography/H6.vue2.js +4 -0
  86. package/components/typography/Label.vue.d.ts +160 -0
  87. package/components/typography/Label.vue.js +61 -0
  88. package/components/typography/Label.vue2.js +4 -0
  89. package/components/typography/List.vue.d.ts +123 -0
  90. package/components/typography/List.vue.js +60 -0
  91. package/components/typography/List.vue2.js +4 -0
  92. package/components/typography/P.vue.d.ts +151 -0
  93. package/components/typography/P.vue.js +55 -0
  94. package/components/typography/P.vue2.js +4 -0
  95. package/components/typography/Span.vue.d.ts +151 -0
  96. package/components/typography/Span.vue.js +55 -0
  97. package/components/typography/Span.vue2.js +4 -0
  98. package/config.js +2 -14
  99. package/exports/composables.d.ts +1 -0
  100. package/exports/icons.d.ts +2 -1
  101. package/exports/toast.d.ts +4 -0
  102. package/exports/types.d.ts +56 -3
  103. package/exports/typography.d.ts +12 -0
  104. package/exports/ui.d.ts +2 -0
  105. package/exports/utils.d.ts +3 -0
  106. package/icons/Alert.vue.js +31 -0
  107. package/icons/AlertCircle.vue.js +31 -0
  108. package/icons/Archive.vue.js +33 -0
  109. package/icons/ArrowDown.vue.js +26 -0
  110. package/icons/ArrowLeft.vue.js +26 -0
  111. package/icons/ArrowRight.vue.js +26 -0
  112. package/icons/ArrowUp.vue.js +26 -0
  113. package/icons/AtSign.vue.js +30 -0
  114. package/icons/Bell.vue.js +26 -0
  115. package/icons/Bold.vue.js +20 -0
  116. package/icons/Bookmark.vue.js +25 -0
  117. package/icons/Camera.vue.js +30 -0
  118. package/icons/Check.vue.js +20 -0
  119. package/icons/CheckCircle.vue.js +26 -0
  120. package/icons/CheckSquare.vue.js +26 -0
  121. package/icons/ChevronDown.vue.js +20 -0
  122. package/icons/ChevronLeft.vue.js +25 -0
  123. package/icons/ChevronRight.vue.js +25 -0
  124. package/icons/ChevronUp.vue.js +25 -0
  125. package/icons/Circle.vue.js +29 -0
  126. package/icons/Clock.vue.js +30 -0
  127. package/icons/Close.vue.js +20 -0
  128. package/icons/Cloud.vue.js +25 -0
  129. package/icons/CloudDownload.vue.js +27 -0
  130. package/icons/CloudUpload.vue.js +27 -0
  131. package/icons/Code.vue.js +26 -0
  132. package/icons/Command.vue.js +26 -0
  133. package/icons/Copy.vue.js +33 -0
  134. package/icons/CreditCard.vue.js +32 -0
  135. package/icons/Database.vue.js +32 -0
  136. package/icons/Download.vue.js +27 -0
  137. package/icons/Edit.vue.js +26 -0
  138. package/icons/ExternalLink.vue.js +27 -0
  139. package/icons/Eye.vue.js +30 -0
  140. package/icons/EyeOff.vue.js +26 -0
  141. package/icons/FastForward.vue.js +26 -0
  142. package/icons/File.vue.js +26 -0
  143. package/icons/FileAudio.vue.js +17 -0
  144. package/icons/FileImage.vue.js +27 -0
  145. package/icons/FilePdf.vue.js +17 -0
  146. package/icons/FileText.vue.js +17 -0
  147. package/icons/FileVideo.vue.js +27 -0
  148. package/icons/FileZip.vue.js +17 -0
  149. package/icons/Filter.vue.js +25 -0
  150. package/icons/Folder.vue.js +25 -0
  151. package/icons/FolderOpen.vue.js +25 -0
  152. package/icons/FolderPlus.vue.js +27 -0
  153. package/icons/Grid.vue.js +33 -0
  154. package/icons/Hamburger.vue.js +24 -0
  155. package/icons/Hash.vue.js +17 -0
  156. package/icons/Heart.vue.js +25 -0
  157. package/icons/HelpCircle.vue.js +31 -0
  158. package/icons/Highlight.vue.js +20 -0
  159. package/icons/Home.vue.js +26 -0
  160. package/icons/Image.vue.js +38 -0
  161. package/icons/Inbox.vue.js +26 -0
  162. package/icons/Info.vue.js +31 -0
  163. package/icons/Italic.vue.js +24 -0
  164. package/icons/Key.vue.js +31 -0
  165. package/icons/Layout.vue.js +33 -0
  166. package/icons/Link.vue.js +26 -0
  167. package/icons/Link2.vue.js +27 -0
  168. package/icons/List.vue.js +17 -0
  169. package/icons/Loading.vue.js +33 -0
  170. package/icons/Lock.vue.js +33 -0
  171. package/icons/LogIn.vue.js +27 -0
  172. package/icons/LogOut.vue.js +27 -0
  173. package/icons/Mail.vue.js +32 -0
  174. package/icons/Maximize.vue.js +25 -0
  175. package/icons/Menu.vue.js +42 -0
  176. package/icons/MessageCircle.vue.js +25 -0
  177. package/icons/MessageSquare.vue.js +25 -0
  178. package/icons/Mic.vue.js +17 -0
  179. package/icons/MicOff.vue.js +17 -0
  180. package/icons/Minimize.vue.js +25 -0
  181. package/icons/Minus.vue.js +25 -0
  182. package/icons/Moon.vue.js +24 -0
  183. package/icons/MoreHorizontal.vue.js +39 -0
  184. package/icons/MoreVertical.vue.js +39 -0
  185. package/icons/Move.vue.js +17 -0
  186. package/icons/Package.vue.js +17 -0
  187. package/icons/Paperclip.vue.js +25 -0
  188. package/icons/Pause.vue.js +36 -0
  189. package/icons/Phone.vue.js +25 -0
  190. package/icons/Play.vue.js +25 -0
  191. package/icons/Plus.vue.js +26 -0
  192. package/icons/Printer.vue.js +27 -0
  193. package/icons/RadioButton.vue.js +34 -0
  194. package/icons/RefreshCw.vue.js +17 -0
  195. package/icons/Repeat.vue.js +17 -0
  196. package/icons/Rewind.vue.js +26 -0
  197. package/icons/RotateCcw.vue.js +26 -0
  198. package/icons/RotateCw.vue.js +26 -0
  199. package/icons/Save.vue.js +26 -0
  200. package/icons/Scissors.vue.js +17 -0
  201. package/icons/Search.vue.js +30 -0
  202. package/icons/Send.vue.js +26 -0
  203. package/icons/Server.vue.js +17 -0
  204. package/icons/Settings.vue.js +30 -0
  205. package/icons/Share.vue.js +27 -0
  206. package/icons/Shield.vue.js +25 -0
  207. package/icons/Shuffle.vue.js +17 -0
  208. package/icons/Sidebar.vue.js +32 -0
  209. package/icons/SkipBack.vue.js +31 -0
  210. package/icons/SkipForward.vue.js +31 -0
  211. package/icons/Slider.vue.js +17 -0
  212. package/icons/Sliders.vue.js +17 -0
  213. package/icons/SortAsc.vue.js +17 -0
  214. package/icons/SortDesc.vue.js +17 -0
  215. package/icons/Square.vue.js +31 -0
  216. package/icons/Star.vue.js +25 -0
  217. package/icons/Stop.vue.js +31 -0
  218. package/icons/Sun.vue.js +20 -0
  219. package/icons/Tag.vue.js +31 -0
  220. package/icons/Tags.vue.js +27 -0
  221. package/icons/Terminal.vue.js +31 -0
  222. package/icons/ThumbsDown.vue.js +26 -0
  223. package/icons/ThumbsUp.vue.js +26 -0
  224. package/icons/ToggleLeft.vue.js +36 -0
  225. package/icons/ToggleRight.vue.js +36 -0
  226. package/icons/Trash.vue.js +27 -0
  227. package/icons/Trash2.vue.js +17 -0
  228. package/icons/Unlink.vue.js +17 -0
  229. package/icons/Unlock.vue.js +33 -0
  230. package/icons/Upload.vue.js +27 -0
  231. package/icons/User.vue.js +30 -0
  232. package/icons/Users.vue.js +31 -0
  233. package/icons/Video.vue.js +32 -0
  234. package/icons/VideoOff.vue.js +27 -0
  235. package/icons/Volume.vue.js +26 -0
  236. package/icons/Volume1.vue.js +26 -0
  237. package/icons/Volume2.vue.js +26 -0
  238. package/icons/VolumeMute.vue.js +25 -0
  239. package/icons/VolumeX.vue.js +27 -0
  240. package/icons/X.vue.js +26 -0
  241. package/icons/XCircle.vue.js +31 -0
  242. package/icons/Zap.vue.js +25 -0
  243. package/icons/ZoomIn.vue.js +17 -0
  244. package/icons/ZoomOut.vue.js +31 -0
  245. package/icons.js +280 -4
  246. package/package.json +6 -1
  247. package/ui.js +45 -7352
  248. package/utils/config.js +16 -0
  249. package/utils/margin.js +77 -0
  250. package/utils/padding.js +77 -0
  251. package/utils/typography.js +66 -0
  252. package/utils/useRandomId.js +10 -0
  253. package/veloce.css +1 -1
  254. package/components/icon/index.d.ts +0 -6
  255. package/index-Cqxg4hfC.js +0 -2928
@@ -0,0 +1,4 @@
1
+ import f from "./Chip.vue.js";
2
+ export {
3
+ f as default
4
+ };
@@ -0,0 +1,94 @@
1
+ import { defineComponent as v, mergeModels as h, useModel as g, computed as n, createElementBlock as d, openBlock as u, Fragment as w, createElementVNode as o, renderSlot as i, normalizeClass as f, createCommentVNode as x, createVNode as k, toDisplayString as c, unref as m } from "vue";
2
+ /* empty css */
3
+ import y from "../icons/Close.vue.js";
4
+ import "motion-v";
5
+ import C from "./Button.vue.js";
6
+ import "@vueuse/core";
7
+ /* empty css */
8
+ const V = { class: "border-b p-2" }, $ = { class: "flex items-center justify-between gap-2" }, B = { class: "text-[0.95em] font-medium" }, S = { class: "text-muted text-sm" }, z = { class: "size-full overflow-auto p-2" }, F = {
9
+ key: 0,
10
+ class: "border-t p-2"
11
+ }, q = /* @__PURE__ */ v({
12
+ __name: "Drawer",
13
+ props: /* @__PURE__ */ h({
14
+ direction: { type: String, default: "bottom", options: ["left", "bottom", "right"] },
15
+ title: { type: String, default: "" },
16
+ description: { type: String, default: "" },
17
+ showFooter: { type: Boolean, default: !1 },
18
+ show: { type: Boolean, default: !1 }
19
+ }, {
20
+ modelValue: {},
21
+ modelModifiers: {}
22
+ }),
23
+ emits: ["update:modelValue"],
24
+ setup(s) {
25
+ const r = s, t = g(s, "modelValue"), p = n(() => {
26
+ let e = "";
27
+ switch (r.direction) {
28
+ case "left":
29
+ e = t.value ? "fixed top-0 left-0 bottom-0" : "fixed top-0 -left-full bottom-0";
30
+ break;
31
+ case "bottom":
32
+ e = t.value ? "fixed left-0 bottom-0 right-0" : "fixed left-0 right-0 -bottom-full";
33
+ break;
34
+ case "right":
35
+ e = t.value ? "fixed top-0 right-0 bottom-0" : "fixed top-0 -right-full bottom-0";
36
+ break;
37
+ default:
38
+ alert("Invalid direction");
39
+ }
40
+ return e;
41
+ }), b = n(() => {
42
+ let e = "";
43
+ switch (r.direction) {
44
+ case "left":
45
+ e = "w-full max-w-[22.5rem]";
46
+ break;
47
+ case "bottom":
48
+ e = "w-full h-full max-h-[90dvh]";
49
+ break;
50
+ case "right":
51
+ e = "w-full max-w-[22.5rem]";
52
+ break;
53
+ }
54
+ return e;
55
+ });
56
+ return (e, l) => (u(), d(w, null, [
57
+ o("div", {
58
+ onClick: l[0] || (l[0] = (a) => t.value = !t.value)
59
+ }, [
60
+ i(e.$slots, "default")
61
+ ]),
62
+ o("div", {
63
+ class: f([[p.value, b.value], "bg-background z-51 flex flex-col justify-between duration-300"])
64
+ }, [
65
+ o("div", V, [
66
+ o("div", $, [
67
+ o("h4", B, c(s.title), 1),
68
+ k(m(C), {
69
+ icon: m(y),
70
+ class: "p-1!",
71
+ circle: "",
72
+ variant: "ghost",
73
+ onClick: l[1] || (l[1] = (a) => t.value = !1)
74
+ }, null, 8, ["icon"])
75
+ ]),
76
+ o("p", S, c(s.description), 1)
77
+ ]),
78
+ o("div", z, [
79
+ i(e.$slots, "content")
80
+ ]),
81
+ s.showFooter ? (u(), d("div", F, [
82
+ i(e.$slots, "footer")
83
+ ])) : x("", !0)
84
+ ], 2),
85
+ o("div", {
86
+ class: f([t.value ? "opacity-100" : "pointer-events-none", "fixed inset-0 z-50 bg-black/40 opacity-0 duration-200"]),
87
+ onClick: l[2] || (l[2] = (a) => t.value = !1)
88
+ }, null, 2)
89
+ ], 64));
90
+ }
91
+ });
92
+ export {
93
+ q as default
94
+ };
@@ -0,0 +1,4 @@
1
+ import f from "./Drawer.vue.js";
2
+ export {
3
+ f as default
4
+ };
@@ -1,5 +1,4 @@
1
- import { Icons } from '../exports/icons';
2
- import { DefineComponent, ExtractPropTypes, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
1
+ import { Component, DefineComponent, ExtractPropTypes, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
3
2
  declare function __VLS_template(): {
4
3
  attrs: Partial<{}>;
5
4
  slots: {
@@ -15,8 +14,8 @@ declare const __VLS_component: DefineComponent<ExtractPropTypes<{
15
14
  default: string;
16
15
  };
17
16
  icon: {
18
- type: () => Icons;
19
- default: string;
17
+ type: () => Component;
18
+ default: () => null;
20
19
  };
21
20
  toggleable: {
22
21
  type: BooleanConstructor;
@@ -34,8 +33,8 @@ declare const __VLS_component: DefineComponent<ExtractPropTypes<{
34
33
  default: string;
35
34
  };
36
35
  icon: {
37
- type: () => Icons;
38
- default: string;
36
+ type: () => Component;
37
+ default: () => null;
39
38
  };
40
39
  toggleable: {
41
40
  type: BooleanConstructor;
@@ -49,7 +48,7 @@ declare const __VLS_component: DefineComponent<ExtractPropTypes<{
49
48
  "onUpdate:collapsed"?: ((value: boolean) => any) | undefined;
50
49
  }>, {
51
50
  legend: string;
52
- icon: "filter" | "code" | "link" | "menu" | "video" | "circle" | "image" | "stop" | "square" | "x" | "alert" | "alert-circle" | "archive" | "arrow-down" | "arrow-left" | "arrow-right" | "arrow-up" | "at-sign" | "bell" | "bookmark" | "camera" | "check" | "check-circle" | "check-square" | "chevron-down" | "chevron-left" | "chevron-right" | "chevron-up" | "clock" | "close" | "cloud" | "cloud-download" | "cloud-upload" | "command" | "copy" | "credit-card" | "database" | "download" | "edit" | "external-link" | "eye" | "eye-off" | "fast-forward" | "file" | "file-audio" | "file-image" | "file-pdf" | "file-text" | "file-video" | "file-zip" | "folder" | "folder-open" | "folder-plus" | "grid" | "hamburger" | "hash" | "heart" | "help-circle" | "home" | "inbox" | "info" | "key" | "layout" | "link-2" | "list" | "loading" | "lock" | "log-in" | "log-out" | "mail" | "maximize" | "message-circle" | "message-square" | "mic" | "mic-off" | "minimize" | "minus" | "moon" | "more-horizontal" | "more-vertical" | "move" | "package" | "paperclip" | "pause" | "phone" | "play" | "plus" | "printer" | "radio-button" | "refresh-cw" | "repeat" | "rewind" | "rotate-ccw" | "rotate-cw" | "save" | "scissors" | "search" | "send" | "server" | "settings" | "share" | "shield" | "shuffle" | "sidebar" | "skip-back" | "skip-forward" | "slider" | "sliders" | "sort-asc" | "sort-desc" | "star" | "sun" | "tag" | "tags" | "terminal" | "thumbs-down" | "thumbs-up" | "toggle-left" | "toggle-right" | "trash" | "trash-2" | "unlink" | "unlock" | "upload" | "user" | "users" | "video-off" | "volume" | "volume-1" | "volume-2" | "volume-mute" | "volume-x" | "x-circle" | "zap" | "zoom-in" | "zoom-out";
51
+ icon: Component;
53
52
  toggleable: boolean;
54
53
  collapsed: boolean;
55
54
  }, {}, {}, {}, string, ComponentProvideOptions, true, {}, HTMLFieldSetElement>;
@@ -0,0 +1,49 @@
1
+ import { defineComponent as p, mergeModels as f, useModel as g, createElementBlock as a, openBlock as l, createCommentVNode as t, normalizeClass as r, createBlock as c, createElementVNode as m, unref as s, toDisplayString as b, renderSlot as y } from "vue";
2
+ import k from "../icons/ChevronDown.vue.js";
3
+ import d from "./icon/Icon.vue.js";
4
+ const _ = { class: "border-border bg-background w-full rounded border p-4" }, C = {
5
+ key: 1,
6
+ class: "mt-2"
7
+ }, z = /* @__PURE__ */ p({
8
+ __name: "Fieldset",
9
+ props: /* @__PURE__ */ f({
10
+ legend: { type: String, default: "" },
11
+ icon: { type: Object, default: () => null },
12
+ toggleable: { type: Boolean, default: !1 },
13
+ collapsed: { type: Boolean, default: !1 }
14
+ }, {
15
+ collapsed: { type: Boolean, default: !1 },
16
+ collapsedModifiers: {}
17
+ }),
18
+ emits: ["update:collapsed"],
19
+ setup(n) {
20
+ const e = n, o = g(n, "collapsed"), i = () => {
21
+ e.toggleable && (o.value = !o.value);
22
+ };
23
+ return (u, v) => (l(), a("fieldset", _, [
24
+ e.legend || e.icon || e.toggleable ? (l(), a("legend", {
25
+ key: 0,
26
+ class: r([{ "cursor-pointer": e.toggleable }, "flex items-center gap-2 px-2 text-sm font-semibold"]),
27
+ onClick: i
28
+ }, [
29
+ e.icon ? (l(), c(s(d), {
30
+ key: 0,
31
+ icon: e.icon,
32
+ class: "size-4"
33
+ }, null, 8, ["icon"])) : t("", !0),
34
+ m("span", null, b(e.legend), 1),
35
+ e.toggleable ? (l(), c(s(d), {
36
+ key: 1,
37
+ icon: s(k),
38
+ class: r([{ "rotate-180": !o.value }, "size-4 transition-transform duration-200"])
39
+ }, null, 8, ["icon", "class"])) : t("", !0)
40
+ ], 2)) : t("", !0),
41
+ !o.value || !e.toggleable ? (l(), a("div", C, [
42
+ y(u.$slots, "default")
43
+ ])) : t("", !0)
44
+ ]));
45
+ }
46
+ });
47
+ export {
48
+ z as default
49
+ };
@@ -0,0 +1,4 @@
1
+ import f from "./Fieldset.vue.js";
2
+ export {
3
+ f as default
4
+ };
@@ -1,14 +1,13 @@
1
- import { Icons } from '../exports/icons';
1
+ import { Component, DefineComponent, ExtractPropTypes, PropType, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
2
2
  import { Size } from '../exports/types';
3
- import { DefineComponent, ExtractPropTypes, PropType, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
4
3
  declare const _default: DefineComponent<ExtractPropTypes<{
5
4
  leadingIcon: {
6
- type: () => Icons;
7
- default: string;
5
+ type: () => Component;
6
+ default: () => null;
8
7
  };
9
8
  trailingIcon: {
10
- type: () => Icons;
11
- default: string;
9
+ type: () => Component;
10
+ default: () => null;
12
11
  };
13
12
  placeholder: {
14
13
  type: StringConstructor;
@@ -45,12 +44,12 @@ declare const _default: DefineComponent<ExtractPropTypes<{
45
44
  "update:modelValue": (value: any) => any;
46
45
  }, string, PublicProps, Readonly< ExtractPropTypes<{
47
46
  leadingIcon: {
48
- type: () => Icons;
49
- default: string;
47
+ type: () => Component;
48
+ default: () => null;
50
49
  };
51
50
  trailingIcon: {
52
- type: () => Icons;
53
- default: string;
51
+ type: () => Component;
52
+ default: () => null;
54
53
  };
55
54
  placeholder: {
56
55
  type: StringConstructor;
@@ -91,8 +90,8 @@ declare const _default: DefineComponent<ExtractPropTypes<{
91
90
  size: Size;
92
91
  placeholder: string;
93
92
  iconClass: string;
94
- leadingIcon: "filter" | "code" | "link" | "menu" | "video" | "circle" | "image" | "stop" | "square" | "x" | "alert" | "alert-circle" | "archive" | "arrow-down" | "arrow-left" | "arrow-right" | "arrow-up" | "at-sign" | "bell" | "bookmark" | "camera" | "check" | "check-circle" | "check-square" | "chevron-down" | "chevron-left" | "chevron-right" | "chevron-up" | "clock" | "close" | "cloud" | "cloud-download" | "cloud-upload" | "command" | "copy" | "credit-card" | "database" | "download" | "edit" | "external-link" | "eye" | "eye-off" | "fast-forward" | "file" | "file-audio" | "file-image" | "file-pdf" | "file-text" | "file-video" | "file-zip" | "folder" | "folder-open" | "folder-plus" | "grid" | "hamburger" | "hash" | "heart" | "help-circle" | "home" | "inbox" | "info" | "key" | "layout" | "link-2" | "list" | "loading" | "lock" | "log-in" | "log-out" | "mail" | "maximize" | "message-circle" | "message-square" | "mic" | "mic-off" | "minimize" | "minus" | "moon" | "more-horizontal" | "more-vertical" | "move" | "package" | "paperclip" | "pause" | "phone" | "play" | "plus" | "printer" | "radio-button" | "refresh-cw" | "repeat" | "rewind" | "rotate-ccw" | "rotate-cw" | "save" | "scissors" | "search" | "send" | "server" | "settings" | "share" | "shield" | "shuffle" | "sidebar" | "skip-back" | "skip-forward" | "slider" | "sliders" | "sort-asc" | "sort-desc" | "star" | "sun" | "tag" | "tags" | "terminal" | "thumbs-down" | "thumbs-up" | "toggle-left" | "toggle-right" | "trash" | "trash-2" | "unlink" | "unlock" | "upload" | "user" | "users" | "video-off" | "volume" | "volume-1" | "volume-2" | "volume-mute" | "volume-x" | "x-circle" | "zap" | "zoom-in" | "zoom-out";
95
- trailingIcon: "filter" | "code" | "link" | "menu" | "video" | "circle" | "image" | "stop" | "square" | "x" | "alert" | "alert-circle" | "archive" | "arrow-down" | "arrow-left" | "arrow-right" | "arrow-up" | "at-sign" | "bell" | "bookmark" | "camera" | "check" | "check-circle" | "check-square" | "chevron-down" | "chevron-left" | "chevron-right" | "chevron-up" | "clock" | "close" | "cloud" | "cloud-download" | "cloud-upload" | "command" | "copy" | "credit-card" | "database" | "download" | "edit" | "external-link" | "eye" | "eye-off" | "fast-forward" | "file" | "file-audio" | "file-image" | "file-pdf" | "file-text" | "file-video" | "file-zip" | "folder" | "folder-open" | "folder-plus" | "grid" | "hamburger" | "hash" | "heart" | "help-circle" | "home" | "inbox" | "info" | "key" | "layout" | "link-2" | "list" | "loading" | "lock" | "log-in" | "log-out" | "mail" | "maximize" | "message-circle" | "message-square" | "mic" | "mic-off" | "minimize" | "minus" | "moon" | "more-horizontal" | "more-vertical" | "move" | "package" | "paperclip" | "pause" | "phone" | "play" | "plus" | "printer" | "radio-button" | "refresh-cw" | "repeat" | "rewind" | "rotate-ccw" | "rotate-cw" | "save" | "scissors" | "search" | "send" | "server" | "settings" | "share" | "shield" | "shuffle" | "sidebar" | "skip-back" | "skip-forward" | "slider" | "sliders" | "sort-asc" | "sort-desc" | "star" | "sun" | "tag" | "tags" | "terminal" | "thumbs-down" | "thumbs-up" | "toggle-left" | "toggle-right" | "trash" | "trash-2" | "unlink" | "unlock" | "upload" | "user" | "users" | "video-off" | "volume" | "volume-1" | "volume-2" | "volume-mute" | "volume-x" | "x-circle" | "zap" | "zoom-in" | "zoom-out";
93
+ leadingIcon: Component;
94
+ trailingIcon: Component;
96
95
  helpText: string;
97
96
  labelStyle: "float" | "static";
98
97
  }, {}, {}, {}, string, ComponentProvideOptions, true, {}, HTMLDivElement>;
@@ -0,0 +1,106 @@
1
+ import { defineComponent as h, mergeModels as z, useModel as I, ref as b, computed as k, createElementBlock as u, openBlock as a, createCommentVNode as o, createElementVNode as x, unref as n, toDisplayString as f, normalizeClass as s, createBlock as g, withDirectives as w, vModelDynamic as S, createVNode as V } from "vue";
2
+ import { useRandomId as C } from "../utils/useRandomId.js";
3
+ import L from "../icons/Eye.vue.js";
4
+ import $ from "../icons/EyeOff.vue.js";
5
+ import y from "./icon/Icon.vue.js";
6
+ const B = {
7
+ key: 0,
8
+ class: "mb-2 pl-0.5"
9
+ }, E = ["for"], M = ["type", "id", "placeholder"], T = {
10
+ key: 1,
11
+ class: "text-muted ml-1 pt-1 text-xs"
12
+ }, R = /* @__PURE__ */ h({
13
+ __name: "Input",
14
+ props: /* @__PURE__ */ z({
15
+ leadingIcon: { type: Object, default: () => null },
16
+ trailingIcon: { type: Object, default: () => null },
17
+ placeholder: { type: String, default: "" },
18
+ iconClass: { type: String, default: "" },
19
+ helpText: { type: String, default: "" },
20
+ type: { type: String, default: "text" },
21
+ labelStyle: { type: String, default: "static" },
22
+ label: { type: String, default: "" },
23
+ size: { type: String, default: "md" }
24
+ }, {
25
+ modelValue: {},
26
+ modelModifiers: {}
27
+ }),
28
+ emits: ["update:modelValue"],
29
+ setup(e) {
30
+ const p = C(), t = e, d = I(e, "modelValue"), c = b(!1), r = b(!1), v = () => c.value = !c.value, l = k(() => {
31
+ switch (t.size) {
32
+ case "sm":
33
+ return { container: "h-[30px]", input: "px-2 py-1 text-sm", icon: "size-4", text: "text-sm", floatLabel: { focus: "text-xs", base: "text-sm" } };
34
+ case "md":
35
+ return { container: "h-[34px]", input: "px-2.5 py-1.5 text-sm", icon: "size-4", text: "text-sm", floatLabel: { focus: "text-xs", base: "text-sm" } };
36
+ case "lg":
37
+ return { container: "h-[42px]", input: "px-3 py-2 text-base", icon: "size-5", text: "text-base", floatLabel: { focus: "text-sm", base: "text-base" } };
38
+ case "xl":
39
+ return { container: "h-[50px]", input: "px-3.5 py-2.5 text-lg", icon: "size-6", text: "text-lg", floatLabel: { focus: "text-sm", base: "text-lg" } };
40
+ }
41
+ });
42
+ return (D, i) => (a(), u("div", null, [
43
+ e.labelStyle === "static" && e.label ? (a(), u("div", B, [
44
+ x("label", {
45
+ class: "text-sm font-medium duration-100",
46
+ for: n(p)
47
+ }, f(e.label), 9, E)
48
+ ])) : o("", !0),
49
+ x("div", {
50
+ class: s([[{ "mb-6": e.helpText }, l.value.container], "relative"])
51
+ }, [
52
+ e.leadingIcon ? (a(), g(n(y), {
53
+ key: 0,
54
+ icon: e.leadingIcon,
55
+ class: s([[l.value.icon, e.iconClass], "text-muted absolute left-3 top-1/2 -translate-y-1/2"])
56
+ }, null, 8, ["icon", "class"])) : o("", !0),
57
+ e.trailingIcon ? (a(), g(n(y), {
58
+ key: 1,
59
+ icon: e.trailingIcon,
60
+ class: s([[l.value.icon, e.iconClass], "text-muted absolute right-3 top-1/2 -translate-y-1/2"])
61
+ }, null, 8, ["icon", "class"])) : o("", !0),
62
+ w(x("input", {
63
+ type: e.type === "password" && c.value ? "text" : e.type,
64
+ "onUpdate:modelValue": i[0] || (i[0] = (m) => d.value = m),
65
+ class: s([[
66
+ l.value.input,
67
+ l.value.text,
68
+ { "pr-12": t.type === "password" },
69
+ { "pl-10": e.leadingIcon && t.size === "md" },
70
+ { "pl-9": e.leadingIcon && t.size === "sm" },
71
+ { "pl-11": e.leadingIcon && t.size === "lg" },
72
+ { "pl-12": e.leadingIcon && t.size === "xl" },
73
+ { "pr-10": e.trailingIcon && t.type !== "password" && t.size === "md" },
74
+ { "pr-9": e.trailingIcon && t.type !== "password" && t.size === "sm" },
75
+ { "pr-11": e.trailingIcon && t.type !== "password" && t.size === "lg" },
76
+ { "pr-12": e.trailingIcon && t.type !== "password" && t.size === "xl" }
77
+ ], "outline-primary dark:placeholder:text-muted focus:border-primary/75 peer h-full w-full rounded border outline-none duration-200"]),
78
+ id: n(p),
79
+ placeholder: e.labelStyle === "float" ? " " : e.placeholder,
80
+ onFocus: i[1] || (i[1] = (m) => r.value = !0),
81
+ onBlur: i[2] || (i[2] = (m) => r.value = !1)
82
+ }, null, 42, M), [
83
+ [S, d.value]
84
+ ]),
85
+ e.labelStyle === "float" ? (a(), u("div", {
86
+ key: 2,
87
+ class: s([[d.value || r.value ? `-top-1.5 px-0.5 ${l.value.floatLabel.focus}` : `bottom-0 top-0 my-auto ${l.value.floatLabel.base}`], "bg-background dark:text-muted absolute left-2.5 h-fit rounded leading-none text-neutral-400 duration-100"])
88
+ }, f(e.placeholder), 3)) : o("", !0),
89
+ e.type === "password" ? (a(), u("div", {
90
+ key: 3,
91
+ class: "absolute right-4 top-1/2 -translate-y-1/2 cursor-pointer",
92
+ onClick: v
93
+ }, [
94
+ V(n(y), {
95
+ icon: c.value ? n($) : n(L),
96
+ class: s([l.value.icon, "text-muted"])
97
+ }, null, 8, ["icon", "class"])
98
+ ])) : o("", !0)
99
+ ], 2),
100
+ e.helpText ? (a(), u("div", T, f(e.helpText), 1)) : o("", !0)
101
+ ]));
102
+ }
103
+ });
104
+ export {
105
+ R as default
106
+ };
@@ -0,0 +1,4 @@
1
+ import f from "./Input.vue.js";
2
+ export {
3
+ f as default
4
+ };
@@ -0,0 +1,14 @@
1
+ import { JsonRendererItem } from '../exports/types';
2
+ import { DefineComponent, ExtractPropTypes, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
3
+ declare const _default: DefineComponent<ExtractPropTypes<{
4
+ json: {
5
+ type: () => JsonRendererItem[];
6
+ required: true;
7
+ };
8
+ }>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<{
9
+ json: {
10
+ type: () => JsonRendererItem[];
11
+ required: true;
12
+ };
13
+ }>> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, HTMLDivElement>;
14
+ export default _default;
@@ -0,0 +1,63 @@
1
+ import { defineComponent as _, createElementBlock as m, openBlock as r, Fragment as e, renderList as f, createBlock as n, resolveDynamicComponent as p, mergeProps as s, withCtx as c, createTextVNode as a, toDisplayString as l } from "vue";
2
+ import u from "./typography/Blockquote.vue.js";
3
+ import $ from "./typography/Code.vue.js";
4
+ import d from "./typography/H1.vue.js";
5
+ import h from "./typography/H2.vue.js";
6
+ import k from "./typography/H3.vue.js";
7
+ import y from "./typography/H4.vue.js";
8
+ import g from "./typography/H5.vue.js";
9
+ import x from "./typography/H6.vue.js";
10
+ import b from "./typography/Label.vue.js";
11
+ import B from "./typography/List.vue.js";
12
+ import C from "./typography/P.vue.js";
13
+ import j from "./typography/Span.vue.js";
14
+ /* empty css */
15
+ import "motion-v";
16
+ /* empty css */
17
+ import "@vueuse/core";
18
+ import q from "./Message.vue.js";
19
+ /* empty css */
20
+ const v = { class: "*:first:mt-0 *:last:mb-0" }, U = /* @__PURE__ */ _({
21
+ __name: "JsonRenderer",
22
+ props: {
23
+ json: { type: Array, required: !0 }
24
+ },
25
+ setup(i) {
26
+ const t = {
27
+ h1: d,
28
+ h2: h,
29
+ h3: k,
30
+ h4: y,
31
+ h5: g,
32
+ h6: x,
33
+ p: C,
34
+ span: j,
35
+ blockquote: u,
36
+ code: $,
37
+ label: b,
38
+ list: B,
39
+ message: q
40
+ };
41
+ return (D, w) => (r(), m("div", v, [
42
+ (r(!0), m(e, null, f(i.json, (o) => (r(), m(e, {
43
+ key: o.id
44
+ }, [
45
+ o.component === "message" ? (r(), n(p(t[o.component]), s({
46
+ key: 0,
47
+ ref_for: !0
48
+ }, o.props), {
49
+ default: c(() => [
50
+ a(l(o.props?.text), 1)
51
+ ]),
52
+ _: 2
53
+ }, 1040)) : (r(), n(p(t[o.component]), s({
54
+ key: 1,
55
+ ref_for: !0
56
+ }, o.props), null, 16))
57
+ ], 64))), 128))
58
+ ]));
59
+ }
60
+ });
61
+ export {
62
+ U as default
63
+ };
@@ -0,0 +1,4 @@
1
+ import f from "./JsonRenderer.vue.js";
2
+ export {
3
+ f as default
4
+ };
@@ -0,0 +1,83 @@
1
+ import { defineComponent as v, ref as g, onMounted as x, resolveComponent as d, createElementBlock as w, openBlock as a, Fragment as k, createElementVNode as o, createVNode as r, createBlock as m, createCommentVNode as u, unref as e, withCtx as n, toDisplayString as C, renderSlot as f, normalizeClass as S } from "vue";
2
+ /* empty css */
3
+ import y from "../icons/Hamburger.vue.js";
4
+ import { AnimatePresence as N, motion as V } from "motion-v";
5
+ import B from "./Button.vue.js";
6
+ import { useStorage as z } from "@vueuse/core";
7
+ /* empty css */
8
+ const E = { class: "flex h-14 items-center justify-between gap-4 border-b px-4" }, L = { class: "flex items-center gap-2" }, $ = { class: "text-base font-medium" }, j = { class: "header-actions flex items-center gap-2" }, A = { class: "relative h-[calc(100dvh-3.5rem)] overflow-hidden" }, G = /* @__PURE__ */ v({
9
+ __name: "Layout",
10
+ props: {
11
+ brandName: { type: String, default: "VeloceVue" }
12
+ },
13
+ emits: ["sidebar"],
14
+ setup(i, { emit: p }) {
15
+ const h = p, t = z("showSidebar", !1), s = g(!0);
16
+ x(() => setTimeout(() => s.value = !1, 100));
17
+ const l = () => {
18
+ t.value = !t.value, h("sidebar", t.value);
19
+ };
20
+ return (c, D) => {
21
+ const _ = d("router-link"), b = d("router-view");
22
+ return a(), w(k, null, [
23
+ o("header", E, [
24
+ o("div", L, [
25
+ r(e(B), {
26
+ icon: e(y),
27
+ iconClass: "size-6",
28
+ class: "p-1!",
29
+ variant: "soft",
30
+ onClick: l
31
+ }, null, 8, ["icon"]),
32
+ i.brandName ? (a(), m(_, {
33
+ key: 0,
34
+ to: "/"
35
+ }, {
36
+ default: n(() => [
37
+ o("h1", $, C(i.brandName), 1)
38
+ ]),
39
+ _: 1
40
+ })) : u("", !0)
41
+ ]),
42
+ o("div", j, [
43
+ f(c.$slots, "header-actions")
44
+ ])
45
+ ]),
46
+ o("main", A, [
47
+ r(e(N), null, {
48
+ default: n(() => [
49
+ e(t) ? (a(), m(e(V).div, {
50
+ key: 0,
51
+ class: "bg-background absolute bottom-0 left-0 top-0 z-50 w-[240px] shrink-0 overflow-hidden border-r",
52
+ initial: s.value && e(t) ? { x: 0 } : { x: -240 },
53
+ animate: { x: 0 },
54
+ exit: { x: -240 },
55
+ transition: {
56
+ duration: 0.3,
57
+ ease: [0.4, 0, 0.2, 1]
58
+ }
59
+ }, {
60
+ default: n(() => [
61
+ f(c.$slots, "sidebar", {
62
+ showSidebar: e(t),
63
+ onClose: l
64
+ })
65
+ ]),
66
+ _: 3
67
+ }, 8, ["initial"])) : u("", !0)
68
+ ]),
69
+ _: 3
70
+ }),
71
+ o("div", {
72
+ class: S([{ "lg:ml-[240px]": e(t) }, "h-full overflow-auto p-2 transition-[margin-left] duration-300 ease-in-out"])
73
+ }, [
74
+ r(b)
75
+ ], 2)
76
+ ])
77
+ ], 64);
78
+ };
79
+ }
80
+ });
81
+ export {
82
+ G as default
83
+ };
@@ -0,0 +1,4 @@
1
+ import f from "./Layout.vue.js";
2
+ export {
3
+ f as default
4
+ };