@esri/calcite-components 5.1.0-next.4 → 5.1.0-next.41
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/cdn/{CAAZHUX4.js → 24MYDDCX.js} +1 -1
- package/dist/cdn/2CMEG656.js +2 -0
- package/dist/cdn/{SYSNPKVM.js → 2ERRVHOG.js} +1 -1
- package/dist/cdn/{5WKPS2ZT.js → 2FA462GH.js} +1 -1
- package/dist/cdn/2HNLUEFE.js +2 -0
- package/dist/cdn/{3W4NT367.js → 2S7YK3XB.js} +1 -1
- package/dist/cdn/2ZVRANSV.js +2 -0
- package/dist/cdn/3JPPSAVC.js +2 -0
- package/dist/cdn/{5TWM6GKK.js → 3PMEQAA4.js} +1 -1
- package/dist/cdn/3Z3BLSQV.js +2 -0
- package/dist/cdn/45PPV4KB.js +2 -0
- package/dist/cdn/{HRUVPNCI.js → 4BN3NFQE.js} +1 -1
- package/dist/cdn/{X7JEHH2B.js → 4EQVX3RN.js} +1 -1
- package/dist/cdn/4JQR5BFT.js +2 -0
- package/dist/cdn/{EW6277QZ.js → 4LF7JOWB.js} +1 -1
- package/dist/cdn/4R2OUXIA.js +2 -0
- package/dist/cdn/4RK74RAX.js +2 -0
- package/dist/cdn/{F7XISEIT.js → 4Y2EOU6I.js} +1 -1
- package/dist/cdn/{RRHN2PDB.js → 564OQMMG.js} +1 -1
- package/dist/cdn/{WR6QBFCR.js → 5DNRIF2T.js} +1 -1
- package/dist/cdn/5LFL3RZM.js +2 -0
- package/dist/cdn/{RROGXGP5.js → 5W3NUC35.js} +1 -1
- package/dist/cdn/{AYPT6VGV.js → 5XXHCJWT.js} +1 -1
- package/dist/cdn/{UTFS3HNB.js → 5YJHDAMC.js} +1 -1
- package/dist/cdn/{FAHLSHDH.js → 6ALR2RKE.js} +1 -1
- package/dist/cdn/{HXS3PD57.js → 6FYE5EO4.js} +1 -1
- package/dist/cdn/{DFXECQ6Z.js → 6HUNPYIU.js} +1 -1
- package/dist/cdn/6IXX24B5.js +2 -0
- package/dist/cdn/6OIJRLWE.js +2 -0
- package/dist/cdn/6OJ75BQL.js +2 -0
- package/dist/cdn/6W5UQMJB.js +2 -0
- package/dist/cdn/6WINJYQB.js +2 -0
- package/dist/cdn/{XDOFVA4S.js → 7FDVLRYA.js} +1 -1
- package/dist/cdn/{R6D5F2V7.js → 7MRRY2FG.js} +1 -1
- package/dist/cdn/7ZM7AHRH.js +2 -0
- package/dist/cdn/A3EVLDK2.js +2 -0
- package/dist/cdn/ABWDY3S3.js +2 -0
- package/dist/cdn/{GM6FZWSL.js → AGJOJXT7.js} +1 -1
- package/dist/cdn/AGT4E2MR.js +2 -0
- package/dist/cdn/AKNE222R.js +2 -0
- package/dist/cdn/AMBU24RT.js +2 -0
- package/dist/cdn/B5HEG3NU.js +2 -0
- package/dist/cdn/B6IJE67V.js +2 -0
- package/dist/cdn/{7DA7BZM3.js → B74NISG7.js} +1 -1
- package/dist/cdn/C3ZMZ6DZ.js +2 -0
- package/dist/cdn/CKN7KBBX.js +2 -0
- package/dist/cdn/{LGKOEBZ4.js → CQTKLBEA.js} +1 -1
- package/dist/cdn/CUEFJU5M.js +2 -0
- package/dist/cdn/CX6NYW6U.js +2 -0
- package/dist/cdn/DAN2REQH.js +2 -0
- package/dist/cdn/{EHIAXJAL.js → DCWL5FUH.js} +1 -1
- package/dist/cdn/DM4TDFHC.js +2 -0
- package/dist/cdn/DNCPJ3MF.js +2 -0
- package/dist/cdn/DQX5RKEG.js +2 -0
- package/dist/cdn/DREDLWCT.js +2 -0
- package/dist/cdn/{MTNYIXZQ.js → DSZEUV6U.js} +1 -1
- package/dist/cdn/DVT6XGRX.js +2 -0
- package/dist/cdn/{VLGFWPBL.js → E4G4YBUV.js} +1 -1
- package/dist/cdn/EDZNJS2P.js +2 -0
- package/dist/cdn/{XLGGANFA.js → EYQJAUTS.js} +1 -1
- package/dist/cdn/F2OT6ZS7.js +2 -0
- package/dist/cdn/FNUCXO5T.js +2 -0
- package/dist/cdn/FO5KZ2B4.js +2 -0
- package/dist/cdn/{TCAGY7OI.js → FUAQVSMM.js} +1 -1
- package/dist/cdn/FUUTIPHY.js +2 -0
- package/dist/cdn/FVJPSUND.js +2 -0
- package/dist/cdn/{A4OYPK5D.js → FWIH6QX6.js} +1 -1
- package/dist/cdn/FXPBVOSU.js +2 -0
- package/dist/cdn/G2N5QQQC.js +2 -0
- package/dist/cdn/{Z22BRBT4.js → GA7UTPCH.js} +1 -1
- package/dist/cdn/GEWK7CNC.js +2 -0
- package/dist/cdn/{QOSBMGOZ.js → GF6UHDWG.js} +1 -1
- package/dist/cdn/{TLAXB6HU.js → GPB37IZK.js} +1 -1
- package/dist/cdn/GRAXNZVF.js +2 -0
- package/dist/cdn/{KKH2HVQW.js → I2C2U4EG.js} +1 -1
- package/dist/cdn/{CZYFEVKF.js → II5Q35BQ.js} +1 -1
- package/dist/cdn/J75WMG5K.js +2 -0
- package/dist/cdn/JGCSNM6I.js +2 -0
- package/dist/cdn/{BWUA5WU5.js → JIPOSCDQ.js} +1 -1
- package/dist/cdn/{MXRMT4RB.js → JMESEQBV.js} +1 -1
- package/dist/cdn/{HCJDTU7F.js → JQ2SIN67.js} +1 -1
- package/dist/cdn/{AMZPSRIA.js → JQWPSLVQ.js} +1 -1
- package/dist/cdn/{OVU2NGHU.js → JTIOKO5Z.js} +1 -1
- package/dist/cdn/K2J5VOGN.js +2 -0
- package/dist/cdn/K3TXMTAA.js +2 -0
- package/dist/cdn/KGN7LNPW.js +2 -0
- package/dist/cdn/{IFHMJCAE.js → KKCLSEGI.js} +1 -1
- package/dist/cdn/KT5ZBHYJ.js +2 -0
- package/dist/cdn/KZ26ANWU.js +2 -0
- package/dist/cdn/LQJ57QQT.js +2 -0
- package/dist/cdn/M2AV52WE.js +2 -0
- package/dist/cdn/M3F5QBVV.js +2 -0
- package/dist/cdn/MDIOA3TB.js +2 -0
- package/dist/cdn/MHY3UNM6.js +4 -0
- package/dist/cdn/MWRUONCP.js +2 -0
- package/dist/cdn/{3GV45XL7.js → MYDCGCGV.js} +1 -1
- package/dist/cdn/N7RECCIH.js +2 -0
- package/dist/cdn/{ED2GANBI.js → NBJNGORU.js} +1 -1
- package/dist/cdn/{ZZNRLKQQ.js → NPL2RAJH.js} +1 -1
- package/dist/cdn/{6IZMIAV2.js → NT3HJBBX.js} +1 -1
- package/dist/cdn/OW7J4OUX.js +2 -0
- package/dist/cdn/PQFBEGNW.js +2 -0
- package/dist/cdn/{LIJYENWJ.js → PS3RNTX7.js} +1 -1
- package/dist/cdn/{4MFRMO5M.js → Q43RHQO7.js} +1 -1
- package/dist/cdn/{ZIOXZBYF.js → QA5WKG2V.js} +1 -1
- package/dist/cdn/{YQY6DOSF.js → QB4POCYZ.js} +1 -1
- package/dist/cdn/{QKUQGG2M.js → QH3YRMT7.js} +1 -1
- package/dist/cdn/QKTDNEVV.js +2 -0
- package/dist/cdn/R6ION3EX.js +2 -0
- package/dist/cdn/{A22XLAKZ.js → RBNGWGBY.js} +3 -3
- package/dist/cdn/{IMOAPVVW.js → RGLX6ZUD.js} +1 -1
- package/dist/cdn/RLDG7JKF.js +2 -0
- package/dist/cdn/{HYYJZO6T.js → RUV4NSFE.js} +1 -1
- package/dist/cdn/RVXWIAKA.js +2 -0
- package/dist/cdn/S6W6A66Z.js +2 -0
- package/dist/cdn/{Z3IVC2AV.js → S7XRYSLC.js} +1 -1
- package/dist/cdn/{7TEW7OYZ.js → SOV3TN4E.js} +1 -1
- package/dist/cdn/{XYAZINKS.js → T5FTXYCC.js} +1 -1
- package/dist/cdn/T5OE6UXW.js +2 -0
- package/dist/cdn/T5QTQYSJ.js +2 -0
- package/dist/cdn/{GZNBU3BV.js → TDPJ5IO7.js} +1 -1
- package/dist/cdn/{5HQ3O27G.js → TIOSPWRC.js} +1 -1
- package/dist/cdn/{KVSU3DLB.js → TRGMORRC.js} +1 -1
- package/dist/cdn/TWAQRNOV.js +2 -0
- package/dist/cdn/U4RNEEDS.js +2 -0
- package/dist/cdn/U66XQE3L.js +2 -0
- package/dist/cdn/UWTFVQZZ.js +2 -0
- package/dist/cdn/V2V4HEZE.js +2 -0
- package/dist/cdn/{IOSK2I75.js → V3MIT2UF.js} +1 -1
- package/dist/cdn/{RA4KNUNM.js → V7U5TUOP.js} +1 -1
- package/dist/cdn/{7B4D4WJ2.js → VFQ6FGYV.js} +1 -1
- package/dist/cdn/{LHJSBAM5.js → VG74OPNP.js} +1 -1
- package/dist/cdn/VIV5RTB5.js +2 -0
- package/dist/cdn/VJUAN25O.js +2 -0
- package/dist/cdn/{CDTY6WOM.js → VS7QNWXR.js} +1 -1
- package/dist/cdn/WLMV5NME.js +2 -0
- package/dist/cdn/{GJE7FY35.js → XDZU4ZCM.js} +1 -1
- package/dist/cdn/{HXVXRVZW.js → XL6HVXTT.js} +1 -1
- package/dist/cdn/{5YROPSGB.js → XQ2A5CAB.js} +1 -1
- package/dist/cdn/XWE4Y4LH.js +2 -0
- package/dist/cdn/Y73IXKXQ.js +2 -0
- package/dist/cdn/YK2YMJCK.js +2 -0
- package/dist/cdn/YZZ2SHC2.js +2 -0
- package/dist/cdn/{QBLAE2O5.js → Z3PR5L6P.js} +1 -1
- package/dist/cdn/{MJCRT7H4.js → ZDXIPCCV.js} +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.ar.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.bg.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.bs.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.ca.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.cs.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.da.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.de.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.el.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.en.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.es.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.et.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.fi.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.fr.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.he.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.hr.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.hu.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.id.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.it.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.ja.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.ko.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.lt.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.lv.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.nl.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.no.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.pl.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.pt-BR.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.pt-PT.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.ro.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.ru.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.sk.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.sl.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.sr.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.sv.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.th.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.tr.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.uk.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.vi.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.zh-CN.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.zh-HK.json +1 -1
- package/dist/cdn/assets/combobox/t9n/messages.zh-TW.json +1 -1
- package/dist/cdn/assets/icon/arcgisQuickcapture16.json +1 -0
- package/dist/cdn/assets/icon/arcgisQuickcapture24.json +1 -0
- package/dist/cdn/assets/icon/arcgisQuickcapture32.json +1 -0
- package/dist/cdn/assets/icon/arcgisSurvey12316.json +1 -0
- package/dist/cdn/assets/icon/arcgisSurvey12324.json +1 -0
- package/dist/cdn/assets/icon/arcgisSurvey12332.json +1 -0
- package/dist/cdn/assets/icon/gpsReceiver16.json +1 -0
- package/dist/cdn/assets/icon/gpsReceiver24.json +1 -0
- package/dist/cdn/assets/icon/gpsReceiver32.json +1 -0
- package/dist/cdn/assets/icon/layerStreamSetting16.json +1 -0
- package/dist/cdn/assets/icon/layerStreamSetting24.json +1 -0
- package/dist/cdn/assets/icon/layerStreamSetting32.json +1 -0
- package/dist/cdn/assets/icon/publish16.json +1 -0
- package/dist/cdn/assets/icon/publish24.json +1 -0
- package/dist/cdn/assets/icon/publish32.json +1 -0
- package/dist/cdn/assets/icon/totalStation16.json +1 -0
- package/dist/cdn/assets/icon/totalStation24.json +1 -0
- package/dist/cdn/assets/icon/totalStation32.json +1 -0
- package/dist/cdn/assets/icon/velocityServer16.json +1 -0
- package/dist/cdn/assets/icon/velocityServer24.json +1 -0
- package/dist/cdn/assets/icon/velocityServer32.json +1 -0
- package/dist/cdn/index.js +2 -2
- package/dist/cdn/main.css +1 -1
- package/dist/chunks/ClearButton.js +16 -0
- package/dist/chunks/ExpandToggle.js +4 -5
- package/dist/chunks/Heading.js +3 -3
- package/dist/chunks/dom.js +63 -49
- package/dist/chunks/floating-ui.js +3 -6
- package/dist/chunks/label.js +1 -1
- package/dist/chunks/locale.js +29 -12
- package/dist/chunks/manager.js +505 -0
- package/dist/chunks/openCloseComponent.js +1 -1
- package/dist/chunks/resources5.js +2 -1
- package/dist/chunks/resources6.js +2 -0
- package/dist/chunks/runtime.js +4 -4
- package/dist/chunks/useFocusTrap.js +22 -1
- package/dist/chunks/useForm.js +294 -0
- package/dist/chunks/useFormTrigger.js +25 -0
- package/dist/chunks/useSetFocus.js +1 -1
- package/dist/chunks/{sortableComponent.js → useSortable.js} +70 -44
- package/dist/chunks/utils2.js +1 -1
- package/dist/components/calcite-accordion-item/customElement.d.ts +6 -6
- package/dist/components/calcite-accordion-item/customElement.js +4 -3
- package/dist/components/calcite-action/customElement.d.ts +14 -12
- package/dist/components/calcite-action/customElement.js +8 -14
- package/dist/components/calcite-action-bar/customElement.d.ts +12 -3
- package/dist/components/calcite-action-bar/customElement.js +43 -15
- package/dist/components/calcite-action-group/customElement.d.ts +6 -6
- package/dist/components/calcite-action-menu/customElement.d.ts +2 -2
- package/dist/components/calcite-action-pad/customElement.d.ts +3 -3
- package/dist/components/calcite-action-pad/customElement.js +5 -3
- package/dist/components/calcite-alert/customElement.d.ts +2 -2
- package/dist/components/calcite-alert/customElement.js +2 -2
- package/dist/components/calcite-autocomplete/customElement.d.ts +16 -13
- package/dist/components/calcite-autocomplete/customElement.js +23 -32
- package/dist/components/calcite-autocomplete-item/customElement.d.ts +6 -0
- package/dist/components/calcite-autocomplete-item/customElement.js +9 -4
- package/dist/components/calcite-avatar/customElement.js +1 -1
- package/dist/components/calcite-block/customElement.d.ts +5 -5
- package/dist/components/calcite-block/customElement.js +2 -2
- package/dist/components/calcite-block-group/customElement.d.ts +1 -1
- package/dist/components/calcite-block-group/customElement.js +5 -12
- package/dist/components/calcite-block-group/interfaces.d.ts +2 -6
- package/dist/components/calcite-block-section/customElement.d.ts +1 -1
- package/dist/components/calcite-button/customElement.d.ts +6 -6
- package/dist/components/calcite-button/customElement.js +11 -23
- package/dist/components/calcite-card/customElement.d.ts +4 -4
- package/dist/components/calcite-card/customElement.js +5 -3
- package/dist/components/calcite-card-group/customElement.d.ts +9 -3
- package/dist/components/calcite-card-group/customElement.js +11 -1
- package/dist/components/calcite-carousel/customElement.d.ts +1 -1
- package/dist/components/calcite-carousel/customElement.js +27 -25
- package/dist/components/calcite-checkbox/customElement.d.ts +4 -5
- package/dist/components/calcite-checkbox/customElement.js +10 -23
- package/dist/components/calcite-chip/customElement.d.ts +2 -2
- package/dist/components/calcite-chip/customElement.js +2 -2
- package/dist/components/calcite-chip-group/customElement.d.ts +1 -1
- package/dist/components/calcite-chip-group/customElement.js +1 -1
- package/dist/components/calcite-color-picker/customElement.d.ts +2 -2
- package/dist/components/calcite-color-picker/customElement.js +4 -2
- package/dist/components/calcite-color-picker-hex-input/customElement.d.ts +1 -1
- package/dist/components/calcite-color-picker-swatch/customElement.d.ts +1 -1
- package/dist/components/calcite-color-picker-swatch/customElement.js +1 -1
- package/dist/components/calcite-combobox/customElement.d.ts +16 -6
- package/dist/components/calcite-combobox/customElement.js +189 -106
- package/dist/components/calcite-combobox/index.js +2 -1
- package/dist/components/calcite-combobox-item/customElement.d.ts +1 -1
- package/dist/components/calcite-combobox-item/customElement.js +10 -4
- package/dist/components/calcite-date-picker/customElement.d.ts +1 -1
- package/dist/components/calcite-date-picker-day/customElement.d.ts +1 -1
- package/dist/components/calcite-date-picker-month/customElement.js +1 -1
- package/dist/components/calcite-date-picker-month-header/customElement.js +1 -1
- package/dist/components/calcite-dialog/customElement.d.ts +8 -6
- package/dist/components/calcite-dialog/customElement.js +5 -3
- package/dist/components/calcite-dropdown/customElement.d.ts +15 -5
- package/dist/components/calcite-dropdown/customElement.js +168 -90
- package/dist/components/calcite-dropdown-item/customElement.d.ts +2 -2
- package/dist/components/calcite-dropdown-item/customElement.js +14 -32
- package/dist/components/calcite-fab/customElement.d.ts +1 -1
- package/dist/components/calcite-filter/customElement.d.ts +1 -1
- package/dist/components/calcite-flow/customElement.d.ts +1 -1
- package/dist/components/calcite-flow-item/customElement.d.ts +9 -7
- package/dist/components/calcite-flow-item/customElement.js +6 -4
- package/dist/components/calcite-handle/customElement.d.ts +1 -1
- package/dist/components/calcite-icon/customElement.d.ts +1 -1
- package/dist/components/calcite-icon/customElement.js +4 -3
- package/dist/components/calcite-inline-editable/customElement.d.ts +1 -1
- package/dist/components/calcite-inline-editable/customElement.js +1 -1
- package/dist/components/calcite-input/customElement.d.ts +17 -18
- package/dist/components/calcite-input/customElement.js +30 -52
- package/dist/components/calcite-input/index.js +1 -0
- package/dist/components/calcite-input-date-picker/customElement.d.ts +6 -7
- package/dist/components/calcite-input-date-picker/customElement.js +34 -28
- package/dist/components/calcite-input-message/customElement.d.ts +1 -1
- package/dist/components/calcite-input-message/customElement.js +1 -1
- package/dist/components/calcite-input-number/customElement.d.ts +13 -14
- package/dist/components/calcite-input-number/customElement.js +26 -51
- package/dist/components/calcite-input-number/index.js +1 -0
- package/dist/components/calcite-input-text/customElement.d.ts +11 -12
- package/dist/components/calcite-input-text/customElement.js +20 -44
- package/dist/components/calcite-input-text/index.js +1 -0
- package/dist/components/calcite-input-time-picker/customElement.d.ts +6 -7
- package/dist/components/calcite-input-time-picker/customElement.js +14 -25
- package/dist/components/calcite-input-time-zone/customElement.d.ts +5 -6
- package/dist/components/calcite-input-time-zone/customElement.js +21 -19
- package/dist/components/calcite-link/customElement.d.ts +9 -9
- package/dist/components/calcite-link/customElement.js +31 -25
- package/dist/components/calcite-list/customElement.d.ts +1 -1
- package/dist/components/calcite-list/customElement.js +30 -11
- package/dist/components/calcite-list/interfaces.d.ts +2 -6
- package/dist/components/calcite-list-item/customElement.d.ts +2 -2
- package/dist/components/calcite-list-item/customElement.js +6 -4
- package/dist/components/calcite-list-item-group/customElement.js +1 -1
- package/dist/components/calcite-loader/customElement.d.ts +1 -1
- package/dist/components/calcite-menu/customElement.d.ts +1 -1
- package/dist/components/calcite-menu/customElement.js +2 -2
- package/dist/components/calcite-menu-item/customElement.d.ts +3 -3
- package/dist/components/calcite-menu-item/customElement.js +4 -2
- package/dist/components/calcite-meter/customElement.d.ts +7 -1
- package/dist/components/calcite-meter/customElement.js +4 -8
- package/dist/components/calcite-navigation/customElement.d.ts +2 -2
- package/dist/components/calcite-navigation-logo/customElement.d.ts +3 -3
- package/dist/components/calcite-navigation-user/customElement.d.ts +1 -1
- package/dist/components/calcite-notice/customElement.d.ts +3 -3
- package/dist/components/calcite-notice/customElement.js +2 -2
- package/dist/components/calcite-pagination/customElement.d.ts +1 -1
- package/dist/components/calcite-pagination/customElement.js +1 -1
- package/dist/components/calcite-panel/customElement.d.ts +11 -9
- package/dist/components/calcite-panel/customElement.js +20 -8
- package/dist/components/calcite-popover/customElement.d.ts +2 -2
- package/dist/components/calcite-popover/customElement.js +14 -175
- package/dist/components/calcite-progress/customElement.js +3 -2
- package/dist/components/calcite-radio-button/customElement.d.ts +1 -1
- package/dist/components/calcite-radio-button/customElement.js +173 -5
- package/dist/components/calcite-radio-button-group/customElement.d.ts +1 -1
- package/dist/components/calcite-rating/customElement.d.ts +3 -4
- package/dist/components/calcite-rating/customElement.js +12 -18
- package/dist/components/calcite-scrim/customElement.js +1 -1
- package/dist/components/calcite-segmented-control/customElement.d.ts +3 -4
- package/dist/components/calcite-segmented-control/customElement.js +13 -22
- package/dist/components/calcite-segmented-control-item/customElement.js +2 -2
- package/dist/components/calcite-select/customElement.d.ts +3 -4
- package/dist/components/calcite-select/customElement.js +8 -19
- package/dist/components/calcite-sheet/customElement.d.ts +2 -2
- package/dist/components/calcite-sheet/customElement.js +10 -11
- package/dist/components/calcite-shell/customElement.js +1 -1
- package/dist/components/calcite-shell-panel/customElement.d.ts +2 -2
- package/dist/components/calcite-shell-panel/customElement.js +11 -5
- package/dist/components/calcite-slider/customElement.d.ts +3 -4
- package/dist/components/calcite-slider/customElement.js +12 -22
- package/dist/components/calcite-sort-handle/customElement.d.ts +4 -4
- package/dist/components/calcite-sort-handle/customElement.js +44 -17
- package/dist/components/calcite-sortable-list/customElement.d.ts +1 -1
- package/dist/components/calcite-sortable-list/customElement.js +4 -4
- package/dist/components/calcite-split-button/customElement.d.ts +8 -8
- package/dist/components/calcite-stepper/customElement.d.ts +2 -2
- package/dist/components/calcite-stepper/customElement.js +30 -43
- package/dist/components/calcite-stepper-item/customElement.d.ts +1 -1
- package/dist/components/calcite-stepper-item/customElement.js +3 -9
- package/dist/components/calcite-swatch/customElement.d.ts +1 -1
- package/dist/components/calcite-swatch-group/customElement.js +1 -1
- package/dist/components/calcite-switch/customElement.d.ts +4 -4
- package/dist/components/calcite-switch/customElement.js +9 -8
- package/dist/components/calcite-tab/customElement.d.ts +1 -1
- package/dist/components/calcite-tab/customElement.js +2 -2
- package/dist/components/calcite-tab-nav/customElement.js +4 -2
- package/dist/components/calcite-tab-title/customElement.js +6 -4
- package/dist/components/calcite-table/customElement.js +1 -1
- package/dist/components/calcite-table-cell/customElement.d.ts +2 -2
- package/dist/components/calcite-table-cell/customElement.js +3 -2
- package/dist/components/calcite-table-header/customElement.d.ts +2 -2
- package/dist/components/calcite-table-row/customElement.d.ts +1 -1
- package/dist/components/calcite-tabs/customElement.js +1 -1
- package/dist/components/calcite-text-area/customElement.d.ts +13 -14
- package/dist/components/calcite-text-area/customElement.js +32 -37
- package/dist/components/calcite-tile/customElement.d.ts +1 -1
- package/dist/components/calcite-time-picker/customElement.d.ts +1 -1
- package/dist/components/calcite-time-picker/customElement.js +5 -4
- package/dist/components/calcite-tooltip/customElement.d.ts +15 -2
- package/dist/components/calcite-tooltip/customElement.js +27 -315
- package/dist/components/calcite-tree/customElement.js +1 -1
- package/dist/components/calcite-tree-item/customElement.js +5 -4
- package/dist/controllers/useSortable.d.ts +7 -0
- package/dist/docs/api.json +1 -1
- package/dist/docs/docs.json +1 -1
- package/dist/docs/supported-browsers.json +1 -1
- package/dist/docs/translations.json +1 -1
- package/dist/docs/vscode.css-custom-data.json +1 -1
- package/dist/docs/vscode.html-custom-data.json +1 -1
- package/dist/docs/web-types.json +1 -1
- package/dist/loader.js +25 -25
- package/dist/types/lumina.d.ts +6 -6
- package/dist/types/preact.d.ts +6 -6
- package/dist/types/react.d.ts +6 -6
- package/dist/types/stencil.d.ts +6 -6
- package/package.json +14 -13
- package/dist/cdn/256EMMKX.js +0 -2
- package/dist/cdn/2ZJ5ADD2.js +0 -2
- package/dist/cdn/37APBABQ.js +0 -2
- package/dist/cdn/3OIE2RR5.js +0 -2
- package/dist/cdn/3TCEXRVB.js +0 -2
- package/dist/cdn/43T3HPVW.js +0 -2
- package/dist/cdn/4ET37OQN.js +0 -2
- package/dist/cdn/4SJVPWEI.js +0 -2
- package/dist/cdn/6NGWODBG.js +0 -2
- package/dist/cdn/7CLOFSLV.js +0 -2
- package/dist/cdn/7CZHE7FZ.js +0 -2
- package/dist/cdn/7KCC74EE.js +0 -2
- package/dist/cdn/7WPF3NTF.js +0 -2
- package/dist/cdn/CPDXUV3S.js +0 -2
- package/dist/cdn/EIFNZZAD.js +0 -2
- package/dist/cdn/F7SGO63N.js +0 -2
- package/dist/cdn/FAOX7WLQ.js +0 -2
- package/dist/cdn/FCNCDBSI.js +0 -2
- package/dist/cdn/FDGUUC3D.js +0 -2
- package/dist/cdn/FRI4RPRX.js +0 -2
- package/dist/cdn/G6R56WT6.js +0 -2
- package/dist/cdn/GAUJK4Z7.js +0 -2
- package/dist/cdn/GDTRICJF.js +0 -2
- package/dist/cdn/GFZYTB3O.js +0 -2
- package/dist/cdn/GW7IPUQS.js +0 -2
- package/dist/cdn/HBVQ77SB.js +0 -2
- package/dist/cdn/HD23H6LX.js +0 -2
- package/dist/cdn/HVBNJRAQ.js +0 -2
- package/dist/cdn/I6CQ5UW5.js +0 -2
- package/dist/cdn/ILES2J66.js +0 -2
- package/dist/cdn/IR6Z2XSF.js +0 -2
- package/dist/cdn/IUAHSZQ6.js +0 -2
- package/dist/cdn/JKLX623E.js +0 -2
- package/dist/cdn/JLB2FYLL.js +0 -2
- package/dist/cdn/JRCEHRYP.js +0 -2
- package/dist/cdn/KNDQJ2XX.js +0 -2
- package/dist/cdn/L6F7C3O7.js +0 -2
- package/dist/cdn/LIZ5IMMJ.js +0 -2
- package/dist/cdn/LR57FDVO.js +0 -2
- package/dist/cdn/LRL6N22U.js +0 -2
- package/dist/cdn/LYKD5N65.js +0 -2
- package/dist/cdn/MASQZEFU.js +0 -2
- package/dist/cdn/MAXAPKJ5.js +0 -2
- package/dist/cdn/MQPFYNQR.js +0 -2
- package/dist/cdn/MUGKSK5F.js +0 -2
- package/dist/cdn/N6QRZM7N.js +0 -2
- package/dist/cdn/NQEVKT6K.js +0 -2
- package/dist/cdn/OS7NHPEF.js +0 -2
- package/dist/cdn/P7RXOG72.js +0 -2
- package/dist/cdn/P7U46JDU.js +0 -2
- package/dist/cdn/PBMFDSRI.js +0 -2
- package/dist/cdn/PS64W4X6.js +0 -2
- package/dist/cdn/Q52SIZ3L.js +0 -2
- package/dist/cdn/Q7WYXKFZ.js +0 -2
- package/dist/cdn/R3EE76WN.js +0 -2
- package/dist/cdn/R6YSSNOG.js +0 -2
- package/dist/cdn/RSCA2AM5.js +0 -2
- package/dist/cdn/S22OVJTO.js +0 -3
- package/dist/cdn/SBPWZDAB.js +0 -2
- package/dist/cdn/SFEXJ2YW.js +0 -2
- package/dist/cdn/SXVCUXNL.js +0 -2
- package/dist/cdn/TPXLAPIE.js +0 -2
- package/dist/cdn/TSZAQNPK.js +0 -2
- package/dist/cdn/U6LKEFFT.js +0 -2
- package/dist/cdn/UAADJQTQ.js +0 -2
- package/dist/cdn/ULBA6IRN.js +0 -2
- package/dist/cdn/UOIMVKXE.js +0 -2
- package/dist/cdn/V4KATS7H.js +0 -2
- package/dist/cdn/WAC3IAWB.js +0 -2
- package/dist/cdn/WJXZ7BPV.js +0 -2
- package/dist/cdn/XSSG2WBN.js +0 -2
- package/dist/cdn/YHGC7HRA.js +0 -2
- package/dist/cdn/YOYLPMEA.js +0 -2
- package/dist/cdn/YUJ33VWR.js +0 -2
- package/dist/cdn/Z53AVC5H.js +0 -2
- package/dist/cdn/ZQLGBHLZ.js +0 -2
- package/dist/cdn/ZXUITROT.js +0 -2
- package/dist/chunks/form.js +0 -268
- package/dist/chunks/input.js +0 -30
- package/dist/utils/form.d.ts +0 -3
- package/dist/utils/sortableComponent.d.ts +0 -7
|
@@ -0,0 +1,294 @@
|
|
|
1
|
+
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
+
import { makeGenericController, bypassReadOnly } from "@arcgis/lumina/controllers";
|
|
3
|
+
import { uncapitalize, kebabToPascal } from "@arcgis/toolkit/string";
|
|
4
|
+
import { r as isCalciteFocusable } from "./dom.js";
|
|
5
|
+
import "lit";
|
|
6
|
+
const minMaxStepTypes = ["date", "datetime-local", "month", "number", "range", "time", "week"];
|
|
7
|
+
const patternTypes = ["email", "password", "search", "tel", "text", "url"];
|
|
8
|
+
const minMaxLengthTypes = ["email", "password", "search", "tel", "text", "textarea", "url"];
|
|
9
|
+
function updateConstraintValidation(inputComponent, input, propName, matchesType) {
|
|
10
|
+
const attributeName = propName.toLowerCase();
|
|
11
|
+
const value = inputComponent[propName];
|
|
12
|
+
if (matchesType && value != null) {
|
|
13
|
+
input.setAttribute(attributeName, `${value}`);
|
|
14
|
+
} else {
|
|
15
|
+
input.removeAttribute(attributeName);
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
function syncInputDelegate(type, inputComponent, input) {
|
|
19
|
+
input.type = type;
|
|
20
|
+
const isMinMaxStepType = minMaxStepTypes.includes(type);
|
|
21
|
+
const numericInputComponent = inputComponent;
|
|
22
|
+
updateConstraintValidation(numericInputComponent, input, "min", isMinMaxStepType);
|
|
23
|
+
updateConstraintValidation(numericInputComponent, input, "max", isMinMaxStepType);
|
|
24
|
+
updateConstraintValidation(numericInputComponent, input, "step", isMinMaxStepType);
|
|
25
|
+
const isMinMaxLengthType = minMaxLengthTypes.includes(type);
|
|
26
|
+
const textualInputComponent = inputComponent;
|
|
27
|
+
updateConstraintValidation(textualInputComponent, input, "minLength", isMinMaxLengthType);
|
|
28
|
+
updateConstraintValidation(textualInputComponent, input, "maxLength", isMinMaxLengthType);
|
|
29
|
+
const isPatternType = patternTypes.includes(type);
|
|
30
|
+
updateConstraintValidation(textualInputComponent, input, "pattern", isPatternType);
|
|
31
|
+
}
|
|
32
|
+
function isSupportedType(type) {
|
|
33
|
+
const effectiveType = type === "textarea" ? "text" : type;
|
|
34
|
+
return minMaxStepTypes.includes(effectiveType) || patternTypes.includes(effectiveType) || minMaxLengthTypes.includes(effectiveType);
|
|
35
|
+
}
|
|
36
|
+
const joinableValueTypes = ["text", "email", "search", "hidden", "tel", "url"];
|
|
37
|
+
const allValid = Object.freeze({ validity: {}, validationMessage: "" });
|
|
38
|
+
function validate(input, value) {
|
|
39
|
+
if (!Array.isArray(value)) {
|
|
40
|
+
if (validateValue(input, value)) {
|
|
41
|
+
return allValid;
|
|
42
|
+
}
|
|
43
|
+
return {
|
|
44
|
+
validity: getValidityFlags(input.validity),
|
|
45
|
+
validationMessage: input.validationMessage
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
if (joinableValueTypes.includes(input.type)) {
|
|
49
|
+
if (validateValue(input, value.join(","))) {
|
|
50
|
+
return allValid;
|
|
51
|
+
}
|
|
52
|
+
return {
|
|
53
|
+
validity: getValidityFlags(input.validity),
|
|
54
|
+
validationMessage: input.validationMessage
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
const mergedValidity = {};
|
|
58
|
+
const validationMessages = [];
|
|
59
|
+
for (const item of value) {
|
|
60
|
+
if (validateValue(input, item)) {
|
|
61
|
+
continue;
|
|
62
|
+
}
|
|
63
|
+
Object.assign(mergedValidity, getValidityFlags(input.validity));
|
|
64
|
+
if (input.validationMessage) {
|
|
65
|
+
validationMessages.push(input.validationMessage);
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
return {
|
|
69
|
+
validity: mergedValidity,
|
|
70
|
+
validationMessage: validationMessages.join("; ")
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
function validateValue(inputDelegate, valueToValidate) {
|
|
74
|
+
inputDelegate.value = // file will throw if non-empty string is provided
|
|
75
|
+
inputDelegate.type === "file" || valueToValidate == null ? "" : String(valueToValidate);
|
|
76
|
+
return inputDelegate.validity.valid;
|
|
77
|
+
}
|
|
78
|
+
function getValidityFlags(validityState) {
|
|
79
|
+
const validityFlags = {};
|
|
80
|
+
for (const key in validityState) {
|
|
81
|
+
if (key !== "valid" && validityState[key]) {
|
|
82
|
+
validityFlags[key] = true;
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
return validityFlags;
|
|
86
|
+
}
|
|
87
|
+
const componentsWithInputEvent = [
|
|
88
|
+
"calcite-input",
|
|
89
|
+
"calcite-input-number",
|
|
90
|
+
"calcite-input-text",
|
|
91
|
+
"calcite-text-area"
|
|
92
|
+
];
|
|
93
|
+
function getClearValidationEventName(componentTag) {
|
|
94
|
+
const componentTagCamelCase = uncapitalize(kebabToPascal(componentTag));
|
|
95
|
+
return `${componentTagCamelCase}${componentsWithInputEvent.includes(componentTag) ? "Input" : "Change"}`;
|
|
96
|
+
}
|
|
97
|
+
function isFormComponentEl(el) {
|
|
98
|
+
return "form" in el && "name" in el && isCalciteFocusable(el);
|
|
99
|
+
}
|
|
100
|
+
function displayValidationMessage(component, { status, message, icon }) {
|
|
101
|
+
if ("status" in component) {
|
|
102
|
+
component.status = status;
|
|
103
|
+
}
|
|
104
|
+
if ("validationIcon" in component && typeof component.validationIcon !== "string") {
|
|
105
|
+
component.validationIcon = icon;
|
|
106
|
+
}
|
|
107
|
+
if ("validationMessage" in component && !component.validationMessage) {
|
|
108
|
+
component.validationMessage = message;
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
function syncInternalInput(component, input) {
|
|
112
|
+
const { disabled, required } = component;
|
|
113
|
+
input.disabled = disabled;
|
|
114
|
+
input.required = !!required;
|
|
115
|
+
if (isCheckable(component)) {
|
|
116
|
+
input.checked = component.checked;
|
|
117
|
+
} else if (isInputComponent(component, input)) {
|
|
118
|
+
syncInputDelegate(input.type, component, input);
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
function isCheckable(component) {
|
|
122
|
+
return "checked" in component;
|
|
123
|
+
}
|
|
124
|
+
function isInputComponent(component, input) {
|
|
125
|
+
return component && isSupportedType(input.type);
|
|
126
|
+
}
|
|
127
|
+
function focusFirstInvalidFormElement(form) {
|
|
128
|
+
const formElements = Array.from(form.elements);
|
|
129
|
+
requestAnimationFrame(() => {
|
|
130
|
+
const invalidEls = formElements.filter(
|
|
131
|
+
(el) => el.matches("[status=invalid]") && isFormComponentEl(el)
|
|
132
|
+
);
|
|
133
|
+
for (const el of invalidEls) {
|
|
134
|
+
if (el.validationMessage) {
|
|
135
|
+
el.setFocus();
|
|
136
|
+
break;
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
});
|
|
140
|
+
}
|
|
141
|
+
const useForm = (options) => {
|
|
142
|
+
return makeGenericController((component, controller) => {
|
|
143
|
+
let customValidityMessage = "";
|
|
144
|
+
let inputDelegate;
|
|
145
|
+
let lastAssociatedForm = null;
|
|
146
|
+
let effectiveInputType = options.inputType;
|
|
147
|
+
if (effectiveInputType) {
|
|
148
|
+
inputDelegate = document.createElement("input");
|
|
149
|
+
}
|
|
150
|
+
function invalidFormHandler(event) {
|
|
151
|
+
if (event.defaultPrevented) {
|
|
152
|
+
return;
|
|
153
|
+
}
|
|
154
|
+
event.preventDefault();
|
|
155
|
+
const form = event.currentTarget;
|
|
156
|
+
focusFirstInvalidFormElement(form);
|
|
157
|
+
}
|
|
158
|
+
function onFormReset() {
|
|
159
|
+
if ("status" in component) {
|
|
160
|
+
component.status = "idle";
|
|
161
|
+
}
|
|
162
|
+
if ("validationIcon" in component) {
|
|
163
|
+
component.validationIcon = false;
|
|
164
|
+
}
|
|
165
|
+
if ("validationMessage" in component) {
|
|
166
|
+
component.validationMessage = "";
|
|
167
|
+
}
|
|
168
|
+
if (isCheckable(component)) {
|
|
169
|
+
component.checked = component.defaultChecked;
|
|
170
|
+
}
|
|
171
|
+
component.value = component.defaultValue;
|
|
172
|
+
}
|
|
173
|
+
component.listen("luminaFormResetCallback", () => {
|
|
174
|
+
onFormReset();
|
|
175
|
+
});
|
|
176
|
+
component.listen("luminaFormAssociatedCallback", ({ detail: [form] }) => {
|
|
177
|
+
if (form) {
|
|
178
|
+
form.addEventListener("invalid", invalidFormHandler, { capture: true });
|
|
179
|
+
} else {
|
|
180
|
+
lastAssociatedForm?.removeEventListener("invalid", invalidFormHandler, { capture: true });
|
|
181
|
+
}
|
|
182
|
+
lastAssociatedForm = form;
|
|
183
|
+
});
|
|
184
|
+
function handleInvalidInput() {
|
|
185
|
+
const validationMsg = customValidityMessage || inputDelegate?.validationMessage || "";
|
|
186
|
+
component.el.dispatchEvent(
|
|
187
|
+
// allows users to set custom validation messages
|
|
188
|
+
new CustomEvent("calciteInvalid", { bubbles: true, composed: true })
|
|
189
|
+
);
|
|
190
|
+
displayValidationMessage(component, {
|
|
191
|
+
message: validationMsg,
|
|
192
|
+
icon: true,
|
|
193
|
+
status: "invalid"
|
|
194
|
+
});
|
|
195
|
+
const clearValidationEvent = getClearValidationEventName(component.el.tagName.toLowerCase());
|
|
196
|
+
component.listen(
|
|
197
|
+
clearValidationEvent,
|
|
198
|
+
() => {
|
|
199
|
+
if ("status" in component) {
|
|
200
|
+
component.status = "idle";
|
|
201
|
+
}
|
|
202
|
+
if ("validationIcon" in component && (!component.validationIcon || component.validationIcon === true)) {
|
|
203
|
+
component.validationIcon = false;
|
|
204
|
+
}
|
|
205
|
+
if ("validationMessage" in component && component.validationMessage === validationMsg) {
|
|
206
|
+
component.validationMessage = "";
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
{ once: true }
|
|
210
|
+
);
|
|
211
|
+
}
|
|
212
|
+
controller.onConnected(() => {
|
|
213
|
+
component.el.addEventListener("invalid", handleInvalidInput);
|
|
214
|
+
});
|
|
215
|
+
controller.onDisconnected(() => {
|
|
216
|
+
component.el.removeEventListener("invalid", handleInvalidInput);
|
|
217
|
+
});
|
|
218
|
+
controller.onUpdate((changes) => {
|
|
219
|
+
if (!component.hasUpdated) {
|
|
220
|
+
component.defaultValue = component.value;
|
|
221
|
+
if (isCheckable(component)) {
|
|
222
|
+
component.defaultChecked = component.checked;
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
if (changes.has("name") || changes.has("value") || isCheckable(component) && changes.has("checked")) {
|
|
226
|
+
component.elementInternals.setFormValue(getFormValue());
|
|
227
|
+
}
|
|
228
|
+
updateValidity();
|
|
229
|
+
});
|
|
230
|
+
function updateValidity() {
|
|
231
|
+
const { elementInternals } = component;
|
|
232
|
+
let validity = {};
|
|
233
|
+
let validationMessage = "";
|
|
234
|
+
if (inputDelegate) {
|
|
235
|
+
inputDelegate.type = effectiveInputType;
|
|
236
|
+
syncInternalInput(component, inputDelegate);
|
|
237
|
+
({ validity, validationMessage } = validate(inputDelegate, getComponentValue()));
|
|
238
|
+
}
|
|
239
|
+
if (customValidityMessage) {
|
|
240
|
+
validity = { ...validity, customError: true };
|
|
241
|
+
validationMessage = customValidityMessage;
|
|
242
|
+
}
|
|
243
|
+
elementInternals.setValidity(validity, validationMessage);
|
|
244
|
+
if ("validity" in component) {
|
|
245
|
+
bypassReadOnly(() => {
|
|
246
|
+
component.validity = elementInternals.validity;
|
|
247
|
+
});
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
function getComponentValue() {
|
|
251
|
+
if (options.getValue) {
|
|
252
|
+
return options.getValue();
|
|
253
|
+
}
|
|
254
|
+
return component.value;
|
|
255
|
+
}
|
|
256
|
+
function getFormValue() {
|
|
257
|
+
const value = getComponentValue();
|
|
258
|
+
if (Array.isArray(value)) {
|
|
259
|
+
const formData = new FormData();
|
|
260
|
+
value.forEach((value2) => formData.append(component.name, value2));
|
|
261
|
+
return formData;
|
|
262
|
+
}
|
|
263
|
+
if (isCheckable(component)) {
|
|
264
|
+
if (component.checked) {
|
|
265
|
+
return value || "on";
|
|
266
|
+
}
|
|
267
|
+
return null;
|
|
268
|
+
}
|
|
269
|
+
return value;
|
|
270
|
+
}
|
|
271
|
+
return {
|
|
272
|
+
get active() {
|
|
273
|
+
return !!component.elementInternals.form;
|
|
274
|
+
},
|
|
275
|
+
overrideDefaultValue: (value) => {
|
|
276
|
+
component.defaultValue = value;
|
|
277
|
+
},
|
|
278
|
+
overrideInputType: (type) => {
|
|
279
|
+
effectiveInputType = type;
|
|
280
|
+
updateValidity();
|
|
281
|
+
},
|
|
282
|
+
requestSubmit: () => {
|
|
283
|
+
component.elementInternals.form?.requestSubmit();
|
|
284
|
+
},
|
|
285
|
+
setCustomValidity: (message) => {
|
|
286
|
+
customValidityMessage = message;
|
|
287
|
+
updateValidity();
|
|
288
|
+
}
|
|
289
|
+
};
|
|
290
|
+
});
|
|
291
|
+
};
|
|
292
|
+
export {
|
|
293
|
+
useForm as u
|
|
294
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
+
import { makeGenericController } from "@arcgis/lumina/controllers";
|
|
3
|
+
const useFormTrigger = (options) => makeGenericController((component) => {
|
|
4
|
+
function clickHandler(event) {
|
|
5
|
+
const { form } = component.elementInternals;
|
|
6
|
+
if (event.defaultPrevented || component.disabled || options?.disabled?.() || !form || component.type === "button") {
|
|
7
|
+
return;
|
|
8
|
+
}
|
|
9
|
+
if (component.type === "submit") {
|
|
10
|
+
form.requestSubmit();
|
|
11
|
+
return;
|
|
12
|
+
}
|
|
13
|
+
form.reset();
|
|
14
|
+
}
|
|
15
|
+
component.listen("luminaFormAssociatedCallback", ({ detail: [form] }) => {
|
|
16
|
+
if (form) {
|
|
17
|
+
component.el.addEventListener("click", clickHandler);
|
|
18
|
+
} else {
|
|
19
|
+
component.el.removeEventListener("click", clickHandler);
|
|
20
|
+
}
|
|
21
|
+
});
|
|
22
|
+
});
|
|
23
|
+
export {
|
|
24
|
+
useFormTrigger as u
|
|
25
|
+
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
2
|
import { makeGenericController } from "@arcgis/lumina/controllers";
|
|
3
3
|
import { c as componentFocusable } from "./component.js";
|
|
4
|
-
import {
|
|
4
|
+
import { e as getRootNode, i as focusElement } from "./dom.js";
|
|
5
5
|
const useSetFocus = () => {
|
|
6
6
|
return makeGenericController((component, controller) => {
|
|
7
7
|
let abortController;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
+
import { makeGenericController } from "@arcgis/lumina/controllers";
|
|
2
3
|
import Sortable from "sortablejs";
|
|
3
4
|
const sortableComponentSet = /* @__PURE__ */ new Set();
|
|
4
5
|
const CSS = {
|
|
@@ -7,15 +8,17 @@ const CSS = {
|
|
|
7
8
|
dragClass: "calcite-sortable--drag",
|
|
8
9
|
fallbackClass: "calcite-sortable--fallback"
|
|
9
10
|
};
|
|
10
|
-
function
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
11
|
+
function onGlobalDragStart() {
|
|
12
|
+
Array.from(sortableComponentSet).forEach((component) => component.onGlobalDragStart());
|
|
13
|
+
}
|
|
14
|
+
function onGlobalDragEnd() {
|
|
15
|
+
Array.from(sortableComponentSet).forEach((component) => component.onGlobalDragEnd());
|
|
16
|
+
}
|
|
17
|
+
const globalDragState = { active: false };
|
|
18
|
+
function createSortable(component) {
|
|
16
19
|
const dataIdAttr = "id";
|
|
17
|
-
const { group, handleSelector: handle, dragSelector: draggable, sortDisabled } = component;
|
|
18
|
-
|
|
20
|
+
const { el, group, handleSelector: handle, dragSelector: draggable, sortDisabled } = component;
|
|
21
|
+
return Sortable.create(el, {
|
|
19
22
|
dataIdAttr,
|
|
20
23
|
swapThreshold: 0.5,
|
|
21
24
|
...CSS,
|
|
@@ -25,22 +28,26 @@ function connectSortableComponent(component) {
|
|
|
25
28
|
group: {
|
|
26
29
|
name: group,
|
|
27
30
|
...!!component.canPull && {
|
|
28
|
-
pull: (to, from, dragEl, { newDraggableIndex: newIndex, oldDraggableIndex: oldIndex }) =>
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
31
|
+
pull: (to, from, dragEl, { newDraggableIndex: newIndex, oldDraggableIndex: oldIndex }) => {
|
|
32
|
+
return component.canPull({
|
|
33
|
+
toEl: to.el,
|
|
34
|
+
fromEl: from.el,
|
|
35
|
+
dragEl,
|
|
36
|
+
newIndex,
|
|
37
|
+
oldIndex
|
|
38
|
+
});
|
|
39
|
+
}
|
|
35
40
|
},
|
|
36
41
|
...!!component.canPut && {
|
|
37
|
-
put: (to, from, dragEl, { newDraggableIndex: newIndex, oldDraggableIndex: oldIndex }) =>
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
put: (to, from, dragEl, { newDraggableIndex: newIndex, oldDraggableIndex: oldIndex }) => {
|
|
43
|
+
return component.canPut({
|
|
44
|
+
toEl: to.el,
|
|
45
|
+
fromEl: from.el,
|
|
46
|
+
dragEl,
|
|
47
|
+
newIndex,
|
|
48
|
+
oldIndex
|
|
49
|
+
});
|
|
50
|
+
}
|
|
44
51
|
}
|
|
45
52
|
}
|
|
46
53
|
},
|
|
@@ -53,12 +60,12 @@ function connectSortableComponent(component) {
|
|
|
53
60
|
handle,
|
|
54
61
|
filter: `${handle}[disabled]`,
|
|
55
62
|
onStart: ({ from: fromEl, item: dragEl, to: toEl, newDraggableIndex: newIndex, oldDraggableIndex: oldIndex }) => {
|
|
56
|
-
|
|
63
|
+
globalDragState.active = true;
|
|
57
64
|
onGlobalDragStart();
|
|
58
65
|
component.onDragStart({ fromEl, dragEl, toEl, newIndex, oldIndex });
|
|
59
66
|
},
|
|
60
67
|
onEnd: ({ from: fromEl, item: dragEl, to: toEl, newDraggableIndex: newIndex, oldDraggableIndex: oldIndex }) => {
|
|
61
|
-
|
|
68
|
+
globalDragState.active = false;
|
|
62
69
|
onGlobalDragEnd();
|
|
63
70
|
component.onDragEnd({ fromEl, dragEl, toEl, newIndex, oldIndex });
|
|
64
71
|
},
|
|
@@ -67,25 +74,44 @@ function connectSortableComponent(component) {
|
|
|
67
74
|
}
|
|
68
75
|
});
|
|
69
76
|
}
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
77
|
+
const useSortable = () => {
|
|
78
|
+
return makeGenericController((component, controller) => {
|
|
79
|
+
let sortable;
|
|
80
|
+
function dragActive(component2) {
|
|
81
|
+
return component2.dragEnabled && globalDragState.active;
|
|
82
|
+
}
|
|
83
|
+
function setUpSortable(component2) {
|
|
84
|
+
if (dragActive(component2)) {
|
|
85
|
+
return;
|
|
86
|
+
}
|
|
87
|
+
tearDownSortable(component2);
|
|
88
|
+
if (!component2.dragEnabled) {
|
|
89
|
+
return;
|
|
90
|
+
}
|
|
91
|
+
sortableComponentSet.add(component2);
|
|
92
|
+
sortable = createSortable(component2);
|
|
93
|
+
}
|
|
94
|
+
function tearDownSortable(component2) {
|
|
95
|
+
if (dragActive(component2)) {
|
|
96
|
+
return;
|
|
97
|
+
}
|
|
98
|
+
sortableComponentSet.delete(component2);
|
|
99
|
+
sortable?.destroy();
|
|
100
|
+
sortable = void 0;
|
|
101
|
+
}
|
|
102
|
+
controller.onConnected(() => {
|
|
103
|
+
setUpSortable(component);
|
|
104
|
+
});
|
|
105
|
+
controller.onDisconnected(() => {
|
|
106
|
+
tearDownSortable(component);
|
|
107
|
+
});
|
|
108
|
+
return {
|
|
109
|
+
reset: () => {
|
|
110
|
+
setUpSortable(component);
|
|
111
|
+
}
|
|
112
|
+
};
|
|
113
|
+
});
|
|
114
|
+
};
|
|
88
115
|
export {
|
|
89
|
-
|
|
90
|
-
disconnectSortableComponent as d
|
|
116
|
+
useSortable as u
|
|
91
117
|
};
|
package/dist/chunks/utils2.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
2
|
import { isServer } from "lit";
|
|
3
|
-
import {
|
|
3
|
+
import { n as nodeListToArray } from "./dom.js";
|
|
4
4
|
import { A as AllComboboxChildrenSelector, a as ComboboxItemSelector, b as ComboboxItemGroupSelector } from "./resources5.js";
|
|
5
5
|
function getAncestors(element) {
|
|
6
6
|
const parent = element.parentElement?.closest(AllComboboxChildrenSelector);
|
|
@@ -10,8 +10,8 @@ import type { HeadingLevel } from "../functional/Heading.js";
|
|
|
10
10
|
* @cssproperty [--calcite-accordion-text-color] - Specifies the component's text color.
|
|
11
11
|
* @cssproperty [--calcite-accordion-text-color-hover] - Specifies the component's main text color on hover.
|
|
12
12
|
* @cssproperty [--calcite-accordion-text-color-press] - Specifies the component's main text color when pressed.
|
|
13
|
-
* @cssproperty [--calcite-accordion-item-background-color] - [Deprecated] Use `--calcite-accordion-background-color
|
|
14
|
-
* @cssproperty [--calcite-accordion-item-border-color] - [Deprecated] Use `--calcite-accordion-border-color
|
|
13
|
+
* @cssproperty [--calcite-accordion-item-background-color] - [Deprecated] in v3.1.0, removal target v6.0.0 - Use `--calcite-accordion-background-color` instead. Specifies the component's background color.
|
|
14
|
+
* @cssproperty [--calcite-accordion-item-border-color] - [Deprecated] in v3.1.0, removal target v6.0.0 - Use `--calcite-accordion-border-color` instead. Specifies the component's border color.
|
|
15
15
|
* @cssproperty [--calcite-accordion-item-content-space] - Specifies the component's padding.
|
|
16
16
|
* @cssproperty [--calcite-accordion-item-end-icon-color] - Specifies the component's `iconEnd` color. Falls back to `--calcite-accordion-item-icon-color` or current color.
|
|
17
17
|
* @cssproperty [--calcite-accordion-item-expand-icon-color] - Specifies the component's expand icon color.
|
|
@@ -19,10 +19,10 @@ import type { HeadingLevel } from "../functional/Heading.js";
|
|
|
19
19
|
* @cssproperty [--calcite-accordion-item-header-background-color-hover] - Specifies the component's `heading` background color when hovered.
|
|
20
20
|
* @cssproperty [--calcite-accordion-item-header-background-color-press] - Specifies the component's `heading` background color when pressed.
|
|
21
21
|
* @cssproperty [--calcite-accordion-item-heading-text-color] - Specifies the component's `heading` text color.
|
|
22
|
-
* @cssproperty [--calcite-accordion-item-icon-color] - [Deprecated] Use `--calcite-icon-color
|
|
22
|
+
* @cssproperty [--calcite-accordion-item-icon-color] - [Deprecated] in v3.1.0, removal target v6.0.0 - Use `--calcite-icon-color` instead. Specifies the component's default icon color.
|
|
23
23
|
* @cssproperty [--calcite-accordion-item-start-icon-color] - Specifies the component's `iconStart` color. Falls back to `--calcite-accordion-item-icon-color` or current color.
|
|
24
|
-
* @cssproperty [--calcite-accordion-item-text-color] - [Deprecated] Use `--calcite-accordion-text-color
|
|
25
|
-
* @cssproperty [--calcite-accordion-item-text-color-hover] - [Deprecated] Use `--calcite-accordion-text-color-hover
|
|
24
|
+
* @cssproperty [--calcite-accordion-item-text-color] - [Deprecated] in v3.1.0, removal target v6.0.0 - Use `--calcite-accordion-text-color` instead. Specifies the component's text color.
|
|
25
|
+
* @cssproperty [--calcite-accordion-item-text-color-hover] - [Deprecated] in v3.1.0, removal target v6.0.0 - Use `--calcite-accordion-text-color-hover` instead. Specifies the component's text color on hover.
|
|
26
26
|
* @slot - A slot for adding custom content, including nested `calcite-accordion-item`s.
|
|
27
27
|
* @slot [actions-end] - A slot for adding `calcite-action`s or content to the end side of the component's header.
|
|
28
28
|
* @slot [actions-start] - A slot for adding `calcite-action`s or content to the start side of the component's header.
|
|
@@ -57,7 +57,7 @@ export abstract class AccordionItem extends LitElement {
|
|
|
57
57
|
* Sets focus on the component.
|
|
58
58
|
*
|
|
59
59
|
* @param options - When specified an optional object customizes the component's focusing process. When `preventScroll` is `true`, scrolling will not occur on the component.
|
|
60
|
-
* @
|
|
60
|
+
* @see [MDN - focus(options)](https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/focus#options)
|
|
61
61
|
*/
|
|
62
62
|
setFocus(options?: FocusOptions): Promise<void>;
|
|
63
63
|
/** Fires when the component's content area is collapsed. */
|
|
@@ -3,8 +3,9 @@ import { C as CSS_UTILITY, c as customElement } from "../../chunks/runtime.js";
|
|
|
3
3
|
import { keyed } from "lit/directives/keyed.js";
|
|
4
4
|
import { css, html, nothing } from "lit";
|
|
5
5
|
import { LitElement, createEvent, safeClassMap } from "@arcgis/lumina";
|
|
6
|
+
import { useDirection } from "@arcgis/lumina/controllers";
|
|
6
7
|
import { createRef, ref } from "lit/directives/ref.js";
|
|
7
|
-
import { c as closestElementCrossShadowBoundary, s as slotChangeHasAssignedElement
|
|
8
|
+
import { c as closestElementCrossShadowBoundary, s as slotChangeHasAssignedElement } from "../../chunks/dom.js";
|
|
8
9
|
import { g as getIconScale } from "../../chunks/component.js";
|
|
9
10
|
import { u as useSetFocus } from "../../chunks/useSetFocus.js";
|
|
10
11
|
import { u as useT9n } from "../../chunks/useT9n.js";
|
|
@@ -51,6 +52,7 @@ const styles = css`.icon-position--end,.icon-position--start{--calcite-internal-
|
|
|
51
52
|
class AccordionItem extends LitElement {
|
|
52
53
|
constructor() {
|
|
53
54
|
super();
|
|
55
|
+
this.direction = useDirection();
|
|
54
56
|
this.headerRef = createRef();
|
|
55
57
|
this.focusSetter = useSetFocus()(this);
|
|
56
58
|
this.messages = useT9n();
|
|
@@ -173,7 +175,6 @@ class AccordionItem extends LitElement {
|
|
|
173
175
|
}
|
|
174
176
|
render() {
|
|
175
177
|
const { iconFlipRtl, heading, headingLevel, messages, expanded } = this;
|
|
176
|
-
const dir = getElementDir(this.el);
|
|
177
178
|
const expandIconTitle = expanded ? messages.collapse : messages.expand;
|
|
178
179
|
const iconStartEl = this.iconStart ? keyed("icon-start", html`<calcite-icon class=${safeClassMap({ [CSS.icon]: true, [CSS.iconStart]: true })} .flipRtl=${iconFlipRtl === "both" || iconFlipRtl === "start"} .icon=${this.iconStart} .scale=${getIconScale(this.scale)}></calcite-icon>`) : null;
|
|
179
180
|
const iconEndEl = this.iconEnd ? keyed("icon-end", html`<calcite-icon class=${safeClassMap({ [CSS.iconEnd]: true, [CSS.icon]: true })} .flipRtl=${iconFlipRtl === "both" || iconFlipRtl === "end"} .icon=${this.iconEnd} .scale=${getIconScale(this.scale)}></calcite-icon>`) : null;
|
|
@@ -183,7 +184,7 @@ class AccordionItem extends LitElement {
|
|
|
183
184
|
[CSS.iconType(this.iconType)]: true
|
|
184
185
|
})}><div class=${safeClassMap({
|
|
185
186
|
[CSS.header]: true,
|
|
186
|
-
[CSS_UTILITY.rtl]:
|
|
187
|
+
[CSS_UTILITY.rtl]: this.direction === "rtl",
|
|
187
188
|
[CSS.headerAppearance(this.appearance)]: true
|
|
188
189
|
})}>${this.renderActionsStart()}<button aria-controls=${IDS.section} .ariaExpanded=${expanded} class=${safeClassMap(CSS.headerContent)} id=${IDS.sectionToggle} @click=${this.itemHeaderClickHandler} type=button ${ref(this.headerRef)}><div class=${safeClassMap(CSS.headerContainer)}>${this.renderContentStart()}${iconStartEl}<div class=${safeClassMap(CSS.headerText)}>${Heading({ class: CSS.heading, level: headingLevel, children: heading })}${description ? html`<span class=${safeClassMap(CSS.description)}>${description}</span>` : null}</div>${iconEndEl}${this.renderContentEnd()}</div><calcite-icon class=${safeClassMap(CSS.expandIcon)} .icon=${this.iconType === "chevron" ? ICONS.chevronDown : this.iconType === "caret" ? ICONS.caretDown : expanded ? ICONS.minus : ICONS.plus} .scale=${getIconScale(this.scale)} title=${expandIconTitle ?? nothing}></calcite-icon></button>${this.renderActionsEnd()}</div><section aria-labelledby=${IDS.sectionToggle} class=${safeClassMap(CSS.content)} id=${IDS.section}><slot></slot></section></div>`;
|
|
189
190
|
}
|
|
@@ -6,16 +6,16 @@ import type { IconName } from "../calcite-icon/interfaces.js";
|
|
|
6
6
|
/**
|
|
7
7
|
* @cssproperty [--calcite-action-background-color-hover] - Specifies the component's background color when hovered.
|
|
8
8
|
* @cssproperty [--calcite-action-background-color-press] - Specifies the component's background color when active.
|
|
9
|
-
* @cssproperty [--calcite-action-background-color-pressed] - [Deprecated] Use
|
|
9
|
+
* @cssproperty [--calcite-action-background-color-pressed] - [Deprecated] in v3.0.0, removal target v6.0.0 - Use `--calcite-action-background-color-press` instead. Specifies the component's background color when active.
|
|
10
10
|
* @cssproperty [--calcite-action-background-color] - Specifies the component's background color.
|
|
11
|
-
* @cssproperty [--calcite-action-corner-radius-end-end] - [Deprecated] Use
|
|
12
|
-
* @cssproperty [--calcite-action-corner-radius-end-start] - [Deprecated] Use
|
|
13
|
-
* @cssproperty [--calcite-action-corner-radius-start-end] - [Deprecated] Use
|
|
14
|
-
* @cssproperty [--calcite-action-corner-radius-start-start] - [Deprecated] Use
|
|
11
|
+
* @cssproperty [--calcite-action-corner-radius-end-end] - [Deprecated] in v3.0.0, removal target v6.0.0 - Use `--calcite-action-corner-radius` instead. Specifies the component's corner radius end end.
|
|
12
|
+
* @cssproperty [--calcite-action-corner-radius-end-start] - [Deprecated] in v3.0.0, removal target v6.0.0 - Use `--calcite-action-corner-radius` instead. Specifies the component's corner radius end start.
|
|
13
|
+
* @cssproperty [--calcite-action-corner-radius-start-end] - [Deprecated] in v3.0.0, removal target v6.0.0 - Use `--calcite-action-corner-radius` instead. Specifies the component's corner radius start end.
|
|
14
|
+
* @cssproperty [--calcite-action-corner-radius-start-start] - [Deprecated] in v3.0.0, removal target v6.0.0 - Use `--calcite-action-corner-radius` instead. Specifies the component's corner radius start start.
|
|
15
15
|
* @cssproperty [--calcite-action-corner-radius] - Specifies the component's corner radius.
|
|
16
16
|
* @cssproperty [--calcite-action-indicator-color] - Specifies the component's indicator color.
|
|
17
17
|
* @cssproperty [--calcite-action-text-color-press] - Specifies the component's text color when pressed or hovered.
|
|
18
|
-
* @cssproperty [--calcite-action-text-color-pressed] - [Deprecated] Use
|
|
18
|
+
* @cssproperty [--calcite-action-text-color-pressed] - [Deprecated] in v3.0.0, removal target v6.0.0 - Use `--calcite-action-text-color-press` instead. Specifies the component's text color when hovered.
|
|
19
19
|
* @cssproperty [--calcite-action-text-color] - Specifies the component's text color.
|
|
20
20
|
* @slot - A slot for adding non-interactive content, such as a `calcite-icon`.
|
|
21
21
|
*/
|
|
@@ -27,7 +27,7 @@ export abstract class Action extends LitElement {
|
|
|
27
27
|
*/
|
|
28
28
|
accessor active: boolean;
|
|
29
29
|
/** Specifies the horizontal alignment of button elements with text content. */
|
|
30
|
-
accessor alignment: Alignment;
|
|
30
|
+
accessor alignment: Alignment | undefined;
|
|
31
31
|
/**
|
|
32
32
|
* Specifies the appearance of the component.
|
|
33
33
|
*
|
|
@@ -55,9 +55,9 @@ export abstract class Action extends LitElement {
|
|
|
55
55
|
*
|
|
56
56
|
* When not set, the component is associated with its ancestor form element, if one exists.
|
|
57
57
|
*/
|
|
58
|
-
accessor form: string;
|
|
58
|
+
accessor form: string | undefined;
|
|
59
59
|
/** Specifies an icon to display. */
|
|
60
|
-
accessor icon: IconName;
|
|
60
|
+
accessor icon: IconName | undefined;
|
|
61
61
|
/**
|
|
62
62
|
* When `true`, the icon will be flipped when the element direction is right-to-left (`"rtl"`).
|
|
63
63
|
*
|
|
@@ -71,7 +71,7 @@ export abstract class Action extends LitElement {
|
|
|
71
71
|
*/
|
|
72
72
|
accessor indicator: boolean;
|
|
73
73
|
/** Specifies an accessible label for the component. If no label is provided, the label inherits what's provided for the `text` prop. */
|
|
74
|
-
accessor label: string;
|
|
74
|
+
accessor label: string | undefined;
|
|
75
75
|
/**
|
|
76
76
|
* When `true`, a busy indicator is displayed.
|
|
77
77
|
*
|
|
@@ -99,6 +99,8 @@ export abstract class Action extends LitElement {
|
|
|
99
99
|
/**
|
|
100
100
|
* When `true`, displays `text` adjacent to the `icon`.
|
|
101
101
|
*
|
|
102
|
+
* When `true` and the component is used as a child of `calcite-action-bar`, the text will be shown initially regardless of the parent components `expanded` state.
|
|
103
|
+
*
|
|
102
104
|
* @default false
|
|
103
105
|
*/
|
|
104
106
|
accessor textEnabled: boolean;
|
|
@@ -106,14 +108,14 @@ export abstract class Action extends LitElement {
|
|
|
106
108
|
* Specifies the default behavior of the component.
|
|
107
109
|
*
|
|
108
110
|
* @default "button"
|
|
109
|
-
* @
|
|
111
|
+
* @see [MDN - type](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#attr-type)
|
|
110
112
|
*/
|
|
111
113
|
accessor type: HTMLButtonElement["type"];
|
|
112
114
|
/**
|
|
113
115
|
* Sets focus on the component.
|
|
114
116
|
*
|
|
115
117
|
* @param options - When specified an optional object customizes the component's focusing process. When `preventScroll` is `true`, scrolling will not occur on the component.
|
|
116
|
-
* @
|
|
118
|
+
* @see [MDN - focus(options)](https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/focus#options)
|
|
117
119
|
*/
|
|
118
120
|
setFocus(options?: FocusOptions): Promise<void>;
|
|
119
121
|
}
|