@alfadocs/ui-kit 0.25.1 → 0.30.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 (205) hide show
  1. package/dist/_chunks/{agenda-card-BmpaUG1h.js → agenda-card-CznB7K8e.js} +2 -2
  2. package/dist/_chunks/{agenda-tray-DiInnVqk.js → agenda-tray-C_bha7oK.js} +4 -4
  3. package/dist/_chunks/{ai-prompt-input-B5MdixzR.js → ai-prompt-input-Bka3jX3i.js} +2 -2
  4. package/dist/_chunks/{alia-sidebar-CUi2UCbY.js → alia-sidebar-CnvXq95r.js} +92 -109
  5. package/dist/_chunks/{audio-recorder-D4xM3H5i.js → audio-recorder-OB6IV9B1.js} +2 -2
  6. package/dist/_chunks/{autocomplete-C7xq06bP.js → autocomplete-CUh0f7Dj.js} +2 -2
  7. package/dist/_chunks/{avatar-BpFohgWG.js → avatar-D_H4emLo.js} +7 -7
  8. package/dist/_chunks/{benefit-card-DXmrAyfn.js → benefit-card-CjYM8vNr.js} +29 -29
  9. package/dist/_chunks/booking-BYuc_8HV.js +2250 -0
  10. package/dist/_chunks/{calendar-zy0tUUVG.js → calendar-WWNx448i.js} +114 -142
  11. package/dist/_chunks/{card-C353dU-H.js → card-DKTMLVrw.js} +11 -11
  12. package/dist/_chunks/{carousel.agent-DnPiqijR.js → carousel.agent-C9swH-Uf.js} +2 -2
  13. package/dist/_chunks/{chat-input-B3XmFGDw.js → chat-input-BfDcz1Yi.js} +2 -2
  14. package/dist/_chunks/{chat-message-W3k8rLOA.js → chat-message-fg221-yx.js} +2 -2
  15. package/dist/_chunks/{command-palette-DkL-aW4O.js → command-palette-11BieSNq.js} +2 -2
  16. package/dist/_chunks/{contact-card-CjG7c-1q.js → contact-card-DYbp--s-.js} +3 -3
  17. package/dist/_chunks/{date-picker-BIoSLRly.js → date-picker-D0Ry1dMz.js} +26 -27
  18. package/dist/_chunks/{date-range-picker-9gANFNG9.js → date-range-picker-DYgHzMOo.js} +19 -20
  19. package/dist/_chunks/{date-time-picker-DG7BiGdb.js → date-time-picker-CGmGtcyc.js} +10 -11
  20. package/dist/_chunks/{description-list-Bsga4IW8.js → description-list-yl3y3QKg.js} +34 -24
  21. package/dist/_chunks/{dialog-DUomPCRS.js → dialog-BBXqpZIt.js} +2 -2
  22. package/dist/_chunks/{editable-currency-cell-renderer-DJB5MxAI.js → editable-currency-cell-renderer-DSReCae7.js} +7 -7
  23. package/dist/_chunks/{empty-state-3CLJIXSj.js → empty-state-BLy7tigq.js} +13 -33
  24. package/dist/_chunks/eye-LHlSU38h.js +21 -0
  25. package/dist/_chunks/{freemium-paywall-CM6V1zNf.js → freemium-paywall-B9c8Ylww.js} +11 -11
  26. package/dist/_chunks/{header-DqmKROIY.js → header-CkMb1TZS.js} +24 -24
  27. package/dist/_chunks/heart-pulse-CvuyFKHB.js +21 -0
  28. package/dist/_chunks/icon-button-BRHSSFmZ.js +70 -0
  29. package/dist/_chunks/{isSameDay-ecuM8PBB.js → isSameDay-DHG8Xade.js} +4 -4
  30. package/dist/_chunks/{key-value-pair-DBuOCtIc.js → key-value-pair-CqeKiP__.js} +2 -2
  31. package/dist/_chunks/{link-DmM5IevO.js → link-DrD_cRUg.js} +50 -45
  32. package/dist/_chunks/{locale-picker-BxEUUPW7.js → locale-picker-BHxbTNmR.js} +297 -208
  33. package/dist/_chunks/{map-view-CcwycFQX.js → map-view-DyB8tr6c.js} +9 -9
  34. package/dist/_chunks/{matrix-rain-CRPMXcVx.js → matrix-rain-sDOUUwZp.js} +35 -35
  35. package/dist/_chunks/{message-card-i61k1TGc.js → message-card-DjRtA8GG.js} +3 -3
  36. package/dist/_chunks/{message-tray-DrV7G-wR.js → message-tray-DfsAMncP.js} +3 -3
  37. package/dist/_chunks/monitor-D-SFdbrU.js +16 -0
  38. package/dist/_chunks/{notification-card-ejOw5g6g.js → notification-card-B_847w5g.js} +3 -3
  39. package/dist/_chunks/{notification-tray-D_69dXFY.js → notification-tray-6f7smmT1.js} +22 -19
  40. package/dist/_chunks/parseISO-Dk4xa7q6.js +120 -0
  41. package/dist/_chunks/patient-search-BhlxYAI3.js +1102 -0
  42. package/dist/_chunks/patient-shell-CAXYzbRw.js +173 -0
  43. package/dist/_chunks/{payment-form-F7uh0Rqr.js → payment-form-Ds3rxvad.js} +2 -2
  44. package/dist/_chunks/{pdf-viewer-CuYaVR1I.js → pdf-viewer-CIuaocnq.js} +2 -2
  45. package/dist/_chunks/{popover--derJ_wq.js → popover-D0slaBB9.js} +17 -13
  46. package/dist/_chunks/{privacy-lock-BKsI6ReN.js → privacy-lock-BI4vi9Ud.js} +2 -2
  47. package/dist/_chunks/public-footer.agent-CA29gxHJ.js +516 -0
  48. package/dist/_chunks/{public-header.agent-BQ3r6Hgq.js → public-header.agent-5U3S9QiC.js} +49 -41
  49. package/dist/_chunks/react-day-picker-D3yzgvDB.js +3127 -0
  50. package/dist/_chunks/{recaptcha-widget-Kp1XntuE.js → recaptcha-widget-BtBNb6tB.js} +2 -2
  51. package/dist/_chunks/reviews-panel-CFttsfuC.js +513 -0
  52. package/dist/_chunks/{search-bar-DORSAzNt.js → search-bar-BRMW1-WG.js} +2 -2
  53. package/dist/_chunks/{search-input-BtEJAJHa.js → search-input-CIA6pPfn.js} +2 -2
  54. package/dist/_chunks/{sheet-BT0izeoI.js → sheet-D8M8hf8B.js} +2 -2
  55. package/dist/_chunks/{sign-in-with-alfadocs-button-4zZC-I6y.js → sign-in-with-alfadocs-button-BI0fVonM.js} +2 -2
  56. package/dist/_chunks/slot-grid-B2zprPcv.js +387 -0
  57. package/dist/_chunks/sparkles-CuYXqQLg.js +23 -0
  58. package/dist/_chunks/{spinner-DirtWZNG.js → spinner-CCByyvcb.js} +2 -2
  59. package/dist/_chunks/stepper-accordion-BfS6lUB9.js +257 -0
  60. package/dist/_chunks/stepper-accordion.agent-C4quJ-MD.js +71 -0
  61. package/dist/_chunks/stethoscope-DT5qCW8Y.js +18 -0
  62. package/dist/_chunks/{sun-Eweh5fvi.js → sun-BuXE0xUS.js} +3 -15
  63. package/dist/_chunks/{task-tray-B3A2fRGR.js → task-tray-Bcmrrs8m.js} +3 -3
  64. package/dist/_chunks/{theme-toggle-FrotC2VI.js → theme-toggle-nPzb378f.js} +37 -36
  65. package/dist/_chunks/{timeline-jmd7lfDf.js → timeline-CR7HjZCK.js} +3 -3
  66. package/dist/_chunks/{toast.agent-32WNQ-_x.js → toast.agent-CTF6nIj5.js} +2 -2
  67. package/dist/_chunks/{transcript-panel-DUrjx5sa.js → transcript-panel-QUQ9XJmf.js} +2 -2
  68. package/dist/_chunks/{use-password-requirements-C9vKBSVn.js → use-password-requirements-E0sSfx5X.js} +38 -53
  69. package/dist/_chunks/use-theme-C2dHKUAN.js +145 -0
  70. package/dist/_chunks/{workflow-map-BR6txfFX.js → workflow-map-BKsKdYvZ.js} +5 -5
  71. package/dist/agent-catalog.json +151 -51
  72. package/dist/components/agenda-card/index.js +1 -1
  73. package/dist/components/agenda-tray/index.js +1 -1
  74. package/dist/components/ai-prompt-input/index.js +1 -1
  75. package/dist/components/audio-recorder/index.js +1 -1
  76. package/dist/components/autocomplete/index.js +1 -1
  77. package/dist/components/avatar/index.js +1 -1
  78. package/dist/components/benefit-card/index.js +1 -1
  79. package/dist/components/booking/booking-types.d.ts +145 -0
  80. package/dist/components/booking/booking.agent.d.ts +4 -0
  81. package/dist/components/booking/booking.d.ts +6 -0
  82. package/dist/components/booking/cascade.d.ts +96 -0
  83. package/dist/components/booking/details-form.d.ts +32 -0
  84. package/dist/components/booking/index.d.ts +5 -0
  85. package/dist/components/booking/index.js +8 -0
  86. package/dist/components/button/index.js +1 -1
  87. package/dist/components/calendar/index.js +1 -1
  88. package/dist/components/card/index.js +1 -1
  89. package/dist/components/carousel/index.js +1 -1
  90. package/dist/components/chat-input/index.js +1 -1
  91. package/dist/components/chat-message/index.js +1 -1
  92. package/dist/components/checkbox/checkbox.d.ts +6 -2
  93. package/dist/components/command-palette/index.js +1 -1
  94. package/dist/components/contact-card/index.js +1 -1
  95. package/dist/components/data-table/index.js +1 -1
  96. package/dist/components/date-picker/index.js +1 -1
  97. package/dist/components/date-range-picker/index.js +1 -1
  98. package/dist/components/date-time-picker/index.js +1 -1
  99. package/dist/components/description-list/index.js +1 -1
  100. package/dist/components/dialog/index.js +1 -1
  101. package/dist/components/empty-state/index.js +1 -1
  102. package/dist/components/freemium-paywall/index.js +1 -1
  103. package/dist/components/header/index.js +1 -1
  104. package/dist/components/header-settings/index.js +16 -15
  105. package/dist/components/icon-button/index.js +1 -1
  106. package/dist/components/index.d.ts +4 -1
  107. package/dist/components/key-value-pair/index.js +1 -1
  108. package/dist/components/link/index.js +1 -1
  109. package/dist/components/link/link.d.ts +7 -0
  110. package/dist/components/locale-picker/index.js +1 -1
  111. package/dist/components/map-view/index.js +1 -1
  112. package/dist/components/matrix-rain/index.js +1 -1
  113. package/dist/components/message-card/index.js +1 -1
  114. package/dist/components/message-tray/index.js +1 -1
  115. package/dist/components/notification-card/index.js +1 -1
  116. package/dist/components/notification-tray/index.js +1 -1
  117. package/dist/components/password-input/index.js +1 -1
  118. package/dist/components/patient-search/index.d.ts +4 -0
  119. package/dist/components/patient-search/index.js +6 -0
  120. package/dist/components/patient-search/patient-search.agent.d.ts +4 -0
  121. package/dist/components/patient-search/patient-search.d.ts +103 -0
  122. package/dist/components/payment-form/index.js +1 -1
  123. package/dist/components/pdf-viewer/index.js +1 -1
  124. package/dist/components/popover/index.js +1 -1
  125. package/dist/components/privacy-lock/index.js +1 -1
  126. package/dist/components/public-footer/index.d.ts +6 -0
  127. package/dist/components/public-footer/index.js +10 -0
  128. package/dist/components/public-footer/legal-urls.d.ts +18 -0
  129. package/dist/components/public-footer/public-footer.agent.d.ts +4 -0
  130. package/dist/components/public-footer/public-footer.d.ts +51 -0
  131. package/dist/components/public-footer/socials.d.ts +9 -0
  132. package/dist/components/public-header/index.js +1 -1
  133. package/dist/components/recaptcha-widget/index.js +1 -1
  134. package/dist/components/reviews-panel/index.d.ts +4 -0
  135. package/dist/components/reviews-panel/index.js +6 -0
  136. package/dist/components/reviews-panel/reviews-panel.agent.d.ts +4 -0
  137. package/dist/components/reviews-panel/reviews-panel.d.ts +76 -0
  138. package/dist/components/search-bar/index.js +1 -1
  139. package/dist/components/search-input/index.js +1 -1
  140. package/dist/components/sheet/index.js +1 -1
  141. package/dist/components/sign-in-with-alfadocs-button/index.js +1 -1
  142. package/dist/components/slot-grid/index.js +1 -1
  143. package/dist/components/spinner/index.js +1 -1
  144. package/dist/components/stepper-accordion/index.js +4 -3
  145. package/dist/components/task-tray/index.js +1 -1
  146. package/dist/components/theme-toggle/index.js +1 -1
  147. package/dist/components/timeline/index.js +1 -1
  148. package/dist/components/toast/index.js +1 -1
  149. package/dist/components/transcript-panel/index.js +1 -1
  150. package/dist/components/workflow/index.js +1 -1
  151. package/dist/hooks/index.js +1 -1
  152. package/dist/i18n/config.js +4923 -49
  153. package/dist/i18n/locales/ar.d.ts +272 -0
  154. package/dist/i18n/locales/de.d.ts +272 -0
  155. package/dist/i18n/locales/el.d.ts +272 -0
  156. package/dist/i18n/locales/es.d.ts +272 -0
  157. package/dist/i18n/locales/fr.d.ts +272 -0
  158. package/dist/i18n/locales/hi.d.ts +272 -0
  159. package/dist/i18n/locales/ja.d.ts +272 -0
  160. package/dist/i18n/locales/nl.d.ts +272 -0
  161. package/dist/i18n/locales/pl.d.ts +272 -0
  162. package/dist/i18n/locales/pt.d.ts +272 -0
  163. package/dist/i18n/locales/ro.d.ts +272 -0
  164. package/dist/i18n/locales/ru.d.ts +272 -0
  165. package/dist/i18n/locales/sq.d.ts +272 -0
  166. package/dist/i18n/locales/sv.d.ts +272 -0
  167. package/dist/i18n/locales/tr.d.ts +272 -0
  168. package/dist/i18n/locales/zh.d.ts +272 -0
  169. package/dist/i18n/resources.d.ts +544 -0
  170. package/dist/index.js +364 -348
  171. package/dist/locales/ar.json +273 -1
  172. package/dist/locales/de.json +273 -1
  173. package/dist/locales/el.json +273 -1
  174. package/dist/locales/en.json +273 -1
  175. package/dist/locales/es.json +273 -1
  176. package/dist/locales/fr.json +273 -1
  177. package/dist/locales/hi.json +273 -1
  178. package/dist/locales/it.json +273 -1
  179. package/dist/locales/ja.json +273 -1
  180. package/dist/locales/nl.json +273 -1
  181. package/dist/locales/pl.json +273 -1
  182. package/dist/locales/pt.json +273 -1
  183. package/dist/locales/ro.json +273 -1
  184. package/dist/locales/ru.json +273 -1
  185. package/dist/locales/sq.json +273 -1
  186. package/dist/locales/sv.json +273 -1
  187. package/dist/locales/tr.json +273 -1
  188. package/dist/locales/zh.json +273 -1
  189. package/dist/patterns/alia-assistant/index.js +1 -1
  190. package/dist/patterns/patient-shell/index.js +1 -1
  191. package/dist/tokens.css +1 -1
  192. package/package.json +17 -1
  193. package/dist/_chunks/icon-button-C4CGcYuz.js +0 -54
  194. package/dist/_chunks/isSameMonth-5wNF2f4I.js +0 -1307
  195. package/dist/_chunks/patient-shell-B164drIa.js +0 -173
  196. package/dist/_chunks/react-day-picker-C5F3-TTX.js +0 -1827
  197. package/dist/_chunks/slot-grid-CgpYgBkW.js +0 -502
  198. package/dist/_chunks/stepper-C-sIpRRU.js +0 -7
  199. package/dist/_chunks/stepper-accordion.agent-ckKYZCIP.js +0 -322
  200. package/dist/_chunks/stepper-calendar-BLOJUE0-.js +0 -648
  201. package/dist/_chunks/use-theme-B1cwAXJR.js +0 -145
  202. package/dist/components/stepper-calendar/index.d.ts +0 -4
  203. package/dist/components/stepper-calendar/index.js +0 -6
  204. package/dist/components/stepper-calendar/stepper-calendar.agent.d.ts +0 -4
  205. package/dist/components/stepper-calendar/stepper-calendar.d.ts +0 -62
