@alfadocs/ui-kit 0.64.0 → 0.66.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/{agenda-tray-DA6qj8BL.js → agenda-tray-Bh1KfEOG.js} +2 -2
- package/dist/_chunks/{ai-consent-banner-DBKV27je.js → ai-consent-banner-Btzmk8OH.js} +3 -2
- package/dist/_chunks/{ai-prompt-input-Dx8eXoPm.js → ai-prompt-input-BwEACCPm.js} +2 -2
- package/dist/_chunks/{ai-tools-rail-7tC3GT4h.js → ai-tools-rail-DAfaW8eA.js} +65 -56
- package/dist/_chunks/{alia-sidebar-DlvyXgVC.js → alia-sidebar-CN8pA6c-.js} +7 -7
- package/dist/_chunks/{anamnesis-card-CmkBVAln.js → anamnesis-card-qeLYRG79.js} +2 -2
- package/dist/_chunks/{antenatal-schedule-timeline-CdiqkF05.js → antenatal-schedule-timeline-BfzFjEyb.js} +3 -3
- package/dist/_chunks/{appointment-tray-BwDHhWWC.js → appointment-tray-BQnJEora.js} +2 -2
- package/dist/_chunks/{ar-C68WKG5a.js → ar-Cn5Fq48Z.js} +2 -2
- package/dist/_chunks/{audio-recorder-CdXuT9ln.js → audio-recorder-DjXLP4aF.js} +2 -2
- package/dist/_chunks/{autocomplete-CDqxB68B.js → autocomplete-CcCFlVf-.js} +4 -4
- package/dist/_chunks/{bishop-score-CzjSx-dm.js → bishop-score-DPN4Ched.js} +2 -2
- package/dist/_chunks/{bmi-calculator-DA2NGmVK.js → bmi-calculator-DuUneHuZ.js} +2 -2
- package/dist/_chunks/{booking-ChfvWy3P.js → booking-L8-YP8BJ.js} +148 -148
- package/dist/_chunks/calendar-B6soK1Yb.js +17 -0
- package/dist/_chunks/{calendar-CkuJIg3s.js → calendar-oYWOCrnf.js} +1 -1
- package/dist/_chunks/{care-plan-card-DhZNoXs4.js → care-plan-card-D42WD4-T.js} +2 -2
- package/dist/_chunks/{care-plan-entry-card-DW70yBOD.js → care-plan-entry-card-BukNI7Uy.js} +2 -2
- package/dist/_chunks/{carousel.agent-DrX96W-1.js → carousel.agent-vt21A_el.js} +2 -2
- package/dist/_chunks/{chat-input-CFwc7JxL.js → chat-input-B5zjNEUN.js} +2 -2
- package/dist/_chunks/{chat-message-Dm8U2RY1.js → chat-message-3V54YipB.js} +2 -2
- package/dist/_chunks/{code-block-HoddNOKJ.js → code-block-BBWHhIc8.js} +2 -2
- package/dist/_chunks/columns-2-BTOBZbep.js +15 -0
- package/dist/_chunks/{contact-profile-card-DvvVfAA2.js → contact-profile-card-CCeJmjbd.js} +2 -2
- package/dist/_chunks/{cycle-calculator-C_t1Hs8V.js → cycle-calculator-D6LTmtQt.js} +4 -4
- package/dist/_chunks/{date-picker-BfHblqwA.js → date-picker-oGg5BnXL.js} +12 -11
- package/dist/_chunks/{date-picker-variants-CXEAx3O_.js → date-picker-variants-DAcSLTua.js} +358 -372
- package/dist/_chunks/{date-range-picker-hcAMs1wO.js → date-range-picker-C5BWfH_T.js} +34 -25
- package/dist/_chunks/{date-time-picker-H-3Pwqlb.js → date-time-picker-Ze1My59T.js} +18 -17
- package/dist/_chunks/{de-DK4A9_a8.js → de-CrJs4ZsX.js} +2 -2
- package/dist/_chunks/{description-list-BEbK2g93.js → description-list-gkNGWk5G.js} +2 -2
- package/dist/_chunks/{due-date-calculator-Q8MIwEVV.js → due-date-calculator-CIG194vq.js} +4 -4
- package/dist/_chunks/{editable-currency-cell-renderer-BQgaKFCz.js → editable-currency-cell-renderer-f3d0Rhue.js} +535 -535
- package/dist/_chunks/editor-overlay-wYm22wZK.js +88 -0
- package/dist/_chunks/{el-B29HXhG5.js → el-DHdMOIhL.js} +6 -6
- package/dist/_chunks/{es-BOwPVwWn.js → es-DCATCfqo.js} +2 -2
- package/dist/_chunks/{fetal-weight-D1a6BmM-.js → fetal-weight-Xf8-ZoDy.js} +2 -2
- package/dist/_chunks/{fiscal-code-input-BZ0FxwUl.js → fiscal-code-input-DPtqluVb.js} +2 -2
- package/dist/_chunks/{fr-DoDBtn0T.js → fr-BfGEMshF.js} +2 -2
- package/dist/_chunks/{freemium-paywall-gHGA44dW.js → freemium-paywall-CkWjv3o6.js} +2 -2
- package/dist/_chunks/{gestational-age-calculator-D85E8lGN.js → gestational-age-calculator-BGsZaWXW.js} +6 -6
- package/dist/_chunks/{hcg-doubling-Dg0Hr7ey.js → hcg-doubling-LH5i6oM7.js} +3 -3
- package/dist/_chunks/{header-Ce1Br27u.js → header-CNszv2WQ.js} +2 -2
- package/dist/_chunks/{header-settings-D5Z2B_Yz.js → header-settings-CNOqIhoW.js} +3 -3
- package/dist/_chunks/{hi-DGByrKby.js → hi-CBFRXEIm.js} +2 -2
- package/dist/_chunks/icon-button-LqoiKcUN.js +78 -0
- package/dist/_chunks/image-C6RM5hfF.js +16 -0
- package/dist/_chunks/{insert-result-C1SYdueh.js → insert-result-njqBthzT.js} +115 -125
- package/dist/_chunks/{isSameWeek-B1odL2vR.js → isSameWeek-I3DfXUp1.js} +2 -2
- package/dist/_chunks/{it-B16rEecm.js → it-nz6vAKwG.js} +7 -7
- package/dist/_chunks/{ja-B0viOgft.js → ja-DQcqdAEJ.js} +2 -2
- package/dist/_chunks/{key-value-pair-CkQIb9EG.js → key-value-pair-BrgbMfbF.js} +2 -2
- package/dist/_chunks/{locale-picker-D99UyZVJ.js → locale-picker-C9JmBht3.js} +3 -3
- package/dist/_chunks/{marketplace-app-shell-C4OYAC22.js → marketplace-app-shell-Cou6XnMJ.js} +5 -5
- package/dist/_chunks/{message-card-Dvl1TgaN.js → message-card-Bgcvfj6-.js} +2 -2
- package/dist/_chunks/{message-tray-Dl6GQaaV.js → message-tray-saAVMeHP.js} +3 -3
- package/dist/_chunks/{multi-select-DOLO3K_z.js → multi-select-BcPylvHR.js} +100 -90
- package/dist/_chunks/{nl-cBxEX2QU.js → nl-L5SuDjyl.js} +2 -2
- package/dist/_chunks/{notification-card-CObnGdJu.js → notification-card-BiESdm8q.js} +2 -2
- package/dist/_chunks/{notification-tray-BWHDIjgd.js → notification-tray-DlgenTEe.js} +3 -3
- package/dist/_chunks/{patient-search-CArmRKeg.js → patient-search-Bw9ONucF.js} +2 -2
- package/dist/_chunks/{patient-shell-Coarf346.js → patient-shell-Tgpv0HND.js} +4 -4
- package/dist/_chunks/{patient-summary-card-BnTqxcTr.js → patient-summary-card-Bgso0p_l.js} +2 -2
- package/dist/_chunks/{payment-form-DJ9vnzrT.js → payment-form-nXocS_MX.js} +11 -4
- package/dist/_chunks/{payment-request-card-B_lyobd0.js → payment-request-card-DBz3hVDz.js} +3 -3
- package/dist/_chunks/{pdf-viewer-chMpwpA4.js → pdf-viewer-GsfNqeeT.js} +3 -3
- package/dist/_chunks/{periodontal-chart-card-BYs9hax1.js → periodontal-chart-card-AYyHtU9K.js} +2 -2
- package/dist/_chunks/phone-input-DVXhNlIl.js +563 -0
- package/dist/_chunks/{pl-DtS08ioY.js → pl-YAn5z2wR.js} +3 -3
- package/dist/_chunks/{popover-Devce-tT.js → popover-DTbfAuR0.js} +2 -2
- package/dist/_chunks/{practice-results-CtfciF2v.js → practice-results-CVAgY2RZ.js} +3 -3
- package/dist/_chunks/{pregnancy-dating-7NUaAfob.js → pregnancy-dating-f9aJbiAk.js} +6 -6
- package/dist/_chunks/{pregnancy-weight-gain-DI7X-0JX.js → pregnancy-weight-gain-BMRBeA8V.js} +2 -2
- package/dist/_chunks/{privacy-lock-BN3L-alb.js → privacy-lock-C7JyMf0y.js} +2 -2
- package/dist/_chunks/{product-hub-panel-CkfZBA3t.js → product-hub-panel-CAXDFeGP.js} +2 -2
- package/dist/_chunks/{pt-yFXs1VvH.js → pt-D9xdT5KQ.js} +6 -6
- package/dist/_chunks/{public-header.agent-CYQK6T6F.js → public-header.agent-BOhJgZEU.js} +3 -3
- package/dist/_chunks/{reviews-panel-CPrXu5TX.js → reviews-panel-DBktKm7i.js} +2 -2
- package/dist/_chunks/rich-text-editor-B5XQNxe8.js +1586 -0
- package/dist/_chunks/{ro-DsCzSrzR.js → ro-Cp--52bT.js} +2 -2
- package/dist/_chunks/{ru-DgDxL0pc.js → ru-BM8eX_Zz.js} +3 -3
- package/dist/_chunks/{search-bar-CvN_S0jW.js → search-bar-SY2BcV2N.js} +2 -2
- package/dist/_chunks/{search-input-D3aMvi4l.js → search-input-DbxrnHkW.js} +3 -3
- package/dist/_chunks/{sheet-xbzu4YiY.js → sheet-taJer-Ha.js} +2 -2
- package/dist/_chunks/{sidebar-DPEHzxLZ.js → sidebar-BFwbx74W.js} +12 -1
- package/dist/_chunks/{sign-document--nr5cxsB.js → sign-document-CdAiHiCh.js} +2 -2
- package/dist/_chunks/{sign-in-with-alfadocs-button-BpAjVmsI.js → sign-in-with-alfadocs-button-LppxjlFt.js} +2 -2
- package/dist/_chunks/{signature-field-DbhbpLha.js → signature-field-Dy1JRjzE.js} +10 -3
- package/dist/_chunks/{slot-grid-BlHHP9Qy.js → slot-grid-FsqumOaS.js} +2 -2
- package/dist/_chunks/smart-date-CWikAqZx.js +114 -0
- package/dist/_chunks/{social-sign-in-button-uJYLM366.js → social-sign-in-button-dlpPI5l7.js} +2 -2
- package/dist/_chunks/{spinner-OjQNn8oN.js → spinner-hbwuKwMf.js} +10 -10
- package/dist/_chunks/{sq-DHlCYN67.js → sq-XRpr0r49.js} +6 -6
- package/dist/_chunks/{streaming-text-CfhDqtIT.js → streaming-text-BB9mvK4m.js} +2 -2
- package/dist/_chunks/subDays-BcYv1Lxi.js +8 -0
- package/dist/_chunks/{sv-O0QaQs_s.js → sv-Z3APomE8.js} +2 -2
- package/dist/_chunks/{task-tray-Cb_hK4yb.js → task-tray-CAncV-QQ.js} +2 -2
- package/dist/_chunks/{theme-toggle-DAW7uC0B.js → theme-toggle-DETmSu_h.js} +2 -2
- package/dist/_chunks/{toast.agent-B0MCsvdZ.js → toast.agent-vuLRRn2a.js} +2 -2
- package/dist/_chunks/{tooth-scheme-CiphQaON.js → tooth-scheme-BIx1O2aJ.js} +3 -3
- package/dist/_chunks/{tr-BmNDRuio.js → tr-e0-P4FON.js} +2 -2
- package/dist/_chunks/{transcript-panel-B4HiC7ed.js → transcript-panel-CLHmv83g.js} +2 -2
- package/dist/_chunks/trash-2-rPAKaRgB.js +18 -0
- package/dist/_chunks/{unit-converter-BIbXHIQA.js → unit-converter-C1V3ACM9.js} +2 -2
- package/dist/_chunks/{wallet-pay-button-DuDPBlCO.js → wallet-pay-button--dnR6NfJ.js} +2 -2
- package/dist/_chunks/{workflow-map-BJDUNYlX.js → workflow-map-Bt4Of5dT.js} +137 -149
- package/dist/_chunks/{zh-CN-CgVJZEzz.js → zh-CN-B-igM5gY.js} +3 -3
- package/dist/agent-catalog.json +32 -1
- package/dist/components/agenda-tray/index.js +1 -1
- package/dist/components/ai-consent-banner/index.js +1 -1
- package/dist/components/ai-prompt-input/index.js +1 -1
- package/dist/components/ai-tools-rail/index.js +1 -1
- package/dist/components/anamnesis-card/index.js +1 -1
- package/dist/components/appointment-card/index.js +1 -1
- package/dist/components/audio-recorder/index.js +1 -1
- package/dist/components/autocomplete/index.js +1 -1
- package/dist/components/bishop-score/index.js +1 -1
- package/dist/components/bmi-calculator/index.js +1 -1
- package/dist/components/booking/index.js +1 -1
- package/dist/components/button/index.js +1 -1
- package/dist/components/calendar/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/carousel/index.js +1 -1
- package/dist/components/chat-input/index.js +1 -1
- package/dist/components/chat-message/index.js +1 -1
- package/dist/components/contact-profile-card/index.js +1 -1
- package/dist/components/cycle-calculator/index.js +1 -1
- package/dist/components/data-table/index.js +1 -1
- package/dist/components/date-picker/index.js +1 -1
- package/dist/components/date-range-picker/index.js +1 -1
- package/dist/components/date-time-picker/index.js +1 -1
- package/dist/components/description-list/index.js +1 -1
- package/dist/components/due-date-calculator/index.js +2 -2
- package/dist/components/editor-overlay/editor-overlay.d.ts +19 -0
- package/dist/components/editor-overlay/index.d.ts +3 -0
- package/dist/components/editor-overlay/index.js +5 -0
- package/dist/components/fetal-weight/index.js +1 -1
- package/dist/components/fiscal-code-input/index.js +1 -1
- package/dist/components/freemium-paywall/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/index.js +1 -1
- package/dist/components/header-settings/index.js +1 -1
- package/dist/components/icon-button/index.js +1 -1
- package/dist/components/index.d.ts +2 -0
- package/dist/components/key-value-pair/index.js +1 -1
- package/dist/components/locale-picker/index.js +1 -1
- package/dist/components/message-card/index.js +1 -1
- package/dist/components/message-tray/index.js +1 -1
- package/dist/components/multi-select/index.js +1 -1
- package/dist/components/notification-card/index.js +1 -1
- package/dist/components/notification-tray/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/payment-card/index.js +1 -1
- package/dist/components/payment-form/index.js +1 -1
- package/dist/components/pdf-viewer/index.js +1 -1
- package/dist/components/periodontal-chart-card/index.js +1 -1
- package/dist/components/phone-input/index.js +1 -1
- package/dist/components/phone-input/phone-input.d.ts +9 -0
- package/dist/components/popover/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/privacy-lock/index.js +1 -1
- package/dist/components/product-hub-tray/index.js +1 -1
- package/dist/components/public-header/index.js +1 -1
- package/dist/components/reviews-panel/index.js +1 -1
- package/dist/components/rich-text-editor/editor-toolbar.d.ts +26 -0
- package/dist/components/rich-text-editor/help-me-write-overlay.d.ts +25 -0
- package/dist/components/rich-text-editor/index.js +1 -1
- package/dist/components/rich-text-editor/rich-text-editor.d.ts +43 -0
- package/dist/components/search-bar/index.js +1 -1
- package/dist/components/search-input/index.js +1 -1
- package/dist/components/sheet/index.js +1 -1
- package/dist/components/sidebar/index.js +1 -1
- package/dist/components/sign-document/index.js +1 -1
- package/dist/components/sign-in-with-alfadocs-button/index.js +1 -1
- package/dist/components/signature-field/index.js +1 -1
- package/dist/components/slot-grid/index.js +1 -1
- package/dist/components/smart-date/index.d.ts +3 -0
- package/dist/components/smart-date/index.js +5 -0
- package/dist/components/smart-date/smart-date.d.ts +32 -0
- package/dist/components/social-sign-in-button/index.js +1 -1
- package/dist/components/spinner/index.js +1 -1
- package/dist/components/streaming-text/index.js +1 -1
- package/dist/components/task-tray/index.js +1 -1
- package/dist/components/theme-toggle/index.js +1 -1
- package/dist/components/toast/index.js +1 -1
- package/dist/components/tooth-scheme/index.js +1 -1
- package/dist/components/transcript-panel/index.js +1 -1
- package/dist/components/unit-converter/index.js +1 -1
- package/dist/components/wallet-pay-button/index.js +1 -1
- package/dist/components/workflow/index.js +1 -1
- package/dist/i18n/locales/ar.d.ts +60 -0
- package/dist/i18n/locales/ar.js +61 -1
- package/dist/i18n/locales/de.d.ts +60 -0
- package/dist/i18n/locales/de.js +61 -1
- package/dist/i18n/locales/el.d.ts +60 -0
- package/dist/i18n/locales/el.js +61 -1
- package/dist/i18n/locales/en.d.ts +60 -0
- package/dist/i18n/locales/en.js +65 -1
- package/dist/i18n/locales/es.d.ts +60 -0
- package/dist/i18n/locales/es.js +61 -1
- package/dist/i18n/locales/fr.d.ts +60 -0
- package/dist/i18n/locales/fr.js +61 -1
- package/dist/i18n/locales/hi.d.ts +60 -0
- package/dist/i18n/locales/hi.js +61 -1
- package/dist/i18n/locales/it.d.ts +60 -0
- package/dist/i18n/locales/it.js +61 -1
- package/dist/i18n/locales/ja.d.ts +60 -0
- package/dist/i18n/locales/ja.js +61 -1
- package/dist/i18n/locales/nl.d.ts +60 -0
- package/dist/i18n/locales/nl.js +61 -1
- package/dist/i18n/locales/pl.d.ts +60 -0
- package/dist/i18n/locales/pl.js +61 -1
- package/dist/i18n/locales/pt.d.ts +60 -0
- package/dist/i18n/locales/pt.js +61 -1
- package/dist/i18n/locales/ro.d.ts +60 -0
- package/dist/i18n/locales/ro.js +61 -1
- package/dist/i18n/locales/ru.d.ts +60 -0
- package/dist/i18n/locales/ru.js +61 -1
- package/dist/i18n/locales/sq.d.ts +60 -0
- package/dist/i18n/locales/sq.js +61 -1
- package/dist/i18n/locales/sv.d.ts +60 -0
- package/dist/i18n/locales/sv.js +61 -1
- package/dist/i18n/locales/tr.d.ts +60 -0
- package/dist/i18n/locales/tr.js +61 -1
- package/dist/i18n/locales/zh.d.ts +60 -0
- package/dist/i18n/locales/zh.js +61 -1
- package/dist/index.js +494 -490
- package/dist/locales/ar.json +61 -1
- package/dist/locales/de.json +61 -1
- package/dist/locales/el.json +61 -1
- package/dist/locales/en.json +61 -1
- package/dist/locales/es.json +61 -1
- package/dist/locales/fr.json +61 -1
- package/dist/locales/hi.json +61 -1
- package/dist/locales/it.json +61 -1
- package/dist/locales/ja.json +61 -1
- package/dist/locales/nl.json +61 -1
- package/dist/locales/pl.json +61 -1
- package/dist/locales/pt.json +61 -1
- package/dist/locales/ro.json +61 -1
- package/dist/locales/ru.json +61 -1
- package/dist/locales/sq.json +61 -1
- package/dist/locales/sv.json +61 -1
- package/dist/locales/tr.json +61 -1
- package/dist/locales/zh.json +61 -1
- package/dist/patterns/alia-assistant/index.js +1 -1
- package/dist/patterns/marketplace-app-shell/index.js +1 -1
- package/dist/patterns/patient-shell/index.js +1 -1
- package/dist/tokens.css +36 -22
- package/package.json +10 -1
- package/dist/_chunks/icon-button-CKEOrN37.js +0 -70
- package/dist/_chunks/phone-input-DfZbPPvh.js +0 -525
- package/dist/_chunks/rich-text-editor-B03qM22-.js +0 -334
- package/dist/_chunks/subDays-Bs00akhK.js +0 -8
|
@@ -1,32 +1,22 @@
|
|
|
1
1
|
import { jsxs as P, jsx as g } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as ht, useRef as
|
|
3
|
-
import { useTranslation as
|
|
4
|
-
import { c as
|
|
5
|
-
import { B as
|
|
6
|
-
import { L as
|
|
7
|
-
import {
|
|
2
|
+
import { forwardRef as ht, useRef as St } from "react";
|
|
3
|
+
import { useTranslation as Dt } from "react-i18next";
|
|
4
|
+
import { c as Nt } from "./index-D2ZczOXr.js";
|
|
5
|
+
import { B as Gt } from "./button-DD_0Xdmr.js";
|
|
6
|
+
import { L as Ht } from "./layers-pzGcbLPj.js";
|
|
7
|
+
import { I as Rt } from "./image-C6RM5hfF.js";
|
|
8
|
+
import { c as Pt } from "./createLucideIcon-CrFbzy84.js";
|
|
8
9
|
/**
|
|
9
10
|
* @license lucide-react v1.8.0 - ISC
|
|
10
11
|
*
|
|
11
12
|
* This source code is licensed under the ISC license.
|
|
12
13
|
* See the LICENSE file in the root directory of this source tree.
|
|
13
14
|
*/
|
|
14
|
-
const
|
|
15
|
-
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", ry: "2", key: "1m3agn" }],
|
|
16
|
-
["circle", { cx: "9", cy: "9", r: "2", key: "af1f0g" }],
|
|
17
|
-
["path", { d: "m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21", key: "1xmnt7" }]
|
|
18
|
-
], Ft = pt("image", Pt);
|
|
19
|
-
/**
|
|
20
|
-
* @license lucide-react v1.8.0 - ISC
|
|
21
|
-
*
|
|
22
|
-
* This source code is licensed under the ISC license.
|
|
23
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
24
|
-
*/
|
|
25
|
-
const Ot = [
|
|
15
|
+
const Ft = [
|
|
26
16
|
["path", { d: "M12 4v16", key: "1654pz" }],
|
|
27
17
|
["path", { d: "M4 7V5a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v2", key: "e0r10z" }],
|
|
28
18
|
["path", { d: "M9 20h6", key: "s66wpe" }]
|
|
29
|
-
],
|
|
19
|
+
], Ot = Pt("type", Ft), Ut = 15, at = 40, zt = [18.5, 25, 30];
|
|
30
20
|
function Mn() {
|
|
31
21
|
return {
|
|
32
22
|
bands: [
|
|
@@ -35,19 +25,19 @@ function Mn() {
|
|
|
35
25
|
{ upTo: 30, colorToken: "--warning-readable" },
|
|
36
26
|
{ upTo: at, colorToken: "--destructive" }
|
|
37
27
|
],
|
|
38
|
-
min:
|
|
28
|
+
min: Ut,
|
|
39
29
|
max: at,
|
|
40
|
-
ticks: [...
|
|
30
|
+
ticks: [...zt]
|
|
41
31
|
};
|
|
42
32
|
}
|
|
43
|
-
const V = 14, j = 12,
|
|
33
|
+
const V = 14, j = 12, Wt = j / 2, ot = 18, Xt = 12, Vt = 16;
|
|
44
34
|
function N(t, n, i, a, o) {
|
|
45
35
|
if (i <= n) return a;
|
|
46
36
|
const r = (t - n) / (i - n);
|
|
47
37
|
return a + r * (o - a);
|
|
48
38
|
}
|
|
49
|
-
function
|
|
50
|
-
const a = V, o = n - V, r = ot +
|
|
39
|
+
function pt(t, { width: n, height: i }) {
|
|
40
|
+
const a = V, o = n - V, r = ot + Xt, e = ot, c = r + j + Vt;
|
|
51
41
|
let u = t.min;
|
|
52
42
|
const d = t.bands.map((l) => {
|
|
53
43
|
const T = Math.max(t.min, Math.min(u, t.max)), y = Math.max(t.min, Math.min(l.upTo, t.max));
|
|
@@ -65,7 +55,7 @@ function bt(t, { width: n, height: i }) {
|
|
|
65
55
|
barEnd: o,
|
|
66
56
|
barY: r,
|
|
67
57
|
barH: j,
|
|
68
|
-
barRadius:
|
|
58
|
+
barRadius: Wt,
|
|
69
59
|
bands: d,
|
|
70
60
|
marker: {
|
|
71
61
|
x: k,
|
|
@@ -82,23 +72,23 @@ function bt(t, { width: n, height: i }) {
|
|
|
82
72
|
};
|
|
83
73
|
}
|
|
84
74
|
const s = (t) => Math.round(t * 100) / 100, M = (t) => t.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """);
|
|
85
|
-
function
|
|
75
|
+
function bt(t, n, i, a, o, r) {
|
|
86
76
|
const e = t + i, c = n + a, u = r > 0 ? `A${r} ${r} 0 0 1 ${s(e)} ${s(n + r)}` : "", d = r > 0 ? `A${r} ${r} 0 0 1 ${s(e - r)} ${s(c)}` : "", f = o > 0 ? `A${o} ${o} 0 0 1 ${s(t)} ${s(c - o)}` : "", b = o > 0 ? `A${o} ${o} 0 0 1 ${s(t + o)} ${s(n)}` : "";
|
|
87
77
|
return `M${s(t + o)} ${s(n)} H${s(e - r)} ${u} V${s(
|
|
88
78
|
c - r
|
|
89
79
|
)} ${d} H${s(t + o)} ${f} V${s(n + o)} ${b} Z`;
|
|
90
80
|
}
|
|
91
|
-
function
|
|
81
|
+
function jt(t, n) {
|
|
92
82
|
const { resolve: i, font: a, fg: o, muted: r, track: e } = n, c = M(a), u = `<rect x="${s(t.barStart)}" y="${s(
|
|
93
83
|
t.barY
|
|
94
84
|
)}" width="${s(t.barEnd - t.barStart)}" height="${t.barH}" rx="${t.barRadius}" fill="${e}"/>`, d = t.bands.length, f = t.bands.map((m, x) => {
|
|
95
|
-
const C = i(m.colorToken),
|
|
96
|
-
return `<path d="${
|
|
85
|
+
const C = i(m.colorToken), I = x === 0 ? t.barRadius : 0, U = x === d - 1 ? t.barRadius : 0;
|
|
86
|
+
return `<path d="${bt(
|
|
97
87
|
m.x,
|
|
98
88
|
t.barY,
|
|
99
89
|
m.w,
|
|
100
90
|
t.barH,
|
|
101
|
-
|
|
91
|
+
I,
|
|
102
92
|
U
|
|
103
93
|
)}" fill="${C}"/>`;
|
|
104
94
|
}).join(""), b = t.barY + t.barH, k = b + 4, h = t.ticks.map((m) => {
|
|
@@ -147,13 +137,13 @@ function Kt(t, n) {
|
|
|
147
137
|
t.ariaLabel
|
|
148
138
|
)}">${D}${u}${f}${h}${y}${E}${w}${B}${S}</g>`;
|
|
149
139
|
}
|
|
150
|
-
const
|
|
151
|
-
function
|
|
140
|
+
const Kt = 260, Q = 64;
|
|
141
|
+
function Zt(t) {
|
|
152
142
|
return `var(${t})`;
|
|
153
143
|
}
|
|
154
|
-
const
|
|
155
|
-
function({ model: n, width: i =
|
|
156
|
-
const e =
|
|
144
|
+
const qt = ht(
|
|
145
|
+
function({ model: n, width: i = Kt, height: a = Q, className: o }, r) {
|
|
146
|
+
const e = pt(n, { width: i, height: a }), c = e.barY + e.barH, u = c + 4, d = e.barY - 3, f = e.barY + e.barH + 3, b = e.barY - 4, k = e.bands.length, h = e.barY + e.barH / 2;
|
|
157
147
|
return /* @__PURE__ */ P(
|
|
158
148
|
"svg",
|
|
159
149
|
{
|
|
@@ -182,7 +172,7 @@ const Jt = ht(
|
|
|
182
172
|
e.bands.map(($, l) => /* @__PURE__ */ g(
|
|
183
173
|
"path",
|
|
184
174
|
{
|
|
185
|
-
d:
|
|
175
|
+
d: bt(
|
|
186
176
|
$.x,
|
|
187
177
|
e.barY,
|
|
188
178
|
$.w,
|
|
@@ -190,7 +180,7 @@ const Jt = ht(
|
|
|
190
180
|
l === 0 ? e.barRadius : 0,
|
|
191
181
|
l === k - 1 ? e.barRadius : 0
|
|
192
182
|
),
|
|
193
|
-
fill:
|
|
183
|
+
fill: Zt($.colorToken)
|
|
194
184
|
},
|
|
195
185
|
`${$.colorToken}-${l}`
|
|
196
186
|
)),
|
|
@@ -292,8 +282,8 @@ const Jt = ht(
|
|
|
292
282
|
);
|
|
293
283
|
}
|
|
294
284
|
);
|
|
295
|
-
|
|
296
|
-
const
|
|
285
|
+
qt.displayName = "BandedGauge";
|
|
286
|
+
const Jt = 24, mt = 18, G = 12, gt = {
|
|
297
287
|
activity: '<path d="M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2"/>',
|
|
298
288
|
scale: '<path d="M12 3v18"/><path d="m19 8 3 8a5 5 0 0 1-6 0zV7"/><path d="M3 7h1a17 17 0 0 0 8-2 17 17 0 0 0 8 2h1"/><path d="m5 8 3 8a5 5 0 0 1-6 0zV7"/><path d="M7 21h10"/>',
|
|
299
289
|
ruler: '<path d="M21.3 15.3a2.4 2.4 0 0 1 0 3.4l-2.6 2.6a2.4 2.4 0 0 1-3.4 0L2.7 8.7a2.41 2.41 0 0 1 0-3.4l2.6-2.6a2.41 2.41 0 0 1 3.4 0Z"/><path d="m14.5 12.5 2-2"/><path d="m11.5 9.5 2-2"/><path d="m8.5 6.5 2-2"/><path d="m17.5 15.5 2-2"/>',
|
|
@@ -307,22 +297,22 @@ const Qt = 24, gt = 18, G = 12, xt = {
|
|
|
307
297
|
"trending-up": '<path d="M16 7h6v6"/><path d="m22 7-8.5 8.5-5-5L2 17"/>',
|
|
308
298
|
percent: '<line x1="19" x2="5" y1="5" y2="19"/><circle cx="6.5" cy="6.5" r="2.5"/><circle cx="17.5" cy="17.5" r="2.5"/>'
|
|
309
299
|
};
|
|
310
|
-
function
|
|
311
|
-
return Object.prototype.hasOwnProperty.call(
|
|
300
|
+
function xt(t) {
|
|
301
|
+
return Object.prototype.hasOwnProperty.call(gt, t);
|
|
312
302
|
}
|
|
313
303
|
function rt(t, n, i, a, o) {
|
|
314
|
-
if (!
|
|
315
|
-
const r = o /
|
|
316
|
-
return `<g transform="translate(${i} ${a}) scale(${r})" fill="none" color="${n}" stroke="${n}" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">${
|
|
304
|
+
if (!xt(t)) return "";
|
|
305
|
+
const r = o / Jt;
|
|
306
|
+
return `<g transform="translate(${i} ${a}) scale(${r})" fill="none" color="${n}" stroke="${n}" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">${gt[t]}</g>`;
|
|
317
307
|
}
|
|
318
308
|
function Y(t) {
|
|
319
309
|
return t.variant === "banded";
|
|
320
310
|
}
|
|
321
|
-
const
|
|
322
|
-
function
|
|
311
|
+
const Qt = ["fg", "muted", "accent", "border", "bg"], tt = "--primary", F = 380, vt = (t) => t.trim().replace(/^--/, "");
|
|
312
|
+
function tn(t) {
|
|
323
313
|
return `ds:text-[color:var(${t})]`;
|
|
324
314
|
}
|
|
325
|
-
function
|
|
315
|
+
function kt(t) {
|
|
326
316
|
return t.highlightToken ?? tt;
|
|
327
317
|
}
|
|
328
318
|
function W(t) {
|
|
@@ -331,7 +321,7 @@ function W(t) {
|
|
|
331
321
|
const a = t.highlightToken ?? tt;
|
|
332
322
|
n.add(a), n.add(`${a}-foreground`);
|
|
333
323
|
}
|
|
334
|
-
const i =
|
|
324
|
+
const i = kt(t);
|
|
335
325
|
if (n.add(i), t.gauge)
|
|
336
326
|
if (Y(t.gauge))
|
|
337
327
|
for (const a of t.gauge.bands) n.add(a.colorToken);
|
|
@@ -356,7 +346,7 @@ function K(t, n = []) {
|
|
|
356
346
|
}, o = {};
|
|
357
347
|
for (const r of n) {
|
|
358
348
|
const e = t.querySelector(
|
|
359
|
-
`[data-token="${
|
|
349
|
+
`[data-token="${vt(r)}"]`
|
|
360
350
|
);
|
|
361
351
|
if (e) {
|
|
362
352
|
const c = getComputedStyle(e).color;
|
|
@@ -378,19 +368,19 @@ function O(t, n, i) {
|
|
|
378
368
|
return n ? ((a = t.tokens) == null ? void 0 : a[n]) ?? i : i;
|
|
379
369
|
}
|
|
380
370
|
const v = (t) => t.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """);
|
|
381
|
-
function
|
|
371
|
+
function yt(t) {
|
|
382
372
|
const n = [t.title];
|
|
383
373
|
t.highlight && n.push(t.highlight);
|
|
384
374
|
for (const i of t.fields) n.push(`• ${i.label}: ${i.value}`);
|
|
385
375
|
return n.join(`
|
|
386
376
|
`);
|
|
387
377
|
}
|
|
388
|
-
function
|
|
378
|
+
function Lt(t) {
|
|
389
379
|
const n = t.fields.map((a) => `<li>${v(a.label)}: ${v(a.value)}</li>`).join(""), i = t.highlight ? `<p><strong>${v(t.highlight)}</strong></p>` : "";
|
|
390
380
|
return `<p><strong>${v(t.title)}</strong></p>${i}<ul>${n}</ul>`;
|
|
391
381
|
}
|
|
392
|
-
const L = 20,
|
|
393
|
-
function
|
|
382
|
+
const L = 20, _ = L + 18, H = 22, nn = 10, wt = 22, st = 16, it = 12, en = 12, Tt = 34, Z = 9, q = (Tt + Z) * 2, an = 16, lt = mt, on = 6, R = L + G + on, X = F - L - R, ct = 13, Et = 14, It = 13, J = 16;
|
|
383
|
+
function rn(t) {
|
|
394
384
|
return t >= 4352 && t <= 4447 || // Hangul Jamo
|
|
395
385
|
t >= 11904 && t <= 42191 || // CJK radicals … Yi
|
|
396
386
|
t >= 44032 && t <= 55203 || // Hangul syllables
|
|
@@ -402,10 +392,10 @@ function sn(t) {
|
|
|
402
392
|
function A(t, n) {
|
|
403
393
|
let i = 0;
|
|
404
394
|
for (const a of t)
|
|
405
|
-
i +=
|
|
395
|
+
i += rn(a.codePointAt(0) ?? 0) ? 1 : 0.62;
|
|
406
396
|
return i * n;
|
|
407
397
|
}
|
|
408
|
-
function
|
|
398
|
+
function sn(t, n, i) {
|
|
409
399
|
const a = [];
|
|
410
400
|
let o = "";
|
|
411
401
|
for (const r of t)
|
|
@@ -416,7 +406,7 @@ function ut(t, n, i) {
|
|
|
416
406
|
const a = [];
|
|
417
407
|
let o = "";
|
|
418
408
|
const r = (e) => {
|
|
419
|
-
const c =
|
|
409
|
+
const c = sn(e, n, i);
|
|
420
410
|
for (let u = 0; u < c.length - 1; u += 1) a.push(c[u]);
|
|
421
411
|
o = c[c.length - 1];
|
|
422
412
|
};
|
|
@@ -426,11 +416,11 @@ function ut(t, n, i) {
|
|
|
426
416
|
}
|
|
427
417
|
return o && a.push(o), a.length ? a : [""];
|
|
428
418
|
}
|
|
429
|
-
function
|
|
419
|
+
function Mt(t) {
|
|
430
420
|
const n = [];
|
|
431
421
|
let i = 0;
|
|
432
422
|
t.fields.forEach((r, e) => {
|
|
433
|
-
const c = e === 0 ?
|
|
423
|
+
const c = e === 0 ? Et : It, d = A(`${r.label}: `, ct) + A(r.value, c) <= X ? [{ kind: "inline", text: "" }] : [
|
|
434
424
|
...ut(
|
|
435
425
|
`${r.label}:`,
|
|
436
426
|
ct,
|
|
@@ -440,7 +430,7 @@ function It(t) {
|
|
|
440
430
|
(f) => ({ kind: "value", text: f })
|
|
441
431
|
)
|
|
442
432
|
];
|
|
443
|
-
n.push({ field: r, index: e, firstLineDy: i, lines: d }), i +=
|
|
433
|
+
n.push({ field: r, index: e, firstLineDy: i, lines: d }), i += wt + (d.length - 1) * J;
|
|
444
434
|
});
|
|
445
435
|
const a = n[n.length - 1], o = a ? a.firstLineDy + (a.lines.length - 1) * J : 0;
|
|
446
436
|
return { placements: n, endDy: o };
|
|
@@ -449,14 +439,14 @@ function nt(t, n) {
|
|
|
449
439
|
const i = n !== void 0 ? n : t.brand;
|
|
450
440
|
return typeof i == "string" ? i : !1;
|
|
451
441
|
}
|
|
452
|
-
function
|
|
442
|
+
function ln(t) {
|
|
453
443
|
if (typeof t.fraction == "number")
|
|
454
444
|
return Math.min(1, Math.max(0, t.fraction));
|
|
455
445
|
const n = parseFloat(t.value);
|
|
456
446
|
return Number.isFinite(n) && typeof t.max == "number" && t.max > 0 ? Math.min(1, Math.max(0, n / t.max)) : 1;
|
|
457
447
|
}
|
|
458
|
-
function
|
|
459
|
-
const i = !!t.highlight, a =
|
|
448
|
+
function _t(t, n) {
|
|
449
|
+
const i = !!t.highlight, a = _ + nn, o = (i ? a + H + st : _ + st) + wt - 6, r = o + Mt(t).endDy, e = t.gauge && Y(t.gauge), d = t.gauge && !Y(t.gauge) ? (i ? a : _) + q : 0, f = e ? r + an : null, b = f !== null ? f + Q : 0, k = Math.max(r, d, b), h = n ? k + it + en - 4 : k, $ = Math.round(h + (n ? it : L));
|
|
460
450
|
return {
|
|
461
451
|
hasChip: i,
|
|
462
452
|
chipY: a,
|
|
@@ -467,11 +457,11 @@ function At(t, n) {
|
|
|
467
457
|
height: $
|
|
468
458
|
};
|
|
469
459
|
}
|
|
470
|
-
function
|
|
471
|
-
return
|
|
460
|
+
function At(t, n) {
|
|
461
|
+
return _t(t, n !== !1).height;
|
|
472
462
|
}
|
|
473
|
-
function
|
|
474
|
-
const r =
|
|
463
|
+
function cn(t, n, i, a, o) {
|
|
464
|
+
const r = Tt, e = 2 * Math.PI * r, c = ln(t), u = O(n, t.colorToken, n.accent), d = typeof t.segments == "number" && t.segments > 1 ? t.segments : 0, f = d ? 3 : 0, b = d ? e / d - f : e, k = d ? `${b} ${f}` : "", h = `${e * c} ${e}`, $ = `transform="rotate(-90 ${a} ${o})"`, l = v(
|
|
475
465
|
t.label ? `${t.value} — ${t.label}` : t.value
|
|
476
466
|
), T = `<circle cx="${a}" cy="${o}" r="${r}" fill="none" stroke="${n.border}" stroke-width="${Z}"${k ? ` stroke-dasharray="${k}"` : ""} ${$}/>`, y = `<circle cx="${a}" cy="${o}" r="${r}" fill="none" stroke="${u}" stroke-width="${Z}" stroke-linecap="round" stroke-dasharray="${h}" ${$}/>`, p = `<text x="${a}" y="${o + 1}" text-anchor="middle" dominant-baseline="middle" font-family="${i}" font-size="16" font-weight="700" fill="${n.fg}">${v(
|
|
477
467
|
t.value
|
|
@@ -480,8 +470,8 @@ function un(t, n, i, a, o) {
|
|
|
480
470
|
)}</text>` : "";
|
|
481
471
|
return `<g role="img" aria-label="${l}"><title>${l}</title>${T}${y}${p}${E}</g>`;
|
|
482
472
|
}
|
|
483
|
-
function
|
|
484
|
-
const o = L - V, r = i - 2 * o, e =
|
|
473
|
+
function un(t, n, i, a) {
|
|
474
|
+
const o = L - V, r = i - 2 * o, e = pt(
|
|
485
475
|
{
|
|
486
476
|
value: t.value,
|
|
487
477
|
bands: t.bands,
|
|
@@ -494,7 +484,7 @@ function dn(t, n, i, a) {
|
|
|
494
484
|
ticks: t.ticks
|
|
495
485
|
},
|
|
496
486
|
{ width: r, height: Q }
|
|
497
|
-
), c =
|
|
487
|
+
), c = jt(e, {
|
|
498
488
|
resolve: (u) => O(n, u, n.accent),
|
|
499
489
|
// Raw theme font — buildBandedGaugeSvgString escapes it once. Passing the
|
|
500
490
|
// card's already-escaped `font` here would double-escape and break it.
|
|
@@ -516,71 +506,71 @@ function ft([t, n, i]) {
|
|
|
516
506
|
};
|
|
517
507
|
return 0.2126 * a(t) + 0.7152 * a(n) + 0.0722 * a(i);
|
|
518
508
|
}
|
|
519
|
-
function
|
|
509
|
+
function dn(t, n) {
|
|
520
510
|
const i = dt(t), a = dt(n);
|
|
521
511
|
if (!i || !a) return 0;
|
|
522
512
|
const o = ft(i), r = ft(a);
|
|
523
513
|
return (Math.max(o, r) + 0.05) / (Math.min(o, r) + 0.05);
|
|
524
514
|
}
|
|
525
|
-
function
|
|
526
|
-
const o = t.highlight, r = t.highlightToken ?? tt, e = O(n, r, n.accent), c =
|
|
515
|
+
function fn(t, n, i, a) {
|
|
516
|
+
const o = t.highlight, r = t.highlightToken ?? tt, e = O(n, r, n.accent), c = dn(n.bg, e) >= 3 ? n.bg : n.fg, u = Math.round(o.length * 7.2 + 28), d = L + u / 2, f = a + H / 2 + 1;
|
|
527
517
|
return `<rect x="${L}" y="${a}" width="${u}" height="${H}" rx="${H / 2}" fill="${e}"/><text x="${d}" y="${f}" text-anchor="middle" dominant-baseline="middle" font-family="${i}" font-size="12" font-weight="600" fill="${c}">${v(
|
|
528
518
|
o
|
|
529
519
|
)}</text>`;
|
|
530
520
|
}
|
|
531
521
|
function et(t, n, i = !1) {
|
|
532
|
-
const a = F, o =
|
|
522
|
+
const a = F, o = _t(t, i !== !1), r = o.height, e = v(n.font), c = kt(t), u = O(n, c, n.accent), d = t.icon ? rt(
|
|
533
523
|
t.icon,
|
|
534
524
|
u,
|
|
535
525
|
a - L - lt,
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
) : "", { placements: f } =
|
|
539
|
-
const E = o.firstFieldY + p.firstLineDy, w = p.index === 0, B = w ?
|
|
526
|
+
_ - lt + 2,
|
|
527
|
+
mt
|
|
528
|
+
) : "", { placements: f } = Mt(t), b = f.map((p) => {
|
|
529
|
+
const E = o.firstFieldY + p.firstLineDy, w = p.index === 0, B = w ? Et : It, S = w ? 700 : 500, D = w ? u : n.fg, m = E - 4;
|
|
540
530
|
let x;
|
|
541
|
-
p.field.icon &&
|
|
531
|
+
p.field.icon && xt(p.field.icon) ? x = rt(
|
|
542
532
|
p.field.icon,
|
|
543
533
|
u,
|
|
544
534
|
L,
|
|
545
535
|
m - G / 2,
|
|
546
536
|
G
|
|
547
537
|
) : x = `<circle cx="${L + G / 2}" cy="${m}" r="2" fill="${n.muted}"/>`;
|
|
548
|
-
const C = p.lines.map((
|
|
538
|
+
const C = p.lines.map((I, U) => {
|
|
549
539
|
const z = E + U * J;
|
|
550
|
-
return
|
|
540
|
+
return I.kind === "inline" ? `<text x="${R}" y="${z}" font-family="${e}" font-size="13"><tspan fill="${n.muted}">${v(
|
|
551
541
|
p.field.label
|
|
552
542
|
)}: </tspan><tspan font-size="${B}" font-weight="${S}" fill="${D}">${v(
|
|
553
543
|
p.field.value
|
|
554
|
-
)}</tspan></text>` :
|
|
555
|
-
|
|
544
|
+
)}</tspan></text>` : I.kind === "label" ? `<text x="${R}" y="${z}" font-family="${e}" font-size="13" fill="${n.muted}">${v(
|
|
545
|
+
I.text
|
|
556
546
|
)}</text>` : `<text x="${R}" y="${z}" font-family="${e}" font-size="${B}" font-weight="${S}" fill="${D}">${v(
|
|
557
|
-
|
|
547
|
+
I.text
|
|
558
548
|
)}</text>`;
|
|
559
549
|
}).join("");
|
|
560
550
|
return `${x}${C}`;
|
|
561
|
-
}).join(""), k = o.hasChip ?
|
|
551
|
+
}).join(""), k = o.hasChip ? fn(t, n, e, o.chipY) : "";
|
|
562
552
|
let h = "";
|
|
563
|
-
t.gauge && (Y(t.gauge) && o.bandedGaugeY !== null ? h =
|
|
553
|
+
t.gauge && (Y(t.gauge) && o.bandedGaugeY !== null ? h = un(t.gauge, n, a, o.bandedGaugeY) : Y(t.gauge) || (h = cn(
|
|
564
554
|
t.gauge,
|
|
565
555
|
n,
|
|
566
556
|
e,
|
|
567
557
|
a - L - q / 2,
|
|
568
|
-
(o.hasChip ? o.chipY :
|
|
558
|
+
(o.hasChip ? o.chipY : _) + q / 2
|
|
569
559
|
)));
|
|
570
560
|
const $ = i !== !1 ? `<text x="${L}" y="${o.footerY}" font-family="${e}" font-size="10" font-weight="500" fill="${n.muted}">${v(
|
|
571
561
|
i
|
|
572
|
-
)}</text>` : "", l = `<text x="${L}" y="${
|
|
562
|
+
)}</text>` : "", l = `<text x="${L}" y="${_}" font-family="${e}" font-size="16" font-weight="700" fill="${n.fg}">${v(
|
|
573
563
|
t.title
|
|
574
564
|
)}</text>`, T = `<rect x="0.5" y="0.5" width="${a - 1}" height="${r - 1}" rx="12" fill="${n.bg}"/>`, y = `<rect x="0.5" y="0.5" width="${a - 1}" height="${r - 1}" rx="12" fill="none" stroke="${n.border}"/>`;
|
|
575
565
|
return `<svg xmlns="http://www.w3.org/2000/svg" width="${a}" height="${r}" viewBox="0 0 ${a} ${r}" role="img" aria-label="${v(
|
|
576
566
|
t.title
|
|
577
567
|
)}">${T}${l}${d}${k}${h}${b}${$}${y}</svg>`;
|
|
578
568
|
}
|
|
579
|
-
function
|
|
569
|
+
function $n() {
|
|
580
570
|
var t;
|
|
581
571
|
return typeof navigator < "u" && typeof ((t = navigator.clipboard) == null ? void 0 : t.write) == "function" && typeof ClipboardItem < "u";
|
|
582
572
|
}
|
|
583
|
-
function
|
|
573
|
+
function Bt(t, n, i) {
|
|
584
574
|
return new Promise((a, o) => {
|
|
585
575
|
const r = new Image();
|
|
586
576
|
r.decoding = "async", r.onload = () => {
|
|
@@ -597,46 +587,46 @@ function Ct(t, n, i) {
|
|
|
597
587
|
}, r.onerror = () => o(new Error("SVG failed to decode as an image")), r.src = t;
|
|
598
588
|
});
|
|
599
589
|
}
|
|
600
|
-
function
|
|
590
|
+
function Ct() {
|
|
601
591
|
const t = typeof window < "u" && typeof window.devicePixelRatio == "number" ? window.devicePixelRatio : 1;
|
|
602
592
|
return Math.max(2, t);
|
|
603
593
|
}
|
|
604
|
-
async function
|
|
605
|
-
return (await
|
|
594
|
+
async function _n(t, n = {}) {
|
|
595
|
+
return (await Yt(t, n)).dataUri;
|
|
606
596
|
}
|
|
607
|
-
async function
|
|
608
|
-
const { colours: i, scale: a =
|
|
597
|
+
async function Yt(t, n = {}) {
|
|
598
|
+
const { colours: i, scale: a = Ct() } = n, o = i ?? K(null), r = nt(t, n.brand), e = et(t, o, r), c = `data:image/svg+xml,${encodeURIComponent(e)}`, u = F, d = At(t, r), f = await Bt(
|
|
609
599
|
c,
|
|
610
600
|
Math.round(u * a),
|
|
611
601
|
Math.round(d * a)
|
|
612
602
|
);
|
|
613
|
-
return { dataUri: await
|
|
603
|
+
return { dataUri: await hn(f), width: u, height: d };
|
|
614
604
|
}
|
|
615
|
-
function
|
|
605
|
+
function hn(t) {
|
|
616
606
|
return new Promise((n, i) => {
|
|
617
607
|
const a = new FileReader();
|
|
618
608
|
a.onload = () => n(String(a.result)), a.onerror = () => i(a.error ?? new Error("FileReader error")), a.readAsDataURL(t);
|
|
619
609
|
});
|
|
620
610
|
}
|
|
621
|
-
async function
|
|
622
|
-
const a =
|
|
611
|
+
async function pn(t, n, i) {
|
|
612
|
+
const a = yt(n), o = new Blob([a], { type: "text/plain" });
|
|
623
613
|
if (t === "text")
|
|
624
614
|
return new ClipboardItem({ "text/plain": o });
|
|
625
|
-
const r = nt(n, void 0), e = et(n, i, r), c = `data:image/svg+xml,${encodeURIComponent(e)}`, u =
|
|
615
|
+
const r = nt(n, void 0), e = et(n, i, r), c = `data:image/svg+xml,${encodeURIComponent(e)}`, u = Ct(), d = await Bt(
|
|
626
616
|
c,
|
|
627
617
|
Math.round(F * u),
|
|
628
|
-
Math.round(
|
|
618
|
+
Math.round(At(n, r) * u)
|
|
629
619
|
);
|
|
630
620
|
if (t === "image")
|
|
631
621
|
return new ClipboardItem({ "image/png": d, "text/plain": o });
|
|
632
|
-
const f = new Blob([
|
|
622
|
+
const f = new Blob([Lt(n)], { type: "text/html" });
|
|
633
623
|
return new ClipboardItem({
|
|
634
624
|
"text/html": f,
|
|
635
625
|
"image/png": d,
|
|
636
626
|
"text/plain": o
|
|
637
627
|
});
|
|
638
628
|
}
|
|
639
|
-
const
|
|
629
|
+
const bn = Nt(
|
|
640
630
|
"ds:inline-flex ds:items-center ds:gap-[var(--spacing-xs)]",
|
|
641
631
|
{
|
|
642
632
|
variants: {
|
|
@@ -647,10 +637,10 @@ const mn = Gt(
|
|
|
647
637
|
},
|
|
648
638
|
defaultVariants: { variant: "insert" }
|
|
649
639
|
}
|
|
650
|
-
),
|
|
651
|
-
text: /* @__PURE__ */ g(
|
|
652
|
-
image: /* @__PURE__ */ g(
|
|
653
|
-
"text-image": /* @__PURE__ */ g(
|
|
640
|
+
), mn = ["text", "image", "text-image"], gn = {
|
|
641
|
+
text: /* @__PURE__ */ g(Ot, { "aria-hidden": !0 }),
|
|
642
|
+
image: /* @__PURE__ */ g(Rt, { "aria-hidden": !0 }),
|
|
643
|
+
"text-image": /* @__PURE__ */ g(Ht, { "aria-hidden": !0 })
|
|
654
644
|
}, $t = {
|
|
655
645
|
insert: {
|
|
656
646
|
text: "insert.text",
|
|
@@ -662,7 +652,7 @@ const mn = Gt(
|
|
|
662
652
|
image: "insert.copyImage",
|
|
663
653
|
"text-image": "insert.copyTextImage"
|
|
664
654
|
}
|
|
665
|
-
},
|
|
655
|
+
}, xn = ht(
|
|
666
656
|
function({
|
|
667
657
|
card: n,
|
|
668
658
|
variant: i = "insert",
|
|
@@ -672,13 +662,13 @@ const mn = Gt(
|
|
|
672
662
|
size: e = "sm",
|
|
673
663
|
intent: c = "primary"
|
|
674
664
|
}, u) {
|
|
675
|
-
const { t: d } =
|
|
676
|
-
const T =
|
|
665
|
+
const { t: d } = Dt(), f = St(null), b = (l) => {
|
|
666
|
+
const T = yt(n), y = Lt(n);
|
|
677
667
|
let p = "", E = "";
|
|
678
668
|
const w = l === "text" ? null : K(f.current, W(n));
|
|
679
|
-
return w && (p = et(n, w, nt(n, void 0)), E = `data:image/svg+xml,${encodeURIComponent(p)}`), { mode: l, text: T, html: y, svg: p, imageDataUri: E, pngDataUri: () => w ?
|
|
669
|
+
return w && (p = et(n, w, nt(n, void 0)), E = `data:image/svg+xml,${encodeURIComponent(p)}`), { mode: l, text: T, html: y, svg: p, imageDataUri: E, pngDataUri: () => w ? Yt(n, { colours: w }) : Promise.resolve({ dataUri: "", width: 0, height: 0 }) };
|
|
680
670
|
}, $ = i === "copy" ? (l) => {
|
|
681
|
-
if (
|
|
671
|
+
if (!$n()) {
|
|
682
672
|
r == null || r(new Error("Clipboard write unavailable in this context"));
|
|
683
673
|
return;
|
|
684
674
|
}
|
|
@@ -688,7 +678,7 @@ const mn = Gt(
|
|
|
688
678
|
);
|
|
689
679
|
(async () => {
|
|
690
680
|
try {
|
|
691
|
-
const y = await
|
|
681
|
+
const y = await pn(l, n, T);
|
|
692
682
|
await navigator.clipboard.write([y]), o == null || o(l);
|
|
693
683
|
} catch (y) {
|
|
694
684
|
r == null || r(y);
|
|
@@ -703,10 +693,10 @@ const mn = Gt(
|
|
|
703
693
|
ref: u,
|
|
704
694
|
"data-component": "insert-result",
|
|
705
695
|
"data-variant": i,
|
|
706
|
-
className:
|
|
696
|
+
className: bn({ variant: i }),
|
|
707
697
|
children: [
|
|
708
698
|
/* @__PURE__ */ P("span", { ref: f, "aria-hidden": !0, className: "ds:sr-only", children: [
|
|
709
|
-
|
|
699
|
+
Qt.map((l) => /* @__PURE__ */ g(
|
|
710
700
|
"span",
|
|
711
701
|
{
|
|
712
702
|
"data-k": l,
|
|
@@ -717,19 +707,19 @@ const mn = Gt(
|
|
|
717
707
|
W(n).map((l) => /* @__PURE__ */ g(
|
|
718
708
|
"span",
|
|
719
709
|
{
|
|
720
|
-
"data-token":
|
|
721
|
-
className:
|
|
710
|
+
"data-token": vt(l),
|
|
711
|
+
className: tn(l)
|
|
722
712
|
},
|
|
723
713
|
l
|
|
724
714
|
))
|
|
725
715
|
] }),
|
|
726
|
-
|
|
727
|
-
|
|
716
|
+
mn.map((l) => /* @__PURE__ */ g(
|
|
717
|
+
Gt,
|
|
728
718
|
{
|
|
729
719
|
type: "button",
|
|
730
720
|
intent: c,
|
|
731
721
|
size: e,
|
|
732
|
-
startIcon:
|
|
722
|
+
startIcon: gn[l],
|
|
733
723
|
"aria-label": d($t[i][l]),
|
|
734
724
|
onClick: () => $(l),
|
|
735
725
|
children: d($t[i][l])
|
|
@@ -741,12 +731,12 @@ const mn = Gt(
|
|
|
741
731
|
);
|
|
742
732
|
}
|
|
743
733
|
);
|
|
744
|
-
|
|
734
|
+
xn.displayName = "InsertButton";
|
|
745
735
|
export {
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
736
|
+
qt as B,
|
|
737
|
+
xn as I,
|
|
738
|
+
_n as a,
|
|
749
739
|
Mn as b,
|
|
750
|
-
|
|
740
|
+
Yt as s
|
|
751
741
|
};
|
|
752
|
-
//# sourceMappingURL=insert-result-
|
|
742
|
+
//# sourceMappingURL=insert-result-njqBthzT.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as l } from "./isSameDay-DUEiAT0G.js";
|
|
2
|
-
import { s as r } from "./date-picker-variants-
|
|
2
|
+
import { s as r } from "./date-picker-variants-DAcSLTua.js";
|
|
3
3
|
function i(a, m, e) {
|
|
4
4
|
const [t, f] = l(
|
|
5
5
|
e == null ? void 0 : e.in,
|
|
@@ -11,4 +11,4 @@ function i(a, m, e) {
|
|
|
11
11
|
export {
|
|
12
12
|
i
|
|
13
13
|
};
|
|
14
|
-
//# sourceMappingURL=isSameWeek-
|
|
14
|
+
//# sourceMappingURL=isSameWeek-I3DfXUp1.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { i as d } from "./isSameWeek-
|
|
1
|
+
import { o as s, q as i, r, v as l } from "./date-picker-variants-DAcSLTua.js";
|
|
2
|
+
import { i as d } from "./isSameWeek-I3DfXUp1.js";
|
|
3
3
|
const c = {
|
|
4
4
|
lessThanXSeconds: {
|
|
5
5
|
one: "meno di un secondo",
|
|
@@ -135,10 +135,10 @@ const P = {
|
|
|
135
135
|
return d(e, n, a) ? u(t) : z(t);
|
|
136
136
|
},
|
|
137
137
|
other: "P"
|
|
138
|
-
},
|
|
138
|
+
}, M = (e, n, a, t) => {
|
|
139
139
|
const o = P[e];
|
|
140
140
|
return typeof o == "function" ? o(n, a, t) : o;
|
|
141
|
-
},
|
|
141
|
+
}, w = {
|
|
142
142
|
narrow: ["aC", "dC"],
|
|
143
143
|
abbreviated: ["a.C.", "d.C."],
|
|
144
144
|
wide: ["avanti Cristo", "dopo Cristo"]
|
|
@@ -257,7 +257,7 @@ const P = {
|
|
|
257
257
|
}, V = {
|
|
258
258
|
ordinalNumber: x,
|
|
259
259
|
era: i({
|
|
260
|
-
values:
|
|
260
|
+
values: w,
|
|
261
261
|
defaultWidth: "wide"
|
|
262
262
|
}),
|
|
263
263
|
quarter: i({
|
|
@@ -387,7 +387,7 @@ const P = {
|
|
|
387
387
|
code: "it",
|
|
388
388
|
formatDistance: g,
|
|
389
389
|
formatLong: p,
|
|
390
|
-
formatRelative:
|
|
390
|
+
formatRelative: M,
|
|
391
391
|
localize: V,
|
|
392
392
|
match: G,
|
|
393
393
|
options: {
|
|
@@ -398,4 +398,4 @@ const P = {
|
|
|
398
398
|
export {
|
|
399
399
|
I as it
|
|
400
400
|
};
|
|
401
|
-
//# sourceMappingURL=it-
|
|
401
|
+
//# sourceMappingURL=it-nz6vAKwG.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { o as s, q as o, r as i, v as d } from "./date-picker-variants-DAcSLTua.js";
|
|
2
2
|
const u = {
|
|
3
3
|
lessThanXSeconds: {
|
|
4
4
|
one: "1秒未満",
|
|
@@ -363,4 +363,4 @@ const u = {
|
|
|
363
363
|
export {
|
|
364
364
|
L as ja
|
|
365
365
|
};
|
|
366
|
-
//# sourceMappingURL=ja-
|
|
366
|
+
//# sourceMappingURL=ja-DQcqdAEJ.js.map
|
|
@@ -2,7 +2,7 @@ import { jsx as a, jsxs as i, Fragment as f } from "react/jsx-runtime";
|
|
|
2
2
|
import { forwardRef as g, useState as y, useCallback as z } from "react";
|
|
3
3
|
import { c as P } from "./index-D2ZczOXr.js";
|
|
4
4
|
import { useTranslation as I } from "react-i18next";
|
|
5
|
-
import { I as K } from "./icon-button-
|
|
5
|
+
import { I as K } from "./icon-button-LqoiKcUN.js";
|
|
6
6
|
import { C as T } from "./check-DPdL_Sm7.js";
|
|
7
7
|
import { C as j } from "./copy-B00HK7tj.js";
|
|
8
8
|
const B = P("ds:flex", {
|
|
@@ -141,4 +141,4 @@ export {
|
|
|
141
141
|
L as K,
|
|
142
142
|
_ as a
|
|
143
143
|
};
|
|
144
|
-
//# sourceMappingURL=key-value-pair-
|
|
144
|
+
//# sourceMappingURL=key-value-pair-BrgbMfbF.js.map
|