@tylertech/forge 3.0.0-next.5 → 3.0.0-next.7
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/custom-elements.json +3175 -1640
- package/dist/esm/accordion/index.js +1 -1
- package/dist/esm/app-bar/help-button/index.js +1 -1
- package/dist/esm/app-bar/index.js +1 -1
- package/dist/esm/app-bar/menu-button/index.js +1 -1
- package/dist/esm/app-bar/notification-button/index.js +1 -1
- package/dist/esm/app-bar/profile-button/index.js +1 -1
- package/dist/esm/app-bar/search/index.js +1 -1
- package/dist/esm/autocomplete/index.js +1 -1
- package/dist/esm/avatar/index.js +1 -1
- package/dist/esm/backdrop/index.js +1 -1
- package/dist/esm/badge/index.js +1 -1
- package/dist/esm/banner/index.js +1 -1
- package/dist/esm/bottom-sheet/index.js +1 -1
- package/dist/esm/busy-indicator/index.js +1 -1
- package/dist/esm/button/index.js +1 -1
- package/dist/esm/button-toggle/button-toggle/index.js +1 -1
- package/dist/esm/button-toggle/button-toggle-group/index.js +1 -1
- package/dist/esm/button-toggle/index.js +1 -1
- package/dist/esm/calendar/calendar-dropdown/index.js +1 -1
- package/dist/esm/calendar/calendar-menu/index.js +1 -1
- package/dist/esm/calendar/index.js +1 -1
- package/dist/esm/card/index.js +1 -1
- package/dist/esm/checkbox/index.js +1 -1
- package/dist/esm/chip-field/index.js +1 -1
- package/dist/esm/chips/chip/index.js +1 -1
- package/dist/esm/chips/chip-set/index.js +1 -1
- package/dist/esm/chips/index.js +1 -1
- package/dist/esm/chunks/{chunk.UEN7B7Q4.js → chunk.246JM2YT.js} +2 -2
- package/dist/esm/chunks/{chunk.64F24XMH.js → chunk.24L5GDD2.js} +2 -2
- package/dist/esm/chunks/{chunk.IGOGRMRW.js → chunk.2CTK5R37.js} +2 -2
- package/dist/esm/chunks/chunk.2IQGDFQS.js +7 -0
- package/dist/esm/chunks/{chunk.U4CFRHOW.js.map → chunk.2IQGDFQS.js.map} +1 -1
- package/dist/esm/chunks/{chunk.ZXPAXZCF.js → chunk.2LRDPTHK.js} +2 -2
- package/dist/esm/chunks/{chunk.HSXUQFHK.js → chunk.2QFIMTVP.js} +2 -2
- package/dist/esm/chunks/{chunk.SCP23NBN.js → chunk.2QSDH3PC.js} +2 -2
- package/dist/esm/chunks/{chunk.KWD5EK54.js → chunk.2TQONIPK.js} +2 -2
- package/dist/esm/chunks/{chunk.SSJYPH4U.js → chunk.2XFVFZ3P.js} +2 -2
- package/dist/esm/chunks/{chunk.BPEGGZOR.js → chunk.2YAU7AXH.js} +2 -2
- package/dist/esm/chunks/{chunk.KI5FPZOX.js → chunk.2YX7ASSX.js} +2 -2
- package/dist/esm/chunks/{chunk.Y4OET6II.js → chunk.2ZTERGYF.js} +2 -2
- package/dist/esm/chunks/{chunk.3OT44DTM.js → chunk.3CBVRCKM.js} +2 -2
- package/dist/esm/chunks/{chunk.7BNQYL2F.js → chunk.4EB5NVCK.js} +2 -2
- package/dist/esm/chunks/{chunk.4NV7AHF2.js → chunk.4LVS2EYJ.js} +2 -2
- package/dist/esm/chunks/{chunk.LQQIN7JE.js → chunk.57IVD67K.js} +2 -2
- package/dist/esm/chunks/{chunk.RXBGYGVH.js → chunk.5CMQ7DNL.js} +2 -2
- package/dist/esm/chunks/chunk.5IVB5L5Z.js +7 -0
- package/dist/esm/chunks/{chunk.FZ43DC2H.js.map → chunk.5IVB5L5Z.js.map} +1 -1
- package/dist/esm/chunks/{chunk.MT3CYR5E.js → chunk.5M6Y2RU6.js} +2 -2
- package/dist/esm/chunks/{chunk.E5H7OQXZ.js → chunk.5PHLKON3.js} +2 -2
- package/dist/esm/chunks/chunk.5V5ABSHI.js +7 -0
- package/dist/esm/chunks/{chunk.TKDMM2ZZ.js.map → chunk.5V5ABSHI.js.map} +1 -1
- package/dist/esm/chunks/{chunk.A6RLV2QU.js → chunk.632OMHHN.js} +2 -2
- package/dist/esm/chunks/{chunk.PNDQ3LAB.js → chunk.6SBTLXLH.js} +2 -2
- package/dist/esm/chunks/chunk.7G72CBOJ.js +7 -0
- package/dist/esm/chunks/{chunk.FHW6LV4A.js.map → chunk.7G72CBOJ.js.map} +1 -1
- package/dist/esm/chunks/{chunk.KTPSDP4C.js → chunk.7JQHQKXN.js} +2 -2
- package/dist/esm/chunks/{chunk.BTTHTLD3.js → chunk.7WVTJIVR.js} +2 -2
- package/dist/esm/chunks/{chunk.PKZYVWEG.js → chunk.7ZQMJLHE.js} +2 -2
- package/dist/esm/chunks/{chunk.A5D7XSBD.js → chunk.A5MBSCSQ.js} +2 -2
- package/dist/esm/chunks/{chunk.7UN5EYUE.js → chunk.A5R7KUIP.js} +2 -2
- package/dist/esm/chunks/{chunk.XARGY3WT.js → chunk.AGMPIMJV.js} +2 -2
- package/dist/esm/chunks/{chunk.3W2ERIMT.js → chunk.BKCEVPKW.js} +2 -2
- package/dist/esm/chunks/{chunk.X63F5NVD.js → chunk.BSTIDYQJ.js} +2 -2
- package/dist/esm/chunks/{chunk.UUUF27IU.js → chunk.BWZKQ6WX.js} +2 -2
- package/dist/esm/chunks/{chunk.XBW6KSW3.js → chunk.CNQESSA3.js} +2 -2
- package/dist/esm/chunks/{chunk.55FCNVG5.js → chunk.DTZFWZPB.js} +2 -2
- package/dist/esm/chunks/{chunk.R4B7JSSA.js → chunk.E6KWYFZG.js} +2 -2
- package/dist/esm/chunks/{chunk.XGWGJFWC.js → chunk.E7Z3IRWV.js} +2 -2
- package/dist/esm/chunks/{chunk.NSTCCETU.js → chunk.ECRL6O3V.js} +2 -2
- package/dist/esm/chunks/{chunk.W6MDMZTN.js → chunk.EDEYCLDU.js} +2 -2
- package/dist/esm/chunks/{chunk.P6ZUHPI6.js → chunk.ER52NFXX.js} +2 -2
- package/dist/esm/chunks/{chunk.AY46N5Y7.js → chunk.EUE3OVC7.js} +2 -2
- package/dist/esm/chunks/{chunk.RMPS2I2P.js → chunk.EYZ25QUP.js} +2 -2
- package/dist/esm/chunks/{chunk.VJ2SSV5X.js → chunk.FAANPQES.js} +2 -2
- package/dist/esm/chunks/{chunk.MZLPUI6R.js → chunk.FYWPZFLJ.js} +2 -2
- package/dist/esm/chunks/{chunk.MZLPUI6R.js.map → chunk.FYWPZFLJ.js.map} +2 -2
- package/dist/esm/chunks/{chunk.DX32NTD3.js → chunk.GF2GUVYS.js} +2 -2
- package/dist/esm/chunks/chunk.GHSAKRYH.js +7 -0
- package/dist/esm/chunks/{chunk.2TVYAW7Q.js.map → chunk.GHSAKRYH.js.map} +1 -1
- package/dist/esm/chunks/chunk.GJW4WS4I.js +7 -0
- package/dist/esm/chunks/{chunk.P4TIMZKU.js → chunk.GUYPITGA.js} +2 -2
- package/dist/esm/chunks/chunk.GWIVOPRO.js +7 -0
- package/dist/esm/chunks/chunk.GWIVOPRO.js.map +7 -0
- package/dist/esm/chunks/{chunk.T64UW37U.js → chunk.H5D54EHO.js} +2 -2
- package/dist/esm/chunks/{chunk.FPMQAUL3.js → chunk.HKJEGD6C.js} +2 -2
- package/dist/esm/chunks/chunk.HRGTAVNA.js +7 -0
- package/dist/esm/chunks/{chunk.UZENE2NC.js.map → chunk.HRGTAVNA.js.map} +2 -2
- package/dist/esm/chunks/{chunk.7KEUUHXY.js → chunk.IDD54B5P.js} +2 -2
- package/dist/esm/chunks/chunk.IGK3VYZG.js +7 -0
- package/dist/esm/chunks/chunk.IGK3VYZG.js.map +7 -0
- package/dist/esm/chunks/{chunk.H4H75YUA.js → chunk.IWA3CYIB.js} +2 -2
- package/dist/esm/chunks/chunk.JHXNEHWR.js +12 -0
- package/dist/esm/chunks/{chunk.ZOV2BUZG.js → chunk.JVW6JGV3.js} +2 -2
- package/dist/esm/chunks/chunk.MF36FG2X.js +7 -0
- package/dist/esm/chunks/{chunk.LSFIZAUF.js.map → chunk.MF36FG2X.js.map} +1 -1
- package/dist/esm/chunks/{chunk.P64BBB3U.js → chunk.MXNLCQRB.js} +2 -2
- package/dist/esm/chunks/chunk.NK7H3MMM.js +7 -0
- package/dist/esm/chunks/{chunk.QH2GB3PD.js.map → chunk.NK7H3MMM.js.map} +2 -2
- package/dist/esm/chunks/chunk.NVMILGC2.js +7 -0
- package/dist/esm/chunks/{chunk.WDTA5G7R.js.map → chunk.NVMILGC2.js.map} +3 -3
- package/dist/esm/chunks/chunk.OHNPVHPF.js +7 -0
- package/dist/esm/chunks/chunk.OHNPVHPF.js.map +7 -0
- package/dist/esm/chunks/chunk.OT6H5NHX.js +7 -0
- package/dist/esm/chunks/chunk.OTVT3XM2.js +7 -0
- package/dist/esm/chunks/{chunk.4ZWV37ZJ.js → chunk.P5QIB6OY.js} +2 -2
- package/dist/esm/chunks/{chunk.ZB54OC26.js → chunk.PHBOQRF6.js} +2 -2
- package/dist/esm/chunks/{chunk.YTOYNJMD.js → chunk.PHTOULRR.js} +2 -2
- package/dist/esm/chunks/chunk.PPPTT3SM.js +7 -0
- package/dist/esm/chunks/{chunk.C4YKXXKM.js.map → chunk.PPPTT3SM.js.map} +1 -1
- package/dist/esm/chunks/{chunk.VMQZA47V.js → chunk.QA3NU7EN.js} +2 -2
- package/dist/esm/chunks/chunk.QYKO543K.js +7 -0
- package/dist/esm/chunks/{chunk.RHPJRCIC.js.map → chunk.QYKO543K.js.map} +1 -1
- package/dist/esm/chunks/{chunk.7VWG4IEN.js → chunk.QZK3WEH6.js} +2 -2
- package/dist/esm/chunks/{chunk.GFWFEBAH.js → chunk.RGPNNISQ.js} +2 -2
- package/dist/esm/chunks/chunk.RHYRMQS7.js +7 -0
- package/dist/esm/chunks/chunk.RHYRMQS7.js.map +7 -0
- package/dist/esm/chunks/{chunk.EUNKM7XR.js → chunk.RUSHOL23.js} +2 -2
- package/dist/esm/chunks/chunk.SIJGKRYS.js +7 -0
- package/dist/esm/chunks/{chunk.TFMOLR6W.js.map → chunk.SIJGKRYS.js.map} +1 -1
- package/dist/esm/chunks/{chunk.EWEX3PHR.js → chunk.STGRPD2L.js} +2 -2
- package/dist/esm/chunks/{chunk.EWEX3PHR.js.map → chunk.STGRPD2L.js.map} +1 -1
- package/dist/esm/chunks/chunk.SYZB7B4F.js +7 -0
- package/dist/esm/chunks/chunk.SYZB7B4F.js.map +7 -0
- package/dist/esm/chunks/chunk.SZIM4KFZ.js +7 -0
- package/dist/esm/chunks/chunk.SZIM4KFZ.js.map +7 -0
- package/dist/esm/chunks/{chunk.YNE75HFH.js → chunk.THPU5KBV.js} +2 -2
- package/dist/esm/chunks/{chunk.INRH62VL.js → chunk.TL6WVBGT.js} +2 -2
- package/dist/esm/chunks/{chunk.O4KZV4MX.js → chunk.TT2VTZJ6.js} +2 -2
- package/dist/esm/chunks/{chunk.7X7A74SI.js → chunk.TXFYS6EU.js} +2 -2
- package/dist/esm/chunks/{chunk.5MPUISW3.js → chunk.U4GYQOPY.js} +2 -2
- package/dist/esm/chunks/{chunk.I3MZQIAF.js → chunk.UCM6CGFM.js} +2 -2
- package/dist/esm/chunks/{chunk.SOMT6F6S.js → chunk.V4RBOYNH.js} +2 -2
- package/dist/esm/chunks/{chunk.2R72ZTIK.js → chunk.V6JVHYVW.js} +2 -2
- package/dist/esm/chunks/{chunk.UROMKMFI.js → chunk.WBYXVMYI.js} +2 -2
- package/dist/esm/chunks/chunk.WFDIA7R6.js +7 -0
- package/dist/esm/chunks/chunk.WFDIA7R6.js.map +7 -0
- package/dist/esm/chunks/{chunk.QUJL4A23.js → chunk.WO7KEM5K.js} +2 -2
- package/dist/esm/chunks/{chunk.HVYK2OWE.js → chunk.WYP2M5FR.js} +2 -2
- package/dist/esm/chunks/{chunk.NEMJIVPU.js → chunk.X3YNJSDT.js} +2 -2
- package/dist/esm/chunks/{chunk.WQL55O4A.js → chunk.XMFQFFKR.js} +2 -2
- package/dist/esm/chunks/{chunk.46LZNRRP.js → chunk.Y5UJ23LB.js} +2 -2
- package/dist/esm/chunks/{chunk.S5EJVD5E.js → chunk.YQXX5KSW.js} +2 -2
- package/dist/esm/chunks/{chunk.RVUMHJMM.js → chunk.YUAU5IWT.js} +2 -2
- package/dist/esm/chunks/{chunk.YSFUL5AD.js → chunk.YZLASVCK.js} +2 -2
- package/dist/esm/chunks/{chunk.ELY4YCON.js → chunk.Z5TWWM7I.js} +2 -2
- package/dist/esm/chunks/{chunk.RPKVFFQ6.js → chunk.ZIB7L7DZ.js} +2 -2
- package/dist/esm/circular-progress/index.js +1 -1
- package/dist/esm/color-picker/index.js +1 -1
- package/dist/esm/core/base/index.js +1 -1
- package/dist/esm/core/index.js +1 -1
- package/dist/esm/core/utils/index.js +1 -1
- package/dist/esm/date-picker/index.js +1 -1
- package/dist/esm/date-range-picker/index.js +1 -1
- package/dist/esm/dialog/index.js +1 -1
- package/dist/esm/divider/index.js +1 -1
- package/dist/esm/drawer/base/index.js +1 -1
- package/dist/esm/drawer/drawer/index.js +1 -1
- package/dist/esm/drawer/index.js +1 -1
- package/dist/esm/drawer/mini-drawer/index.js +1 -1
- package/dist/esm/drawer/modal-drawer/index.js +1 -1
- package/dist/esm/expansion-panel/index.js +1 -1
- package/dist/esm/file-picker/index.js +1 -1
- package/dist/esm/floating-action-button/index.js +1 -1
- package/dist/esm/icon/index.js +1 -1
- package/dist/esm/icon-button/index.js +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/inline-message/index.js +1 -1
- package/dist/esm/keyboard-shortcut/index.js +1 -1
- package/dist/esm/label-value/index.js +1 -1
- package/dist/esm/linear-progress/index.js +1 -1
- package/dist/esm/list/index.js +1 -1
- package/dist/esm/list/list/index.js +1 -1
- package/dist/esm/list/list-item/index.js +1 -1
- package/dist/esm/list-dropdown/index.js +1 -1
- package/dist/esm/menu/index.js +1 -1
- package/dist/esm/open-icon/index.js +1 -1
- package/dist/esm/page-state/index.js +1 -1
- package/dist/esm/paginator/index.js +1 -1
- package/dist/esm/popup/index.js +1 -1
- package/dist/esm/product-icon/index.js +1 -1
- package/dist/esm/profile-card/index.js +1 -1
- package/dist/esm/quantity-field/index.js +1 -1
- package/dist/esm/radio/index.js +1 -1
- package/dist/esm/ripple/index.js +1 -1
- package/dist/esm/scaffold/index.js +1 -1
- package/dist/esm/select/core/index.js +1 -1
- package/dist/esm/select/index.js +1 -1
- package/dist/esm/select/option/index.js +1 -1
- package/dist/esm/select/option-group/index.js +1 -1
- package/dist/esm/select/select/index.js +1 -1
- package/dist/esm/select/select-dropdown/index.js +1 -1
- package/dist/esm/skeleton/index.js +1 -1
- package/dist/esm/slider/index.js +1 -1
- package/dist/esm/split-view/index.js +1 -1
- package/dist/esm/split-view/split-view/index.js +1 -1
- package/dist/esm/split-view/split-view-panel/index.js +1 -1
- package/dist/esm/stack/index.js +1 -1
- package/dist/esm/stepper/index.js +1 -1
- package/dist/esm/stepper/step/index.js +1 -1
- package/dist/esm/stepper/stepper/index.js +1 -1
- package/dist/esm/switch/index.js +1 -1
- package/dist/esm/table/index.js +1 -1
- package/dist/esm/tabs/index.js +1 -1
- package/dist/esm/tabs/tab/index.js +1 -1
- package/dist/esm/tabs/tab-bar/index.js +1 -1
- package/dist/esm/text-field/index.js +1 -1
- package/dist/esm/time-picker/index.js +1 -1
- package/dist/esm/toast/index.js +1 -1
- package/dist/esm/toolbar/index.js +1 -1
- package/dist/esm/tooltip/index.js +1 -1
- package/dist/esm/utils/index.js +1 -1
- package/dist/esm/view-switcher/index.js +1 -1
- package/dist/esm/view-switcher/view/index.js +1 -1
- package/esm/accordion/accordion.js +4 -4
- package/esm/app-bar/app-bar.js +5 -5
- package/esm/app-bar/notification-button/app-bar-notification-button.js +5 -5
- package/esm/app-bar/profile-button/app-bar-profile-button-constants.d.ts +1 -1
- package/esm/app-bar/profile-button/app-bar-profile-button.js +4 -4
- package/esm/app-bar/search/app-bar-search.js +6 -6
- package/esm/autocomplete/autocomplete-adapter.d.ts +0 -2
- package/esm/autocomplete/autocomplete-adapter.js +0 -4
- package/esm/autocomplete/autocomplete-component-delegate.d.ts +1 -1
- package/esm/autocomplete/autocomplete-constants.d.ts +4 -4
- package/esm/autocomplete/autocomplete-foundation.js +0 -11
- package/esm/autocomplete/autocomplete.js +6 -6
- package/esm/avatar/avatar-component-delegate.d.ts +1 -1
- package/esm/avatar/avatar.js +5 -5
- package/esm/backdrop/backdrop-constants.d.ts +1 -1
- package/esm/backdrop/backdrop.js +5 -5
- package/esm/badge/badge-component-delegate.d.ts +1 -1
- package/esm/badge/badge.js +5 -5
- package/esm/banner/banner.js +6 -6
- package/esm/bottom-sheet/bottom-sheet.js +5 -5
- package/esm/busy-indicator/busy-indicator-constants.d.ts +1 -1
- package/esm/busy-indicator/busy-indicator.js +5 -5
- package/esm/button/button-component-delegate.d.ts +1 -1
- package/esm/button/button.js +3 -3
- package/esm/button-toggle/button-toggle/button-toggle.js +6 -6
- package/esm/button-toggle/button-toggle-group/button-toggle-group-constants.d.ts +2 -2
- package/esm/button-toggle/button-toggle-group/button-toggle-group.js +5 -5
- package/esm/calendar/calendar-component-delegate.d.ts +1 -1
- package/esm/calendar/calendar-constants.d.ts +10 -10
- package/esm/calendar/calendar-dropdown/calendar-dropdown.js +5 -5
- package/esm/calendar/calendar-menu/calendar-menu-constants.d.ts +2 -2
- package/esm/calendar/calendar-menu/calendar-menu.js +5 -5
- package/esm/calendar/calendar.js +6 -6
- package/esm/card/card.js +5 -5
- package/esm/checkbox/checkbox-component-delegate.d.ts +1 -1
- package/esm/checkbox/checkbox.js +3 -3
- package/esm/chip-field/chip-field-component-delegate.d.ts +1 -1
- package/esm/chips/chip/chip.js +6 -6
- package/esm/chips/chip-set/chip-set.js +5 -5
- package/esm/circular-progress/circular-progress.js +5 -5
- package/esm/color-picker/color-picker-constants.d.ts +2 -2
- package/esm/color-picker/color-picker.js +6 -6
- package/esm/core/delegates/base-component-delegate.d.ts +1 -1
- package/esm/core/delegates/base-component-delegate.js +3 -3
- package/esm/core/delegates/form-field-component-delegate.d.ts +1 -1
- package/esm/core/mask/time-segment-parser.d.ts +1 -1
- package/esm/core/utils/utils.d.ts +17 -0
- package/esm/core/utils/utils.js +27 -0
- package/esm/date-picker/date-picker-component-delegate.d.ts +1 -1
- package/esm/date-range-picker/date-range-picker-component-delegate.d.ts +1 -1
- package/esm/dialog/dialog-constants.d.ts +2 -2
- package/esm/dialog/dialog.js +5 -5
- package/esm/drawer/base/base-drawer-constants.d.ts +1 -1
- package/esm/expansion-panel/expansion-panel.js +5 -5
- package/esm/field/field-constants.d.ts +3 -3
- package/esm/field/field.js +3 -3
- package/esm/file-picker/file-picker-component-delegate.d.ts +1 -1
- package/esm/file-picker/file-picker.js +5 -5
- package/esm/floating-action-button/floating-action-button-component-delegate.d.ts +1 -1
- package/esm/floating-action-button/floating-action-button.js +6 -6
- package/esm/icon/icon.js +5 -5
- package/esm/icon-button/icon-button-component-delegate.d.ts +1 -1
- package/esm/icon-button/icon-button.js +7 -7
- package/esm/keyboard-shortcut/keyboard-shortcut.js +4 -4
- package/esm/label-value/label-value-component-delegate.d.ts +1 -1
- package/esm/label-value/label-value-constants.d.ts +1 -1
- package/esm/label-value/label-value.js +5 -5
- package/esm/linear-progress/linear-progress.js +5 -5
- package/esm/list/list/list.js +5 -5
- package/esm/list/list-item/list-item.js +5 -5
- package/esm/list-dropdown/list-dropdown-adapter.js +1 -1
- package/esm/list-dropdown/list-dropdown-constants.d.ts +6 -6
- package/esm/list-dropdown/list-dropdown-utils.d.ts +1 -1
- package/esm/list-dropdown/list-dropdown-utils.js +7 -4
- package/esm/menu/menu-constants.d.ts +3 -3
- package/esm/menu/menu.js +6 -6
- package/esm/open-icon/open-icon.js +6 -6
- package/esm/paginator/paginator-constants.d.ts +1 -1
- package/esm/paginator/paginator-foundation.js +2 -0
- package/esm/paginator/paginator.js +11 -11
- package/esm/popup/popup-constants.d.ts +2 -2
- package/esm/popup/popup.js +5 -5
- package/esm/product-icon/product-icon.js +5 -5
- package/esm/profile-card/profile-card.js +5 -5
- package/esm/quantity-field/quantity-field-component-delegate.d.ts +1 -1
- package/esm/quantity-field/quantity-field.js +6 -6
- package/esm/radio/radio.js +5 -5
- package/esm/ripple/forge-ripple.d.ts +2 -0
- package/esm/ripple/forge-ripple.js +4 -0
- package/esm/ripple/ripple.js +4 -4
- package/esm/select/core/base-select-constants.d.ts +4 -4
- package/esm/select/option/option.js +4 -4
- package/esm/select/option-group/option-group.js +3 -3
- package/esm/select/select/select-adapter.d.ts +1 -1
- package/esm/select/select-component-delegate.d.ts +1 -1
- package/esm/slider/slider-adapter.d.ts +95 -0
- package/esm/slider/slider-adapter.js +238 -0
- package/esm/slider/slider-component-delegate.d.ts +19 -3
- package/esm/slider/slider-component-delegate.js +48 -0
- package/esm/slider/slider-constants.d.ts +58 -19
- package/esm/slider/slider-constants.js +59 -14
- package/esm/slider/slider-foundation.d.ts +95 -0
- package/esm/slider/slider-foundation.js +319 -0
- package/esm/slider/slider-handle-ripple.d.ts +18 -0
- package/esm/slider/slider-handle-ripple.js +37 -0
- package/esm/slider/slider-utils.d.ts +9 -0
- package/esm/slider/slider-utils.js +53 -0
- package/esm/slider/slider.d.ts +135 -65
- package/esm/slider/slider.js +235 -246
- package/esm/split-view/split-view/split-view-constants.d.ts +1 -1
- package/esm/split-view/split-view/split-view.js +5 -5
- package/esm/split-view/split-view-panel/split-view-panel-constants.d.ts +2 -2
- package/esm/split-view/split-view-panel/split-view-panel-foundation.js +18 -18
- package/esm/split-view/split-view-panel/split-view-panel.js +7 -7
- package/esm/stack/stack-constants.d.ts +1 -1
- package/esm/stack/stack.js +5 -5
- package/esm/stepper/step/step-constants.d.ts +1 -1
- package/esm/stepper/step/step.js +12 -12
- package/esm/stepper/stepper/stepper-constants.d.ts +2 -2
- package/esm/stepper/stepper/stepper.js +5 -5
- package/esm/switch/switch-component-delegate.d.ts +1 -1
- package/esm/switch/switch-constants.d.ts +1 -1
- package/esm/switch/switch.js +9 -9
- package/esm/table/table.js +5 -5
- package/esm/table/types.d.ts +4 -4
- package/esm/tabs/tab/tab-adapter.d.ts +14 -38
- package/esm/tabs/tab/tab-adapter.js +65 -78
- package/esm/tabs/tab/tab-constants.d.ts +13 -13
- package/esm/tabs/tab/tab-constants.js +18 -10
- package/esm/tabs/tab/tab-foundation.d.ts +24 -23
- package/esm/tabs/tab/tab-foundation.js +68 -62
- package/esm/tabs/tab/tab-ripple.d.ts +17 -0
- package/esm/tabs/tab/tab-ripple.js +33 -0
- package/esm/tabs/tab/tab.d.ts +56 -19
- package/esm/tabs/tab/tab.js +82 -36
- package/esm/tabs/tab-bar/tab-bar-adapter.d.ts +49 -87
- package/esm/tabs/tab-bar/tab-bar-adapter.js +114 -188
- package/esm/tabs/tab-bar/tab-bar-constants.d.ts +15 -45
- package/esm/tabs/tab-bar/tab-bar-constants.js +22 -56
- package/esm/tabs/tab-bar/tab-bar-foundation.d.ts +56 -65
- package/esm/tabs/tab-bar/tab-bar-foundation.js +241 -302
- package/esm/tabs/tab-bar/tab-bar.d.ts +51 -36
- package/esm/tabs/tab-bar/tab-bar.js +89 -57
- package/esm/text-field/text-field-component-delegate.d.ts +1 -1
- package/esm/theme/theme-utils.d.ts +2 -2
- package/esm/time-picker/time-picker-component-delegate.d.ts +1 -1
- package/esm/time-picker/time-picker-constants.d.ts +6 -6
- package/esm/time-picker/time-picker.js +6 -6
- package/esm/toast/toast-constants.d.ts +2 -2
- package/esm/toast/toast.js +6 -6
- package/esm/toolbar/toolbar.js +5 -5
- package/esm/tooltip/tooltip-constants.d.ts +1 -1
- package/esm/tooltip/tooltip.js +4 -4
- package/esm/utils/color-utils.js +1 -0
- package/esm/view-switcher/view-switcher.js +5 -5
- package/package.json +1 -1
- package/styles/core/style-layer/slider/_core.scss +550 -0
- package/styles/core/style-layer/slider/_functions.scss +33 -0
- package/styles/core/style-layer/slider/_variables.scss +17 -0
- package/styles/core/style-layer/slider/index.scss +18 -0
- package/styles/core/style-layer/tabs/tab/_core.scss +419 -0
- package/styles/core/style-layer/tabs/tab/_variables.scss +20 -0
- package/styles/core/style-layer/tabs/tab/index.scss +13 -0
- package/styles/core/style-layer/tabs/tab-bar/_core.scss +110 -0
- package/styles/core/style-layer/tabs/tab-bar/_variables.scss +9 -0
- package/styles/core/style-layer/tabs/tab-bar/index.scss +13 -0
- package/styles/slider/_mixins.scss +27 -0
- package/styles/slider/_variables.scss +37 -0
- package/styles/slider/slider.scss +3 -20
- package/styles/tabs/tab/_mixins.scss +46 -128
- package/styles/tabs/tab/_variables.scss +26 -4
- package/styles/tabs/tab/tab.scss +50 -11
- package/styles/tabs/tab-bar/_mixins.scss +20 -60
- package/styles/tabs/tab-bar/_variables.scss +11 -0
- package/styles/tabs/tab-bar/tab-bar.scss +29 -2
- package/dist/esm/chunks/chunk.2TVYAW7Q.js +0 -7
- package/dist/esm/chunks/chunk.3SBF7CUU.js +0 -201
- package/dist/esm/chunks/chunk.3SBF7CUU.js.map +0 -7
- package/dist/esm/chunks/chunk.3XZRUXG7.js +0 -7
- package/dist/esm/chunks/chunk.7JBR7GWZ.js +0 -7
- package/dist/esm/chunks/chunk.ABN3DL7G.js +0 -7
- package/dist/esm/chunks/chunk.C4YKXXKM.js +0 -7
- package/dist/esm/chunks/chunk.FF5DED5D.js +0 -7
- package/dist/esm/chunks/chunk.FF5DED5D.js.map +0 -7
- package/dist/esm/chunks/chunk.FHW6LV4A.js +0 -7
- package/dist/esm/chunks/chunk.FZ43DC2H.js +0 -7
- package/dist/esm/chunks/chunk.GOZVC3ZT.js +0 -7
- package/dist/esm/chunks/chunk.GOZVC3ZT.js.map +0 -7
- package/dist/esm/chunks/chunk.IMRPJU4M.js +0 -129
- package/dist/esm/chunks/chunk.IMRPJU4M.js.map +0 -7
- package/dist/esm/chunks/chunk.JKEIP657.js +0 -7
- package/dist/esm/chunks/chunk.JKEIP657.js.map +0 -7
- package/dist/esm/chunks/chunk.LSFIZAUF.js +0 -7
- package/dist/esm/chunks/chunk.QH2GB3PD.js +0 -7
- package/dist/esm/chunks/chunk.RHPJRCIC.js +0 -7
- package/dist/esm/chunks/chunk.SKEI7ZSK.js +0 -153
- package/dist/esm/chunks/chunk.SKEI7ZSK.js.map +0 -7
- package/dist/esm/chunks/chunk.TFMOLR6W.js +0 -7
- package/dist/esm/chunks/chunk.TKDMM2ZZ.js +0 -7
- package/dist/esm/chunks/chunk.U4CFRHOW.js +0 -7
- package/dist/esm/chunks/chunk.UETV4PTS.js +0 -12
- package/dist/esm/chunks/chunk.UZENE2NC.js +0 -7
- package/dist/esm/chunks/chunk.VUGNSK4K.js +0 -7
- package/dist/esm/chunks/chunk.VUGNSK4K.js.map +0 -7
- package/dist/esm/chunks/chunk.WDTA5G7R.js +0 -7
- /package/dist/esm/chunks/{chunk.UEN7B7Q4.js.map → chunk.246JM2YT.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.64F24XMH.js.map → chunk.24L5GDD2.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.IGOGRMRW.js.map → chunk.2CTK5R37.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.ZXPAXZCF.js.map → chunk.2LRDPTHK.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.HSXUQFHK.js.map → chunk.2QFIMTVP.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.SCP23NBN.js.map → chunk.2QSDH3PC.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.KWD5EK54.js.map → chunk.2TQONIPK.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.SSJYPH4U.js.map → chunk.2XFVFZ3P.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.BPEGGZOR.js.map → chunk.2YAU7AXH.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.KI5FPZOX.js.map → chunk.2YX7ASSX.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.Y4OET6II.js.map → chunk.2ZTERGYF.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.3OT44DTM.js.map → chunk.3CBVRCKM.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.7BNQYL2F.js.map → chunk.4EB5NVCK.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.4NV7AHF2.js.map → chunk.4LVS2EYJ.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.LQQIN7JE.js.map → chunk.57IVD67K.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.RXBGYGVH.js.map → chunk.5CMQ7DNL.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.MT3CYR5E.js.map → chunk.5M6Y2RU6.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.E5H7OQXZ.js.map → chunk.5PHLKON3.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.A6RLV2QU.js.map → chunk.632OMHHN.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.PNDQ3LAB.js.map → chunk.6SBTLXLH.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.KTPSDP4C.js.map → chunk.7JQHQKXN.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.BTTHTLD3.js.map → chunk.7WVTJIVR.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.PKZYVWEG.js.map → chunk.7ZQMJLHE.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.A5D7XSBD.js.map → chunk.A5MBSCSQ.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.7UN5EYUE.js.map → chunk.A5R7KUIP.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.XARGY3WT.js.map → chunk.AGMPIMJV.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.3W2ERIMT.js.map → chunk.BKCEVPKW.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.X63F5NVD.js.map → chunk.BSTIDYQJ.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.UUUF27IU.js.map → chunk.BWZKQ6WX.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.XBW6KSW3.js.map → chunk.CNQESSA3.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.55FCNVG5.js.map → chunk.DTZFWZPB.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.R4B7JSSA.js.map → chunk.E6KWYFZG.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.XGWGJFWC.js.map → chunk.E7Z3IRWV.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.NSTCCETU.js.map → chunk.ECRL6O3V.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.W6MDMZTN.js.map → chunk.EDEYCLDU.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.P6ZUHPI6.js.map → chunk.ER52NFXX.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.AY46N5Y7.js.map → chunk.EUE3OVC7.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.RMPS2I2P.js.map → chunk.EYZ25QUP.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.VJ2SSV5X.js.map → chunk.FAANPQES.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.DX32NTD3.js.map → chunk.GF2GUVYS.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.ABN3DL7G.js.map → chunk.GJW4WS4I.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.P4TIMZKU.js.map → chunk.GUYPITGA.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.T64UW37U.js.map → chunk.H5D54EHO.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.FPMQAUL3.js.map → chunk.HKJEGD6C.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.7KEUUHXY.js.map → chunk.IDD54B5P.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.H4H75YUA.js.map → chunk.IWA3CYIB.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.UETV4PTS.js.map → chunk.JHXNEHWR.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.ZOV2BUZG.js.map → chunk.JVW6JGV3.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.P64BBB3U.js.map → chunk.MXNLCQRB.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.3XZRUXG7.js.map → chunk.OT6H5NHX.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.7JBR7GWZ.js.map → chunk.OTVT3XM2.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.4ZWV37ZJ.js.map → chunk.P5QIB6OY.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.ZB54OC26.js.map → chunk.PHBOQRF6.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.YTOYNJMD.js.map → chunk.PHTOULRR.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.VMQZA47V.js.map → chunk.QA3NU7EN.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.7VWG4IEN.js.map → chunk.QZK3WEH6.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.GFWFEBAH.js.map → chunk.RGPNNISQ.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.EUNKM7XR.js.map → chunk.RUSHOL23.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.YNE75HFH.js.map → chunk.THPU5KBV.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.INRH62VL.js.map → chunk.TL6WVBGT.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.O4KZV4MX.js.map → chunk.TT2VTZJ6.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.7X7A74SI.js.map → chunk.TXFYS6EU.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.5MPUISW3.js.map → chunk.U4GYQOPY.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.I3MZQIAF.js.map → chunk.UCM6CGFM.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.SOMT6F6S.js.map → chunk.V4RBOYNH.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.2R72ZTIK.js.map → chunk.V6JVHYVW.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.UROMKMFI.js.map → chunk.WBYXVMYI.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.QUJL4A23.js.map → chunk.WO7KEM5K.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.HVYK2OWE.js.map → chunk.WYP2M5FR.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.NEMJIVPU.js.map → chunk.X3YNJSDT.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.WQL55O4A.js.map → chunk.XMFQFFKR.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.46LZNRRP.js.map → chunk.Y5UJ23LB.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.S5EJVD5E.js.map → chunk.YQXX5KSW.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.RVUMHJMM.js.map → chunk.YUAU5IWT.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.YSFUL5AD.js.map → chunk.YZLASVCK.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.ELY4YCON.js.map → chunk.Z5TWWM7I.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.RPKVFFQ6.js.map → chunk.ZIB7L7DZ.js.map} +0 -0
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2023 Tyler Technologies, Inc.
|
|
4
|
-
* License: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
import{a as T}from"./chunk.P4TIMZKU.js";import{c as L}from"./chunk.SSJYPH4U.js";import{a as D}from"./chunk.AY46N5Y7.js";import{a as c,d as H}from"./chunk.GFWFEBAH.js";import{a as C}from"./chunk.LEVFMI2Q.js";import{a as w}from"./chunk.7UN5EYUE.js";import{a as s}from"./chunk.NVUMRW44.js";import{a as S}from"./chunk.TKDMM2ZZ.js";import{a as x,b as B}from"./chunk.55FCNVG5.js";import{a as k,e as y,g}from"./chunk.QH2GB3PD.js";import{i as E,r as h,t as l}from"./chunk.CFDK4RCW.js";import{k as d}from"./chunk.J2M2MXP2.js";import{a as v,b as _,d as a}from"./chunk.M3QDAYD2.js";var p=`${B}bottom-sheet`,A={DRAGGING:"forge-bottom-sheet--dragging",FULLSCREEN:"forge-bottom-sheet--fullscreen",OPEN:"forge-bottom-sheet--open",SCROLLABLE:"forge-bottom-sheet--scrollable"},O={BACKDROP_CLOSE:"backdrop-close",ESCAPE_CLOSE:"escape-close",FULLSCREEN:"fullscreen",INITIAL_FOCUS:`${p}-focus`,OPEN:`${p}-open`,SHOW_BACKDROP:"show-backdrop"},N={BACKDROP:c.elementName,CONTAINER:".forge-bottom-sheet",CONTENT_BODY:"[forge-bottom-sheet-body]",INITIAL_FOCUS:`[${O.INITIAL_FOCUS}]`,HOST:`[${p}-host]`},P={BEFORE_CLOSE:"forge-bottom-sheet-before-close",CLOSE:"forge-bottom-sheet-close",OPEN:"forge-bottom-sheet-open",READY:"forge-bottom-sheet-ready",DRAG_START:"forge-bottom-sheet-drag-start",DRAGGED:"forge-bottom-sheet-dragged",DRAG_END:"forge-bottom-sheet-drag-end",DRAG_CANCEL:"forge-bottom-sheet-drag-cancel",FULLSCREEN:"forge-bottom-sheet-fullscreen"},o={elementName:p,classes:A,selectors:N,attributes:O,events:P};var m=class extends S{constructor(e){super(e);this._backdropElement=g(e,o.selectors.BACKDROP),this._containerElement=g(e,o.selectors.CONTAINER)}initializeAccessibility(){this._component.hasAttribute("role")||(this._component.setAttribute("role","dialog"),this._component.setAttribute("aria-modal","true"))}setVisibility(e){l(this._containerElement,e,o.classes.OPEN)}attach(){(document.querySelector(o.selectors.HOST)||document.body).appendChild(this._component)}detach(){E(this._component)}registerTransitionEndHandler(e){this._containerElement.addEventListener("transitionend",e)}deregisterTransitionEndHandler(e){this._containerElement.removeEventListener("transitionend",e)}setBodyListener(e,i,r){document.body.addEventListener(e,i,r)}removeBodyListener(e,i){document.body.removeEventListener(e,i)}setDocumentListener(e,i){document.addEventListener(e,i)}removeDocumentListener(e,i){document.removeEventListener(e,i)}registerBackdropClickHandler(e){this._backdropElement.addEventListener(c.events.BACKDROP_CLICK,e)}deregisterBackdropClickHandler(e){this._backdropElement.removeEventListener(c.events.BACKDROP_CLICK,e)}getOpenBottomSheets(e){return document.querySelectorAll(e)}trySetInitialFocus(){let e=h(this._component,o.selectors.INITIAL_FOCUS);e&&e.length&&e[e.length-1].focus()}isScrollable(){let e=this._getContentElement();return e?e.scrollHeight>e.offsetHeight:!1}isContentChild(e){let i=this._getContentElement();return i?i.contains(e):!1}initScrollable(){let e=this.isScrollable();l(this._component,e,o.classes.SCROLLABLE),l(this._containerElement,e,o.classes.SCROLLABLE)}setDragging(e){l(this._containerElement,e,o.classes.DRAGGING),l(this._component,e,o.classes.DRAGGING)}setBackdropVisiblity(e){this._backdropElement.hidden=!e}setFullscreen(e){l(this._containerElement,e,o.classes.FULLSCREEN)}tryLayoutChildren(){let e=[w.elementName,D.elementName,L.elementName,T.elementName];Array.from(this._component.querySelectorAll(e.join(","))).filter(r=>typeof r.layout=="function").forEach(r=>r.layout())}setContainerHeight(e){if(e!=null){let i=Math.min(100,100*e/window.innerHeight);this._containerElement.style.maxHeight=`${i}%`}else this._containerElement.style.removeProperty("max-height")}getContainerBounds(){return this._containerElement.getBoundingClientRect()}setDragTargetHandler(e,i){this._containerElement.addEventListener(e,i)}removeDragTargetHandler(e,i){this._containerElement.removeEventListener(e,i)}setBodyScrollHandler(e){let i=this._getContentElement();i&&i.addEventListener("scroll",e)}_getContentElement(){let e=Array.from(h(this._component,o.selectors.CONTENT_BODY,!1));return e.length?e[0]:null}};var b=class{constructor(t){this._adapter=t;this._open=!1;this._backdropClose=!0;this._escapeClose=!0;this._fullscreen=!1;this._showBackdrop=!1;this._isDragging=!1;this._bodyScrollHandler=()=>this._onBodyScroll();this._dragStartHandler=t=>this._onDragStart(t);this._dragMoveHandler=t=>this._onDragMove(t);this._dragEndHandler=()=>this._onDragEnd();this._dragCancelHandler=()=>this._onDragCancel();this._openTransitionEndHandler=e=>this._onOpenTransitionEnd(),this._closeTransitionEndHandler=e=>this._onCloseTransitionEnd(),this._documentKeydownHandler=e=>this._onDocumentKeydown(e),this._backdropClickHandler=e=>this._onBackdropClick(e)}initialize(){this._adapter.initializeAccessibility()}destroy(){this._open&&(this._adapter.deregisterTransitionEndHandler(this._openTransitionEndHandler),this._adapter.removeDocumentListener("keydown",this._documentKeydownHandler),this._adapter.deregisterBackdropClickHandler(this._backdropClickHandler))}_setOpen(t){this._open=t,this._open?this._openBottomSheet():this._closeBottomSheet(),this._adapter.toggleHostAttribute(o.attributes.OPEN,this._open)}_openBottomSheet(){this._adapter.attach(),this._adapter.setBodyAttribute(o.attributes.OPEN,"true"),this._adapter.registerTransitionEndHandler(this._openTransitionEndHandler),this._setDocumentKeydownListener(this._escapeClose),this._setBackdropClickListener(this._backdropClose),window.requestAnimationFrame(()=>{window.requestAnimationFrame(()=>{this._adapter.setVisibility(!0),this._adapter.emitHostEvent(o.events.OPEN),this._adapter.trySetInitialFocus(),this._adapter.initScrollable()})})}_closeBottomSheet(){this._adapter.deregisterTransitionEndHandler(this._openTransitionEndHandler),this._adapter.removeDocumentListener("keydown",this._documentKeydownHandler),this._adapter.deregisterBackdropClickHandler(this._backdropClickHandler),this._adapter.registerTransitionEndHandler(this._closeTransitionEndHandler),this._adapter.setVisibility(!1)}_onCloseTransitionEnd(){this._adapter.emitHostEvent(o.events.CLOSE),this._adapter.detach(),this._adapter.getOpenBottomSheets(o.elementName).length||this._adapter.removeBodyAttribute(o.attributes.OPEN)}_onOpenTransitionEnd(){this._open&&(this._adapter.deregisterTransitionEndHandler(this._openTransitionEndHandler),this._adapter.emitHostEvent(o.events.READY),this._adapter.tryLayoutChildren(),this._adapter.isScrollable()&&this._initScrollableHandlers())}_onDocumentKeydown(t){t.stopPropagation(),t.key&&(t.key==="Escape"||t.key==="Esc")&&this._tryClose()}_onBackdropClick(t){t.stopPropagation(),this._tryClose()}async _tryClose(){if(this._adapter.emitHostEvent(o.events.BEFORE_CLOSE,void 0,void 0,!0)){if(!this._beforeCloseCallback){this.open=!1;return}try{if(await Promise.resolve(this._beforeCloseCallback())){this.open=!1;return}}catch(e){return}}}_setBackdropClickListener(t){this._open&&(t?this._adapter.registerBackdropClickHandler(this._backdropClickHandler):this._adapter.deregisterBackdropClickHandler(this._backdropClickHandler))}_setDocumentKeydownListener(t){this._open&&(t?this._adapter.addDocumentListener("keydown",this._documentKeydownHandler):this._adapter.removeDocumentListener("keydown",this._documentKeydownHandler))}set backdropClose(t){t=!!t,this._backdropClose!==t&&(this._backdropClose=t,this._setBackdropClickListener(this._backdropClose),this._adapter.toggleHostAttribute(o.attributes.BACKDROP_CLOSE,this._backdropClose))}get backdropClose(){return this._backdropClose}set escapeClose(t){t=!!t,this._escapeClose!==t&&(this._escapeClose=t,this._setDocumentKeydownListener(this._escapeClose),this._adapter.toggleHostAttribute(o.attributes.ESCAPE_CLOSE,this._escapeClose))}get escapeClose(){return this._escapeClose}get open(){return this._open}set open(t){if(this._open!==t&&(t=!!t,t!==this._open)){let e=t?this._openCallback:this._closeCallback;e?Promise.resolve(e()).then(()=>{this._setOpen(t)}).catch(()=>{}):this._setOpen(t)}}get fullscreen(){return this._fullscreen}set fullscreen(t){this._fullscreen!==t&&(this._fullscreen=t,this._adapter.setFullscreen(this._fullscreen),this._adapter.toggleHostAttribute(o.attributes.FULLSCREEN,this._fullscreen))}get showBackdrop(){return this._showBackdrop}set showBackdrop(t){this._showBackdrop!==t&&(this._showBackdrop=t,this._adapter.setBackdropVisiblity(t),this._adapter.toggleHostAttribute(o.attributes.SHOW_BACKDROP,this._showBackdrop))}get openCallback(){return this._openCallback}set openCallback(t){this._openCallback=t}get closeCallback(){return this._closeCallback}set closeCallback(t){this._closeCallback=t}get beforeCloseCallback(){return this._beforeCloseCallback}set beforeCloseCallback(t){this._beforeCloseCallback=t}_initScrollableHandlers(){!this._fullscreen&&this._adapter.isScrollable()&&(this._adapter.setDragTargetHandler("mousedown",this._dragStartHandler),this._adapter.setDragTargetHandler("touchstart",this._dragStartHandler),this._adapter.setBodyScrollHandler(this._bodyScrollHandler))}_onBodyScroll(){!this._fullscreen&&!this._isDragging&&(this.fullscreen=!0,this._adapter.emitHostEvent(o.events.FULLSCREEN,this._fullscreen))}_onDragStart(t){if(this._fullscreen){let r=C(t);if(this._adapter.isScrollable()&&this._adapter.isContentChild(r[0]))return}t.stopPropagation();let e=this._adapter.getContainerBounds(),i=t instanceof MouseEvent?t.clientY:t.touches[0].clientY;this._dragContext={top:i-e.top,height:e.height},this._adapter.setBodyListener("mousemove",this._dragMoveHandler,{passive:!1}),this._adapter.setBodyListener("touchmove",this._dragMoveHandler,{passive:!1}),this._adapter.setBodyListener("mouseup",this._dragEndHandler),this._adapter.setBodyListener("touchend",this._dragEndHandler),this._adapter.setBodyListener("touchcancel",this._dragCancelHandler)}_onDragMove(t){if(t.stopPropagation(),t.preventDefault(),!this._dragContext)return;let e=t instanceof MouseEvent?t.clientY:t.touches[0].clientY,i={y:window.innerHeight-e+this._dragContext.top};if(!this._isDragging){if(this._isDragging=!0,!this._adapter.emitHostEvent(o.events.DRAG_START,i,!0,!0))return;this._adapter.setDragging(!0)}let r=this._fullscreen?i:{y:Math.max(i.y,this._dragContext.height)};(!this._lastPosition||r.y!==this._lastPosition.y)&&this._adapter.emitHostEvent(o.events.DRAGGED,r,!0,!0)&&(this._lastPosition=_(v({},r),{clientY:e}),this._adapter.setContainerHeight(r.y))}_onDragEnd(){if(this._lastPosition){let t=this._lastPosition.clientY,e=this._dragContext;e&&(this._fullscreen&&t>0?(this.fullscreen=!1,this._adapter.emitHostEvent(o.events.FULLSCREEN,this._fullscreen)):!this._fullscreen&&t<e.height+e.top&&(this.fullscreen=!0,this._adapter.emitHostEvent(o.events.FULLSCREEN,this._fullscreen)))}this._isDragging&&this._adapter.emitHostEvent(o.events.DRAG_END),this._dragComplete()}_onDragCancel(){this._isDragging&&this._adapter.emitHostEvent(o.events.DRAG_CANCEL),this._dragComplete()}_dragComplete(){this._adapter.setDragging(!1),this._adapter.removeBodyListener("mousemove",this._dragMoveHandler),this._adapter.removeBodyListener("touchmove",this._dragMoveHandler),this._adapter.removeBodyListener("mouseup",this._dragEndHandler),this._adapter.removeBodyListener("touchend",this._dragEndHandler),this._adapter.removeBodyListener("touchcancel",this._dragCancelHandler),this._adapter.setContainerHeight(null),this._lastPosition=void 0,this._dragContext=void 0,this._isDragging=!1}};var I='<template><forge-backdrop hidden part="backdrop"></forge-backdrop><div class="forge-bottom-sheet" part="root"><slot></slot></div></template>',R='.forge-icon-button{display:-webkit-inline-box;display:inline-flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;border:none;outline:0;background-color:transparent;fill:currentColor;color:inherit;font-size:24px;text-decoration:none;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:48px;height:48px;padding:12px}.forge-icon-button forge-icon,.forge-icon-button img,.forge-icon-button svg{width:24px;height:24px}.forge-icon-button:disabled{color:rgba(0,0,0,.38);color:var(--mdc-theme-text-disabled-on-light,rgba(0,0,0,.38))}.forge-icon-button:disabled{cursor:default;pointer-events:none}.forge-icon-button__icon{display:inline-block}.forge-icon-button__icon.forge-icon-button__icon--on{display:none}.forge-icon-button--on .forge-icon-button__icon{display:none}.forge-icon-button--on .forge-icon-button__icon.forge-icon-button__icon--on{display:inline-block}@-webkit-keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@-webkit-keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@-webkit-keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}@keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.forge-icon-button{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:transparent;will-change:transform,opacity}.forge-icon-button::after,.forge-icon-button::before{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:""}.forge-icon-button::before{-webkit-transition:opacity 15ms linear,background-color 15ms linear;transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index,1)}.forge-icon-button::after{z-index:0;z-index:var(--mdc-ripple-z-index,0)}.forge-icon-button.mdc-ripple-upgraded::before{-webkit-transform:scale(var(--mdc-ripple-fg-scale,1));transform:scale(var(--mdc-ripple-fg-scale,1))}.forge-icon-button.mdc-ripple-upgraded::after{top:0;left:0;-webkit-transform:scale(0);transform:scale(0);-webkit-transform-origin:center center;transform-origin:center center}.forge-icon-button.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top,0);left:var(--mdc-ripple-left,0)}.forge-icon-button.mdc-ripple-upgraded--foreground-activation::after{-webkit-animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards;animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.forge-icon-button.mdc-ripple-upgraded--foreground-deactivation::after{-webkit-animation:mdc-ripple-fg-opacity-out 150ms;animation:mdc-ripple-fg-opacity-out 150ms;-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}.forge-icon-button::after,.forge-icon-button::before{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.forge-icon-button.mdc-ripple-upgraded::after,.forge-icon-button.mdc-ripple-upgraded::before{top:var(--mdc-ripple-top,calc(50% - 50%));left:var(--mdc-ripple-left,calc(50% - 50%));width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.forge-icon-button.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.forge-icon-button::after,.forge-icon-button::before{background-color:#000;background-color:var(--mdc-ripple-color,var(--mdc-theme-on-surface,#000))}.forge-icon-button.mdc-ripple-surface--hover::before,.forge-icon-button:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.forge-icon-button.mdc-ripple-upgraded--background-focused::before,.forge-icon-button:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.forge-icon-button:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.forge-icon-button:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.forge-icon-button.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}forge-icon-button{position:relative;display:inline-block;overflow:visible}.forge-icon-button--on{color:#3f51b5;color:var(--mdc-theme-primary,#3f51b5)}.forge-icon-button--on::after,.forge-icon-button--on::before{background-color:#3f51b5;background-color:var(--mdc-ripple-color,var(--mdc-theme-primary,#3f51b5))}.forge-icon-button--on.mdc-ripple-surface--hover::before,.forge-icon-button--on:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.forge-icon-button--on.mdc-ripple-upgraded--background-focused::before,.forge-icon-button--on:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.forge-icon-button--on:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.forge-icon-button--on:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.forge-icon-button--on.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.forge-icon-button--on::before{background-color:#3f51b5;background-color:var(--mdc-theme-primary,#3f51b5);opacity:.08}.forge-icon-button--dense{width:28px;height:28px;padding:2px;padding:0}.forge-icon-button--dense-1{width:44px;height:44px;padding:10px}.forge-icon-button--dense-2{width:40px;height:40px;padding:8px}.forge-icon-button--dense-3{width:36px;height:36px;padding:6px}.forge-icon-button--dense-4{width:32px;height:32px;padding:4px}.forge-icon-button--dense-5{width:28px;height:28px;padding:2px}.forge-icon-button--dense-6{width:24px;height:24px;padding:0}.forge-icon-button--with-badge forge-badge{z-index:1;z-index:var(--forge-z-index-surface,1);pointer-events:none;--forge-badge-max-width:32px;--forge-badge-border:1px solid transparent}.forge-icon-button--with-badge forge-badge[app-bar-context]{--forge-badge-border:2px solid var(--forge-app-bar-theme-background)}.forge-bottom-sheet{background-color:#fff;background-color:var(--mdc-theme-surface,#fff);-webkit-box-shadow:0 5px 5px -3px rgba(0,0,0,.2),0 8px 10px 1px rgba(0,0,0,.14),0 3px 14px 2px rgba(0,0,0,.12);box-shadow:0 5px 5px -3px rgba(0,0,0,.2),0 8px 10px 1px rgba(0,0,0,.14),0 3px 14px 2px rgba(0,0,0,.12);border-radius:4px 4px 0 0;border-radius:var(--forge-bottom-sheet-border-radius,4px 4px 0 0);max-width:50%;max-width:var(--forge-bottom-sheet-desktop-max-width,50%);-webkit-box-sizing:border-box;box-sizing:border-box;position:fixed;bottom:0;right:0;left:0;max-height:50%;margin:0 auto;display:-webkit-inline-box;display:inline-flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;flex-direction:column;-webkit-transform:translateY(100%);transform:translateY(100%);-webkit-transition:max-height var(--forge-bottom-sheet-transition-duration, 250ms) ease-in,-webkit-transform var(--forge-bottom-sheet-transition-duration-close, 200ms) cubic-bezier(.4, 0, .2, 1);transition:max-height var(--forge-bottom-sheet-transition-duration, 250ms) ease-in,-webkit-transform var(--forge-bottom-sheet-transition-duration-close, 200ms) cubic-bezier(.4, 0, .2, 1);transition:max-height var(--forge-bottom-sheet-transition-duration, 250ms) ease-in,transform var(--forge-bottom-sheet-transition-duration-close, 200ms) cubic-bezier(.4, 0, .2, 1);transition:max-height var(--forge-bottom-sheet-transition-duration, 250ms) ease-in,transform var(--forge-bottom-sheet-transition-duration-close, 200ms) cubic-bezier(.4, 0, .2, 1),-webkit-transform var(--forge-bottom-sheet-transition-duration-close, 200ms) cubic-bezier(.4, 0, .2, 1)}@media (max-width:600px){.forge-bottom-sheet{max-width:100%;width:100%;margin:0;border-radius:0}}.forge-bottom-sheet--open{-webkit-transform:translateY(0);transform:translateY(0);-webkit-transition-duration:var(--forge-bottom-sheet-transition-duration, 250ms);transition-duration:var(--forge-bottom-sheet-transition-duration, 250ms)}.forge-bottom-sheet--fullscreen.forge-bottom-sheet--open{height:100%;max-height:100%;-webkit-transition:max-height var(--forge-bottom-sheet-transition-duration, 250ms) ease-in;transition:max-height var(--forge-bottom-sheet-transition-duration, 250ms) ease-in}.forge-bottom-sheet--dragging{-webkit-transition:none!important;transition:none!important}.forge-bottom-sheet--scrollable{height:100%}:host{z-index:8;z-index:var(--forge-z-index-dialog,8);position:fixed}:host forge-backdrop{position:absolute;top:0;bottom:0;left:0;right:0;position:fixed}:host([hidden]){display:none}',n=class extends HTMLElement{constructor(){super();y(this,I,R),this._foundation=new b(new m(this))}static get observedAttributes(){return[o.attributes.BACKDROP_CLOSE,o.attributes.ESCAPE_CLOSE,o.attributes.OPEN,o.attributes.FULLSCREEN,o.attributes.SHOW_BACKDROP]}connectedCallback(){this._foundation.initialize()}disconnectedCallback(){this._foundation.destroy()}attributeChangedCallback(e,i,r){switch(e){case o.attributes.BACKDROP_CLOSE:this.backdropClose=d(r);break;case o.attributes.ESCAPE_CLOSE:this.escapeClose=d(r);break;case o.attributes.OPEN:this.open=d(r);break;case o.attributes.FULLSCREEN:this.fullscreen=d(r);break;case o.attributes.SHOW_BACKDROP:this.showBackdrop=d(r);break}}};a([s()],n.prototype,"backdropClose",2),a([s()],n.prototype,"escapeClose",2),a([s()],n.prototype,"open",2),a([s()],n.prototype,"fullscreen",2),a([s()],n.prototype,"showBackdrop",2),a([s()],n.prototype,"openCallback",2),a([s()],n.prototype,"closeCallback",2),a([s()],n.prototype,"beforeCloseCallback",2),n=a([x({name:o.elementName,dependencies:[H]})],n);function ve(){k(n)}export{o as a,m as b,b as c,n as d,ve as e};
|
|
7
|
-
//# sourceMappingURL=chunk.U4CFRHOW.js.map
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2023 Tyler Technologies, Inc.
|
|
4
|
-
* License: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
import{e as z}from"./chunk.E5H7OQXZ.js";import{e as J}from"./chunk.4ZWV37ZJ.js";import{d as oo}from"./chunk.RHPJRCIC.js";import{d as X}from"./chunk.KTPSDP4C.js";import{b as W}from"./chunk.YNE75HFH.js";import{d as Y}from"./chunk.KI5FPZOX.js";import{d as p}from"./chunk.KWD5EK54.js";import{d as M}from"./chunk.SOMT6F6S.js";import{d as D}from"./chunk.U4CFRHOW.js";import{d as A}from"./chunk.DX32NTD3.js";import{d as P}from"./chunk.LQQIN7JE.js";import{i as B}from"./chunk.VUGNSK4K.js";import{f as V}from"./chunk.ELY4YCON.js";import{d}from"./chunk.FPMQAUL3.js";import{c as u}from"./chunk.7BNQYL2F.js";import{e as c}from"./chunk.C4YKXXKM.js";import{b as O}from"./chunk.UUUF27IU.js";import{d as F}from"./chunk.P64BBB3U.js";import{d as E}from"./chunk.ZOV2BUZG.js";import{d as K}from"./chunk.XARGY3WT.js";import{d as N}from"./chunk.W6MDMZTN.js";import{b as H}from"./chunk.XGWGJFWC.js";import{b as G}from"./chunk.HVYK2OWE.js";import{b as e}from"./chunk.5MPUISW3.js";import{e as v}from"./chunk.RVUMHJMM.js";import{d as y}from"./chunk.VJ2SSV5X.js";import{E as L}from"./chunk.64F24XMH.js";import{d as j}from"./chunk.LSFIZAUF.js";import{j as _}from"./chunk.BTTHTLD3.js";import{b as U}from"./chunk.RXBGYGVH.js";import{b as Q}from"./chunk.Y4OET6II.js";import{d as io}from"./chunk.S5EJVD5E.js";import{d as fo}from"./chunk.GOZVC3ZT.js";import{b as ro}from"./chunk.46LZNRRP.js";import{d as q}from"./chunk.P6ZUHPI6.js";import{b as xo}from"./chunk.SKEI7ZSK.js";import{d as eo}from"./chunk.EUNKM7XR.js";import{d as no}from"./chunk.TFMOLR6W.js";import{b as to}from"./chunk.SCP23NBN.js";import{d as mo}from"./chunk.H4H75YUA.js";import{d as I}from"./chunk.IGOGRMRW.js";import{b as po}from"./chunk.7VWG4IEN.js";import{b as k}from"./chunk.P4TIMZKU.js";import{d as Co}from"./chunk.A5D7XSBD.js";import{d as $}from"./chunk.BPEGGZOR.js";import{d as S}from"./chunk.UROMKMFI.js";import{f as So}from"./chunk.3SBF7CUU.js";import{d as Bo}from"./chunk.IMRPJU4M.js";import{h as uo}from"./chunk.XBW6KSW3.js";import{f as h}from"./chunk.SSJYPH4U.js";import{b as w}from"./chunk.AY46N5Y7.js";import{d as co}from"./chunk.ZXPAXZCF.js";import{d as lo}from"./chunk.PNDQ3LAB.js";import{d as t}from"./chunk.NSTCCETU.js";import{d as m}from"./chunk.R4B7JSSA.js";import{e as Ao}from"./chunk.MT3CYR5E.js";import{c as ao}from"./chunk.WQL55O4A.js";import{f as To}from"./chunk.I3MZQIAF.js";import{b as go}from"./chunk.PKZYVWEG.js";import{d as T}from"./chunk.NEMJIVPU.js";import{b as Z}from"./chunk.INRH62VL.js";import{d as Po}from"./chunk.VMQZA47V.js";import{c as b}from"./chunk.UEN7B7Q4.js";import{q as so}from"./chunk.3W2ERIMT.js";import{d as R}from"./chunk.O4KZV4MX.js";import{d as s}from"./chunk.GFWFEBAH.js";import{b as n}from"./chunk.RPKVFFQ6.js";import{e as x}from"./chunk.FHW6LV4A.js";import{c as C}from"./chunk.HSXUQFHK.js";import{e as i}from"./chunk.FZ43DC2H.js";import{b as a}from"./chunk.7KEUUHXY.js";import{c as l}from"./chunk.A6RLV2QU.js";import{b as g}from"./chunk.7UN5EYUE.js";import{l as r}from"./chunk.T64UW37U.js";import{f}from"./chunk.JKEIP657.js";import{b as o}from"./chunk.QH2GB3PD.js";var ho=[p,S,s,P,A,D,M,b,E,F,L,O,h,c,u,d,I,V,y,v,R,e,G,H,N,t,K,Q,io,r,g,U,_,j,n,C,i,q,z,J,W,X,Y,oo,$,m,mo,to,ro,fo,x,Co,k,f,po,no,eo,a,xo,ao,Ao,co,lo,w,So,Bo,uo,l,so,Po,Z,T,To,go,B];function Fr(){o(ho)}export{Fr as a};
|
|
7
|
-
/**
|
|
8
|
-
* @license
|
|
9
|
-
* Copyright (c) 2022 Tyler Technologies, Inc.
|
|
10
|
-
* License: Apache-2.0
|
|
11
|
-
*/
|
|
12
|
-
//# sourceMappingURL=chunk.UETV4PTS.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2023 Tyler Technologies, Inc.
|
|
4
|
-
* License: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
import{a as e}from"./chunk.3CTKWBV2.js";function l(){let o="0123456789ABCDEF".split(""),r="#";for(let t=0;t<6;t++)r+=o[Math.floor(Math.random()*16)];return r}function i(o){(!o||typeof o!="string")&&(o="");let r;if(o.charCodeAt(0)<65)r=l();else{let t=Math.floor((o.charCodeAt(0)-65)%e.letterColors.length);r=e.letterColors[t]}return r}export{l as a,i as b};
|
|
7
|
-
//# sourceMappingURL=chunk.UZENE2NC.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2023 Tyler Technologies, Inc.
|
|
4
|
-
* License: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
import{a as y}from"./chunk.FPMQAUL3.js";import{b as Q}from"./chunk.5MPUISW3.js";import{a as ie}from"./chunk.2TVYAW7Q.js";import{h as ae,i as ue}from"./chunk.FF5DED5D.js";import{b as Z}from"./chunk.RPKVFFQ6.js";import{a as F,e as oe}from"./chunk.FHW6LV4A.js";import{c as te}from"./chunk.HSXUQFHK.js";import{e as ee}from"./chunk.FZ43DC2H.js";import{b as ne}from"./chunk.7KEUUHXY.js";import{c as le}from"./chunk.A6RLV2QU.js";import{a as re,b as pe}from"./chunk.YTOYNJMD.js";import{a as se}from"./chunk.GO5A4GKZ.js";import{a as L}from"./chunk.MGLWXAZO.js";import{c as V,g as q,h as z}from"./chunk.MZLPUI6R.js";import{d as X,l as J,m as j}from"./chunk.T64UW37U.js";import{a as Y}from"./chunk.WDTA5G7R.js";import{a as $}from"./chunk.G4IN6Y46.js";import{a}from"./chunk.NVUMRW44.js";import{a as G}from"./chunk.TKDMM2ZZ.js";import{a as R,b as K,c as W}from"./chunk.55FCNVG5.js";import{a as U,e as H,g as C}from"./chunk.QH2GB3PD.js";import{m as M,r as N,s as k,u as A}from"./chunk.CFDK4RCW.js";import{a as x,b as h,c as S,j as w,k as g,l as P,n as D,o as B}from"./chunk.J2M2MXP2.js";import{a as T,d as p}from"./chunk.M3QDAYD2.js";var O=`${K}autocomplete`,fe={MODE:"mode",MULTIPLE:"multiple",DEBOUNCE:"debounce",FILTER_ON_FOCUS:"filter-on-focus",FILTER_FOCUS_FIRST:"filter-focus-first",ALLOW_UNMATCHED:"allow-unmatched",POPUP_TARGET:"popup-target",POPUP_CLASSES:"popup-classes",OPTION_LIMIT:"option-limit",OBSERVE_SCROLL:"observe-scroll",OBSERVE_SCROLL_THRESHOLD:"observe-scroll-threshold",SYNC_POPUP_WIDTH:"sync-popup-width",OPEN:"open",MATCH_KEY:"match-key",FILTER_TEXT:"filter-text",DROPDOWN_ICON_OPEN:"data-forge-dropdown-icon-open"},ve={INPUT:se.selectors.INPUT,DROPDOWN_ICON:"[data-forge-dropdown-icon],[data-forge-dropdown-icon],[forge-dropdown-icon],.forge-dropdown-icon",CLEAR_BUTTON:"[data-forge-autocomplete-clear],[forge-autocomplete-clear]"},ge={DEFAULT_DEBOUNCE_TIME:500,NUM_SKELETON_ITEMS:3},be={CHANGE:`${O}-change`,SELECT:`${O}-select`,SCROLLED_BOTTOM:`${O}-scrolled-bottom`},o={elementName:O,attributes:fe,selectors:ve,numbers:ge,events:be},de=(e=>(e.Default="default",e.Stateless="stateless",e))(de||{});var I=class extends G{constructor(e){super(e);this.setInputElement()}setInputElement(){let e=N(this._component,o.selectors.INPUT,!1);return e.length&&(this._inputElement=e[0]),this._inputElement}setInputAttribute(e,t){this._inputElement.setAttribute(e,t)}addInputListener(e,t){this._inputElement.addEventListener(e,t)}removeInputListener(e,t){this._inputElement.removeEventListener(e,t)}initializeInputAccessibility(e){this._inputElement.setAttribute("autocomplete","off"),this._inputElement.setAttribute("role","combobox"),this._inputElement.setAttribute("aria-live","polite"),this._inputElement.setAttribute("aria-atomic","true"),this._inputElement.setAttribute("aria-haspopup","true"),this._inputElement.setAttribute("aria-expanded","false"),this._inputElement.setAttribute("aria-autocomplete","list")}isWrappingChipField(){return!!this._component.querySelector(y.elementName)}show(e,t){this._targetElement=this._getTargetElement(t),this._targetElement&&(this._listDropdown=new ae(this._targetElement,e),this._listDropdown.open(),this._inputElement.setAttribute("aria-expanded","true"),this._inputElement.setAttribute("aria-controls",`list-dropdown-popup-${e.id}`),this._tryToggleDropdownIconRotation(!0))}hide(e){if(!this._listDropdown)return;let{targetElement:t}=this._listDropdown.dropdownElement;t.removeEventListener(F.events.BLUR,e),this.setBusyVisibility(!1),this._tryToggleDropdownIconRotation(!1),this._inputElement.removeAttribute("aria-activedescendant"),this._inputElement.removeAttribute("aria-controls"),this._inputElement.setAttribute("aria-expanded","false"),this._listDropdown.close(),this._listDropdown=void 0}setBusyVisibility(e){var t;(t=this._listDropdown)==null||t.setBusyVisibility(e)}toggleOptionMultiple(e,t){var i;(i=this._listDropdown)==null||i.toggleOptionMultiple(e,t)}setDismissListener(e){if(!this._listDropdown||!this._listDropdown.dropdownElement)return;let t=this._listDropdown.dropdownElement;t.targetElement&&t.targetElement.addEventListener(F.events.BLUR,e)}focus(){window.requestAnimationFrame(()=>this._inputElement.focus())}setOptions(e){var t;(t=this._listDropdown)==null||t.setOptions(e)}appendOptions(e){var t;(t=this._listDropdown)==null||t.appendOptions(e)}setSelectedText(e){this._inputElement.value=e}getInputValue(){return this._inputElement.value}setInputValue(e){this._inputElement.value=e}selectInputValue(){window.requestAnimationFrame(()=>this._inputElement.select())}isFocusWithinPopup(e){return!this._listDropdown||!this._listDropdown.dropdownElement?!1:this._listDropdown.dropdownElement.contains(e)}hasFocus(){let e=k();return e===this._inputElement||this.isFocusWithinPopup(e)}hasInputElement(){return!!this._inputElement}setDropdownIconListener(e,t){window.requestAnimationFrame(()=>{let i=this._component.querySelector(o.selectors.DROPDOWN_ICON);i&&i.addEventListener(e,t)})}removeDropdownIconListener(e,t){let i=this._component.querySelector(o.selectors.DROPDOWN_ICON);i&&i.removeEventListener(e,t)}setClearButtonListener(e,t){window.requestAnimationFrame(()=>{let i=this._component.querySelector(o.selectors.CLEAR_BUTTON);i&&i.addEventListener(e,t)})}removeClearButtonListener(e,t){let i=this._component.querySelector(o.selectors.CLEAR_BUTTON);i&&i.removeEventListener(e,t)}propagateKey(e){var t;(t=this._listDropdown)==null||t.handleKey(e)}updateActiveDescendant(e){this._targetElement&&A(this._inputElement,!!e,"aria-activedescendant",e)}getTargetElementWidth(e){return this._targetElement||(this._targetElement=this._getTargetElement(e)),this._targetElement.getBoundingClientRect().width}getPopupElement(){var e,t;return(t=(e=this._listDropdown)==null?void 0:e.dropdownElement)!=null?t:null}activateFirstOption(){var e;(e=this._listDropdown)==null||e.activateFirstOption()}activateSelectedOption(){var e;(e=this._listDropdown)==null||e.activateSelectedOption()}activateOptionByIndex(e){var t;(t=this._listDropdown)==null||t.activateOption(e)}getActiveOptionIndex(){var e,t;return(t=(e=this._listDropdown)==null?void 0:e.getActiveOptionIndex())!=null?t:null}clearActiveOption(){var e;(e=this._listDropdown)==null||e.clearActiveOption()}setSelectedOptions(e){if(this._listDropdown){let t=e.map(i=>i.value);this._listDropdown.setSelectedValues(t)}}queueDropdownPositionUpdate(){this.getPopupElement()&&window.requestAnimationFrame(()=>{let e=this.getPopupElement();e==null||e.position()})}_getTargetElement(e){return e?this._component.querySelector(e)||this._getDefaultTargetElement():this._getDefaultTargetElement()}_getDefaultTargetElement(){let e=this._component.querySelector("forge-text-field");if(e&&e.shadowRoot){let i=C(e,re.selectors.ROOT);if(i)return i}let t=this._component.querySelector("forge-chip-field");if(t&&t.shadowRoot){let i=C(t,y.selectors.ROOT);if(i)return i}return this._component.querySelector("input")||this._component}_tryToggleDropdownIconRotation(e){let t=this._component.querySelector(o.selectors.DROPDOWN_ICON);t&&A(t,e,o.attributes.DROPDOWN_ICON_OPEN)}};var ce=(e=>(e[e.Option=0]="Option",e[e.Group=1]="Group",e))(ce||{});function b(u,d){let e=u.some(i=>h(i)&&w(i)&&i.hasOwnProperty("options")&&(i.hasOwnProperty("text")||i.hasOwnProperty("builder"))),t=u.some(i=>h(i)&&w(i)&&i.hasOwnProperty("label")&&i.hasOwnProperty("value"));return e&&d===1||t&&d===0}function he(u,d){return u.find(e=>e.value===d)}function v(u,d,e=null){return e?!(e in u.value)||!(e in d)?!1:D(u.value[e],d[e]):D(u.value,d)}var E=class extends ue{constructor(e){super();this._adapter=e;this._isInitialized=!1;this._isDropdownOpen=!1;this._mode="default";this._multiple=!1;this._debounce=o.numbers.DEFAULT_DEBOUNCE_TIME;this._allowUnmatched=!1;this._filterOnFocus=!0;this._filterFocusFirst=!0;this._options=[];this._filterText="";this._selectedOptions=[];this._values=[];this._pendingFilterPromises=[];this._matchKey=null;this._clickListener=t=>this._onClick(t),this._focusListener=()=>this._onFocus(),this._blurListener=t=>this._onBlur(t),this._keydownListener=t=>this._onKeydown(t),this._dropdownIconClickListener=t=>this._onDropdownIconClick(t),this._dropdownScrollEndListener=()=>this._onDropdownScrollEnd(),this._dropdownIconMouseDownListener=t=>this._onDropdownIconMouseDown(t),this._clearButtonListener=t=>this._onClear(t),this._dismissListener=()=>this._onDismiss(),this._activeChangeListener=t=>this._adapter.updateActiveDescendant(t),this._targetWidthCallback=()=>this._adapter.getTargetElementWidth(this._popupTarget),this._identifier=x()}async initialize(){if(!this._adapter.hasInputElement()&&!this._adapter.setInputElement())throw new Error("An input element is required as a child of the autocomplete component.");if(this._setInputListener(),this._setFilterCallback(),this._attachListeners(),this._initializeAccessibility(),this._values.length){if(!this._selectedOptions.length){try{await this._executeFilter()}catch(e){console.error(e)}this._updateSelectedOptions(this._values)}this._adapter.setSelectedText(this._getSelectedText())}this._isInitialized=!0}disconnect(){this._isInitialized&&(this._detachListeners(),this._isInitialized=!1),this._isDropdownOpen&&this._closeDropdown()}_attachListeners(){this._adapter.addInputListener("click",this._clickListener),this._adapter.addInputListener("focus",this._focusListener),this._adapter.addInputListener("blur",this._blurListener),this._adapter.addInputListener("input",this._inputListener),this._adapter.addInputListener("keydown",this._keydownListener),this._adapter.setDropdownIconListener("click",this._dropdownIconClickListener),this._adapter.setDropdownIconListener("mousedown",this._dropdownIconMouseDownListener),this._adapter.setClearButtonListener("click",this._clearButtonListener)}_detachListeners(){this._adapter.removeInputListener("click",this._clickListener),this._adapter.removeInputListener("focus",this._focusListener),this._adapter.removeInputListener("blur",this._blurListener),this._adapter.removeInputListener("input",this._inputListener),this._adapter.removeInputListener("keydown",this._keydownListener),this._adapter.removeDropdownIconListener("click",this._dropdownIconClickListener),this._adapter.removeDropdownIconListener("mousedown",this._dropdownIconMouseDownListener),this._adapter.removeClearButtonListener("click",this._clearButtonListener)}_setInputListener(){this._inputListener=e=>this._onInput(e)}_setFilterCallback(){this._filterFn=h(this._debounce)&&this._debounce>0?B(this._debounceFilter,this._debounce,!1):this._debounceFilter}_initializeAccessibility(){this._adapter.initializeInputAccessibility(this._identifier)}get _flatOptions(){return b(this._options,1)?this._options.reduce((e,t)=>e.concat(t.options),[]):this._options}_onClick(e){!this._isDropdownOpen&&this._filterOnFocus&&this._showDropdown()}_onDropdownIconMouseDown(e){e.preventDefault()}_onDropdownIconClick(e){this._isDropdownOpen?this._closeDropdown():(this._adapter.focus(),window.requestAnimationFrame(()=>this._showDropdown()))}_onClear(e){this._clearValue(),this._adapter.setSelectedText(this._getSelectedText())}_onDropdownScrollEnd(){this._adapter.emitHostEvent(o.events.SCROLLED_BOTTOM)}_onFocus(){!this._isDropdownOpen&&this._adapter.getInputValue()&&!L.isMobile&&this._adapter.selectInputValue()}_onBlur(e){this._adapter.isFocusWithinPopup(e.relatedTarget)||this._applyBlur()}_applyBlur(){this._isDropdownOpen&&this._closeDropdown(),this._mode!=="stateless"&&(this._selectedOptions.length?this._adapter.setSelectedText(this._getSelectedText()):this._allowUnmatched||(this._filterText="",this._adapter.setSelectedText("")))}_onInput(e){this._selectedOptions.length&&!this._multiple&&(!this._adapter.getInputValue()||this._allowUnmatched)&&!this._adapter.isWrappingChipField()&&(this._selectedOptions=[],this._values=[],this._emitChangeEvent()),this._filterText=this._adapter.getInputValue(),this._filterFn()}async _debounceFilter({checkFocus:e=!0}={}){if(!e&&!this._adapter.hasFocus()){this._pendingFilterPromises=[],this._isDropdownOpen&&this._closeDropdown();return}let t=this._filterText,i=this._executeFilter();this._pendingFilterPromises.push(i),this._isDropdownOpen?this._adapter.setBusyVisibility(!0):this._showDropdown({filter:!1});try{await i}catch(n){this._pendingFilterPromises=[],this._isDropdownOpen&&this._closeDropdown();return}if(t===this._filterText)this._pendingFilterPromises=[],this._onFilterComplete();else{let n=this._pendingFilterPromises.indexOf(i);n!==-1&&this._pendingFilterPromises.splice(n,1)}}_onKeydown(e){switch(e.key){case"Tab":this._isDropdownOpen&&!this._multiple&&this._selectActiveOption(!1);break;case"Esc":case"Escape":this._isDropdownOpen&&(e.preventDefault(),e.stopPropagation(),this._closeDropdown());break;case"Down":case"ArrowDown":e.preventDefault(),this._isDropdownOpen?this._adapter.propagateKey(e.key):this._showDropdown({activateFirst:!0,activateSelected:!0});break;case"Up":case"ArrowUp":e.preventDefault(),this._isDropdownOpen&&this._adapter.propagateKey(e.key);break;case"Enter":case"Home":case"End":this._isDropdownOpen&&(e.key==="Enter"&&e.stopPropagation(),e.preventDefault(),this._adapter.propagateKey(e.key));break;case"Backspace":case"Delete":let t=e.target,i=this._adapter.getInputValue(),n=t.value.substring(t.selectionStart,t.selectionEnd)===t.value,l=i.length===1&&t.selectionEnd===1,c=i.length===1&&t.selectionEnd===0,_=!i||n||l||c;!this._adapter.isWrappingChipField()&&_&&!this._multiple&&this._values.length&&this._clearValue();break}}_executeFilter(e=!0,t=!1){if(!this._filter||typeof this._filter!="function")throw new Error('A filter callback must be provided. Did you set the "filter" property?');let i=this._filter,n=e?this._filterText:"",l=t?this._getValue():null;return new Promise((c,_)=>Promise.resolve(i(n,l)).then(s=>{this._options=s,c(this._options)}).catch(s=>_(`An unexpected error occurred while filtering: ${s}`)))}_onFilterComplete(){if(!this._adapter.hasFocus()){this._isDropdownOpen&&this._closeDropdown();return}if(this._options.length){let e=this._allowUnmatched&&!this._selectedOptions.length;this._dropdownReady({userTriggered:e}),this._filterFocusFirst&&this._filterText&&this._adapter.activateFirstOption()}else this._closeDropdown()}_clearValue(){this._selectedOptions=[],this._values=[],this._isDropdownOpen&&(this._adapter.setSelectedOptions([]),this._adapter.clearActiveOption()),this._emitChangeEvent()}async _showDropdown({filter:e=!0,userTriggered:t=!0,activateFirst:i=!1,activateSelected:n=!1}={}){let l=this._allowUnmatched&&!this._selectedOptions.length;this._isDropdownOpen=!0;let c;if(this._optionBuilder){let s=this._optionBuilder;c=(m,f)=>s(m,this._filterText,f)}let _={options:this._options,multiple:this._multiple,selectedValues:[...this._values],id:`forge-autocomplete-${this._identifier}`,asyncStyle:"skeleton",optionLimit:this._optionLimit,popupClasses:this._popupClasses,headerBuilder:this._popupHeaderBuilder,footerBuilder:this._popupFooterBuilder,transform:s=>{if(this._filterText){let m=Y(s,this._filterText);if(m)return m}return s},allowBusy:!0,optionBuilder:c,syncWidth:this._syncPopupWidth,observeScroll:this._observeScroll,observeScrollThreshold:this._observeScrollThreshold,scrollEndListener:this._dropdownScrollEndListener,activeChangeCallback:this._activeChangeListener,targetWidthCallback:this._targetWidthCallback,selectCallback:s=>this._onSelect(s),closeCallback:()=>this._closeDropdown()};if(this._adapter.show(_,this._popupTarget),this._adapter.toggleHostAttribute(o.attributes.OPEN,this._isDropdownOpen),e){this._options.length&&this._adapter.setBusyVisibility(!0);try{await this._executeFilter(l)}catch(s){console.error(s)}this._updateSelectedOptions(this._values)}this._pendingFilterPromises.length||this._dropdownReady({userTriggered:t,activateFirst:i,activateSelected:n})}_dropdownReady({userTriggered:e=!0,activateFirst:t=!1,activateSelected:i=!1}={}){if(!this._isDropdownOpen||!this._options.length||e&&!this._adapter.hasFocus()){this._closeDropdown();return}this._sortSelectedOptions(),this._adapter.setBusyVisibility(!1),this._adapter.setOptions(this._options),this._adapter.setSelectedOptions(this._selectedOptions),this._adapter.setDismissListener(this._dismissListener),i&&this._selectedOptions.length?this._adapter.activateSelectedOption():t&&this._adapter.activateFirstOption()}_closeDropdown(){this._multiple&&(this._filterText=""),this._isDropdownOpen=!1,this._adapter.hide(this._dismissListener),this._sortSelectedOptions(),this._adapter.toggleHostAttribute(o.attributes.OPEN,this._isDropdownOpen)}_sortSelectedOptions(){if(this._multiple&&this._selectedOptions.length&&b(this._options,0)){let e=[],t=[];this._options.forEach(i=>{this._selectedOptions.find(n=>v(n,i.value,this._matchKey))?e.push(i):t.push(i)}),this._options=[...e,...t]}}async _onSelect(e,t=!0){if(this._valueChanging)return;if(this._mode==="stateless"){let n={value:e};this._adapter.emitHostEvent(o.events.SELECT,n,!0,!0)&&(this._filterText="",this._multiple||this._closeDropdown());return}let i=()=>{let n=this._flatOptions,l=n.find(s=>v(s,e,this._matchKey)),c=l?l.value:"",_=l?l.label:"";if(this._multiple){let s=n.findIndex(f=>v(f,e,this._matchKey));if(s>=0){let f=this._selectedOptions.some(me=>v(me,e,this._matchKey));this._adapter.toggleOptionMultiple(s,f)}let m=he(this._selectedOptions,c);if(m){let f=this._selectedOptions.indexOf(m);this._selectedOptions.splice(f,1)}else this._selectedOptions.push(l)}else h(c)?(this._selectedOptions[0]=l,this._filterText=_):(this._selectedOptions=[],this._filterText="");if(this._isDropdownOpen&&this._adapter.setSelectedOptions(this._selectedOptions),this._values=this._selectedOptions.map(s=>s.value),this._adapter.setSelectedText(this._getSelectedText()),!L.isMobile&&t&&this._adapter.selectInputValue(),this._multiple){let s=n.findIndex(f=>v(f,e,this._matchKey)),m=this._values.includes(e);this._adapter.toggleOptionMultiple(s,m)}this._emitChangeEvent(),this._tryUpdateDropdownPosition()};this._isDropdownOpen&&!this._multiple&&this._closeDropdown(),typeof this._beforeValueChange=="function"?(this._valueChanging=Promise.resolve(this._beforeValueChange.call(null,e,this._matchKey)),await this._valueChanging?i():this._tryUpdateDropdownPosition(),this._valueChanging=void 0):i()}_selectActiveOption(e=!0){let t=this._adapter.getActiveOptionIndex();if(typeof t=="number"&&t>=0){let i=this._flatOptions[t];i&&this._onSelect(i.value,e)}}_emitChangeEvent(){this._adapter.emitHostEvent(o.events.CHANGE,this._getValue(),!0)}_tryUpdateDropdownPosition(){this._isDropdownOpen&&this._adapter.queueDropdownPositionUpdate()}_getValue(){return this._values?this._values.length?this._multiple?[...this._values]:this._values[0]:this._multiple?[]:null:null}_getSelectedText(){var e,t;return this._adapter.isWrappingChipField()?"":this._selectedTextBuilder?this._selectedTextBuilder(this._selectedOptions):this._multiple?this._values.length?this._values.length===1?(t=(e=this._selectedOptions[0])==null?void 0:e.label)!=null?t:"":`${this._values.length} options selected`:"":this._selectedOptions.filter(i=>i&&i.label).map(i=>i.label).join(" ").trim()}_onDismiss(){this._closeDropdown()}async _applyValue(e){let t=[];this._selectedOptions=[],Array.isArray(e)?t=e:t=h(e)?[e]:[],!this._multiple&&t.length>1&&(t=[t[0]]),b(t,0)?(this._values=t.map(n=>n.value),this._selectedOptions=t):this._values=t;let i=this._flatOptions;if(t.length&&i.length&&this._updateSelectedOptions(t),this._values.length&&!this._selectedOptions.length&&this._filter&&this._isInitialized){try{await this._executeFilter(!1,!0)}catch(n){console.error(n)}this._updateSelectedOptions(this._values)}this._multiple?this._filterText="":this._filterText=this._selectedOptions.length?this._selectedOptions[0].label:"",this._isInitialized&&this._adapter.setSelectedText(this._getSelectedText()),this._isDropdownOpen&&this._adapter.setSelectedOptions(this._selectedOptions)}_updateSelectedOptions(e){let t=[...this._flatOptions,...this._selectedOptions];if(this._selectedOptions.length&&(this._selectedOptions=[]),b(e,0))for(let i of e){let n=t.find(l=>v(l,i.value,this._matchKey));n?this._selectedOptions.push(n):this._selectedOptions.push(i)}else for(let i of e){let n=t.find(l=>v(l,i,this._matchKey));n?this._selectedOptions.push(n):this._allowUnmatched&&this._selectedOptions.push({label:i,value:i})}}get mode(){return this._mode}set mode(e){this._mode!==e&&(this._mode=e,this._mode==="stateless"&&(this._selectedOptions=[],this._isDropdownOpen&&this._closeDropdown()),this._adapter.setHostAttribute(o.attributes.MODE,this._mode))}get multiple(){return this._multiple}set multiple(e){this._multiple!==e&&(this._multiple=e,this._adapter.setHostAttribute(o.attributes.MULTIPLE,h(this._multiple)?this._multiple.toString():""))}get value(){return this._getValue()}set value(e){let t=[];e==null?t=[]:Array.isArray(e)?t=JSON.parse(JSON.stringify(e)):S(e)?t=[e]:t=[JSON.parse(JSON.stringify(e))],(t.length!==this._values.length||t.some(n=>!this._values.includes(n)))&&this._applyValue(e)}get filterOnFocus(){return this._filterOnFocus}set filterOnFocus(e){this._filterOnFocus!==e&&(this._filterOnFocus=e,this._adapter.setHostAttribute(o.attributes.FILTER_ON_FOCUS,h(this._filterOnFocus)?this._filterOnFocus.toString():""))}get filterFocusFirst(){return this._filterFocusFirst}set filterFocusFirst(e){this._filterFocusFirst!==e&&(this._filterFocusFirst=e,this._adapter.toggleHostAttribute(o.attributes.FILTER_FOCUS_FIRST,this._filterFocusFirst))}get allowUnmatched(){return this._allowUnmatched}set allowUnmatched(e){this._allowUnmatched!==e&&(this._allowUnmatched=e,h(this._allowUnmatched)&&this._adapter.setHostAttribute(o.attributes.ALLOW_UNMATCHED,this._allowUnmatched.toString()))}get matchKey(){return this._matchKey}set matchKey(e){this._matchKey!==e&&(this._matchKey=e)}get popupTarget(){return this._popupTarget}set popupTarget(e){this._popupTarget!==e&&(this._popupTarget=e)}get filterText(){return this._filterText}set filterText(e){this._filterText!==e&&(this._filterText=this._allowUnmatched?e:"",this._isInitialized&&this._allowUnmatched&&(this._adapter.setInputValue(this._filterText),this._isDropdownOpen&&this._debounceFilter({checkFocus:!1})))}get popupClasses(){return Array.isArray(this._popupClasses)?[...this._popupClasses]:[this._popupClasses]}set popupClasses(e){this._popupClasses!==e&&(this._popupClasses=Array.isArray(e)?[...e]:[e])}set popupHeaderBuilder(e){this._popupHeaderBuilder=e}set popupFooterBuilder(e){this._popupFooterBuilder=e}get syncPopupWidth(){return this._syncPopupWidth}set syncPopupWidth(e){this._syncPopupWidth!==e&&(this._syncPopupWidth=e)}get optionLimit(){return this._optionLimit}set optionLimit(e){this._optionLimit!==e&&(this._optionLimit=e)}get debounce(){return this._debounce}set debounce(e){this._debounce!==e&&(this._debounce=e,this._isInitialized&&this._setFilterCallback(),this._adapter.setHostAttribute(o.attributes.DEBOUNCE,h(this._debounce)?this._debounce.toString():""))}get optionBuilder(){return this._optionBuilder}set optionBuilder(e){this._optionBuilder=e}get filter(){return this._filter}set filter(e){this._filter!==e&&(this._filter=e,this._isInitialized&&this._values.length&&!this._flatOptions.length&&this._filter&&this._executeFilter().then(()=>{this._updateSelectedOptions(this._values),this._adapter.setSelectedText(this._getSelectedText())}))}get selectedTextBuilder(){return this._selectedTextBuilder}set selectedTextBuilder(e){this._selectedTextBuilder=e,this._selectedOptions.length&&this._adapter.setSelectedText(this._getSelectedText())}get observeScroll(){return this._observeScroll}set observeScroll(e){this._observeScroll=e}get observeScrollThreshold(){return this._observeScrollThreshold}set observeScrollThreshold(e){this._observeScrollThreshold=e}appendOptions(e){this._isDropdownOpen&&(this._options=[...this._options,...e],this._adapter.appendOptions(e))}get isInitialized(){return this._isInitialized}get open(){return this._isDropdownOpen}set open(e){this._isDropdownOpen!==e&&(e?this._showDropdown({userTriggered:!1}):this._closeDropdown())}get beforeValueChange(){return this._beforeValueChange}set beforeValueChange(e){e!==this._beforeValueChange&&(this._beforeValueChange=e)}get popupElement(){return this._adapter.getPopupElement()}};var Oe="<template><slot></slot></template>",Ie=":host{display:block}:host([hidden]){display:none}",r=class extends ie{constructor(){super();X.define([V,z,q]),H(this,Oe,Ie),this._foundation=new E(new I(this))}static get observedAttributes(){return[o.attributes.MODE,o.attributes.MULTIPLE,o.attributes.DEBOUNCE,o.attributes.FILTER_ON_FOCUS,o.attributes.FILTER_FOCUS_FIRST,o.attributes.ALLOW_UNMATCHED,o.attributes.POPUP_TARGET,o.attributes.POPUP_CLASSES,o.attributes.OBSERVE_SCROLL,o.attributes.OBSERVE_SCROLL_THRESHOLD,o.attributes.OPTION_LIMIT,o.attributes.SYNC_POPUP_WIDTH,o.attributes.OPEN,o.attributes.MATCH_KEY,o.attributes.FILTER_TEXT]}connectedCallback(){this.querySelector(o.selectors.INPUT)?this._foundation.initialize():M(this,o.selectors.INPUT).then(()=>this._foundation.initialize())}disconnectedCallback(){this._foundation.disconnect()}attributeChangedCallback(e,t,i){switch(super.attributeChangedCallback(e,t,i),e){case o.attributes.MODE:this.mode=i;break;case o.attributes.MULTIPLE:this.multiple=g(i);break;case o.attributes.DEBOUNCE:this.debounce=P(i);break;case o.attributes.FILTER_ON_FOCUS:this.filterOnFocus=g(i);break;case o.attributes.FILTER_FOCUS_FIRST:this.filterFocusFirst=g(i);break;case o.attributes.ALLOW_UNMATCHED:this.allowUnmatched=g(i);break;case o.attributes.POPUP_TARGET:this.popupTarget=i;break;case o.attributes.OPEN:this.open=g(i);break;case o.attributes.MATCH_KEY:this.matchKey=i;break;case o.attributes.FILTER_TEXT:this.filterText=i;break}}appendOptions(e){this._foundation.appendOptions(e)}openDropdown(){this.open=!0}closeDropdown(){this.open=!1}};p([a()],r.prototype,"mode",2),p([a()],r.prototype,"multiple",2),p([a()],r.prototype,"value",2),p([a()],r.prototype,"debounce",2),p([a()],r.prototype,"filterOnFocus",2),p([a()],r.prototype,"filterFocusFirst",2),p([a()],r.prototype,"allowUnmatched",2),p([a()],r.prototype,"popupTarget",2),p([a()],r.prototype,"filterText",2),p([a()],r.prototype,"optionBuilder",2),p([a()],r.prototype,"filter",2),p([a()],r.prototype,"selectedTextBuilder",2),p([a()],r.prototype,"open",2),p([a()],r.prototype,"matchKey",2),p([a({set:!1})],r.prototype,"isInitialized",2),p([a({set:!1})],r.prototype,"popupElement",2),p([a()],r.prototype,"beforeValueChange",2),r=p([R({name:o.elementName,dependencies:[le,oe,te,ee,Q,ne,Z,J]})],r);var _e=class extends ${constructor(e){super(e)}_build(){let e=document.createElement(o.elementName);return this._attachTextField(e),e}get textFieldDelegate(){return this._textFieldDelegate}get value(){return this._element.value}set value(e){this._element.value=e}get disabled(){return this._textFieldDelegate.inputElement.disabled}set disabled(e){this._textFieldDelegate.inputElement.disabled=e}get invalid(){return this._textFieldDelegate.invalid||!1}set invalid(e){this._textFieldDelegate.invalid=e}onChange(e){this._element.addEventListener(o.events.CHANGE,t=>e(t.detail))}onFocus(e){this._textFieldDelegate.inputElement.addEventListener("focus",t=>e(t))}onBlur(e){this._textFieldDelegate.inputElement.addEventListener("blur",t=>e(t))}_attachTextField(e){var i,n,l,c,_,s;let t={props:T({},(n=(i=this._config.options)==null?void 0:i.textFieldDelegateConfig)==null?void 0:n.props),options:T({},(c=(l=this._config.options)==null?void 0:l.textFieldDelegateConfig)==null?void 0:c.options)};t.options||(t.options={}),((_=this._config.options)==null?void 0:_.useDropdownIcon)!==!1&&!((s=t.options)!=null&&s.trailingElement)&&(t.options.trailingElement=this._createDropdownIconElement()),this._textFieldDelegate=new pe(t),e.appendChild(this._textFieldDelegate.element)}_createDropdownIconElement(){let e={props:{slot:"trailing",name:"arrow_drop_down"},options:{attributes:{"forge-dropdown-icon":""}}};return new j(e).element}};function Kt(){U(r)}export{o as a,de as b,I as c,ce as d,b as e,he as f,v as g,E as h,r as i,_e as j,Kt as k};
|
|
7
|
-
//# sourceMappingURL=chunk.VUGNSK4K.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/autocomplete/autocomplete-constants.ts", "../../src/autocomplete/autocomplete-adapter.ts", "../../src/autocomplete/autocomplete-utils.ts", "../../src/autocomplete/autocomplete-foundation.ts", "../../src/autocomplete/autocomplete.ts", "../../src/autocomplete/autocomplete-component-delegate.ts", "../../src/autocomplete/index.ts"],
|
|
4
|
-
"sourcesContent": ["import { COMPONENT_NAME_PREFIX, KEYSTROKE_DEBOUNCE_THRESHOLD } from '../constants';\nimport { IListItemComponent } from '../list';\nimport { IListDropdownConfig, IListDropdownOption, IListDropdownOptionGroup, ListDropdownOptionGroupBuilder } from '../list-dropdown';\nimport { IPopupPosition } from '../popup';\nimport { FIELD_CONSTANTS } from '../field/field-constants';\n\nconst elementName: keyof HTMLElementTagNameMap = `${COMPONENT_NAME_PREFIX}autocomplete`;\n\nconst attributes = {\n MODE: 'mode',\n MULTIPLE: 'multiple',\n DEBOUNCE: 'debounce',\n FILTER_ON_FOCUS: 'filter-on-focus',\n FILTER_FOCUS_FIRST: 'filter-focus-first',\n ALLOW_UNMATCHED: 'allow-unmatched',\n POPUP_TARGET: 'popup-target',\n POPUP_CLASSES: 'popup-classes',\n OPTION_LIMIT: 'option-limit',\n OBSERVE_SCROLL: 'observe-scroll',\n OBSERVE_SCROLL_THRESHOLD: 'observe-scroll-threshold',\n SYNC_POPUP_WIDTH: 'sync-popup-width',\n OPEN: 'open',\n MATCH_KEY: 'match-key',\n FILTER_TEXT: 'filter-text',\n DROPDOWN_ICON_OPEN: 'data-forge-dropdown-icon-open'\n};\n\nconst selectors = {\n INPUT: FIELD_CONSTANTS.selectors.INPUT,\n DROPDOWN_ICON: '[data-forge-dropdown-icon],[data-forge-dropdown-icon],[forge-dropdown-icon],.forge-dropdown-icon',\n CLEAR_BUTTON: '[data-forge-autocomplete-clear],[forge-autocomplete-clear]'\n};\n\nconst numbers = {\n DEFAULT_DEBOUNCE_TIME: KEYSTROKE_DEBOUNCE_THRESHOLD,\n NUM_SKELETON_ITEMS: 3\n};\n\nconst events = {\n CHANGE: `${elementName}-change`,\n SELECT: `${elementName}-select`,\n SCROLLED_BOTTOM: `${elementName}-scrolled-bottom`\n};\n\nexport const AUTOCOMPLETE_CONSTANTS = {\n elementName,\n attributes,\n selectors,\n numbers,\n events\n};\n\nexport type AutocompleteOptionBuilder<T = any> = (option: IAutocompleteOption<T>, filterText: string, parentElement: IListItemComponent) => HTMLElement;\nexport type AutocompleteOptionGroupBuilder<T = any> = ListDropdownOptionGroupBuilder<T>;\nexport type AutocompleteFilterCallback<T = any> = (filterText: string, value: T | null) => IAutocompleteOption<T>[] | IAutocompleteOptionGroup<T>[] | Promise<IAutocompleteOption<T>[] | IAutocompleteOptionGroup<T>[]>;\nexport type AutocompleteSelectedTextBuilder<T = any> = (selectedOptions: Array<IAutocompleteOption<T>>) => string;\n\nexport enum AutocompleteMode {\n Default = 'default',\n Stateless = 'stateless'\n}\n\nexport interface IAutocompleteOption<T = any> extends IListDropdownOption<T> {}\nexport interface IAutocompleteOptionGroup<T = any> extends IListDropdownOptionGroup<T> {}\n\nexport interface IAutocompletePopupConfiguration {\n filterText: string;\n popupTarget: string;\n dropdownConfig: IListDropdownConfig;\n popupClasses: string[];\n popupOffset: IPopupPosition;\n syncPopupWidth: boolean;\n listener: (value: string) => void;\n scrollEndListener: () => void;\n}\n\nexport interface IAutocompleteSelectEventData<T = any> {\n value: T;\n}\n", "import { getShadowElement, deepQuerySelectorAll, getActiveElement, toggleAttribute } from '@tylertech/forge-core';\nimport { BaseAdapter, IBaseAdapter } from '../core/base/base-adapter';\nimport { IAutocompleteComponent } from './autocomplete';\nimport { AUTOCOMPLETE_CONSTANTS, IAutocompleteOption, IAutocompleteOptionGroup } from './autocomplete-constants';\nimport { TEXT_FIELD_CONSTANTS } from '../text-field';\nimport { IListDropdown, IListDropdownConfig, ListDropdown } from '../list-dropdown';\nimport { CHIP_FIELD_CONSTANTS } from '../chip-field';\nimport { IPopupComponent, POPUP_CONSTANTS } from '../popup';\n\nexport interface IAutocompleteAdapter extends IBaseAdapter {\n setInputElement(): HTMLInputElement;\n setInputAttribute(name: string, value: string): void;\n addInputListener(type: string, listener: (evt: Event) => void): void;\n removeInputListener(type: string, listener: (evt: Event) => void): void;\n initializeInputAccessibility(identifier: string): void;\n isWrappingChipField(): boolean;\n show(config: IListDropdownConfig, popupTarget: string): void;\n hide(listener: () => void): void;\n focus(): void;\n setOptions(options: IAutocompleteOption[] | IAutocompleteOptionGroup[]): void;\n appendOptions(options: IAutocompleteOption[] | IAutocompleteOptionGroup[]): void;\n setSelectedText(value: string): void;\n getInputValue(): string;\n setInputValue(value: string): void;\n selectInputValue(): void;\n setDismissListener(listener: () => void): void;\n toggleOptionMultiple(index: number, selected: boolean): void;\n isFocusWithinPopup(target: HTMLElement): boolean;\n hasFocus(): boolean;\n hasInputElement(): boolean;\n setDropdownIconListener(type: string, listener: EventListener): void;\n removeDropdownIconListener(type: string, listener: EventListener): void;\n setClearButtonListener(type: string, listener: EventListener): void;\n removeClearButtonListener(type: string, listener: EventListener): void;\n getPopupElement(): HTMLElement | null;\n propagateKey(key: string): void;\n updateActiveDescendant(id: string): void;\n getTargetElementWidth(selector: string): number;\n activateFirstOption(): void;\n activateSelectedOption(): void;\n activateOptionByIndex(value: number): void;\n setBusyVisibility(busy: boolean): void;\n getActiveOptionIndex(): number | null;\n clearActiveOption(): void;\n setSelectedOptions(options: IAutocompleteOption[]): void;\n queueDropdownPositionUpdate(): void;\n}\n\n/**\n * The DOM adapter for the `<forge-autocomplete>` element.\n */\nexport class AutocompleteAdapter extends BaseAdapter<IAutocompleteComponent> implements IAutocompleteAdapter {\n private _inputElement: HTMLInputElement;\n private _listDropdown?: IListDropdown;\n private _targetElement?: HTMLElement;\n \n constructor(component: IAutocompleteComponent) {\n super(component);\n this.setInputElement();\n }\n\n public setInputElement(): HTMLInputElement {\n const inputElements = deepQuerySelectorAll(this._component, AUTOCOMPLETE_CONSTANTS.selectors.INPUT, false);\n if (inputElements.length) {\n this._inputElement = inputElements[0] as HTMLInputElement;\n }\n return this._inputElement;\n }\n\n public setInputAttribute(name: string, value: string): void {\n this._inputElement.setAttribute(name, value);\n }\n\n public addInputListener(type: string, listener: (evt: Event) => void): void {\n this._inputElement.addEventListener(type, listener);\n }\n\n public removeInputListener(type: string, listener: (evt: Event) => void): void {\n this._inputElement.removeEventListener(type, listener);\n }\n\n public initializeInputAccessibility(identifier: string): void {\n this._inputElement.setAttribute('autocomplete', 'off');\n this._inputElement.setAttribute('role', 'combobox');\n this._inputElement.setAttribute('aria-live', 'polite');\n this._inputElement.setAttribute('aria-atomic', 'true');\n this._inputElement.setAttribute('aria-haspopup', 'true');\n this._inputElement.setAttribute('aria-expanded', 'false');\n this._inputElement.setAttribute('aria-autocomplete', 'list');\n }\n\n public isWrappingChipField(): boolean {\n return !!this._component.querySelector(CHIP_FIELD_CONSTANTS.elementName);\n }\n\n public show(config: IListDropdownConfig, popupTarget: string): void {\n this._targetElement = this._getTargetElement(popupTarget);\n if (!this._targetElement) {\n return;\n }\n this._listDropdown = new ListDropdown(this._targetElement, config);\n this._listDropdown.open();\n this._inputElement.setAttribute('aria-expanded', 'true');\n this._inputElement.setAttribute('aria-controls', `list-dropdown-popup-${config.id}`);\n this._tryToggleDropdownIconRotation(true);\n }\n\n public hide(listener: () => void): void {\n if (!this._listDropdown) {\n return;\n }\n const { targetElement } = this._listDropdown.dropdownElement as IPopupComponent;\n targetElement.removeEventListener(POPUP_CONSTANTS.events.BLUR, listener);\n this.setBusyVisibility(false);\n this._tryToggleDropdownIconRotation(false);\n this._inputElement.removeAttribute('aria-activedescendant');\n this._inputElement.removeAttribute('aria-controls');\n this._inputElement.setAttribute('aria-expanded', 'false');\n this._listDropdown.close();\n this._listDropdown = undefined;\n }\n\n\n public setBusyVisibility(isVisible: boolean): void {\n this._listDropdown?.setBusyVisibility(isVisible);\n }\n\n public toggleOptionMultiple(index: number, selected: boolean): void {\n this._listDropdown?.toggleOptionMultiple(index, selected);\n }\n\n public setDismissListener(listener: () => void): void {\n if (!this._listDropdown || !this._listDropdown.dropdownElement) {\n return;\n }\n const dropdownElement = this._listDropdown.dropdownElement as IPopupComponent;\n if (dropdownElement.targetElement) {\n dropdownElement.targetElement.addEventListener(POPUP_CONSTANTS.events.BLUR, listener);\n }\n }\n\n public focus(): void {\n window.requestAnimationFrame(() => this._inputElement.focus());\n }\n\n public setOptions(options: IAutocompleteOption[] | IAutocompleteOptionGroup[]): void {\n this._listDropdown?.setOptions(options);\n }\n\n public appendOptions(options: IAutocompleteOption[] | IAutocompleteOptionGroup[]): void {\n this._listDropdown?.appendOptions(options);\n }\n\n public setSelectedText(value: string): void {\n this._inputElement.value = value;\n }\n\n public getInputValue(): string {\n return this._inputElement.value;\n }\n\n public setInputValue(value: string): void {\n this._inputElement.value = value;\n }\n\n public selectInputValue(): void {\n window.requestAnimationFrame(() => this._inputElement.select());\n }\n\n public isFocusWithinPopup(target: HTMLElement): boolean {\n if (!this._listDropdown || !this._listDropdown.dropdownElement) {\n return false;\n }\n return this._listDropdown.dropdownElement.contains(target);\n }\n\n public hasFocus(): boolean {\n const activeElement = getActiveElement() as HTMLElement;\n return activeElement === this._inputElement || this.isFocusWithinPopup(activeElement);\n }\n\n public hasInputElement(): boolean {\n return !!this._inputElement;\n }\n\n public setDropdownIconListener(type: string, listener: EventListener): void {\n window.requestAnimationFrame(() => {\n const dropdownIcon = this._component.querySelector(AUTOCOMPLETE_CONSTANTS.selectors.DROPDOWN_ICON);\n if (dropdownIcon) {\n dropdownIcon.addEventListener(type, listener);\n }\n });\n }\n\n public removeDropdownIconListener(type: string, listener: EventListener): void {\n const dropdownIcon = this._component.querySelector(AUTOCOMPLETE_CONSTANTS.selectors.DROPDOWN_ICON);\n if (dropdownIcon) {\n dropdownIcon.removeEventListener(type, listener);\n }\n }\n\n public setClearButtonListener(type: string, listener: EventListener): void {\n window.requestAnimationFrame(() => {\n const clearButton = this._component.querySelector(AUTOCOMPLETE_CONSTANTS.selectors.CLEAR_BUTTON);\n if (clearButton) {\n clearButton.addEventListener(type, listener);\n }\n });\n }\n\n public removeClearButtonListener(type: string, listener: EventListener): void {\n const clearButton = this._component.querySelector(AUTOCOMPLETE_CONSTANTS.selectors.CLEAR_BUTTON);\n if (clearButton) {\n clearButton.removeEventListener(type, listener);\n }\n }\n\n public propagateKey(key: string): void {\n this._listDropdown?.handleKey(key);\n }\n\n public updateActiveDescendant(id: string): void {\n if (!this._targetElement) {\n return;\n }\n toggleAttribute(this._inputElement, !!id, 'aria-activedescendant', id);\n }\n\n public getTargetElementWidth(selector: string): number {\n if (!this._targetElement) {\n this._targetElement = this._getTargetElement(selector);\n }\n return this._targetElement.getBoundingClientRect().width;\n }\n\n public getPopupElement(): HTMLElement | null {\n return this._listDropdown?.dropdownElement ?? null;\n }\n\n public activateFirstOption(): void {\n this._listDropdown?.activateFirstOption();\n }\n\n public activateSelectedOption(): void {\n this._listDropdown?.activateSelectedOption();\n }\n\n public activateOptionByIndex(value: number): void {\n this._listDropdown?.activateOption(value);\n }\n\n public getActiveOptionIndex(): number | null {\n return this._listDropdown?.getActiveOptionIndex() ?? null;\n }\n\n public clearActiveOption(): void {\n this._listDropdown?.clearActiveOption();\n }\n\n public setSelectedOptions(options: IAutocompleteOption[]): void {\n if (this._listDropdown) {\n const values = options.map(o => o.value);\n this._listDropdown.setSelectedValues(values);\n }\n }\n\n public queueDropdownPositionUpdate(): void {\n if (!this.getPopupElement()) {\n return;\n }\n // We need to wait for the next animation frame to ensure that the layout has been updated\n window.requestAnimationFrame(() => {\n const dropdownEl = this.getPopupElement() as IPopupComponent | undefined;\n dropdownEl?.position();\n });\n }\n\n private _getTargetElement(selector?: string): HTMLElement {\n return selector ? this._component.querySelector(selector) || this._getDefaultTargetElement() : this._getDefaultTargetElement();\n }\n\n private _getDefaultTargetElement(): HTMLElement {\n // This component is often used with the text-field, if so, let's target our popup around one if its internal elements for proper alignnment\n const textField = this._component.querySelector('forge-text-field');\n if (textField && textField.shadowRoot) {\n const textFieldRoot = getShadowElement(textField, TEXT_FIELD_CONSTANTS.selectors.ROOT) as HTMLElement;\n if (textFieldRoot) {\n return textFieldRoot;\n }\n }\n\n // This component is often used with the chip-field, if so, let's target our popup around one if its internal elements for proper alignnment\n const chipField = this._component.querySelector('forge-chip-field');\n if (chipField && chipField.shadowRoot) {\n const chipFieldRoot = getShadowElement(chipField, CHIP_FIELD_CONSTANTS.selectors.ROOT) as HTMLElement;\n if (chipFieldRoot) {\n return chipFieldRoot;\n }\n }\n\n return this._component.querySelector('input') || this._component;\n }\n\n private _tryToggleDropdownIconRotation(state: boolean): void {\n const dropdownIcon = this._component.querySelector(AUTOCOMPLETE_CONSTANTS.selectors.DROPDOWN_ICON) as HTMLElement;\n if (dropdownIcon) {\n toggleAttribute(dropdownIcon, state, AUTOCOMPLETE_CONSTANTS.attributes.DROPDOWN_ICON_OPEN);\n }\n }\n}\n", "import { IAutocompleteOption, IAutocompleteOptionGroup } from './autocomplete-constants';\nimport { isDefined, isObject, isDeepEqual } from '@tylertech/forge-core';\n\n/** The available option types. */\nexport enum OptionType { Option, Group }\n\n/**\n * Determines if the provided options are of the specified type.\n * @param options The options either grouped or individual.\n * @param type The type of option to detect.\n */\nexport function isOptionType(options: IAutocompleteOption[] | IAutocompleteOptionGroup[], type: OptionType): boolean {\n const isOptionGroups = options.some((o: IAutocompleteOption | IAutocompleteOptionGroup) => isDefined(o) && isObject(o) && o.hasOwnProperty('options') && (o.hasOwnProperty('text') || o.hasOwnProperty('builder')));\n const isOptionTypes = options.some((o: IAutocompleteOption | IAutocompleteOptionGroup) => isDefined(o) && isObject(o) && o.hasOwnProperty('label') && o.hasOwnProperty('value'));\n return (isOptionGroups && type === OptionType.Group) || (isOptionTypes && type === OptionType.Option);\n}\n\n/** A utility function to find the matching option in the provided options by the value provided. */\nexport function getSelectedOption(options: IAutocompleteOption[], value: string): IAutocompleteOption | undefined {\n return options.find(o => o.value === value);\n}\n\n/** A predicate function that will determine if an option value is equal regardless of primitive type or complex object type. */\nexport function optionEqualPredicate(option: IAutocompleteOption, value: any, property: string | null = null): boolean {\n if (property) {\n if (!(property in option.value) || !(property in value)) {\n return false;\n }\n return isDeepEqual(option.value[property], value[property]);\n }\n return isDeepEqual(option.value, value);\n}\n", "import { debounce, isDefined, isString, Platform, randomChars } from '@tylertech/forge-core';\nimport { highlightTextHTML } from '../core';\nimport { IListItemComponent } from '../list';\nimport { IListDropdownConfig, IListDropdownOption, ListDropdownAsyncStyle, ListDropdownFooterBuilder, ListDropdownHeaderBuilder, ListDropdownOptionBuilder } from '../list-dropdown';\nimport { IListDropdownAwareFoundation, ListDropdownAwareFoundation } from '../list-dropdown/list-dropdown-aware-foundation';\nimport { IAutocompleteAdapter } from './autocomplete-adapter';\nimport { AutocompleteFilterCallback, AutocompleteMode, AutocompleteOptionBuilder, AutocompleteSelectedTextBuilder, AUTOCOMPLETE_CONSTANTS, IAutocompleteOption, IAutocompleteOptionGroup, IAutocompleteSelectEventData } from './autocomplete-constants';\nimport { getSelectedOption, isOptionType, optionEqualPredicate, OptionType } from './autocomplete-utils';\n\nexport interface IAutocompleteFoundation extends IListDropdownAwareFoundation {\n mode: AutocompleteMode;\n multiple: boolean;\n value: string | string[] | IAutocompleteOption | IAutocompleteOption[] | null | undefined;\n debounce: number;\n filterOnFocus: boolean;\n filterFocusFirst: boolean;\n allowUnmatched: boolean;\n popupTarget: string;\n filterText: string;\n optionBuilder: AutocompleteOptionBuilder | null | undefined;\n filter: AutocompleteFilterCallback | null | undefined;\n selectedTextBuilder: AutocompleteSelectedTextBuilder;\n isInitialized: boolean;\n open: boolean;\n matchKey: string | null | undefined;\n appendOptions(options: IAutocompleteOption[] | IAutocompleteOptionGroup[]): void;\n beforeValueChange: (value: any) => boolean | Promise<boolean>;\n}\n\n/**\n * The foundation class behind the `<forge-autocomplete>` element.\n */\nexport class AutocompleteFoundation extends ListDropdownAwareFoundation implements IAutocompleteFoundation {\n private _isInitialized = false;\n private _isDropdownOpen = false;\n private _mode: AutocompleteMode = AutocompleteMode.Default;\n private _multiple = false;\n private _debounce = AUTOCOMPLETE_CONSTANTS.numbers.DEFAULT_DEBOUNCE_TIME;\n private _allowUnmatched = false;\n private _popupTarget: string;\n private _filterOnFocus = true;\n private _filterFocusFirst = true;\n private _optionBuilder?: AutocompleteOptionBuilder | null;\n private _filter?: AutocompleteFilterCallback | null;\n private _selectedTextBuilder: AutocompleteSelectedTextBuilder;\n private _options: IAutocompleteOption[] | IAutocompleteOptionGroup[] = [];\n private _filterText = '';\n private _selectedOptions: IAutocompleteOption[] = [];\n private _values: any[] = [];\n private _pendingFilterPromises: Array<Promise<IAutocompleteOption[] | IAutocompleteOptionGroup[]>> = [];\n private _identifier: string;\n private _matchKey?: string | null = null;\n private _filterFn: () => Promise<void>;\n private _clickListener: (evt: MouseEvent) => void;\n private _focusListener: (evt: FocusEvent) => void;\n private _blurListener: (evt: FocusEvent) => void;\n private _inputListener: (evt: KeyboardEvent) => void;\n private _keydownListener: (evt: KeyboardEvent) => void;\n private _dropdownIconClickListener: (evt: MouseEvent) => void;\n private _dropdownIconMouseDownListener: (evt: MouseEvent) => void;\n private _clearButtonListener: (evt: MouseEvent) => void;\n private _dropdownScrollEndListener: () => void;\n private _dismissListener: () => void;\n private _activeChangeListener: (id: string) => void;\n private _targetWidthCallback: () => number;\n private _beforeValueChange: (value: any) => boolean | Promise<boolean>;\n private _valueChanging: Promise<boolean> | undefined;\n\n constructor(private _adapter: IAutocompleteAdapter) {\n super();\n this._clickListener = evt => this._onClick(evt);\n this._focusListener = () => this._onFocus();\n this._blurListener = evt => this._onBlur(evt);\n this._keydownListener = evt => this._onKeydown(evt);\n this._dropdownIconClickListener = evt => this._onDropdownIconClick(evt);\n this._dropdownScrollEndListener = () => this._onDropdownScrollEnd();\n this._dropdownIconMouseDownListener = evt => this._onDropdownIconMouseDown(evt);\n this._clearButtonListener = evt => this._onClear(evt);\n this._dismissListener = () => this._onDismiss();\n this._activeChangeListener = id => this._adapter.updateActiveDescendant(id);\n this._targetWidthCallback = () => this._adapter.getTargetElementWidth(this._popupTarget);\n this._identifier = randomChars();\n }\n\n public async initialize(): Promise<void> {\n if (!this._adapter.hasInputElement() && !this._adapter.setInputElement()) {\n throw new Error('An input element is required as a child of the autocomplete component.');\n }\n\n this._setInputListener();\n this._setFilterCallback();\n this._attachListeners();\n this._initializeAccessibility();\n\n if (this._values.length) {\n if (!this._selectedOptions.length) {\n try {\n await this._executeFilter();\n } catch (e) {\n console.error(e);\n }\n this._updateSelectedOptions(this._values);\n }\n this._adapter.setSelectedText(this._getSelectedText());\n }\n\n this._isInitialized = true;\n }\n\n public disconnect(): void {\n if (this._isInitialized) {\n this._detachListeners();\n this._isInitialized = false;\n }\n if (this._isDropdownOpen) {\n this._closeDropdown();\n }\n }\n\n private _attachListeners(): void {\n this._adapter.addInputListener('click', this._clickListener);\n this._adapter.addInputListener('focus', this._focusListener);\n this._adapter.addInputListener('blur', this._blurListener);\n this._adapter.addInputListener('input', this._inputListener);\n this._adapter.addInputListener('keydown', this._keydownListener);\n this._adapter.setDropdownIconListener('click', this._dropdownIconClickListener);\n this._adapter.setDropdownIconListener('mousedown', this._dropdownIconMouseDownListener);\n this._adapter.setClearButtonListener('click', this._clearButtonListener);\n }\n\n private _detachListeners(): void {\n this._adapter.removeInputListener('click', this._clickListener);\n this._adapter.removeInputListener('focus', this._focusListener);\n this._adapter.removeInputListener('blur', this._blurListener);\n this._adapter.removeInputListener('input', this._inputListener);\n this._adapter.removeInputListener('keydown', this._keydownListener);\n this._adapter.removeDropdownIconListener('click', this._dropdownIconClickListener);\n this._adapter.removeDropdownIconListener('mousedown', this._dropdownIconMouseDownListener);\n this._adapter.removeClearButtonListener('click', this._clearButtonListener);\n }\n\n private _setInputListener(): void {\n this._inputListener = (evt: KeyboardEvent) => this._onInput(evt);\n }\n\n private _setFilterCallback(): void {\n this._filterFn = isDefined(this._debounce) && this._debounce > 0 ? debounce(this._debounceFilter, this._debounce, false) : this._debounceFilter;\n }\n\n private _initializeAccessibility(): void {\n this._adapter.initializeInputAccessibility(this._identifier);\n }\n\n private get _flatOptions(): IAutocompleteOption[] {\n if (isOptionType(this._options, OptionType.Group)) {\n return (this._options as IAutocompleteOptionGroup[]).reduce((previousValue, currentValue) => previousValue.concat(currentValue.options), [] as IAutocompleteOption[]);\n }\n return this._options as IAutocompleteOption[];\n }\n\n private _onClick(evt: MouseEvent): void {\n if (!this._isDropdownOpen && this._filterOnFocus) {\n this._showDropdown();\n }\n }\n\n private _onDropdownIconMouseDown(evt: MouseEvent): void {\n evt.preventDefault(); // Always avoid changing focus when clicking the dropdown\n }\n\n private _onDropdownIconClick(evt: MouseEvent): void {\n if (!this._isDropdownOpen) {\n this._adapter.focus();\n window.requestAnimationFrame(() => this._showDropdown());\n } else {\n this._closeDropdown();\n }\n }\n\n private _onClear(evt: MouseEvent): void {\n this._clearValue();\n this._adapter.setSelectedText(this._getSelectedText());\n }\n\n private _onDropdownScrollEnd(): void {\n this._adapter.emitHostEvent(AUTOCOMPLETE_CONSTANTS.events.SCROLLED_BOTTOM);\n }\n\n private _onFocus(): void {\n if (!this._isDropdownOpen && this._adapter.getInputValue() && !Platform.isMobile) {\n this._adapter.selectInputValue();\n }\n }\n\n private _onBlur(evt: FocusEvent): void {\n // If the blur event was triggered by an element within the popup then ignore it\n if (this._adapter.isFocusWithinPopup(evt.relatedTarget as HTMLElement)) {\n return;\n }\n\n this._applyBlur();\n }\n\n private _applyBlur(): void {\n if (this._isDropdownOpen) {\n this._closeDropdown();\n }\n\n // If we are in stateless mode, we don't need to do anything further\n if (this._mode === AutocompleteMode.Stateless) {\n return;\n }\n\n if (!this._selectedOptions.length) {\n if (!this._allowUnmatched) {\n this._filterText = '';\n this._adapter.setSelectedText('');\n }\n } else {\n this._adapter.setSelectedText(this._getSelectedText());\n }\n }\n\n private _onInput(evt: KeyboardEvent): void {\n if (this._selectedOptions.length && !this._multiple && (!this._adapter.getInputValue() || this._allowUnmatched) && !this._adapter.isWrappingChipField()) {\n this._selectedOptions = [];\n this._values = [];\n this._emitChangeEvent();\n }\n this._filterText = this._adapter.getInputValue();\n this._filterFn();\n }\n\n private async _debounceFilter({ checkFocus = true } = {}): Promise<void> {\n // There is the potential that the user could have started a filter, then moved focus to another element\n // while a debounced filter is running. This check detects that scenario and stops all pending filters.\n if (!checkFocus && !this._adapter.hasFocus()) {\n this._pendingFilterPromises = [];\n if (this._isDropdownOpen) {\n this._closeDropdown();\n }\n return;\n }\n\n // Keep track of these variables so we can use them when each filter callback completes\n const filterText = this._filterText; // Filter text just before the execution\n const filterPromise = this._executeFilter(); // Execute the filter and keep track of the filter promise object for use after it resolves\n\n // Keep track of all pending promises\n this._pendingFilterPromises.push(filterPromise);\n\n // If the dropdown is open, show the spinner and execute the filter. If not open, then we need to\n // show the dropdown (which will handle showing the spinner and executing the filter for us) so\n // we use the promise from that method instead.\n if (this._isDropdownOpen) {\n this._adapter.setBusyVisibility(true);\n } else {\n this._showDropdown({ filter: false });\n }\n\n try {\n await filterPromise;\n } catch {\n // When an exception occurs, we just flush the pending promises and clean up\n this._pendingFilterPromises = [];\n if (this._isDropdownOpen) {\n this._closeDropdown();\n }\n return;\n }\n\n // We only continue if the filter text before this result matches the latest filter text\n if (filterText === this._filterText) {\n this._pendingFilterPromises = [];\n this._onFilterComplete();\n } else {\n // If this is not the latest filter result, we ignore it and remove it from the pending promises\n const promiseIndex = this._pendingFilterPromises.indexOf(filterPromise);\n if (promiseIndex !== -1) {\n this._pendingFilterPromises.splice(promiseIndex, 1);\n }\n }\n }\n\n private _onKeydown(evt: KeyboardEvent): void {\n switch (evt.key) {\n case 'Tab':\n if (this._isDropdownOpen && !this._multiple) {\n this._selectActiveOption(false);\n }\n break;\n case 'Esc':\n case 'Escape':\n if (this._isDropdownOpen) {\n evt.preventDefault();\n evt.stopPropagation();\n this._closeDropdown();\n }\n break;\n case 'Down':\n case 'ArrowDown':\n evt.preventDefault();\n if (!this._isDropdownOpen) {\n this._showDropdown({ activateFirst: true, activateSelected: true });\n } else {\n this._adapter.propagateKey(evt.key);\n }\n break;\n case 'Up':\n case 'ArrowUp':\n evt.preventDefault();\n if (this._isDropdownOpen) {\n this._adapter.propagateKey(evt.key);\n }\n break;\n case 'Enter':\n case 'Home':\n case 'End':\n if (this._isDropdownOpen) {\n if (evt.key === 'Enter') {\n evt.stopPropagation();\n }\n evt.preventDefault();\n this._adapter.propagateKey(evt.key);\n }\n break;\n case 'Backspace':\n case 'Delete':\n const input = evt.target as HTMLInputElement;\n const value = this._adapter.getInputValue();\n const isRemovingAllChars = input.value.substring(input.selectionStart as number, input.selectionEnd as number) === input.value;\n const isBackspacingLastChar = value.length === 1 && input.selectionEnd === 1;\n const isDeletingLastChar = value.length === 1 && input.selectionEnd === 0;\n const isEmpty = !value || isRemovingAllChars || isBackspacingLastChar || isDeletingLastChar;\n \n // We only clear the value on empty when not around a chip-field and NOT in multiple mode\n if (!this._adapter.isWrappingChipField() && isEmpty && !this._multiple && this._values.length) {\n this._clearValue();\n }\n break;\n }\n }\n\n private _executeFilter(sendFilterText = true, sendValue = false): Promise<IAutocompleteOption[] | IAutocompleteOptionGroup[]> {\n if (!this._filter || typeof this._filter !== 'function') {\n throw new Error('A filter callback must be provided. Did you set the \"filter\" property?');\n }\n const filter = this._filter;\n\n const filterText = sendFilterText ? this._filterText : '';\n const value = sendValue ? this._getValue() : null;\n\n return new Promise<IAutocompleteOption[] | IAutocompleteOptionGroup[]>((resolve, reject) => {\n return Promise.resolve(filter(filterText, value))\n .then(options => {\n this._options = options;\n resolve(this._options);\n })\n .catch(e => reject(`An unexpected error occurred while filtering: ${e}`));\n });\n }\n\n private _onFilterComplete(): void {\n if (!this._adapter.hasFocus()) {\n if (this._isDropdownOpen) {\n this._closeDropdown();\n }\n return;\n }\n\n if (this._options.length) {\n const sendFilterText = this._allowUnmatched && !this._selectedOptions.length;\n this._dropdownReady({ userTriggered: sendFilterText });\n\n if (this._filterFocusFirst && this._filterText) {\n this._adapter.activateFirstOption();\n }\n } else {\n this._closeDropdown();\n }\n }\n\n private _clearValue(): void {\n this._selectedOptions = [];\n this._values = [];\n\n if (this._isDropdownOpen) {\n this._adapter.setSelectedOptions([]);\n this._adapter.clearActiveOption();\n }\n\n this._emitChangeEvent();\n }\n\n private async _showDropdown({ filter = true, userTriggered = true, activateFirst = false, activateSelected = false } = {}): Promise<void> {\n const sendFilterText = this._allowUnmatched && !this._selectedOptions.length;\n this._isDropdownOpen = true;\n let listOptionBuilder: ListDropdownOptionBuilder<HTMLElement> | undefined;\n if (this._optionBuilder) {\n const optionBuilder = this._optionBuilder;\n listOptionBuilder = (option: IListDropdownOption, parentElement: HTMLElement) => {\n return optionBuilder(option, this._filterText, parentElement as IListItemComponent);\n };\n }\n const config: IListDropdownConfig = {\n options: this._options,\n multiple: this._multiple,\n selectedValues: [...this._values],\n id: `forge-autocomplete-${this._identifier}`,\n asyncStyle: ListDropdownAsyncStyle.Skeleton,\n optionLimit: this._optionLimit,\n popupClasses: this._popupClasses,\n headerBuilder: this._popupHeaderBuilder,\n footerBuilder: this._popupFooterBuilder,\n transform: label => {\n if (this._filterText) {\n // Highlight the filter text within the label\n const highlightElement = highlightTextHTML(label, this._filterText);\n if (highlightElement) {\n return highlightElement;\n }\n }\n return label;\n },\n allowBusy: true,\n optionBuilder: listOptionBuilder,\n syncWidth: this._syncPopupWidth,\n observeScroll: this._observeScroll,\n observeScrollThreshold: this._observeScrollThreshold,\n scrollEndListener: this._dropdownScrollEndListener,\n activeChangeCallback: this._activeChangeListener,\n targetWidthCallback: this._targetWidthCallback,\n selectCallback: (value: any) => this._onSelect(value),\n closeCallback: () => this._closeDropdown()\n };\n\n this._adapter.show(config, this._popupTarget);\n this._adapter.toggleHostAttribute(AUTOCOMPLETE_CONSTANTS.attributes.OPEN, this._isDropdownOpen);\n\n if (filter) {\n if (this._options.length) {\n this._adapter.setBusyVisibility(true);\n }\n try {\n await this._executeFilter(sendFilterText);\n } catch (e) {\n console.error(e);\n }\n this._updateSelectedOptions(this._values);\n }\n\n // If we have any pending filter promises, then we will let those complete and update the dropdown separately after\n if (this._pendingFilterPromises.length) {\n return;\n }\n\n this._dropdownReady({ userTriggered, activateFirst, activateSelected });\n }\n\n private _dropdownReady({ userTriggered = true, activateFirst = false, activateSelected = false } = {}): void {\n if (!this._isDropdownOpen || !this._options.length || (userTriggered && !this._adapter.hasFocus())) {\n this._closeDropdown();\n return;\n }\n\n this._sortSelectedOptions();\n this._adapter.setBusyVisibility(false);\n this._adapter.setOptions(this._options);\n this._adapter.setSelectedOptions(this._selectedOptions);\n this._adapter.setDismissListener(this._dismissListener);\n\n if (activateSelected && this._selectedOptions.length) {\n this._adapter.activateSelectedOption();\n } else if (activateFirst) {\n this._adapter.activateFirstOption();\n }\n }\n\n private _closeDropdown(): void {\n if (this._multiple) {\n this._filterText = '';\n }\n this._isDropdownOpen = false;\n this._adapter.hide(this._dismissListener);\n this._sortSelectedOptions();\n this._adapter.toggleHostAttribute(AUTOCOMPLETE_CONSTANTS.attributes.OPEN, this._isDropdownOpen);\n }\n\n private _sortSelectedOptions(): void {\n // When in multiple selection mode, we need to make sure that the selected options appear at the top of the list\n if (this._multiple && this._selectedOptions.length && isOptionType(this._options, OptionType.Option)) {\n const selectedOptions: IAutocompleteOption[] = [];\n const unselectedOptions: IAutocompleteOption[] = [];\n\n (this._options as IAutocompleteOption[]).forEach(option => {\n if (this._selectedOptions.find(o => optionEqualPredicate(o, option.value, this._matchKey))) {\n selectedOptions.push(option);\n } else {\n unselectedOptions.push(option);\n }\n });\n\n this._options = [...selectedOptions, ...unselectedOptions];\n }\n }\n\n /**\n * Handles selecting an item in the dropdown.\n * @param {string} selectedValue The string value to select.\n */\n private async _onSelect(selectedValue: string, keepFocus = true): Promise<void> {\n if (this._valueChanging) {\n return;\n }\n\n // If we are in stateless mode, then we need to just emit an event when selecting an option. The\n // selected values are not tracked in stateless mode\n if (this._mode === AutocompleteMode.Stateless) {\n const data: IAutocompleteSelectEventData = { value: selectedValue };\n const result = this._adapter.emitHostEvent(AUTOCOMPLETE_CONSTANTS.events.SELECT, data, true, true);\n if (result) {\n this._filterText = '';\n if (!this._multiple) {\n this._closeDropdown();\n }\n }\n return;\n }\n\n const select = (): void => {\n const flatOptions = this._flatOptions;\n const option = flatOptions.find(o => optionEqualPredicate(o, selectedValue, this._matchKey)) as IAutocompleteOption;\n const value = option ? option.value : '';\n const label = option ? option.label : '';\n\n if (this._multiple) {\n const optionIndex = flatOptions.findIndex(o => optionEqualPredicate(o, selectedValue, this._matchKey));\n if (optionIndex >= 0) {\n const selected = this._selectedOptions.some(o => optionEqualPredicate(o, selectedValue, this._matchKey));\n this._adapter.toggleOptionMultiple(optionIndex, selected);\n }\n const selectedOption = getSelectedOption(this._selectedOptions, value);\n if (selectedOption) {\n const index = this._selectedOptions.indexOf(selectedOption);\n this._selectedOptions.splice(index, 1);\n } else {\n this._selectedOptions.push(option);\n }\n } else {\n if (isDefined(value)) {\n this._selectedOptions[0] = option;\n this._filterText = label;\n } else {\n this._selectedOptions = [];\n this._filterText = '';\n }\n }\n\n // Update the dropdown selection status if its open\n if (this._isDropdownOpen) {\n this._adapter.setSelectedOptions(this._selectedOptions);\n }\n\n // Keep the values in sync with the currently selected options\n this._values = this._selectedOptions.map(o => o.value);\n\n // Update the selected text in the input\n this._adapter.setSelectedText(this._getSelectedText());\n\n // Select the text in the input to allow for the next filter\n if (!Platform.isMobile && keepFocus) {\n this._adapter.selectInputValue();\n }\n\n if (this._multiple) {\n // If we're in multiselect mode, we need to toggle the selected option\n const index = flatOptions.findIndex(o => optionEqualPredicate(o, selectedValue, this._matchKey));\n const isSelected = this._values.includes(selectedValue);\n this._adapter.toggleOptionMultiple(index, isSelected);\n }\n\n this._emitChangeEvent();\n this._tryUpdateDropdownPosition();\n };\n\n // We close the dropdown immediately if in single selection mode\n if (this._isDropdownOpen && !this._multiple) {\n this._closeDropdown();\n }\n\n if (typeof this._beforeValueChange === 'function') {\n this._valueChanging = Promise.resolve(this._beforeValueChange.call(null, selectedValue, this._matchKey));\n const shouldContinue = await this._valueChanging;\n if (shouldContinue) {\n select();\n } else {\n this._tryUpdateDropdownPosition();\n }\n this._valueChanging = undefined;\n } else {\n select();\n }\n }\n\n private _selectActiveOption(keepFocus = true): void {\n const activeOptionIndex = this._adapter.getActiveOptionIndex();\n if (typeof activeOptionIndex === 'number' && activeOptionIndex >= 0) {\n const option = this._flatOptions[activeOptionIndex];\n if (option) {\n this._onSelect(option.value, keepFocus);\n }\n }\n }\n\n private _emitChangeEvent(): void {\n this._adapter.emitHostEvent(AUTOCOMPLETE_CONSTANTS.events.CHANGE, this._getValue(), true);\n }\n\n private _tryUpdateDropdownPosition(): void {\n if (this._isDropdownOpen) {\n this._adapter.queueDropdownPositionUpdate();\n }\n }\n\n /**\n * Retrieves the current value(s) from the selected options array based on whether\n * we are in multi-select mode or not.\n */\n private _getValue(): string | string[] | null | undefined {\n if (!this._values) {\n return null;\n }\n\n if (!this._values.length) {\n return this._multiple ? [] : null;\n }\n\n return this._multiple ? [...this._values] : this._values[0];\n }\n\n /**\n * Creates the selected text value from the selected label values.\n */\n private _getSelectedText(): string {\n if (this._adapter.isWrappingChipField()) {\n return '';\n }\n\n if (this._selectedTextBuilder) {\n return this._selectedTextBuilder(this._selectedOptions);\n } else {\n if (this._multiple) {\n if (this._values.length) {\n if (this._values.length === 1) {\n return this._selectedOptions[0]?.label ?? '';\n } else {\n return `${this._values.length} options selected`;\n }\n } else {\n return '';\n }\n } else {\n return this._selectedOptions.filter(o => o && o.label).map(o => o.label).join(' ').trim();\n }\n }\n }\n\n /**\n * Handles the user dismissing the dropdown. This is only called if the blur event was triggered\n * from within the popup element itself (in a custom template most likely).\n * @param keepFocus Keep focus on the dropdown or not.\n */\n private _onDismiss(): void {\n this._closeDropdown();\n }\n\n private async _applyValue(value: string | string[] | IAutocompleteOption | IAutocompleteOption[] | null | undefined): Promise<void> {\n let values: any[] = [];\n this._selectedOptions = [];\n\n if (!Array.isArray(value)) {\n values = isDefined(value) ? [value] : [];\n } else {\n values = value;\n }\n\n // If this is not a multi-select, then make sure we only allow one selected value\n if (!this._multiple && values.length > 1) {\n values = [values[0]];\n }\n\n if (isOptionType(values, OptionType.Option)) {\n this._values = values.map((o: IAutocompleteOption) => o.value);\n this._selectedOptions = values as IAutocompleteOption[];\n } else {\n this._values = values as any[];\n }\n\n // Ensure that the values passed are actually existing options\n const allOptions = this._flatOptions;\n if (values.length && allOptions.length) {\n this._updateSelectedOptions(values);\n }\n\n // Execute the filter now if we have a value, but not options yet (only if it has been initialized already)\n if (this._values.length && !this._selectedOptions.length && !!this._filter && this._isInitialized) {\n try {\n await this._executeFilter(false, true);\n } catch (e) {\n console.error(e);\n }\n this._updateSelectedOptions(this._values);\n }\n\n // Update filter text to match the label when on in multiselect mode\n if (!this._multiple) {\n this._filterText = this._selectedOptions.length ? this._selectedOptions[0].label : '';\n } else {\n this._filterText = '';\n }\n\n // Update the state of the component based on the existence of a selected value\n if (this._isInitialized) {\n this._adapter.setSelectedText(this._getSelectedText());\n }\n\n // When the value is changed programmatically we should update the selected options\n if (this._isDropdownOpen) {\n this._adapter.setSelectedOptions(this._selectedOptions);\n }\n }\n\n private _updateSelectedOptions(values: Array<any | IAutocompleteOption>): void {\n const flatOptions = [...this._flatOptions, ...this._selectedOptions];\n\n if (this._selectedOptions.length) {\n this._selectedOptions = [];\n }\n\n if (isOptionType(values, OptionType.Option)) {\n for (const option of values as IAutocompleteOption[]) {\n const actualOption = flatOptions.find(o => optionEqualPredicate(o, option.value, this._matchKey));\n if (actualOption) {\n this._selectedOptions.push(actualOption);\n } else {\n this._selectedOptions.push(option);\n }\n }\n } else {\n for (const value of values as any[]) {\n const actualOption = flatOptions.find(o => optionEqualPredicate(o, value, this._matchKey));\n if (actualOption) {\n this._selectedOptions.push(actualOption);\n } else if (this._allowUnmatched) {\n this._selectedOptions.push({ label: value, value });\n }\n }\n }\n }\n\n /** Gets/sets the mode state. */\n public get mode(): AutocompleteMode {\n return this._mode;\n }\n public set mode(value: AutocompleteMode) {\n if (this._mode !== value) {\n this._mode = value;\n if (this._mode === AutocompleteMode.Stateless) {\n this._selectedOptions = [];\n if (this._isDropdownOpen) {\n this._closeDropdown();\n }\n }\n this._adapter.setHostAttribute(AUTOCOMPLETE_CONSTANTS.attributes.MODE, this._mode);\n }\n }\n\n /** Gets/sets the multi-select state. */\n public get multiple(): boolean {\n return this._multiple;\n }\n public set multiple(value: boolean) {\n if (this._multiple !== value) {\n this._multiple = value;\n this._adapter.setHostAttribute(AUTOCOMPLETE_CONSTANTS.attributes.MULTIPLE, isDefined(this._multiple) ? this._multiple.toString() : '');\n }\n }\n\n /** Gets/sets the value of the component. */\n public get value(): string | string[] | IAutocompleteOption | IAutocompleteOption[] | null | undefined {\n return this._getValue();\n }\n public set value(value: string | string[] | IAutocompleteOption | IAutocompleteOption[] | null | undefined) {\n let values: Array<string | IAutocompleteOption | IAutocompleteOption[] | string[]> = [];\n\n if (value == null) {\n values = [];\n } else if (Array.isArray(value)) {\n values = JSON.parse(JSON.stringify(value));\n } else if (isString(value)) {\n values = [value];\n } else {\n values = [JSON.parse(JSON.stringify(value))];\n }\n\n const hasNewValue = values.length !== this._values.length || values.some(v => !this._values.includes(v));\n if (!hasNewValue) {\n return;\n }\n\n // We only apply the new values if they have actually changed\n this._applyValue(value);\n }\n\n /** Gets/sets filter on focus settings which controls whether the dropdown displays automatically when focused. */\n public get filterOnFocus(): boolean {\n return this._filterOnFocus;\n }\n public set filterOnFocus(value: boolean) {\n if (this._filterOnFocus !== value) {\n this._filterOnFocus = value;\n this._adapter.setHostAttribute(AUTOCOMPLETE_CONSTANTS.attributes.FILTER_ON_FOCUS, isDefined(this._filterOnFocus) ? this._filterOnFocus.toString() : '');\n }\n }\n\n /** Gets/sets whether the first option in the dropdown will be focused automatically when opened or not. */\n public get filterFocusFirst(): boolean {\n return this._filterFocusFirst;\n }\n public set filterFocusFirst(value: boolean) {\n if (this._filterFocusFirst !== value) {\n this._filterFocusFirst = value;\n this._adapter.toggleHostAttribute(AUTOCOMPLETE_CONSTANTS.attributes.FILTER_FOCUS_FIRST, this._filterFocusFirst);\n }\n }\n\n /** Controls whether unmatched text entered by the user will stay visible an option in the dropdown is not found. */\n public get allowUnmatched(): boolean {\n return this._allowUnmatched;\n }\n public set allowUnmatched(value: boolean) {\n if (this._allowUnmatched !== value) {\n this._allowUnmatched = value;\n\n if (isDefined(this._allowUnmatched)) {\n this._adapter.setHostAttribute(AUTOCOMPLETE_CONSTANTS.attributes.ALLOW_UNMATCHED, this._allowUnmatched.toString());\n }\n }\n }\n\n /** Gets/sets the property key to match the value to an option. */\n public get matchKey(): string | null | undefined {\n return this._matchKey;\n }\n public set matchKey(value: string | null | undefined) {\n if (this._matchKey !== value) {\n this._matchKey = value;\n }\n }\n\n /** Gets/sets the selector that will be used to find an element to attach the popup to. Defaults to the input element. */\n public get popupTarget(): string {\n return this._popupTarget;\n }\n public set popupTarget(value: string) {\n if (this._popupTarget !== value) {\n this._popupTarget = value;\n }\n }\n\n /**\n * Gets/sets the filter text.\n * \n * Setting the filter text only applies when allowUnmatched is enabled.\n */\n public get filterText(): string {\n return this._filterText;\n }\n public set filterText(value: string) {\n if (this._filterText !== value) {\n this._filterText = this._allowUnmatched ? value : '';\n\n if (this._isInitialized && this._allowUnmatched) {\n this._adapter.setInputValue(this._filterText);\n\n if (this._isDropdownOpen) {\n this._debounceFilter({ checkFocus: false });\n }\n }\n }\n }\n\n /** Gets/sets the list of classes to apply to the popup element. */\n public get popupClasses(): string | string[] {\n return Array.isArray(this._popupClasses) ? [...this._popupClasses] : [this._popupClasses];\n }\n public set popupClasses(value: string | string[]) {\n if (this._popupClasses !== value) {\n this._popupClasses = Array.isArray(value) ? [...value] : [value];\n }\n }\n\n /** Gets/sets the builder callback to use for the popup header. */\n public set popupHeaderBuilder(value: ListDropdownHeaderBuilder) {\n this._popupHeaderBuilder = value;\n }\n\n /** Gets/sets the builder callback to use for the popup footer. */\n public set popupFooterBuilder(value: ListDropdownFooterBuilder) {\n this._popupFooterBuilder = value;\n }\n\n /** Gets/sets whether the popup width is synchronized with the popup target. */\n public get syncPopupWidth(): boolean {\n return this._syncPopupWidth;\n }\n public set syncPopupWidth(value: boolean) {\n if (this._syncPopupWidth !== value) {\n this._syncPopupWidth = value;\n }\n }\n\n /** Gets/sets the maximum number of options to display in the dropdown. */\n public get optionLimit(): number {\n return this._optionLimit;\n }\n public set optionLimit(value: number) {\n if (this._optionLimit !== value) {\n this._optionLimit = value;\n }\n }\n\n /** Gets/sets the debounce delay (milliseconds) for keyboard events. */\n public get debounce(): number {\n return this._debounce;\n }\n public set debounce(value: number) {\n if (this._debounce !== value) {\n this._debounce = value;\n\n if (this._isInitialized) {\n this._setFilterCallback();\n }\n\n this._adapter.setHostAttribute(AUTOCOMPLETE_CONSTANTS.attributes.DEBOUNCE, isDefined(this._debounce) ? this._debounce.toString() : '');\n }\n }\n\n /** Sets the item builder callback that will be executed when building the option list in the dropdown. */\n public get optionBuilder(): AutocompleteOptionBuilder | null | undefined {\n return this._optionBuilder;\n }\n public set optionBuilder(fn: AutocompleteOptionBuilder | null | undefined) {\n this._optionBuilder = fn;\n }\n\n /** Sets the filter callback that will be executed when fetching options for the autocomplete dropdown. */\n public get filter(): AutocompleteFilterCallback | null | undefined {\n return this._filter;\n }\n public set filter(cb: AutocompleteFilterCallback | null | undefined) {\n if (this._filter !== cb) {\n this._filter = cb;\n\n // If we have a value, but don't have any options yet then execute the filter\n if (this._isInitialized && this._values.length && !this._flatOptions.length && !!this._filter) {\n this._executeFilter().then(() => {\n this._updateSelectedOptions(this._values);\n this._adapter.setSelectedText(this._getSelectedText());\n });\n }\n }\n }\n\n /** Sets the selected text builder callback that will be executed when getting the selected text. */\n public get selectedTextBuilder(): AutocompleteSelectedTextBuilder {\n return this._selectedTextBuilder;\n }\n public set selectedTextBuilder(fn: AutocompleteSelectedTextBuilder) {\n this._selectedTextBuilder = fn;\n\n // If there are selected options, set the selected text again\n if (this._selectedOptions.length) {\n this._adapter.setSelectedText(this._getSelectedText());\n }\n }\n\n public get observeScroll(): boolean {\n return this._observeScroll;\n }\n public set observeScroll(value: boolean) {\n this._observeScroll = value;\n }\n\n public get observeScrollThreshold(): number {\n return this._observeScrollThreshold;\n }\n public set observeScrollThreshold(value: number) {\n this._observeScrollThreshold = value;\n }\n\n public appendOptions(options: IAutocompleteOption[] | IAutocompleteOptionGroup[]): void {\n if (!this._isDropdownOpen) {\n return;\n }\n this._options = [...this._options, ...options] as IAutocompleteOption[] | IAutocompleteOptionGroup[];\n this._adapter.appendOptions(options);\n }\n\n public get isInitialized(): boolean {\n return this._isInitialized;\n }\n\n public get open(): boolean {\n return this._isDropdownOpen;\n }\n public set open(value: boolean) {\n if (this._isDropdownOpen !== value) {\n if (value) {\n this._showDropdown({ userTriggered: false });\n } else {\n this._closeDropdown();\n }\n }\n }\n\n public get beforeValueChange(): (value: any) => boolean | Promise<boolean> {\n return this._beforeValueChange;\n }\n public set beforeValueChange(value: (value: any) => boolean | Promise<boolean>) {\n if (value !== this._beforeValueChange) {\n this._beforeValueChange = value;\n }\n }\n\n public get popupElement(): HTMLElement | null {\n return this._adapter.getPopupElement();\n }\n}\n", "import { attachShadowTemplate, coerceBoolean, coerceNumber, CustomElement, ensureChild, FoundationProperty } from '@tylertech/forge-core';\nimport { tylIconArrowDropDown, tylIconCheckBox, tylIconCheckBoxOutlineBlank } from '@tylertech/tyler-icons/standard';\nimport { DividerComponent } from '../divider';\nimport { IconComponent, IconRegistry } from '../icon';\nimport { LinearProgressComponent } from '../linear-progress';\nimport { ListComponent, ListItemComponent } from '../list';\nimport { IListDropdownAware, ListDropdownAware } from '../list-dropdown/list-dropdown-aware';\nimport { PopupComponent } from '../popup';\nimport { SkeletonComponent } from '../skeleton';\nimport { TextFieldComponent } from '../text-field';\nimport { AutocompleteAdapter } from './autocomplete-adapter';\nimport { AutocompleteFilterCallback, AutocompleteMode, AutocompleteOptionBuilder, AutocompleteSelectedTextBuilder, AUTOCOMPLETE_CONSTANTS, IAutocompleteOption, IAutocompleteOptionGroup, IAutocompleteSelectEventData } from './autocomplete-constants';\nimport { AutocompleteFoundation } from './autocomplete-foundation';\n\nconst template = '<template><slot></slot></template>';\nconst styles = ':host{display:block}:host([hidden]){display:none}';\n\nexport interface IAutocompleteComponent extends IListDropdownAware {\n mode: `${AutocompleteMode}`;\n multiple: boolean;\n value: any;\n debounce: number;\n filterOnFocus: boolean;\n filterFocusFirst: boolean;\n allowUnmatched: boolean;\n matchKey: string | null | undefined;\n popupTarget: string;\n filterText: string;\n filter: AutocompleteFilterCallback | null | undefined;\n optionBuilder: AutocompleteOptionBuilder | null | undefined;\n selectedTextBuilder: AutocompleteSelectedTextBuilder;\n popupElement: HTMLElement | null;\n beforeValueChange: (value: any) => boolean | Promise<boolean>;\n isInitialized: boolean;\n open: boolean;\n appendOptions(options: IAutocompleteOption[] | IAutocompleteOptionGroup[]): void;\n openDropdown(): void;\n closeDropdown(): void;\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'forge-autocomplete': IAutocompleteComponent;\n }\n\n interface HTMLElementEventMap {\n 'forge-autocomplete-change': CustomEvent<any>;\n 'forge-autocomplete-select': CustomEvent<IAutocompleteSelectEventData>;\n 'forge-autocomplete-scrolled-bottom': CustomEvent<void>;\n }\n}\n\n/**\n * The custom element class behind the `<forge-autocomplete>` element.\n * \n * @tag forge-autocomplete\n */\n@CustomElement({\n name: AUTOCOMPLETE_CONSTANTS.elementName,\n dependencies: [\n TextFieldComponent,\n PopupComponent,\n ListComponent,\n ListItemComponent,\n DividerComponent,\n SkeletonComponent,\n LinearProgressComponent,\n IconComponent\n ]\n})\nexport class AutocompleteComponent extends ListDropdownAware implements IAutocompleteComponent {\n public static get observedAttributes(): string[] {\n return [\n AUTOCOMPLETE_CONSTANTS.attributes.MODE,\n AUTOCOMPLETE_CONSTANTS.attributes.MULTIPLE,\n AUTOCOMPLETE_CONSTANTS.attributes.DEBOUNCE,\n AUTOCOMPLETE_CONSTANTS.attributes.FILTER_ON_FOCUS,\n AUTOCOMPLETE_CONSTANTS.attributes.FILTER_FOCUS_FIRST,\n AUTOCOMPLETE_CONSTANTS.attributes.ALLOW_UNMATCHED,\n AUTOCOMPLETE_CONSTANTS.attributes.POPUP_TARGET,\n AUTOCOMPLETE_CONSTANTS.attributes.POPUP_CLASSES,\n AUTOCOMPLETE_CONSTANTS.attributes.OBSERVE_SCROLL,\n AUTOCOMPLETE_CONSTANTS.attributes.OBSERVE_SCROLL_THRESHOLD,\n AUTOCOMPLETE_CONSTANTS.attributes.OPTION_LIMIT,\n AUTOCOMPLETE_CONSTANTS.attributes.SYNC_POPUP_WIDTH,\n AUTOCOMPLETE_CONSTANTS.attributes.OPEN,\n AUTOCOMPLETE_CONSTANTS.attributes.MATCH_KEY,\n AUTOCOMPLETE_CONSTANTS.attributes.FILTER_TEXT\n ];\n }\n\n private _foundation: AutocompleteFoundation;\n\n constructor() {\n super();\n IconRegistry.define([tylIconArrowDropDown, tylIconCheckBox, tylIconCheckBoxOutlineBlank]);\n attachShadowTemplate(this, template, styles);\n this._foundation = new AutocompleteFoundation(new AutocompleteAdapter(this));\n }\n\n public connectedCallback(): void {\n if (this.querySelector(AUTOCOMPLETE_CONSTANTS.selectors.INPUT)) {\n this._foundation.initialize();\n } else {\n ensureChild(this, AUTOCOMPLETE_CONSTANTS.selectors.INPUT).then(() => this._foundation.initialize());\n }\n }\n\n public disconnectedCallback(): void {\n this._foundation.disconnect();\n }\n\n public attributeChangedCallback(name: string, oldValue: string, newValue: string): void {\n super.attributeChangedCallback(name, oldValue, newValue);\n switch (name) {\n case AUTOCOMPLETE_CONSTANTS.attributes.MODE:\n this.mode = newValue as AutocompleteMode;\n break;\n case AUTOCOMPLETE_CONSTANTS.attributes.MULTIPLE:\n this.multiple = coerceBoolean(newValue);\n break;\n case AUTOCOMPLETE_CONSTANTS.attributes.DEBOUNCE:\n this.debounce = coerceNumber(newValue);\n break;\n case AUTOCOMPLETE_CONSTANTS.attributes.FILTER_ON_FOCUS:\n this.filterOnFocus = coerceBoolean(newValue);\n break;\n case AUTOCOMPLETE_CONSTANTS.attributes.FILTER_FOCUS_FIRST:\n this.filterFocusFirst = coerceBoolean(newValue);\n break;\n case AUTOCOMPLETE_CONSTANTS.attributes.ALLOW_UNMATCHED:\n this.allowUnmatched = coerceBoolean(newValue);\n break;\n case AUTOCOMPLETE_CONSTANTS.attributes.POPUP_TARGET:\n this.popupTarget = newValue;\n break;\n case AUTOCOMPLETE_CONSTANTS.attributes.OPEN:\n this.open = coerceBoolean(newValue);\n break;\n case AUTOCOMPLETE_CONSTANTS.attributes.MATCH_KEY:\n this.matchKey = newValue;\n break;\n case AUTOCOMPLETE_CONSTANTS.attributes.FILTER_TEXT:\n this.filterText = newValue;\n break;\n }\n }\n\n /** Gets/sets the interaction mode. */\n @FoundationProperty()\n public declare mode: `${AutocompleteMode}`;\n\n /** Gets/sets the multi-select state. */\n @FoundationProperty()\n public declare multiple: boolean;\n\n /** Gets/sets the value. */\n @FoundationProperty()\n public declare value: any;\n\n /** Gets/sets the debounce delay (milliseconds) for keyboard events. */\n @FoundationProperty()\n public declare debounce: number;\n\n /** Gets/sets filter on focus settings which controls whether the dropdown displays automatically when focused. */\n @FoundationProperty()\n public declare filterOnFocus: boolean;\n\n /** Gets/sets whether the first option in the dropdown will be focused automatically when opened or not. */\n @FoundationProperty()\n public declare filterFocusFirst: boolean;\n\n /** Controls whether unmatched text entered by the user will stay visible an option in the dropdown is not found. */\n @FoundationProperty()\n public declare allowUnmatched: boolean;\n\n /** Gets/sets the selector that will be used to find an element to attach the popup to. Defaults to the input element. */\n @FoundationProperty()\n public declare popupTarget: string;\n\n /**\n * Gets/sets the filter text.\n * \n * Setting the filter text only applies when allowUnmatched is enabled.\n */\n @FoundationProperty()\n public declare filterText: string;\n\n /** Sets the option builder callback that will be executed when building the option list in the dropdown. */\n @FoundationProperty()\n public declare optionBuilder: AutocompleteOptionBuilder | null | undefined;\n\n /** Sets the filter callback that will be executed when fetching options for the autocomplete dropdown. */\n @FoundationProperty()\n public declare filter: AutocompleteFilterCallback | null | undefined;\n\n /** Sets the selected text builder callback that will be executed when getting the selected text. */\n @FoundationProperty()\n public declare selectedTextBuilder: AutocompleteSelectedTextBuilder;\n\n /** Controls the open state of the dropdown. */\n @FoundationProperty()\n public declare open: boolean;\n\n /** Gets/sets the property key to match the value to an option. */\n @FoundationProperty()\n public declare matchKey: string | null | undefined;\n\n /** Returns whether the component has been initialized or not yet. */\n @FoundationProperty({ set: false })\n public declare isInitialized: boolean;\n\n /** Gets the currently active popup element when the dropdown is open. */\n @FoundationProperty({ set: false })\n public declare popupElement: HTMLElement | null;\n\n /** Sets the callback to be executed when the user selects an option, before the UI is updated to allow for validation. */\n @FoundationProperty()\n public declare beforeValueChange: (value: any) => boolean | Promise<boolean>;\n\n /** Adds options to the dropdown while it is open. Has no effect if the dropdown is closed. */\n public appendOptions(options: IAutocompleteOption[] | IAutocompleteOptionGroup[]): void {\n this._foundation.appendOptions(options);\n }\n\n /** Opens the dropdown. */\n public openDropdown(): void {\n this.open = true;\n }\n\n /** Closes the dropdown. */\n public closeDropdown(): void {\n this.open = false;\n }\n}\n", "import { FormFieldComponentDelegate, IFormFieldComponentDelegateOptions } from '../core/delegates/form-field-component-delegate';\nimport { ITextFieldComponent, TextFieldComponentDelegate, ITextFieldComponentDelegateOptions } from '../text-field';\nimport { IAutocompleteComponent } from './autocomplete';\nimport { AUTOCOMPLETE_CONSTANTS } from './autocomplete-constants';\nimport { IconComponentDelegate, IIconComponentDelegateConfig } from '../icon';\nimport { IBaseComponentDelegateConfig } from '../core/delegates/base-component-delegate';\nimport { ITextFieldComponentDelegateConfig } from '../text-field/text-field-component-delegate';\n\nexport type AutocompleteComponentDelegateProps = Partial<IAutocompleteComponent>;\nexport interface IAutocompleteComponentDelegateOptions extends IFormFieldComponentDelegateOptions {\n useDropdownIcon?: boolean;\n textFieldDelegateConfig?: ITextFieldComponentDelegateConfig;\n}\n\nexport interface IAutocompleteComponentDelegateConfig extends IBaseComponentDelegateConfig<IAutocompleteComponent, IAutocompleteComponentDelegateOptions> {}\n\nexport class AutocompleteComponentDelegate extends FormFieldComponentDelegate<IAutocompleteComponent, IAutocompleteComponentDelegateOptions> {\n private _textFieldDelegate: TextFieldComponentDelegate;\n\n constructor(config?: IAutocompleteComponentDelegateConfig) {\n super(config);\n }\n\n protected _build(): IAutocompleteComponent {\n const autocomplete = document.createElement(AUTOCOMPLETE_CONSTANTS.elementName) as IAutocompleteComponent;\n this._attachTextField(autocomplete);\n return autocomplete;\n }\n\n public get textFieldDelegate(): TextFieldComponentDelegate {\n return this._textFieldDelegate;\n }\n\n public get value(): any {\n return this._element.value;\n }\n public set value(value: any) {\n this._element.value = value;\n }\n\n public get disabled(): boolean {\n return this._textFieldDelegate.inputElement.disabled;\n }\n public set disabled(value: boolean) {\n this._textFieldDelegate.inputElement.disabled = value;\n }\n\n public get invalid(): boolean {\n return this._textFieldDelegate.invalid || false;\n }\n public set invalid(value: boolean) {\n this._textFieldDelegate.invalid = value;\n }\n\n public onChange(listener: (value: string) => void): void {\n this._element.addEventListener(AUTOCOMPLETE_CONSTANTS.events.CHANGE, (evt: CustomEvent) => listener(evt.detail));\n }\n\n public onFocus(listener: (evt: FocusEvent) => void): void {\n this._textFieldDelegate.inputElement.addEventListener('focus', (evt: FocusEvent) => listener(evt));\n }\n\n public onBlur(listener: (evt: FocusEvent) => void): void {\n this._textFieldDelegate.inputElement.addEventListener('blur', (evt: FocusEvent) => listener(evt));\n }\n\n private _attachTextField(autocomplete: IAutocompleteComponent): void {\n const textFieldConfig: ITextFieldComponentDelegateConfig = {\n props: { ...this._config.options?.textFieldDelegateConfig?.props },\n options: { ...this._config.options?.textFieldDelegateConfig?.options }\n };\n\n if (!textFieldConfig.options) {\n textFieldConfig.options = {};\n }\n\n if (this._config.options?.useDropdownIcon !== false && !textFieldConfig.options?.trailingElement) {\n textFieldConfig.options.trailingElement = this._createDropdownIconElement();\n }\n\n this._textFieldDelegate = new TextFieldComponentDelegate(textFieldConfig);\n autocomplete.appendChild(this._textFieldDelegate.element);\n }\n\n private _createDropdownIconElement(): HTMLElement {\n const config: IIconComponentDelegateConfig = {\n props: {\n slot: 'trailing',\n name: 'arrow_drop_down'\n },\n options: {\n attributes: { 'forge-dropdown-icon': '' }\n }\n };\n return new IconComponentDelegate(config).element;\n }\n}\n", "import { defineCustomElement } from '@tylertech/forge-core';\n\nimport { AutocompleteComponent } from './autocomplete';\n\nexport * from './autocomplete-adapter';\nexport * from './autocomplete-component-delegate';\nexport * from './autocomplete-constants';\nexport * from './autocomplete-foundation';\nexport * from './autocomplete-utils';\nexport * from './autocomplete';\n\nexport function defineAutocompleteComponent(): void {\n defineCustomElement(AutocompleteComponent);\n}\n"],
|
|
5
|
-
"mappings": "gmCAMA,IAAMA,EAA2C,GAAGC,gBAE9CC,GAAa,CACjB,KAAM,OACN,SAAU,WACV,SAAU,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AoBD,EAASC,CAAG,CAAC,CACnG,CAEO,OAAOD,EAA2C,CACvD,KAAK,mBAAmB,aAAa,iBAAiB,OAASC,GAAoBD,EAASC,CAAG,CAAC,CAClG,CAEQ,iBAAiBJ,EAA4C,CAlEvE,IAAAK,EAAAC,EAAAC,EAAAC,EAAAC,EAAAC,EAmEI,IAAMC,EAAqD,CACzD,MAAOC,EAAA,IAAKN,GAAAD,EAAA,KAAK,QAAQ,UAAb,YAAAA,EAAsB,0BAAtB,YAAAC,EAA+C,OAC3D,QAASM,EAAA,IAAKJ,GAAAD,EAAA,KAAK,QAAQ,UAAb,YAAAA,EAAsB,0BAAtB,YAAAC,EAA+C,QAC/D,EAEKG,EAAgB,UACnBA,EAAgB,QAAU,CAAC,KAGzBF,EAAA,KAAK,QAAQ,UAAb,YAAAA,EAAsB,mBAAoB,IAAS,GAACC,EAAAC,EAAgB,UAAhB,MAAAD,EAAyB,mBAC/EC,EAAgB,QAAQ,gBAAkB,KAAK,2BAA2B,GAG5E,KAAK,mBAAqB,IAAIE,GAA2BF,CAAe,EACxEX,EAAa,YAAY,KAAK,mBAAmB,OAAO,CAC1D,CAEQ,4BAA0C,CAChD,IAAMD,EAAuC,CAC3C,MAAO,CACL,KAAM,WACN,KAAM,iBACR,EACA,QAAS,CACP,WAAY,CAAE,sBAAuB,EAAG,CAC1C,CACF,EACA,OAAO,IAAIe,EAAsBf,CAAM,EAAE,OAC3C,CACF,ECrFO,SAASgB,IAAoC,CAClDC,EAAoBC,CAAqB,CAC3C",
|
|
6
|
-
"names": ["elementName", "COMPONENT_NAME_PREFIX", "attributes", "selectors", "FIELD_CONSTANTS", "numbers", "events", "AUTOCOMPLETE_CONSTANTS", "AutocompleteMode", "AutocompleteAdapter", "BaseAdapter", "component", "inputElements", "deepQuerySelectorAll", "AUTOCOMPLETE_CONSTANTS", "name", "value", "type", "listener", "identifier", "CHIP_FIELD_CONSTANTS", "config", "popupTarget", "ListDropdown", "targetElement", "POPUP_CONSTANTS", "isVisible", "_a", "index", "selected", "dropdownElement", "options", "target", "activeElement", "getActiveElement", "dropdownIcon", "clearButton", "key", "id", "toggleAttribute", "selector", "_b", "values", "o", "dropdownEl", "textField", "textFieldRoot", "getShadowElement", "TEXT_FIELD_CONSTANTS", "chipField", "chipFieldRoot", "state", "OptionType", "isOptionType", "options", "type", "isOptionGroups", "o", "isDefined", "isObject", "isOptionTypes", "getSelectedOption", "value", "optionEqualPredicate", "option", "property", "isDeepEqual", "AutocompleteFoundation", "ListDropdownAwareFoundation", "_adapter", "AUTOCOMPLETE_CONSTANTS", "evt", "id", "randomChars", "isDefined", "debounce", "isOptionType", "previousValue", "currentValue", "Platform", "checkFocus", "filterText", "filterPromise", "e", "promiseIndex", "input", "value", "isRemovingAllChars", "isBackspacingLastChar", "isDeletingLastChar", "isEmpty", "sendFilterText", "sendValue", "filter", "resolve", "reject", "options", "userTriggered", "activateFirst", "activateSelected", "listOptionBuilder", "optionBuilder", "option", "parentElement", "config", "label", "highlightElement", "highlightTextHTML", "selectedOptions", "unselectedOptions", "o", "optionEqualPredicate", "selectedValue", "keepFocus", "data", "select", "flatOptions", "optionIndex", "selected", "selectedOption", "getSelectedOption", "index", "isSelected", "activeOptionIndex", "_a", "_b", "values", "allOptions", "actualOption", "isString", "v", "fn", "cb", "template", "styles", "AutocompleteComponent", "ListDropdownAware", "IconRegistry", "tylIconArrowDropDown", "tylIconCheckBox", "tylIconCheckBoxOutlineBlank", "attachShadowTemplate", "AutocompleteFoundation", "AutocompleteAdapter", "AUTOCOMPLETE_CONSTANTS", "ensureChild", "name", "oldValue", "newValue", "coerceBoolean", "coerceNumber", "options", "__decorateClass", "FoundationProperty", "CustomElement", "TextFieldComponent", "PopupComponent", "ListComponent", "ListItemComponent", "DividerComponent", "SkeletonComponent", "LinearProgressComponent", "IconComponent", "AutocompleteComponentDelegate", "FormFieldComponentDelegate", "config", "autocomplete", "AUTOCOMPLETE_CONSTANTS", "value", "listener", "evt", "_a", "_b", "_c", "_d", "_e", "_f", "textFieldConfig", "__spreadValues", "TextFieldComponentDelegate", "IconComponentDelegate", "defineAutocompleteComponent", "defineCustomElement", "AutocompleteComponent"]
|
|
7
|
-
}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2023 Tyler Technologies, Inc.
|
|
4
|
-
* License: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
function d(n,e){let r=n.toLowerCase().indexOf(e.toLowerCase());if(r!==-1){let o=r+e.length,t=document.createElement("span"),u=document.createElement("span");return u.style.fontWeight="bold",u.textContent=n.substring(r,o),t.appendChild(document.createTextNode(n.substring(0,r))),t.appendChild(u),t.appendChild(document.createTextNode(n.substring(o))),t}}function c(n,{capture:e=!0,pointerenter:i=!0,focusin:r=!0}={}){return new Promise(o=>{let t={once:!0,capture:e},u=()=>{r&&n.removeEventListener("focusin",s,t),o("pointerenter")},s=()=>{i&&n.removeEventListener("pointerenter",u,t),o("focusin")};i&&n.addEventListener("pointerenter",u,t),r&&n.addEventListener("focusin",s,t)})}function p(n,e){return e===0?0:n/100*e}function m(n,e){return e===0?0:n*100/e}function f(n,e,i,r=0,o=100){let t=i-e,u=n-e;return!t||!u?r:u*o/t+r}function a(...n){return Math.min(...n.map(e=>e!=null?e:Number.POSITIVE_INFINITY))}function x(...n){return Math.max(...n.map(e=>e!=null?e:Number.NEGATIVE_INFINITY))}export{d as a,c as b,p as c,m as d,f as e,a as f,x as g};
|
|
7
|
-
//# sourceMappingURL=chunk.WDTA5G7R.js.map
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|