@alfadocs/ui-kit 0.42.0 → 0.43.0

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 (84) hide show
  1. package/dist/_chunks/{ar-Cn_NxqkN.js → ar-DEz65ZJW.js} +2 -2
  2. package/dist/_chunks/bmi-calculator-DuVSFDuw.js +259 -0
  3. package/dist/_chunks/{booking-4mCw3Mpl.js → booking-CtLwaxkK.js} +4 -4
  4. package/dist/_chunks/{calculator-dialog-B74fqpFZ.js → calculator-dialog-DdexHrTP.js} +2 -2
  5. package/dist/_chunks/{chart-Cbt0_sKv.js → chart-Cg3e9EH9.js} +101 -99
  6. package/dist/_chunks/{cycle-calculator-DsZbyzX6.js → cycle-calculator-Dln-y1k_.js} +43 -42
  7. package/dist/_chunks/{date-picker-CvQfs6Xh.js → date-picker-Bq7xhMA-.js} +109 -108
  8. package/dist/_chunks/date-picker-variants-DLi1Va_e.js +3238 -0
  9. package/dist/_chunks/{date-range-picker-U9fn1g9d.js → date-range-picker-DcXuI9y7.js} +20 -19
  10. package/dist/_chunks/{date-time-picker-Cva0ZCWw.js → date-time-picker-RimumeLR.js} +18 -17
  11. package/dist/_chunks/{de-BMM2H7Bs.js → de-bTBGdjPS.js} +2 -2
  12. package/dist/_chunks/{dialog-Cee13rHU.js → dialog-DOYgd75U.js} +46 -37
  13. package/dist/_chunks/{due-date-calculator-s_CBgaFs.js → due-date-calculator-Cc4dRqTI.js} +46 -38
  14. package/dist/_chunks/{editable-currency-cell-renderer-BhUkRiPZ.js → editable-currency-cell-renderer-9jqwDv5x.js} +2 -2
  15. package/dist/_chunks/{el-BYPonAaK.js → el-BWG5RXxa.js} +6 -6
  16. package/dist/_chunks/{es-CMkVCQ4F.js → es-DfO_G435.js} +2 -2
  17. package/dist/_chunks/{fr-BcuWxqft.js → fr-BTn24bs8.js} +2 -2
  18. package/dist/_chunks/{gestation-BXEgDGmP.js → gestation-mWF4AXea.js} +3 -3
  19. package/dist/_chunks/{gestational-age-calculator-CWOG3bkI.js → gestational-age-calculator-ZMSrzkRW.js} +42 -41
  20. package/dist/_chunks/{header-CTZWX-tm.js → header-Ce1Br27u.js} +70 -75
  21. package/dist/_chunks/{hi-wkq_rQAh.js → hi-Dj3oYd84.js} +2 -2
  22. package/dist/_chunks/{insert-result-DtQQeSSf.js → insert-result-DisOY2G-.js} +91 -75
  23. package/dist/_chunks/{isSameWeek-Bim5ftRd.js → isSameWeek-HfxKk6Lz.js} +2 -2
  24. package/dist/_chunks/{it-GiQrQ9p4.js → it-Y85ofIQQ.js} +7 -7
  25. package/dist/_chunks/{ja-qfYg3Rua.js → ja-CQ7J6YoA.js} +2 -2
  26. package/dist/_chunks/{marketplace-app-shell-kVAVycz_.js → marketplace-app-shell-Dc5cTIt8.js} +186 -149
  27. package/dist/_chunks/{nl-xOogO4sZ.js → nl-D9kHCmp3.js} +2 -2
  28. package/dist/_chunks/{patient-shell-lDX3wwu6.js → patient-shell-CnT4L8gn.js} +2 -2
  29. package/dist/_chunks/{pl-GnOW6eGK.js → pl-B3Smqpkr.js} +3 -3
  30. package/dist/_chunks/{pregnancy-weight-gain-B7kBK-ZR.js → pregnancy-weight-gain-zZL5Ir2-.js} +49 -48
  31. package/dist/_chunks/{pt-_bV5b5RW.js → pt-D3J-1c_7.js} +6 -6
  32. package/dist/_chunks/{ro-BEcyh5Nj.js → ro-BKAbbEA3.js} +2 -2
  33. package/dist/_chunks/{ru-Bi86hqMf.js → ru-BeG8f0Ep.js} +3 -3
  34. package/dist/_chunks/{sign-document-QHfcNKFj.js → sign-document-B-3k_0LO.js} +165 -137
  35. package/dist/_chunks/{sq-BujHSAWu.js → sq-_hRPaeUy.js} +6 -6
  36. package/dist/_chunks/subDays-Dv7q9S7u.js +8 -0
  37. package/dist/_chunks/{sv-C8AeDrTA.js → sv-g009fSpe.js} +2 -2
  38. package/dist/_chunks/{tab-bar-C4II-7ej.js → tab-bar-Xetknddo.js} +53 -34
  39. package/dist/_chunks/{tr-CMSs_Vgf.js → tr-OKUOuhMW.js} +2 -2
  40. package/dist/_chunks/{unit-converter-D1UrEUxa.js → unit-converter-CuXCXJhK.js} +2 -2
  41. package/dist/_chunks/{zh-CN-eXB-PFu4.js → zh-CN-De4zwEhx.js} +3 -3
  42. package/dist/agent-catalog.json +1 -1
  43. package/dist/components/_shared/calendar-class-names.d.ts +8 -0
  44. package/dist/components/_shared/index.d.ts +2 -0
  45. package/dist/components/_shared/insert-result.d.ts +57 -2
  46. package/dist/components/badge/badge.d.ts +1 -1
  47. package/dist/components/bmi-calculator/index.js +1 -1
  48. package/dist/components/booking/index.js +1 -1
  49. package/dist/components/calculator-dialog/index.js +1 -1
  50. package/dist/components/card/card.d.ts +1 -1
  51. package/dist/components/chart/chart.d.ts +10 -0
  52. package/dist/components/chart/index.js +1 -1
  53. package/dist/components/cycle-calculator/index.js +1 -1
  54. package/dist/components/data-table/index.js +1 -1
  55. package/dist/components/date-picker/date-picker.d.ts +0 -1
  56. package/dist/components/date-picker/index.js +1 -1
  57. package/dist/components/date-range-picker/date-range-picker.d.ts +0 -1
  58. package/dist/components/date-range-picker/index.js +1 -1
  59. package/dist/components/date-time-picker/date-time-picker.d.ts +0 -1
  60. package/dist/components/date-time-picker/index.js +1 -1
  61. package/dist/components/dialog/index.js +1 -1
  62. package/dist/components/due-date-calculator/index.js +2 -2
  63. package/dist/components/gestational-age-calculator/index.js +1 -1
  64. package/dist/components/header/header.d.ts +8 -0
  65. package/dist/components/header/index.js +1 -1
  66. package/dist/components/index.d.ts +1 -1
  67. package/dist/components/pregnancy-weight-gain/index.js +1 -1
  68. package/dist/components/public-header/public-header.d.ts +1 -1
  69. package/dist/components/sign-document/index.js +1 -1
  70. package/dist/components/sign-document/sign-document.d.ts +12 -0
  71. package/dist/components/stat/stat.d.ts +1 -1
  72. package/dist/components/tab-bar/index.d.ts +1 -1
  73. package/dist/components/tab-bar/index.js +1 -1
  74. package/dist/components/tab-bar/tab-bar.d.ts +44 -1
  75. package/dist/components/unit-converter/index.js +1 -1
  76. package/dist/index.js +495 -494
  77. package/dist/patterns/marketplace-app-shell/index.js +1 -1
  78. package/dist/patterns/marketplace-app-shell/marketplace-app-shell.d.ts +57 -1
  79. package/dist/patterns/patient-shell/index.js +1 -1
  80. package/dist/tokens.css +1411 -2
  81. package/package.json +1 -1
  82. package/dist/_chunks/bmi-calculator-D4juUcyF.js +0 -219
  83. package/dist/_chunks/react-day-picker-CdtIiKjx.js +0 -3174
  84. package/dist/_chunks/subDays-_T9YeKPX.js +0 -8