@@ -0,0 +1,145 @@
1
+ import { useSyncExternalStore as D, useEffect as b, useCallback as p } from "react";
2
+ const y = "alfadocs-ui.theme", w = "alfadocs-ui.accessibility", r = {
3
+ light: "theme-light",
4
+ dark: "theme-dark",
5
+ accessible: "theme-accessible"
6
+ }, M = "(prefers-color-scheme: dark)", C = "(prefers-contrast: more)";
7
+ function g(e) {
8
+ if (typeof window > "u") return null;
9
+ try {
10
+ return window.localStorage.getItem(e);
11
+ } catch {
12
+ return null;
13
+ }
14
+ }
15
+ function S(e, t) {
16
+ if (!(typeof window > "u"))
17
+ try {
18
+ t === null ? window.localStorage.removeItem(e) : window.localStorage.setItem(e, t);
19
+ } catch {
20
+ }
21
+ }
22
+ function L(e) {
23
+ return e === "light" || e === "dark" || e === "system";
24
+ }
25
+ function T(e) {
26
+ return e === "default" || e === "accessible" || e === "system";
27
+ }
28
+ function O() {
29
+ const e = g(y), t = g(w), i = typeof window < "u" && typeof window.matchMedia == "function", s = typeof document < "u" ? document.documentElement.classList : null, A = s ? s.contains(r.dark) ? "dark" : s.contains(r.light) ? "light" : null : null, _ = s != null && s.contains(r.accessible) ? "accessible" : null;
30
+ return {
31
+ theme: L(e) ? e : A ?? "system",
32
+ accessibility: T(t) ? t : _ ?? "system",
33
+ prefersDark: i ? window.matchMedia(M).matches : !1,
34
+ prefersMoreContrast: i ? window.matchMedia(C).matches : !1
35
+ };
36
+ }
37
+ let n = O();
38
+ const h = /* @__PURE__ */ new Set();
39
+ function c(e) {
40
+ e.theme === n.theme && e.accessibility === n.accessibility && e.prefersDark === n.prefersDark && e.prefersMoreContrast === n.prefersMoreContrast || (n = e, h.forEach((t) => t()));
41
+ }
42
+ function I(e) {
43
+ return h.add(e), () => {
44
+ h.delete(e);
45
+ };
46
+ }
47
+ function R() {
48
+ return n;
49
+ }
50
+ function V() {
51
+ return {
52
+ theme: "system",
53
+ accessibility: "system",
54
+ prefersDark: !1,
55
+ prefersMoreContrast: !1
56
+ };
57
+ }
58
+ let d = 0, u = null, f = null, l = null;
59
+ function v(e) {
60
+ c({ ...n, prefersDark: e.matches });
61
+ }
62
+ function H(e) {
63
+ c({ ...n, prefersMoreContrast: e.matches });
64
+ }
65
+ function Y(e) {
66
+ if (e.key === y) {
67
+ const t = L(e.newValue) ? e.newValue : "system";
68
+ c({ ...n, theme: t });
69
+ } else if (e.key === w) {
70
+ const t = T(e.newValue) ? e.newValue : "system";
71
+ c({ ...n, accessibility: t });
72
+ }
73
+ }
74
+ function E(e, t) {
75
+ return typeof e.addEventListener == "function" ? (e.addEventListener("change", t), () => e.removeEventListener("change", t)) : (e.addListener(t), () => e.removeListener(t));
76
+ }
77
+ function G() {
78
+ return d += 1, d > 1 || typeof window > "u" || (typeof window.matchMedia == "function" && (u = window.matchMedia(M), f = window.matchMedia(C), c({
79
+ ...n,
80
+ prefersDark: u.matches,
81
+ prefersMoreContrast: f.matches
82
+ }), o = E(u, v), a = E(f, H)), l = Y, window.addEventListener("storage", l)), m;
83
+ }
84
+ let o = null, a = null;
85
+ function m() {
86
+ d -= 1, !(d > 0) && (o == null || o(), a == null || a(), o = null, a = null, u = null, f = null, l && typeof window < "u" && window.removeEventListener("storage", l), l = null);
87
+ }
88
+ function k(e) {
89
+ const t = e.theme === "system" ? e.prefersDark ? "dark" : "light" : e.theme, i = e.accessibility === "system" ? e.prefersMoreContrast : e.accessibility === "accessible";
90
+ return t === "dark" && i ? "dark-accessible" : t === "dark" ? "dark" : i ? "light-accessible" : "light";
91
+ }
92
+ function K(e) {
93
+ switch (e) {
94
+ case "light":
95
+ return [r.light];
96
+ case "dark":
97
+ return [r.dark];
98
+ case "light-accessible":
99
+ return [r.light, r.accessible];
100
+ case "dark-accessible":
101
+ return [r.dark, r.accessible];
102
+ }
103
+ }
104
+ const Q = [
105
+ r.light,
106
+ r.dark,
107
+ r.accessible
108
+ ];
109
+ function U(e) {
110
+ if (typeof document > "u") return;
111
+ const t = document.documentElement, i = new Set(K(e));
112
+ Q.forEach((s) => {
113
+ i.has(s) ? t.classList.add(s) : t.classList.remove(s);
114
+ });
115
+ }
116
+ function N() {
117
+ const e = D(I, R, V);
118
+ b(() => G(), []), b(() => {
119
+ U(k(e));
120
+ }, [e]);
121
+ const t = p((s) => {
122
+ S(y, s === "system" ? null : s), c({ ...n, theme: s });
123
+ }, []), i = p((s) => {
124
+ S(
125
+ w,
126
+ s === "system" ? null : s
127
+ ), c({ ...n, accessibility: s });
128
+ }, []);
129
+ return {
130
+ theme: e.theme,
131
+ accessibility: e.accessibility,
132
+ resolvedTheme: k(e),
133
+ setTheme: t,
134
+ setAccessibility: i
135
+ };
136
+ }
137
+ export {
138
+ w as A,
139
+ r as T,
140
+ y as a,
141
+ k as r,
142
+ K as t,
143
+ N as u
144
+ };
145
+ //# sourceMappingURL=use-theme-C2dHKUAN.js.map
@@ -2,18 +2,18 @@ import { jsx as t, jsxs as u, Fragment as ve } from "react/jsx-runtime";
2
2
  import { forwardRef as O, useMemo as R, useRef as j, useCallback as W, useState as ge, useImperativeHandle as ke, useEffect as ye } from "react";
