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