vlite3 1.2.1 → 1.2.2

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