@tesouro/embedded-components-react 0.5.228 → 0.5.230

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 (85) hide show
  1. package/README.md +22 -21
  2. package/dist/index.d.ts +34 -1
  3. package/dist/index.js +1 -1
  4. package/dist/lib/ReceivablesWidget.d.ts +34 -1
  5. package/dist/lib/ReceivablesWidget.js +1 -1
  6. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/data-access/dist/index.js +1 -1
  7. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/data-access/dist/index11.js +1 -1
  8. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/data-access/dist/index5.js +32 -33
  9. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/data-access/dist/index6.js +34 -32
  10. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/data-access/dist/index7.js +1 -1
  11. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index.js +1 -1
  12. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index10.js +120 -52
  13. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index11.js +44 -100
  14. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index12.js +93 -337
  15. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index13.js +356 -211
  16. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index14.js +225 -157
  17. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index15.js +152 -21
  18. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index16.js +18 -221
  19. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index17.js +224 -56
  20. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index18.js +126 -231
  21. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index19.js +53 -298
  22. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index20.js +232 -43
  23. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index21.js +295 -118
  24. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index22.js +38 -145
  25. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index23.js +126 -46
  26. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index24.js +145 -117
  27. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index25.js +38 -91
  28. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index26.js +113 -107
  29. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index27.js +94 -27
  30. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index28.js +104 -619
  31. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index29.js +34 -41
  32. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index30.js +635 -34
  33. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index31.js +39 -77
  34. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index32.js +34 -117
  35. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index33.js +75 -318
  36. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index34.js +139 -0
  37. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index35.js +340 -0
  38. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index5.js +1 -1
  39. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index8.js +55 -468
  40. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index9.js +443 -97
  41. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index.js +24 -21
  42. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index10.js +32 -2
  43. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index11.js +205 -84
  44. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index12.js +161 -3
  45. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index13.js +12 -20
  46. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index14.js +23 -40
  47. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index15.js +2 -17
  48. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index16.js +90 -68
  49. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index17.js +3 -20
  50. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index18.js +20 -12
  51. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index19.js +40 -30
  52. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index2.js +14 -7
  53. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index20.js +15 -301
  54. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index21.js +73 -1
  55. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index22.js +17 -45
  56. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index23.js +12 -68
  57. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index24.js +26 -490
  58. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index25.js +294 -95
  59. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index26.js +1 -0
  60. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index27.js +48 -2
  61. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index28.js +72 -4
  62. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index29.js +496 -1
  63. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index3.js +121 -27
  64. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index30.js +97 -91
  65. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index32.js +2 -236
  66. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index33.js +3 -2
  67. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index34.js +1 -249
  68. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index35.js +89 -82
  69. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index36.js +23 -54
  70. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index37.js +223 -340
  71. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index38.js +3 -0
  72. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index39.js +249 -0
  73. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index4.js +100 -216
  74. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index40.js +93 -0
  75. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index41.js +59 -0
  76. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index42.js +353 -0
  77. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index5.js +35 -29
  78. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index6.js +2 -216
  79. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index7.js +9 -159
  80. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index8.js +27 -14
  81. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index9.js +216 -23
  82. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
  83. package/dist/libs/tesouro-embedded-components-react/shared/product-catalog/feature/dist/index.js +12 -12
  84. package/package.json +1 -1
  85. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index31.js +0 -28
