@alfadocs/ui-kit 1.147.1 → 1.148.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.
- package/dist/_chunks/{appointment-details-panel.history-eqPMKmW0.js → appointment-details-panel.history-BxNqcA-r.js} +109 -110
- package/dist/_chunks/{appointment-timeline-D5qbZ7in.js → appointment-timeline-CuZW-CGT.js} +2 -2
- package/dist/_chunks/{bill-line-table-DnkFqMnM.js → bill-line-table-B8Cc2pTH.js} +2 -2
- package/dist/_chunks/button-group-CHQD8GJ0.js +449 -0
- package/dist/_chunks/{calendar-appointment-editor-dialog-sY-k0GGW.js → calendar-appointment-editor-dialog-Cz8F2H4M.js} +6 -6
- package/dist/_chunks/{calendar-waiting-list-panel-Bm7NAZdk.js → calendar-waiting-list-panel-C4T85b4q.js} +3 -3
- package/dist/_chunks/{calendar.sheets-CCvdZF-R.js → calendar.sheets-DsgPdycU.js} +4 -4
- package/dist/_chunks/{data-grid-CujX-2tF.js → data-grid-CkzbCZSo.js} +486 -476
- package/dist/_chunks/{default-tabs-CqP1uWdx.js → default-tabs-C45FVzsG.js} +3 -3
- package/dist/_chunks/editable-description-BsSjLnSx.js +193 -0
- package/dist/_chunks/{editable-description.agent-Bm_LBV2j.js → editable-description.agent-zyyR_hxB.js} +2 -2
- package/dist/_chunks/{face-scheme-ByYeboH9.js → face-scheme-BC2whb1S.js} +2 -2
- package/dist/_chunks/{invoice-upload-list-srvWy5_d.js → invoice-upload-list-BReimsvV.js} +3 -3
- package/dist/_chunks/{notes-panel-C9aB1Cma.js → notes-panel-BHMnLbEH.js} +2 -2
- package/dist/_chunks/prescription-history-CQuJmd4H.js +1846 -0
- package/dist/_chunks/{rich-text-editor-CJXc5GgH.js → rich-text-editor-BAcJq1PO.js} +445 -437
- package/dist/_chunks/{tasks-panel-DsjfS_k5.js → tasks-panel-DufAoAxG.js} +2 -2
- package/dist/_chunks/{toolbar-z_6tE7zG.js → toolbar-B9oh9XY9.js} +2 -2
- package/dist/_chunks/{use-appointment-details-read-Dod21IxM.js → use-appointment-details-read-kYp-gfhb.js} +417 -422
- package/dist/agent-catalog.json +2 -2
- package/dist/appointment-editor-panel/index.js +1 -1
- package/dist/browser-support.js +1 -1
- package/dist/calendar-action-buttons/index.js +1 -1
- package/dist/components/appointment-details-panel/appointment-details-panel.history.d.ts +4 -6
- package/dist/components/appointment-details-panel/index.js +1 -1
- package/dist/components/appointment-timeline/index.js +1 -1
- package/dist/components/bill-line-table/index.js +1 -1
- package/dist/components/bill-table/index.js +1 -1
- package/dist/components/button-group/button-group.d.ts +2 -1
- package/dist/components/button-group/index.js +1 -1
- package/dist/components/data-grid/data-grid.variants.d.ts +7 -1
- package/dist/components/data-grid/index.js +2 -2
- package/dist/components/editable-description/editable-description.d.ts +2 -1
- package/dist/components/editable-description/index.js +2 -2
- package/dist/components/face-scheme/index.js +1 -1
- package/dist/components/invoice-upload-list/index.js +1 -1
- package/dist/components/notes-panel/index.js +1 -1
- package/dist/components/rich-text-editor/index.js +1 -1
- package/dist/components/tasks-panel/index.js +1 -1
- package/dist/core.css +1 -1
- package/dist/find-free-slots-panel/index.js +1 -1
- package/dist/host-compat.css +7 -1
- package/dist/i18n/locales/ar.d.ts +0 -1
- package/dist/i18n/locales/ar.js +1 -2
- package/dist/i18n/locales/de.d.ts +0 -1
- package/dist/i18n/locales/de.js +1 -2
- package/dist/i18n/locales/el.d.ts +0 -1
- package/dist/i18n/locales/el.js +1 -2
- package/dist/i18n/locales/en.d.ts +0 -1
- package/dist/i18n/locales/en.js +1 -2
- package/dist/i18n/locales/es.d.ts +0 -1
- package/dist/i18n/locales/es.js +1 -2
- package/dist/i18n/locales/fr.d.ts +0 -1
- package/dist/i18n/locales/fr.js +1 -2
- package/dist/i18n/locales/hi.d.ts +0 -1
- package/dist/i18n/locales/hi.js +1 -2
- package/dist/i18n/locales/it.d.ts +0 -1
- package/dist/i18n/locales/it.js +1 -2
- package/dist/i18n/locales/ja.d.ts +0 -1
- package/dist/i18n/locales/ja.js +1 -2
- package/dist/i18n/locales/nl.d.ts +0 -1
- package/dist/i18n/locales/nl.js +1 -2
- package/dist/i18n/locales/pl.d.ts +0 -1
- package/dist/i18n/locales/pl.js +1 -2
- package/dist/i18n/locales/pt.d.ts +0 -1
- package/dist/i18n/locales/pt.js +1 -2
- package/dist/i18n/locales/ro.d.ts +0 -1
- package/dist/i18n/locales/ro.js +1 -2
- package/dist/i18n/locales/ru.d.ts +0 -1
- package/dist/i18n/locales/ru.js +1 -2
- package/dist/i18n/locales/sq.d.ts +0 -1
- package/dist/i18n/locales/sq.js +1 -2
- package/dist/i18n/locales/sv.d.ts +0 -1
- package/dist/i18n/locales/sv.js +1 -2
- package/dist/i18n/locales/tr.d.ts +0 -1
- package/dist/i18n/locales/tr.js +1 -2
- package/dist/i18n/locales/zh.d.ts +0 -1
- package/dist/i18n/locales/zh.js +1 -2
- package/dist/index.js +17 -17
- package/dist/locales/ar.json +1 -2
- package/dist/locales/de.json +1 -2
- package/dist/locales/el.json +1 -2
- package/dist/locales/en.json +1 -2
- package/dist/locales/es.json +1 -2
- package/dist/locales/fr.json +1 -2
- package/dist/locales/hi.json +1 -2
- package/dist/locales/it.json +1 -2
- package/dist/locales/ja.json +1 -2
- package/dist/locales/nl.json +1 -2
- package/dist/locales/pl.json +1 -2
- package/dist/locales/pt.json +1 -2
- package/dist/locales/ro.json +1 -2
- package/dist/locales/ru.json +1 -2
- package/dist/locales/sq.json +1 -2
- package/dist/locales/sv.json +1 -2
- package/dist/locales/tr.json +1 -2
- package/dist/locales/zh.json +1 -2
- package/dist/online-bookings-panel/index.js +1 -1
- package/dist/patterns/calendar/index.js +2 -2
- package/dist/patterns/prescription/index.d.ts +1 -1
- package/dist/patterns/prescription/index.js +1 -1
- package/dist/patterns/prescription/prescription-history.d.ts +28 -0
- package/dist/tokens.css +1 -1
- package/dist/waiting-list-panel/index.js +2 -2
- package/package.json +1 -1
- package/dist/_chunks/button-group-N60L3HMa.js +0 -408
- package/dist/_chunks/editable-description-BQauSuCG.js +0 -142
- package/dist/_chunks/prescription-history-CFs3JMIE.js +0 -1773
|
@@ -1,32 +1,33 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as b, jsx as e, Fragment as ne } from "react/jsx-runtime";
|
|
2
2
|
import { c as lt } from "./index-D2ZczOXr.js";
|
|
3
|
-
import { useId as
|
|
4
|
-
import { useTranslation as
|
|
5
|
-
import { u as
|
|
6
|
-
import { u as
|
|
7
|
-
import { c as
|
|
3
|
+
import { useId as tt, useRef as R, forwardRef as Qt, useEffect as Se, useMemo as kt, useState as F, useCallback as Zt } from "react";
|
|
4
|
+
import { useTranslation as G } from "react-i18next";
|
|
5
|
+
import { u as en } from "./registry-DvAUVLHh.js";
|
|
6
|
+
import { u as de } from "./use-isomorphic-layout-effect-BGfaCOP1.js";
|
|
7
|
+
import { c as tn } from "./compose-refs-C0k0tdqF.js";
|
|
8
8
|
import { g as nt } from "./get-error-message-DbFUzuja.js";
|
|
9
|
-
import { h as
|
|
10
|
-
import { c as
|
|
11
|
-
import { A as
|
|
9
|
+
import { h as Qe } from "./handled-rejection-C-6Dq0As.js";
|
|
10
|
+
import { c as nn, a as wt } from "./privacy-mask-zVh0ntm0.js";
|
|
11
|
+
import { A as ce } from "./alert-C4WKViaS.js";
|
|
12
12
|
import { B as C } from "./button-Dp4j9ygh.js";
|
|
13
|
-
import { I as
|
|
14
|
-
import { B as
|
|
13
|
+
import { I as Ht } from "./icon-button-u9VMQn3x.js";
|
|
14
|
+
import { B as an } from "./button-group-CHQD8GJ0.js";
|
|
15
15
|
import { D as $e } from "./dropdown-menu-Bm1KALnk.js";
|
|
16
|
-
import { E as
|
|
16
|
+
import { E as Mt } from "./editable-description-BsSjLnSx.js";
|
|
17
17
|
import { N as at } from "./note-timeline-BbjHMhkL.js";
|
|
18
18
|
import { P as Wt } from "./panel-header-CbtlTe85.js";
|
|
19
|
-
import { P as
|
|
19
|
+
import { P as Ze } from "./panel-subview-DjBwNV16.js";
|
|
20
20
|
import { P as Bt } from "./patient-summary-card-roM9Esfb.js";
|
|
21
|
-
import { S as
|
|
22
|
-
import { C as
|
|
21
|
+
import { S as ue } from "./section-card-CYfeQ6EQ.js";
|
|
22
|
+
import { C as sn, S as we } from "./skeleton-tTWJpvAq.js";
|
|
23
|
+
import { F as on } from "./form-field-CyHfOVKF.js";
|
|
23
24
|
import { T as rn } from "./text-area-COMVJ1yE.js";
|
|
24
25
|
import { T as ln } from "./tooltip-uEBdD1-5.js";
|
|
25
26
|
import { T as Ut } from "./treatment-receipt-BZzwvsnY.js";
|
|
26
|
-
import { a as
|
|
27
|
+
import { a as et } from "./whatsapp-button-XbozeDl_.js";
|
|
27
28
|
import { W as dn, a as cn } from "./workflow-status-Cg7yjnye.js";
|
|
28
29
|
import { a as St, u as un, i as pn } from "./appointment-workflow-status-S-lx81Yz.js";
|
|
29
|
-
import { M as mn, C as At, A as hn } from "./appointment-details-panel.history-
|
|
30
|
+
import { M as mn, C as At, A as hn } from "./appointment-details-panel.history-BxNqcA-r.js";
|
|
30
31
|
import { R as fn, a as xt, b as it, e as gn, g as vn, c as yn, d as bn, h as kn, D as Nt, f as wn, i as Sn, p as An } from "./appointment-details-panel.identity--_j07UG1.js";
|
|
31
32
|
import { A as Tt } from "./avatar-Dp5apm1d.js";
|
|
32
33
|
import { B as $t } from "./badge-BUk4RjTS.js";
|
|
@@ -34,7 +35,7 @@ import { C as xn } from "./counter-WsvRuum1.js";
|
|
|
34
35
|
import { D as qe } from "./description-list-DA4TgL_I.js";
|
|
35
36
|
import { T as Et } from "./timestamp-UMF1llBs.js";
|
|
36
37
|
import { T as Nn } from "./transaction-chip-CkYd-3ky.js";
|
|
37
|
-
import { H as
|
|
38
|
+
import { H as Ae } from "./hover-card-CS8ulBf9.js";
|
|
38
39
|
import { c as qt } from "./createLucideIcon-DhHxpK9K.js";
|
|
39
40
|
import { S as Ct } from "./smartphone-C0rFF2if.js";
|
|
40
41
|
import { P as Tn } from "./phone-FceYcIFQ.js";
|
|
@@ -47,11 +48,11 @@ import { C as Pn } from "./credit-card-D9XZsHGA.js";
|
|
|
47
48
|
import { H as Ln } from "./heart-pulse-BCppJyN2.js";
|
|
48
49
|
import { R as On } from "./refresh-cw-DnI0cLFC.js";
|
|
49
50
|
import { C as _n } from "./calendar-days-BGWklvE-.js";
|
|
50
|
-
import { C as
|
|
51
|
-
import { H as
|
|
51
|
+
import { C as Fn } from "./clock-Drd4Wtis.js";
|
|
52
|
+
import { H as Hn } from "./hourglass-BEAzW1wE.js";
|
|
52
53
|
import { V as zt } from "./video-BheNGvsu.js";
|
|
53
54
|
import { A as It } from "./armchair-BaLDW6Hz.js";
|
|
54
|
-
import { B as
|
|
55
|
+
import { B as Mn } from "./building-2-D33bLCWL.js";
|
|
55
56
|
import { R as Wn } from "./repeat-CvQa5rZt.js";
|
|
56
57
|
import { N as Bn } from "./notebook-pen-CO7HoM-W.js";
|
|
57
58
|
import { C as st } from "./clipboard-list-rSzfIYZB.js";
|
|
@@ -227,11 +228,11 @@ function ot(t) {
|
|
|
227
228
|
const n = document.activeElement;
|
|
228
229
|
n && n !== document.body || t == null || t.focus({ preventScroll: !0 });
|
|
229
230
|
}
|
|
230
|
-
function
|
|
231
|
+
function _e(t) {
|
|
231
232
|
const n = document.getElementById(t);
|
|
232
233
|
n && !n.hasAttribute("tabindex") && (n.tabIndex = -1), ot(n);
|
|
233
234
|
}
|
|
234
|
-
const
|
|
235
|
+
const le = {
|
|
235
236
|
advancedSignature: "setup-advanced-signature",
|
|
236
237
|
requestSignature: "request-signature",
|
|
237
238
|
signOnDevice: "sign-on-device",
|
|
@@ -289,42 +290,42 @@ function da(t, n, i) {
|
|
|
289
290
|
function ca(t, n, i, d) {
|
|
290
291
|
const c = fn[i.frequency];
|
|
291
292
|
if (!c) return;
|
|
292
|
-
const l = (
|
|
293
|
-
(
|
|
294
|
-
) : [], f = i.frequency === "monthly" || i.frequency === "yearly" ? a.find(([,
|
|
295
|
-
let
|
|
293
|
+
const l = (y) => `calendarWorkspace.editor.${y}`, u = (y) => `calendarWorkspace.details.${y}`, p = oa[i.frequency], r = p && (i.interval ?? 1) > 1 ? t(l(p), { count: i.interval }) : t(l(c)), a = (i.byDay ?? []).map((y) => la.exec(y)).filter((y) => y !== null), o = i.frequency === "weekly" ? sa.filter(
|
|
294
|
+
(y) => a.some(([, m, N]) => !m && N === y)
|
|
295
|
+
) : [], f = i.frequency === "monthly" || i.frequency === "yearly" ? a.find(([, y]) => y) : void 0;
|
|
296
|
+
let v = r;
|
|
296
297
|
if (o.length > 0)
|
|
297
|
-
|
|
298
|
+
v = t(u("seriesOnDays"), {
|
|
298
299
|
every: r,
|
|
299
300
|
days: new Intl.ListFormat(n, { type: "conjunction" }).format(
|
|
300
|
-
o.map((
|
|
301
|
+
o.map((y) => Pt(y, n))
|
|
301
302
|
)
|
|
302
303
|
});
|
|
303
304
|
else if (f) {
|
|
304
|
-
const [,
|
|
305
|
-
|
|
305
|
+
const [, y, m] = f, N = Pt(m, n);
|
|
306
|
+
v = y === "-1" ? t(u("seriesOnLast"), { every: r, weekday: N }) : t(u("seriesOnNth"), {
|
|
306
307
|
every: r,
|
|
307
308
|
weekday: N,
|
|
308
|
-
ordinal: t(l(ra[
|
|
309
|
+
ordinal: t(l(ra[y]))
|
|
309
310
|
});
|
|
310
311
|
}
|
|
311
312
|
if (i.count !== void 0)
|
|
312
313
|
return t(u("seriesRule"), {
|
|
313
|
-
frequency:
|
|
314
|
+
frequency: v,
|
|
314
315
|
count: i.count
|
|
315
316
|
});
|
|
316
317
|
const k = i.untilIso ? da(n, i.untilIso, d) : void 0;
|
|
317
|
-
return k ? t(u("seriesUntil"), { rule:
|
|
318
|
+
return k ? t(u("seriesUntil"), { rule: v, date: k }) : v;
|
|
318
319
|
}
|
|
319
320
|
function rt({
|
|
320
321
|
eyebrow: t,
|
|
321
322
|
heading: n,
|
|
322
323
|
facts: i
|
|
323
324
|
}) {
|
|
324
|
-
return /* @__PURE__ */
|
|
325
|
-
/* @__PURE__ */ e(
|
|
326
|
-
/* @__PURE__ */ e(
|
|
327
|
-
i && i.length > 0 ? /* @__PURE__ */ e(
|
|
325
|
+
return /* @__PURE__ */ b(ne, { children: [
|
|
326
|
+
/* @__PURE__ */ e(Ae.Eyebrow, { children: t }),
|
|
327
|
+
/* @__PURE__ */ e(Ae.Heading, { children: n }),
|
|
328
|
+
i && i.length > 0 ? /* @__PURE__ */ e(Ae.Body, { children: /* @__PURE__ */ e("ul", { className: "ds:m-0 ds:flex ds:list-none ds:flex-col ds:gap-[var(--spacing-2xs)] ds:p-0 type-body-sm", children: i.map((d, c) => /* @__PURE__ */ e(
|
|
328
329
|
"li",
|
|
329
330
|
{
|
|
330
331
|
className: d.muted ? "ds:text-[color:var(--muted-foreground)]" : void 0,
|
|
@@ -342,9 +343,9 @@ function Lt({
|
|
|
342
343
|
facts: d,
|
|
343
344
|
children: c
|
|
344
345
|
}) {
|
|
345
|
-
return /* @__PURE__ */
|
|
346
|
-
/* @__PURE__ */ e(
|
|
347
|
-
/* @__PURE__ */ e(
|
|
346
|
+
return /* @__PURE__ */ b(Ae, { children: [
|
|
347
|
+
/* @__PURE__ */ e(Ae.Trigger, { asChild: !0, children: /* @__PURE__ */ e("button", { type: "button", "data-chip-hover": t, className: ua, children: c }) }),
|
|
348
|
+
/* @__PURE__ */ e(Ae.Content, { side: "bottom", align: "start", size: "sm", children: /* @__PURE__ */ e(rt, { eyebrow: n, heading: i, facts: d }) })
|
|
348
349
|
] });
|
|
349
350
|
}
|
|
350
351
|
const s = (t) => `calendarWorkspace.details.${t}`, pa = {
|
|
@@ -373,7 +374,7 @@ function Ke({
|
|
|
373
374
|
}
|
|
374
375
|
function Ot({ rows: t }) {
|
|
375
376
|
const n = t.filter((i) => !!i);
|
|
376
|
-
return n.length === 0 ? null : /* @__PURE__ */ e(qe, { layout: "inline", density: "compact", children: n.map((i) => /* @__PURE__ */
|
|
377
|
+
return n.length === 0 ? null : /* @__PURE__ */ e(qe, { layout: "inline", density: "compact", children: n.map((i) => /* @__PURE__ */ b(
|
|
377
378
|
qe.Row,
|
|
378
379
|
{
|
|
379
380
|
"data-row": i.id,
|
|
@@ -397,25 +398,25 @@ function ma({
|
|
|
397
398
|
onSignOnDevice: p,
|
|
398
399
|
onOpenPatient: r
|
|
399
400
|
}) {
|
|
400
|
-
const { t: a } =
|
|
401
|
+
const { t: a } = G("ui"), { patient: o, signing: f, money: v, booking: k } = t;
|
|
401
402
|
if (!o) return null;
|
|
402
|
-
const
|
|
403
|
+
const y = (f == null ? void 0 : f.consents) ?? [], m = f && (f.required > 0 || y.length > 0) ? f : void 0, N = ((m == null ? void 0 : m.toComplete) ?? 0) > 0, L = m ? [
|
|
403
404
|
{
|
|
404
405
|
text: N ? m.requestedVia === "sms" ? a(s("signingRequestedSms")) : m.requestedVia === "email" ? a(s("signingRequestedEmail")) : a(s("signingNotRequested")) : a(s("signingAllSigned"))
|
|
405
406
|
},
|
|
406
407
|
...m.aesSetUp ? [] : [{ text: a(s("aesMissing")), muted: !0 }]
|
|
407
|
-
] : [], P = ((f == null ? void 0 : f.required) ?? 0) > 0 && N, T = !!(l != null && l.advancedSignatureUrl) && ((f == null ? void 0 : f.required) ?? 0) > 0 && !(f != null && f.aesSetUp),
|
|
408
|
+
] : [], P = ((f == null ? void 0 : f.required) ?? 0) > 0 && N, T = !!(l != null && l.advancedSignatureUrl) && ((f == null ? void 0 : f.required) ?? 0) > 0 && !(f != null && f.aesSetUp), H = !!u && P, E = !!p && P, I = o.highlightedAnamnesisCount ?? 0, M = o.expiredAnamnesisCount ?? 0, q = (o.highlightedAnamnesisAnswers ?? []).map((x) => ({
|
|
408
409
|
text: [
|
|
409
410
|
x.question,
|
|
410
411
|
a(s(x.yes ? "anamnesisYes" : "anamnesisNo")),
|
|
411
412
|
x.answer,
|
|
412
413
|
it(n, x.interviewIso)
|
|
413
414
|
].filter(Boolean).join(" · ")
|
|
414
|
-
})),
|
|
415
|
+
})), X = gn(o), ae = vn(o) || X, z = y.map((x) => ({
|
|
415
416
|
id: `consent-${x.id}`,
|
|
416
417
|
label: x.name,
|
|
417
418
|
value: a(s(pa[x.state]))
|
|
418
|
-
})),
|
|
419
|
+
})), K = [
|
|
419
420
|
...o.dobIso ? [
|
|
420
421
|
{
|
|
421
422
|
id: "dob",
|
|
@@ -429,11 +430,11 @@ function ma({
|
|
|
429
430
|
)}`
|
|
430
431
|
}
|
|
431
432
|
] : [],
|
|
432
|
-
...bn(o).map((x,
|
|
433
|
-
const
|
|
433
|
+
...bn(o).map((x, Y) => {
|
|
434
|
+
const Z = x.label === "mobile" || x.label === "home" || x.label === "work";
|
|
434
435
|
return {
|
|
435
|
-
id: `phone-${
|
|
436
|
-
label: a(
|
|
436
|
+
id: `phone-${Y}`,
|
|
437
|
+
label: a(Z ? `calendarWorkspace.print.phoneLabels.${x.label}` : s("phone")),
|
|
437
438
|
icon: x.label === "mobile" ? /* @__PURE__ */ e(Ct, {}) : /* @__PURE__ */ e(Tn, {}),
|
|
438
439
|
value: jt(x.number)
|
|
439
440
|
};
|
|
@@ -448,7 +449,7 @@ function ma({
|
|
|
448
449
|
] : [],
|
|
449
450
|
/* P27: hidden patient details leave the address out, and with it the
|
|
450
451
|
row: no map link and no empty "address" line. */
|
|
451
|
-
...c &&
|
|
452
|
+
...c && X ? [
|
|
452
453
|
{
|
|
453
454
|
id: "address",
|
|
454
455
|
label: a(s("address")),
|
|
@@ -459,32 +460,32 @@ function ma({
|
|
|
459
460
|
href: kn(o),
|
|
460
461
|
target: "_blank",
|
|
461
462
|
rel: "noopener noreferrer",
|
|
462
|
-
"aria-label": `${a(s("mapsLink"))}: ${
|
|
463
|
-
children:
|
|
463
|
+
"aria-label": `${a(s("mapsLink"))}: ${ae}`,
|
|
464
|
+
children: ae
|
|
464
465
|
}
|
|
465
466
|
)
|
|
466
467
|
}
|
|
467
468
|
] : []
|
|
468
|
-
], W = (
|
|
469
|
+
], W = (v == null ? void 0 : v.unpaidAmount) ?? 0, j = (v == null ? void 0 : v.billableAmount) ?? 0, J = (k == null ? void 0 : k.paidOnlineAmount) ?? 0, Q = (x, Y, Z, xe, Ne, pe) => /* @__PURE__ */ e(
|
|
469
470
|
Lt,
|
|
470
471
|
{
|
|
471
|
-
id:
|
|
472
|
+
id: Z,
|
|
472
473
|
eyebrow: a(s("hoverBilling")),
|
|
473
|
-
heading: a(s(
|
|
474
|
-
amount: Vt(n,
|
|
474
|
+
heading: a(s(xe), {
|
|
475
|
+
amount: Vt(n, Y, i)
|
|
475
476
|
}),
|
|
476
|
-
facts: [{ text: a(s(
|
|
477
|
+
facts: [{ text: a(s(Ne)) }],
|
|
477
478
|
children: /* @__PURE__ */ e(
|
|
478
479
|
Nn,
|
|
479
480
|
{
|
|
480
|
-
"data-chip":
|
|
481
|
+
"data-chip": Z,
|
|
481
482
|
state: x,
|
|
482
|
-
amount:
|
|
483
|
+
amount: Y,
|
|
483
484
|
currency: i,
|
|
484
485
|
locale: n,
|
|
485
486
|
size: "md",
|
|
486
487
|
showLabel: !0,
|
|
487
|
-
label:
|
|
488
|
+
label: pe,
|
|
488
489
|
showIcon: !1
|
|
489
490
|
}
|
|
490
491
|
)
|
|
@@ -521,29 +522,29 @@ function ma({
|
|
|
521
522
|
{
|
|
522
523
|
eyebrow: a(s("anamnesisTitle")),
|
|
523
524
|
heading: a(s("anamnesisHighlighted"), { n: I }),
|
|
524
|
-
facts:
|
|
525
|
+
facts: q
|
|
525
526
|
}
|
|
526
527
|
)
|
|
527
528
|
},
|
|
528
|
-
extraChips: W > 0 ||
|
|
529
|
-
/* @__PURE__ */
|
|
530
|
-
W > 0 ?
|
|
529
|
+
extraChips: W > 0 || j > 0 || J > 0 || M > 0 || T || H || E || r ? /* @__PURE__ */ b(ne, { children: [
|
|
530
|
+
/* @__PURE__ */ b("span", { className: "ds:inline-flex ds:flex-wrap ds:items-center ds:gap-[var(--spacing-xs)]", children: [
|
|
531
|
+
W > 0 ? Q(
|
|
531
532
|
"debt",
|
|
532
533
|
W,
|
|
533
534
|
"unpaid",
|
|
534
535
|
"hoverUnpaidHeading",
|
|
535
536
|
"hoverUnpaidFact"
|
|
536
537
|
) : null,
|
|
537
|
-
|
|
538
|
+
j > 0 ? Q(
|
|
538
539
|
"to-invoice",
|
|
539
|
-
|
|
540
|
+
j,
|
|
540
541
|
"billable",
|
|
541
542
|
"hoverBillableHeading",
|
|
542
543
|
"hoverBillableFact"
|
|
543
544
|
) : null,
|
|
544
|
-
|
|
545
|
+
J > 0 ? Q(
|
|
545
546
|
"settled",
|
|
546
|
-
|
|
547
|
+
J,
|
|
547
548
|
"paidOnline",
|
|
548
549
|
"hoverPaidOnlineHeading",
|
|
549
550
|
"hoverPaidOnlineFact",
|
|
@@ -552,12 +553,12 @@ function ma({
|
|
|
552
553
|
a(s("paidOnline"))
|
|
553
554
|
) : null
|
|
554
555
|
] }),
|
|
555
|
-
|
|
556
|
+
H ? /* @__PURE__ */ e(
|
|
556
557
|
C,
|
|
557
558
|
{
|
|
558
559
|
size: "sm",
|
|
559
560
|
intent: "outline",
|
|
560
|
-
"data-action":
|
|
561
|
+
"data-action": le.requestSignature,
|
|
561
562
|
startIcon: /* @__PURE__ */ e(In, { "aria-hidden": "true" }),
|
|
562
563
|
onClick: () => u(t.eventId),
|
|
563
564
|
children: a(s("signingRequest"))
|
|
@@ -568,7 +569,7 @@ function ma({
|
|
|
568
569
|
{
|
|
569
570
|
size: "sm",
|
|
570
571
|
intent: "outline",
|
|
571
|
-
"data-action":
|
|
572
|
+
"data-action": le.signOnDevice,
|
|
572
573
|
"aria-label": `${a(s("signingRequest"))}: ${a(s("signingOnDevice"))}`,
|
|
573
574
|
startIcon: /* @__PURE__ */ e(Ct, { "aria-hidden": "true" }),
|
|
574
575
|
onClick: () => p(t.eventId),
|
|
@@ -580,7 +581,7 @@ function ma({
|
|
|
580
581
|
{
|
|
581
582
|
size: "sm",
|
|
582
583
|
intent: "outline",
|
|
583
|
-
"data-action":
|
|
584
|
+
"data-action": le.openPatient,
|
|
584
585
|
startIcon: /* @__PURE__ */ e(Dn, { "aria-hidden": "true" }),
|
|
585
586
|
onClick: () => r(t.eventId),
|
|
586
587
|
children: a(s("openPatient"))
|
|
@@ -590,26 +591,26 @@ function ma({
|
|
|
590
591
|
Ke,
|
|
591
592
|
{
|
|
592
593
|
href: l.advancedSignatureUrl,
|
|
593
|
-
action:
|
|
594
|
+
action: le.advancedSignature,
|
|
594
595
|
icon: /* @__PURE__ */ e(Rn, { "aria-hidden": "true" }),
|
|
595
596
|
children: a(s("aesSetUp"))
|
|
596
597
|
}
|
|
597
598
|
) : null,
|
|
598
|
-
l != null && l.unlockPaymentsUrl && (W > 0 ||
|
|
599
|
+
l != null && l.unlockPaymentsUrl && (W > 0 || j > 0) ? /* @__PURE__ */ e(
|
|
599
600
|
Ke,
|
|
600
601
|
{
|
|
601
602
|
href: l.unlockPaymentsUrl,
|
|
602
|
-
action:
|
|
603
|
+
action: le.unlockPayments,
|
|
603
604
|
icon: /* @__PURE__ */ e(Pn, { "aria-hidden": "true" }),
|
|
604
605
|
children: a(s("unlockPayments"))
|
|
605
606
|
}
|
|
606
607
|
) : null,
|
|
607
|
-
|
|
608
|
+
M > 0 ? /* @__PURE__ */ e(
|
|
608
609
|
Lt,
|
|
609
610
|
{
|
|
610
611
|
id: "anamnesisExpired",
|
|
611
612
|
eyebrow: a(s("anamnesisTitle")),
|
|
612
|
-
heading: a(s("anamnesisExpired"), { n:
|
|
613
|
+
heading: a(s("anamnesisExpired"), { n: M }),
|
|
613
614
|
facts: [{ text: a(s("hoverAnamnesisExpiredFact")) }],
|
|
614
615
|
children: /* @__PURE__ */ e(
|
|
615
616
|
$t,
|
|
@@ -618,29 +619,29 @@ function ma({
|
|
|
618
619
|
variant: "warning",
|
|
619
620
|
size: "md",
|
|
620
621
|
leading: /* @__PURE__ */ e(Ln, {}),
|
|
621
|
-
children: a(s("anamnesisExpired"), { n:
|
|
622
|
+
children: a(s("anamnesisExpired"), { n: M })
|
|
622
623
|
}
|
|
623
624
|
)
|
|
624
625
|
}
|
|
625
626
|
) : null,
|
|
626
|
-
|
|
627
|
+
M > 0 && (l != null && l.renewAnamnesisUrl) ? /* @__PURE__ */ e(
|
|
627
628
|
Ke,
|
|
628
629
|
{
|
|
629
630
|
href: l.renewAnamnesisUrl,
|
|
630
|
-
action:
|
|
631
|
+
action: le.renewAnamnesis,
|
|
631
632
|
icon: /* @__PURE__ */ e(On, { "aria-hidden": "true" }),
|
|
632
633
|
children: a(s("anamnesisRenew"))
|
|
633
634
|
}
|
|
634
635
|
) : null
|
|
635
636
|
] }) : void 0,
|
|
636
|
-
visibleFieldOrder: [...
|
|
637
|
-
sections:
|
|
638
|
-
...
|
|
639
|
-
...
|
|
637
|
+
visibleFieldOrder: [...K, ...z].map((x) => x.id),
|
|
638
|
+
sections: K.length > 0 || z.length > 0 ? [
|
|
639
|
+
...K.length > 0 ? [{ id: "contact", heading: a(s("sectionPatient")), fields: K }] : [],
|
|
640
|
+
...z.length > 0 ? [
|
|
640
641
|
{
|
|
641
642
|
id: "consents",
|
|
642
643
|
heading: a(s("sectionSigning")),
|
|
643
|
-
fields:
|
|
644
|
+
fields: z
|
|
644
645
|
}
|
|
645
646
|
] : []
|
|
646
647
|
] : void 0
|
|
@@ -657,7 +658,7 @@ function ha({
|
|
|
657
658
|
privacy: u = !1,
|
|
658
659
|
history: p
|
|
659
660
|
}) {
|
|
660
|
-
const { t: r } =
|
|
661
|
+
const { t: r } = G("ui"), { appointment: a, booking: o, patient: f } = t, v = (I) => r(`calendarWorkspace.editor.${I}`), k = new Date(a.startIso), y = new Date(k.getTime() + a.durationMin * 6e4), m = Number.isFinite(k.getTime()), { recurrence: N } = a, L = N && ca(r, n, N, a.startIso), P = o ? [
|
|
661
662
|
o.bookedAtIso && {
|
|
662
663
|
id: "bookedAt",
|
|
663
664
|
label: r(s("bookedAt")),
|
|
@@ -698,11 +699,11 @@ function ha({
|
|
|
698
699
|
label: r(s("paidOnline")),
|
|
699
700
|
value: Vt(n, o.paidOnlineAmount, i)
|
|
700
701
|
}
|
|
701
|
-
] : [], T = u ? P.filter((I) => I && I.id === "bookedAt") : P,
|
|
702
|
+
] : [], T = u ? P.filter((I) => I && I.id === "bookedAt") : P, H = T.some(Boolean), E = o || a.bookedOnline || p == null ? void 0 : p.filter(
|
|
702
703
|
(I) => (I.kind === "created" || I.kind === "copied") && I.actor.trim() !== ""
|
|
703
|
-
).sort((I,
|
|
704
|
-
return /* @__PURE__ */
|
|
705
|
-
|
|
704
|
+
).sort((I, M) => Date.parse(I.atIso) - Date.parse(M.atIso))[0];
|
|
705
|
+
return /* @__PURE__ */ b(
|
|
706
|
+
ue,
|
|
706
707
|
{
|
|
707
708
|
"data-card": "appointment",
|
|
708
709
|
title: r(s("sectionAppointment")),
|
|
@@ -715,27 +716,27 @@ function ha({
|
|
|
715
716
|
rows: [
|
|
716
717
|
m && {
|
|
717
718
|
id: "date",
|
|
718
|
-
label:
|
|
719
|
+
label: v("date"),
|
|
719
720
|
icon: /* @__PURE__ */ e(_n, {}),
|
|
720
721
|
value: it(n, k)
|
|
721
722
|
},
|
|
722
723
|
m && {
|
|
723
724
|
id: "time",
|
|
724
725
|
label: r(s("time")),
|
|
725
|
-
icon: /* @__PURE__ */ e(
|
|
726
|
-
value: a.allDay ?
|
|
726
|
+
icon: /* @__PURE__ */ e(Fn, {}),
|
|
727
|
+
value: a.allDay ? v("allDay") : wn(n, k, y)
|
|
727
728
|
},
|
|
728
729
|
!a.allDay && {
|
|
729
730
|
id: "duration",
|
|
730
|
-
label:
|
|
731
|
-
icon: /* @__PURE__ */ e(
|
|
732
|
-
value: `${a.durationMin} ${
|
|
731
|
+
label: v("duration"),
|
|
732
|
+
icon: /* @__PURE__ */ e(Hn, {}),
|
|
733
|
+
value: `${a.durationMin} ${v("durationUnit")}`
|
|
733
734
|
},
|
|
734
735
|
a.isTelehealth && {
|
|
735
736
|
id: "type",
|
|
736
|
-
label:
|
|
737
|
+
label: v("type"),
|
|
737
738
|
icon: /* @__PURE__ */ e(zt, {}),
|
|
738
|
-
value:
|
|
739
|
+
value: v("typeTelehealth")
|
|
739
740
|
},
|
|
740
741
|
d && {
|
|
741
742
|
id: "operator",
|
|
@@ -752,15 +753,15 @@ function ha({
|
|
|
752
753
|
},
|
|
753
754
|
a.branchLabel && {
|
|
754
755
|
id: "branch",
|
|
755
|
-
label:
|
|
756
|
-
icon: /* @__PURE__ */ e(
|
|
756
|
+
label: v("branch"),
|
|
757
|
+
icon: /* @__PURE__ */ e(Mn, {}),
|
|
757
758
|
value: a.branchLabel
|
|
758
759
|
},
|
|
759
760
|
E && {
|
|
760
761
|
id: "createdBy",
|
|
761
762
|
label: r(s("createdBy")),
|
|
762
763
|
icon: /* @__PURE__ */ e(Tt, { name: E.actor, size: "xs" }),
|
|
763
|
-
value: /* @__PURE__ */
|
|
764
|
+
value: /* @__PURE__ */ b("span", { className: "ds:inline-flex ds:flex-wrap ds:items-baseline ds:gap-x-[var(--spacing-xs)]", children: [
|
|
764
765
|
/* @__PURE__ */ e("span", { children: E.actor }),
|
|
765
766
|
" ",
|
|
766
767
|
/* @__PURE__ */ e("span", { className: "ds:text-[color:var(--muted-foreground)]", children: /* @__PURE__ */ e(
|
|
@@ -784,7 +785,7 @@ function ha({
|
|
|
784
785
|
]
|
|
785
786
|
}
|
|
786
787
|
),
|
|
787
|
-
|
|
788
|
+
H ? /* @__PURE__ */ b(
|
|
788
789
|
"div",
|
|
789
790
|
{
|
|
790
791
|
"data-block": "booking",
|
|
@@ -806,16 +807,16 @@ function fa({
|
|
|
806
807
|
privacy: d = !1,
|
|
807
808
|
carePlanUrl: c
|
|
808
809
|
}) {
|
|
809
|
-
const { t: l } =
|
|
810
|
-
return !u || !p && u.lines.length === 0 ? null : /* @__PURE__ */
|
|
811
|
-
|
|
810
|
+
const { t: l } = G("ui"), { care: u } = t, p = d || u == null ? void 0 : u.plan;
|
|
811
|
+
return !u || !p && u.lines.length === 0 ? null : /* @__PURE__ */ b(
|
|
812
|
+
ue,
|
|
812
813
|
{
|
|
813
814
|
"data-card": "treatments",
|
|
814
815
|
title: l(s("sectionTreatments")),
|
|
815
816
|
headingLevel: 3,
|
|
816
817
|
children: [
|
|
817
|
-
p ? /* @__PURE__ */
|
|
818
|
-
/* @__PURE__ */
|
|
818
|
+
p ? /* @__PURE__ */ b("span", { className: "ds:flex ds:flex-wrap ds:items-center ds:justify-between ds:gap-[var(--spacing-xs)]", children: [
|
|
819
|
+
/* @__PURE__ */ b("span", { className: "ds:flex ds:items-center ds:gap-[var(--spacing-xs)] type-title-item", children: [
|
|
819
820
|
/* @__PURE__ */ e(
|
|
820
821
|
st,
|
|
821
822
|
{
|
|
@@ -829,7 +830,7 @@ function fa({
|
|
|
829
830
|
Ke,
|
|
830
831
|
{
|
|
831
832
|
href: c,
|
|
832
|
-
action:
|
|
833
|
+
action: le.carePlan,
|
|
833
834
|
icon: /* @__PURE__ */ e(st, { "aria-hidden": "true" }),
|
|
834
835
|
children: l(s("openCarePlan"))
|
|
835
836
|
}
|
|
@@ -856,21 +857,21 @@ function ga({
|
|
|
856
857
|
onOpenNotes: n,
|
|
857
858
|
locale: i
|
|
858
859
|
}) {
|
|
859
|
-
const { t: d } =
|
|
860
|
-
|
|
861
|
-
u.current && (l !== "loading" && (u.current = !1),
|
|
860
|
+
const { t: d } = G("ui"), c = tt(), l = t.status ?? "ready", u = R(!1);
|
|
861
|
+
de(() => {
|
|
862
|
+
u.current && (l !== "loading" && (u.current = !1), _e(c));
|
|
862
863
|
}, [l, c]);
|
|
863
864
|
const p = t.total ?? (l === "ready" ? t.notes.length : null), r = Math.max(0, (p ?? 0) - _t), a = r > 0 ? d(s("notesMore"), { n: r }) : d(s("notesPreviewOpen"));
|
|
864
|
-
return /* @__PURE__ */
|
|
865
|
-
|
|
865
|
+
return /* @__PURE__ */ b(
|
|
866
|
+
ue,
|
|
866
867
|
{
|
|
867
868
|
"data-card": "notes",
|
|
868
869
|
headingId: c,
|
|
869
870
|
headingLevel: 3,
|
|
870
871
|
title: p === null ? d("notesPanel.title") : d(s("notesPreviewTitle"), { count: p }),
|
|
871
|
-
headerAction: n && (p ?? 0) > 0 ? /* @__PURE__ */
|
|
872
|
+
headerAction: n && (p ?? 0) > 0 ? /* @__PURE__ */ b("span", { className: "ds:relative ds:inline-flex", children: [
|
|
872
873
|
/* @__PURE__ */ e(
|
|
873
|
-
|
|
874
|
+
Ht,
|
|
874
875
|
{
|
|
875
876
|
icon: /* @__PURE__ */ e(Bn, { "aria-hidden": "true" }),
|
|
876
877
|
intent: "outline",
|
|
@@ -897,9 +898,9 @@ function ga({
|
|
|
897
898
|
) : null
|
|
898
899
|
] }) : void 0,
|
|
899
900
|
children: [
|
|
900
|
-
l === "error" ? /* @__PURE__ */
|
|
901
|
-
/* @__PURE__ */ e(
|
|
902
|
-
t.onRetry ? /* @__PURE__ */ e(
|
|
901
|
+
l === "error" ? /* @__PURE__ */ b(ce, { variant: "error", children: [
|
|
902
|
+
/* @__PURE__ */ e(ce.Description, { children: d("notesPanel.loadError") }),
|
|
903
|
+
t.onRetry ? /* @__PURE__ */ e(ce.Action, { children: /* @__PURE__ */ e(
|
|
903
904
|
C,
|
|
904
905
|
{
|
|
905
906
|
intent: "secondary",
|
|
@@ -912,7 +913,7 @@ function ga({
|
|
|
912
913
|
}
|
|
913
914
|
) }) : null
|
|
914
915
|
] }) : null,
|
|
915
|
-
t.notes.length === 0 && l === "loading" ? /* @__PURE__ */
|
|
916
|
+
t.notes.length === 0 && l === "loading" ? /* @__PURE__ */ b(ne, { children: [
|
|
916
917
|
/* @__PURE__ */ e("span", { role: "status", className: "ds:sr-only", children: d("notesPanel.loading") }),
|
|
917
918
|
/* @__PURE__ */ e(at, { notes: [], loading: !0, loadingRows: 2 })
|
|
918
919
|
] }) : l !== "error" || t.notes.length > 0 ? (
|
|
@@ -963,7 +964,7 @@ const va = lt("ds:flex ds:h-full ds:min-h-0 ds:flex-col"), ya = lt(
|
|
|
963
964
|
identification: /* @__PURE__ */ e(ta, { "aria-hidden": "true" }),
|
|
964
965
|
webcam: /* @__PURE__ */ e(Yn, { "aria-hidden": "true" })
|
|
965
966
|
}, S = (t) => `calendarWorkspace.details.${t}`;
|
|
966
|
-
function
|
|
967
|
+
function Ft({
|
|
967
968
|
children: t,
|
|
968
969
|
startIcon: n,
|
|
969
970
|
overflowItems: i,
|
|
@@ -973,7 +974,7 @@ function Ht({
|
|
|
973
974
|
size: u,
|
|
974
975
|
hideLabel: p
|
|
975
976
|
}) {
|
|
976
|
-
return /* @__PURE__ */
|
|
977
|
+
return /* @__PURE__ */ b($e.Root, { children: [
|
|
977
978
|
/* @__PURE__ */ e(ln, { label: t, side: "top", children: /* @__PURE__ */ e($e.Trigger, { asChild: !0, children: /* @__PURE__ */ e(
|
|
978
979
|
C,
|
|
979
980
|
{
|
|
@@ -1001,10 +1002,10 @@ function Ht({
|
|
|
1001
1002
|
] });
|
|
1002
1003
|
}
|
|
1003
1004
|
function xa() {
|
|
1004
|
-
const { t } =
|
|
1005
|
-
return /* @__PURE__ */
|
|
1005
|
+
const { t } = G("ui");
|
|
1006
|
+
return /* @__PURE__ */ b(ne, { children: [
|
|
1006
1007
|
/* @__PURE__ */ e("span", { role: "status", className: "ds:sr-only", children: t("common.loading") }),
|
|
1007
|
-
/* @__PURE__ */
|
|
1008
|
+
/* @__PURE__ */ b(
|
|
1008
1009
|
"div",
|
|
1009
1010
|
{
|
|
1010
1011
|
"aria-hidden": "true",
|
|
@@ -1019,15 +1020,15 @@ function xa() {
|
|
|
1019
1020
|
density: "compact"
|
|
1020
1021
|
}
|
|
1021
1022
|
),
|
|
1022
|
-
/* @__PURE__ */
|
|
1023
|
-
/* @__PURE__ */ e(
|
|
1024
|
-
/* @__PURE__ */ e("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: Gt.map((n, i) => /* @__PURE__ */
|
|
1023
|
+
/* @__PURE__ */ b(ue, { title: t(S("sectionAppointment")), headingLevel: 3, children: [
|
|
1024
|
+
/* @__PURE__ */ e(Mt, { loading: !0, maxLines: 2 }),
|
|
1025
|
+
/* @__PURE__ */ e("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: Gt.map((n, i) => /* @__PURE__ */ b(
|
|
1025
1026
|
"div",
|
|
1026
1027
|
{
|
|
1027
1028
|
className: "ds:flex ds:items-center ds:gap-[var(--spacing-sm)]",
|
|
1028
1029
|
children: [
|
|
1029
1030
|
/* @__PURE__ */ e(
|
|
1030
|
-
|
|
1031
|
+
we,
|
|
1031
1032
|
{
|
|
1032
1033
|
variant: "rounded",
|
|
1033
1034
|
stagger: i + 2,
|
|
@@ -1037,7 +1038,7 @@ function xa() {
|
|
|
1037
1038
|
}
|
|
1038
1039
|
),
|
|
1039
1040
|
/* @__PURE__ */ e(
|
|
1040
|
-
|
|
1041
|
+
we,
|
|
1041
1042
|
{
|
|
1042
1043
|
variant: "text",
|
|
1043
1044
|
size: "sm",
|
|
@@ -1050,20 +1051,20 @@ function xa() {
|
|
|
1050
1051
|
n
|
|
1051
1052
|
)) })
|
|
1052
1053
|
] }),
|
|
1053
|
-
/* @__PURE__ */ e(
|
|
1054
|
-
/* @__PURE__ */ e(
|
|
1054
|
+
/* @__PURE__ */ e(ue, { title: t("notesPanel.title"), headingLevel: 3, children: /* @__PURE__ */ e(at, { notes: [], loading: !0, loadingRows: 2 }) }),
|
|
1055
|
+
/* @__PURE__ */ e(ue, { title: t(S("sectionTreatments")), headingLevel: 3, children: /* @__PURE__ */ e(Ut, { lines: [], loading: !0 }) })
|
|
1055
1056
|
]
|
|
1056
1057
|
}
|
|
1057
1058
|
),
|
|
1058
|
-
/* @__PURE__ */
|
|
1059
|
+
/* @__PURE__ */ b(
|
|
1059
1060
|
"div",
|
|
1060
1061
|
{
|
|
1061
1062
|
"aria-hidden": "true",
|
|
1062
1063
|
className: "ds:flex ds:shrink-0 ds:items-center ds:gap-[var(--spacing-sm)] ds:border-t ds:border-[color:var(--border)] ds:p-[var(--spacing-md)]",
|
|
1063
1064
|
children: [
|
|
1064
|
-
/* @__PURE__ */ e(
|
|
1065
|
+
/* @__PURE__ */ e(we, { variant: "rounded", width: "33%", height: "var(--spacing-xl)" }),
|
|
1065
1066
|
/* @__PURE__ */ e(
|
|
1066
|
-
|
|
1067
|
+
we,
|
|
1067
1068
|
{
|
|
1068
1069
|
variant: "rounded",
|
|
1069
1070
|
stagger: 1,
|
|
@@ -1084,13 +1085,13 @@ function Na({
|
|
|
1084
1085
|
privacy: c
|
|
1085
1086
|
}) {
|
|
1086
1087
|
var k;
|
|
1087
|
-
const { t: l } =
|
|
1088
|
-
|
|
1088
|
+
const { t: l } = G("ui"), u = t.status ?? (t.entries ? "ready" : "loading"), p = u === "error" ? void 0 : t.entries, r = u === "loading" || u !== "error" && !p, [a, o] = F(!1);
|
|
1089
|
+
Se(() => o(!0), []);
|
|
1089
1090
|
let f = "";
|
|
1090
1091
|
r ? f = l("common.loading") : p && (f = p.length === 0 ? l(S("historyEmpty")) : l(S("historyLoaded"), { n: p.length }));
|
|
1091
|
-
let
|
|
1092
|
-
return u === "error" ?
|
|
1093
|
-
/* @__PURE__ */ e(
|
|
1092
|
+
let v;
|
|
1093
|
+
return u === "error" ? v = /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
1094
|
+
/* @__PURE__ */ e(ce, { variant: "error", children: /* @__PURE__ */ e(ce.Description, { children: ((k = t.message) == null ? void 0 : k.trim()) || l("emptyState.error.description") }) }),
|
|
1094
1095
|
i ? /* @__PURE__ */ e(
|
|
1095
1096
|
C,
|
|
1096
1097
|
{
|
|
@@ -1100,18 +1101,18 @@ function Na({
|
|
|
1100
1101
|
children: l("emptyState.error.cta")
|
|
1101
1102
|
}
|
|
1102
1103
|
) : null
|
|
1103
|
-
] }) : r || !p ?
|
|
1104
|
+
] }) : r || !p ? v = /* @__PURE__ */ e(
|
|
1104
1105
|
"div",
|
|
1105
1106
|
{
|
|
1106
1107
|
"aria-hidden": "true",
|
|
1107
1108
|
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]",
|
|
1108
|
-
children: Gt.slice(0, 3).map((
|
|
1109
|
+
children: Gt.slice(0, 3).map((y, m) => /* @__PURE__ */ b(
|
|
1109
1110
|
"div",
|
|
1110
1111
|
{
|
|
1111
1112
|
className: "ds:flex ds:items-start ds:gap-[var(--spacing-sm)]",
|
|
1112
1113
|
children: [
|
|
1113
1114
|
/* @__PURE__ */ e(
|
|
1114
|
-
|
|
1115
|
+
we,
|
|
1115
1116
|
{
|
|
1116
1117
|
variant: "circular",
|
|
1117
1118
|
stagger: m,
|
|
@@ -1121,20 +1122,20 @@ function Na({
|
|
|
1121
1122
|
}
|
|
1122
1123
|
),
|
|
1123
1124
|
/* @__PURE__ */ e(
|
|
1124
|
-
|
|
1125
|
+
we,
|
|
1125
1126
|
{
|
|
1126
1127
|
variant: "rounded",
|
|
1127
1128
|
stagger: m,
|
|
1128
|
-
width:
|
|
1129
|
+
width: y,
|
|
1129
1130
|
height: "var(--spacing-2xl)"
|
|
1130
1131
|
}
|
|
1131
1132
|
)
|
|
1132
1133
|
]
|
|
1133
1134
|
},
|
|
1134
|
-
|
|
1135
|
+
y
|
|
1135
1136
|
))
|
|
1136
1137
|
}
|
|
1137
|
-
) :
|
|
1138
|
+
) : v = /* @__PURE__ */ e(
|
|
1138
1139
|
hn,
|
|
1139
1140
|
{
|
|
1140
1141
|
history: p,
|
|
@@ -1142,9 +1143,9 @@ function Na({
|
|
|
1142
1143
|
noteUnrecordedEdits: d,
|
|
1143
1144
|
privacy: c
|
|
1144
1145
|
}
|
|
1145
|
-
), /* @__PURE__ */
|
|
1146
|
+
), /* @__PURE__ */ b(ne, { children: [
|
|
1146
1147
|
/* @__PURE__ */ e("span", { role: "status", className: "ds:sr-only", children: a ? f : "" }),
|
|
1147
|
-
|
|
1148
|
+
v
|
|
1148
1149
|
] });
|
|
1149
1150
|
}
|
|
1150
1151
|
function Ta({
|
|
@@ -1158,123 +1159,123 @@ function Ta({
|
|
|
1158
1159
|
enter: p,
|
|
1159
1160
|
live: r,
|
|
1160
1161
|
statusControl: a,
|
|
1161
|
-
patientId: o = ((
|
|
1162
|
+
patientId: o = ((Fe) => (Fe = t.patient) == null ? void 0 : Fe.id)(),
|
|
1162
1163
|
operator: f,
|
|
1163
|
-
chair:
|
|
1164
|
+
chair: v,
|
|
1164
1165
|
privacy: k = !1,
|
|
1165
|
-
privacyTitle:
|
|
1166
|
+
privacyTitle: y,
|
|
1166
1167
|
mapsLink: m,
|
|
1167
1168
|
notesPreview: N,
|
|
1168
1169
|
onOpenNotes: L,
|
|
1169
1170
|
history: P,
|
|
1170
1171
|
onOpenHistory: T,
|
|
1171
|
-
noteUnrecordedEdits:
|
|
1172
|
+
noteUnrecordedEdits: H = !1,
|
|
1172
1173
|
readOnly: E = !1,
|
|
1173
1174
|
onStatusChange: I,
|
|
1174
|
-
allowedStatuses:
|
|
1175
|
-
onDescriptionChange:
|
|
1176
|
-
descriptionMaxLength:
|
|
1177
|
-
onAssignPatient:
|
|
1178
|
-
onEdit:
|
|
1179
|
-
onMove:
|
|
1175
|
+
allowedStatuses: M = St,
|
|
1176
|
+
onDescriptionChange: q,
|
|
1177
|
+
descriptionMaxLength: X,
|
|
1178
|
+
onAssignPatient: ae,
|
|
1179
|
+
onEdit: z,
|
|
1180
|
+
onMove: K,
|
|
1180
1181
|
onCopy: W,
|
|
1181
|
-
onDelete:
|
|
1182
|
-
onJoinTelehealth:
|
|
1183
|
-
onWhatsApp:
|
|
1182
|
+
onDelete: j,
|
|
1183
|
+
onJoinTelehealth: J,
|
|
1184
|
+
onWhatsApp: Q,
|
|
1184
1185
|
whatsappUrl: x,
|
|
1185
|
-
onBuyWhatsApp:
|
|
1186
|
-
createTaskUrl:
|
|
1187
|
-
onRequestSignature:
|
|
1188
|
-
onSignOnDevice:
|
|
1189
|
-
onOpenPatient:
|
|
1190
|
-
shortcuts:
|
|
1191
|
-
documents:
|
|
1186
|
+
onBuyWhatsApp: Y,
|
|
1187
|
+
createTaskUrl: Z,
|
|
1188
|
+
onRequestSignature: xe,
|
|
1189
|
+
onSignOnDevice: Ne,
|
|
1190
|
+
onOpenPatient: pe,
|
|
1191
|
+
shortcuts: me,
|
|
1192
|
+
documents: ie
|
|
1192
1193
|
}) {
|
|
1193
1194
|
var vt, yt;
|
|
1194
|
-
const { t: h } =
|
|
1195
|
-
|
|
1196
|
-
},
|
|
1197
|
-
|
|
1198
|
-
const g =
|
|
1199
|
-
|
|
1200
|
-
const
|
|
1201
|
-
|
|
1195
|
+
const { t: h } = G("ui"), { eventId: D } = t, [je] = F(p), he = { details: t, locale: c, currency: i }, w = P ? P.eventId !== void 0 && P.eventId !== D ? { status: "loading" } : P : t.history ? { entries: t.history } : void 0, He = (N == null ? void 0 : N.patientId) === void 0 || N.patientId === o, fe = N ? He ? N : o ? { notes: [], status: "loading", total: null } : void 0 : void 0, se = !!q && !E && !k, [Te, ee] = F(!1), [Ee, V] = F(!1), oe = Te && w !== void 0, Me = Ee && se, Ce = () => {
|
|
1196
|
+
oe || !w || (ee(!0), T == null || T(D));
|
|
1197
|
+
}, We = R({ history: !1, editor: !1 });
|
|
1198
|
+
de(() => {
|
|
1199
|
+
const g = We.current;
|
|
1200
|
+
We.current = { history: oe, editor: Me };
|
|
1201
|
+
const ke = g.history && w === void 0, bt = g.editor && !se;
|
|
1202
|
+
ke && ee(!1), bt && V(!1), (ke || bt) && _e(u);
|
|
1202
1203
|
});
|
|
1203
|
-
const
|
|
1204
|
-
|
|
1205
|
-
O.current && (
|
|
1206
|
-
}, [
|
|
1207
|
-
const [$,
|
|
1208
|
-
|
|
1209
|
-
|
|
1204
|
+
const ge = R(null), O = R(!1), Ie = (w == null ? void 0 : w.status) ?? (w != null && w.entries ? "ready" : "loading");
|
|
1205
|
+
de(() => {
|
|
1206
|
+
O.current && (Ie !== "loading" && (O.current = !1), ot(ge.current));
|
|
1207
|
+
}, [Ie]);
|
|
1208
|
+
const [$, De] = F(t.appointment.name ?? "");
|
|
1209
|
+
Se(() => {
|
|
1210
|
+
De(t.appointment.name ?? "");
|
|
1210
1211
|
}, [t.appointment.name]);
|
|
1211
|
-
const [
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
}, [
|
|
1215
|
-
const
|
|
1216
|
-
if (!
|
|
1217
|
-
const g =
|
|
1218
|
-
|
|
1212
|
+
const [ve, re] = F(""), [ye, Re] = F(!1), [A, B] = F(), be = R(null), Pe = X !== void 0 && ve.trim().length > X;
|
|
1213
|
+
Se(() => {
|
|
1214
|
+
Ee && (re($), B(void 0));
|
|
1215
|
+
}, [Ee]);
|
|
1216
|
+
const Be = async () => {
|
|
1217
|
+
if (!q) return;
|
|
1218
|
+
const g = ve.trim();
|
|
1219
|
+
Re(!0), B(void 0);
|
|
1219
1220
|
try {
|
|
1220
|
-
await
|
|
1221
|
-
} catch (
|
|
1221
|
+
await q(g, D), De(g), V(!1);
|
|
1222
|
+
} catch (ke) {
|
|
1222
1223
|
B(
|
|
1223
|
-
nt(
|
|
1224
|
+
nt(ke, h(S("descriptionSaveFailed")))
|
|
1224
1225
|
);
|
|
1225
1226
|
} finally {
|
|
1226
|
-
|
|
1227
|
+
Re(!1);
|
|
1227
1228
|
}
|
|
1228
|
-
}, [
|
|
1229
|
-
|
|
1230
|
-
|
|
1229
|
+
}, [te, Ye] = F(t.appointment.status);
|
|
1230
|
+
Se(() => {
|
|
1231
|
+
Ye(t.appointment.status);
|
|
1231
1232
|
}, [t.appointment.status]);
|
|
1232
1233
|
const dt = R(n);
|
|
1233
|
-
|
|
1234
|
+
de(() => {
|
|
1234
1235
|
const g = dt.current && !n;
|
|
1235
|
-
dt.current = n, g && (
|
|
1236
|
+
dt.current = n, g && (Ye(t.appointment.status), De(t.appointment.name ?? ""));
|
|
1236
1237
|
}, [n]);
|
|
1237
1238
|
const Ue = St.filter(
|
|
1238
|
-
(g) =>
|
|
1239
|
-
),
|
|
1239
|
+
(g) => M.includes(g)
|
|
1240
|
+
), Le = un(te, {
|
|
1240
1241
|
statuses: Ue,
|
|
1241
1242
|
/* Shown so the control can say it, but not a choice. */
|
|
1242
|
-
disabledStatuses:
|
|
1243
|
-
}),
|
|
1243
|
+
disabledStatuses: te && !Ue.includes(te) ? [te] : []
|
|
1244
|
+
}), Oe = !!I && !E && Ue.some((g) => g !== te), Xt = async (g) => {
|
|
1244
1245
|
if (!(!I || !pn(g))) {
|
|
1245
1246
|
try {
|
|
1246
1247
|
await I(g, D);
|
|
1247
|
-
} catch (
|
|
1248
|
-
throw new Error(nt(
|
|
1248
|
+
} catch (ke) {
|
|
1249
|
+
throw new Error(nt(ke, h(S("statusSaveFailed"))));
|
|
1249
1250
|
}
|
|
1250
|
-
|
|
1251
|
+
Ye(g);
|
|
1251
1252
|
}
|
|
1252
1253
|
}, ct = k ? void 0 : x, ut = Sa.filter(
|
|
1253
|
-
(g) =>
|
|
1254
|
-
),
|
|
1255
|
-
|
|
1256
|
-
const g = mt.current && !
|
|
1257
|
-
mt.current =
|
|
1254
|
+
(g) => ie == null ? void 0 : ie.kinds.includes(g)
|
|
1255
|
+
), Jt = (((vt = t.care) == null ? void 0 : vt.lines.length) ?? 0) > 0, Ve = o !== void 0 && o !== "", Ge = h(S("status")), pt = `${Ge}: ${Le.option.label}`, Xe = R(null), mt = R(Oe);
|
|
1256
|
+
de(() => {
|
|
1257
|
+
const g = mt.current && !Oe;
|
|
1258
|
+
mt.current = Oe, g && (Xe.current ? ot(Xe.current) : _e(u));
|
|
1258
1259
|
});
|
|
1259
|
-
const ht =
|
|
1260
|
+
const ht = Oe ? /* @__PURE__ */ e(
|
|
1260
1261
|
dn,
|
|
1261
1262
|
{
|
|
1262
1263
|
ref: a,
|
|
1263
|
-
value:
|
|
1264
|
-
options:
|
|
1264
|
+
value: Le.value,
|
|
1265
|
+
options: Le.options,
|
|
1265
1266
|
size: "sm",
|
|
1266
|
-
workflowLabel:
|
|
1267
|
+
workflowLabel: Ge,
|
|
1267
1268
|
className: `ds:[&>button]:bg-[color:var(--background)] ${ka}`,
|
|
1268
1269
|
"aria-label": pt,
|
|
1269
|
-
onValueChange:
|
|
1270
|
+
onValueChange: Xt
|
|
1270
1271
|
}
|
|
1271
|
-
) :
|
|
1272
|
+
) : te ? (
|
|
1272
1273
|
/* Named as the control is, "Status: Confirmed": the small display
|
|
1273
1274
|
prints the value alone. */
|
|
1274
1275
|
/* @__PURE__ */ e(
|
|
1275
1276
|
"div",
|
|
1276
1277
|
{
|
|
1277
|
-
ref:
|
|
1278
|
+
ref: Xe,
|
|
1278
1279
|
role: "group",
|
|
1279
1280
|
"aria-label": pt,
|
|
1280
1281
|
tabIndex: -1,
|
|
@@ -1283,16 +1284,16 @@ function Ta({
|
|
|
1283
1284
|
children: /* @__PURE__ */ e(
|
|
1284
1285
|
cn,
|
|
1285
1286
|
{
|
|
1286
|
-
value:
|
|
1287
|
+
value: Le.value,
|
|
1287
1288
|
size: "sm",
|
|
1288
|
-
workflowLabel:
|
|
1289
|
-
option:
|
|
1289
|
+
workflowLabel: Ge,
|
|
1290
|
+
option: Le.option
|
|
1290
1291
|
}
|
|
1291
1292
|
)
|
|
1292
1293
|
}
|
|
1293
1294
|
)
|
|
1294
1295
|
) : null, _ = [];
|
|
1295
|
-
!E &&
|
|
1296
|
+
!E && ae && !Ve && _.push([
|
|
1296
1297
|
"assign-patient",
|
|
1297
1298
|
/* @__PURE__ */ e(
|
|
1298
1299
|
C,
|
|
@@ -1301,12 +1302,12 @@ function Ta({
|
|
|
1301
1302
|
"data-action": "assign-patient",
|
|
1302
1303
|
className: U,
|
|
1303
1304
|
startIcon: /* @__PURE__ */ e(Un, { "aria-hidden": "true" }),
|
|
1304
|
-
onClick: () =>
|
|
1305
|
+
onClick: () => ae(D),
|
|
1305
1306
|
children: h("calendarWorkspace.inc1.bookings.assignPatient")
|
|
1306
1307
|
},
|
|
1307
1308
|
"assign"
|
|
1308
1309
|
)
|
|
1309
|
-
]),
|
|
1310
|
+
]), J && _.push([
|
|
1310
1311
|
"join-telehealth",
|
|
1311
1312
|
/* @__PURE__ */ e(
|
|
1312
1313
|
C,
|
|
@@ -1315,12 +1316,12 @@ function Ta({
|
|
|
1315
1316
|
"data-action": "join-telehealth",
|
|
1316
1317
|
className: U,
|
|
1317
1318
|
startIcon: /* @__PURE__ */ e(zt, { "aria-hidden": "true" }),
|
|
1318
|
-
onClick: () =>
|
|
1319
|
+
onClick: () => J(D),
|
|
1319
1320
|
children: h(S("joinTelehealth"))
|
|
1320
1321
|
},
|
|
1321
1322
|
"join"
|
|
1322
1323
|
)
|
|
1323
|
-
]), !E &&
|
|
1324
|
+
]), !E && z && _.push([
|
|
1324
1325
|
"edit-appointment",
|
|
1325
1326
|
/* @__PURE__ */ e(
|
|
1326
1327
|
C,
|
|
@@ -1328,12 +1329,12 @@ function Ta({
|
|
|
1328
1329
|
"data-action": "edit-appointment",
|
|
1329
1330
|
className: U,
|
|
1330
1331
|
startIcon: /* @__PURE__ */ e(Dt, { "aria-hidden": "true" }),
|
|
1331
|
-
onClick: () =>
|
|
1332
|
+
onClick: () => z(D),
|
|
1332
1333
|
children: h("calendarWorkspace.editor.editTitle")
|
|
1333
1334
|
},
|
|
1334
1335
|
"edit"
|
|
1335
1336
|
)
|
|
1336
|
-
]), !E &&
|
|
1337
|
+
]), !E && K && _.push([
|
|
1337
1338
|
"move-appointment",
|
|
1338
1339
|
/* @__PURE__ */ e(
|
|
1339
1340
|
C,
|
|
@@ -1341,15 +1342,15 @@ function Ta({
|
|
|
1341
1342
|
"data-action": "move-appointment",
|
|
1342
1343
|
className: U,
|
|
1343
1344
|
startIcon: /* @__PURE__ */ e(mn, { "aria-hidden": "true" }),
|
|
1344
|
-
onClick: () =>
|
|
1345
|
+
onClick: () => K(D),
|
|
1345
1346
|
children: h(S("move"))
|
|
1346
1347
|
},
|
|
1347
1348
|
"move"
|
|
1348
1349
|
)
|
|
1349
1350
|
]), !E && W && _.push([
|
|
1350
1351
|
"copy-appointment",
|
|
1351
|
-
|
|
1352
|
-
|
|
1352
|
+
Jt ? /* @__PURE__ */ e(
|
|
1353
|
+
Ft,
|
|
1353
1354
|
{
|
|
1354
1355
|
"data-action": "copy-appointment",
|
|
1355
1356
|
"data-overflow-tip": !1,
|
|
@@ -1382,10 +1383,10 @@ function Ta({
|
|
|
1382
1383
|
},
|
|
1383
1384
|
"copy"
|
|
1384
1385
|
)
|
|
1385
|
-
]),
|
|
1386
|
+
]), ie && ut.length > 0 && _.push([
|
|
1386
1387
|
"open-create-document",
|
|
1387
1388
|
/* @__PURE__ */ e(
|
|
1388
|
-
|
|
1389
|
+
Ft,
|
|
1389
1390
|
{
|
|
1390
1391
|
"data-action": "open-create-document",
|
|
1391
1392
|
"data-overflow-tip": !1,
|
|
@@ -1394,21 +1395,21 @@ function Ta({
|
|
|
1394
1395
|
label: h(S(`documents.${g}`)),
|
|
1395
1396
|
icon: Aa[g],
|
|
1396
1397
|
action: `create-document-${g}`,
|
|
1397
|
-
onSelect: () =>
|
|
1398
|
+
onSelect: () => ie.onCreate(g, D)
|
|
1398
1399
|
})),
|
|
1399
1400
|
children: h(S("documents.label"))
|
|
1400
1401
|
},
|
|
1401
1402
|
"documents"
|
|
1402
1403
|
)
|
|
1403
|
-
]),
|
|
1404
|
+
]), Q ? _.push([
|
|
1404
1405
|
"open-whatsapp",
|
|
1405
1406
|
/* @__PURE__ */ e(
|
|
1406
1407
|
C,
|
|
1407
1408
|
{
|
|
1408
1409
|
"data-action": "open-whatsapp",
|
|
1409
1410
|
className: U,
|
|
1410
|
-
startIcon: /* @__PURE__ */ e(
|
|
1411
|
-
onClick: () =>
|
|
1411
|
+
startIcon: /* @__PURE__ */ e(et, { "aria-hidden": "true" }),
|
|
1412
|
+
onClick: () => Q(D),
|
|
1412
1413
|
children: h(S("remindWhatsApp"))
|
|
1413
1414
|
},
|
|
1414
1415
|
"whatsapp"
|
|
@@ -1421,7 +1422,7 @@ function Ta({
|
|
|
1421
1422
|
asChild: !0,
|
|
1422
1423
|
"data-action": "open-whatsapp",
|
|
1423
1424
|
className: U,
|
|
1424
|
-
startIcon: /* @__PURE__ */ e(
|
|
1425
|
+
startIcon: /* @__PURE__ */ e(et, { "aria-hidden": "true" }),
|
|
1425
1426
|
children: /* @__PURE__ */ e(
|
|
1426
1427
|
"a",
|
|
1427
1428
|
{
|
|
@@ -1434,21 +1435,21 @@ function Ta({
|
|
|
1434
1435
|
},
|
|
1435
1436
|
"whatsapp"
|
|
1436
1437
|
)
|
|
1437
|
-
]) :
|
|
1438
|
+
]) : Y && !x && _.push([
|
|
1438
1439
|
"buy-whatsapp",
|
|
1439
1440
|
/* @__PURE__ */ e(
|
|
1440
1441
|
C,
|
|
1441
1442
|
{
|
|
1442
1443
|
"data-action": "buy-whatsapp",
|
|
1443
1444
|
className: U,
|
|
1444
|
-
startIcon: /* @__PURE__ */ e(
|
|
1445
|
-
onClick: () =>
|
|
1445
|
+
startIcon: /* @__PURE__ */ e(et, { "aria-hidden": "true" }),
|
|
1446
|
+
onClick: () => Y(D),
|
|
1446
1447
|
children: h(S("buyWhatsApp"))
|
|
1447
1448
|
},
|
|
1448
1449
|
"buy-whatsapp"
|
|
1449
1450
|
)
|
|
1450
1451
|
]);
|
|
1451
|
-
const ft = ze(
|
|
1452
|
+
const ft = ze(Z);
|
|
1452
1453
|
ft && _.push([
|
|
1453
1454
|
"create-task",
|
|
1454
1455
|
/* @__PURE__ */ e(
|
|
@@ -1462,7 +1463,7 @@ function Ta({
|
|
|
1462
1463
|
},
|
|
1463
1464
|
"task"
|
|
1464
1465
|
)
|
|
1465
|
-
]), !E &&
|
|
1466
|
+
]), !E && j && _.push([
|
|
1466
1467
|
"delete-appointment",
|
|
1467
1468
|
/* @__PURE__ */ e(
|
|
1468
1469
|
C,
|
|
@@ -1471,28 +1472,28 @@ function Ta({
|
|
|
1471
1472
|
"data-action": "delete-appointment",
|
|
1472
1473
|
className: U,
|
|
1473
1474
|
startIcon: /* @__PURE__ */ e(Kn, { "aria-hidden": "true" }),
|
|
1474
|
-
onClick: () =>
|
|
1475
|
+
onClick: () => j(D),
|
|
1475
1476
|
children: h("calendarWorkspace.editor.delete")
|
|
1476
1477
|
},
|
|
1477
1478
|
"delete"
|
|
1478
1479
|
)
|
|
1479
1480
|
]);
|
|
1480
|
-
const
|
|
1481
|
+
const Je = _.map(([, g]) => g);
|
|
1481
1482
|
r.current = {
|
|
1482
|
-
status:
|
|
1483
|
-
allowed:
|
|
1483
|
+
status: te ?? null,
|
|
1484
|
+
allowed: Oe ? Ue : [],
|
|
1484
1485
|
offered: _.map(([g]) => g),
|
|
1485
1486
|
historyAvailable: w !== void 0,
|
|
1486
|
-
historyOpen:
|
|
1487
|
-
openHistory:
|
|
1488
|
-
closeHistory: () =>
|
|
1487
|
+
historyOpen: oe,
|
|
1488
|
+
openHistory: Ce,
|
|
1489
|
+
closeHistory: () => ee(!1)
|
|
1489
1490
|
};
|
|
1490
1491
|
const gt = h(S("historyBack"));
|
|
1491
1492
|
return /* @__PURE__ */ e(
|
|
1492
1493
|
"div",
|
|
1493
1494
|
{
|
|
1494
|
-
className: `ds:flex ds:min-h-0 ds:flex-1 ds:flex-col ${
|
|
1495
|
-
children: /* @__PURE__ */
|
|
1495
|
+
className: `ds:flex ds:min-h-0 ds:flex-1 ds:flex-col ${je ? sn : ""}`,
|
|
1496
|
+
children: /* @__PURE__ */ b(Ze.Host, { children: [
|
|
1496
1497
|
/* @__PURE__ */ e(
|
|
1497
1498
|
Wt,
|
|
1498
1499
|
{
|
|
@@ -1502,7 +1503,7 @@ function Ta({
|
|
|
1502
1503
|
sticky: !0,
|
|
1503
1504
|
divider: !0,
|
|
1504
1505
|
actions: w ? /* @__PURE__ */ e(
|
|
1505
|
-
|
|
1506
|
+
Ht,
|
|
1506
1507
|
{
|
|
1507
1508
|
size: "sm",
|
|
1508
1509
|
intent: "ghost",
|
|
@@ -1510,7 +1511,7 @@ function Ta({
|
|
|
1510
1511
|
"aria-label": h(S("historyAction")),
|
|
1511
1512
|
tooltip: h(S("historyAction")),
|
|
1512
1513
|
"data-action": "open-history",
|
|
1513
|
-
onClick:
|
|
1514
|
+
onClick: Ce
|
|
1514
1515
|
}
|
|
1515
1516
|
) : void 0
|
|
1516
1517
|
}
|
|
@@ -1521,17 +1522,17 @@ function Ta({
|
|
|
1521
1522
|
tabIndex: 0,
|
|
1522
1523
|
"aria-busy": n || void 0,
|
|
1523
1524
|
className: "ds:[min-block-size:0] ds:flex-1 ds:overflow-y-auto",
|
|
1524
|
-
children: /* @__PURE__ */
|
|
1525
|
-
k ? /* @__PURE__ */ e(
|
|
1525
|
+
children: /* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)] ds:p-[var(--spacing-md)]", children: [
|
|
1526
|
+
k ? /* @__PURE__ */ e(nn, { mask: y }) : t.patient ? /* @__PURE__ */ e(
|
|
1526
1527
|
ma,
|
|
1527
1528
|
{
|
|
1528
|
-
...
|
|
1529
|
+
...he,
|
|
1529
1530
|
now: d,
|
|
1530
1531
|
mapsLink: m,
|
|
1531
|
-
shortcuts:
|
|
1532
|
-
onRequestSignature:
|
|
1533
|
-
onSignOnDevice:
|
|
1534
|
-
onOpenPatient:
|
|
1532
|
+
shortcuts: me,
|
|
1533
|
+
onRequestSignature: xe,
|
|
1534
|
+
onSignOnDevice: Ne,
|
|
1535
|
+
onOpenPatient: pe
|
|
1535
1536
|
}
|
|
1536
1537
|
) : (
|
|
1537
1538
|
/* No patient card to carry the identity: a patient-less, an
|
|
@@ -1540,13 +1541,13 @@ function Ta({
|
|
|
1540
1541
|
Sn,
|
|
1541
1542
|
{
|
|
1542
1543
|
name: t.appointment.title.trim() ? t.appointment.title : h(S("patientNotLoaded")),
|
|
1543
|
-
unresolved:
|
|
1544
|
-
status:
|
|
1544
|
+
unresolved: Ve,
|
|
1545
|
+
status: te,
|
|
1545
1546
|
flags: {
|
|
1546
1547
|
isTelehealth: t.appointment.isTelehealth,
|
|
1547
1548
|
isBookedOnline: t.appointment.bookedOnline,
|
|
1548
1549
|
isRecurring: t.appointment.recurrence !== void 0,
|
|
1549
|
-
hasUnassignedPatient: t.appointment.bookedOnline && !
|
|
1550
|
+
hasUnassignedPatient: t.appointment.bookedOnline && !Ve,
|
|
1550
1551
|
hasHighlightedAnamnesis: !1,
|
|
1551
1552
|
hasBillableAmount: (((yt = t.money) == null ? void 0 : yt.billableAmount) ?? 0) > 0
|
|
1552
1553
|
},
|
|
@@ -1557,9 +1558,9 @@ function Ta({
|
|
|
1557
1558
|
/* @__PURE__ */ e(
|
|
1558
1559
|
ha,
|
|
1559
1560
|
{
|
|
1560
|
-
...
|
|
1561
|
+
...he,
|
|
1561
1562
|
operator: f,
|
|
1562
|
-
chair:
|
|
1563
|
+
chair: v,
|
|
1563
1564
|
privacy: k,
|
|
1564
1565
|
history: (w == null ? void 0 : w.status) === "error" || w == null ? void 0 : w.entries,
|
|
1565
1566
|
description: (
|
|
@@ -1567,56 +1568,56 @@ function Ta({
|
|
|
1567
1568
|
so the sub-view can hand focus back to it. An empty
|
|
1568
1569
|
read-only description prints nothing. Privacy hides the
|
|
1569
1570
|
text and the pencil. */
|
|
1570
|
-
k ? $ ? /* @__PURE__ */ e(wt, { block: "description" }) : void 0 : $ ||
|
|
1571
|
-
|
|
1571
|
+
k ? $ ? /* @__PURE__ */ e(wt, { block: "description" }) : void 0 : $ || q && !E ? /* @__PURE__ */ e(
|
|
1572
|
+
Mt,
|
|
1572
1573
|
{
|
|
1573
1574
|
"data-block": "description",
|
|
1574
1575
|
role: "group",
|
|
1575
1576
|
"aria-label": h("calendarWorkspace.editor.description"),
|
|
1576
1577
|
value: $,
|
|
1577
1578
|
editLabel: h(S("editDescription")),
|
|
1578
|
-
onEdit:
|
|
1579
|
+
onEdit: q && !E ? () => V(!0) : void 0
|
|
1579
1580
|
}
|
|
1580
1581
|
) : void 0
|
|
1581
1582
|
)
|
|
1582
1583
|
}
|
|
1583
1584
|
),
|
|
1584
|
-
|
|
1585
|
-
|
|
1585
|
+
fe && k ? /* @__PURE__ */ e(
|
|
1586
|
+
ue,
|
|
1586
1587
|
{
|
|
1587
1588
|
"data-card": "notes",
|
|
1588
1589
|
title: h("notesPanel.title"),
|
|
1589
1590
|
headingLevel: 3,
|
|
1590
1591
|
children: /* @__PURE__ */ e(wt, {})
|
|
1591
1592
|
}
|
|
1592
|
-
) :
|
|
1593
|
+
) : fe ? /* @__PURE__ */ e(
|
|
1593
1594
|
ga,
|
|
1594
1595
|
{
|
|
1595
|
-
preview:
|
|
1596
|
-
onOpenNotes:
|
|
1596
|
+
preview: fe,
|
|
1597
|
+
onOpenNotes: He ? L : void 0,
|
|
1597
1598
|
locale: c
|
|
1598
1599
|
}
|
|
1599
1600
|
) : null,
|
|
1600
1601
|
/* @__PURE__ */ e(
|
|
1601
1602
|
fa,
|
|
1602
1603
|
{
|
|
1603
|
-
...
|
|
1604
|
+
...he,
|
|
1604
1605
|
privacy: k,
|
|
1605
|
-
carePlanUrl:
|
|
1606
|
+
carePlanUrl: me == null ? void 0 : me.carePlanUrl
|
|
1606
1607
|
}
|
|
1607
1608
|
)
|
|
1608
1609
|
] })
|
|
1609
1610
|
}
|
|
1610
1611
|
),
|
|
1611
|
-
ht ||
|
|
1612
|
+
ht || Je.length > 0 ? (
|
|
1612
1613
|
/* The body scrolls; the status and the actions stay put. The
|
|
1613
1614
|
status keeps its own segment and never folds. The actions fold
|
|
1614
1615
|
to icons, then into More, never onto a second line. Only a
|
|
1615
1616
|
refused status change adds a line, for its message. */
|
|
1616
|
-
/* @__PURE__ */
|
|
1617
|
+
/* @__PURE__ */ b("div", { className: ya(), children: [
|
|
1617
1618
|
ht,
|
|
1618
|
-
|
|
1619
|
-
|
|
1619
|
+
Je.length > 0 ? /* @__PURE__ */ e(
|
|
1620
|
+
an,
|
|
1620
1621
|
{
|
|
1621
1622
|
label: h(S("actionsLabel")),
|
|
1622
1623
|
overflow: "menu",
|
|
@@ -1624,28 +1625,28 @@ function Ta({
|
|
|
1624
1625
|
background: "surface",
|
|
1625
1626
|
size: "sm",
|
|
1626
1627
|
className: `ds:min-w-0 ds:flex-1 ds:text-end ${wa}`,
|
|
1627
|
-
children:
|
|
1628
|
+
children: Je
|
|
1628
1629
|
}
|
|
1629
1630
|
) : null
|
|
1630
1631
|
] })
|
|
1631
1632
|
) : null,
|
|
1632
1633
|
w ? /* @__PURE__ */ e(
|
|
1633
|
-
|
|
1634
|
+
Ze,
|
|
1634
1635
|
{
|
|
1635
|
-
ref:
|
|
1636
|
-
open:
|
|
1636
|
+
ref: ge,
|
|
1637
|
+
open: oe,
|
|
1637
1638
|
icon: /* @__PURE__ */ e(Rt, { "aria-hidden": "true" }),
|
|
1638
1639
|
title: h(S("historyTitle")),
|
|
1639
1640
|
backLabel: gt,
|
|
1640
1641
|
headingLevel: 3,
|
|
1641
|
-
onBack: () =>
|
|
1642
|
+
onBack: () => ee(!1),
|
|
1642
1643
|
"data-details-subview": "history",
|
|
1643
1644
|
children: /* @__PURE__ */ e("div", { className: "ds:-m-[var(--panel-subview-inset)] ds:p-[var(--spacing-md)]", children: /* @__PURE__ */ e(
|
|
1644
1645
|
Na,
|
|
1645
1646
|
{
|
|
1646
1647
|
history: w,
|
|
1647
1648
|
locale: c,
|
|
1648
|
-
noteUnrecordedEdits:
|
|
1649
|
+
noteUnrecordedEdits: H,
|
|
1649
1650
|
privacy: k,
|
|
1650
1651
|
onRetry: w.onRetry ? () => {
|
|
1651
1652
|
var g;
|
|
@@ -1655,26 +1656,26 @@ function Ta({
|
|
|
1655
1656
|
) })
|
|
1656
1657
|
}
|
|
1657
1658
|
) : null,
|
|
1658
|
-
|
|
1659
|
-
|
|
1659
|
+
se ? /* @__PURE__ */ e(
|
|
1660
|
+
Ze,
|
|
1660
1661
|
{
|
|
1661
|
-
open:
|
|
1662
|
+
open: Me,
|
|
1662
1663
|
icon: /* @__PURE__ */ e(Dt, { "aria-hidden": "true" }),
|
|
1663
1664
|
title: h(S("editDescription")),
|
|
1664
1665
|
backLabel: gt,
|
|
1665
1666
|
headingLevel: 3,
|
|
1666
|
-
initialFocusRef:
|
|
1667
|
+
initialFocusRef: be,
|
|
1667
1668
|
onBack: () => {
|
|
1668
|
-
|
|
1669
|
+
ye || V(!1);
|
|
1669
1670
|
},
|
|
1670
1671
|
"data-details-subview": "description",
|
|
1671
|
-
footer: /* @__PURE__ */
|
|
1672
|
+
footer: /* @__PURE__ */ b(ne, { children: [
|
|
1672
1673
|
/* @__PURE__ */ e(
|
|
1673
1674
|
C,
|
|
1674
1675
|
{
|
|
1675
1676
|
intent: "secondary",
|
|
1676
|
-
disabled:
|
|
1677
|
-
onClick: () =>
|
|
1677
|
+
disabled: ye,
|
|
1678
|
+
onClick: () => V(!1),
|
|
1678
1679
|
children: h(S("noteCancel"))
|
|
1679
1680
|
}
|
|
1680
1681
|
),
|
|
@@ -1683,45 +1684,39 @@ function Ta({
|
|
|
1683
1684
|
{
|
|
1684
1685
|
intent: "primary",
|
|
1685
1686
|
"data-action": "save-description",
|
|
1686
|
-
loading:
|
|
1687
|
-
disabled:
|
|
1688
|
-
onClick: () => void
|
|
1687
|
+
loading: ye,
|
|
1688
|
+
disabled: Pe,
|
|
1689
|
+
onClick: () => void Be(),
|
|
1689
1690
|
children: h(S("descriptionSave"))
|
|
1690
1691
|
}
|
|
1691
1692
|
)
|
|
1692
1693
|
] }),
|
|
1693
|
-
children: /* @__PURE__ */
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
"aria-invalid": q || void 0,
|
|
1713
|
-
"aria-describedby": q ? Le : void 0,
|
|
1714
|
-
onChange: (g) => de(g.target.value)
|
|
1715
|
-
}
|
|
1716
|
-
)
|
|
1717
|
-
] })
|
|
1694
|
+
children: /* @__PURE__ */ e("div", { className: "ds:-m-[var(--panel-subview-inset)] ds:flex ds:flex-col ds:gap-[var(--spacing-sm)] ds:p-[var(--spacing-md)]", children: /* @__PURE__ */ e(
|
|
1695
|
+
on,
|
|
1696
|
+
{
|
|
1697
|
+
label: h("calendarWorkspace.editor.description"),
|
|
1698
|
+
error: Pe ? h("calendarWorkspace.editor.descriptionTooLong", {
|
|
1699
|
+
max: X
|
|
1700
|
+
}) : A,
|
|
1701
|
+
children: /* @__PURE__ */ e(
|
|
1702
|
+
rn,
|
|
1703
|
+
{
|
|
1704
|
+
ref: be,
|
|
1705
|
+
value: ve,
|
|
1706
|
+
minRows: 6,
|
|
1707
|
+
autoResize: !0,
|
|
1708
|
+
onChange: (g) => re(g.target.value)
|
|
1709
|
+
}
|
|
1710
|
+
)
|
|
1711
|
+
}
|
|
1712
|
+
) })
|
|
1718
1713
|
}
|
|
1719
1714
|
) : null
|
|
1720
1715
|
] })
|
|
1721
1716
|
}
|
|
1722
1717
|
);
|
|
1723
1718
|
}
|
|
1724
|
-
const Ea =
|
|
1719
|
+
const Ea = Qt(function({
|
|
1725
1720
|
state: n,
|
|
1726
1721
|
onRetry: i,
|
|
1727
1722
|
patientId: d,
|
|
@@ -1733,54 +1728,54 @@ const Ea = Zt(function({
|
|
|
1733
1728
|
title: a,
|
|
1734
1729
|
privacy: o = !1,
|
|
1735
1730
|
privacyTitle: f,
|
|
1736
|
-
mapsLink:
|
|
1731
|
+
mapsLink: v,
|
|
1737
1732
|
notesPreview: k,
|
|
1738
|
-
onOpenNotes:
|
|
1733
|
+
onOpenNotes: y,
|
|
1739
1734
|
history: m,
|
|
1740
1735
|
onOpenHistory: N,
|
|
1741
1736
|
noteUnrecordedEdits: L,
|
|
1742
1737
|
readOnly: P = !1,
|
|
1743
1738
|
onStatusChange: T,
|
|
1744
|
-
allowedStatuses:
|
|
1739
|
+
allowedStatuses: H,
|
|
1745
1740
|
onDescriptionChange: E,
|
|
1746
1741
|
descriptionMaxLength: I,
|
|
1747
|
-
onAssignPatient:
|
|
1748
|
-
onEdit:
|
|
1749
|
-
onMove:
|
|
1750
|
-
onCopy:
|
|
1751
|
-
onDelete:
|
|
1752
|
-
onJoinTelehealth:
|
|
1742
|
+
onAssignPatient: M,
|
|
1743
|
+
onEdit: q,
|
|
1744
|
+
onMove: X,
|
|
1745
|
+
onCopy: ae,
|
|
1746
|
+
onDelete: z,
|
|
1747
|
+
onJoinTelehealth: K,
|
|
1753
1748
|
onWhatsApp: W,
|
|
1754
|
-
whatsappUrl:
|
|
1755
|
-
onBuyWhatsApp:
|
|
1756
|
-
createTaskUrl:
|
|
1749
|
+
whatsappUrl: j,
|
|
1750
|
+
onBuyWhatsApp: J,
|
|
1751
|
+
createTaskUrl: Q,
|
|
1757
1752
|
onRequestSignature: x,
|
|
1758
|
-
onSignOnDevice:
|
|
1759
|
-
onOpenPatient:
|
|
1760
|
-
shortcuts:
|
|
1761
|
-
documents:
|
|
1762
|
-
id:
|
|
1763
|
-
className:
|
|
1764
|
-
...
|
|
1765
|
-
},
|
|
1766
|
-
var
|
|
1767
|
-
const { t: h, i18n: D } =
|
|
1753
|
+
onSignOnDevice: Y,
|
|
1754
|
+
onOpenPatient: Z,
|
|
1755
|
+
shortcuts: xe,
|
|
1756
|
+
documents: Ne,
|
|
1757
|
+
id: pe,
|
|
1758
|
+
className: me,
|
|
1759
|
+
...ie
|
|
1760
|
+
}, Fe) {
|
|
1761
|
+
var ye, Re;
|
|
1762
|
+
const { t: h, i18n: D } = G("ui"), je = tt(), he = pe ?? je, w = tt(), He = r ?? D.language, fe = !o && (a != null && a.trim()) ? a : h(S("region")), se = n.status === "ready" ? n.read : void 0, Te = n.status === "ready" ? n.read.eventId : n.eventId, ee = R(
|
|
1768
1763
|
void 0
|
|
1769
|
-
),
|
|
1770
|
-
|
|
1771
|
-
|
|
1764
|
+
), Ee = ee.current !== void 0 && ee.current !== "ready";
|
|
1765
|
+
Se(() => {
|
|
1766
|
+
ee.current = n.status;
|
|
1772
1767
|
}, [n.status]);
|
|
1773
|
-
const
|
|
1774
|
-
typeof document < "u" && (
|
|
1775
|
-
const
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
}, [
|
|
1768
|
+
const V = !!i && (n.status === "error" || n.status === "refused" && n.retryable === !0), oe = R(null), Me = kt(() => tn(Fe, oe), [Fe]), Ce = R(!1);
|
|
1769
|
+
typeof document < "u" && (Ce.current = ((ye = oe.current) == null ? void 0 : ye.contains(document.activeElement)) ?? !1);
|
|
1770
|
+
const We = se ? `ready:${se.eventId}` : n.status, ge = R(!1);
|
|
1771
|
+
de(() => {
|
|
1772
|
+
ge.current ? (n.status !== "loading" && (ge.current = !1), _e(w)) : Ce.current && _e(w);
|
|
1773
|
+
}, [We, w]);
|
|
1779
1774
|
const O = R(null);
|
|
1780
|
-
|
|
1781
|
-
const
|
|
1782
|
-
$.current = { state: n, eventId:
|
|
1783
|
-
const
|
|
1775
|
+
se || (O.current = null);
|
|
1776
|
+
const Ie = R(null), $ = R({ state: n, eventId: Te, privacy: o, retryOffered: V, onRetry: i });
|
|
1777
|
+
$.current = { state: n, eventId: Te, privacy: o, retryOffered: V, onRetry: i };
|
|
1778
|
+
const De = kt(
|
|
1784
1779
|
() => ({
|
|
1785
1780
|
getEventId: () => $.current.eventId ?? null,
|
|
1786
1781
|
getLoadStatus: () => $.current.state.status,
|
|
@@ -1812,22 +1807,22 @@ const Ea = Zt(function({
|
|
|
1812
1807
|
(A = O.current) == null || A.closeHistory();
|
|
1813
1808
|
},
|
|
1814
1809
|
setAppointmentStatus: (A) => {
|
|
1815
|
-
const B = O.current,
|
|
1816
|
-
if (!B || !
|
|
1817
|
-
return
|
|
1810
|
+
const B = O.current, be = Ie.current;
|
|
1811
|
+
if (!B || !be || B.allowed.length === 0)
|
|
1812
|
+
return Qe(
|
|
1818
1813
|
new Error("AppointmentDetailsPanel: the status is read-only.")
|
|
1819
1814
|
);
|
|
1820
1815
|
if (A === B.status) return Promise.resolve();
|
|
1821
1816
|
if (!B.allowed.includes(A))
|
|
1822
|
-
return
|
|
1817
|
+
return Qe(
|
|
1823
1818
|
new Error(`AppointmentDetailsPanel: "${A}" is not allowed.`)
|
|
1824
1819
|
);
|
|
1825
|
-
const
|
|
1820
|
+
const Pe = () => Qe(
|
|
1826
1821
|
new Error("AppointmentDetailsPanel: a status save is in flight.")
|
|
1827
1822
|
);
|
|
1828
|
-
if (
|
|
1829
|
-
const
|
|
1830
|
-
return
|
|
1823
|
+
if (be.getIsSaving()) return Pe();
|
|
1824
|
+
const Be = be.setValue(A);
|
|
1825
|
+
return Be === void 0 ? Pe() : Be;
|
|
1831
1826
|
},
|
|
1832
1827
|
retry: () => {
|
|
1833
1828
|
const { retryOffered: A, onRetry: B } = $.current;
|
|
@@ -1838,78 +1833,78 @@ const Ea = Zt(function({
|
|
|
1838
1833
|
}),
|
|
1839
1834
|
[]
|
|
1840
1835
|
);
|
|
1841
|
-
|
|
1842
|
-
const
|
|
1836
|
+
en(aa, De, he);
|
|
1837
|
+
const ve = /* @__PURE__ */ e(
|
|
1843
1838
|
Wt,
|
|
1844
1839
|
{
|
|
1845
|
-
title:
|
|
1840
|
+
title: fe,
|
|
1846
1841
|
headingId: w,
|
|
1847
1842
|
icon: /* @__PURE__ */ e(Kt, { "aria-hidden": "true" }),
|
|
1848
1843
|
sticky: !0,
|
|
1849
1844
|
divider: !0
|
|
1850
1845
|
}
|
|
1851
1846
|
);
|
|
1852
|
-
let
|
|
1853
|
-
return n.status === "ready" ?
|
|
1847
|
+
let re;
|
|
1848
|
+
return n.status === "ready" ? re = /* @__PURE__ */ e(
|
|
1854
1849
|
Ta,
|
|
1855
1850
|
{
|
|
1856
1851
|
read: n.read,
|
|
1857
1852
|
refreshing: n.refreshing === !0,
|
|
1858
1853
|
currency: u,
|
|
1859
1854
|
now: p ?? /* @__PURE__ */ new Date(),
|
|
1860
|
-
locale:
|
|
1861
|
-
shownTitle:
|
|
1855
|
+
locale: He,
|
|
1856
|
+
shownTitle: fe,
|
|
1862
1857
|
headingId: w,
|
|
1863
|
-
enter:
|
|
1858
|
+
enter: Ee,
|
|
1864
1859
|
live: O,
|
|
1865
|
-
statusControl:
|
|
1860
|
+
statusControl: Ie,
|
|
1866
1861
|
patientId: d,
|
|
1867
1862
|
operator: c,
|
|
1868
1863
|
chair: l,
|
|
1869
1864
|
privacy: o,
|
|
1870
1865
|
privacyTitle: f,
|
|
1871
|
-
mapsLink:
|
|
1866
|
+
mapsLink: v,
|
|
1872
1867
|
notesPreview: k,
|
|
1873
|
-
onOpenNotes:
|
|
1868
|
+
onOpenNotes: y,
|
|
1874
1869
|
history: m,
|
|
1875
1870
|
onOpenHistory: N,
|
|
1876
1871
|
noteUnrecordedEdits: L,
|
|
1877
1872
|
readOnly: P,
|
|
1878
1873
|
onStatusChange: T,
|
|
1879
|
-
allowedStatuses:
|
|
1874
|
+
allowedStatuses: H,
|
|
1880
1875
|
onDescriptionChange: E,
|
|
1881
1876
|
descriptionMaxLength: I,
|
|
1882
|
-
onAssignPatient:
|
|
1883
|
-
onEdit:
|
|
1884
|
-
onMove:
|
|
1885
|
-
onCopy:
|
|
1886
|
-
onDelete:
|
|
1887
|
-
onJoinTelehealth:
|
|
1877
|
+
onAssignPatient: M,
|
|
1878
|
+
onEdit: q,
|
|
1879
|
+
onMove: X,
|
|
1880
|
+
onCopy: ae,
|
|
1881
|
+
onDelete: z,
|
|
1882
|
+
onJoinTelehealth: K,
|
|
1888
1883
|
onWhatsApp: W,
|
|
1889
|
-
whatsappUrl:
|
|
1890
|
-
onBuyWhatsApp:
|
|
1891
|
-
createTaskUrl:
|
|
1884
|
+
whatsappUrl: j,
|
|
1885
|
+
onBuyWhatsApp: J,
|
|
1886
|
+
createTaskUrl: Q,
|
|
1892
1887
|
onRequestSignature: x,
|
|
1893
|
-
onSignOnDevice:
|
|
1894
|
-
onOpenPatient:
|
|
1895
|
-
shortcuts:
|
|
1896
|
-
documents:
|
|
1888
|
+
onSignOnDevice: Y,
|
|
1889
|
+
onOpenPatient: Z,
|
|
1890
|
+
shortcuts: xe,
|
|
1891
|
+
documents: Ne
|
|
1897
1892
|
},
|
|
1898
1893
|
n.read.eventId
|
|
1899
|
-
) : n.status === "loading" ?
|
|
1900
|
-
|
|
1894
|
+
) : n.status === "loading" ? re = /* @__PURE__ */ b(ne, { children: [
|
|
1895
|
+
ve,
|
|
1901
1896
|
/* @__PURE__ */ e(xa, {})
|
|
1902
|
-
] }) :
|
|
1903
|
-
|
|
1904
|
-
/* @__PURE__ */
|
|
1905
|
-
/* @__PURE__ */ e(
|
|
1906
|
-
|
|
1897
|
+
] }) : re = /* @__PURE__ */ b(ne, { children: [
|
|
1898
|
+
ve,
|
|
1899
|
+
/* @__PURE__ */ b("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)] ds:p-[var(--spacing-md)]", children: [
|
|
1900
|
+
/* @__PURE__ */ e(ce, { variant: n.status === "error" ? "error" : "warning", children: /* @__PURE__ */ e(ce.Description, { children: n.status === "error" ? ((Re = n.message) == null ? void 0 : Re.trim()) || h("emptyState.error.description") : n.reason }) }),
|
|
1901
|
+
V ? /* @__PURE__ */ e(
|
|
1907
1902
|
C,
|
|
1908
1903
|
{
|
|
1909
1904
|
intent: "outline",
|
|
1910
1905
|
"data-action": "retry-load",
|
|
1911
1906
|
onClick: () => {
|
|
1912
|
-
|
|
1907
|
+
ge.current = !0, i == null || i();
|
|
1913
1908
|
},
|
|
1914
1909
|
children: h("emptyState.error.cta")
|
|
1915
1910
|
}
|
|
@@ -1918,33 +1913,33 @@ const Ea = Zt(function({
|
|
|
1918
1913
|
] }), /* @__PURE__ */ e(
|
|
1919
1914
|
"div",
|
|
1920
1915
|
{
|
|
1921
|
-
ref:
|
|
1922
|
-
id:
|
|
1916
|
+
ref: Me,
|
|
1917
|
+
id: pe,
|
|
1923
1918
|
"data-component": "appointment-details-panel",
|
|
1924
|
-
"data-component-id":
|
|
1925
|
-
"data-event-id":
|
|
1919
|
+
"data-component-id": he,
|
|
1920
|
+
"data-event-id": Te,
|
|
1926
1921
|
"data-status": n.status,
|
|
1927
1922
|
"aria-busy": n.status === "loading" || void 0,
|
|
1928
|
-
className: va({ className:
|
|
1929
|
-
...
|
|
1930
|
-
children:
|
|
1923
|
+
className: va({ className: me }),
|
|
1924
|
+
...ie,
|
|
1925
|
+
children: re
|
|
1931
1926
|
}
|
|
1932
1927
|
);
|
|
1933
1928
|
});
|
|
1934
1929
|
Ea.displayName = "AppointmentDetailsPanel";
|
|
1935
|
-
function
|
|
1930
|
+
function ji({
|
|
1936
1931
|
eventId: t,
|
|
1937
1932
|
load: n,
|
|
1938
1933
|
reloadKey: i
|
|
1939
1934
|
}) {
|
|
1940
|
-
const { t: d } =
|
|
1935
|
+
const { t: d } = G("ui"), c = R("");
|
|
1941
1936
|
c.current = d("emptyState.error.description");
|
|
1942
1937
|
const l = R(n);
|
|
1943
|
-
|
|
1938
|
+
de(() => {
|
|
1944
1939
|
l.current = n;
|
|
1945
1940
|
});
|
|
1946
|
-
const [u, p] =
|
|
1947
|
-
f.eventId !== t &&
|
|
1941
|
+
const [u, p] = F(0), [r, a] = F(), o = JSON.stringify([i ?? null, u]), [f, v] = F({ eventId: t, count: 0 }), k = f.eventId === t ? f.count : f.count + 1;
|
|
1942
|
+
f.eventId !== t && v({ eventId: t, count: k }), Se(() => {
|
|
1948
1943
|
if (t === null) {
|
|
1949
1944
|
a(void 0);
|
|
1950
1945
|
return;
|
|
@@ -1953,7 +1948,7 @@ function Ki({
|
|
|
1953
1948
|
L.signal.aborted || a({ eventId: t, selection: k, request: o, value: T });
|
|
1954
1949
|
};
|
|
1955
1950
|
return Promise.resolve().then(() => l.current(t, { signal: L.signal })).then((T) => {
|
|
1956
|
-
var
|
|
1951
|
+
var H, E;
|
|
1957
1952
|
if (T.status !== "ready") {
|
|
1958
1953
|
P({
|
|
1959
1954
|
status: "refused",
|
|
@@ -1963,7 +1958,7 @@ function Ki({
|
|
|
1963
1958
|
});
|
|
1964
1959
|
return;
|
|
1965
1960
|
}
|
|
1966
|
-
if (((
|
|
1961
|
+
if (((H = T.details) == null ? void 0 : H.eventId) !== t || !An((E = T.details.appointment) == null ? void 0 : E.startIso))
|
|
1967
1962
|
throw new Error(c.current);
|
|
1968
1963
|
P({ status: "ready", read: T.details });
|
|
1969
1964
|
}).catch((T) => {
|
|
@@ -1974,16 +1969,16 @@ function Ki({
|
|
|
1974
1969
|
});
|
|
1975
1970
|
}), () => L.abort();
|
|
1976
1971
|
}, [t, k, o]);
|
|
1977
|
-
const
|
|
1978
|
-
if (t === null) return { state: null, retry:
|
|
1972
|
+
const y = Zt(() => p((L) => L + 1), []);
|
|
1973
|
+
if (t === null) return { state: null, retry: y };
|
|
1979
1974
|
const m = (r == null ? void 0 : r.eventId) === t && r.selection === k ? r : void 0;
|
|
1980
1975
|
let N = { status: "loading", eventId: t };
|
|
1981
|
-
return (m == null ? void 0 : m.request) === o ? N = m.value : (m == null ? void 0 : m.value.status) === "ready" && (N = { status: "ready", read: m.value.read, refreshing: !0 }), { state: N, retry:
|
|
1976
|
+
return (m == null ? void 0 : m.request) === o ? N = m.value : (m == null ? void 0 : m.value.status) === "ready" && (N = { status: "ready", read: m.value.read, refreshing: !0 }), { state: N, retry: y };
|
|
1982
1977
|
}
|
|
1983
1978
|
export {
|
|
1984
1979
|
Ea as A,
|
|
1985
|
-
|
|
1980
|
+
le as D,
|
|
1986
1981
|
aa as a,
|
|
1987
|
-
|
|
1982
|
+
ji as u
|
|
1988
1983
|
};
|
|
1989
|
-
//# sourceMappingURL=use-appointment-details-read-
|
|
1984
|
+
//# sourceMappingURL=use-appointment-details-read-kYp-gfhb.js.map
|