@alfadocs/ui-kit-debug 1.30.0 → 1.32.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-CZ0pEdEI.js → address-fields-jFfjxOQR.js} +3 -3
- package/dist/_chunks/{address-fields-CZ0pEdEI.js.map → address-fields-jFfjxOQR.js.map} +1 -1
- package/dist/_chunks/{agenda-card-pdN49pMu.js → agenda-card-DVz3jwTf.js} +2 -2
- package/dist/_chunks/{agenda-card-pdN49pMu.js.map → agenda-card-DVz3jwTf.js.map} +1 -1
- package/dist/_chunks/{agenda-tray-BweO8pDo.js → agenda-tray-1oDWCJdB.js} +2 -2
- package/dist/_chunks/{agenda-tray-BweO8pDo.js.map → agenda-tray-1oDWCJdB.js.map} +1 -1
- package/dist/_chunks/{ai-prompt-input-CrHr-5H8.js → ai-prompt-input-Dt7tpCBh.js} +2 -2
- package/dist/_chunks/{ai-prompt-input-CrHr-5H8.js.map → ai-prompt-input-Dt7tpCBh.js.map} +1 -1
- package/dist/_chunks/{alia-sidebar-BWcWZivN.js → alia-sidebar-D18kp3p9.js} +3 -3
- package/dist/_chunks/{alia-sidebar-BWcWZivN.js.map → alia-sidebar-D18kp3p9.js.map} +1 -1
- package/dist/_chunks/{anamnesis-summary-rows-DMO3MWSt.js → anamnesis-summary-rows-BYgyp_i2.js} +6 -6
- package/dist/_chunks/{anamnesis-summary-rows-DMO3MWSt.js.map → anamnesis-summary-rows-BYgyp_i2.js.map} +1 -1
- package/dist/_chunks/{appointment-card-Dzr3GeVz.js → appointment-card-D-oj_ugh.js} +9 -7
- package/dist/_chunks/appointment-card-D-oj_ugh.js.map +1 -0
- package/dist/_chunks/{appointment-timeline-DhHwmHo1.js → appointment-timeline-CymGHyIP.js} +2 -2
- package/dist/_chunks/{appointment-timeline-DhHwmHo1.js.map → appointment-timeline-CymGHyIP.js.map} +1 -1
- package/dist/_chunks/{appointment-tray-4FUu_5NX.js → appointment-tray-DCk8gHod.js} +2 -2
- package/dist/_chunks/{appointment-tray-4FUu_5NX.js.map → appointment-tray-DCk8gHod.js.map} +1 -1
- package/dist/_chunks/{audio-recorder-DXG6LTtO.js → audio-recorder-11wClczr.js} +2 -2
- package/dist/_chunks/{audio-recorder-DXG6LTtO.js.map → audio-recorder-11wClczr.js.map} +1 -1
- package/dist/_chunks/{avatar-BNQNhoyL.js → avatar-CkDeQOSI.js} +37 -37
- package/dist/_chunks/avatar-CkDeQOSI.js.map +1 -0
- package/dist/_chunks/{balance-badge-cell-CX6b0ML4.js → balance-badge-cell-DhBtFRoW.js} +4 -4
- package/dist/_chunks/{balance-badge-cell-CX6b0ML4.js.map → balance-badge-cell-DhBtFRoW.js.map} +1 -1
- package/dist/_chunks/{bishop-score-CJUVBfAu.js → bishop-score-CAl7C5hm.js} +2 -2
- package/dist/_chunks/{bishop-score-CJUVBfAu.js.map → bishop-score-CAl7C5hm.js.map} +1 -1
- package/dist/_chunks/{bmi-calculator-CcH6upht.js → bmi-calculator-Dwkih9a4.js} +3 -3
- package/dist/_chunks/{bmi-calculator-CcH6upht.js.map → bmi-calculator-Dwkih9a4.js.map} +1 -1
- package/dist/_chunks/{booking-AabCk7CI.js → booking-l6UGNiE1.js} +3 -3
- package/dist/_chunks/{booking-AabCk7CI.js.map → booking-l6UGNiE1.js.map} +1 -1
- package/dist/_chunks/{calculator-dialog-12d3Sxaz.js → calculator-dialog-C0ixc3SU.js} +2 -2
- package/dist/_chunks/{calculator-dialog-12d3Sxaz.js.map → calculator-dialog-C0ixc3SU.js.map} +1 -1
- package/dist/_chunks/{calendar-CI9MINcR.js → calendar-Dgvl5L4T.js} +494 -438
- package/dist/_chunks/calendar-Dgvl5L4T.js.map +1 -0
- package/dist/_chunks/{calendar-event-card-66CEEWU6.js → calendar-event-card-DSh-69HT.js} +130 -122
- package/dist/_chunks/calendar-event-card-DSh-69HT.js.map +1 -0
- package/dist/_chunks/calendar-workspace-BX-zDyVR.js +9392 -0
- package/dist/_chunks/calendar-workspace-BX-zDyVR.js.map +1 -0
- package/dist/_chunks/{care-plan-card-CQVboTn1.js → care-plan-card-CZW476Kg.js} +2 -2
- package/dist/_chunks/{care-plan-card-CQVboTn1.js.map → care-plan-card-CZW476Kg.js.map} +1 -1
- package/dist/_chunks/{care-plan-entry-card-jxHkzez5.js → care-plan-entry-card-BMUYagEw.js} +2 -2
- package/dist/_chunks/{care-plan-entry-card-jxHkzez5.js.map → care-plan-entry-card-BMUYagEw.js.map} +1 -1
- package/dist/_chunks/{chat-message-DBQu10rs.js → chat-message-C-8UU2av.js} +2 -2
- package/dist/_chunks/{chat-message-DBQu10rs.js.map → chat-message-C-8UU2av.js.map} +1 -1
- package/dist/_chunks/{clinical-note-card-BBgFd2nB.js → clinical-note-card-D2WTV2CO.js} +185 -188
- package/dist/_chunks/clinical-note-card-D2WTV2CO.js.map +1 -0
- package/dist/_chunks/{color-picker-CU303VjY.js → color-picker-Bl5f0iK1.js} +28 -25
- package/dist/_chunks/color-picker-Bl5f0iK1.js.map +1 -0
- package/dist/_chunks/{combobox-D7_NLE2Z.js → combobox-DnSdYssy.js} +216 -215
- package/dist/_chunks/combobox-DnSdYssy.js.map +1 -0
- package/dist/_chunks/{country-select-DzbPFktV.js → country-select-CfDNFG5c.js} +2 -2
- package/dist/_chunks/{country-select-DzbPFktV.js.map → country-select-CfDNFG5c.js.map} +1 -1
- package/dist/_chunks/{data-table-DB5BiVQ0.js → data-table-DC96JJIq.js} +2 -2
- package/dist/_chunks/{data-table-DB5BiVQ0.js.map → data-table-DC96JJIq.js.map} +1 -1
- package/dist/_chunks/{dependent-selector-cJlJFAKD.js → dependent-selector-yTKKsuc9.js} +2 -2
- package/dist/_chunks/{dependent-selector-cJlJFAKD.js.map → dependent-selector-yTKKsuc9.js.map} +1 -1
- package/dist/_chunks/{dialog-UbKJCi1X.js → dialog-BJiLqhx6.js} +54 -46
- package/dist/_chunks/dialog-BJiLqhx6.js.map +1 -0
- package/dist/_chunks/{document-preview-CDb-n_W7.js → document-preview-BrhMHNh8.js} +2 -2
- package/dist/_chunks/{document-preview-CDb-n_W7.js.map → document-preview-BrhMHNh8.js.map} +1 -1
- package/dist/_chunks/{due-date-calculator-BtgWeFqp.js → due-date-calculator-CxgK8vzt.js} +3 -3
- package/dist/_chunks/{due-date-calculator-BtgWeFqp.js.map → due-date-calculator-CxgK8vzt.js.map} +1 -1
- package/dist/_chunks/{entity-summary-B_vO5Ur4.js → entity-summary-5o768XLU.js} +2 -2
- package/dist/_chunks/{entity-summary-B_vO5Ur4.js.map → entity-summary-5o768XLU.js.map} +1 -1
- package/dist/_chunks/{face-scheme-DA2vjqaM.js → face-scheme-l-CQyLs-.js} +2 -2
- package/dist/_chunks/{face-scheme-DA2vjqaM.js.map → face-scheme-l-CQyLs-.js.map} +1 -1
- package/dist/_chunks/{file-manager-Cd8V9IcZ.js → file-manager-CI2Qn8qW.js} +3 -3
- package/dist/_chunks/{file-manager-Cd8V9IcZ.js.map → file-manager-CI2Qn8qW.js.map} +1 -1
- package/dist/_chunks/{gestational-age-calculator-KdMg9z9H.js → gestational-age-calculator-CZHVrERT.js} +4 -4
- package/dist/_chunks/{gestational-age-calculator-KdMg9z9H.js.map → gestational-age-calculator-CZHVrERT.js.map} +1 -1
- package/dist/_chunks/{link-cell-renderer-tWEOv3Sc.js → link-cell-renderer-BEpMNtAa.js} +3 -3
- package/dist/_chunks/{link-cell-renderer-tWEOv3Sc.js.map → link-cell-renderer-BEpMNtAa.js.map} +1 -1
- package/dist/_chunks/{marketplace-app-shell-C4AjQmvz.js → marketplace-app-shell-CK_ND8Tr.js} +2 -2
- package/dist/_chunks/{marketplace-app-shell-C4AjQmvz.js.map → marketplace-app-shell-CK_ND8Tr.js.map} +1 -1
- package/dist/_chunks/{message-card-D8GB4FdF.js → message-card-BUMv16un.js} +2 -2
- package/dist/_chunks/{message-card-D8GB4FdF.js.map → message-card-BUMv16un.js.map} +1 -1
- package/dist/_chunks/{message-tray-CGIRQjx5.js → message-tray-0zsv27xX.js} +2 -2
- package/dist/_chunks/{message-tray-CGIRQjx5.js.map → message-tray-0zsv27xX.js.map} +1 -1
- package/dist/_chunks/{muscle-scheme-BSJsI4-I.js → muscle-scheme-UVz_x4iE.js} +2 -2
- package/dist/_chunks/{muscle-scheme-BSJsI4-I.js.map → muscle-scheme-UVz_x4iE.js.map} +1 -1
- package/dist/_chunks/notes-panel-C4G-mhZ9.js +380 -0
- package/dist/_chunks/notes-panel-C4G-mhZ9.js.map +1 -0
- package/dist/_chunks/{operator-hero-BnFv-Uef.js → operator-hero-D7-iiFQ9.js} +2 -2
- package/dist/_chunks/{operator-hero-BnFv-Uef.js.map → operator-hero-D7-iiFQ9.js.map} +1 -1
- package/dist/_chunks/{optical-prescription-BvwuqTpl.js → optical-prescription-DUJOhKz_.js} +2 -2
- package/dist/_chunks/{optical-prescription-BvwuqTpl.js.map → optical-prescription-DUJOhKz_.js.map} +1 -1
- package/dist/_chunks/{patient-details-DYAmq76G.js → patient-details-BGiawUHd.js} +5 -5
- package/dist/_chunks/{patient-details-DYAmq76G.js.map → patient-details-BGiawUHd.js.map} +1 -1
- package/dist/_chunks/{patient-summary-card-C9WBwct-.js → patient-summary-card--CT_gbaQ.js} +2 -2
- package/dist/_chunks/{patient-summary-card-C9WBwct-.js.map → patient-summary-card--CT_gbaQ.js.map} +1 -1
- package/dist/_chunks/{periodontal-diagnosis-HrFsVi-C.js → periodontal-diagnosis-lEwA8wqX.js} +3 -3
- package/dist/_chunks/{periodontal-diagnosis-HrFsVi-C.js.map → periodontal-diagnosis-lEwA8wqX.js.map} +1 -1
- package/dist/_chunks/{practice-profile-hero-YQ7h2K4o.js → practice-profile-hero-DQyDvpJL.js} +2 -2
- package/dist/_chunks/{practice-profile-hero-YQ7h2K4o.js.map → practice-profile-hero-DQyDvpJL.js.map} +1 -1
- package/dist/_chunks/{practice-results-CxIsU2YO.js → practice-results-DjEzPgAK.js} +2 -2
- package/dist/_chunks/{practice-results-CxIsU2YO.js.map → practice-results-DjEzPgAK.js.map} +1 -1
- package/dist/_chunks/{pregnancy-dating-m-c05DOI.js → pregnancy-dating-n5j5dAKy.js} +4 -4
- package/dist/_chunks/{pregnancy-dating-m-c05DOI.js.map → pregnancy-dating-n5j5dAKy.js.map} +1 -1
- package/dist/_chunks/{pregnancy-weight-gain-CJwbs9W-.js → pregnancy-weight-gain-D5A8vPjj.js} +3 -3
- package/dist/_chunks/{pregnancy-weight-gain-CJwbs9W-.js.map → pregnancy-weight-gain-D5A8vPjj.js.map} +1 -1
- package/dist/_chunks/{province-select-BBc7s7vR.js → province-select-BaUnkg4S.js} +2 -2
- package/dist/_chunks/{province-select-BBc7s7vR.js.map → province-select-BaUnkg4S.js.map} +1 -1
- package/dist/_chunks/qr-code-DOJs4suh.js +750 -0
- package/dist/_chunks/qr-code-DOJs4suh.js.map +1 -0
- package/dist/_chunks/radio-DNRe6H_8.js +193 -0
- package/dist/_chunks/radio-DNRe6H_8.js.map +1 -0
- package/dist/_chunks/radio-group-DyVBgnA3.js +297 -0
- package/dist/_chunks/radio-group-DyVBgnA3.js.map +1 -0
- package/dist/_chunks/{radiograph-panel.agent-ByM9M3qm.js → radiograph-panel.agent-o4jwEJPC.js} +2 -2
- package/dist/_chunks/{radiograph-panel.agent-ByM9M3qm.js.map → radiograph-panel.agent-o4jwEJPC.js.map} +1 -1
- package/dist/_chunks/{rich-text-editor-lSCiE0Zz.js → rich-text-editor-CQ7yZdG3.js} +3 -3
- package/dist/_chunks/{rich-text-editor-lSCiE0Zz.js.map → rich-text-editor-CQ7yZdG3.js.map} +1 -1
- package/dist/_chunks/select-CLSUnKjF.js +520 -0
- package/dist/_chunks/select-CLSUnKjF.js.map +1 -0
- package/dist/_chunks/signature-request-vihDT8On.js +2232 -0
- package/dist/_chunks/signature-request-vihDT8On.js.map +1 -0
- package/dist/_chunks/{tabs-DqKtTIjZ.js → tabs-BnRaLT0y.js} +2 -2
- package/dist/_chunks/{tabs-DqKtTIjZ.js.map → tabs-BnRaLT0y.js.map} +1 -1
- package/dist/_chunks/{tasks-panel-DPCNaRko.js → tasks-panel-DQuaVvl5.js} +2 -2
- package/dist/_chunks/{tasks-panel-DPCNaRko.js.map → tasks-panel-DQuaVvl5.js.map} +1 -1
- package/dist/_chunks/{timeline-r-8IUoBS.js → timeline-Bs9Erxlo.js} +38 -36
- package/dist/_chunks/timeline-Bs9Erxlo.js.map +1 -0
- package/dist/_chunks/{tooth-scheme-C9jssOmy.js → tooth-scheme-Qe7LO5Di.js} +2 -2
- package/dist/_chunks/{tooth-scheme-C9jssOmy.js.map → tooth-scheme-Qe7LO5Di.js.map} +1 -1
- package/dist/_chunks/{unit-converter-C6jMjqL9.js → unit-converter-BTgU50gk.js} +2 -2
- package/dist/_chunks/{unit-converter-C6jMjqL9.js.map → unit-converter-BTgU50gk.js.map} +1 -1
- package/dist/_chunks/{widget-picker-em4xGgv0.js → widget-picker-DvUkBemi.js} +2 -2
- package/dist/_chunks/{widget-picker-em4xGgv0.js.map → widget-picker-DvUkBemi.js.map} +1 -1
- package/dist/agent-catalog.json +366 -29
- package/dist/agent-i18n/en.json +27 -15
- package/dist/components/_shared/get-error-message.d.ts +3 -0
- package/dist/components/_shared/get-error-message.d.ts.map +1 -0
- package/dist/components/address-fields/index.js +1 -1
- package/dist/components/agenda-card/index.js +1 -1
- package/dist/components/agenda-tray/index.js +1 -1
- package/dist/components/ai-prompt-input/index.js +1 -1
- package/dist/components/appointment-card/appointment-card.d.ts.map +1 -1
- package/dist/components/appointment-card/index.js +2 -2
- package/dist/components/appointment-timeline/index.js +1 -1
- package/dist/components/audio-recorder/index.js +1 -1
- package/dist/components/avatar/avatar.d.ts +2 -0
- package/dist/components/avatar/avatar.d.ts.map +1 -1
- package/dist/components/avatar/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/calculator-dialog/index.js +1 -1
- package/dist/components/calendar/calendar.d.ts +26 -2
- package/dist/components/calendar/calendar.d.ts.map +1 -1
- package/dist/components/calendar/index.js +1 -1
- package/dist/components/calendar-event-card/calendar-event-card.d.ts +9 -0
- package/dist/components/calendar-event-card/calendar-event-card.d.ts.map +1 -1
- package/dist/components/calendar-event-card/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/chat-message/index.js +1 -1
- package/dist/components/clinical-note-card/clinical-note-card.d.ts +16 -1
- package/dist/components/clinical-note-card/clinical-note-card.d.ts.map +1 -1
- package/dist/components/clinical-note-card/index.js +1 -1
- package/dist/components/color-picker/color-utils.d.ts.map +1 -1
- package/dist/components/color-picker/index.js +1 -1
- package/dist/components/combobox/combobox.d.ts +5 -0
- package/dist/components/combobox/combobox.d.ts.map +1 -1
- package/dist/components/combobox/index.js +1 -1
- package/dist/components/country-select/index.js +1 -1
- package/dist/components/data-table/index.js +2 -2
- package/dist/components/dependent-selector/index.js +1 -1
- package/dist/components/dialog/dialog.d.ts +9 -0
- package/dist/components/dialog/dialog.d.ts.map +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/message-card/index.js +1 -1
- package/dist/components/message-tray/index.js +1 -1
- package/dist/components/muscle-scheme/index.js +1 -1
- package/dist/components/notes-panel/index.d.ts +1 -1
- package/dist/components/notes-panel/index.d.ts.map +1 -1
- package/dist/components/notes-panel/index.js +1 -1
- package/dist/components/notes-panel/notes-panel.agent.d.ts.map +1 -1
- package/dist/components/notes-panel/notes-panel.d.ts +24 -5
- package/dist/components/notes-panel/notes-panel.d.ts.map +1 -1
- package/dist/components/operator-hero/index.js +1 -1
- package/dist/components/optical-prescription/index.js +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/periodontal-diagnosis/index.js +1 -1
- package/dist/components/practice-profile-hero/index.js +1 -1
- package/dist/components/practice-results/index.js +1 -1
- package/dist/components/pregnancy-dating/index.js +1 -1
- package/dist/components/pregnancy-weight-gain/index.js +1 -1
- package/dist/components/province-select/index.js +1 -1
- package/dist/components/qr-code/index.js +1 -1
- package/dist/components/qr-code/qr-encode.d.ts +14 -16
- package/dist/components/qr-code/qr-encode.d.ts.map +1 -1
- package/dist/components/radio/index.js +1 -1
- package/dist/components/radio-group/index.js +2 -2
- package/dist/components/radio-group/radio-group-context.d.ts +4 -1
- package/dist/components/radio-group/radio-group-context.d.ts.map +1 -1
- package/dist/components/radio-group/radio-group.agent.d.ts.map +1 -1
- package/dist/components/radio-group/radio-group.d.ts +13 -1
- package/dist/components/radio-group/radio-group.d.ts.map +1 -1
- package/dist/components/radio-group/radio.d.ts +24 -1
- package/dist/components/radio-group/radio.d.ts.map +1 -1
- package/dist/components/radiograph-panel/index.js +1 -1
- package/dist/components/rich-text-editor/index.js +1 -1
- package/dist/components/select/index.js +1 -1
- package/dist/components/select/select.agent.d.ts.map +1 -1
- package/dist/components/select/select.d.ts +33 -0
- package/dist/components/select/select.d.ts.map +1 -1
- package/dist/components/skeleton-scheme/index.js +1 -1
- package/dist/components/tabs/index.js +1 -1
- package/dist/components/tasks-panel/index.js +1 -1
- package/dist/components/timeline/index.js +1 -1
- package/dist/components/timeline/timeline.d.ts +2 -0
- package/dist/components/timeline/timeline.d.ts.map +1 -1
- package/dist/components/tooth-scheme/index.js +1 -1
- package/dist/components/unit-converter/index.js +1 -1
- package/dist/components/widget-picker/index.js +1 -1
- package/dist/host-compat.css +7 -1
- package/dist/i18n/locales/ar.d.ts +118 -0
- package/dist/i18n/locales/ar.d.ts.map +1 -1
- package/dist/i18n/locales/ar.js +123 -5
- package/dist/i18n/locales/ar.js.map +1 -1
- package/dist/i18n/locales/de.d.ts +128 -10
- package/dist/i18n/locales/de.d.ts.map +1 -1
- package/dist/i18n/locales/de.js +135 -15
- package/dist/i18n/locales/de.js.map +1 -1
- package/dist/i18n/locales/el.d.ts +118 -0
- package/dist/i18n/locales/el.d.ts.map +1 -1
- package/dist/i18n/locales/el.js +123 -5
- package/dist/i18n/locales/el.js.map +1 -1
- package/dist/i18n/locales/en.d.ts +118 -0
- package/dist/i18n/locales/en.d.ts.map +1 -1
- package/dist/i18n/locales/en.js +123 -5
- package/dist/i18n/locales/en.js.map +1 -1
- package/dist/i18n/locales/es.d.ts +118 -0
- package/dist/i18n/locales/es.d.ts.map +1 -1
- package/dist/i18n/locales/es.js +123 -5
- package/dist/i18n/locales/es.js.map +1 -1
- package/dist/i18n/locales/fr.d.ts +118 -0
- package/dist/i18n/locales/fr.d.ts.map +1 -1
- package/dist/i18n/locales/fr.js +122 -4
- package/dist/i18n/locales/fr.js.map +1 -1
- package/dist/i18n/locales/hi.d.ts +118 -0
- package/dist/i18n/locales/hi.d.ts.map +1 -1
- package/dist/i18n/locales/hi.js +123 -5
- package/dist/i18n/locales/hi.js.map +1 -1
- package/dist/i18n/locales/it.d.ts +128 -10
- package/dist/i18n/locales/it.d.ts.map +1 -1
- package/dist/i18n/locales/it.js +133 -15
- package/dist/i18n/locales/it.js.map +1 -1
- package/dist/i18n/locales/ja.d.ts +118 -0
- package/dist/i18n/locales/ja.d.ts.map +1 -1
- package/dist/i18n/locales/ja.js +123 -5
- package/dist/i18n/locales/ja.js.map +1 -1
- package/dist/i18n/locales/nl.d.ts +118 -0
- package/dist/i18n/locales/nl.d.ts.map +1 -1
- package/dist/i18n/locales/nl.js +123 -5
- package/dist/i18n/locales/nl.js.map +1 -1
- package/dist/i18n/locales/pl.d.ts +118 -0
- package/dist/i18n/locales/pl.d.ts.map +1 -1
- package/dist/i18n/locales/pl.js +123 -5
- package/dist/i18n/locales/pl.js.map +1 -1
- package/dist/i18n/locales/pt.d.ts +118 -0
- package/dist/i18n/locales/pt.d.ts.map +1 -1
- package/dist/i18n/locales/pt.js +123 -5
- package/dist/i18n/locales/pt.js.map +1 -1
- package/dist/i18n/locales/ro.d.ts +118 -0
- package/dist/i18n/locales/ro.d.ts.map +1 -1
- package/dist/i18n/locales/ro.js +122 -4
- package/dist/i18n/locales/ro.js.map +1 -1
- package/dist/i18n/locales/ru.d.ts +118 -0
- package/dist/i18n/locales/ru.d.ts.map +1 -1
- package/dist/i18n/locales/ru.js +123 -5
- package/dist/i18n/locales/ru.js.map +1 -1
- package/dist/i18n/locales/sq.d.ts +118 -0
- package/dist/i18n/locales/sq.d.ts.map +1 -1
- package/dist/i18n/locales/sq.js +123 -5
- package/dist/i18n/locales/sq.js.map +1 -1
- package/dist/i18n/locales/sv.d.ts +118 -0
- package/dist/i18n/locales/sv.d.ts.map +1 -1
- package/dist/i18n/locales/sv.js +123 -5
- package/dist/i18n/locales/sv.js.map +1 -1
- package/dist/i18n/locales/tr.d.ts +118 -0
- package/dist/i18n/locales/tr.d.ts.map +1 -1
- package/dist/i18n/locales/tr.js +123 -5
- package/dist/i18n/locales/tr.js.map +1 -1
- package/dist/i18n/locales/zh.d.ts +118 -0
- package/dist/i18n/locales/zh.d.ts.map +1 -1
- package/dist/i18n/locales/zh.js +123 -5
- package/dist/i18n/locales/zh.js.map +1 -1
- package/dist/index.js +131 -130
- package/dist/locales/ar.json +123 -5
- package/dist/locales/de.json +133 -15
- package/dist/locales/el.json +123 -5
- package/dist/locales/en.json +123 -5
- package/dist/locales/es.json +123 -5
- package/dist/locales/fr.json +122 -4
- package/dist/locales/hi.json +123 -5
- package/dist/locales/it.json +133 -15
- package/dist/locales/ja.json +123 -5
- package/dist/locales/nl.json +123 -5
- package/dist/locales/pl.json +123 -5
- package/dist/locales/pt.json +123 -5
- package/dist/locales/ro.json +122 -4
- package/dist/locales/ru.json +123 -5
- package/dist/locales/sq.json +123 -5
- package/dist/locales/sv.json +123 -5
- package/dist/locales/tr.json +123 -5
- package/dist/locales/zh.json +123 -5
- package/dist/patterns/alia-assistant/index.js +1 -1
- package/dist/patterns/anamnesis/index.js +1 -1
- package/dist/patterns/calendar/calendar-appointment-details.d.ts +145 -0
- package/dist/patterns/calendar/calendar-appointment-details.d.ts.map +1 -0
- package/dist/patterns/calendar/calendar-appointment-details.sections.d.ts +32 -0
- package/dist/patterns/calendar/calendar-appointment-details.sections.d.ts.map +1 -0
- package/dist/patterns/calendar/calendar-editor-hydration.d.ts +59 -0
- package/dist/patterns/calendar/calendar-editor-hydration.d.ts.map +1 -0
- package/dist/patterns/calendar/calendar-notes-tool.d.ts +14 -0
- package/dist/patterns/calendar/calendar-notes-tool.d.ts.map +1 -0
- package/dist/patterns/calendar/calendar-patient-picker.d.ts +11 -0
- package/dist/patterns/calendar/calendar-patient-picker.d.ts.map +1 -0
- package/dist/patterns/calendar/calendar-series-scope-chooser.d.ts +18 -0
- package/dist/patterns/calendar/calendar-series-scope-chooser.d.ts.map +1 -0
- package/dist/patterns/calendar/calendar-workspace.d.ts +26 -1
- package/dist/patterns/calendar/calendar-workspace.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar-workspace.model.d.ts +8 -5
- package/dist/patterns/calendar/calendar-workspace.model.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar.data.d.ts +66 -1
- package/dist/patterns/calendar/calendar.data.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar.host.d.ts +2 -0
- package/dist/patterns/calendar/calendar.host.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar.journey.d.ts +42 -7
- package/dist/patterns/calendar/calendar.journey.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar.model.d.ts +54 -5
- package/dist/patterns/calendar/calendar.model.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar.sheets.d.ts +68 -15
- package/dist/patterns/calendar/calendar.sheets.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar.surface.d.ts +12 -2
- package/dist/patterns/calendar/calendar.surface.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar.types.d.ts +29 -1
- package/dist/patterns/calendar/calendar.types.d.ts.map +1 -1
- package/dist/patterns/calendar/index.d.ts +9 -6
- package/dist/patterns/calendar/index.d.ts.map +1 -1
- package/dist/patterns/calendar/index.js +15 -14
- package/dist/patterns/marketplace-app-shell/index.js +1 -1
- package/dist/patterns/signature-request/channel-meta.d.ts +27 -0
- package/dist/patterns/signature-request/channel-meta.d.ts.map +1 -0
- package/dist/patterns/signature-request/index.d.ts +1 -1
- package/dist/patterns/signature-request/index.d.ts.map +1 -1
- package/dist/patterns/signature-request/index.js +1 -1
- package/dist/patterns/signature-request/load-status.d.ts +13 -0
- package/dist/patterns/signature-request/load-status.d.ts.map +1 -0
- package/dist/patterns/signature-request/person-grid.d.ts +32 -0
- package/dist/patterns/signature-request/person-grid.d.ts.map +1 -0
- package/dist/patterns/signature-request/required-documents.d.ts +127 -0
- package/dist/patterns/signature-request/required-documents.d.ts.map +1 -0
- package/dist/patterns/signature-request/signature-history.d.ts +57 -0
- package/dist/patterns/signature-request/signature-history.d.ts.map +1 -0
- package/dist/patterns/signature-request/signature-outcome.d.ts +29 -0
- package/dist/patterns/signature-request/signature-outcome.d.ts.map +1 -0
- package/dist/patterns/signature-request/signature-request.d.ts +390 -26
- package/dist/patterns/signature-request/signature-request.d.ts.map +1 -1
- package/dist/tokens.css +10 -2
- package/package.json +3 -1
- package/dist/_chunks/appointment-card-Dzr3GeVz.js.map +0 -1
- package/dist/_chunks/avatar-BNQNhoyL.js.map +0 -1
- package/dist/_chunks/calendar-CI9MINcR.js.map +0 -1
- package/dist/_chunks/calendar-event-card-66CEEWU6.js.map +0 -1
- package/dist/_chunks/calendar-workspace-a84AHQwj.js +0 -7506
- package/dist/_chunks/calendar-workspace-a84AHQwj.js.map +0 -1
- package/dist/_chunks/clinical-note-card-BBgFd2nB.js.map +0 -1
- package/dist/_chunks/color-picker-CU303VjY.js.map +0 -1
- package/dist/_chunks/combobox-D7_NLE2Z.js.map +0 -1
- package/dist/_chunks/dialog-UbKJCi1X.js.map +0 -1
- package/dist/_chunks/notes-panel-CTNpsByN.js +0 -353
- package/dist/_chunks/notes-panel-CTNpsByN.js.map +0 -1
- package/dist/_chunks/qr-code-CPkEs5mG.js +0 -574
- package/dist/_chunks/qr-code-CPkEs5mG.js.map +0 -1
- package/dist/_chunks/radio-TWf9Q-mp.js +0 -108
- package/dist/_chunks/radio-TWf9Q-mp.js.map +0 -1
- package/dist/_chunks/radio-group-rXDJADzW.js +0 -175
- package/dist/_chunks/radio-group-rXDJADzW.js.map +0 -1
- package/dist/_chunks/select-Bi8zril7.js +0 -471
- package/dist/_chunks/select-Bi8zril7.js.map +0 -1
- package/dist/_chunks/signature-request-C-IsbkPf.js +0 -417
- package/dist/_chunks/signature-request-C-IsbkPf.js.map +0 -1
- package/dist/_chunks/timeline-r-8IUoBS.js.map +0 -1
|
@@ -0,0 +1,750 @@
|
|
|
1
|
+
var rt = Object.defineProperty;
|
|
2
|
+
var ot = (r, t, e) => t in r ? rt(r, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[t] = e;
|
|
3
|
+
var A = (r, t, e) => ot(r, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
+
import { jsxs as F, jsx as b } from "react/jsx-runtime";
|
|
5
|
+
import { forwardRef as nt, useMemo as it } from "react";
|
|
6
|
+
import { c as O } from "./index-D2ZczOXr.js";
|
|
7
|
+
import { useTranslation as at } from "react-i18next";
|
|
8
|
+
import { u as lt } from "./registry-DvAUVLHh.js";
|
|
9
|
+
import { A as ct } from "./Alfadocs_Logo_Mark-7o3L3WBI.js";
|
|
10
|
+
const dt = {
|
|
11
|
+
id: "qr-code",
|
|
12
|
+
capabilities: [],
|
|
13
|
+
state: {
|
|
14
|
+
value: {
|
|
15
|
+
type: "string",
|
|
16
|
+
descriptionKey: "ui.agent.qrCode.state.value",
|
|
17
|
+
description: "The string (typically an https URL) encoded into the QR.",
|
|
18
|
+
read: (r) => r
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
actions: {},
|
|
22
|
+
domHooks: {
|
|
23
|
+
root: {
|
|
24
|
+
attr: "data-component",
|
|
25
|
+
value: "qr-code",
|
|
26
|
+
description: "Marks the element as a kit QrCode renderer."
|
|
27
|
+
},
|
|
28
|
+
instanceId: {
|
|
29
|
+
attr: "data-component-id",
|
|
30
|
+
sourceProp: "id",
|
|
31
|
+
description: "Sourced from the id prop."
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
var M = /* @__PURE__ */ ((r) => (r[r.Border = -1] = "Border", r[r.Data = 0] = "Data", r[r.Function = 1] = "Function", r[r.Position = 2] = "Position", r[r.Timing = 3] = "Timing", r[r.Alignment = 4] = "Alignment", r))(M || {});
|
|
36
|
+
const ft = [0, 1], G = [1, 0], j = [2, 3], K = [3, 2], ht = {
|
|
37
|
+
L: ft,
|
|
38
|
+
M: G,
|
|
39
|
+
Q: j,
|
|
40
|
+
H: K
|
|
41
|
+
}, ut = /^\d*$/, mt = /^[A-Z0-9 $%*+./:-]*$/, I = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:", L = 1, S = 40, Y = 3, gt = 3, z = 40, pt = 10, H = [
|
|
42
|
+
// Version: (note that index 0 is for padding, and is set to an illegal value)
|
|
43
|
+
// 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40 Error correction level
|
|
44
|
+
[-1, 7, 10, 15, 20, 26, 18, 20, 24, 30, 18, 20, 24, 26, 30, 22, 24, 28, 30, 28, 28, 28, 28, 30, 30, 26, 28, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30],
|
|
45
|
+
// Low
|
|
46
|
+
[-1, 10, 16, 26, 18, 24, 16, 18, 22, 22, 26, 30, 22, 22, 24, 24, 28, 28, 26, 26, 26, 26, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28],
|
|
47
|
+
// Medium
|
|
48
|
+
[-1, 13, 22, 18, 26, 18, 24, 18, 22, 20, 24, 28, 26, 24, 20, 30, 24, 28, 28, 26, 30, 28, 30, 30, 30, 30, 28, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30],
|
|
49
|
+
// Quartile
|
|
50
|
+
[-1, 17, 28, 22, 16, 22, 28, 26, 26, 24, 28, 24, 28, 22, 24, 24, 30, 28, 28, 26, 28, 30, 24, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30]
|
|
51
|
+
// High
|
|
52
|
+
], X = [
|
|
53
|
+
// Version: (note that index 0 is for padding, and is set to an illegal value)
|
|
54
|
+
// 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40 Error correction level
|
|
55
|
+
[-1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 4, 4, 4, 4, 4, 6, 6, 6, 6, 7, 8, 8, 9, 9, 10, 12, 12, 12, 13, 14, 15, 16, 17, 18, 19, 19, 20, 21, 22, 24, 25],
|
|
56
|
+
// Low
|
|
57
|
+
[-1, 1, 1, 1, 2, 2, 4, 4, 4, 5, 5, 5, 8, 9, 9, 10, 10, 11, 13, 14, 16, 17, 17, 18, 20, 21, 23, 25, 26, 28, 29, 31, 33, 35, 37, 38, 40, 43, 45, 47, 49],
|
|
58
|
+
// Medium
|
|
59
|
+
[-1, 1, 1, 2, 2, 4, 4, 6, 6, 8, 8, 8, 10, 12, 16, 12, 17, 16, 18, 21, 20, 23, 23, 25, 27, 29, 34, 34, 35, 38, 40, 43, 45, 48, 51, 53, 56, 59, 62, 65, 68],
|
|
60
|
+
// Quartile
|
|
61
|
+
[-1, 1, 1, 2, 4, 4, 4, 5, 6, 8, 8, 11, 11, 16, 16, 18, 16, 19, 21, 25, 25, 25, 34, 30, 32, 35, 37, 40, 42, 45, 48, 51, 54, 57, 60, 63, 66, 70, 74, 77, 81]
|
|
62
|
+
// High
|
|
63
|
+
];
|
|
64
|
+
let wt = class {
|
|
65
|
+
/* -- Constructor (low level) and fields -- */
|
|
66
|
+
// Creates a new QR Code with the given version number,
|
|
67
|
+
// error correction level, data codeword bytes, and mask number.
|
|
68
|
+
// This is a low-level API that most users should not use directly.
|
|
69
|
+
// A mid-level API is the encodeSegments() function.
|
|
70
|
+
constructor(t, e, s, o) {
|
|
71
|
+
/* -- Fields -- */
|
|
72
|
+
// The width and height of this QR Code, measured in modules, between
|
|
73
|
+
// 21 and 177 (inclusive). This is equal to version * 4 + 17.
|
|
74
|
+
A(this, "size");
|
|
75
|
+
// The index of the mask pattern used in this QR Code, which is between 0 and 7 (inclusive).
|
|
76
|
+
// Even if a QR Code is created with automatic masking requested (mask = -1),
|
|
77
|
+
// the resulting object still has a mask value between 0 and 7.
|
|
78
|
+
A(this, "mask");
|
|
79
|
+
// The modules of this QR Code (false = light, true = dark).
|
|
80
|
+
// Immutable after constructor finishes. Accessed through getModule().
|
|
81
|
+
A(this, "modules", []);
|
|
82
|
+
A(this, "types", []);
|
|
83
|
+
if (this.version = t, this.ecc = e, t < L || t > S)
|
|
84
|
+
throw new RangeError("Version value out of range");
|
|
85
|
+
if (o < -1 || o > 7)
|
|
86
|
+
throw new RangeError("Mask value out of range");
|
|
87
|
+
this.size = t * 4 + 17;
|
|
88
|
+
const n = Array.from({ length: this.size }).fill(!1);
|
|
89
|
+
for (let a = 0; a < this.size; a++)
|
|
90
|
+
this.modules.push(n.slice()), this.types.push(n.map(() => 0));
|
|
91
|
+
this.drawFunctionPatterns();
|
|
92
|
+
const i = this.addEccAndInterleave(s);
|
|
93
|
+
if (this.drawCodewords(i), o === -1) {
|
|
94
|
+
let a = 1e9;
|
|
95
|
+
for (let l = 0; l < 8; l++) {
|
|
96
|
+
this.applyMask(l), this.drawFormatBits(l);
|
|
97
|
+
const c = this.getPenaltyScore();
|
|
98
|
+
c < a && (o = l, a = c), this.applyMask(l);
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
this.mask = o, this.applyMask(o), this.drawFormatBits(o);
|
|
102
|
+
}
|
|
103
|
+
/* -- Accessor methods -- */
|
|
104
|
+
// Returns the color of the module (pixel) at the given coordinates, which is false
|
|
105
|
+
// for light or true for dark. The top left corner has the coordinates (x=0, y=0).
|
|
106
|
+
// If the given coordinates are out of bounds, then false (light) is returned.
|
|
107
|
+
getModule(t, e) {
|
|
108
|
+
return t >= 0 && t < this.size && e >= 0 && e < this.size && this.modules[e][t];
|
|
109
|
+
}
|
|
110
|
+
/* -- Private helper methods for constructor: Drawing function modules -- */
|
|
111
|
+
// Reads this object's version field, and draws and marks all function modules.
|
|
112
|
+
drawFunctionPatterns() {
|
|
113
|
+
for (let s = 0; s < this.size; s++)
|
|
114
|
+
this.setFunctionModule(6, s, s % 2 === 0, M.Timing), this.setFunctionModule(s, 6, s % 2 === 0, M.Timing);
|
|
115
|
+
this.drawFinderPattern(3, 3), this.drawFinderPattern(this.size - 4, 3), this.drawFinderPattern(3, this.size - 4);
|
|
116
|
+
const t = this.getAlignmentPatternPositions(), e = t.length;
|
|
117
|
+
for (let s = 0; s < e; s++)
|
|
118
|
+
for (let o = 0; o < e; o++)
|
|
119
|
+
s === 0 && o === 0 || s === 0 && o === e - 1 || s === e - 1 && o === 0 || this.drawAlignmentPattern(t[s], t[o]);
|
|
120
|
+
this.drawFormatBits(0), this.drawVersion();
|
|
121
|
+
}
|
|
122
|
+
// Draws two copies of the format bits (with its own error correction code)
|
|
123
|
+
// based on the given mask and this object's error correction level field.
|
|
124
|
+
drawFormatBits(t) {
|
|
125
|
+
const e = this.ecc[1] << 3 | t;
|
|
126
|
+
let s = e;
|
|
127
|
+
for (let n = 0; n < 10; n++)
|
|
128
|
+
s = s << 1 ^ (s >>> 9) * 1335;
|
|
129
|
+
const o = (e << 10 | s) ^ 21522;
|
|
130
|
+
for (let n = 0; n <= 5; n++)
|
|
131
|
+
this.setFunctionModule(8, n, p(o, n));
|
|
132
|
+
this.setFunctionModule(8, 7, p(o, 6)), this.setFunctionModule(8, 8, p(o, 7)), this.setFunctionModule(7, 8, p(o, 8));
|
|
133
|
+
for (let n = 9; n < 15; n++)
|
|
134
|
+
this.setFunctionModule(14 - n, 8, p(o, n));
|
|
135
|
+
for (let n = 0; n < 8; n++)
|
|
136
|
+
this.setFunctionModule(this.size - 1 - n, 8, p(o, n));
|
|
137
|
+
for (let n = 8; n < 15; n++)
|
|
138
|
+
this.setFunctionModule(8, this.size - 15 + n, p(o, n));
|
|
139
|
+
this.setFunctionModule(8, this.size - 8, !0);
|
|
140
|
+
}
|
|
141
|
+
// Draws two copies of the version bits (with its own error correction code),
|
|
142
|
+
// based on this object's version field, iff 7 <= version <= 40.
|
|
143
|
+
drawVersion() {
|
|
144
|
+
if (this.version < 7)
|
|
145
|
+
return;
|
|
146
|
+
let t = this.version;
|
|
147
|
+
for (let s = 0; s < 12; s++)
|
|
148
|
+
t = t << 1 ^ (t >>> 11) * 7973;
|
|
149
|
+
const e = this.version << 12 | t;
|
|
150
|
+
for (let s = 0; s < 18; s++) {
|
|
151
|
+
const o = p(e, s), n = this.size - 11 + s % 3, i = Math.floor(s / 3);
|
|
152
|
+
this.setFunctionModule(n, i, o), this.setFunctionModule(i, n, o);
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
// Draws a 9*9 finder pattern including the border separator,
|
|
156
|
+
// with the center module at (x, y). Modules can be out of bounds.
|
|
157
|
+
drawFinderPattern(t, e) {
|
|
158
|
+
for (let s = -4; s <= 4; s++)
|
|
159
|
+
for (let o = -4; o <= 4; o++) {
|
|
160
|
+
const n = Math.max(Math.abs(o), Math.abs(s)), i = t + o, a = e + s;
|
|
161
|
+
i >= 0 && i < this.size && a >= 0 && a < this.size && this.setFunctionModule(i, a, n !== 2 && n !== 4, M.Position);
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
// Draws a 5*5 alignment pattern, with the center module
|
|
165
|
+
// at (x, y). All modules must be in bounds.
|
|
166
|
+
drawAlignmentPattern(t, e) {
|
|
167
|
+
for (let s = -2; s <= 2; s++)
|
|
168
|
+
for (let o = -2; o <= 2; o++)
|
|
169
|
+
this.setFunctionModule(
|
|
170
|
+
t + o,
|
|
171
|
+
e + s,
|
|
172
|
+
Math.max(Math.abs(o), Math.abs(s)) !== 1,
|
|
173
|
+
M.Alignment
|
|
174
|
+
);
|
|
175
|
+
}
|
|
176
|
+
// Sets the color of a module and marks it as a function module.
|
|
177
|
+
// Only used by the constructor. Coordinates must be in bounds.
|
|
178
|
+
setFunctionModule(t, e, s, o = M.Function) {
|
|
179
|
+
this.modules[e][t] = s, this.types[e][t] = o;
|
|
180
|
+
}
|
|
181
|
+
/* -- Private helper methods for constructor: Codewords and masking -- */
|
|
182
|
+
// Returns a new byte string representing the given data with the appropriate error correction
|
|
183
|
+
// codewords appended to it, based on this object's version and error correction level.
|
|
184
|
+
addEccAndInterleave(t) {
|
|
185
|
+
const e = this.version, s = this.ecc;
|
|
186
|
+
if (t.length !== C(e, s))
|
|
187
|
+
throw new RangeError("Invalid argument");
|
|
188
|
+
const o = X[s[0]][e], n = H[s[0]][e], i = Math.floor(q(e) / 8), a = o - i % o, l = Math.floor(i / o), c = [], h = Ct(n);
|
|
189
|
+
for (let f = 0, m = 0; f < o; f++) {
|
|
190
|
+
const u = t.slice(m, m + l - n + (f < a ? 0 : 1));
|
|
191
|
+
m += u.length;
|
|
192
|
+
const y = Nt(u, h);
|
|
193
|
+
f < a && u.push(0), c.push(u.concat(y));
|
|
194
|
+
}
|
|
195
|
+
const d = [];
|
|
196
|
+
for (let f = 0; f < c[0].length; f++)
|
|
197
|
+
c.forEach((m, u) => {
|
|
198
|
+
(f !== l - n || u >= a) && d.push(m[f]);
|
|
199
|
+
});
|
|
200
|
+
return d;
|
|
201
|
+
}
|
|
202
|
+
// Draws the given sequence of 8-bit codewords (data and error correction) onto the entire
|
|
203
|
+
// data area of this QR Code. Function modules need to be marked off before this is called.
|
|
204
|
+
drawCodewords(t) {
|
|
205
|
+
if (t.length !== Math.floor(q(this.version) / 8))
|
|
206
|
+
throw new RangeError("Invalid argument");
|
|
207
|
+
let e = 0;
|
|
208
|
+
for (let s = this.size - 1; s >= 1; s -= 2) {
|
|
209
|
+
s === 6 && (s = 5);
|
|
210
|
+
for (let o = 0; o < this.size; o++)
|
|
211
|
+
for (let n = 0; n < 2; n++) {
|
|
212
|
+
const i = s - n, l = (s + 1 & 2) === 0 ? this.size - 1 - o : o;
|
|
213
|
+
!this.types[l][i] && e < t.length * 8 && (this.modules[l][i] = p(t[e >>> 3], 7 - (e & 7)), e++);
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
// XORs the codeword modules in this QR Code with the given mask pattern.
|
|
218
|
+
// The function modules must be marked and the codeword bits must be drawn
|
|
219
|
+
// before masking. Due to the arithmetic of XOR, calling applyMask() with
|
|
220
|
+
// the same mask value a second time will undo the mask. A final well-formed
|
|
221
|
+
// QR Code needs exactly one (not zero, two, etc.) mask applied.
|
|
222
|
+
applyMask(t) {
|
|
223
|
+
if (t < 0 || t > 7)
|
|
224
|
+
throw new RangeError("Mask value out of range");
|
|
225
|
+
for (let e = 0; e < this.size; e++)
|
|
226
|
+
for (let s = 0; s < this.size; s++) {
|
|
227
|
+
let o;
|
|
228
|
+
switch (t) {
|
|
229
|
+
case 0:
|
|
230
|
+
o = (s + e) % 2 === 0;
|
|
231
|
+
break;
|
|
232
|
+
case 1:
|
|
233
|
+
o = e % 2 === 0;
|
|
234
|
+
break;
|
|
235
|
+
case 2:
|
|
236
|
+
o = s % 3 === 0;
|
|
237
|
+
break;
|
|
238
|
+
case 3:
|
|
239
|
+
o = (s + e) % 3 === 0;
|
|
240
|
+
break;
|
|
241
|
+
case 4:
|
|
242
|
+
o = (Math.floor(s / 3) + Math.floor(e / 2)) % 2 === 0;
|
|
243
|
+
break;
|
|
244
|
+
case 5:
|
|
245
|
+
o = s * e % 2 + s * e % 3 === 0;
|
|
246
|
+
break;
|
|
247
|
+
case 6:
|
|
248
|
+
o = (s * e % 2 + s * e % 3) % 2 === 0;
|
|
249
|
+
break;
|
|
250
|
+
case 7:
|
|
251
|
+
o = ((s + e) % 2 + s * e % 3) % 2 === 0;
|
|
252
|
+
break;
|
|
253
|
+
default:
|
|
254
|
+
throw new Error("Unreachable");
|
|
255
|
+
}
|
|
256
|
+
!this.types[e][s] && o && (this.modules[e][s] = !this.modules[e][s]);
|
|
257
|
+
}
|
|
258
|
+
}
|
|
259
|
+
// Calculates and returns the penalty score based on state of this QR Code's current modules.
|
|
260
|
+
// This is used by the automatic mask choice algorithm to find the mask pattern that yields the lowest score.
|
|
261
|
+
getPenaltyScore() {
|
|
262
|
+
let t = 0;
|
|
263
|
+
for (let n = 0; n < this.size; n++) {
|
|
264
|
+
let i = !1, a = 0;
|
|
265
|
+
const l = [0, 0, 0, 0, 0, 0, 0];
|
|
266
|
+
for (let c = 0; c < this.size; c++)
|
|
267
|
+
this.modules[n][c] === i ? (a++, a === 5 ? t += Y : a > 5 && t++) : (this.finderPenaltyAddHistory(a, l), i || (t += this.finderPenaltyCountPatterns(l) * z), i = this.modules[n][c], a = 1);
|
|
268
|
+
t += this.finderPenaltyTerminateAndCount(i, a, l) * z;
|
|
269
|
+
}
|
|
270
|
+
for (let n = 0; n < this.size; n++) {
|
|
271
|
+
let i = !1, a = 0;
|
|
272
|
+
const l = [0, 0, 0, 0, 0, 0, 0];
|
|
273
|
+
for (let c = 0; c < this.size; c++)
|
|
274
|
+
this.modules[c][n] === i ? (a++, a === 5 ? t += Y : a > 5 && t++) : (this.finderPenaltyAddHistory(a, l), i || (t += this.finderPenaltyCountPatterns(l) * z), i = this.modules[c][n], a = 1);
|
|
275
|
+
t += this.finderPenaltyTerminateAndCount(i, a, l) * z;
|
|
276
|
+
}
|
|
277
|
+
for (let n = 0; n < this.size - 1; n++)
|
|
278
|
+
for (let i = 0; i < this.size - 1; i++) {
|
|
279
|
+
const a = this.modules[n][i];
|
|
280
|
+
a === this.modules[n][i + 1] && a === this.modules[n + 1][i] && a === this.modules[n + 1][i + 1] && (t += gt);
|
|
281
|
+
}
|
|
282
|
+
let e = 0;
|
|
283
|
+
for (const n of this.modules)
|
|
284
|
+
e = n.reduce((i, a) => i + (a ? 1 : 0), e);
|
|
285
|
+
const s = this.size * this.size, o = Math.ceil(Math.abs(e * 20 - s * 10) / s) - 1;
|
|
286
|
+
return t += o * pt, t;
|
|
287
|
+
}
|
|
288
|
+
/* -- Private helper functions -- */
|
|
289
|
+
// Returns an ascending list of positions of alignment patterns for this version number.
|
|
290
|
+
// Each position is in the range [0,177), and are used on both the x and y axes.
|
|
291
|
+
// This could be implemented as lookup table of 40 variable-length lists of integers.
|
|
292
|
+
getAlignmentPatternPositions() {
|
|
293
|
+
if (this.version === 1)
|
|
294
|
+
return [];
|
|
295
|
+
{
|
|
296
|
+
const t = Math.floor(this.version / 7) + 2, e = this.version === 32 ? 26 : Math.ceil((this.version * 4 + 4) / (t * 2 - 2)) * 2, s = [6];
|
|
297
|
+
for (let o = this.size - 7; s.length < t; o -= e)
|
|
298
|
+
s.splice(1, 0, o);
|
|
299
|
+
return s;
|
|
300
|
+
}
|
|
301
|
+
}
|
|
302
|
+
// Can only be called immediately after a light run is added, and
|
|
303
|
+
// returns either 0, 1, or 2. A helper function for getPenaltyScore().
|
|
304
|
+
finderPenaltyCountPatterns(t) {
|
|
305
|
+
const e = t[1], s = e > 0 && t[2] === e && t[3] === e * 3 && t[4] === e && t[5] === e;
|
|
306
|
+
return (s && t[0] >= e * 4 && t[6] >= e ? 1 : 0) + (s && t[6] >= e * 4 && t[0] >= e ? 1 : 0);
|
|
307
|
+
}
|
|
308
|
+
// Must be called at the end of a line (row or column) of modules. A helper function for getPenaltyScore().
|
|
309
|
+
finderPenaltyTerminateAndCount(t, e, s) {
|
|
310
|
+
return t && (this.finderPenaltyAddHistory(e, s), e = 0), e += this.size, this.finderPenaltyAddHistory(e, s), this.finderPenaltyCountPatterns(s);
|
|
311
|
+
}
|
|
312
|
+
// Pushes the given value to the front and drops the last value. A helper function for getPenaltyScore().
|
|
313
|
+
finderPenaltyAddHistory(t, e) {
|
|
314
|
+
e[0] === 0 && (t += this.size), e.pop(), e.unshift(t);
|
|
315
|
+
}
|
|
316
|
+
};
|
|
317
|
+
function w(r, t, e) {
|
|
318
|
+
if (t < 0 || t > 31 || r >>> t)
|
|
319
|
+
throw new RangeError("Value out of range");
|
|
320
|
+
for (let s = t - 1; s >= 0; s--)
|
|
321
|
+
e.push(r >>> s & 1);
|
|
322
|
+
}
|
|
323
|
+
function p(r, t) {
|
|
324
|
+
return (r >>> t & 1) !== 0;
|
|
325
|
+
}
|
|
326
|
+
class U {
|
|
327
|
+
// Creates a new QR Code segment with the given attributes and data.
|
|
328
|
+
// The character count (numChars) must agree with the mode and the bit buffer length,
|
|
329
|
+
// but the constraint isn't checked. The given bit buffer is cloned and stored.
|
|
330
|
+
constructor(t, e, s) {
|
|
331
|
+
if (this.mode = t, this.numChars = e, this.bitData = s, e < 0)
|
|
332
|
+
throw new RangeError("Invalid argument");
|
|
333
|
+
this.bitData = s.slice();
|
|
334
|
+
}
|
|
335
|
+
/* -- Methods -- */
|
|
336
|
+
// Returns a new copy of the data bits of this segment.
|
|
337
|
+
getData() {
|
|
338
|
+
return this.bitData.slice();
|
|
339
|
+
}
|
|
340
|
+
}
|
|
341
|
+
const bt = [1, 10, 12, 14], Mt = [2, 9, 11, 13], Et = [4, 8, 16, 16];
|
|
342
|
+
function Q(r, t) {
|
|
343
|
+
return r[Math.floor((t + 7) / 17) + 1];
|
|
344
|
+
}
|
|
345
|
+
function W(r) {
|
|
346
|
+
const t = [];
|
|
347
|
+
for (const e of r)
|
|
348
|
+
w(e, 8, t);
|
|
349
|
+
return new U(Et, r.length, t);
|
|
350
|
+
}
|
|
351
|
+
function vt(r) {
|
|
352
|
+
if (!Z(r))
|
|
353
|
+
throw new RangeError("String contains non-numeric characters");
|
|
354
|
+
const t = [];
|
|
355
|
+
for (let e = 0; e < r.length; ) {
|
|
356
|
+
const s = Math.min(r.length - e, 3);
|
|
357
|
+
w(Number.parseInt(r.substring(e, e + s), 10), s * 3 + 1, t), e += s;
|
|
358
|
+
}
|
|
359
|
+
return new U(bt, r.length, t);
|
|
360
|
+
}
|
|
361
|
+
function At(r) {
|
|
362
|
+
if (!J(r))
|
|
363
|
+
throw new RangeError("String contains unencodable characters in alphanumeric mode");
|
|
364
|
+
const t = [];
|
|
365
|
+
let e;
|
|
366
|
+
for (e = 0; e + 2 <= r.length; e += 2) {
|
|
367
|
+
let s = I.indexOf(r.charAt(e)) * 45;
|
|
368
|
+
s += I.indexOf(r.charAt(e + 1)), w(s, 11, t);
|
|
369
|
+
}
|
|
370
|
+
return e < r.length && w(I.indexOf(r.charAt(e)), 6, t), new U(Mt, r.length, t);
|
|
371
|
+
}
|
|
372
|
+
function yt(r) {
|
|
373
|
+
return r === "" ? [] : Z(r) ? [vt(r)] : J(r) ? [At(r)] : [W(Pt(r))];
|
|
374
|
+
}
|
|
375
|
+
function Z(r) {
|
|
376
|
+
return ut.test(r);
|
|
377
|
+
}
|
|
378
|
+
function J(r) {
|
|
379
|
+
return mt.test(r);
|
|
380
|
+
}
|
|
381
|
+
function zt(r, t) {
|
|
382
|
+
let e = 0;
|
|
383
|
+
for (const s of r) {
|
|
384
|
+
const o = Q(s.mode, t);
|
|
385
|
+
if (s.numChars >= 1 << o)
|
|
386
|
+
return Number.POSITIVE_INFINITY;
|
|
387
|
+
e += 4 + o + s.bitData.length;
|
|
388
|
+
}
|
|
389
|
+
return e;
|
|
390
|
+
}
|
|
391
|
+
function Pt(r) {
|
|
392
|
+
r = encodeURI(r);
|
|
393
|
+
const t = [];
|
|
394
|
+
for (let e = 0; e < r.length; e++)
|
|
395
|
+
r.charAt(e) !== "%" ? t.push(r.charCodeAt(e)) : (t.push(Number.parseInt(r.substring(e + 1, e + 3), 16)), e += 2);
|
|
396
|
+
return t;
|
|
397
|
+
}
|
|
398
|
+
function q(r) {
|
|
399
|
+
if (r < L || r > S)
|
|
400
|
+
throw new RangeError("Version number out of range");
|
|
401
|
+
let t = (16 * r + 128) * r + 64;
|
|
402
|
+
if (r >= 2) {
|
|
403
|
+
const e = Math.floor(r / 7) + 2;
|
|
404
|
+
t -= (25 * e - 10) * e - 55, r >= 7 && (t -= 36);
|
|
405
|
+
}
|
|
406
|
+
return t;
|
|
407
|
+
}
|
|
408
|
+
function C(r, t) {
|
|
409
|
+
return Math.floor(q(r) / 8) - H[t[0]][r] * X[t[0]][r];
|
|
410
|
+
}
|
|
411
|
+
function Ct(r) {
|
|
412
|
+
if (r < 1 || r > 255)
|
|
413
|
+
throw new RangeError("Degree out of range");
|
|
414
|
+
const t = [];
|
|
415
|
+
for (let s = 0; s < r - 1; s++)
|
|
416
|
+
t.push(0);
|
|
417
|
+
t.push(1);
|
|
418
|
+
let e = 1;
|
|
419
|
+
for (let s = 0; s < r; s++) {
|
|
420
|
+
for (let o = 0; o < t.length; o++)
|
|
421
|
+
t[o] = B(t[o], e), o + 1 < t.length && (t[o] ^= t[o + 1]);
|
|
422
|
+
e = B(e, 2);
|
|
423
|
+
}
|
|
424
|
+
return t;
|
|
425
|
+
}
|
|
426
|
+
function Nt(r, t) {
|
|
427
|
+
const e = t.map((s) => 0);
|
|
428
|
+
for (const s of r) {
|
|
429
|
+
const o = s ^ e.shift();
|
|
430
|
+
e.push(0), t.forEach((n, i) => e[i] ^= B(n, o));
|
|
431
|
+
}
|
|
432
|
+
return e;
|
|
433
|
+
}
|
|
434
|
+
function B(r, t) {
|
|
435
|
+
if (r >>> 8 || t >>> 8)
|
|
436
|
+
throw new RangeError("Byte out of range");
|
|
437
|
+
let e = 0;
|
|
438
|
+
for (let s = 7; s >= 0; s--)
|
|
439
|
+
e = e << 1 ^ (e >>> 7) * 285, e ^= (t >>> s & 1) * r;
|
|
440
|
+
return e;
|
|
441
|
+
}
|
|
442
|
+
function Rt(r, t, e = 1, s = 40, o = -1, n = !0) {
|
|
443
|
+
if (!(L <= e && e <= s && s <= S) || o < -1 || o > 7)
|
|
444
|
+
throw new RangeError("Invalid value");
|
|
445
|
+
let i, a;
|
|
446
|
+
for (i = e; ; i++) {
|
|
447
|
+
const d = C(i, t) * 8, f = zt(r, i);
|
|
448
|
+
if (f <= d) {
|
|
449
|
+
a = f;
|
|
450
|
+
break;
|
|
451
|
+
}
|
|
452
|
+
if (i >= s)
|
|
453
|
+
throw new RangeError("Data too long");
|
|
454
|
+
}
|
|
455
|
+
for (const d of [G, j, K])
|
|
456
|
+
n && a <= C(i, d) * 8 && (t = d);
|
|
457
|
+
const l = [];
|
|
458
|
+
for (const d of r) {
|
|
459
|
+
w(d.mode[0], 4, l), w(d.numChars, Q(d.mode, i), l);
|
|
460
|
+
for (const f of d.getData())
|
|
461
|
+
l.push(f);
|
|
462
|
+
}
|
|
463
|
+
const c = C(i, t) * 8;
|
|
464
|
+
w(0, Math.min(4, c - l.length), l), w(0, (8 - l.length % 8) % 8, l);
|
|
465
|
+
for (let d = 236; l.length < c; d ^= 253)
|
|
466
|
+
w(d, 8, l);
|
|
467
|
+
const h = Array.from({ length: Math.ceil(l.length / 8) }, () => 0);
|
|
468
|
+
return l.forEach((d, f) => h[f >>> 3] |= d << 7 - (f & 7)), new wt(i, t, h, o);
|
|
469
|
+
}
|
|
470
|
+
function _t(r, t) {
|
|
471
|
+
var d;
|
|
472
|
+
const {
|
|
473
|
+
ecc: e = "L",
|
|
474
|
+
boostEcc: s = !1,
|
|
475
|
+
minVersion: o = 1,
|
|
476
|
+
maxVersion: n = 40,
|
|
477
|
+
maskPattern: i = -1,
|
|
478
|
+
border: a = 1
|
|
479
|
+
} = t || {}, l = typeof r == "string" ? yt(r) : Array.isArray(r) ? [W(r)] : void 0;
|
|
480
|
+
if (!l)
|
|
481
|
+
throw new Error(`uqr only supports encoding string and binary data, but got: ${typeof r}`);
|
|
482
|
+
const c = Rt(
|
|
483
|
+
l,
|
|
484
|
+
ht[e],
|
|
485
|
+
o,
|
|
486
|
+
n,
|
|
487
|
+
i,
|
|
488
|
+
s
|
|
489
|
+
), h = kt({
|
|
490
|
+
version: c.version,
|
|
491
|
+
maskPattern: c.mask,
|
|
492
|
+
size: c.size,
|
|
493
|
+
data: c.modules,
|
|
494
|
+
types: c.types
|
|
495
|
+
}, a);
|
|
496
|
+
return t != null && t.invert && (h.data = h.data.map((f) => f.map((m) => !m))), (d = t == null ? void 0 : t.onEncoded) == null || d.call(t, h), h;
|
|
497
|
+
}
|
|
498
|
+
function kt(r, t = 1) {
|
|
499
|
+
if (!t)
|
|
500
|
+
return r;
|
|
501
|
+
const { size: e } = r, s = e + t * 2;
|
|
502
|
+
r.size = s, r.data.forEach((n) => {
|
|
503
|
+
for (let i = 0; i < t; i++)
|
|
504
|
+
n.unshift(!1), n.push(!1);
|
|
505
|
+
});
|
|
506
|
+
for (let n = 0; n < t; n++)
|
|
507
|
+
r.data.unshift(Array.from({ length: s }, (i) => !1)), r.data.push(Array.from({ length: s }, (i) => !1));
|
|
508
|
+
const o = M.Border;
|
|
509
|
+
r.types.forEach((n) => {
|
|
510
|
+
for (let i = 0; i < t; i++)
|
|
511
|
+
n.unshift(o), n.push(o);
|
|
512
|
+
});
|
|
513
|
+
for (let n = 0; n < t; n++)
|
|
514
|
+
r.types.unshift(Array.from({ length: s }, (i) => o)), r.types.push(Array.from({ length: s }, (i) => o));
|
|
515
|
+
return r;
|
|
516
|
+
}
|
|
517
|
+
let x = null;
|
|
518
|
+
function Ht(r) {
|
|
519
|
+
x = r;
|
|
520
|
+
}
|
|
521
|
+
function Ft(r, t) {
|
|
522
|
+
if (x) {
|
|
523
|
+
const o = x(r, { errorCorrectionLevel: t }), { size: n, data: i } = o.modules, a = [];
|
|
524
|
+
for (let l = 0; l < i.length; l++) a.push(i[l] === 1);
|
|
525
|
+
return { size: n, modules: a };
|
|
526
|
+
}
|
|
527
|
+
const e = _t(r, {
|
|
528
|
+
ecc: t,
|
|
529
|
+
border: 0,
|
|
530
|
+
boostEcc: !1
|
|
531
|
+
}), s = [];
|
|
532
|
+
for (const o of e.data) for (const n of o) s.push(n);
|
|
533
|
+
return { size: e.size, modules: s };
|
|
534
|
+
}
|
|
535
|
+
const It = O(
|
|
536
|
+
[
|
|
537
|
+
"ds:inline-flex ds:flex-col ds:items-center ds:shrink-0",
|
|
538
|
+
"ds:gap-[var(--spacing-sm)]",
|
|
539
|
+
// The matrix must never mirror in RTL — a mirrored QR is unscannable —
|
|
540
|
+
// so the wrapper pins LTR while caption/label text still flips via the
|
|
541
|
+
// logical `text-*` utilities. Mirrors Sparkline's `dir="ltr"` pin.
|
|
542
|
+
"ds:leading-none"
|
|
543
|
+
],
|
|
544
|
+
{
|
|
545
|
+
variants: {
|
|
546
|
+
variant: {
|
|
547
|
+
plain: "",
|
|
548
|
+
framed: [
|
|
549
|
+
"ds:bg-[var(--card)] ds:text-[var(--card-foreground)]",
|
|
550
|
+
"ds:border ds:border-[color:var(--border)]",
|
|
551
|
+
// Accessible theme thickens the boundary in step with Card / Stat.
|
|
552
|
+
"ds:[.theme-accessible_&]:border-2",
|
|
553
|
+
"ds:rounded-[var(--radius-lg)]",
|
|
554
|
+
"ds:p-[var(--spacing-md)]",
|
|
555
|
+
// Forced-colors: the UA strips background; keep a CanvasText
|
|
556
|
+
// boundary so the frame survives Windows High Contrast Mode.
|
|
557
|
+
"ds:forced-colors:border ds:forced-colors:border-[CanvasText]"
|
|
558
|
+
],
|
|
559
|
+
"with-caption": [
|
|
560
|
+
"ds:bg-[var(--card)] ds:text-[var(--card-foreground)]",
|
|
561
|
+
"ds:border ds:border-[color:var(--border)]",
|
|
562
|
+
"ds:[.theme-accessible_&]:border-2",
|
|
563
|
+
"ds:rounded-[var(--radius-lg)]",
|
|
564
|
+
"ds:p-[var(--spacing-md)]",
|
|
565
|
+
"ds:forced-colors:border ds:forced-colors:border-[CanvasText]"
|
|
566
|
+
]
|
|
567
|
+
},
|
|
568
|
+
// Edge length of the matrix box, driven by dedicated tokens
|
|
569
|
+
// (`--qr-code-size-*`, parallel to `--logo-size-*`). The token owner
|
|
570
|
+
// controls the scale and the accessible theme can lift it; the
|
|
571
|
+
// var() fallback is only a graceful default so the box renders before
|
|
572
|
+
// those token rows land — the token wins whenever it is defined.
|
|
573
|
+
size: {
|
|
574
|
+
sm: "ds:[--qr-edge:var(--qr-code-size-sm,8rem)]",
|
|
575
|
+
md: "ds:[--qr-edge:var(--qr-code-size-md,12rem)]",
|
|
576
|
+
lg: "ds:[--qr-edge:var(--qr-code-size-lg,16rem)]"
|
|
577
|
+
},
|
|
578
|
+
tone: {
|
|
579
|
+
default: "",
|
|
580
|
+
// Light modules on a dark quiet zone. The chrome inverts via tokens;
|
|
581
|
+
// the matrix colours themselves are swapped in the SVG (scanner
|
|
582
|
+
// constraint — see the literal note below).
|
|
583
|
+
inverted: ""
|
|
584
|
+
}
|
|
585
|
+
},
|
|
586
|
+
defaultVariants: { variant: "framed", size: "md", tone: "default" }
|
|
587
|
+
}
|
|
588
|
+
), qt = O(
|
|
589
|
+
[
|
|
590
|
+
"type-body-sm",
|
|
591
|
+
"ds:text-[color:var(--card-foreground)]",
|
|
592
|
+
// Caption flips with reading direction; the matrix above stays LTR.
|
|
593
|
+
"ds:text-center"
|
|
594
|
+
],
|
|
595
|
+
{
|
|
596
|
+
variants: {
|
|
597
|
+
tone: {
|
|
598
|
+
default: "",
|
|
599
|
+
inverted: ""
|
|
600
|
+
}
|
|
601
|
+
},
|
|
602
|
+
defaultVariants: { tone: "default" }
|
|
603
|
+
}
|
|
604
|
+
), Bt = O(
|
|
605
|
+
[
|
|
606
|
+
"ds:pointer-events-none ds:absolute ds:inset-0 ds:m-auto",
|
|
607
|
+
"ds:flex ds:items-center ds:justify-center",
|
|
608
|
+
"ds:rounded-[var(--radius-sm)] ds:p-[var(--spacing-2xs)]",
|
|
609
|
+
"ds:bg-[var(--background)]",
|
|
610
|
+
// Clamp to the published LOGO_EDGE_FRACTION of the matrix edge.
|
|
611
|
+
"ds:[block-size:calc(var(--qr-edge)*var(--qr-logo-edge))]",
|
|
612
|
+
"ds:[inline-size:calc(var(--qr-edge)*var(--qr-logo-edge))]",
|
|
613
|
+
// The mark/custom node fills the padded knockout box.
|
|
614
|
+
"ds:[&>*]:h-full ds:[&>*]:w-full",
|
|
615
|
+
"ds:[&>*]:max-h-full ds:[&>*]:max-w-full"
|
|
616
|
+
],
|
|
617
|
+
{
|
|
618
|
+
variants: {
|
|
619
|
+
tone: {
|
|
620
|
+
default: "ds:text-[color:var(--primary)]",
|
|
621
|
+
inverted: "ds:text-[color:var(--foreground)]"
|
|
622
|
+
}
|
|
623
|
+
},
|
|
624
|
+
defaultVariants: { tone: "default" }
|
|
625
|
+
}
|
|
626
|
+
), P = 4, xt = "ds:[--qr-logo-edge:0.22]", Ot = /* @__PURE__ */ b(ct, { "aria-hidden": !0, focusable: "false" });
|
|
627
|
+
function Lt(r, t) {
|
|
628
|
+
if (!r) return null;
|
|
629
|
+
try {
|
|
630
|
+
return Ft(r, t);
|
|
631
|
+
} catch {
|
|
632
|
+
return null;
|
|
633
|
+
}
|
|
634
|
+
}
|
|
635
|
+
const St = nt(
|
|
636
|
+
({
|
|
637
|
+
value: r,
|
|
638
|
+
variant: t = "framed",
|
|
639
|
+
size: e = "md",
|
|
640
|
+
tone: s = "default",
|
|
641
|
+
errorCorrectionLevel: o,
|
|
642
|
+
logo: n,
|
|
643
|
+
caption: i,
|
|
644
|
+
quietZone: a = P,
|
|
645
|
+
label: l,
|
|
646
|
+
decorative: c,
|
|
647
|
+
className: h,
|
|
648
|
+
id: d,
|
|
649
|
+
...f
|
|
650
|
+
}, m) => {
|
|
651
|
+
const { t: u } = at(), y = n !== !1, N = y ? n ?? Ot : null, R = o ?? (y ? "H" : "M"), g = it(() => Lt(r, R), [r, R]), _ = Math.max(P, Math.floor(a)), tt = g ? l ? u("qrCode.ariaLabelNamed", { label: l }) : u("qrCode.ariaLabel") : u("qrCode.empty"), et = c ? { role: "presentation", "aria-hidden": !0 } : { role: "img", "aria-label": tt }, T = t === "with-caption" ? i ?? u("qrCode.caption") : void 0, st = s === "inverted" ? "#fff" : "#000", V = s === "inverted" ? "#000" : "#fff", D = [];
|
|
652
|
+
let k = `0 0 ${(P * 2 + 1) * 1} ${(P * 2 + 1) * 1}`;
|
|
653
|
+
if (g) {
|
|
654
|
+
const $ = g.size + _ * 2;
|
|
655
|
+
k = `0 0 ${$} ${$}`;
|
|
656
|
+
for (let E = 0; E < g.size; E++)
|
|
657
|
+
for (let v = 0; v < g.size; v++)
|
|
658
|
+
g.modules[E * g.size + v] && D.push(
|
|
659
|
+
/* @__PURE__ */ b(
|
|
660
|
+
"rect",
|
|
661
|
+
{
|
|
662
|
+
x: v + _,
|
|
663
|
+
y: E + _,
|
|
664
|
+
width: 1,
|
|
665
|
+
height: 1,
|
|
666
|
+
fill: st
|
|
667
|
+
},
|
|
668
|
+
`${E}-${v}`
|
|
669
|
+
)
|
|
670
|
+
);
|
|
671
|
+
}
|
|
672
|
+
return lt(dt, r, d), /* @__PURE__ */ F(
|
|
673
|
+
"div",
|
|
674
|
+
{
|
|
675
|
+
ref: m,
|
|
676
|
+
...et,
|
|
677
|
+
...f,
|
|
678
|
+
id: d,
|
|
679
|
+
dir: "ltr",
|
|
680
|
+
"data-component": "qr-code",
|
|
681
|
+
"data-component-id": d,
|
|
682
|
+
"data-tone": s,
|
|
683
|
+
"data-ec": R,
|
|
684
|
+
"data-logo": N ? "true" : "false",
|
|
685
|
+
className: It({ variant: t, size: e, tone: s, className: h }),
|
|
686
|
+
children: [
|
|
687
|
+
/* @__PURE__ */ F(
|
|
688
|
+
"div",
|
|
689
|
+
{
|
|
690
|
+
className: `ds:relative ds:w-[var(--qr-edge)] ds:h-[var(--qr-edge)] ds:max-w-full ${xt}`,
|
|
691
|
+
children: [
|
|
692
|
+
g ? /* @__PURE__ */ F(
|
|
693
|
+
"svg",
|
|
694
|
+
{
|
|
695
|
+
"aria-hidden": "true",
|
|
696
|
+
focusable: "false",
|
|
697
|
+
viewBox: k,
|
|
698
|
+
shapeRendering: "crispEdges",
|
|
699
|
+
className: "ds:block ds:h-full ds:w-full",
|
|
700
|
+
children: [
|
|
701
|
+
/* @__PURE__ */ b("rect", { x: 0, y: 0, width: "100%", height: "100%", fill: V }),
|
|
702
|
+
D
|
|
703
|
+
]
|
|
704
|
+
}
|
|
705
|
+
) : /* @__PURE__ */ b(
|
|
706
|
+
"svg",
|
|
707
|
+
{
|
|
708
|
+
"aria-hidden": "true",
|
|
709
|
+
focusable: "false",
|
|
710
|
+
viewBox: k,
|
|
711
|
+
className: "ds:block ds:h-full ds:w-full",
|
|
712
|
+
children: /* @__PURE__ */ b(
|
|
713
|
+
"rect",
|
|
714
|
+
{
|
|
715
|
+
x: 0,
|
|
716
|
+
y: 0,
|
|
717
|
+
width: "100%",
|
|
718
|
+
height: "100%",
|
|
719
|
+
fill: V,
|
|
720
|
+
className: "ds:opacity-0"
|
|
721
|
+
}
|
|
722
|
+
)
|
|
723
|
+
}
|
|
724
|
+
),
|
|
725
|
+
g && N ? /* @__PURE__ */ b(
|
|
726
|
+
"span",
|
|
727
|
+
{
|
|
728
|
+
"aria-hidden": "true",
|
|
729
|
+
"data-slot": "qr-center-logo",
|
|
730
|
+
className: Bt({ tone: s }),
|
|
731
|
+
children: N
|
|
732
|
+
}
|
|
733
|
+
) : null
|
|
734
|
+
]
|
|
735
|
+
}
|
|
736
|
+
),
|
|
737
|
+
T ? /* @__PURE__ */ b("p", { className: qt({ tone: s }), children: T }) : null
|
|
738
|
+
]
|
|
739
|
+
}
|
|
740
|
+
);
|
|
741
|
+
}
|
|
742
|
+
);
|
|
743
|
+
St.displayName = "QrCode";
|
|
744
|
+
export {
|
|
745
|
+
St as Q,
|
|
746
|
+
Ft as c,
|
|
747
|
+
dt as q,
|
|
748
|
+
Ht as s
|
|
749
|
+
};
|
|
750
|
+
//# sourceMappingURL=qr-code-DOJs4suh.js.map
|