@@ -1 +1,73 @@
1
- import "./index20.js";
1
+ import { AccordionContent as e, AccordionItem as t, AccordionTrigger as n, Badge as r, Typography as i } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
2
+ import { jsx as a, jsxs as o } from "react/jsx-runtime";
3
+ import { Check as s } from "lucide-react";
4
+ //#region ../../libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index21.js
5
+ var c = "attachments";
6
+ function l({ attachments: l, labels: u }) {
7
+ return /* @__PURE__ */ o(t, {
8
+ value: c,
9
+ children: [/* @__PURE__ */ a(n, { children: /* @__PURE__ */ o("span", {
10
+ className: "ttw:flex ttw:items-center ttw:gap-2",
11
+ children: [/* @__PURE__ */ a("span", {
12
+ className: "ttw:group-hover:underline",
13
+ children: u.attachmentsHeading
14
+ }), /* @__PURE__ */ a(r, {
15
+ variant: "secondary",
16
+ className: "ttw:rounded-full",
17
+ children: l.countLabel
18
+ })]
19
+ }) }), /* @__PURE__ */ a(e, { children: l.rows.length === 0 ? /* @__PURE__ */ a(i, {
20
+ variant: "body2",
21
+ color: "muted",
22
+ children: u.attachmentsEmpty
23
+ }) : /* @__PURE__ */ o("table", {
24
+ className: "ttw:w-full ttw:border-collapse",
25
+ children: [/* @__PURE__ */ a("thead", { children: /* @__PURE__ */ o("tr", {
26
+ className: "ttw:border-b ttw:border-border",
27
+ children: [/* @__PURE__ */ a("th", {
28
+ scope: "col",
29
+ className: "ttw:py-2 ttw:text-left",
30
+ children: /* @__PURE__ */ a(i, {
31
+ component: "span",
32
+ variant: "caption",
33
+ color: "muted",
34
+ children: u.attachmentsFileColumn
35
+ })
36
+ }), /* @__PURE__ */ a("th", {
37
+ scope: "col",
38
+ className: "ttw:py-2 ttw:text-right",
39
+ children: /* @__PURE__ */ a(i, {
40
+ component: "span",
41
+ variant: "caption",
42
+ color: "muted",
43
+ children: u.attachmentsEmailedColumn
44
+ })
45
+ })]
46
+ }) }), /* @__PURE__ */ a("tbody", { children: l.rows.map((e) => /* @__PURE__ */ o("tr", {
47
+ className: "ttw:border-b ttw:border-border ttw:last:border-b-0",
48
+ children: [/* @__PURE__ */ a("td", {
49
+ className: "ttw:py-3",
50
+ children: /* @__PURE__ */ a("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__ */ a("td", {
58
+ className: "ttw:py-3 ttw:text-right ttw:align-middle",
59
+ children: e.includeInEmail ? /* @__PURE__ */ a(s, {
60
+ role: "img",
61
+ "aria-label": e.emailedLabel,
62
+ className: "ttw:inline-block ttw:size-4 ttw:text-emerald-600"
63
+ }) : /* @__PURE__ */ a("span", {
64
+ className: "ttw:sr-only",
65
+ children: e.emailedLabel
66
+ })
67
+ })]
68
+ }, e.id)) })]
69
+ }) })]
70
+ });
71
+ }
72
+ //#endregion
73
+ export { c as ATTACHMENTS_ITEM_VALUE, l as AttachmentsItem };
@@ -1,48 +1,20 @@
1
- import { cn as e } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
2
- import { jsx as t, jsxs as n } from "react/jsx-runtime";
1
+ import { Button as e } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
2
+ import { forwardRef as t } from "react";
3
+ import { jsx as n } from "react/jsx-runtime";
4
+ import { XIcon as r } from "lucide-react";
3
5
  //#region ../../libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index22.js
4
- function r({ label: r, value: i, className: a }) {
5
- return /* @__PURE__ */ n("li", {
6
- className: e("ttw:flex ttw:items-center ttw:justify-between", a),
7
- children: [/* @__PURE__ */ t("span", { children: r }), /* @__PURE__ */ t("span", { children: i })]
6
+ var i = t(function({ label: t, onClose: i, variant: a = "ghost", size: o = "icon", onClick: s, ...c }, l) {
7
+ return /* @__PURE__ */ n(e, {
8
+ ref: l,
9
+ variant: a,
10
+ size: o,
11
+ ...c,
12
+ "aria-label": t,
13
+ onClick: (e) => {
14
+ s?.(e), i();
15
+ },
16
+ children: /* @__PURE__ */ n(r, { className: "ttw:size-4" })
8
17
  });
9
- }
10
- function i({ totals: e, labels: i }) {
11
- return /* @__PURE__ */ n("ul", {
12
- className: "ttw:flex ttw:w-full ttw:list-none ttw:flex-col ttw:gap-1.5",
13
- children: [
14
- /* @__PURE__ */ t(r, {
15
- label: i.subtotalLabel,
16
- value: e.subtotal,
17
- className: "ttw:text-sm ttw:font-normal"
18
- }),
19
- /* @__PURE__ */ t(r, {
20
- label: i.discountTotalLabel,
21
- value: e.discount,
22
- className: "ttw:text-sm ttw:font-normal"
23
- }),
24
- /* @__PURE__ */ t(r, {
25
- label: i.nonTaxableSubtotalLabel,
26
- value: e.nonTaxableSubtotal,
27
- className: "ttw:text-sm ttw:font-normal ttw:text-muted-foreground"
28
- }),
29
- /* @__PURE__ */ t(r, {
30
- label: i.taxableSubtotalLabel,
31
- value: e.taxableSubtotal,
32
- className: "ttw:text-sm ttw:font-normal ttw:text-muted-foreground"
33
- }),
34
- /* @__PURE__ */ t(r, {
35
- label: i.taxTotalLabel,
36
- value: e.tax,
37
- className: "ttw:text-sm ttw:font-normal"
38
- }),
39
- /* @__PURE__ */ t(r, {
40
- label: i.totalLabel,
41
- value: e.total,
42
- className: "ttw:text-lg ttw:font-medium"
43
- })
44
- ]
45
- });
46
- }
18
+ });
47
19
  //#endregion
48
- export { i as ReceivableFormTotals };
20
+ export { i as CloseButton };
@@ -1,72 +1,16 @@
1
- import { Field as e, FieldContent as t, FieldDescription as n, FieldError as r, FieldLabel as i, Textarea as a, Typography as o } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
2
- import { jsx as s, jsxs as c } from "react/jsx-runtime";
1
+ import { jsx as e, jsxs as t } from "react/jsx-runtime";
3
2
  //#region ../../libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index23.js
4
- function l({ id: l, value: u, error: d, disabled: f, label: p, optionalSuffix: m, placeholder: h, description: g, onChange: _ }) {
5
- return /* @__PURE__ */ s(e, { children: /* @__PURE__ */ c(t, { children: [
6
- /* @__PURE__ */ c(i, {
7
- htmlFor: l,
8
- className: "ttw:text-nowrap",
9
- children: [p, /* @__PURE__ */ s(o, {
10
- variant: "body2",
11
- component: "span",
12
- color: "muted",
13
- className: "ttw:leading-snug",
14
- children: m
15
- })]
16
- }),
17
- /* @__PURE__ */ s(a, {
18
- id: l,
19
- value: u,
20
- disabled: f,
21
- placeholder: h,
22
- className: "ttw:h-26 ttw:resize-none",
23
- "aria-invalid": !!d,
24
- onChange: (e) => _(e.target.value)
25
- }),
26
- /* @__PURE__ */ s(n, { children: g }),
27
- /* @__PURE__ */ s(r, { errors: d ? [{ message: d }] : [] })
28
- ] }) });
29
- }
30
- function u({ idPrefix: e, openingNote: t, closingNote: n, openingNoteError: r, closingNoteError: i, disabled: a, onOpeningNoteChange: u, onClosingNoteChange: d, labels: f }) {
31
- return /* @__PURE__ */ c("div", {
32
- className: "ttw:flex ttw:flex-col ttw:gap-2.5 ttw:rounded-xl ttw:border ttw:border-border ttw:p-6",
33
- children: [
34
- /* @__PURE__ */ c("div", {
35
- className: "ttw:flex ttw:flex-col ttw:gap-2.5 ttw:pb-4",
36
- children: [/* @__PURE__ */ s(o, {
37
- variant: "h4",
38
- children: f.notesHeading
39
- }), /* @__PURE__ */ s(o, {
40
- variant: "body2",
41
- color: "muted",
42
- className: "ttw:font-medium",
43
- children: f.notesDescription
44
- })]
45
- }),
46
- /* @__PURE__ */ s(l, {
47
- id: `${e}-opening-note`,
48
- value: t,
49
- error: r,
50
- disabled: a,
51
- label: f.openingNoteLabel,
52
- optionalSuffix: f.optionalSuffix,
53
- placeholder: f.openingNotePlaceholder,
54
- description: f.openingNoteDescription,
55
- onChange: u
56
- }),
57
- /* @__PURE__ */ s(l, {
58
- id: `${e}-closing-note`,
59
- value: n,
60
- error: i,
61
- disabled: a,
62
- label: f.closingNoteLabel,
63
- optionalSuffix: f.optionalSuffix,
64
- placeholder: f.closingNotePlaceholder,
65
- description: f.closingNoteDescription,
66
- onChange: d
67
- })
68
- ]
3
+ function n({ label: n, value: r }) {
4
+ return /* @__PURE__ */ t("div", {
5
+ className: "ttw:flex ttw:gap-4 ttw:border-b ttw:border-border ttw:py-3 ttw:text-sm ttw:last:border-b-0",
6
+ children: [/* @__PURE__ */ e("span", {
7
+ className: "ttw:w-40 ttw:shrink-0 ttw:text-muted-foreground",
8
+ children: n
9
+ }), /* @__PURE__ */ e("span", {
10
+ className: "ttw:whitespace-pre-line ttw:text-foreground",
11
+ children: r
12
+ })]
69
13
  });
70
14
  }
71
15
  //#endregion
72
- export { u as ReceivableNotesSection };
16
+ export { n as InfoRow };