@@ -1,15 +1,16 @@
1
1
  import { jsxs as r, jsx as e } from "react/jsx-runtime";
2
- import { forwardRef as F, useState as L, useMemo as x, useEffect as A } from "react";
3
- import { c as S } from "./index-D2ZczOXr.js";
4
- import { useTranslation as T } from "react-i18next";
2
+ import { forwardRef as A, useState as L, useMemo as v, useEffect as S } from "react";
3
+ import { c as T } from "./index-D2ZczOXr.js";
4
+ import { useTranslation as W } from "react-i18next";
5
5
  import { F as P } from "./form-field-BOm9hK35.js";
6
- import { D as W } from "./date-picker-CvQfs6Xh.js";
7
- import { N as $ } from "./number-input-Dj5L3pXK.js";
8
- import { B as v } from "./badge-zsf5i5bH.js";
9
- import { I as H } from "./insert-result-DtQQeSSf.js";
10
- import { a as i } from "./react-day-picker-CdtIiKjx.js";
11
- import { C as I } from "./check-DPdL_Sm7.js";
12
- import { H as z } from "./heart-C0faivFf.js";
6
+ import { D as $ } from "./date-picker-Bq7xhMA-.js";
7
+ import { N as H } from "./number-input-Dj5L3pXK.js";
8
+ import { C as w } from "./card-DPmk26CL.js";
9
+ import { B as x } from "./badge-zsf5i5bH.js";
10
+ import { I } from "./insert-result-DisOY2G-.js";
11
+ import { a as i } from "./date-picker-variants-DLi1Va_e.js";
12
+ import { C as z } from "./check-DPdL_Sm7.js";
13
+ import { H as B } from "./heart-C0faivFf.js";
13
14
  import { c as k } from "./createLucideIcon-CrFbzy84.js";
