@alfadocs/ui-kit 0.48.0 → 0.49.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/{address-autocomplete-CSjMrBvu.js → address-autocomplete-CT-9AOli.js} +2 -2
- package/dist/_chunks/{ai-consent-banner-DO5ingMq.js → ai-consent-banner-F2md5JD3.js} +2 -2
- package/dist/_chunks/{ai-tools-rail-CxYG04cw.js → ai-tools-rail-CYLWrRmm.js} +6 -6
- package/dist/_chunks/{alert-ywPR59NE.js → alert-CUTxnym2.js} +56 -35
- package/dist/_chunks/antenatal-schedule-timeline-Dg0m0yFl.js +412 -0
- package/dist/_chunks/{ar-DEz65ZJW.js → ar-C68WKG5a.js} +2 -2
- package/dist/_chunks/{audio-recorder-DC-v9YFW.js → audio-recorder-DVJXV7_k.js} +2 -2
- package/dist/_chunks/bishop-score-2MzAz8NE.js +185 -0
- package/dist/_chunks/{booking-WV2GSru5.js → booking-DljH0JkS.js} +5 -5
- package/dist/_chunks/circle-arrow-up-CC_85SuH.js +16 -0
- package/dist/_chunks/cycle-calculator-oOkj5wlB.js +252 -0
- package/dist/_chunks/{date-picker-Bq7xhMA-.js → date-picker-BfHblqwA.js} +2 -2
- package/dist/_chunks/{date-picker-variants-DLi1Va_e.js → date-picker-variants-CXEAx3O_.js} +22 -22
- package/dist/_chunks/{date-range-picker-DcXuI9y7.js → date-range-picker-hcAMs1wO.js} +3 -3
- package/dist/_chunks/{date-time-picker-RimumeLR.js → date-time-picker-H-3Pwqlb.js} +9 -9
- package/dist/_chunks/{de-bTBGdjPS.js → de-DK4A9_a8.js} +2 -2
- package/dist/_chunks/{document-scanner-BqLsGs4Y.js → document-scanner-Cxqvq7GR.js} +2 -2
- package/dist/_chunks/due-date-calculator-tDqZXPWO.js +256 -0
- package/dist/_chunks/{editable-currency-cell-renderer-CLil9B29.js → editable-currency-cell-renderer-Bh48OHRv.js} +2 -2
- package/dist/_chunks/{el-BWG5RXxa.js → el-B29HXhG5.js} +2 -2
- package/dist/_chunks/{es-DfO_G435.js → es-BOwPVwWn.js} +2 -2
- package/dist/_chunks/fetal-weight-Da-B4P4k.js +122 -0
- package/dist/_chunks/{fr-BTn24bs8.js → fr-DoDBtn0T.js} +2 -2
- package/dist/_chunks/{freemium-paywall-DzpD63WY.js → freemium-paywall-BWaLWje-.js} +2 -2
- package/dist/_chunks/gestational-age-calculator-DbDfTJU2.js +311 -0
- package/dist/_chunks/hcg-doubling-DAnpbale.js +170 -0
- package/dist/_chunks/{hi-Dj3oYd84.js → hi-DGByrKby.js} +2 -2
- package/dist/_chunks/{isSameWeek-HfxKk6Lz.js → isSameWeek-B1odL2vR.js} +2 -2
- package/dist/_chunks/{it-Y85ofIQQ.js → it-B16rEecm.js} +3 -3
- package/dist/_chunks/{ja-CQ7J6YoA.js → ja-B0viOgft.js} +2 -2
- package/dist/_chunks/{marketplace-app-shell-Gfsf78ge.js → marketplace-app-shell-UKSLx9K_.js} +3 -3
- package/dist/_chunks/{nl-D9kHCmp3.js → nl-cBxEX2QU.js} +2 -2
- package/dist/_chunks/{patient-search-CocVcGJ3.js → patient-search-BJOmTmDA.js} +2 -2
- package/dist/_chunks/{patient-shell-CnT4L8gn.js → patient-shell-DUmhXnFq.js} +2 -2
- package/dist/_chunks/{payment-form-BNTx4876.js → payment-form-xmeCkxas.js} +2 -2
- package/dist/_chunks/{pdf-viewer-G8SU6Azw.js → pdf-viewer-q1D3Uion.js} +2 -2
- package/dist/_chunks/{pl-B3Smqpkr.js → pl-DtS08ioY.js} +3 -3
- package/dist/_chunks/{practice-results-BFL_mcDW.js → practice-results-Cq1y8JFD.js} +2 -2
- package/dist/_chunks/pregnancy-weight-gain-CCGrvarh.js +322 -0
- package/dist/_chunks/product-hub-panel-CkfZBA3t.js +620 -0
- package/dist/_chunks/{pt-D3J-1c_7.js → pt-yFXs1VvH.js} +2 -2
- package/dist/_chunks/{ro-BKAbbEA3.js → ro-DsCzSrzR.js} +2 -2
- package/dist/_chunks/{ru-BeG8f0Ep.js → ru-DgDxL0pc.js} +3 -3
- package/dist/_chunks/{sidebar-_vJXI9rB.js → sidebar-h78cTNLh.js} +440 -338
- package/dist/_chunks/{sign-document-DPI2pY9V.js → sign-document-CZkAf28g.js} +2 -2
- package/dist/_chunks/{sq-_hRPaeUy.js → sq-DHlCYN67.js} +2 -2
- package/dist/_chunks/subDays-Bs00akhK.js +8 -0
- package/dist/_chunks/{sv-g009fSpe.js → sv-O0QaQs_s.js} +2 -2
- package/dist/_chunks/{tr-OKUOuhMW.js → tr-BmNDRuio.js} +2 -2
- package/dist/_chunks/warning-stack-CXfoAT-_.js +220 -0
- package/dist/_chunks/{workflow-map-ZXw-zsZ8.js → workflow-map-DzX_LI4y.js} +2 -2
- package/dist/_chunks/{zh-CN-De4zwEhx.js → zh-CN-CgVJZEzz.js} +3 -3
- package/dist/agent-catalog.json +44 -1
- package/dist/components/_shared/antenatal-schedule-timeline.d.ts +18 -0
- package/dist/components/_shared/antenatal-schedule.d.ts +68 -0
- package/dist/components/_shared/index.d.ts +3 -0
- package/dist/components/_shared/obstetrics.d.ts +138 -0
- package/dist/components/address-autocomplete/index.js +1 -1
- package/dist/components/ai-consent-banner/index.js +1 -1
- package/dist/components/ai-tools-rail/index.js +1 -1
- package/dist/components/alert/alert.d.ts +2 -2
- package/dist/components/alert/index.js +1 -1
- package/dist/components/audio-recorder/index.js +1 -1
- package/dist/components/bishop-score/bishop-score.d.ts +27 -0
- package/dist/components/bishop-score/bishop.d.ts +30 -0
- package/dist/components/bishop-score/index.d.ts +4 -0
- package/dist/components/bishop-score/index.js +10 -0
- package/dist/components/booking/index.js +1 -1
- package/dist/components/cycle-calculator/cycle.d.ts +5 -0
- package/dist/components/cycle-calculator/index.js +1 -1
- package/dist/components/data-table/index.js +1 -1
- package/dist/components/date-picker/index.js +1 -1
- package/dist/components/date-range-picker/index.js +1 -1
- package/dist/components/date-time-picker/index.js +1 -1
- package/dist/components/document-scanner/index.js +1 -1
- package/dist/components/due-date-calculator/due-date-calculator.d.ts +13 -1
- package/dist/components/due-date-calculator/gestation.d.ts +1 -59
- package/dist/components/due-date-calculator/index.d.ts +1 -1
- package/dist/components/due-date-calculator/index.js +16 -10
- package/dist/components/fetal-weight/efw.d.ts +25 -0
- package/dist/components/fetal-weight/fetal-weight.d.ts +27 -0
- package/dist/components/fetal-weight/index.d.ts +4 -0
- package/dist/components/fetal-weight/index.js +6 -0
- package/dist/components/freemium-paywall/index.js +1 -1
- package/dist/components/gestational-age-calculator/gestational-age-calculator.d.ts +25 -1
- package/dist/components/gestational-age-calculator/index.js +1 -1
- package/dist/components/hcg-doubling/hcg-doubling.d.ts +31 -0
- package/dist/components/hcg-doubling/hcg.d.ts +33 -0
- package/dist/components/hcg-doubling/index.d.ts +4 -0
- package/dist/components/hcg-doubling/index.js +7 -0
- package/dist/components/index.d.ts +4 -0
- package/dist/components/patient-search/index.js +1 -1
- package/dist/components/payment-form/index.js +1 -1
- package/dist/components/pdf-viewer/index.js +1 -1
- package/dist/components/practice-results/index.js +1 -1
- package/dist/components/pregnancy-weight-gain/index.js +1 -1
- package/dist/components/pregnancy-weight-gain/pregnancy-weight-gain.d.ts +7 -0
- package/dist/components/pregnancy-weight-gain/weight-gain.d.ts +33 -8
- package/dist/components/product-hub-tray/index.d.ts +8 -0
- package/dist/components/product-hub-tray/index.js +10 -0
- package/dist/components/product-hub-tray/product-hub-panel.agent.d.ts +4 -0
- package/dist/components/product-hub-tray/product-hub-panel.d.ts +54 -0
- package/dist/components/product-hub-tray/product-hub-tray.agent.d.ts +4 -0
- package/dist/components/product-hub-tray/product-hub-tray.d.ts +115 -0
- package/dist/components/sidebar/index.d.ts +2 -2
- package/dist/components/sidebar/index.js +12 -11
- package/dist/components/sidebar/sidebar.d.ts +14 -1
- package/dist/components/sign-document/index.js +1 -1
- package/dist/components/warning-stack/index.js +1 -1
- package/dist/components/workflow/index.js +1 -1
- package/dist/i18n/locales/ar.d.ts +210 -1
- package/dist/i18n/locales/ar.js +209 -2
- package/dist/i18n/locales/de.d.ts +210 -1
- package/dist/i18n/locales/de.js +209 -2
- package/dist/i18n/locales/el.d.ts +210 -1
- package/dist/i18n/locales/el.js +209 -2
- package/dist/i18n/locales/en.d.ts +210 -1
- package/dist/i18n/locales/en.js +209 -2
- package/dist/i18n/locales/es.d.ts +210 -1
- package/dist/i18n/locales/es.js +209 -2
- package/dist/i18n/locales/fr.d.ts +210 -1
- package/dist/i18n/locales/fr.js +209 -2
- package/dist/i18n/locales/hi.d.ts +210 -1
- package/dist/i18n/locales/hi.js +209 -2
- package/dist/i18n/locales/it.d.ts +210 -1
- package/dist/i18n/locales/it.js +209 -2
- package/dist/i18n/locales/ja.d.ts +210 -1
- package/dist/i18n/locales/ja.js +209 -2
- package/dist/i18n/locales/nl.d.ts +210 -1
- package/dist/i18n/locales/nl.js +209 -2
- package/dist/i18n/locales/pl.d.ts +210 -1
- package/dist/i18n/locales/pl.js +209 -2
- package/dist/i18n/locales/pt.d.ts +210 -1
- package/dist/i18n/locales/pt.js +209 -2
- package/dist/i18n/locales/ro.d.ts +210 -1
- package/dist/i18n/locales/ro.js +209 -2
- package/dist/i18n/locales/ru.d.ts +210 -1
- package/dist/i18n/locales/ru.js +209 -2
- package/dist/i18n/locales/sq.d.ts +210 -1
- package/dist/i18n/locales/sq.js +209 -2
- package/dist/i18n/locales/sv.d.ts +210 -1
- package/dist/i18n/locales/sv.js +209 -2
- package/dist/i18n/locales/tr.d.ts +210 -1
- package/dist/i18n/locales/tr.js +209 -2
- package/dist/i18n/locales/zh.d.ts +210 -1
- package/dist/i18n/locales/zh.js +209 -2
- package/dist/index.js +658 -631
- package/dist/locales/ar.json +211 -2
- package/dist/locales/de.json +211 -2
- package/dist/locales/el.json +211 -2
- package/dist/locales/en.json +211 -2
- package/dist/locales/es.json +211 -2
- package/dist/locales/fr.json +211 -2
- package/dist/locales/hi.json +211 -2
- package/dist/locales/it.json +211 -2
- package/dist/locales/ja.json +211 -2
- package/dist/locales/nl.json +211 -2
- package/dist/locales/pl.json +211 -2
- package/dist/locales/pt.json +211 -2
- package/dist/locales/ro.json +211 -2
- package/dist/locales/ru.json +211 -2
- package/dist/locales/sq.json +211 -2
- package/dist/locales/sv.json +211 -2
- package/dist/locales/tr.json +211 -2
- package/dist/locales/zh.json +211 -2
- package/dist/patterns/marketplace-app-shell/index.js +1 -1
- package/dist/patterns/patient-shell/index.js +1 -1
- package/dist/tokens.css +1 -1
- package/package.json +17 -1
- package/dist/_chunks/cycle-calculator-DYvGm_m1.js +0 -211
- package/dist/_chunks/due-date-calculator-BXd3ANj7.js +0 -216
- package/dist/_chunks/gestation-mWF4AXea.js +0 -50
- package/dist/_chunks/gestational-age-calculator-Crj6FgZw.js +0 -203
- package/dist/_chunks/pregnancy-weight-gain-C7dK89jE.js +0 -246
- package/dist/_chunks/subDays-Dv7q9S7u.js +0 -8
- package/dist/_chunks/warning-stack-DNR3-IbP.js +0 -180
|
@@ -2,7 +2,7 @@ import { jsxs as c, jsx as n } from "react/jsx-runtime";
|
|
|
2
2
|
import { forwardRef as ce, useId as le, useMemo as G, useRef as L, useState as x, useEffect as _, useCallback as l, useImperativeHandle as ue } from "react";
|
|
3
3
|
import { c as i } from "./index-D2ZczOXr.js";
|
|
4
4
|
import { useTranslation as me } from "react-i18next";
|
|
5
|
-
import { P as ge } from "./pdf-viewer-
|
|
5
|
+
import { P as ge } from "./pdf-viewer-q1D3Uion.js";
|
|
6
6
|
import { S as pe } from "./signature-capture-CpMBhqQ9.js";
|
|
7
7
|
import { u as fe } from "./registry-nPAVE19X.js";
|
|
8
8
|
import { C as J } from "./circle-check-9AeSgJD_.js";
|
|
@@ -341,4 +341,4 @@ export {
|
|
|
341
341
|
je as S,
|
|
342
342
|
ve as s
|
|
343
343
|
};
|
|
344
|
-
//# sourceMappingURL=sign-document-
|
|
344
|
+
//# sourceMappingURL=sign-document-CZkAf28g.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { q as s, r, v as i, w as m } from "./date-picker-variants-
|
|
1
|
+
import { q as s, r, v as i, w as m } from "./date-picker-variants-CXEAx3O_.js";
|
|
2
2
|
const d = {
|
|
3
3
|
lessThanXSeconds: {
|
|
4
4
|
one: "më pak se një sekondë",
|
|
@@ -352,4 +352,4 @@ const d = {
|
|
|
352
352
|
export {
|
|
353
353
|
T as sq
|
|
354
354
|
};
|
|
355
|
-
//# sourceMappingURL=sq-
|
|
355
|
+
//# sourceMappingURL=sq-DHlCYN67.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { q as d, r, v as i, w as m } from "./date-picker-variants-
|
|
1
|
+
import { q as d, r, v as i, w as m } from "./date-picker-variants-CXEAx3O_.js";
|
|
2
2
|
const s = {
|
|
3
3
|
lessThanXSeconds: {
|
|
4
4
|
one: "mindre än en sekund",
|
|
@@ -373,4 +373,4 @@ const s = {
|
|
|
373
373
|
export {
|
|
374
374
|
q as sv
|
|
375
375
|
};
|
|
376
|
-
//# sourceMappingURL=sv-
|
|
376
|
+
//# sourceMappingURL=sv-O0QaQs_s.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { q as o, r as n, v as i, w as m } from "./date-picker-variants-
|
|
1
|
+
import { q as o, r as n, v as i, w as m } from "./date-picker-variants-CXEAx3O_.js";
|
|
2
2
|
const d = {
|
|
3
3
|
lessThanXSeconds: {
|
|
4
4
|
one: "bir saniyeden az",
|
|
@@ -375,4 +375,4 @@ const d = {
|
|
|
375
375
|
export {
|
|
376
376
|
O as tr
|
|
377
377
|
};
|
|
378
|
-
//# sourceMappingURL=tr-
|
|
378
|
+
//# sourceMappingURL=tr-BmNDRuio.js.map
|
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
import { jsxs as d, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as U, useId as M, useState as T, useEffect as b, useMemo as G, useRef as p, useCallback as S } from "react";
|
|
3
|
+
import { c as V } from "./index-D2ZczOXr.js";
|
|
4
|
+
import { useTranslation as X } from "react-i18next";
|
|
5
|
+
import { A as v } from "./alert-CUTxnym2.js";
|
|
6
|
+
import { B as Y } from "./button-DD_0Xdmr.js";
|
|
7
|
+
import { C as Z } from "./chevron-down-BX_NP2Yh.js";
|
|
8
|
+
const O = V(
|
|
9
|
+
[
|
|
10
|
+
"ds:flex ds:flex-col",
|
|
11
|
+
"ds:rounded-[var(--radius-lg)]",
|
|
12
|
+
"ds:bg-[color:var(--card)] ds:text-[color:var(--card-foreground)]",
|
|
13
|
+
"ds:shadow-[var(--shadow-card)]",
|
|
14
|
+
"ds:border ds:border-[color:var(--card-border)] ds:[.theme-accessible_&]:border-2",
|
|
15
|
+
"ds:p-[var(--spacing-md)]"
|
|
16
|
+
].join(" "),
|
|
17
|
+
{
|
|
18
|
+
variants: {
|
|
19
|
+
size: {
|
|
20
|
+
sm: "ds:gap-[var(--spacing-sm)]",
|
|
21
|
+
md: "ds:gap-[var(--spacing-md)]"
|
|
22
|
+
},
|
|
23
|
+
// `stretch: true` fills the parent layout cell — mirrors the `stretch`
|
|
24
|
+
// prop on `Card` so a WarningStack rendered next to a Card in a grid
|
|
25
|
+
// row ends up at matching height.
|
|
26
|
+
stretch: {
|
|
27
|
+
true: "ds:h-full ds:self-stretch",
|
|
28
|
+
false: ""
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
defaultVariants: {
|
|
32
|
+
size: "md",
|
|
33
|
+
stretch: !1
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
), $ = V(
|
|
37
|
+
[
|
|
38
|
+
"ds:grid ds:grid-cols-1",
|
|
39
|
+
"ds:@3xl/warning-stack:grid-cols-2",
|
|
40
|
+
"ds:@3xl/warning-stack:[&>li:nth-child(odd):last-child]:col-span-full"
|
|
41
|
+
].join(" "),
|
|
42
|
+
{
|
|
43
|
+
variants: {
|
|
44
|
+
size: {
|
|
45
|
+
sm: "ds:gap-[var(--spacing-sm)]",
|
|
46
|
+
md: "ds:gap-[var(--spacing-md)]"
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
defaultVariants: { size: "md" }
|
|
50
|
+
}
|
|
51
|
+
), D = [
|
|
52
|
+
"ds:inline-flex ds:items-center ds:gap-[var(--spacing-xs)] ds:self-start"
|
|
53
|
+
].join(" "), nn = U(
|
|
54
|
+
({
|
|
55
|
+
items: u,
|
|
56
|
+
title: k,
|
|
57
|
+
description: N,
|
|
58
|
+
maxVisible: o,
|
|
59
|
+
defaultCollapsed: _ = !0,
|
|
60
|
+
onDismiss: f,
|
|
61
|
+
size: w = "md",
|
|
62
|
+
stretch: C = !1,
|
|
63
|
+
ariaLabel: q,
|
|
64
|
+
emptyState: y,
|
|
65
|
+
className: I,
|
|
66
|
+
...j
|
|
67
|
+
}, l) => {
|
|
68
|
+
const { t: i } = X(), g = M(), z = M(), [R, A] = T(
|
|
69
|
+
() => /* @__PURE__ */ new Set()
|
|
70
|
+
);
|
|
71
|
+
b(() => {
|
|
72
|
+
A((n) => {
|
|
73
|
+
if (n.size === 0) return n;
|
|
74
|
+
const s = new Set(u.map((a) => a.id)), r = new Set([...n].filter((a) => s.has(a)));
|
|
75
|
+
return r.size === n.size ? n : r;
|
|
76
|
+
});
|
|
77
|
+
}, [u]);
|
|
78
|
+
const t = G(
|
|
79
|
+
() => u.filter((n) => !R.has(n.id)),
|
|
80
|
+
[u, R]
|
|
81
|
+
), h = o !== void 0 && t.length > o, [c, F] = T(_), x = p(null), L = p(t.length);
|
|
82
|
+
b(() => {
|
|
83
|
+
if (!x.current) return;
|
|
84
|
+
const n = L.current, s = t.length;
|
|
85
|
+
n !== s && (x.current.textContent = i("warningStack.countChanged", {
|
|
86
|
+
count: s,
|
|
87
|
+
defaultValue: "{{count}} warnings to review"
|
|
88
|
+
})), L.current = s;
|
|
89
|
+
}, [t.length, i]);
|
|
90
|
+
const H = G(() => !h || !c ? t : t.slice(0, o), [t, h, c, o]), J = h ? t.length - (o ?? 0) : 0, B = p(null), W = S(
|
|
91
|
+
(n) => {
|
|
92
|
+
B.current = n, typeof l == "function" ? l(n) : l && (l.current = n);
|
|
93
|
+
},
|
|
94
|
+
[l]
|
|
95
|
+
), m = p(null);
|
|
96
|
+
b(() => {
|
|
97
|
+
if (m.current === null) return;
|
|
98
|
+
const n = m.current;
|
|
99
|
+
m.current = null;
|
|
100
|
+
const s = B.current;
|
|
101
|
+
if (!s) return;
|
|
102
|
+
const r = Array.from(
|
|
103
|
+
s.querySelectorAll("[data-alert-dismiss]")
|
|
104
|
+
), a = r[Math.min(n, r.length - 1)];
|
|
105
|
+
a ? a.focus() : s.focus();
|
|
106
|
+
});
|
|
107
|
+
const K = S(
|
|
108
|
+
(n, s) => (r) => {
|
|
109
|
+
r || (m.current = s, A((a) => new Set(a).add(n.id)), f == null || f(n));
|
|
110
|
+
},
|
|
111
|
+
[f]
|
|
112
|
+
), P = S(() => F((n) => !n), []), Q = q ?? i("warningStack.regionLabel", "Warnings"), E = k ? /* @__PURE__ */ d("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-2xs)]", children: [
|
|
113
|
+
/* @__PURE__ */ e(
|
|
114
|
+
"h2",
|
|
115
|
+
{
|
|
116
|
+
id: g,
|
|
117
|
+
className: "ds:text-start type-title-section ds:text-[var(--foreground)]",
|
|
118
|
+
children: k
|
|
119
|
+
}
|
|
120
|
+
),
|
|
121
|
+
N ? /* @__PURE__ */ e("p", { className: "ds:text-start type-body-sm ds:text-[var(--muted-foreground)]", children: N }) : null
|
|
122
|
+
] }) : /* @__PURE__ */ e("h2", { id: g, className: "ds:sr-only", children: Q });
|
|
123
|
+
return t.length === 0 ? y ? /* @__PURE__ */ d(
|
|
124
|
+
"section",
|
|
125
|
+
{
|
|
126
|
+
ref: W,
|
|
127
|
+
"aria-labelledby": g,
|
|
128
|
+
"data-component": "warning-stack",
|
|
129
|
+
tabIndex: -1,
|
|
130
|
+
className: [O({ size: w, stretch: C }), I].filter(Boolean).join(" "),
|
|
131
|
+
...j,
|
|
132
|
+
children: [
|
|
133
|
+
E,
|
|
134
|
+
y
|
|
135
|
+
]
|
|
136
|
+
}
|
|
137
|
+
) : null : /* @__PURE__ */ d(
|
|
138
|
+
"section",
|
|
139
|
+
{
|
|
140
|
+
ref: W,
|
|
141
|
+
"aria-labelledby": g,
|
|
142
|
+
"data-component": "warning-stack",
|
|
143
|
+
tabIndex: -1,
|
|
144
|
+
className: [O({ size: w, stretch: C }), I].filter(Boolean).join(" "),
|
|
145
|
+
...j,
|
|
146
|
+
children: [
|
|
147
|
+
E,
|
|
148
|
+
/* @__PURE__ */ e(
|
|
149
|
+
"div",
|
|
150
|
+
{
|
|
151
|
+
ref: x,
|
|
152
|
+
"aria-live": "polite",
|
|
153
|
+
"aria-atomic": "true",
|
|
154
|
+
className: "ds:sr-only"
|
|
155
|
+
}
|
|
156
|
+
),
|
|
157
|
+
/* @__PURE__ */ e("div", { className: "ds:@container/warning-stack", children: /* @__PURE__ */ e(
|
|
158
|
+
"ul",
|
|
159
|
+
{
|
|
160
|
+
id: z,
|
|
161
|
+
className: $({ size: w }),
|
|
162
|
+
"aria-label": i("warningStack.listLabel", "Notices"),
|
|
163
|
+
children: H.map((n, s) => {
|
|
164
|
+
const r = n.variant ?? "warning";
|
|
165
|
+
return /* @__PURE__ */ e("li", { children: /* @__PURE__ */ d(
|
|
166
|
+
v,
|
|
167
|
+
{
|
|
168
|
+
variant: r,
|
|
169
|
+
dismissible: n.dismissible,
|
|
170
|
+
icon: n.icon,
|
|
171
|
+
onOpenChange: K(n, s),
|
|
172
|
+
className: "ds:h-full",
|
|
173
|
+
children: [
|
|
174
|
+
/* @__PURE__ */ e(v.Title, { as: "h3", children: n.title }),
|
|
175
|
+
n.description ? /* @__PURE__ */ e(v.Description, { children: n.description }) : null,
|
|
176
|
+
n.actions ? /* @__PURE__ */ e(v.Action, { children: n.actions }) : null
|
|
177
|
+
]
|
|
178
|
+
}
|
|
179
|
+
) }, n.id);
|
|
180
|
+
})
|
|
181
|
+
}
|
|
182
|
+
) }),
|
|
183
|
+
h ? /* @__PURE__ */ d(
|
|
184
|
+
Y,
|
|
185
|
+
{
|
|
186
|
+
type: "button",
|
|
187
|
+
intent: "link",
|
|
188
|
+
size: "sm",
|
|
189
|
+
"aria-expanded": !c,
|
|
190
|
+
"aria-controls": z,
|
|
191
|
+
onClick: P,
|
|
192
|
+
className: D,
|
|
193
|
+
children: [
|
|
194
|
+
/* @__PURE__ */ e(
|
|
195
|
+
Z,
|
|
196
|
+
{
|
|
197
|
+
"aria-hidden": "true",
|
|
198
|
+
className: [
|
|
199
|
+
"ds:size-4 ds:transition-transform ds:duration-[var(--animation-duration)] ds:motion-reduce:transition-none",
|
|
200
|
+
c ? "" : "ds:rotate-180"
|
|
201
|
+
].join(" ")
|
|
202
|
+
}
|
|
203
|
+
),
|
|
204
|
+
c ? i("warningStack.showMore", {
|
|
205
|
+
count: J,
|
|
206
|
+
defaultValue: "Show {{count}} more warnings"
|
|
207
|
+
}) : i("warningStack.showLess", "Show less")
|
|
208
|
+
]
|
|
209
|
+
}
|
|
210
|
+
) : null
|
|
211
|
+
]
|
|
212
|
+
}
|
|
213
|
+
);
|
|
214
|
+
}
|
|
215
|
+
);
|
|
216
|
+
nn.displayName = "WarningStack";
|
|
217
|
+
export {
|
|
218
|
+
nn as W
|
|
219
|
+
};
|
|
220
|
+
//# sourceMappingURL=warning-stack-CXfoAT-_.js.map
|
|
@@ -11,7 +11,7 @@ import { P as U } from "./pencil-CfQX-0Qc.js";
|
|
|
11
11
|
import { c as z } from "./createLucideIcon-CrFbzy84.js";
|
|
12
12
|
import { C as Ne } from "./circle-BkqTgYmt.js";
|
|
13
13
|
import { u as Ce } from "./registry-nPAVE19X.js";
|
|
14
|
-
import { A as V } from "./alert-
|
|
14
|
+
import { A as V } from "./alert-CUTxnym2.js";
|
|
15
15
|
import { B as _e } from "./button-DD_0Xdmr.js";
|
|
16
16
|
import { D as N } from "./dropdown-menu-CUEXqKis.js";
|
|
17
17
|
import { E } from "./empty-state-BLy7tigq.js";
|
|
@@ -1366,4 +1366,4 @@ export {
|
|
|
1366
1366
|
ee as r,
|
|
1367
1367
|
L as w
|
|
1368
1368
|
};
|
|
1369
|
-
//# sourceMappingURL=workflow-map-
|
|
1369
|
+
//# sourceMappingURL=workflow-map-DzX_LI4y.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { q as s, r as i, v as o, w as m } from "./date-picker-variants-
|
|
2
|
-
import { i as u } from "./isSameWeek-
|
|
1
|
+
import { q as s, r as i, v as o, w as m } from "./date-picker-variants-CXEAx3O_.js";
|
|
2
|
+
import { i as u } from "./isSameWeek-B1odL2vR.js";
|
|
3
3
|
const c = {
|
|
4
4
|
lessThanXSeconds: {
|
|
5
5
|
one: "不到 1 秒",
|
|
@@ -385,4 +385,4 @@ const b = {
|
|
|
385
385
|
export {
|
|
386
386
|
Q as zhCN
|
|
387
387
|
};
|
|
388
|
-
//# sourceMappingURL=zh-CN-
|
|
388
|
+
//# sourceMappingURL=zh-CN-CgVJZEzz.js.map
|
package/dist/agent-catalog.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 1,
|
|
3
|
-
"packageVersion": "0.
|
|
3
|
+
"packageVersion": "0.49.0",
|
|
4
4
|
"components": [
|
|
5
5
|
{
|
|
6
6
|
"kind": "component",
|
|
@@ -3234,6 +3234,49 @@
|
|
|
3234
3234
|
}
|
|
3235
3235
|
}
|
|
3236
3236
|
},
|
|
3237
|
+
{
|
|
3238
|
+
"kind": "component",
|
|
3239
|
+
"id": "product-hub-tray",
|
|
3240
|
+
"capabilities": [
|
|
3241
|
+
"open",
|
|
3242
|
+
"close"
|
|
3243
|
+
],
|
|
3244
|
+
"state": [
|
|
3245
|
+
{
|
|
3246
|
+
"name": "unseenCount",
|
|
3247
|
+
"type": "number",
|
|
3248
|
+
"description": "Number of unseen product releases — the trigger badge count."
|
|
3249
|
+
}
|
|
3250
|
+
],
|
|
3251
|
+
"actions": [
|
|
3252
|
+
{
|
|
3253
|
+
"name": "open",
|
|
3254
|
+
"safety": "read",
|
|
3255
|
+
"description": "Open the product-updates panel."
|
|
3256
|
+
},
|
|
3257
|
+
{
|
|
3258
|
+
"name": "close",
|
|
3259
|
+
"safety": "read",
|
|
3260
|
+
"description": "Close the product-updates panel."
|
|
3261
|
+
}
|
|
3262
|
+
],
|
|
3263
|
+
"domHooks": {
|
|
3264
|
+
"root": {
|
|
3265
|
+
"attr": "data-component",
|
|
3266
|
+
"value": "product-hub-tray",
|
|
3267
|
+
"description": "Marks the ProductHubTray wrapper."
|
|
3268
|
+
},
|
|
3269
|
+
"instanceId": {
|
|
3270
|
+
"attr": "data-component-id",
|
|
3271
|
+
"sourceProp": "id",
|
|
3272
|
+
"description": "Sourced from the id prop. Required to address a specific tray from the agent."
|
|
3273
|
+
},
|
|
3274
|
+
"item": {
|
|
3275
|
+
"attr": "data-update-id",
|
|
3276
|
+
"description": "Stable release id emitted on each rendered release row inside the tray."
|
|
3277
|
+
}
|
|
3278
|
+
}
|
|
3279
|
+
},
|
|
3237
3280
|
{
|
|
3238
3281
|
"kind": "component",
|
|
3239
3282
|
"id": "progress",
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { InsertCardField } from './insert-result';
|
|
2
|
+
import type { ResolvedAntenatalEvent } from './antenatal-schedule';
|
|
3
|
+
/** Minimal translator shape this module needs (matches react-i18next's `t`). */
|
|
4
|
+
type Translate = (key: string, opts?: Record<string, unknown>) => string;
|
|
5
|
+
/**
|
|
6
|
+
* Build the inserted-card rows for a resolved schedule, so a host calculator's
|
|
7
|
+
* single Insert button can carry the schedule in its payload (rather than a
|
|
8
|
+
* second Insert button on the schedule card). One row per event: a
|
|
9
|
+
* category-tinted glyph, the localised label, and the date range.
|
|
10
|
+
*/
|
|
11
|
+
export declare function buildScheduleInsertFields(events: ResolvedAntenatalEvent[], t: Translate, formatDate: (date: Date) => string): InsertCardField[];
|
|
12
|
+
export interface AntenatalScheduleTimelineProps {
|
|
13
|
+
/** Resolved schedule events (from `computeAntenatalSchedule`). */
|
|
14
|
+
events: ResolvedAntenatalEvent[];
|
|
15
|
+
}
|
|
16
|
+
export declare function AntenatalScheduleTimeline({ events, }: AntenatalScheduleTimelineProps): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export {};
|
|
18
|
+
//# sourceMappingURL=antenatal-schedule-timeline.d.ts.map
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { type Plurality, type Chorionicity, type BirthGuideline } from './obstetrics';
|
|
2
|
+
export type AntenatalCategory = 'scan' | 'screening' | 'diagnostic' | 'lab' | 'prophylaxis' | 'milestone';
|
|
3
|
+
/** Which national schedule to resolve. Italy is the default market. */
|
|
4
|
+
export type ScheduleLocale = 'it' | 'uk' | 'international';
|
|
5
|
+
/** Status of a window relative to the reference date (keyed off its end). */
|
|
6
|
+
export type AntenatalStatus = 'past' | 'current' | 'upcoming';
|
|
7
|
+
/** Gestational-diabetes risk tier (drives which OGTT window applies). */
|
|
8
|
+
export type GdmRisk = 'high' | 'medium';
|
|
9
|
+
/** A clinical condition gating whether an event applies to a pregnancy. */
|
|
10
|
+
export type AntenatalCondition = 'rh-negative' | 'gdm-high' | 'gdm-medium' | 'on-indication';
|
|
11
|
+
export interface AntenatalEvent {
|
|
12
|
+
/** Stable key → i18n lookup `antenatalSchedule.event.<key>`. */
|
|
13
|
+
key: string;
|
|
14
|
+
category: AntenatalCategory;
|
|
15
|
+
/** Window start as GA days from gestationalStart (week*7 + day). Inclusive. */
|
|
16
|
+
startDay: number;
|
|
17
|
+
/** Window end as GA days. Inclusive. Equals `startDay` for single dates. */
|
|
18
|
+
endDay: number;
|
|
19
|
+
/** Restrict to these pluralities (omit ⇒ applies to all). */
|
|
20
|
+
plurality?: Plurality[];
|
|
21
|
+
/** Restrict to these chorionicities (omit ⇒ any). */
|
|
22
|
+
chorionicity?: Chorionicity[];
|
|
23
|
+
/** Gate behind a clinical condition (omit ⇒ always applies). */
|
|
24
|
+
condition?: AntenatalCondition;
|
|
25
|
+
/** Citation key for provenance display. */
|
|
26
|
+
source: string;
|
|
27
|
+
/** Interpolation values for the event's i18n string (e.g. surveillance cadence). */
|
|
28
|
+
meta?: Record<string, string | number>;
|
|
29
|
+
}
|
|
30
|
+
export interface ResolvedAntenatalEvent extends AntenatalEvent {
|
|
31
|
+
/** Absolute window start date. */
|
|
32
|
+
start: Date;
|
|
33
|
+
/** Absolute window end date (=== `start` for a single-date event). */
|
|
34
|
+
end: Date;
|
|
35
|
+
/** True when the event is a single calendar date, not a range. */
|
|
36
|
+
single: boolean;
|
|
37
|
+
/** Status relative to the reference date, keyed off the window end. */
|
|
38
|
+
status: AntenatalStatus;
|
|
39
|
+
/** Reference date is within `nearDays` before the window end. */
|
|
40
|
+
near: boolean;
|
|
41
|
+
}
|
|
42
|
+
export interface AntenatalScheduleOptions {
|
|
43
|
+
/** Reference date for status. Defaults to the host's current date. */
|
|
44
|
+
today?: Date;
|
|
45
|
+
/** National schedule. Defaults to `'it'`. */
|
|
46
|
+
schedule?: ScheduleLocale;
|
|
47
|
+
/** Number of fetuses. Defaults to `'singleton'`. */
|
|
48
|
+
plurality?: Plurality;
|
|
49
|
+
/** Placentation, for multiples. Defaults to `'unknown'`. */
|
|
50
|
+
chorionicity?: Chorionicity;
|
|
51
|
+
/** Surface the anti-D prophylaxis event (Rh-negative, non-sensitised). */
|
|
52
|
+
rhNegative?: boolean;
|
|
53
|
+
/** Surface the matching OGTT window for the patient's GDM risk tier. */
|
|
54
|
+
gdmRisk?: GdmRisk;
|
|
55
|
+
/** Include `on-indication` diagnostics (CVS, amnio, NIPT). Default false. */
|
|
56
|
+
includeOnIndication?: boolean;
|
|
57
|
+
/** Planned-birth guideline for multiples. Defaults to `'nice'`. */
|
|
58
|
+
birthGuideline?: BirthGuideline;
|
|
59
|
+
/** Days before a window's end still counted as `current`. Default 14. */
|
|
60
|
+
nearDays?: number;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Resolve the antenatal schedule for a pregnancy to dated, status-tagged
|
|
64
|
+
* windows, ordered by start date (then end date). Pure: the only clock is
|
|
65
|
+
* `opts.today` (defaults to a fresh `Date`).
|
|
66
|
+
*/
|
|
67
|
+
export declare function computeAntenatalSchedule(gestationalStart: Date, opts?: AntenatalScheduleOptions): ResolvedAntenatalEvent[];
|
|
68
|
+
//# sourceMappingURL=antenatal-schedule.d.ts.map
|
|
@@ -4,6 +4,9 @@ export { isSafeEntityUrl } from './is-safe-url';
|
|
|
4
4
|
export { entitySurfaceVariants, CARE_PLAN_STATE_BADGE, APPOINTMENT_STATE_BADGE, APPOINTMENT_STATE_BADGE_DEFAULT, appointmentStateBadge, colorIdToToken, type CarePlanState, type AppointmentState, } from './entity-card';
|
|
5
5
|
export { SafeHtml, sanitiseHtml, type SafeHtmlProfile, type SafeHtmlProps, } from './safe-html';
|
|
6
6
|
export { groupOptions } from './group-options';
|
|
7
|
+
export { computeDueDate, trimesterForWeeks, gestationalMilestones, trimesterHighlightToken, plannedBirthWindow, crlToGestationalAgeDays, redatingThresholdDays, redateByCrl, MILESTONE_WEEKS, GESTATION_DAYS, CONCEPTION_OFFSET_DAYS, TERM_FROM_CONCEPTION_DAYS, DEFAULT_CYCLE_LENGTH, CRL_DATING_MIN_MM, CRL_DATING_MAX_MM, TRIMESTER_BADGE_VARIANT, TRIMESTER_HIGHLIGHT_TOKEN, type BirthGuideline, type BirthWindow, type CrlRedatingInput, type CrlRedatingResult, type DueDateMethod, type EmbryoAge, type Trimester, type TrimesterBadgeVariant, type DueDateInput, type DueDateResult, type GestationalAge, type GestationalMilestone, type Plurality, type Chorionicity, } from './obstetrics';
|
|
8
|
+
export { computeAntenatalSchedule, type AntenatalEvent, type ResolvedAntenatalEvent, type AntenatalScheduleOptions, type AntenatalCategory, type AntenatalStatus, type AntenatalCondition, type ScheduleLocale, type GdmRisk, } from './antenatal-schedule';
|
|
9
|
+
export { AntenatalScheduleTimeline, type AntenatalScheduleTimelineProps, } from './antenatal-schedule-timeline';
|
|
7
10
|
export { InsertButton, buildResultText, buildResultHtml, buildResultCardSvg, svgCardToPngDataUri, svgCardToPng, type InsertButtonProps, type InsertVariant, type InsertPayload, type InsertPngResult, type InsertMode, type InsertCardData, type InsertCardField, type InsertCardGauge, type SvgCardToPngOptions, } from './insert-result';
|
|
8
11
|
export { normalizeDiacritics } from './normalize-diacritics';
|
|
9
12
|
export { useDebouncedCallback } from './use-debounced-callback';
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
export type DueDateMethod = 'lmp' | 'conception' | 'ivf';
|
|
2
|
+
/** Embryo age at transfer, in days (cleavage vs blastocyst). */
|
|
3
|
+
export type EmbryoAge = 3 | 5;
|
|
4
|
+
export type Trimester = 'preconception' | 'first' | 'second' | 'third' | 'postterm';
|
|
5
|
+
/** Number of fetuses. Drives surveillance schedule and planned-birth timing. */
|
|
6
|
+
export type Plurality = 'singleton' | 'twin' | 'triplet';
|
|
7
|
+
/**
|
|
8
|
+
* Placentation of a multiple pregnancy. `unknown` is the safe default — managed
|
|
9
|
+
* as monochorionic (the higher-risk assumption) until proven otherwise, per
|
|
10
|
+
* NICE QS46. Only meaningful when `plurality !== 'singleton'`.
|
|
11
|
+
*/
|
|
12
|
+
export type Chorionicity = 'dichorionic-diamniotic' | 'monochorionic-diamniotic' | 'monochorionic-monoamniotic' | 'unknown';
|
|
13
|
+
/** Naegele's rule: a term pregnancy is 280 days from the LMP. */
|
|
14
|
+
export declare const GESTATION_DAYS = 280;
|
|
15
|
+
/** Ovulation/conception sits ~14 days after the LMP in a 28-day cycle. */
|
|
16
|
+
export declare const CONCEPTION_OFFSET_DAYS = 14;
|
|
17
|
+
/** A term pregnancy is 266 days from conception. */
|
|
18
|
+
export declare const TERM_FROM_CONCEPTION_DAYS = 266;
|
|
19
|
+
/** Standard menstrual-cycle length Naegele assumes. */
|
|
20
|
+
export declare const DEFAULT_CYCLE_LENGTH = 28;
|
|
21
|
+
export interface DueDateInput {
|
|
22
|
+
method: DueDateMethod;
|
|
23
|
+
/** The reference date for the chosen method (LMP / conception / transfer). */
|
|
24
|
+
date: Date;
|
|
25
|
+
/** LMP only — average cycle length in days. Defaults to 28. */
|
|
26
|
+
cycleLength?: number;
|
|
27
|
+
/** IVF only — embryo age at transfer in days. Defaults to 5 (blastocyst). */
|
|
28
|
+
embryoAge?: EmbryoAge;
|
|
29
|
+
}
|
|
30
|
+
export interface GestationalAge {
|
|
31
|
+
weeks: number;
|
|
32
|
+
days: number;
|
|
33
|
+
totalDays: number;
|
|
34
|
+
}
|
|
35
|
+
export interface DueDateResult {
|
|
36
|
+
/** Estimated date of delivery. */
|
|
37
|
+
dueDate: Date;
|
|
38
|
+
/** GA day-0 anchor (notional LMP) the trimester maths counts from. */
|
|
39
|
+
gestationalStart: Date;
|
|
40
|
+
/** Gestational age as of `today`; `null` before conception. */
|
|
41
|
+
gestationalAge: GestationalAge | null;
|
|
42
|
+
trimester: Trimester;
|
|
43
|
+
}
|
|
44
|
+
/** Classify gestational age (in completed weeks) into a trimester. */
|
|
45
|
+
export declare function trimesterForWeeks(totalDays: number): Trimester;
|
|
46
|
+
/**
|
|
47
|
+
* Resolve the gestational start (notional LMP) and due date for a method.
|
|
48
|
+
* `cycleLength` shifts a longer/shorter cycle's ovulation, moving the due
|
|
49
|
+
* date while GA stays counted from the LMP — the standard convention.
|
|
50
|
+
*/
|
|
51
|
+
export declare function computeDueDate(input: DueDateInput, today: Date): DueDateResult;
|
|
52
|
+
/** Gestational weeks at which clinically notable milestones fall. */
|
|
53
|
+
export declare const MILESTONE_WEEKS: readonly [12, 24, 28, 37, 40];
|
|
54
|
+
export interface GestationalMilestone {
|
|
55
|
+
/** Stable key (`w12`, `w24`, …) for i18n lookup. */
|
|
56
|
+
key: string;
|
|
57
|
+
/** Completed gestational weeks. */
|
|
58
|
+
week: number;
|
|
59
|
+
/** Calendar date the milestone is reached. */
|
|
60
|
+
date: Date;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Project the standard milestone dates from a gestational start (notional
|
|
64
|
+
* LMP / GA day 0): end of first trimester (12w), viability (24w), third
|
|
65
|
+
* trimester (28w), term (37w) and the 40-week due date.
|
|
66
|
+
*/
|
|
67
|
+
export declare function gestationalMilestones(gestationalStart: Date): GestationalMilestone[];
|
|
68
|
+
/** Badge `variant` names used for trimesters (the Badge component's union). */
|
|
69
|
+
export type TrimesterBadgeVariant = 'neutral' | 'info' | 'success' | 'warning' | 'error';
|
|
70
|
+
/** Trimester → on-screen Badge variant. */
|
|
71
|
+
export declare const TRIMESTER_BADGE_VARIANT: Record<Trimester, TrimesterBadgeVariant>;
|
|
72
|
+
/**
|
|
73
|
+
* DS token NAME backing each trimester's result-card chip — the solid-fill
|
|
74
|
+
* companion of `TRIMESTER_BADGE_VARIANT` (Badge `error` fills `--destructive`;
|
|
75
|
+
* `neutral` fills `--muted`). Passed as the card's `highlightToken` so the
|
|
76
|
+
* inserted PNG chip matches the on-screen trimester badge; `InsertButton`
|
|
77
|
+
* resolves the name to a concrete colour at raster time.
|
|
78
|
+
*
|
|
79
|
+
* `third` resolves to `--warning-readable`, which the result card's colour
|
|
80
|
+
* probe resolves in the live themed DOM: orange-600 in light, non-accessible
|
|
81
|
+
* mode (where bare `--warning` yellow only reaches ~3.2:1 on the white card)
|
|
82
|
+
* and `--warning` elsewhere, whose deepened ramp already clears contrast.
|
|
83
|
+
* Resolving the token NAME at the card means the choice tracks the live theme
|
|
84
|
+
* regardless of where the theme class lives.
|
|
85
|
+
*/
|
|
86
|
+
export declare const TRIMESTER_HIGHLIGHT_TOKEN: Record<Trimester, string>;
|
|
87
|
+
/** The DS token name for a trimester's result-card chip. */
|
|
88
|
+
export declare function trimesterHighlightToken(trimester: Trimester): string;
|
|
89
|
+
/** Which body's planned-birth timing to use for multiples. */
|
|
90
|
+
export type BirthGuideline = 'nice' | 'acog';
|
|
91
|
+
/** Planned-birth window as GA days (week*7 + day), inclusive, with source. */
|
|
92
|
+
export interface BirthWindow {
|
|
93
|
+
startDay: number;
|
|
94
|
+
endDay: number;
|
|
95
|
+
source: string;
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* Recommended planned-birth window for a multiple pregnancy, by chorionicity.
|
|
99
|
+
* Singletons return `null` (use the 40-week EDD instead). `unknown`
|
|
100
|
+
* chorionicity is managed as monochorionic-diamniotic — the higher-risk
|
|
101
|
+
* default (NICE QS46).
|
|
102
|
+
*/
|
|
103
|
+
export declare function plannedBirthWindow(plurality: Plurality, chorionicity?: Chorionicity, guideline?: BirthGuideline): BirthWindow | null;
|
|
104
|
+
/** Robinson–Fleming dating is validated for CRL 45–84 mm. */
|
|
105
|
+
export declare const CRL_DATING_MIN_MM = 45;
|
|
106
|
+
export declare const CRL_DATING_MAX_MM = 84;
|
|
107
|
+
/** Gestational age in days from a crown-rump length (mm), Robinson–Fleming. */
|
|
108
|
+
export declare function crlToGestationalAgeDays(crlMm: number): number;
|
|
109
|
+
/**
|
|
110
|
+
* ACOG CO 700 redating threshold (in days) for a given GA-by-LMP: re-date the
|
|
111
|
+
* EDD to the ultrasound estimate only when the discrepancy EXCEEDS this.
|
|
112
|
+
*/
|
|
113
|
+
export declare function redatingThresholdDays(gaByLmpDays: number): number;
|
|
114
|
+
export interface CrlRedatingInput {
|
|
115
|
+
/** Reported first day of the last menstrual period. */
|
|
116
|
+
lmp: Date;
|
|
117
|
+
/** Date the ultrasound CRL was measured. */
|
|
118
|
+
scanDate: Date;
|
|
119
|
+
/** Crown-rump length, mm. */
|
|
120
|
+
crlMm: number;
|
|
121
|
+
}
|
|
122
|
+
export interface CrlRedatingResult {
|
|
123
|
+
/** Notional LMP (GA day 0) after the rule — the ultrasound's or the original. */
|
|
124
|
+
gestationalStart: Date;
|
|
125
|
+
/** Whether the ultrasound estimate replaced the LMP dating. */
|
|
126
|
+
redated: boolean;
|
|
127
|
+
/** |GA-by-LMP − GA-by-CRL| at the scan, in days. */
|
|
128
|
+
discrepancyDays: number;
|
|
129
|
+
/** The ACOG CO 700 threshold (days) that applied. */
|
|
130
|
+
thresholdDays: number;
|
|
131
|
+
/** CRL − LMP dating, in days (+ = fetus ahead of dates). Server `eco_diff_days`. */
|
|
132
|
+
ecoDiffDays: number;
|
|
133
|
+
/** Whether the CRL is within the 45–84 mm dating-validity window. */
|
|
134
|
+
crlInRange: boolean;
|
|
135
|
+
}
|
|
136
|
+
/** Apply the ACOG CO 700 CRL-redating rule to an LMP. */
|
|
137
|
+
export declare function redateByCrl(input: CrlRedatingInput): CrlRedatingResult;
|
|
138
|
+
//# sourceMappingURL=obstetrics.d.ts.map
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { type HTMLAttributes, type ReactNode } from 'react';
|
|
2
2
|
import { type VariantProps } from 'class-variance-authority';
|
|
3
3
|
declare const alertVariants: (props?: ({
|
|
4
|
-
variant?: "error" | "info" | "success" | "warning" | null | undefined;
|
|
4
|
+
variant?: "error" | "info" | "success" | "warning" | "promo" | null | undefined;
|
|
5
5
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
6
6
|
interface AlertTitleProps extends HTMLAttributes<HTMLHeadingElement> {
|
|
7
7
|
as?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'p' | 'span';
|
|
8
8
|
}
|
|
9
9
|
export interface AlertProps extends Omit<HTMLAttributes<HTMLDivElement>, 'role'>, VariantProps<typeof alertVariants> {
|
|
10
|
-
variant?: 'info' | 'success' | 'warning' | 'error';
|
|
10
|
+
variant?: 'info' | 'success' | 'warning' | 'error' | 'promo';
|
|
11
11
|
dismissible?: boolean;
|
|
12
12
|
open?: boolean;
|
|
13
13
|
onOpenChange?: (open: boolean) => void;
|