3
3
  import { c as L } from "./index-D2ZczOXr.js";
4
4
  import { useTranslation as z } from "react-i18next";
5
- import { C } from "./card-C353dU-H.js";
5
+ import { C } from "./card-DKTMLVrw.js";
6
6
  import { B as be } from "./badge-cLYVGlMh.js";
7
- import { K as Z } from "./key-value-pair-DBuOCtIc.js";
7
+ import { K as Z } from "./key-value-pair-CqeKiP__.js";
8
8
  import { T as xe } from "./timestamp-BV2lC-wV.js";
9
- import { I as S } from "./icon-button-C4CGcYuz.js";
9
+ import { I as S } from "./icon-button-BRHSSFmZ.js";
10
10
  import { c as _ } from "./createLucideIcon-CrFbzy84.js";
11
11
  import { C as Ne } from "./circle-BkqTgYmt.js";
12
12
  import { u as Ce } from "./registry-C9nwlNyL.js";
13
13
  import { A as V } from "./alert-ywPR59NE.js";
14
14
  import { B as _e } from "./button-DD_0Xdmr.js";
15
15
  import { D as N } from "./dropdown-menu-DZxwF23X.js";
16
- import { E } from "./empty-state-3CLJIXSj.js";
16
+ import { E } from "./empty-state-BLy7tigq.js";
17
17
  import { P as ae } from "./plus-CYKNmfuA.js";
