@alfadocs/ui-kit 1.114.0 → 1.116.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/accessible-target-Bs9ELM3l.js +6 -0
- package/dist/_chunks/{actions-cell-renderer-BVn3vDTg.js → actions-cell-renderer-DzHxDyI7.js} +3 -3
- package/dist/_chunks/{address-fields-D5Ije0S2.js → address-fields-BFVCtfP2.js} +3 -3
- package/dist/_chunks/{ai-permission-notice-BkgcGmu8.js → ai-permission-notice-C-xR2_iS.js} +2 -2
- package/dist/_chunks/{alia-sidebar-CKkg3gc8.js → alia-sidebar-BBxbMRmX.js} +2 -2
- package/dist/_chunks/{anamnesis-summary-rows-DaS-j8Jd.js → anamnesis-summary-rows-gEXqU5i5.js} +8 -8
- package/dist/_chunks/{antenatal-schedule-timeline-DmlXxevC.js → antenatal-schedule-timeline-va9zx7tJ.js} +11 -11
- package/dist/_chunks/{appointment-card-FKOnH1uJ.js → appointment-card-BMZoXaGx.js} +4 -4
- package/dist/_chunks/{appointment-peek-DWfcpoGy.js → appointment-peek-B1CCv-7J.js} +2 -2
- package/dist/_chunks/{appointment-timeline-eOi-y8m3.js → appointment-timeline-0k4LxODn.js} +4 -4
- package/dist/_chunks/{appointment-tray-C6oBvsG5.js → appointment-tray-DIxpgIXM.js} +2 -2
- package/dist/_chunks/{ar-C4YQVTH6.js → ar-BFvUBJ_g.js} +10 -10
- package/dist/_chunks/arrow-down-left-DECv-dJt.js +15 -0
- package/dist/_chunks/{balance-badge-cell-BAZynD--.js → balance-badge-cell-L7bD0Nsh.js} +28 -27
- package/dist/_chunks/bill-line-table-WEIRDcv6.js +1563 -0
- package/dist/_chunks/{bmi-calculator-Ba4yoR31.js → bmi-calculator-BjUfXqcY.js} +2 -2
- package/dist/_chunks/buildMatchPatternFn-jbaE1-W0.js +68 -0
- package/dist/_chunks/{button-group-CUnNnt8a.js → button-group-BvU9vRnX.js} +2 -2
- package/dist/_chunks/{calculator-dialog-D4TyJwqy.js → calculator-dialog-BGX5XQCM.js} +2 -2
- package/dist/_chunks/{calendar-appointment-editor-dialog-iyh9QqNw.js → calendar-appointment-editor-dialog-DqZMb4yd.js} +527 -539
- package/dist/_chunks/{care-plan-card-DMjlYlFc.js → care-plan-card-CfV8jiF0.js} +3 -3
- package/dist/_chunks/{care-plan-entry-card-3hguBW45.js → care-plan-entry-card-Bt01kyTl.js} +4 -4
- package/dist/_chunks/{chart-bddVIElM.js → chart-BSx8cfMm.js} +2 -2
- package/dist/_chunks/{chat-container-baxzy8k8.js → chat-container-B83b4hut.js} +2 -2
- package/dist/_chunks/checkbox-DV4sNDeB.js +282 -0
- package/dist/_chunks/{checkbox-group-eGdv9fZc.js → checkbox-group-EfinQS1h.js} +2 -2
- package/dist/_chunks/chevrons-up-down-CgiVAHb7.js +15 -0
- package/dist/_chunks/circle-off-DuT9pVy2.js +16 -0
- package/dist/_chunks/combobox-BBCVQS-S.js +935 -0
- package/dist/_chunks/compact-editor-fields-6sTWRLtf.js +21 -0
- package/dist/_chunks/{contact-profile-card-DMXWBBkU.js → contact-profile-card-BRCHbQ3-.js} +2 -2
- package/dist/_chunks/{country-select-CUuGOAoZ.js → country-select-C2GdvRtS.js} +2 -2
- package/dist/_chunks/{cycle-calculator-Dd-XbKmZ.js → cycle-calculator-Brd0PP4U.js} +6 -6
- package/dist/_chunks/{dashboard-grid-DrOkTtya.js → dashboard-grid-3aidD-IQ.js} +2 -2
- package/dist/_chunks/data-grid-ByhrYGVw.js +9814 -0
- package/dist/_chunks/data-grid-tabs-D9Y4DeeH.js +365 -0
- package/dist/_chunks/data-table-B47iw2CO.js +1694 -0
- package/dist/_chunks/data-table-tabs-NYLhD8_Z.js +242 -0
- package/dist/_chunks/date-locale-OG-MupVD.js +83 -0
- package/dist/_chunks/{date-picker-CdhXlgVI.js → date-picker-DBVTj6lO.js} +21 -20
- package/dist/_chunks/{date-picker-variants-Dt6UbonG.js → date-picker-variants-J1EeAhIH.js} +601 -678
- package/dist/_chunks/date-range-panel-B-DUtfw3.js +62 -0
- package/dist/_chunks/{date-range-picker-DCADIR8o.js → date-range-picker-PTRpDkXT.js} +72 -70
- package/dist/_chunks/{date-time-picker-CT2bC7-A.js → date-time-picker-CJnqiQoT.js} +22 -21
- package/dist/_chunks/{de-B1B3PIgY.js → de-i9wbjGPc.js} +2 -2
- package/dist/_chunks/default-tabs-BQcSqcNG.js +2250 -0
- package/dist/_chunks/dialog-CIUn5oLb.js +348 -0
- package/dist/_chunks/{document-preview-WvJKHJOP.js → document-preview-B_JGHsEW.js} +2 -2
- package/dist/_chunks/{dropdown-menu-CqxBthww.js → dropdown-menu-Dmbak7q6.js} +320 -248
- package/dist/_chunks/{due-date-calculator-Dl6SyMHO.js → due-date-calculator-DzIQXEX5.js} +7 -7
- package/dist/_chunks/{editable-currency-cell-renderer-BUdFMh67.js → editable-currency-cell-renderer-p-Q1UkZS.js} +3 -3
- package/dist/_chunks/{el-iLqGpapg.js → el-Cm-rWthb.js} +20 -20
- package/dist/_chunks/{en-GB-CxPRQbD6.js → en-GB-BHn82gW8.js} +11 -10
- package/dist/_chunks/en-US-C4QKhzhA.js +46 -0
- package/dist/_chunks/{es-Bg1oqwDs.js → es-B_6Z19UA.js} +4 -4
- package/dist/_chunks/export-files-BByoK9Cg.js +248 -0
- package/dist/_chunks/{face-scheme-DlcQaQVR.js → face-scheme-CEjJUnNe.js} +19 -18
- package/dist/_chunks/{fetal-weight-DmZzMRzB.js → fetal-weight-CJTlfh_k.js} +2 -2
- package/dist/_chunks/{file-manager-LG7B_UHB.js → file-manager-DEe51ZDe.js} +5 -5
- package/dist/_chunks/format-price-CIX0YJZn.js +179 -0
- package/dist/_chunks/format-ql5WTsYT.js +846 -0
- package/dist/_chunks/{fr-DpGxyOGI.js → fr-gTba51QO.js} +7 -7
- package/dist/_chunks/funnel-DpPV3Qkd.js +20 -0
- package/dist/_chunks/{gestational-age-calculator-DmzYdW5e.js → gestational-age-calculator-60y1RyQL.js} +7 -7
- package/dist/_chunks/grid-context-jn9y8tNE.js +46 -0
- package/dist/_chunks/{hcg-doubling-Tr72PetS.js → hcg-doubling-BUZQkSYC.js} +7 -6
- package/dist/_chunks/{header-settings-Df9q1uHt.js → header-settings-DNgvO8fS.js} +2 -2
- package/dist/_chunks/{heatmap-CNxCDl0D.js → heatmap-tn1WxoMT.js} +4 -4
- package/dist/_chunks/{help-me-write-templates-CWxgjDZl.js → help-me-write-templates-C28E_rOt.js} +2 -2
- package/dist/_chunks/{hi-3Dtsksrw.js → hi-BIHq9ncx.js} +10 -10
- package/dist/_chunks/highlighter-DSkckT2Q.js +15 -0
- package/dist/_chunks/icon-button-group-Ca2VkXy5.js +442 -0
- package/dist/_chunks/{index-CJE9uQmb.js → index-Bze5jCG_.js} +2 -1
- package/dist/_chunks/{isSameWeek-DyVftHWi.js → isSameWeek-CZOtDcsd.js} +2 -2
- package/dist/_chunks/{it-Cp0CA13d.js → it-DaCPWJ9Y.js} +11 -11
- package/dist/_chunks/{ja-9FOyR1lb.js → ja-BRCpkD95.js} +26 -26
- package/dist/_chunks/{kit-extensions-DZJRmDI6.js → kit-extensions-BFfLg7c-.js} +7 -7
- package/dist/_chunks/link-cell-renderer-D-Io828l.js +800 -0
- package/dist/_chunks/{login-dev-card-D7orCfJT.js → login-dev-card-CPndtWdz.js} +2 -2
- package/dist/_chunks/{marketplace-app-shell-CPNVBVLH.js → marketplace-app-shell-CBHNg8x-.js} +5 -5
- package/dist/_chunks/match-BATShpSX.js +336 -0
- package/dist/_chunks/money-OE6_oDPH.js +138 -0
- package/dist/_chunks/{muscle-scheme-BkmDUTmk.js → muscle-scheme-7UsRsCHP.js} +2 -2
- package/dist/_chunks/{nl-sfx-zJgR.js → nl-5tAwYo00.js} +6 -6
- package/dist/_chunks/normalizeDates-BBNNIR-v.js +36 -0
- package/dist/_chunks/{notes-panel-DXMTObBv.js → notes-panel-DexbfrFo.js} +3 -3
- package/dist/_chunks/number-input-DUSvP7Dq.js +625 -0
- package/dist/_chunks/{optical-prescription-CvbN8yD2.js → optical-prescription-Da_r8pMr.js} +2 -2
- package/dist/_chunks/{parse-B0s7bY4d.js → parse-BLBWPIgE.js} +63 -61
- package/dist/_chunks/{parseISO-DZZ5a-zK.js → parseISO-Dl4T9peU.js} +2 -2
- package/dist/_chunks/parts-CtcTW1PN.js +869 -0
- package/dist/_chunks/{patient-details-DdtXBNjt.js → patient-details-PJ0Y__7t.js} +2 -2
- package/dist/_chunks/{patient-field-row-D9rb-QJH.js → patient-field-row-0QP8KCVp.js} +7 -7
- package/dist/_chunks/{patient-search-DDRDCjZi.js → patient-search-Bdx_Ob3y.js} +2 -2
- package/dist/_chunks/{patient-summary-card-CGHz-Bvm.js → patient-summary-card-BOfXDP8a.js} +4 -4
- package/dist/_chunks/{payment-request-card-BmV2pLoM.js → payment-request-card-_04afZEx.js} +14 -13
- package/dist/_chunks/{periodontal-diagnosis-xheWfi4g.js → periodontal-diagnosis-DnZuZD14.js} +2 -2
- package/dist/_chunks/{permission-matrix-BJ6sg3Zp.js → permission-matrix-BXmhICzN.js} +3 -3
- package/dist/_chunks/{pl-BLh7KO-s.js → pl-mLYbfByR.js} +7 -7
- package/dist/_chunks/{practice-results-BlxfBx-D.js → practice-results-CrBjScXX.js} +3 -3
- package/dist/_chunks/{pregnancy-dating-BvorzHrd.js → pregnancy-dating-Bg_VUPwl.js} +8 -8
- package/dist/_chunks/{pregnancy-weight-gain-DQoOM8QV.js → pregnancy-weight-gain-B-eXFdmq.js} +2 -2
- package/dist/_chunks/privacy-mask-BlJK51MD.js +78 -0
- package/dist/_chunks/privacy-mask-text-B8YfzB7L.js +7 -0
- package/dist/_chunks/{province-select-cVOlwEc5.js → province-select-CTM8A9SM.js} +2 -2
- package/dist/_chunks/{pt-CPKOrOLj.js → pt-CgaqtlD9.js} +6 -6
- package/dist/_chunks/{radiograph-panel.agent-CXah49KM.js → radiograph-panel.agent-9jwXlOXB.js} +4 -4
- package/dist/_chunks/{registration-form-Lw9T7IXr.js → registration-form-DW-0X7S4.js} +2 -2
- package/dist/_chunks/{reserved.agent-D2jwJPac.js → reserved.agent-C1zRHaya.js} +12 -12
- package/dist/_chunks/{rich-text-editor-BLS2cK-u.js → rich-text-editor-r80Zw8ll.js} +14 -13
- package/dist/_chunks/{ro-Dc-oNqbF.js → ro-CpDg1-8v.js} +2 -2
- package/dist/_chunks/row-actions-Df7TJbNR.js +213 -0
- package/dist/_chunks/{ru-BtNpDZRR.js → ru-B7VMyjud.js} +9 -9
- package/dist/_chunks/saved-view-tabs-DLWm88Eq.js +932 -0
- package/dist/_chunks/{send-registration-link-form-DfbTjrEK.js → send-registration-link-form-DWxWa_cJ.js} +5 -5
- package/dist/_chunks/{sidebar-2VsPlNkZ.js → sidebar-D5DFYN5K.js} +326 -335
- package/dist/_chunks/{signature-request-BnTihryS.js → signature-request-CgvjLic3.js} +3 -3
- package/dist/_chunks/{slot-grid-BhjaLJ0o.js → slot-grid-b4eZXokb.js} +3 -3
- package/dist/_chunks/{sq-D4c7olaV.js → sq-B0Ree_9P.js} +2 -2
- package/dist/_chunks/subDays-Bsoy023P.js +8 -0
- package/dist/_chunks/{sv-Bf_dHPvh.js → sv-D9fP66O7.js} +4 -4
- package/dist/_chunks/{tab-bar-C_pggqVr.js → tab-bar-DTn8pHqH.js} +2 -2
- package/dist/_chunks/{tabs-CXYjr_8O.js → tabs-CsmgkiG6.js} +2 -2
- package/dist/_chunks/{tag-DOZGz0fT.js → tag-BNlcEJfE.js} +70 -67
- package/dist/_chunks/{task-card-DqVoitRk.js → task-card-BNbkwIYM.js} +2 -2
- package/dist/_chunks/{task-editor-D--LwVrg.js → task-editor-DgUjtqpX.js} +386 -410
- package/dist/_chunks/{task-tray-C6j8HVMv.js → task-tray-Bmi9wCHq.js} +2 -2
- package/dist/_chunks/{tasks-panel-D6PuF4MQ.js → tasks-panel-B5Nsf10r.js} +3 -3
- package/dist/_chunks/{theme-toggle-Czq3K9jB.js → theme-toggle-DfvdEg_V.js} +3 -3
- package/dist/_chunks/{token-insert-menu-Dl3x2ekR.js → token-insert-menu-BdcmK5Um.js} +2 -2
- package/dist/_chunks/toolbar-DbUQBrq4.js +159 -0
- package/dist/_chunks/{tooth-scheme-C-ALCHaV.js → tooth-scheme-LTkT4EXd.js} +2 -2
- package/dist/_chunks/{tr-xqQ6cbGY.js → tr-Bcz5LCHZ.js} +2 -2
- package/dist/_chunks/{transaction-chip-CohY6sTA.js → transaction-chip-CkYd-3ky.js} +47 -57
- package/dist/_chunks/{transcript-panel-A781Pkzr.js → transcript-panel-Wr8e4Zgi.js} +2 -2
- package/dist/_chunks/{treatment-receipt-pFqWFyD_.js → treatment-receipt-1VnuinhY.js} +3 -3
- package/dist/_chunks/undo-2-EBxWjj1W.js +15 -0
- package/dist/_chunks/{unit-converter-D77vmlzN.js → unit-converter-YKlHyUC2.js} +2 -2
- package/dist/_chunks/{use-appointment-details-read-BK_Gw1GG.js → use-appointment-details-read-_r7cjTtm.js} +8 -8
- package/dist/_chunks/{verify-identity-types-C85EXNzy.js → verify-identity-types-D_LdByCp.js} +2 -2
- package/dist/_chunks/{voice-control-panel-BGiX4sqB.js → voice-control-panel-Be_c0CQ0.js} +2 -2
- package/dist/_chunks/{widget-picker-U4JsEhQE.js → widget-picker-DrxJjEkv.js} +2 -2
- package/dist/_chunks/{workflow-map-B4XkcET0.js → workflow-map-D-u8_YSr.js} +2 -2
- package/dist/_chunks/{workflow-status-9wb7iWUd.js → workflow-status-fykpTxfb.js} +2 -2
- package/dist/_chunks/{workflow-webhook-action-CtBn5JvO.js → workflow-webhook-action-DM3W8XZE.js} +3 -3
- package/dist/_chunks/{zh-CN-C657DBCO.js → zh-CN-B7Ek17US.js} +11 -11
- package/dist/agent-catalog.json +3359 -1569
- package/dist/agent-i18n/en.json +100 -2
- package/dist/components/_shared/accessible-target.d.ts +12 -0
- package/dist/components/_shared/decimal.d.ts +171 -0
- package/dist/components/_shared/format-price.d.ts +54 -2
- package/dist/components/_shared/privacy-mask-text.d.ts +4 -0
- package/dist/components/_shared/privacy-mask.d.ts +2 -4
- package/dist/components/_shared/saved-view-tabs/saved-tab.d.ts +54 -0
- package/dist/components/_shared/saved-view-tabs/saved-view-tabs.d.ts +93 -0
- package/dist/components/_shared/saved-view-tabs/use-saved-view-tabs.d.ts +59 -0
- package/dist/components/_shared/saved-view-tabs/view-adapter.d.ts +69 -0
- package/dist/components/_shared/table-filters/calendar-day.d.ts +27 -0
- package/dist/components/_shared/table-filters/predicates.d.ts +56 -0
- package/dist/components/_shared/table-toolbar/context.d.ts +28 -0
- package/dist/components/_shared/table-toolbar/describe-filter.d.ts +42 -0
- package/dist/components/_shared/table-toolbar/export-files.d.ts +47 -0
- package/dist/components/{data-table/xlsx-export.d.ts → _shared/table-toolbar/export-xlsx.d.ts} +2 -2
- package/dist/components/_shared/table-toolbar/parts.d.ts +125 -0
- package/dist/components/_shared/table-toolbar/seam.d.ts +261 -0
- package/dist/components/address-fields/index.js +1 -1
- package/dist/components/ai-permission-notice/index.js +1 -1
- package/dist/components/appointment-card/index.js +2 -2
- package/dist/components/appointment-details-panel/index.js +1 -1
- package/dist/components/appointment-peek/index.js +1 -1
- package/dist/components/appointment-timeline/index.js +1 -1
- package/dist/components/bill-line-table/bill-line-table.agent.d.ts +4 -0
- package/dist/components/bill-line-table/bill-line-table.columns.d.ts +47 -0
- package/dist/components/bill-line-table/bill-line-table.d.ts +4 -0
- package/dist/components/bill-line-table/bill-line-table.model.d.ts +173 -0
- package/dist/components/bill-line-table/bill-line-table.types.d.ts +443 -0
- package/dist/components/bill-line-table/bill-line-table.variants.d.ts +34 -0
- package/dist/components/bill-line-table/index.d.ts +6 -0
- package/dist/components/bill-line-table/index.js +23 -0
- package/dist/components/bill-table/bill-table.agent.d.ts +4 -0
- package/dist/components/bill-table/bill-table.d.ts +13 -0
- package/dist/components/bill-table/bill-table.variants.d.ts +55 -0
- package/dist/components/bill-table/cells.d.ts +89 -0
- package/dist/components/bill-table/columns.d.ts +21 -0
- package/dist/components/bill-table/default-tabs.d.ts +21 -0
- package/dist/components/bill-table/handle.d.ts +19 -0
- package/dist/components/bill-table/index.d.ts +7 -0
- package/dist/components/bill-table/index.js +19 -0
- package/dist/components/bill-table/model.d.ts +103 -0
- package/dist/components/bill-table/row-actions.d.ts +27 -0
- package/dist/components/bill-table/status-maps.d.ts +225 -0
- package/dist/components/bill-table/types.d.ts +542 -0
- package/dist/components/bmi-calculator/index.js +1 -1
- package/dist/components/booking/index.js +1 -1
- package/dist/components/button-group/index.js +1 -1
- package/dist/components/calculator-dialog/index.js +1 -1
- package/dist/components/care-plan-card/index.js +1 -1
- package/dist/components/care-plan-entry-card/index.js +1 -1
- package/dist/components/chart/index.js +1 -1
- package/dist/components/chat-container/index.js +1 -1
- package/dist/components/checkbox/checkbox.d.ts +66 -6
- package/dist/components/checkbox/index.js +1 -1
- package/dist/components/checkbox-group/index.js +1 -1
- package/dist/components/combobox/combobox.d.ts +59 -1
- package/dist/components/combobox/index.d.ts +1 -1
- package/dist/components/combobox/index.js +1 -1
- package/dist/components/contact-profile-card/index.js +1 -1
- package/dist/components/country-select/index.js +1 -1
- package/dist/components/cycle-calculator/index.js +1 -1
- package/dist/components/dashboard-grid/index.js +1 -1
- package/dist/components/data-grid/announcer.d.ts +27 -0
- package/dist/components/data-grid/body.d.ts +101 -0
- package/dist/components/data-grid/columns.d.ts +96 -0
- package/dist/components/data-grid/data-grid.agent.d.ts +2 -1
- package/dist/components/data-grid/data-grid.d.ts +11 -27
- package/dist/components/data-grid/data-grid.variants.d.ts +110 -0
- package/dist/components/data-grid/editors.d.ts +14 -0
- package/dist/components/data-grid/export-snapshot.d.ts +3 -0
- package/dist/components/data-grid/features.d.ts +56 -0
- package/dist/components/data-grid/filter-fns.d.ts +23 -0
- package/dist/components/data-grid/filters/date-range-panel.d.ts +8 -0
- package/dist/components/data-grid/filters/filter-panels.d.ts +27 -0
- package/dist/components/data-grid/filters/filter-trigger.d.ts +7 -0
- package/dist/components/data-grid/footer.d.ts +10 -0
- package/dist/components/data-grid/grid-context.d.ts +18 -0
- package/dist/components/data-grid/handle.d.ts +60 -0
- package/dist/components/data-grid/header.d.ts +12 -0
- package/dist/components/data-grid/index.d.ts +3 -0
- package/dist/components/data-grid/index.js +11 -3
- package/dist/components/data-grid/keyboard.d.ts +76 -0
- package/dist/components/data-grid/pager.d.ts +18 -0
- package/dist/components/data-grid/persistence.d.ts +60 -0
- package/dist/components/data-grid/print.d.ts +10 -0
- package/dist/components/data-grid/responsive.d.ts +36 -0
- package/dist/components/data-grid/selection.d.ts +68 -0
- package/dist/components/data-grid/state.d.ts +119 -0
- package/dist/components/data-grid/states.d.ts +34 -0
- package/dist/components/data-grid/toolbar-seam.d.ts +7 -0
- package/dist/components/data-grid/toolbar.d.ts +41 -0
- package/dist/components/data-grid/types.d.ts +1396 -0
- package/dist/components/data-grid/use-data-grid-engine.d.ts +9 -0
- package/dist/components/data-grid/virtual-rows.d.ts +43 -0
- package/dist/components/data-grid-tabs/data-grid-tabs.agent.d.ts +9 -0
- package/dist/components/data-grid-tabs/data-grid-tabs.d.ts +4 -0
- package/dist/components/data-grid-tabs/grid-view-adapter.d.ts +15 -0
- package/dist/components/data-grid-tabs/index.d.ts +5 -0
- package/dist/components/data-grid-tabs/index.js +8 -0
- package/dist/components/data-grid-tabs/types.d.ts +220 -0
- package/dist/components/data-table/ag-toolbar-seam.d.ts +35 -0
- package/dist/components/data-table/calendar-day.d.ts +4 -21
- package/dist/components/data-table/data-table.d.ts +10 -6
- package/dist/components/data-table/filters/date-range-filter.d.ts +5 -9
- package/dist/components/data-table/filters/filter-kind.d.ts +6 -0
- package/dist/components/data-table/filters/number-filter.d.ts +6 -10
- package/dist/components/data-table/filters/select-filter.d.ts +2 -4
- package/dist/components/data-table/filters/text-filter.d.ts +2 -5
- package/dist/components/data-table/index.js +4 -4
- package/dist/components/data-table/toolbar.d.ts +25 -21
- package/dist/components/data-table-tabs/ag-view-adapter.d.ts +17 -0
- package/dist/components/data-table-tabs/data-table-tabs.d.ts +34 -33
- package/dist/components/data-table-tabs/index.js +1 -1
- package/dist/components/data-table-tabs/use-data-table-filter-tabs.d.ts +11 -66
- 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/focus-return.d.ts +12 -0
- package/dist/components/dialog/index.js +1 -1
- package/dist/components/document-preview/index.js +1 -1
- package/dist/components/dropdown-menu/dropdown-menu.d.ts +11 -0
- package/dist/components/dropdown-menu/index.js +1 -1
- package/dist/components/due-date-calculator/index.js +2 -2
- package/dist/components/face-scheme/index.js +1 -1
- package/dist/components/fetal-weight/index.js +1 -1
- package/dist/components/file-manager/index.js +1 -1
- package/dist/components/gestational-age-calculator/index.js +1 -1
- package/dist/components/hcg-doubling/index.js +1 -1
- package/dist/components/header-settings/index.js +1 -1
- package/dist/components/heatmap/index.js +1 -1
- package/dist/components/icon-button-group/icon-button-group.d.ts +19 -1
- package/dist/components/icon-button-group/index.d.ts +1 -1
- package/dist/components/icon-button-group/index.js +1 -1
- package/dist/components/index.d.ts +7 -0
- package/dist/components/money/index.js +1 -1
- package/dist/components/money/money.d.ts +39 -6
- package/dist/components/muscle-scheme/index.js +1 -1
- package/dist/components/notes-panel/index.js +1 -1
- package/dist/components/number-input/index.d.ts +2 -2
- package/dist/components/number-input/index.js +1 -1
- package/dist/components/number-input/number-input.d.ts +43 -2
- package/dist/components/number-input/use-locale-number.d.ts +67 -3
- package/dist/components/optical-prescription/index.js +1 -1
- package/dist/components/patient-details/index.js +1 -1
- package/dist/components/patient-search/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/payment-card/index.js +1 -1
- package/dist/components/periodontal-diagnosis/index.js +1 -1
- package/dist/components/permission-matrix/index.js +1 -1
- package/dist/components/practice-results/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/province-select/index.js +1 -1
- package/dist/components/radiograph-panel/index.js +1 -1
- package/dist/components/rich-text-editor/index.js +2 -2
- package/dist/components/row-actions/index.d.ts +3 -0
- package/dist/components/row-actions/index.js +5 -0
- package/dist/components/row-actions/row-actions.d.ts +63 -0
- package/dist/components/sidebar/index.js +1 -1
- package/dist/components/skeleton-scheme/index.js +1 -1
- package/dist/components/slot-grid/index.js +1 -1
- package/dist/components/smart-date/smart-date.d.ts +1 -1
- package/dist/components/tab-bar/index.js +1 -1
- package/dist/components/tabs/index.js +1 -1
- package/dist/components/tag/index.js +1 -1
- package/dist/components/task-card/index.js +1 -1
- package/dist/components/task-editor/index.js +1 -1
- package/dist/components/task-tray/index.js +1 -1
- package/dist/components/tasks-panel/index.js +1 -1
- package/dist/components/theme-toggle/index.js +1 -1
- package/dist/components/token-insert-menu/index.js +1 -1
- package/dist/components/tooth-scheme/index.js +1 -1
- package/dist/components/transaction-chip/index.js +1 -1
- package/dist/components/transaction-chip/transaction-chip.d.ts +1 -1
- package/dist/components/transcript-panel/index.js +1 -1
- package/dist/components/treatment-receipt/index.js +1 -1
- package/dist/components/unit-converter/index.js +1 -1
- package/dist/components/voice-control-panel/index.js +1 -1
- package/dist/components/widget-picker/index.js +1 -1
- package/dist/components/workflow/index.js +1 -1
- package/dist/components/workflow-status/index.js +1 -1
- package/dist/core.css +1 -1
- package/dist/decimal/index.js +149 -0
- package/dist/host-compat.css +36 -2
- package/dist/i18n/locales/ar.d.ts +342 -0
- package/dist/i18n/locales/ar.js +344 -2
- package/dist/i18n/locales/de.d.ts +342 -0
- package/dist/i18n/locales/de.js +344 -2
- package/dist/i18n/locales/el.d.ts +342 -0
- package/dist/i18n/locales/el.js +344 -2
- package/dist/i18n/locales/en.d.ts +342 -0
- package/dist/i18n/locales/en.js +345 -2
- package/dist/i18n/locales/es.d.ts +342 -0
- package/dist/i18n/locales/es.js +344 -2
- package/dist/i18n/locales/fr.d.ts +342 -0
- package/dist/i18n/locales/fr.js +344 -2
- package/dist/i18n/locales/hi.d.ts +342 -0
- package/dist/i18n/locales/hi.js +344 -2
- package/dist/i18n/locales/it.d.ts +342 -0
- package/dist/i18n/locales/it.js +344 -2
- package/dist/i18n/locales/ja.d.ts +342 -0
- package/dist/i18n/locales/ja.js +344 -2
- package/dist/i18n/locales/nl.d.ts +342 -0
- package/dist/i18n/locales/nl.js +344 -2
- package/dist/i18n/locales/pl.d.ts +342 -0
- package/dist/i18n/locales/pl.js +344 -2
- package/dist/i18n/locales/pt.d.ts +342 -0
- package/dist/i18n/locales/pt.js +344 -2
- package/dist/i18n/locales/ro.d.ts +342 -0
- package/dist/i18n/locales/ro.js +344 -2
- package/dist/i18n/locales/ru.d.ts +342 -0
- package/dist/i18n/locales/ru.js +344 -2
- package/dist/i18n/locales/sq.d.ts +342 -0
- package/dist/i18n/locales/sq.js +344 -2
- package/dist/i18n/locales/sv.d.ts +342 -0
- package/dist/i18n/locales/sv.js +344 -2
- package/dist/i18n/locales/tr.d.ts +342 -0
- package/dist/i18n/locales/tr.js +344 -2
- package/dist/i18n/locales/zh.d.ts +342 -0
- package/dist/i18n/locales/zh.js +344 -2
- package/dist/index.js +1305 -1241
- package/dist/locales/ar.json +344 -2
- package/dist/locales/de.json +344 -2
- package/dist/locales/el.json +344 -2
- package/dist/locales/en.json +344 -2
- package/dist/locales/es.json +344 -2
- package/dist/locales/fr.json +344 -2
- package/dist/locales/hi.json +344 -2
- package/dist/locales/it.json +344 -2
- package/dist/locales/ja.json +344 -2
- package/dist/locales/nl.json +344 -2
- package/dist/locales/pl.json +344 -2
- package/dist/locales/pt.json +344 -2
- package/dist/locales/ro.json +344 -2
- package/dist/locales/ru.json +344 -2
- package/dist/locales/sq.json +344 -2
- package/dist/locales/sv.json +344 -2
- package/dist/locales/tr.json +344 -2
- package/dist/locales/zh.json +344 -2
- package/dist/patterns/alia-assistant/index.js +1 -1
- package/dist/patterns/anamnesis/index.js +1 -1
- package/dist/patterns/calendar/index.js +1 -1
- package/dist/patterns/help-me-write-templates/index.js +1 -1
- package/dist/patterns/login-form/index.js +1 -1
- package/dist/patterns/marketplace-app-shell/index.js +1 -1
- package/dist/patterns/registration-form/index.js +1 -1
- package/dist/patterns/send-registration-link-form/index.js +1 -1
- package/dist/patterns/signature-request/index.js +1 -1
- package/dist/patterns/verify-identity/index.js +1 -1
- package/dist/patterns/workflow-webhook-action/index.js +1 -1
- package/dist/tokens.css +1 -1
- package/package.json +21 -1
- package/dist/_chunks/checkbox-a7Sh-dXb.js +0 -227
- package/dist/_chunks/combobox-duuDRI1t.js +0 -688
- package/dist/_chunks/data-grid.agent-CASyEAnb.js +0 -1773
- package/dist/_chunks/data-table-C9idMvs0.js +0 -2042
- package/dist/_chunks/data-table-tabs-Db7zToFD.js +0 -728
- package/dist/_chunks/dialog-BTjSQjdY.js +0 -274
- package/dist/_chunks/format--x5jypvH.js +0 -1319
- package/dist/_chunks/format-price-BcFBa-WP.js +0 -52
- package/dist/_chunks/icon-button-group-mXvYDaba.js +0 -427
- package/dist/_chunks/link-cell-renderer-_Fv3WEmb.js +0 -867
- package/dist/_chunks/money-Tsczpjfz.js +0 -102
- package/dist/_chunks/number-input-CVwI1ltI.js +0 -423
- package/dist/_chunks/privacy-mask-Dc3kdkCR.js +0 -81
- package/dist/_chunks/subDays-DKISP2nE.js +0 -8
- package/dist/_chunks/undo-2-CYNAzclj.js +0 -26
|
@@ -1,59 +1,51 @@
|
|
|
1
|
-
import { jsx as n, jsxs as k, Fragment as
|
|
2
|
-
import { useState as
|
|
1
|
+
import { jsx as n, jsxs as k, Fragment as Te } from "react/jsx-runtime";
|
|
2
|
+
import { useState as q, useRef as C, useEffect as qe, forwardRef as At, useId as Bt, useMemo as Pe } from "react";
|
|
3
3
|
import { c as ht } from "./index-D2ZczOXr.js";
|
|
4
4
|
import { useTranslation as gt } from "react-i18next";
|
|
5
|
-
import { A as
|
|
6
|
-
import { B as
|
|
5
|
+
import { A as $ } from "./alert-C4WKViaS.js";
|
|
6
|
+
import { B as $e } from "./button-DohK_Ak_.js";
|
|
7
7
|
import { I as We } from "./icon-button-S8_weU3g.js";
|
|
8
|
-
import { C as Qe } from "./combobox-
|
|
9
|
-
import { D as
|
|
10
|
-
import { D as
|
|
8
|
+
import { C as Qe } from "./combobox-BBCVQS-S.js";
|
|
9
|
+
import { D as le } from "./dialog-CIUn5oLb.js";
|
|
10
|
+
import { D as Ft } from "./date-picker-DBVTj6lO.js";
|
|
11
11
|
import { F as H } from "./form-field-CyHfOVKF.js";
|
|
12
|
-
import { I as
|
|
12
|
+
import { I as xt } from "./icon-button-group-Ca2VkXy5.js";
|
|
13
13
|
import { P as Pt } from "./panel-header-CbtlTe85.js";
|
|
14
14
|
import { P as Ot } from "./panel-subview-DCyvn-49.js";
|
|
15
|
-
import { R as
|
|
15
|
+
import { R as Oe } from "./radio-BZQs6_36.js";
|
|
16
16
|
import { R as jt } from "./radio-group-ChIKyeSJ.js";
|
|
17
17
|
import { S as Mt } from "./scroll-area-CY5SLYNw.js";
|
|
18
18
|
import { S as Ke } from "./select-uESzXTX6.js";
|
|
19
19
|
import { S as He } from "./skeleton-tTWJpvAq.js";
|
|
20
20
|
import { S as $t } from "./switch-DO6uC4HJ.js";
|
|
21
|
-
import { T as
|
|
22
|
-
import { T as
|
|
23
|
-
import { T as
|
|
24
|
-
import { u as
|
|
25
|
-
import { u as
|
|
26
|
-
import { c as
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
21
|
+
import { T as qt } from "./text-area-COMVJ1yE.js";
|
|
22
|
+
import { T as je } from "./text-input-B6iAgCr3.js";
|
|
23
|
+
import { T as Vt } from "./time-picker-DDr5vhwQ.js";
|
|
24
|
+
import { u as _t } from "./registry-DvAUVLHh.js";
|
|
25
|
+
import { u as zt } from "./use-isomorphic-layout-effect-BGfaCOP1.js";
|
|
26
|
+
import { c as Lt } from "./compose-refs-C0k0tdqF.js";
|
|
27
|
+
import { a as Ut, E as Wt } from "./compact-editor-fields-6sTWRLtf.js";
|
|
28
|
+
import { n as Kt } from "./normalize-diacritics-BNGbFNlJ.js";
|
|
29
|
+
import { P as Ht } from "./privacy-mask-BlJK51MD.js";
|
|
30
|
+
import { g as Me, h as Gt } from "./handled-rejection-6gqCf5vt.js";
|
|
30
31
|
import { L as Qt } from "./lock-ClAFG1gy.js";
|
|
31
32
|
import { X as Yt } from "./x-B5YnXwCz.js";
|
|
32
|
-
import {
|
|
33
|
-
import { U as
|
|
34
|
-
import { B as
|
|
35
|
-
import { S as
|
|
33
|
+
import { C as Xt } from "./circle-off-DuT9pVy2.js";
|
|
34
|
+
import { U as Jt } from "./user-B12p7bVF.js";
|
|
35
|
+
import { B as Zt } from "./building-2-D33bLCWL.js";
|
|
36
|
+
import { S as en } from "./stethoscope-sZXGC43m.js";
|
|
36
37
|
import { T as dt } from "./trash-2-uumy3fy1.js";
|
|
37
|
-
import { S as
|
|
38
|
-
import {
|
|
38
|
+
import { S as lt } from "./square-check-big-dj0o8yA3.js";
|
|
39
|
+
import { p as tn } from "./privacy-mask-text-B8YfzB7L.js";
|
|
40
|
+
import { L as nn } from "./loader-circle-BECIU_8N.js";
|
|
41
|
+
import { c as on } from "./createLucideIcon-DhHxpK9K.js";
|
|
39
42
|
/**
|
|
40
43
|
* @license lucide-react v1.22.0 - ISC
|
|
41
44
|
*
|
|
42
45
|
* This source code is licensed under the ISC license.
|
|
43
46
|
* See the LICENSE file in the root directory of this source tree.
|
|
44
47
|
*/
|
|
45
|
-
const
|
|
46
|
-
["path", { d: "m2 2 20 20", key: "1ooewy" }],
|
|
47
|
-
["path", { d: "M8.35 2.69A10 10 0 0 1 21.3 15.65", key: "1pfsoa" }],
|
|
48
|
-
["path", { d: "M19.08 19.08A10 10 0 1 1 4.92 4.92", key: "1ablyi" }]
|
|
49
|
-
], nn = vt("circle-off", tn);
|
|
50
|
-
/**
|
|
51
|
-
* @license lucide-react v1.22.0 - ISC
|
|
52
|
-
*
|
|
53
|
-
* This source code is licensed under the ISC license.
|
|
54
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
55
|
-
*/
|
|
56
|
-
const on = [
|
|
48
|
+
const rn = [
|
|
57
49
|
[
|
|
58
50
|
"path",
|
|
59
51
|
{
|
|
@@ -63,62 +55,47 @@ const on = [
|
|
|
63
55
|
],
|
|
64
56
|
["path", { d: "M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7", key: "1ydtos" }],
|
|
65
57
|
["path", { d: "M7 3v4a1 1 0 0 0 1 1h7", key: "t51u73" }]
|
|
66
|
-
], an =
|
|
67
|
-
|
|
68
|
-
"ds:[&_:is([data-component=select][role=combobox],[data-component=text-input],[data-component=text-input]_input,[data-component=date-picker]_input,[data-component=combobox],[data-component=time-picker],[data-component=number-input])]:rounded-[var(--radius-md)]",
|
|
69
|
-
"ds:[&_:is([data-component=select][role=combobox],[data-component=text-input],[data-component=text-input]_input,[data-component=date-picker]_input,[data-component=combobox],[data-component=time-picker],[data-component=number-input])]:[min-block-size:var(--accessible-target-floor,auto)]",
|
|
70
|
-
"ds:max-sm:[&_:is([data-component=select][role=combobox],[data-component=text-input],[data-component=text-input]_input,[data-component=date-picker]_input,[data-component=combobox],[data-component=time-picker],[data-component=number-input])]:[min-block-size:var(--min-target-size)]",
|
|
71
|
-
/* Multi-line notes keep their height but share the corners. */
|
|
72
|
-
"ds:[&_[data-component=text-area]_textarea]:rounded-[var(--radius-md)]",
|
|
73
|
-
/* The time field's hour and minute segments are 32px at the kit default;
|
|
74
|
-
inside a 32px box they take the kit's `sm` segment height instead,
|
|
75
|
-
and get the default back wherever the field is raised. */
|
|
76
|
-
"ds:[&_[data-component=time-picker]_[role=spinbutton]]:h-[calc(var(--ds-spacing)*(6+2*var(--accessible-on,0)))]",
|
|
77
|
-
"ds:max-sm:[&_[data-component=time-picker]_[role=spinbutton]]:h-8"
|
|
78
|
-
].join(" "), sn = [
|
|
79
|
-
"ds:h-[var(--accessible-auto,calc(var(--ds-spacing)*8))] ds:[&_[role=radio]]:[min-block-size:var(--accessible-target-floor,0px)]",
|
|
80
|
-
"ds:max-sm:h-auto ds:max-sm:[&_[role=radio]]:min-h-[var(--min-target-size)]"
|
|
81
|
-
].join(" ");
|
|
82
|
-
function dn({
|
|
58
|
+
], an = on("save", rn);
|
|
59
|
+
function sn({
|
|
83
60
|
patients: o = [],
|
|
84
|
-
searchPatients:
|
|
61
|
+
searchPatients: l,
|
|
85
62
|
...I
|
|
86
63
|
}) {
|
|
87
|
-
if (
|
|
88
|
-
return /* @__PURE__ */ n(
|
|
89
|
-
const { value:
|
|
64
|
+
if (l)
|
|
65
|
+
return /* @__PURE__ */ n(dn, { ...I, searchPatients: l });
|
|
66
|
+
const { value: y, onValueChange: x, selectedLabel: B, placeholder: Y, size: D, disabled: X } = I;
|
|
90
67
|
return /* @__PURE__ */ n(
|
|
91
68
|
Qe,
|
|
92
69
|
{
|
|
93
|
-
value:
|
|
94
|
-
onValueChange:
|
|
70
|
+
value: y,
|
|
71
|
+
onValueChange: x,
|
|
95
72
|
options: [
|
|
96
|
-
...
|
|
97
|
-
...o.map((
|
|
73
|
+
...y && !o.some((T) => T.id === y) ? [{ value: y, label: B ?? "" }] : [],
|
|
74
|
+
...o.map((T) => ({ value: T.id, label: T.name }))
|
|
98
75
|
],
|
|
99
76
|
placeholder: Y,
|
|
100
|
-
size:
|
|
77
|
+
size: D,
|
|
101
78
|
disabled: X,
|
|
102
79
|
clearable: !0
|
|
103
80
|
}
|
|
104
81
|
);
|
|
105
82
|
}
|
|
106
|
-
function
|
|
83
|
+
function dn({
|
|
107
84
|
value: o,
|
|
108
|
-
onValueChange:
|
|
85
|
+
onValueChange: l,
|
|
109
86
|
selectedLabel: I,
|
|
110
|
-
placeholder:
|
|
111
|
-
size:
|
|
112
|
-
disabled:
|
|
87
|
+
placeholder: y,
|
|
88
|
+
size: x,
|
|
89
|
+
disabled: B,
|
|
113
90
|
searchPatients: Y
|
|
114
91
|
}) {
|
|
115
|
-
const { t:
|
|
116
|
-
|
|
117
|
-
if (!
|
|
118
|
-
const m = new AbortController(), S = { query:
|
|
92
|
+
const { t: D } = gt("ui"), [X, T] = q(""), [J, Z] = q(0), [P, se] = q(), [N, ee] = q(), _ = C(null), O = X.trim();
|
|
93
|
+
qe(() => {
|
|
94
|
+
if (!O) return;
|
|
95
|
+
const m = new AbortController(), S = { query: O, source: Y };
|
|
119
96
|
ee({ ...S, status: "loading", patients: [] });
|
|
120
|
-
const
|
|
121
|
-
Promise.resolve().then(() => Y(
|
|
97
|
+
const ce = setTimeout(() => {
|
|
98
|
+
Promise.resolve().then(() => Y(O, { signal: m.signal })).then(
|
|
122
99
|
(oe) => {
|
|
123
100
|
m.signal.aborted || ee({ ...S, status: "ready", patients: oe });
|
|
124
101
|
},
|
|
@@ -128,16 +105,16 @@ function cn({
|
|
|
128
105
|
);
|
|
129
106
|
}, 250);
|
|
130
107
|
return () => {
|
|
131
|
-
clearTimeout(
|
|
108
|
+
clearTimeout(ce), m.abort();
|
|
132
109
|
};
|
|
133
|
-
}, [
|
|
134
|
-
const
|
|
110
|
+
}, [O, Y, J]);
|
|
111
|
+
const z = (N == null ? void 0 : N.query) === O && N.source === Y, L = O ? z ? N.status : "loading" : "idle", te = z && L === "ready" ? N.patients : [], ne = L === "loading" ? D("inputs.search.loading") : L === "error" ? D("emptyState.error.description") : L === "idle" ? y : te.length === 0 ? D("inputs.combobox.empty") : "", j = te.map((m) => ({
|
|
135
112
|
value: m.id,
|
|
136
113
|
label: m.name
|
|
137
114
|
}));
|
|
138
|
-
return o && !te.some((m) => m.id === o) &&
|
|
115
|
+
return o && !te.some((m) => m.id === o) && j.push({
|
|
139
116
|
value: o,
|
|
140
|
-
label: (
|
|
117
|
+
label: (P == null ? void 0 : P.id) === o ? P.name : I ?? ""
|
|
141
118
|
}), /* @__PURE__ */ k(
|
|
142
119
|
"div",
|
|
143
120
|
{
|
|
@@ -148,37 +125,37 @@ function cn({
|
|
|
148
125
|
/* @__PURE__ */ n(
|
|
149
126
|
Qe,
|
|
150
127
|
{
|
|
151
|
-
ref:
|
|
152
|
-
options:
|
|
128
|
+
ref: _,
|
|
129
|
+
options: j,
|
|
153
130
|
value: o,
|
|
154
131
|
onValueChange: (m) => {
|
|
155
132
|
se(
|
|
156
|
-
(S) => te.find((
|
|
157
|
-
),
|
|
133
|
+
(S) => te.find((ce) => ce.id === m) ?? ((S == null ? void 0 : S.id) === m ? S : void 0)
|
|
134
|
+
), l(m);
|
|
158
135
|
},
|
|
159
|
-
onQueryChange:
|
|
136
|
+
onQueryChange: T,
|
|
160
137
|
onOpenChange: (m) => {
|
|
161
|
-
!m && L !== "error" &&
|
|
138
|
+
!m && L !== "error" && T("");
|
|
162
139
|
},
|
|
163
|
-
filter: (m) => !
|
|
164
|
-
size:
|
|
165
|
-
disabled:
|
|
166
|
-
placeholder:
|
|
140
|
+
filter: (m) => !O || te.some((S) => Kt(S.id) === m) ? 1 : 0,
|
|
141
|
+
size: x,
|
|
142
|
+
disabled: B,
|
|
143
|
+
placeholder: y,
|
|
167
144
|
emptyMessage: ne || void 0,
|
|
168
145
|
clearable: !0
|
|
169
146
|
}
|
|
170
147
|
),
|
|
171
148
|
/* @__PURE__ */ n("p", { role: "status", className: "type-body-sm ds:text-muted-foreground", children: ne }),
|
|
172
149
|
L === "error" ? /* @__PURE__ */ n(
|
|
173
|
-
|
|
150
|
+
$e,
|
|
174
151
|
{
|
|
175
152
|
size: "sm",
|
|
176
153
|
intent: "ghost",
|
|
177
154
|
onClick: () => {
|
|
178
155
|
var m;
|
|
179
|
-
Z((S) => S + 1), (m =
|
|
156
|
+
Z((S) => S + 1), (m = _.current) == null || m.focus();
|
|
180
157
|
},
|
|
181
|
-
children:
|
|
158
|
+
children: D("emptyState.error.cta")
|
|
182
159
|
}
|
|
183
160
|
) : null
|
|
184
161
|
]
|
|
@@ -238,8 +215,8 @@ const ln = {
|
|
|
238
215
|
],
|
|
239
216
|
descriptionKey: "ui.agent.taskEditor.actions.setFields",
|
|
240
217
|
description: "Set draft fields. Ids must come from the host lists, a patient the host search returned, or equal the stored one. At most one counterpart per call, and it selects its branch; assigneeId null is nobody. Nothing is saved.",
|
|
241
|
-
invoke: (o,
|
|
242
|
-
o.setFields(
|
|
218
|
+
invoke: (o, l) => {
|
|
219
|
+
o.setFields(l);
|
|
243
220
|
}
|
|
244
221
|
},
|
|
245
222
|
save: {
|
|
@@ -266,7 +243,7 @@ const ln = {
|
|
|
266
243
|
],
|
|
267
244
|
descriptionKey: "ui.agent.taskEditor.actions.setDone",
|
|
268
245
|
description: "Mark an existing task done or not done through the host. A rejection rolls the switch back.",
|
|
269
|
-
invoke: (o,
|
|
246
|
+
invoke: (o, l) => o.setDone(l.done)
|
|
270
247
|
},
|
|
271
248
|
delete: {
|
|
272
249
|
safety: "destructive",
|
|
@@ -298,7 +275,7 @@ const ln = {
|
|
|
298
275
|
description: "Sourced from the id prop, or generated. Addresses one editor from the agent. [data-component-id] reaches the footer actions in both variants."
|
|
299
276
|
}
|
|
300
277
|
}
|
|
301
|
-
},
|
|
278
|
+
}, V = "none", ct = {
|
|
302
279
|
showError: !1,
|
|
303
280
|
saving: !1,
|
|
304
281
|
saveError: void 0,
|
|
@@ -311,106 +288,106 @@ const ln = {
|
|
|
311
288
|
confirmDeleteOpen: !1,
|
|
312
289
|
accepted: !1
|
|
313
290
|
};
|
|
314
|
-
function
|
|
291
|
+
function cn(o) {
|
|
315
292
|
return o.patientId ? "patient" : o.companyId ? "company" : o.operatorId ? "operator" : "nobody";
|
|
316
293
|
}
|
|
317
294
|
function Ye(o) {
|
|
318
295
|
return { hours: o.getHours(), minutes: o.getMinutes() };
|
|
319
296
|
}
|
|
320
297
|
function ut(o) {
|
|
321
|
-
const
|
|
298
|
+
const l = o ?? /* @__PURE__ */ new Date();
|
|
322
299
|
return {
|
|
323
|
-
date:
|
|
324
|
-
time: Ye(
|
|
300
|
+
date: l,
|
|
301
|
+
time: Ye(l),
|
|
325
302
|
note: "",
|
|
326
|
-
operatorId:
|
|
303
|
+
operatorId: V,
|
|
327
304
|
typeId: "",
|
|
328
|
-
assigneeId:
|
|
305
|
+
assigneeId: V,
|
|
329
306
|
about: "nobody",
|
|
330
307
|
patientId: "",
|
|
331
308
|
companyId: ""
|
|
332
309
|
};
|
|
333
310
|
}
|
|
334
|
-
function
|
|
335
|
-
const
|
|
311
|
+
function un(o) {
|
|
312
|
+
const l = new Date(o.dateIso);
|
|
336
313
|
return {
|
|
337
|
-
date:
|
|
338
|
-
time: Ye(
|
|
314
|
+
date: l,
|
|
315
|
+
time: Ye(l),
|
|
339
316
|
note: o.note,
|
|
340
317
|
/* `||`, not `??`: a host's '' is unset, like patient and company. */
|
|
341
|
-
operatorId: o.operatorId ||
|
|
318
|
+
operatorId: o.operatorId || V,
|
|
342
319
|
/* A stored type wins. With none, '' falls through to the first entry. */
|
|
343
320
|
typeId: o.typeId ?? "",
|
|
344
321
|
/* `||` too: '' would become a Select option with an empty value. */
|
|
345
|
-
assigneeId: o.assigneeId ||
|
|
346
|
-
about:
|
|
322
|
+
assigneeId: o.assigneeId || V,
|
|
323
|
+
about: cn(o),
|
|
347
324
|
patientId: o.patientId ?? "",
|
|
348
325
|
companyId: o.companyId ?? ""
|
|
349
326
|
};
|
|
350
327
|
}
|
|
351
|
-
const
|
|
328
|
+
const pn = [
|
|
352
329
|
["patientId", "patient"],
|
|
353
330
|
["companyId", "company"],
|
|
354
331
|
["operatorId", "operator"]
|
|
355
332
|
];
|
|
356
|
-
function
|
|
333
|
+
function mn({
|
|
357
334
|
mode: o,
|
|
358
|
-
taskId:
|
|
335
|
+
taskId: l,
|
|
359
336
|
initialDate: I,
|
|
360
|
-
active:
|
|
361
|
-
taskTypes:
|
|
362
|
-
assignees:
|
|
337
|
+
active: y,
|
|
338
|
+
taskTypes: x,
|
|
339
|
+
assignees: B,
|
|
363
340
|
companies: Y,
|
|
364
|
-
operators:
|
|
341
|
+
operators: D,
|
|
365
342
|
patients: X,
|
|
366
|
-
searchedPatients:
|
|
343
|
+
searchedPatients: T,
|
|
367
344
|
resolvePatientLabel: J,
|
|
368
345
|
loadTask: Z,
|
|
369
|
-
onCreateTask:
|
|
346
|
+
onCreateTask: P,
|
|
370
347
|
onUpdateTask: se,
|
|
371
348
|
onDeleteTask: N,
|
|
372
349
|
onSetTaskDone: ee,
|
|
373
|
-
onSaved:
|
|
374
|
-
onDeleted:
|
|
375
|
-
readOnly:
|
|
350
|
+
onSaved: _,
|
|
351
|
+
onDeleted: O,
|
|
352
|
+
readOnly: z,
|
|
376
353
|
withheld: L,
|
|
377
354
|
maskPatient: te,
|
|
378
355
|
fallbackError: ne
|
|
379
356
|
}) {
|
|
380
|
-
var
|
|
381
|
-
const
|
|
382
|
-
|
|
383
|
-
const U = `${o}|${
|
|
357
|
+
var Ce;
|
|
358
|
+
const j = o === "edit", [m, S] = q(0), [ce, oe] = q(y);
|
|
359
|
+
ce !== y && (oe(y), y && S((e) => e + 1));
|
|
360
|
+
const U = `${o}|${l ?? ""}|${m}`, [p, fe] = q(
|
|
384
361
|
() => ut(I)
|
|
385
|
-
), [G, Ee] =
|
|
386
|
-
ge !== U && (
|
|
387
|
-
const
|
|
362
|
+
), [G, Ee] = q(ct), [b, r] = q(), w = (e) => Ee((i) => ({ ...i, ...e })), he = (e) => fe((i) => ({ ...i, ...e })), [ge, re] = q(U);
|
|
363
|
+
ge !== U && (re(U), fe(ut(I)), Ee(ct), r(void 0));
|
|
364
|
+
const F = C({
|
|
388
365
|
subject: U,
|
|
389
366
|
saving: !1,
|
|
390
367
|
deleting: !1,
|
|
391
368
|
donePending: !1,
|
|
392
369
|
accepted: !1
|
|
393
370
|
});
|
|
394
|
-
|
|
371
|
+
F.current.subject !== U && (F.current = {
|
|
395
372
|
subject: U,
|
|
396
373
|
saving: !1,
|
|
397
374
|
deleting: !1,
|
|
398
375
|
donePending: !1,
|
|
399
376
|
accepted: !1
|
|
400
377
|
});
|
|
401
|
-
const ve =
|
|
402
|
-
|
|
378
|
+
const ve = C(!0);
|
|
379
|
+
qe(() => (ve.current = !0, () => {
|
|
403
380
|
ve.current = !1;
|
|
404
381
|
}), []);
|
|
405
|
-
const
|
|
382
|
+
const R = (e) => ve.current && F.current === e, ue = C(Z);
|
|
406
383
|
ue.current = Z;
|
|
407
|
-
const d = !!Z, [
|
|
384
|
+
const d = !!Z, [A, c] = q(0), [s, f] = q(null), ke = C(s);
|
|
408
385
|
ke.current = s;
|
|
409
|
-
const
|
|
410
|
-
|
|
386
|
+
const ye = y && j && !!l && d && !L;
|
|
387
|
+
qe(() => {
|
|
411
388
|
const e = ue.current;
|
|
412
|
-
if (!
|
|
413
|
-
const i =
|
|
389
|
+
if (!ye || !l || !e) return;
|
|
390
|
+
const i = F.current, h = ke.current;
|
|
414
391
|
if ((h == null ? void 0 : h.subject) === i.subject && h.status === "ready")
|
|
415
392
|
return;
|
|
416
393
|
const u = new AbortController();
|
|
@@ -418,25 +395,25 @@ function fn({
|
|
|
418
395
|
() => (
|
|
419
396
|
/* Cleaned up before this ran (StrictMode's replay, a quick re-run):
|
|
420
397
|
never call the host with a signal already aborted. */
|
|
421
|
-
u.signal.aborted ? Promise.reject(u.signal.reason) : e(
|
|
398
|
+
u.signal.aborted ? Promise.reject(u.signal.reason) : e(l, { signal: u.signal })
|
|
422
399
|
)
|
|
423
400
|
).then(
|
|
424
401
|
(g) => {
|
|
425
|
-
u.signal.aborted || !
|
|
402
|
+
u.signal.aborted || !R(i) || (fe(un(g)), w({ done: g.done, confirmedDone: g.done }), r(g), f({ subject: i.subject, status: "ready" }));
|
|
426
403
|
},
|
|
427
404
|
(g) => {
|
|
428
|
-
u.signal.aborted || !
|
|
405
|
+
u.signal.aborted || !R(i) || f({
|
|
429
406
|
subject: i.subject,
|
|
430
407
|
status: "error",
|
|
431
|
-
message:
|
|
408
|
+
message: Me(g, ne)
|
|
432
409
|
});
|
|
433
410
|
}
|
|
434
411
|
), () => u.abort();
|
|
435
|
-
}, [
|
|
436
|
-
const
|
|
437
|
-
|
|
438
|
-
}, pe = p.typeId || (((
|
|
439
|
-
(
|
|
412
|
+
}, [ye, U, A]);
|
|
413
|
+
const M = j ? !l || !d ? "locked" : L ? "withheld" : (s == null ? void 0 : s.subject) === U ? s.status : "loading" : "ready", Q = () => {
|
|
414
|
+
M === "error" && (f(null), c((e) => e + 1));
|
|
415
|
+
}, pe = p.typeId || (((Ce = x[0]) == null ? void 0 : Ce.id) ?? ""), Ve = p.about === "nobody" || p.about === "patient" && p.patientId !== "" || p.about === "company" && p.companyId !== "" || p.about === "operator" && p.operatorId !== V, me = !z && p.note.trim() !== "" && p.date !== void 0 && Ve && /* Required whenever the host offers a list. */
|
|
416
|
+
(x.length === 0 || pe !== "") && !G.saving && !G.donePending, be = j ? se : P, Se = () => {
|
|
440
417
|
const { date: e, time: i } = p;
|
|
441
418
|
return e ? {
|
|
442
419
|
dateIso: new Date(
|
|
@@ -453,54 +430,54 @@ function fn({
|
|
|
453
430
|
longer resolves: a real link must survive a Save that never
|
|
454
431
|
offered to change it. */
|
|
455
432
|
typeId: pe === "" ? void 0 : pe,
|
|
456
|
-
assigneeId: p.assigneeId ===
|
|
433
|
+
assigneeId: p.assigneeId === V ? void 0 : p.assigneeId,
|
|
457
434
|
/* ONE counterpart, decided by `about` alone: the platform refuses a
|
|
458
435
|
task carrying two. Never gated on a list being loaded, or a list
|
|
459
436
|
that empties mid-edit would unlink the task on Save. */
|
|
460
437
|
patientId: p.about === "patient" && p.patientId ? p.patientId : void 0,
|
|
461
438
|
companyId: p.about === "company" && p.companyId ? p.companyId : void 0,
|
|
462
|
-
operatorId: p.about === "operator" && p.operatorId !==
|
|
439
|
+
operatorId: p.about === "operator" && p.operatorId !== V ? p.operatorId : void 0,
|
|
463
440
|
/* The last CONFIRMED value only, never an optimistic or rolled-back
|
|
464
441
|
toggle. */
|
|
465
442
|
done: G.confirmedDone
|
|
466
443
|
} : void 0;
|
|
467
|
-
}, E = (e) => Gt(new Error(`TaskEditor: ${e}`)),
|
|
468
|
-
const e =
|
|
469
|
-
if (
|
|
470
|
-
if (!
|
|
444
|
+
}, E = (e) => Gt(new Error(`TaskEditor: ${e}`)), Re = () => {
|
|
445
|
+
const e = F.current;
|
|
446
|
+
if (M !== "ready") return E(`cannot save while ${M}.`);
|
|
447
|
+
if (!be) return E("the host gave no save seam.");
|
|
471
448
|
if (e.accepted) return E("this task was already saved.");
|
|
472
449
|
if (e.deleting) return E("a delete is in flight.");
|
|
473
450
|
if (e.saving || !me) return E("the task cannot be saved.");
|
|
474
451
|
const i = Se();
|
|
475
452
|
if (!i)
|
|
476
453
|
return w({ showError: !0 }), E("the task has no date.");
|
|
477
|
-
const h =
|
|
454
|
+
const h = l;
|
|
478
455
|
e.saving = !0, w({ saving: !0, saveError: void 0 });
|
|
479
456
|
const u = (async () => {
|
|
480
457
|
try {
|
|
481
|
-
if (
|
|
482
|
-
await (se == null ? void 0 : se(h, i)), e.accepted = !0,
|
|
458
|
+
if (j)
|
|
459
|
+
await (se == null ? void 0 : se(h, i)), e.accepted = !0, R(e) && (w({ accepted: !0 }), _ == null || _({
|
|
483
460
|
...i,
|
|
484
461
|
id: h,
|
|
485
462
|
done: i.done ?? !1
|
|
486
463
|
}));
|
|
487
464
|
else {
|
|
488
|
-
const g = await (
|
|
489
|
-
e.accepted = !0,
|
|
465
|
+
const g = await (P == null ? void 0 : P(i));
|
|
466
|
+
e.accepted = !0, R(e) && (w({ accepted: !0 }), g && (_ == null || _(g)));
|
|
490
467
|
}
|
|
491
468
|
} catch (g) {
|
|
492
|
-
throw
|
|
469
|
+
throw R(e) && w({ saveError: Me(g, ne) }), g;
|
|
493
470
|
} finally {
|
|
494
|
-
e.saving = !1,
|
|
471
|
+
e.saving = !1, R(e) && w({ saving: !1 });
|
|
495
472
|
}
|
|
496
473
|
})();
|
|
497
474
|
return u.catch(() => {
|
|
498
475
|
}), u;
|
|
499
|
-
},
|
|
500
|
-
const i =
|
|
501
|
-
if (
|
|
502
|
-
return E(`cannot change Done while ${
|
|
503
|
-
if (!
|
|
476
|
+
}, Ae = (e) => {
|
|
477
|
+
const i = F.current;
|
|
478
|
+
if (M !== "ready")
|
|
479
|
+
return E(`cannot change Done while ${M}.`);
|
|
480
|
+
if (!j || !l || !ee || z)
|
|
504
481
|
return E("the host gave no Done seam.");
|
|
505
482
|
if (i.donePending) return E("a Done change is already pending.");
|
|
506
483
|
if (i.saving || i.deleting)
|
|
@@ -508,38 +485,38 @@ function fn({
|
|
|
508
485
|
if (i.accepted)
|
|
509
486
|
return E("this task was already saved or deleted.");
|
|
510
487
|
if (e === G.done) return Promise.resolve();
|
|
511
|
-
const h = G.confirmedDone, u =
|
|
488
|
+
const h = G.confirmedDone, u = l;
|
|
512
489
|
i.donePending = !0, w({ done: e, donePending: !0, doneError: void 0 });
|
|
513
490
|
const g = (async () => {
|
|
514
491
|
try {
|
|
515
|
-
await ee(u, e),
|
|
492
|
+
await ee(u, e), R(i) && w({ confirmedDone: e });
|
|
516
493
|
} catch (W) {
|
|
517
|
-
throw
|
|
494
|
+
throw R(i) && w({
|
|
518
495
|
done: h,
|
|
519
|
-
doneError:
|
|
496
|
+
doneError: Me(W, ne)
|
|
520
497
|
}), W;
|
|
521
498
|
} finally {
|
|
522
|
-
i.donePending = !1,
|
|
499
|
+
i.donePending = !1, R(i) && w({ donePending: !1 });
|
|
523
500
|
}
|
|
524
501
|
})();
|
|
525
502
|
return g.catch(() => {
|
|
526
503
|
}), g;
|
|
527
|
-
},
|
|
528
|
-
const e =
|
|
529
|
-
if (
|
|
530
|
-
if (!
|
|
504
|
+
}, Be = () => {
|
|
505
|
+
const e = F.current;
|
|
506
|
+
if (M !== "ready") return E(`cannot delete while ${M}.`);
|
|
507
|
+
if (!j || !l || !N || z)
|
|
531
508
|
return E("the host gave no delete seam.");
|
|
532
509
|
if (e.saving || e.accepted || e.deleting)
|
|
533
510
|
return E("the task cannot be deleted now.");
|
|
534
|
-
const i =
|
|
511
|
+
const i = l;
|
|
535
512
|
e.deleting = !0, w({ deleting: !0, deleteError: void 0 });
|
|
536
513
|
const h = (async () => {
|
|
537
514
|
try {
|
|
538
|
-
await N(i), e.accepted = !0,
|
|
515
|
+
await N(i), e.accepted = !0, R(e) && (w({ accepted: !0, confirmDeleteOpen: !1 }), O == null || O(i));
|
|
539
516
|
} catch (u) {
|
|
540
|
-
throw
|
|
517
|
+
throw R(e) && w({ deleteError: Me(u, ne) }), u;
|
|
541
518
|
} finally {
|
|
542
|
-
e.deleting = !1,
|
|
519
|
+
e.deleting = !1, R(e) && w({ deleting: !1 });
|
|
543
520
|
}
|
|
544
521
|
})();
|
|
545
522
|
return h.catch(() => {
|
|
@@ -549,10 +526,10 @@ function fn({
|
|
|
549
526
|
i !== "" && (i === h || e.some((u) => u.id === i))
|
|
550
527
|
), Ie = (e) => {
|
|
551
528
|
var g;
|
|
552
|
-
if (
|
|
553
|
-
throw new Error(`TaskEditor: cannot set fields while ${
|
|
554
|
-
if (
|
|
555
|
-
const i =
|
|
529
|
+
if (M !== "ready")
|
|
530
|
+
throw new Error(`TaskEditor: cannot set fields while ${M}.`);
|
|
531
|
+
if (z) throw new Error("TaskEditor: the task is read-only.");
|
|
532
|
+
const i = pn.filter(([W]) => e[W] !== void 0);
|
|
556
533
|
if (i.length > 1)
|
|
557
534
|
throw new Error(
|
|
558
535
|
"TaskEditor: set at most one of patientId, companyId and operatorId."
|
|
@@ -562,18 +539,18 @@ function fn({
|
|
|
562
539
|
throw new Error(
|
|
563
540
|
`TaskEditor: about "${e.about}" does not match the ${h} id.`
|
|
564
541
|
);
|
|
565
|
-
if (e.typeId !== void 0 && !de(
|
|
542
|
+
if (e.typeId !== void 0 && !de(x, e.typeId, b == null ? void 0 : b.typeId))
|
|
566
543
|
throw new Error(`TaskEditor: unknown typeId "${e.typeId}".`);
|
|
567
|
-
if (e.assigneeId !== void 0 && e.assigneeId !== null && !de(
|
|
544
|
+
if (e.assigneeId !== void 0 && e.assigneeId !== null && !de(B, e.assigneeId, b == null ? void 0 : b.assigneeId))
|
|
568
545
|
throw new Error(`TaskEditor: unknown assigneeId "${e.assigneeId}".`);
|
|
569
|
-
if (e.companyId !== void 0 && !de(Y, e.companyId,
|
|
546
|
+
if (e.companyId !== void 0 && !de(Y, e.companyId, b == null ? void 0 : b.companyId))
|
|
570
547
|
throw new Error(`TaskEditor: unknown companyId "${e.companyId}".`);
|
|
571
|
-
if (e.operatorId !== void 0 && !de(
|
|
548
|
+
if (e.operatorId !== void 0 && !de(D, e.operatorId, b == null ? void 0 : b.operatorId))
|
|
572
549
|
throw new Error(`TaskEditor: unknown operatorId "${e.operatorId}".`);
|
|
573
550
|
if (e.patientId !== void 0) {
|
|
574
551
|
if (te)
|
|
575
552
|
throw new Error("TaskEditor: no patient can be set in privacy mode.");
|
|
576
|
-
if (!(de(X, e.patientId,
|
|
553
|
+
if (!(de(X, e.patientId, b == null ? void 0 : b.patientId) || T.has(e.patientId) || (J == null ? void 0 : J(e.patientId)) !== void 0))
|
|
577
554
|
throw new Error(`TaskEditor: unknown patientId "${e.patientId}".`);
|
|
578
555
|
}
|
|
579
556
|
const u = {};
|
|
@@ -583,8 +560,8 @@ function fn({
|
|
|
583
560
|
throw new Error(`TaskEditor: "${e.dateIso}" is not a date.`);
|
|
584
561
|
u.date = W, u.time = Ye(W);
|
|
585
562
|
}
|
|
586
|
-
e.note !== void 0 && (u.note = e.note), e.typeId !== void 0 && (u.typeId = e.typeId), e.assigneeId !== void 0 && (u.assigneeId = e.assigneeId ??
|
|
587
|
-
},
|
|
563
|
+
e.note !== void 0 && (u.note = e.note), e.typeId !== void 0 && (u.typeId = e.typeId), e.assigneeId !== void 0 && (u.assigneeId = e.assigneeId ?? V), e.about !== void 0 && (u.about = e.about), e.patientId !== void 0 && (u.patientId = e.patientId, u.about = "patient"), e.companyId !== void 0 && (u.companyId = e.companyId, u.about = "company"), e.operatorId !== void 0 && (u.operatorId = e.operatorId, u.about = "operator"), he(u);
|
|
564
|
+
}, Fe = () => {
|
|
588
565
|
const e = Se();
|
|
589
566
|
return {
|
|
590
567
|
mode: o,
|
|
@@ -601,31 +578,31 @@ function fn({
|
|
|
601
578
|
};
|
|
602
579
|
};
|
|
603
580
|
return {
|
|
604
|
-
status:
|
|
581
|
+
status: M,
|
|
605
582
|
loadError: (s == null ? void 0 : s.subject) === U ? s.message : void 0,
|
|
606
583
|
retry: Q,
|
|
607
584
|
fields: p,
|
|
608
585
|
patchFields: he,
|
|
609
|
-
stored:
|
|
586
|
+
stored: b,
|
|
610
587
|
chosenTypeId: pe,
|
|
611
588
|
canSave: me,
|
|
612
589
|
/** What the agent's `canSave` reports: the button's rule plus the
|
|
613
590
|
* status, the seam and a save that has not landed yet. */
|
|
614
|
-
agentCanSave:
|
|
615
|
-
showSave: !
|
|
616
|
-
showDelete:
|
|
617
|
-
showDone:
|
|
591
|
+
agentCanSave: M === "ready" && !!be && me && !G.accepted,
|
|
592
|
+
showSave: !z && !!be,
|
|
593
|
+
showDelete: j && !z && !!N && !!l,
|
|
594
|
+
showDone: j && !z && !!ee,
|
|
618
595
|
ui: G,
|
|
619
596
|
patchUi: w,
|
|
620
597
|
/** True once a save or delete landed in this session. */
|
|
621
|
-
isAccepted: () =>
|
|
598
|
+
isAccepted: () => F.current.accepted,
|
|
622
599
|
/** A save or delete is in flight: closing now would lose its outcome. */
|
|
623
|
-
isBusy: () =>
|
|
624
|
-
submit:
|
|
625
|
-
setDone:
|
|
626
|
-
remove:
|
|
600
|
+
isBusy: () => F.current.saving || F.current.deleting,
|
|
601
|
+
submit: Re,
|
|
602
|
+
setDone: Ae,
|
|
603
|
+
remove: Be,
|
|
627
604
|
applyPatch: Ie,
|
|
628
|
-
draftState:
|
|
605
|
+
draftState: Fe
|
|
629
606
|
};
|
|
630
607
|
}
|
|
631
608
|
const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
@@ -641,7 +618,7 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
641
618
|
},
|
|
642
619
|
defaultVariants: { variant: "panel" }
|
|
643
620
|
}), mt = ht(
|
|
644
|
-
`ds:m-0 ds:min-w-0 ds:border-0 ds:p-[var(--spacing-md)] ${
|
|
621
|
+
`ds:m-0 ds:min-w-0 ds:border-0 ds:p-[var(--spacing-md)] ${Wt}`,
|
|
645
622
|
{
|
|
646
623
|
variants: {
|
|
647
624
|
/** 'form': the fields in a column. 'notice': the locked notice. */
|
|
@@ -652,91 +629,91 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
652
629
|
},
|
|
653
630
|
defaultVariants: { layout: "form" }
|
|
654
631
|
}
|
|
655
|
-
),
|
|
656
|
-
(I) => !
|
|
657
|
-
),
|
|
632
|
+
), a = (o) => `calendarWorkspace.taskEditor.${o}`, fn = (o, l, I) => I.includes(l) ? 1 : 0, Ne = [], Ge = (o, l) => Array.from(o.querySelectorAll("[data-task-id]")).filter(
|
|
633
|
+
(I) => !l.contains(I)
|
|
634
|
+
), hn = 'button:not([disabled]), a[href], input:not([disabled]), [tabindex]:not([tabindex="-1"])', ft = (o, l) => {
|
|
658
635
|
if (!o) return [];
|
|
659
636
|
const I = Array.from(
|
|
660
637
|
o.querySelectorAll("[data-action]")
|
|
661
638
|
);
|
|
662
639
|
return [
|
|
663
|
-
...I.filter((
|
|
664
|
-
...I.filter((
|
|
665
|
-
...Array.from(o.querySelectorAll(
|
|
640
|
+
...I.filter((y) => l && y.dataset.action === l),
|
|
641
|
+
...I.filter((y) => y.dataset.action === "open-task"),
|
|
642
|
+
...Array.from(o.querySelectorAll(hn))
|
|
666
643
|
];
|
|
667
|
-
},
|
|
644
|
+
}, gn = At(
|
|
668
645
|
({
|
|
669
646
|
id: o,
|
|
670
|
-
mode:
|
|
647
|
+
mode: l,
|
|
671
648
|
taskId: I,
|
|
672
|
-
initialDate:
|
|
673
|
-
variant:
|
|
674
|
-
open:
|
|
649
|
+
initialDate: y,
|
|
650
|
+
variant: x = "panel",
|
|
651
|
+
open: B = !0,
|
|
675
652
|
onExited: Y,
|
|
676
|
-
taskTypes:
|
|
653
|
+
taskTypes: D = Ne,
|
|
677
654
|
assignees: X = Ne,
|
|
678
|
-
companies:
|
|
655
|
+
companies: T = Ne,
|
|
679
656
|
operators: J = Ne,
|
|
680
657
|
patients: Z = Ne,
|
|
681
|
-
searchPatients:
|
|
658
|
+
searchPatients: P,
|
|
682
659
|
patientLabel: se,
|
|
683
660
|
resolvePatientLabel: N,
|
|
684
661
|
companyLabel: ee,
|
|
685
|
-
operatorLabel:
|
|
686
|
-
backLabel:
|
|
687
|
-
loadTask:
|
|
662
|
+
operatorLabel: _,
|
|
663
|
+
backLabel: O,
|
|
664
|
+
loadTask: z,
|
|
688
665
|
onCreateTask: L,
|
|
689
666
|
onUpdateTask: te,
|
|
690
667
|
onDeleteTask: ne,
|
|
691
|
-
onSetTaskDone:
|
|
668
|
+
onSetTaskDone: j,
|
|
692
669
|
onCancel: m,
|
|
693
670
|
onSaved: S,
|
|
694
|
-
onDeleted:
|
|
671
|
+
onDeleted: ce,
|
|
695
672
|
readOnly: oe = !1,
|
|
696
673
|
privacy: U = !1,
|
|
697
674
|
privacyMode: p = "notice",
|
|
698
675
|
onPrivacyOff: fe,
|
|
699
676
|
className: G,
|
|
700
677
|
...Ee
|
|
701
|
-
},
|
|
702
|
-
const { t:
|
|
703
|
-
mode:
|
|
678
|
+
}, b) => {
|
|
679
|
+
const { t: r } = gt("ui"), w = Bt(), he = o ?? w, ge = l === "edit", re = x === "subview", F = !re || B, ve = U && ge && p === "notice", R = U && !ve, [ue] = q(() => /* @__PURE__ */ new Map()), d = mn({
|
|
680
|
+
mode: l,
|
|
704
681
|
taskId: I,
|
|
705
|
-
initialDate:
|
|
706
|
-
active:
|
|
707
|
-
taskTypes:
|
|
682
|
+
initialDate: y,
|
|
683
|
+
active: F,
|
|
684
|
+
taskTypes: D,
|
|
708
685
|
assignees: X,
|
|
709
|
-
companies:
|
|
686
|
+
companies: T,
|
|
710
687
|
operators: J,
|
|
711
688
|
patients: Z,
|
|
712
689
|
searchedPatients: ue,
|
|
713
690
|
resolvePatientLabel: N,
|
|
714
|
-
loadTask:
|
|
691
|
+
loadTask: z,
|
|
715
692
|
onCreateTask: L,
|
|
716
693
|
onUpdateTask: te,
|
|
717
694
|
onDeleteTask: ne,
|
|
718
|
-
onSetTaskDone:
|
|
695
|
+
onSetTaskDone: j,
|
|
719
696
|
onSaved: S,
|
|
720
|
-
onDeleted:
|
|
697
|
+
onDeleted: ce,
|
|
721
698
|
readOnly: oe,
|
|
722
699
|
withheld: ve,
|
|
723
|
-
maskPatient:
|
|
724
|
-
fallbackError:
|
|
725
|
-
}), { status:
|
|
726
|
-
ke.current =
|
|
727
|
-
const
|
|
728
|
-
() =>
|
|
700
|
+
maskPatient: R,
|
|
701
|
+
fallbackError: r("emptyState.error.title")
|
|
702
|
+
}), { status: A, fields: c, ui: s, stored: f } = d, ke = C(P);
|
|
703
|
+
ke.current = P;
|
|
704
|
+
const ye = !!P, M = Pe(
|
|
705
|
+
() => ye ? async (t, v) => {
|
|
729
706
|
const K = await ke.current(t, v);
|
|
730
707
|
for (const ie of K)
|
|
731
708
|
ue.set(ie.id, ie.name);
|
|
732
709
|
return K;
|
|
733
710
|
} : void 0,
|
|
734
|
-
[
|
|
735
|
-
), Q =
|
|
711
|
+
[ye, ue]
|
|
712
|
+
), Q = C(d);
|
|
736
713
|
Q.current = d;
|
|
737
|
-
const pe =
|
|
714
|
+
const pe = C(m);
|
|
738
715
|
pe.current = m;
|
|
739
|
-
const
|
|
716
|
+
const Ve = Pe(
|
|
740
717
|
() => ({
|
|
741
718
|
getStatus: () => Q.current.status,
|
|
742
719
|
getDraft: () => Q.current.draftState(),
|
|
@@ -753,31 +730,31 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
753
730
|
}),
|
|
754
731
|
[]
|
|
755
732
|
);
|
|
756
|
-
|
|
757
|
-
const me =
|
|
758
|
-
() =>
|
|
759
|
-
[
|
|
760
|
-
), Se =
|
|
761
|
-
|
|
762
|
-
const
|
|
763
|
-
|
|
764
|
-
const
|
|
765
|
-
|
|
733
|
+
_t(ln, F ? Ve : null, he);
|
|
734
|
+
const me = C(null), be = Pe(
|
|
735
|
+
() => Lt(b, me),
|
|
736
|
+
[b]
|
|
737
|
+
), Se = C(null), E = C(null), Re = C(!1);
|
|
738
|
+
re && B && !Re.current && (E.current = typeof document < "u" && document.activeElement instanceof HTMLElement ? document.activeElement : null), Re.current = re && B;
|
|
739
|
+
const Ae = C(B);
|
|
740
|
+
Ae.current = B;
|
|
741
|
+
const Be = C(I);
|
|
742
|
+
Be.current = ge ? I : void 0, qe(() => {
|
|
766
743
|
var st;
|
|
767
744
|
const t = me.current, v = t == null ? void 0 : t.parentElement;
|
|
768
|
-
if (!
|
|
769
|
-
const K = E.current, ie = K && v.contains(K) && !t.contains(K) ? K : null,
|
|
745
|
+
if (!re || !B || !t || !v) return;
|
|
746
|
+
const K = E.current, ie = K && v.contains(K) && !t.contains(K) ? K : null, Nt = Be.current, De = (ie == null ? void 0 : ie.closest("[data-task-id]")) ?? Ge(v, t).find((xe) => xe.dataset.taskId === Nt), rt = De == null ? void 0 : De.dataset.taskId, at = (st = ie == null ? void 0 : ie.closest("[data-action]")) == null ? void 0 : st.dataset.action, it = De ? Ge(v, t).indexOf(De) : -1;
|
|
770
747
|
return () => {
|
|
771
|
-
if (
|
|
772
|
-
const
|
|
773
|
-
if (!v.isConnected ||
|
|
748
|
+
if (Ae.current && t.isConnected) return;
|
|
749
|
+
const xe = document.activeElement;
|
|
750
|
+
if (!v.isConnected || xe && xe !== document.body) return;
|
|
774
751
|
const Ue = Ge(v, t), Rt = [
|
|
775
752
|
...ft(
|
|
776
|
-
Ue.find((we) =>
|
|
777
|
-
|
|
753
|
+
Ue.find((we) => rt !== void 0 && we.dataset.taskId === rt),
|
|
754
|
+
at
|
|
778
755
|
),
|
|
779
756
|
/* The row that took its place, or the last row when it was last. */
|
|
780
|
-
...it >= 0 ? ft(Ue[Math.min(it, Ue.length - 1)],
|
|
757
|
+
...it >= 0 ? ft(Ue[Math.min(it, Ue.length - 1)], at) : [],
|
|
781
758
|
v.querySelector('[data-action="add-task"]'),
|
|
782
759
|
v.querySelector("[data-tasks-panel-region]")
|
|
783
760
|
];
|
|
@@ -785,11 +762,11 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
785
762
|
if (!(!we || t.contains(we)) && (we.focus(), document.activeElement === we))
|
|
786
763
|
return;
|
|
787
764
|
};
|
|
788
|
-
}, [
|
|
789
|
-
const de =
|
|
765
|
+
}, [B, re]);
|
|
766
|
+
const de = C(null), Ie = C(!1), Fe = (t) => () => {
|
|
790
767
|
Ie.current = !0, t();
|
|
791
768
|
};
|
|
792
|
-
|
|
769
|
+
zt(() => {
|
|
793
770
|
var K;
|
|
794
771
|
if (!Ie.current) return;
|
|
795
772
|
const t = me.current, v = document.activeElement;
|
|
@@ -797,68 +774,68 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
797
774
|
Ie.current = !1;
|
|
798
775
|
return;
|
|
799
776
|
}
|
|
800
|
-
|
|
777
|
+
A !== "loading" && (Ie.current = !1), (K = A === "error" ? de.current : t) == null || K.focus({
|
|
801
778
|
preventScroll: !0
|
|
802
779
|
});
|
|
803
|
-
}, [
|
|
804
|
-
const
|
|
805
|
-
() =>
|
|
806
|
-
[
|
|
780
|
+
}, [A]);
|
|
781
|
+
const Ce = r(a(ge ? "editTitle" : "title")), e = T.length > 0, i = J.length > 0, h = ye || Z.length > 0, u = Pe(
|
|
782
|
+
() => T.map((t) => ({ value: t.id, label: t.label })),
|
|
783
|
+
[T]
|
|
807
784
|
), g = (t) => {
|
|
808
785
|
var v;
|
|
809
|
-
return (N == null ? void 0 : N(t)) ?? ((v = Z.find((K) => K.id === t)) == null ? void 0 : v.name) ?? ue.get(t) ?? (t === (f == null ? void 0 : f.patientId) ? se : void 0) ??
|
|
810
|
-
}, W = (t) => t === (f == null ? void 0 : f.operatorId) &&
|
|
811
|
-
{ value:
|
|
786
|
+
return (N == null ? void 0 : N(t)) ?? ((v = Z.find((K) => K.id === t)) == null ? void 0 : v.name) ?? ue.get(t) ?? (t === (f == null ? void 0 : f.patientId) ? se : void 0) ?? r("calendarWorkspace.details.patientNotLoaded");
|
|
787
|
+
}, W = (t) => t === (f == null ? void 0 : f.operatorId) && _ ? _ : r(a("operatorUnresolved"), { id: t }), vt = [
|
|
788
|
+
{ value: V, label: r(a("operatorNone")) },
|
|
812
789
|
...J.map((t) => ({ value: t.id, label: t.label })),
|
|
813
790
|
/* An operator the roster no longer lists is still a real link, so it
|
|
814
791
|
stays pickable and survives a Save. */
|
|
815
|
-
...
|
|
792
|
+
...c.operatorId !== V && !J.some((t) => t.id === c.operatorId) ? [
|
|
816
793
|
{
|
|
817
|
-
value:
|
|
818
|
-
label: W(
|
|
794
|
+
value: c.operatorId,
|
|
795
|
+
label: W(c.operatorId)
|
|
819
796
|
}
|
|
820
797
|
] : []
|
|
821
|
-
], yt =
|
|
822
|
-
...
|
|
798
|
+
], yt = D.some((t) => t.custom) && D.some((t) => !t.custom), bt = [
|
|
799
|
+
...D.map((t) => ({
|
|
823
800
|
value: t.id,
|
|
824
801
|
label: t.label,
|
|
825
|
-
group: yt ? a(
|
|
802
|
+
group: yt ? r(a(t.custom ? "typeGroupCustom" : "typeGroupStandard")) : void 0
|
|
826
803
|
})),
|
|
827
804
|
/* An id the list no longer resolves is still a real link: offered as
|
|
828
805
|
its own option so Save re-sends it. */
|
|
829
|
-
...d.chosenTypeId && !
|
|
806
|
+
...d.chosenTypeId && !D.some((t) => t.id === d.chosenTypeId) ? [
|
|
830
807
|
{
|
|
831
808
|
value: d.chosenTypeId,
|
|
832
|
-
label: a(
|
|
809
|
+
label: r(a("typeUnresolved"), { id: d.chosenTypeId })
|
|
833
810
|
}
|
|
834
811
|
] : []
|
|
835
|
-
],
|
|
836
|
-
{ value:
|
|
812
|
+
], It = [
|
|
813
|
+
{ value: V, label: r(a("assigneeNone")) },
|
|
837
814
|
...X.map((t) => ({ value: t.id, label: t.label })),
|
|
838
|
-
...
|
|
815
|
+
...c.assigneeId !== V && !X.some((t) => t.id === c.assigneeId) ? [
|
|
839
816
|
{
|
|
840
|
-
value:
|
|
841
|
-
label: a(
|
|
817
|
+
value: c.assigneeId,
|
|
818
|
+
label: r(a("assigneeUnresolved"), { id: c.assigneeId })
|
|
842
819
|
}
|
|
843
820
|
] : []
|
|
844
|
-
],
|
|
845
|
-
/* @__PURE__ */ n(
|
|
846
|
-
/* @__PURE__ */ n(
|
|
847
|
-
] }),
|
|
821
|
+
], ae = c.about === "company" && c.companyId && !T.some((t) => t.id === c.companyId) ? c.companyId : void 0, wt = ae && ae === (f == null ? void 0 : f.companyId) && ee ? ee : r(a("companyUnresolved"), { id: ae }), Xe = /* @__PURE__ */ k($, { variant: "info", announce: "off", icon: /* @__PURE__ */ n(Qt, { "aria-hidden": "true" }), children: [
|
|
822
|
+
/* @__PURE__ */ n($.Title, { as: "p", children: r("calendarWorkspace.details.readOnlyTitle") }),
|
|
823
|
+
/* @__PURE__ */ n($.Description, { children: r(a("readOnlyBody")) })
|
|
824
|
+
] }), _e = s.saving || s.deleting, Je = () => {
|
|
848
825
|
d.isBusy() || m();
|
|
849
|
-
},
|
|
826
|
+
}, Et = /* @__PURE__ */ n(
|
|
850
827
|
We,
|
|
851
828
|
{
|
|
852
829
|
size: "sm",
|
|
853
830
|
intent: "outline",
|
|
854
831
|
icon: /* @__PURE__ */ n(Yt, { "aria-hidden": "true" }),
|
|
855
|
-
"aria-label": a(
|
|
856
|
-
tooltip: a(
|
|
832
|
+
"aria-label": r(a("cancel")),
|
|
833
|
+
tooltip: r(a("cancel")),
|
|
857
834
|
"data-action": "cancel-task",
|
|
858
|
-
disabled:
|
|
835
|
+
disabled: _e,
|
|
859
836
|
onClick: Je
|
|
860
837
|
}
|
|
861
|
-
),
|
|
838
|
+
), ze = s.saving || s.accepted, Ze = (t) => /* @__PURE__ */ k(Te, { children: [
|
|
862
839
|
t && d.showDelete ? /* @__PURE__ */ n(
|
|
863
840
|
We,
|
|
864
841
|
{
|
|
@@ -866,41 +843,41 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
866
843
|
size: "sm",
|
|
867
844
|
intent: "destructiveOutline",
|
|
868
845
|
icon: /* @__PURE__ */ n(dt, { "aria-hidden": "true" }),
|
|
869
|
-
"aria-label": a(
|
|
870
|
-
tooltip: a(
|
|
846
|
+
"aria-label": r(a("delete")),
|
|
847
|
+
tooltip: r(a("delete")),
|
|
871
848
|
"data-action": "delete-task",
|
|
872
|
-
disabled:
|
|
849
|
+
disabled: _e || s.accepted,
|
|
873
850
|
onClick: () => d.patchUi({ confirmDeleteOpen: !0, deleteError: void 0 })
|
|
874
851
|
}
|
|
875
852
|
) : null,
|
|
876
853
|
/* @__PURE__ */ k(
|
|
877
|
-
|
|
854
|
+
xt,
|
|
878
855
|
{
|
|
879
856
|
role: "toolbar",
|
|
880
|
-
"aria-label": a(
|
|
857
|
+
"aria-label": r(a("actionsLabel")),
|
|
881
858
|
className: "ds:ms-auto",
|
|
882
859
|
children: [
|
|
883
|
-
|
|
860
|
+
Et,
|
|
884
861
|
t && d.showSave ? /* @__PURE__ */ n(
|
|
885
862
|
We,
|
|
886
863
|
{
|
|
887
864
|
size: "sm",
|
|
888
865
|
intent: "primary",
|
|
889
866
|
icon: s.saving ? /* @__PURE__ */ n(
|
|
890
|
-
|
|
867
|
+
nn,
|
|
891
868
|
{
|
|
892
869
|
"aria-hidden": "true",
|
|
893
870
|
className: "ds:animate-spin ds:motion-reduce:animate-none"
|
|
894
871
|
}
|
|
895
872
|
) : /* @__PURE__ */ n(an, { "aria-hidden": "true" }),
|
|
896
|
-
"aria-label": a(
|
|
897
|
-
tooltip: a(
|
|
898
|
-
disabled: !
|
|
899
|
-
"aria-disabled":
|
|
873
|
+
"aria-label": r(a("save")),
|
|
874
|
+
tooltip: r(a("save")),
|
|
875
|
+
disabled: !ze && !d.canSave,
|
|
876
|
+
"aria-disabled": ze || void 0,
|
|
900
877
|
"aria-busy": s.saving || void 0,
|
|
901
878
|
"data-action": "save-task",
|
|
902
879
|
onClick: () => {
|
|
903
|
-
|
|
880
|
+
ze || d.submit();
|
|
904
881
|
}
|
|
905
882
|
}
|
|
906
883
|
) : null
|
|
@@ -909,10 +886,10 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
909
886
|
),
|
|
910
887
|
t && d.showSave ? (
|
|
911
888
|
/* Out of flow, so it never moves the footer's two ends. */
|
|
912
|
-
/* @__PURE__ */ n("span", { role: "status", className: "ds:sr-only", children: s.saving ? a(
|
|
889
|
+
/* @__PURE__ */ n("span", { role: "status", className: "ds:sr-only", children: s.saving ? r(a("saving")) : "" })
|
|
913
890
|
) : null
|
|
914
|
-
] }),
|
|
915
|
-
/* @__PURE__ */ n("span", { role: "status", className: "ds:sr-only", children:
|
|
891
|
+
] }), kt = /* @__PURE__ */ k("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)] ds:p-[var(--spacing-md)]", children: [
|
|
892
|
+
/* @__PURE__ */ n("span", { role: "status", className: "ds:sr-only", children: r("common.loading") }),
|
|
916
893
|
/* @__PURE__ */ k(
|
|
917
894
|
"div",
|
|
918
895
|
{
|
|
@@ -945,55 +922,55 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
945
922
|
]
|
|
946
923
|
}
|
|
947
924
|
)
|
|
948
|
-
] }),
|
|
949
|
-
/* @__PURE__ */ n(
|
|
925
|
+
] }), St = /* @__PURE__ */ k("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)] ds:p-[var(--spacing-md)]", children: [
|
|
926
|
+
/* @__PURE__ */ n($, { variant: "error", children: /* @__PURE__ */ n($.Description, { children: d.loadError }) }),
|
|
950
927
|
/* @__PURE__ */ n(
|
|
951
|
-
|
|
928
|
+
$e,
|
|
952
929
|
{
|
|
953
930
|
ref: de,
|
|
954
931
|
intent: "outline",
|
|
955
932
|
"data-action": "retry-load",
|
|
956
|
-
onClick:
|
|
957
|
-
children:
|
|
933
|
+
onClick: Fe(d.retry),
|
|
934
|
+
children: r("emptyState.error.cta")
|
|
958
935
|
}
|
|
959
936
|
)
|
|
960
|
-
] }), Ct = /* @__PURE__ */ n("fieldset", { disabled: !0, className: mt({ layout: "notice" }), children: Xe }), Dt = () =>
|
|
961
|
-
|
|
937
|
+
] }), Ct = /* @__PURE__ */ n("fieldset", { disabled: !0, className: mt({ layout: "notice" }), children: Xe }), Dt = () => c.about !== "patient" ? null : R ? /* @__PURE__ */ n(H, { label: r(a("aboutPatient")), children: /* @__PURE__ */ n(je, { value: tn(), disabled: !0, readOnly: !0 }) }) : h ? /* @__PURE__ */ n(H, { label: r(a("aboutPatient")), children: /* @__PURE__ */ n(
|
|
938
|
+
sn,
|
|
962
939
|
{
|
|
963
|
-
value:
|
|
940
|
+
value: c.patientId,
|
|
964
941
|
onValueChange: (t) => d.patchFields({ patientId: t }),
|
|
965
942
|
patients: Z,
|
|
966
|
-
searchPatients:
|
|
967
|
-
selectedLabel:
|
|
968
|
-
placeholder:
|
|
943
|
+
searchPatients: M,
|
|
944
|
+
selectedLabel: c.patientId ? g(c.patientId) : void 0,
|
|
945
|
+
placeholder: r("calendarWorkspace.editor.patientSearch"),
|
|
969
946
|
disabled: oe
|
|
970
947
|
}
|
|
971
|
-
) }) :
|
|
948
|
+
) }) : c.patientId ? /* @__PURE__ */ n(H, { label: r(a("aboutPatient")), children: /* @__PURE__ */ n(je, { value: g(c.patientId), disabled: !0, readOnly: !0 }) }) : null, et = /* @__PURE__ */ k("fieldset", { disabled: oe, className: mt(), children: [
|
|
972
949
|
oe ? Xe : null,
|
|
973
|
-
/* @__PURE__ */ n(H, { label: a(
|
|
974
|
-
|
|
950
|
+
/* @__PURE__ */ n(H, { label: r(a("date")), children: /* @__PURE__ */ n(
|
|
951
|
+
Ft,
|
|
975
952
|
{
|
|
976
|
-
value:
|
|
953
|
+
value: c.date,
|
|
977
954
|
onChange: (t) => d.patchFields({ date: t })
|
|
978
955
|
}
|
|
979
956
|
) }),
|
|
980
|
-
/* @__PURE__ */ n(H, { label: a(
|
|
981
|
-
|
|
957
|
+
/* @__PURE__ */ n(H, { label: r(a("time")), children: /* @__PURE__ */ n(
|
|
958
|
+
Vt,
|
|
982
959
|
{
|
|
983
|
-
value:
|
|
960
|
+
value: c.time,
|
|
984
961
|
onChange: (t) => d.patchFields({ time: t })
|
|
985
962
|
}
|
|
986
963
|
) }),
|
|
987
964
|
/* @__PURE__ */ n(
|
|
988
965
|
H,
|
|
989
966
|
{
|
|
990
|
-
label: a(
|
|
967
|
+
label: r(a("note")),
|
|
991
968
|
required: !0,
|
|
992
|
-
error: s.showError &&
|
|
969
|
+
error: s.showError && c.note.trim() === "" ? r(a("noteRequired")) : void 0,
|
|
993
970
|
children: /* @__PURE__ */ n(
|
|
994
|
-
|
|
971
|
+
qt,
|
|
995
972
|
{
|
|
996
|
-
value:
|
|
973
|
+
value: c.note,
|
|
997
974
|
onChange: (t) => {
|
|
998
975
|
d.patchFields({ note: t.target.value }), d.patchUi({ showError: !1 });
|
|
999
976
|
},
|
|
@@ -1003,117 +980,117 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
1003
980
|
)
|
|
1004
981
|
}
|
|
1005
982
|
),
|
|
1006
|
-
|
|
983
|
+
D.length > 0 ? /* @__PURE__ */ n(H, { label: r(a("type")), required: !0, children: /* @__PURE__ */ n(
|
|
1007
984
|
Ke,
|
|
1008
985
|
{
|
|
1009
|
-
options:
|
|
986
|
+
options: bt,
|
|
1010
987
|
value: d.chosenTypeId,
|
|
1011
988
|
onValueChange: (t) => t && d.patchFields({ typeId: t })
|
|
1012
989
|
}
|
|
1013
990
|
) }) : null,
|
|
1014
|
-
X.length > 0 ? /* @__PURE__ */ n(H, { label: a(
|
|
991
|
+
X.length > 0 ? /* @__PURE__ */ n(H, { label: r(a("assignee")), children: /* @__PURE__ */ n(
|
|
1015
992
|
Ke,
|
|
1016
993
|
{
|
|
1017
|
-
options:
|
|
1018
|
-
value:
|
|
994
|
+
options: It,
|
|
995
|
+
value: c.assigneeId,
|
|
1019
996
|
onValueChange: (t) => t && d.patchFields({ assigneeId: t })
|
|
1020
997
|
}
|
|
1021
998
|
) }) : null,
|
|
1022
999
|
/* @__PURE__ */ k(
|
|
1023
1000
|
jt,
|
|
1024
1001
|
{
|
|
1025
|
-
label: a(
|
|
1002
|
+
label: r(a("about")),
|
|
1026
1003
|
variant: "segmented",
|
|
1027
|
-
className:
|
|
1028
|
-
value:
|
|
1004
|
+
className: Ut,
|
|
1005
|
+
value: c.about,
|
|
1029
1006
|
onValueChange: (t) => d.patchFields({ about: t }),
|
|
1030
1007
|
children: [
|
|
1031
1008
|
/* @__PURE__ */ n(
|
|
1032
|
-
|
|
1009
|
+
Oe,
|
|
1033
1010
|
{
|
|
1034
1011
|
value: "nobody",
|
|
1035
|
-
label: a(
|
|
1036
|
-
icon: /* @__PURE__ */ n(
|
|
1012
|
+
label: r(a("aboutNobody")),
|
|
1013
|
+
icon: /* @__PURE__ */ n(Xt, { "aria-hidden": "true" })
|
|
1037
1014
|
}
|
|
1038
1015
|
),
|
|
1039
|
-
h ||
|
|
1040
|
-
|
|
1016
|
+
h || c.about === "patient" || f != null && f.patientId ? /* @__PURE__ */ n(
|
|
1017
|
+
Oe,
|
|
1041
1018
|
{
|
|
1042
1019
|
value: "patient",
|
|
1043
|
-
label: a(
|
|
1044
|
-
icon: /* @__PURE__ */ n(
|
|
1020
|
+
label: r(a("aboutPatient")),
|
|
1021
|
+
icon: /* @__PURE__ */ n(Jt, { "aria-hidden": "true" })
|
|
1045
1022
|
}
|
|
1046
1023
|
) : null,
|
|
1047
|
-
e ||
|
|
1048
|
-
|
|
1024
|
+
e || c.about === "company" || f != null && f.companyId ? /* @__PURE__ */ n(
|
|
1025
|
+
Oe,
|
|
1049
1026
|
{
|
|
1050
1027
|
value: "company",
|
|
1051
|
-
label: a(
|
|
1052
|
-
icon: /* @__PURE__ */ n(
|
|
1028
|
+
label: r(a("aboutCompany")),
|
|
1029
|
+
icon: /* @__PURE__ */ n(Zt, { "aria-hidden": "true" })
|
|
1053
1030
|
}
|
|
1054
1031
|
) : null,
|
|
1055
|
-
i ||
|
|
1056
|
-
|
|
1032
|
+
i || c.about === "operator" || f != null && f.operatorId ? /* @__PURE__ */ n(
|
|
1033
|
+
Oe,
|
|
1057
1034
|
{
|
|
1058
1035
|
value: "operator",
|
|
1059
|
-
label: a(
|
|
1060
|
-
icon: /* @__PURE__ */ n(
|
|
1036
|
+
label: r(a("aboutOperator")),
|
|
1037
|
+
icon: /* @__PURE__ */ n(en, { "aria-hidden": "true" })
|
|
1061
1038
|
}
|
|
1062
1039
|
) : null
|
|
1063
1040
|
]
|
|
1064
1041
|
}
|
|
1065
1042
|
),
|
|
1066
1043
|
Dt(),
|
|
1067
|
-
|
|
1068
|
-
|
|
1044
|
+
c.about === "company" ? /* @__PURE__ */ k(Te, { children: [
|
|
1045
|
+
ae ? /* @__PURE__ */ n(H, { label: r(a("companyName")), children: /* @__PURE__ */ n(je, { value: wt, disabled: !0, readOnly: !0 }) }) : null,
|
|
1069
1046
|
e ? /* @__PURE__ */ n(
|
|
1070
1047
|
H,
|
|
1071
1048
|
{
|
|
1072
|
-
label:
|
|
1073
|
-
|
|
1049
|
+
label: r(
|
|
1050
|
+
a(ae ? "companyReplace" : "companyName")
|
|
1074
1051
|
),
|
|
1075
1052
|
children: /* @__PURE__ */ n(
|
|
1076
1053
|
Qe,
|
|
1077
1054
|
{
|
|
1078
1055
|
options: u,
|
|
1079
|
-
value:
|
|
1080
|
-
onValueChange: (t) =>
|
|
1081
|
-
clearable: !
|
|
1082
|
-
filter:
|
|
1083
|
-
placeholder: a(
|
|
1084
|
-
"aria-label":
|
|
1085
|
-
|
|
1056
|
+
value: ae ? "" : c.companyId,
|
|
1057
|
+
onValueChange: (t) => ae ? t && d.patchFields({ companyId: t }) : d.patchFields({ companyId: t }),
|
|
1058
|
+
clearable: !ae && !oe,
|
|
1059
|
+
filter: fn,
|
|
1060
|
+
placeholder: r(a("companySearch")),
|
|
1061
|
+
"aria-label": r(
|
|
1062
|
+
a(ae ? "companyReplace" : "companyName")
|
|
1086
1063
|
)
|
|
1087
1064
|
}
|
|
1088
1065
|
)
|
|
1089
1066
|
}
|
|
1090
1067
|
) : null
|
|
1091
1068
|
] }) : null,
|
|
1092
|
-
|
|
1069
|
+
c.about === "operator" ? i ? /* @__PURE__ */ n(H, { label: r(a("operator")), children: /* @__PURE__ */ n(
|
|
1093
1070
|
Ke,
|
|
1094
1071
|
{
|
|
1095
|
-
options:
|
|
1096
|
-
value:
|
|
1072
|
+
options: vt,
|
|
1073
|
+
value: c.operatorId,
|
|
1097
1074
|
onValueChange: (t) => t && d.patchFields({ operatorId: t })
|
|
1098
1075
|
}
|
|
1099
|
-
) }) :
|
|
1076
|
+
) }) : c.operatorId !== V ? (
|
|
1100
1077
|
/* No roster to pick from: name the link read-only. */
|
|
1101
|
-
/* @__PURE__ */ n(H, { label: a(
|
|
1102
|
-
|
|
1078
|
+
/* @__PURE__ */ n(H, { label: r(a("operator")), children: /* @__PURE__ */ n(
|
|
1079
|
+
je,
|
|
1103
1080
|
{
|
|
1104
|
-
value: W(
|
|
1081
|
+
value: W(c.operatorId),
|
|
1105
1082
|
disabled: !0,
|
|
1106
1083
|
readOnly: !0
|
|
1107
1084
|
}
|
|
1108
1085
|
) })
|
|
1109
1086
|
) : null : null,
|
|
1110
|
-
d.showDone ? /* @__PURE__ */ k(
|
|
1087
|
+
d.showDone ? /* @__PURE__ */ k(Te, { children: [
|
|
1111
1088
|
/* @__PURE__ */ n(
|
|
1112
1089
|
$t,
|
|
1113
1090
|
{
|
|
1114
|
-
label: a(
|
|
1091
|
+
label: r(a("done")),
|
|
1115
1092
|
checked: s.done,
|
|
1116
|
-
disabled:
|
|
1093
|
+
disabled: _e || s.accepted,
|
|
1117
1094
|
"aria-disabled": s.donePending || void 0,
|
|
1118
1095
|
"aria-busy": s.donePending || void 0,
|
|
1119
1096
|
className: "ds:aria-disabled:cursor-progress",
|
|
@@ -1122,26 +1099,26 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
1122
1099
|
}
|
|
1123
1100
|
}
|
|
1124
1101
|
),
|
|
1125
|
-
s.doneError ? /* @__PURE__ */ n(
|
|
1102
|
+
s.doneError ? /* @__PURE__ */ n($, { variant: "error", children: /* @__PURE__ */ n($.Description, { children: s.doneError }) }) : null
|
|
1126
1103
|
] }) : null,
|
|
1127
|
-
s.saveError ? /* @__PURE__ */ n(
|
|
1128
|
-
s.deleteError && !s.confirmDeleteOpen ? /* @__PURE__ */ n(
|
|
1129
|
-
] }), tt =
|
|
1104
|
+
s.saveError ? /* @__PURE__ */ n($, { variant: "error", children: /* @__PURE__ */ n($.Description, { children: s.saveError }) }) : null,
|
|
1105
|
+
s.deleteError && !s.confirmDeleteOpen ? /* @__PURE__ */ n($, { variant: "error", children: /* @__PURE__ */ n($.Description, { children: s.deleteError }) }) : null
|
|
1106
|
+
] }), tt = A === "loading" ? kt : A === "error" ? St : A === "locked" ? Ct : A === "withheld" ? /* @__PURE__ */ n(
|
|
1130
1107
|
Ht,
|
|
1131
1108
|
{
|
|
1132
|
-
onTurnOff: fe ?
|
|
1109
|
+
onTurnOff: fe ? Fe(fe) : void 0
|
|
1133
1110
|
}
|
|
1134
|
-
) :
|
|
1135
|
-
|
|
1111
|
+
) : re ? et : /* @__PURE__ */ n(Mt, { orientation: "vertical", className: "ds:min-h-0 ds:flex-1", children: et }), Le = A === "ready" ? Ze(!0) : A === "locked" || A === "withheld" ? Ze(!1) : null, Tt = A === "ready" && d.showDelete, nt = ge ? /* @__PURE__ */ n(
|
|
1112
|
+
le,
|
|
1136
1113
|
{
|
|
1137
|
-
open: s.confirmDeleteOpen &&
|
|
1114
|
+
open: s.confirmDeleteOpen && F,
|
|
1138
1115
|
onOpenChange: (t) => {
|
|
1139
1116
|
s.deleting || d.patchUi(
|
|
1140
1117
|
t ? { confirmDeleteOpen: !0 } : { confirmDeleteOpen: !1, deleteError: void 0 }
|
|
1141
1118
|
);
|
|
1142
1119
|
},
|
|
1143
1120
|
children: /* @__PURE__ */ k(
|
|
1144
|
-
|
|
1121
|
+
le.Content,
|
|
1145
1122
|
{
|
|
1146
1123
|
size: "sm",
|
|
1147
1124
|
variant: "alert",
|
|
@@ -1150,15 +1127,15 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
1150
1127
|
t.preventDefault(), d.isAccepted() || (v = Se.current) == null || v.focus();
|
|
1151
1128
|
},
|
|
1152
1129
|
children: [
|
|
1153
|
-
/* @__PURE__ */ k(
|
|
1154
|
-
/* @__PURE__ */ n(
|
|
1155
|
-
/* @__PURE__ */ n(
|
|
1130
|
+
/* @__PURE__ */ k(le.Header, { children: [
|
|
1131
|
+
/* @__PURE__ */ n(le.Title, { children: r(a("deleteConfirmTitle")) }),
|
|
1132
|
+
/* @__PURE__ */ n(le.Description, { children: r(a("deleteConfirmBody")) })
|
|
1156
1133
|
] }),
|
|
1157
|
-
s.deleteError ? /* @__PURE__ */ n(
|
|
1158
|
-
/* @__PURE__ */ k(
|
|
1159
|
-
/* @__PURE__ */ n(
|
|
1134
|
+
s.deleteError ? /* @__PURE__ */ n(le.Body, { children: /* @__PURE__ */ n($, { variant: "error", children: /* @__PURE__ */ n($.Description, { children: s.deleteError }) }) }) : null,
|
|
1135
|
+
/* @__PURE__ */ k(le.Footer, { divider: !0, children: [
|
|
1136
|
+
/* @__PURE__ */ n(le.Close, { asChild: !0, children: /* @__PURE__ */ n($e, { intent: "outline", "aria-disabled": s.deleting || void 0, children: r(a("deleteCancel")) }) }),
|
|
1160
1137
|
/* @__PURE__ */ n(
|
|
1161
|
-
|
|
1138
|
+
$e,
|
|
1162
1139
|
{
|
|
1163
1140
|
intent: "destructive",
|
|
1164
1141
|
startIcon: /* @__PURE__ */ n(dt, { "aria-hidden": "true" }),
|
|
@@ -1167,7 +1144,7 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
1167
1144
|
onClick: () => {
|
|
1168
1145
|
s.deleting || d.remove();
|
|
1169
1146
|
},
|
|
1170
|
-
children: a(
|
|
1147
|
+
children: r(a("deleteConfirm"))
|
|
1171
1148
|
}
|
|
1172
1149
|
)
|
|
1173
1150
|
] })
|
|
@@ -1178,46 +1155,46 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
1178
1155
|
) : null, ot = {
|
|
1179
1156
|
"data-component": "task-editor",
|
|
1180
1157
|
"data-component-id": he,
|
|
1181
|
-
"data-variant":
|
|
1182
|
-
"data-status":
|
|
1158
|
+
"data-variant": x,
|
|
1159
|
+
"data-status": A
|
|
1183
1160
|
};
|
|
1184
|
-
return
|
|
1161
|
+
return re ? /* @__PURE__ */ k(Te, { children: [
|
|
1185
1162
|
/* @__PURE__ */ n(
|
|
1186
1163
|
Ot,
|
|
1187
1164
|
{
|
|
1188
1165
|
...Ee,
|
|
1189
1166
|
"data-component-id": he,
|
|
1190
|
-
"data-variant":
|
|
1191
|
-
"data-status":
|
|
1192
|
-
ref:
|
|
1193
|
-
open:
|
|
1167
|
+
"data-variant": x,
|
|
1168
|
+
"data-status": A,
|
|
1169
|
+
ref: be,
|
|
1170
|
+
open: B,
|
|
1194
1171
|
onBack: Je,
|
|
1195
1172
|
onExited: Y,
|
|
1196
|
-
title:
|
|
1197
|
-
icon: /* @__PURE__ */ n(
|
|
1198
|
-
backLabel:
|
|
1173
|
+
title: Ce,
|
|
1174
|
+
icon: /* @__PURE__ */ n(lt, { "aria-hidden": "true" }),
|
|
1175
|
+
backLabel: O ?? r(a("back")),
|
|
1199
1176
|
footer: Le,
|
|
1200
|
-
footerAlign:
|
|
1177
|
+
footerAlign: Tt ? "between" : "end",
|
|
1201
1178
|
className: G,
|
|
1202
|
-
children: /* @__PURE__ */ n("div", { ...ot, className: pt({ variant:
|
|
1179
|
+
children: /* @__PURE__ */ n("div", { ...ot, className: pt({ variant: x }), children: tt })
|
|
1203
1180
|
}
|
|
1204
1181
|
),
|
|
1205
1182
|
nt
|
|
1206
|
-
] }) : /* @__PURE__ */ k(
|
|
1183
|
+
] }) : /* @__PURE__ */ k(Te, { children: [
|
|
1207
1184
|
/* @__PURE__ */ k(
|
|
1208
1185
|
"div",
|
|
1209
1186
|
{
|
|
1210
1187
|
tabIndex: -1,
|
|
1211
1188
|
...Ee,
|
|
1212
1189
|
...ot,
|
|
1213
|
-
ref:
|
|
1214
|
-
className: pt({ variant:
|
|
1190
|
+
ref: be,
|
|
1191
|
+
className: pt({ variant: x, className: G }),
|
|
1215
1192
|
children: [
|
|
1216
1193
|
/* @__PURE__ */ n(
|
|
1217
1194
|
Pt,
|
|
1218
1195
|
{
|
|
1219
|
-
title:
|
|
1220
|
-
icon: /* @__PURE__ */ n(
|
|
1196
|
+
title: Ce,
|
|
1197
|
+
icon: /* @__PURE__ */ n(lt, { "aria-hidden": "true" }),
|
|
1221
1198
|
sticky: !0,
|
|
1222
1199
|
divider: !0
|
|
1223
1200
|
}
|
|
@@ -1231,12 +1208,11 @@ const pt = ht("ds:flex ds:min-h-0 ds:flex-col", {
|
|
|
1231
1208
|
] });
|
|
1232
1209
|
}
|
|
1233
1210
|
);
|
|
1234
|
-
|
|
1211
|
+
gn.displayName = "TaskEditor";
|
|
1235
1212
|
export {
|
|
1236
|
-
|
|
1237
|
-
dn as P,
|
|
1213
|
+
sn as P,
|
|
1238
1214
|
an as S,
|
|
1239
|
-
|
|
1215
|
+
gn as T,
|
|
1240
1216
|
ln as t
|
|
1241
1217
|
};
|
|
1242
|
-
//# sourceMappingURL=task-editor-
|
|
1218
|
+
//# sourceMappingURL=task-editor-DgUjtqpX.js.map
|