@alfadocs/ui-kit 1.139.0 → 1.140.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/{anamnesis-summary-rows-BgfBnjp0.js → anamnesis-summary-rows-YJGs2uWD.js} +2 -2
- package/dist/_chunks/{balance-badge-cell-CRrIv2hy.js → balance-badge-cell-CRStPNDd.js} +2 -2
- package/dist/_chunks/{bill-line-table-DCqxhode.js → bill-line-table-DTqXdBED.js} +2 -2
- package/dist/_chunks/{bmi-calculator-rri5vvMt.js → bmi-calculator-rq3ZsKp0.js} +2 -2
- package/dist/_chunks/{calendar-appointment-editor-dialog-GdnaPIOV.js → calendar-appointment-editor-dialog-BBrJlmyd.js} +4 -4
- package/dist/_chunks/{calendar-waiting-list-panel-CkZBAv_E.js → calendar-waiting-list-panel-Cdg9YssA.js} +2 -2
- package/dist/_chunks/{calendar.sheets-B0jP2Yt0.js → calendar.sheets-DbMOO7YV.js} +2 -2
- package/dist/_chunks/{cycle-calculator-WFhMfJHt.js → cycle-calculator-Cb66X2Pf.js} +2 -2
- package/dist/_chunks/{data-grid-bQ6iFm10.js → data-grid-CRUSZcVT.js} +2 -2
- package/dist/_chunks/{default-tabs-Dm_vk6hd.js → default-tabs-CRbVCDSU.js} +3 -3
- package/dist/_chunks/{due-date-calculator-CALlODZe.js → due-date-calculator-Dlqegxx9.js} +2 -2
- package/dist/_chunks/{fetal-weight-D0KofJJw.js → fetal-weight-DWj-_ME8.js} +2 -2
- package/dist/_chunks/{hcg-doubling-Dhdt3Jyd.js → hcg-doubling-Dqbj6PQj.js} +2 -2
- package/dist/_chunks/{invoice-upload-list-Dz3CXHPP.js → invoice-upload-list-BR6vycF7.js} +3 -3
- package/dist/_chunks/{kit-extensions-BB_ksnVl.js → kit-extensions-QddOSnIq.js} +6 -6
- package/dist/_chunks/{link-cell-renderer-CSA0KKPe.js → link-cell-renderer-hAJplRFF.js} +2 -2
- package/dist/_chunks/medication-line-BohqbCYD.js +238 -0
- package/dist/_chunks/{number-input-DUSvP7Dq.js → number-input-Bi5Yk6PX.js} +135 -133
- package/dist/_chunks/{optical-prescription-C4jpDFOE.js → optical-prescription-GzeK_2cf.js} +2 -2
- package/dist/_chunks/{patient-details-DQTxSWY4.js → patient-details-D0PjzALT.js} +2 -2
- package/dist/_chunks/{patient-field-row-CXuWQeQJ.js → patient-field-row-DlpIModg.js} +2 -2
- package/dist/_chunks/{patient-summary-card-j5u7c5Us.js → patient-summary-card-BP_K7g_q.js} +2 -2
- package/dist/_chunks/{pregnancy-dating-C-3NLI6K.js → pregnancy-dating-a6WIg4oy.js} +2 -2
- package/dist/_chunks/{pregnancy-weight-gain-DkGcEc_l.js → pregnancy-weight-gain-DmrVHk9y.js} +2 -2
- package/dist/_chunks/prescription-history-Bp_JHhdF.js +1719 -0
- package/dist/_chunks/{print-sheet-CSeqkM3_.js → print-sheet-gaxObGcm.js} +110 -100
- package/dist/_chunks/{toolbar-Dz_hAUIZ.js → toolbar-B7UHCMSr.js} +2 -2
- package/dist/_chunks/{unit-converter-CBy7S4Tl.js → unit-converter-OBhSDXee.js} +2 -2
- package/dist/_chunks/{use-appointment-details-read-CBSpX4DI.js → use-appointment-details-read-DeQnmmZw.js} +2 -2
- package/dist/agent-catalog.json +8 -14
- package/dist/agent-i18n/en.json +3 -3
- package/dist/appointment-editor-panel/index.js +1 -1
- package/dist/browser-support.js +1 -1
- package/dist/components/appointment-details-panel/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/bmi-calculator/index.js +1 -1
- package/dist/components/cycle-calculator/index.js +1 -1
- package/dist/components/data-grid/index.js +2 -2
- package/dist/components/data-table/index.js +1 -1
- package/dist/components/due-date-calculator/index.js +1 -1
- package/dist/components/fetal-weight/index.js +1 -1
- package/dist/components/hcg-doubling/index.js +1 -1
- package/dist/components/invoice-upload-list/index.js +1 -1
- package/dist/components/medication-line/index.js +1 -1
- package/dist/components/medication-line/medication-line.d.ts +6 -0
- package/dist/components/number-input/index.js +1 -1
- package/dist/components/optical-prescription/index.js +1 -1
- package/dist/components/patient-details/index.js +1 -1
- package/dist/components/patient-summary-card/index.js +1 -1
- package/dist/components/patient-table/index.js +1 -1
- package/dist/components/pregnancy-dating/index.js +1 -1
- package/dist/components/pregnancy-weight-gain/index.js +1 -1
- package/dist/components/print-sheet/index.js +1 -1
- package/dist/components/print-sheet/print-sheet.d.ts +7 -0
- package/dist/components/rich-text-editor/index.js +1 -1
- package/dist/components/unit-converter/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 +6 -1
- package/dist/i18n/locales/ar.d.ts +27 -10
- package/dist/i18n/locales/ar.js +32 -15
- package/dist/i18n/locales/de.d.ts +27 -10
- package/dist/i18n/locales/de.js +32 -15
- package/dist/i18n/locales/el.d.ts +27 -10
- package/dist/i18n/locales/el.js +32 -15
- package/dist/i18n/locales/en.d.ts +27 -10
- package/dist/i18n/locales/en.js +32 -15
- package/dist/i18n/locales/es.d.ts +27 -10
- package/dist/i18n/locales/es.js +32 -15
- package/dist/i18n/locales/fr.d.ts +27 -10
- package/dist/i18n/locales/fr.js +32 -15
- package/dist/i18n/locales/hi.d.ts +27 -10
- package/dist/i18n/locales/hi.js +32 -15
- package/dist/i18n/locales/it.d.ts +27 -10
- package/dist/i18n/locales/it.js +32 -15
- package/dist/i18n/locales/ja.d.ts +27 -10
- package/dist/i18n/locales/ja.js +32 -15
- package/dist/i18n/locales/nl.d.ts +27 -10
- package/dist/i18n/locales/nl.js +32 -15
- package/dist/i18n/locales/pl.d.ts +27 -10
- package/dist/i18n/locales/pl.js +32 -15
- package/dist/i18n/locales/pt.d.ts +27 -10
- package/dist/i18n/locales/pt.js +32 -15
- package/dist/i18n/locales/ro.d.ts +27 -10
- package/dist/i18n/locales/ro.js +32 -15
- package/dist/i18n/locales/ru.d.ts +27 -10
- package/dist/i18n/locales/ru.js +32 -15
- package/dist/i18n/locales/sq.d.ts +27 -10
- package/dist/i18n/locales/sq.js +32 -15
- package/dist/i18n/locales/sv.d.ts +27 -10
- package/dist/i18n/locales/sv.js +32 -15
- package/dist/i18n/locales/tr.d.ts +27 -10
- package/dist/i18n/locales/tr.js +32 -15
- package/dist/i18n/locales/zh.d.ts +27 -10
- package/dist/i18n/locales/zh.js +32 -15
- package/dist/index.js +27 -27
- package/dist/locales/ar.json +32 -15
- package/dist/locales/de.json +32 -15
- package/dist/locales/el.json +32 -15
- package/dist/locales/en.json +32 -15
- package/dist/locales/es.json +32 -15
- package/dist/locales/fr.json +32 -15
- package/dist/locales/hi.json +32 -15
- package/dist/locales/it.json +32 -15
- package/dist/locales/ja.json +32 -15
- package/dist/locales/nl.json +32 -15
- package/dist/locales/pl.json +32 -15
- package/dist/locales/pt.json +32 -15
- package/dist/locales/ro.json +32 -15
- package/dist/locales/ru.json +32 -15
- package/dist/locales/sq.json +32 -15
- package/dist/locales/sv.json +32 -15
- package/dist/locales/tr.json +32 -15
- package/dist/locales/zh.json +32 -15
- package/dist/online-bookings-panel/index.js +1 -1
- package/dist/patterns/anamnesis/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-composer-item.d.ts +8 -1
- package/dist/patterns/prescription/prescription-composer.d.ts +14 -9
- package/dist/patterns/prescription/prescription-sheet.d.ts +23 -4
- package/dist/patterns/prescription/prescription-types.d.ts +35 -10
- package/dist/patterns/prescription/prescription-validation.d.ts +17 -11
- package/dist/tokens.css +1 -1
- package/dist/waiting-list-panel/index.js +2 -2
- package/package.json +1 -1
- package/dist/_chunks/medication-line-CHdlh-F7.js +0 -222
- package/dist/_chunks/prescription-history-748qDVwZ.js +0 -1544
|
@@ -4,8 +4,8 @@ import { useTranslation as K } from "react-i18next";
|
|
|
4
4
|
import { d as s, b as L } from "../_chunks/toast-DQ1Zu1kk.js";
|
|
5
5
|
import { a as M } from "../_chunks/tooltip-uEBdD1-5.js";
|
|
6
6
|
import { C as Q } from "../_chunks/calendar-editor-guard-9fShhNIA.js";
|
|
7
|
-
import { S as V } from "../_chunks/calendar.sheets-
|
|
8
|
-
import { W as X } from "../_chunks/calendar-waiting-list-panel-
|
|
7
|
+
import { S as V } from "../_chunks/calendar.sheets-DbMOO7YV.js";
|
|
8
|
+
import { W as X } from "../_chunks/calendar-waiting-list-panel-Cdg9YssA.js";
|
|
9
9
|
import { P as Y } from "../_chunks/privacy-mask-C2ZLKrMh.js";
|
|
10
10
|
import { H as Z } from "../_chunks/hourglass-BEAzW1wE.js";
|
|
11
11
|
const q = { open: () => {
|
package/package.json
CHANGED
|
@@ -1,222 +0,0 @@
|
|
|
1
|
-
import { jsxs as s, jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as I, useContext as L, useRef as v, useCallback as B, useMemo as q, useImperativeHandle as G, createContext as k } from "react";
|
|
3
|
-
import { c as a } from "./index-D2ZczOXr.js";
|
|
4
|
-
import { useTranslation as J } from "react-i18next";
|
|
5
|
-
import { I as Q } from "./icon-button-S8_weU3g.js";
|
|
6
|
-
import { u as U } from "./registry-DvAUVLHh.js";
|
|
7
|
-
import { f as W, m as X, M as Y } from "./medication-I6QvOq6k.js";
|
|
8
|
-
import { T as Z } from "./trash-2-uumy3fy1.js";
|
|
9
|
-
const $ = {
|
|
10
|
-
id: "medication-line",
|
|
11
|
-
// Closed set (§4): `dismiss` is "hide or acknowledge with no commitment";
|
|
12
|
-
// removing a line changes the list, so it is `edit_inline`, as field-array
|
|
13
|
-
// declares for its `remove`.
|
|
14
|
-
capabilities: ["edit_inline"],
|
|
15
|
-
state: {
|
|
16
|
-
value: {
|
|
17
|
-
type: "string",
|
|
18
|
-
descriptionKey: "ui.agent.medicationLine.state.value",
|
|
19
|
-
description: "The catalogue id of the medication on this line. An id only, never a name.",
|
|
20
|
-
read: (e) => e.getMedicationId()
|
|
21
|
-
}
|
|
22
|
-
},
|
|
23
|
-
actions: {
|
|
24
|
-
remove: {
|
|
25
|
-
// §3: `destructive`. Taking a medication off a prescription or therapy
|
|
26
|
-
// list has no undo in this UI (the host owns the list), so it is "hard
|
|
27
|
-
// to reverse via the same UI", the same class field-array and
|
|
28
|
-
// suggestion-chip give removal. It is not `phi`: the line holds a
|
|
29
|
-
// catalogue id, not patient identity.
|
|
30
|
-
safety: "destructive",
|
|
31
|
-
idempotent: !0,
|
|
32
|
-
descriptionKey: "ui.agent.medicationLine.actions.remove",
|
|
33
|
-
description: "Remove this medication from the list. Does nothing on a read-only line.",
|
|
34
|
-
invoke: (e) => {
|
|
35
|
-
e.remove();
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
domHooks: {
|
|
40
|
-
root: {
|
|
41
|
-
attr: "data-component",
|
|
42
|
-
value: "medication-line",
|
|
43
|
-
description: "Marks one medication line. The remove button is present only on the removable variant."
|
|
44
|
-
},
|
|
45
|
-
instanceId: {
|
|
46
|
-
attr: "data-component-id",
|
|
47
|
-
sourceProp: "id",
|
|
48
|
-
description: "Sourced from the id prop, when provided."
|
|
49
|
-
},
|
|
50
|
-
item: {
|
|
51
|
-
attr: "data-medication-id",
|
|
52
|
-
description: "The root also emits the catalogue id of the medication. An id only, never a name."
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
}, ee = a(
|
|
56
|
-
[
|
|
57
|
-
"ds:flex ds:items-start ds:justify-between",
|
|
58
|
-
"ds:text-foreground ds:break-inside-avoid",
|
|
59
|
-
"ds:m-0 ds:list-none"
|
|
60
|
-
].join(" "),
|
|
61
|
-
{
|
|
62
|
-
variants: {
|
|
63
|
-
density: {
|
|
64
|
-
default: "ds:gap-[var(--spacing-md)] ds:py-[var(--spacing-sm)]",
|
|
65
|
-
compact: "ds:gap-[var(--spacing-sm)] ds:py-[var(--spacing-xs)]"
|
|
66
|
-
}
|
|
67
|
-
},
|
|
68
|
-
defaultVariants: { density: "default" }
|
|
69
|
-
}
|
|
70
|
-
), te = a("ds:flex ds:flex-col ds:flex-1 ds:min-w-0", {
|
|
71
|
-
variants: {
|
|
72
|
-
density: {
|
|
73
|
-
default: "ds:gap-[var(--spacing-xs)]",
|
|
74
|
-
compact: "ds:gap-0"
|
|
75
|
-
}
|
|
76
|
-
},
|
|
77
|
-
defaultVariants: { density: "default" }
|
|
78
|
-
}), ie = a(
|
|
79
|
-
"ds:m-0 ds:[overflow-wrap:anywhere] ds:text-foreground",
|
|
80
|
-
{
|
|
81
|
-
variants: {
|
|
82
|
-
density: {
|
|
83
|
-
default: "type-title-item",
|
|
84
|
-
compact: "type-label"
|
|
85
|
-
}
|
|
86
|
-
},
|
|
87
|
-
defaultVariants: { density: "default" }
|
|
88
|
-
}
|
|
89
|
-
), ae = a(
|
|
90
|
-
"ds:m-0 ds:[overflow-wrap:anywhere] ds:text-muted-foreground",
|
|
91
|
-
{
|
|
92
|
-
variants: {
|
|
93
|
-
density: {
|
|
94
|
-
default: "type-body-sm",
|
|
95
|
-
compact: "type-meta"
|
|
96
|
-
}
|
|
97
|
-
},
|
|
98
|
-
defaultVariants: { density: "default" }
|
|
99
|
-
}
|
|
100
|
-
), N = a(
|
|
101
|
-
"ds:flex ds:flex-wrap ds:items-baseline ds:gap-x-[var(--spacing-xs)]"
|
|
102
|
-
), V = a("ds:shrink-0 ds:text-muted-foreground", {
|
|
103
|
-
variants: {
|
|
104
|
-
density: { default: "type-label", compact: "type-meta" }
|
|
105
|
-
},
|
|
106
|
-
defaultVariants: { density: "default" }
|
|
107
|
-
}), M = a(
|
|
108
|
-
"ds:m-0 ds:min-w-0 ds:[overflow-wrap:anywhere] ds:text-foreground",
|
|
109
|
-
{
|
|
110
|
-
variants: {
|
|
111
|
-
density: { default: "type-body", compact: "type-body-sm" }
|
|
112
|
-
},
|
|
113
|
-
defaultVariants: { density: "default" }
|
|
114
|
-
}
|
|
115
|
-
), ne = a(
|
|
116
|
-
[
|
|
117
|
-
"ds:m-0 ds:p-0 ds:list-none",
|
|
118
|
-
"ds:divide-y ds:divide-[color:var(--border)]"
|
|
119
|
-
].join(" ")
|
|
120
|
-
), A = k("default"), C = k(!1);
|
|
121
|
-
function T(e) {
|
|
122
|
-
return e !== void 0 && e.trim() !== "";
|
|
123
|
-
}
|
|
124
|
-
const se = I(
|
|
125
|
-
({
|
|
126
|
-
medication: e,
|
|
127
|
-
dosage: r,
|
|
128
|
-
notes: d,
|
|
129
|
-
codeLabel: c,
|
|
130
|
-
showDetail: l = !0,
|
|
131
|
-
density: R,
|
|
132
|
-
as: j,
|
|
133
|
-
onRemove: m,
|
|
134
|
-
removeLabel: P,
|
|
135
|
-
disabled: u = !1,
|
|
136
|
-
id: y,
|
|
137
|
-
className: D,
|
|
138
|
-
...S
|
|
139
|
-
}, _) => {
|
|
140
|
-
const { t: n } = J("ui"), z = L(A), i = R ?? z, E = L(C), F = j ?? (E ? "li" : "div"), h = W(e), H = T(e.code) ? n("medicationSearch.code", {
|
|
141
|
-
label: c ?? n("medicationSearch.codeFallbackLabel"),
|
|
142
|
-
code: e.code.trim()
|
|
143
|
-
}) : void 0, g = X(
|
|
144
|
-
{ ...e, strength: void 0, form: void 0 },
|
|
145
|
-
H
|
|
146
|
-
).join(Y), K = m !== void 0, o = v(m);
|
|
147
|
-
o.current = m;
|
|
148
|
-
const x = v(u);
|
|
149
|
-
x.current = u;
|
|
150
|
-
const b = v(e.id);
|
|
151
|
-
b.current = e.id;
|
|
152
|
-
const p = B(() => {
|
|
153
|
-
var w;
|
|
154
|
-
x.current || (w = o.current) == null || w.call(o);
|
|
155
|
-
}, []), f = q(
|
|
156
|
-
() => ({
|
|
157
|
-
getMedicationId: () => b.current,
|
|
158
|
-
remove: p
|
|
159
|
-
}),
|
|
160
|
-
[p]
|
|
161
|
-
);
|
|
162
|
-
G(_, () => f, [f]), U($, f, y);
|
|
163
|
-
const O = P ?? n("medicationLine.remove", { name: h });
|
|
164
|
-
return /* @__PURE__ */ s(
|
|
165
|
-
F,
|
|
166
|
-
{
|
|
167
|
-
...S,
|
|
168
|
-
className: ee({ density: i, className: D }),
|
|
169
|
-
"data-component": "medication-line",
|
|
170
|
-
"data-component-id": y,
|
|
171
|
-
"data-medication-id": e.id,
|
|
172
|
-
children: [
|
|
173
|
-
/* @__PURE__ */ s("div", { className: te({ density: i }), children: [
|
|
174
|
-
/* @__PURE__ */ t("p", { dir: "auto", className: ie({ density: i }), children: h }),
|
|
175
|
-
l && g !== "" ? /* @__PURE__ */ t("p", { dir: "auto", className: ae({ density: i }), children: g }) : null,
|
|
176
|
-
/* @__PURE__ */ s("dl", { className: "ds:m-0 ds:flex ds:flex-col", children: [
|
|
177
|
-
/* @__PURE__ */ s("div", { className: N(), children: [
|
|
178
|
-
/* @__PURE__ */ t("dt", { className: V({ density: i }), children: n("medicationLine.dosage") }),
|
|
179
|
-
/* @__PURE__ */ t("dd", { dir: "auto", className: M({ density: i }), children: r })
|
|
180
|
-
] }),
|
|
181
|
-
T(d) ? /* @__PURE__ */ s("div", { className: N(), children: [
|
|
182
|
-
/* @__PURE__ */ t("dt", { className: V({ density: i }), children: n("medicationLine.notes") }),
|
|
183
|
-
/* @__PURE__ */ t("dd", { dir: "auto", className: M({ density: i }), children: d })
|
|
184
|
-
] }) : null
|
|
185
|
-
] })
|
|
186
|
-
] }),
|
|
187
|
-
K ? /* @__PURE__ */ t(
|
|
188
|
-
Q,
|
|
189
|
-
{
|
|
190
|
-
type: "button",
|
|
191
|
-
intent: "ghost",
|
|
192
|
-
icon: /* @__PURE__ */ t(Z, { "aria-hidden": "true" }),
|
|
193
|
-
"aria-label": O,
|
|
194
|
-
disabled: u,
|
|
195
|
-
onClick: p,
|
|
196
|
-
className: "ds:shrink-0 ds:min-h-[var(--min-target-size)] ds:min-w-[var(--min-target-size)] ds:print:hidden"
|
|
197
|
-
}
|
|
198
|
-
) : null
|
|
199
|
-
]
|
|
200
|
-
}
|
|
201
|
-
);
|
|
202
|
-
}
|
|
203
|
-
);
|
|
204
|
-
se.displayName = "MedicationLine";
|
|
205
|
-
const de = I(({ density: e = "default", className: r, children: d, ...c }, l) => /* @__PURE__ */ t(A.Provider, { value: e, children: /* @__PURE__ */ t(C.Provider, { value: !0, children: /* @__PURE__ */ t(
|
|
206
|
-
"ul",
|
|
207
|
-
{
|
|
208
|
-
ref: l,
|
|
209
|
-
role: "list",
|
|
210
|
-
...c,
|
|
211
|
-
className: ne({ className: r }),
|
|
212
|
-
"data-component": "medication-line-list",
|
|
213
|
-
children: d
|
|
214
|
-
}
|
|
215
|
-
) }) }));
|
|
216
|
-
de.displayName = "MedicationLineList";
|
|
217
|
-
export {
|
|
218
|
-
se as M,
|
|
219
|
-
de as a,
|
|
220
|
-
$ as m
|
|
221
|
-
};
|
|
222
|
-
//# sourceMappingURL=medication-line-CHdlh-F7.js.map
|