18
18
  import { G as ne } from "./globe-BkEFMNSg.js";
19
19
  import { S as de } from "./square-check-big-Jr-0202D.js";
@@ -1412,4 +1412,4 @@ export {
1412
1412
  ee as r,
1413
1413
  D as w
1414
1414
  };
1415
- //# sourceMappingURL=workflow-map-BR6txfFX.js.map
1415
+ //# sourceMappingURL=workflow-map-BKsKdYvZ.js.map
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "schemaVersion": 1,
3
- "packageVersion": "0.25.1",
3
+ "packageVersion": "0.30.0",
4
4
  "components": [
5
5
  {
6
6
  "kind": "component",
@@ -401,6 +401,46 @@
401
401
  }
402
402
  }
403
403
  },
404
+ {
405
+ "kind": "component",
406
+ "id": "booking",
407
+ "capabilities": [
408
+ "navigate",
409
+ "view_change"
410
+ ],
411
+ "state": [
412
+ {
413
+ "name": "variant",
414
+ "type": "string",
415
+ "description": "Active variant — one of `inline-list`, `accordion`, `calendar`, `flexible`, `progress`."
416
+ }
417
+ ],
418
+ "actions": [
419
+ {
420
+ "name": "reset",
421
+ "safety": "write",
422
+ "description": "Clear the booking value back to an empty state. Use to abandon an in-progress flow."
423
+ },
424
+ {
425
+ "name": "goto_step",
426
+ "safety": "read",
427
+ "argsType": "{ step: 1 | 2 | 3 | 4 | 5 | 6 | 7 }",
428
+ "description": "Jump to the given step. Implementations may clamp to the first incomplete step if the requested one is not reachable yet."
429
+ }
430
+ ],
431
+ "domHooks": {
432
+ "root": {
433
+ "attr": "data-component",
434
+ "value": "booking",
435
+ "description": "Marks the Booking root region."
436
+ },
437
+ "instanceId": {
438
+ "attr": "data-component-id",
439
+ "sourceProp": "id",
440
+ "description": "Sourced from the id prop."
441
+ }
442
+ }
443
+ },
404
444
  {
405
445
  "kind": "component",
406
446
  "id": "breadcrumb",
@@ -2394,6 +2434,45 @@
2394
2434
  }
