vlite3 1.1.2 → 1.1.4

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 (87) hide show
  1. package/components/AttachmentsList/AttachmentsList.vue.d.ts +1 -1
  2. package/components/AttachmentsList/AttachmentsList.vue.js +237 -163
  3. package/components/Avatar.vue.js +1 -1
  4. package/components/AvatarUploader/AvatarUploader.vue.js +40 -37
  5. package/components/Button.vue.js +30 -28
  6. package/components/Carousel/Carousel.vue.d.ts +2 -2
  7. package/components/CategoryManager/CategoryManager.vue.d.ts +10 -2
  8. package/components/CategoryManager/CategoryManager.vue.js +137 -118
  9. package/components/CategoryManager/CategoryNode.vue.d.ts +2 -0
  10. package/components/CategoryManager/CategoryNode.vue.js +93 -88
  11. package/components/Chat/ChatBubble.vue.js +22 -22
  12. package/components/CheckBox.vue.js +29 -28
  13. package/components/CommandPalette/CommandPaletteContent.vue2.js +1 -1
  14. package/components/CommandPalette/{CommandPaletteItem.vue.js → CommandPaletteItem.vue2.js} +1 -1
  15. package/components/ConfirmationModal.vue.js +30 -28
  16. package/components/CopyButton.vue.d.ts +50 -0
  17. package/components/CopyButton.vue.js +69 -0
  18. package/components/CopyButton.vue2.js +4 -0
  19. package/components/DataTable/DataTable.vue.js +44 -44
  20. package/components/DatePicker.vue.js +41 -35
  21. package/components/DateRangePicker.vue.js +18 -17
  22. package/components/Dropdown/Dropdown.vue.d.ts +3 -0
  23. package/components/Dropdown/Dropdown.vue.js +117 -115
  24. package/components/Dropdown/DropdownBooleanItem.vue.js +16 -15
  25. package/components/Dropdown/DropdownItem.vue.js +21 -20
  26. package/components/Dropdown/DropdownMenu.vue.js +1 -1
  27. package/components/Dropdown/DropdownMenu.vue2.js +13 -12
  28. package/components/Dropdown/DropdownTrigger.vue.d.ts +2 -0
  29. package/components/Dropdown/DropdownTrigger.vue.js +10 -6
  30. package/components/Dropdown/composables/useDropdownHydration.d.ts +2 -0
  31. package/components/Dropdown/composables/useDropdownSelection.d.ts +1 -0
  32. package/components/Dropdown/composables/useDropdownSelection.js +46 -31
  33. package/components/FilePicker/FilePicker.vue.js +93 -90
  34. package/components/Form/CustomFields.vue.js +2 -2
  35. package/components/Form/Form.vue.js +2 -2
  36. package/components/Form/Form.vue2.js +68 -64
  37. package/components/Form/FormField.vue.js +204 -148
  38. package/components/Form/FormFields.vue.js +2 -2
  39. package/components/Form/FormFields.vue2.js +28 -27
  40. package/components/Form/types.d.ts +2 -2
  41. package/components/Form/utils/form.utils.d.ts +3 -3
  42. package/components/Form/utils/form.utils.js +37 -37
  43. package/components/Input.vue.js +64 -62
  44. package/components/Invoice/Invoice.vue.js +9 -7
  45. package/components/Invoice/InvoiceTotals.vue.d.ts +14 -0
  46. package/components/Invoice/InvoiceTotals.vue.js +86 -0
  47. package/components/Invoice/InvoiceTotals.vue2.js +4 -0
  48. package/components/Invoice/InvoiceVariant1.vue.d.ts +3 -1
  49. package/components/Invoice/InvoiceVariant1.vue.js +194 -207
  50. package/components/Invoice/InvoiceVariant2.vue.d.ts +3 -1
  51. package/components/Invoice/InvoiceVariant2.vue.js +109 -118
  52. package/components/Invoice/InvoiceVariant3.vue.d.ts +3 -1
  53. package/components/Invoice/InvoiceVariant3.vue.js +157 -167
  54. package/components/Invoice/InvoiceVariant4.vue.d.ts +3 -1
  55. package/components/Invoice/InvoiceVariant4.vue.js +192 -202
  56. package/components/Invoice/index.d.ts +1 -0
  57. package/components/Invoice/types.d.ts +22 -0
  58. package/components/Masonry/Masonry.vue.d.ts +1 -1
  59. package/components/Modal.vue.js +1 -1
  60. package/components/Modal.vue2.js +60 -54
  61. package/components/MultiSelect/MultiSelect.vue.js +47 -46
  62. package/components/MultiSelect/composables/useMultiSelectHydration.d.ts +2 -0
  63. package/components/NavbarCommandPalette.vue.js +1 -1
  64. package/components/NumberInput.vue.js +2 -2
  65. package/components/NumberInput.vue2.js +121 -116
  66. package/components/PricingPlan/PricingPlan.vue.d.ts +1 -1
  67. package/components/SidePanel.vue.js +2 -2
  68. package/components/SidePanel.vue2.js +58 -52
  69. package/components/Stats/StatItem.vue.js +96 -91
  70. package/components/Stats/types.d.ts +1 -0
  71. package/components/Switch.vue.d.ts +6 -1
  72. package/components/Switch.vue.js +61 -24
  73. package/components/TagInput/TagInput.vue.d.ts +187 -0
  74. package/components/TagInput/TagInput.vue.js +113 -0
  75. package/components/TagInput/TagInput.vue2.js +4 -0
  76. package/components/TagInput/index.d.ts +1 -0
  77. package/components/Textarea.vue.js +19 -18
  78. package/components/ThumbnailSelector/ThumbnailSelector.vue.js +2 -2
  79. package/components/ThumbnailSelector/ThumbnailSelector.vue2.js +19 -16
  80. package/core/config.d.ts +36 -0
  81. package/index.d.ts +2 -0
  82. package/index.js +130 -124
  83. package/package.json +1 -1
  84. package/style.css +616 -1
  85. package/types/button.d.ts +1 -1
  86. package/types/styles.d.ts +1 -0
  87. package/utils/functions.js +9 -9
