@tesouro/embedded-components-react 0.5.233 → 0.5.236
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/README.md +19 -14
- package/dist/index.d.ts +175 -16
- package/dist/index.js +1 -1
- package/dist/lib/BankAccountOnboardingWidget.d.ts +39 -1
- package/dist/lib/ReceivablesWidget.d.ts +110 -1
- package/dist/lib/ReceivablesWidget.js +1 -1
- package/dist/lib/WidgetSuite.d.ts +65 -15
- package/dist/libs/tesouro-embedded-components-react/bank-account-onboarding-widget/feature/dist/index.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/bank-account-onboarding-widget/feature/dist/index12.js +2 -1
- package/dist/libs/tesouro-embedded-components-react/bank-account-onboarding-widget/feature/dist/index22.js +6 -0
- package/dist/libs/tesouro-embedded-components-react/bank-account-onboarding-widget/feature/dist/index23.js +15 -11
- package/dist/libs/tesouro-embedded-components-react/bank-account-onboarding-widget/feature/dist/index26.js +441 -409
- package/dist/libs/tesouro-embedded-components-react/bank-account-onboarding-widget/ui/dist/index10.js +18 -14
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index10.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index15.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index16.js +3 -3
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index19.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index21.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index23.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index31.js +210 -208
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index32.js +98 -40
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index33.js +159 -39
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index34.js +53 -77
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index35.js +99 -132
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index36.js +40 -341
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index37.js +43 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index38.js +92 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index39.js +146 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index40.js +354 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index5.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index9.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index.js +28 -24
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index10.js +2 -37
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index11.js +9 -214
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index12.js +27 -159
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index13.js +233 -14
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index14.js +34 -22
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index15.js +214 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index16.js +153 -87
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index17.js +16 -3
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index18.js +22 -21
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index19.js +2 -51
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index2.js +30 -15
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index20.js +90 -14
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index21.js +3 -10
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index22.js +20 -69
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index23.js +51 -33
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index24.js +16 -17
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index25.js +8 -14
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index26.js +70 -30
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index27.js +33 -14
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index28.js +17 -25
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index29.js +12 -83
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index3.js +9 -121
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index30.js +28 -401
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index31.js +16 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index32.js +22 -42
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index33.js +80 -65
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index34.js +383 -473
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index35.js +2 -106
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index36.js +48 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index37.js +72 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index38.js +498 -4
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index39.js +106 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index4.js +141 -93
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index41.js +2 -28
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index42.js +4 -236
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index43.js +0 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index44.js +90 -239
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index45.js +24 -89
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index46.js +231 -54
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index47.js +3 -353
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index48.js +249 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index49.js +93 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index5.js +3 -40
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index50.js +59 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index51.js +353 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index6.js +18 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index7.js +121 -9
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index8.js +100 -27
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index9.js +38 -233
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/widget-suite/feature/dist/index16.js +123 -92
- package/dist/libs/tesouro-embedded-components-react/widget-suite/feature/dist/index4.js +12 -5
- package/package.json +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index40.js +0 -100
|
@@ -1,95 +1,161 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { SelectionValue as y } from "./index14.js";
|
|
6
|
-
import { jsx as b, jsxs as x } from "react/jsx-runtime";
|
|
1
|
+
import { Button as e, Checkbox as t, Separator as n, Typography as r, cn as i } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
2
|
+
import { RECEIVABLE_FORM_SHEET_LABELS_EN as a } from "./index13.js";
|
|
3
|
+
import { Fragment as o, jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
4
|
+
import { FileText as l, ImageIcon as u, Loader2 as d, Trash2 as f, X as p } from "lucide-react";
|
|
7
5
|
//#region ../../libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index16.js
|
|
8
|
-
function
|
|
9
|
-
let
|
|
10
|
-
...
|
|
11
|
-
...
|
|
12
|
-
}, M = `${S}-payment-terms`, N = () => {
|
|
13
|
-
window.setTimeout(() => D(!0), 0);
|
|
6
|
+
function m({ view: m, isDragging: h, disabled: g, inputRef: _, onBrowseClick: v, onDragOver: y, onDragLeave: b, onDrop: x, onFilesSelect: S, onIncludeInEmailChange: C, onRemove: w, labels: T }) {
|
|
7
|
+
let E = {
|
|
8
|
+
...a,
|
|
9
|
+
...T
|
|
14
10
|
};
|
|
15
|
-
return /* @__PURE__ */
|
|
11
|
+
return /* @__PURE__ */ c("div", {
|
|
16
12
|
className: "ttw:flex ttw:flex-col ttw:gap-2.5 ttw:rounded-xl ttw:border ttw:border-border ttw:p-6",
|
|
17
|
-
children: [
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
className: "ttw:flex ttw:
|
|
32
|
-
children:
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
children: [/* @__PURE__ */
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
"
|
|
52
|
-
children:
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
}),
|
|
74
|
-
/* @__PURE__ */ b(d, {}),
|
|
75
|
-
C.options.map((e) => /* @__PURE__ */ b(u, {
|
|
76
|
-
value: e.value,
|
|
77
|
-
children: /* @__PURE__ */ b(v, { option: e })
|
|
78
|
-
}, e.value))
|
|
79
|
-
] })]
|
|
80
|
-
}), /* @__PURE__ */ b(s, {
|
|
81
|
-
className: "ttw:w-auto ttw:overflow-hidden ttw:p-0",
|
|
82
|
-
align: "start",
|
|
83
|
-
onFocusOutside: (e) => e.preventDefault(),
|
|
84
|
-
children: O
|
|
13
|
+
children: [
|
|
14
|
+
/* @__PURE__ */ c("div", {
|
|
15
|
+
className: "ttw:flex ttw:flex-col ttw:gap-2.5 ttw:pb-4",
|
|
16
|
+
children: [/* @__PURE__ */ s(r, {
|
|
17
|
+
variant: "h4",
|
|
18
|
+
children: E.attachmentsHeading
|
|
19
|
+
}), /* @__PURE__ */ s(r, {
|
|
20
|
+
variant: "body2",
|
|
21
|
+
color: "muted",
|
|
22
|
+
className: "ttw:font-medium",
|
|
23
|
+
children: E.attachmentsDescription
|
|
24
|
+
})]
|
|
25
|
+
}),
|
|
26
|
+
m.showRows && /* @__PURE__ */ c("div", {
|
|
27
|
+
className: "ttw:flex ttw:flex-col ttw:gap-2",
|
|
28
|
+
children: [m.emailCaption && /* @__PURE__ */ c(o, { children: [/* @__PURE__ */ s(r, {
|
|
29
|
+
variant: "caption",
|
|
30
|
+
color: "muted",
|
|
31
|
+
children: m.emailCaption
|
|
32
|
+
}), /* @__PURE__ */ s(n, {})] }), /* @__PURE__ */ c("ul", {
|
|
33
|
+
className: "ttw:flex ttw:flex-col ttw:gap-2",
|
|
34
|
+
children: [m.attachedRows.map((n) => /* @__PURE__ */ c("li", {
|
|
35
|
+
className: "ttw:flex ttw:items-center ttw:gap-2",
|
|
36
|
+
children: [/* @__PURE__ */ s(t, {
|
|
37
|
+
checked: n.includeInEmail,
|
|
38
|
+
disabled: g,
|
|
39
|
+
"aria-label": n.includeInEmailLabel,
|
|
40
|
+
onCheckedChange: (e) => C(n.id, e === !0)
|
|
41
|
+
}), /* @__PURE__ */ c("div", {
|
|
42
|
+
className: "ttw:flex ttw:w-full ttw:items-center ttw:gap-3 ttw:rounded-lg ttw:bg-muted ttw:px-2 ttw:py-1",
|
|
43
|
+
children: [/* @__PURE__ */ c("div", {
|
|
44
|
+
className: "ttw:flex ttw:min-w-0 ttw:flex-1 ttw:items-center ttw:gap-1",
|
|
45
|
+
children: [/* @__PURE__ */ s(r, {
|
|
46
|
+
variant: "body2",
|
|
47
|
+
className: "ttw:truncate",
|
|
48
|
+
children: n.name
|
|
49
|
+
}), /* @__PURE__ */ c(r, {
|
|
50
|
+
variant: "body2",
|
|
51
|
+
color: "muted",
|
|
52
|
+
className: "ttw:shrink-0",
|
|
53
|
+
children: [
|
|
54
|
+
"(",
|
|
55
|
+
n.sizeLabel,
|
|
56
|
+
")"
|
|
57
|
+
]
|
|
58
|
+
})]
|
|
59
|
+
}), /* @__PURE__ */ s(e, {
|
|
60
|
+
type: "button",
|
|
61
|
+
variant: "ghost",
|
|
62
|
+
size: "icon",
|
|
63
|
+
className: "ttw:size-4",
|
|
64
|
+
disabled: g,
|
|
65
|
+
"aria-label": n.removeLabel,
|
|
66
|
+
onClick: () => w(n.id),
|
|
67
|
+
children: /* @__PURE__ */ s(f, { className: "ttw:size-4" })
|
|
68
|
+
})]
|
|
85
69
|
})]
|
|
70
|
+
}, n.id)), m.pendingRows.map((t) => /* @__PURE__ */ c("li", {
|
|
71
|
+
className: "ttw:flex ttw:w-full ttw:items-center ttw:gap-3 ttw:rounded-lg ttw:bg-muted ttw:px-2 ttw:py-1",
|
|
72
|
+
children: [
|
|
73
|
+
t.state === "uploading" ? /* @__PURE__ */ s(d, { className: "ttw:size-5 ttw:shrink-0 ttw:animate-spin ttw:text-muted-foreground" }) : /* @__PURE__ */ s(l, { className: "ttw:size-5 ttw:shrink-0 ttw:text-destructive" }),
|
|
74
|
+
/* @__PURE__ */ c("div", {
|
|
75
|
+
className: "ttw:flex ttw:min-w-0 ttw:flex-1 ttw:flex-col",
|
|
76
|
+
children: [/* @__PURE__ */ s(r, {
|
|
77
|
+
variant: "body2",
|
|
78
|
+
className: "ttw:truncate",
|
|
79
|
+
children: t.name
|
|
80
|
+
}), t.state === "uploading" ? /* @__PURE__ */ s(r, {
|
|
81
|
+
variant: "caption",
|
|
82
|
+
color: "muted",
|
|
83
|
+
children: t.message
|
|
84
|
+
}) : /* @__PURE__ */ s(r, {
|
|
85
|
+
variant: "caption",
|
|
86
|
+
role: "alert",
|
|
87
|
+
className: "ttw:text-destructive",
|
|
88
|
+
children: t.message
|
|
89
|
+
})]
|
|
90
|
+
}),
|
|
91
|
+
/* @__PURE__ */ s(e, {
|
|
92
|
+
type: "button",
|
|
93
|
+
variant: "ghost",
|
|
94
|
+
size: "icon",
|
|
95
|
+
disabled: g,
|
|
96
|
+
"aria-label": t.removeLabel,
|
|
97
|
+
onClick: () => w(t.id),
|
|
98
|
+
children: /* @__PURE__ */ s(p, { className: "ttw:size-4" })
|
|
99
|
+
})
|
|
100
|
+
]
|
|
101
|
+
}, t.id))]
|
|
102
|
+
})]
|
|
103
|
+
}),
|
|
104
|
+
/* @__PURE__ */ c("button", {
|
|
105
|
+
type: "button",
|
|
106
|
+
disabled: g,
|
|
107
|
+
onClick: v,
|
|
108
|
+
onDragOver: (e) => {
|
|
109
|
+
e.preventDefault(), y();
|
|
110
|
+
},
|
|
111
|
+
onDragLeave: (e) => {
|
|
112
|
+
e.preventDefault(), b();
|
|
113
|
+
},
|
|
114
|
+
onDrop: (e) => {
|
|
115
|
+
e.preventDefault(), x(e.dataTransfer.files);
|
|
116
|
+
},
|
|
117
|
+
className: i("ttw:flex ttw:w-full ttw:flex-col ttw:items-center ttw:gap-2 ttw:rounded-xl ttw:border ttw:border-dashed ttw:p-6 ttw:text-center ttw:disabled:cursor-not-allowed ttw:disabled:opacity-50", h ? "ttw:border-primary ttw:bg-primary/5" : "ttw:border-border ttw:bg-muted"),
|
|
118
|
+
children: [
|
|
119
|
+
/* @__PURE__ */ s("span", {
|
|
120
|
+
className: "ttw:flex ttw:size-10 ttw:items-center ttw:justify-center ttw:rounded-full ttw:border ttw:border-border",
|
|
121
|
+
children: /* @__PURE__ */ s(u, { className: "ttw:size-5 ttw:text-muted-foreground" })
|
|
86
122
|
}),
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
123
|
+
/* @__PURE__ */ c(r, {
|
|
124
|
+
variant: "body2",
|
|
125
|
+
children: [
|
|
126
|
+
E.attachmentsDropPrompt,
|
|
127
|
+
" ",
|
|
128
|
+
/* @__PURE__ */ s("span", {
|
|
129
|
+
className: "ttw:text-primary ttw:underline",
|
|
130
|
+
children: E.attachmentsBrowseLink
|
|
131
|
+
})
|
|
132
|
+
]
|
|
133
|
+
}),
|
|
134
|
+
/* @__PURE__ */ s(r, {
|
|
135
|
+
variant: "caption",
|
|
136
|
+
color: "muted",
|
|
137
|
+
children: E.attachmentsFormatsHint
|
|
138
|
+
})
|
|
139
|
+
]
|
|
140
|
+
}),
|
|
141
|
+
m.countLimitMessage && /* @__PURE__ */ s(r, {
|
|
142
|
+
variant: "body2",
|
|
143
|
+
role: "alert",
|
|
144
|
+
className: "ttw:text-destructive",
|
|
145
|
+
children: m.countLimitMessage
|
|
146
|
+
}),
|
|
147
|
+
/* @__PURE__ */ s("input", {
|
|
148
|
+
ref: _,
|
|
149
|
+
type: "file",
|
|
150
|
+
multiple: !0,
|
|
151
|
+
tabIndex: -1,
|
|
152
|
+
"aria-hidden": !0,
|
|
153
|
+
className: "ttw:sr-only",
|
|
154
|
+
accept: m.accept,
|
|
155
|
+
onChange: (e) => S(e.target.files)
|
|
156
|
+
})
|
|
157
|
+
]
|
|
92
158
|
});
|
|
93
159
|
}
|
|
94
160
|
//#endregion
|
|
95
|
-
export {
|
|
161
|
+
export { m as ReceivableAttachmentsSection };
|
|
@@ -1,3 +1,16 @@
|
|
|
1
|
-
import "
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { jsx as e, jsxs as t } from "react/jsx-runtime";
|
|
2
|
+
//#region ../../libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index17.js
|
|
3
|
+
function n({ option: n }) {
|
|
4
|
+
return /* @__PURE__ */ t("span", {
|
|
5
|
+
className: "ttw:flex ttw:w-full ttw:min-w-0 ttw:items-center ttw:justify-between ttw:gap-2",
|
|
6
|
+
children: [/* @__PURE__ */ e("span", {
|
|
7
|
+
className: "ttw:truncate",
|
|
8
|
+
children: n.label
|
|
9
|
+
}), n.dueDateLabel && /* @__PURE__ */ e("span", {
|
|
10
|
+
className: "ttw:shrink-0 ttw:text-xs ttw:text-muted-foreground",
|
|
11
|
+
children: n.dueDateLabel
|
|
12
|
+
})]
|
|
13
|
+
});
|
|
14
|
+
}
|
|
15
|
+
//#endregion
|
|
16
|
+
export { n as OptionRow };
|
|
@@ -1,24 +1,25 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { jsxs as r } from "react/jsx-runtime";
|
|
1
|
+
import { cn as e } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
2
|
+
import { OptionRow as t } from "./index17.js";
|
|
3
|
+
import { jsx as n, jsxs as r } from "react/jsx-runtime";
|
|
4
|
+
import { CalendarIcon as i } from "lucide-react";
|
|
4
5
|
//#region ../../libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index18.js
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
});
|
|
6
|
+
function a({ selection: a, labels: o }) {
|
|
7
|
+
return a?.kind === "receiptDue" ? /* @__PURE__ */ n("span", {
|
|
8
|
+
className: "ttw:truncate",
|
|
9
|
+
children: o.paymentTermsReceiptDue
|
|
10
|
+
}) : a?.kind === "customDate" ? /* @__PURE__ */ r("span", {
|
|
11
|
+
className: "ttw:flex ttw:w-full ttw:min-w-0 ttw:items-center ttw:justify-between ttw:gap-2",
|
|
12
|
+
children: [/* @__PURE__ */ r("span", {
|
|
13
|
+
className: "ttw:flex ttw:min-w-0 ttw:items-center ttw:gap-1.5",
|
|
14
|
+
children: [/* @__PURE__ */ n(i, { className: e("ttw:size-4 ttw:shrink-0", !a.hasDate && "ttw:text-muted-foreground") }), /* @__PURE__ */ n("span", {
|
|
15
|
+
className: e("ttw:truncate", !a.hasDate && "ttw:text-muted-foreground"),
|
|
16
|
+
children: a.dateLabel
|
|
17
|
+
})]
|
|
18
|
+
}), /* @__PURE__ */ n("span", {
|
|
19
|
+
className: "ttw:shrink-0 ttw:text-xs ttw:text-muted-foreground",
|
|
20
|
+
children: o.paymentTermsCustomDate
|
|
21
|
+
})]
|
|
22
|
+
}) : a?.kind === "term" ? /* @__PURE__ */ n(t, { option: a.option }) : null;
|
|
22
23
|
}
|
|
23
24
|
//#endregion
|
|
24
|
-
export { a as
|
|
25
|
+
export { a as SelectionValue };
|
|
@@ -1,53 +1,4 @@
|
|
|
1
|
-
import { Ban as e, CalendarX2 as t, Check as n, ChevronsRight as r, CircleCheck as i, CircleSlash as a, CircleX as o, ClipboardCheck as s, Clock as c, CopyPlus as l, Mail as u, Pause as d, PenTool as f, Pencil as p, Play as m, Trash2 as h } from "lucide-react";
|
|
2
1
|
//#region ../../libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index19.js
|
|
3
|
-
var
|
|
4
|
-
edit: "editButton",
|
|
5
|
-
issue: "issueButton",
|
|
6
|
-
recordPayment: "recordPaymentButton",
|
|
7
|
-
send: "sendButton",
|
|
8
|
-
accept: "acceptButton",
|
|
9
|
-
decline: "declineButton",
|
|
10
|
-
markPaid: "markPaidButton",
|
|
11
|
-
markUncollectible: "markUncollectibleButton",
|
|
12
|
-
cancel: "cancelButton",
|
|
13
|
-
clone: "cloneButton",
|
|
14
|
-
delete: "deleteButton",
|
|
15
|
-
pauseRecurrence: "pauseRecurrenceButton",
|
|
16
|
-
resumeRecurrence: "resumeRecurrenceButton",
|
|
17
|
-
cancelRecurrence: "cancelRecurrenceButton"
|
|
18
|
-
}, _ = {
|
|
19
|
-
edit: p,
|
|
20
|
-
issue: u,
|
|
21
|
-
recordPayment: s,
|
|
22
|
-
send: u,
|
|
23
|
-
accept: i,
|
|
24
|
-
decline: o,
|
|
25
|
-
markPaid: i,
|
|
26
|
-
markUncollectible: a,
|
|
27
|
-
cancel: e,
|
|
28
|
-
clone: l,
|
|
29
|
-
delete: h,
|
|
30
|
-
pauseRecurrence: d,
|
|
31
|
-
resumeRecurrence: m,
|
|
32
|
-
cancelRecurrence: t
|
|
33
|
-
}, v = {
|
|
34
|
-
draft: f,
|
|
35
|
-
issuing: c,
|
|
36
|
-
issued: c,
|
|
37
|
-
partially_paid: c,
|
|
38
|
-
paid: n,
|
|
39
|
-
overdue: c,
|
|
40
|
-
canceled: e
|
|
41
|
-
}, y = {
|
|
42
|
-
forward: r,
|
|
43
|
-
pause: d,
|
|
44
|
-
ban: e,
|
|
45
|
-
check: n
|
|
46
|
-
}, b = {
|
|
47
|
-
default: "ttw:text-foreground",
|
|
48
|
-
danger: "ttw:text-red-600",
|
|
49
|
-
success: "ttw:text-emerald-600",
|
|
50
|
-
muted: "ttw:text-muted-foreground"
|
|
51
|
-
}, x = "ttw:bg-muted ttw:text-muted-foreground ttw:hover:bg-accent";
|
|
2
|
+
var e = "receipt_due", t = "custom";
|
|
52
3
|
//#endregion
|
|
53
|
-
export {
|
|
4
|
+
export { t as RECEIVABLE_PAYMENT_TERMS_CUSTOM_DATE, e as RECEIVABLE_PAYMENT_TERMS_RECEIPT_DUE };
|
|
@@ -1,18 +1,33 @@
|
|
|
1
|
+
import { AMOUNT_FILTER_LABELS_EN as e, DATE_RANGE_PICKER_LABELS_EN as t, FILTER_MENU_BUTTON_LABELS_EN as n, FILTER_TAG_LABELS_EN as r } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
1
2
|
//#region ../../libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index2.js
|
|
2
|
-
var
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
3
|
+
var i = {
|
|
4
|
+
fields: {
|
|
5
|
+
dueDate: "Due date",
|
|
6
|
+
createdAt: "Created on",
|
|
7
|
+
issueDate: "Issue date",
|
|
8
|
+
status: "Status",
|
|
9
|
+
amount: "Amount",
|
|
10
|
+
customer: "Customer"
|
|
11
|
+
},
|
|
12
|
+
searchPlaceholder: "Search by number or customer...",
|
|
13
|
+
searchLabel: "Search invoices",
|
|
14
|
+
amountMin: "No less than",
|
|
15
|
+
amountMax: "No more than",
|
|
16
|
+
customerNameHeading: "Customer name",
|
|
17
|
+
customerSearchPlaceholder: "Search customers...",
|
|
18
|
+
customerSearchHint: "Matches names containing your search",
|
|
19
|
+
clearAll: "Clear all",
|
|
20
|
+
filterMenuButton: n,
|
|
21
|
+
filterTag: r,
|
|
22
|
+
amountFilter: {
|
|
23
|
+
modeAny: e.modeAny,
|
|
24
|
+
modeExact: e.modeExact,
|
|
25
|
+
modeRange: e.modeRange,
|
|
26
|
+
flowAny: e.flowAny,
|
|
27
|
+
flowIn: e.flowIn,
|
|
28
|
+
flowOut: e.flowOut
|
|
29
|
+
},
|
|
30
|
+
dateRangePicker: { presetPlaceholder: t.presetPlaceholder }
|
|
16
31
|
};
|
|
17
32
|
//#endregion
|
|
18
|
-
export {
|
|
33
|
+
export { i as INVOICES_FILTER_BAR_LABELS_EN };
|
|
@@ -1,19 +1,95 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { Field as e, FieldContent as t, FieldDescription as n, FieldError as r, FieldLabel as i, Popover as a, PopoverAnchor as o, PopoverContent as s, Select as c, SelectContent as l, SelectItem as u, SelectSeparator as d, SelectTrigger as f, SelectValue as p, Skeleton as m, Typography as h } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
2
|
+
import { RECEIVABLE_BILLING_SECTION_LABELS_EN as g } from "./index11.js";
|
|
3
|
+
import { RECEIVABLE_PAYMENT_TERMS_RECEIPT_DUE as _ } from "./index19.js";
|
|
4
|
+
import { OptionRow as v } from "./index17.js";
|
|
5
|
+
import { SelectionValue as y } from "./index18.js";
|
|
6
|
+
import { jsx as b, jsxs as x } from "react/jsx-runtime";
|
|
4
7
|
//#region ../../libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index20.js
|
|
5
|
-
function
|
|
6
|
-
let
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
8
|
+
function S({ idPrefix: S, paymentTerms: C, paymentTermsError: w, disabled: T, onPaymentTermsChange: E, onCustomDatePickerOpenChange: D, customDateCalendar: O, recurrenceSection: k, labels: A }) {
|
|
9
|
+
let j = {
|
|
10
|
+
...g,
|
|
11
|
+
...A
|
|
12
|
+
}, M = `${S}-payment-terms`, N = () => {
|
|
13
|
+
window.setTimeout(() => D(!0), 0);
|
|
14
|
+
};
|
|
15
|
+
return /* @__PURE__ */ x("div", {
|
|
16
|
+
className: "ttw:flex ttw:flex-col ttw:gap-2.5 ttw:rounded-xl ttw:border ttw:border-border ttw:p-6",
|
|
17
|
+
children: [/* @__PURE__ */ x("div", {
|
|
18
|
+
className: "ttw:flex ttw:flex-col ttw:gap-2.5 ttw:pb-4",
|
|
19
|
+
children: [/* @__PURE__ */ b(h, {
|
|
20
|
+
variant: "h4",
|
|
21
|
+
children: j.billingHeading
|
|
22
|
+
}), /* @__PURE__ */ b(h, {
|
|
23
|
+
variant: "body2",
|
|
24
|
+
color: "muted",
|
|
25
|
+
className: "ttw:font-medium",
|
|
26
|
+
children: j.billingDescription
|
|
27
|
+
})]
|
|
28
|
+
}), /* @__PURE__ */ x("div", {
|
|
29
|
+
className: "ttw:flex ttw:flex-col ttw:gap-6",
|
|
30
|
+
children: [k, /* @__PURE__ */ b("div", {
|
|
31
|
+
className: "ttw:flex ttw:w-full ttw:items-start ttw:gap-2.5",
|
|
32
|
+
children: C.kind === "loading" ? /* @__PURE__ */ b(m, { className: "ttw:h-9 ttw:w-full" }) : /* @__PURE__ */ b(e, { children: /* @__PURE__ */ x(t, { children: [
|
|
33
|
+
/* @__PURE__ */ b(i, {
|
|
34
|
+
htmlFor: M,
|
|
35
|
+
children: j.paymentTermsLabel
|
|
36
|
+
}),
|
|
37
|
+
/* @__PURE__ */ x(a, {
|
|
38
|
+
open: C.customDatePicker.open,
|
|
39
|
+
onOpenChange: D,
|
|
40
|
+
children: [/* @__PURE__ */ x(c, {
|
|
41
|
+
disabled: T,
|
|
42
|
+
value: C.value,
|
|
43
|
+
onValueChange: (e) => {
|
|
44
|
+
E(e), e === "custom" && N();
|
|
45
|
+
},
|
|
46
|
+
children: [/* @__PURE__ */ b(o, {
|
|
47
|
+
className: "ttw:w-full",
|
|
48
|
+
children: /* @__PURE__ */ b(f, {
|
|
49
|
+
id: M,
|
|
50
|
+
className: "ttw:w-full",
|
|
51
|
+
"aria-invalid": !!w,
|
|
52
|
+
children: /* @__PURE__ */ b(p, {
|
|
53
|
+
placeholder: j.paymentTermsPlaceholder,
|
|
54
|
+
children: /* @__PURE__ */ b(y, {
|
|
55
|
+
selection: C.selection,
|
|
56
|
+
labels: j
|
|
57
|
+
})
|
|
58
|
+
})
|
|
59
|
+
})
|
|
60
|
+
}), /* @__PURE__ */ x(l, { children: [
|
|
61
|
+
/* @__PURE__ */ b(u, {
|
|
62
|
+
value: _,
|
|
63
|
+
children: j.paymentTermsReceiptDue
|
|
64
|
+
}),
|
|
65
|
+
C.showCustomDate && /* @__PURE__ */ b(u, {
|
|
66
|
+
value: "custom",
|
|
67
|
+
onPointerUp: N,
|
|
68
|
+
onClick: N,
|
|
69
|
+
onKeyDown: (e) => {
|
|
70
|
+
(e.key === "Enter" || e.key === " ") && N();
|
|
71
|
+
},
|
|
72
|
+
children: j.paymentTermsCustomDate
|
|
73
|
+
}),
|
|
74
|
+
/* @__PURE__ */ b(d, {}),
|
|
75
|
+
C.options.map((e) => /* @__PURE__ */ b(u, {
|
|
76
|
+
value: e.value,
|
|
77
|
+
children: /* @__PURE__ */ b(v, { option: e })
|
|
78
|
+
}, e.value))
|
|
79
|
+
] })]
|
|
80
|
+
}), /* @__PURE__ */ b(s, {
|
|
81
|
+
className: "ttw:w-auto ttw:overflow-hidden ttw:p-0",
|
|
82
|
+
align: "start",
|
|
83
|
+
onFocusOutside: (e) => e.preventDefault(),
|
|
84
|
+
children: O
|
|
85
|
+
})]
|
|
86
|
+
}),
|
|
87
|
+
C.description && /* @__PURE__ */ b(n, { children: C.description }),
|
|
88
|
+
/* @__PURE__ */ b(r, { errors: w ? [{ message: w }] : [] })
|
|
89
|
+
] }) })
|
|
90
|
+
})]
|
|
15
91
|
})]
|
|
16
92
|
});
|
|
17
93
|
}
|
|
18
94
|
//#endregion
|
|
19
|
-
export {
|
|
95
|
+
export { S as ReceivableBillingSection, S as default };
|
|
@@ -1,10 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
lineItems: "line-items",
|
|
5
|
-
notes: "notes",
|
|
6
|
-
attachments: "attachments",
|
|
7
|
-
auditHistory: "audit-history"
|
|
8
|
-
};
|
|
9
|
-
//#endregion
|
|
10
|
-
export { e as RECEIVABLE_DETAILS_SECTION };
|
|
1
|
+
import "./index11.js";
|
|
2
|
+
import "./index19.js";
|
|
3
|
+
import "./index20.js";
|
|
@@ -1,73 +1,24 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { Check as c } from "lucide-react";
|
|
1
|
+
import { Badge as e, cn as t } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
2
|
+
import { RECEIVABLE_STATUS_BADGE_LABELS_EN as n } from "./index13.js";
|
|
3
|
+
import { jsxs as r } from "react/jsx-runtime";
|
|
5
4
|
//#region ../../libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index22.js
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
children: u.attachmentsEmpty
|
|
23
|
-
}) : /* @__PURE__ */ s("table", {
|
|
24
|
-
className: "ttw:w-full ttw:border-collapse",
|
|
25
|
-
children: [/* @__PURE__ */ o("thead", { children: /* @__PURE__ */ s("tr", {
|
|
26
|
-
className: "ttw:border-b ttw:border-border",
|
|
27
|
-
children: [/* @__PURE__ */ o("th", {
|
|
28
|
-
scope: "col",
|
|
29
|
-
className: "ttw:py-2 ttw:text-left",
|
|
30
|
-
children: /* @__PURE__ */ o(i, {
|
|
31
|
-
component: "span",
|
|
32
|
-
variant: "caption",
|
|
33
|
-
color: "muted",
|
|
34
|
-
children: u.attachmentsFileColumn
|
|
35
|
-
})
|
|
36
|
-
}), /* @__PURE__ */ o("th", {
|
|
37
|
-
scope: "col",
|
|
38
|
-
className: "ttw:py-2 ttw:text-right",
|
|
39
|
-
children: /* @__PURE__ */ o(i, {
|
|
40
|
-
component: "span",
|
|
41
|
-
variant: "caption",
|
|
42
|
-
color: "muted",
|
|
43
|
-
children: u.attachmentsEmailedColumn
|
|
44
|
-
})
|
|
45
|
-
})]
|
|
46
|
-
}) }), /* @__PURE__ */ o("tbody", { children: l.rows.map((e) => /* @__PURE__ */ s("tr", {
|
|
47
|
-
className: "ttw:border-b ttw:border-border ttw:last:border-b-0",
|
|
48
|
-
children: [/* @__PURE__ */ o("td", {
|
|
49
|
-
className: "ttw:py-3",
|
|
50
|
-
children: /* @__PURE__ */ o("a", {
|
|
51
|
-
href: e.url,
|
|
52
|
-
target: "_blank",
|
|
53
|
-
rel: "noreferrer",
|
|
54
|
-
className: "ttw:text-primary ttw:hover:underline",
|
|
55
|
-
children: e.name
|
|
56
|
-
})
|
|
57
|
-
}), /* @__PURE__ */ o("td", {
|
|
58
|
-
className: "ttw:py-3 ttw:text-right ttw:align-middle",
|
|
59
|
-
children: e.includeInEmail ? /* @__PURE__ */ o(c, {
|
|
60
|
-
role: "img",
|
|
61
|
-
"aria-label": e.emailedLabel,
|
|
62
|
-
className: "ttw:inline-block ttw:size-4 ttw:text-emerald-600"
|
|
63
|
-
}) : /* @__PURE__ */ o("span", {
|
|
64
|
-
className: "ttw:sr-only",
|
|
65
|
-
children: e.emailedLabel
|
|
66
|
-
})
|
|
67
|
-
})]
|
|
68
|
-
}, e.id)) })]
|
|
69
|
-
}) })]
|
|
5
|
+
var i = {
|
|
6
|
+
danger: "ttw:border-red-200 ttw:bg-red-50 ttw:text-red-700 ttw:hover:bg-red-50",
|
|
7
|
+
info: "ttw:border-blue-200 ttw:bg-blue-50 ttw:text-blue-700 ttw:hover:bg-blue-50",
|
|
8
|
+
neutral: "ttw:border-border ttw:bg-muted ttw:text-foreground ttw:hover:bg-muted",
|
|
9
|
+
success: "ttw:border-emerald-200 ttw:bg-emerald-50 ttw:text-emerald-700 ttw:hover:bg-emerald-50",
|
|
10
|
+
warning: "ttw:border-amber-200 ttw:bg-amber-50 ttw:text-amber-800 ttw:hover:bg-amber-50"
|
|
11
|
+
};
|
|
12
|
+
function a({ status: a, label: o, tone: s, labels: c, icon: l }) {
|
|
13
|
+
let u = {
|
|
14
|
+
...n,
|
|
15
|
+
...c
|
|
16
|
+
}, d = o ?? u[a] ?? u.unknown;
|
|
17
|
+
return /* @__PURE__ */ r(e, {
|
|
18
|
+
variant: "outline",
|
|
19
|
+
className: t(l && "ttw:gap-1", i[s]),
|
|
20
|
+
children: [l, d]
|
|
70
21
|
});
|
|
71
22
|
}
|
|
72
23
|
//#endregion
|
|
73
|
-
export {
|
|
24
|
+
export { a as ReceivableStatusBadge, a as default };
|