2395
2435
  }
2396
2436
  },
2437
+ {
2438
+ "kind": "component",
2439
+ "id": "patient-search",
2440
+ "capabilities": [
2441
+ "navigate",
2442
+ "view_change"
2443
+ ],
2444
+ "state": [
2445
+ {
2446
+ "name": "variant",
2447
+ "type": "string",
2448
+ "description": "Active variant — one of `who-where`, `who-where-when`, `faceted`, `discovery`."
2449
+ }
2450
+ ],
2451
+ "actions": [
2452
+ {
2453
+ "name": "reset",
2454
+ "safety": "write",
2455
+ "description": "Clear the current selection (WHO, WHERE, WHEN, facets, geo) via the consumer-owned onChange."
2456
+ },
2457
+ {
2458
+ "name": "focus_primary",
2459
+ "safety": "read",
2460
+ "description": "Move keyboard focus to the most-relevant field for the current variant."
2461
+ }
2462
+ ],
2463
+ "domHooks": {
2464
+ "root": {
2465
+ "attr": "data-component",
2466
+ "value": "patient-search",
2467
+ "description": "Marks the PatientSearch root region."
2468
+ },
2469
+ "instanceId": {
2470
+ "attr": "data-component-id",
2471
+ "sourceProp": "id",
2472
+ "description": "Sourced from the id prop."
2473
+ }
2474
+ }
2475
+ },
2397
2476
  {
2398
2477
  "kind": "component",
2399
2478
  "id": "payment-form",
@@ -2622,6 +2701,38 @@
2622
2701
  }
