@alfadocs/ui-kit-debug 1.56.0 → 1.58.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-fields-BfjxS05Z.js → address-fields-CJtu7LQU.js} +2 -2
- package/dist/_chunks/{address-fields-BfjxS05Z.js.map → address-fields-CJtu7LQU.js.map} +1 -1
- package/dist/_chunks/{ai-credits-notice-BoNJtOuE.js → ai-credits-notice-ktklr8fy.js} +2 -2
- package/dist/_chunks/{ai-credits-notice-BoNJtOuE.js.map → ai-credits-notice-ktklr8fy.js.map} +1 -1
- package/dist/_chunks/ai-permission-notice-DyuEGwAt.js +206 -0
- package/dist/_chunks/ai-permission-notice-DyuEGwAt.js.map +1 -0
- package/dist/_chunks/alia-sidebar-dybRpWml.js +1284 -0
- package/dist/_chunks/alia-sidebar-dybRpWml.js.map +1 -0
- package/dist/_chunks/{anamnesis-summary-rows-CQ-XGr0T.js → anamnesis-summary-rows-M-FUkw9p.js} +6 -6
- package/dist/_chunks/{anamnesis-summary-rows-CQ-XGr0T.js.map → anamnesis-summary-rows-M-FUkw9p.js.map} +1 -1
- package/dist/_chunks/{app-frame-B-0O9CrU.js → app-frame-CqmDh2v5.js} +2 -2
- package/dist/_chunks/{app-frame-B-0O9CrU.js.map → app-frame-CqmDh2v5.js.map} +1 -1
- package/dist/_chunks/{appointment-peek-BIZaDeCi.js → appointment-peek-WvNbE4JG.js} +2 -2
- package/dist/_chunks/{appointment-peek-BIZaDeCi.js.map → appointment-peek-WvNbE4JG.js.map} +1 -1
- package/dist/_chunks/{appointment-timeline-DmqYEIT9.js → appointment-timeline-Z0494xO-.js} +2 -2
- package/dist/_chunks/{appointment-timeline-DmqYEIT9.js.map → appointment-timeline-Z0494xO-.js.map} +1 -1
- package/dist/_chunks/{balance-badge-cell-DmDcXw0c.js → balance-badge-cell-CGoJZlKf.js} +3 -3
- package/dist/_chunks/{balance-badge-cell-DmDcXw0c.js.map → balance-badge-cell-CGoJZlKf.js.map} +1 -1
- package/dist/_chunks/{booking-WyNGKPE2.js → booking-CiFSAMR-.js} +4 -4
- package/dist/_chunks/{booking-WyNGKPE2.js.map → booking-CiFSAMR-.js.map} +1 -1
- package/dist/_chunks/{calculator-dialog-pCPWta7h.js → calculator-dialog-CzQv03p0.js} +2 -2
- package/dist/_chunks/{calculator-dialog-pCPWta7h.js.map → calculator-dialog-CzQv03p0.js.map} +1 -1
- package/dist/_chunks/{calendar-workspace-Du2ryaI-.js → calendar-workspace-DNHzjG7O.js} +19 -19
- package/dist/_chunks/calendar-workspace-DNHzjG7O.js.map +1 -0
- package/dist/_chunks/{care-plan-card-Ddjh5Doc.js → care-plan-card-DxrRLRdW.js} +2 -2
- package/dist/_chunks/{care-plan-card-Ddjh5Doc.js.map → care-plan-card-DxrRLRdW.js.map} +1 -1
- package/dist/_chunks/{care-plan-header-DUX_SVvF.js → care-plan-header-BMwZIgHJ.js} +2 -2
- package/dist/_chunks/{care-plan-header-DUX_SVvF.js.map → care-plan-header-BMwZIgHJ.js.map} +1 -1
- package/dist/_chunks/{chart-HsF1KHbx.js → chart-ZMkX-Gqy.js} +338 -341
- package/dist/_chunks/chart-ZMkX-Gqy.js.map +1 -0
- package/dist/_chunks/{city-input-BC_nYINn.js → city-input-3J3bz9EO.js} +2 -2
- package/dist/_chunks/{city-input-BC_nYINn.js.map → city-input-3J3bz9EO.js.map} +1 -1
- package/dist/_chunks/{clinical-note-card-14JIoUR0.js → clinical-note-card-hx939bvw.js} +2 -2
- package/dist/_chunks/{clinical-note-card-14JIoUR0.js.map → clinical-note-card-hx939bvw.js.map} +1 -1
- package/dist/_chunks/{color-picker-BRQ4Y9SO.js → color-picker-BsggJovx.js} +128 -123
- package/dist/_chunks/color-picker-BsggJovx.js.map +1 -0
- package/dist/_chunks/{contact-card-CmK05vNb.js → contact-card-fHBMwEsx.js} +2 -2
- package/dist/_chunks/{contact-card-CmK05vNb.js.map → contact-card-fHBMwEsx.js.map} +1 -1
- package/dist/_chunks/{contact-profile-card-Ci8lBQ6a.js → contact-profile-card-CMyBYgRR.js} +2 -2
- package/dist/_chunks/{contact-profile-card-Ci8lBQ6a.js.map → contact-profile-card-CMyBYgRR.js.map} +1 -1
- package/dist/_chunks/{control-room-rail-Tx2jW250.js → control-room-rail-CJ85HkS2.js} +2 -2
- package/dist/_chunks/{control-room-rail-Tx2jW250.js.map → control-room-rail-CJ85HkS2.js.map} +1 -1
- package/dist/_chunks/{cycle-calculator-Dgfqr4Q4.js → cycle-calculator-Cww9DzIa.js} +2 -2
- package/dist/_chunks/{cycle-calculator-Dgfqr4Q4.js.map → cycle-calculator-Cww9DzIa.js.map} +1 -1
- package/dist/_chunks/dashboard-grid-Cs7cJAsA.js +933 -0
- package/dist/_chunks/dashboard-grid-Cs7cJAsA.js.map +1 -0
- package/dist/_chunks/{data-table-D8fuhqO1.js → data-table-Yn5xiGzs.js} +3 -3
- package/dist/_chunks/{data-table-D8fuhqO1.js.map → data-table-Yn5xiGzs.js.map} +1 -1
- package/dist/_chunks/{data-table-tabs-Xhg5G0gU.js → data-table-tabs-CHYAAeHy.js} +2 -2
- package/dist/_chunks/{data-table-tabs-Xhg5G0gU.js.map → data-table-tabs-CHYAAeHy.js.map} +1 -1
- package/dist/_chunks/{date-picker-wRAcq2lt.js → date-picker-BSZuKo13.js} +69 -62
- package/dist/_chunks/date-picker-BSZuKo13.js.map +1 -0
- package/dist/_chunks/{date-range-picker-CtUOI38x.js → date-range-picker-CFk-5O3R.js} +176 -171
- package/dist/_chunks/date-range-picker-CFk-5O3R.js.map +1 -0
- package/dist/_chunks/{date-time-picker-CLeLKuv9.js → date-time-picker-CjxTkblD.js} +92 -85
- package/dist/_chunks/date-time-picker-CjxTkblD.js.map +1 -0
- package/dist/_chunks/{dialog-CUzbnKLw.js → dialog-Dn-iQ0Jp.js} +2 -2
- package/dist/_chunks/{dialog-CUzbnKLw.js.map → dialog-Dn-iQ0Jp.js.map} +1 -1
- package/dist/_chunks/{document-preview-uoTekVR7.js → document-preview-CHGGG0l_.js} +2 -2
- package/dist/_chunks/{document-preview-uoTekVR7.js.map → document-preview-CHGGG0l_.js.map} +1 -1
- package/dist/_chunks/{due-date-calculator-CSjklbyw.js → due-date-calculator-D_qFUiHp.js} +2 -2
- package/dist/_chunks/{due-date-calculator-CSjklbyw.js.map → due-date-calculator-D_qFUiHp.js.map} +1 -1
- package/dist/_chunks/{entity-summary-DcB0fIiv.js → entity-summary-CWcCSThK.js} +2 -2
- package/dist/_chunks/{entity-summary-DcB0fIiv.js.map → entity-summary-CWcCSThK.js.map} +1 -1
- package/dist/_chunks/{face-scheme-BicuUA2K.js → face-scheme-DSKDdIsb.js} +2 -2
- package/dist/_chunks/{face-scheme-BicuUA2K.js.map → face-scheme-DSKDdIsb.js.map} +1 -1
- package/dist/_chunks/{file-manager-Cc_uO8r2.js → file-manager-DEtkQR1F.js} +4 -4
- package/dist/_chunks/{file-manager-Cc_uO8r2.js.map → file-manager-DEtkQR1F.js.map} +1 -1
- package/dist/_chunks/{forgot-password-form-DEx-M_QR.js → forgot-password-form-CEqOmNuX.js} +2 -2
- package/dist/_chunks/{forgot-password-form-DEx-M_QR.js.map → forgot-password-form-CEqOmNuX.js.map} +1 -1
- package/dist/_chunks/{gestational-age-calculator-DqVeJke2.js → gestational-age-calculator-CZi43xKG.js} +2 -2
- package/dist/_chunks/{gestational-age-calculator-DqVeJke2.js.map → gestational-age-calculator-CZi43xKG.js.map} +1 -1
- package/dist/_chunks/{hcg-doubling-BIYyI2Yo.js → hcg-doubling-Ccvh7OaU.js} +2 -2
- package/dist/_chunks/{hcg-doubling-BIYyI2Yo.js.map → hcg-doubling-Ccvh7OaU.js.map} +1 -1
- package/dist/_chunks/{header-settings-ge_3gYEq.js → header-settings-BMcCx2LC.js} +2 -2
- package/dist/_chunks/{header-settings-ge_3gYEq.js.map → header-settings-BMcCx2LC.js.map} +1 -1
- package/dist/_chunks/{heatmap-Gf9r7Tn1.js → heatmap-DiyOSQk9.js} +2 -2
- package/dist/_chunks/{heatmap-Gf9r7Tn1.js.map → heatmap-DiyOSQk9.js.map} +1 -1
- package/dist/_chunks/{help-me-write-templates-fV-Apf72.js → help-me-write-templates-CM1p6qkm.js} +3 -3
- package/dist/_chunks/{help-me-write-templates-fV-Apf72.js.map → help-me-write-templates-CM1p6qkm.js.map} +1 -1
- package/dist/_chunks/{hover-card-BnTueNS2.js → hover-card-U_ZYoh1n.js} +201 -187
- package/dist/_chunks/hover-card-U_ZYoh1n.js.map +1 -0
- package/dist/_chunks/{icon-picker-DWrqmI1c.js → icon-picker-rOFTawXk.js} +3 -3
- package/dist/_chunks/{icon-picker-DWrqmI1c.js.map → icon-picker-rOFTawXk.js.map} +1 -1
- package/dist/_chunks/{info-tip-B0jmIt6M.js → info-tip-CJpNpzZe.js} +2 -2
- package/dist/_chunks/{info-tip-B0jmIt6M.js.map → info-tip-CJpNpzZe.js.map} +1 -1
- package/dist/_chunks/{kit-extensions-Byfxy6sy.js → kit-extensions-DYVxWcqv.js} +4 -4
- package/dist/_chunks/{kit-extensions-Byfxy6sy.js.map → kit-extensions-DYVxWcqv.js.map} +1 -1
- package/dist/_chunks/{link-cell-renderer-TeJNvymP.js → link-cell-renderer-C1wOyxDF.js} +3 -3
- package/dist/_chunks/{link-cell-renderer-TeJNvymP.js.map → link-cell-renderer-C1wOyxDF.js.map} +1 -1
- package/dist/_chunks/link-gRw3NtOt.js +137 -0
- package/dist/_chunks/link-gRw3NtOt.js.map +1 -0
- package/dist/_chunks/{list-RRN2TJ_7.js → list-CNnn7DOD.js} +75 -73
- package/dist/_chunks/list-CNnn7DOD.js.map +1 -0
- package/dist/_chunks/{locale-picker-DfNSdOpy.js → locale-picker-BGfrZyTw.js} +2 -2
- package/dist/_chunks/{locale-picker-DfNSdOpy.js.map → locale-picker-BGfrZyTw.js.map} +1 -1
- package/dist/_chunks/{login-dev-card-DmZ1B0lB.js → login-dev-card-CIim81VB.js} +2 -2
- package/dist/_chunks/{login-dev-card-DmZ1B0lB.js.map → login-dev-card-CIim81VB.js.map} +1 -1
- package/dist/_chunks/marketplace-app-shell-CSDmGLPW.js +613 -0
- package/dist/_chunks/marketplace-app-shell-CSDmGLPW.js.map +1 -0
- package/dist/_chunks/{message-tray-BB95DA82.js → message-tray-DmU0poD7.js} +76 -69
- package/dist/_chunks/message-tray-DmU0poD7.js.map +1 -0
- package/dist/_chunks/{nav-grid-BqCPH8sm.js → nav-grid-Byx8PxuB.js} +2 -2
- package/dist/_chunks/{nav-grid-BqCPH8sm.js.map → nav-grid-Byx8PxuB.js.map} +1 -1
- package/dist/_chunks/navigation-dismiss-B1mcW1CT.js +9 -0
- package/dist/_chunks/navigation-dismiss-B1mcW1CT.js.map +1 -0
- package/dist/_chunks/non-modal-tab-exit-j3CPOuE3.js +89 -0
- package/dist/_chunks/non-modal-tab-exit-j3CPOuE3.js.map +1 -0
- package/dist/_chunks/{note-attachment-I1NLoeRZ.js → note-attachment-Bt2cddsZ.js} +2 -2
- package/dist/_chunks/{note-attachment-I1NLoeRZ.js.map → note-attachment-Bt2cddsZ.js.map} +1 -1
- package/dist/_chunks/{note-timeline-CsY8YOE7.js → note-timeline-CX9nAgAR.js} +2 -2
- package/dist/_chunks/{note-timeline-CsY8YOE7.js.map → note-timeline-CX9nAgAR.js.map} +1 -1
- package/dist/_chunks/{notes-panel-DceRhthG.js → notes-panel-DHLHsxpW.js} +4 -4
- package/dist/_chunks/{notes-panel-DceRhthG.js.map → notes-panel-DHLHsxpW.js.map} +1 -1
- package/dist/_chunks/{notification-tray-__sJXnsz.js → notification-tray-DPU-Xg0i.js} +83 -76
- package/dist/_chunks/notification-tray-DPU-Xg0i.js.map +1 -0
- package/dist/_chunks/{panel-subview-BT-Apwgb.js → panel-subview-D4o6ar6_.js} +61 -47
- package/dist/_chunks/panel-subview-D4o6ar6_.js.map +1 -0
- package/dist/_chunks/{patient-details-DsTtjpuX.js → patient-details-BCaVuaXz.js} +2 -2
- package/dist/_chunks/{patient-details-DsTtjpuX.js.map → patient-details-BCaVuaXz.js.map} +1 -1
- package/dist/_chunks/{patient-field-row-BvZ9luz-.js → patient-field-row-jcRSTrp4.js} +7 -7
- package/dist/_chunks/{patient-field-row-BvZ9luz-.js.map → patient-field-row-jcRSTrp4.js.map} +1 -1
- package/dist/_chunks/{patient-summary-card-9nQWTQf6.js → patient-summary-card-kQIfPQOE.js} +4 -4
- package/dist/_chunks/{patient-summary-card-9nQWTQf6.js.map → patient-summary-card-kQIfPQOE.js.map} +1 -1
- package/dist/_chunks/{payment-automation-upsell-DiHovmUL.js → payment-automation-upsell-C4wHOxsp.js} +2 -2
- package/dist/_chunks/{payment-automation-upsell-DiHovmUL.js.map → payment-automation-upsell-C4wHOxsp.js.map} +1 -1
- package/dist/_chunks/{payment-request-card-CwDpwXUC.js → payment-request-card-DAniJNLX.js} +2 -2
- package/dist/_chunks/{payment-request-card-CwDpwXUC.js.map → payment-request-card-DAniJNLX.js.map} +1 -1
- package/dist/_chunks/{pdf-viewer-C3minW5b.js → pdf-viewer-CNQxa4tv.js} +396 -391
- package/dist/_chunks/pdf-viewer-CNQxa4tv.js.map +1 -0
- package/dist/_chunks/{phone-input-DxkHMYmu.js → phone-input-O9camxkq.js} +156 -151
- package/dist/_chunks/phone-input-O9camxkq.js.map +1 -0
- package/dist/_chunks/popover-BG75rYjN.js +367 -0
- package/dist/_chunks/popover-BG75rYjN.js.map +1 -0
- package/dist/_chunks/{practice-results-Dhbo-fc_.js → practice-results-D07wgCqV.js} +2 -2
- package/dist/_chunks/{practice-results-Dhbo-fc_.js.map → practice-results-D07wgCqV.js.map} +1 -1
- package/dist/_chunks/{pregnancy-dating-Bfu0Cq4H.js → pregnancy-dating-BFzv9g1N.js} +2 -2
- package/dist/_chunks/{pregnancy-dating-Bfu0Cq4H.js.map → pregnancy-dating-BFzv9g1N.js.map} +1 -1
- package/dist/_chunks/{product-hub-panel-BSSiGGG4.js → product-hub-panel-DCYX0rPG.js} +103 -96
- package/dist/_chunks/product-hub-panel-DCYX0rPG.js.map +1 -0
- package/dist/_chunks/{public-footer-CxpG6J1M.js → public-footer-ZWTEG1Rq.js} +2 -2
- package/dist/_chunks/{public-footer-CxpG6J1M.js.map → public-footer-ZWTEG1Rq.js.map} +1 -1
- package/dist/_chunks/{public-header.agent-pr2hyiND.js → public-header.agent-C1SlVSYt.js} +2 -2
- package/dist/_chunks/{public-header.agent-pr2hyiND.js.map → public-header.agent-C1SlVSYt.js.map} +1 -1
- package/dist/_chunks/{radiograph-panel.agent-DkUokbEa.js → radiograph-panel.agent-DyqbTECc.js} +4 -4
- package/dist/_chunks/{radiograph-panel.agent-DkUokbEa.js.map → radiograph-panel.agent-DyqbTECc.js.map} +1 -1
- package/dist/_chunks/{registration-form-D7iNqMBF.js → registration-form-DrSR9Sjk.js} +4 -4
- package/dist/_chunks/{registration-form-D7iNqMBF.js.map → registration-form-DrSR9Sjk.js.map} +1 -1
- package/dist/_chunks/{rich-text-editor-CkFfmA3v.js → rich-text-editor-UgXri8h6.js} +490 -485
- package/dist/_chunks/rich-text-editor-UgXri8h6.js.map +1 -0
- package/dist/_chunks/{scroll-area-ZtFCv9K7.js → scroll-area-CY5SLYNw.js} +104 -74
- package/dist/_chunks/scroll-area-CY5SLYNw.js.map +1 -0
- package/dist/_chunks/{search-bar-DQJS0wJN.js → search-bar-mA4bPe3t.js} +294 -255
- package/dist/_chunks/search-bar-mA4bPe3t.js.map +1 -0
- package/dist/_chunks/{sheet-C7SwIxwB.js → sheet-Dtjk0CVv.js} +3 -3
- package/dist/_chunks/{sheet-C7SwIxwB.js.map → sheet-Dtjk0CVv.js.map} +1 -1
- package/dist/_chunks/sidebar-D4Wllqfz.js +2029 -0
- package/dist/_chunks/sidebar-D4Wllqfz.js.map +1 -0
- package/dist/_chunks/{sign-document-B6HlyCGV.js → sign-document-D4iHS_Ug.js} +2 -2
- package/dist/_chunks/{sign-document-B6HlyCGV.js.map → sign-document-D4iHS_Ug.js.map} +1 -1
- package/dist/_chunks/{signature-request-DhbpB9N9.js → signature-request-dAVgE0_5.js} +3 -3
- package/dist/_chunks/{signature-request-DhbpB9N9.js.map → signature-request-dAVgE0_5.js.map} +1 -1
- package/dist/_chunks/{signed-out-frame-B2GTIeqA.js → signed-out-frame-DOJpobp8.js} +3 -3
- package/dist/_chunks/{signed-out-frame-B2GTIeqA.js.map → signed-out-frame-DOJpobp8.js.map} +1 -1
- package/dist/_chunks/{state-backed-text-input-DECQy5aA.js → state-backed-text-input-Cgh4ms3p.js} +2 -2
- package/dist/_chunks/{state-backed-text-input-DECQy5aA.js.map → state-backed-text-input-Cgh4ms3p.js.map} +1 -1
- package/dist/_chunks/{task-editor-ByyRu29Y.js → task-editor-BflEZmcF.js} +7 -6
- package/dist/_chunks/task-editor-BflEZmcF.js.map +1 -0
- package/dist/_chunks/{tool-rail-Bwyuw_Ot.js → tool-rail-CTq1KwxW.js} +115 -114
- package/dist/_chunks/{tool-rail-Bwyuw_Ot.js.map → tool-rail-CTq1KwxW.js.map} +1 -1
- package/dist/_chunks/{use-appointment-details-read-JsDM48tf.js → use-appointment-details-read-izwoXh-G.js} +8 -8
- package/dist/_chunks/{use-appointment-details-read-JsDM48tf.js.map → use-appointment-details-read-izwoXh-G.js.map} +1 -1
- package/dist/_chunks/use-state-backed-input-DhRQo6gM.js +57 -0
- package/dist/_chunks/use-state-backed-input-DhRQo6gM.js.map +1 -0
- package/dist/_chunks/{voice-control-panel-Bg1eklL0.js → voice-control-panel-an-bpQfF.js} +3 -3
- package/dist/_chunks/{voice-control-panel-Bg1eklL0.js.map → voice-control-panel-an-bpQfF.js.map} +1 -1
- package/dist/_chunks/{widget-picker-DXYBMTfe.js → widget-picker-DlJOgYrZ.js} +80 -57
- package/dist/_chunks/widget-picker-DlJOgYrZ.js.map +1 -0
- package/dist/agent-catalog.json +3 -3
- package/dist/agent-i18n/en.json +1 -1
- package/dist/components/_shared/navigation-dismiss.d.ts +8 -0
- package/dist/components/_shared/navigation-dismiss.d.ts.map +1 -0
- package/dist/components/_shared/non-modal-tab-exit.d.ts +15 -4
- package/dist/components/_shared/non-modal-tab-exit.d.ts.map +1 -1
- package/dist/components/_shared/use-state-backed-input.d.ts +3 -2
- package/dist/components/_shared/use-state-backed-input.d.ts.map +1 -1
- package/dist/components/address-fields/index.js +1 -1
- package/dist/components/ai-credits-notice/index.js +1 -1
- package/dist/components/ai-permission-notice/ai-permission-notice.d.ts +32 -0
- package/dist/components/ai-permission-notice/ai-permission-notice.d.ts.map +1 -1
- package/dist/components/ai-permission-notice/index.d.ts +1 -1
- package/dist/components/ai-permission-notice/index.d.ts.map +1 -1
- package/dist/components/ai-permission-notice/index.js +1 -1
- package/dist/components/app-frame/index.js +1 -1
- 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/booking/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-header/index.js +1 -1
- package/dist/components/chart/chart.d.ts +5 -5
- package/dist/components/chart/chart.d.ts.map +1 -1
- package/dist/components/chart/index.js +1 -1
- package/dist/components/city-input/index.js +1 -1
- package/dist/components/clinical-note-card/index.js +1 -1
- package/dist/components/color-picker/color-picker.d.ts.map +1 -1
- package/dist/components/color-picker/index.js +1 -1
- package/dist/components/contact-card/index.js +1 -1
- package/dist/components/contact-profile-card/index.js +1 -1
- package/dist/components/control-room-rail/index.js +1 -1
- package/dist/components/cycle-calculator/index.js +1 -1
- package/dist/components/dashboard-grid/dashboard-grid.d.ts +33 -8
- package/dist/components/dashboard-grid/dashboard-grid.d.ts.map +1 -1
- package/dist/components/dashboard-grid/index.js +1 -1
- package/dist/components/data-table/index.js +2 -2
- package/dist/components/data-table-tabs/index.js +1 -1
- package/dist/components/date-picker/date-picker.d.ts.map +1 -1
- package/dist/components/date-picker/index.js +1 -1
- package/dist/components/date-range-picker/date-range-picker.d.ts.map +1 -1
- package/dist/components/date-range-picker/index.js +1 -1
- package/dist/components/date-time-picker/date-time-picker.d.ts.map +1 -1
- package/dist/components/date-time-picker/index.js +1 -1
- package/dist/components/dialog/index.js +1 -1
- package/dist/components/document-preview/index.js +1 -1
- package/dist/components/due-date-calculator/index.js +1 -1
- package/dist/components/entity-summary/index.js +1 -1
- package/dist/components/face-scheme/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/hover-card/hover-card.d.ts.map +1 -1
- package/dist/components/hover-card/index.js +1 -1
- package/dist/components/icon-picker/index.js +1 -1
- package/dist/components/info-tip/index.js +1 -1
- package/dist/components/link/index.js +1 -1
- package/dist/components/link/link.d.ts +5 -3
- package/dist/components/link/link.d.ts.map +1 -1
- package/dist/components/list/index.js +1 -1
- package/dist/components/list/list.d.ts.map +1 -1
- package/dist/components/locale-picker/index.js +1 -1
- package/dist/components/message-tray/index.js +1 -1
- package/dist/components/message-tray/message-tray.d.ts.map +1 -1
- package/dist/components/nav-grid/index.js +1 -1
- package/dist/components/note-timeline/index.js +1 -1
- package/dist/components/notes-panel/index.js +1 -1
- package/dist/components/notification-tray/index.js +1 -1
- package/dist/components/notification-tray/notification-tray.d.ts.map +1 -1
- package/dist/components/panel-subview/index.js +1 -1
- package/dist/components/panel-subview/panel-subview.d.ts.map +1 -1
- package/dist/components/patient-details/index.js +1 -1
- package/dist/components/patient-summary-card/index.js +1 -1
- package/dist/components/patient-table/index.js +1 -1
- package/dist/components/payment-card/index.js +1 -1
- package/dist/components/pdf-viewer/index.js +1 -1
- package/dist/components/pdf-viewer/pdf-viewer.d.ts.map +1 -1
- package/dist/components/phone-input/index.js +1 -1
- package/dist/components/phone-input/phone-input.d.ts.map +1 -1
- package/dist/components/popover/index.js +1 -1
- package/dist/components/popover/popover.d.ts +1 -1
- package/dist/components/popover/popover.d.ts.map +1 -1
- package/dist/components/practice-results/index.js +1 -1
- package/dist/components/pregnancy-dating/index.js +1 -1
- package/dist/components/product-hub-tray/index.js +1 -1
- package/dist/components/product-hub-tray/product-hub-tray.d.ts.map +1 -1
- package/dist/components/public-footer/index.js +1 -1
- package/dist/components/public-header/index.js +1 -1
- package/dist/components/radiograph-panel/index.js +1 -1
- package/dist/components/rich-text-editor/editor-toolbar.d.ts.map +1 -1
- package/dist/components/rich-text-editor/index.js +2 -2
- package/dist/components/scroll-area/index.js +1 -1
- package/dist/components/scroll-area/scroll-area.d.ts +6 -5
- package/dist/components/scroll-area/scroll-area.d.ts.map +1 -1
- package/dist/components/search-bar/index.js +1 -1
- package/dist/components/search-bar/search-bar.d.ts +1 -1
- package/dist/components/search-bar/search-bar.d.ts.map +1 -1
- package/dist/components/sheet/index.js +1 -1
- package/dist/components/sidebar/index.d.ts +1 -1
- package/dist/components/sidebar/index.d.ts.map +1 -1
- package/dist/components/sidebar/index.js +1 -1
- package/dist/components/sidebar/sidebar-move.d.ts +88 -0
- package/dist/components/sidebar/sidebar-move.d.ts.map +1 -0
- package/dist/components/sidebar/sidebar.d.ts +26 -1
- package/dist/components/sidebar/sidebar.d.ts.map +1 -1
- package/dist/components/sign-document/index.js +1 -1
- package/dist/components/task-editor/index.js +1 -1
- package/dist/components/task-editor/task-editor.d.ts.map +1 -1
- package/dist/components/tool-rail/index.js +1 -1
- package/dist/components/tool-rail/tool-rail.d.ts.map +1 -1
- package/dist/components/voice-control-panel/index.js +1 -1
- package/dist/components/widget-picker/index.js +1 -1
- package/dist/components/widget-picker/widget-picker.d.ts.map +1 -1
- package/dist/host-compat.css +2 -1
- package/dist/i18n/locales/ar.d.ts +24 -0
- package/dist/i18n/locales/ar.d.ts.map +1 -1
- package/dist/i18n/locales/ar.js +26 -2
- package/dist/i18n/locales/ar.js.map +1 -1
- package/dist/i18n/locales/de.d.ts +24 -0
- package/dist/i18n/locales/de.d.ts.map +1 -1
- package/dist/i18n/locales/de.js +26 -2
- package/dist/i18n/locales/de.js.map +1 -1
- package/dist/i18n/locales/el.d.ts +24 -0
- package/dist/i18n/locales/el.d.ts.map +1 -1
- package/dist/i18n/locales/el.js +26 -2
- package/dist/i18n/locales/el.js.map +1 -1
- package/dist/i18n/locales/en.d.ts +24 -0
- package/dist/i18n/locales/en.d.ts.map +1 -1
- package/dist/i18n/locales/en.js +26 -2
- package/dist/i18n/locales/en.js.map +1 -1
- package/dist/i18n/locales/es.d.ts +24 -0
- package/dist/i18n/locales/es.d.ts.map +1 -1
- package/dist/i18n/locales/es.js +26 -2
- package/dist/i18n/locales/es.js.map +1 -1
- package/dist/i18n/locales/fr.d.ts +24 -0
- package/dist/i18n/locales/fr.d.ts.map +1 -1
- package/dist/i18n/locales/fr.js +26 -2
- package/dist/i18n/locales/fr.js.map +1 -1
- package/dist/i18n/locales/hi.d.ts +24 -0
- package/dist/i18n/locales/hi.d.ts.map +1 -1
- package/dist/i18n/locales/hi.js +26 -2
- package/dist/i18n/locales/hi.js.map +1 -1
- package/dist/i18n/locales/it.d.ts +24 -0
- package/dist/i18n/locales/it.d.ts.map +1 -1
- package/dist/i18n/locales/it.js +26 -2
- package/dist/i18n/locales/it.js.map +1 -1
- package/dist/i18n/locales/ja.d.ts +24 -0
- package/dist/i18n/locales/ja.d.ts.map +1 -1
- package/dist/i18n/locales/ja.js +26 -2
- package/dist/i18n/locales/ja.js.map +1 -1
- package/dist/i18n/locales/nl.d.ts +24 -0
- package/dist/i18n/locales/nl.d.ts.map +1 -1
- package/dist/i18n/locales/nl.js +26 -2
- package/dist/i18n/locales/nl.js.map +1 -1
- package/dist/i18n/locales/pl.d.ts +24 -0
- package/dist/i18n/locales/pl.d.ts.map +1 -1
- package/dist/i18n/locales/pl.js +26 -2
- package/dist/i18n/locales/pl.js.map +1 -1
- package/dist/i18n/locales/pt.d.ts +24 -0
- package/dist/i18n/locales/pt.d.ts.map +1 -1
- package/dist/i18n/locales/pt.js +26 -2
- package/dist/i18n/locales/pt.js.map +1 -1
- package/dist/i18n/locales/ro.d.ts +24 -0
- package/dist/i18n/locales/ro.d.ts.map +1 -1
- package/dist/i18n/locales/ro.js +26 -2
- package/dist/i18n/locales/ro.js.map +1 -1
- package/dist/i18n/locales/ru.d.ts +24 -0
- package/dist/i18n/locales/ru.d.ts.map +1 -1
- package/dist/i18n/locales/ru.js +26 -2
- package/dist/i18n/locales/ru.js.map +1 -1
- package/dist/i18n/locales/sq.d.ts +24 -0
- package/dist/i18n/locales/sq.d.ts.map +1 -1
- package/dist/i18n/locales/sq.js +26 -2
- package/dist/i18n/locales/sq.js.map +1 -1
- package/dist/i18n/locales/sv.d.ts +24 -0
- package/dist/i18n/locales/sv.d.ts.map +1 -1
- package/dist/i18n/locales/sv.js +26 -2
- package/dist/i18n/locales/sv.js.map +1 -1
- package/dist/i18n/locales/tr.d.ts +24 -0
- package/dist/i18n/locales/tr.d.ts.map +1 -1
- package/dist/i18n/locales/tr.js +26 -2
- package/dist/i18n/locales/tr.js.map +1 -1
- package/dist/i18n/locales/zh.d.ts +24 -0
- package/dist/i18n/locales/zh.d.ts.map +1 -1
- package/dist/i18n/locales/zh.js +26 -2
- package/dist/i18n/locales/zh.js.map +1 -1
- package/dist/index.js +204 -203
- package/dist/locales/ar.json +26 -2
- package/dist/locales/de.json +26 -2
- package/dist/locales/el.json +26 -2
- package/dist/locales/en.json +26 -2
- package/dist/locales/es.json +26 -2
- package/dist/locales/fr.json +26 -2
- package/dist/locales/hi.json +26 -2
- package/dist/locales/it.json +26 -2
- package/dist/locales/ja.json +26 -2
- package/dist/locales/nl.json +26 -2
- package/dist/locales/pl.json +26 -2
- package/dist/locales/pt.json +26 -2
- package/dist/locales/ro.json +26 -2
- package/dist/locales/ru.json +26 -2
- package/dist/locales/sq.json +26 -2
- package/dist/locales/sv.json +26 -2
- package/dist/locales/tr.json +26 -2
- package/dist/locales/zh.json +26 -2
- package/dist/patterns/alia-assistant/alia-asteroid-icon.d.ts +10 -13
- package/dist/patterns/alia-assistant/alia-asteroid-icon.d.ts.map +1 -1
- package/dist/patterns/alia-assistant/alia-chat-surface.d.ts.map +1 -1
- package/dist/patterns/alia-assistant/alia-popout.d.ts +5 -3
- package/dist/patterns/alia-assistant/alia-popout.d.ts.map +1 -1
- package/dist/patterns/alia-assistant/index.d.ts +2 -0
- package/dist/patterns/alia-assistant/index.d.ts.map +1 -1
- package/dist/patterns/alia-assistant/index.js +6 -5
- package/dist/patterns/anamnesis/index.js +1 -1
- package/dist/patterns/calendar/index.js +1 -1
- package/dist/patterns/forgot-password-form/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/marketplace-app-shell/marketplace-app-shell.d.ts +40 -10
- package/dist/patterns/marketplace-app-shell/marketplace-app-shell.d.ts.map +1 -1
- package/dist/patterns/payment-automation-upsell/index.js +1 -1
- package/dist/patterns/registration-form/index.js +1 -1
- package/dist/patterns/signature-request/index.js +1 -1
- package/dist/patterns/signed-out-frame/index.js +1 -1
- package/dist/tokens.css +1 -1
- package/package.json +1 -1
- package/dist/_chunks/ai-permission-notice-5vpblPCx.js +0 -171
- package/dist/_chunks/ai-permission-notice-5vpblPCx.js.map +0 -1
- package/dist/_chunks/alia-sidebar-DOei4Iyu.js +0 -1183
- package/dist/_chunks/alia-sidebar-DOei4Iyu.js.map +0 -1
- package/dist/_chunks/calendar-workspace-Du2ryaI-.js.map +0 -1
- package/dist/_chunks/chart-HsF1KHbx.js.map +0 -1
- package/dist/_chunks/color-picker-BRQ4Y9SO.js.map +0 -1
- package/dist/_chunks/dashboard-grid-DfEY2qci.js +0 -844
- package/dist/_chunks/dashboard-grid-DfEY2qci.js.map +0 -1
- package/dist/_chunks/date-picker-wRAcq2lt.js.map +0 -1
- package/dist/_chunks/date-range-picker-CtUOI38x.js.map +0 -1
- package/dist/_chunks/date-time-picker-CLeLKuv9.js.map +0 -1
- package/dist/_chunks/hover-card-BnTueNS2.js.map +0 -1
- package/dist/_chunks/link-2HokYuIi.js +0 -130
- package/dist/_chunks/link-2HokYuIi.js.map +0 -1
- package/dist/_chunks/list-RRN2TJ_7.js.map +0 -1
- package/dist/_chunks/marketplace-app-shell-Dcx-JEjg.js +0 -541
- package/dist/_chunks/marketplace-app-shell-Dcx-JEjg.js.map +0 -1
- package/dist/_chunks/message-tray-BB95DA82.js.map +0 -1
- package/dist/_chunks/non-modal-tab-exit-D2Bd93Bq.js +0 -65
- package/dist/_chunks/non-modal-tab-exit-D2Bd93Bq.js.map +0 -1
- package/dist/_chunks/notification-tray-__sJXnsz.js.map +0 -1
- package/dist/_chunks/panel-subview-BT-Apwgb.js.map +0 -1
- package/dist/_chunks/pdf-viewer-C3minW5b.js.map +0 -1
- package/dist/_chunks/phone-input-DxkHMYmu.js.map +0 -1
- package/dist/_chunks/popover-BI3oV3eY.js +0 -305
- package/dist/_chunks/popover-BI3oV3eY.js.map +0 -1
- package/dist/_chunks/product-hub-panel-BSSiGGG4.js.map +0 -1
- package/dist/_chunks/rich-text-editor-CkFfmA3v.js.map +0 -1
- package/dist/_chunks/scroll-area-ZtFCv9K7.js.map +0 -1
- package/dist/_chunks/search-bar-DQJS0wJN.js.map +0 -1
- package/dist/_chunks/sidebar-DLsG2AIk.js +0 -1349
- package/dist/_chunks/sidebar-DLsG2AIk.js.map +0 -1
- package/dist/_chunks/task-editor-ByyRu29Y.js.map +0 -1
- package/dist/_chunks/use-state-backed-input-C7ESmxKB.js +0 -59
- package/dist/_chunks/use-state-backed-input-C7ESmxKB.js.map +0 -1
- package/dist/_chunks/widget-picker-DXYBMTfe.js.map +0 -1
|
@@ -1,844 +0,0 @@
|
|
|
1
|
-
import { jsxs as J, jsx as M } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as qe, useRef as w, useState as X, useCallback as z, useMemo as A, useEffect as ne, useImperativeHandle as Xe, useContext as Je, Children as Qe, isValidElement as Ze, Fragment as Be, createContext as et, cloneElement as De } from "react";
|
|
3
|
-
import { c as Ce } from "./index-D2ZczOXr.js";
|
|
4
|
-
import { useTranslation as Te } from "react-i18next";
|
|
5
|
-
import { I as ue } from "./icon-button-COX76Jdj.js";
|
|
6
|
-
import { u as $ } from "./use-isomorphic-layout-effect-BGfaCOP1.js";
|
|
7
|
-
import { u as tt } from "./registry-DvAUVLHh.js";
|
|
8
|
-
import { P as rt } from "./plus-DzMQ_c6b.js";
|
|
9
|
-
import { G as nt } from "./grip-vertical-onSb1JXO.js";
|
|
10
|
-
import { X as st } from "./x-B5YnXwCz.js";
|
|
11
|
-
import { c as it } from "./createLucideIcon-DhHxpK9K.js";
|
|
12
|
-
/**
|
|
13
|
-
* @license lucide-react v1.22.0 - ISC
|
|
14
|
-
*
|
|
15
|
-
* This source code is licensed under the ISC license.
|
|
16
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/
|
|
18
|
-
const ot = [
|
|
19
|
-
["path", { d: "M19 13v6h-6", key: "1hxl6d" }],
|
|
20
|
-
["path", { d: "M5 11V5h6", key: "12e2xe" }],
|
|
21
|
-
["path", { d: "m5 5 14 14", key: "11anup" }]
|
|
22
|
-
], at = it("move-diagonal-2", ot), dt = {
|
|
23
|
-
id: "dashboard-grid",
|
|
24
|
-
// The board's whole purpose is in-place rearrangement of its widgets.
|
|
25
|
-
capabilities: ["edit_inline"],
|
|
26
|
-
state: {
|
|
27
|
-
layout: {
|
|
28
|
-
type: "{ id: string, x: number, y: number, w: number, h: number }[]",
|
|
29
|
-
descriptionKey: "ui.agent.dashboardGrid.state.layout",
|
|
30
|
-
description: "Current widget geometry in cell units — ids and rectangles only, no widget content.",
|
|
31
|
-
read: (r) => r.getGridState().layout
|
|
32
|
-
},
|
|
33
|
-
cols: {
|
|
34
|
-
type: "number",
|
|
35
|
-
descriptionKey: "ui.agent.dashboardGrid.state.cols",
|
|
36
|
-
description: "Logical column count of the board.",
|
|
37
|
-
read: (r) => r.getGridState().cols
|
|
38
|
-
},
|
|
39
|
-
editing: {
|
|
40
|
-
type: "boolean",
|
|
41
|
-
descriptionKey: "ui.agent.dashboardGrid.state.editing",
|
|
42
|
-
description: "Whether edit mode is on. Move/resize actions are refused while it is off — the host app owns the toggle.",
|
|
43
|
-
read: (r) => r.getGridState().editing
|
|
44
|
-
},
|
|
45
|
-
stacked: {
|
|
46
|
-
type: "boolean",
|
|
47
|
-
descriptionKey: "ui.agent.dashboardGrid.state.stacked",
|
|
48
|
-
description: "Whether the board is narrower than its stackBelow width and shows its widgets as one read-only column. Move/resize actions are unavailable while it is true, even in edit mode; the saved layout is unchanged.",
|
|
49
|
-
read: (r) => r.getGridState().stacked
|
|
50
|
-
}
|
|
51
|
-
},
|
|
52
|
-
actions: {
|
|
53
|
-
move_widget: {
|
|
54
|
-
// Rearranging the board mutates user configuration — a write,
|
|
55
|
-
// reversible by moving back.
|
|
56
|
-
safety: "write",
|
|
57
|
-
argsType: "id, x, y",
|
|
58
|
-
argsSchema: {
|
|
59
|
-
type: "object",
|
|
60
|
-
properties: {
|
|
61
|
-
id: { type: "string", description: "Widget id (see layout state)." },
|
|
62
|
-
x: {
|
|
63
|
-
type: "integer",
|
|
64
|
-
minimum: 0,
|
|
65
|
-
description: "0-based logical column."
|
|
66
|
-
},
|
|
67
|
-
y: { type: "integer", minimum: 0, description: "0-based row." }
|
|
68
|
-
},
|
|
69
|
-
required: ["id", "x", "y"]
|
|
70
|
-
},
|
|
71
|
-
returns: "boolean (accepted)",
|
|
72
|
-
returnsSchema: {
|
|
73
|
-
type: "boolean",
|
|
74
|
-
description: "True when applied; false when edit mode is off, the board is stacked, or the id is unknown."
|
|
75
|
-
},
|
|
76
|
-
idempotent: !0,
|
|
77
|
-
errors: [
|
|
78
|
-
"Unavailable while the board is stacked (state stacked is true): returns false and changes nothing.",
|
|
79
|
-
"Unavailable while edit mode is off: returns false.",
|
|
80
|
-
"Unknown widget id: returns false."
|
|
81
|
-
],
|
|
82
|
-
descriptionKey: "ui.agent.dashboardGrid.actions.moveWidget",
|
|
83
|
-
description: "Move a widget to a cell. Out-of-bounds targets are clamped; colliding widgets are pushed down and the layout re-compacts. Refused while edit mode is off or the board is stacked.",
|
|
84
|
-
invoke: (r, o) => r.moveWidgetTo(o.id, o.x, o.y)
|
|
85
|
-
},
|
|
86
|
-
resize_widget: {
|
|
87
|
-
safety: "write",
|
|
88
|
-
argsType: "id, w, h",
|
|
89
|
-
argsSchema: {
|
|
90
|
-
type: "object",
|
|
91
|
-
properties: {
|
|
92
|
-
id: { type: "string", description: "Widget id (see layout state)." },
|
|
93
|
-
w: {
|
|
94
|
-
type: "integer",
|
|
95
|
-
minimum: 1,
|
|
96
|
-
description: "Column span (≥ 1)."
|
|
97
|
-
},
|
|
98
|
-
h: { type: "integer", minimum: 1, description: "Row span (≥ 1)." }
|
|
99
|
-
},
|
|
100
|
-
required: ["id", "w", "h"]
|
|
101
|
-
},
|
|
102
|
-
returns: "boolean (accepted)",
|
|
103
|
-
returnsSchema: {
|
|
104
|
-
type: "boolean",
|
|
105
|
-
description: "True when applied; false when edit mode is off, the board is stacked, or the id is unknown."
|
|
106
|
-
},
|
|
107
|
-
idempotent: !0,
|
|
108
|
-
errors: [
|
|
109
|
-
"Unavailable while the board is stacked (state stacked is true): returns false and changes nothing.",
|
|
110
|
-
"Unavailable while edit mode is off: returns false.",
|
|
111
|
-
"Unknown widget id: returns false."
|
|
112
|
-
],
|
|
113
|
-
descriptionKey: "ui.agent.dashboardGrid.actions.resizeWidget",
|
|
114
|
-
description: "Resize a widget to a span. Clamped to the grid and the widget’s min/max; colliding widgets are pushed down. Refused while edit mode is off or the board is stacked.",
|
|
115
|
-
invoke: (r, o) => r.resizeWidgetTo(o.id, o.w, o.h)
|
|
116
|
-
}
|
|
117
|
-
},
|
|
118
|
-
domHooks: {
|
|
119
|
-
root: {
|
|
120
|
-
attr: "data-component",
|
|
121
|
-
value: "dashboard-grid",
|
|
122
|
-
description: 'Also carries data-stacked="true" while the board shows one read-only column.'
|
|
123
|
-
},
|
|
124
|
-
instanceId: {
|
|
125
|
-
attr: "data-component-id",
|
|
126
|
-
sourceProp: "id",
|
|
127
|
-
description: "Sourced from the id prop."
|
|
128
|
-
},
|
|
129
|
-
item: {
|
|
130
|
-
attr: "data-widget-id",
|
|
131
|
-
description: "Each widget wrapper carries its layout id."
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
};
|
|
135
|
-
function U(r, o) {
|
|
136
|
-
return r.x < o.x + o.w && o.x < r.x + r.w && r.y < o.y + o.h && o.y < r.y + r.h;
|
|
137
|
-
}
|
|
138
|
-
function ie(r, o) {
|
|
139
|
-
const s = Math.max(1, r.minW ?? 1), u = Math.max(1, r.minH ?? 1), p = Math.min(o, r.maxW ?? o), l = r.maxH ?? Number.POSITIVE_INFINITY, f = Math.min(Math.max(r.w, s), p), c = Math.min(Math.max(r.h, u), l), d = Math.min(Math.max(0, r.x), o - f), g = Math.max(0, r.y);
|
|
140
|
-
return { ...r, x: d, y: g, w: f, h: c };
|
|
141
|
-
}
|
|
142
|
-
function F(r, o, s) {
|
|
143
|
-
const u = r.map((d) => ie(d, o)), p = [...u].sort((d, g) => d.id === s ? -1 : g.id === s ? 1 : d.y - g.y || d.x - g.x), l = [], f = s ? u.find((d) => d.id === s) : void 0;
|
|
144
|
-
for (const d of p) {
|
|
145
|
-
if (d.id !== s) {
|
|
146
|
-
if (f && U(f, d)) {
|
|
147
|
-
const g = { ...d, y: Math.max(0, f.y - d.h) };
|
|
148
|
-
!U(f, g) && !l.some((x) => x.id !== s && U(x, g)) && (d.y = g.y);
|
|
149
|
-
}
|
|
150
|
-
for (; l.some((g) => U(g, d)); )
|
|
151
|
-
d.y += 1;
|
|
152
|
-
for (; d.y > 0; ) {
|
|
153
|
-
const g = { ...d, y: d.y - 1 };
|
|
154
|
-
if (l.some((x) => U(x, g))) break;
|
|
155
|
-
d.y -= 1;
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
l.push(d);
|
|
159
|
-
}
|
|
160
|
-
const c = new Map(l.map((d) => [d.id, d]));
|
|
161
|
-
return r.map((d) => c.get(d.id));
|
|
162
|
-
}
|
|
163
|
-
function le(r, o, s, u, p) {
|
|
164
|
-
const l = r.map(
|
|
165
|
-
(f) => f.id === o ? ie({ ...f, x: s, y: u }, p) : f
|
|
166
|
-
);
|
|
167
|
-
return F(l, p, o);
|
|
168
|
-
}
|
|
169
|
-
function fe(r, o, s, u, p) {
|
|
170
|
-
const l = r.map(
|
|
171
|
-
(f) => f.id === o ? (
|
|
172
|
-
// Resizing never moves the widget: the width clamps to the space
|
|
173
|
-
// between its position and the grid edge (clampRect would slide it).
|
|
174
|
-
// minW wins over the edge clamp so clampRect cannot re-raise w and
|
|
175
|
-
// slide x as a side effect.
|
|
176
|
-
ie(
|
|
177
|
-
{
|
|
178
|
-
...f,
|
|
179
|
-
w: Math.max(f.minW ?? 1, Math.min(s, p - f.x)),
|
|
180
|
-
h: u
|
|
181
|
-
},
|
|
182
|
-
p
|
|
183
|
-
)
|
|
184
|
-
) : f
|
|
185
|
-
);
|
|
186
|
-
return F(l, p, o);
|
|
187
|
-
}
|
|
188
|
-
function ze(r, o, s, u) {
|
|
189
|
-
const p = Math.min(Math.max(1, s), o), l = r.reduce((f, c) => Math.max(f, c.y + c.h), 0);
|
|
190
|
-
for (let f = 0; f <= l; f += 1)
|
|
191
|
-
for (let c = 0; c <= o - p; c += 1) {
|
|
192
|
-
const d = {
|
|
193
|
-
x: c,
|
|
194
|
-
y: f,
|
|
195
|
-
w: p,
|
|
196
|
-
h: u
|
|
197
|
-
};
|
|
198
|
-
if (!r.some((g) => U(g, d)))
|
|
199
|
-
return { x: c, y: f };
|
|
200
|
-
}
|
|
201
|
-
return { x: 0, y: l };
|
|
202
|
-
}
|
|
203
|
-
function ct(r) {
|
|
204
|
-
return r.reduce((o, s) => Math.max(o, s.y + s.h), 0);
|
|
205
|
-
}
|
|
206
|
-
const ut = 24;
|
|
207
|
-
function Ie(r, o, s) {
|
|
208
|
-
return o === void 0 || !Number.isFinite(o) || o <= 0 ? !1 : !Number.isFinite(r) || r <= 0 ? s : s ? r < o + ut : r < o;
|
|
209
|
-
}
|
|
210
|
-
function lt(r, o) {
|
|
211
|
-
const s = new Map(o.map((u) => [u.id, u]));
|
|
212
|
-
return r.map((u, p) => ({ id: u, index: p, entry: s.get(u) })).sort((u, p) => !u.entry || !p.entry ? u.entry ? -1 : p.entry ? 1 : u.index - p.index : u.entry.y - p.entry.y || u.entry.x - p.entry.x || u.index - p.index).map(({ id: u }) => u);
|
|
213
|
-
}
|
|
214
|
-
const ft = Ce(
|
|
215
|
-
[
|
|
216
|
-
"ds:grid ds:w-full",
|
|
217
|
-
"ds:gap-[var(--spacing-md)]",
|
|
218
|
-
// Edit-mode surface: tint the whole plane, draw faint cell lines, and
|
|
219
|
-
// reserve spare rows (--dg-min-block) so the AVAILABLE space reads at
|
|
220
|
-
// a glance instead of the board ending at the last occupied row.
|
|
221
|
-
"ds:data-[editing=true]:rounded-[var(--radius-lg)] ds:data-[editing=true]:bg-muted/10",
|
|
222
|
-
"ds:data-[editing=true]:[background-image:var(--dg-grid-lines)]",
|
|
223
|
-
"ds:data-[editing=true]:min-h-[var(--dg-min-block)]"
|
|
224
|
-
].join(" "),
|
|
225
|
-
{
|
|
226
|
-
variants: {
|
|
227
|
-
// Stacked: one full-width column; each row takes its widget's block
|
|
228
|
-
// size. Focus can fall back to the board here (see the focus effect),
|
|
229
|
-
// so it gets the kit's focus ring.
|
|
230
|
-
stacked: {
|
|
231
|
-
false: [
|
|
232
|
-
"ds:[grid-template-columns:repeat(var(--dg-cols),minmax(0,1fr))]",
|
|
233
|
-
"ds:[grid-auto-rows:var(--dg-row)]"
|
|
234
|
-
].join(" "),
|
|
235
|
-
true: [
|
|
236
|
-
"ds:grid-cols-1 ds:auto-rows-auto",
|
|
237
|
-
"ds:focus-visible:outline-[length:var(--focus-ring-width)] ds:focus-visible:outline-solid ds:focus-visible:outline-ring ds:focus-visible:outline-offset-[length:var(--focus-ring-offset)]"
|
|
238
|
-
].join(" ")
|
|
239
|
-
}
|
|
240
|
-
},
|
|
241
|
-
defaultVariants: { stacked: !1 }
|
|
242
|
-
}
|
|
243
|
-
), pt = Ce(
|
|
244
|
-
[
|
|
245
|
-
"ds:relative ds:flex ds:min-h-0 ds:min-w-0 ds:flex-col ds:overflow-hidden",
|
|
246
|
-
// Mirror of Card variant="elevated" so widgets read as kit cards.
|
|
247
|
-
"ds:rounded-[var(--radius-lg)] ds:bg-[var(--card)] ds:text-[var(--card-foreground)]",
|
|
248
|
-
"ds:[:where(&)]:border-[length:var(--surface-border-width,var(--border-width-sm))] ds:border-[color:var(--card-border)] ds:shadow-[var(--shadow-card)]",
|
|
249
|
-
// Grabbed feedback (keyboard or pointer drag in flight).
|
|
250
|
-
"ds:data-[grabbed=true]:ring-[length:var(--focus-ring-width)] ds:data-[grabbed=true]:ring-ring ds:data-[grabbed=true]:z-10",
|
|
251
|
-
// Only reachable when stacking removes the focused edit control: the
|
|
252
|
-
// widget then takes focus itself (tabindex -1, set at that moment).
|
|
253
|
-
"ds:focus-visible:outline-[length:var(--focus-ring-width)] ds:focus-visible:outline-solid ds:focus-visible:outline-ring ds:focus-visible:outline-offset-[length:var(--focus-ring-offset)]"
|
|
254
|
-
].join(" "),
|
|
255
|
-
{
|
|
256
|
-
variants: {
|
|
257
|
-
stacked: {
|
|
258
|
-
false: [
|
|
259
|
-
"ds:[grid-column-start:var(--dg-x)] ds:[grid-column-end:span_var(--dg-w)]",
|
|
260
|
-
"ds:[grid-row-start:var(--dg-y)] ds:[grid-row-end:span_var(--dg-h)]"
|
|
261
|
-
].join(" "),
|
|
262
|
-
// Full width, and at least the block size the widget has in the
|
|
263
|
-
// grid (h rows plus the h - 1 gaps it spans there). A minimum, not a
|
|
264
|
-
// fixed size: at 200% zoom or with long text the widget grows
|
|
265
|
-
// instead of clipping its content (WCAG 1.4.4, 1.4.10).
|
|
266
|
-
true: [
|
|
267
|
-
"ds:col-span-full ds:row-auto",
|
|
268
|
-
"ds:[min-block-size:calc(var(--dg-h)*var(--dg-row)_+_(var(--dg-h)_-_1)*var(--spacing-md))]"
|
|
269
|
-
].join(" ")
|
|
270
|
-
}
|
|
271
|
-
},
|
|
272
|
-
defaultVariants: { stacked: !1 }
|
|
273
|
-
}
|
|
274
|
-
), Ae = et(
|
|
275
|
-
null
|
|
276
|
-
);
|
|
277
|
-
function se(r, o) {
|
|
278
|
-
Qe.forEach(r, (s) => {
|
|
279
|
-
if (Ze(s)) {
|
|
280
|
-
if (s.type === Be) {
|
|
281
|
-
se(
|
|
282
|
-
s.props.children,
|
|
283
|
-
o
|
|
284
|
-
);
|
|
285
|
-
return;
|
|
286
|
-
}
|
|
287
|
-
o(s);
|
|
288
|
-
}
|
|
289
|
-
});
|
|
290
|
-
}
|
|
291
|
-
function $e({
|
|
292
|
-
id: r,
|
|
293
|
-
title: o,
|
|
294
|
-
actionsSlot: s,
|
|
295
|
-
children: u
|
|
296
|
-
}) {
|
|
297
|
-
var x, V, N;
|
|
298
|
-
const { t: p } = Te("ui"), l = Je(Ae), f = w(null), c = l == null ? void 0 : l.layoutById.get(r);
|
|
299
|
-
if ($(() => {
|
|
300
|
-
const v = f.current;
|
|
301
|
-
!v || !c || (v.style.setProperty("--dg-x", String(c.x + 1)), v.style.setProperty("--dg-y", String(c.y + 1)), v.style.setProperty("--dg-w", String(c.w)), v.style.setProperty("--dg-h", String(c.h)));
|
|
302
|
-
}, [c == null ? void 0 : c.x, c == null ? void 0 : c.y, c == null ? void 0 : c.w, c == null ? void 0 : c.h, c]), !l || !c) return null;
|
|
303
|
-
const d = ((x = l.grab) == null ? void 0 : x.id) === r, g = l.editing;
|
|
304
|
-
return /* @__PURE__ */ J(
|
|
305
|
-
"div",
|
|
306
|
-
{
|
|
307
|
-
ref: f,
|
|
308
|
-
role: "listitem",
|
|
309
|
-
"aria-label": o,
|
|
310
|
-
"data-component": "dashboard-grid-widget",
|
|
311
|
-
"data-widget-id": r,
|
|
312
|
-
"data-grabbed": d || void 0,
|
|
313
|
-
className: pt({ stacked: l.stacked }),
|
|
314
|
-
children: [
|
|
315
|
-
/* @__PURE__ */ J("div", { className: "ds:flex ds:items-center ds:gap-[var(--spacing-xs)] ds:ps-[var(--spacing-sm)] ds:pe-[var(--spacing-sm)] ds:pt-[var(--spacing-sm)]", children: [
|
|
316
|
-
g ? /* @__PURE__ */ M(
|
|
317
|
-
ue,
|
|
318
|
-
{
|
|
319
|
-
size: "sm",
|
|
320
|
-
intent: "outline",
|
|
321
|
-
type: "button",
|
|
322
|
-
icon: /* @__PURE__ */ M(nt, {}),
|
|
323
|
-
"aria-label": p("dashboardGrid.move", { title: o }),
|
|
324
|
-
"aria-pressed": d && ((V = l.grab) == null ? void 0 : V.kind) === "move",
|
|
325
|
-
className: "ds:cursor-grab ds:touch-none ds:bg-[var(--card)]",
|
|
326
|
-
onPointerDown: (v) => l.startPointerGrab("move", r, v),
|
|
327
|
-
onKeyDown: (v) => l.keyboardStep(v, r),
|
|
328
|
-
onClick: () => l.startKeyboardGrab("move", r)
|
|
329
|
-
}
|
|
330
|
-
) : null,
|
|
331
|
-
/* @__PURE__ */ M("span", { className: "ds:min-w-0 ds:flex-1 ds:truncate ds:text-sm ds:font-medium", children: o }),
|
|
332
|
-
s,
|
|
333
|
-
g && l.canRemove ? /* @__PURE__ */ M(
|
|
334
|
-
ue,
|
|
335
|
-
{
|
|
336
|
-
size: "sm",
|
|
337
|
-
intent: "outline",
|
|
338
|
-
type: "button",
|
|
339
|
-
icon: /* @__PURE__ */ M(st, {}),
|
|
340
|
-
className: "ds:bg-[var(--card)]",
|
|
341
|
-
"aria-label": p("dashboardGrid.remove", { title: o }),
|
|
342
|
-
onClick: () => l.requestRemove(r)
|
|
343
|
-
}
|
|
344
|
-
) : null
|
|
345
|
-
] }),
|
|
346
|
-
/* @__PURE__ */ M("div", { className: "ds:min-h-0 ds:flex-1 ds:overflow-hidden ds:ps-[var(--spacing-md)] ds:pe-[var(--spacing-md)] ds:pb-[var(--spacing-md)] ds:pt-[var(--spacing-xs)]", children: u }),
|
|
347
|
-
g ? /* @__PURE__ */ M("span", { className: "ds:absolute ds:bottom-[var(--spacing-sm)] ds:end-[var(--spacing-sm)]", children: /* @__PURE__ */ M(
|
|
348
|
-
ue,
|
|
349
|
-
{
|
|
350
|
-
size: "sm",
|
|
351
|
-
intent: "outline",
|
|
352
|
-
type: "button",
|
|
353
|
-
icon: /* @__PURE__ */ M(at, {}),
|
|
354
|
-
flipIconInRtl: !0,
|
|
355
|
-
"aria-label": p("dashboardGrid.resize", { title: o }),
|
|
356
|
-
"aria-pressed": d && ((N = l.grab) == null ? void 0 : N.kind) === "resize",
|
|
357
|
-
className: "ds:touch-none ds:bg-[var(--card)]",
|
|
358
|
-
onPointerDown: (v) => l.startPointerGrab("resize", r, v),
|
|
359
|
-
onKeyDown: (v) => l.keyboardStep(v, r),
|
|
360
|
-
onClick: () => l.startKeyboardGrab("resize", r)
|
|
361
|
-
}
|
|
362
|
-
) }) : null
|
|
363
|
-
]
|
|
364
|
-
}
|
|
365
|
-
);
|
|
366
|
-
}
|
|
367
|
-
$e.displayName = "DashboardGrid.Widget";
|
|
368
|
-
const Le = qe(
|
|
369
|
-
({
|
|
370
|
-
"aria-label": r,
|
|
371
|
-
id: o,
|
|
372
|
-
cols: s = 12,
|
|
373
|
-
rowHeight: u = 96,
|
|
374
|
-
layout: p,
|
|
375
|
-
defaultLayout: l,
|
|
376
|
-
onLayoutChange: f,
|
|
377
|
-
editing: c = !1,
|
|
378
|
-
onRemoveWidget: d,
|
|
379
|
-
onRequestAdd: g,
|
|
380
|
-
stackBelow: x,
|
|
381
|
-
onStackedChange: V,
|
|
382
|
-
children: N,
|
|
383
|
-
className: v
|
|
384
|
-
}, We) => {
|
|
385
|
-
const { t: y } = Te("ui"), Q = w(null), P = w(null), [b, je] = X(!1), L = w(!1);
|
|
386
|
-
L.current = b;
|
|
387
|
-
const oe = w(null), Z = z((e) => {
|
|
388
|
-
var i;
|
|
389
|
-
if (e === L.current) return;
|
|
390
|
-
const t = Q.current, n = typeof document < "u" ? document.activeElement : null;
|
|
391
|
-
oe.current = t && n instanceof HTMLElement && t.contains(n) ? {
|
|
392
|
-
element: n,
|
|
393
|
-
widgetId: ((i = n.closest("[data-widget-id]")) == null ? void 0 : i.getAttribute("data-widget-id")) ?? null
|
|
394
|
-
} : null, L.current = e, je(e);
|
|
395
|
-
}, []);
|
|
396
|
-
$(() => {
|
|
397
|
-
const e = Q.current;
|
|
398
|
-
if (!e) return;
|
|
399
|
-
if (x === void 0) {
|
|
400
|
-
Z(!1);
|
|
401
|
-
return;
|
|
402
|
-
}
|
|
403
|
-
if (Z(
|
|
404
|
-
Ie(e.offsetWidth, x, L.current)
|
|
405
|
-
), typeof ResizeObserver > "u") return;
|
|
406
|
-
const t = new ResizeObserver((n) => {
|
|
407
|
-
var m, h;
|
|
408
|
-
const i = n[n.length - 1];
|
|
409
|
-
if (!i) return;
|
|
410
|
-
const a = ((h = (m = i.borderBoxSize) == null ? void 0 : m[0]) == null ? void 0 : h.inlineSize) ?? i.contentRect.width;
|
|
411
|
-
Z(Ie(a, x, L.current));
|
|
412
|
-
});
|
|
413
|
-
return t.observe(e), () => t.disconnect();
|
|
414
|
-
}, [x, Z]);
|
|
415
|
-
const S = c && !b, pe = A(() => {
|
|
416
|
-
const e = [];
|
|
417
|
-
return se(N, (t) => {
|
|
418
|
-
t.props.id && e.push(t.props.id);
|
|
419
|
-
}), e;
|
|
420
|
-
}, [N]), me = A(() => {
|
|
421
|
-
const e = /* @__PURE__ */ new Map();
|
|
422
|
-
return se(N, (t) => {
|
|
423
|
-
t.props.id && e.set(t.props.id, {
|
|
424
|
-
defaultW: t.props.defaultW ?? 4,
|
|
425
|
-
defaultH: t.props.defaultH ?? 2
|
|
426
|
-
});
|
|
427
|
-
}), e;
|
|
428
|
-
}, [N]), [_e, Fe] = X(() => l ?? []), ge = p ?? _e, I = z(
|
|
429
|
-
(e) => {
|
|
430
|
-
p === void 0 && Fe(e), f == null || f(e);
|
|
431
|
-
},
|
|
432
|
-
[p, f]
|
|
433
|
-
), { resolved: k, autoPlaced: be } = A(() => {
|
|
434
|
-
const e = ge.map((i) => ie(i, s)), t = pe.filter(
|
|
435
|
-
(i) => !e.some((a) => a.id === i)
|
|
436
|
-
);
|
|
437
|
-
if (t.length === 0)
|
|
438
|
-
return { resolved: e, autoPlaced: !1 };
|
|
439
|
-
const n = [...e];
|
|
440
|
-
for (const i of t) {
|
|
441
|
-
const a = me.get(i) ?? { defaultW: 4, defaultH: 2 }, m = Math.min(a.defaultW, s), h = ze(n, s, m, a.defaultH);
|
|
442
|
-
n.push({ id: i, x: h.x, y: h.y, w: m, h: a.defaultH });
|
|
443
|
-
}
|
|
444
|
-
return { resolved: F(n, s), autoPlaced: !0 };
|
|
445
|
-
}, [ge, pe, me, s]), he = w("");
|
|
446
|
-
ne(() => {
|
|
447
|
-
if (!be) return;
|
|
448
|
-
const e = k.map(
|
|
449
|
-
(t) => `${t.id}:${t.x},${t.y},${t.w},${t.h}`
|
|
450
|
-
).join("|");
|
|
451
|
-
he.current !== e && (he.current = e, I(k));
|
|
452
|
-
}, [be, k, I]);
|
|
453
|
-
const [Ke, Oe] = X(null), [E, ye] = X(null), [Ue, W] = X(""), ae = w(null), C = w(null), H = w(null), B = w(!1), Y = w(s);
|
|
454
|
-
Y.current = s;
|
|
455
|
-
const K = w(k);
|
|
456
|
-
K.current = k;
|
|
457
|
-
const T = z((e) => {
|
|
458
|
-
ae.current = e, Oe(e);
|
|
459
|
-
}, []), ee = z(
|
|
460
|
-
(e, t, n) => {
|
|
461
|
-
const i = { kind: e, id: t, via: n };
|
|
462
|
-
C.current = { ...i, baseLayout: K.current }, ye(i), T(K.current);
|
|
463
|
-
},
|
|
464
|
-
[T]
|
|
465
|
-
), q = Ke ?? k, ve = A(
|
|
466
|
-
() => new Map(q.map((e) => [e.id, e])),
|
|
467
|
-
[q]
|
|
468
|
-
), we = z(
|
|
469
|
-
(e, t) => {
|
|
470
|
-
W(
|
|
471
|
-
e === "move" ? y("dashboardGrid.movedTo", { col: t.x + 1, row: t.y + 1 }) : y("dashboardGrid.resizedTo", { cols: t.w, rows: t.h })
|
|
472
|
-
);
|
|
473
|
-
},
|
|
474
|
-
[y]
|
|
475
|
-
), G = z(
|
|
476
|
-
(e) => {
|
|
477
|
-
const t = ae.current, n = C.current;
|
|
478
|
-
if (C.current = null, H.current = null, ye(null), T(null), !e || !t || !n) {
|
|
479
|
-
W(y("dashboardGrid.cancelled"));
|
|
480
|
-
return;
|
|
481
|
-
}
|
|
482
|
-
const i = F(t, Y.current), a = (h) => h.map((R) => `${R.id}:${R.x},${R.y},${R.w},${R.h}`).join("|");
|
|
483
|
-
if (a(i) === a(K.current)) {
|
|
484
|
-
W(y("dashboardGrid.cancelled"));
|
|
485
|
-
return;
|
|
486
|
-
}
|
|
487
|
-
I(i);
|
|
488
|
-
const m = i.find((h) => h.id === n.id);
|
|
489
|
-
W(
|
|
490
|
-
m ? y("dashboardGrid.droppedAt", {
|
|
491
|
-
col: m.x + 1,
|
|
492
|
-
row: m.y + 1
|
|
493
|
-
}) : y("dashboardGrid.cancelled")
|
|
494
|
-
);
|
|
495
|
-
},
|
|
496
|
-
[T, I, y]
|
|
497
|
-
), xe = z(
|
|
498
|
-
(e, t) => {
|
|
499
|
-
if (!S) return;
|
|
500
|
-
if (B.current) {
|
|
501
|
-
B.current = !1;
|
|
502
|
-
return;
|
|
503
|
-
}
|
|
504
|
-
const n = C.current;
|
|
505
|
-
if ((n == null ? void 0 : n.via) !== "pointer") {
|
|
506
|
-
if (n && n.id === t && n.kind === e) {
|
|
507
|
-
G(!0);
|
|
508
|
-
return;
|
|
509
|
-
}
|
|
510
|
-
ee(e, t, "keyboard"), W(
|
|
511
|
-
y(e === "move" ? "dashboardGrid.grabbed" : "dashboardGrid.resizeGrabbed")
|
|
512
|
-
);
|
|
513
|
-
}
|
|
514
|
-
},
|
|
515
|
-
[S, ee, G, y]
|
|
516
|
-
), ke = z(
|
|
517
|
-
(e, t) => {
|
|
518
|
-
const n = C.current;
|
|
519
|
-
if (!n || n.id !== t || n.via !== "keyboard")
|
|
520
|
-
return;
|
|
521
|
-
if (e.key === "Escape") {
|
|
522
|
-
e.preventDefault(), G(!1);
|
|
523
|
-
return;
|
|
524
|
-
}
|
|
525
|
-
if (!["ArrowLeft", "ArrowRight", "ArrowUp", "ArrowDown"].includes(e.key)) return;
|
|
526
|
-
e.preventDefault();
|
|
527
|
-
const a = typeof window < "u" && P.current ? window.getComputedStyle(P.current).direction === "rtl" : !1, m = e.key === "ArrowRight" ? a ? -1 : 1 : e.key === "ArrowLeft" ? a ? 1 : -1 : 0, h = e.key === "ArrowDown" ? 1 : e.key === "ArrowUp" ? -1 : 0, D = (ae.current ?? n.baseLayout).find((O) => O.id === t);
|
|
528
|
-
if (!D) return;
|
|
529
|
-
const j = n.kind === "move" ? le(
|
|
530
|
-
n.baseLayout,
|
|
531
|
-
t,
|
|
532
|
-
D.x + m,
|
|
533
|
-
D.y + h,
|
|
534
|
-
s
|
|
535
|
-
) : fe(
|
|
536
|
-
n.baseLayout,
|
|
537
|
-
t,
|
|
538
|
-
D.w + m,
|
|
539
|
-
D.h + h,
|
|
540
|
-
s
|
|
541
|
-
);
|
|
542
|
-
T(j);
|
|
543
|
-
const _ = j.find((O) => O.id === t);
|
|
544
|
-
_ && we(n.kind, _);
|
|
545
|
-
},
|
|
546
|
-
[s, G, T, we]
|
|
547
|
-
), Ge = z(
|
|
548
|
-
(e, t, n) => {
|
|
549
|
-
var _, O, Pe, Ee;
|
|
550
|
-
if (!S || C.current) return;
|
|
551
|
-
const i = P.current, a = K.current.find((Ye) => Ye.id === t);
|
|
552
|
-
if (!i || !a) return;
|
|
553
|
-
n.preventDefault(), (O = (_ = n.currentTarget).focus) == null || O.call(_);
|
|
554
|
-
const m = i.getBoundingClientRect();
|
|
555
|
-
if (m.width <= 0) return;
|
|
556
|
-
const h = window.getComputedStyle(i), R = Number.parseFloat(h.columnGap) || 0, D = Number.parseFloat(h.rowGap) || 0, j = (m.width - R * (s - 1)) / s;
|
|
557
|
-
H.current = {
|
|
558
|
-
kind: e,
|
|
559
|
-
id: t,
|
|
560
|
-
pointerId: n.pointerId,
|
|
561
|
-
startClientX: n.clientX,
|
|
562
|
-
startClientY: n.clientY,
|
|
563
|
-
origin: a,
|
|
564
|
-
colStride: j + R,
|
|
565
|
-
rowStride: u + D,
|
|
566
|
-
isRtl: h.direction === "rtl"
|
|
567
|
-
};
|
|
568
|
-
try {
|
|
569
|
-
(Ee = (Pe = n.currentTarget).setPointerCapture) == null || Ee.call(Pe, n.pointerId);
|
|
570
|
-
} catch {
|
|
571
|
-
}
|
|
572
|
-
ee(e, t, "pointer");
|
|
573
|
-
},
|
|
574
|
-
[S, s, u, ee]
|
|
575
|
-
);
|
|
576
|
-
ne(() => {
|
|
577
|
-
if (!E || E.via !== "pointer") return;
|
|
578
|
-
const e = (i) => {
|
|
579
|
-
const a = H.current, m = C.current;
|
|
580
|
-
if (!a || !m || i.pointerId !== a.pointerId)
|
|
581
|
-
return;
|
|
582
|
-
const h = i.clientX - a.startClientX, R = i.clientY - a.startClientY, D = Math.round(h / a.colStride) * (a.isRtl ? -1 : 1), j = Math.round(R / a.rowStride), _ = a.kind === "move" ? le(
|
|
583
|
-
m.baseLayout,
|
|
584
|
-
a.id,
|
|
585
|
-
a.origin.x + D,
|
|
586
|
-
a.origin.y + j,
|
|
587
|
-
Y.current
|
|
588
|
-
) : fe(
|
|
589
|
-
m.baseLayout,
|
|
590
|
-
a.id,
|
|
591
|
-
a.origin.w + D,
|
|
592
|
-
a.origin.h + j,
|
|
593
|
-
Y.current
|
|
594
|
-
);
|
|
595
|
-
T(_);
|
|
596
|
-
}, t = (i) => {
|
|
597
|
-
const a = H.current;
|
|
598
|
-
!a || i.pointerId !== a.pointerId || (B.current = !0, G(!0));
|
|
599
|
-
}, n = (i) => {
|
|
600
|
-
const a = H.current;
|
|
601
|
-
!a || i.pointerId !== a.pointerId || (B.current = !0, G(!1));
|
|
602
|
-
};
|
|
603
|
-
return window.addEventListener("pointermove", e), window.addEventListener("pointerup", t), window.addEventListener("pointercancel", n), () => {
|
|
604
|
-
window.removeEventListener("pointermove", e), window.removeEventListener("pointerup", t), window.removeEventListener("pointercancel", n);
|
|
605
|
-
};
|
|
606
|
-
}, [E, G, T]), ne(() => {
|
|
607
|
-
if (!E) return;
|
|
608
|
-
const e = (t) => {
|
|
609
|
-
t.key === "Escape" && G(!1);
|
|
610
|
-
};
|
|
611
|
-
return window.addEventListener("keydown", e), () => window.removeEventListener("keydown", e);
|
|
612
|
-
}, [E, G]), ne(() => {
|
|
613
|
-
if (!E || E.via !== "keyboard") return;
|
|
614
|
-
const e = (n) => {
|
|
615
|
-
var a;
|
|
616
|
-
const i = n.relatedTarget;
|
|
617
|
-
(!i || !((a = P.current) != null && a.contains(i))) && G(!1);
|
|
618
|
-
}, t = P.current;
|
|
619
|
-
return t == null || t.addEventListener("focusout", e), () => t == null ? void 0 : t.removeEventListener("focusout", e);
|
|
620
|
-
}, [E, G]), $(() => {
|
|
621
|
-
b && (C.current && G(!1), c && W(y("dashboardGrid.stackedReadOnly")));
|
|
622
|
-
}, [b, c, G, y]), $(() => {
|
|
623
|
-
var a;
|
|
624
|
-
const e = oe.current;
|
|
625
|
-
oe.current = null;
|
|
626
|
-
const t = Q.current;
|
|
627
|
-
if (!e || !t) return;
|
|
628
|
-
const n = document.activeElement;
|
|
629
|
-
if (n === e.element || n !== null && n !== document.body) return;
|
|
630
|
-
if (t.contains(e.element)) {
|
|
631
|
-
e.element.focus();
|
|
632
|
-
return;
|
|
633
|
-
}
|
|
634
|
-
const i = e.widgetId ? Array.from(
|
|
635
|
-
t.querySelectorAll("[data-widget-id]")
|
|
636
|
-
).find(
|
|
637
|
-
(m) => m.getAttribute("data-widget-id") === e.widgetId
|
|
638
|
-
) : void 0;
|
|
639
|
-
if (i) {
|
|
640
|
-
i.setAttribute("tabindex", "-1"), i.focus();
|
|
641
|
-
return;
|
|
642
|
-
}
|
|
643
|
-
(a = P.current) == null || a.focus();
|
|
644
|
-
}, [b]);
|
|
645
|
-
const te = w(V);
|
|
646
|
-
te.current = V;
|
|
647
|
-
const Me = w(!1);
|
|
648
|
-
$(() => {
|
|
649
|
-
var e;
|
|
650
|
-
Me.current !== b && (Me.current = b, (e = te.current) == null || e.call(te, b));
|
|
651
|
-
}, [b]), $(() => {
|
|
652
|
-
const e = P.current;
|
|
653
|
-
e && (e.style.setProperty("--dg-cols", String(s)), e.style.setProperty("--dg-row", `${u}px`));
|
|
654
|
-
}, [s, u]);
|
|
655
|
-
const Se = ct(q);
|
|
656
|
-
$(() => {
|
|
657
|
-
const e = P.current;
|
|
658
|
-
e && (e.style.setProperty(
|
|
659
|
-
"--dg-grid-lines",
|
|
660
|
-
`repeating-linear-gradient(to right, color-mix(in srgb, var(--border) 50%, transparent) 0 1px, transparent 1px calc((100% + var(--spacing-md)) / ${s})), repeating-linear-gradient(to bottom, color-mix(in srgb, var(--border) 50%, transparent) 0 1px, transparent 1px calc(${u}px + var(--spacing-md)))`
|
|
661
|
-
), e.style.setProperty(
|
|
662
|
-
"--dg-min-block",
|
|
663
|
-
`calc(${Se + 2} * (${u}px + var(--spacing-md)) - var(--spacing-md))`
|
|
664
|
-
));
|
|
665
|
-
}, [s, u, Se]);
|
|
666
|
-
const Re = w(null), de = S && !!g, re = A(
|
|
667
|
-
() => de ? ze(q, s, 2, 2) : null,
|
|
668
|
-
[de, q, s]
|
|
669
|
-
);
|
|
670
|
-
$(() => {
|
|
671
|
-
const e = Re.current;
|
|
672
|
-
!e || !re || (e.style.setProperty("--dg-x", String(re.x + 1)), e.style.setProperty("--dg-y", String(re.y + 1)), e.style.setProperty("--dg-w", "2"), e.style.setProperty("--dg-h", "2"));
|
|
673
|
-
}, [re]);
|
|
674
|
-
const Ne = z(
|
|
675
|
-
(e) => {
|
|
676
|
-
I(
|
|
677
|
-
F(
|
|
678
|
-
K.current.filter((t) => t.id !== e),
|
|
679
|
-
Y.current
|
|
680
|
-
)
|
|
681
|
-
), W(y("dashboardGrid.removed")), d == null || d(e), requestAnimationFrame(() => {
|
|
682
|
-
const t = P.current;
|
|
683
|
-
if (!t) return;
|
|
684
|
-
const n = t.querySelector("button");
|
|
685
|
-
n ? n.focus() : t.focus();
|
|
686
|
-
});
|
|
687
|
-
},
|
|
688
|
-
[I, d, y]
|
|
689
|
-
), ce = A(
|
|
690
|
-
() => ({
|
|
691
|
-
moveWidgetTo(e, t, n) {
|
|
692
|
-
return !S || L.current || !Number.isFinite(t) || !Number.isFinite(n) || !k.some((i) => i.id === e) ? !1 : (I(
|
|
693
|
-
F(
|
|
694
|
-
le(k, e, Math.round(t), Math.round(n), s),
|
|
695
|
-
s
|
|
696
|
-
)
|
|
697
|
-
), !0);
|
|
698
|
-
},
|
|
699
|
-
resizeWidgetTo(e, t, n) {
|
|
700
|
-
return !S || L.current || !Number.isFinite(t) || !Number.isFinite(n) || !k.some((i) => i.id === e) ? !1 : (I(
|
|
701
|
-
F(
|
|
702
|
-
fe(
|
|
703
|
-
k,
|
|
704
|
-
e,
|
|
705
|
-
Math.round(t),
|
|
706
|
-
Math.round(n),
|
|
707
|
-
s
|
|
708
|
-
),
|
|
709
|
-
s
|
|
710
|
-
)
|
|
711
|
-
), !0);
|
|
712
|
-
},
|
|
713
|
-
getGridState() {
|
|
714
|
-
return {
|
|
715
|
-
cols: s,
|
|
716
|
-
editing: c,
|
|
717
|
-
stacked: b,
|
|
718
|
-
layout: k.map((e) => ({ ...e }))
|
|
719
|
-
};
|
|
720
|
-
}
|
|
721
|
-
}),
|
|
722
|
-
[S, c, b, k, s, I]
|
|
723
|
-
);
|
|
724
|
-
Xe(We, () => ce, [ce]), tt(dt, ce, o);
|
|
725
|
-
const Ve = A(
|
|
726
|
-
() => ({
|
|
727
|
-
editing: S,
|
|
728
|
-
stacked: b,
|
|
729
|
-
layoutById: ve,
|
|
730
|
-
grab: E,
|
|
731
|
-
canRemove: !!d,
|
|
732
|
-
requestRemove: Ne,
|
|
733
|
-
startKeyboardGrab: xe,
|
|
734
|
-
keyboardStep: ke,
|
|
735
|
-
startPointerGrab: Ge
|
|
736
|
-
}),
|
|
737
|
-
[
|
|
738
|
-
S,
|
|
739
|
-
b,
|
|
740
|
-
ve,
|
|
741
|
-
E,
|
|
742
|
-
d,
|
|
743
|
-
Ne,
|
|
744
|
-
xe,
|
|
745
|
-
ke,
|
|
746
|
-
Ge
|
|
747
|
-
]
|
|
748
|
-
), He = A(() => {
|
|
749
|
-
if (x === void 0) return N;
|
|
750
|
-
const e = [], t = /* @__PURE__ */ new Map(), n = [];
|
|
751
|
-
return se(N, (i) => {
|
|
752
|
-
const a = i.props.id;
|
|
753
|
-
if (a && !t.has(a)) {
|
|
754
|
-
const m = De(i, {
|
|
755
|
-
key: `widget:${a}:${i.key ?? ""}`
|
|
756
|
-
});
|
|
757
|
-
t.set(a, m), e.push(m);
|
|
758
|
-
} else {
|
|
759
|
-
const m = De(i, {
|
|
760
|
-
key: i.key === null ? `child:at:${n.length}` : `child:key:${i.key}`
|
|
761
|
-
});
|
|
762
|
-
n.push(m), e.push(m);
|
|
763
|
-
}
|
|
764
|
-
}), b ? [
|
|
765
|
-
...lt([...t.keys()], k).map(
|
|
766
|
-
(i) => t.get(i)
|
|
767
|
-
),
|
|
768
|
-
...n
|
|
769
|
-
] : e;
|
|
770
|
-
}, [x, N, b, k]);
|
|
771
|
-
return /* @__PURE__ */ J(
|
|
772
|
-
"div",
|
|
773
|
-
{
|
|
774
|
-
ref: Q,
|
|
775
|
-
"data-component": "dashboard-grid",
|
|
776
|
-
"data-component-id": o,
|
|
777
|
-
"data-editing": S || void 0,
|
|
778
|
-
"data-stacked": b || void 0,
|
|
779
|
-
className: `ds:block ds:w-full ${v ?? ""}`.trim(),
|
|
780
|
-
children: [
|
|
781
|
-
/* @__PURE__ */ M("div", { role: "status", "aria-live": "polite", className: "ds:sr-only", children: Ue }),
|
|
782
|
-
/* @__PURE__ */ J(
|
|
783
|
-
"div",
|
|
784
|
-
{
|
|
785
|
-
ref: P,
|
|
786
|
-
role: "list",
|
|
787
|
-
"aria-label": r,
|
|
788
|
-
tabIndex: -1,
|
|
789
|
-
"data-editing": S || void 0,
|
|
790
|
-
"data-stacked": b || void 0,
|
|
791
|
-
className: ft({ stacked: b }),
|
|
792
|
-
children: [
|
|
793
|
-
/* @__PURE__ */ M(Ae.Provider, { value: Ve, children: He }),
|
|
794
|
-
de ? (
|
|
795
|
-
// role="list" allows only listitem children — the tile wrapper
|
|
796
|
-
// carries the grid placement, the button fills it.
|
|
797
|
-
/* @__PURE__ */ M(
|
|
798
|
-
"div",
|
|
799
|
-
{
|
|
800
|
-
ref: Re,
|
|
801
|
-
role: "listitem",
|
|
802
|
-
className: [
|
|
803
|
-
"ds:flex",
|
|
804
|
-
"ds:[grid-column-start:var(--dg-x)] ds:[grid-column-end:span_var(--dg-w)]",
|
|
805
|
-
"ds:[grid-row-start:var(--dg-y)] ds:[grid-row-end:span_var(--dg-h)]"
|
|
806
|
-
].join(" "),
|
|
807
|
-
children: /* @__PURE__ */ J(
|
|
808
|
-
"button",
|
|
809
|
-
{
|
|
810
|
-
type: "button",
|
|
811
|
-
onClick: g,
|
|
812
|
-
className: [
|
|
813
|
-
"ds:flex ds:flex-1 ds:items-center ds:justify-center ds:gap-[var(--spacing-xs)]",
|
|
814
|
-
"ds:rounded-[var(--radius-lg)] ds:border ds:border-dashed ds:border-border",
|
|
815
|
-
"ds:text-sm ds:text-muted-foreground ds:transition-colors",
|
|
816
|
-
"ds:hover:bg-muted/10 ds:hover:text-foreground",
|
|
817
|
-
"ds:focus-visible:outline-[length:var(--focus-ring-width)] ds:focus-visible:outline-solid ds:focus-visible:outline-ring"
|
|
818
|
-
].join(" "),
|
|
819
|
-
children: [
|
|
820
|
-
/* @__PURE__ */ M(rt, { "aria-hidden": "true", className: "ds:size-4" }),
|
|
821
|
-
y("dashboardGrid.add")
|
|
822
|
-
]
|
|
823
|
-
}
|
|
824
|
-
)
|
|
825
|
-
}
|
|
826
|
-
)
|
|
827
|
-
) : null
|
|
828
|
-
]
|
|
829
|
-
}
|
|
830
|
-
)
|
|
831
|
-
]
|
|
832
|
-
}
|
|
833
|
-
);
|
|
834
|
-
}
|
|
835
|
-
);
|
|
836
|
-
Le.displayName = "DashboardGrid";
|
|
837
|
-
const St = Object.assign(Le, {
|
|
838
|
-
Widget: $e
|
|
839
|
-
});
|
|
840
|
-
export {
|
|
841
|
-
St as D,
|
|
842
|
-
dt as d
|
|
843
|
-
};
|
|
844
|
-
//# sourceMappingURL=dashboard-grid-DfEY2qci.js.map
|