@alfadocs/ui-kit 0.47.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/{agenda-card-CFyWSX7Z.js → agenda-card-BaSfVfrL.js} +25 -29
- package/dist/_chunks/{agenda-tray-Dyj9ChHC.js → agenda-tray-DQayYmQ0.js} +50 -67
- package/dist/_chunks/ai-consent-banner-F2md5JD3.js +169 -0
- package/dist/_chunks/ai-tools-rail-CYLWrRmm.js +280 -0
- package/dist/_chunks/{alert-ywPR59NE.js → alert-CUTxnym2.js} +56 -35
- package/dist/_chunks/{alia-sidebar-CVIPrdc9.js → alia-sidebar-DlvyXgVC.js} +3 -2
- package/dist/_chunks/anamnesis-card-CmkBVAln.js +156 -0
- package/dist/_chunks/antenatal-schedule-timeline-Dg0m0yFl.js +412 -0
- package/dist/_chunks/appointment-tray-BwDHhWWC.js +419 -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/{bmi-calculator-CQqXTVNL.js → bmi-calculator-DdylQzT6.js} +2 -2
- package/dist/_chunks/{booking-DlDVuWMd.js → booking-DljH0JkS.js} +294 -306
- package/dist/_chunks/{calculator-dialog-D-nfvteH.js → calculator-dialog-CFk4I91b.js} +2 -2
- package/dist/_chunks/calendar-days-C4BmpCZg.js +23 -0
- package/dist/_chunks/{calendar-YHFknAGv.js → calendar-oYWOCrnf.js} +195 -210
- package/dist/_chunks/care-plan-card-QmNpGggC.js +252 -0
- package/dist/_chunks/care-plan-entry-card-Cnra7vUc.js +318 -0
- package/dist/_chunks/{chat-message-B5JpFj0F.js → chat-message-Dm8U2RY1.js} +36 -35
- package/dist/_chunks/circle-arrow-up-CC_85SuH.js +16 -0
- package/dist/_chunks/clinical-note-card-BYo437dU.js +333 -0
- package/dist/_chunks/{contact-profile-card-DHyuAPXM.js → contact-profile-card-DvvVfAA2.js} +102 -115
- 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/{dialog-BTpZV6It.js → dialog-DMGnSelc.js} +55 -55
- 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/entity-card-COhmqHly.js +69 -0
- 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/{insert-result-C5ABnzDl.js → insert-result-DNdi_JYW.js} +140 -168
- package/dist/_chunks/is-safe-url-DkETxeHz.js +7 -0
- 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/languages-DsVf_WzT.js +19 -0
- package/dist/_chunks/layers-pzGcbLPj.js +34 -0
- package/dist/_chunks/{marketplace-app-shell-Gfsf78ge.js → marketplace-app-shell-UKSLx9K_.js} +3 -3
- package/dist/_chunks/{message-card-DSPw5ghw.js → message-card-Dvl1TgaN.js} +15 -19
- package/dist/_chunks/{message-tray-hSQff9u4.js → message-tray-Dl6GQaaV.js} +2 -2
- package/dist/_chunks/{nl-D9kHCmp3.js → nl-cBxEX2QU.js} +2 -2
- package/dist/_chunks/operator-hero-CM8949Hd.js +198 -0
- 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/patient-summary-card-BnTqxcTr.js +443 -0
- package/dist/_chunks/{payment-form-BNTx4876.js → payment-form-xmeCkxas.js} +2 -2
- package/dist/_chunks/payment-request-card-B_lyobd0.js +478 -0
- package/dist/_chunks/{pdf-viewer-CWEXTlwq.js → pdf-viewer-q1D3Uion.js} +4 -4
- package/dist/_chunks/periodontal-chart-card-BYs9hax1.js +455 -0
- package/dist/_chunks/phone-Bi5yUm4I.js +20 -0
- package/dist/_chunks/{pl-B3Smqpkr.js → pl-DtS08ioY.js} +3 -3
- package/dist/_chunks/{practice-results-DDi-kvaD.js → practice-results-Cq1y8JFD.js} +4 -3
- 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/scan-line-lGioFwLC.js +18 -0
- package/dist/_chunks/shield-check-BjCGH_Sr.js +21 -0
- package/dist/_chunks/{sidebar-_vJXI9rB.js → sidebar-h78cTNLh.js} +440 -338
- package/dist/_chunks/{sign-document-BCyLpFHJ.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/{transaction-chip-B8ujzowA.js → transaction-chip-BZCa6XDn.js} +8 -6
- package/dist/_chunks/{unit-converter-u3CwNDpP.js → unit-converter-jWp3Z85y.js} +2 -2
- package/dist/_chunks/user-cog-BS_qc8nA.js +24 -0
- package/dist/_chunks/video-BAeICxCT.js +21 -0
- package/dist/_chunks/warning-stack-CXfoAT-_.js +220 -0
- package/dist/_chunks/{workflow-map-Djn1QMJc.js → workflow-map-DzX_LI4y.js} +139 -157
- package/dist/_chunks/{zh-CN-De4zwEhx.js → zh-CN-CgVJZEzz.js} +3 -3
- package/dist/agent-catalog.json +367 -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/entity-card/entity-card.d.ts +40 -0
- package/dist/components/_shared/entity-card/index.d.ts +3 -0
- package/dist/components/_shared/index.d.ts +5 -0
- package/dist/components/_shared/is-safe-url.d.ts +13 -0
- package/dist/components/_shared/obstetrics.d.ts +138 -0
- package/dist/components/address-autocomplete/index.js +1 -1
- package/dist/components/agenda-card/agenda-card.d.ts +1 -2
- package/dist/components/agenda-card/index.d.ts +2 -1
- package/dist/components/agenda-card/index.js +6 -5
- package/dist/components/agenda-tray/index.js +1 -1
- package/dist/components/ai-consent-banner/ai-consent-banner.agent.d.ts +4 -0
- package/dist/components/ai-consent-banner/ai-consent-banner.d.ts +45 -0
- package/dist/components/ai-consent-banner/index.d.ts +4 -0
- package/dist/components/ai-consent-banner/index.js +6 -0
- package/dist/components/ai-tools-rail/ai-tools-rail.agent.d.ts +4 -0
- package/dist/components/ai-tools-rail/ai-tools-rail.d.ts +60 -0
- package/dist/components/ai-tools-rail/index.d.ts +4 -0
- package/dist/components/ai-tools-rail/index.js +6 -0
- package/dist/components/alert/alert.d.ts +2 -2
- package/dist/components/alert/index.js +1 -1
- package/dist/components/anamnesis-card/anamnesis-card.d.ts +68 -0
- package/dist/components/anamnesis-card/index.d.ts +3 -0
- package/dist/components/anamnesis-card/index.js +5 -0
- package/dist/components/appointment-card/appointment-card.agent.d.ts +3 -0
- package/dist/components/appointment-card/appointment-card.d.ts +93 -0
- package/dist/components/appointment-card/appointment-tray.agent.d.ts +4 -0
- package/dist/components/appointment-card/appointment-tray.d.ts +48 -0
- package/dist/components/appointment-card/index.d.ts +8 -0
- package/dist/components/appointment-card/index.js +10 -0
- package/dist/components/audio-recorder/index.js +1 -1
- package/dist/components/badge/badge.d.ts +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/bmi-calculator/index.js +1 -1
- package/dist/components/booking/index.js +1 -1
- package/dist/components/calculator-dialog/index.js +1 -1
- package/dist/components/calendar/index.js +1 -1
- package/dist/components/card/card.d.ts +1 -1
- package/dist/components/care-plan-card/care-plan-card.agent.d.ts +4 -0
- package/dist/components/care-plan-card/care-plan-card.d.ts +102 -0
- package/dist/components/care-plan-card/index.d.ts +4 -0
- package/dist/components/care-plan-card/index.js +6 -0
- package/dist/components/care-plan-entry-card/care-plan-entry-card.agent.d.ts +4 -0
- package/dist/components/care-plan-entry-card/care-plan-entry-card.d.ts +110 -0
- package/dist/components/care-plan-entry-card/index.d.ts +4 -0
- package/dist/components/care-plan-entry-card/index.js +6 -0
- package/dist/components/chat-message/chat-message.d.ts +7 -0
- package/dist/components/chat-message/index.js +1 -1
- package/dist/components/clinical-note-card/clinical-note-card.agent.d.ts +4 -0
- package/dist/components/clinical-note-card/clinical-note-card.d.ts +98 -0
- package/dist/components/clinical-note-card/index.d.ts +4 -0
- package/dist/components/clinical-note-card/index.js +6 -0
- package/dist/components/contact-profile-card/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/dialog/dialog.d.ts +7 -0
- package/dist/components/dialog/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 +14 -0
- package/dist/components/message-card/index.js +5 -4
- package/dist/components/message-card/message-card.d.ts +1 -2
- package/dist/components/message-tray/index.js +1 -1
- package/dist/components/operator-hero/index.js +1 -1
- package/dist/components/operator-hero/operator-hero.d.ts +9 -0
- package/dist/components/patient-search/index.js +1 -1
- package/dist/components/patient-summary-card/index.d.ts +4 -0
- package/dist/components/patient-summary-card/index.js +6 -0
- package/dist/components/patient-summary-card/patient-summary-card.agent.d.ts +4 -0
- package/dist/components/patient-summary-card/patient-summary-card.d.ts +120 -0
- package/dist/components/payment-card/index.d.ts +7 -0
- package/dist/components/payment-card/index.js +8 -0
- package/dist/components/payment-card/payment-card.agent.d.ts +4 -0
- package/dist/components/payment-card/payment-card.d.ts +71 -0
- package/dist/components/payment-card/payment-request-card.agent.d.ts +4 -0
- package/dist/components/payment-card/payment-request-card.d.ts +43 -0
- package/dist/components/payment-form/index.js +1 -1
- package/dist/components/pdf-viewer/index.js +1 -1
- package/dist/components/periodontal-chart-card/index.d.ts +4 -0
- package/dist/components/periodontal-chart-card/index.js +7 -0
- package/dist/components/periodontal-chart-card/periodontal-chart-card.agent.d.ts +4 -0
- package/dist/components/periodontal-chart-card/periodontal-chart-card.d.ts +74 -0
- 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/public-header/public-header.d.ts +1 -1
- 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/stat/stat.d.ts +1 -1
- package/dist/components/transaction-chip/index.js +1 -1
- package/dist/components/unit-converter/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 +561 -1
- package/dist/i18n/locales/ar.js +560 -2
- package/dist/i18n/locales/de.d.ts +561 -1
- package/dist/i18n/locales/de.js +560 -2
- package/dist/i18n/locales/el.d.ts +561 -1
- package/dist/i18n/locales/el.js +560 -2
- package/dist/i18n/locales/en.d.ts +561 -1
- package/dist/i18n/locales/en.js +560 -2
- package/dist/i18n/locales/es.d.ts +561 -1
- package/dist/i18n/locales/es.js +560 -2
- package/dist/i18n/locales/fr.d.ts +561 -1
- package/dist/i18n/locales/fr.js +560 -2
- package/dist/i18n/locales/hi.d.ts +561 -1
- package/dist/i18n/locales/hi.js +560 -2
- package/dist/i18n/locales/it.d.ts +561 -1
- package/dist/i18n/locales/it.js +560 -2
- package/dist/i18n/locales/ja.d.ts +561 -1
- package/dist/i18n/locales/ja.js +560 -2
- package/dist/i18n/locales/nl.d.ts +561 -1
- package/dist/i18n/locales/nl.js +560 -2
- package/dist/i18n/locales/pl.d.ts +561 -1
- package/dist/i18n/locales/pl.js +560 -2
- package/dist/i18n/locales/pt.d.ts +561 -1
- package/dist/i18n/locales/pt.js +560 -2
- package/dist/i18n/locales/ro.d.ts +561 -1
- package/dist/i18n/locales/ro.js +560 -2
- package/dist/i18n/locales/ru.d.ts +561 -1
- package/dist/i18n/locales/ru.js +560 -2
- package/dist/i18n/locales/sq.d.ts +561 -1
- package/dist/i18n/locales/sq.js +560 -2
- package/dist/i18n/locales/sv.d.ts +561 -1
- package/dist/i18n/locales/sv.js +560 -2
- package/dist/i18n/locales/tr.d.ts +561 -1
- package/dist/i18n/locales/tr.js +560 -2
- package/dist/i18n/locales/zh.d.ts +561 -1
- package/dist/i18n/locales/zh.js +560 -2
- package/dist/index.js +663 -600
- package/dist/locales/ar.json +562 -2
- package/dist/locales/de.json +562 -2
- package/dist/locales/el.json +562 -2
- package/dist/locales/en.json +562 -2
- package/dist/locales/es.json +562 -2
- package/dist/locales/fr.json +562 -2
- package/dist/locales/hi.json +562 -2
- package/dist/locales/it.json +562 -2
- package/dist/locales/ja.json +562 -2
- package/dist/locales/nl.json +562 -2
- package/dist/locales/pl.json +562 -2
- package/dist/locales/pt.json +562 -2
- package/dist/locales/ro.json +562 -2
- package/dist/locales/ru.json +562 -2
- package/dist/locales/sq.json +562 -2
- package/dist/locales/sv.json +562 -2
- package/dist/locales/tr.json +562 -2
- package/dist/locales/zh.json +562 -2
- package/dist/patterns/alia-assistant/alia-types.d.ts +15 -0
- package/dist/patterns/alia-assistant/index.js +1 -1
- 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 +58 -1
- package/dist/_chunks/cycle-calculator-KxA8dqDf.js +0 -211
- package/dist/_chunks/due-date-calculator-mFxpHLml.js +0 -216
- package/dist/_chunks/gestation-mWF4AXea.js +0 -50
- package/dist/_chunks/gestational-age-calculator-gWI_uRA1.js +0 -203
- package/dist/_chunks/operator-hero-7LiiP7zi.js +0 -171
- package/dist/_chunks/pregnancy-weight-gain-BtEHaSqy.js +0 -246
- package/dist/_chunks/shield-check-C73ma9Cs.js +0 -36
- package/dist/_chunks/subDays-Dv7q9S7u.js +0 -8
- package/dist/_chunks/warning-stack-DNR3-IbP.js +0 -180
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
import { jsxs as t, jsx as l } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as k, useState as p, useMemo as T, useEffect as S } from "react";
|
|
3
|
+
import { c as V } from "./index-D2ZczOXr.js";
|
|
4
|
+
import { useTranslation as j } from "react-i18next";
|
|
5
|
+
import { F as f } from "./form-field-BOm9hK35.js";
|
|
6
|
+
import { N as L } from "./number-input-Dj5L3pXK.js";
|
|
7
|
+
import { D as M } from "./date-time-picker-H-3Pwqlb.js";
|
|
8
|
+
import { C as _ } from "./card-DPmk26CL.js";
|
|
9
|
+
import { B as A } from "./badge-zsf5i5bH.js";
|
|
10
|
+
import { I as C } from "./insert-result-DNdi_JYW.js";
|
|
11
|
+
const O = 1e3 * 60 * 60, z = 35;
|
|
12
|
+
function G(D) {
|
|
13
|
+
const { hcg1: r, hcg2: s, date1: d, date2: o } = D;
|
|
14
|
+
if (!(r > 0) || !(s > 0)) return null;
|
|
15
|
+
const i = (o.getTime() - d.getTime()) / O;
|
|
16
|
+
if (!(i > 0)) return null;
|
|
17
|
+
const a = s / r, v = (a - 1) * 100, c = (a ** (48 / i) - 1) * 100, x = a > 1 ? i * Math.LN2 / Math.log(a) : null, N = a <= 1 ? "plateau-falling" : c >= z ? "rising-normal" : "rising-slow";
|
|
18
|
+
return {
|
|
19
|
+
intervalHours: i,
|
|
20
|
+
ratio: a,
|
|
21
|
+
percentRise: v,
|
|
22
|
+
twoDayRisePercent: c,
|
|
23
|
+
doublingTimeHours: x,
|
|
24
|
+
trend: N
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
const K = V("ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", {
|
|
28
|
+
variants: {
|
|
29
|
+
width: { full: "ds:w-full", auto: "ds:inline-flex" }
|
|
30
|
+
},
|
|
31
|
+
defaultVariants: { width: "full" }
|
|
32
|
+
}), U = {
|
|
33
|
+
"rising-normal": "success",
|
|
34
|
+
"rising-slow": "warning",
|
|
35
|
+
"plateau-falling": "error"
|
|
36
|
+
}, q = {
|
|
37
|
+
"rising-normal": "--success",
|
|
38
|
+
"rising-slow": "--warning-readable",
|
|
39
|
+
"plateau-falling": "--destructive"
|
|
40
|
+
}, J = k(
|
|
41
|
+
({
|
|
42
|
+
defaultDate1: D,
|
|
43
|
+
defaultDate2: r,
|
|
44
|
+
onResultChange: s,
|
|
45
|
+
onInsert: d,
|
|
46
|
+
insertVariant: o = "insert",
|
|
47
|
+
onCopy: i,
|
|
48
|
+
onError: a,
|
|
49
|
+
insertBrand: v,
|
|
50
|
+
id: c,
|
|
51
|
+
width: x,
|
|
52
|
+
className: N
|
|
53
|
+
}, I) => {
|
|
54
|
+
const { t: e, i18n: w } = j(), [g, B] = p(null), [u, F] = p(D), [m, P] = p(null), [h, R] = p(r), H = T(() => /* @__PURE__ */ new Date(), []), n = T(() => g === null || m === null || !u || !h ? null : G({ hcg1: g, date1: u, hcg2: m, date2: h }), [g, u, m, h]);
|
|
55
|
+
S(() => {
|
|
56
|
+
s == null || s(n);
|
|
57
|
+
}, [n, s]);
|
|
58
|
+
const $ = T(
|
|
59
|
+
() => new Intl.NumberFormat(w.language, { maximumFractionDigits: 0 }),
|
|
60
|
+
[w.language]
|
|
61
|
+
), y = (b) => b.doublingTimeHours === null ? "—" : e("hcgDoubling.hoursValue", {
|
|
62
|
+
hours: $.format(b.doublingTimeHours)
|
|
63
|
+
}), E = (b) => e("hcgDoubling.percentValue", { value: $.format(b.twoDayRisePercent) });
|
|
64
|
+
return /* @__PURE__ */ t(
|
|
65
|
+
"div",
|
|
66
|
+
{
|
|
67
|
+
ref: I,
|
|
68
|
+
"data-component": "hcg-doubling",
|
|
69
|
+
"data-component-id": c,
|
|
70
|
+
className: K({ width: x, className: N }),
|
|
71
|
+
children: [
|
|
72
|
+
/* @__PURE__ */ t("div", { className: "ds:grid ds:grid-cols-1 ds:gap-[var(--spacing-md)] ds:sm:grid-cols-2", children: [
|
|
73
|
+
/* @__PURE__ */ l(
|
|
74
|
+
f,
|
|
75
|
+
{
|
|
76
|
+
label: `${e("hcgDoubling.hcg1")} (${e("hcgDoubling.units")})`,
|
|
77
|
+
children: /* @__PURE__ */ l(
|
|
78
|
+
L,
|
|
79
|
+
{
|
|
80
|
+
mode: "decimal",
|
|
81
|
+
min: 0,
|
|
82
|
+
value: g,
|
|
83
|
+
onChange: B
|
|
84
|
+
}
|
|
85
|
+
)
|
|
86
|
+
}
|
|
87
|
+
),
|
|
88
|
+
/* @__PURE__ */ l(f, { label: e("hcgDoubling.date1"), children: /* @__PURE__ */ l(M, { value: u, onChange: F, maxDate: H }) }),
|
|
89
|
+
/* @__PURE__ */ l(
|
|
90
|
+
f,
|
|
91
|
+
{
|
|
92
|
+
label: `${e("hcgDoubling.hcg2")} (${e("hcgDoubling.units")})`,
|
|
93
|
+
children: /* @__PURE__ */ l(
|
|
94
|
+
L,
|
|
95
|
+
{
|
|
96
|
+
mode: "decimal",
|
|
97
|
+
min: 0,
|
|
98
|
+
value: m,
|
|
99
|
+
onChange: P
|
|
100
|
+
}
|
|
101
|
+
)
|
|
102
|
+
}
|
|
103
|
+
),
|
|
104
|
+
/* @__PURE__ */ l(f, { label: e("hcgDoubling.date2"), children: /* @__PURE__ */ l(M, { value: h, onChange: R, maxDate: H }) })
|
|
105
|
+
] }),
|
|
106
|
+
/* @__PURE__ */ l("p", { className: "ds:sr-only", role: "status", "aria-live": "polite", children: n ? `${e("hcgDoubling.doublingLabel")}: ${y(n)}. ${e(
|
|
107
|
+
`hcgDoubling.trend.${n.trend}`
|
|
108
|
+
)}.` : "" }),
|
|
109
|
+
n ? /* @__PURE__ */ l(_, { variant: "elevated", children: /* @__PURE__ */ t(_.Body, { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: [
|
|
110
|
+
/* @__PURE__ */ t("dl", { className: "ds:grid ds:grid-cols-1 ds:gap-[var(--spacing-md)] ds:sm:grid-cols-3", children: [
|
|
111
|
+
/* @__PURE__ */ t("div", { className: "ds:flex ds:flex-col ds:items-start ds:gap-[var(--spacing-xs)]", children: [
|
|
112
|
+
/* @__PURE__ */ l("dt", { className: "type-label ds:text-muted-foreground", children: e("hcgDoubling.doublingLabel") }),
|
|
113
|
+
/* @__PURE__ */ l("dd", { className: "type-metric ds:text-foreground", children: y(n) })
|
|
114
|
+
] }),
|
|
115
|
+
/* @__PURE__ */ t("div", { className: "ds:flex ds:flex-col ds:items-start ds:gap-[var(--spacing-xs)]", children: [
|
|
116
|
+
/* @__PURE__ */ l("dt", { className: "type-label ds:text-muted-foreground", children: e("hcgDoubling.riseLabel") }),
|
|
117
|
+
/* @__PURE__ */ l("dd", { className: "type-body ds:text-foreground", children: E(n) })
|
|
118
|
+
] }),
|
|
119
|
+
/* @__PURE__ */ t("div", { className: "ds:flex ds:flex-col ds:items-end ds:gap-[var(--spacing-xs)] ds:text-end", children: [
|
|
120
|
+
/* @__PURE__ */ l("dt", { className: "type-label ds:text-muted-foreground", children: e("hcgDoubling.trendLabel") }),
|
|
121
|
+
/* @__PURE__ */ l("dd", { children: /* @__PURE__ */ l(A, { variant: U[n.trend], size: "lg", children: e(`hcgDoubling.trend.${n.trend}`) }) })
|
|
122
|
+
] })
|
|
123
|
+
] }),
|
|
124
|
+
/* @__PURE__ */ l("p", { className: "type-body-sm ds:text-muted-foreground", children: e("hcgDoubling.disclaimer") }),
|
|
125
|
+
o === "copy" || d ? /* @__PURE__ */ l(
|
|
126
|
+
C,
|
|
127
|
+
{
|
|
128
|
+
onInsert: d,
|
|
129
|
+
variant: o,
|
|
130
|
+
onCopy: i,
|
|
131
|
+
onError: a,
|
|
132
|
+
card: {
|
|
133
|
+
title: e("insert.title.hcg"),
|
|
134
|
+
icon: "activity",
|
|
135
|
+
highlight: e(`hcgDoubling.trend.${n.trend}`),
|
|
136
|
+
highlightToken: q[n.trend],
|
|
137
|
+
brand: v,
|
|
138
|
+
fields: [
|
|
139
|
+
{
|
|
140
|
+
icon: "clock",
|
|
141
|
+
label: e("hcgDoubling.doublingLabel"),
|
|
142
|
+
value: y(n)
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
icon: "trending-up",
|
|
146
|
+
label: e("hcgDoubling.riseLabel"),
|
|
147
|
+
value: E(n)
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
icon: "tag",
|
|
151
|
+
label: e("hcgDoubling.trendLabel"),
|
|
152
|
+
value: e(`hcgDoubling.trend.${n.trend}`)
|
|
153
|
+
}
|
|
154
|
+
]
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
) : null
|
|
158
|
+
] }) }) : /* @__PURE__ */ l("p", { className: "type-body ds:text-muted-foreground", children: e("hcgDoubling.empty") })
|
|
159
|
+
]
|
|
160
|
+
}
|
|
161
|
+
);
|
|
162
|
+
}
|
|
163
|
+
);
|
|
164
|
+
J.displayName = "HcgDoubling";
|
|
165
|
+
export {
|
|
166
|
+
J as H,
|
|
167
|
+
z as M,
|
|
168
|
+
G as a
|
|
169
|
+
};
|
|
170
|
+
//# sourceMappingURL=hcg-doubling-DAnpbale.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as o, q as s, v as r, w as u } from "./date-picker-variants-
|
|
1
|
+
import { r as o, q as s, v as r, w as u } from "./date-picker-variants-CXEAx3O_.js";
|
|
2
2
|
const d = {
|
|
3
3
|
locale: {
|
|
4
4
|
1: "१",
|
|
@@ -430,4 +430,4 @@ const y = {
|
|
|
430
430
|
export {
|
|
431
431
|
H as hi
|
|
432
432
|
};
|
|
433
|
-
//# sourceMappingURL=hi-
|
|
433
|
+
//# sourceMappingURL=hi-DGByrKby.js.map
|