14
15
  /**
15
16
  * @license lucide-react v1.8.0 - ISC
@@ -17,7 +18,7 @@ import { c as k } from "./createLucideIcon-CrFbzy84.js";
17
18
  * This source code is licensed under the ISC license.
18
19
  * See the LICENSE file in the root directory of this source tree.
19
20
  */
20
- const B = [
21
+ const Y = [
21
22
  [
22
23
  "path",
23
24
  {
@@ -25,23 +26,23 @@ const B = [
25
26
  key: "c7niix"
26
27
  }
27
28
  ]
28
- ], Y = k("droplet", B), h = 28, j = 14, M = 1;
29
- function U(n, c = 3) {
30
- const d = n.cycleLength ?? h, { lastPeriodStart: s } = n, o = i(s, d - j), u = {
29
+ ], j = k("droplet", Y), h = 28, M = 14, U = 1;
30
+ function G(n, c = 3) {
31
+ const d = n.cycleLength ?? h, { lastPeriodStart: s } = n, o = i(s, d - M), u = {
31
32
  start: i(o, -5),
32
- end: i(o, M)
33
+ end: i(o, U)
33
34
  }, f = i(s, d), p = Array.from(
34
35
  { length: c },
35
36
  (C, g) => i(s, d * (g + 1))
36
37
  );
37
38
  return { nextPeriod: f, ovulation: o, fertileWindow: u, upcomingPeriods: p };
38
39
  }
39
- const G = S("ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", {
40
+ const V = T("ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", {
40
41
  variants: {
41
42
  width: { full: "ds:w-full", auto: "ds:inline-flex" }
42
43
  },
43
44
  defaultVariants: { width: "full" }
44
- }), V = F(
45
+ }), q = A(
45
46
  ({
46
47
  defaultCycleLength: n = h,
47
48
  onResultChange: c,
@@ -53,34 +54,34 @@ const G = S("ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", {
53
54
  width: p,
54
55
  className: C
55
56
  }, g) => {
56
- const { t: a, i18n: N } = T(), [m, w] = L(void 0), [y, b] = L(
57
+ const { t: a, i18n: N } = W(), [m, b] = L(void 0), [y, D] = L(
57
58
  n
58
- ), t = x(() => m ? U({
59
+ ), t = v(() => m ? G({
59
60
  lastPeriodStart: m,
60
61
  cycleLength: y ?? h
61
- }) : null, [m, y]), D = x(
62
+ }) : null, [m, y]), E = v(
62
63
  () => new Intl.DateTimeFormat(N.language, { dateStyle: "medium" }),
63
64
  [N.language]
64
65
  );
65
- A(() => {
66
+ S(() => {
66
67
  c == null || c(t);
67
68
  }, [t, c]);
68
- const E = x(() => /* @__PURE__ */ new Date(), []), l = (_) => D.format(_);
69
+ const _ = v(() => /* @__PURE__ */ new Date(), []), l = (F) => E.format(F);
69
70
  return /* @__PURE__ */ r(
70
71
  "div",
71
72
  {
72
73
  ref: g,
73
74
  "data-component": "cycle-calculator",
74
75
  "data-component-id": f,
75
- className: G({ width: p, className: C }),
76
+ className: V({ width: p, className: C }),
76
77
  children: [
77
78
  /* @__PURE__ */ r("div", { className: "ds:grid ds:grid-cols-1 ds:gap-[var(--spacing-md)] ds:sm:grid-cols-2", children: [
78
79
  /* @__PURE__ */ e(P, { label: a("cycleCalculator.lastPeriod"), children: /* @__PURE__ */ e(
79
- W,
80
+ $,
80
81
  {
81
82
  value: m,
82
- onChange: w,
83
- maxDate: E
83
+ onChange: b,
84
+ maxDate: _
84
85
  }
85
86
  ) }),
86
87
  /* @__PURE__ */ e(
@@ -89,13 +90,13 @@ const G = S("ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", {
89
90
  label: a("cycleCalculator.cycleLength"),
90
91
  description: a("cycleCalculator.cycleLengthHint"),
91
92
  children: /* @__PURE__ */ e(
92
- $,
93
+ H,
93
94
  {
94
95
  mode: "integer",
95
96
  min: 20,
96
97
  max: 45,
97
98
  value: y,
98
- onChange: b
99
+ onChange: D
99
100
  }
100
101
  )
101
102
  }
@@ -104,16 +105,16 @@ const G = S("ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", {
104
105
  /* @__PURE__ */ e("p", { className: "ds:sr-only", role: "status", "aria-live": "polite", children: t ? `${a("cycleCalculator.ovulation")}: ${l(t.ovulation)}. ${a(
105
106
  "cycleCalculator.nextPeriod"
106
107
  )}: ${l(t.nextPeriod)}.` : "" }),
107
- t ? /* @__PURE__ */ r("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
108
+ t ? /* @__PURE__ */ e(w, { variant: "elevated", children: /* @__PURE__ */ r(w.Body, { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
108
109
  /* @__PURE__ */ r("dl", { className: "ds:grid ds:grid-cols-1 ds:gap-[var(--spacing-md)] ds:sm:grid-cols-3", children: [
109
110
  /* @__PURE__ */ r("div", { className: "ds:flex ds:flex-col ds:items-center ds:gap-[var(--spacing-xs)] ds:text-center", children: [
110
111
  /* @__PURE__ */ e("dt", { className: "type-label ds:text-muted-foreground", children: a("cycleCalculator.ovulation") }),
111
112
  /* @__PURE__ */ e("dd", { children: /* @__PURE__ */ e(
112
- v,
113
+ x,
113
114
  {
114
115
  variant: "success",
115
116
  size: "lg",
116
- leading: /* @__PURE__ */ e(I, { "aria-hidden": !0 }),
117
+ leading: /* @__PURE__ */ e(z, { "aria-hidden": !0 }),
117
118
  children: l(t.ovulation)
118
119
  }
119
120
  ) })
@@ -121,11 +122,11 @@ const G = S("ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", {
121
122
  /* @__PURE__ */ r("div", { className: "ds:flex ds:flex-col ds:items-center ds:gap-[var(--spacing-xs)] ds:text-center", children: [
122
123
  /* @__PURE__ */ e("dt", { className: "type-label ds:text-muted-foreground", children: a("cycleCalculator.fertileWindow") }),
123
124
  /* @__PURE__ */ e("dd", { children: /* @__PURE__ */ r(
124
- v,
125
+ x,
125
126
  {
126
127
  variant: "accent",
127
128
  size: "lg",
128
- leading: /* @__PURE__ */ e(z, { "aria-hidden": !0 }),
129
+ leading: /* @__PURE__ */ e(B, { "aria-hidden": !0 }),
129
130
  children: [
130
131
  l(t.fertileWindow.start),
131
132
  " –",
@@ -138,18 +139,18 @@ const G = S("ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", {
138
139
  /* @__PURE__ */ r("div", { className: "ds:flex ds:flex-col ds:items-center ds:gap-[var(--spacing-xs)] ds:text-center", children: [
139
140
  /* @__PURE__ */ e("dt", { className: "type-label ds:text-muted-foreground", children: a("cycleCalculator.nextPeriod") }),
140
141
  /* @__PURE__ */ e("dd", { children: /* @__PURE__ */ e(
141
- v,
142
+ x,
142
143
  {
143
144
  variant: "error",
144
145
  size: "lg",
145
- leading: /* @__PURE__ */ e(Y, { "aria-hidden": !0 }),
146
+ leading: /* @__PURE__ */ e(j, { "aria-hidden": !0 }),
146
147
  children: l(t.nextPeriod)
147
148
  }
148
149
  ) })
149
150
  ] })
150
151
  ] }),
151
152
  s === "copy" || d ? /* @__PURE__ */ e(
152
- H,
153
+ I,
153
154
  {
154
155
  onInsert: d,
155
156
  variant: s,
@@ -176,16 +177,16 @@ const G = S("ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", {
176
177
  }
177
178
  }
178
179
  ) : null
179
- ] }) : /* @__PURE__ */ e("p", { className: "type-body ds:text-muted-foreground", children: a("cycleCalculator.empty") })
180
+ ] }) }) : /* @__PURE__ */ e("p", { className: "type-body ds:text-muted-foreground", children: a("cycleCalculator.empty") })
180
181
  ]
181
182
  }
182
183
  );
183
184
  }
184
185
  );
185
- V.displayName = "CycleCalculator";
186
+ q.displayName = "CycleCalculator";
186
187
  export {
187
- V as C,
188
- j as L,
189
- U as p
188
+ q as C,
189
+ M as L,
190
+ G as p
190
191
  };
191
- //# sourceMappingURL=cycle-calculator-DsZbyzX6.js.map
192
+ //# sourceMappingURL=cycle-calculator-Dln-y1k_.js.map