2623
2702
  }
2624
2703
  },
2704
+ {
2705
+ "kind": "component",
2706
+ "id": "public-footer",
2707
+ "capabilities": [
2708
+ "navigate"
2709
+ ],
2710
+ "state": [
2711
+ {
2712
+ "name": "variant",
2713
+ "type": "string",
2714
+ "description": "Active variant — one of `minimal`, `compact`, `full`."
2715
+ },
2716
+ {
2717
+ "name": "legalUrls",
2718
+ "type": "object",
2719
+ "description": "Resolved legal URLs for the active locale + marketingBaseUrl + overrides: `{ privacy, terms, contacts }`."
2720
+ }
2721
+ ],
2722
+ "actions": [],
2723
+ "domHooks": {
2724
+ "root": {
2725
+ "attr": "data-component",
2726
+ "value": "public-footer",
2727
+ "description": "Marks the PublicFooter root region. The root also carries `data-variant=\"minimal|compact|full\"` for CSS + agent selectors."
2728
+ },
2729
+ "instanceId": {
2730
+ "attr": "id",
2731
+ "sourceProp": "id",
2732
+ "description": "Sourced from the `id` prop when provided."
2733
+ }
2734
+ }
2735
+ },
2625
2736
  {
2626
2737
  "kind": "component",
2627
2738
  "id": "public-header",
@@ -2801,6 +2912,45 @@
2801
2912
  }
2802
2913
  }
2803
2914
  },
2915
+ {
2916
+ "kind": "component",
2917
+ "id": "reviews-panel",
2918
+ "capabilities": [
2919
+ "filter"
2920
+ ],
2921
+ "state": [
2922
+ {
2923
+ "name": "filter",
2924
+ "type": "string",
2925
+ "description": "Active star-bucket filter — `\"all\"` or an integer 1..5. Reads the controlled `filter` prop."
2926
+ },
2927
+ {
2928
+ "name": "visibleCount",
2929
+ "type": "number",
2930
+ "description": "Number of reviews currently rendered after the filter is applied."
2931
+ }
2932
+ ],
2933
+ "actions": [
2934
+ {
2935
+ "name": "set_filter",
2936
+ "safety": "read",
2937
+ "argsType": "{ filter: \"all\" | 1 | 2 | 3 | 4 | 5 }",
2938
+ "description": "Narrow the visible review list to a star bucket, or `\"all\"` to clear the filter."
2939
+ }
2940
+ ],
2941
+ "domHooks": {
2942
+ "root": {
2943
+ "attr": "data-component",
2944
+ "value": "reviews-panel",
2945
+ "description": "Marks the ReviewsPanel root region."
2946
+ },
2947
+ "instanceId": {
2948
+ "attr": "data-component-id",
2949
+ "sourceProp": "id",
2950
+ "description": "Sourced from the id prop."
2951
+ }
2952
+ }
2953
+ },
2804
2954
  {
2805
2955
  "kind": "component",
2806
2956
  "id": "rich-text-editor",
@@ -3396,56 +3546,6 @@
3396
3546
  }
3397
3547
  }
3398
3548
  },