@@ -1,62 +1,76 @@
1
- import { defineComponent as _, computed as b, openBlock as t, createElementBlock as a, normalizeStyle as D, createElementVNode as o, normalizeClass as n, toDisplayString as l, createBlock as T, createCommentVNode as c, createVNode as i, unref as u, createTextVNode as m, Fragment as v, renderList as g } from "vue";
1
+ import { defineComponent as I, computed as x, openBlock as o, createElementBlock as s, normalizeStyle as w, createElementVNode as a, normalizeClass as n, toDisplayString as t, createBlock as D, createCommentVNode as c, createVNode as r, unref as u, createTextVNode as m, Fragment as f, renderList as z } from "vue";
2
2
  import p from "../Price/Price.vue.js";
3
- import k from "../DateTime/DateTime.vue.js";
4
- import z from "../Barcode/Barcode.vue.js";
3
+ import g from "../DateTime/DateTime.vue.js";
4
+ import T from "../Barcode/Barcode.vue.js";
5
5
  import N from "../QRCode/QRCode.vue.js";
6
- import I from "../Avatar.vue.js";
7
- import B from "../StatusChip/StatusChip.vue.js";
8
- const V = { class: "flex flex-col sm:flex-row justify-between items-start gap-4" }, $ = { class: "flex flex-col gap-3" }, j = { class: "flex items-center gap-2.5 mt-1.5 flex-wrap" }, C = { class: "flex flex-wrap gap-5" }, L = { key: 0 }, S = { key: 1 }, E = { class: "flex flex-col items-start sm:items-end gap-2 shrink-0" }, q = { class: "grid grid-cols-1 md:grid-cols-2 gap-5 mb-6" }, F = { key: 0 }, G = { key: 1 }, O = { key: 2 }, P = { key: 3 }, K = { class: "flex flex-col gap-0.5" }, Q = { key: 0 }, U = { key: 1 }, A = {
6
+ import k from "../Avatar.vue.js";
7
+ import V from "../StatusChip/StatusChip.vue.js";
8
+ import B from "./InvoiceTotals.vue.js";
9
+ const $ = { class: "flex flex-col sm:flex-row justify-between items-start gap-4" }, C = { class: "flex flex-col gap-3" }, L = { class: "flex items-center gap-2.5 mt-1.5 flex-wrap" }, S = { class: "flex flex-wrap gap-5" }, j = { key: 0 }, q = { key: 1 }, E = { class: "flex flex-col items-start sm:items-end gap-2 shrink-0" }, F = { class: "grid grid-cols-1 md:grid-cols-2 gap-5 mb-6" }, O = { key: 0 }, P = { key: 1 }, K = { key: 2 }, Q = { key: 3 }, U = { class: "flex flex-col gap-0.5" }, A = { key: 0 }, G = { key: 1 }, H = {
9
10
  key: 2,
10
- class: "text-primary font-medium"
11
- }, H = { key: 4 }, J = { key: 1 }, M = { key: 1 }, R = { key: 2 }, W = { key: 3 }, X = { class: "flex flex-col gap-0.5" }, Y = { key: 0 }, Z = { key: 1 }, ee = {
11
+ class: "text-gray-700 font-medium"
12
+ }, J = { key: 4 }, M = { key: 1 }, R = { key: 1 }, W = { key: 2 }, X = { key: 3 }, Y = { class: "flex flex-col gap-0.5" }, Z = { key: 0 }, ee = { key: 1 }, te = {
12
13
  key: 4,
13
14
  class: "text-xs font-semibold"
14
- }, te = {
15
+ }, oe = {
16
+ scope: "col",
17
+ class: "invoice-th font-bold"
18
+ }, ae = {
19
+ scope: "col",
20
+ class: "invoice-th invoice-text-right font-bold"
21
+ }, se = {
15
22
  key: 0,
16
23
  scope: "col",
17
24
  class: "invoice-th invoice-text-right font-bold"
18
- }, oe = {
25
+ }, ce = {
26
+ scope: "col",
27
+ class: "invoice-th invoice-text-right font-bold"
28
+ }, le = {
19
29
  key: 1,
20
30
  scope: "col",
21
31
  class: "invoice-th invoice-text-right font-bold"
22
- }, ae = { class: "invoice-tbody" }, se = { class: "invoice-td" }, ce = { class: "flex items-center gap-3" }, le = { class: "min-w-0 flex-1" }, ne = ["title"], re = ["title"], ie = {
32
+ }, ne = {
33
+ scope: "col",
34
+ class: "invoice-th invoice-text-right font-bold text-gray-900"
35
+ }, ie = { class: "invoice-tbody" }, de = { class: "invoice-td" }, re = { class: "flex items-center gap-3" }, ue = { class: "min-w-0 flex-1" }, me = ["title"], ve = ["title"], xe = {
23
36
  key: 1,
24
37
  class: "block text-xs text-muted-foreground line-clamp-2 max-w-md whitespace-normal mt-0.5 leading-relaxed"
25
- }, de = { class: "invoice-td invoice-text-right tabular-nums text-muted-foreground font-semibold text-sm" }, ue = {
38
+ }, fe = { class: "invoice-td invoice-text-right tabular-nums text-muted-foreground font-semibold text-sm" }, pe = {
26
39
  key: 0,
27
40
  class: "invoice-td invoice-text-right tabular-nums text-muted-foreground text-sm"
28
- }, me = { class: "invoice-td invoice-text-right tabular-nums text-muted-foreground font-medium" }, xe = {
41
+ }, he = { class: "invoice-td invoice-text-right tabular-nums text-muted-foreground font-medium" }, be = {
29
42
  key: 1,
30
43
  class: "invoice-td invoice-text-right tabular-nums text-success font-bold"
31
- }, ve = {
44
+ }, ye = {
32
45
  key: 0,
33
46
  class: "flex flex-col items-end"
34
- }, pe = {
47
+ }, ge = {
35
48
  key: 0,
36
49
  class: "text-sm uppercase tracking-wider font-extrabold opacity-80 mt-0.5"
37
- }, fe = {
50
+ }, ke = {
38
51
  key: 1,
39
52
  class: "text-muted-foreground font-normal"
40
- }, be = { class: "invoice-td invoice-text-right tabular-nums font-bold text-foreground" }, ye = { class: "flex flex-row flex-wrap gap-3 items-center" }, he = {
53
+ }, _e = { class: "invoice-td invoice-text-right tabular-nums font-bold text-foreground" }, Ie = { class: "flex flex-row flex-wrap gap-2 items-center" }, we = {
41
54
  key: 0,
42
- class: "shrink-0 inline-block border border-border rounded-lg bg-white p-1.5"
43
- }, ge = {
55
+ class: "shrink-0 inline-block"
56
+ }, De = {
44
57
  key: 1,
45
- class: "shrink-0 inline-block border border-border rounded-lg bg-white p-2 overflow-hidden"
46
- }, ke = { key: 0 }, Ie = { class: "w-full md:w-[42%] min-w-[260px]" }, we = { key: 0 }, _e = { key: 1 }, je = /* @__PURE__ */ _({
58
+ class: "shrink-0 inline-block overflow-hidden"
59
+ }, ze = { key: 0 }, Te = { class: "w-full md:w-[42%] min-w-[260px]" }, Ne = { key: 0 }, Ve = { key: 1 }, Oe = /* @__PURE__ */ I({
47
60
  __name: "InvoiceVariant4",
48
61
  props: {
49
62
  data: {},
50
63
  compact: { type: Boolean, default: !1 },
51
- displayBarcodeValue: { type: Boolean, default: !1 }
64
+ displayBarcodeValue: { type: Boolean, default: !1 },
65
+ labels: {}
52
66
  },
53
- setup(s) {
54
- const w = s, e = b(() => w.data), y = b(() => e.value.items.some((x) => !!x.size)), h = b(() => e.value.items.some((x) => x.discount !== void 0));
55
- return (x, d) => (t(), a("div", {
67
+ setup(l) {
68
+ const h = l, e = x(() => h.data), d = x(() => h.labels || {}), b = x(() => e.value.items.some((v) => !!v.size)), y = x(() => e.value.items.some((v) => v.discount !== void 0));
69
+ return (v, Be) => (o(), s("div", {
56
70
  class: "v-invoice-v4 bg-background border border-border text-foreground overflow-hidden rounded-xl font-sans print:shadow-none print:border-none",
57
- style: D({
58
- "--invoice-cell-px": s.compact ? "0.75rem" : "1rem",
59
- "--invoice-cell-py": s.compact ? "0.5rem" : "0.75rem",
71
+ style: w({
72
+ "--invoice-cell-px": l.compact ? "0.75rem" : "1rem",
73
+ "--invoice-cell-py": l.compact ? "0.5rem" : "0.75rem",
60
74
  "--invoice-thead-bg": "var(--color-muted)",
61
75
  "--invoice-thead-border": "1px solid var(--color-border)",
62
76
  "--invoice-thead-color": "var(--color-muted-foreground)",
@@ -65,20 +79,20 @@ const V = { class: "flex flex-col sm:flex-row justify-between items-start gap-4"
65
79
  "--invoice-td-valign": "middle"
66
80
  })
67
81
  }, [
68
- o("div", {
69
- class: n(["bg-primary text-primary-fg", s.compact ? "px-5 py-4" : "px-6 py-5 sm:px-8"])
82
+ a("div", {
83
+ class: n(["bg-gray-900 text-white", l.compact ? "px-5 py-4" : "px-6 py-5 sm:px-8"])
70
84
  }, [
71
- o("div", V, [
72
- o("div", $, [
73
- o("div", null, [
74
- o("h1", {
75
- class: n(["font-black tracking-tighter uppercase leading-none text-primary-fg", s.compact ? "text-3xl" : "text-4xl"])
76
- }, l(e.value.brandTitle || "INVOICE"), 3),
77
- o("div", j, [
78
- o("span", {
79
- class: n(["font-semibold opacity-80", s.compact ? "text-sm" : "text-base"])
80
- }, " #" + l(e.value.invoiceNumber), 3),
81
- e.value.status ? (t(), T(B, {
85
+ a("div", $, [
86
+ a("div", C, [
87
+ a("div", null, [
88
+ a("h1", {
89
+ class: n(["font-black tracking-tighter uppercase leading-none text-white", l.compact ? "text-3xl" : "text-4xl"])
90
+ }, t(e.value.brandTitle || d.value.invoice || "INVOICE"), 3),
91
+ a("div", L, [
92
+ a("span", {
93
+ class: n(["font-semibold opacity-80", l.compact ? "text-sm" : "text-base"])
94
+ }, " #" + t(e.value.invoiceNumber), 3),
95
+ e.value.status ? (o(), D(V, {
82
96
  key: 0,
83
97
  status: e.value.status,
84
98
  "hide-icon": "",
@@ -86,190 +100,178 @@ const V = { class: "flex flex-col sm:flex-row justify-between items-start gap-4"
86
100
  }, null, 8, ["status"])) : c("", !0)
87
101
  ])
88
102
  ]),
89
- o("div", C, [
90
- e.value.issuedDate ? (t(), a("div", L, [
91
- o("p", {
92
- class: n(["font-semibold uppercase tracking-widest opacity-60", s.compact ? "text-[9px] mb-0.5" : "text-[10px] mb-1"])
93
- }, " Issue Date ", 2),
94
- i(u(k), {
103
+ a("div", S, [
104
+ e.value.issuedDate ? (o(), s("div", j, [
105
+ a("p", {
106
+ class: n(["font-semibold uppercase tracking-widest opacity-60", l.compact ? "text-[9px] mb-0.5" : "text-[10px] mb-1"])
107
+ }, t(d.value.issued || "Issue Date"), 3),
108
+ r(u(g), {
95
109
  value: e.value.issuedDate,
96
110
  type: "date",
97
- class: n(["font-extrabold", s.compact ? "text-sm" : "text-base"])
111
+ class: n(["font-extrabold", l.compact ? "text-sm" : "text-base"])
98
112
  }, null, 8, ["value", "class"])
99
113
  ])) : c("", !0),
100
- e.value.dueDate ? (t(), a("div", S, [
101
- o("p", {
102
- class: n(["font-semibold uppercase tracking-widest opacity-60", s.compact ? "text-[9px] mb-0.5" : "text-[10px] mb-1"])
103
- }, " Due Date ", 2),
104
- i(u(k), {
114
+ e.value.dueDate ? (o(), s("div", q, [
115
+ a("p", {
116
+ class: n(["font-semibold uppercase tracking-widest opacity-60", l.compact ? "text-[9px] mb-0.5" : "text-[10px] mb-1"])
117
+ }, t(d.value.due || "Due Date"), 3),
118
+ r(u(g), {
105
119
  value: e.value.dueDate,
106
120
  type: "date",
107
- class: n(["font-extrabold", s.compact ? "text-sm" : "text-base"])
121
+ class: n(["font-extrabold", l.compact ? "text-sm" : "text-base"])
108
122
  }, null, 8, ["value", "class"])
109
123
  ])) : c("", !0)
110
124
  ])
111
125
  ]),
112
- o("div", E, [
113
- e.value.brandLogo ? (t(), a("div", {
126
+ a("div", E, [
127
+ e.value.brandLogo ? (o(), s("div", {
114
128
  key: 0,
115
- class: n(["bg-white/10 rounded-lg p-2 border border-white/20", s.compact ? "h-11" : "h-14"])
129
+ class: n(["bg-white/10 rounded-lg p-2 border border-white/20", l.compact ? "h-11" : "h-14"])
116
130
  }, [
117
- i(I, {
131
+ r(k, {
118
132
  src: e.value.brandLogo,
119
133
  alt: e.value.brandName,
120
134
  class: "h-full w-auto object-contain",
121
135
  rounded: "sm"
122
136
  }, null, 8, ["src", "alt"])
123
137
  ], 2)) : c("", !0),
124
- e.value.brandName ? (t(), a("h2", {
138
+ e.value.brandName ? (o(), s("h2", {
125
139
  key: 1,
126
- class: n(["font-extrabold tracking-tight opacity-90 text-primary-fg", s.compact ? "text-base" : "text-lg"])
127
- }, l(e.value.brandName), 3)) : c("", !0)
140
+ class: n(["font-extrabold tracking-tight opacity-90 text-white", l.compact ? "text-base" : "text-lg"])
141
+ }, t(e.value.brandName), 3)) : c("", !0)
128
142
  ])
129
143
  ])
130
144
  ], 2),
131
- o("div", {
132
- class: n(s.compact ? "p-5" : "px-7 py-4.5")
145
+ a("div", {
146
+ class: n(l.compact ? "p-5" : "px-7 py-4.5")
133
147
  }, [
134
- o("div", q, [
135
- e.value.companyInfo ? (t(), a("div", F, [
136
- o("p", {
137
- class: n(["font-bold text-primary uppercase tracking-widest border-b border-primary/20 pb-1 inline-block mb-2", s.compact ? "text-[10px]" : "text-[11px]"])
138
- }, " From ", 2),
139
- o("div", {
140
- class: n(["text-muted-foreground leading-relaxed", s.compact ? "text-xs space-y-0.5" : "text-sm space-y-1"])
148
+ a("div", F, [
149
+ e.value.companyInfo ? (o(), s("div", O, [
150
+ a("p", {
151
+ class: n(["font-bold text-gray-700 uppercase tracking-widest border-b border-gray-300 pb-1 inline-block mb-2", l.compact ? "text-[10px]" : "text-[11px]"])
152
+ }, t(d.value.from || "From"), 3),
153
+ a("div", {
154
+ class: n(["text-muted-foreground leading-relaxed", l.compact ? "text-xs space-y-0.5" : "text-sm space-y-1"])
141
155
  }, [
142
- e.value.companyInfo.name ? (t(), a("p", {
156
+ e.value.companyInfo.name ? (o(), s("p", {
143
157
  key: 0,
144
- class: n(["font-extrabold text-foreground", s.compact ? "text-sm mb-0.5" : "text-base mb-1"])
145
- }, l(e.value.companyInfo.name), 3)) : c("", !0),
146
- e.value.companyInfo.address ? (t(), a("p", G, l(e.value.companyInfo.address), 1)) : c("", !0),
147
- e.value.companyInfo.city || e.value.companyInfo.state ? (t(), a("p", O, [
148
- m(l(e.value.companyInfo.city), 1),
149
- e.value.companyInfo.city && e.value.companyInfo.state ? (t(), a(v, { key: 0 }, [
158
+ class: n(["font-extrabold text-foreground", l.compact ? "text-sm mb-0.5" : "text-base mb-1"])
159
+ }, t(e.value.companyInfo.name), 3)) : c("", !0),
160
+ e.value.companyInfo.address ? (o(), s("p", P, t(e.value.companyInfo.address), 1)) : c("", !0),
161
+ e.value.companyInfo.city || e.value.companyInfo.state ? (o(), s("p", K, [
162
+ m(t(e.value.companyInfo.city), 1),
163
+ e.value.companyInfo.city && e.value.companyInfo.state ? (o(), s(f, { key: 0 }, [
150
164
  m(", ")
151
165
  ], 64)) : c("", !0),
152
- m(l(e.value.companyInfo.state) + " " + l(e.value.companyInfo.zip), 1)
166
+ m(t(e.value.companyInfo.state) + " " + t(e.value.companyInfo.zip), 1)
153
167
  ])) : c("", !0),
154
- e.value.companyInfo.country ? (t(), a("p", P, l(e.value.companyInfo.country), 1)) : c("", !0),
155
- o("div", K, [
156
- e.value.companyInfo.email ? (t(), a("p", Q, l(e.value.companyInfo.email), 1)) : c("", !0),
157
- e.value.companyInfo.phone ? (t(), a("p", U, l(e.value.companyInfo.phone), 1)) : c("", !0),
158
- e.value.companyInfo.website ? (t(), a("p", A, l(e.value.companyInfo.website), 1)) : c("", !0)
168
+ e.value.companyInfo.country ? (o(), s("p", Q, t(e.value.companyInfo.country), 1)) : c("", !0),
169
+ a("div", U, [
170
+ e.value.companyInfo.email ? (o(), s("p", A, t(e.value.companyInfo.email), 1)) : c("", !0),
171
+ e.value.companyInfo.phone ? (o(), s("p", G, t(e.value.companyInfo.phone), 1)) : c("", !0),
172
+ e.value.companyInfo.website ? (o(), s("p", H, t(e.value.companyInfo.website), 1)) : c("", !0)
159
173
  ]),
160
- e.value.companyInfo.taxId ? (t(), a("p", H, "Tax ID: " + l(e.value.companyInfo.taxId), 1)) : c("", !0)
174
+ e.value.companyInfo.taxId ? (o(), s("p", J, t(d.value.taxId || "Tax ID") + ": " + t(e.value.companyInfo.taxId), 1)) : c("", !0)
161
175
  ], 2)
162
176
  ])) : c("", !0),
163
- e.value.customerInfo ? (t(), a("div", J, [
164
- o("p", {
165
- class: n(["font-bold text-primary uppercase tracking-widest border-b border-primary/20 pb-1 inline-block mb-2", s.compact ? "text-[10px]" : "text-[11px]"])
166
- }, " Billed To ", 2),
167
- o("div", {
168
- class: n(["text-muted-foreground leading-relaxed", s.compact ? "text-xs space-y-0.5" : "text-sm space-y-1"])
177
+ e.value.customerInfo ? (o(), s("div", M, [
178
+ a("p", {
179
+ class: n(["font-bold text-gray-700 uppercase tracking-widest border-b border-gray-300 pb-1 inline-block mb-2", l.compact ? "text-[10px]" : "text-[11px]"])
180
+ }, t(d.value.billedTo || "Billed To"), 3),
181
+ a("div", {
182
+ class: n(["text-muted-foreground leading-relaxed", l.compact ? "text-xs space-y-0.5" : "text-sm space-y-1"])
169
183
  }, [
170
- e.value.customerInfo.name ? (t(), a("p", {
184
+ e.value.customerInfo.name ? (o(), s("p", {
171
185
  key: 0,
172
- class: n(["font-extrabold text-foreground", s.compact ? "text-sm mb-0.5" : "text-base mb-1"])
173
- }, l(e.value.customerInfo.name), 3)) : c("", !0),
174
- e.value.customerInfo.address ? (t(), a("p", M, l(e.value.customerInfo.address), 1)) : c("", !0),
175
- e.value.customerInfo.city || e.value.customerInfo.state ? (t(), a("p", R, [
176
- m(l(e.value.customerInfo.city), 1),
177
- e.value.customerInfo.city && e.value.customerInfo.state ? (t(), a(v, { key: 0 }, [
186
+ class: n(["font-extrabold text-foreground", l.compact ? "text-sm mb-0.5" : "text-base mb-1"])
187
+ }, t(e.value.customerInfo.name), 3)) : c("", !0),
188
+ e.value.customerInfo.address ? (o(), s("p", R, t(e.value.customerInfo.address), 1)) : c("", !0),
189
+ e.value.customerInfo.city || e.value.customerInfo.state ? (o(), s("p", W, [
190
+ m(t(e.value.customerInfo.city), 1),
191
+ e.value.customerInfo.city && e.value.customerInfo.state ? (o(), s(f, { key: 0 }, [
178
192
  m(", ")
179
193
  ], 64)) : c("", !0),
180
- m(l(e.value.customerInfo.state) + " " + l(e.value.customerInfo.zip), 1)
194
+ m(t(e.value.customerInfo.state) + " " + t(e.value.customerInfo.zip), 1)
181
195
  ])) : c("", !0),
182
- e.value.customerInfo.country ? (t(), a("p", W, l(e.value.customerInfo.country), 1)) : c("", !0),
183
- o("div", X, [
184
- e.value.customerInfo.email ? (t(), a("p", Y, l(e.value.customerInfo.email), 1)) : c("", !0),
185
- e.value.customerInfo.phone ? (t(), a("p", Z, l(e.value.customerInfo.phone), 1)) : c("", !0)
196
+ e.value.customerInfo.country ? (o(), s("p", X, t(e.value.customerInfo.country), 1)) : c("", !0),
197
+ a("div", Y, [
198
+ e.value.customerInfo.email ? (o(), s("p", Z, t(e.value.customerInfo.email), 1)) : c("", !0),
199
+ e.value.customerInfo.phone ? (o(), s("p", ee, t(e.value.customerInfo.phone), 1)) : c("", !0)
186
200
  ]),
187
- e.value.customerInfo.taxId ? (t(), a("p", ee, " Tax ID: " + l(e.value.customerInfo.taxId), 1)) : c("", !0)
201
+ e.value.customerInfo.taxId ? (o(), s("p", te, t(d.value.taxId || "Tax ID") + ": " + t(e.value.customerInfo.taxId), 1)) : c("", !0)
188
202
  ], 2)
189
203
  ])) : c("", !0)
190
204
  ]),
191
- o("div", {
192
- class: n(["border border-border rounded-lg overflow-x-auto", s.compact ? "mb-5" : "mb-6"])
205
+ a("div", {
206
+ class: n(["border border-border rounded-lg overflow-x-auto", l.compact ? "mb-5" : "mb-6"])
193
207
  }, [
194
- o("table", {
195
- class: n(["invoice-table", s.compact ? "text-xs" : "text-sm"])
208
+ a("table", {
209
+ class: n(["invoice-table", l.compact ? "text-xs" : "text-sm"])
196
210
  }, [
197
- o("thead", {
198
- class: n(["invoice-thead uppercase", s.compact ? "text-[9px]" : "text-[10px]"])
211
+ a("thead", {
212
+ class: n(["invoice-thead uppercase", l.compact ? "text-[9px]" : "text-[10px]"])
199
213
  }, [
200
- o("tr", null, [
201
- d[0] || (d[0] = o("th", {
202
- scope: "col",
203
- class: "invoice-th font-bold"
204
- }, "Product", -1)),
205
- d[1] || (d[1] = o("th", {
206
- scope: "col",
207
- class: "invoice-th invoice-text-right font-bold"
208
- }, "Qty", -1)),
209
- y.value ? (t(), a("th", te, " Size ")) : c("", !0),
210
- d[2] || (d[2] = o("th", {
211
- scope: "col",
212
- class: "invoice-th invoice-text-right font-bold"
213
- }, "Price", -1)),
214
- h.value ? (t(), a("th", oe, " Discount ")) : c("", !0),
215
- d[3] || (d[3] = o("th", {
216
- scope: "col",
217
- class: "invoice-th invoice-text-right font-bold text-primary"
218
- }, " Total ", -1))
214
+ a("tr", null, [
215
+ a("th", oe, t(d.value.item || "Product"), 1),
216
+ a("th", ae, t(d.value.qty || "Qty"), 1),
217
+ b.value ? (o(), s("th", se, t(d.value.size || "Size"), 1)) : c("", !0),
218
+ a("th", ce, t(d.value.price || "Price"), 1),
219
+ y.value ? (o(), s("th", le, t(d.value.discount || "Discount"), 1)) : c("", !0),
220
+ a("th", ne, t(d.value.total || "Total"), 1)
219
221
  ])
220
222
  ], 2),
221
- o("tbody", ae, [
222
- (t(!0), a(v, null, g(e.value.items, (r, f) => (t(), a("tr", {
223
- key: r.id || f,
223
+ a("tbody", ie, [
224
+ (o(!0), s(f, null, z(e.value.items, (i, _) => (o(), s("tr", {
225
+ key: i.id || _,
224
226
  class: "invoice-tr group"
225
227
  }, [
226
- o("td", se, [
227
- o("div", ce, [
228
- r.thumbnail ? (t(), a("div", {
228
+ a("td", de, [
229
+ a("div", re, [
230
+ i.thumbnail ? (o(), s("div", {
229
231
  key: 0,
230
- class: n(["shrink-0 overflow-hidden border border-border", s.compact ? "w-9 h-9 rounded-md" : "w-10 h-10 rounded-lg"])
232
+ class: n(["shrink-0 overflow-hidden border border-border", l.compact ? "w-9 h-9 rounded-md" : "w-10 h-10 rounded-lg"])
231
233
  }, [
232
- i(I, {
233
- src: r.thumbnail,
234
- alt: r.name,
234
+ r(k, {
235
+ src: i.thumbnail,
236
+ alt: i.name,
235
237
  class: "w-full h-full",
236
238
  rounded: "sm"
237
239
  }, null, 8, ["src", "alt"])
238
240
  ], 2)) : c("", !0),
239
- o("div", le, [
240
- o("span", {
241
+ a("div", ue, [
242
+ a("span", {
241
243
  class: "block truncate font-semibold text-foreground text-sm",
242
- title: r.name
243
- }, l(r.name), 9, ne),
244
- r.sku ? (t(), a("div", {
244
+ title: i.name
245
+ }, t(i.name), 9, me),
246
+ i.sku ? (o(), s("div", {
245
247
  key: 0,
246
248
  class: "text-xs uppercase tracking-widest text-muted-foreground font-medium truncate mt-0.5",
247
- title: r.sku
248
- }, " SKU: " + l(r.sku), 9, re)) : c("", !0),
249
- r.description && !s.compact ? (t(), a("span", ie, l(r.description), 1)) : c("", !0)
249
+ title: i.sku
250
+ }, t(d.value.sku || "SKU") + ": " + t(i.sku), 9, ve)) : c("", !0),
251
+ i.description && !l.compact ? (o(), s("span", xe, t(i.description), 1)) : c("", !0)
250
252
  ])
251
253
  ])
252
254
  ]),
253
- o("td", de, l(r.quantity), 1),
254
- y.value ? (t(), a("td", ue, l(r.size || "-"), 1)) : c("", !0),
255
- o("td", me, [
256
- i(u(p), {
257
- value: r.price,
255
+ a("td", fe, t(i.quantity), 1),
256
+ b.value ? (o(), s("td", pe, t(i.size || "-"), 1)) : c("", !0),
257
+ a("td", he, [
258
+ r(u(p), {
259
+ value: i.price,
258
260
  class: "text-sm"
259
261
  }, null, 8, ["value"])
260
262
  ]),
261
- h.value ? (t(), a("td", xe, [
262
- r.discount !== void 0 ? (t(), a("div", ve, [
263
- i(u(p), {
264
- value: -r.discount,
263
+ y.value ? (o(), s("td", be, [
264
+ i.discount !== void 0 ? (o(), s("div", ye, [
265
+ r(u(p), {
266
+ value: -i.discount,
265
267
  class: "text-sm"
266
268
  }, null, 8, ["value"]),
267
- r.discountLabel ? (t(), a("span", pe, l(r.discountLabel), 1)) : c("", !0)
268
- ])) : (t(), a("span", fe, "-"))
269
+ i.discountLabel ? (o(), s("span", ge, t(i.discountLabel), 1)) : c("", !0)
270
+ ])) : (o(), s("span", ke, "-"))
269
271
  ])) : c("", !0),
270
- o("td", be, [
271
- i(u(p), {
272
- value: r.total,
272
+ a("td", _e, [
273
+ r(u(p), {
274
+ value: i.total,
273
275
  class: "text-sm"
274
276
  }, null, 8, ["value"])
275
277
  ])
@@ -277,67 +279,55 @@ const V = { class: "flex flex-col sm:flex-row justify-between items-start gap-4"
277
279
  ])
278
280
  ], 2)
279
281
  ], 2),
280
- o("div", {
281
- class: n(["flex flex-col-reverse md:flex-row justify-between items-start", s.compact ? "gap-5" : "gap-6"])
282
+ a("div", {
283
+ class: n(["flex flex-col-reverse md:flex-row justify-between items-start", l.compact ? "gap-5" : "gap-6"])
282
284
  }, [
283
- o("div", {
284
- class: n(["w-full md:w-1/2 flex flex-col", s.compact ? "gap-3" : "gap-4"])
285
+ a("div", {
286
+ class: n(["w-full md:w-1/2 flex flex-col", l.compact ? "gap-3" : "gap-4"])
285
287
  }, [
286
- o("div", ye, [
287
- e.value.qrcode ? (t(), a("div", he, [
288
- i(u(N), {
288
+ a("div", Ie, [
289
+ e.value.qrcode ? (o(), s("div", we, [
290
+ r(u(N), {
289
291
  value: e.value.qrcode,
290
- size: s.compact ? 56 : 72
292
+ size: l.compact ? 56 : 72
291
293
  }, null, 8, ["value", "size"])
292
294
  ])) : c("", !0),
293
- e.value.barcode ? (t(), a("div", ge, [
294
- i(u(z), {
295
+ e.value.barcode ? (o(), s("div", De, [
296
+ r(u(T), {
295
297
  value: e.value.barcode,
296
298
  format: "CODE128",
297
- height: s.compact ? 28 : 36,
298
- width: s.compact ? 1.3 : 1.5,
299
- "display-value": s.displayBarcodeValue
299
+ height: l.compact ? 28 : 40,
300
+ width: l.compact ? 1.3 : 1.5,
301
+ "display-value": l.displayBarcodeValue
300
302
  }, null, 8, ["value", "height", "width", "display-value"])
301
303
  ])) : c("", !0)
302
304
  ]),
303
- e.value.notes ? (t(), a("div", ke, [
304
- o("h4", {
305
- class: n(["font-bold text-muted-foreground uppercase tracking-widest mb-1.5", s.compact ? "text-[9px]" : "text-[10px]"])
306
- }, " Notes & Terms ", 2),
307
- o("div", {
308
- class: n(["text-muted-foreground leading-relaxed whitespace-pre-wrap p-3 bg-muted/30 rounded-lg border border-border", s.compact ? "text-xs max-w-xs" : "text-xs max-w-sm"])
309
- }, l(e.value.notes), 3)
305
+ e.value.notes ? (o(), s("div", ze, [
306
+ a("h4", {
307
+ class: n(["font-bold text-muted-foreground uppercase tracking-widest mb-1.5", l.compact ? "text-[9px]" : "text-[10px]"])
308
+ }, t(d.value.notes || "Notes & Terms"), 3),
309
+ a("div", {
310
+ class: n(["text-muted-foreground leading-relaxed whitespace-pre-wrap p-3 bg-muted/30 rounded-lg border border-border", l.compact ? "text-xs max-w-xs" : "text-xs max-w-sm"])
311
+ }, t(e.value.notes), 3)
310
312
  ])) : c("", !0)
311
313
  ], 2),
312
- o("div", Ie, [
313
- o("div", {
314
- class: n(["border border-border rounded-lg", s.compact ? "p-4 space-y-2" : "p-5 space-y-2.5"])
315
- }, [
316
- (t(!0), a(v, null, g(e.value.totals, (r, f) => (t(), a("div", {
317
- key: f,
318
- class: n(["flex justify-between items-center", [
319
- r.isGrandTotal ? s.compact ? "pt-2.5 mt-1 border-t border-primary/30 text-base font-black text-primary" : "pt-3 mt-1.5 border-t border-primary/30 text-lg font-black text-primary" : s.compact ? "text-xs font-semibold text-muted-foreground" : "text-sm font-semibold text-muted-foreground"
320
- ]])
321
- }, [
322
- o("span", {
323
- class: n(r.isGrandTotal ? "uppercase tracking-widest text-xs" : "")
324
- }, l(r.label), 3),
325
- i(u(p), {
326
- value: r.value
327
- }, null, 8, ["value"])
328
- ], 2))), 128))
329
- ], 2)
314
+ a("div", Te, [
315
+ r(B, {
316
+ totals: e.value.totals,
317
+ compact: l.compact,
318
+ variant: "Variant4"
319
+ }, null, 8, ["totals", "compact"])
330
320
  ])
331
321
  ], 2)
332
322
  ], 2),
333
- o("div", {
334
- class: n(["bg-primary text-primary-foreground flex justify-center font-bold uppercase tracking-widest", s.compact ? "py-2 px-4 text-[9px]" : "py-2.5 px-6 text-[10px]"])
323
+ a("div", {
324
+ class: n(["bg-gray-900 text-white flex justify-center font-bold uppercase tracking-widest", l.compact ? "py-2 px-4 text-[9px]" : "py-2.5 px-6 text-[10px]"])
335
325
  }, [
336
- e.value.footerText ? (t(), a("span", we, l(e.value.footerText), 1)) : (t(), a("span", _e, "Thank you for your business"))
326
+ e.value.footerText ? (o(), s("span", Ne, t(e.value.footerText), 1)) : (o(), s("span", Ve, "Thank you for your business"))
337
327
  ], 2)
338
328
  ], 4));
339
329
  }
340
330
  });
341
331
  export {
342
- je as default
332
+ Oe as default
343
333
  };
@@ -1,2 +1,3 @@
1
1
  export { default as Invoice } from './Invoice.vue';
2
+ export { default as InvoiceTotals } from './InvoiceTotals.vue';
2
3
  export * from './types';
@@ -82,6 +82,24 @@ export interface InvoiceData {
82
82
  /** Footer text, usually for terms and conditions */
83
83
  footerText?: string;
84
84
  }
85
+ export interface InvoiceLabels {
86
+ invoice?: string;
87
+ invoiceNumber?: string;
88
+ issued?: string;
89
+ due?: string;
90
+ from?: string;
91
+ billedTo?: string;
92
+ status?: string;
93
+ item?: string;
94
+ price?: string;
95
+ qty?: string;
96
+ size?: string;
97
+ discount?: string;
98
+ total?: string;
99
+ notes?: string;
100
+ sku?: string;
101
+ taxId?: string;
102
+ }
85
103
  export interface InvoiceProps {
86
104
  data: InvoiceData;
87
105
  variant?: InvoiceVariant;
@@ -94,4 +112,8 @@ export interface InvoiceProps {
94
112
  * Whether to display the text value underneath the barcode
95
113
  */
96
114
  displayBarcodeValue?: boolean;
115
+ /**
116
+ * Custom text labels for static UI strings (e.g. overriding "Invoice", "Issued")
117
+ */
118
+ labels?: InvoiceLabels;
97
119
  }
@@ -16,8 +16,8 @@ declare function __VLS_template(): {
16
16
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
17
17
  declare const __VLS_component: import('vue').DefineComponent<MasonryProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<MasonryProps> & Readonly<{}>, {
18
18
  tag: string;
19
- itemKey: string;
20
19
  gap: number;
20
+ itemKey: string;
21
21
  cols: number | Record<string | number, number>;
22
22
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
23
23
  containerRef: unknown;
@@ -1,7 +1,7 @@
1
1
  import o from "./Modal.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../_virtual/_plugin-vue_export-helper.js";
4
- const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-7c958115"]]);
4
+ const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-350b61e5"]]);
5
5
  export {
6
6
  p as default
7
7
  };