@tylertech/forge 3.0.0-next.1 → 3.0.0-next.11
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 +18061 -12338
- package/dist/button/forge-button.css +1 -1
- 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/core/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.2AJ7FFI6.js +7 -0
- package/dist/esm/chunks/chunk.2AJ7FFI6.js.map +7 -0
- package/dist/esm/chunks/{chunk.SSRQFKNH.js → chunk.2EWV2XBP.js} +2 -2
- package/dist/esm/chunks/{chunk.SSRQFKNH.js.map → chunk.2EWV2XBP.js.map} +1 -1
- package/dist/esm/chunks/chunk.2QHD3DCR.js +7 -0
- package/dist/esm/chunks/chunk.2QHD3DCR.js.map +7 -0
- package/dist/esm/chunks/{chunk.BJZ7RB5F.js → chunk.3CTKWBV2.js} +1 -1
- package/dist/esm/chunks/{chunk.BJZ7RB5F.js.map → chunk.3CTKWBV2.js.map} +1 -1
- package/dist/esm/chunks/chunk.3HB22HCX.js +7 -0
- package/dist/esm/chunks/chunk.44IUAOBP.js +7 -0
- package/dist/esm/chunks/{chunk.YPZNIYQL.js.map → chunk.44IUAOBP.js.map} +2 -2
- package/dist/esm/chunks/chunk.4C6KHYUO.js +7 -0
- package/dist/esm/chunks/{chunk.SXTTEIIH.js → chunk.4YFVG4KP.js} +2 -2
- package/dist/esm/chunks/{chunk.SXTTEIIH.js.map → chunk.4YFVG4KP.js.map} +1 -1
- package/dist/esm/chunks/chunk.4ZKX3SO5.js +7 -0
- package/dist/esm/chunks/{chunk.5WNKQTXX.js.map → chunk.4ZKX3SO5.js.map} +2 -2
- package/dist/esm/chunks/chunk.54OOOQ4R.js +7 -0
- package/dist/esm/chunks/chunk.54OOOQ4R.js.map +7 -0
- package/dist/esm/chunks/chunk.5565ZSTH.js +7 -0
- package/dist/esm/chunks/chunk.5565ZSTH.js.map +7 -0
- package/dist/esm/chunks/chunk.5MZ5SGMO.js +7 -0
- package/dist/esm/chunks/chunk.5MZ5SGMO.js.map +7 -0
- package/dist/esm/chunks/{chunk.7UKA4E5A.js → chunk.624UKZFU.js} +2 -2
- package/dist/esm/chunks/{chunk.7UKA4E5A.js.map → chunk.624UKZFU.js.map} +1 -1
- package/dist/esm/chunks/chunk.6GC5AJPE.js +7 -0
- package/dist/esm/chunks/chunk.6GC5AJPE.js.map +7 -0
- package/dist/esm/chunks/{chunk.CLM6MNKC.js → chunk.6OUJSOJY.js} +2 -2
- package/dist/esm/chunks/{chunk.CLM6MNKC.js.map → chunk.6OUJSOJY.js.map} +1 -1
- package/dist/esm/chunks/{chunk.TR5YMNJJ.js → chunk.6OW6Q3EW.js} +2 -2
- package/dist/esm/chunks/{chunk.TR5YMNJJ.js.map → chunk.6OW6Q3EW.js.map} +1 -1
- package/dist/esm/chunks/chunk.7CGKFRBK.js +7 -0
- package/dist/esm/chunks/chunk.7CGKFRBK.js.map +7 -0
- package/dist/esm/chunks/chunk.7DB3XVPI.js +7 -0
- package/dist/esm/chunks/chunk.7DB3XVPI.js.map +7 -0
- package/dist/esm/chunks/chunk.7TMLILLW.js +7 -0
- package/dist/esm/chunks/{chunk.ZFHPUAYX.js.map → chunk.7TMLILLW.js.map} +2 -2
- package/dist/esm/chunks/{chunk.KU5CXXGS.js → chunk.A62DE5PD.js} +2 -2
- package/dist/esm/chunks/chunk.AEKOP3XT.js +7 -0
- package/dist/esm/chunks/chunk.AEKOP3XT.js.map +7 -0
- package/dist/esm/chunks/chunk.ALIYGJXA.js +129 -0
- package/dist/esm/chunks/chunk.ALIYGJXA.js.map +7 -0
- package/dist/esm/chunks/chunk.B4T3R53C.js +7 -0
- package/dist/esm/chunks/{chunk.6OKJPSUE.js.map → chunk.B4T3R53C.js.map} +2 -2
- package/dist/esm/chunks/chunk.BH2TUG2V.js +7 -0
- package/dist/esm/chunks/chunk.BH2TUG2V.js.map +7 -0
- package/dist/esm/chunks/chunk.BKL2BAYW.js +7 -0
- package/dist/esm/chunks/{chunk.G5MGGEFP.js.map → chunk.BKL2BAYW.js.map} +1 -1
- package/dist/esm/chunks/chunk.BY25RT52.js +7 -0
- package/dist/esm/chunks/chunk.BY25RT52.js.map +7 -0
- package/dist/esm/chunks/chunk.CDGZYUQS.js +7 -0
- package/dist/esm/chunks/{chunk.RB5BTA5N.js.map → chunk.CDGZYUQS.js.map} +2 -2
- package/dist/esm/chunks/chunk.CKW7KKDW.js +7 -0
- package/dist/esm/chunks/{chunk.4NI63FGK.js.map → chunk.CKW7KKDW.js.map} +2 -2
- package/dist/esm/chunks/{chunk.RYMPSU4J.js → chunk.COVTBIQQ.js} +2 -2
- package/dist/esm/chunks/{chunk.RYMPSU4J.js.map → chunk.COVTBIQQ.js.map} +2 -2
- package/dist/esm/chunks/{chunk.G45OZEIS.js → chunk.CWTV3TB3.js} +2 -2
- package/dist/esm/chunks/chunk.CXY6K7EI.js +7 -0
- package/dist/esm/chunks/{chunk.ROR6JMAE.js.map → chunk.CXY6K7EI.js.map} +1 -1
- package/dist/esm/chunks/chunk.D5TAI6Q7.js +7 -0
- package/dist/esm/chunks/{chunk.BTBHIIGI.js.map → chunk.D5TAI6Q7.js.map} +1 -1
- package/dist/esm/chunks/chunk.DBNJHUYY.js +7 -0
- package/dist/esm/chunks/chunk.DBNJHUYY.js.map +7 -0
- package/dist/esm/chunks/{chunk.WP4QOOIS.js → chunk.DG4ZM3AW.js} +2 -2
- package/dist/esm/chunks/{chunk.U6WGJELL.js → chunk.DMCBAYQX.js} +1 -1
- package/dist/esm/chunks/{chunk.U6WGJELL.js.map → chunk.DMCBAYQX.js.map} +1 -1
- package/dist/esm/chunks/{chunk.BE7PZANN.js → chunk.DXN7ZOH3.js} +2 -2
- package/dist/esm/chunks/{chunk.BE7PZANN.js.map → chunk.DXN7ZOH3.js.map} +1 -1
- package/dist/esm/chunks/chunk.EK24Y56W.js +7 -0
- package/dist/esm/chunks/chunk.F4VXEE76.js +7 -0
- package/dist/esm/chunks/chunk.F4VXEE76.js.map +7 -0
- package/dist/esm/chunks/chunk.F5SY2D4B.js +7 -0
- package/dist/esm/chunks/{chunk.DT7MZR5Y.js.map → chunk.F5SY2D4B.js.map} +3 -3
- package/dist/esm/chunks/chunk.F74YURLV.js +7 -0
- package/dist/esm/chunks/chunk.F74YURLV.js.map +7 -0
- package/dist/esm/chunks/chunk.FCATJM34.js +7 -0
- package/dist/esm/chunks/chunk.FCATJM34.js.map +7 -0
- package/dist/esm/chunks/{chunk.3KQL7VAZ.js → chunk.FDZSLGIW.js} +2 -2
- package/dist/esm/chunks/{chunk.3KQL7VAZ.js.map → chunk.FDZSLGIW.js.map} +1 -1
- package/dist/esm/chunks/chunk.FG2GNAM2.js +7 -0
- package/dist/esm/chunks/chunk.FG2GNAM2.js.map +7 -0
- package/dist/esm/chunks/{chunk.UT7QUGAO.js → chunk.FWFOOQMA.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.GNG64TXK.js +7 -0
- package/dist/esm/chunks/chunk.GNG64TXK.js.map +7 -0
- package/dist/esm/chunks/chunk.HHCO64F3.js +7 -0
- package/dist/esm/chunks/chunk.HHCO64F3.js.map +7 -0
- package/dist/esm/chunks/chunk.HRGTAVNA.js +7 -0
- package/dist/esm/chunks/{chunk.J6WCFQSS.js.map → chunk.HRGTAVNA.js.map} +2 -2
- package/dist/esm/chunks/chunk.ISC7SZSP.js +7 -0
- package/dist/esm/chunks/chunk.ISC7SZSP.js.map +7 -0
- package/dist/esm/chunks/{chunk.ZUNZKRRK.js → chunk.IX25DYIM.js} +2 -2
- package/dist/esm/chunks/chunk.JIKSKUDW.js +7 -0
- package/dist/esm/chunks/chunk.JIKSKUDW.js.map +7 -0
- package/dist/esm/chunks/{chunk.F2B24WLK.js → chunk.JLLHDJSO.js} +2 -2
- package/dist/esm/chunks/{chunk.F2B24WLK.js.map → chunk.JLLHDJSO.js.map} +1 -1
- package/dist/esm/chunks/chunk.JUJGROHA.js +7 -0
- package/dist/esm/chunks/{chunk.YBEBD4CN.js.map → chunk.JUJGROHA.js.map} +1 -1
- package/dist/esm/chunks/{chunk.UBD2DPQN.js → chunk.K3KAM2PL.js} +2 -2
- package/dist/esm/chunks/{chunk.UBD2DPQN.js.map → chunk.K3KAM2PL.js.map} +1 -1
- package/dist/esm/chunks/{chunk.PN26D52V.js → chunk.K7FPXAFS.js} +2 -2
- package/dist/esm/chunks/{chunk.PN26D52V.js.map → chunk.K7FPXAFS.js.map} +3 -3
- package/dist/esm/chunks/chunk.KJP2VA6Q.js +7 -0
- package/dist/esm/chunks/chunk.KJP2VA6Q.js.map +7 -0
- package/dist/esm/chunks/{chunk.ARJ3EVVO.js → chunk.KVCDAZ6B.js} +2 -2
- package/dist/esm/chunks/{chunk.4DAIIJ37.js → chunk.LEVFMI2Q.js} +1 -1
- package/dist/esm/chunks/{chunk.4DAIIJ37.js.map → chunk.LEVFMI2Q.js.map} +1 -1
- package/dist/esm/chunks/{chunk.77Y3EABF.js → chunk.LFODKHUO.js} +2 -2
- package/dist/esm/chunks/{chunk.77Y3EABF.js.map → chunk.LFODKHUO.js.map} +1 -1
- package/dist/esm/chunks/{chunk.XQ2EQIDS.js → chunk.LK4AAUOP.js} +2 -2
- package/dist/esm/chunks/{chunk.XQ2EQIDS.js.map → chunk.LK4AAUOP.js.map} +2 -2
- package/dist/esm/chunks/{chunk.H4Z4DHPA.js → chunk.LTT67HTW.js} +2 -2
- package/dist/esm/chunks/chunk.LXPFG7MW.js +7 -0
- package/dist/esm/chunks/chunk.LXPFG7MW.js.map +7 -0
- package/dist/esm/chunks/chunk.M3QDAYD2.js +7 -0
- package/dist/esm/chunks/chunk.M56LSSPW.js +7 -0
- package/dist/esm/chunks/{chunk.Y5A7RQ5M.js.map → chunk.M56LSSPW.js.map} +1 -1
- package/dist/esm/chunks/chunk.MACPUZC2.js +7 -0
- package/dist/esm/chunks/chunk.MACPUZC2.js.map +7 -0
- package/dist/esm/chunks/{chunk.O73S5LF3.js → chunk.MGLL67VO.js} +2 -2
- package/dist/esm/chunks/chunk.MGLWXAZO.js +18 -0
- package/dist/esm/chunks/{chunk.YI4JTY4T.js.map → chunk.MGLWXAZO.js.map} +2 -2
- package/dist/esm/chunks/{chunk.XZ4WI7VK.js → chunk.MHBBMC6O.js} +2 -2
- package/dist/esm/chunks/{chunk.XZ4WI7VK.js.map → chunk.MHBBMC6O.js.map} +1 -1
- package/dist/esm/chunks/{chunk.HBMNXZES.js → chunk.MTKSU2BV.js} +2 -2
- package/dist/esm/chunks/{chunk.HBMNXZES.js.map → chunk.MTKSU2BV.js.map} +1 -1
- package/dist/esm/chunks/chunk.MVTBJPO2.js +7 -0
- package/dist/esm/chunks/{chunk.Y4GKBJGI.js.map → chunk.MVTBJPO2.js.map} +3 -3
- package/dist/esm/chunks/chunk.MXEKIEJA.js +7 -0
- package/dist/esm/chunks/chunk.MXEKIEJA.js.map +7 -0
- package/dist/esm/chunks/chunk.N43BCJHN.js +7 -0
- package/dist/esm/chunks/chunk.N43BCJHN.js.map +7 -0
- package/dist/esm/chunks/{chunk.VC2BG2RS.js → chunk.NR3MLTXF.js} +2 -2
- package/dist/esm/chunks/{chunk.VC2BG2RS.js.map → chunk.NR3MLTXF.js.map} +1 -1
- package/dist/esm/chunks/{chunk.KTGSZEAG.js → chunk.NVUMRW44.js} +1 -1
- package/dist/esm/chunks/{chunk.KTGSZEAG.js.map → chunk.NVUMRW44.js.map} +1 -1
- package/dist/esm/chunks/{chunk.MLV25D2G.js → chunk.OWCYRSI3.js} +2 -2
- package/dist/esm/chunks/chunk.P2CW5MQO.js +12 -0
- package/dist/esm/chunks/chunk.P2CW5MQO.js.map +7 -0
- package/dist/esm/chunks/{chunk.N4PVZUJX.js → chunk.P2ZCNO63.js} +2 -2
- package/dist/esm/chunks/{chunk.N4PVZUJX.js.map → chunk.P2ZCNO63.js.map} +2 -2
- package/dist/esm/chunks/chunk.PADPL4L3.js +7 -0
- package/dist/esm/chunks/{chunk.47A2CN5U.js.map → chunk.PADPL4L3.js.map} +1 -1
- package/dist/esm/chunks/chunk.PEBT47AU.js +7 -0
- package/dist/esm/chunks/chunk.PEBT47AU.js.map +7 -0
- package/dist/esm/chunks/chunk.PH3HUFJJ.js +7 -0
- package/dist/esm/chunks/{chunk.JHBCYICS.js.map → chunk.PH3HUFJJ.js.map} +1 -1
- package/dist/esm/chunks/chunk.Q7JUJNYD.js +7 -0
- package/dist/esm/chunks/chunk.Q7JUJNYD.js.map +7 -0
- package/dist/esm/chunks/chunk.Q7Z3SJ5F.js +7 -0
- package/dist/esm/chunks/{chunk.4BEI55KI.js.map → chunk.Q7Z3SJ5F.js.map} +1 -1
- package/dist/esm/chunks/chunk.QCRRHGBA.js +7 -0
- package/dist/esm/chunks/chunk.QCRRHGBA.js.map +7 -0
- package/dist/esm/chunks/{chunk.IUOBRBDZ.js → chunk.QOJESHEV.js} +2 -2
- package/dist/esm/chunks/chunk.S3JMOOWC.js +7 -0
- package/dist/esm/chunks/{chunk.4WPFFNLH.js.map → chunk.S3JMOOWC.js.map} +1 -1
- package/dist/esm/chunks/{chunk.O4FB4BV5.js → chunk.SBYX7VZ4.js} +2 -2
- package/dist/esm/chunks/{chunk.O4FB4BV5.js.map → chunk.SBYX7VZ4.js.map} +2 -2
- package/dist/esm/chunks/{chunk.XUW3GG46.js → chunk.SFCGOCQK.js} +2 -2
- package/dist/esm/chunks/chunk.SJJS4LYN.js +7 -0
- package/dist/esm/chunks/chunk.SJJS4LYN.js.map +7 -0
- package/dist/esm/chunks/{chunk.P3IA2WTO.js → chunk.SMGXXR6K.js} +2 -2
- package/dist/esm/chunks/{chunk.P3IA2WTO.js.map → chunk.SMGXXR6K.js.map} +1 -1
- package/dist/esm/chunks/{chunk.PALRSBSY.js → chunk.SU4FU7GK.js} +2 -2
- package/dist/esm/chunks/{chunk.PALRSBSY.js.map → chunk.SU4FU7GK.js.map} +1 -1
- package/dist/esm/chunks/{chunk.XHV3GQ7L.js → chunk.TK5I4RHF.js} +2 -2
- package/dist/esm/chunks/{chunk.XHV3GQ7L.js.map → chunk.TK5I4RHF.js.map} +2 -2
- package/dist/esm/chunks/{chunk.BJE6O5ES.js → chunk.TYLOAD7R.js} +2 -2
- package/dist/esm/chunks/{chunk.BJE6O5ES.js.map → chunk.TYLOAD7R.js.map} +2 -2
- package/dist/esm/chunks/chunk.UJ2WQOLO.js +7 -0
- package/dist/esm/chunks/{chunk.E6CYXNS2.js.map → chunk.UJ2WQOLO.js.map} +2 -2
- package/dist/esm/chunks/{chunk.J2H5RXTX.js → chunk.ULY4H76N.js} +2 -2
- package/dist/esm/chunks/{chunk.J2H5RXTX.js.map → chunk.ULY4H76N.js.map} +1 -1
- package/dist/esm/chunks/{chunk.DONAMICM.js → chunk.UV3WIHCM.js} +1 -1
- package/dist/esm/chunks/{chunk.DONAMICM.js.map → chunk.UV3WIHCM.js.map} +1 -1
- package/dist/esm/chunks/{chunk.T76JYRPR.js → chunk.VSQOTSAO.js} +2 -2
- package/dist/esm/chunks/{chunk.T76JYRPR.js.map → chunk.VSQOTSAO.js.map} +2 -2
- package/dist/esm/chunks/chunk.VVXSELXX.js +7 -0
- package/dist/esm/chunks/chunk.VVXSELXX.js.map +7 -0
- package/dist/esm/chunks/chunk.VZWNNK7A.js +7 -0
- package/dist/esm/chunks/chunk.VZWNNK7A.js.map +7 -0
- package/dist/esm/chunks/chunk.W4247Q2P.js +7 -0
- package/dist/esm/chunks/{chunk.MHOS3IHQ.js.map → chunk.W4247Q2P.js.map} +1 -1
- package/dist/esm/chunks/chunk.WPG7NNQX.js +7 -0
- package/dist/esm/chunks/chunk.WPG7NNQX.js.map +7 -0
- package/dist/esm/chunks/{chunk.LYOQ2RGP.js → chunk.X3C3J5MH.js} +2 -2
- package/dist/esm/chunks/{chunk.LYOQ2RGP.js.map → chunk.X3C3J5MH.js.map} +1 -1
- package/dist/esm/chunks/{chunk.RBAVT3XQ.js → chunk.XGOAYMK2.js} +2 -2
- package/dist/esm/chunks/chunk.XI3MJSIS.js +7 -0
- package/dist/esm/chunks/chunk.XI3MJSIS.js.map +7 -0
- package/dist/esm/chunks/chunk.XIQFHO5R.js +7 -0
- package/dist/esm/chunks/{chunk.FVRSGKJD.js.map → chunk.XIQFHO5R.js.map} +2 -2
- package/dist/esm/chunks/chunk.XKI46BH2.js +7 -0
- package/dist/esm/chunks/{chunk.INCKI5IX.js.map → chunk.XKI46BH2.js.map} +1 -1
- package/dist/esm/chunks/{chunk.AFLH5HUG.js → chunk.YLG6ZC5K.js} +2 -2
- package/dist/esm/chunks/chunk.YRMR7IOS.js +7 -0
- package/dist/esm/chunks/chunk.YRMR7IOS.js.map +7 -0
- package/dist/esm/chunks/chunk.YWNCJ7XP.js +7 -0
- package/dist/esm/chunks/{chunk.242YUZKU.js.map → chunk.YWNCJ7XP.js.map} +2 -2
- package/dist/esm/chunks/{chunk.K2C4W3CO.js → chunk.YX7WLO5Y.js} +2 -2
- package/dist/esm/chunks/chunk.YZLASVCK.js +177 -0
- package/dist/esm/chunks/chunk.YZLASVCK.js.map +7 -0
- package/dist/esm/chunks/{chunk.5FPFRE4H.js → chunk.Z6FCL3G3.js} +2 -2
- package/dist/esm/chunks/{chunk.5FPFRE4H.js.map → chunk.Z6FCL3G3.js.map} +1 -1
- package/dist/esm/chunks/chunk.ZDD2NLGP.js +7 -0
- package/dist/esm/chunks/{chunk.FRYLJWYL.js → chunk.ZJC2DSNM.js} +2 -2
- package/dist/esm/chunks/{chunk.FRYLJWYL.js.map → chunk.ZJC2DSNM.js.map} +1 -1
- package/dist/esm/chunks/chunk.ZKGSQQGU.js +12 -0
- package/dist/esm/chunks/chunk.ZKGSQQGU.js.map +7 -0
- package/dist/esm/chunks/{chunk.JEN6YP2Q.js → chunk.ZVBZ3LGP.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/delegates/index.js +1 -1
- package/dist/esm/core/index.js +1 -1
- package/dist/esm/core/mask/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/floating-label/index.js +1 -1
- package/dist/esm/focus-indicator/index.js +7 -0
- package/dist/esm/focus-indicator/index.js.map +7 -0
- 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/state-layer/index.js +7 -0
- package/dist/esm/state-layer/index.js.map +7 -0
- 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/theme/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/dist/forge-dark.css +1 -1
- package/dist/forge.css +1 -1
- package/dist/icon-button/forge-icon-button.css +1 -1
- package/dist/table/forge-table.css +1 -1
- package/dist/theme/forge-theme.css +1 -1
- package/dist/typography/forge-typography-legacy.css +6 -0
- package/dist/typography/forge-typography.css +1 -1
- package/esm/accordion/accordion.js +4 -4
- package/esm/app-bar/app-bar.js +6 -6
- package/esm/app-bar/notification-button/app-bar-notification-button.js +5 -5
- package/esm/app-bar/profile-button/app-bar-profile-button-adapter.js +1 -1
- 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 +1 -5
- package/esm/autocomplete/autocomplete-component-delegate.d.ts +1 -1
- package/esm/autocomplete/autocomplete-constants.d.ts +5 -4
- package/esm/autocomplete/autocomplete-constants.js +1 -0
- package/esm/autocomplete/autocomplete-foundation.d.ts +5 -0
- package/esm/autocomplete/autocomplete-foundation.js +12 -12
- package/esm/autocomplete/autocomplete.d.ts +3 -0
- package/esm/autocomplete/autocomplete.js +13 -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 +7 -7
- package/esm/bottom-sheet/bottom-sheet.js +6 -6
- package/esm/busy-indicator/busy-indicator-adapter.js +1 -1
- package/esm/busy-indicator/busy-indicator-constants.d.ts +1 -1
- package/esm/busy-indicator/busy-indicator.js +6 -6
- package/esm/button/button-component-delegate.d.ts +1 -1
- package/esm/button/button.d.ts +1 -0
- package/esm/button/button.js +11 -5
- package/esm/button-toggle/button-toggle/button-toggle.js +7 -7
- 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.d.ts +3 -0
- package/esm/calendar/calendar-dropdown/calendar-dropdown.js +14 -5
- package/esm/calendar/calendar-menu/calendar-menu-constants.d.ts +2 -2
- package/esm/calendar/calendar-menu/calendar-menu.js +6 -6
- package/esm/calendar/calendar.js +7 -7
- package/esm/card/card-constants.d.ts +2 -2
- package/esm/card/card-constants.js +2 -2
- package/esm/card/card.d.ts +19 -8
- package/esm/card/card.js +34 -25
- package/esm/checkbox/checkbox-adapter.d.ts +1 -0
- package/esm/checkbox/checkbox-adapter.js +9 -2
- package/esm/checkbox/checkbox-component-delegate.d.ts +1 -1
- package/esm/checkbox/checkbox.js +4 -4
- package/esm/chip-field/chip-field-component-delegate.d.ts +1 -1
- package/esm/chip-field/chip-field-foundation.d.ts +1 -1
- package/esm/chip-field/chip-field-foundation.js +1 -1
- package/esm/chip-field/chip-field.js +1 -1
- package/esm/chips/chip/chip-adapter.js +2 -2
- package/esm/chips/chip/chip.js +7 -7
- package/esm/chips/chip-set/chip-set.js +5 -5
- package/esm/circular-progress/circular-progress-adapter.d.ts +7 -14
- package/esm/circular-progress/circular-progress-adapter.js +25 -25
- package/esm/circular-progress/circular-progress-constants.d.ts +6 -2
- package/esm/circular-progress/circular-progress-constants.js +8 -3
- package/esm/circular-progress/circular-progress-foundation.d.ts +0 -8
- package/esm/circular-progress/circular-progress-foundation.js +9 -27
- package/esm/circular-progress/circular-progress.d.ts +24 -5
- package/esm/circular-progress/circular-progress.js +33 -21
- package/esm/color-picker/color-picker-constants.d.ts +2 -2
- package/esm/color-picker/color-picker-foundation.d.ts +0 -1
- package/esm/color-picker/color-picker-foundation.js +2 -5
- package/esm/color-picker/color-picker.js +7 -7
- package/esm/core/base/base-component.d.ts +1 -2
- 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/testing/pointer.d.ts +13 -0
- package/esm/core/testing/pointer.js +42 -0
- package/esm/core/utils/utils.d.ts +33 -2
- package/esm/core/utils/utils.js +74 -6
- package/esm/date-picker/base/base-date-picker-adapter.d.ts +4 -2
- package/esm/date-picker/base/base-date-picker-adapter.js +6 -0
- package/esm/date-picker/base/base-date-picker-constants.d.ts +1 -0
- package/esm/date-picker/base/base-date-picker-constants.js +2 -1
- package/esm/date-picker/base/base-date-picker-foundation.d.ts +6 -2
- package/esm/date-picker/base/base-date-picker-foundation.js +21 -6
- package/esm/date-picker/base/base-date-picker.d.ts +3 -0
- package/esm/date-picker/base/base-date-picker.js +6 -0
- package/esm/date-picker/date-picker-adapter.js +6 -8
- package/esm/date-picker/date-picker-component-delegate.d.ts +1 -1
- package/esm/date-range-picker/date-range-picker-adapter.d.ts +4 -2
- package/esm/date-range-picker/date-range-picker-adapter.js +20 -18
- package/esm/date-range-picker/date-range-picker-component-delegate.d.ts +1 -1
- package/esm/date-range-picker/date-range-picker-foundation.d.ts +4 -1
- package/esm/date-range-picker/date-range-picker-foundation.js +48 -14
- package/esm/dialog/dialog-adapter.js +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-constants.d.ts +2 -0
- package/esm/expansion-panel/expansion-panel-constants.js +3 -1
- package/esm/expansion-panel/expansion-panel-foundation.js +4 -1
- package/esm/expansion-panel/expansion-panel.js +6 -6
- package/esm/field/field-adapter.d.ts +4 -2
- package/esm/field/field-adapter.js +5 -2
- package/esm/field/field-constants.d.ts +3 -3
- package/esm/field/field-foundation.d.ts +2 -2
- package/esm/field/field-foundation.js +12 -9
- 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 +6 -6
- 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/focus-indicator/focus-indicator-adapter.d.ts +29 -0
- package/esm/focus-indicator/focus-indicator-adapter.js +39 -0
- package/esm/focus-indicator/focus-indicator-constants.d.ts +15 -0
- package/esm/focus-indicator/focus-indicator-constants.js +19 -0
- package/esm/focus-indicator/focus-indicator-foundation.d.ts +43 -0
- package/esm/focus-indicator/focus-indicator-foundation.js +110 -0
- package/esm/focus-indicator/focus-indicator.d.ts +67 -0
- package/esm/focus-indicator/focus-indicator.js +112 -0
- package/esm/focus-indicator/index.d.ts +10 -0
- package/esm/focus-indicator/index.js +14 -0
- 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.d.ts +1 -0
- package/esm/icon-button/icon-button.js +16 -9
- package/esm/index.d.ts +2 -0
- package/esm/index.js +6 -0
- 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-adapter.d.ts +23 -0
- package/esm/linear-progress/linear-progress-adapter.js +34 -0
- package/esm/linear-progress/linear-progress-constants.d.ts +6 -2
- package/esm/linear-progress/linear-progress-constants.js +8 -3
- package/esm/linear-progress/linear-progress-foundation.d.ts +26 -0
- package/esm/linear-progress/linear-progress-foundation.js +53 -0
- package/esm/linear-progress/linear-progress.d.ts +32 -25
- package/esm/linear-progress/linear-progress.js +49 -107
- package/esm/list/list/list-adapter.js +2 -2
- package/esm/list/list/list.js +5 -5
- package/esm/list/list-item/list-item-adapter.d.ts +3 -3
- package/esm/list/list-item/list-item-adapter.js +2 -2
- package/esm/list/list-item/list-item-foundation.d.ts +1 -0
- package/esm/list/list-item/list-item-foundation.js +8 -1
- package/esm/list/list-item/list-item.js +6 -6
- package/esm/list-dropdown/list-dropdown-adapter.js +4 -5
- 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 +12 -12
- package/esm/popup/popup-adapter.js +2 -2
- 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 +6 -6
- 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-adapter.d.ts +1 -0
- package/esm/radio/radio-adapter.js +11 -3
- 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/select.js +1 -1
- package/esm/select/select-component-delegate.d.ts +1 -1
- package/esm/slider/slider-adapter.d.ts +79 -0
- package/esm/slider/slider-adapter.js +178 -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 +55 -19
- package/esm/slider/slider-constants.js +56 -14
- package/esm/slider/slider-foundation.d.ts +94 -0
- package/esm/slider/slider-foundation.js +313 -0
- package/esm/slider/slider-utils.d.ts +9 -0
- package/esm/slider/slider-utils.js +56 -0
- package/esm/slider/slider.d.ts +135 -66
- package/esm/slider/slider.js +241 -249
- package/esm/split-view/split-view/split-view-adapter.js +3 -1
- 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/state-layer/index.d.ts +10 -0
- package/esm/state-layer/index.js +14 -0
- package/esm/state-layer/state-layer-adapter.d.ts +41 -0
- package/esm/state-layer/state-layer-adapter.js +101 -0
- package/esm/state-layer/state-layer-constants.d.ts +79 -0
- package/esm/state-layer/state-layer-constants.js +89 -0
- package/esm/state-layer/state-layer-foundation.d.ts +57 -0
- package/esm/state-layer/state-layer-foundation.js +237 -0
- package/esm/state-layer/state-layer-utils.d.ts +26 -0
- package/esm/state-layer/state-layer-utils.js +54 -0
- package/esm/state-layer/state-layer.d.ts +66 -0
- package/esm/state-layer/state-layer.js +96 -0
- package/esm/stepper/core/stepper-utils.js +2 -1
- package/esm/stepper/step/step-constants.d.ts +1 -1
- package/esm/stepper/step/step.js +13 -13
- package/esm/stepper/stepper/stepper-adapter.js +1 -1
- package/esm/stepper/stepper/stepper-constants.d.ts +2 -2
- package/esm/stepper/stepper/stepper-foundation.js +1 -0
- 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 +19 -12
- package/esm/table/table.js +5 -5
- package/esm/table/types.d.ts +4 -4
- package/esm/tabs/tab/tab-adapter.d.ts +14 -40
- package/esm/tabs/tab/tab-adapter.js +57 -79
- package/esm/tabs/tab/tab-constants.d.ts +13 -14
- package/esm/tabs/tab/tab-constants.js +17 -10
- package/esm/tabs/tab/tab-foundation.d.ts +23 -23
- package/esm/tabs/tab/tab-foundation.js +66 -62
- package/esm/tabs/tab/tab.d.ts +56 -20
- package/esm/tabs/tab/tab.js +88 -39
- 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-adapter.d.ts +1 -1
- package/esm/text-field/text-field-adapter.js +5 -3
- package/esm/text-field/text-field-component-delegate.d.ts +1 -1
- package/esm/text-field/text-field.js +1 -1
- package/esm/theme/theme-utils.d.ts +2 -2
- package/esm/time-picker/time-picker-adapter.js +6 -8
- 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-foundation.js +9 -6
- package/esm/time-picker/time-picker.js +6 -6
- package/esm/toast/toast-constants.d.ts +2 -2
- package/esm/toast/toast.js +7 -7
- 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 +2 -4
- package/styles/app-bar/_mixins.scss +8 -1
- package/styles/card/_mixins.scss +8 -7
- package/styles/chips/chip/_mixins.scss +1 -0
- package/styles/circular-progress/_animation.scss +75 -0
- package/styles/circular-progress/_configuration.scss +23 -0
- package/styles/circular-progress/_core.scss +122 -0
- package/styles/circular-progress/circular-progress.scss +92 -3
- package/styles/circular-progress/index.scss +8 -0
- package/styles/core/styles/_utils.scss +63 -0
- package/styles/core/styles/animation/index.scss +16 -0
- package/styles/core/styles/border/index.scss +38 -0
- package/styles/core/styles/core/_config.scss +6 -0
- package/styles/core/styles/elevation/index.scss +61 -0
- package/styles/core/styles/shape/index.scss +31 -0
- package/styles/core/styles/spacing/index.scss +30 -0
- package/styles/core/styles/theme/index.scss +52 -0
- package/styles/core/styles/tokens/_color-palette.scss +299 -0
- package/styles/core/styles/tokens/animation/_tokens.scss +38 -0
- package/styles/core/styles/tokens/border/_tokens.scss +17 -0
- package/styles/core/styles/tokens/circular-progress/_tokens.scss +21 -0
- package/styles/core/styles/tokens/elevation/_tokens.scss +105 -0
- package/styles/core/styles/tokens/focus-indicator/_tokens.scss +34 -0
- package/styles/core/styles/tokens/index.scss +10 -0
- package/styles/core/styles/tokens/linear-progress/_tokens.scss +25 -0
- package/styles/core/styles/tokens/shape/_tokens.scss +42 -0
- package/styles/core/styles/tokens/slider/_tokens.scss +49 -0
- package/styles/core/styles/tokens/spacing/_tokens.scss +23 -0
- package/styles/core/styles/tokens/state-layer/_tokens.scss +23 -0
- package/styles/core/styles/tokens/tabs/tab/_tokens.scss +71 -0
- package/styles/core/styles/tokens/tabs/tab-bar/_tokens.scss +19 -0
- package/styles/core/styles/tokens/theme/_tokens.scss +133 -0
- package/styles/core/styles/tokens/typography/_tokens.scss +236 -0
- package/styles/core/styles/typography/index.scss +119 -0
- package/styles/focus-indicator/_animations.scss +36 -0
- package/styles/focus-indicator/_configuration.scss +23 -0
- package/styles/focus-indicator/_core.scss +52 -0
- package/styles/focus-indicator/focus-indicator.scss +55 -0
- package/styles/focus-indicator/index.scss +8 -0
- package/styles/linear-progress/_animations.scss +129 -0
- package/styles/linear-progress/_configuration.scss +29 -0
- package/styles/linear-progress/_core.scss +99 -0
- package/styles/linear-progress/index.scss +8 -0
- package/styles/linear-progress/linear-progress.scss +101 -18
- package/styles/list/list-item/_mixins.scss +11 -1
- package/styles/list/list-item/_variables.scss +9 -0
- package/styles/slider/_configuration.scss +61 -0
- package/styles/slider/_core.scss +344 -0
- package/styles/slider/index.scss +7 -0
- package/styles/slider/slider.scss +186 -14
- package/styles/state-layer/_configuration.scss +17 -0
- package/styles/state-layer/_core.scss +124 -0
- package/styles/state-layer/index.scss +7 -0
- package/styles/state-layer/state-layer.scss +38 -0
- package/styles/table/_mixins.scss +2 -2
- package/styles/tabs/tab/_configuration.scss +64 -0
- package/styles/tabs/tab/_core.scss +190 -0
- package/styles/tabs/tab/index.scss +7 -0
- package/styles/tabs/tab/tab.scss +182 -15
- package/styles/tabs/tab-bar/_configuration.scss +13 -0
- package/styles/tabs/tab-bar/_core.scss +60 -0
- package/styles/tabs/tab-bar/index.scss +7 -0
- package/styles/tabs/tab-bar/tab-bar.scss +66 -5
- package/styles/theme/_theme-dark.scss +4 -8
- package/styles/theme/_theme.scss +3 -36
- package/styles/typography/forge-typography-legacy.scss +8 -0
- package/styles/typography/forge-typography.scss +11 -3
- package/styles/utils/_mixins-core.scss +1 -1
- package/dist/esm/chunks/chunk.242YUZKU.js +0 -7
- package/dist/esm/chunks/chunk.2BNDXFI5.js +0 -7
- package/dist/esm/chunks/chunk.2BNDXFI5.js.map +0 -7
- package/dist/esm/chunks/chunk.2DXG2R3M.js +0 -73
- package/dist/esm/chunks/chunk.2DXG2R3M.js.map +0 -7
- package/dist/esm/chunks/chunk.44IJE5UL.js +0 -7
- package/dist/esm/chunks/chunk.44IJE5UL.js.map +0 -7
- package/dist/esm/chunks/chunk.47A2CN5U.js +0 -7
- package/dist/esm/chunks/chunk.4BEI55KI.js +0 -7
- package/dist/esm/chunks/chunk.4FSAAN6W.js +0 -29
- package/dist/esm/chunks/chunk.4FSAAN6W.js.map +0 -7
- package/dist/esm/chunks/chunk.4NI63FGK.js +0 -7
- package/dist/esm/chunks/chunk.4WPFFNLH.js +0 -7
- package/dist/esm/chunks/chunk.5WNKQTXX.js +0 -7
- package/dist/esm/chunks/chunk.6OKJPSUE.js +0 -7
- package/dist/esm/chunks/chunk.72AUOVCD.js +0 -7
- package/dist/esm/chunks/chunk.72AUOVCD.js.map +0 -7
- package/dist/esm/chunks/chunk.7A6MX6CS.js +0 -7
- package/dist/esm/chunks/chunk.7A6MX6CS.js.map +0 -7
- package/dist/esm/chunks/chunk.7BOXIJAM.js +0 -7
- package/dist/esm/chunks/chunk.7BOXIJAM.js.map +0 -7
- package/dist/esm/chunks/chunk.ABLKZXJ3.js +0 -12
- package/dist/esm/chunks/chunk.ABLKZXJ3.js.map +0 -7
- package/dist/esm/chunks/chunk.BTBHIIGI.js +0 -7
- package/dist/esm/chunks/chunk.C7AN6FMW.js +0 -7
- package/dist/esm/chunks/chunk.C7AN6FMW.js.map +0 -7
- package/dist/esm/chunks/chunk.CKYHP5MC.js +0 -7
- package/dist/esm/chunks/chunk.CKYHP5MC.js.map +0 -7
- package/dist/esm/chunks/chunk.DT7MZR5Y.js +0 -7
- package/dist/esm/chunks/chunk.DYNEJBYK.js +0 -7
- package/dist/esm/chunks/chunk.E6CYXNS2.js +0 -7
- package/dist/esm/chunks/chunk.EGRUD7S7.js +0 -7
- package/dist/esm/chunks/chunk.ESR2NHOS.js +0 -7
- package/dist/esm/chunks/chunk.ESR2NHOS.js.map +0 -7
- package/dist/esm/chunks/chunk.F3MP6AXF.js +0 -29
- package/dist/esm/chunks/chunk.F3MP6AXF.js.map +0 -7
- package/dist/esm/chunks/chunk.FVRSGKJD.js +0 -7
- package/dist/esm/chunks/chunk.G3ZTZ4AN.js +0 -7
- package/dist/esm/chunks/chunk.G3ZTZ4AN.js.map +0 -7
- package/dist/esm/chunks/chunk.G5MGGEFP.js +0 -7
- package/dist/esm/chunks/chunk.HPDBSBQJ.js +0 -29
- package/dist/esm/chunks/chunk.HPDBSBQJ.js.map +0 -7
- package/dist/esm/chunks/chunk.HV6SPRC4.js +0 -7
- package/dist/esm/chunks/chunk.HV6SPRC4.js.map +0 -7
- package/dist/esm/chunks/chunk.I5BAZWUF.js +0 -7
- package/dist/esm/chunks/chunk.I5BAZWUF.js.map +0 -7
- package/dist/esm/chunks/chunk.IGTXLDZS.js +0 -7
- package/dist/esm/chunks/chunk.ILRWZHH3.js +0 -29
- package/dist/esm/chunks/chunk.ILRWZHH3.js.map +0 -7
- package/dist/esm/chunks/chunk.INCKI5IX.js +0 -7
- package/dist/esm/chunks/chunk.J6WCFQSS.js +0 -7
- package/dist/esm/chunks/chunk.JHBCYICS.js +0 -7
- package/dist/esm/chunks/chunk.JHY2CKEH.js +0 -7
- package/dist/esm/chunks/chunk.K6AFP52A.js +0 -7
- package/dist/esm/chunks/chunk.K6AFP52A.js.map +0 -7
- package/dist/esm/chunks/chunk.KE6GOYAB.js +0 -7
- package/dist/esm/chunks/chunk.KE6GOYAB.js.map +0 -7
- package/dist/esm/chunks/chunk.LDN4HLF7.js +0 -7
- package/dist/esm/chunks/chunk.LDN4HLF7.js.map +0 -7
- package/dist/esm/chunks/chunk.M2QU3LUR.js +0 -7
- package/dist/esm/chunks/chunk.M2QU3LUR.js.map +0 -7
- package/dist/esm/chunks/chunk.MCIQXNKY.js +0 -7
- package/dist/esm/chunks/chunk.MHOS3IHQ.js +0 -7
- package/dist/esm/chunks/chunk.MSF55AA3.js +0 -7
- package/dist/esm/chunks/chunk.MSF55AA3.js.map +0 -7
- package/dist/esm/chunks/chunk.MXTDW27J.js +0 -7
- package/dist/esm/chunks/chunk.MXTDW27J.js.map +0 -7
- package/dist/esm/chunks/chunk.NW7NV2A2.js +0 -7
- package/dist/esm/chunks/chunk.NW7NV2A2.js.map +0 -7
- package/dist/esm/chunks/chunk.Q7LFOS2I.js +0 -7
- package/dist/esm/chunks/chunk.Q7LFOS2I.js.map +0 -7
- package/dist/esm/chunks/chunk.RB5BTA5N.js +0 -7
- package/dist/esm/chunks/chunk.RE5X26QT.js +0 -29
- package/dist/esm/chunks/chunk.RE5X26QT.js.map +0 -7
- package/dist/esm/chunks/chunk.RG6CDWEX.js +0 -7
- package/dist/esm/chunks/chunk.RG6CDWEX.js.map +0 -7
- package/dist/esm/chunks/chunk.ROR6JMAE.js +0 -7
- package/dist/esm/chunks/chunk.SAQVWOVK.js +0 -7
- package/dist/esm/chunks/chunk.SAQVWOVK.js.map +0 -7
- package/dist/esm/chunks/chunk.TWZXQQQO.js +0 -29
- package/dist/esm/chunks/chunk.TWZXQQQO.js.map +0 -7
- package/dist/esm/chunks/chunk.UF43SSFY.js +0 -7
- package/dist/esm/chunks/chunk.UF43SSFY.js.map +0 -7
- package/dist/esm/chunks/chunk.V4TCOZLK.js +0 -29
- package/dist/esm/chunks/chunk.V4TCOZLK.js.map +0 -7
- package/dist/esm/chunks/chunk.V7WKXEZC.js +0 -7
- package/dist/esm/chunks/chunk.V7WKXEZC.js.map +0 -7
- package/dist/esm/chunks/chunk.VAKNDCLP.js +0 -29
- package/dist/esm/chunks/chunk.VAKNDCLP.js.map +0 -7
- package/dist/esm/chunks/chunk.WY7DECJD.js +0 -7
- package/dist/esm/chunks/chunk.WY7DECJD.js.map +0 -7
- package/dist/esm/chunks/chunk.X5LGVZGO.js +0 -7
- package/dist/esm/chunks/chunk.X5LGVZGO.js.map +0 -7
- package/dist/esm/chunks/chunk.Y4GKBJGI.js +0 -7
- package/dist/esm/chunks/chunk.Y5A7RQ5M.js +0 -7
- package/dist/esm/chunks/chunk.Y66GSZJB.js +0 -7
- package/dist/esm/chunks/chunk.Y66GSZJB.js.map +0 -7
- package/dist/esm/chunks/chunk.Y72NANFX.js +0 -7
- package/dist/esm/chunks/chunk.Y72NANFX.js.map +0 -7
- package/dist/esm/chunks/chunk.YBEBD4CN.js +0 -7
- package/dist/esm/chunks/chunk.YI4JTY4T.js +0 -14
- package/dist/esm/chunks/chunk.YPZNIYQL.js +0 -7
- package/dist/esm/chunks/chunk.ZFHPUAYX.js +0 -7
- package/dist/typography/forge-form.css +0 -6
- package/styles/circular-progress/_keyframes.scss +0 -185
- package/styles/circular-progress/_mixins.scss +0 -320
- package/styles/circular-progress/_variables.scss +0 -50
- package/styles/linear-progress/_mixins.scss +0 -11
- package/styles/linear-progress/_variables.scss +0 -15
- package/styles/tabs/tab/_mixins.scss +0 -165
- package/styles/tabs/tab/_variables.scss +0 -9
- package/styles/tabs/tab-bar/_mixins.scss +0 -78
- package/styles/typography/forge-form.scss +0 -67
- /package/dist/esm/chunks/{chunk.JHY2CKEH.js.map → chunk.3HB22HCX.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.IGTXLDZS.js.map → chunk.4C6KHYUO.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.KU5CXXGS.js.map → chunk.A62DE5PD.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.G45OZEIS.js.map → chunk.CWTV3TB3.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.WP4QOOIS.js.map → chunk.DG4ZM3AW.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.EGRUD7S7.js.map → chunk.EK24Y56W.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.UT7QUGAO.js.map → chunk.FWFOOQMA.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.ZUNZKRRK.js.map → chunk.IX25DYIM.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.ARJ3EVVO.js.map → chunk.KVCDAZ6B.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.H4Z4DHPA.js.map → chunk.LTT67HTW.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.MCIQXNKY.js.map → chunk.M3QDAYD2.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.O73S5LF3.js.map → chunk.MGLL67VO.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.MLV25D2G.js.map → chunk.OWCYRSI3.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.IUOBRBDZ.js.map → chunk.QOJESHEV.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.XUW3GG46.js.map → chunk.SFCGOCQK.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.RBAVT3XQ.js.map → chunk.XGOAYMK2.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.AFLH5HUG.js.map → chunk.YLG6ZC5K.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.K2C4W3CO.js.map → chunk.YX7WLO5Y.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.DYNEJBYK.js.map → chunk.ZDD2NLGP.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.JEN6YP2Q.js.map → chunk.ZVBZ3LGP.js.map} +0 -0
|
@@ -3,5 +3,5 @@
|
|
|
3
3
|
* Copyright 2023 Tyler Technologies, Inc.
|
|
4
4
|
* License: Apache-2.0
|
|
5
5
|
*/
|
|
6
|
-
import{i as a}from"./chunk.J2M2MXP2.js";function u(t){return t.ownerDocument||document}function p(t){return t&&t.nodeType===1}function L(t,e){if(!p(t))throw new Error("DOMUtils - elementParents: invalid element argument");let o=[];for(;t.parentElement&&(o.push(t.parentElement),!(t.parentElement===e||t.parentElement===u(t).body));)t.parentElement&&t.parentElement.parentNode&&t.parentElement.parentNode.nodeType===11?t=t.parentElement.parentNode.host:t=t.parentElement;return o}function g(t,e){if(!p(t))throw new Error("DOMUtils - offset: invalid element argument");let o=t.getBoundingClientRect(),n=u(t).defaultView,r=e||n.document.documentElement,i={width:o.width,height:o.width,top:0,left:0,bottom:0,right:0};if(!e||r===n.document.documentElement||r===n.document.body)i.top=n.scrollY+o.top,i.bottom=r.clientHeight-n.scrollY-o.bottom,i.left=n.scrollX+o.left,i.right=r.clientWidth-n.scrollX-o.right;else{if(!p(e))throw new Error("DOMUtils - offset: invalid parentElement argument");let s=e.getBoundingClientRect();i.top=o.top-s.top,i.bottom=s.bottom-o.bottom,i.left=o.left-s.left,i.right=s.right-o.right}return{width:Math.round(o.width),height:Math.round(o.height),top:Math.round(i.top),bottom:Math.round(i.bottom),left:Math.round(i.left),right:Math.round(i.right)}}function M(t,e,o){let n=i=>{let s=()=>{i.stopPropagation(),i.cancelable&&i.preventDefault();let l=i.type==="touchstart"?i.target:u(t).activeElement;t.contains(l)||e(l)};o?window.requestAnimationFrame(()=>s()):s()},r=u(t);return r.addEventListener("blur",n,!0),r.addEventListener("touchstart",n,!0),()=>{r.removeEventListener("blur",n,!0),r.removeEventListener("touchstart",n,!0)}}function N(t){for(;t.lastChild;)t.removeChild(t.lastChild)}function P(t,e){return e.parentNode.replaceChild(t,e)}function b(t,e){a(t)?t.forEach(o=>e.classList.add(o)):e.classList.add(t)}function v(t,e){a(t)?t.forEach(o=>e.classList.remove(o)):e.classList.remove(t)}function x(){let t=document.createElement("fakeelement"),e={animation:"animationend",OAnimation:"oAnimationEnd",MozAnimation:"animationend",WebkitAnimation:"webkitAnimationEnd"};for(let o in e)if(t.style[o]!==void 0)return e[o]}async function W(t,e,o=!0){return t.classList.add(e),new Promise(n=>{let r=x(),i=()=>{o&&t.classList.remove(e),t.removeEventListener(r,i),n()};t.addEventListener(r,i)})}function E(t){t.removeNode?t.removeNode(!0):t.remove?t.remove():t.parentNode.removeChild(t)}function O(t){if(typeof t=="string"){if(t[t.length-1]==="%")return t;if(t.slice(-2)==="px")return t;if(Number(t)>=0)return`${t}px`}else if(typeof t=="number"&&t>=0)return`${t}px`}function R(t){let e=document.createElement("div");e.style.position="absolute",e.style.top="-99999px",e.style.left="-99999px",e.style.visibility="hidden",e.appendChild(t.cloneNode(!0)),document.body.appendChild(e);let o={width:e.scrollWidth,height:e.scrollHeight};return E(e),e=void 0,o}function H(t){return t.children.length?Promise.resolve():new Promise(e=>{let o=new MutationObserver(n=>{t.children.length&&(o.disconnect(),e())});o.observe(t,{childList:!0})})}function T(t,e){let o=f(t,e);return o.length?Promise.resolve(o[0]):new Promise(n=>{let r=new MutationObserver(i=>{if(i.reduce((l,c)=>l+c.addedNodes.length,0)>0){let l=f(t,e);l.length&&(r.disconnect(),n(l[0]))}});r.observe(t,{childList:!0,subtree:!0})})}function D(t,e){let o=t&&t.parentNode;for(;o;){if(e(o))return o;o=o.parentNode}return null}function U(t,e){let n=document.createElement("canvas").getContext("2d"),r=e?e.fontSize:16,i=e?e.fontFamily:"Roboto";return n.font=`${r}px ${i}`,n.measureText(t).width}function V(t,e){let o=[];for(let n=1;n<=t;n++)o.push(`${n}px ${n}px ${e}`);return o.join(", ")}function y(t,e){if(t.nodeType!==Node.ELEMENT_NODE)return!1;typeof e=="string"&&(e=e.replace(/\s+/,"").split(","));let o=Element.prototype.matches;return e.some(n=>o.call(t,n))}function f(t,e,o=!1){let n=[];if(!t)return n;if(typeof e=="string"&&(e=e.replace(/\s+/,"").split(",")),o&&y(t,e)&&n.indexOf(t)===-1&&n.push(t),t.tagName==="SLOT")t.assignedNodes().forEach(i=>n=n.concat(f(i,e,!0)));else{let r=t.shadowRoot?t.shadowRoot.firstElementChild:t.firstElementChild;for(;r;)n=n.concat(f(r,e,!0)),r=r.nextElementSibling}return n}function $(){let t
|
|
7
|
-
//# sourceMappingURL=chunk.
|
|
6
|
+
import{i as a}from"./chunk.J2M2MXP2.js";function u(t){return t.ownerDocument||document}function p(t){return t&&t.nodeType===1}function L(t,e){if(!p(t))throw new Error("DOMUtils - elementParents: invalid element argument");let o=[];for(;t.parentElement&&(o.push(t.parentElement),!(t.parentElement===e||t.parentElement===u(t).body));)t.parentElement&&t.parentElement.parentNode&&t.parentElement.parentNode.nodeType===11?t=t.parentElement.parentNode.host:t=t.parentElement;return o}function g(t,e){if(!p(t))throw new Error("DOMUtils - offset: invalid element argument");let o=t.getBoundingClientRect(),n=u(t).defaultView,r=e||n.document.documentElement,i={width:o.width,height:o.width,top:0,left:0,bottom:0,right:0};if(!e||r===n.document.documentElement||r===n.document.body)i.top=n.scrollY+o.top,i.bottom=r.clientHeight-n.scrollY-o.bottom,i.left=n.scrollX+o.left,i.right=r.clientWidth-n.scrollX-o.right;else{if(!p(e))throw new Error("DOMUtils - offset: invalid parentElement argument");let s=e.getBoundingClientRect();i.top=o.top-s.top,i.bottom=s.bottom-o.bottom,i.left=o.left-s.left,i.right=s.right-o.right}return{width:Math.round(o.width),height:Math.round(o.height),top:Math.round(i.top),bottom:Math.round(i.bottom),left:Math.round(i.left),right:Math.round(i.right)}}function M(t,e,o){let n=i=>{let s=()=>{i.stopPropagation(),i.cancelable&&i.preventDefault();let l=i.type==="touchstart"?i.target:u(t).activeElement;t.contains(l)||e(l)};o?window.requestAnimationFrame(()=>s()):s()},r=u(t);return r.addEventListener("blur",n,!0),r.addEventListener("touchstart",n,!0),()=>{r.removeEventListener("blur",n,!0),r.removeEventListener("touchstart",n,!0)}}function N(t){for(;t.lastChild;)t.removeChild(t.lastChild)}function P(t,e){return e.parentNode.replaceChild(t,e)}function b(t,e){a(t)?t.forEach(o=>e.classList.add(o)):e.classList.add(t)}function v(t,e){a(t)?t.forEach(o=>e.classList.remove(o)):e.classList.remove(t)}function x(){let t=document.createElement("fakeelement"),e={animation:"animationend",OAnimation:"oAnimationEnd",MozAnimation:"animationend",WebkitAnimation:"webkitAnimationEnd"};for(let o in e)if(t.style[o]!==void 0)return e[o]}async function W(t,e,o=!0){return t.classList.add(e),new Promise(n=>{let r=x(),i=()=>{o&&t.classList.remove(e),t.removeEventListener(r,i),n()};t.addEventListener(r,i)})}function E(t){t.removeNode?t.removeNode(!0):t.remove?t.remove():t.parentNode.removeChild(t)}function O(t){if(typeof t=="string"){if(t[t.length-1]==="%")return t;if(t.slice(-2)==="px")return t;if(Number(t)>=0)return`${t}px`}else if(typeof t=="number"&&t>=0)return`${t}px`}function R(t){let e=document.createElement("div");e.style.position="absolute",e.style.top="-99999px",e.style.left="-99999px",e.style.visibility="hidden",e.appendChild(t.cloneNode(!0)),document.body.appendChild(e);let o={width:e.scrollWidth,height:e.scrollHeight};return E(e),e=void 0,o}function H(t){return t.children.length?Promise.resolve():new Promise(e=>{let o=new MutationObserver(n=>{t.children.length&&(o.disconnect(),e())});o.observe(t,{childList:!0})})}function T(t,e){let o=f(t,e);return o.length?Promise.resolve(o[0]):new Promise(n=>{let r=new MutationObserver(i=>{if(i.reduce((l,c)=>l+c.addedNodes.length,0)>0){let l=f(t,e);l.length&&(r.disconnect(),n(l[0]))}});r.observe(t,{childList:!0,subtree:!0})})}function D(t,e){let o=t&&t.parentNode;for(;o;){if(e(o))return o;o=o.parentNode}return null}function U(t,e){let n=document.createElement("canvas").getContext("2d"),r=e?e.fontSize:16,i=e?e.fontFamily:"Roboto";return n.font=`${r}px ${i}`,n.measureText(t).width}function V(t,e){let o=[];for(let n=1;n<=t;n++)o.push(`${n}px ${n}px ${e}`);return o.join(", ")}function y(t,e){if(t.nodeType!==Node.ELEMENT_NODE)return!1;typeof e=="string"&&(e=e.replace(/\s+/,"").split(","));let o=Element.prototype.matches;return e.some(n=>o.call(t,n))}function f(t,e,o=!1){let n=[];if(!t)return n;if(typeof e=="string"&&(e=e.replace(/\s+/,"").split(",")),o&&y(t,e)&&n.indexOf(t)===-1&&n.push(t),t.tagName==="SLOT")t.assignedNodes().forEach(i=>n=n.concat(f(i,e,!0)));else{let r=t.shadowRoot?t.shadowRoot.firstElementChild:t.firstElementChild;for(;r;)n=n.concat(f(r,e,!0)),r=r.nextElementSibling}return n}function $(t=document){let e=t.activeElement;return!e||e===t.body?e:m(e)}function m(t){return t.shadowRoot&&t.shadowRoot.activeElement&&(t=m(t.shadowRoot.activeElement)),t}function B(t,e,o){e?b(o,t):v(o,t)}function F(t,e,o,n=""){e?t.setAttribute(o,n):t.removeAttribute(o)}function I(t,e,o,n){let r=t.getAttribute(e);(n===void 0||n===!0)&&(!r||!r.includes(o))?A(t,e,o):n||C(t,e,o)}function A(t,e,o){let n=t.getAttribute(e);!n||!n.length?t.setAttribute(e,o):t.setAttribute(e,`${n} ${o}`)}function C(t,e,o){if(!t.hasAttribute(e))return;let n=t.getAttribute(e);if(n){let r=n==null?void 0:n.replace(o,"");r=r.replace(/\s+/g," ").trim(),r.length?t.setAttribute(e,r):t.removeAttribute(e)}}function X(t,e,o="auto",n="nearest"){if(!t)return;if(t.scrollHeight>t.clientHeight||t.scrollWidth>t.clientWidth){let i=g(e,t),s=i.top<=e.clientHeight,l=i.bottom<=e.clientHeight;if(s||l){let d=h(n,s,e.offsetTop,e.clientHeight,t.offsetTop,t.offsetHeight);t.scrollTo({top:d,behavior:o});return}let c=i.left<=e.clientWidth,w=i.right<=e.clientWidth;if(c||w){let d=h(n,c,e.offsetLeft,e.clientWidth,t.offsetLeft,t.offsetWidth);t.scrollTo({left:d,behavior:o})}}}function h(t,e,o,n,r,i){return t==="nearest"?e?o-r-n:o-i+n*2:o-r-i/2+n/2}function k(t){let e=document.createElement("template");return t=t.trim(),e.innerHTML=t,e.content.firstElementChild}function Y(t,e,o){let n=new MutationObserver(r=>{for(let i of r)i.attributeName&&e(i.attributeName,t.getAttribute(i.attributeName))});return n.observe(t,{attributes:!0,attributeFilter:o}),n}export{p as a,L as b,M as c,N as d,P as e,b as f,v as g,W as h,E as i,O as j,R as k,H as l,T as m,D as n,U as o,V as p,y as q,f as r,$ as s,B as t,F as u,I as v,A as w,X as x,k as y,Y as z};
|
|
7
|
+
//# sourceMappingURL=chunk.K7FPXAFS.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../node_modules/@tylertech/forge-core/esm/utils/dom-utils.js"],
|
|
4
|
-
"sourcesContent": ["import { isArray } from './utils';\n/**\n * Holds regular expressions\n */\n/* tslint:disable-next-line:require-private-underscore */\nconst REGULAR_EXPRESSIONS = {\n placement: {\n auto: /\\s?auto?\\s?/i,\n primary: /^(top|bottom|left|right)$/,\n secondary: /^(top|bottom|left|right|center)$/,\n topBottom: /^(top|bottom)$/\n },\n overflow: /(auto|scroll)/\n};\n/**\n * Holds the browser scrollbar width.\n */\n/* tslint:disable-next-line:require-private-underscore */\nlet SCROLLBAR_WIDTH;\n/**\n * Gets the ownerDocument for an element, if null, than returns the document element.\n * @param {Element} element The element to get the ownerDocument for\n * @returns {Document}\n */\nfunction _ownerDocument(element) {\n return element.ownerDocument || document;\n}\n/**\n * Retrieves an element based on the provided root and selector.\n * @param {Element} root The root element to search within.\n * @param {string} selector The selector for the child element.\n * @param {boolean} [allowNull=false] Should the method allow the element to be not found? Default is false.\n * @returns {HTMLElement}\n */\nexport function getElement(root, selector, allowNull = false) {\n const element = root.querySelector(selector);\n if (!element && !allowNull) {\n throw new Error(`Element not found with selector: ${selector}`);\n }\n return element;\n}\n/**\n * Checks if an element is a valid element.\n * @param {Element} element The node to test\n * @returns {boolean}\n */\nexport function isElement(element) {\n return element && element.nodeType === 1;\n}\n/**\n * Checks if an element is statically positioned.\n * @param {Element} element The node to test.\n * @returns {boolean}\n */\nexport function isPositionStatic(element) {\n return (window.getComputedStyle(element).position || 'static') === 'static';\n}\n/**\n * Parses a style string to a numeric value (removes 'px').\n * @param {string} value The style string to parse.\n * @returns {number}\n */\nexport function parseStyle(value) {\n if (!value || !value.length) {\n return 0;\n }\n const parsedValue = parseFloat(value);\n return isFinite(parsedValue) ? parsedValue : 0;\n}\n/**\n * Gets the index of an element in the parent element children.\n * @param {Element} element The element to get the index on.\n * @returns {number}\n */\nexport function elementIndex(element) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - elementIndex: invalid element argument');\n }\n if (!element.parentElement) {\n return -1;\n }\n return Array.from(element.parentElement.children).indexOf(element);\n}\n/**\n * Gets an array of parent elements up to the body element.\n * @param {Element} element The element to get the parents of.\n * @param {Element=} untilElement Optional element where traversal should stop.\n * @returns {Array}\n */\nexport function elementParents(element, untilElement) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - elementParents: invalid element argument');\n }\n const parentElements = [];\n while (element.parentElement) {\n parentElements.push(element.parentElement);\n if (element.parentElement === untilElement || element.parentElement === _ownerDocument(element).body) {\n break;\n }\n // pierce shadow DOM\n if (element.parentElement && element.parentElement.parentNode && element.parentElement.parentNode.nodeType === 11) {\n element = element.parentElement.parentNode.host;\n }\n else {\n element = element.parentElement;\n }\n }\n return parentElements;\n}\n/**\n * Gets the non-statically positioned parent of an element.\n * @param element The element to get the offset parent of.\n * @returns {Element}\n */\nexport function offsetParent(element) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - offsetParent: invalid element argument');\n }\n let offsetParentElem = element.offsetParent;\n while (offsetParentElem && isPositionStatic(offsetParentElem)) {\n offsetParentElem = offsetParentElem.offsetParent;\n }\n return offsetParentElem || _ownerDocument(element).documentElement;\n}\n/**\n * Gets the browser scrollbar width.\n * @returns {number}\n */\nexport function scrollbarWidth() {\n if (SCROLLBAR_WIDTH === undefined) {\n const elem = document.createElement('div');\n elem.style.position = 'absolute';\n elem.style.top = '-100px';\n elem.style.left = '-100px';\n elem.style.width = '50px';\n elem.style.height = '50px';\n elem.style.overflow = 'scroll';\n document.body.appendChild(elem);\n const width = elem.offsetWidth - elem.clientWidth;\n removeElement(elem);\n SCROLLBAR_WIDTH = isFinite(width) ? width : 0;\n }\n return SCROLLBAR_WIDTH;\n}\n/**\n * Checks if an element is scrollable.\n * @param {Element} element The element to test for scrollability\n * @returns {boolean}\n */\nexport function isScrollable(element) {\n const elemStyle = window.getComputedStyle(element);\n return REGULAR_EXPRESSIONS.overflow.test('' + elemStyle.overflow + elemStyle.overflowY + elemStyle.overflowX);\n}\n/**\n * Gets the scroll parent of an element.\n * @param {Element} element The element to get the scroll parent of.\n * @param {boolean} [includeSelf=false] Should the element be checked for scrollability.\n * @returns {Element}\n */\nexport function scrollParent(element, includeSelf = false) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - scrollParent: invalid element argument');\n }\n const docElem = _ownerDocument(element).documentElement;\n const elemStyle = window.getComputedStyle(element);\n if (includeSelf && REGULAR_EXPRESSIONS.overflow.test('' + elemStyle.overflow + elemStyle.overflowY + elemStyle.overflowX)) {\n return element;\n }\n let excludeStatic = elemStyle.position === 'absolute';\n let scrollParentElem = element.parentElement || docElem;\n if (scrollParentElem === docElem || elemStyle.position === 'fixed') {\n return scrollParentElem;\n }\n while (scrollParentElem && scrollParentElem !== docElem) {\n const scrollParentStyle = window.getComputedStyle(scrollParentElem);\n if (excludeStatic && scrollParentStyle.position !== 'static') {\n excludeStatic = false;\n }\n if (!excludeStatic && REGULAR_EXPRESSIONS.overflow.test('' + scrollParentStyle.overflow + scrollParentStyle.overflowY + scrollParentStyle.overflowX)) {\n break;\n }\n scrollParentElem = scrollParentElem.scrollParent;\n }\n return scrollParentElem || docElem;\n}\n/**\n * Checks if the elements scroll parent scrollbars are visible.\n * @param {Element} element The element to check the scroll parent of.\n * @returns {IScrollbarVisibility}\n */\nexport function isScrollbarVisible(element) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - isDocumentScrolled: invalid element argument');\n }\n const scrollParentElem = scrollParent(element);\n return {\n x: scrollParentElem.scrollWidth > scrollParentElem.clientWidth,\n y: scrollParentElem.scrollHeight > scrollParentElem.clientHeight\n };\n}\n/**\n * Gets the offset from the element to the parent element edges.\n * If no parentElement is supplied, the documentElement will be used.\n * @param {Element} element The element to compute the offset for.\n * @param {Element=} parentElement Optional parent element to measure from.\n * @returns {DOMRect}\n */\nexport function offset(element, parentElement) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - offset: invalid element argument');\n }\n const elemBCR = element.getBoundingClientRect();\n const win = _ownerDocument(element).defaultView;\n const docElem = parentElement || win.document.documentElement;\n const offsetValues = { width: elemBCR.width, height: elemBCR.width, top: 0, left: 0, bottom: 0, right: 0 };\n if (!parentElement || docElem === win.document.documentElement || docElem === win.document.body) {\n offsetValues.top = win.scrollY + elemBCR.top;\n offsetValues.bottom = docElem.clientHeight - win.scrollY - elemBCR.bottom;\n offsetValues.left = win.scrollX + elemBCR.left;\n offsetValues.right = docElem.clientWidth - win.scrollX - elemBCR.right;\n }\n else {\n if (!isElement(parentElement)) {\n throw new Error('DOMUtils - offset: invalid parentElement argument');\n }\n const parentBCR = parentElement.getBoundingClientRect();\n offsetValues.top = elemBCR.top - parentBCR.top;\n offsetValues.bottom = parentBCR.bottom - elemBCR.bottom;\n offsetValues.left = elemBCR.left - parentBCR.left;\n offsetValues.right = parentBCR.right - elemBCR.right;\n }\n return {\n width: Math.round(elemBCR.width),\n height: Math.round(elemBCR.height),\n top: Math.round(offsetValues.top),\n bottom: Math.round(offsetValues.bottom),\n left: Math.round(offsetValues.left),\n right: Math.round(offsetValues.right)\n };\n}\n/**\n * Gets the offset from the element to the parent element viewable edges.\n * If no parentElement is supplied, the documentElement will be used.\n * @param {Element} element The element to measure\n * @param {Element=} parentElement The parent element to measure to.\n * @returns {DOMRect}\n */\nexport function viewportOffset(element, parentElement) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - offset: invalid element argument');\n }\n const win = _ownerDocument(element).defaultView;\n parentElement = parentElement || win.document.documentElement;\n const parentElementOffset = offset(element, parentElement);\n const offsetValues = {\n top: parentElementOffset.top,\n bottom: 0,\n left: parentElementOffset.left,\n right: 0\n };\n if (parentElement === win.document.documentElement) {\n offsetValues.top -= win.scrollY;\n offsetValues.left -= win.scrollX;\n }\n else {\n const parentStyle = window.getComputedStyle(parentElement);\n offsetValues.top -= parseStyle('' + parentStyle.borderTopWidth);\n offsetValues.left -= parseStyle('' + parentStyle.borderLeftWidth);\n }\n offsetValues.bottom = parentElement.clientHeight - offsetValues.top - element.offsetHeight;\n offsetValues.right = parentElement.clientWidth - offsetValues.left - element.offsetWidth;\n return {\n width: parentElementOffset.width,\n height: parentElementOffset.height,\n top: Math.round(offsetValues.top),\n bottom: Math.round(offsetValues.bottom),\n left: Math.round(offsetValues.left),\n right: Math.round(offsetValues.right)\n };\n}\n/**\n * Checks if any part of an element is visible in the viewport.\n * @param {Element} element The element to check.\n * @returns {boolean}\n */\nexport function isElementInViewport(element) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - isElementInViewport: invalid element argument');\n }\n const document = _ownerDocument(element);\n const scrollParentElem = scrollParent(element);\n const elemBCR = element.getBoundingClientRect();\n if (scrollParentElem !== document.documentElement && scrollParentElem !== document.body) {\n const scrollParentOffset = offset(element, scrollParentElem);\n if (scrollParentOffset.top + elemBCR.height < 0 ||\n scrollParentOffset.left + elemBCR.width < 0 ||\n scrollParentOffset.bottom + elemBCR.height - this.scrollbarWidth < 0 ||\n scrollParentOffset.right + elemBCR.width - this.scrollbarWidth < 0) {\n return false;\n }\n }\n if (elemBCR.top + elemBCR.height < 0 ||\n elemBCR.left + elemBCR.width < 0 ||\n elemBCR.bottom + elemBCR.height > document.documentElement.clientHeight ||\n elemBCR.right + elemBCR.width > document.documentElement.clientWidth) {\n return false;\n }\n return true;\n}\n/**\n * Adds an event listener to the document that will call the provided callback function\n * when an element and it's children no longer have focus. The blur and touchstart events are used\n * to evaluate the active element to determine if the callback should be called.\n *\n * @param {Element} element The element to add the event listener to.\n * @param {Function} callback The function to call when the element and children don't have focus.\n * @param {boolean} [delay=false] Should a RAF cycle occur before the callback is called.\n * @returns {Function} The function to call to remove the document events.\n */\nexport function notChildEventListener(element, callback, delay) {\n const evtHandler = (event) => {\n const handle = () => {\n event.stopPropagation();\n if (event.cancelable) {\n event.preventDefault();\n }\n const activeElement = (event.type === 'touchstart' ? event.target : _ownerDocument(element).activeElement);\n if (!element.contains(activeElement)) {\n callback(activeElement);\n }\n };\n if (delay) {\n window.requestAnimationFrame(() => handle());\n }\n else {\n handle();\n }\n };\n const docElem = _ownerDocument(element);\n docElem.addEventListener('blur', evtHandler, true);\n docElem.addEventListener('touchstart', evtHandler, true);\n return () => {\n docElem.removeEventListener('blur', evtHandler, true);\n docElem.removeEventListener('touchstart', evtHandler, true);\n };\n}\n/**\n * Removes all children from a DOM node.\n * @param node The DOM node to remove children from.\n */\nexport function removeAllChildren(node) {\n while (node.lastChild) {\n node.removeChild(node.lastChild);\n }\n}\n/**\n * Replaces one child node of the specified node with another.\n * @param newChild The new node to replace `oldChild`.\n * @param oldChild The existing node to be replaced.\n * @returns {Node} The replaced node. Same node as `oldChild`.\n */\nexport function replaceElement(newChild, oldChild) {\n return oldChild.parentNode.replaceChild(newChild, oldChild);\n}\n/**\n * Adds a class or array of classes to an element.\n *\n * @param {string | string[]} name The class(es) to add to the element\n * @param {Element} element The element to add class(es) to.\n */\nexport function addClass(name, element) {\n if (isArray(name)) {\n name.forEach(n => element.classList.add(n));\n }\n else {\n element.classList.add(name);\n }\n}\n/**\n * Removes a class or array of classes to an element.\n *\n * @param {string | string[]} name The class(es) to remove from the element\n * @param {Element} element The element to remove class(es) from.\n */\nexport function removeClass(name, element) {\n if (isArray(name)) {\n name.forEach(n => element.classList.remove(n));\n }\n else {\n element.classList.remove(name);\n }\n}\n/** Determines which type of animation event is supported. */\nexport function getAnimationEvent() {\n const el = document.createElement('fakeelement');\n // tslint:disable:object-literal-key-quotes\n const animations = {\n 'animation': 'animationend',\n 'OAnimation': 'oAnimationEnd',\n 'MozAnimation': 'animationend',\n 'WebkitAnimation': 'webkitAnimationEnd'\n };\n for (const t in animations) {\n if (el.style[t] !== undefined) {\n return animations[t];\n }\n }\n}\n/**\n * A helper method to trigger a keyframe animation via adding a class, and removing the class when the animation completes.\n * @param {HTMLElement} element The element to play the animation on.\n * @param {string} className The class to add that triggers the animation.\n */\nexport async function playKeyframeAnimation(element, className, remove = true) {\n element.classList.add(className);\n return new Promise(resolve => {\n const animationEvent = getAnimationEvent();\n const animationCompletedListener = () => {\n if (remove) {\n element.classList.remove(className);\n }\n element.removeEventListener(animationEvent, animationCompletedListener);\n resolve();\n };\n element.addEventListener(animationEvent, animationCompletedListener);\n });\n}\n/**\n * Removes an element from the DOM using the available remove method for that platform.\n * @param {HTMLElement} element The element to remove.\n */\nexport function removeElement(element) {\n if (element.removeNode) {\n element.removeNode(true);\n }\n else if (element.remove) {\n element.remove();\n }\n else {\n element.parentNode.removeChild(element);\n }\n}\n/**\n * Returns a width string that is safe for css based on the provided input.\n * @param {string | number} width\n * @returns {string | undefined} A width safe for using in CSS.\n */\nexport function safeCssWidth(width) {\n if (typeof width === 'string') {\n if (width[width.length - 1] === '%') {\n return width;\n }\n else if (width.slice(-2) === 'px') {\n return width;\n }\n else if (Number(width) >= 0) {\n return `${width}px`;\n }\n }\n else if (typeof width === 'number') {\n if (width >= 0) {\n return `${width}px`;\n }\n }\n return undefined;\n}\n/**\n * Calculates the size of an element that is not attached to the DOM.\n * @param {HTMLElement} element The element to calc the size of.\n * @returns {width, height} The size of the element.\n */\nexport function calcSizeUnattached(element) {\n let container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '-99999px';\n container.style.left = '-99999px';\n container.style.visibility = 'hidden';\n container.appendChild(element.cloneNode(true));\n document.body.appendChild(container);\n const size = {\n width: container.scrollWidth,\n height: container.scrollHeight\n };\n removeElement(container);\n container = undefined;\n return size;\n}\n/**\n * Resolves a promise when the provided element has children.\n * @param {Element} element An element that does or will contain children.\n */\nexport function ensureChildren(element) {\n if (element.children.length) {\n return Promise.resolve();\n }\n return new Promise(resolve => {\n const observer = new MutationObserver(changes => {\n if (element.children.length) {\n observer.disconnect();\n resolve();\n }\n });\n observer.observe(element, { childList: true });\n });\n}\n/**\n * Resolves a promise when the provided element has a child that matches a given selector.\n * @param {Element} element An element that does or will contain children.\n * @param {string} selector A CSS selector to use for finding an element.\n */\nexport function ensureChild(element, selector) {\n const initialElements = deepQuerySelectorAll(element, selector);\n if (initialElements.length) {\n return Promise.resolve(initialElements[0]);\n }\n return new Promise(resolve => {\n const observer = new MutationObserver(changes => {\n const hasAddedNodes = changes.reduce((prev, curr) => prev + curr.addedNodes.length, 0) > 0;\n if (hasAddedNodes) {\n const foundElements = deepQuerySelectorAll(element, selector);\n if (foundElements.length) {\n observer.disconnect();\n resolve(foundElements[0]);\n }\n }\n });\n observer.observe(element, { childList: true, subtree: true });\n });\n}\n/**\n * Resolves a promise when the provided host element has an `<input>` element child\n * @param {HTMLElement} host An element that does or will contain children.\n */\nexport function ensureInputElement(host) {\n return new Promise(resolve => {\n const element = host.querySelector('input');\n if (element) {\n resolve(element);\n }\n const observer = new MutationObserver(changes => {\n const hasAddedNodes = changes.reduce((prev, curr) => prev + curr.addedNodes.length, 0) > 0;\n if (hasAddedNodes) {\n const foundElement = host.querySelector('input');\n if (foundElement) {\n observer.disconnect();\n resolve(foundElement);\n }\n }\n });\n observer.observe(host, { childList: true, subtree: true });\n });\n}\n/**\n * Walks up the tree starting a specific node and stops when the provided matcher function returns true.\n * @param {Node} node The node to start searching from.\n * @returns {Node | null} The closest matching ancestor node, or null if not found.\n */\nexport function walkUpUntil(node, matcher) {\n let parent = node && node.parentNode;\n while (parent) {\n if (matcher(parent)) {\n return parent;\n }\n parent = parent.parentNode;\n }\n return null;\n}\n/**\n * Calculates the width of a string given the provided font information.\n */\nexport function calculateFontWidth(value, info) {\n const canvas = document.createElement('canvas');\n const ctx = canvas.getContext('2d');\n const fontSize = info ? info.fontSize : 16;\n const fontFamily = info ? info.fontFamily : 'Roboto';\n ctx.font = `${fontSize}px ${fontFamily}`;\n return ctx.measureText(value).width;\n}\n/**\n * Generates a CSS text-shadow style value based on the number of iterations and color provided.\n * @param {number} iterations The number of iterations for how long the shadow should be.\n * @param {string} color The color of the text shadow. Can be any CSS-safe color format. Ex. hex, rgb, rgba, hsl... etc.\n */\nexport function generateTextShadow(iterations, color) {\n const shadows = [];\n for (let i = 1; i <= iterations; i++) {\n shadows.push(`${i}px ${i}px ${color}`);\n }\n return shadows.join(', ');\n}\n/**\n * Checks if an element matches any of the provided selectors.\n * @param {Element} el The element to match.\n * @param {string[]} selectors The selectors to check the element against.\n */\nexport function matchesSelectors(el, selectors) {\n if (el.nodeType !== Node.ELEMENT_NODE) {\n return false;\n }\n if (typeof selectors === 'string') {\n selectors = selectors.replace(/\\s+/, '').split(',');\n }\n const matchesFn = Element.prototype.matches;\n return selectors.some(selector => matchesFn.call(el, selector));\n}\n/**\n * Walks the DOM tree starting at a root element and checks if any of its children\n * match the provided selectors. Similar to the native `querySelectorAll` except\n * that it will traverse the shadow DOM as well as slotted nodes.\n * @param {Element} rootElement The element to start querying from.\n * @param {string[]} selectors An array of CSS selectors.\n * @param {boolean} [checkRootElement] True if the provided root element is to be matched against the selectors.\n */\nexport function deepQuerySelectorAll(rootElement, selectors, checkRootElement = false) {\n let nodes = [];\n if (!rootElement) {\n return nodes;\n }\n if (typeof selectors === 'string') {\n selectors = selectors.replace(/\\s+/, '').split(',');\n }\n if (checkRootElement && matchesSelectors(rootElement, selectors) && nodes.indexOf(rootElement) === -1) {\n nodes.push(rootElement);\n }\n if (rootElement.tagName === 'SLOT') {\n const slotNodes = rootElement.assignedNodes();\n slotNodes.forEach(slottedNode => nodes = nodes.concat(deepQuerySelectorAll(slottedNode, selectors, true)));\n }\n else {\n let node = rootElement.shadowRoot ? rootElement.shadowRoot.firstElementChild : rootElement.firstElementChild;\n while (node) {\n nodes = nodes.concat(deepQuerySelectorAll(node, selectors, true));\n node = node.nextElementSibling;\n }\n }\n return nodes;\n}\n/**\n * Gets the currently focused element within the document by also traversing shadow roots.\n * @returns {Element}\n */\nexport function getActiveElement() {\n const activeElement = document.activeElement;\n if (!activeElement || activeElement === document.body) {\n return activeElement;\n }\n return getActiveShadowElement(activeElement);\n}\n/**\n * Gets the active element within the provided elements shadow root. If the element\n * does not have a shadow root, the provided element is returned.\n * @param {Element} element The active element.\n */\nexport function getActiveShadowElement(element) {\n if (element.shadowRoot && element.shadowRoot.activeElement) {\n element = getActiveShadowElement(element.shadowRoot.activeElement);\n }\n return element;\n}\n/** Toggles a CSS class (or classes) on an element based on a boolean. */\nexport function toggleClass(el, hasClass, className) {\n if (hasClass) {\n addClass(className, el);\n }\n else {\n removeClass(className, el);\n }\n}\n/** Toggles a value-less attribute on an element. */\nexport function toggleAttribute(el, hasAttribute, name, value = '') {\n if (hasAttribute) {\n el.setAttribute(name, value);\n }\n else {\n el.removeAttribute(name);\n }\n}\n/** Toggles part of an attribute on an element. */\nexport function toggleOnAttribute(el, attribute, value, force) {\n const oldValue = el.getAttribute(attribute);\n if ((force === undefined || force === true) && (!oldValue || !oldValue.includes(value))) {\n appendToAttribute(el, attribute, value);\n }\n else if (!force) {\n removeFromAttribute(el, attribute, value);\n }\n}\n/** Appends a value to an attribute on an element, first setting it if it doesn't exist. */\nexport function appendToAttribute(el, attribute, value) {\n const oldValue = el.getAttribute(attribute);\n if (!oldValue || !oldValue.length) {\n el.setAttribute(attribute, value);\n }\n else {\n el.setAttribute(attribute, `${oldValue} ${value}`);\n }\n}\n/** Removes a value from an attribute on an element, removing the attribute if empty. */\nexport function removeFromAttribute(el, attribute, value) {\n if (!el.hasAttribute(attribute)) {\n return;\n }\n const oldValue = el.getAttribute(attribute);\n if (oldValue) {\n let newValue = oldValue === null || oldValue === void 0 ? void 0 : oldValue.replace(value, '');\n newValue = newValue.replace(/\\s+/g, ' ').trim();\n if (newValue.length) {\n el.setAttribute(attribute, newValue);\n }\n else {\n el.removeAttribute(attribute);\n }\n }\n}\n/**\n * Attempts to scroll a target element into view within a scrollable parent element, unless already visible within the container.\n * @param scrollElement The scrollable parent element.\n * @param targetElement The element to scroll into view.\n * @param behavior The scroll behavior. Defaults to 'auto'.\n * @param block The block position to anchor the target element to within the scroll element.\n */\nexport function tryScrollIntoView(scrollElement, targetElement, behavior = 'auto', block = 'nearest') {\n if (!scrollElement) {\n return;\n }\n const canScroll = scrollElement.scrollHeight > scrollElement.clientHeight || scrollElement.scrollWidth > scrollElement.clientWidth;\n if (canScroll) {\n const offsetRect = offset(targetElement, scrollElement);\n const isClippedTop = offsetRect.top <= targetElement.clientHeight;\n const isClippedBottom = offsetRect.bottom <= targetElement.clientHeight;\n if (isClippedTop || isClippedBottom) {\n const top = calcBlockScroll(block, isClippedTop, targetElement.offsetTop, targetElement.clientHeight, scrollElement.offsetTop, scrollElement.offsetHeight);\n scrollElement.scrollTo({ top, behavior });\n return;\n }\n const isClippedLeft = offsetRect.left <= targetElement.clientWidth;\n const isClippedRight = offsetRect.right <= targetElement.clientWidth;\n if (isClippedLeft || isClippedRight) {\n const left = calcBlockScroll(block, isClippedLeft, targetElement.offsetLeft, targetElement.clientWidth, scrollElement.offsetLeft, scrollElement.offsetWidth);\n scrollElement.scrollTo({ left, behavior });\n }\n }\n}\n/** Calculates the block anchor position for a target element within a scrollable parent element. */\nexport function calcBlockScroll(block, isClippedStart, targetOffset, targetSize, scrollOffset, scrollSize) {\n if (block === 'nearest') {\n if (isClippedStart) {\n return (targetOffset - scrollOffset) - targetSize;\n }\n return (targetOffset - scrollSize) + targetSize * 2;\n }\n return targetOffset - scrollOffset - scrollSize / 2 + targetSize / 2;\n}\n/**\n * Creates an element from an HTML string.\n */\nexport function elementFromHTML(html) {\n const template = document.createElement('template');\n html = html.trim();\n template.innerHTML = html;\n return template.content.firstElementChild;\n}\n/**\n * Observes changes to the provided attributes on a target element and executes a provided callback when changed.\n * @param element The element to observe.\n * @param listener The callback to execute when an attribute changes on the element.\n * @param attributeFilter The attributes to observe.\n * @returns A `MutationObserver` instasnce.\n */\nexport function createElementAttributeObserver(element, listener, attributeFilter) {\n const observer = new MutationObserver(mutations => {\n for (const mutation of mutations) {\n if (mutation.attributeName) {\n listener(mutation.attributeName, element.getAttribute(mutation.attributeName));\n }\n }\n });\n observer.observe(element, { attributes: true, attributeFilter });\n return observer;\n}\n"],
|
|
5
|
-
"mappings": "wCAwBA,SAASA,EAAeC,EAAS,CAC7B,OAAOA,EAAQ,eAAiB,QACpC,CAoBO,SAASC,EAAUC,EAAS,CAC/B,OAAOA,GAAWA,EAAQ,WAAa,CAC3C,CAyCO,SAASC,EAAeC,EAASC,EAAc,CAClD,GAAI,CAACC,EAAUF,CAAO,EAClB,MAAM,IAAI,MAAM,qDAAqD,EAEzE,IAAMG,EAAiB,CAAC,EACxB,KAAOH,EAAQ,gBACXG,EAAe,KAAKH,EAAQ,aAAa,EACrC,EAAAA,EAAQ,gBAAkBC,GAAgBD,EAAQ,gBAAkBI,EAAeJ,CAAO,EAAE,QAI5FA,EAAQ,eAAiBA,EAAQ,cAAc,YAAcA,EAAQ,cAAc,WAAW,WAAa,GAC3GA,EAAUA,EAAQ,cAAc,WAAW,KAG3CA,EAAUA,EAAQ,cAG1B,OAAOG,CACX,CAmGO,SAASE,EAAOC,EAASC,EAAe,CAC3C,GAAI,CAACC,EAAUF,CAAO,EAClB,MAAM,IAAI,MAAM,6CAA6C,EAEjE,IAAMG,EAAUH,EAAQ,sBAAsB,EACxCI,EAAMC,EAAeL,CAAO,EAAE,YAC9BM,EAAUL,GAAiBG,EAAI,SAAS,gBACxCG,EAAe,CAAE,MAAOJ,EAAQ,MAAO,OAAQA,EAAQ,MAAO,IAAK,EAAG,KAAM,EAAG,OAAQ,EAAG,MAAO,CAAE,EACzG,GAAI,CAACF,GAAiBK,IAAYF,EAAI,SAAS,iBAAmBE,IAAYF,EAAI,SAAS,KACvFG,EAAa,IAAMH,EAAI,QAAUD,EAAQ,IACzCI,EAAa,OAASD,EAAQ,aAAeF,EAAI,QAAUD,EAAQ,OACnEI,EAAa,KAAOH,EAAI,QAAUD,EAAQ,KAC1CI,EAAa,MAAQD,EAAQ,YAAcF,EAAI,QAAUD,EAAQ,UAEhE,CACD,GAAI,CAACD,EAAUD,CAAa,EACxB,MAAM,IAAI,MAAM,mDAAmD,EAEvE,IAAMO,EAAYP,EAAc,sBAAsB,EACtDM,EAAa,IAAMJ,EAAQ,IAAMK,EAAU,IAC3CD,EAAa,OAASC,EAAU,OAASL,EAAQ,OACjDI,EAAa,KAAOJ,EAAQ,KAAOK,EAAU,KAC7CD,EAAa,MAAQC,EAAU,MAAQL,EAAQ,
|
|
6
|
-
"names": ["_ownerDocument", "element", "isElement", "element", "elementParents", "element", "untilElement", "isElement", "parentElements", "_ownerDocument", "offset", "element", "parentElement", "isElement", "elemBCR", "win", "_ownerDocument", "docElem", "offsetValues", "parentBCR", "notChildEventListener", "element", "callback", "delay", "evtHandler", "event", "handle", "activeElement", "_ownerDocument", "docElem", "removeAllChildren", "node", "replaceElement", "newChild", "oldChild", "addClass", "name", "isArray", "n", "removeClass", "getAnimationEvent", "el", "animations", "t", "playKeyframeAnimation", "className", "remove", "resolve", "animationEvent", "animationCompletedListener", "removeElement", "safeCssWidth", "width", "calcSizeUnattached", "container", "size", "ensureChildren", "observer", "changes", "ensureChild", "selector", "initialElements", "deepQuerySelectorAll", "prev", "curr", "foundElements", "walkUpUntil", "node", "matcher", "parent", "calculateFontWidth", "value", "info", "ctx", "fontSize", "fontFamily", "generateTextShadow", "iterations", "color", "shadows", "i", "matchesSelectors", "el", "selectors", "matchesFn", "selector", "deepQuerySelectorAll", "rootElement", "checkRootElement", "nodes", "slottedNode", "getActiveElement", "activeElement", "getActiveShadowElement", "element", "toggleClass", "hasClass", "className", "addClass", "removeClass", "toggleAttribute", "hasAttribute", "name", "toggleOnAttribute", "attribute", "force", "oldValue", "appendToAttribute", "removeFromAttribute", "newValue", "tryScrollIntoView", "scrollElement", "targetElement", "behavior", "block", "offsetRect", "offset", "isClippedTop", "isClippedBottom", "top", "calcBlockScroll", "isClippedLeft", "isClippedRight", "left", "isClippedStart", "targetOffset", "targetSize", "scrollOffset", "scrollSize", "elementFromHTML", "html", "template", "createElementAttributeObserver", "listener", "attributeFilter", "observer", "mutations", "mutation"]
|
|
4
|
+
"sourcesContent": ["import { isArray } from './utils';\n/**\n * Holds regular expressions\n */\n/* tslint:disable-next-line:require-private-underscore */\nconst REGULAR_EXPRESSIONS = {\n placement: {\n auto: /\\s?auto?\\s?/i,\n primary: /^(top|bottom|left|right)$/,\n secondary: /^(top|bottom|left|right|center)$/,\n topBottom: /^(top|bottom)$/\n },\n overflow: /(auto|scroll)/\n};\n/**\n * Holds the browser scrollbar width.\n */\n/* tslint:disable-next-line:require-private-underscore */\nlet SCROLLBAR_WIDTH;\n/**\n * Gets the ownerDocument for an element, if null, than returns the document element.\n * @param {Element} element The element to get the ownerDocument for\n * @returns {Document}\n */\nfunction _ownerDocument(element) {\n return element.ownerDocument || document;\n}\n/**\n * Retrieves an element based on the provided root and selector.\n * @param {Element} root The root element to search within.\n * @param {string} selector The selector for the child element.\n * @param {boolean} [allowNull=false] Should the method allow the element to be not found? Default is false.\n * @returns {HTMLElement}\n */\nexport function getElement(root, selector, allowNull = false) {\n const element = root.querySelector(selector);\n if (!element && !allowNull) {\n throw new Error(`Element not found with selector: ${selector}`);\n }\n return element;\n}\n/**\n * Checks if an element is a valid element.\n * @param {Element} element The node to test\n * @returns {boolean}\n */\nexport function isElement(element) {\n return element && element.nodeType === 1;\n}\n/**\n * Checks if an element is statically positioned.\n * @param {Element} element The node to test.\n * @returns {boolean}\n */\nexport function isPositionStatic(element) {\n return (window.getComputedStyle(element).position || 'static') === 'static';\n}\n/**\n * Parses a style string to a numeric value (removes 'px').\n * @param {string} value The style string to parse.\n * @returns {number}\n */\nexport function parseStyle(value) {\n if (!value || !value.length) {\n return 0;\n }\n const parsedValue = parseFloat(value);\n return isFinite(parsedValue) ? parsedValue : 0;\n}\n/**\n * Gets the index of an element in the parent element children.\n * @param {Element} element The element to get the index on.\n * @returns {number}\n */\nexport function elementIndex(element) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - elementIndex: invalid element argument');\n }\n if (!element.parentElement) {\n return -1;\n }\n return Array.from(element.parentElement.children).indexOf(element);\n}\n/**\n * Gets an array of parent elements up to the body element.\n * @param {Element} element The element to get the parents of.\n * @param {Element=} untilElement Optional element where traversal should stop.\n * @returns {Array}\n */\nexport function elementParents(element, untilElement) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - elementParents: invalid element argument');\n }\n const parentElements = [];\n while (element.parentElement) {\n parentElements.push(element.parentElement);\n if (element.parentElement === untilElement || element.parentElement === _ownerDocument(element).body) {\n break;\n }\n // pierce shadow DOM\n if (element.parentElement && element.parentElement.parentNode && element.parentElement.parentNode.nodeType === 11) {\n element = element.parentElement.parentNode.host;\n }\n else {\n element = element.parentElement;\n }\n }\n return parentElements;\n}\n/**\n * Gets the non-statically positioned parent of an element.\n * @param element The element to get the offset parent of.\n * @returns {Element}\n */\nexport function offsetParent(element) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - offsetParent: invalid element argument');\n }\n let offsetParentElem = element.offsetParent;\n while (offsetParentElem && isPositionStatic(offsetParentElem)) {\n offsetParentElem = offsetParentElem.offsetParent;\n }\n return offsetParentElem || _ownerDocument(element).documentElement;\n}\n/**\n * Gets the browser scrollbar width.\n * @returns {number}\n */\nexport function scrollbarWidth() {\n if (SCROLLBAR_WIDTH === undefined) {\n const elem = document.createElement('div');\n elem.style.position = 'absolute';\n elem.style.top = '-100px';\n elem.style.left = '-100px';\n elem.style.width = '50px';\n elem.style.height = '50px';\n elem.style.overflow = 'scroll';\n document.body.appendChild(elem);\n const width = elem.offsetWidth - elem.clientWidth;\n removeElement(elem);\n SCROLLBAR_WIDTH = isFinite(width) ? width : 0;\n }\n return SCROLLBAR_WIDTH;\n}\n/**\n * Checks if an element is scrollable.\n * @param {Element} element The element to test for scrollability\n * @returns {boolean}\n */\nexport function isScrollable(element) {\n const elemStyle = window.getComputedStyle(element);\n return REGULAR_EXPRESSIONS.overflow.test('' + elemStyle.overflow + elemStyle.overflowY + elemStyle.overflowX);\n}\n/**\n * Gets the scroll parent of an element.\n * @param {Element} element The element to get the scroll parent of.\n * @param {boolean} [includeSelf=false] Should the element be checked for scrollability.\n * @returns {Element}\n */\nexport function scrollParent(element, includeSelf = false) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - scrollParent: invalid element argument');\n }\n const docElem = _ownerDocument(element).documentElement;\n const elemStyle = window.getComputedStyle(element);\n if (includeSelf && REGULAR_EXPRESSIONS.overflow.test('' + elemStyle.overflow + elemStyle.overflowY + elemStyle.overflowX)) {\n return element;\n }\n let excludeStatic = elemStyle.position === 'absolute';\n let scrollParentElem = element.parentElement || docElem;\n if (scrollParentElem === docElem || elemStyle.position === 'fixed') {\n return scrollParentElem;\n }\n while (scrollParentElem && scrollParentElem !== docElem) {\n const scrollParentStyle = window.getComputedStyle(scrollParentElem);\n if (excludeStatic && scrollParentStyle.position !== 'static') {\n excludeStatic = false;\n }\n if (!excludeStatic && REGULAR_EXPRESSIONS.overflow.test('' + scrollParentStyle.overflow + scrollParentStyle.overflowY + scrollParentStyle.overflowX)) {\n break;\n }\n scrollParentElem = scrollParentElem.scrollParent;\n }\n return scrollParentElem || docElem;\n}\n/**\n * Checks if the elements scroll parent scrollbars are visible.\n * @param {Element} element The element to check the scroll parent of.\n * @returns {IScrollbarVisibility}\n */\nexport function isScrollbarVisible(element) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - isDocumentScrolled: invalid element argument');\n }\n const scrollParentElem = scrollParent(element);\n return {\n x: scrollParentElem.scrollWidth > scrollParentElem.clientWidth,\n y: scrollParentElem.scrollHeight > scrollParentElem.clientHeight\n };\n}\n/**\n * Gets the offset from the element to the parent element edges.\n * If no parentElement is supplied, the documentElement will be used.\n * @param {Element} element The element to compute the offset for.\n * @param {Element=} parentElement Optional parent element to measure from.\n * @returns {DOMRect}\n */\nexport function offset(element, parentElement) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - offset: invalid element argument');\n }\n const elemBCR = element.getBoundingClientRect();\n const win = _ownerDocument(element).defaultView;\n const docElem = parentElement || win.document.documentElement;\n const offsetValues = { width: elemBCR.width, height: elemBCR.width, top: 0, left: 0, bottom: 0, right: 0 };\n if (!parentElement || docElem === win.document.documentElement || docElem === win.document.body) {\n offsetValues.top = win.scrollY + elemBCR.top;\n offsetValues.bottom = docElem.clientHeight - win.scrollY - elemBCR.bottom;\n offsetValues.left = win.scrollX + elemBCR.left;\n offsetValues.right = docElem.clientWidth - win.scrollX - elemBCR.right;\n }\n else {\n if (!isElement(parentElement)) {\n throw new Error('DOMUtils - offset: invalid parentElement argument');\n }\n const parentBCR = parentElement.getBoundingClientRect();\n offsetValues.top = elemBCR.top - parentBCR.top;\n offsetValues.bottom = parentBCR.bottom - elemBCR.bottom;\n offsetValues.left = elemBCR.left - parentBCR.left;\n offsetValues.right = parentBCR.right - elemBCR.right;\n }\n return {\n width: Math.round(elemBCR.width),\n height: Math.round(elemBCR.height),\n top: Math.round(offsetValues.top),\n bottom: Math.round(offsetValues.bottom),\n left: Math.round(offsetValues.left),\n right: Math.round(offsetValues.right)\n };\n}\n/**\n * Gets the offset from the element to the parent element viewable edges.\n * If no parentElement is supplied, the documentElement will be used.\n * @param {Element} element The element to measure\n * @param {Element=} parentElement The parent element to measure to.\n * @returns {DOMRect}\n */\nexport function viewportOffset(element, parentElement) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - offset: invalid element argument');\n }\n const win = _ownerDocument(element).defaultView;\n parentElement = parentElement || win.document.documentElement;\n const parentElementOffset = offset(element, parentElement);\n const offsetValues = {\n top: parentElementOffset.top,\n bottom: 0,\n left: parentElementOffset.left,\n right: 0\n };\n if (parentElement === win.document.documentElement) {\n offsetValues.top -= win.scrollY;\n offsetValues.left -= win.scrollX;\n }\n else {\n const parentStyle = window.getComputedStyle(parentElement);\n offsetValues.top -= parseStyle('' + parentStyle.borderTopWidth);\n offsetValues.left -= parseStyle('' + parentStyle.borderLeftWidth);\n }\n offsetValues.bottom = parentElement.clientHeight - offsetValues.top - element.offsetHeight;\n offsetValues.right = parentElement.clientWidth - offsetValues.left - element.offsetWidth;\n return {\n width: parentElementOffset.width,\n height: parentElementOffset.height,\n top: Math.round(offsetValues.top),\n bottom: Math.round(offsetValues.bottom),\n left: Math.round(offsetValues.left),\n right: Math.round(offsetValues.right)\n };\n}\n/**\n * Checks if any part of an element is visible in the viewport.\n * @param {Element} element The element to check.\n * @returns {boolean}\n */\nexport function isElementInViewport(element) {\n if (!isElement(element)) {\n throw new Error('DOMUtils - isElementInViewport: invalid element argument');\n }\n const document = _ownerDocument(element);\n const scrollParentElem = scrollParent(element);\n const elemBCR = element.getBoundingClientRect();\n if (scrollParentElem !== document.documentElement && scrollParentElem !== document.body) {\n const scrollParentOffset = offset(element, scrollParentElem);\n if (scrollParentOffset.top + elemBCR.height < 0 ||\n scrollParentOffset.left + elemBCR.width < 0 ||\n scrollParentOffset.bottom + elemBCR.height - this.scrollbarWidth < 0 ||\n scrollParentOffset.right + elemBCR.width - this.scrollbarWidth < 0) {\n return false;\n }\n }\n if (elemBCR.top + elemBCR.height < 0 ||\n elemBCR.left + elemBCR.width < 0 ||\n elemBCR.bottom + elemBCR.height > document.documentElement.clientHeight ||\n elemBCR.right + elemBCR.width > document.documentElement.clientWidth) {\n return false;\n }\n return true;\n}\n/**\n * Adds an event listener to the document that will call the provided callback function\n * when an element and it's children no longer have focus. The blur and touchstart events are used\n * to evaluate the active element to determine if the callback should be called.\n *\n * @param {Element} element The element to add the event listener to.\n * @param {Function} callback The function to call when the element and children don't have focus.\n * @param {boolean} [delay=false] Should a RAF cycle occur before the callback is called.\n * @returns {Function} The function to call to remove the document events.\n */\nexport function notChildEventListener(element, callback, delay) {\n const evtHandler = (event) => {\n const handle = () => {\n event.stopPropagation();\n if (event.cancelable) {\n event.preventDefault();\n }\n const activeElement = (event.type === 'touchstart' ? event.target : _ownerDocument(element).activeElement);\n if (!element.contains(activeElement)) {\n callback(activeElement);\n }\n };\n if (delay) {\n window.requestAnimationFrame(() => handle());\n }\n else {\n handle();\n }\n };\n const docElem = _ownerDocument(element);\n docElem.addEventListener('blur', evtHandler, true);\n docElem.addEventListener('touchstart', evtHandler, true);\n return () => {\n docElem.removeEventListener('blur', evtHandler, true);\n docElem.removeEventListener('touchstart', evtHandler, true);\n };\n}\n/**\n * Removes all children from a DOM node.\n * @param node The DOM node to remove children from.\n */\nexport function removeAllChildren(node) {\n while (node.lastChild) {\n node.removeChild(node.lastChild);\n }\n}\n/**\n * Replaces one child node of the specified node with another.\n * @param newChild The new node to replace `oldChild`.\n * @param oldChild The existing node to be replaced.\n * @returns {Node} The replaced node. Same node as `oldChild`.\n */\nexport function replaceElement(newChild, oldChild) {\n return oldChild.parentNode.replaceChild(newChild, oldChild);\n}\n/**\n * Adds a class or array of classes to an element.\n *\n * @param {string | string[]} name The class(es) to add to the element\n * @param {Element} element The element to add class(es) to.\n */\nexport function addClass(name, element) {\n if (isArray(name)) {\n name.forEach(n => element.classList.add(n));\n }\n else {\n element.classList.add(name);\n }\n}\n/**\n * Removes a class or array of classes to an element.\n *\n * @param {string | string[]} name The class(es) to remove from the element\n * @param {Element} element The element to remove class(es) from.\n */\nexport function removeClass(name, element) {\n if (isArray(name)) {\n name.forEach(n => element.classList.remove(n));\n }\n else {\n element.classList.remove(name);\n }\n}\n/** Determines which type of animation event is supported. */\nexport function getAnimationEvent() {\n const el = document.createElement('fakeelement');\n // tslint:disable:object-literal-key-quotes\n const animations = {\n 'animation': 'animationend',\n 'OAnimation': 'oAnimationEnd',\n 'MozAnimation': 'animationend',\n 'WebkitAnimation': 'webkitAnimationEnd'\n };\n for (const t in animations) {\n if (el.style[t] !== undefined) {\n return animations[t];\n }\n }\n}\n/**\n * A helper method to trigger a keyframe animation via adding a class, and removing the class when the animation completes.\n * @param {HTMLElement} element The element to play the animation on.\n * @param {string} className The class to add that triggers the animation.\n */\nexport async function playKeyframeAnimation(element, className, remove = true) {\n element.classList.add(className);\n return new Promise(resolve => {\n const animationEvent = getAnimationEvent();\n const animationCompletedListener = () => {\n if (remove) {\n element.classList.remove(className);\n }\n element.removeEventListener(animationEvent, animationCompletedListener);\n resolve();\n };\n element.addEventListener(animationEvent, animationCompletedListener);\n });\n}\n/**\n * Removes an element from the DOM using the available remove method for that platform.\n * @param {HTMLElement} element The element to remove.\n */\nexport function removeElement(element) {\n if (element.removeNode) {\n element.removeNode(true);\n }\n else if (element.remove) {\n element.remove();\n }\n else {\n element.parentNode.removeChild(element);\n }\n}\n/**\n * Returns a width string that is safe for css based on the provided input.\n * @param {string | number} width\n * @returns {string | undefined} A width safe for using in CSS.\n */\nexport function safeCssWidth(width) {\n if (typeof width === 'string') {\n if (width[width.length - 1] === '%') {\n return width;\n }\n else if (width.slice(-2) === 'px') {\n return width;\n }\n else if (Number(width) >= 0) {\n return `${width}px`;\n }\n }\n else if (typeof width === 'number') {\n if (width >= 0) {\n return `${width}px`;\n }\n }\n return undefined;\n}\n/**\n * Calculates the size of an element that is not attached to the DOM.\n * @param {HTMLElement} element The element to calc the size of.\n * @returns {width, height} The size of the element.\n */\nexport function calcSizeUnattached(element) {\n let container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '-99999px';\n container.style.left = '-99999px';\n container.style.visibility = 'hidden';\n container.appendChild(element.cloneNode(true));\n document.body.appendChild(container);\n const size = {\n width: container.scrollWidth,\n height: container.scrollHeight\n };\n removeElement(container);\n container = undefined;\n return size;\n}\n/**\n * Resolves a promise when the provided element has children.\n * @param {Element} element An element that does or will contain children.\n */\nexport function ensureChildren(element) {\n if (element.children.length) {\n return Promise.resolve();\n }\n return new Promise(resolve => {\n const observer = new MutationObserver(changes => {\n if (element.children.length) {\n observer.disconnect();\n resolve();\n }\n });\n observer.observe(element, { childList: true });\n });\n}\n/**\n * Resolves a promise when the provided element has a child that matches a given selector.\n * @param {Element} element An element that does or will contain children.\n * @param {string} selector A CSS selector to use for finding an element.\n */\nexport function ensureChild(element, selector) {\n const initialElements = deepQuerySelectorAll(element, selector);\n if (initialElements.length) {\n return Promise.resolve(initialElements[0]);\n }\n return new Promise(resolve => {\n const observer = new MutationObserver(changes => {\n const hasAddedNodes = changes.reduce((prev, curr) => prev + curr.addedNodes.length, 0) > 0;\n if (hasAddedNodes) {\n const foundElements = deepQuerySelectorAll(element, selector);\n if (foundElements.length) {\n observer.disconnect();\n resolve(foundElements[0]);\n }\n }\n });\n observer.observe(element, { childList: true, subtree: true });\n });\n}\n/**\n * Resolves a promise when the provided host element has an `<input>` element child\n * @param {HTMLElement} host An element that does or will contain children.\n */\nexport function ensureInputElement(host) {\n return new Promise(resolve => {\n const element = host.querySelector('input');\n if (element) {\n resolve(element);\n }\n const observer = new MutationObserver(changes => {\n const hasAddedNodes = changes.reduce((prev, curr) => prev + curr.addedNodes.length, 0) > 0;\n if (hasAddedNodes) {\n const foundElement = host.querySelector('input');\n if (foundElement) {\n observer.disconnect();\n resolve(foundElement);\n }\n }\n });\n observer.observe(host, { childList: true, subtree: true });\n });\n}\n/**\n * Walks up the tree starting a specific node and stops when the provided matcher function returns true.\n * @param {Node} node The node to start searching from.\n * @returns {Node | null} The closest matching ancestor node, or null if not found.\n */\nexport function walkUpUntil(node, matcher) {\n let parent = node && node.parentNode;\n while (parent) {\n if (matcher(parent)) {\n return parent;\n }\n parent = parent.parentNode;\n }\n return null;\n}\n/**\n * Calculates the width of a string given the provided font information.\n */\nexport function calculateFontWidth(value, info) {\n const canvas = document.createElement('canvas');\n const ctx = canvas.getContext('2d');\n const fontSize = info ? info.fontSize : 16;\n const fontFamily = info ? info.fontFamily : 'Roboto';\n ctx.font = `${fontSize}px ${fontFamily}`;\n return ctx.measureText(value).width;\n}\n/**\n * Generates a CSS text-shadow style value based on the number of iterations and color provided.\n * @param {number} iterations The number of iterations for how long the shadow should be.\n * @param {string} color The color of the text shadow. Can be any CSS-safe color format. Ex. hex, rgb, rgba, hsl... etc.\n */\nexport function generateTextShadow(iterations, color) {\n const shadows = [];\n for (let i = 1; i <= iterations; i++) {\n shadows.push(`${i}px ${i}px ${color}`);\n }\n return shadows.join(', ');\n}\n/**\n * Checks if an element matches any of the provided selectors.\n * @param {Element} el The element to match.\n * @param {string[]} selectors The selectors to check the element against.\n */\nexport function matchesSelectors(el, selectors) {\n if (el.nodeType !== Node.ELEMENT_NODE) {\n return false;\n }\n if (typeof selectors === 'string') {\n selectors = selectors.replace(/\\s+/, '').split(',');\n }\n const matchesFn = Element.prototype.matches;\n return selectors.some(selector => matchesFn.call(el, selector));\n}\n/**\n * Walks the DOM tree starting at a root element and checks if any of its children\n * match the provided selectors. Similar to the native `querySelectorAll` except\n * that it will traverse the shadow DOM as well as slotted nodes.\n * @param {Element} rootElement The element to start querying from.\n * @param {string[]} selectors An array of CSS selectors.\n * @param {boolean} [checkRootElement] True if the provided root element is to be matched against the selectors.\n */\nexport function deepQuerySelectorAll(rootElement, selectors, checkRootElement = false) {\n let nodes = [];\n if (!rootElement) {\n return nodes;\n }\n if (typeof selectors === 'string') {\n selectors = selectors.replace(/\\s+/, '').split(',');\n }\n if (checkRootElement && matchesSelectors(rootElement, selectors) && nodes.indexOf(rootElement) === -1) {\n nodes.push(rootElement);\n }\n if (rootElement.tagName === 'SLOT') {\n const slotNodes = rootElement.assignedNodes();\n slotNodes.forEach(slottedNode => nodes = nodes.concat(deepQuerySelectorAll(slottedNode, selectors, true)));\n }\n else {\n let node = rootElement.shadowRoot ? rootElement.shadowRoot.firstElementChild : rootElement.firstElementChild;\n while (node) {\n nodes = nodes.concat(deepQuerySelectorAll(node, selectors, true));\n node = node.nextElementSibling;\n }\n }\n return nodes;\n}\n/**\n * Gets the currently focused element within the document by also traversing shadow roots.\n * @param {Document} doc The document to get the active element from. Defaults to the current document.\n * @returns {Element}\n */\nexport function getActiveElement(doc = document) {\n const activeElement = doc.activeElement;\n if (!activeElement || activeElement === doc.body) {\n return activeElement;\n }\n return getActiveShadowElement(activeElement);\n}\n/**\n * Gets the active element within the provided elements shadow root. If the element\n * does not have a shadow root, the provided element is returned.\n * @param {Element} element The active element.\n */\nexport function getActiveShadowElement(element) {\n if (element.shadowRoot && element.shadowRoot.activeElement) {\n element = getActiveShadowElement(element.shadowRoot.activeElement);\n }\n return element;\n}\n/** Toggles a CSS class (or classes) on an element based on a boolean. */\nexport function toggleClass(el, hasClass, className) {\n if (hasClass) {\n addClass(className, el);\n }\n else {\n removeClass(className, el);\n }\n}\n/** Toggles a value-less attribute on an element. */\nexport function toggleAttribute(el, hasAttribute, name, value = '') {\n if (hasAttribute) {\n el.setAttribute(name, value);\n }\n else {\n el.removeAttribute(name);\n }\n}\n/** Toggles part of an attribute on an element. */\nexport function toggleOnAttribute(el, attribute, value, force) {\n const oldValue = el.getAttribute(attribute);\n if ((force === undefined || force === true) && (!oldValue || !oldValue.includes(value))) {\n appendToAttribute(el, attribute, value);\n }\n else if (!force) {\n removeFromAttribute(el, attribute, value);\n }\n}\n/** Appends a value to an attribute on an element, first setting it if it doesn't exist. */\nexport function appendToAttribute(el, attribute, value) {\n const oldValue = el.getAttribute(attribute);\n if (!oldValue || !oldValue.length) {\n el.setAttribute(attribute, value);\n }\n else {\n el.setAttribute(attribute, `${oldValue} ${value}`);\n }\n}\n/** Removes a value from an attribute on an element, removing the attribute if empty. */\nexport function removeFromAttribute(el, attribute, value) {\n if (!el.hasAttribute(attribute)) {\n return;\n }\n const oldValue = el.getAttribute(attribute);\n if (oldValue) {\n let newValue = oldValue === null || oldValue === void 0 ? void 0 : oldValue.replace(value, '');\n newValue = newValue.replace(/\\s+/g, ' ').trim();\n if (newValue.length) {\n el.setAttribute(attribute, newValue);\n }\n else {\n el.removeAttribute(attribute);\n }\n }\n}\n/**\n * Attempts to scroll a target element into view within a scrollable parent element, unless already visible within the container.\n * @param scrollElement The scrollable parent element.\n * @param targetElement The element to scroll into view.\n * @param behavior The scroll behavior. Defaults to 'auto'.\n * @param block The block position to anchor the target element to within the scroll element.\n */\nexport function tryScrollIntoView(scrollElement, targetElement, behavior = 'auto', block = 'nearest') {\n if (!scrollElement) {\n return;\n }\n const canScroll = scrollElement.scrollHeight > scrollElement.clientHeight || scrollElement.scrollWidth > scrollElement.clientWidth;\n if (canScroll) {\n const offsetRect = offset(targetElement, scrollElement);\n const isClippedTop = offsetRect.top <= targetElement.clientHeight;\n const isClippedBottom = offsetRect.bottom <= targetElement.clientHeight;\n if (isClippedTop || isClippedBottom) {\n const top = calcBlockScroll(block, isClippedTop, targetElement.offsetTop, targetElement.clientHeight, scrollElement.offsetTop, scrollElement.offsetHeight);\n scrollElement.scrollTo({ top, behavior });\n return;\n }\n const isClippedLeft = offsetRect.left <= targetElement.clientWidth;\n const isClippedRight = offsetRect.right <= targetElement.clientWidth;\n if (isClippedLeft || isClippedRight) {\n const left = calcBlockScroll(block, isClippedLeft, targetElement.offsetLeft, targetElement.clientWidth, scrollElement.offsetLeft, scrollElement.offsetWidth);\n scrollElement.scrollTo({ left, behavior });\n }\n }\n}\n/** Calculates the block anchor position for a target element within a scrollable parent element. */\nexport function calcBlockScroll(block, isClippedStart, targetOffset, targetSize, scrollOffset, scrollSize) {\n if (block === 'nearest') {\n if (isClippedStart) {\n return (targetOffset - scrollOffset) - targetSize;\n }\n return (targetOffset - scrollSize) + targetSize * 2;\n }\n return targetOffset - scrollOffset - scrollSize / 2 + targetSize / 2;\n}\n/**\n * Creates an element from an HTML string.\n */\nexport function elementFromHTML(html) {\n const template = document.createElement('template');\n html = html.trim();\n template.innerHTML = html;\n return template.content.firstElementChild;\n}\n/**\n * Observes changes to the provided attributes on a target element and executes a provided callback when changed.\n * @param element The element to observe.\n * @param listener The callback to execute when an attribute changes on the element.\n * @param attributeFilter The attributes to observe.\n * @returns A `MutationObserver` instasnce.\n */\nexport function createElementAttributeObserver(element, listener, attributeFilter) {\n const observer = new MutationObserver(mutations => {\n for (const mutation of mutations) {\n if (mutation.attributeName) {\n listener(mutation.attributeName, element.getAttribute(mutation.attributeName));\n }\n }\n });\n observer.observe(element, { attributes: true, attributeFilter });\n return observer;\n}\n"],
|
|
5
|
+
"mappings": "wCAwBA,SAASA,EAAeC,EAAS,CAC7B,OAAOA,EAAQ,eAAiB,QACpC,CAoBO,SAASC,EAAUC,EAAS,CAC/B,OAAOA,GAAWA,EAAQ,WAAa,CAC3C,CAyCO,SAASC,EAAeC,EAASC,EAAc,CAClD,GAAI,CAACC,EAAUF,CAAO,EAClB,MAAM,IAAI,MAAM,qDAAqD,EAEzE,IAAMG,EAAiB,CAAC,EACxB,KAAOH,EAAQ,gBACXG,EAAe,KAAKH,EAAQ,aAAa,EACrC,EAAAA,EAAQ,gBAAkBC,GAAgBD,EAAQ,gBAAkBI,EAAeJ,CAAO,EAAE,QAI5FA,EAAQ,eAAiBA,EAAQ,cAAc,YAAcA,EAAQ,cAAc,WAAW,WAAa,GAC3GA,EAAUA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AAUH,EAAc,aAC3D,GAAIK,GAAgBC,EAAiB,CACjC,IAAMC,EAAMC,EAAgBN,EAAOG,EAAcL,EAAc,UAAWA,EAAc,aAAcD,EAAc,UAAWA,EAAc,YAAY,EACzJA,EAAc,SAAS,CAAE,IAAAQ,EAAK,SAAAN,CAAS,CAAC,EACxC,OAEJ,IAAMQ,EAAgBN,EAAW,MAAQH,EAAc,YACjDU,EAAiBP,EAAW,OAASH,EAAc,YACzD,GAAIS,GAAiBC,EAAgB,CACjC,IAAMC,EAAOH,EAAgBN,EAAOO,EAAeT,EAAc,WAAYA,EAAc,YAAaD,EAAc,WAAYA,EAAc,WAAW,EAC3JA,EAAc,SAAS,CAAE,KAAAY,EAAM,SAAAV,CAAS,CAAC,GAGrD,CAEO,SAASO,EAAgBN,EAAOU,EAAgBC,EAAcC,EAAYC,EAAcC,EAAY,CACvG,OAAId,IAAU,UACNU,EACQC,EAAeE,EAAgBD,EAEnCD,EAAeG,EAAcF,EAAa,EAE/CD,EAAeE,EAAeC,EAAa,EAAIF,EAAa,CACvE,CAIO,SAASG,EAAgBC,EAAM,CAClC,IAAMC,EAAW,SAAS,cAAc,UAAU,EAClD,OAAAD,EAAOA,EAAK,KAAK,EACjBC,EAAS,UAAYD,EACdC,EAAS,QAAQ,iBAC5B,CAQO,SAASC,EAA+BtC,EAASuC,EAAUC,EAAiB,CAC/E,IAAMC,EAAW,IAAI,iBAAiBC,GAAa,CAC/C,QAAWC,KAAYD,EACfC,EAAS,eACTJ,EAASI,EAAS,cAAe3C,EAAQ,aAAa2C,EAAS,aAAa,CAAC,CAGzF,CAAC,EACD,OAAAF,EAAS,QAAQzC,EAAS,CAAE,WAAY,GAAM,gBAAAwC,CAAgB,CAAC,EACxDC,CACX",
|
|
6
|
+
"names": ["_ownerDocument", "element", "isElement", "element", "elementParents", "element", "untilElement", "isElement", "parentElements", "_ownerDocument", "offset", "element", "parentElement", "isElement", "elemBCR", "win", "_ownerDocument", "docElem", "offsetValues", "parentBCR", "notChildEventListener", "element", "callback", "delay", "evtHandler", "event", "handle", "activeElement", "_ownerDocument", "docElem", "removeAllChildren", "node", "replaceElement", "newChild", "oldChild", "addClass", "name", "isArray", "n", "removeClass", "getAnimationEvent", "el", "animations", "t", "playKeyframeAnimation", "className", "remove", "resolve", "animationEvent", "animationCompletedListener", "removeElement", "safeCssWidth", "width", "calcSizeUnattached", "container", "size", "ensureChildren", "observer", "changes", "ensureChild", "selector", "initialElements", "deepQuerySelectorAll", "prev", "curr", "foundElements", "walkUpUntil", "node", "matcher", "parent", "calculateFontWidth", "value", "info", "ctx", "fontSize", "fontFamily", "generateTextShadow", "iterations", "color", "shadows", "i", "matchesSelectors", "el", "selectors", "matchesFn", "selector", "deepQuerySelectorAll", "rootElement", "checkRootElement", "nodes", "slottedNode", "getActiveElement", "doc", "activeElement", "getActiveShadowElement", "element", "toggleClass", "hasClass", "className", "addClass", "removeClass", "toggleAttribute", "hasAttribute", "name", "toggleOnAttribute", "attribute", "force", "oldValue", "appendToAttribute", "removeFromAttribute", "newValue", "tryScrollIntoView", "scrollElement", "targetElement", "behavior", "block", "offsetRect", "offset", "isClippedTop", "isClippedBottom", "top", "calcBlockScroll", "isClippedLeft", "isClippedRight", "left", "isClippedStart", "targetOffset", "targetSize", "scrollOffset", "scrollSize", "elementFromHTML", "html", "template", "createElementAttributeObserver", "listener", "attributeFilter", "observer", "mutations", "mutation"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2023 Tyler Technologies, Inc.
|
|
4
|
+
* License: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import{d as at}from"./chunk.YWNCJ7XP.js";import{a as rt}from"./chunk.LIKJD4SK.js";import{h as st}from"./chunk.QCRRHGBA.js";import{c as et}from"./chunk.F4VXEE76.js";import{e as tt}from"./chunk.HHCO64F3.js";import{e as it}from"./chunk.7CGKFRBK.js";import{a as f,b as nt}from"./chunk.OWCYRSI3.js";import{a as F}from"./chunk.MGLWXAZO.js";import{a as C,b as ot}from"./chunk.MXEKIEJA.js";import{j as K}from"./chunk.FYWPZFLJ.js";import{a as Q,d as Z,l as E}from"./chunk.PH3HUFJJ.js";import{g as J}from"./chunk.XIQFHO5R.js";import{j as b,k as X,n as G,o as q,p as Y,q as j}from"./chunk.DMCBAYQX.js";import{a as $}from"./chunk.KVCDAZ6B.js";import{a as u}from"./chunk.NVUMRW44.js";import{a as W}from"./chunk.BKL2BAYW.js";import{a as R,b as z}from"./chunk.DXN7ZOH3.js";import{a as N,e as H,f as V,h as U,k as B}from"./chunk.MVTBJPO2.js";import{m as A,s as P,u as x}from"./chunk.K7FPXAFS.js";import{a as D,k as m,l as y,o as L}from"./chunk.J2M2MXP2.js";import{a as w,d as p}from"./chunk.M3QDAYD2.js";var h=`${z}time-picker`,lt={TOGGLE:"forge-time-picker-toggle",VALUE:"value",OPEN:"open",ALLOW_SECONDS:"allow-seconds",MASKED:"masked",SHOW_MASK_FORMAT:"show-mask-format",USE_24_HOUR_TIME:"use-24-hour-time",ALLOW_INVALID_TIME:"allow-invalid-time",MIN:"min",MAX:"max",START_TIME:"start-time",STEP:"step",ALLOW_INPUT:"allow-input",SHOW_NOW:"show-now",SHOW_HOUR_OPTIONS:"show-hour-options",DISABLED:"disabled",POPUP_CLASSES:"popup-classes",ALLOW_DROPDOWN:"allow-dropdown"},ft={INPUT:"input, input[forge-time-picker-input]",TOGGLE:`[${lt.TOGGLE}]`},gt={OPEN:`${h}-open`,CLOSE:`${h}-close`,INPUT:`${h}-input`,CHANGE:`${h}-change`},vt={DEFAULT_MINUTE_STEP:60,MAX_DAY_MILLIS:864e5,MAX_DAY_MINUTES:1440},s={elementName:h,attributes:lt,selectors:ft,events:gt,numbers:vt};var g=class extends W{constructor(e){super(e)}initialize(){this._inputElement=this._component.querySelector(s.selectors.INPUT)}initializeMask(e){this.destroyMask(),this._inputMask=new J(this._inputElement,e)}destroy(){this._targetElement=void 0,this._toggleElement=void 0,this._inputElement=void 0}destroyMask(){var e;(e=this._inputMask)==null||e.destroy(),this._inputMask=void 0}initializeAccessibility(e){this._inputElement.setAttribute("autocomplete","off"),this._inputElement.setAttribute("autocorrect","off"),this._inputElement.setAttribute("autocapitalize","off"),this._inputElement.setAttribute("spellcheck","false"),this._inputElement.setAttribute("role","combobox"),this._inputElement.setAttribute("aria-live","assertive"),this._inputElement.setAttribute("aria-atomic","true"),this._inputElement.setAttribute("aria-haspopup","true"),this._inputElement.setAttribute("aria-expanded","false")}addInputListener(e,i,n){this._inputElement.addEventListener(e,i,{capture:n})}removeInputListener(e,i,n){this._inputElement&&this._inputElement.removeEventListener(e,i,{capture:n})}addToggleListener(e,i){this._toggleElement&&this._toggleElement.addEventListener(e,i)}removeToggleListener(e,i){this._toggleElement&&this._toggleElement.removeEventListener(e,i)}hasInputElement(){return!!this._inputElement}tryCreateToggle(){let e=this._component.querySelector(f.elementName),i=this._component.querySelector(s.selectors.TOGGLE);if(e){let n=e.querySelector(`${C.elementName}[slot=trailing]`);if(n||i){this._toggleElement=n||i;return}let a=document.createElement(C.elementName);a.slot="trailing",a.dense=!0,a.densityLevel=3,a.style.marginRight="4px";let r=document.createElement("button");r.type="button",r.tabIndex=-1,r.setAttribute("aria-label","Toggle time dropdown");let d=document.createElement(Q.elementName);d.name="clock_outline",r.appendChild(d),a.appendChild(r),e.appendChild(a),this._toggleElement=a}else i&&(this._toggleElement=i)}tryFocusInput(){this._inputElement.select()}tryBlurInput(){this._inputElement.blur()}selectInputText(){this._inputElement.select()}isInputDisabled(){return this._inputElement.disabled}isInputFocused(){return P(this._component.ownerDocument)===this._inputElement}setInputValue(e,i){this._inputElement.value!==e&&(this._inputElement.value=e,this._inputMask&&this._inputMask.update(),i&&(this._emitInputEvent("change"),this._emitInputEvent("input")))}getInputValue(){return this._inputMask?this._inputMask.maskedValue:this._inputElement.value}setDisabled(e){this._inputElement.disabled=e,this._inputElement.setAttribute("aria-disabled",e.toString()),this.setToggleDisabled(e)}attachDropdown(e){this._listDropdown=new st(this._inputElement,e),this._listDropdown.open(),this._inputElement.setAttribute("aria-controls",`list-dropdown-popup-${e.id}`)}detachDropdown(){this._listDropdown&&(this._listDropdown.close(),this._listDropdown.destroy(),this._listDropdown=void 0),this._inputElement.removeAttribute("aria-controls")}propagateKey(e){var i;(i=this._listDropdown)==null||i.handleKey(e)}setActiveDescendant(e){x(this._inputElement,!!e,"aria-activedescendant",e)}getTargetElementWidth(e){return this._getTargetElement(e).getBoundingClientRect().width}_emitInputEvent(e){this._inputElement.dispatchEvent(new Event(e))}emitInputEvent(e,i){U(this._inputElement,e,i)}setInputReadonly(e){this._inputElement.readOnly=e}setToggleDisabled(e){if(this._toggleElement)if(this._toggleElement.setAttribute("aria-disabled",e.toString()),"disabled"in this._toggleElement)this._toggleElement.disabled=e;else{let i=this._toggleElement.querySelector("button");i&&(i.disabled=e)}}hasActiveOption(){var e,i;return((i=(e=this._listDropdown)==null?void 0:e.getActiveOptionIndex())!=null?i:-1)>=0}activateOptionByIndex(e){var i;(i=this._listDropdown)==null||i.activateOption(e)}activateFirstOption(){var e;(e=this._listDropdown)==null||e.activateFirstOption()}getActiveOption(){var e;return(e=this._listDropdown)==null?void 0:e.getActiveOption()}_getTargetElement(e){return this._targetElement?this._targetElement:(this._targetElement=e?this._component.querySelector(e)||this._getDefaultTargetElement():this._getDefaultTargetElement(),this._targetElement)}_getDefaultTargetElement(){let e=this._component.querySelector(f.elementName);if(e&&e.shadowRoot){let i=V(e,f.selectors.ROOT);if(i)return i}return this._component}};function v(o,t,e){if(!o||/^\s*$/.test(o))return null;let i=0,n=0,a=0;if(b.test(o)){let r=G(o);i=+r.hours||0,n=+r.minutes||0,a=+r.seconds||0}else if(X.test(o)){let r=q(o);i=+r.hours||0,n=+r.minutes||0,a=+r.seconds||0,i===12&&r.meridiem==="AM"&&(i=0),i<12&&r.meridiem==="PM"&&(i+=12)}else return null;return dt(i)+T(n)+(e?O(a):0)}function c(o,t,e){if(typeof o!="number"||o<0)return null;let i=Math.min(pt(o),23),n=Math.min(ut(o),59),r=o/(1e3*60)<720?"AM":"PM";t||(i=i<=12?i:i-12,i===0&&(i=12));let d=`${String(i).padStart(2,"0")}:${String(n).padStart(2,"0")}`;if(e){let _=Math.min(M(o),59);d+=`:${String(_).padStart(2,"0")}`}return t||(d+=` ${r}`),d}function pt(o){return Math.abs(Math.floor(o/(1e3*60*60)))}function ut(o){return Math.abs(Math.floor(I(o)%60))}function I(o){return o/(1e3*60)}function M(o){return Math.abs(Math.floor(It(o)%60))}function It(o){return o/1e3}function dt(o){return o*60*60*1e3}function T(o){return o*60*1e3}function O(o){return o*1e3}function ct(o){return o-O(M(o))}function S(o){let t=new Date,e=t.getHours(),i=t.getMinutes();return dt(e)+T(i)+(o?O(t.getSeconds()):0)}function Rt(o,t,e=!1){o||(o=new Date);let i=v(t,!0,e);if(!i)return o.setHours(0,0,0),o;let n=pt(i),a=828e5;n>a?n=a:n<0&&(n=0);let r=ut(i),d=e?M(i):0;return o.setHours(n,r,d),o}var k=class{constructor(t){this._adapter=t;this._value=null;this._masked=!0;this._use24HourTime=!1;this._showMaskFormat=!1;this._min=null;this._max=null;this._restrictedTimes=[];this._startTime=null;this._step=s.numbers.DEFAULT_MINUTE_STEP;this._allowInput=!0;this._open=!1;this._allowSeconds=!1;this._allowInvalidTime=!1;this._showNow=!1;this._showHourOptions=!0;this._customOptions=[];this._disabled=!1;this._popupClasses=[];this._allowDropdown=!0;this._isInitialized=!1;this._identifier=D(),this._inputListener=e=>this._onInput(e),this._inputKeydownListener=e=>this._onInputKeydown(e),this._toggleMousedownListener=e=>this._onToggleMousedown(e),this._inputFocusListener=e=>this._onInputFocus(e),this._inputBlurListener=e=>this._onInputBlur(e),this._inputMousedownListener=e=>this._onInputMousedown(e)}initialize(){if(this._adapter.initialize(),!this._adapter.hasInputElement())throw new Error("Unable to locate <input> element to attach to.");if(this._adapter.initializeAccessibility(this._identifier),!this._value){let t=this._adapter.getInputValue();this._setValue(this._convertTimeStringToMillis(t,this._use24HourTime,this._allowSeconds))}this._adapter.addInputListener("focus",this._inputFocusListener),this._adapter.addInputListener("blur",this._inputBlurListener),this._adapter.addInputListener("keydown",this._inputKeydownListener,!0),this._formatInputValue(!1),typeof this._value=="number"&&this._applyValue(this._value,!1),this._applyAllowInput(),this._applyAllowDropdown(),this._applyDisabled(),this._applyMask(),this._isInitialized=!0}disconnect(){this._isInitialized=!1,this._adapter.removeInputListener("input",this._inputListener),this._adapter.removeInputListener("focus",this._inputFocusListener),this._adapter.removeInputListener("blur",this._inputBlurListener),this._adapter.removeToggleListener("mousedown",this._toggleMousedownListener),this._adapter.removeInputListener("keydown",this._inputKeydownListener,!0),this._masked&&this._adapter.destroyMask(),this._closeDropdown(),this._adapter.destroy()}_onInput(t){this._handleInput(this._adapter.getInputValue())}_onInputKeydown(t){var e,i;if(t.shiftKey)switch(t.code){case"Backspace":case"Delete":t.preventDefault(),this._trySetValue(null)&&this._formatInputValue();return}switch(t.code){case"Tab":this._open&&this._selectActiveOption();break;case"Esc":case"Escape":this._open&&(t.preventDefault(),t.stopPropagation(),this._closeDropdown(!0));break;case"Down":case"ArrowDown":this._allowDropdown&&(t.preventDefault(),this._open?this._adapter.hasActiveOption()?this._adapter.propagateKey(t.code):this._trySetActiveOption():(this._openDropdown(),typeof((e=this._dropdownConfig)==null?void 0:e.visibleStartIndex)=="number"&&this._dropdownConfig.visibleStartIndex>=0?this._adapter.activateOptionByIndex((i=this._dropdownConfig)==null?void 0:i.visibleStartIndex):this._adapter.activateFirstOption()));break;case"ArrowUp":this._allowDropdown&&(t.preventDefault(),this._open&&(this._adapter.hasActiveOption()?this._adapter.propagateKey(t.code):this._trySetActiveOption()));break;case"Enter":case"NumpadEnter":case"Home":case"End":this._open&&((t.code==="Enter"||t.code==="NumpadEnter")&&t.stopPropagation(),t.preventDefault(),this._adapter.propagateKey(t.code));break;case"KeyN":t.preventDefault();let n=S(this._allowSeconds);if(this._value!==n){let a=c(n,!0,this._allowSeconds);this._emitChangeEvent(a)&&(this._applyValue(n),this._selectInputText())}break}}_trySetActiveOption(){var t,e;!this._adapter.hasActiveOption()&&typeof((t=this._dropdownConfig)==null?void 0:t.visibleStartIndex)=="number"&&this._dropdownConfig.visibleStartIndex>=0&&this._adapter.activateOptionByIndex((e=this._dropdownConfig)==null?void 0:e.visibleStartIndex)}_selectActiveOption(){let t=this._adapter.getActiveOption();t&&this._onSelect(t.value)}_onToggleMousedown(t){this._disabled||!this.allowDropdown||(t.stopPropagation(),!this._adapter.isInputDisabled()&&(t.preventDefault(),this._open?this._closeDropdown(!0):(F.isMobile?this._adapter.tryBlurInput():this._adapter.tryFocusInput(),this._openDropdown())))}_onInputFocus(t){this._allowInput&&this._adapter.selectInputText(),this.masked&&this._showMaskFormat&&this._applyMask()}_onInputBlur(t){this.masked&&this._showMaskFormat&&this._applyMask(),this._formatInputValue(),this._open&&!this._adapter.isInputFocused()&&this._closeDropdown(!0)}_onInputMousedown(t){!this._allowInput&&!this._open&&(this._openDropdown(),this._adapter.tryFocusInput(),window.requestAnimationFrame(()=>this._adapter.selectInputText()))}_applyDisabled(){this._adapter.setDisabled(this._disabled)}_applyMask(){if(this._masked&&this._allowInput){this._adapter.destroyMask();let t={showMaskFormat:this._showMaskFormat&&this._adapter.isInputFocused(),use24HourTime:this._use24HourTime,showSeconds:this._allowSeconds,prepareCallback:this._prepareMaskCallback,onChange:L(e=>this._handleInput(e),0,!0)};this._adapter.initializeMask(t)}else this._adapter.destroyMask(),this._formatInputValue()}_applyAllowInput(){this._adapter.setInputReadonly(!this._allowInput),this._allowInput?(this._adapter.removeInputListener("mousedown",this._inputMousedownListener),this._masked||this._adapter.addInputListener("input",this._inputListener)):(this._adapter.addInputListener("mousedown",this._inputMousedownListener),this._adapter.removeInputListener("input",this._inputListener))}_applyAllowDropdown(){this._adapter.setToggleDisabled(!this._allowDropdown),this._allowDropdown?(this._adapter.removeToggleListener("mousedown",this._toggleMousedownListener),this._adapter.tryCreateToggle(),this._adapter.addToggleListener("mousedown",this._toggleMousedownListener)):this._open&&this._closeDropdown(!0)}_applyAllowSeconds(){let t=this._value;if(this._allowSeconds){if(this._isInitialized&&t!==this._value){let e=c(this._value,!0,!0);this._emitChangeEvent(e)}}else{if(typeof this._value!="number")return;if(this._setValue(ct(this._value)),this._isInitialized&&t!==this._value){let e=c(this._value,!0,!1);this._emitChangeEvent(e)}}}_handleInput(t){let e=t;if(!this._allowInput)return;this._open&&this._closeDropdown(!0),t=j(t,this._use24HourTime,this._allowSeconds),typeof this._coercionCallback=="function"&&(t=this._coercionCallback.call(null,e,t,this._allowSeconds)),this._isValidTimeFormat(t)||(t="");let i;!this._masked&&typeof this._parseCallback=="function"?i=this._parseCallback.call(null,t):i=this._convertTimeStringToMillis(t,this._use24HourTime,this._allowSeconds),i=this._validateMillis(i),this._trySetValue(i)}_emitChangeEvent(t,e=!1){return this._adapter.emitHostEvent(s.events.CHANGE,t,!0,!e)}_trySetValue(t){if(t===this._value)return!1;let e=c(t,!0,this._allowSeconds);return this._adapter.emitInputEvent(s.events.INPUT,e),this._value!==t&&this._emitChangeEvent(e)?(this._setValue(t),!0):!1}_setValue(t){this._value=this._normalizeTimeValue(t)}_validateMillis(t){if(typeof t=="number"){let e=typeof this._min=="number"&&t<this._min,i=typeof this._max=="number"&&t>this._max;(e||i)&&(t=null)}return typeof t=="number"&&this._restrictedTimes.length&&this._restrictedTimes.includes(t)&&(t=null),t}_isValidTimeFormat(t){return!this._masked&&typeof this._validationCallback=="function"?this._validationCallback.call(this,t):Y(t)}_isValidInputValue(t){return b.test(t)}_onSelect(t){if(this._closeDropdown(!0),!t.isCustom&&t.metadata==="now"&&(t.time=S(this._allowSeconds)),t.isCustom)if(typeof t.customCallback=="function"){let n=t.customCallback.call(null,t.metadata);if(typeof n!="number")throw new Error("Custom options must provide a time of day value in milliseconds.");t.time=n}else throw new Error("You must implement a `toMilliseconds` callback that returns the time value to use for this custom option.");if(this._value===t.time)return;let e=c(t.time,!0,this._allowSeconds);this._emitChangeEvent(e)&&(this._applyValue(t.time),this._selectInputText())}_selectInputText(){window.requestAnimationFrame(()=>{window.requestAnimationFrame(()=>{this._adapter.isInputFocused()&&this._adapter.selectInputText()})})}_applyValue(t,e=!0){this._setValue(t);let i=this._formatValue(this._value);this._adapter.getInputValue()!==i&&this._adapter.setInputValue(i,e)}_normalizeTimeValue(t){return t==null?null:t<0?0:t>s.numbers.MAX_DAY_MILLIS?s.numbers.MAX_DAY_MILLIS:t}_openDropdown(){let t=this._generateTimeOptions();if(!this.allowDropdown||!t.length)return;this._formatInputValue(),this._open=!0,this._adapter.setHostAttribute(s.attributes.OPEN);let e=t.filter(a=>!a.divider&&!a.disabled),i=[],n=0;if(t.length)if(this._value!=null){let a=this._findClosestOptionIndex(this._value,e);a>=0&&(e[a].value.time===this._value?i=[e[a].value]:n=a)}else if(typeof this._startTime=="number"){let a=this._findClosestOptionIndex(this._startTime,e);a>=0&&a<e.length&&(n=a)}else this._startTime==null&&(n=this._getOptionIndexClosestCurrent(e));this._dropdownConfig={id:`forge-time-picker-${this._identifier}`,selectedValues:i,syncWidth:!0,visibleStartIndex:n,popupClasses:this._popupClasses,popupStatic:!0,type:"standard",options:t,selectCallback:a=>this._onSelect(a),closeCallback:()=>this._closeDropdown(!0),activeChangeCallback:a=>this._adapter.setActiveDescendant(a),targetWidthCallback:()=>this._adapter.getTargetElementWidth(this._popupTarget)},this._adapter.attachDropdown(this._dropdownConfig),this._adapter.emitHostEvent(s.events.OPEN,void 0,!1)}_closeDropdown(t=!1){this._open=!1,this._dropdownConfig=void 0,this._adapter.removeHostAttribute(s.attributes.OPEN),this._adapter.detachDropdown(),t&&this._adapter.emitHostEvent(s.events.CLOSE,!0,!1)}_getOptionIndexClosestCurrent(t){let e=new Date,i=`${String(e.getHours()).padStart(2,"0")}:${String(e.getMinutes()).padStart(2,"0")}`,n=v(i,!0,!1);return this._findClosestOptionIndex(n,t)}_findClosestOptionIndex(t,e){let i=e.reduce((n,a)=>Math.abs((a.value.time||0)-t)<Math.abs((n.value.time||0)-t)?a:n);return e.indexOf(i)}_formatInputValue(t=!0){let e=this._adapter.getInputValue();if(this._allowInvalidTime&&!this._masked&&e&&!this._value)return;let i=this._formatValue(this._value);e!==i&&(this._adapter.setInputValue(i,t),this._adapter.emitInputEvent(s.events.INPUT,i))}_generateTimeOptions(){let t=this._min!=null?Math.max(I(this._min),0):0,e=this._max!=null?Math.min(I(this._max),s.numbers.MAX_DAY_MINUTES):s.numbers.MAX_DAY_MINUTES,i=this._step,n=[],a=[];if(this._showHourOptions){for(let d=t;d<=e&&d!==s.numbers.MAX_DAY_MINUTES;d+=i){let _=T(d),_t=this._restrictedTimes.includes(_),ht=c(_,this._use24HourTime,!1)||"",bt={time:_};n.push({label:ht,value:bt,disabled:_t})}let r=n.findIndex(d=>d.value.time/1e3/60>=720);r>=0&&r<n.length-1&&n.splice(r,0,{label:"",value:null,divider:!0})}if(this._showNow){let r={time:null,metadata:"now"};a.push({label:"Now",value:r})}if(Array.isArray(this._customOptions)&&this._customOptions.length){let r=this._customOptions.map(d=>{let _={time:null,metadata:d.value,isCustom:!0,customCallback:d.toMilliseconds};return{label:d.label,value:_}});a=[...a,...r]}return a.length&&(n.length&&n.splice(0,0,{label:"",value:null,divider:!0}),a.forEach((r,d)=>n.splice(d,0,r))),n}_convertTimeStringToMillis(t,e,i){return(!t||!this._isValidTimeFormat(t))&&(t=""),v(t,e,i)}_formatValue(t){return!this._masked&&typeof this._formatCallback=="function"?this._formatCallback.call(null,t,this._use24HourTime,this._allowSeconds):c(this._value,this._use24HourTime,this._allowSeconds)||""}_warnInvalidFormat(t){console.warn(`The specified value "${t}" does not conform to the required format. The format is "HH:mm", "HH:mm:ss" where HH is 00-23, mm is 00-59, and ss is 00-59.`)}get open(){return this._open}set open(t){this._open!==t&&this._isInitialized&&(this._open=t,this._open?this._openDropdown():this._closeDropdown())}get masked(){return this._masked}set masked(t){this._masked!==t&&(this._masked=t,this._isInitialized&&(this._masked?(this._adapter.removeInputListener("input",this._inputListener),this._applyMask()):(this._adapter.destroyMask(),this._formatInputValue(),this._adapter.addInputListener("input",this._inputListener))))}get showMaskFormat(){return this._showMaskFormat}set showMaskFormat(t){this._showMaskFormat!==t&&(this._showMaskFormat=t)}get allowSeconds(){return this._allowSeconds}set allowSeconds(t){this._allowSeconds!==t&&(this._allowSeconds=!!t,this._applyAllowSeconds(),this._isInitialized&&(this._applyMask(),this._formatInputValue()),this._adapter.setHostAttribute(s.attributes.ALLOW_SECONDS,`${!!t}`))}get use24HourTime(){return this._use24HourTime}set use24HourTime(t){this._use24HourTime!==t&&(this._use24HourTime=!!t,this._isInitialized&&(this._applyMask(),this._formatInputValue()),this._adapter.setHostAttribute(s.attributes.USE_24_HOUR_TIME,`${!!t}`))}get allowInvalidTime(){return this._allowInvalidTime}set allowInvalidTime(t){this._allowInvalidTime!==t&&(this._allowInvalidTime=!!t,this._adapter.setHostAttribute(s.attributes.ALLOW_INVALID_TIME,`${!!t}`))}get value(){return c(this._value,!0,this._allowSeconds)}set value(t){if(t&&!this._isValidInputValue(t)){this._warnInvalidFormat(t);return}let e=this._validateMillis(this._convertTimeStringToMillis(t,!0,!0));this._setValue(e),this._isInitialized&&this._applyValue(this._value)}get min(){return c(this._min,!0,this._allowSeconds)}set min(t){if(this._min!==t){if(t&&!this._isValidInputValue(t)){this._warnInvalidFormat(t);return}this._min=this._convertTimeStringToMillis(t,!0,this._allowSeconds);let e=this._validateMillis(this._value);this._setValue(e),this._isInitialized&&this._applyValue(e)}}get max(){return c(this._max,!0,this._allowSeconds)}set max(t){if(this._max!==t){if(t&&!this._isValidInputValue(t)){this._warnInvalidFormat(t);return}this._max=this._convertTimeStringToMillis(t,!0,this._allowSeconds);let e=this._validateMillis(this._value);this._setValue(e),this._isInitialized&&this._applyValue(e)}}get restrictedTimes(){return this._restrictedTimes.map(t=>c(t,!0,this._allowSeconds)).filter(t=>typeof t=="string")}set restrictedTimes(t){Array.isArray(t)||(t=[]),this._restrictedTimes=t.filter(e=>typeof e=="string").map(e=>this._convertTimeStringToMillis(e,!0,!0)).filter(e=>typeof e=="number")}get startTime(){return c(this._startTime,!0,this._allowSeconds)}set startTime(t){if(this._startTime!==t){if(t&&!this._isValidInputValue(t)){this._warnInvalidFormat(t);return}this._startTime=this._convertTimeStringToMillis(t,!0,this._allowSeconds)}}get step(){return this._step}set step(t){this._step=t}get allowInput(){return this._allowInput}set allowInput(t){this._allowInput!==t&&(this._allowInput=t,this._isInitialized&&(this._applyAllowInput(),this._applyMask()))}get popupTarget(){return this._popupTarget}set popupTarget(t){this._popupTarget!==t&&(this._popupTarget=t)}get showNow(){return this._showNow}set showNow(t){this._showNow!==t&&(this._showNow=t)}get showHourOptions(){return this._showHourOptions}set showHourOptions(t){this._showHourOptions!==t&&(this._showHourOptions=t)}get customOptions(){return this._customOptions}set customOptions(t){this._customOptions=Array.isArray(t)?t:[]}set validationCallback(t){this._validationCallback=t,this._isInitialized&&this._applyMask()}set parseCallback(t){this._parseCallback=t}set formatCallback(t){this._formatCallback=t}set coercionCallback(t){this._coercionCallback=t}set prepareMaskCallback(t){this._prepareMaskCallback=t,this._isInitialized&&this._applyMask()}get disabled(){return this._disabled}set disabled(t){this._disabled!==t&&(this._disabled=!!t,this._isInitialized&&this._applyDisabled(),this._adapter.toggleHostAttribute(s.attributes.DISABLED,this._disabled))}get popupClasses(){return Array.isArray(this._popupClasses)?[...this._popupClasses]:this._popupClasses}set popupClasses(t){Array.isArray(t)?this._popupClasses=[...t]:this._popupClasses=[t]}get allowDropdown(){return this._allowDropdown}set allowDropdown(t){this._allowDropdown!==t&&(this._allowDropdown=t,this._isInitialized&&this._applyAllowDropdown())}};var Tt="<template><slot></slot></template>",kt=":host{display:block}:host([hidden]){display:none}",l=class extends B{constructor(){super();Z.define([rt,K]),H(this,Tt,kt),this._foundation=new k(new g(this))}static get observedAttributes(){return[s.attributes.VALUE,s.attributes.OPEN,s.attributes.ALLOW_SECONDS,s.attributes.MASKED,s.attributes.SHOW_MASK_FORMAT,s.attributes.USE_24_HOUR_TIME,s.attributes.ALLOW_INVALID_TIME,s.attributes.MIN,s.attributes.MAX,s.attributes.START_TIME,s.attributes.STEP,s.attributes.ALLOW_INPUT,s.attributes.SHOW_NOW,s.attributes.SHOW_HOUR_OPTIONS,s.attributes.DISABLED,s.attributes.POPUP_CLASSES,s.attributes.ALLOW_DROPDOWN]}connectedCallback(){this.querySelector(s.selectors.INPUT)?this._foundation.initialize():A(this,s.selectors.INPUT).then(()=>this._foundation.initialize())}disconnectedCallback(){this._foundation.disconnect()}attributeChangedCallback(e,i,n){switch(e){case s.attributes.VALUE:this.value=n;break;case s.attributes.OPEN:this.open=m(n);break;case s.attributes.ALLOW_SECONDS:this.allowSeconds=m(n);break;case s.attributes.MASKED:this.masked=m(n);break;case s.attributes.SHOW_MASK_FORMAT:this.showMaskFormat=m(n);break;case s.attributes.USE_24_HOUR_TIME:this.use24HourTime=m(n);break;case s.attributes.ALLOW_INVALID_TIME:this.allowInvalidTime=m(n);break;case s.attributes.SHOW_NOW:this.showNow=m(n);break;case s.attributes.SHOW_HOUR_OPTIONS:this.showHourOptions=m(n);break;case s.attributes.MIN:this.min=n;break;case s.attributes.MAX:this.max=n;break;case s.attributes.START_TIME:this.startTime=n;break;case s.attributes.STEP:this.step=y(n);break;case s.attributes.ALLOW_INPUT:this.allowInput=m(n);break;case s.attributes.DISABLED:this.disabled=m(n);break;case s.attributes.POPUP_CLASSES:this.popupClasses=n;break;case s.attributes.ALLOW_DROPDOWN:this.allowDropdown=m(n);break}}};p([u()],l.prototype,"value",2),p([u()],l.prototype,"open",2),p([u()],l.prototype,"allowSeconds",2),p([u()],l.prototype,"masked",2),p([u()],l.prototype,"showMaskFormat",2),p([u()],l.prototype,"use24HourTime",2),p([u()],l.prototype,"allowInvalidTime",2),p([u()],l.prototype,"min",2),p([u()],l.prototype,"max",2),p([u()],l.prototype,"restrictedTimes",2),p([u()],l.prototype,"startTime",2),p([u()],l.prototype,"step",2),p([u()],l.prototype,"allowInput",2),p([u()],l.prototype,"showNow",2),p([u()],l.prototype,"showHourOptions",2),p([u()],l.prototype,"customOptions",2),p([u()],l.prototype,"validationCallback",2),p([u()],l.prototype,"parseCallback",2),p([u()],l.prototype,"formatCallback",2),p([u()],l.prototype,"coercionCallback",2),p([u()],l.prototype,"prepareMaskCallback",2),p([u()],l.prototype,"disabled",2),p([u()],l.prototype,"popupClasses",2),p([u()],l.prototype,"allowDropdown",2),p([u()],l.prototype,"popupTarget",2),l=p([R({name:s.elementName,dependencies:[et,tt,ot,E,it,E,at]})],l);var mt=class extends ${constructor(e){super(e)}_build(){let e=document.createElement(s.elementName);return this._attachTextField(e),e}get inputElement(){return this._textFieldDelegate.inputElement}get textFieldElement(){return this._textFieldDelegate.element}get value(){return this._element.value}set value(e){this._element.value=e}get disabled(){return this._element.disabled}set disabled(e){this._element.disabled=e}get invalid(){return this._textFieldDelegate.invalid||!1}set invalid(e){this._textFieldDelegate.invalid=e}onChange(e){this._element.addEventListener(s.events.CHANGE,i=>{var n;return e((n=i.detail)!=null?n:"")})}onInput(e){this._element.addEventListener(s.events.INPUT,i=>{var n;return e((n=i.detail)!=null?n:"")})}onFocus(e){this._textFieldDelegate.inputElement.addEventListener("focus",i=>e(i))}onBlur(e){this._textFieldDelegate.inputElement.addEventListener("blur",i=>e(i))}_attachTextField(e){var n,a,r,d;let i={props:w({},(a=(n=this._config.options)==null?void 0:n.textFieldDelegateConfig)==null?void 0:a.props),options:w({},(d=(r=this._config.options)==null?void 0:r.textFieldDelegateConfig)==null?void 0:d.options)};this._textFieldDelegate=new nt(i),e.appendChild(this._textFieldDelegate.element)}};function Ne(){N(l)}export{s as a,g as b,v as c,c as d,pt as e,ut as f,I as g,M as h,It as i,dt as j,T as k,O as l,ct as m,S as n,Rt as o,k as p,l as q,mt as r,Ne as s};
|
|
7
|
+
//# sourceMappingURL=chunk.KJP2VA6Q.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/time-picker/time-picker-constants.ts", "../../src/time-picker/time-picker-adapter.ts", "../../src/time-picker/time-picker-utils.ts", "../../src/time-picker/time-picker-foundation.ts", "../../src/time-picker/time-picker.ts", "../../src/time-picker/time-picker-component-delegate.ts", "../../src/time-picker/index.ts"],
|
|
4
|
+
"sourcesContent": ["import { COMPONENT_NAME_PREFIX } from '../constants';\nimport { IListDropdownOption } from '../list-dropdown/list-dropdown-constants';\nimport IMask, { Masked, InputMask } from 'imask';\n\nconst elementName: keyof HTMLElementTagNameMap = `${COMPONENT_NAME_PREFIX}time-picker`;\n\nconst attributes = {\n TOGGLE: 'forge-time-picker-toggle',\n VALUE: 'value',\n OPEN: 'open',\n ALLOW_SECONDS: 'allow-seconds',\n MASKED: 'masked',\n SHOW_MASK_FORMAT: 'show-mask-format',\n USE_24_HOUR_TIME: 'use-24-hour-time',\n ALLOW_INVALID_TIME: 'allow-invalid-time',\n MIN: 'min',\n MAX: 'max',\n START_TIME: 'start-time',\n STEP: 'step',\n ALLOW_INPUT: 'allow-input',\n SHOW_NOW: 'show-now',\n SHOW_HOUR_OPTIONS: 'show-hour-options',\n DISABLED: 'disabled',\n POPUP_CLASSES: 'popup-classes',\n ALLOW_DROPDOWN: 'allow-dropdown'\n};\n\nconst selectors = {\n INPUT: 'input, input[forge-time-picker-input]',\n TOGGLE: `[${attributes.TOGGLE}]`\n};\n\nconst events = {\n OPEN: `${elementName}-open`,\n CLOSE: `${elementName}-close`,\n INPUT: `${elementName}-input`,\n CHANGE: `${elementName}-change`\n};\n\nconst numbers = {\n DEFAULT_MINUTE_STEP: 60,\n MAX_DAY_MILLIS: 86400000,\n MAX_DAY_MINUTES: 1440\n};\n\nexport const TIME_PICKER_CONSTANTS = {\n elementName,\n attributes,\n selectors,\n events,\n numbers\n};\n\nexport type TimePickerValidationCallback = (time: string) => boolean;\nexport type TimePickerParseCallback = (time: string) => number | null;\nexport type TimePickerFormatCallback = (value: number | null) => string;\nexport type TimePickerCustomOptionCallback<T> = (value: T, use24HourTime: boolean, allowSeconds: boolean) => number;\nexport type TimePickerCoercionCallback = (rawValue: string, coercedValue: string, allowSeconds: boolean) => string;\nexport type TimePickerPrepareMaskCallback = (value: string, masked: Masked<string>, flags: IMask.AppendFlags, maskInstance: InputMask<IMask.AnyMaskedOptions>) => string;\n\nexport interface ITimePickerOption<T = any> extends IListDropdownOption<T> {\n toMilliseconds: TimePickerCustomOptionCallback<T>;\n}\nexport interface ITimePickerOptionValue {\n time: number | null;\n metadata?: any;\n isCustom?: boolean;\n customCallback?: TimePickerCustomOptionCallback<any>;\n}\n", "import { getShadowElement, emitEvent, getActiveElement, toggleAttribute } from '@tylertech/forge-core';\nimport { ITimePickerComponent } from './time-picker';\nimport { BaseAdapter } from '../core';\nimport { TIME_PICKER_CONSTANTS } from './time-picker-constants';\nimport { ITimeInputMaskOptions, TimeInputMask } from '../core/mask/time-input-mask';\nimport { TEXT_FIELD_CONSTANTS, ITextFieldComponent } from '../text-field';\nimport { ICON_BUTTON_CONSTANTS, IIconButtonComponent } from '../icon-button';\nimport { ICON_CONSTANTS, IIconComponent } from '../icon';\nimport { IListDropdownConfig, IListDropdownOption } from '../list-dropdown/list-dropdown-constants';\nimport { IListDropdown, ListDropdown } from '../list-dropdown';\n\nexport interface ITimePickerAdapter extends BaseAdapter<ITimePickerComponent> {\n initialize(): void;\n initializeMask(options: ITimeInputMaskOptions): void;\n destroy(): void;\n destroyMask(): void;\n initializeAccessibility(identifier: string): void;\n addInputListener(type: string, listener: (event: Event) => void, capture?: boolean): void;\n removeInputListener(type: string, listener: (event: Event) => void, capture?: boolean): void;\n addToggleListener(type: string, listener: (event: Event) => void): void;\n removeToggleListener(type: string, listener: (event: Event) => void): void;\n hasInputElement(): boolean;\n tryCreateToggle(): void;\n tryFocusInput(): void;\n tryBlurInput(): void;\n selectInputText(): void;\n getInputValue(): string;\n setInputValue(value: string, emitEvents: boolean): void;\n isInputDisabled(): boolean;\n isInputFocused(): boolean;\n setDisabled(isDisabled: boolean): void;\n attachDropdown(config: IListDropdownConfig): void;\n detachDropdown(): void;\n setActiveDescendant(id: string): void;\n propagateKey(key: string): void;\n getTargetElementWidth(selector: string): number;\n emitInputEvent(type: string, data?: any): void;\n setInputReadonly(value: boolean): void;\n setToggleDisabled(value: boolean): void;\n hasActiveOption(): boolean;\n activateOptionByIndex(index: number): void;\n activateFirstOption(): void;\n getActiveOption(): IListDropdownOption | undefined;\n}\n\nexport class TimePickerAdapter extends BaseAdapter<ITimePickerComponent> implements ITimePickerAdapter {\n private _inputElement: HTMLInputElement;\n private _toggleElement?: HTMLElement;\n private _inputMask?: TimeInputMask;\n private _listDropdown?: IListDropdown;\n private _targetElement?: HTMLElement;\n\n constructor(component: ITimePickerComponent) {\n super(component);\n }\n\n public initialize(): void {\n this._inputElement = this._component.querySelector(TIME_PICKER_CONSTANTS.selectors.INPUT) as HTMLInputElement;\n }\n\n public initializeMask(options: ITimeInputMaskOptions): void {\n this.destroyMask();\n this._inputMask = new TimeInputMask(this._inputElement, options);\n }\n\n public destroy(): void {\n this._targetElement = undefined;\n this._toggleElement = undefined as any;\n this._inputElement = undefined as any;\n }\n\n public destroyMask(): void {\n this._inputMask?.destroy();\n this._inputMask = undefined;\n }\n\n public initializeAccessibility(identifier: string): void {\n this._inputElement.setAttribute('autocomplete', 'off');\n this._inputElement.setAttribute('autocorrect', 'off');\n this._inputElement.setAttribute('autocapitalize', 'off');\n this._inputElement.setAttribute('spellcheck', 'false');\n this._inputElement.setAttribute('role', 'combobox');\n this._inputElement.setAttribute('aria-live', 'assertive');\n this._inputElement.setAttribute('aria-atomic', 'true');\n this._inputElement.setAttribute('aria-haspopup', 'true');\n this._inputElement.setAttribute('aria-expanded', 'false');\n }\n\n public addInputListener(type: string, listener: (event: Event) => void, capture?: boolean): void {\n this._inputElement.addEventListener(type, listener, { capture });\n }\n\n public removeInputListener(type: string, listener: (event: Event) => void, capture?: boolean): void {\n if (this._inputElement) {\n this._inputElement.removeEventListener(type, listener, { capture });\n }\n }\n\n public addToggleListener(type: string, listener: (event: Event) => void): void {\n if (this._toggleElement) {\n this._toggleElement.addEventListener(type, listener);\n }\n }\n\n public removeToggleListener(type: string, listener: (event: Event) => void): void {\n if (this._toggleElement) {\n this._toggleElement.removeEventListener(type, listener);\n }\n }\n\n public hasInputElement(): boolean {\n return !!this._inputElement;\n }\n\n public tryCreateToggle(): void {\n const textField = this._component.querySelector(TEXT_FIELD_CONSTANTS.elementName) as ITextFieldComponent;\n const toggleElement = this._component.querySelector(TIME_PICKER_CONSTANTS.selectors.TOGGLE);\n if (textField) {\n const existingIconButton = textField.querySelector(`${ICON_BUTTON_CONSTANTS.elementName}[slot=trailing]`);\n if (existingIconButton || toggleElement) {\n this._toggleElement = (existingIconButton || toggleElement) as IIconButtonComponent;\n return;\n }\n\n const iconButtonElement = document.createElement(ICON_BUTTON_CONSTANTS.elementName) as IIconButtonComponent;\n iconButtonElement.slot = 'trailing';\n iconButtonElement.dense = true;\n iconButtonElement.densityLevel = 3;\n iconButtonElement.style.marginRight = '4px'; // Override default trailing slot margin in text-field\n\n const buttonElement = document.createElement('button');\n buttonElement.type = 'button';\n buttonElement.tabIndex = -1;\n buttonElement.setAttribute('aria-label', 'Toggle time dropdown');\n\n const iconElement = document.createElement(ICON_CONSTANTS.elementName) as IIconComponent;\n iconElement.name = 'clock_outline';\n buttonElement.appendChild(iconElement);\n iconButtonElement.appendChild(buttonElement);\n\n textField.appendChild(iconButtonElement);\n this._toggleElement = iconButtonElement;\n } else if (toggleElement) {\n this._toggleElement = toggleElement as HTMLElement;\n }\n }\n\n public tryFocusInput(): void {\n this._inputElement.select();\n }\n\n public tryBlurInput(): void {\n this._inputElement.blur();\n }\n\n public selectInputText(): void {\n this._inputElement.select();\n }\n\n public isInputDisabled(): boolean {\n return this._inputElement.disabled;\n }\n\n public isInputFocused(): boolean {\n const activeElement = getActiveElement(this._component.ownerDocument);\n return activeElement === this._inputElement;\n }\n\n public setInputValue(value: string, emitEvents: boolean): void {\n if (this._inputElement.value === value) {\n return;\n }\n\n this._inputElement.value = value;\n\n if (this._inputMask) {\n this._inputMask.update();\n }\n\n if (emitEvents) {\n this._emitInputEvent('change');\n this._emitInputEvent('input');\n }\n }\n\n public getInputValue(): string {\n return this._inputMask ? this._inputMask.maskedValue : this._inputElement.value;\n }\n\n public setDisabled(isDisabled: boolean): void {\n this._inputElement.disabled = isDisabled;\n this._inputElement.setAttribute('aria-disabled', isDisabled.toString());\n this.setToggleDisabled(isDisabled);\n }\n\n public attachDropdown(config: IListDropdownConfig): void {\n this._listDropdown = new ListDropdown(this._inputElement, config);\n this._listDropdown.open();\n this._inputElement.setAttribute('aria-controls', `list-dropdown-popup-${config.id}`);\n }\n \n public detachDropdown(): void {\n if (this._listDropdown) {\n this._listDropdown.close();\n this._listDropdown.destroy();\n this._listDropdown = undefined;\n }\n this._inputElement.removeAttribute('aria-controls');\n }\n\n public propagateKey(key: string): void {\n this._listDropdown?.handleKey(key);\n }\n\n public setActiveDescendant(id: string): void {\n toggleAttribute(this._inputElement, !!id, 'aria-activedescendant', id);\n }\n\n public getTargetElementWidth(selector: string): number {\n const targetElement = this._getTargetElement(selector);\n return targetElement.getBoundingClientRect().width;\n }\n\n private _emitInputEvent(type: string): void {\n this._inputElement.dispatchEvent(new Event(type));\n }\n\n public emitInputEvent(type: string, data?: any): void {\n emitEvent(this._inputElement, type, data);\n }\n\n public setInputReadonly(value: boolean): void {\n this._inputElement.readOnly = value;\n }\n\n public setToggleDisabled(value: boolean): void {\n if (this._toggleElement) {\n this._toggleElement.setAttribute('aria-disabled', value.toString());\n if ('disabled' in this._toggleElement) {\n (this._toggleElement as HTMLButtonElement).disabled = value;\n } else {\n const button = this._toggleElement.querySelector('button') as HTMLButtonElement;\n if (button) {\n button.disabled = value;\n }\n }\n }\n }\n\n public hasActiveOption(): boolean {\n return (this._listDropdown?.getActiveOptionIndex() ?? -1) >= 0;\n }\n\n public activateOptionByIndex(index: number): void {\n this._listDropdown?.activateOption(index);\n }\n\n public activateFirstOption(): void {\n this._listDropdown?.activateFirstOption();\n }\n\n public getActiveOption(): IListDropdownOption | undefined {\n return this._listDropdown?.getActiveOption();\n }\n\n private _getTargetElement(selector?: string): HTMLElement {\n if (this._targetElement) {\n return this._targetElement;\n }\n this._targetElement = selector ? this._component.querySelector(selector) as HTMLElement || this._getDefaultTargetElement() : this._getDefaultTargetElement();\n return this._targetElement;\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(TEXT_FIELD_CONSTANTS.elementName) as HTMLElement;\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 return this._component; // Otherwise we just use the time-picker host as the target\n }\n}\n", "import { tokenize24HourTimeString, tokenize12HourTimeString, TWENTY_FOUR_HOUR_TIME_REGEX, TWELVE_HOUR_TIME_REGEX } from '../core/utils/time-utils';\n\nexport function timeStringToMillis(time: string | null, use24HourTime: boolean, allowSeconds: boolean): number | null {\n if (!time || /^\\s*$/.test(time)) {\n return null;\n }\n\n let hours = 0;\n let minutes = 0;\n let seconds = 0;\n\n if (TWENTY_FOUR_HOUR_TIME_REGEX.test(time)) {\n const tokens = tokenize24HourTimeString(time);\n hours = +tokens.hours || 0;\n minutes = +tokens.minutes || 0;\n seconds = +tokens.seconds || 0;\n } else if (TWELVE_HOUR_TIME_REGEX.test(time)) {\n const tokens = tokenize12HourTimeString(time);\n hours = +tokens.hours || 0;\n minutes = +tokens.minutes || 0;\n seconds = +tokens.seconds || 0;\n if (hours === 12 && tokens.meridiem === 'AM') {\n hours = 0;\n }\n if (hours < 12 && tokens.meridiem === 'PM') {\n hours += 12;\n }\n } else {\n return null;\n }\n\n return hoursToMillis(hours) + minutesToMillis(minutes) + (allowSeconds ? secondsToMillis(seconds) : 0);\n}\n\nexport function millisToTimeString(value: number | null | undefined, use24HourTime: boolean, allowSeconds: boolean): string | null {\n if (typeof value !== 'number' || value < 0) {\n return null;\n }\n\n let hours = Math.min(millisToHours(value), 23);\n const minutes = Math.min(millisToMinutesClamped(value), 59);\n const totalMinutes = value / (1000 * 60);\n const meridiem = totalMinutes < 720 ? 'AM' : 'PM';\n\n if (!use24HourTime) {\n hours = hours <= 12 ? hours : hours - 12;\n if (hours === 0) {\n hours = 12;\n }\n }\n\n let time = `${String(hours).padStart(2, '0')}:${String(minutes).padStart(2, '0')}`;\n\n if (allowSeconds) {\n const seconds = Math.min(millisToSecondsClamped(value), 59);\n time += `:${String(seconds).padStart(2, '0')}`;\n }\n\n if (!use24HourTime) {\n time += ` ${meridiem}`;\n }\n\n return time;\n}\n\nexport function millisToHours(millis: number): number {\n return Math.abs(Math.floor(millis / (1000 * 60 * 60)));\n}\n\nexport function millisToMinutesClamped(millis: number): number {\n return Math.abs(Math.floor(millisToMinutes(millis) % 60));\n}\n\nexport function millisToMinutes(millis: number): number {\n return millis / (1000 * 60);\n}\n\nexport function millisToSecondsClamped(millis: number): number {\n return Math.abs(Math.floor(millisToSeconds(millis) % 60));\n}\n\nexport function millisToSeconds(millis: number): number {\n return millis / 1000;\n}\n\nexport function hoursToMillis(hours: number): number {\n return hours * 60 * 60 * 1000;\n}\n\nexport function minutesToMillis(minutes: number): number {\n return minutes * 60 * 1000;\n}\n\nexport function secondsToMillis(seconds: number): number {\n return seconds * 1000;\n}\n\nexport function stripSecondsFromMillis(millis: number): number {\n return millis - secondsToMillis(millisToSecondsClamped(millis));\n}\n\nexport function getCurrentTimeOfDayMillis(allowSeconds: boolean): number {\n const date = new Date();\n const hours = date.getHours();\n const minutes = date.getMinutes();\n return hoursToMillis(hours) + minutesToMillis(minutes) + (allowSeconds ? secondsToMillis(date.getSeconds()) : 0);\n}\n\n/**\n * Combines a `Date` object with a 24-hour time string from the time-picker component.\n * @param date The `Date` object to adjust.\n * @param time The 24-hour time string.\n * @param useSeconds If your 24-hour time string contains seconds, set this to `true`.\n * @returns The same `Date` object that was provided, with the newly adjusted time.\n */\nexport function mergeDateWithTime(date: Date, time: string, useSeconds = false): Date {\n if (!date) {\n date = new Date();\n }\n\n const millis = timeStringToMillis(time, true, useSeconds);\n if (!millis) {\n date.setHours(0, 0, 0);\n return date;\n }\n\n let hours = millisToHours(millis);\n \n const twentyThreeHoursInMillis = 82800000;\n if (hours > twentyThreeHoursInMillis) {\n hours = twentyThreeHoursInMillis;\n } else if (hours < 0) {\n hours = 0;\n }\n\n const minutes = millisToMinutesClamped(millis);\n const seconds = useSeconds ? millisToSecondsClamped(millis) : 0;\n date.setHours(hours, minutes, seconds);\n\n return date;\n}\n", "import { ICustomElementFoundation, Platform, debounce, randomChars } from '@tylertech/forge-core';\nimport { ITimePickerAdapter } from './time-picker-adapter';\nimport { ITimeInputMaskOptions } from '../core/mask/time-input-mask';\nimport { isSupportedTimeFormat, TWENTY_FOUR_HOUR_TIME_REGEX, tryCoerceTimeString } from '../core/utils/time-utils';\nimport {\n TIME_PICKER_CONSTANTS,\n ITimePickerOptionValue,\n ITimePickerOption,\n TimePickerValidationCallback,\n TimePickerParseCallback,\n TimePickerFormatCallback,\n TimePickerCoercionCallback,\n TimePickerPrepareMaskCallback\n} from './time-picker-constants';\nimport { IListDropdownConfig, ListDropdownType, IListDropdownOption } from '../list-dropdown/list-dropdown-constants';\nimport { timeStringToMillis, millisToTimeString, minutesToMillis, getCurrentTimeOfDayMillis, millisToMinutes, stripSecondsFromMillis } from './time-picker-utils';\n\nexport interface ITimePickerFoundation extends ICustomElementFoundation {\n value: string | null | undefined;\n open: boolean;\n allowSeconds: boolean;\n masked: boolean;\n showMaskFormat: boolean;\n use24HourTime: boolean;\n allowInvalidTime: boolean;\n min: string | null | undefined;\n max: string | null | undefined;\n restrictedTimes: string[];\n startTime: string | null | undefined;\n step: number;\n allowInput: boolean;\n showNow: boolean;\n showHourOptions: boolean;\n customOptions: ITimePickerOption[];\n validationCallback: TimePickerValidationCallback;\n parseCallback: TimePickerParseCallback;\n formatCallback: TimePickerFormatCallback;\n coercionCallback: TimePickerCoercionCallback;\n prepareMaskCallback: TimePickerPrepareMaskCallback;\n disabled: boolean;\n popupClasses: string | string[];\n allowDropdown: boolean;\n}\n\nexport class TimePickerFoundation implements ITimePickerFoundation {\n // State vars\n private _value?: number | null = null;\n private _masked = true;\n private _use24HourTime = false;\n private _showMaskFormat = false;\n private _min?: number | null = null;\n private _max?: number | null = null;\n private _restrictedTimes: number[] = [];\n private _startTime?: number | null = null;\n private _step = TIME_PICKER_CONSTANTS.numbers.DEFAULT_MINUTE_STEP;\n private _allowInput = true;\n private _identifier: string;\n private _open = false;\n private _allowSeconds = false;\n private _allowInvalidTime = false;\n private _popupTarget: string;\n private _showNow = false;\n private _showHourOptions = true;\n private _customOptions: ITimePickerOption[] = [];\n private _validationCallback: TimePickerValidationCallback;\n private _parseCallback: TimePickerParseCallback;\n private _formatCallback: TimePickerFormatCallback;\n private _coercionCallback: TimePickerCoercionCallback;\n private _prepareMaskCallback: TimePickerPrepareMaskCallback;\n private _disabled = false;\n private _popupClasses: string[] = [];\n private _allowDropdown = true;\n \n // Internal state vars\n private _isInitialized = false;\n private _dropdownConfig: IListDropdownConfig<ITimePickerOptionValue> | undefined;\n\n // Listeners\n private _inputListener: (evt: Event) => void;\n private _inputKeydownListener: (evt: KeyboardEvent) => void;\n private _toggleMousedownListener: (evt: MouseEvent) => void;\n private _inputFocusListener: (evt: Event) => void;\n private _inputBlurListener: (evt: Event) => void;\n private _inputMousedownListener: (evt: MouseEvent) => void;\n \n constructor(private _adapter: ITimePickerAdapter) {\n this._identifier = randomChars(); // This is a unique identifier for this instance of the time picker (used for a11y purposes)\n\n // Set up listeners\n this._inputListener = evt => this._onInput(evt);\n this._inputKeydownListener = evt => this._onInputKeydown(evt);\n this._toggleMousedownListener = evt => this._onToggleMousedown(evt);\n this._inputFocusListener = evt => this._onInputFocus(evt);\n this._inputBlurListener = evt => this._onInputBlur(evt);\n this._inputMousedownListener = evt => this._onInputMousedown(evt);\n }\n\n public initialize(): void {\n this._adapter.initialize();\n \n // We require an input element to be a child of this component\n if (!this._adapter.hasInputElement()) {\n throw new Error('Unable to locate <input> element to attach to.');\n }\n\n this._adapter.initializeAccessibility(this._identifier);\n\n // Detect if a value already exists in the input and set our values based on that\n if (!this._value) {\n const inputValue = this._adapter.getInputValue();\n this._setValue(this._convertTimeStringToMillis(inputValue, this._use24HourTime, this._allowSeconds));\n }\n\n // Attach required listeners\n this._adapter.addInputListener('focus', this._inputFocusListener);\n this._adapter.addInputListener('blur', this._inputBlurListener);\n this._adapter.addInputListener('keydown', this._inputKeydownListener, true);\n\n // Ensure our input has the correct time format (make sure not to emit input events manually at this point)\n this._formatInputValue(false);\n\n // Apply our state\n if (typeof this._value === 'number') {\n this._applyValue(this._value, false);\n }\n this._applyAllowInput();\n this._applyAllowDropdown();\n this._applyDisabled();\n this._applyMask();\n\n this._isInitialized = true;\n }\n\n public disconnect(): void {\n this._isInitialized = false;\n\n // Remove listeners\n this._adapter.removeInputListener('input', this._inputListener);\n this._adapter.removeInputListener('focus', this._inputFocusListener);\n this._adapter.removeInputListener('blur', this._inputBlurListener);\n this._adapter.removeToggleListener('mousedown', this._toggleMousedownListener);\n this._adapter.removeInputListener('keydown', this._inputKeydownListener, true);\n\n // If we are using an input mask, let's destroy that now\n if (this._masked) {\n this._adapter.destroyMask();\n }\n\n // Ensure we remove our dropdown\n this._closeDropdown();\n\n // Cleanup any resources used in the adapter\n this._adapter.destroy();\n }\n\n /** Called when the input mask changes or the `input` event occurs on our `<input>` element. */\n private _onInput(evt: Event): void {\n this._handleInput(this._adapter.getInputValue());\n }\n\n private _onInputKeydown(evt: KeyboardEvent): void {\n if (evt.shiftKey) {\n switch (evt.code) {\n case 'Backspace':\n case 'Delete':\n evt.preventDefault();\n const result = this._trySetValue(null);\n if (result) {\n this._formatInputValue();\n }\n return;\n }\n }\n\n switch (evt.code) {\n case 'Tab':\n if (this._open) {\n this._selectActiveOption();\n }\n break;\n case 'Esc':\n case 'Escape':\n if (this._open) {\n evt.preventDefault();\n evt.stopPropagation();\n this._closeDropdown(true);\n }\n break;\n case 'Down':\n case 'ArrowDown':\n if (this._allowDropdown) {\n evt.preventDefault();\n if (!this._open) {\n this._openDropdown();\n if (typeof this._dropdownConfig?.visibleStartIndex === 'number' && this._dropdownConfig.visibleStartIndex >= 0) {\n this._adapter.activateOptionByIndex(this._dropdownConfig?.visibleStartIndex);\n } else {\n this._adapter.activateFirstOption();\n }\n // TODO: Should we cycle the hours, minutes, seconds, or meridiem where the cursor is instead of opening the dropdown?\n } else {\n if (!this._adapter.hasActiveOption()) {\n this._trySetActiveOption();\n } else {\n this._adapter.propagateKey(evt.code);\n }\n }\n }\n break;\n case 'ArrowUp':\n if (this._allowDropdown) {\n evt.preventDefault();\n if (this._open) {\n if (!this._adapter.hasActiveOption()) {\n this._trySetActiveOption();\n } else {\n this._adapter.propagateKey(evt.code);\n }\n } else {\n // TODO: cycle the hours, minutes, seconds, or meridiem where the cursor is\n }\n }\n break;\n case 'Enter':\n case 'NumpadEnter':\n case 'Home':\n case 'End':\n if (this._open) {\n if (evt.code === 'Enter' || evt.code === 'NumpadEnter') {\n evt.stopPropagation();\n }\n evt.preventDefault();\n this._adapter.propagateKey(evt.code);\n }\n break;\n case 'KeyN':\n evt.preventDefault();\n const nowMillis = getCurrentTimeOfDayMillis(this._allowSeconds);\n if (this._value !== nowMillis) {\n const timeString = millisToTimeString(nowMillis, true, this._allowSeconds);\n const canContinue = this._emitChangeEvent(timeString);\n if (canContinue) {\n this._applyValue(nowMillis);\n this._selectInputText();\n }\n }\n break;\n }\n }\n\n private _trySetActiveOption(): void {\n if (!this._adapter.hasActiveOption() && typeof this._dropdownConfig?.visibleStartIndex === 'number' && this._dropdownConfig.visibleStartIndex >= 0) {\n this._adapter.activateOptionByIndex(this._dropdownConfig?.visibleStartIndex);\n }\n }\n\n private _selectActiveOption(): void {\n const activeOption = this._adapter.getActiveOption();\n if (activeOption) {\n this._onSelect(activeOption.value);\n }\n }\n\n private _onToggleMousedown(evt: Event): void {\n if (this._disabled || !this.allowDropdown) {\n return;\n }\n\n evt.stopPropagation();\n\n if (this._adapter.isInputDisabled()) {\n return;\n }\n\n evt.preventDefault();\n\n if (this._open) {\n this._closeDropdown(true);\n } else {\n if (!Platform.isMobile) {\n this._adapter.tryFocusInput();\n } else {\n this._adapter.tryBlurInput();\n }\n this._openDropdown();\n }\n }\n\n private _onInputFocus(evt: Event): void {\n if (this._allowInput) {\n this._adapter.selectInputText();\n }\n\n if (this.masked && this._showMaskFormat) {\n this._applyMask();\n }\n }\n\n private _onInputBlur(evt: Event): void {\n if (this.masked && this._showMaskFormat) {\n this._applyMask();\n }\n\n this._formatInputValue();\n\n if (this._open && !this._adapter.isInputFocused()) {\n this._closeDropdown(true);\n }\n }\n\n private _onInputMousedown(evt: MouseEvent): void {\n if (!this._allowInput && !this._open) {\n this._openDropdown();\n this._adapter.tryFocusInput();\n window.requestAnimationFrame(() => this._adapter.selectInputText());\n }\n }\n\n private _applyDisabled(): void {\n this._adapter.setDisabled(this._disabled);\n }\n\n private _applyMask(): void {\n if (this._masked && this._allowInput) {\n this._adapter.destroyMask();\n const options: ITimeInputMaskOptions = {\n showMaskFormat: this._showMaskFormat && this._adapter.isInputFocused(),\n use24HourTime: this._use24HourTime,\n showSeconds: this._allowSeconds,\n prepareCallback: this._prepareMaskCallback,\n onChange: debounce((value: string) => this._handleInput(value), 0, true) // debounce this to avoid multiple callbacks for same value\n };\n this._adapter.initializeMask(options);\n } else {\n this._adapter.destroyMask();\n this._formatInputValue();\n }\n }\n\n private _applyAllowInput(): void {\n this._adapter.setInputReadonly(!this._allowInput);\n if (this._allowInput) {\n this._adapter.removeInputListener('mousedown', this._inputMousedownListener);\n // If not using an input mask we need to attach our own `input` listener, otherwise\n // we use the mask to notify us of changes\n if (!this._masked) {\n this._adapter.addInputListener('input', this._inputListener);\n }\n } else {\n this._adapter.addInputListener('mousedown', this._inputMousedownListener);\n this._adapter.removeInputListener('input', this._inputListener);\n }\n }\n\n private _applyAllowDropdown(): void {\n this._adapter.setToggleDisabled(!this._allowDropdown);\n if (this._allowDropdown) {\n this._adapter.removeToggleListener('mousedown', this._toggleMousedownListener);\n this._adapter.tryCreateToggle();\n this._adapter.addToggleListener('mousedown', this._toggleMousedownListener);\n } else if (this._open) {\n this._closeDropdown(true);\n }\n }\n\n private _applyAllowSeconds(): void {\n const originalValue = this._value;\n if (!this._allowSeconds) {\n // If we are not using seconds, we need to remove our seconds from the value\n if (typeof this._value !== 'number') {\n return;\n }\n\n this._setValue(stripSecondsFromMillis(this._value));\n\n if (this._isInitialized && originalValue !== this._value) {\n // We need to emit a change event with our new value which does not include the seconds\n const timeString = millisToTimeString(this._value, true, false);\n this._emitChangeEvent(timeString);\n }\n } else if (this._isInitialized && originalValue !== this._value) {\n // We need to emit a change event with our new value which includes the seconds\n const timeString = millisToTimeString(this._value, true, true);\n this._emitChangeEvent(timeString);\n }\n }\n\n private _handleInput(value: string): void {\n const rawValue = value;\n\n if (!this._allowInput) {\n return;\n }\n\n if (this._open) {\n this._closeDropdown(true);\n }\n\n // Let's attempt to coerce our time string into a known format to help with ease of entry\n value = tryCoerceTimeString(value, this._use24HourTime, this._allowSeconds);\n\n // If we were provided a custom coercion callback then we need to call that now to perform any further coercion by the consumer\n if (typeof this._coercionCallback === 'function') {\n value = this._coercionCallback.call(null, rawValue, value, this._allowSeconds);\n }\n\n // Validate the time format and make sure it's supported\n if (!this._isValidTimeFormat(value)) {\n value = '';\n }\n\n // Convert the time string to milliseconds\n let millis: number | null | undefined;\n if (!this._masked && typeof this._parseCallback === 'function') {\n millis = this._parseCallback.call(null, value);\n } else {\n millis = this._convertTimeStringToMillis(value, this._use24HourTime, this._allowSeconds);\n }\n\n // Validate that our time can be chosen as a valid value\n millis = this._validateMillis(millis);\n\n // Update our value\n this._trySetValue(millis);\n }\n\n private _emitChangeEvent(value: string | null, force = false): boolean {\n return this._adapter.emitHostEvent(TIME_PICKER_CONSTANTS.events.CHANGE, value, true, !force);\n }\n\n private _trySetValue(millis: number | null | undefined): boolean {\n // If our value hasn't changed, we can just return\n if (millis === this._value) {\n return false;\n }\n\n // Convert our milliseconds to a 24-hour time string to use as our normalized value\n const timeString = millisToTimeString(millis, true, this._allowSeconds);\n\n // Dispatch our custom input event to let consumers know raw input occurred (before our change event)\n this._adapter.emitInputEvent(TIME_PICKER_CONSTANTS.events.INPUT, timeString);\n\n // Only emit our change event if the value is different\n if (this._value !== millis) {\n const canContinue = this._emitChangeEvent(timeString);\n if (canContinue) {\n this._setValue(millis);\n return true;\n }\n }\n\n return false;\n }\n\n private _setValue(value: number | null | undefined): void {\n this._value = this._normalizeTimeValue(value);\n }\n\n private _validateMillis(millis: number | null | undefined): number | null | undefined {\n // Trap for min/max validation\n if (typeof millis === 'number') {\n const isBelowMin = typeof this._min === 'number' && millis < this._min;\n const isAboveMax = typeof this._max === 'number' && millis > this._max;\n if (isBelowMin || isAboveMax) {\n millis = null;\n }\n }\n \n // Trap for restricted times\n if (typeof millis === 'number' && this._restrictedTimes.length) {\n if (this._restrictedTimes.includes(millis)) {\n millis = null;\n }\n }\n\n return millis;\n }\n\n private _isValidTimeFormat(value: string): boolean {\n if (!this._masked && typeof this._validationCallback === 'function') {\n return this._validationCallback.call(this, value);\n }\n return isSupportedTimeFormat(value);\n }\n\n private _isValidInputValue(value: string): boolean {\n return TWENTY_FOUR_HOUR_TIME_REGEX.test(value);\n }\n\n private _onSelect(value: ITimePickerOptionValue): void {\n this._closeDropdown(true);\n\n // Check if the \"Now\" option was selected\n if (!value.isCustom && value.metadata === 'now') {\n value.time = getCurrentTimeOfDayMillis(this._allowSeconds);\n }\n\n // Check if this is a custom option, and then call the provided callback for it\n if (value.isCustom) {\n if (typeof value.customCallback === 'function') {\n const result = value.customCallback.call(null, value.metadata);\n if (typeof result !== 'number') {\n throw new Error('Custom options must provide a time of day value in milliseconds.');\n }\n value.time = result;\n } else {\n throw new Error('You must implement a `toMilliseconds` callback that returns the time value to use for this custom option.');\n }\n }\n\n // Make sure the time is different than what is already populated or we can just return\n if (this._value === value.time) {\n return;\n }\n\n // Emit the change event\n const timeString = millisToTimeString(value.time, true, this._allowSeconds);\n const canContinue = this._emitChangeEvent(timeString);\n if (!canContinue) {\n return;\n }\n\n // This will update our state and the UI at once\n this._applyValue(value.time);\n\n // Select full input text\n this._selectInputText();\n }\n\n private _selectInputText(): void {\n // We need to select the text of the input in the next cycle to allow time for the UI to update\n // with the selected text (assuming it still has focus)\n window.requestAnimationFrame(() => {\n window.requestAnimationFrame(() => {\n if (this._adapter.isInputFocused()) {\n this._adapter.selectInputText();\n }\n });\n });\n }\n\n private _applyValue(value: number | null | undefined, emitEvents = true): void {\n this._setValue(value);\n const formattedValue = this._formatValue(this._value);\n if (this._adapter.getInputValue() !== formattedValue) {\n this._adapter.setInputValue(formattedValue, emitEvents);\n }\n }\n\n private _normalizeTimeValue(value: number | null | undefined): number | null {\n if (value == null) {\n return null;\n } else if (value < 0) {\n return 0;\n } else if (value > TIME_PICKER_CONSTANTS.numbers.MAX_DAY_MILLIS) {\n return TIME_PICKER_CONSTANTS.numbers.MAX_DAY_MILLIS;\n }\n return value;\n }\n\n private _openDropdown(): void {\n const options = this._generateTimeOptions();\n\n if (!this.allowDropdown || !options.length) {\n return;\n }\n \n this._formatInputValue();\n this._open = true;\n this._adapter.setHostAttribute(TIME_PICKER_CONSTANTS.attributes.OPEN);\n \n const selectableOptions = options.filter(o => !o.divider && !o.disabled);\n let selectedValues: ITimePickerOptionValue[] = [];\n let visibleStartIndex = 0;\n \n // Find closest match in list of time options and activate/select it\n if (options.length) {\n if (this._value != null) {\n const optionIndex = this._findClosestOptionIndex(this._value, selectableOptions);\n if (optionIndex >= 0) {\n const isExactMatch = selectableOptions[optionIndex].value.time === this._value;\n if (isExactMatch) {\n selectedValues = [selectableOptions[optionIndex].value];\n } else {\n visibleStartIndex = optionIndex;\n }\n }\n } else if (typeof this._startTime === 'number') {\n const optionIndex = this._findClosestOptionIndex(this._startTime, selectableOptions);\n if (optionIndex >= 0 && optionIndex < selectableOptions.length) {\n visibleStartIndex = optionIndex;\n }\n } else if (this._startTime == null) {\n // If we don't have a start time set then let's scroll the closest time to current time into view\n visibleStartIndex = this._getOptionIndexClosestCurrent(selectableOptions);\n }\n }\n\n this._dropdownConfig = {\n id: `forge-time-picker-${this._identifier}`,\n selectedValues,\n syncWidth: true,\n visibleStartIndex,\n popupClasses: this._popupClasses,\n popupStatic: true,\n type: ListDropdownType.Standard,\n options,\n selectCallback: value => this._onSelect(value),\n closeCallback: () => this._closeDropdown(true),\n activeChangeCallback: id => this._adapter.setActiveDescendant(id),\n targetWidthCallback: () => this._adapter.getTargetElementWidth(this._popupTarget)\n };\n this._adapter.attachDropdown(this._dropdownConfig);\n this._adapter.emitHostEvent(TIME_PICKER_CONSTANTS.events.OPEN, undefined, false);\n }\n\n private _closeDropdown(emitCloseEvent = false): void {\n this._open = false;\n this._dropdownConfig = undefined;\n this._adapter.removeHostAttribute(TIME_PICKER_CONSTANTS.attributes.OPEN);\n this._adapter.detachDropdown();\n if (emitCloseEvent) {\n this._adapter.emitHostEvent(TIME_PICKER_CONSTANTS.events.CLOSE, true, false);\n }\n }\n\n private _getOptionIndexClosestCurrent(options: IListDropdownOption<ITimePickerOptionValue>[]): number {\n const date = new Date();\n const currentTimeString = `${String(date.getHours()).padStart(2, '0')}:${String(date.getMinutes()).padStart(2, '0')}`;\n const currentTimeMillis = timeStringToMillis(currentTimeString, true, false) as number;\n return this._findClosestOptionIndex(currentTimeMillis, options);\n }\n\n private _findClosestOptionIndex(value: number, options: Array<IListDropdownOption<ITimePickerOptionValue>>): number {\n const closestItem = options.reduce((prev, curr) => {\n return Math.abs((curr.value.time || 0) - value) < Math.abs((prev.value.time || 0) - value) ? curr : prev;\n });\n return options.indexOf(closestItem);\n }\n\n private _formatInputValue(emitEvents = true): void {\n const inputValue = this._adapter.getInputValue();\n \n // If we allow invalid times, we can leave the input value as-is (only when unmasked)\n if (this._allowInvalidTime && !this._masked && inputValue && !this._value) {\n return;\n }\n\n const formattedValue = this._formatValue(this._value);\n \n if (inputValue !== formattedValue) {\n this._adapter.setInputValue(formattedValue, emitEvents);\n this._adapter.emitInputEvent(TIME_PICKER_CONSTANTS.events.INPUT, formattedValue);\n }\n }\n\n private _generateTimeOptions(): Array<IListDropdownOption<ITimePickerOptionValue>> {\n const minMinutes = this._min != null ? Math.max(millisToMinutes(this._min), 0) : 0;\n const maxMinutes = this._max != null ? Math.min(millisToMinutes(this._max), TIME_PICKER_CONSTANTS.numbers.MAX_DAY_MINUTES) : TIME_PICKER_CONSTANTS.numbers.MAX_DAY_MINUTES;\n const minuteStep = this._step;\n const times: IListDropdownOption[] = [];\n let leadingOptions: IListDropdownOption[] = [];\n \n if (this._showHourOptions) {\n for (let totalMinutes = minMinutes; totalMinutes <= maxMinutes; totalMinutes += minuteStep) {\n if (totalMinutes === TIME_PICKER_CONSTANTS.numbers.MAX_DAY_MINUTES) {\n break;\n }\n const millis = minutesToMillis(totalMinutes);\n const disabled = this._restrictedTimes.includes(millis);\n const label = millisToTimeString(millis, this._use24HourTime, false) || '';\n const value: ITimePickerOptionValue = { time: millis };\n times.push({ label, value, disabled });\n }\n\n // Add divider between AM/PM times\n const firstPmIndex = times.findIndex(t => t.value.time / 1000 / 60 >= 720);\n if (firstPmIndex >= 0 && firstPmIndex < times.length - 1) {\n times.splice(firstPmIndex, 0, { label: '', value: null, divider: true });\n }\n }\n\n\n // Check if we need to prepend a \"Now\" option\n if (this._showNow) {\n const value: ITimePickerOptionValue = { time: null, metadata: 'now' };\n leadingOptions.push({ label: 'Now', value });\n }\n\n // Check for any custom provided options to prepend\n if (Array.isArray(this._customOptions) && this._customOptions.length) {\n const options = this._customOptions.map(o => {\n const value: ITimePickerOptionValue = { time: null, metadata: o.value, isCustom: true, customCallback: o.toMilliseconds };\n return { label: o.label, value };\n });\n leadingOptions = [...leadingOptions, ...options];\n }\n\n // Append all leading options\n if (leadingOptions.length) {\n if (times.length) {\n times.splice(0, 0, { label: '', value: null, divider: true });\n }\n leadingOptions.forEach((o, index) => times.splice(index, 0, o));\n }\n\n return times;\n }\n\n private _convertTimeStringToMillis(value: string | null, use24HourTime: boolean, allowSeconds: boolean): number | null {\n if (!value || !this._isValidTimeFormat(value)) {\n value = '';\n }\n return timeStringToMillis(value, use24HourTime, allowSeconds);\n }\n\n private _formatValue(value: number | null | undefined): string {\n if (!this._masked && typeof this._formatCallback === 'function') {\n return this._formatCallback.call(null, value, this._use24HourTime, this._allowSeconds);\n }\n return millisToTimeString(this._value, this._use24HourTime, this._allowSeconds) || '';\n }\n\n private _warnInvalidFormat(value: string): void {\n console.warn(`The specified value \"${value}\" does not conform to the required format. The format is \"HH:mm\", \"HH:mm:ss\" where HH is 00-23, mm is 00-59, and ss is 00-59.`);\n }\n\n public get open(): boolean {\n return this._open;\n }\n public set open(value: boolean) {\n if (this._open !== value) {\n if (this._isInitialized) {\n this._open = value;\n if (this._open) {\n this._openDropdown();\n } else {\n this._closeDropdown();\n }\n }\n }\n }\n\n public get masked(): boolean {\n return this._masked;\n }\n public set masked(value: boolean) {\n if (this._masked !== value) {\n this._masked = value;\n if (this._isInitialized) {\n if (this._masked) {\n this._adapter.removeInputListener('input', this._inputListener);\n this._applyMask();\n } else {\n this._adapter.destroyMask();\n this._formatInputValue();\n this._adapter.addInputListener('input', this._inputListener);\n }\n }\n }\n }\n\n public get showMaskFormat(): boolean {\n return this._showMaskFormat;\n }\n public set showMaskFormat(value: boolean) {\n if (this._showMaskFormat !== value) {\n this._showMaskFormat = value;\n }\n }\n\n public get allowSeconds(): boolean {\n return this._allowSeconds;\n }\n public set allowSeconds(value: boolean) {\n if (this._allowSeconds !== value) {\n this._allowSeconds = !!value;\n this._applyAllowSeconds();\n\n if (this._isInitialized) {\n this._applyMask();\n this._formatInputValue();\n }\n\n this._adapter.setHostAttribute(TIME_PICKER_CONSTANTS.attributes.ALLOW_SECONDS, `${!!value}`);\n }\n }\n\n public get use24HourTime(): boolean {\n return this._use24HourTime;\n }\n public set use24HourTime(value: boolean) {\n if (this._use24HourTime !== value) {\n this._use24HourTime = !!value;\n \n if (this._isInitialized) {\n this._applyMask();\n this._formatInputValue();\n }\n\n this._adapter.setHostAttribute(TIME_PICKER_CONSTANTS.attributes.USE_24_HOUR_TIME, `${!!value}`);\n }\n }\n\n public get allowInvalidTime(): boolean {\n return this._allowInvalidTime;\n }\n public set allowInvalidTime(value: boolean) {\n if (this._allowInvalidTime !== value) {\n this._allowInvalidTime = !!value;\n this._adapter.setHostAttribute(TIME_PICKER_CONSTANTS.attributes.ALLOW_INVALID_TIME, `${!!value}`);\n }\n }\n\n public get value(): string | null {\n return millisToTimeString(this._value, true, this._allowSeconds);\n }\n public set value(value: string | null) {\n if (value && !this._isValidInputValue(value)) {\n this._warnInvalidFormat(value);\n return;\n }\n const millis = this._validateMillis(this._convertTimeStringToMillis(value, true, true));\n this._setValue(millis);\n if (this._isInitialized) {\n this._applyValue(this._value);\n }\n }\n\n public get min(): string | null {\n return millisToTimeString(this._min, true, this._allowSeconds);\n }\n public set min(value: string | null) {\n if (this._min !== value) {\n if (value && !this._isValidInputValue(value)) {\n this._warnInvalidFormat(value);\n return;\n }\n this._min = this._convertTimeStringToMillis(value, true, this._allowSeconds);\n\n // Validate and reset our millis to ensure within range\n const millis = this._validateMillis(this._value);\n this._setValue(millis);\n\n if (this._isInitialized) {\n this._applyValue(millis);\n }\n }\n }\n\n public get max(): string | null {\n return millisToTimeString(this._max, true, this._allowSeconds);\n }\n public set max(value: string | null) {\n if (this._max !== value) {\n if (value && !this._isValidInputValue(value)) {\n this._warnInvalidFormat(value);\n return;\n }\n this._max = this._convertTimeStringToMillis(value, true, this._allowSeconds);\n \n // Validate and reset our millis to ensure within range\n const millis = this._validateMillis(this._value);\n this._setValue(millis);\n\n if (this._isInitialized) {\n this._applyValue(millis);\n }\n }\n }\n\n public get restrictedTimes(): string[] {\n return this._restrictedTimes\n .map(t => millisToTimeString(t, true, this._allowSeconds))\n .filter(v => typeof v === 'string') as string[];\n }\n public set restrictedTimes(value: string[]) {\n if (!Array.isArray(value)) {\n value = [];\n }\n this._restrictedTimes = value\n .filter(v => typeof v === 'string')\n .map(v => this._convertTimeStringToMillis(v, true, true))\n .filter(v => typeof v === 'number') as number[];\n }\n\n public get startTime(): string | null {\n return millisToTimeString(this._startTime, true, this._allowSeconds);\n }\n public set startTime(value: string | null) {\n if (this._startTime !== value) {\n if (value && !this._isValidInputValue(value)) {\n this._warnInvalidFormat(value);\n return;\n }\n this._startTime = this._convertTimeStringToMillis(value, true, this._allowSeconds);\n }\n }\n\n public get step(): number {\n return this._step;\n }\n public set step(value: number) {\n this._step = value;\n }\n\n public get allowInput(): boolean {\n return this._allowInput;\n }\n public set allowInput(value: boolean) {\n if (this._allowInput !== value) {\n this._allowInput = value;\n if (this._isInitialized) {\n this._applyAllowInput();\n this._applyMask();\n }\n }\n }\n\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 public get showNow(): boolean {\n return this._showNow;\n }\n public set showNow(value: boolean) {\n if (this._showNow !== value) {\n this._showNow = value;\n }\n }\n\n public get showHourOptions(): boolean {\n return this._showHourOptions;\n }\n public set showHourOptions(value: boolean) {\n if (this._showHourOptions !== value) {\n this._showHourOptions = value;\n }\n }\n\n public get customOptions(): ITimePickerOption[] {\n return this._customOptions;\n }\n public set customOptions(value: ITimePickerOption[]) {\n this._customOptions = Array.isArray(value) ? value : [];\n }\n\n public set validationCallback(cb: TimePickerValidationCallback) {\n this._validationCallback = cb;\n if (this._isInitialized) {\n this._applyMask();\n }\n }\n\n public set parseCallback(cb: TimePickerParseCallback) {\n this._parseCallback = cb;\n }\n\n public set formatCallback(cb: TimePickerFormatCallback) {\n this._formatCallback = cb;\n }\n\n public set coercionCallback(cb: TimePickerCoercionCallback) {\n this._coercionCallback = cb;\n }\n\n public set prepareMaskCallback(cb: TimePickerPrepareMaskCallback) {\n this._prepareMaskCallback = cb;\n if (this._isInitialized) {\n this._applyMask();\n }\n }\n\n public get disabled(): boolean {\n return this._disabled;\n }\n public set disabled(value: boolean) {\n if (this._disabled !== value) {\n this._disabled = !!value;\n if (this._isInitialized) {\n this._applyDisabled();\n }\n this._adapter.toggleHostAttribute(TIME_PICKER_CONSTANTS.attributes.DISABLED, this._disabled);\n }\n }\n\n public get popupClasses(): string | string[] {\n if (Array.isArray(this._popupClasses)) {\n return [...this._popupClasses];\n }\n\n return this._popupClasses;\n }\n public set popupClasses(value: string | string[]) {\n if (Array.isArray(value)) {\n this._popupClasses = [...value];\n } else {\n this._popupClasses = [value];\n }\n }\n\n public get allowDropdown(): boolean {\n return this._allowDropdown;\n }\n public set allowDropdown(value: boolean) {\n if (this._allowDropdown !== value) {\n this._allowDropdown = value;\n if (this._isInitialized) {\n this._applyAllowDropdown();\n }\n }\n }\n}\n", "import { CustomElement, attachShadowTemplate, FoundationProperty, coerceBoolean, coerceNumber, ensureChild } from '@tylertech/forge-core';\nimport { tylIconClockOutline } from '@tylertech/tyler-icons/extended';\nimport { tylIconClose } from '@tylertech/tyler-icons/standard';\nimport { TimePickerAdapter } from './time-picker-adapter';\nimport { TimePickerFoundation } from './time-picker-foundation';\nimport {\n TIME_PICKER_CONSTANTS,\n ITimePickerOption,\n TimePickerParseCallback,\n TimePickerValidationCallback,\n TimePickerFormatCallback,\n TimePickerCoercionCallback,\n TimePickerPrepareMaskCallback\n} from './time-picker-constants';\nimport { IconRegistry, IconComponent } from '../icon';\nimport { IconButtonComponent } from '../icon-button';\nimport { PopupComponent } from '../popup';\nimport { DialogComponent } from '../dialog';\nimport { ListComponent, ListItemComponent } from '../list';\nimport { BaseComponent, IBaseComponent } from '../core/base/base-component';\n\nconst template = '<template><slot></slot></template>';\nconst styles = ':host{display:block}:host([hidden]){display:none}';\n\nexport interface ITimePickerComponent extends IBaseComponent {\n value: string | null | undefined;\n open: boolean;\n allowSeconds: boolean;\n masked: boolean;\n showMaskFormat: boolean;\n use24HourTime: boolean;\n allowInvalidTime: boolean;\n min: string | null | undefined;\n max: string | null | undefined;\n restrictedTimes: string[];\n startTime: string | null | undefined;\n step: number;\n allowInput: boolean;\n showNow: boolean;\n showHourOptions: boolean;\n customOptions: ITimePickerOption[];\n validationCallback: TimePickerValidationCallback;\n parseCallback: TimePickerParseCallback;\n formatCallback: TimePickerFormatCallback;\n coercionCallback: TimePickerCoercionCallback;\n prepareMaskCallback: TimePickerPrepareMaskCallback;\n disabled: boolean;\n popupClasses: string | string[];\n allowDropdown: boolean;\n popupTarget: string;\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'forge-time-picker': ITimePickerComponent;\n }\n\n interface HTMLElementEventMap {\n 'forge-time-picker-open': CustomEvent<void>;\n 'forge-time-picker-close': CustomEvent<void>;\n 'forge-time-picker-input': Event;\n 'forge-time-picker-change': CustomEvent<string | null>;\n }\n}\n\n/**\n * The web component class behind the `<forge-time-picker>` custom element.\n * \n * @tag forge-time-picker\n */\n@CustomElement({\n name: TIME_PICKER_CONSTANTS.elementName,\n dependencies: [\n ListComponent,\n ListItemComponent,\n IconButtonComponent,\n IconComponent,\n PopupComponent,\n IconComponent,\n DialogComponent\n ]\n})\nexport class TimePickerComponent extends BaseComponent implements ITimePickerComponent {\n public static get observedAttributes(): string[] {\n return [\n TIME_PICKER_CONSTANTS.attributes.VALUE,\n TIME_PICKER_CONSTANTS.attributes.OPEN,\n TIME_PICKER_CONSTANTS.attributes.ALLOW_SECONDS,\n TIME_PICKER_CONSTANTS.attributes.MASKED,\n TIME_PICKER_CONSTANTS.attributes.SHOW_MASK_FORMAT,\n TIME_PICKER_CONSTANTS.attributes.USE_24_HOUR_TIME,\n TIME_PICKER_CONSTANTS.attributes.ALLOW_INVALID_TIME,\n TIME_PICKER_CONSTANTS.attributes.MIN,\n TIME_PICKER_CONSTANTS.attributes.MAX,\n TIME_PICKER_CONSTANTS.attributes.START_TIME,\n TIME_PICKER_CONSTANTS.attributes.STEP,\n TIME_PICKER_CONSTANTS.attributes.ALLOW_INPUT,\n TIME_PICKER_CONSTANTS.attributes.SHOW_NOW,\n TIME_PICKER_CONSTANTS.attributes.SHOW_HOUR_OPTIONS,\n TIME_PICKER_CONSTANTS.attributes.DISABLED,\n TIME_PICKER_CONSTANTS.attributes.POPUP_CLASSES,\n TIME_PICKER_CONSTANTS.attributes.ALLOW_DROPDOWN\n ];\n }\n\n private _foundation: TimePickerFoundation;\n\n constructor() {\n super();\n IconRegistry.define([tylIconClockOutline, tylIconClose]);\n attachShadowTemplate(this, template, styles);\n this._foundation = new TimePickerFoundation(new TimePickerAdapter(this));\n }\n\n public connectedCallback(): void {\n if (this.querySelector(TIME_PICKER_CONSTANTS.selectors.INPUT)) {\n this._foundation.initialize();\n } else {\n ensureChild(this, TIME_PICKER_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 switch (name) {\n case TIME_PICKER_CONSTANTS.attributes.VALUE:\n this.value = newValue;\n break;\n case TIME_PICKER_CONSTANTS.attributes.OPEN:\n this.open = coerceBoolean(newValue);\n break;\n case TIME_PICKER_CONSTANTS.attributes.ALLOW_SECONDS:\n this.allowSeconds = coerceBoolean(newValue);\n break;\n case TIME_PICKER_CONSTANTS.attributes.MASKED:\n this.masked = coerceBoolean(newValue);\n break;\n case TIME_PICKER_CONSTANTS.attributes.SHOW_MASK_FORMAT:\n this.showMaskFormat = coerceBoolean(newValue);\n break;\n case TIME_PICKER_CONSTANTS.attributes.USE_24_HOUR_TIME:\n this.use24HourTime = coerceBoolean(newValue);\n break;\n case TIME_PICKER_CONSTANTS.attributes.ALLOW_INVALID_TIME:\n this.allowInvalidTime = coerceBoolean(newValue);\n break;\n case TIME_PICKER_CONSTANTS.attributes.SHOW_NOW:\n this.showNow = coerceBoolean(newValue);\n break;\n case TIME_PICKER_CONSTANTS.attributes.SHOW_HOUR_OPTIONS:\n this.showHourOptions = coerceBoolean(newValue);\n break;\n case TIME_PICKER_CONSTANTS.attributes.MIN:\n this.min = newValue;\n break;\n case TIME_PICKER_CONSTANTS.attributes.MAX:\n this.max = newValue;\n break;\n case TIME_PICKER_CONSTANTS.attributes.START_TIME:\n this.startTime = newValue;\n break;\n case TIME_PICKER_CONSTANTS.attributes.STEP:\n this.step = coerceNumber(newValue);\n break;\n case TIME_PICKER_CONSTANTS.attributes.ALLOW_INPUT:\n this.allowInput = coerceBoolean(newValue);\n break;\n case TIME_PICKER_CONSTANTS.attributes.DISABLED:\n this.disabled = coerceBoolean(newValue);\n break;\n case TIME_PICKER_CONSTANTS.attributes.POPUP_CLASSES:\n this.popupClasses = newValue;\n break;\n case TIME_PICKER_CONSTANTS.attributes.ALLOW_DROPDOWN:\n this.allowDropdown = coerceBoolean(newValue);\n break;\n }\n }\n\n @FoundationProperty()\n public declare value: string | null | undefined;\n\n @FoundationProperty()\n public declare open: boolean;\n\n @FoundationProperty()\n public declare allowSeconds: boolean;\n\n @FoundationProperty()\n public declare masked: boolean;\n\n @FoundationProperty()\n public declare showMaskFormat: boolean;\n\n @FoundationProperty()\n public declare use24HourTime: boolean;\n\n @FoundationProperty()\n public declare allowInvalidTime: boolean;\n\n @FoundationProperty()\n public declare min: string | null | undefined;\n\n @FoundationProperty()\n public declare max: string | null | undefined;\n\n @FoundationProperty()\n public declare restrictedTimes: string[];\n\n @FoundationProperty()\n public declare startTime: string | null | undefined;\n\n @FoundationProperty()\n public declare step: number;\n\n @FoundationProperty()\n public declare allowInput: boolean;\n\n @FoundationProperty()\n public declare showNow: boolean;\n\n /** Whether or not to display hour options in dropdown */\n @FoundationProperty()\n public declare showHourOptions: boolean;\n\n @FoundationProperty()\n public declare customOptions: ITimePickerOption[];\n\n @FoundationProperty()\n public declare validationCallback: TimePickerValidationCallback;\n \n @FoundationProperty()\n public declare parseCallback: TimePickerParseCallback;\n\n @FoundationProperty()\n public declare formatCallback: TimePickerFormatCallback;\n\n @FoundationProperty()\n public declare coercionCallback: TimePickerCoercionCallback;\n\n @FoundationProperty()\n public declare prepareMaskCallback: TimePickerPrepareMaskCallback;\n\n @FoundationProperty()\n public declare disabled: boolean;\n\n @FoundationProperty()\n public declare popupClasses: string | string[];\n\n @FoundationProperty()\n public declare allowDropdown: boolean;\n\n @FoundationProperty()\n public declare popupTarget: string;\n}\n", "import { IBaseComponentDelegateConfig } from '../core/delegates/base-component-delegate';\nimport { FormFieldComponentDelegate, IFormFieldComponentDelegateOptions } from '../core/delegates/form-field-component-delegate';\nimport { ITextFieldComponent, ITextFieldComponentDelegateConfig, TextFieldComponentDelegate } from '../text-field';\nimport { ITimePickerComponent } from './time-picker';\nimport { TIME_PICKER_CONSTANTS } from './time-picker-constants';\n\nexport type TimePickerComponentDelegateProps = Partial<ITimePickerComponent>;\nexport interface ITimePickerComponentDelegateOptions extends IFormFieldComponentDelegateOptions {\n textFieldDelegateConfig?: ITextFieldComponentDelegateConfig;\n}\nexport interface ITimePickerComponentDelegateConfig extends IBaseComponentDelegateConfig<ITimePickerComponent, ITimePickerComponentDelegateOptions> {}\n\nexport class TimePickerComponentDelegate extends FormFieldComponentDelegate<ITimePickerComponent, ITimePickerComponentDelegateOptions> {\n private _textFieldDelegate: TextFieldComponentDelegate;\n\n constructor(config?: ITimePickerComponentDelegateConfig) {\n super(config);\n }\n\n protected _build(): ITimePickerComponent {\n const timePicker = document.createElement(TIME_PICKER_CONSTANTS.elementName);\n this._attachTextField(timePicker);\n return timePicker;\n }\n\n public get inputElement(): HTMLInputElement {\n return this._textFieldDelegate.inputElement;\n }\n\n public get textFieldElement(): ITextFieldComponent {\n return this._textFieldDelegate.element;\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._element.disabled;\n }\n public set disabled(value: boolean) {\n this._element.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(TIME_PICKER_CONSTANTS.events.CHANGE, (evt: CustomEvent<string>) => listener(evt.detail ?? ''));\n }\n\n public onInput(listener: (value: string) => void): void {\n this._element.addEventListener(TIME_PICKER_CONSTANTS.events.INPUT, (evt: CustomEvent<string>) => 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(component: ITimePickerComponent): void {\n const textFieldConfig: ITextFieldComponentDelegateConfig = {\n props: { ...this._config.options?.textFieldDelegateConfig?.props },\n options: { ...this._config.options?.textFieldDelegateConfig?.options }\n };\n this._textFieldDelegate = new TextFieldComponentDelegate(textFieldConfig);\n component.appendChild(this._textFieldDelegate.element);\n }\n}\n", "import { defineCustomElement } from '@tylertech/forge-core';\n\nimport { TimePickerComponent } from './time-picker';\n\nexport * from './time-picker-adapter';\nexport * from './time-picker-component-delegate';\nexport * from './time-picker-constants';\nexport * from './time-picker-foundation';\nexport * from './time-picker-utils';\nexport * from './time-picker';\n\nexport function defineTimePickerComponent(): void {\n defineCustomElement(TimePickerComponent);\n}\n"],
|
|
5
|
+
"mappings": "49BAIA,IAAMA,EAA2C,GAAGC,eAE9CC,GAAa,CACjB,OAAQ,2BACR,MAAO,QACP,KAAM,OACN,cAAe,gBACf,OAAQ,SACR,iBAAkB,mBAClB,iBAAkB,mBAClB,mBAAoB,qBACpB,IAAK,MACL,IAAK,MACL,WAAY,aACZ,KAAM,OACN,YAAa,cACb,SAAU,WACV,kBAAmB,oBACnB,SAAU,WACV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F,GAASE,EAAAD,EAAI,SAAJ,KAAAC,EAAc,EAAE,EAAC,CAC9H,CAEO,QAAQF,EAAyC,CACtD,KAAK,SAAS,iBAAiBF,EAAsB,OAAO,MAAQG,GAA0B,CA3DlG,IAAAC,EA2DqG,OAAAF,GAASE,EAAAD,EAAI,SAAJ,KAAAC,EAAc,EAAE,EAAC,CAC7H,CAEO,QAAQF,EAA2C,CACxD,KAAK,mBAAmB,aAAa,iBAAiB,QAAUC,GAAoBD,EAASC,CAAG,CAAC,CACnG,CAEO,OAAOD,EAA2C,CACvD,KAAK,mBAAmB,aAAa,iBAAiB,OAASC,GAAoBD,EAASC,CAAG,CAAC,CAClG,CAEQ,iBAAiBE,EAAuC,CAtElE,IAAAD,EAAAE,EAAAC,EAAAC,EAuEI,IAAMC,EAAqD,CACzD,MAAOC,EAAA,IAAKJ,GAAAF,EAAA,KAAK,QAAQ,UAAb,YAAAA,EAAsB,0BAAtB,YAAAE,EAA+C,OAC3D,QAASI,EAAA,IAAKF,GAAAD,EAAA,KAAK,QAAQ,UAAb,YAAAA,EAAsB,0BAAtB,YAAAC,EAA+C,QAC/D,EACA,KAAK,mBAAqB,IAAIG,GAA2BF,CAAe,EACxEJ,EAAU,YAAY,KAAK,mBAAmB,OAAO,CACvD,CACF,ECnEO,SAASO,IAAkC,CAChDC,EAAoBC,CAAmB,CACzC",
|
|
6
|
+
"names": ["elementName", "COMPONENT_NAME_PREFIX", "attributes", "selectors", "events", "numbers", "TIME_PICKER_CONSTANTS", "TimePickerAdapter", "BaseAdapter", "component", "TIME_PICKER_CONSTANTS", "options", "TimeInputMask", "_a", "identifier", "type", "listener", "capture", "textField", "TEXT_FIELD_CONSTANTS", "toggleElement", "existingIconButton", "ICON_BUTTON_CONSTANTS", "iconButtonElement", "buttonElement", "iconElement", "ICON_CONSTANTS", "getActiveElement", "value", "emitEvents", "isDisabled", "config", "ListDropdown", "key", "id", "toggleAttribute", "selector", "data", "emitEvent", "button", "_b", "index", "textFieldRoot", "getShadowElement", "timeStringToMillis", "time", "use24HourTime", "allowSeconds", "hours", "minutes", "seconds", "TWENTY_FOUR_HOUR_TIME_REGEX", "tokens", "tokenize24HourTimeString", "TWELVE_HOUR_TIME_REGEX", "tokenize12HourTimeString", "hoursToMillis", "minutesToMillis", "secondsToMillis", "millisToTimeString", "value", "millisToHours", "millisToMinutesClamped", "meridiem", "millisToSecondsClamped", "millis", "millisToMinutes", "millisToSeconds", "stripSecondsFromMillis", "getCurrentTimeOfDayMillis", "date", "mergeDateWithTime", "useSeconds", "twentyThreeHoursInMillis", "TimePickerFoundation", "_adapter", "TIME_PICKER_CONSTANTS", "randomChars", "evt", "inputValue", "_a", "_b", "nowMillis", "getCurrentTimeOfDayMillis", "timeString", "millisToTimeString", "activeOption", "Platform", "options", "debounce", "value", "originalValue", "stripSecondsFromMillis", "rawValue", "tryCoerceTimeString", "millis", "force", "isBelowMin", "isAboveMax", "isSupportedTimeFormat", "TWENTY_FOUR_HOUR_TIME_REGEX", "result", "emitEvents", "formattedValue", "selectableOptions", "o", "selectedValues", "visibleStartIndex", "optionIndex", "id", "emitCloseEvent", "date", "currentTimeString", "currentTimeMillis", "timeStringToMillis", "closestItem", "prev", "curr", "minMinutes", "millisToMinutes", "maxMinutes", "minuteStep", "times", "leadingOptions", "totalMinutes", "minutesToMillis", "disabled", "label", "firstPmIndex", "t", "index", "use24HourTime", "allowSeconds", "v", "cb", "template", "styles", "TimePickerComponent", "BaseComponent", "IconRegistry", "tylIconClockOutline", "tylIconClose", "attachShadowTemplate", "TimePickerFoundation", "TimePickerAdapter", "TIME_PICKER_CONSTANTS", "ensureChild", "name", "oldValue", "newValue", "coerceBoolean", "coerceNumber", "__decorateClass", "FoundationProperty", "CustomElement", "ListComponent", "ListItemComponent", "IconButtonComponent", "IconComponent", "PopupComponent", "DialogComponent", "TimePickerComponentDelegate", "FormFieldComponentDelegate", "config", "timePicker", "TIME_PICKER_CONSTANTS", "value", "listener", "evt", "_a", "component", "_b", "_c", "_d", "textFieldConfig", "__spreadValues", "TextFieldComponentDelegate", "defineTimePickerComponent", "defineCustomElement", "TimePickerComponent"]
|
|
7
|
+
}
|
|
@@ -3,5 +3,5 @@
|
|
|
3
3
|
* Copyright 2023 Tyler Technologies, Inc.
|
|
4
4
|
* License: Apache-2.0
|
|
5
5
|
*/
|
|
6
|
-
import{a as e}from"./chunk.
|
|
7
|
-
//# sourceMappingURL=chunk.
|
|
6
|
+
import{a as e}from"./chunk.PADPL4L3.js";var o=class extends e{constructor(n){super(n)}};export{o as a};
|
|
7
|
+
//# sourceMappingURL=chunk.KVCDAZ6B.js.map
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
* License: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
function h(t){return t.path||t.composedPath&&t.composedPath()||a(t.target)}function a(t){let o=[];for(;t;){if(t.shadowRoot&&(t.shadowRoot.activeElement&&o.push(t.shadowRoot.activeElement),o.push(t.shadowRoot)),o.push(t),t.tagName==="HTML"){o.push(document),o.push(window);break}t=t.parentElement}return o}export{h as a};
|
|
7
|
-
//# sourceMappingURL=chunk.
|
|
7
|
+
//# sourceMappingURL=chunk.LEVFMI2Q.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../node_modules/@tylertech/forge-core/esm/utils/event-utils.js"],
|
|
4
4
|
"sourcesContent": ["/**\n * Gets the node path from where the event originated from.\n * @param evt The event.\n */\nexport function getEventPath(evt) {\n return evt.path || (evt.composedPath && evt.composedPath()) || composedPath(evt.target);\n}\n/**\n * Equivalent to path/composedPath.\n * Note: Slots and shadow roots are detected, but aren't needed as they are virtually invisible anyway...\n */\nexport function composedPath(el) {\n const path = [];\n while (el) {\n if (el.shadowRoot) {\n if (el.shadowRoot.activeElement) {\n path.push(el.shadowRoot.activeElement);\n }\n path.push(el.shadowRoot);\n }\n path.push(el);\n if (el.tagName === 'HTML') {\n path.push(document);\n path.push(window);\n break;\n }\n el = el.parentElement;\n }\n return path;\n}\n"],
|
|
5
|
-
"mappings": "AAIO,SAASA,EAAaC,EAAK,CAC9B,OAAOA,EAAI,MAASA,EAAI,cAAgBA,EAAI,aAAa,GAAMC,EAAaD,EAAI,MAAM,CAC1F,CAKO,SAASC,EAAaC,EAAI,CAC7B,IAAMC,EAAO,CAAC,EACd,KAAOD,GAAI,CAQP,GAPIA,EAAG,aACCA,EAAG,WAAW,eACdC,EAAK,KAAKD,EAAG,WAAW,aAAa,EAEzCC,EAAK,KAAKD,EAAG,UAAU,GAE3BC,EAAK,KAAKD,CAAE,EACRA,EAAG,UAAY,OAAQ,CACvBC,EAAK,KAAK,QAAQ,EAClBA,EAAK,KAAK,MAAM,EAChB,
|
|
5
|
+
"mappings": "AAIO,SAASA,EAAaC,EAAK,CAC9B,OAAOA,EAAI,MAASA,EAAI,cAAgBA,EAAI,aAAa,GAAMC,EAAaD,EAAI,MAAM,CAC1F,CAKO,SAASC,EAAaC,EAAI,CAC7B,IAAMC,EAAO,CAAC,EACd,KAAOD,GAAI,CAQP,GAPIA,EAAG,aACCA,EAAG,WAAW,eACdC,EAAK,KAAKD,EAAG,WAAW,aAAa,EAEzCC,EAAK,KAAKD,EAAG,UAAU,GAE3BC,EAAK,KAAKD,CAAE,EACRA,EAAG,UAAY,OAAQ,CACvBC,EAAK,KAAK,QAAQ,EAClBA,EAAK,KAAK,MAAM,EAChB,MAEJD,EAAKA,EAAG,cAEZ,OAAOC,CACX",
|
|
6
6
|
"names": ["getEventPath", "evt", "composedPath", "el", "path"]
|
|
7
7
|
}
|