3399
- {
3400
- "kind": "component",
3401
- "id": "stepper-calendar",
3402
- "capabilities": [
3403
- "navigate",
3404
- "view_change"
3405
- ],
3406
- "state": [
3407
- {
3408
- "name": "currentStep",
3409
- "type": "number",
3410
- "description": "Zero-indexed active step (0 = service, 1 = date, 2 = time, 3 = details)."
3411
- },
3412
- {
3413
- "name": "totalSteps",
3414
- "type": "number",
3415
- "description": "Total number of steps in the booking flow (always 4)."
3416
- }
3417
- ],
3418
- "actions": [
3419
- {
3420
- "name": "goto_step",
3421
- "safety": "read",
3422
- "argsType": "{ step: number }",
3423
- "description": "Jump to the given step. Steps beyond the first-incomplete are gated internally."
3424
- },
3425
- {
3426
- "name": "next",
3427
- "safety": "read",
3428
- "description": "Advance to the next step when the current step has a valid value."
3429
- },
3430
- {
3431
- "name": "previous",
3432
- "safety": "read",
3433
- "description": "Return to the previous step."
3434
- }
3435
- ],
3436
- "domHooks": {
3437
- "root": {
3438
- "attr": "data-component",
3439
- "value": "stepper-calendar",
3440
- "description": "Marks the StepperCalendar root region."
3441
- },
3442
- "instanceId": {
3443
- "attr": "data-component-id",
3444
- "sourceProp": "id",
3445
- "description": "Sourced from the id prop."
3446
- }
3447
- }
3448
- },
3449
3549
  {
3450
3550
  "kind": "component",
3451
3551
  "id": "stepper-progress",
@@ -1,4 +1,4 @@
1
- import { A as r, i as d } from "../../_chunks/agenda-card-BmpaUG1h.js";
1
+ import { A as r, i as d } from "../../_chunks/agenda-card-CznB7K8e.js";
2
2
  import { a as n } from "../../_chunks/agenda-card.agent-B_R47-c9.js";
3
3
  export {
4
4
  r as AgendaCard,
@@ -1,4 +1,4 @@
1
- import { A as r, a as g } from "../../_chunks/agenda-tray-DiInnVqk.js";
1
+ import { A as r, a as g } from "../../_chunks/agenda-tray-C_bha7oK.js";
2
2
  export {
3
3
  r as AgendaTray,
4
4
  g as agendaTrayAgent
@@ -1,4 +1,4 @@
1
- import { A as a, a as o } from "../../_chunks/ai-prompt-input-B5MdixzR.js";
1
+ import { A as a, a as o } from "../../_chunks/ai-prompt-input-Bka3jX3i.js";
2
2
  export {
3
3
  a as AIPromptInput,
4
4
  o as aiPromptInputAgent
@@ -1,4 +1,4 @@
1
- import { A as r, a } from "../../_chunks/audio-recorder-D4xM3H5i.js";
1
+ import { A as r, a } from "../../_chunks/audio-recorder-OB6IV9B1.js";
2
2
  export {
3
3
  r as AudioRecorder,
4
4
  a as audioRecorderAgent
@@ -1,4 +1,4 @@
1
- import { A as e, a as o, b as m } from "../../_chunks/autocomplete-C7xq06bP.js";
1
+ import { A as e, a as o, b as m } from "../../_chunks/autocomplete-CUh0f7Dj.js";
2
2
  export {
3
3
  e as Autocomplete,
4
4
  o as autocompleteAgent,
@@ -1,4 +1,4 @@
1
- import { A as o, g as r, n as t } from "../../_chunks/avatar-BpFohgWG.js";
1
+ import { A as o, g as r, n as t } from "../../_chunks/avatar-D_H4emLo.js";
2
2
  export {
3
3
  o as Avatar,
4
4
  r as getInitials,
@@ -1,4 +1,4 @@
1
- import { B as a } from "../../_chunks/benefit-card-DXmrAyfn.js";
1
+ import { B as a } from "../../_chunks/benefit-card-CjYM8vNr.js";
2
2
  export {
3
3
  a as BenefitCard
4
4
  };
@@ -0,0 +1,145 @@
1
+ import type { ComponentPropsWithoutRef, ReactNode } from 'react';
2
+ export type BookingVariant = 'inline-list' | 'accordion' | 'calendar' | 'flexible' | 'progress';
3
+ export type InsuranceType = 'private' | 'public';
4
+ /** Channels the patient can pick to receive the confirmation link. */
5
+ export type ConfirmationChannel = 'email' | 'whatsapp' | 'sms';
6
+ /** Fixed order — email first, then WhatsApp, then SMS. */
7
+ export declare const CONFIRMATION_CHANNEL_ORDER: readonly ConfirmationChannel[];
8
+ export interface BookingSpecialty {
9
+ id: string;
10
+ label: string;
11
+ /** Optional ordering hint; falls back to array order. */
12
+ sequenceNumber?: number;
13
+ /** Restrict to operators-on-page when lockedOperatorId is set. */
14
+ operatorIds?: string[];
15
+ }
16
+ export interface BookingService {
17
+ id: string;
18
+ label: string;
19
+ /** Minutes — required for slot fetching. */
20
+ durationMin: number;
21
+ /** Required when useSpecialties is true. */
22
+ specialtyId?: string;
23
+ /** Operators who can perform this service. */
24
+ operatorIds?: string[];
25
+ }
26
+ export interface BookingOperator {
27
+ id: string;
28
+ name: string;
29
+ specialtyIds?: string[];
30
+ appointmentBookingReasonIds?: string[];
31
+ }
32
+ export interface BookingSlot {
33
+ /** Opaque unique key within `availableSlots[date]`. */
34
+ key: string;
35
+ /** HH:mm 24h — used for display. */
36
+ time: string;
37
+ available: boolean;
38
+ /** Opaque passthrough so the consumer can resolve operatorId / chairId
39
+ * / dateTime when `onSubmit` fires. */
40
+ meta?: Record<string, unknown>;
41
+ }
42
+ export interface BookingDetails {
43
+ firstName: string;
44
+ lastName: string;
45
+ email: string;
46
+ mobilePhone: string;
47
+ privacyConsent: boolean;
48
+ termsConsent: boolean;
49
+ codiceFiscale?: string;
50
+ dateOfBirth?: string;
51
+ insuranceNumber?: string;
52
+ note?: string;
53
+ returningPatient?: boolean;
54
+ /**
55
+ * Channels the patient picked for the confirmation link. Guaranteed to
56
+ * be a non-empty subset of the practice's enabled `confirmationChannels`
57
+ * when present. Omitted when only one channel is enabled (implicit —
58
+ * backend infers from the practice config).
59
+ */
60
+ confirmationChannels?: ConfirmationChannel[];
61
+ }
62
+ export interface BookingValue {
63
+ insuranceType?: InsuranceType;
64
+ specialtyId?: string;
65
+ serviceId?: string;
66
+ /** May be the literal `'all'` sentinel to mean "no operator preference". */
67
+ operatorId?: string;
68
+ /** YYYY-MM-DD. */
69
+ date?: string;
70
+ /** Opaque key from `availableSlots[date]`. */
71
+ slotKey?: string;
72
+ /** Partial details — fully populated when the user is ready to submit. */
73
+ details?: Partial<BookingDetails>;
74
+ }
75
+ export interface BookingSubmitPayload {
76
+ slot: BookingSlot;
77
+ value: BookingValue;
78
+ /** Fully populated + validated (privacy + terms ticked, required fields filled). */
79
+ details: BookingDetails;
80
+ }
81
+ export interface BookingValidationResult {
82
+ valid: boolean;
83
+ /** Optional localised hint shown next to the field on failure. */
84
+ hint?: string;
85
+ }
86
+ export type BookingValidator = (value: string) => Promise<BookingValidationResult>;
87
+ export interface BookingHandle {
88
+ getVariant: () => BookingVariant;
89
+ /** Clear `value` back to an empty state via `onChange`. */
90
+ reset: () => void;
91
+ /**
92
+ * Jump to a specific step. Implementations may clamp to the first
93
+ * incomplete step if the requested one isn't reachable yet.
94
+ */
95
+ goToStep: (step: 1 | 2 | 3 | 4 | 5 | 6 | 7) => void;
96
+ }
97
+ export interface BookingProps extends Omit<ComponentPropsWithoutRef<'div'>, 'aria-label' | 'onChange' | 'onSubmit'> {
98
+ variant?: BookingVariant;
99
+ country?: string;
100
+ useSpecialties?: boolean;
101
+ allowOperatorSelection?: boolean;
102
+ /** Pins step 4 to this operator. */
103
+ lockedOperatorId?: string;
104
+ specialties?: BookingSpecialty[];
105
+ services: BookingService[];
106
+ operators?: BookingOperator[];
107
+ availableDates: string[];
108
+ availableSlots: Record<string, BookingSlot[]>;
109
+ /** Server-side hint of the next free date when the current window is empty. */
110
+ nextAvailableDate?: string;
111
+ requireCodiceFiscale?: boolean;
112
+ requireDateOfBirth?: boolean;
113
+ requireInsuranceNumber?: boolean;
114
+ showNote?: boolean;
115
+ showReturningPatientFlag?: boolean;
116
+ privacyPolicyUrl?: string;
117
+ termsUrl?: string;
118
+ validateCodiceFiscale?: BookingValidator;
119
+ validateInsuranceNumber?: BookingValidator;
120
+ /** Default: false. Specialty auto-select on length=1 is always on. */
121
+ autoSelectSingleService?: boolean;
122
+ /**
123
+ * Channels the practice has enabled. The picker renders one checkbox
124
+ * per channel; when length === 1, the picker is hidden and the single
125
+ * channel is implicit. Defaults to `['email']` when omitted.
126
+ */
127
+ confirmationChannels?: ConfirmationChannel[];
128
+ /**
129
+ * Pre-checked channels. Intersected with `confirmationChannels` for
130
+ * safety. When omitted, the kit applies a smart default (always email;
131
+ * +whatsapp when mobile is plausibly filled; +sms when whatsapp isn't
132
+ * available).
133
+ */
134
+ defaultConfirmationChannels?: ConfirmationChannel[];
135
+ value: BookingValue;
136
+ onChange: (next: BookingValue) => void;
137
+ onSubmit: (payload: BookingSubmitPayload) => void | Promise<void>;
138
+ loadingSlots?: boolean;
139
+ submitting?: boolean;
140
+ emptyServicesSlot?: ReactNode;
141
+ onboardingIncompleteSlot?: ReactNode;
142
+ 'aria-label'?: string;
143
+ id?: string;
144
+ }
145
+ //# sourceMappingURL=booking-types.d.ts.map
@@ -0,0 +1,4 @@
1
+ import type { AgentAdapter } from '../../agent/types';
2
+ import type { BookingHandle } from './booking-types';
3
+ export declare const bookingAgent: AgentAdapter<BookingHandle>;
4
+ //# sourceMappingURL=booking.agent.d.ts.map
@@ -0,0 +1,6 @@
1
+ import type { BookingProps } from './booking-types';
2
+ export type { BookingDetails, BookingHandle, BookingOperator, BookingProps, BookingService, BookingSlot, BookingSpecialty, BookingSubmitPayload, BookingValidationResult, BookingValidator, BookingValue, BookingVariant, ConfirmationChannel, InsuranceType, } from './booking-types';
3
+ export { CONFIRMATION_CHANNEL_ORDER } from './booking-types';
4
+ export { OPERATORS_ALL } from './cascade';
5
+ export declare const Booking: import("react").ForwardRefExoticComponent<BookingProps & import("react").RefAttributes<HTMLDivElement>>;
6
+ //# sourceMappingURL=booking.d.ts.map