@tylertech/forge 3.0.0-next.5 → 3.0.0-next.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (496) hide show
  1. package/custom-elements.json +3175 -1640
  2. package/dist/esm/accordion/index.js +1 -1
  3. package/dist/esm/app-bar/help-button/index.js +1 -1
  4. package/dist/esm/app-bar/index.js +1 -1
  5. package/dist/esm/app-bar/menu-button/index.js +1 -1
  6. package/dist/esm/app-bar/notification-button/index.js +1 -1
  7. package/dist/esm/app-bar/profile-button/index.js +1 -1
  8. package/dist/esm/app-bar/search/index.js +1 -1
  9. package/dist/esm/autocomplete/index.js +1 -1
  10. package/dist/esm/avatar/index.js +1 -1
  11. package/dist/esm/backdrop/index.js +1 -1
  12. package/dist/esm/badge/index.js +1 -1
  13. package/dist/esm/banner/index.js +1 -1
  14. package/dist/esm/bottom-sheet/index.js +1 -1
  15. package/dist/esm/busy-indicator/index.js +1 -1
  16. package/dist/esm/button/index.js +1 -1
  17. package/dist/esm/button-toggle/button-toggle/index.js +1 -1
  18. package/dist/esm/button-toggle/button-toggle-group/index.js +1 -1
  19. package/dist/esm/button-toggle/index.js +1 -1
  20. package/dist/esm/calendar/calendar-dropdown/index.js +1 -1
  21. package/dist/esm/calendar/calendar-menu/index.js +1 -1
  22. package/dist/esm/calendar/index.js +1 -1
  23. package/dist/esm/card/index.js +1 -1
  24. package/dist/esm/checkbox/index.js +1 -1
  25. package/dist/esm/chip-field/index.js +1 -1
  26. package/dist/esm/chips/chip/index.js +1 -1
  27. package/dist/esm/chips/chip-set/index.js +1 -1
  28. package/dist/esm/chips/index.js +1 -1
  29. package/dist/esm/chunks/{chunk.UEN7B7Q4.js → chunk.246JM2YT.js} +2 -2
  30. package/dist/esm/chunks/{chunk.64F24XMH.js → chunk.24L5GDD2.js} +2 -2
  31. package/dist/esm/chunks/{chunk.IGOGRMRW.js → chunk.2CTK5R37.js} +2 -2
  32. package/dist/esm/chunks/chunk.2IQGDFQS.js +7 -0
  33. package/dist/esm/chunks/{chunk.U4CFRHOW.js.map → chunk.2IQGDFQS.js.map} +1 -1
  34. package/dist/esm/chunks/{chunk.ZXPAXZCF.js → chunk.2LRDPTHK.js} +2 -2
  35. package/dist/esm/chunks/{chunk.HSXUQFHK.js → chunk.2QFIMTVP.js} +2 -2
  36. package/dist/esm/chunks/{chunk.SCP23NBN.js → chunk.2QSDH3PC.js} +2 -2
  37. package/dist/esm/chunks/{chunk.KWD5EK54.js → chunk.2TQONIPK.js} +2 -2
  38. package/dist/esm/chunks/{chunk.SSJYPH4U.js → chunk.2XFVFZ3P.js} +2 -2
  39. package/dist/esm/chunks/{chunk.BPEGGZOR.js → chunk.2YAU7AXH.js} +2 -2
  40. package/dist/esm/chunks/{chunk.KI5FPZOX.js → chunk.2YX7ASSX.js} +2 -2
  41. package/dist/esm/chunks/{chunk.Y4OET6II.js → chunk.2ZTERGYF.js} +2 -2
  42. package/dist/esm/chunks/{chunk.3OT44DTM.js → chunk.3CBVRCKM.js} +2 -2
  43. package/dist/esm/chunks/{chunk.7BNQYL2F.js → chunk.4EB5NVCK.js} +2 -2
  44. package/dist/esm/chunks/{chunk.4NV7AHF2.js → chunk.4LVS2EYJ.js} +2 -2
  45. package/dist/esm/chunks/{chunk.LQQIN7JE.js → chunk.57IVD67K.js} +2 -2
  46. package/dist/esm/chunks/{chunk.RXBGYGVH.js → chunk.5CMQ7DNL.js} +2 -2
  47. package/dist/esm/chunks/chunk.5IVB5L5Z.js +7 -0
  48. package/dist/esm/chunks/{chunk.FZ43DC2H.js.map → chunk.5IVB5L5Z.js.map} +1 -1
  49. package/dist/esm/chunks/{chunk.MT3CYR5E.js → chunk.5M6Y2RU6.js} +2 -2
  50. package/dist/esm/chunks/{chunk.E5H7OQXZ.js → chunk.5PHLKON3.js} +2 -2
  51. package/dist/esm/chunks/chunk.5V5ABSHI.js +7 -0
  52. package/dist/esm/chunks/{chunk.TKDMM2ZZ.js.map → chunk.5V5ABSHI.js.map} +1 -1
  53. package/dist/esm/chunks/{chunk.A6RLV2QU.js → chunk.632OMHHN.js} +2 -2
  54. package/dist/esm/chunks/{chunk.PNDQ3LAB.js → chunk.6SBTLXLH.js} +2 -2
  55. package/dist/esm/chunks/chunk.7G72CBOJ.js +7 -0
  56. package/dist/esm/chunks/{chunk.FHW6LV4A.js.map → chunk.7G72CBOJ.js.map} +1 -1
  57. package/dist/esm/chunks/{chunk.KTPSDP4C.js → chunk.7JQHQKXN.js} +2 -2
  58. package/dist/esm/chunks/{chunk.BTTHTLD3.js → chunk.7WVTJIVR.js} +2 -2
  59. package/dist/esm/chunks/{chunk.PKZYVWEG.js → chunk.7ZQMJLHE.js} +2 -2
  60. package/dist/esm/chunks/{chunk.A5D7XSBD.js → chunk.A5MBSCSQ.js} +2 -2
  61. package/dist/esm/chunks/{chunk.7UN5EYUE.js → chunk.A5R7KUIP.js} +2 -2
  62. package/dist/esm/chunks/{chunk.XARGY3WT.js → chunk.AGMPIMJV.js} +2 -2
  63. package/dist/esm/chunks/{chunk.3W2ERIMT.js → chunk.BKCEVPKW.js} +2 -2
  64. package/dist/esm/chunks/{chunk.X63F5NVD.js → chunk.BSTIDYQJ.js} +2 -2
  65. package/dist/esm/chunks/{chunk.UUUF27IU.js → chunk.BWZKQ6WX.js} +2 -2
  66. package/dist/esm/chunks/{chunk.XBW6KSW3.js → chunk.CNQESSA3.js} +2 -2
  67. package/dist/esm/chunks/{chunk.55FCNVG5.js → chunk.DTZFWZPB.js} +2 -2
  68. package/dist/esm/chunks/{chunk.R4B7JSSA.js → chunk.E6KWYFZG.js} +2 -2
  69. package/dist/esm/chunks/{chunk.XGWGJFWC.js → chunk.E7Z3IRWV.js} +2 -2
  70. package/dist/esm/chunks/{chunk.NSTCCETU.js → chunk.ECRL6O3V.js} +2 -2
  71. package/dist/esm/chunks/{chunk.W6MDMZTN.js → chunk.EDEYCLDU.js} +2 -2
  72. package/dist/esm/chunks/{chunk.P6ZUHPI6.js → chunk.ER52NFXX.js} +2 -2
  73. package/dist/esm/chunks/{chunk.AY46N5Y7.js → chunk.EUE3OVC7.js} +2 -2
  74. package/dist/esm/chunks/{chunk.RMPS2I2P.js → chunk.EYZ25QUP.js} +2 -2
  75. package/dist/esm/chunks/{chunk.VJ2SSV5X.js → chunk.FAANPQES.js} +2 -2
  76. package/dist/esm/chunks/{chunk.MZLPUI6R.js → chunk.FYWPZFLJ.js} +2 -2
  77. package/dist/esm/chunks/{chunk.MZLPUI6R.js.map → chunk.FYWPZFLJ.js.map} +2 -2
  78. package/dist/esm/chunks/{chunk.DX32NTD3.js → chunk.GF2GUVYS.js} +2 -2
  79. package/dist/esm/chunks/chunk.GHSAKRYH.js +7 -0
  80. package/dist/esm/chunks/{chunk.2TVYAW7Q.js.map → chunk.GHSAKRYH.js.map} +1 -1
  81. package/dist/esm/chunks/chunk.GJW4WS4I.js +7 -0
  82. package/dist/esm/chunks/{chunk.P4TIMZKU.js → chunk.GUYPITGA.js} +2 -2
  83. package/dist/esm/chunks/chunk.GWIVOPRO.js +7 -0
  84. package/dist/esm/chunks/chunk.GWIVOPRO.js.map +7 -0
  85. package/dist/esm/chunks/{chunk.T64UW37U.js → chunk.H5D54EHO.js} +2 -2
  86. package/dist/esm/chunks/{chunk.FPMQAUL3.js → chunk.HKJEGD6C.js} +2 -2
  87. package/dist/esm/chunks/chunk.HRGTAVNA.js +7 -0
  88. package/dist/esm/chunks/{chunk.UZENE2NC.js.map → chunk.HRGTAVNA.js.map} +2 -2
  89. package/dist/esm/chunks/{chunk.7KEUUHXY.js → chunk.IDD54B5P.js} +2 -2
  90. package/dist/esm/chunks/chunk.IGK3VYZG.js +7 -0
  91. package/dist/esm/chunks/chunk.IGK3VYZG.js.map +7 -0
  92. package/dist/esm/chunks/{chunk.H4H75YUA.js → chunk.IWA3CYIB.js} +2 -2
  93. package/dist/esm/chunks/chunk.JHXNEHWR.js +12 -0
  94. package/dist/esm/chunks/{chunk.ZOV2BUZG.js → chunk.JVW6JGV3.js} +2 -2
  95. package/dist/esm/chunks/chunk.MF36FG2X.js +7 -0
  96. package/dist/esm/chunks/{chunk.LSFIZAUF.js.map → chunk.MF36FG2X.js.map} +1 -1
  97. package/dist/esm/chunks/{chunk.P64BBB3U.js → chunk.MXNLCQRB.js} +2 -2
  98. package/dist/esm/chunks/chunk.NK7H3MMM.js +7 -0
  99. package/dist/esm/chunks/{chunk.QH2GB3PD.js.map → chunk.NK7H3MMM.js.map} +2 -2
  100. package/dist/esm/chunks/chunk.NVMILGC2.js +7 -0
  101. package/dist/esm/chunks/{chunk.WDTA5G7R.js.map → chunk.NVMILGC2.js.map} +3 -3
  102. package/dist/esm/chunks/chunk.OHNPVHPF.js +7 -0
  103. package/dist/esm/chunks/chunk.OHNPVHPF.js.map +7 -0
  104. package/dist/esm/chunks/chunk.OT6H5NHX.js +7 -0
  105. package/dist/esm/chunks/chunk.OTVT3XM2.js +7 -0
  106. package/dist/esm/chunks/{chunk.4ZWV37ZJ.js → chunk.P5QIB6OY.js} +2 -2
  107. package/dist/esm/chunks/{chunk.ZB54OC26.js → chunk.PHBOQRF6.js} +2 -2
  108. package/dist/esm/chunks/{chunk.YTOYNJMD.js → chunk.PHTOULRR.js} +2 -2
  109. package/dist/esm/chunks/chunk.PPPTT3SM.js +7 -0
  110. package/dist/esm/chunks/{chunk.C4YKXXKM.js.map → chunk.PPPTT3SM.js.map} +1 -1
  111. package/dist/esm/chunks/{chunk.VMQZA47V.js → chunk.QA3NU7EN.js} +2 -2
  112. package/dist/esm/chunks/chunk.QYKO543K.js +7 -0
  113. package/dist/esm/chunks/{chunk.RHPJRCIC.js.map → chunk.QYKO543K.js.map} +1 -1
  114. package/dist/esm/chunks/{chunk.7VWG4IEN.js → chunk.QZK3WEH6.js} +2 -2
  115. package/dist/esm/chunks/{chunk.GFWFEBAH.js → chunk.RGPNNISQ.js} +2 -2
  116. package/dist/esm/chunks/chunk.RHYRMQS7.js +7 -0
  117. package/dist/esm/chunks/chunk.RHYRMQS7.js.map +7 -0
  118. package/dist/esm/chunks/{chunk.EUNKM7XR.js → chunk.RUSHOL23.js} +2 -2
  119. package/dist/esm/chunks/chunk.SIJGKRYS.js +7 -0
  120. package/dist/esm/chunks/{chunk.TFMOLR6W.js.map → chunk.SIJGKRYS.js.map} +1 -1
  121. package/dist/esm/chunks/{chunk.EWEX3PHR.js → chunk.STGRPD2L.js} +2 -2
  122. package/dist/esm/chunks/{chunk.EWEX3PHR.js.map → chunk.STGRPD2L.js.map} +1 -1
  123. package/dist/esm/chunks/chunk.SYZB7B4F.js +7 -0
  124. package/dist/esm/chunks/chunk.SYZB7B4F.js.map +7 -0
  125. package/dist/esm/chunks/chunk.SZIM4KFZ.js +7 -0
  126. package/dist/esm/chunks/chunk.SZIM4KFZ.js.map +7 -0
  127. package/dist/esm/chunks/{chunk.YNE75HFH.js → chunk.THPU5KBV.js} +2 -2
  128. package/dist/esm/chunks/{chunk.INRH62VL.js → chunk.TL6WVBGT.js} +2 -2
  129. package/dist/esm/chunks/{chunk.O4KZV4MX.js → chunk.TT2VTZJ6.js} +2 -2
  130. package/dist/esm/chunks/{chunk.7X7A74SI.js → chunk.TXFYS6EU.js} +2 -2
  131. package/dist/esm/chunks/{chunk.5MPUISW3.js → chunk.U4GYQOPY.js} +2 -2
  132. package/dist/esm/chunks/{chunk.I3MZQIAF.js → chunk.UCM6CGFM.js} +2 -2
  133. package/dist/esm/chunks/{chunk.SOMT6F6S.js → chunk.V4RBOYNH.js} +2 -2
  134. package/dist/esm/chunks/{chunk.2R72ZTIK.js → chunk.V6JVHYVW.js} +2 -2
  135. package/dist/esm/chunks/{chunk.UROMKMFI.js → chunk.WBYXVMYI.js} +2 -2
  136. package/dist/esm/chunks/chunk.WFDIA7R6.js +7 -0
  137. package/dist/esm/chunks/chunk.WFDIA7R6.js.map +7 -0
  138. package/dist/esm/chunks/{chunk.QUJL4A23.js → chunk.WO7KEM5K.js} +2 -2
  139. package/dist/esm/chunks/{chunk.HVYK2OWE.js → chunk.WYP2M5FR.js} +2 -2
  140. package/dist/esm/chunks/{chunk.NEMJIVPU.js → chunk.X3YNJSDT.js} +2 -2
  141. package/dist/esm/chunks/{chunk.WQL55O4A.js → chunk.XMFQFFKR.js} +2 -2
  142. package/dist/esm/chunks/{chunk.46LZNRRP.js → chunk.Y5UJ23LB.js} +2 -2
  143. package/dist/esm/chunks/{chunk.S5EJVD5E.js → chunk.YQXX5KSW.js} +2 -2
  144. package/dist/esm/chunks/{chunk.RVUMHJMM.js → chunk.YUAU5IWT.js} +2 -2
  145. package/dist/esm/chunks/{chunk.YSFUL5AD.js → chunk.YZLASVCK.js} +2 -2
  146. package/dist/esm/chunks/{chunk.ELY4YCON.js → chunk.Z5TWWM7I.js} +2 -2
  147. package/dist/esm/chunks/{chunk.RPKVFFQ6.js → chunk.ZIB7L7DZ.js} +2 -2
  148. package/dist/esm/circular-progress/index.js +1 -1
  149. package/dist/esm/color-picker/index.js +1 -1
  150. package/dist/esm/core/base/index.js +1 -1
  151. package/dist/esm/core/index.js +1 -1
  152. package/dist/esm/core/utils/index.js +1 -1
  153. package/dist/esm/date-picker/index.js +1 -1
  154. package/dist/esm/date-range-picker/index.js +1 -1
  155. package/dist/esm/dialog/index.js +1 -1
  156. package/dist/esm/divider/index.js +1 -1
  157. package/dist/esm/drawer/base/index.js +1 -1
  158. package/dist/esm/drawer/drawer/index.js +1 -1
  159. package/dist/esm/drawer/index.js +1 -1
  160. package/dist/esm/drawer/mini-drawer/index.js +1 -1
  161. package/dist/esm/drawer/modal-drawer/index.js +1 -1
  162. package/dist/esm/expansion-panel/index.js +1 -1
  163. package/dist/esm/file-picker/index.js +1 -1
  164. package/dist/esm/floating-action-button/index.js +1 -1
  165. package/dist/esm/icon/index.js +1 -1
  166. package/dist/esm/icon-button/index.js +1 -1
  167. package/dist/esm/index.js +1 -1
  168. package/dist/esm/inline-message/index.js +1 -1
  169. package/dist/esm/keyboard-shortcut/index.js +1 -1
  170. package/dist/esm/label-value/index.js +1 -1
  171. package/dist/esm/linear-progress/index.js +1 -1
  172. package/dist/esm/list/index.js +1 -1
  173. package/dist/esm/list/list/index.js +1 -1
  174. package/dist/esm/list/list-item/index.js +1 -1
  175. package/dist/esm/list-dropdown/index.js +1 -1
  176. package/dist/esm/menu/index.js +1 -1
  177. package/dist/esm/open-icon/index.js +1 -1
  178. package/dist/esm/page-state/index.js +1 -1
  179. package/dist/esm/paginator/index.js +1 -1
  180. package/dist/esm/popup/index.js +1 -1
  181. package/dist/esm/product-icon/index.js +1 -1
  182. package/dist/esm/profile-card/index.js +1 -1
  183. package/dist/esm/quantity-field/index.js +1 -1
  184. package/dist/esm/radio/index.js +1 -1
  185. package/dist/esm/ripple/index.js +1 -1
  186. package/dist/esm/scaffold/index.js +1 -1
  187. package/dist/esm/select/core/index.js +1 -1
  188. package/dist/esm/select/index.js +1 -1
  189. package/dist/esm/select/option/index.js +1 -1
  190. package/dist/esm/select/option-group/index.js +1 -1
  191. package/dist/esm/select/select/index.js +1 -1
  192. package/dist/esm/select/select-dropdown/index.js +1 -1
  193. package/dist/esm/skeleton/index.js +1 -1
  194. package/dist/esm/slider/index.js +1 -1
  195. package/dist/esm/split-view/index.js +1 -1
  196. package/dist/esm/split-view/split-view/index.js +1 -1
  197. package/dist/esm/split-view/split-view-panel/index.js +1 -1
  198. package/dist/esm/stack/index.js +1 -1
  199. package/dist/esm/stepper/index.js +1 -1
  200. package/dist/esm/stepper/step/index.js +1 -1
  201. package/dist/esm/stepper/stepper/index.js +1 -1
  202. package/dist/esm/switch/index.js +1 -1
  203. package/dist/esm/table/index.js +1 -1
  204. package/dist/esm/tabs/index.js +1 -1
  205. package/dist/esm/tabs/tab/index.js +1 -1
  206. package/dist/esm/tabs/tab-bar/index.js +1 -1
  207. package/dist/esm/text-field/index.js +1 -1
  208. package/dist/esm/time-picker/index.js +1 -1
  209. package/dist/esm/toast/index.js +1 -1
  210. package/dist/esm/toolbar/index.js +1 -1
  211. package/dist/esm/tooltip/index.js +1 -1
  212. package/dist/esm/utils/index.js +1 -1
  213. package/dist/esm/view-switcher/index.js +1 -1
  214. package/dist/esm/view-switcher/view/index.js +1 -1
  215. package/esm/accordion/accordion.js +4 -4
  216. package/esm/app-bar/app-bar.js +5 -5
  217. package/esm/app-bar/notification-button/app-bar-notification-button.js +5 -5
  218. package/esm/app-bar/profile-button/app-bar-profile-button-constants.d.ts +1 -1
  219. package/esm/app-bar/profile-button/app-bar-profile-button.js +4 -4
  220. package/esm/app-bar/search/app-bar-search.js +6 -6
  221. package/esm/autocomplete/autocomplete-adapter.d.ts +0 -2
  222. package/esm/autocomplete/autocomplete-adapter.js +0 -4
  223. package/esm/autocomplete/autocomplete-component-delegate.d.ts +1 -1
  224. package/esm/autocomplete/autocomplete-constants.d.ts +4 -4
  225. package/esm/autocomplete/autocomplete-foundation.js +0 -11
  226. package/esm/autocomplete/autocomplete.js +6 -6
  227. package/esm/avatar/avatar-component-delegate.d.ts +1 -1
  228. package/esm/avatar/avatar.js +5 -5
  229. package/esm/backdrop/backdrop-constants.d.ts +1 -1
  230. package/esm/backdrop/backdrop.js +5 -5
  231. package/esm/badge/badge-component-delegate.d.ts +1 -1
  232. package/esm/badge/badge.js +5 -5
  233. package/esm/banner/banner.js +6 -6
  234. package/esm/bottom-sheet/bottom-sheet.js +5 -5
  235. package/esm/busy-indicator/busy-indicator-constants.d.ts +1 -1
  236. package/esm/busy-indicator/busy-indicator.js +5 -5
  237. package/esm/button/button-component-delegate.d.ts +1 -1
  238. package/esm/button/button.js +3 -3
  239. package/esm/button-toggle/button-toggle/button-toggle.js +6 -6
  240. package/esm/button-toggle/button-toggle-group/button-toggle-group-constants.d.ts +2 -2
  241. package/esm/button-toggle/button-toggle-group/button-toggle-group.js +5 -5
  242. package/esm/calendar/calendar-component-delegate.d.ts +1 -1
  243. package/esm/calendar/calendar-constants.d.ts +10 -10
  244. package/esm/calendar/calendar-dropdown/calendar-dropdown.js +5 -5
  245. package/esm/calendar/calendar-menu/calendar-menu-constants.d.ts +2 -2
  246. package/esm/calendar/calendar-menu/calendar-menu.js +5 -5
  247. package/esm/calendar/calendar.js +6 -6
  248. package/esm/card/card.js +5 -5
  249. package/esm/checkbox/checkbox-component-delegate.d.ts +1 -1
  250. package/esm/checkbox/checkbox.js +3 -3
  251. package/esm/chip-field/chip-field-component-delegate.d.ts +1 -1
  252. package/esm/chips/chip/chip.js +6 -6
  253. package/esm/chips/chip-set/chip-set.js +5 -5
  254. package/esm/circular-progress/circular-progress.js +5 -5
  255. package/esm/color-picker/color-picker-constants.d.ts +2 -2
  256. package/esm/color-picker/color-picker.js +6 -6
  257. package/esm/core/delegates/base-component-delegate.d.ts +1 -1
  258. package/esm/core/delegates/base-component-delegate.js +3 -3
  259. package/esm/core/delegates/form-field-component-delegate.d.ts +1 -1
  260. package/esm/core/mask/time-segment-parser.d.ts +1 -1
  261. package/esm/core/utils/utils.d.ts +17 -0
  262. package/esm/core/utils/utils.js +27 -0
  263. package/esm/date-picker/date-picker-component-delegate.d.ts +1 -1
  264. package/esm/date-range-picker/date-range-picker-component-delegate.d.ts +1 -1
  265. package/esm/dialog/dialog-constants.d.ts +2 -2
  266. package/esm/dialog/dialog.js +5 -5
  267. package/esm/drawer/base/base-drawer-constants.d.ts +1 -1
  268. package/esm/expansion-panel/expansion-panel.js +5 -5
  269. package/esm/field/field-constants.d.ts +3 -3
  270. package/esm/field/field.js +3 -3
  271. package/esm/file-picker/file-picker-component-delegate.d.ts +1 -1
  272. package/esm/file-picker/file-picker.js +5 -5
  273. package/esm/floating-action-button/floating-action-button-component-delegate.d.ts +1 -1
  274. package/esm/floating-action-button/floating-action-button.js +6 -6
  275. package/esm/icon/icon.js +5 -5
  276. package/esm/icon-button/icon-button-component-delegate.d.ts +1 -1
  277. package/esm/icon-button/icon-button.js +7 -7
  278. package/esm/keyboard-shortcut/keyboard-shortcut.js +4 -4
  279. package/esm/label-value/label-value-component-delegate.d.ts +1 -1
  280. package/esm/label-value/label-value-constants.d.ts +1 -1
  281. package/esm/label-value/label-value.js +5 -5
  282. package/esm/linear-progress/linear-progress.js +5 -5
  283. package/esm/list/list/list.js +5 -5
  284. package/esm/list/list-item/list-item.js +5 -5
  285. package/esm/list-dropdown/list-dropdown-adapter.js +1 -1
  286. package/esm/list-dropdown/list-dropdown-constants.d.ts +6 -6
  287. package/esm/list-dropdown/list-dropdown-utils.d.ts +1 -1
  288. package/esm/list-dropdown/list-dropdown-utils.js +7 -4
  289. package/esm/menu/menu-constants.d.ts +3 -3
  290. package/esm/menu/menu.js +6 -6
  291. package/esm/open-icon/open-icon.js +6 -6
  292. package/esm/paginator/paginator-constants.d.ts +1 -1
  293. package/esm/paginator/paginator-foundation.js +2 -0
  294. package/esm/paginator/paginator.js +11 -11
  295. package/esm/popup/popup-constants.d.ts +2 -2
  296. package/esm/popup/popup.js +5 -5
  297. package/esm/product-icon/product-icon.js +5 -5
  298. package/esm/profile-card/profile-card.js +5 -5
  299. package/esm/quantity-field/quantity-field-component-delegate.d.ts +1 -1
  300. package/esm/quantity-field/quantity-field.js +6 -6
  301. package/esm/radio/radio.js +5 -5
  302. package/esm/ripple/forge-ripple.d.ts +2 -0
  303. package/esm/ripple/forge-ripple.js +4 -0
  304. package/esm/ripple/ripple.js +4 -4
  305. package/esm/select/core/base-select-constants.d.ts +4 -4
  306. package/esm/select/option/option.js +4 -4
  307. package/esm/select/option-group/option-group.js +3 -3
  308. package/esm/select/select/select-adapter.d.ts +1 -1
  309. package/esm/select/select-component-delegate.d.ts +1 -1
  310. package/esm/slider/slider-adapter.d.ts +95 -0
  311. package/esm/slider/slider-adapter.js +238 -0
  312. package/esm/slider/slider-component-delegate.d.ts +19 -3
  313. package/esm/slider/slider-component-delegate.js +48 -0
  314. package/esm/slider/slider-constants.d.ts +58 -19
  315. package/esm/slider/slider-constants.js +59 -14
  316. package/esm/slider/slider-foundation.d.ts +95 -0
  317. package/esm/slider/slider-foundation.js +319 -0
  318. package/esm/slider/slider-handle-ripple.d.ts +18 -0
  319. package/esm/slider/slider-handle-ripple.js +37 -0
  320. package/esm/slider/slider-utils.d.ts +9 -0
  321. package/esm/slider/slider-utils.js +53 -0
  322. package/esm/slider/slider.d.ts +135 -65
  323. package/esm/slider/slider.js +235 -246
  324. package/esm/split-view/split-view/split-view-constants.d.ts +1 -1
  325. package/esm/split-view/split-view/split-view.js +5 -5
  326. package/esm/split-view/split-view-panel/split-view-panel-constants.d.ts +2 -2
  327. package/esm/split-view/split-view-panel/split-view-panel-foundation.js +18 -18
  328. package/esm/split-view/split-view-panel/split-view-panel.js +7 -7
  329. package/esm/stack/stack-constants.d.ts +1 -1
  330. package/esm/stack/stack.js +5 -5
  331. package/esm/stepper/step/step-constants.d.ts +1 -1
  332. package/esm/stepper/step/step.js +12 -12
  333. package/esm/stepper/stepper/stepper-constants.d.ts +2 -2
  334. package/esm/stepper/stepper/stepper.js +5 -5
  335. package/esm/switch/switch-component-delegate.d.ts +1 -1
  336. package/esm/switch/switch-constants.d.ts +1 -1
  337. package/esm/switch/switch.js +9 -9
  338. package/esm/table/table.js +5 -5
  339. package/esm/table/types.d.ts +4 -4
  340. package/esm/tabs/tab/tab-adapter.d.ts +14 -38
  341. package/esm/tabs/tab/tab-adapter.js +65 -78
  342. package/esm/tabs/tab/tab-constants.d.ts +13 -13
  343. package/esm/tabs/tab/tab-constants.js +18 -10
  344. package/esm/tabs/tab/tab-foundation.d.ts +24 -23
  345. package/esm/tabs/tab/tab-foundation.js +68 -62
  346. package/esm/tabs/tab/tab-ripple.d.ts +17 -0
  347. package/esm/tabs/tab/tab-ripple.js +33 -0
  348. package/esm/tabs/tab/tab.d.ts +56 -19
  349. package/esm/tabs/tab/tab.js +82 -36
  350. package/esm/tabs/tab-bar/tab-bar-adapter.d.ts +49 -87
  351. package/esm/tabs/tab-bar/tab-bar-adapter.js +114 -188
  352. package/esm/tabs/tab-bar/tab-bar-constants.d.ts +15 -45
  353. package/esm/tabs/tab-bar/tab-bar-constants.js +22 -56
  354. package/esm/tabs/tab-bar/tab-bar-foundation.d.ts +56 -65
  355. package/esm/tabs/tab-bar/tab-bar-foundation.js +241 -302
  356. package/esm/tabs/tab-bar/tab-bar.d.ts +51 -36
  357. package/esm/tabs/tab-bar/tab-bar.js +89 -57
  358. package/esm/text-field/text-field-component-delegate.d.ts +1 -1
  359. package/esm/theme/theme-utils.d.ts +2 -2
  360. package/esm/time-picker/time-picker-component-delegate.d.ts +1 -1
  361. package/esm/time-picker/time-picker-constants.d.ts +6 -6
  362. package/esm/time-picker/time-picker.js +6 -6
  363. package/esm/toast/toast-constants.d.ts +2 -2
  364. package/esm/toast/toast.js +6 -6
  365. package/esm/toolbar/toolbar.js +5 -5
  366. package/esm/tooltip/tooltip-constants.d.ts +1 -1
  367. package/esm/tooltip/tooltip.js +4 -4
  368. package/esm/utils/color-utils.js +1 -0
  369. package/esm/view-switcher/view-switcher.js +5 -5
  370. package/package.json +1 -1
  371. package/styles/core/style-layer/slider/_core.scss +550 -0
  372. package/styles/core/style-layer/slider/_functions.scss +33 -0
  373. package/styles/core/style-layer/slider/_variables.scss +17 -0
  374. package/styles/core/style-layer/slider/index.scss +18 -0
  375. package/styles/core/style-layer/tabs/tab/_core.scss +419 -0
  376. package/styles/core/style-layer/tabs/tab/_variables.scss +20 -0
  377. package/styles/core/style-layer/tabs/tab/index.scss +13 -0
  378. package/styles/core/style-layer/tabs/tab-bar/_core.scss +110 -0
  379. package/styles/core/style-layer/tabs/tab-bar/_variables.scss +9 -0
  380. package/styles/core/style-layer/tabs/tab-bar/index.scss +13 -0
  381. package/styles/slider/_mixins.scss +27 -0
  382. package/styles/slider/_variables.scss +37 -0
  383. package/styles/slider/slider.scss +3 -20
  384. package/styles/tabs/tab/_mixins.scss +46 -128
  385. package/styles/tabs/tab/_variables.scss +26 -4
  386. package/styles/tabs/tab/tab.scss +50 -11
  387. package/styles/tabs/tab-bar/_mixins.scss +20 -60
  388. package/styles/tabs/tab-bar/_variables.scss +11 -0
  389. package/styles/tabs/tab-bar/tab-bar.scss +29 -2
  390. package/dist/esm/chunks/chunk.2TVYAW7Q.js +0 -7
  391. package/dist/esm/chunks/chunk.3SBF7CUU.js +0 -201
  392. package/dist/esm/chunks/chunk.3SBF7CUU.js.map +0 -7
  393. package/dist/esm/chunks/chunk.3XZRUXG7.js +0 -7
  394. package/dist/esm/chunks/chunk.7JBR7GWZ.js +0 -7
  395. package/dist/esm/chunks/chunk.ABN3DL7G.js +0 -7
  396. package/dist/esm/chunks/chunk.C4YKXXKM.js +0 -7
  397. package/dist/esm/chunks/chunk.FF5DED5D.js +0 -7
  398. package/dist/esm/chunks/chunk.FF5DED5D.js.map +0 -7
  399. package/dist/esm/chunks/chunk.FHW6LV4A.js +0 -7
  400. package/dist/esm/chunks/chunk.FZ43DC2H.js +0 -7
  401. package/dist/esm/chunks/chunk.GOZVC3ZT.js +0 -7
  402. package/dist/esm/chunks/chunk.GOZVC3ZT.js.map +0 -7
  403. package/dist/esm/chunks/chunk.IMRPJU4M.js +0 -129
  404. package/dist/esm/chunks/chunk.IMRPJU4M.js.map +0 -7
  405. package/dist/esm/chunks/chunk.JKEIP657.js +0 -7
  406. package/dist/esm/chunks/chunk.JKEIP657.js.map +0 -7
  407. package/dist/esm/chunks/chunk.LSFIZAUF.js +0 -7
  408. package/dist/esm/chunks/chunk.QH2GB3PD.js +0 -7
  409. package/dist/esm/chunks/chunk.RHPJRCIC.js +0 -7
  410. package/dist/esm/chunks/chunk.SKEI7ZSK.js +0 -153
  411. package/dist/esm/chunks/chunk.SKEI7ZSK.js.map +0 -7
  412. package/dist/esm/chunks/chunk.TFMOLR6W.js +0 -7
  413. package/dist/esm/chunks/chunk.TKDMM2ZZ.js +0 -7
  414. package/dist/esm/chunks/chunk.U4CFRHOW.js +0 -7
  415. package/dist/esm/chunks/chunk.UETV4PTS.js +0 -12
  416. package/dist/esm/chunks/chunk.UZENE2NC.js +0 -7
  417. package/dist/esm/chunks/chunk.VUGNSK4K.js +0 -7
  418. package/dist/esm/chunks/chunk.VUGNSK4K.js.map +0 -7
  419. package/dist/esm/chunks/chunk.WDTA5G7R.js +0 -7
  420. /package/dist/esm/chunks/{chunk.UEN7B7Q4.js.map → chunk.246JM2YT.js.map} +0 -0
  421. /package/dist/esm/chunks/{chunk.64F24XMH.js.map → chunk.24L5GDD2.js.map} +0 -0
  422. /package/dist/esm/chunks/{chunk.IGOGRMRW.js.map → chunk.2CTK5R37.js.map} +0 -0
  423. /package/dist/esm/chunks/{chunk.ZXPAXZCF.js.map → chunk.2LRDPTHK.js.map} +0 -0
  424. /package/dist/esm/chunks/{chunk.HSXUQFHK.js.map → chunk.2QFIMTVP.js.map} +0 -0
  425. /package/dist/esm/chunks/{chunk.SCP23NBN.js.map → chunk.2QSDH3PC.js.map} +0 -0
  426. /package/dist/esm/chunks/{chunk.KWD5EK54.js.map → chunk.2TQONIPK.js.map} +0 -0
  427. /package/dist/esm/chunks/{chunk.SSJYPH4U.js.map → chunk.2XFVFZ3P.js.map} +0 -0
  428. /package/dist/esm/chunks/{chunk.BPEGGZOR.js.map → chunk.2YAU7AXH.js.map} +0 -0
  429. /package/dist/esm/chunks/{chunk.KI5FPZOX.js.map → chunk.2YX7ASSX.js.map} +0 -0
  430. /package/dist/esm/chunks/{chunk.Y4OET6II.js.map → chunk.2ZTERGYF.js.map} +0 -0
  431. /package/dist/esm/chunks/{chunk.3OT44DTM.js.map → chunk.3CBVRCKM.js.map} +0 -0
  432. /package/dist/esm/chunks/{chunk.7BNQYL2F.js.map → chunk.4EB5NVCK.js.map} +0 -0
  433. /package/dist/esm/chunks/{chunk.4NV7AHF2.js.map → chunk.4LVS2EYJ.js.map} +0 -0
  434. /package/dist/esm/chunks/{chunk.LQQIN7JE.js.map → chunk.57IVD67K.js.map} +0 -0
  435. /package/dist/esm/chunks/{chunk.RXBGYGVH.js.map → chunk.5CMQ7DNL.js.map} +0 -0
  436. /package/dist/esm/chunks/{chunk.MT3CYR5E.js.map → chunk.5M6Y2RU6.js.map} +0 -0
  437. /package/dist/esm/chunks/{chunk.E5H7OQXZ.js.map → chunk.5PHLKON3.js.map} +0 -0
  438. /package/dist/esm/chunks/{chunk.A6RLV2QU.js.map → chunk.632OMHHN.js.map} +0 -0
  439. /package/dist/esm/chunks/{chunk.PNDQ3LAB.js.map → chunk.6SBTLXLH.js.map} +0 -0
  440. /package/dist/esm/chunks/{chunk.KTPSDP4C.js.map → chunk.7JQHQKXN.js.map} +0 -0
  441. /package/dist/esm/chunks/{chunk.BTTHTLD3.js.map → chunk.7WVTJIVR.js.map} +0 -0
  442. /package/dist/esm/chunks/{chunk.PKZYVWEG.js.map → chunk.7ZQMJLHE.js.map} +0 -0
  443. /package/dist/esm/chunks/{chunk.A5D7XSBD.js.map → chunk.A5MBSCSQ.js.map} +0 -0
  444. /package/dist/esm/chunks/{chunk.7UN5EYUE.js.map → chunk.A5R7KUIP.js.map} +0 -0
  445. /package/dist/esm/chunks/{chunk.XARGY3WT.js.map → chunk.AGMPIMJV.js.map} +0 -0
  446. /package/dist/esm/chunks/{chunk.3W2ERIMT.js.map → chunk.BKCEVPKW.js.map} +0 -0
  447. /package/dist/esm/chunks/{chunk.X63F5NVD.js.map → chunk.BSTIDYQJ.js.map} +0 -0
  448. /package/dist/esm/chunks/{chunk.UUUF27IU.js.map → chunk.BWZKQ6WX.js.map} +0 -0
  449. /package/dist/esm/chunks/{chunk.XBW6KSW3.js.map → chunk.CNQESSA3.js.map} +0 -0
  450. /package/dist/esm/chunks/{chunk.55FCNVG5.js.map → chunk.DTZFWZPB.js.map} +0 -0
  451. /package/dist/esm/chunks/{chunk.R4B7JSSA.js.map → chunk.E6KWYFZG.js.map} +0 -0
  452. /package/dist/esm/chunks/{chunk.XGWGJFWC.js.map → chunk.E7Z3IRWV.js.map} +0 -0
  453. /package/dist/esm/chunks/{chunk.NSTCCETU.js.map → chunk.ECRL6O3V.js.map} +0 -0
  454. /package/dist/esm/chunks/{chunk.W6MDMZTN.js.map → chunk.EDEYCLDU.js.map} +0 -0
  455. /package/dist/esm/chunks/{chunk.P6ZUHPI6.js.map → chunk.ER52NFXX.js.map} +0 -0
  456. /package/dist/esm/chunks/{chunk.AY46N5Y7.js.map → chunk.EUE3OVC7.js.map} +0 -0
  457. /package/dist/esm/chunks/{chunk.RMPS2I2P.js.map → chunk.EYZ25QUP.js.map} +0 -0
  458. /package/dist/esm/chunks/{chunk.VJ2SSV5X.js.map → chunk.FAANPQES.js.map} +0 -0
  459. /package/dist/esm/chunks/{chunk.DX32NTD3.js.map → chunk.GF2GUVYS.js.map} +0 -0
  460. /package/dist/esm/chunks/{chunk.ABN3DL7G.js.map → chunk.GJW4WS4I.js.map} +0 -0
  461. /package/dist/esm/chunks/{chunk.P4TIMZKU.js.map → chunk.GUYPITGA.js.map} +0 -0
  462. /package/dist/esm/chunks/{chunk.T64UW37U.js.map → chunk.H5D54EHO.js.map} +0 -0
  463. /package/dist/esm/chunks/{chunk.FPMQAUL3.js.map → chunk.HKJEGD6C.js.map} +0 -0
  464. /package/dist/esm/chunks/{chunk.7KEUUHXY.js.map → chunk.IDD54B5P.js.map} +0 -0
  465. /package/dist/esm/chunks/{chunk.H4H75YUA.js.map → chunk.IWA3CYIB.js.map} +0 -0
  466. /package/dist/esm/chunks/{chunk.UETV4PTS.js.map → chunk.JHXNEHWR.js.map} +0 -0
  467. /package/dist/esm/chunks/{chunk.ZOV2BUZG.js.map → chunk.JVW6JGV3.js.map} +0 -0
  468. /package/dist/esm/chunks/{chunk.P64BBB3U.js.map → chunk.MXNLCQRB.js.map} +0 -0
  469. /package/dist/esm/chunks/{chunk.3XZRUXG7.js.map → chunk.OT6H5NHX.js.map} +0 -0
  470. /package/dist/esm/chunks/{chunk.7JBR7GWZ.js.map → chunk.OTVT3XM2.js.map} +0 -0
  471. /package/dist/esm/chunks/{chunk.4ZWV37ZJ.js.map → chunk.P5QIB6OY.js.map} +0 -0
  472. /package/dist/esm/chunks/{chunk.ZB54OC26.js.map → chunk.PHBOQRF6.js.map} +0 -0
  473. /package/dist/esm/chunks/{chunk.YTOYNJMD.js.map → chunk.PHTOULRR.js.map} +0 -0
  474. /package/dist/esm/chunks/{chunk.VMQZA47V.js.map → chunk.QA3NU7EN.js.map} +0 -0
  475. /package/dist/esm/chunks/{chunk.7VWG4IEN.js.map → chunk.QZK3WEH6.js.map} +0 -0
  476. /package/dist/esm/chunks/{chunk.GFWFEBAH.js.map → chunk.RGPNNISQ.js.map} +0 -0
  477. /package/dist/esm/chunks/{chunk.EUNKM7XR.js.map → chunk.RUSHOL23.js.map} +0 -0
  478. /package/dist/esm/chunks/{chunk.YNE75HFH.js.map → chunk.THPU5KBV.js.map} +0 -0
  479. /package/dist/esm/chunks/{chunk.INRH62VL.js.map → chunk.TL6WVBGT.js.map} +0 -0
  480. /package/dist/esm/chunks/{chunk.O4KZV4MX.js.map → chunk.TT2VTZJ6.js.map} +0 -0
  481. /package/dist/esm/chunks/{chunk.7X7A74SI.js.map → chunk.TXFYS6EU.js.map} +0 -0
  482. /package/dist/esm/chunks/{chunk.5MPUISW3.js.map → chunk.U4GYQOPY.js.map} +0 -0
  483. /package/dist/esm/chunks/{chunk.I3MZQIAF.js.map → chunk.UCM6CGFM.js.map} +0 -0
  484. /package/dist/esm/chunks/{chunk.SOMT6F6S.js.map → chunk.V4RBOYNH.js.map} +0 -0
  485. /package/dist/esm/chunks/{chunk.2R72ZTIK.js.map → chunk.V6JVHYVW.js.map} +0 -0
  486. /package/dist/esm/chunks/{chunk.UROMKMFI.js.map → chunk.WBYXVMYI.js.map} +0 -0
  487. /package/dist/esm/chunks/{chunk.QUJL4A23.js.map → chunk.WO7KEM5K.js.map} +0 -0
  488. /package/dist/esm/chunks/{chunk.HVYK2OWE.js.map → chunk.WYP2M5FR.js.map} +0 -0
  489. /package/dist/esm/chunks/{chunk.NEMJIVPU.js.map → chunk.X3YNJSDT.js.map} +0 -0
  490. /package/dist/esm/chunks/{chunk.WQL55O4A.js.map → chunk.XMFQFFKR.js.map} +0 -0
  491. /package/dist/esm/chunks/{chunk.46LZNRRP.js.map → chunk.Y5UJ23LB.js.map} +0 -0
  492. /package/dist/esm/chunks/{chunk.S5EJVD5E.js.map → chunk.YQXX5KSW.js.map} +0 -0
  493. /package/dist/esm/chunks/{chunk.RVUMHJMM.js.map → chunk.YUAU5IWT.js.map} +0 -0
  494. /package/dist/esm/chunks/{chunk.YSFUL5AD.js.map → chunk.YZLASVCK.js.map} +0 -0
  495. /package/dist/esm/chunks/{chunk.ELY4YCON.js.map → chunk.Z5TWWM7I.js.map} +0 -0
  496. /package/dist/esm/chunks/{chunk.RPKVFFQ6.js.map → chunk.ZIB7L7DZ.js.map} +0 -0
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/split-view/split-view-panel/split-view-panel-constants.ts", "../../src/split-view/split-view-panel/split-view-panel-utils.ts", "../../src/split-view/split-view-panel/split-view-panel-foundation.ts", "../../src/split-view/split-view/split-view-constants.ts", "../../src/split-view/split-view-panel/split-view-panel-adapter.ts", "../../src/split-view/split-view-panel/split-view-panel.ts", "../../src/split-view/split-view-panel/index.ts"],
4
- "sourcesContent": ["import { COMPONENT_NAME_PREFIX } from '../../constants';\nimport { SplitViewOrientation } from '../split-view/split-view-constants';\n\nconst elementName: keyof HTMLElementTagNameMap = `${COMPONENT_NAME_PREFIX}split-view-panel`;\n\nconst attributes = {\n RESIZABLE: 'resizable',\n SIZE: 'size',\n MIN: 'min',\n MAX: 'max',\n OPEN: 'open',\n ACCESSIBLE_LABEL: 'accessible-label',\n DISABLED: 'disabled',\n ALLOW_CLOSE: 'allow-close',\n AUTO_CLOSE: 'auto-close',\n AUTO_CLOSE_THRESHOLD: 'auto-close-threshold',\n ORIENTATION: 'orientation'\n};\n\nconst classes = {\n ROOT: 'forge-split-view-panel',\n GRABBED: 'forge-split-view-panel--grabbed',\n HANDLE: 'forge-split-view-panel__handle',\n ICON: 'forge-split-view-panel__icon',\n CONTENT: 'forge-split-view-panel__content',\n CLOSED: 'forge-split-view-panel--closed',\n CLOSING: 'forge-split-view-panel--closing',\n OPENING: 'forge-split-view-panel--opening',\n DISABLED: 'forge-split-view-panel--disabled',\n OVERLAY: 'forge-split-view-panel-overlay'\n};\n\nconst ids = {\n ROOT: 'root',\n HANDLE: 'handle',\n ICON: 'icon',\n RIPPLE: 'ripple',\n CONTENT: 'content'\n};\n\nconst selectors = {\n ROOT: `#${ids.ROOT}`,\n HANDLE: `#${ids.HANDLE}`,\n ICON: `#${ids.ICON}`,\n RIPPLE: `#${ids.RIPPLE}`,\n CONTENT: `#${ids.CONTENT}`\n};\n\nconst events = {\n WILL_RESIZE: `${elementName}-will-resize`,\n RESIZE_START: `${elementName}-resize-start`,\n RESIZE_END: `${elementName}-resize-end`,\n RESIZE: `${elementName}-resize`,\n DID_OPEN: `${elementName}-did-open`,\n DID_CLOSE: `${elementName}-did-close`,\n WILL_OPEN: `${elementName}-will-open`,\n WILL_CLOSE: `${elementName}-will-close`\n};\n\nconst numbers = {\n RIPPLE_ACTIVATION_WAIT: 200\n};\n\nconst customCssProperties = {\n SIZE: '--forge-split-view-panel-size',\n CURSOR: '--forge-split-view-panel-cursor'\n};\n\nexport const SPLIT_VIEW_PANEL_CONSTANTS = {\n elementName,\n attributes,\n classes,\n ids,\n selectors,\n events,\n numbers,\n customCssProperties\n};\n\n// 'start' panels have a handle on the left/top and collapse to the right/bottom\n// 'end' panels have a handle on the right/bottom and collapse to the left/top\n// 'off' panels don't have a handle, are not resizable, and fill the remaining space\nexport type SplitViewPanelResizable = 'start' | 'end' | 'off';\n\nexport type SplitViewInputDeviceType = 'pointer' | 'keyboard';\n\nexport enum SplitViewAnimatingLayer {\n Under = 1,\n Active = 2,\n Above = 3\n}\n\nexport interface ISplitViewPanelCursorConfig {\n resizable: SplitViewPanelResizable;\n boundary: 'min' | 'max' | 'none';\n}\n\nexport interface ISplitViewPanelState {\n orientation: SplitViewOrientation;\n resizable: SplitViewPanelResizable;\n arrowKeyHeld: boolean;\n startPoint?: number;\n startSize?: number;\n currentSize?: number;\n availableSpace?: number;\n siblingSize?: number;\n keyboardDelta: number;\n isAtMin: boolean;\n isAtMax: boolean;\n min: number;\n max?: number;\n}\n\nexport interface ISplitViewPanelWillResizeEvent {\n inputDeviceType: SplitViewInputDeviceType;\n}\n\nexport interface ISplitViewPanelOpenEvent {\n auto: boolean;\n userInitiated: boolean;\n}\n", "import { percentToPixels, safeMin, scaleValue } from '../../core/utils/utils';\nimport { ISplitViewPanelCursorConfig, ISplitViewPanelState, SplitViewInputDeviceType, SPLIT_VIEW_PANEL_CONSTANTS } from './split-view-panel-constants';\nimport { ISplitViewPanelAdapter } from './split-view-panel-adapter';\nimport { SplitViewOrientation } from '../split-view/split-view-constants';\nimport { ISplitViewPanelComponent, SplitViewPanelComponent } from './split-view-panel';\n\n/**\n * Creates a default split view panel state object.\n * @returns A new state object.\n */\nexport function initState(): ISplitViewPanelState {\n return {\n orientation: 'horizontal',\n resizable: 'off',\n arrowKeyHeld: false,\n keyboardDelta: 0,\n isAtMin: false,\n isAtMax: false,\n min: 0\n };\n}\n\n/**\n * Gets a state object reflecting the panel's parameters at the beginning of a resize.\n * @param adapter The panel's adapter.\n * @param state The panel's state object.\n * @returns An updated state object.\n */\nexport function setState(adapter: ISplitViewPanelAdapter, state: ISplitViewPanelState): ISplitViewPanelState {\n const currentSize = adapter.getContentSize(state.orientation);\n return {\n ...state,\n currentSize,\n startSize: currentSize,\n availableSpace: adapter.getAvailableSpace(state.orientation, state.resizable),\n siblingSize: adapter.getSiblingContentSize(),\n isAtMin: false,\n isAtMax: false\n };\n}\n\n/**\n * Gets a state object with all properties related to a resize reset to default.\n * @param state The panel's state object.\n * @returns An updated state object.\n */\nexport function clearState(state: ISplitViewPanelState): ISplitViewPanelState {\n return {\n ...state,\n arrowKeyHeld: false,\n keyboardDelta: 0,\n isAtMin: false,\n isAtMax: false\n };\n}\n\n/**\n * Performs a panel resize triggered by a pointer event.\n * @param adapter The panel's adapter.\n * @param evt The pointer event.\n * @param state The panel's state object.\n * @returns Whether a resize happened.\n */\nexport function pointerResize(adapter: ISplitViewPanelAdapter, evt: PointerEvent, state: ISplitViewPanelState): boolean {\n if (state.startPoint === undefined || state.startSize === undefined) {\n return false;\n }\n\n const initialSize = state.currentSize;\n\n const evtPoint = state.orientation === 'horizontal' ? evt.clientX : evt.clientY;\n let delta = state.startPoint - evtPoint;\n if (state.resizable === 'start') {\n delta *= -1;\n }\n\n const size = state.startSize - delta;\n state.currentSize = clampSize(size, state);\n adapter.setContentSize(state.currentSize);\n handleBoundariesDuringResize(adapter, state, 'pointer');\n adapter.setValuenow(getValuenow(state.currentSize, state));\n\n const siblingDelta = size - state.currentSize + delta;\n resizeSibling(adapter, siblingDelta, state);\n\n return initialSize !== state.currentSize;\n}\n\n/**\n * Performs a panel resize triggered by a keyboard event.\n * @param adapter The panel's adapter.\n * @param increment The pixel amount to change the panel's size.\n * @param state The panel's state object.\n * @returns Whether a resize happened.\n */\nexport function keyboardResize(adapter: ISplitViewPanelAdapter, increment: number, state: ISplitViewPanelState): boolean {\n if (state.startSize === undefined) {\n return false;\n }\n\n const initialSize = state.currentSize;\n\n state.keyboardDelta += increment;\n\n const size = state.startSize + state.keyboardDelta;\n state.currentSize = clampSize(size, state);\n adapter.setContentSize(state.currentSize);\n handleBoundariesDuringResize(adapter, state, 'keyboard');\n adapter.setValuenow(getValuenow(state.currentSize, state));\n\n const siblingDelta = size - state.currentSize + state.keyboardDelta * -1;\n resizeSibling(adapter, siblingDelta, state);\n\n return initialSize !== state.currentSize;\n}\n\n/**\n * Resizes a panel to its minimum possible size.\n * @param adapter The panel's adapter.\n * @param state The panel's state object.\n * @returns The new pixel size of the panel.\n */\nexport function minResize(adapter: ISplitViewPanelAdapter, state: ISplitViewPanelState): number {\n adapter.setContentSize(state.min);\n return state.min;\n}\n\n/**\n * Resizes a panel to its maximum possible size.\n * @param adapter The panel's adapter.\n * @param state The panel's state object.\n * @returns The new pixel size of the panel.\n */\nexport function maxResize(adapter: ISplitViewPanelAdapter, state: ISplitViewPanelState): number {\n const availableSpace = adapter.getAvailableSpace(state.orientation, state.resizable);\n const max = safeMin(state.max, availableSpace);\n adapter.setContentSize(max);\n return max;\n}\n\n/**\n * Sets a panel's sibling's size to reflect changes in the panel's size.\n * @param adapter The panel's adapter.\n * @param delta The change in size to apply to the sibling.\n * @param state The panel's state object.\n */\nexport function resizeSibling(adapter: ISplitViewPanelAdapter, delta: number, state: ISplitViewPanelState): void {\n if (state.siblingSize !== undefined) {\n const siblingSize = state.siblingSize + delta;\n adapter.setSiblingContentSize(siblingSize);\n }\n}\n\n/**\n * Returns a size limited to an allowed range.\n * @param size The size to try setting this panel to.\n * @param state The panel's state object.\n * @returns A pixel value.\n */\nexport function clampSize(size: number, state: ISplitViewPanelState): number {\n size = Math.max(size, state.min);\n size = safeMin(size, state.max, state.availableSpace);\n return size;\n}\n\n/**\n * Checks whether a panel is at its min or max size while resizing and runs logic related to\n * that once.\n * @param adapter The panel's adapter.\n * @param state The panel's state object.\n * @param inputDevice The input device responsible for the resize.\n * @returns Whether the panel is at its min or max size.\n */\nexport function handleBoundariesDuringResize(adapter: ISplitViewPanelAdapter, state: ISplitViewPanelState, inputDevice?: SplitViewInputDeviceType): boolean {\n if (state.currentSize === undefined) {\n return false;\n }\n\n // Check min\n if (state.currentSize <= state.min) {\n // Just reached the min\n if (!state.isAtMin) {\n adapter.activateRipple(inputDevice === 'pointer');\n if (inputDevice === 'pointer') {\n adapter.setBodyCursor(state.orientation, { resizable: state.resizable, boundary: 'min' });\n }\n state.isAtMin = true;\n }\n return true;\n } else if (state.isAtMin) {\n // TODO: is it more performant to have the else if condition or to always set the variable?\n state.isAtMin = false;\n }\n\n // Check max\n const max = safeMin(state.max, state.availableSpace);\n if (state.currentSize >= max) {\n // Just reached the max\n if(!state.isAtMax) {\n adapter.activateRipple(inputDevice === 'pointer');\n if (inputDevice === 'pointer') {\n adapter.setBodyCursor(state.orientation, { resizable: state.resizable, boundary: 'max' });\n }\n state.isAtMax = true;\n }\n return true;\n } else if (state.isAtMax) {\n state.isAtMax = false;\n }\n\n if (inputDevice === 'pointer') {\n adapter.setBodyCursor(state.orientation);\n }\n \n return false;\n}\n\n/**\n * Checks whether a panel is at its min or max size while not resizing and runs logic related to\n * that once.\n * @param adapter The panel's adapter.\n * @param size The panel's size.\n * @param state The panel's state object.\n * @returns Whether the panel is at its min or max size.\n */\nexport function handleBoundariesAfterResize(adapter: ISplitViewPanelAdapter, size: number, state: ISplitViewPanelState): boolean {\n if (size <= state.min) {\n adapter.setHandleCursor(state.orientation, { resizable: state.resizable, boundary: 'min' });\n return true;\n }\n\n const max = safeMin(state.max, state.availableSpace);\n if (size >= max) {\n adapter.setHandleCursor(state.orientation, { resizable: state.resizable, boundary: 'max' });\n return true;\n }\n\n adapter.setHandleCursor(state.orientation);\n return false;\n}\n\n/**\n * Gets the accessible valuenow of a panel.\n * @param size The panel's size in pixels.\n * @param state The panel's state object.\n */\nexport function getValuenow(size: number, state: ISplitViewPanelState): number {\n if (!state.availableSpace && !state.max) {\n return 100;\n }\n\n const max = safeMin(state.max, state.availableSpace);\n return scaleValue(size, state.min, max);\n}\n\n/**\n * Gets the appropriate cursor for the handle orientation.\n * @param orientation \n * @returns A CSS cursor keyword value.\n */\nexport function getCursor(orientation: SplitViewOrientation, config?: ISplitViewPanelCursorConfig): string {\n if (orientation === 'horizontal') {\n switch (config?.boundary) {\n case 'min':\n return config.resizable === 'end' ? 'e-resize' : 'w-resize';\n case 'max':\n return config.resizable === 'end' ? 'w-resize' : 'e-resize';\n default:\n return 'col-resize';\n }\n } else {\n switch (config?.boundary) {\n case 'min':\n return config.resizable === 'end' ? 's-resize' : 'n-resize';\n case 'max':\n return config.resizable === 'end' ? 'n-resize' : 's-resize';\n default:\n return 'row-resize';\n }\n }\n}\n\n/**\n * Gets the approporate drag icon for the handle orientation.\n * @param orientation \n * @returns A Forge icon name.\n */\nexport function getHandleIcon(orientation: SplitViewOrientation): string {\n return orientation === 'horizontal' ? 'drag_vertical_variant' : 'drag_handle';\n}\n\n/**\n * Gets the panel that the given panel resizes into.\n * @param el A split view panel.\n * @returns A sibling split view panel or undefined if there is not a sibling.\n */\nexport function getSplitViewPanelSibling(el: ISplitViewPanelComponent): SplitViewPanelComponent | undefined {\n const resizable = el.resizable;\n if (resizable === 'off') {\n return undefined;\n }\n \n let sibling: Element | null = el;\n do {\n sibling = resizable === 'end' ? sibling.nextElementSibling : sibling.previousElementSibling;\n } while (sibling instanceof SplitViewPanelComponent && !sibling.open);\n\n if (sibling instanceof SplitViewPanelComponent) {\n return sibling;\n }\n\n return undefined;\n}\n\n/**\n * Extracts a size and unit from a `number` or `string` formatted as a CSS dimension using px or %.\n * A `number` is interpreted to be a pixel value.\n * @param value A `number` or `string` representing a size in pixels or percent.\n * @returns An object containing the parsed size and unit.\n */\nexport function parseSize(value: number | string): { amount: number; unit: 'px' | '%' | '' } {\n if (!isNaN(+value)) {\n return { amount: +value, unit: 'px' };\n }\n\n // Matches digits with or without decimals, any amount of whitespace, and 'px' or '%'\n const regex = /(^\\d*\\.?\\d*)\\s*(px|%$)?/i;\n const parts = (value as string).match(regex);\n const amount = parts?.[1] ? +parts[1] : -1;\n const unit = (parts?.[2]?.toLowerCase() ?? '') as 'px' | '%' | '';\n\n return { amount, unit };\n}\n\n/**\n * Gets a pixel size value from a pixel or percent value.\n * @param value A `number` or `string` representing a size in pixels or percent.\n * @param parentSize The pixel size of the parent container along the relevant axis.\n * @returns A pixel amount.\n */\nexport function getPixelDimension(value: number | string, parentSize: number): number {\n const parsedSize = parseSize(value);\n\n if (parsedSize.unit === '%') {\n return percentToPixels(parsedSize.amount, parentSize);\n }\n return parsedSize.amount;\n}\n\n/**\n * Creates a transparent element to overlay on top of the document body, ensuring the split view\n * behaves as expected when dragging over other contexts.\n * @returns An overlay element.\n */\nexport function createOverlay(): HTMLElement {\n const el = document.createElement('div');\n el.classList.add(SPLIT_VIEW_PANEL_CONSTANTS.classes.OVERLAY);\n el.style.position = 'fixed';\n el.style.top = '0';\n el.style.left = '0';\n el.style.width = '100vw';\n el.style.height = '100vh';\n el.style.zIndex = '9999';\n return el;\n}\n", "import { ICustomElementFoundation, isDefined } from '@tylertech/forge-core';\n\nimport { safeMin, scaleValue } from '../../core/utils/utils';\nimport { eventIncludesArrowKey } from '../../core/utils/event-utils';\nimport { ISplitViewPanelOpenEvent, ISplitViewPanelState, SplitViewInputDeviceType, SplitViewPanelResizable, SPLIT_VIEW_PANEL_CONSTANTS } from './split-view-panel-constants';\nimport { ISplitViewPanelAdapter } from './split-view-panel-adapter';\nimport { ISplitViewUpdateConfig, SplitViewOrientation } from '../split-view/split-view-constants';\nimport { ISplitViewBase } from '../core/split-view-base';\nimport { clampSize, clearState, getPixelDimension, getValuenow, handleBoundariesAfterResize, handleBoundariesDuringResize, initState, keyboardResize, maxResize, minResize, pointerResize, setState } from './split-view-panel-utils';\n\nexport interface ISplitViewPanelFoundation extends Partial<ISplitViewBase>, ICustomElementFoundation {\n resizable: SplitViewPanelResizable;\n size: number | string;\n min: number | string;\n max: number | string | undefined;\n accessibleLabel: string;\n open: boolean;\n getContentSize(): number;\n getCollapsibleSize(): number;\n setContentSize(size: number): void;\n update(config: ISplitViewUpdateConfig): void;\n}\n\nexport class SplitViewPanelFoundation implements ISplitViewPanelFoundation {\n // API\n private _size: number | string = 200;\n private _min: number | string = 0;\n private _max: number | string | undefined;\n private _accessibleLabel = 'Split view panel';\n private _open = true;\n private _disabled?: boolean;\n private _allowClose?: boolean;\n private _autoClose?: boolean;\n private _autoCloseThreshold?: number;\n \n // State\n private _state: ISplitViewPanelState = initState();\n private _isInitialized = false;\n\n // Properties stored in state\n private get _orientation(): SplitViewOrientation {\n return this._state.orientation;\n }\n private set _orientation(value: SplitViewOrientation) {\n this._state.orientation = value;\n }\n\n private get _resizable(): SplitViewPanelResizable {\n return this._state.resizable;\n }\n private set _resizable(value: SplitViewPanelResizable) {\n this._state.resizable = value;\n }\n\n private get _pixelMin(): number {\n return this._state.min;\n }\n private set _pixelMin(value: number) {\n this._state.min = value;\n }\n\n private get _pixelMax(): number | undefined {\n return this._state.max;\n }\n private set _pixelMax(value: number | undefined) {\n this._state.max = value;\n }\n\n // Properties inherited from parent split view\n private _parentProperties: Partial<ISplitViewBase> = {};\n\n // Applied properties that can be inherited from parent\n private get _appliedDisabled(): boolean {\n return this._disabled ?? this._parentProperties.disabled ?? false;\n }\n\n private get _appliedAllowClose(): boolean {\n return this._allowClose ?? this._parentProperties.allowClose ?? false;\n }\n\n private get _appliedAutoClose(): boolean {\n return this._autoClose ?? this._parentProperties.autoClose ?? false;\n }\n\n private get _appliedAutoCloseThreshold(): number {\n return this._autoCloseThreshold ?? this._parentProperties.autoCloseThreshold ?? 0;\n }\n\n // Listeners\n private _pointerdownListener: (evt: PointerEvent) => void;\n private _pointerupListener: (evt: PointerEvent) => void;\n private _pointermoveListener: (evt: PointerEvent) => void;\n private _keydownListener: (evt: KeyboardEvent) => void;\n private _keyupListener: (evt: KeyboardEvent) => void;\n\n constructor(private _adapter: ISplitViewPanelAdapter) {\n this._pointerdownListener = evt => this._onPointerdown(evt);\n this._pointerupListener = evt => this._onPointerup(evt);\n this._pointermoveListener = evt => this._onPointermove(evt);\n this._keydownListener = evt => this._onKeydown(evt);\n this._keyupListener = evt => this._onKeyup(evt);\n }\n\n public initialize(): void {\n this._adapter.initialize();\n this._adapter.setPointerdownListener(this._pointerdownListener);\n this._adapter.setKeydownListener(this._keydownListener);\n this._getParentProperties();\n this._applyResizable();\n this._applyMin();\n this._applyMax();\n this._applySize();\n this._applyAccessibleLabel();\n this._applyOpen();\n this._applyDisabled();\n this._applyAllowClose();\n this._applyAutoClose();\n this._applyAutoCloseThreshold();\n this._isInitialized = true;\n }\n\n public disconnect(): void {\n this._adapter.tryRemoveOverlay();\n this._adapter.removePointerupListener(this._pointerupListener);\n this._adapter.removePointermoveListener(this._pointermoveListener);\n }\n\n /**\n * Handles a pointerdown event and sets further pointer event listeners.\n * @param evt The pointer event.\n */\n private _onPointerdown(evt: PointerEvent): void {\n if (this._appliedDisabled || !this._allowResize('pointer')) {\n return;\n }\n\n evt.preventDefault();\n\n this._adapter.setPointermoveListener(this._pointermoveListener);\n this._adapter.setPointerupListener(this._pointerupListener);\n this._handlePointerdown(evt);\n }\n\n /**\n * Handles a pointerup event and removes pointer event listeners.\n * @param evt The pointer event.\n */\n private _onPointerup(evt: PointerEvent): void {\n evt.preventDefault();\n\n this._adapter.removePointermoveListener(this._pointermoveListener);\n this._adapter.removePointerupListener(this._pointerupListener);\n this._handlePointerup();\n }\n\n /**\n * Handles a pointermove event and removes pointer events if the mouse button is released.\n * @param evt The pointer event.\n */\n private _onPointermove(evt: PointerEvent): void {\n if (this._appliedDisabled) {\n return;\n }\n\n evt.preventDefault();\n\n // Detect when the mouse button is released outside of the document\n if (evt.buttons === 0) {\n this._adapter.removePointermoveListener(this._pointermoveListener);\n this._adapter.removePointerupListener(this._pointerupListener);\n this._handlePointerup();\n return;\n }\n\n this._handlePointermove(evt);\n }\n\n /**\n * Handles a keydown event and sets a keyup listener if an arrow key is pressed.\n * @param evt The keyboard event.\n */\n private _onKeydown(evt: KeyboardEvent): void {\n if (this._appliedDisabled) {\n return;\n }\n\n if (evt.key === 'Enter') {\n this._handleEnterKey(evt);\n } else if (evt.key === 'Home' && this._allowResize('keyboard')) {\n this._handleHomeKey(evt);\n } else if (evt.key === 'End' && this._allowResize('keyboard')) {\n this._handleEndKey(evt);\n } else if (eventIncludesArrowKey(evt) && this._allowResize('keyboard')) {\n this._adapter.setKeyupListener(this._keyupListener);\n this._handleArrowKey(evt);\n }\n }\n\n /**\n * Handles a keyup event and removes the keyup listener if an arrow key was released.\n * @param evt The keyboard event.\n */\n private _onKeyup(evt: KeyboardEvent): void {\n if (eventIncludesArrowKey(evt)) {\n this._adapter.removeKeyupListener(this._keyupListener);\n this._handleArrowKeyUp();\n }\n }\n\n /**\n * Toggles the open state.\n * @param evt \n */\n private _handleEnterKey(evt: KeyboardEvent): void {\n if (!this._appliedAllowClose) {\n return;\n }\n\n evt.preventDefault();\n this._tryOpenOrClose(!this._open, false, true);\n }\n\n /**\n * Sets panel size to the min.\n * @param evt\n */\n private _handleHomeKey(evt: KeyboardEvent): void {\n evt.preventDefault();\n\n const size = minResize(this._adapter, this._state);\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE, size);\n this._tryAutoClose();\n }\n\n /**\n * Sets panel size to the max.\n * @param evt\n */\n private _handleEndKey(evt: KeyboardEvent): void {\n evt.preventDefault();\n\n const size = maxResize(this._adapter, this._state);\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE, size);\n }\n\n /**\n * Runs resize logic if an arrow key is included in the event.\n * @param evt \n */\n private _handleArrowKey(evt: KeyboardEvent): void {\n let increment = 0;\n if (this._orientation === 'horizontal') {\n switch (evt.key) {\n case 'ArrowLeft':\n increment = -1;\n break;\n case 'ArrowRight':\n increment = 1;\n break;\n default:\n return;\n }\n } else {\n switch (evt.key) {\n case 'ArrowUp':\n increment = -1;\n break;\n case 'ArrowDown':\n increment = 1;\n break;\n default:\n return;\n }\n }\n\n evt.preventDefault();\n\n if (this._resizable === 'start') {\n increment *= -1;\n }\n if (evt.shiftKey) {\n increment *= 10;\n }\n\n this._tryHandleArrowKeyDown();\n this._handleArrowKeyHeld(increment);\n }\n\n /**\n * Sets resize properties when an arrow key is first pressed.\n */\n private _tryHandleArrowKeyDown(): void {\n if (!this._state.arrowKeyHeld) {\n this._startResize();\n }\n this._state.arrowKeyHeld = true;\n }\n\n /**\n * Performs cleanup logic after a keyboard driven resize.\n */\n private _handleArrowKeyUp(): void {\n this._endResize();\n }\n\n /**\n * Resizes the panel by a set amount.\n * @param increment The pixel change in size.\n */\n private _handleArrowKeyHeld(increment: number): void {\n if (keyboardResize(this._adapter, increment, this._state)) {\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE, this._state.currentSize);\n }\n }\n\n /**\n * Handles the beginning of a pointer driven resize.\n * @param evt \n */\n private _handlePointerdown(evt: MouseEvent): void {\n this._adapter.setGrabbed(true);\n this._adapter.focusHandle();\n \n this._startResize();\n this._state.startPoint = this._orientation === 'horizontal' ? evt.clientX : evt.clientY;\n handleBoundariesDuringResize(this._adapter, this._state, 'pointer');\n }\n\n /**\n * Handles the end of a pointer driven resize.\n */\n private _handlePointerup(): void {\n this._adapter.setGrabbed(false);\n this._adapter.deactivateRipple();\n this._endResize();\n }\n\n /**\n * Resizes the panel from a pointer event.\n * @param evt \n */\n private _handlePointermove(evt: PointerEvent): void {\n if(pointerResize(this._adapter, evt, this._state)) {\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE, this._state.currentSize);\n }\n }\n\n /**\n * Emits a will resize event and allows it to be cancelled.\n * @returns Whether the resize should proceed.\n */\n private _allowResize(inputDeviceType: SplitViewInputDeviceType): boolean {\n return this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.WILL_RESIZE, { inputDeviceType }, true, true);\n }\n\n /**\n * Handles common logic to begin a resize.\n */\n private _startResize(): void {\n this._state = setState(this._adapter, this._state);\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE_START, this._state.startSize);\n }\n\n /**\n * Handles common logic to end a resize.\n */\n private _endResize(): void {\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE_END, this._state.currentSize);\n this._adapter.updateParent({ accessibility: this._state.startSize !== this._state.currentSize, cursor: true });\n this._state = clearState(this._state);\n this._tryAutoClose();\n }\n\n /**\n * Emits a will open or will close event and sets the panel open or closed if allowed.\n * @param shouldOpen Whether the panel should open or close. Defaults to `true`.\n * @param auto Whether the panel auto-opened or auto-closed.\n * @param userInitiated Whether opening or closing via user action instead of programmatically.\n */\n private _tryOpenOrClose(shouldOpen = true, auto = false, userInitiated = false): void {\n const eventType = shouldOpen ? SPLIT_VIEW_PANEL_CONSTANTS.events.WILL_OPEN : SPLIT_VIEW_PANEL_CONSTANTS.events.WILL_CLOSE;\n const event: ISplitViewPanelOpenEvent = {\n auto,\n userInitiated\n };\n const isAllowed = this._adapter.emitHostEvent(eventType, event, true, true);\n if (!isAllowed) {\n return;\n }\n this._open = shouldOpen;\n this._applyOpen(event);\n }\n\n /**\n * Auto close the panel if enabled and within the size threshold.\n */\n private _tryAutoClose(): void {\n const size = this._adapter.getContentSize(this._orientation);\n if (this._appliedAutoClose && size <= this._appliedAutoCloseThreshold) {\n this._tryOpenOrClose(false, true, false);\n }\n }\n\n /**\n * Sets orientation, disabled, disable close, and autoclose to reflect the parent split view.\n */\n private _getParentProperties(): void {\n // Parent disabled state\n const parentDisabled = this._adapter.getParentProperty('disabled') as boolean;\n this._parentProperties.disabled = parentDisabled;\n this._applyParentDisabled();\n\n // Parent disable close\n const parentAllowClose = this._adapter.getParentProperty('allowClose') as boolean;\n this._parentProperties.allowClose = parentAllowClose;\n\n // Parent auto close\n const parentAutoClose = this._adapter.getParentProperty('autoClose') as boolean;\n this._parentProperties.autoClose = parentAutoClose;\n this._applyParentAutoClose();\n\n // Parent auto close threshold\n const parentAutoCloseThreshold = this._adapter.getParentProperty('autoCloseThreshold') as number;\n this._parentProperties.autoCloseThreshold = parentAutoCloseThreshold;\n this._applyParentAutoCloseThreshold();\n }\n\n private _applyOrientation(): void {\n this._adapter.setOrientation(this._orientation);\n }\n\n /**\n * Get/set resizable. This affects the side the handle appears on and the direction the panel closes into.\n */\n public get resizable(): SplitViewPanelResizable {\n return this._resizable;\n }\n public set resizable(value: SplitViewPanelResizable) {\n if (this._resizable !== value) {\n this._resizable = value;\n this._applyResizable();\n }\n }\n\n private _applyResizable(): void {\n this._adapter.setHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.RESIZABLE, this._resizable);\n this._adapter.setResizable(this._resizable);\n }\n\n /**\n * Get/set panel size.\n */\n public get size(): number | string {\n return this._size;\n }\n public set size(value: number | string) {\n if (this._size.toString() !== value.toString()) {\n this._size = value;\n this._applySize();\n }\n }\n\n private _applySize(): void {\n const parentSize = this._adapter.getParentSize(this._orientation);\n const pixelSize = getPixelDimension(this._size, parentSize);\n\n this._adapter.setHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.SIZE, this._size.toString());\n this._adapter.setContentSize(pixelSize);\n // Wait for the DOM to render to get available space\n window.requestAnimationFrame(() => {\n const availableSpace = this._adapter.getAvailableSpace(this._orientation, this._resizable);\n const maxSize = safeMin(this._pixelMax, availableSpace);\n const newValue = scaleValue(pixelSize, this._pixelMin, maxSize);\n this._adapter.setValuenow(newValue);\n this._adapter.updateParent({ cursor: true });\n });\n }\n\n /** Get/set min panel size. */\n public get min(): number | string {\n return this._min;\n }\n public set min(value: number | string) {\n if (this._min.toString() !== value.toString()) {\n this._min = value;\n this._applyMin();\n }\n }\n\n private _applyMin(): void {\n this._adapter.setHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.MIN, this._min.toString());\n\n const parentSize = this._adapter.getParentSize(this._orientation);\n this._pixelMin = getPixelDimension(this._min, parentSize);\n\n if (this._resizable === 'off') {\n return;\n }\n\n const size = this._adapter.getContentSize(this._orientation);\n if (size < this._pixelMin) {\n this.setContentSize(size);\n }\n }\n\n /** Get/set max panel size. */\n public get max(): number | string | undefined {\n return this._max;\n }\n public set max(value: number | string | undefined) {\n if (this._max?.toString() !== value?.toString()) {\n this._max = value;\n this._applyMax();\n }\n }\n\n private _applyMax(): void {\n this._adapter.toggleHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.MAX, this._max !== undefined, this._max?.toString());\n\n if (this._max === undefined) {\n this._pixelMax = undefined;\n return;\n }\n\n const parentSize = this._adapter.getParentSize(this._orientation);\n this._pixelMax = getPixelDimension(this._max, parentSize);\n\n if (this._resizable === 'off') {\n return;\n }\n \n const size = this._adapter.getContentSize(this._orientation);\n if (size > this._pixelMax) {\n this.setContentSize(size);\n }\n }\n\n /**\n * Get/set the accessible label.\n */\n public get accessibleLabel(): string {\n return this._accessibleLabel;\n }\n public set accessibleLabel(value: string) {\n if (this._accessibleLabel !== value) {\n this._accessibleLabel = value;\n this._applyAccessibleLabel();\n }\n }\n\n private _applyAccessibleLabel(): void {\n this._adapter.setHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.ACCESSIBLE_LABEL, this._accessibleLabel);\n this._adapter.setAccessibleLabel(this._accessibleLabel);\n }\n\n /**\n * Get/set whether the panel is open.\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._tryOpenOrClose(value, false, false);\n return;\n }\n\n this._open = value;\n const event: ISplitViewPanelOpenEvent | undefined = this._isInitialized ? {\n auto: false,\n userInitiated: false\n } : undefined;\n this._applyOpen(event);\n }\n }\n\n private _applyOpen(event?: ISplitViewPanelOpenEvent): void {\n this._adapter.setHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.OPEN, this._open.toString());\n this._adapter.setOpen(this._open, this._isInitialized, event);\n }\n\n /**\n * Get/set whether interactions are disabled.\n */\n public get disabled(): boolean | undefined {\n return this._disabled;\n }\n public set disabled(value: boolean | undefined) {\n if (this._disabled !== value) {\n this._disabled = value;\n this._applyDisabled();\n }\n }\n\n private _applyDisabled(): void {\n this._adapter.toggleHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.DISABLED, this._disabled ?? false);\n this._adapter.setDisabled(this._appliedDisabled);\n }\n\n private _applyParentDisabled(): void {\n if (this._isInitialized && !isDefined(this._disabled)) {\n this._adapter.setDisabled(this._appliedDisabled);\n }\n }\n\n /**\n * Get/set whether closing the panel is disabled.\n */\n public get allowClose(): boolean | undefined {\n return this._allowClose;\n }\n public set allowClose(value: boolean | undefined) {\n if (this._allowClose !== value) {\n this._allowClose = value;\n this._applyAllowClose();\n }\n }\n\n private _applyAllowClose(): void {\n this._adapter.toggleHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.ALLOW_CLOSE, this._allowClose ?? false);\n }\n\n /**\n * Get/set whether the panel closes when a threshold size is reached.\n */\n public get autoClose(): boolean | undefined {\n return this._autoClose;\n }\n public set autoClose(value: boolean | undefined) {\n if (this._autoClose !== value) {\n this._autoClose = value;\n this._applyAutoClose();\n }\n }\n\n private _applyAutoClose(): void {\n this._adapter.toggleHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE, this._autoClose ?? false);\n if (this._isInitialized) {\n this._tryAutoClose();\n }\n }\n\n private _applyParentAutoClose(): void {\n if (this._isInitialized && !isDefined(this._autoClose)) {\n this._tryAutoClose();\n }\n }\n\n /** Get/set the size at which the panel auto closes. */\n public get autoCloseThreshold(): number | undefined {\n return this._autoCloseThreshold;\n }\n public set autoCloseThreshold(value: number | undefined) {\n if (this._autoCloseThreshold !== value) {\n this._autoCloseThreshold = value;\n this._applyAutoCloseThreshold();\n }\n }\n\n private _applyAutoCloseThreshold(): void {\n this._adapter.toggleHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE_THRESHOLD, isDefined(this._autoCloseThreshold), this.autoCloseThreshold?.toString());\n if (this._isInitialized) {\n this._tryAutoClose();\n }\n }\n\n private _applyParentAutoCloseThreshold(): void {\n if (this._isInitialized && !isDefined(this._autoCloseThreshold)) {\n this._tryAutoClose();\n }\n }\n\n /**\n * Gets the size of panel content without the handle.\n * @returns Content size in pixels.\n */\n public getContentSize(): number {\n return this._adapter.getContentSize(this._orientation);\n }\n\n /**\n * Gets how much the panel can shrink from its current size.\n * @returns The difference between the current and min size in pixels.\n */\n public getCollapsibleSize(): number {\n const parentSize = this._adapter.getParentSize(this._orientation);\n const pixelMin = getPixelDimension(this._min, parentSize);\n return this._adapter.getContentSize(this._orientation) - pixelMin;\n }\n\n /**\n * Sets a new size for the content area.\n * @param size The new content size in pixels.\n */\n public setContentSize(size: number): void {\n if (this._resizable === 'off') {\n return;\n }\n\n const newSize = clampSize(size, this._state);\n this._adapter.setContentSize(newSize);\n if (this._isInitialized) {\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE, newSize);\n }\n }\n\n /**\n * Updates the proved characteristics.\n * @param config An update configuration.\n */\n public update(config: ISplitViewUpdateConfig): void {\n // Orientation\n if (config.orientation) {\n this._orientation = config.orientation;\n this._applyOrientation();\n }\n\n // Parent properties\n if (config.properties) {\n if (isDefined(config.properties.disabled) && this._parentProperties.disabled !== config.properties.disabled) {\n this._parentProperties.disabled = config.properties.disabled;\n this._applyDisabled();\n }\n if (isDefined(config.properties.allowClose)) {\n this._parentProperties.allowClose = config.properties.allowClose;\n }\n if (isDefined(config.properties.autoClose) && this._parentProperties.autoClose !== config.properties.autoClose) {\n this._parentProperties.autoClose = config.properties.autoClose;\n if (!isDefined(this._autoClose)) {\n this._applyAutoClose();\n }\n }\n if (isDefined(config.properties.autoCloseThreshold) && this._parentProperties.autoCloseThreshold !== config.properties.autoCloseThreshold) {\n this._parentProperties.autoCloseThreshold = config.properties.autoCloseThreshold;\n if (!isDefined(this._autoCloseThreshold)) {\n this._applyAutoCloseThreshold();\n }\n }\n }\n\n // Size\n if (config.size && this.open) {\n const parentSize = this._adapter.getParentSize(this._orientation);\n this._pixelMin = getPixelDimension(this._min, parentSize);\n this._pixelMax = isDefined(this._max) ? getPixelDimension(this._max as number | string, parentSize) : undefined;\n this.setContentSize(this._adapter.getContentSize(this._orientation));\n }\n\n // The following properties don't apply to non-resizable panels\n if (this._resizable === 'off') {\n return;\n }\n\n const size = this._adapter.getContentSize(this._orientation);\n const availableSpace = this._adapter.getAvailableSpace(this._orientation, this._resizable);\n\n // Accessibility\n if (config.accessibility && this.open) {\n const valueNow = getValuenow(size, { ...this._state, availableSpace });\n this._adapter.setValuenow(valueNow);\n }\n\n // Contextual cursor\n if (config.cursor) {\n handleBoundariesAfterResize(this._adapter, size, { ...this._state, availableSpace });\n }\n }\n}\n", "import { COMPONENT_NAME_PREFIX } from '../../constants';\nimport { ISplitViewBase } from '../core';\nimport { SPLIT_VIEW_PANEL_CONSTANTS } from '../split-view-panel/split-view-panel-constants';\n\nconst elementName: keyof HTMLElementTagNameMap = `${COMPONENT_NAME_PREFIX}split-view`;\n\nconst attributes = {\n ORIENTATION: 'orientation',\n DISABLED: 'disabled',\n ALLOW_CLOSE: 'allow-close',\n AUTO_CLOSE: 'auto-close',\n AUTO_CLOSE_THRESHOLD: 'auto-close-threshold'\n};\n\nconst classes = {\n ROOT: 'forge-split-view'\n};\n\nconst ids = {\n ROOT: 'root'\n};\n\nconst selectors = {\n ROOT: `#${ids.ROOT}`,\n PANEL: SPLIT_VIEW_PANEL_CONSTANTS.elementName\n};\n\nconst numbers = {\n RESIZE_THROTTLE_THRESHOLD: 200\n};\n\nconst customCssProperties = {\n ANIMATING_LAYER: '--forge-split-view-animating-layer'\n};\n\nexport const SPLIT_VIEW_CONSTANTS = {\n elementName,\n attributes,\n classes,\n ids,\n selectors,\n numbers,\n customCssProperties\n};\n\nexport type SplitViewOrientation = 'horizontal' | 'vertical';\n\nexport interface ISplitViewUpdateConfig {\n accessibility?: boolean;\n cursor?: boolean;\n orientation?: SplitViewOrientation;\n properties?: Partial<ISplitViewBase>;\n size?: boolean;\n}\n", "import { getShadowElement, playKeyframeAnimation, toggleAttribute } from '@tylertech/forge-core';\n\nimport { BaseAdapter, IBaseAdapter } from '../../core/base/base-adapter';\nimport { ISplitViewPanelComponent } from './split-view-panel';\nimport { ISplitViewPanelCursorConfig, ISplitViewPanelOpenEvent, SplitViewPanelResizable, SPLIT_VIEW_PANEL_CONSTANTS } from './split-view-panel-constants';\nimport { ISplitViewUpdateConfig, SplitViewOrientation, SPLIT_VIEW_CONSTANTS } from '../split-view/split-view-constants';\nimport { ISplitViewComponent } from '../split-view/split-view';\nimport { getCursor, getHandleIcon, createOverlay, getSplitViewPanelSibling } from './split-view-panel-utils';\nimport { IIconComponent } from '../../icon';\nimport { IRippleComponent } from '../../ripple';\n\nexport interface ISplitViewPanelAdapter extends IBaseAdapter {\n initialize(): void;\n tryRemoveOverlay(): void;\n setPointerdownListener(listener: (evt: PointerEvent) => void): void;\n setPointerupListener(listener: (evt: PointerEvent) => void): void;\n removePointerupListener(listener: (evt: PointerEvent) => void): void;\n setPointermoveListener(listener: (evt: PointerEvent) => void): void;\n removePointermoveListener(listener: (evt: PointerEvent) => void): void;\n setKeydownListener(listener: (evt: KeyboardEvent) => void): void;\n setKeyupListener(listener: (evt: KeyboardEvent) => void): void;\n removeKeyupListener(listener: (evt: KeyboardEvent) => void): void;\n getParentProperty(name: keyof ISplitViewComponent): unknown;\n setAccessibleLabel(value: string): void;\n setDisabled(value: boolean): void;\n setResizable(value: SplitViewPanelResizable): void;\n setOrientation(value: SplitViewOrientation): void;\n setOpen(value: boolean, withAnimation?: boolean, event?: ISplitViewPanelOpenEvent): void;\n setGrabbed(value: boolean): void;\n setHandleCursor(orientation?: SplitViewOrientation, config?: ISplitViewPanelCursorConfig): void;\n setBodyCursor(orientation: SplitViewOrientation, config?: ISplitViewPanelCursorConfig): void;\n getContentSize(orientation: SplitViewOrientation): number;\n setContentSize(value: number): void;\n setValuenow(value: number): void;\n focusHandle(): void;\n getAvailableSpace(orientation: SplitViewOrientation, resizable: SplitViewPanelResizable): number;\n getSiblingContentSize(): number;\n setSiblingContentSize(value: number): void;\n activateRipple(defaultActivated: boolean): void;\n deactivateRipple(): void;\n getParentSize(orientation: SplitViewOrientation): number;\n updateParent(config: ISplitViewUpdateConfig): void;\n}\n\nexport class SplitViewPanelAdapter extends BaseAdapter<ISplitViewPanelComponent> implements ISplitViewPanelAdapter {\n private _root: HTMLElement;\n private _handle: HTMLElement;\n private _icon: IIconComponent;\n private _ripple: IRippleComponent;\n private _content: HTMLElement;\n private _parent?: ISplitViewComponent;\n private _overlay?: HTMLElement;\n\n constructor(component: ISplitViewPanelComponent) {\n super(component);\n this._root = getShadowElement(component, SPLIT_VIEW_PANEL_CONSTANTS.selectors.ROOT);\n this._handle = getShadowElement(component, SPLIT_VIEW_PANEL_CONSTANTS.selectors.HANDLE);\n this._icon = getShadowElement(component, SPLIT_VIEW_PANEL_CONSTANTS.selectors.ICON) as IIconComponent;\n this._ripple = getShadowElement(component, SPLIT_VIEW_PANEL_CONSTANTS.selectors.RIPPLE) as IRippleComponent;\n this._content = getShadowElement(component, SPLIT_VIEW_PANEL_CONSTANTS.selectors.CONTENT);\n }\n\n public initialize(): void {\n // Set the parent split view\n const parent = this._component.parentElement;\n if (parent?.tagName.toLowerCase() === SPLIT_VIEW_CONSTANTS.elementName) {\n this._parent = parent as ISplitViewComponent;\n }\n }\n\n public tryRemoveOverlay(): void {\n this._overlay?.remove();\n this._overlay = undefined;\n }\n\n public setPointerdownListener(listener: (evt: PointerEvent) => void): void {\n this._handle.addEventListener('pointerdown', listener);\n }\n\n public setPointerupListener(listener: (evt: PointerEvent) => void): void {\n document.addEventListener('pointerup', listener);\n }\n\n public removePointerupListener(listener: (evt: PointerEvent) => void): void {\n document.removeEventListener('pointerup', listener);\n }\n\n public setPointermoveListener(listener: (evt: PointerEvent) => void): void {\n document.addEventListener('pointermove', listener);\n }\n\n public removePointermoveListener(listener: (evt: PointerEvent) => void): void {\n document.removeEventListener('pointermove', listener);\n }\n\n public setKeydownListener(listener: (evt: KeyboardEvent) => void): void {\n this._handle.addEventListener('keydown', listener);\n }\n\n public setKeyupListener(listener: (evt: KeyboardEvent) => void): void {\n this._handle.addEventListener('keyup', listener);\n }\n\n public removeKeyupListener(listener: (evt: KeyboardEvent) => void): void {\n this._handle.removeEventListener('keyup', listener);\n }\n\n /**\n * Gets the specified property value from the parent split view.\n * @param name The property name.\n * @returns The value of the property.\n */\n public getParentProperty(name: keyof ISplitViewComponent): unknown {\n return this._parent?.[name];\n }\n\n /**\n * Sets the accessible label of the resize handle.\n * @param value The label text.\n */\n public setAccessibleLabel(value: string): void {\n this._handle.setAttribute('aria-label', value);\n }\n\n /**\n * Sets the disabled state of the component.\n * @param value Whether the component is disabled.\n */\n public setDisabled(value: boolean): void {\n this._root.classList.toggle(SPLIT_VIEW_PANEL_CONSTANTS.classes.DISABLED, value);\n if (this._handle) {\n this._handle.setAttribute('tabindex', value ? '-1' : '0');\n toggleAttribute(this._handle, value, 'aria-disabled', 'true');\n }\n }\n\n /**\n * Sets the whether the component's handle is present and at its start or end.\n * @param value The component's resizable value.\n */\n public setResizable(value: SplitViewPanelResizable): void {\n this._root.setAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.RESIZABLE, value.toString());\n toggleAttribute(this._handle, value !== 'off', 'aria-valuemin', '0');\n toggleAttribute(this._handle, value !== 'off', 'aria-valuemax', '100');\n\n if (value === 'off') {\n return;\n }\n\n this._handle.remove();\n if (value === 'end') {\n // Place the handle after the content\n this._root.append(this._handle);\n } else {\n // Place the handle before the content\n this._root.prepend(this._handle);\n }\n }\n\n /**\n * Sets the orientation of the component including ARIA attributes and the resize handle icon.\n * @param value The component's orientation.\n */\n public setOrientation(value: SplitViewOrientation): void {\n this._root.setAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.ORIENTATION, value);\n // The divider's orientation is perpendicular to the layout of the component\n this._handle.setAttribute('aria-orientation', value === 'horizontal' ? 'vertical' : 'horizontal');\n this._icon.setAttribute('name', getHandleIcon(value));\n }\n\n /**\n * Opens or closes the component.\n * @param value Whether the component is open.\n * @param withAnimation Whether to use the animation. Defaults to `true`.\n */\n public setOpen(value: boolean, withAnimation = true, event?: ISplitViewPanelOpenEvent): void {\n const finish = (): void => {\n if (!value) {\n this._root.classList.add(SPLIT_VIEW_PANEL_CONSTANTS.classes.CLOSED);\n }\n if (event) {\n this.emitHostEvent(value ? SPLIT_VIEW_PANEL_CONSTANTS.events.DID_OPEN : SPLIT_VIEW_PANEL_CONSTANTS.events.DID_CLOSE, event);\n }\n this._parent?.unlayerSlottedPanels();\n this._parent?.update({ accessibility: true, cursor: true });\n };\n\n if (value && this._root.classList.contains(SPLIT_VIEW_PANEL_CONSTANTS.classes.CLOSED)) {\n this._root.classList.remove(SPLIT_VIEW_PANEL_CONSTANTS.classes.CLOSED);\n\n if (!withAnimation) {\n finish();\n return;\n }\n\n this._parent?.layerSlottedPanels(this._component);\n playKeyframeAnimation(this._root, SPLIT_VIEW_PANEL_CONSTANTS.classes.OPENING, true).then(() => {\n finish();\n });\n } else if (!value && !this._root.classList.contains(SPLIT_VIEW_PANEL_CONSTANTS.classes.CLOSED)) {\n\n if (!withAnimation) {\n finish();\n return;\n }\n\n this._parent?.layerSlottedPanels(this._component);\n playKeyframeAnimation(this._root, SPLIT_VIEW_PANEL_CONSTANTS.classes.CLOSING, true).then(() => {\n finish();\n });\n }\n }\n\n /**\n * Sets the components appearance and accessibility to indicated whether it is currently grabbed\n * by the user. Applies a cursor style to the document body.\n * @param value Whether the component is currently being resized via pointer interaction.\n */\n public setGrabbed(value: boolean): void {\n this._root.classList.toggle(SPLIT_VIEW_PANEL_CONSTANTS.classes.GRABBED, value);\n this._handle.setAttribute('aria-grabbed', value.toString());\n\n if (value) {\n if (!this._overlay) {\n this._overlay = createOverlay();\n }\n document.body.append(this._overlay);\n } else {\n this._overlay?.remove();\n }\n }\n\n /**\n * Applies a cursor style to the resize handle. \n * @param orientation The component's orientation. If absent the cursor will be removed.\n * @param config The component's resizable value and whether it's at the min or max value.\n */\n public setHandleCursor(orientation?: SplitViewOrientation, config?: ISplitViewPanelCursorConfig): void {\n if (orientation) {\n this._root.style.setProperty(SPLIT_VIEW_PANEL_CONSTANTS.customCssProperties.CURSOR, getCursor(orientation, config));\n } else {\n this._root.style.removeProperty(SPLIT_VIEW_PANEL_CONSTANTS.customCssProperties.CURSOR);\n }\n }\n\n /**\n * Applies a cursor style to the overlay element covering the document body.\n * @param orientation The component's orientation.\n * @param config The component's resizable value and whether it's at the min or max value.\n */\n public setBodyCursor(orientation: SplitViewOrientation, config?: ISplitViewPanelCursorConfig): void {\n this._overlay?.style.setProperty('cursor', getCursor(orientation, config));\n }\n\n /**\n * Gets the size of the content along the orientation axis. Does not include the resize handle.\n * @param orientation The component's orientation.\n * @returns The width or height of the content in pixels.\n */\n public getContentSize(orientation: SplitViewOrientation): number {\n return orientation === 'horizontal' ? this._content.clientWidth : this._content.clientHeight;\n }\n\n /**\n * Sets the size of the content not including the resize handle.\n * @param value The width or height of the content in pixels.\n */\n public setContentSize(value: number): void {\n this._component.style.setProperty(SPLIT_VIEW_PANEL_CONSTANTS.customCssProperties.SIZE, `${value}px`);\n }\n\n /**\n * Sets the ARIA attribute representing the size of the content compared to its min and max.\n * @param value The content size scaled from 0 to 100.\n */\n public setValuenow(value: number): void {\n this._handle.setAttribute('aria-valuenow', value.toFixed(2));\n }\n\n /**\n * Sets focus on the handle element.\n */\n public focusHandle(): void {\n this._handle.focus();\n }\n\n /**\n * Gets the amount of space that the component is allowed to take. This includes the current\n * size of the component and the size of the sibling it resizes into along the axis of\n * orientation. The sibling's min and max values are taken into account but the component's are\n * not.\n * @param orientation The component's orientation.\n * @param resizable The component's resizable value.\n * @returns The amount of space available for the component to resize into in pixels.\n */\n public getAvailableSpace(orientation: SplitViewOrientation, resizable: SplitViewPanelResizable): number {\n if (resizable === 'off') {\n // Return -1 if the panel is static (i.e. can't be user resized)\n return -1;\n }\n const sibling = getSplitViewPanelSibling(this._component);\n if (sibling) {\n const siblingSize = sibling.getCollapsibleSize();\n return siblingSize + this.getContentSize(orientation);\n } else {\n return this.getParentSize(orientation);\n }\n }\n\n /**\n * Gets the content size of the sibling panel the component resizes into along its axis of\n * orientation.\n * @returns The sibling's content size in pixels or 0 if the sibling does not exist.\n */\n public getSiblingContentSize(): number {\n const sibling = getSplitViewPanelSibling(this._component);\n return sibling?.getContentSize() ?? 0;\n }\n\n /**\n * Sets the content size of the sibling panel the component resizes into along its axis of\n * orientation.\n * @returns The sibling's content size in pixels.\n */\n public setSiblingContentSize(value: number): void {\n const sibling = getSplitViewPanelSibling(this._component);\n sibling?.setContentSize(value);\n }\n\n /**\n * Runs the ripple animation.\n * @param fromActivated Whether the ripple starts from and should end in an activated state.\n */\n public activateRipple(fromActivated: boolean): void {\n if (fromActivated) {\n this._ripple.deactivate();\n // Wait a short amount of time so the animation is distinguishable\n window.setTimeout(() => {\n this._ripple.activate();\n }, SPLIT_VIEW_PANEL_CONSTANTS.numbers.RIPPLE_ACTIVATION_WAIT);\n } else {\n this._ripple.activate();\n this._ripple.deactivate();\n }\n }\n\n /**\n * Deactivates the ripple.\n */\n public deactivateRipple(): void {\n this._ripple.deactivate();\n }\n\n /**\n * Gets the size of the parent split view along the axis of orientation.\n * @param orientation The component's orientation.\n * @returns The parent's size in pixels.\n */\n public getParentSize(orientation: SplitViewOrientation): number {\n const parentSize = orientation === 'horizontal' ? this._parent?.clientWidth : this._parent?.clientHeight;\n return parentSize ?? 0;\n }\n\n /**\n * Updates the provided characteristics of all panels.\n * @param config An update configuration.\n */\n public updateParent(config: ISplitViewUpdateConfig): void {\n this._parent?.update(config);\n }\n}\n", "import { CustomElement, attachShadowTemplate, FoundationProperty, coerceBoolean, coerceNumber } from '@tylertech/forge-core';\nimport { tylIconDragVerticalVariant } from '@tylertech/tyler-icons/extended';\nimport { tylIconDragHandle } from '@tylertech/tyler-icons/standard';\n\nimport { BaseComponent, IBaseComponent } from '../../core/base/base-component';\nimport { ISplitViewPanelOpenEvent, ISplitViewPanelWillResizeEvent, SplitViewPanelResizable, SPLIT_VIEW_PANEL_CONSTANTS } from './split-view-panel-constants';\nimport { SplitViewPanelFoundation } from './split-view-panel-foundation';\nimport { SplitViewPanelAdapter } from './split-view-panel-adapter';\nimport { ISplitViewUpdateConfig } from '../split-view/split-view-constants';\nimport { ISplitViewBase } from '../core/split-view-base';\nimport { IconComponent, IconRegistry } from '../../icon';\nimport { RippleComponent } from '../../ripple';\n\nconst template = '<template><div class=\\\"forge-split-view-panel\\\" id=\\\"root\\\" part=\\\"root\\\"><div class=\\\"forge-split-view-panel__handle\\\" id=\\\"handle\\\" part=\\\"handle\\\" role=\\\"separator\\\" aria-controls=\\\"content\\\" aria-grabbed=\\\"false\\\" tabindex=\\\"0\\\"><forge-icon class=\\\"forge-split-view-panel__icon\\\" id=\\\"icon\\\" part=\\\"icon\\\"></forge-icon><forge-ripple id=\\\"ripple\\\" part=\\\"ripple\\\"></forge-ripple></div><div class=\\\"forge-split-view-panel__content\\\" id=\\\"content\\\" part=\\\"content\\\" role=\\\"group\\\"><slot></slot></div></div></template>';\nconst styles = '@-webkit-keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@-webkit-keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@-webkit-keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}@keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.mdc-ripple-surface{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:transparent;will-change:transform,opacity;position:relative;outline:0;overflow:hidden}.mdc-ripple-surface::after,.mdc-ripple-surface::before{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:\\\"\\\"}.mdc-ripple-surface::before{-webkit-transition:opacity 15ms linear,background-color 15ms linear;transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index,1)}.mdc-ripple-surface::after{z-index:0;z-index:var(--mdc-ripple-z-index,0)}.mdc-ripple-surface.mdc-ripple-upgraded::before{-webkit-transform:scale(var(--mdc-ripple-fg-scale,1));transform:scale(var(--mdc-ripple-fg-scale,1))}.mdc-ripple-surface.mdc-ripple-upgraded::after{top:0;left:0;-webkit-transform:scale(0);transform:scale(0);-webkit-transform-origin:center center;transform-origin:center center}.mdc-ripple-surface.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top,0);left:var(--mdc-ripple-left,0)}.mdc-ripple-surface.mdc-ripple-upgraded--foreground-activation::after{-webkit-animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards;animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.mdc-ripple-surface.mdc-ripple-upgraded--foreground-deactivation::after{-webkit-animation:mdc-ripple-fg-opacity-out 150ms;animation:mdc-ripple-fg-opacity-out 150ms;-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}.mdc-ripple-surface::after,.mdc-ripple-surface::before{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.mdc-ripple-surface.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.mdc-ripple-surface[data-mdc-ripple-is-unbounded],.mdc-ripple-upgraded--unbounded{overflow:visible}.mdc-ripple-surface[data-mdc-ripple-is-unbounded]::after,.mdc-ripple-surface[data-mdc-ripple-is-unbounded]::before,.mdc-ripple-upgraded--unbounded::after,.mdc-ripple-upgraded--unbounded::before{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::after,.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::before,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::after,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::before{top:var(--mdc-ripple-top,calc(50% - 50%));left:var(--mdc-ripple-left,calc(50% - 50%));width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::after,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.mdc-ripple-surface::after,.mdc-ripple-surface::before{background-color:#000;background-color:var(--mdc-ripple-color,#000)}.mdc-ripple-surface.mdc-ripple-surface--hover::before,.mdc-ripple-surface:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.mdc-ripple-surface.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.mdc-ripple-surface:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.mdc-ripple-surface:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.mdc-ripple-surface.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-ripple-surface::after,.mdc-ripple-surface::before{--mdc-ripple-color:var(--mdc-theme-on-surface)}.forge-split-view-panel{display:-webkit-box;display:flex;width:100%;height:100%;overflow:hidden;contain:paint size}.forge-split-view-panel__handle{color:rgba(0,0,0,.54);color:var(--mdc-theme-text-secondary-on-light,rgba(0,0,0,.54));background-color:#e0e0e0;background-color:var(--forge-theme-border-color,#e0e0e0);display:-webkit-box;display:flex;flex-shrink:0;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;outline:0}.forge-split-view-panel__content{-webkit-box-flex:1;flex:1;overflow:hidden}.forge-split-view-panel--closed{display:none}.forge-split-view-panel--disabled #handle{pointer-events:none}.forge-split-view-panel--disabled .forge-split-view-panel__icon{display:none}.forge-split-view-panel[orientation=horizontal]{min-width:8px;min-width:var(--forge-split-view-handle-width,8px);width:calc(var(--forge-split-view-panel-size,unset) + var(--forge-split-view-handle-width,8px));-webkit-box-orient:horizontal;-webkit-box-direction:normal;flex-direction:row}.forge-split-view-panel[orientation=horizontal] .forge-split-view-panel__handle{width:8px;width:var(--forge-split-view-handle-width,8px);cursor:var(--forge-split-view-panel-cursor)}.forge-split-view-panel[orientation=horizontal].forge-split-view-panel--closing[resizable=end]{position:absolute;top:0;left:0;-webkit-animation-name:uaup4en;animation-name:uaup4en;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1)}@-webkit-keyframes uaup4en{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}@keyframes uaup4en{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}.forge-split-view-panel[orientation=horizontal].forge-split-view-panel--closing[resizable=start]{position:absolute;top:0;right:0;-webkit-animation-name:uaup4ez;animation-name:uaup4ez;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1)}@-webkit-keyframes uaup4ez{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(100%);transform:translateX(100%)}}@keyframes uaup4ez{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(100%);transform:translateX(100%)}}.forge-split-view-panel[orientation=horizontal].forge-split-view-panel--opening[resizable=end]{position:absolute;top:0;left:0;-webkit-animation-name:uaup4fe;animation-name:uaup4fe;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-direction:reverse}@-webkit-keyframes uaup4fe{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}@keyframes uaup4fe{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}.forge-split-view-panel[orientation=horizontal].forge-split-view-panel--opening[resizable=start]{position:absolute;top:0;right:0;-webkit-animation-name:uaup4fr;animation-name:uaup4fr;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-direction:reverse}@-webkit-keyframes uaup4fr{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(100%);transform:translateX(100%)}}@keyframes uaup4fr{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(100%);transform:translateX(100%)}}.forge-split-view-panel[orientation=vertical]{min-height:8px;min-height:var(--forge-split-view-handle-width,8px);height:calc(var(--forge-split-view-panel-size,unset) + var(--forge-split-view-handle-width,8px));-webkit-box-orient:vertical;-webkit-box-direction:normal;flex-direction:column}.forge-split-view-panel[orientation=vertical] .forge-split-view-panel__handle{height:8px;height:var(--forge-split-view-handle-width,8px);cursor:var(--forge-split-view-panel-cursor)}.forge-split-view-panel[orientation=vertical].forge-split-view-panel--closing[resizable=end]{position:absolute;top:0;left:0;-webkit-animation-name:uaup4gh;animation-name:uaup4gh;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1)}@-webkit-keyframes uaup4gh{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}@keyframes uaup4gh{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}.forge-split-view-panel[orientation=vertical].forge-split-view-panel--closing[resizable=start]{position:absolute;bottom:0;left:0;-webkit-animation-name:uaup4h2;animation-name:uaup4h2;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1)}@-webkit-keyframes uaup4h2{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}@keyframes uaup4h2{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}.forge-split-view-panel[orientation=vertical].forge-split-view-panel--opening[resizable=end]{position:absolute;top:0;left:0;-webkit-animation-name:uaup4hi;animation-name:uaup4hi;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-direction:reverse}@-webkit-keyframes uaup4hi{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}@keyframes uaup4hi{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}.forge-split-view-panel[orientation=vertical].forge-split-view-panel--opening[resizable=start]{position:absolute;bottom:0;left:0;-webkit-animation-name:uaup4i4;animation-name:uaup4i4;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-direction:reverse}@-webkit-keyframes uaup4i4{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}@keyframes uaup4i4{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}:host{z-index:var(--forge-split-view-animating-layer)!important;display:block;position:relative;height:100%;width:100%;-webkit-box-flex:0;flex:0}:host([hidden]){display:none}:host(:not([resizable=start],[resizable=end])){-webkit-box-flex:1;flex:1}:host(:not([resizable=start],[resizable=end])) .forge-split-view-panel{width:100%;height:100%;min-width:0;min-height:0}:host(:not([resizable=start],[resizable=end])) .forge-split-view-panel__handle{display:none}';\n\nexport interface ISplitViewPanelComponent extends Partial<ISplitViewBase>, IBaseComponent {\n resizable: SplitViewPanelResizable;\n size: number | string;\n min: number | string;\n max: number | string | undefined;\n accessibleLabel: string;\n open: boolean;\n getContentSize(): number;\n getCollapsibleSize(): number;\n setContentSize(size: number): void;\n update(config: ISplitViewUpdateConfig): void;\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'forge-split-view-panel': ISplitViewPanelComponent;\n }\n\n interface HTMLElementEventMap {\n 'forge-split-view-panel-will-resize': CustomEvent<ISplitViewPanelWillResizeEvent>;\n 'forge-split-view-panel-resize-start': CustomEvent<null>;\n 'forge-split-view-panel-resize-end': CustomEvent<null>;\n 'forge-split-view-panel-resize': CustomEvent<number>;\n 'forge-split-view-panel-will-open': CustomEvent<ISplitViewPanelOpenEvent>;\n 'forge-split-view-panel-will-close': CustomEvent<ISplitViewPanelOpenEvent>;\n 'forge-split-view-panel-did-open': CustomEvent<ISplitViewPanelOpenEvent>;\n 'forge-split-view-panel-did-close': CustomEvent<ISplitViewPanelOpenEvent>;\n }\n}\n\n/**\n * The custom element class behind the `<forge-split-view-panel>` element.\n * \n * @tag forge-split-view-panel\n */\n@CustomElement({\n name: SPLIT_VIEW_PANEL_CONSTANTS.elementName,\n dependencies: [\n IconComponent,\n RippleComponent\n ]\n})\nexport class SplitViewPanelComponent extends BaseComponent implements ISplitViewPanelComponent {\n public static get observedAttributes(): string[] {\n return [\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.RESIZABLE,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.SIZE,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.MIN,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.MAX,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.ACCESSIBLE_LABEL,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.OPEN,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.DISABLED,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.ALLOW_CLOSE,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE_THRESHOLD\n ];\n }\n\n private _foundation: SplitViewPanelFoundation;\n\n constructor() {\n super();\n IconRegistry.define([tylIconDragVerticalVariant, tylIconDragHandle]);\n attachShadowTemplate(this, template, styles);\n this._foundation = new SplitViewPanelFoundation(new SplitViewPanelAdapter(this));\n }\n\n public connectedCallback(): void {\n this._foundation.initialize();\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 SPLIT_VIEW_PANEL_CONSTANTS.attributes.RESIZABLE:\n this.resizable = newValue as SplitViewPanelResizable;\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.SIZE:\n this.size = newValue;\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.MIN:\n this.min = newValue;\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.MAX:\n if (newValue) {\n this.max = newValue;\n } else {\n this.max = undefined;\n }\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.ACCESSIBLE_LABEL:\n this.accessibleLabel = newValue;\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.OPEN:\n this.open = coerceBoolean(newValue);\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.DISABLED:\n if (this.hasAttribute(name)) {\n this.disabled = coerceBoolean(newValue);\n } else {\n this.disabled = undefined;\n }\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.ALLOW_CLOSE:\n if (this.hasAttribute(name)) {\n this.allowClose = coerceBoolean(newValue);\n } else {\n this.allowClose = undefined;\n }\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE:\n if (this.hasAttribute(name)) {\n this.autoClose = coerceBoolean(newValue);\n } else {\n this.autoClose = undefined;\n }\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE_THRESHOLD:\n if (newValue) {\n this.autoCloseThreshold = coerceNumber(newValue);\n } else {\n this.autoCloseThreshold = undefined;\n }\n break;\n }\n }\n\n /**\n * Controls which side of the panel the resize handle appears on.\n */\n @FoundationProperty()\n public resizable: SplitViewPanelResizable;\n\n /**\n * The initial size along the axis of orientation.\n */\n @FoundationProperty()\n public size: number | string;\n\n /**\n * The smallest size the panel can take along its axis of orientation.\n */\n @FoundationProperty()\n public min: number | string;\n\n /**\n * The largest size the panel can take along its axis of orientation.\n */\n @FoundationProperty()\n public max: number | string | undefined;\n\n /**\n * The ARIA label given to the resize handle.\n */\n @FoundationProperty()\n public accessibleLabel: string;\n\n /**\n * Controls the open state of the panel.\n */\n @FoundationProperty()\n public open: boolean;\n\n /**\n * Whether resize interactions are disabled or enabled.\n */\n @FoundationProperty()\n public disabled?: boolean;\n\n /**\n * Whether the panel can be closed via keyboard interaction.\n */\n @FoundationProperty()\n public allowClose?: boolean;\n\n /**\n * Whether the panel automatically closes when it reaches a size of 0.\n */\n @FoundationProperty()\n public autoClose?: boolean;\n\n /**\n * The size at which the panel auto closes.\n */\n @FoundationProperty()\n public autoCloseThreshold?: number;\n\n /**\n * Gets the size of content along the axis of orientation.\n * @returns The size of content in pixels.\n */\n public getContentSize(): number {\n return this._foundation.getContentSize();\n }\n\n /**\n * Gets the amount that the content can shrink along the axis of orientation before reaching its\n * min size.\n * @returns The amount that content can shrink in pixels.\n */\n public getCollapsibleSize(): number {\n return this._foundation.getCollapsibleSize();\n }\n\n /**\n * Sets the size of content along the axis of orientation.\n * @param size The new size of content in pixels.\n */\n public setContentSize(size: number): void {\n this._foundation.setContentSize(size);\n }\n\n /**\n * Updates the provided characteristics.\n * @param config An update configuration.\n */\n public update(config: ISplitViewUpdateConfig): void {\n this._foundation.update(config);\n }\n}\n", "import { defineCustomElement } from '@tylertech/forge-core';\n\nimport { SplitViewPanelComponent } from './split-view-panel';\n\nexport * from './split-view-panel-adapter';\nexport * from './split-view-panel-constants';\nexport * from './split-view-panel-foundation';\nexport * from './split-view-panel';\nexport * from './split-view-panel-utils';\n\nexport function defineSplitViewPanelComponent(): void {\n defineCustomElement(SplitViewPanelComponent);\n}\n"],
4
+ "sourcesContent": ["import { COMPONENT_NAME_PREFIX } from '../../constants';\nimport { SplitViewOrientation } from '../split-view/split-view-constants';\n\nconst elementName: keyof HTMLElementTagNameMap = `${COMPONENT_NAME_PREFIX}split-view-panel`;\n\nconst attributes = {\n RESIZABLE: 'resizable',\n SIZE: 'size',\n MIN: 'min',\n MAX: 'max',\n OPEN: 'open',\n ACCESSIBLE_LABEL: 'accessible-label',\n DISABLED: 'disabled',\n ALLOW_CLOSE: 'allow-close',\n AUTO_CLOSE: 'auto-close',\n AUTO_CLOSE_THRESHOLD: 'auto-close-threshold',\n ORIENTATION: 'orientation'\n};\n\nconst classes = {\n ROOT: 'forge-split-view-panel',\n GRABBED: 'forge-split-view-panel--grabbed',\n HANDLE: 'forge-split-view-panel__handle',\n ICON: 'forge-split-view-panel__icon',\n CONTENT: 'forge-split-view-panel__content',\n CLOSED: 'forge-split-view-panel--closed',\n CLOSING: 'forge-split-view-panel--closing',\n OPENING: 'forge-split-view-panel--opening',\n DISABLED: 'forge-split-view-panel--disabled',\n OVERLAY: 'forge-split-view-panel-overlay'\n};\n\nconst ids = {\n ROOT: 'root',\n HANDLE: 'handle',\n ICON: 'icon',\n RIPPLE: 'ripple',\n CONTENT: 'content'\n};\n\nconst selectors = {\n ROOT: `#${ids.ROOT}`,\n HANDLE: `#${ids.HANDLE}`,\n ICON: `#${ids.ICON}`,\n RIPPLE: `#${ids.RIPPLE}`,\n CONTENT: `#${ids.CONTENT}`\n};\n\nconst events = {\n WILL_RESIZE: `${elementName}-will-resize`,\n RESIZE_START: `${elementName}-resize-start`,\n RESIZE_END: `${elementName}-resize-end`,\n RESIZE: `${elementName}-resize`,\n DID_OPEN: `${elementName}-did-open`,\n DID_CLOSE: `${elementName}-did-close`,\n WILL_OPEN: `${elementName}-will-open`,\n WILL_CLOSE: `${elementName}-will-close`\n};\n\nconst numbers = {\n RIPPLE_ACTIVATION_WAIT: 200\n};\n\nconst customCssProperties = {\n SIZE: '--forge-split-view-panel-size',\n CURSOR: '--forge-split-view-panel-cursor'\n};\n\nexport const SPLIT_VIEW_PANEL_CONSTANTS = {\n elementName,\n attributes,\n classes,\n ids,\n selectors,\n events,\n numbers,\n customCssProperties\n};\n\n// 'start' panels have a handle on the left/top and collapse to the right/bottom\n// 'end' panels have a handle on the right/bottom and collapse to the left/top\n// 'off' panels don't have a handle, are not resizable, and fill the remaining space\nexport type SplitViewPanelResizable = 'start' | 'end' | 'off';\n\nexport type SplitViewInputDeviceType = 'pointer' | 'keyboard';\n\nexport enum SplitViewAnimatingLayer {\n Under = 1,\n Active = 2,\n Above = 3\n}\n\nexport interface ISplitViewPanelCursorConfig {\n resizable: SplitViewPanelResizable;\n boundary: 'min' | 'max' | 'none';\n}\n\nexport interface ISplitViewPanelState {\n orientation: SplitViewOrientation;\n resizable: SplitViewPanelResizable;\n arrowKeyHeld: boolean;\n startPoint?: number;\n startSize?: number;\n currentSize?: number;\n availableSpace?: number;\n siblingSize?: number;\n keyboardDelta: number;\n isAtMin: boolean;\n isAtMax: boolean;\n min: number;\n max?: number;\n}\n\nexport interface ISplitViewPanelWillResizeEvent {\n inputDeviceType: SplitViewInputDeviceType;\n}\n\nexport interface ISplitViewPanelOpenEvent {\n auto: boolean;\n userInitiated: boolean;\n}\n", "import { percentToPixels, safeMin, scaleValue } from '../../core/utils/utils';\nimport { ISplitViewPanelCursorConfig, ISplitViewPanelState, SplitViewInputDeviceType, SPLIT_VIEW_PANEL_CONSTANTS } from './split-view-panel-constants';\nimport { ISplitViewPanelAdapter } from './split-view-panel-adapter';\nimport { SplitViewOrientation } from '../split-view/split-view-constants';\nimport { ISplitViewPanelComponent, SplitViewPanelComponent } from './split-view-panel';\n\n/**\n * Creates a default split view panel state object.\n * @returns A new state object.\n */\nexport function initState(): ISplitViewPanelState {\n return {\n orientation: 'horizontal',\n resizable: 'off',\n arrowKeyHeld: false,\n keyboardDelta: 0,\n isAtMin: false,\n isAtMax: false,\n min: 0\n };\n}\n\n/**\n * Gets a state object reflecting the panel's parameters at the beginning of a resize.\n * @param adapter The panel's adapter.\n * @param state The panel's state object.\n * @returns An updated state object.\n */\nexport function setState(adapter: ISplitViewPanelAdapter, state: ISplitViewPanelState): ISplitViewPanelState {\n const currentSize = adapter.getContentSize(state.orientation);\n return {\n ...state,\n currentSize,\n startSize: currentSize,\n availableSpace: adapter.getAvailableSpace(state.orientation, state.resizable),\n siblingSize: adapter.getSiblingContentSize(),\n isAtMin: false,\n isAtMax: false\n };\n}\n\n/**\n * Gets a state object with all properties related to a resize reset to default.\n * @param state The panel's state object.\n * @returns An updated state object.\n */\nexport function clearState(state: ISplitViewPanelState): ISplitViewPanelState {\n return {\n ...state,\n arrowKeyHeld: false,\n keyboardDelta: 0,\n isAtMin: false,\n isAtMax: false\n };\n}\n\n/**\n * Performs a panel resize triggered by a pointer event.\n * @param adapter The panel's adapter.\n * @param evt The pointer event.\n * @param state The panel's state object.\n * @returns Whether a resize happened.\n */\nexport function pointerResize(adapter: ISplitViewPanelAdapter, evt: PointerEvent, state: ISplitViewPanelState): boolean {\n if (state.startPoint === undefined || state.startSize === undefined) {\n return false;\n }\n\n const initialSize = state.currentSize;\n\n const evtPoint = state.orientation === 'horizontal' ? evt.clientX : evt.clientY;\n let delta = state.startPoint - evtPoint;\n if (state.resizable === 'start') {\n delta *= -1;\n }\n\n const size = state.startSize - delta;\n state.currentSize = clampSize(size, state);\n adapter.setContentSize(state.currentSize);\n handleBoundariesDuringResize(adapter, state, 'pointer');\n adapter.setValuenow(getValuenow(state.currentSize, state));\n\n const siblingDelta = size - state.currentSize + delta;\n resizeSibling(adapter, siblingDelta, state);\n\n return initialSize !== state.currentSize;\n}\n\n/**\n * Performs a panel resize triggered by a keyboard event.\n * @param adapter The panel's adapter.\n * @param increment The pixel amount to change the panel's size.\n * @param state The panel's state object.\n * @returns Whether a resize happened.\n */\nexport function keyboardResize(adapter: ISplitViewPanelAdapter, increment: number, state: ISplitViewPanelState): boolean {\n if (state.startSize === undefined) {\n return false;\n }\n\n const initialSize = state.currentSize;\n\n state.keyboardDelta += increment;\n\n const size = state.startSize + state.keyboardDelta;\n state.currentSize = clampSize(size, state);\n adapter.setContentSize(state.currentSize);\n handleBoundariesDuringResize(adapter, state, 'keyboard');\n adapter.setValuenow(getValuenow(state.currentSize, state));\n\n const siblingDelta = size - state.currentSize + state.keyboardDelta * -1;\n resizeSibling(adapter, siblingDelta, state);\n\n return initialSize !== state.currentSize;\n}\n\n/**\n * Resizes a panel to its minimum possible size.\n * @param adapter The panel's adapter.\n * @param state The panel's state object.\n * @returns The new pixel size of the panel.\n */\nexport function minResize(adapter: ISplitViewPanelAdapter, state: ISplitViewPanelState): number {\n adapter.setContentSize(state.min);\n return state.min;\n}\n\n/**\n * Resizes a panel to its maximum possible size.\n * @param adapter The panel's adapter.\n * @param state The panel's state object.\n * @returns The new pixel size of the panel.\n */\nexport function maxResize(adapter: ISplitViewPanelAdapter, state: ISplitViewPanelState): number {\n const availableSpace = adapter.getAvailableSpace(state.orientation, state.resizable);\n const max = safeMin(state.max, availableSpace);\n adapter.setContentSize(max);\n return max;\n}\n\n/**\n * Sets a panel's sibling's size to reflect changes in the panel's size.\n * @param adapter The panel's adapter.\n * @param delta The change in size to apply to the sibling.\n * @param state The panel's state object.\n */\nexport function resizeSibling(adapter: ISplitViewPanelAdapter, delta: number, state: ISplitViewPanelState): void {\n if (state.siblingSize !== undefined) {\n const siblingSize = state.siblingSize + delta;\n adapter.setSiblingContentSize(siblingSize);\n }\n}\n\n/**\n * Returns a size limited to an allowed range.\n * @param size The size to try setting this panel to.\n * @param state The panel's state object.\n * @returns A pixel value.\n */\nexport function clampSize(size: number, state: ISplitViewPanelState): number {\n size = Math.max(size, state.min);\n size = safeMin(size, state.max, state.availableSpace);\n return size;\n}\n\n/**\n * Checks whether a panel is at its min or max size while resizing and runs logic related to\n * that once.\n * @param adapter The panel's adapter.\n * @param state The panel's state object.\n * @param inputDevice The input device responsible for the resize.\n * @returns Whether the panel is at its min or max size.\n */\nexport function handleBoundariesDuringResize(adapter: ISplitViewPanelAdapter, state: ISplitViewPanelState, inputDevice?: SplitViewInputDeviceType): boolean {\n if (state.currentSize === undefined) {\n return false;\n }\n\n // Check min\n if (state.currentSize <= state.min) {\n // Just reached the min\n if (!state.isAtMin) {\n adapter.activateRipple(inputDevice === 'pointer');\n if (inputDevice === 'pointer') {\n adapter.setBodyCursor(state.orientation, { resizable: state.resizable, boundary: 'min' });\n }\n state.isAtMin = true;\n }\n return true;\n } else if (state.isAtMin) {\n // TODO: is it more performant to have the else if condition or to always set the variable?\n state.isAtMin = false;\n }\n\n // Check max\n const max = safeMin(state.max, state.availableSpace);\n if (state.currentSize >= max) {\n // Just reached the max\n if(!state.isAtMax) {\n adapter.activateRipple(inputDevice === 'pointer');\n if (inputDevice === 'pointer') {\n adapter.setBodyCursor(state.orientation, { resizable: state.resizable, boundary: 'max' });\n }\n state.isAtMax = true;\n }\n return true;\n } else if (state.isAtMax) {\n state.isAtMax = false;\n }\n\n if (inputDevice === 'pointer') {\n adapter.setBodyCursor(state.orientation);\n }\n \n return false;\n}\n\n/**\n * Checks whether a panel is at its min or max size while not resizing and runs logic related to\n * that once.\n * @param adapter The panel's adapter.\n * @param size The panel's size.\n * @param state The panel's state object.\n * @returns Whether the panel is at its min or max size.\n */\nexport function handleBoundariesAfterResize(adapter: ISplitViewPanelAdapter, size: number, state: ISplitViewPanelState): boolean {\n if (size <= state.min) {\n adapter.setHandleCursor(state.orientation, { resizable: state.resizable, boundary: 'min' });\n return true;\n }\n\n const max = safeMin(state.max, state.availableSpace);\n if (size >= max) {\n adapter.setHandleCursor(state.orientation, { resizable: state.resizable, boundary: 'max' });\n return true;\n }\n\n adapter.setHandleCursor(state.orientation);\n return false;\n}\n\n/**\n * Gets the accessible valuenow of a panel.\n * @param size The panel's size in pixels.\n * @param state The panel's state object.\n */\nexport function getValuenow(size: number, state: ISplitViewPanelState): number {\n if (!state.availableSpace && !state.max) {\n return 100;\n }\n\n const max = safeMin(state.max, state.availableSpace);\n return scaleValue(size, state.min, max);\n}\n\n/**\n * Gets the appropriate cursor for the handle orientation.\n * @param orientation \n * @returns A CSS cursor keyword value.\n */\nexport function getCursor(orientation: SplitViewOrientation, config?: ISplitViewPanelCursorConfig): string {\n if (orientation === 'horizontal') {\n switch (config?.boundary) {\n case 'min':\n return config.resizable === 'end' ? 'e-resize' : 'w-resize';\n case 'max':\n return config.resizable === 'end' ? 'w-resize' : 'e-resize';\n default:\n return 'col-resize';\n }\n } else {\n switch (config?.boundary) {\n case 'min':\n return config.resizable === 'end' ? 's-resize' : 'n-resize';\n case 'max':\n return config.resizable === 'end' ? 'n-resize' : 's-resize';\n default:\n return 'row-resize';\n }\n }\n}\n\n/**\n * Gets the approporate drag icon for the handle orientation.\n * @param orientation \n * @returns A Forge icon name.\n */\nexport function getHandleIcon(orientation: SplitViewOrientation): string {\n return orientation === 'horizontal' ? 'drag_vertical_variant' : 'drag_handle';\n}\n\n/**\n * Gets the panel that the given panel resizes into.\n * @param el A split view panel.\n * @returns A sibling split view panel or undefined if there is not a sibling.\n */\nexport function getSplitViewPanelSibling(el: ISplitViewPanelComponent): SplitViewPanelComponent | undefined {\n const resizable = el.resizable;\n if (resizable === 'off') {\n return undefined;\n }\n \n let sibling: Element | null = el;\n do {\n sibling = resizable === 'end' ? sibling.nextElementSibling : sibling.previousElementSibling;\n } while (sibling instanceof SplitViewPanelComponent && !sibling.open);\n\n if (sibling instanceof SplitViewPanelComponent) {\n return sibling;\n }\n\n return undefined;\n}\n\n/**\n * Extracts a size and unit from a `number` or `string` formatted as a CSS dimension using px or %.\n * A `number` is interpreted to be a pixel value.\n * @param value A `number` or `string` representing a size in pixels or percent.\n * @returns An object containing the parsed size and unit.\n */\nexport function parseSize(value: number | string): { amount: number; unit: 'px' | '%' | '' } {\n if (!isNaN(+value)) {\n return { amount: +value, unit: 'px' };\n }\n\n // Matches digits with or without decimals, any amount of whitespace, and 'px' or '%'\n const regex = /(^\\d*\\.?\\d*)\\s*(px|%$)?/i;\n const parts = (value as string).match(regex);\n const amount = parts?.[1] ? +parts[1] : -1;\n const unit = (parts?.[2]?.toLowerCase() ?? '') as 'px' | '%' | '';\n\n return { amount, unit };\n}\n\n/**\n * Gets a pixel size value from a pixel or percent value.\n * @param value A `number` or `string` representing a size in pixels or percent.\n * @param parentSize The pixel size of the parent container along the relevant axis.\n * @returns A pixel amount.\n */\nexport function getPixelDimension(value: number | string, parentSize: number): number {\n const parsedSize = parseSize(value);\n\n if (parsedSize.unit === '%') {\n return percentToPixels(parsedSize.amount, parentSize);\n }\n return parsedSize.amount;\n}\n\n/**\n * Creates a transparent element to overlay on top of the document body, ensuring the split view\n * behaves as expected when dragging over other contexts.\n * @returns An overlay element.\n */\nexport function createOverlay(): HTMLElement {\n const el = document.createElement('div');\n el.classList.add(SPLIT_VIEW_PANEL_CONSTANTS.classes.OVERLAY);\n el.style.position = 'fixed';\n el.style.top = '0';\n el.style.left = '0';\n el.style.width = '100vw';\n el.style.height = '100vh';\n el.style.zIndex = '9999';\n return el;\n}\n", "import { ICustomElementFoundation, isDefined } from '@tylertech/forge-core';\n\nimport { safeMin, scaleValue } from '../../core/utils/utils';\nimport { eventIncludesArrowKey } from '../../core/utils/event-utils';\nimport { ISplitViewPanelOpenEvent, ISplitViewPanelState, SplitViewInputDeviceType, SplitViewPanelResizable, SPLIT_VIEW_PANEL_CONSTANTS } from './split-view-panel-constants';\nimport { ISplitViewPanelAdapter } from './split-view-panel-adapter';\nimport { ISplitViewUpdateConfig, SplitViewOrientation } from '../split-view/split-view-constants';\nimport { ISplitViewBase } from '../core/split-view-base';\nimport { clampSize, clearState, getPixelDimension, getValuenow, handleBoundariesAfterResize, handleBoundariesDuringResize, initState, keyboardResize, maxResize, minResize, pointerResize, setState } from './split-view-panel-utils';\n\nexport interface ISplitViewPanelFoundation extends Partial<ISplitViewBase>, ICustomElementFoundation {\n resizable: SplitViewPanelResizable;\n size: number | string;\n min: number | string;\n max: number | string | undefined;\n accessibleLabel: string;\n open: boolean;\n getContentSize(): number;\n getCollapsibleSize(): number;\n setContentSize(size: number): void;\n update(config: ISplitViewUpdateConfig): void;\n}\n\nexport class SplitViewPanelFoundation implements ISplitViewPanelFoundation {\n // API\n private _size: number | string = 200;\n private _min: number | string = 0;\n private _max: number | string | undefined;\n private _accessibleLabel = 'Split view panel';\n private _open = true;\n private _disabled?: boolean;\n private _allowClose?: boolean;\n private _autoClose?: boolean;\n private _autoCloseThreshold?: number;\n \n // State\n private _state: ISplitViewPanelState = initState();\n private _isInitialized = false;\n\n // Properties stored in state\n private get _orientation(): SplitViewOrientation {\n return this._state.orientation;\n }\n private set _orientation(value: SplitViewOrientation) {\n this._state.orientation = value;\n }\n\n private get _resizable(): SplitViewPanelResizable {\n return this._state.resizable;\n }\n private set _resizable(value: SplitViewPanelResizable) {\n this._state.resizable = value;\n }\n\n private get _pixelMin(): number {\n return this._state.min;\n }\n private set _pixelMin(value: number) {\n this._state.min = value;\n }\n\n private get _pixelMax(): number | undefined {\n return this._state.max;\n }\n private set _pixelMax(value: number | undefined) {\n this._state.max = value;\n }\n\n // Properties inherited from parent split view\n private _parentProperties: Partial<ISplitViewBase> = {};\n\n // Applied properties that can be inherited from parent\n private get _appliedDisabled(): boolean {\n return this._disabled ?? this._parentProperties.disabled ?? false;\n }\n\n private get _appliedAllowClose(): boolean {\n return this._allowClose ?? this._parentProperties.allowClose ?? false;\n }\n\n private get _appliedAutoClose(): boolean {\n return this._autoClose ?? this._parentProperties.autoClose ?? false;\n }\n\n private get _appliedAutoCloseThreshold(): number {\n return this._autoCloseThreshold ?? this._parentProperties.autoCloseThreshold ?? 0;\n }\n\n // Listeners\n private _pointerdownListener: (evt: PointerEvent) => void;\n private _pointerupListener: (evt: PointerEvent) => void;\n private _pointermoveListener: (evt: PointerEvent) => void;\n private _keydownListener: (evt: KeyboardEvent) => void;\n private _keyupListener: (evt: KeyboardEvent) => void;\n\n constructor(private _adapter: ISplitViewPanelAdapter) {\n this._pointerdownListener = evt => this._onPointerdown(evt);\n this._pointerupListener = evt => this._onPointerup(evt);\n this._pointermoveListener = evt => this._onPointermove(evt);\n this._keydownListener = evt => this._onKeydown(evt);\n this._keyupListener = evt => this._onKeyup(evt);\n }\n\n public initialize(): void {\n this._adapter.initialize();\n this._adapter.setPointerdownListener(this._pointerdownListener);\n this._adapter.setKeydownListener(this._keydownListener);\n this._getParentProperties();\n this._applyResizable();\n this._applyMin();\n this._applyMax();\n this._applySize();\n this._applyAccessibleLabel();\n this._applyOpen();\n this._applyDisabled();\n this._applyAllowClose();\n this._applyAutoClose();\n this._applyAutoCloseThreshold();\n this._isInitialized = true;\n }\n\n public disconnect(): void {\n this._adapter.tryRemoveOverlay();\n this._adapter.removePointerupListener(this._pointerupListener);\n this._adapter.removePointermoveListener(this._pointermoveListener);\n }\n\n /**\n * Handles a pointerdown event and sets further pointer event listeners.\n * @param evt The pointer event.\n */\n private _onPointerdown(evt: PointerEvent): void {\n if (this._appliedDisabled || !this._allowResize('pointer')) {\n return;\n }\n\n evt.preventDefault();\n\n this._adapter.setPointermoveListener(this._pointermoveListener);\n this._adapter.setPointerupListener(this._pointerupListener);\n this._handlePointerdown(evt);\n }\n\n /**\n * Handles a pointerup event and removes pointer event listeners.\n * @param evt The pointer event.\n */\n private _onPointerup(evt: PointerEvent): void {\n evt.preventDefault();\n\n this._adapter.removePointermoveListener(this._pointermoveListener);\n this._adapter.removePointerupListener(this._pointerupListener);\n this._handlePointerup();\n }\n\n /**\n * Handles a pointermove event and removes pointer events if the mouse button is released.\n * @param evt The pointer event.\n */\n private _onPointermove(evt: PointerEvent): void {\n if (this._appliedDisabled) {\n return;\n }\n\n evt.preventDefault();\n\n // Detect when the mouse button is released outside of the document\n if (evt.buttons === 0) {\n this._adapter.removePointermoveListener(this._pointermoveListener);\n this._adapter.removePointerupListener(this._pointerupListener);\n this._handlePointerup();\n return;\n }\n\n this._handlePointermove(evt);\n }\n\n /**\n * Handles a keydown event and sets a keyup listener if an arrow key is pressed.\n * @param evt The keyboard event.\n */\n private _onKeydown(evt: KeyboardEvent): void {\n if (this._appliedDisabled) {\n return;\n }\n\n if (evt.key === 'Enter') {\n this._handleEnterKey(evt);\n } else if (evt.key === 'Home' && this._allowResize('keyboard')) {\n this._handleHomeKey(evt);\n } else if (evt.key === 'End' && this._allowResize('keyboard')) {\n this._handleEndKey(evt);\n } else if (eventIncludesArrowKey(evt) && this._allowResize('keyboard')) {\n this._adapter.setKeyupListener(this._keyupListener);\n this._handleArrowKey(evt);\n }\n }\n\n /**\n * Handles a keyup event and removes the keyup listener if an arrow key was released.\n * @param evt The keyboard event.\n */\n private _onKeyup(evt: KeyboardEvent): void {\n if (eventIncludesArrowKey(evt)) {\n this._adapter.removeKeyupListener(this._keyupListener);\n this._handleArrowKeyUp();\n }\n }\n\n /**\n * Toggles the open state.\n * @param evt \n */\n private _handleEnterKey(evt: KeyboardEvent): void {\n if (!this._appliedAllowClose) {\n return;\n }\n\n evt.preventDefault();\n this._tryOpenOrClose(!this._open, false, true);\n }\n\n /**\n * Sets panel size to the min.\n * @param evt\n */\n private _handleHomeKey(evt: KeyboardEvent): void {\n evt.preventDefault();\n\n const size = minResize(this._adapter, this._state);\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE, size);\n this._tryAutoClose();\n }\n\n /**\n * Sets panel size to the max.\n * @param evt\n */\n private _handleEndKey(evt: KeyboardEvent): void {\n evt.preventDefault();\n\n const size = maxResize(this._adapter, this._state);\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE, size);\n }\n\n /**\n * Runs resize logic if an arrow key is included in the event.\n * @param evt \n */\n private _handleArrowKey(evt: KeyboardEvent): void {\n let increment = 0;\n if (this._orientation === 'horizontal') {\n switch (evt.key) {\n case 'ArrowLeft':\n increment = -1;\n break;\n case 'ArrowRight':\n increment = 1;\n break;\n default:\n return;\n }\n } else {\n switch (evt.key) {\n case 'ArrowUp':\n increment = -1;\n break;\n case 'ArrowDown':\n increment = 1;\n break;\n default:\n return;\n }\n }\n\n evt.preventDefault();\n\n if (this._resizable === 'start') {\n increment *= -1;\n }\n if (evt.shiftKey) {\n increment *= 10;\n }\n\n this._tryHandleArrowKeyDown();\n this._handleArrowKeyHeld(increment);\n }\n\n /**\n * Sets resize properties when an arrow key is first pressed.\n */\n private _tryHandleArrowKeyDown(): void {\n if (!this._state.arrowKeyHeld) {\n this._startResize();\n }\n this._state.arrowKeyHeld = true;\n }\n\n /**\n * Performs cleanup logic after a keyboard driven resize.\n */\n private _handleArrowKeyUp(): void {\n this._endResize();\n }\n\n /**\n * Resizes the panel by a set amount.\n * @param increment The pixel change in size.\n */\n private _handleArrowKeyHeld(increment: number): void {\n if (keyboardResize(this._adapter, increment, this._state)) {\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE, this._state.currentSize);\n }\n }\n\n /**\n * Handles the beginning of a pointer driven resize.\n * @param evt \n */\n private _handlePointerdown(evt: MouseEvent): void {\n this._adapter.setGrabbed(true);\n this._adapter.focusHandle();\n \n this._startResize();\n this._state.startPoint = this._orientation === 'horizontal' ? evt.clientX : evt.clientY;\n handleBoundariesDuringResize(this._adapter, this._state, 'pointer');\n }\n\n /**\n * Handles the end of a pointer driven resize.\n */\n private _handlePointerup(): void {\n this._adapter.setGrabbed(false);\n this._adapter.deactivateRipple();\n this._endResize();\n }\n\n /**\n * Resizes the panel from a pointer event.\n * @param evt \n */\n private _handlePointermove(evt: PointerEvent): void {\n if(pointerResize(this._adapter, evt, this._state)) {\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE, this._state.currentSize);\n }\n }\n\n /**\n * Emits a will resize event and allows it to be cancelled.\n * @returns Whether the resize should proceed.\n */\n private _allowResize(inputDeviceType: SplitViewInputDeviceType): boolean {\n return this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.WILL_RESIZE, { inputDeviceType }, true, true);\n }\n\n /**\n * Handles common logic to begin a resize.\n */\n private _startResize(): void {\n this._state = setState(this._adapter, this._state);\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE_START, this._state.startSize);\n }\n\n /**\n * Handles common logic to end a resize.\n */\n private _endResize(): void {\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE_END, this._state.currentSize);\n this._adapter.updateParent({ accessibility: this._state.startSize !== this._state.currentSize, cursor: true });\n this._state = clearState(this._state);\n this._tryAutoClose();\n }\n\n /**\n * Emits a will open or will close event and sets the panel open or closed if allowed.\n * @param shouldOpen Whether the panel should open or close. Defaults to `true`.\n * @param auto Whether the panel auto-opened or auto-closed.\n * @param userInitiated Whether opening or closing via user action instead of programmatically.\n */\n private _tryOpenOrClose(shouldOpen = true, auto = false, userInitiated = false): void {\n const eventType = shouldOpen ? SPLIT_VIEW_PANEL_CONSTANTS.events.WILL_OPEN : SPLIT_VIEW_PANEL_CONSTANTS.events.WILL_CLOSE;\n const event: ISplitViewPanelOpenEvent = {\n auto,\n userInitiated\n };\n const isAllowed = this._adapter.emitHostEvent(eventType, event, true, true);\n if (!isAllowed) {\n return;\n }\n this._open = shouldOpen;\n this._applyOpen(event);\n }\n\n /**\n * Auto close the panel if enabled and within the size threshold.\n */\n private _tryAutoClose(): void {\n const size = this._adapter.getContentSize(this._orientation);\n if (this._appliedAutoClose && size <= this._appliedAutoCloseThreshold) {\n this._tryOpenOrClose(false, true, false);\n }\n }\n\n /**\n * Sets orientation, disabled, disable close, and autoclose to reflect the parent split view.\n */\n private _getParentProperties(): void {\n // Parent disabled state\n const parentDisabled = this._adapter.getParentProperty('disabled') as boolean;\n this._parentProperties.disabled = parentDisabled;\n this._applyParentDisabled();\n\n // Parent disable close\n const parentAllowClose = this._adapter.getParentProperty('allowClose') as boolean;\n this._parentProperties.allowClose = parentAllowClose;\n\n // Parent auto close\n const parentAutoClose = this._adapter.getParentProperty('autoClose') as boolean;\n this._parentProperties.autoClose = parentAutoClose;\n this._applyParentAutoClose();\n\n // Parent auto close threshold\n const parentAutoCloseThreshold = this._adapter.getParentProperty('autoCloseThreshold') as number;\n this._parentProperties.autoCloseThreshold = parentAutoCloseThreshold;\n this._applyParentAutoCloseThreshold();\n }\n\n private _applyOrientation(): void {\n this._adapter.setOrientation(this._orientation);\n }\n\n /**\n * Get/set resizable. This affects the side the handle appears on and the direction the panel closes into.\n */\n public get resizable(): SplitViewPanelResizable {\n return this._resizable;\n }\n public set resizable(value: SplitViewPanelResizable) {\n if (this._resizable !== value) {\n this._resizable = value;\n this._applyResizable();\n }\n }\n\n private _applyResizable(): void {\n this._adapter.setHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.RESIZABLE, this._resizable);\n this._adapter.setResizable(this._resizable);\n }\n\n /**\n * Get/set panel size.\n */\n public get size(): number | string {\n return this._size;\n }\n public set size(value: number | string) {\n if (this._size.toString() !== value.toString()) {\n this._size = value;\n this._applySize();\n }\n }\n\n private _applySize(): void {\n const parentSize = this._adapter.getParentSize(this._orientation);\n const pixelSize = getPixelDimension(this._size, parentSize);\n\n this._adapter.setHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.SIZE, this._size.toString());\n this._adapter.setContentSize(pixelSize);\n // Wait for the DOM to render to get available space\n window.requestAnimationFrame(() => {\n const availableSpace = this._adapter.getAvailableSpace(this._orientation, this._resizable);\n const maxSize = safeMin(this._pixelMax, availableSpace);\n const newValue = scaleValue(pixelSize, this._pixelMin, maxSize);\n this._adapter.setValuenow(newValue);\n this._adapter.updateParent({ cursor: true });\n });\n }\n\n /** Get/set min panel size. */\n public get min(): number | string {\n return this._min;\n }\n public set min(value: number | string) {\n if (this._min.toString() !== value.toString()) {\n this._min = value;\n this._applyMin();\n }\n }\n\n private _applyMin(): void {\n this._adapter.setHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.MIN, this._min.toString());\n\n const parentSize = this._adapter.getParentSize(this._orientation);\n this._pixelMin = getPixelDimension(this._min, parentSize);\n\n if (this._resizable === 'off') {\n return;\n }\n\n const size = this._adapter.getContentSize(this._orientation);\n if (size < this._pixelMin) {\n this.setContentSize(size);\n }\n }\n\n /** Get/set max panel size. */\n public get max(): number | string | undefined {\n return this._max;\n }\n public set max(value: number | string | undefined) {\n if (this._max?.toString() !== value?.toString()) {\n this._max = value;\n this._applyMax();\n }\n }\n\n private _applyMax(): void {\n this._adapter.toggleHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.MAX, this._max !== undefined, this._max?.toString());\n\n if (this._max === undefined) {\n this._pixelMax = undefined;\n return;\n }\n\n const parentSize = this._adapter.getParentSize(this._orientation);\n this._pixelMax = getPixelDimension(this._max, parentSize);\n\n if (this._resizable === 'off') {\n return;\n }\n \n const size = this._adapter.getContentSize(this._orientation);\n if (size > this._pixelMax) {\n this.setContentSize(size);\n }\n }\n\n /**\n * Get/set the accessible label.\n */\n public get accessibleLabel(): string {\n return this._accessibleLabel;\n }\n public set accessibleLabel(value: string) {\n if (this._accessibleLabel !== value) {\n this._accessibleLabel = value;\n this._applyAccessibleLabel();\n }\n }\n\n private _applyAccessibleLabel(): void {\n this._adapter.setHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.ACCESSIBLE_LABEL, this._accessibleLabel);\n this._adapter.setAccessibleLabel(this._accessibleLabel);\n }\n\n /**\n * Get/set whether the panel is open.\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._tryOpenOrClose(value, false, false);\n return;\n }\n\n this._open = value;\n const event: ISplitViewPanelOpenEvent | undefined = this._isInitialized ? {\n auto: false,\n userInitiated: false\n } : undefined;\n this._applyOpen(event);\n }\n }\n\n private _applyOpen(event?: ISplitViewPanelOpenEvent): void {\n this._adapter.setHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.OPEN, this._open.toString());\n this._adapter.setOpen(this._open, this._isInitialized, event);\n }\n\n /**\n * Get/set whether interactions are disabled.\n */\n public get disabled(): boolean | undefined {\n return this._disabled;\n }\n public set disabled(value: boolean | undefined) {\n if (this._disabled !== value) {\n this._disabled = value;\n this._applyDisabled();\n }\n }\n\n private _applyDisabled(): void {\n this._adapter.toggleHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.DISABLED, this._disabled ?? false);\n this._adapter.setDisabled(this._appliedDisabled);\n }\n\n private _applyParentDisabled(): void {\n if (this._isInitialized && !isDefined(this._disabled)) {\n this._adapter.setDisabled(this._appliedDisabled);\n }\n }\n\n /**\n * Get/set whether closing the panel is disabled.\n */\n public get allowClose(): boolean | undefined {\n return this._allowClose;\n }\n public set allowClose(value: boolean | undefined) {\n if (this._allowClose !== value) {\n this._allowClose = value;\n this._applyAllowClose();\n }\n }\n\n private _applyAllowClose(): void {\n this._adapter.toggleHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.ALLOW_CLOSE, this._allowClose ?? false);\n }\n\n /**\n * Get/set whether the panel closes when a threshold size is reached.\n */\n public get autoClose(): boolean | undefined {\n return this._autoClose;\n }\n public set autoClose(value: boolean | undefined) {\n if (this._autoClose !== value) {\n this._autoClose = value;\n this._applyAutoClose();\n }\n }\n\n private _applyAutoClose(): void {\n this._adapter.toggleHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE, this._autoClose ?? false);\n if (this._isInitialized) {\n this._tryAutoClose();\n }\n }\n\n private _applyParentAutoClose(): void {\n if (this._isInitialized && !isDefined(this._autoClose)) {\n this._tryAutoClose();\n }\n }\n\n /** Get/set the size at which the panel auto closes. */\n public get autoCloseThreshold(): number | undefined {\n return this._autoCloseThreshold;\n }\n public set autoCloseThreshold(value: number | undefined) {\n if (this._autoCloseThreshold !== value) {\n this._autoCloseThreshold = value;\n this._applyAutoCloseThreshold();\n }\n }\n\n private _applyAutoCloseThreshold(): void {\n this._adapter.toggleHostAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE_THRESHOLD, isDefined(this._autoCloseThreshold), this.autoCloseThreshold?.toString());\n if (this._isInitialized) {\n this._tryAutoClose();\n }\n }\n\n private _applyParentAutoCloseThreshold(): void {\n if (this._isInitialized && !isDefined(this._autoCloseThreshold)) {\n this._tryAutoClose();\n }\n }\n\n /**\n * Gets the size of panel content without the handle.\n * @returns Content size in pixels.\n */\n public getContentSize(): number {\n return this._adapter.getContentSize(this._orientation);\n }\n\n /**\n * Gets how much the panel can shrink from its current size.\n * @returns The difference between the current and min size in pixels.\n */\n public getCollapsibleSize(): number {\n const parentSize = this._adapter.getParentSize(this._orientation);\n const pixelMin = getPixelDimension(this._min, parentSize);\n return this._adapter.getContentSize(this._orientation) - pixelMin;\n }\n\n /**\n * Sets a new size for the content area.\n * @param size The new content size in pixels.\n */\n public setContentSize(size: number): void {\n if (this._resizable === 'off') {\n return;\n }\n\n const newSize = clampSize(size, this._state);\n this._adapter.setContentSize(newSize);\n if (this._isInitialized) {\n this._adapter.emitHostEvent(SPLIT_VIEW_PANEL_CONSTANTS.events.RESIZE, newSize);\n }\n }\n\n /**\n * Updates the proved characteristics.\n * @param config An update configuration.\n */\n public update(config: ISplitViewUpdateConfig): void {\n // Orientation\n if (config.orientation) {\n this._orientation = config.orientation;\n this._applyOrientation();\n }\n\n // Parent properties\n if (config.properties) {\n if (isDefined(config.properties.disabled) && this._parentProperties.disabled !== config.properties.disabled) {\n this._parentProperties.disabled = config.properties.disabled;\n this._applyDisabled();\n }\n if (isDefined(config.properties.allowClose)) {\n this._parentProperties.allowClose = config.properties.allowClose;\n }\n if (isDefined(config.properties.autoClose) && this._parentProperties.autoClose !== config.properties.autoClose) {\n this._parentProperties.autoClose = config.properties.autoClose;\n if (!isDefined(this._autoClose)) {\n this._applyAutoClose();\n }\n }\n if (isDefined(config.properties.autoCloseThreshold) && this._parentProperties.autoCloseThreshold !== config.properties.autoCloseThreshold) {\n this._parentProperties.autoCloseThreshold = config.properties.autoCloseThreshold;\n if (!isDefined(this._autoCloseThreshold)) {\n this._applyAutoCloseThreshold();\n }\n }\n }\n\n // Size\n if (config.size && this.open) {\n const parentSize = this._adapter.getParentSize(this._orientation);\n this._pixelMin = getPixelDimension(this._min, parentSize);\n this._pixelMax = isDefined(this._max) ? getPixelDimension(this._max as number | string, parentSize) : undefined;\n this.setContentSize(this._adapter.getContentSize(this._orientation));\n }\n\n // The following properties don't apply to non-resizable panels\n if (this._resizable === 'off') {\n return;\n }\n\n const size = this._adapter.getContentSize(this._orientation);\n const availableSpace = this._adapter.getAvailableSpace(this._orientation, this._resizable);\n\n // Accessibility\n if (config.accessibility && this.open) {\n const valueNow = getValuenow(size, { ...this._state, availableSpace });\n this._adapter.setValuenow(valueNow);\n }\n\n // Contextual cursor\n if (config.cursor) {\n handleBoundariesAfterResize(this._adapter, size, { ...this._state, availableSpace });\n }\n }\n}\n", "import { COMPONENT_NAME_PREFIX } from '../../constants';\nimport { ISplitViewBase } from '../core';\nimport { SPLIT_VIEW_PANEL_CONSTANTS } from '../split-view-panel/split-view-panel-constants';\n\nconst elementName: keyof HTMLElementTagNameMap = `${COMPONENT_NAME_PREFIX}split-view`;\n\nconst attributes = {\n ORIENTATION: 'orientation',\n DISABLED: 'disabled',\n ALLOW_CLOSE: 'allow-close',\n AUTO_CLOSE: 'auto-close',\n AUTO_CLOSE_THRESHOLD: 'auto-close-threshold'\n};\n\nconst classes = {\n ROOT: 'forge-split-view'\n};\n\nconst ids = {\n ROOT: 'root'\n};\n\nconst selectors = {\n ROOT: `#${ids.ROOT}`,\n PANEL: SPLIT_VIEW_PANEL_CONSTANTS.elementName\n};\n\nconst numbers = {\n RESIZE_THROTTLE_THRESHOLD: 200\n};\n\nconst customCssProperties = {\n ANIMATING_LAYER: '--forge-split-view-animating-layer'\n};\n\nexport const SPLIT_VIEW_CONSTANTS = {\n elementName,\n attributes,\n classes,\n ids,\n selectors,\n numbers,\n customCssProperties\n};\n\nexport type SplitViewOrientation = 'horizontal' | 'vertical';\n\nexport interface ISplitViewUpdateConfig {\n accessibility?: boolean;\n cursor?: boolean;\n orientation?: SplitViewOrientation;\n properties?: Partial<ISplitViewBase>;\n size?: boolean;\n}\n", "import { getShadowElement, playKeyframeAnimation, toggleAttribute } from '@tylertech/forge-core';\n\nimport { BaseAdapter, IBaseAdapter } from '../../core/base/base-adapter';\nimport { ISplitViewPanelComponent } from './split-view-panel';\nimport { ISplitViewPanelCursorConfig, ISplitViewPanelOpenEvent, SplitViewPanelResizable, SPLIT_VIEW_PANEL_CONSTANTS } from './split-view-panel-constants';\nimport { ISplitViewUpdateConfig, SplitViewOrientation, SPLIT_VIEW_CONSTANTS } from '../split-view/split-view-constants';\nimport { ISplitViewComponent } from '../split-view/split-view';\nimport { getCursor, getHandleIcon, createOverlay, getSplitViewPanelSibling } from './split-view-panel-utils';\nimport { IIconComponent } from '../../icon';\nimport { IRippleComponent } from '../../ripple';\n\nexport interface ISplitViewPanelAdapter extends IBaseAdapter {\n initialize(): void;\n tryRemoveOverlay(): void;\n setPointerdownListener(listener: (evt: PointerEvent) => void): void;\n setPointerupListener(listener: (evt: PointerEvent) => void): void;\n removePointerupListener(listener: (evt: PointerEvent) => void): void;\n setPointermoveListener(listener: (evt: PointerEvent) => void): void;\n removePointermoveListener(listener: (evt: PointerEvent) => void): void;\n setKeydownListener(listener: (evt: KeyboardEvent) => void): void;\n setKeyupListener(listener: (evt: KeyboardEvent) => void): void;\n removeKeyupListener(listener: (evt: KeyboardEvent) => void): void;\n getParentProperty(name: keyof ISplitViewComponent): unknown;\n setAccessibleLabel(value: string): void;\n setDisabled(value: boolean): void;\n setResizable(value: SplitViewPanelResizable): void;\n setOrientation(value: SplitViewOrientation): void;\n setOpen(value: boolean, withAnimation?: boolean, event?: ISplitViewPanelOpenEvent): void;\n setGrabbed(value: boolean): void;\n setHandleCursor(orientation?: SplitViewOrientation, config?: ISplitViewPanelCursorConfig): void;\n setBodyCursor(orientation: SplitViewOrientation, config?: ISplitViewPanelCursorConfig): void;\n getContentSize(orientation: SplitViewOrientation): number;\n setContentSize(value: number): void;\n setValuenow(value: number): void;\n focusHandle(): void;\n getAvailableSpace(orientation: SplitViewOrientation, resizable: SplitViewPanelResizable): number;\n getSiblingContentSize(): number;\n setSiblingContentSize(value: number): void;\n activateRipple(defaultActivated: boolean): void;\n deactivateRipple(): void;\n getParentSize(orientation: SplitViewOrientation): number;\n updateParent(config: ISplitViewUpdateConfig): void;\n}\n\nexport class SplitViewPanelAdapter extends BaseAdapter<ISplitViewPanelComponent> implements ISplitViewPanelAdapter {\n private _root: HTMLElement;\n private _handle: HTMLElement;\n private _icon: IIconComponent;\n private _ripple: IRippleComponent;\n private _content: HTMLElement;\n private _parent?: ISplitViewComponent;\n private _overlay?: HTMLElement;\n\n constructor(component: ISplitViewPanelComponent) {\n super(component);\n this._root = getShadowElement(component, SPLIT_VIEW_PANEL_CONSTANTS.selectors.ROOT);\n this._handle = getShadowElement(component, SPLIT_VIEW_PANEL_CONSTANTS.selectors.HANDLE);\n this._icon = getShadowElement(component, SPLIT_VIEW_PANEL_CONSTANTS.selectors.ICON) as IIconComponent;\n this._ripple = getShadowElement(component, SPLIT_VIEW_PANEL_CONSTANTS.selectors.RIPPLE) as IRippleComponent;\n this._content = getShadowElement(component, SPLIT_VIEW_PANEL_CONSTANTS.selectors.CONTENT);\n }\n\n public initialize(): void {\n // Set the parent split view\n const parent = this._component.parentElement;\n if (parent?.tagName.toLowerCase() === SPLIT_VIEW_CONSTANTS.elementName) {\n this._parent = parent as ISplitViewComponent;\n }\n }\n\n public tryRemoveOverlay(): void {\n this._overlay?.remove();\n this._overlay = undefined;\n }\n\n public setPointerdownListener(listener: (evt: PointerEvent) => void): void {\n this._handle.addEventListener('pointerdown', listener);\n }\n\n public setPointerupListener(listener: (evt: PointerEvent) => void): void {\n document.addEventListener('pointerup', listener);\n }\n\n public removePointerupListener(listener: (evt: PointerEvent) => void): void {\n document.removeEventListener('pointerup', listener);\n }\n\n public setPointermoveListener(listener: (evt: PointerEvent) => void): void {\n document.addEventListener('pointermove', listener);\n }\n\n public removePointermoveListener(listener: (evt: PointerEvent) => void): void {\n document.removeEventListener('pointermove', listener);\n }\n\n public setKeydownListener(listener: (evt: KeyboardEvent) => void): void {\n this._handle.addEventListener('keydown', listener);\n }\n\n public setKeyupListener(listener: (evt: KeyboardEvent) => void): void {\n this._handle.addEventListener('keyup', listener);\n }\n\n public removeKeyupListener(listener: (evt: KeyboardEvent) => void): void {\n this._handle.removeEventListener('keyup', listener);\n }\n\n /**\n * Gets the specified property value from the parent split view.\n * @param name The property name.\n * @returns The value of the property.\n */\n public getParentProperty(name: keyof ISplitViewComponent): unknown {\n return this._parent?.[name];\n }\n\n /**\n * Sets the accessible label of the resize handle.\n * @param value The label text.\n */\n public setAccessibleLabel(value: string): void {\n this._handle.setAttribute('aria-label', value);\n }\n\n /**\n * Sets the disabled state of the component.\n * @param value Whether the component is disabled.\n */\n public setDisabled(value: boolean): void {\n this._root.classList.toggle(SPLIT_VIEW_PANEL_CONSTANTS.classes.DISABLED, value);\n if (this._handle) {\n this._handle.setAttribute('tabindex', value ? '-1' : '0');\n toggleAttribute(this._handle, value, 'aria-disabled', 'true');\n }\n }\n\n /**\n * Sets the whether the component's handle is present and at its start or end.\n * @param value The component's resizable value.\n */\n public setResizable(value: SplitViewPanelResizable): void {\n this._root.setAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.RESIZABLE, value.toString());\n toggleAttribute(this._handle, value !== 'off', 'aria-valuemin', '0');\n toggleAttribute(this._handle, value !== 'off', 'aria-valuemax', '100');\n\n if (value === 'off') {\n return;\n }\n\n this._handle.remove();\n if (value === 'end') {\n // Place the handle after the content\n this._root.append(this._handle);\n } else {\n // Place the handle before the content\n this._root.prepend(this._handle);\n }\n }\n\n /**\n * Sets the orientation of the component including ARIA attributes and the resize handle icon.\n * @param value The component's orientation.\n */\n public setOrientation(value: SplitViewOrientation): void {\n this._root.setAttribute(SPLIT_VIEW_PANEL_CONSTANTS.attributes.ORIENTATION, value);\n // The divider's orientation is perpendicular to the layout of the component\n this._handle.setAttribute('aria-orientation', value === 'horizontal' ? 'vertical' : 'horizontal');\n this._icon.setAttribute('name', getHandleIcon(value));\n }\n\n /**\n * Opens or closes the component.\n * @param value Whether the component is open.\n * @param withAnimation Whether to use the animation. Defaults to `true`.\n */\n public setOpen(value: boolean, withAnimation = true, event?: ISplitViewPanelOpenEvent): void {\n const finish = (): void => {\n if (!value) {\n this._root.classList.add(SPLIT_VIEW_PANEL_CONSTANTS.classes.CLOSED);\n }\n if (event) {\n this.emitHostEvent(value ? SPLIT_VIEW_PANEL_CONSTANTS.events.DID_OPEN : SPLIT_VIEW_PANEL_CONSTANTS.events.DID_CLOSE, event);\n }\n this._parent?.unlayerSlottedPanels();\n this._parent?.update({ accessibility: true, cursor: true });\n };\n\n if (value && this._root.classList.contains(SPLIT_VIEW_PANEL_CONSTANTS.classes.CLOSED)) {\n this._root.classList.remove(SPLIT_VIEW_PANEL_CONSTANTS.classes.CLOSED);\n\n if (!withAnimation) {\n finish();\n return;\n }\n\n this._parent?.layerSlottedPanels(this._component);\n playKeyframeAnimation(this._root, SPLIT_VIEW_PANEL_CONSTANTS.classes.OPENING, true).then(() => {\n finish();\n });\n } else if (!value && !this._root.classList.contains(SPLIT_VIEW_PANEL_CONSTANTS.classes.CLOSED)) {\n\n if (!withAnimation) {\n finish();\n return;\n }\n\n this._parent?.layerSlottedPanels(this._component);\n playKeyframeAnimation(this._root, SPLIT_VIEW_PANEL_CONSTANTS.classes.CLOSING, true).then(() => {\n finish();\n });\n }\n }\n\n /**\n * Sets the components appearance and accessibility to indicated whether it is currently grabbed\n * by the user. Applies a cursor style to the document body.\n * @param value Whether the component is currently being resized via pointer interaction.\n */\n public setGrabbed(value: boolean): void {\n this._root.classList.toggle(SPLIT_VIEW_PANEL_CONSTANTS.classes.GRABBED, value);\n this._handle.setAttribute('aria-grabbed', value.toString());\n\n if (value) {\n if (!this._overlay) {\n this._overlay = createOverlay();\n }\n document.body.append(this._overlay);\n } else {\n this._overlay?.remove();\n }\n }\n\n /**\n * Applies a cursor style to the resize handle. \n * @param orientation The component's orientation. If absent the cursor will be removed.\n * @param config The component's resizable value and whether it's at the min or max value.\n */\n public setHandleCursor(orientation?: SplitViewOrientation, config?: ISplitViewPanelCursorConfig): void {\n if (orientation) {\n this._root.style.setProperty(SPLIT_VIEW_PANEL_CONSTANTS.customCssProperties.CURSOR, getCursor(orientation, config));\n } else {\n this._root.style.removeProperty(SPLIT_VIEW_PANEL_CONSTANTS.customCssProperties.CURSOR);\n }\n }\n\n /**\n * Applies a cursor style to the overlay element covering the document body.\n * @param orientation The component's orientation.\n * @param config The component's resizable value and whether it's at the min or max value.\n */\n public setBodyCursor(orientation: SplitViewOrientation, config?: ISplitViewPanelCursorConfig): void {\n this._overlay?.style.setProperty('cursor', getCursor(orientation, config));\n }\n\n /**\n * Gets the size of the content along the orientation axis. Does not include the resize handle.\n * @param orientation The component's orientation.\n * @returns The width or height of the content in pixels.\n */\n public getContentSize(orientation: SplitViewOrientation): number {\n return orientation === 'horizontal' ? this._content.clientWidth : this._content.clientHeight;\n }\n\n /**\n * Sets the size of the content not including the resize handle.\n * @param value The width or height of the content in pixels.\n */\n public setContentSize(value: number): void {\n this._component.style.setProperty(SPLIT_VIEW_PANEL_CONSTANTS.customCssProperties.SIZE, `${value}px`);\n }\n\n /**\n * Sets the ARIA attribute representing the size of the content compared to its min and max.\n * @param value The content size scaled from 0 to 100.\n */\n public setValuenow(value: number): void {\n this._handle.setAttribute('aria-valuenow', value.toFixed(2));\n }\n\n /**\n * Sets focus on the handle element.\n */\n public focusHandle(): void {\n this._handle.focus();\n }\n\n /**\n * Gets the amount of space that the component is allowed to take. This includes the current\n * size of the component and the size of the sibling it resizes into along the axis of\n * orientation. The sibling's min and max values are taken into account but the component's are\n * not.\n * @param orientation The component's orientation.\n * @param resizable The component's resizable value.\n * @returns The amount of space available for the component to resize into in pixels.\n */\n public getAvailableSpace(orientation: SplitViewOrientation, resizable: SplitViewPanelResizable): number {\n if (resizable === 'off') {\n // Return -1 if the panel is static (i.e. can't be user resized)\n return -1;\n }\n const sibling = getSplitViewPanelSibling(this._component);\n if (sibling) {\n const siblingSize = sibling.getCollapsibleSize();\n return siblingSize + this.getContentSize(orientation);\n } else {\n return this.getParentSize(orientation);\n }\n }\n\n /**\n * Gets the content size of the sibling panel the component resizes into along its axis of\n * orientation.\n * @returns The sibling's content size in pixels or 0 if the sibling does not exist.\n */\n public getSiblingContentSize(): number {\n const sibling = getSplitViewPanelSibling(this._component);\n return sibling?.getContentSize() ?? 0;\n }\n\n /**\n * Sets the content size of the sibling panel the component resizes into along its axis of\n * orientation.\n * @returns The sibling's content size in pixels.\n */\n public setSiblingContentSize(value: number): void {\n const sibling = getSplitViewPanelSibling(this._component);\n sibling?.setContentSize(value);\n }\n\n /**\n * Runs the ripple animation.\n * @param fromActivated Whether the ripple starts from and should end in an activated state.\n */\n public activateRipple(fromActivated: boolean): void {\n if (fromActivated) {\n this._ripple.deactivate();\n // Wait a short amount of time so the animation is distinguishable\n window.setTimeout(() => {\n this._ripple.activate();\n }, SPLIT_VIEW_PANEL_CONSTANTS.numbers.RIPPLE_ACTIVATION_WAIT);\n } else {\n this._ripple.activate();\n this._ripple.deactivate();\n }\n }\n\n /**\n * Deactivates the ripple.\n */\n public deactivateRipple(): void {\n this._ripple.deactivate();\n }\n\n /**\n * Gets the size of the parent split view along the axis of orientation.\n * @param orientation The component's orientation.\n * @returns The parent's size in pixels.\n */\n public getParentSize(orientation: SplitViewOrientation): number {\n const parentSize = orientation === 'horizontal' ? this._parent?.clientWidth : this._parent?.clientHeight;\n return parentSize ?? 0;\n }\n\n /**\n * Updates the provided characteristics of all panels.\n * @param config An update configuration.\n */\n public updateParent(config: ISplitViewUpdateConfig): void {\n this._parent?.update(config);\n }\n}\n", "import { CustomElement, attachShadowTemplate, FoundationProperty, coerceBoolean, coerceNumber } from '@tylertech/forge-core';\nimport { tylIconDragVerticalVariant } from '@tylertech/tyler-icons/extended';\nimport { tylIconDragHandle } from '@tylertech/tyler-icons/standard';\n\nimport { BaseComponent, IBaseComponent } from '../../core/base/base-component';\nimport { ISplitViewPanelOpenEvent, ISplitViewPanelWillResizeEvent, SplitViewPanelResizable, SPLIT_VIEW_PANEL_CONSTANTS } from './split-view-panel-constants';\nimport { SplitViewPanelFoundation } from './split-view-panel-foundation';\nimport { SplitViewPanelAdapter } from './split-view-panel-adapter';\nimport { ISplitViewUpdateConfig } from '../split-view/split-view-constants';\nimport { ISplitViewBase } from '../core/split-view-base';\nimport { IconComponent, IconRegistry } from '../../icon';\nimport { RippleComponent } from '../../ripple';\n\nconst template = '<template><div class=\\\"forge-split-view-panel\\\" id=\\\"root\\\" part=\\\"root\\\"><div class=\\\"forge-split-view-panel__handle\\\" id=\\\"handle\\\" part=\\\"handle\\\" role=\\\"separator\\\" aria-controls=\\\"content\\\" aria-grabbed=\\\"false\\\" tabindex=\\\"0\\\"><forge-icon class=\\\"forge-split-view-panel__icon\\\" id=\\\"icon\\\" part=\\\"icon\\\"></forge-icon><forge-ripple id=\\\"ripple\\\" part=\\\"ripple\\\"></forge-ripple></div><div class=\\\"forge-split-view-panel__content\\\" id=\\\"content\\\" part=\\\"content\\\" role=\\\"group\\\"><slot></slot></div></div></template>';\nconst styles = '@-webkit-keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@-webkit-keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@-webkit-keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}@keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.mdc-ripple-surface{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:transparent;will-change:transform,opacity;position:relative;outline:0;overflow:hidden}.mdc-ripple-surface::after,.mdc-ripple-surface::before{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:\\\"\\\"}.mdc-ripple-surface::before{-webkit-transition:opacity 15ms linear,background-color 15ms linear;transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index,1)}.mdc-ripple-surface::after{z-index:0;z-index:var(--mdc-ripple-z-index,0)}.mdc-ripple-surface.mdc-ripple-upgraded::before{-webkit-transform:scale(var(--mdc-ripple-fg-scale,1));transform:scale(var(--mdc-ripple-fg-scale,1))}.mdc-ripple-surface.mdc-ripple-upgraded::after{top:0;left:0;-webkit-transform:scale(0);transform:scale(0);-webkit-transform-origin:center center;transform-origin:center center}.mdc-ripple-surface.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top,0);left:var(--mdc-ripple-left,0)}.mdc-ripple-surface.mdc-ripple-upgraded--foreground-activation::after{-webkit-animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards;animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.mdc-ripple-surface.mdc-ripple-upgraded--foreground-deactivation::after{-webkit-animation:mdc-ripple-fg-opacity-out 150ms;animation:mdc-ripple-fg-opacity-out 150ms;-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}.mdc-ripple-surface::after,.mdc-ripple-surface::before{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.mdc-ripple-surface.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.mdc-ripple-surface[data-mdc-ripple-is-unbounded],.mdc-ripple-upgraded--unbounded{overflow:visible}.mdc-ripple-surface[data-mdc-ripple-is-unbounded]::after,.mdc-ripple-surface[data-mdc-ripple-is-unbounded]::before,.mdc-ripple-upgraded--unbounded::after,.mdc-ripple-upgraded--unbounded::before{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::after,.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::before,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::after,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::before{top:var(--mdc-ripple-top,calc(50% - 50%));left:var(--mdc-ripple-left,calc(50% - 50%));width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::after,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.mdc-ripple-surface::after,.mdc-ripple-surface::before{background-color:#000;background-color:var(--mdc-ripple-color,#000)}.mdc-ripple-surface.mdc-ripple-surface--hover::before,.mdc-ripple-surface:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.mdc-ripple-surface.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.mdc-ripple-surface:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.mdc-ripple-surface:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.mdc-ripple-surface.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-ripple-surface::after,.mdc-ripple-surface::before{--mdc-ripple-color:var(--mdc-theme-on-surface)}.forge-split-view-panel{display:-webkit-box;display:flex;width:100%;height:100%;overflow:hidden;contain:paint size}.forge-split-view-panel__handle{color:rgba(0,0,0,.54);color:var(--mdc-theme-text-secondary-on-light,rgba(0,0,0,.54));background-color:#e0e0e0;background-color:var(--forge-theme-border-color,#e0e0e0);display:-webkit-box;display:flex;flex-shrink:0;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;outline:0}.forge-split-view-panel__content{-webkit-box-flex:1;flex:1;overflow:hidden}.forge-split-view-panel--closed{display:none}.forge-split-view-panel--disabled #handle{pointer-events:none}.forge-split-view-panel--disabled .forge-split-view-panel__icon{display:none}.forge-split-view-panel[orientation=horizontal]{min-width:8px;min-width:var(--forge-split-view-handle-width,8px);width:calc(var(--forge-split-view-panel-size,unset) + var(--forge-split-view-handle-width,8px));-webkit-box-orient:horizontal;-webkit-box-direction:normal;flex-direction:row}.forge-split-view-panel[orientation=horizontal] .forge-split-view-panel__handle{width:8px;width:var(--forge-split-view-handle-width,8px);cursor:var(--forge-split-view-panel-cursor)}.forge-split-view-panel[orientation=horizontal].forge-split-view-panel--closing[resizable=end]{position:absolute;top:0;left:0;-webkit-animation-name:uvyx5ut;animation-name:uvyx5ut;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1)}@-webkit-keyframes uvyx5ut{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}@keyframes uvyx5ut{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}.forge-split-view-panel[orientation=horizontal].forge-split-view-panel--closing[resizable=start]{position:absolute;top:0;right:0;-webkit-animation-name:uvyx5vd;animation-name:uvyx5vd;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1)}@-webkit-keyframes uvyx5vd{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(100%);transform:translateX(100%)}}@keyframes uvyx5vd{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(100%);transform:translateX(100%)}}.forge-split-view-panel[orientation=horizontal].forge-split-view-panel--opening[resizable=end]{position:absolute;top:0;left:0;-webkit-animation-name:uvyx5w5;animation-name:uvyx5w5;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-direction:reverse}@-webkit-keyframes uvyx5w5{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}@keyframes uvyx5w5{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}.forge-split-view-panel[orientation=horizontal].forge-split-view-panel--opening[resizable=start]{position:absolute;top:0;right:0;-webkit-animation-name:uvyx5wt;animation-name:uvyx5wt;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-direction:reverse}@-webkit-keyframes uvyx5wt{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(100%);transform:translateX(100%)}}@keyframes uvyx5wt{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateX(100%);transform:translateX(100%)}}.forge-split-view-panel[orientation=vertical]{min-height:8px;min-height:var(--forge-split-view-handle-width,8px);height:calc(var(--forge-split-view-panel-size,unset) + var(--forge-split-view-handle-width,8px));-webkit-box-orient:vertical;-webkit-box-direction:normal;flex-direction:column}.forge-split-view-panel[orientation=vertical] .forge-split-view-panel__handle{height:8px;height:var(--forge-split-view-handle-width,8px);cursor:var(--forge-split-view-panel-cursor)}.forge-split-view-panel[orientation=vertical].forge-split-view-panel--closing[resizable=end]{position:absolute;top:0;left:0;-webkit-animation-name:uvyx5xl;animation-name:uvyx5xl;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1)}@-webkit-keyframes uvyx5xl{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}@keyframes uvyx5xl{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}.forge-split-view-panel[orientation=vertical].forge-split-view-panel--closing[resizable=start]{position:absolute;bottom:0;left:0;-webkit-animation-name:uvyx5yd;animation-name:uvyx5yd;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1)}@-webkit-keyframes uvyx5yd{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}@keyframes uvyx5yd{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}.forge-split-view-panel[orientation=vertical].forge-split-view-panel--opening[resizable=end]{position:absolute;top:0;left:0;-webkit-animation-name:uvyx5z5;animation-name:uvyx5z5;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-direction:reverse}@-webkit-keyframes uvyx5z5{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}@keyframes uvyx5z5{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}.forge-split-view-panel[orientation=vertical].forge-split-view-panel--opening[resizable=start]{position:absolute;bottom:0;left:0;-webkit-animation-name:uvyx5zb;animation-name:uvyx5zb;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-direction:reverse}@-webkit-keyframes uvyx5zb{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}@keyframes uvyx5zb{from{-webkit-transform:none;transform:none}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}:host{z-index:var(--forge-split-view-animating-layer)!important;display:block;position:relative;height:100%;width:100%;-webkit-box-flex:0;flex:0}:host([hidden]){display:none}:host(:not([resizable=start],[resizable=end])){-webkit-box-flex:1;flex:1}:host(:not([resizable=start],[resizable=end])) .forge-split-view-panel{width:100%;height:100%;min-width:0;min-height:0}:host(:not([resizable=start],[resizable=end])) .forge-split-view-panel__handle{display:none}';\n\nexport interface ISplitViewPanelComponent extends Partial<ISplitViewBase>, IBaseComponent {\n resizable: SplitViewPanelResizable;\n size: number | string;\n min: number | string;\n max: number | string | undefined;\n accessibleLabel: string;\n open: boolean;\n getContentSize(): number;\n getCollapsibleSize(): number;\n setContentSize(size: number): void;\n update(config: ISplitViewUpdateConfig): void;\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'forge-split-view-panel': ISplitViewPanelComponent;\n }\n\n interface HTMLElementEventMap {\n 'forge-split-view-panel-will-resize': CustomEvent<ISplitViewPanelWillResizeEvent>;\n 'forge-split-view-panel-resize-start': CustomEvent<null>;\n 'forge-split-view-panel-resize-end': CustomEvent<null>;\n 'forge-split-view-panel-resize': CustomEvent<number>;\n 'forge-split-view-panel-will-open': CustomEvent<ISplitViewPanelOpenEvent>;\n 'forge-split-view-panel-will-close': CustomEvent<ISplitViewPanelOpenEvent>;\n 'forge-split-view-panel-did-open': CustomEvent<ISplitViewPanelOpenEvent>;\n 'forge-split-view-panel-did-close': CustomEvent<ISplitViewPanelOpenEvent>;\n }\n}\n\n/**\n * The custom element class behind the `<forge-split-view-panel>` element.\n * \n * @tag forge-split-view-panel\n */\n@CustomElement({\n name: SPLIT_VIEW_PANEL_CONSTANTS.elementName,\n dependencies: [\n IconComponent,\n RippleComponent\n ]\n})\nexport class SplitViewPanelComponent extends BaseComponent implements ISplitViewPanelComponent {\n public static get observedAttributes(): string[] {\n return [\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.RESIZABLE,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.SIZE,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.MIN,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.MAX,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.ACCESSIBLE_LABEL,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.OPEN,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.DISABLED,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.ALLOW_CLOSE,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE,\n SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE_THRESHOLD\n ];\n }\n\n private _foundation: SplitViewPanelFoundation;\n\n constructor() {\n super();\n IconRegistry.define([tylIconDragVerticalVariant, tylIconDragHandle]);\n attachShadowTemplate(this, template, styles);\n this._foundation = new SplitViewPanelFoundation(new SplitViewPanelAdapter(this));\n }\n\n public connectedCallback(): void {\n this._foundation.initialize();\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 SPLIT_VIEW_PANEL_CONSTANTS.attributes.RESIZABLE:\n this.resizable = newValue as SplitViewPanelResizable;\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.SIZE:\n this.size = newValue;\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.MIN:\n this.min = newValue;\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.MAX:\n if (newValue) {\n this.max = newValue;\n } else {\n this.max = undefined;\n }\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.ACCESSIBLE_LABEL:\n this.accessibleLabel = newValue;\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.OPEN:\n this.open = coerceBoolean(newValue);\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.DISABLED:\n if (this.hasAttribute(name)) {\n this.disabled = coerceBoolean(newValue);\n } else {\n this.disabled = undefined;\n }\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.ALLOW_CLOSE:\n if (this.hasAttribute(name)) {\n this.allowClose = coerceBoolean(newValue);\n } else {\n this.allowClose = undefined;\n }\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE:\n if (this.hasAttribute(name)) {\n this.autoClose = coerceBoolean(newValue);\n } else {\n this.autoClose = undefined;\n }\n break;\n case SPLIT_VIEW_PANEL_CONSTANTS.attributes.AUTO_CLOSE_THRESHOLD:\n if (newValue) {\n this.autoCloseThreshold = coerceNumber(newValue);\n } else {\n this.autoCloseThreshold = undefined;\n }\n break;\n }\n }\n\n /**\n * Controls which side of the panel the resize handle appears on.\n */\n @FoundationProperty()\n public resizable: SplitViewPanelResizable;\n\n /**\n * The initial size along the axis of orientation.\n */\n @FoundationProperty()\n public size: number | string;\n\n /**\n * The smallest size the panel can take along its axis of orientation.\n */\n @FoundationProperty()\n public min: number | string;\n\n /**\n * The largest size the panel can take along its axis of orientation.\n */\n @FoundationProperty()\n public max: number | string | undefined;\n\n /**\n * The ARIA label given to the resize handle.\n */\n @FoundationProperty()\n public accessibleLabel: string;\n\n /**\n * Controls the open state of the panel.\n */\n @FoundationProperty()\n public open: boolean;\n\n /**\n * Whether resize interactions are disabled or enabled.\n */\n @FoundationProperty()\n public disabled?: boolean;\n\n /**\n * Whether the panel can be closed via keyboard interaction.\n */\n @FoundationProperty()\n public allowClose?: boolean;\n\n /**\n * Whether the panel automatically closes when it reaches a size of 0.\n */\n @FoundationProperty()\n public autoClose?: boolean;\n\n /**\n * The size at which the panel auto closes.\n */\n @FoundationProperty()\n public autoCloseThreshold?: number;\n\n /**\n * Gets the size of content along the axis of orientation.\n * @returns The size of content in pixels.\n */\n public getContentSize(): number {\n return this._foundation.getContentSize();\n }\n\n /**\n * Gets the amount that the content can shrink along the axis of orientation before reaching its\n * min size.\n * @returns The amount that content can shrink in pixels.\n */\n public getCollapsibleSize(): number {\n return this._foundation.getCollapsibleSize();\n }\n\n /**\n * Sets the size of content along the axis of orientation.\n * @param size The new size of content in pixels.\n */\n public setContentSize(size: number): void {\n this._foundation.setContentSize(size);\n }\n\n /**\n * Updates the provided characteristics.\n * @param config An update configuration.\n */\n public update(config: ISplitViewUpdateConfig): void {\n this._foundation.update(config);\n }\n}\n", "import { defineCustomElement } from '@tylertech/forge-core';\n\nimport { SplitViewPanelComponent } from './split-view-panel';\n\nexport * from './split-view-panel-adapter';\nexport * from './split-view-panel-constants';\nexport * from './split-view-panel-foundation';\nexport * from './split-view-panel';\nexport * from './split-view-panel-utils';\n\nexport function defineSplitViewPanelComponent(): void {\n defineCustomElement(SplitViewPanelComponent);\n}\n"],
5
5
  "mappings": "4lBAGA,IAAMA,EAA2C,GAAGC,oBAE9CC,GAAa,CACjB,UAAW,YACX,KAAM,OACN,IAAK,MACL,IAAK,MACL,KAAM,OACN,iBAAkB,mBAClB,SAAU,WACV,YAAa,cACb,WAAY,aACZ,qBAAsB,uBACtB,YAAa,aACf,EAEMC,GAAU,CACd,KAAM,yBACN,QAAS,kCACT,OAAQ,iCACR,KAAM,+BACN,QAAS,kCACT,OAAQ,iCACR,QAAS,kCACT,QAAS,kCACT,SAAU,mCACV,QAAS,gCACX,EAEMC,EAAM,CACV,KAAM,OACN,OAAQ,SACR,KAAM,OACN,OAAQ,SACR,QAAS,SACX,EAEMC,GAAY,CAChB,KAAM,IAAID,EAAI,OACd,OAAQ,IAAIA,EAAI,SAChB,KAAM,IAAIA,EAAI,OACd,OAAQ,IAAIA,EAAI,SAChB,QAAS,IAAIA,EAAI,SACnB,EAEME,GAAS,CACb,YAAa,GAAGN,gBAChB,aAAc,GAAGA,iBACjB,WAAY,G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CACpDC,EAAoBC,CAAuB,CAC7C",
6
6
  "names": ["elementName", "COMPONENT_NAME_PREFIX", "attributes", "classes", "ids", "selectors", "events", "numbers", "customCssProperties", "SPLIT_VIEW_PANEL_CONSTANTS", "SplitViewAnimatingLayer", "initState", "setState", "adapter", "state", "currentSize", "__spreadProps", "__spreadValues", "clearState", "pointerResize", "evt", "initialSize", "evtPoint", "delta", "size", "clampSize", "handleBoundariesDuringResize", "getValuenow", "siblingDelta", "resizeSibling", "keyboardResize", "increment", "minResize", "maxResize", "availableSpace", "max", "safeMin", "siblingSize", "inputDevice", "handleBoundariesAfterResize", "scaleValue", "getCursor", "orientation", "config", "getHandleIcon", "getSplitViewPanelSibling", "el", "resizable", "sibling", "SplitViewPanelComponent", "parseSize", "value", "_a", "_b", "regex", "parts", "amount", "unit", "getPixelDimension", "parentSize", "parsedSize", "percentToPixels", "createOverlay", "SPLIT_VIEW_PANEL_CONSTANTS", "SplitViewPanelFoundation", "_adapter", "initState", "evt", "value", "_a", "_b", "eventIncludesArrowKey", "size", "minResize", "SPLIT_VIEW_PANEL_CONSTANTS", "maxResize", "increment", "keyboardResize", "handleBoundariesDuringResize", "pointerResize", "inputDeviceType", "setState", "clearState", "shouldOpen", "auto", "userInitiated", "eventType", "event", "parentDisabled", "parentAllowClose", "parentAutoClose", "parentAutoCloseThreshold", "parentSize", "pixelSize", "getPixelDimension", "availableSpace", "maxSize", "safeMin", "newValue", "scaleValue", "isDefined", "pixelMin", "newSize", "clampSize", "config", "valueNow", "getValuenow", "__spreadProps", "__spreadValues", "handleBoundariesAfterResize", "elementName", "COMPONENT_NAME_PREFIX", "attributes", "classes", "ids", "selectors", "SPLIT_VIEW_PANEL_CONSTANTS", "numbers", "customCssProperties", "SPLIT_VIEW_CONSTANTS", "SplitViewPanelAdapter", "BaseAdapter", "component", "getShadowElement", "SPLIT_VIEW_PANEL_CONSTANTS", "parent", "SPLIT_VIEW_CONSTANTS", "_a", "listener", "name", "value", "toggleAttribute", "getHandleIcon", "withAnimation", "event", "_b", "finish", "playKeyframeAnimation", "createOverlay", "orientation", "config", "getCursor", "resizable", "sibling", "getSplitViewPanelSibling", "fromActivated", "parentSize", "template", "styles", "SplitViewPanelComponent", "BaseComponent", "IconRegistry", "tylIconDragVerticalVariant", "tylIconDragHandle", "attachShadowTemplate", "SplitViewPanelFoundation", "SplitViewPanelAdapter", "SPLIT_VIEW_PANEL_CONSTANTS", "name", "oldValue", "newValue", "coerceBoolean", "coerceNumber", "size", "config", "__decorateClass", "FoundationProperty", "CustomElement", "IconComponent", "RippleComponent", "defineSplitViewPanelComponent", "defineCustomElement", "SplitViewPanelComponent"]
7
7
  }
@@ -0,0 +1,7 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2023 Tyler Technologies, Inc.
4
+ * License: Apache-2.0
5
+ */
6
+ import{a as k}from"./chunk.6YPD6CQM.js";import{a as X}from"./chunk.ZIB7L7DZ.js";import{a as b}from"./chunk.7G72CBOJ.js";import{a as Y,b as J}from"./chunk.5IVB5L5Z.js";import{a as Q}from"./chunk.IDD54B5P.js";import{a as z}from"./chunk.LEVFMI2Q.js";import{g as O,h as I}from"./chunk.FYWPZFLJ.js";import{a as j,d as q}from"./chunk.H5D54EHO.js";import{d as $}from"./chunk.DTZFWZPB.js";import{f as H}from"./chunk.NK7H3MMM.js";import{d as R,e as M,f as B,i as U,x as K}from"./chunk.CFDK4RCW.js";import{b as _,d as V,h as P,j as v,n as g,p as G}from"./chunk.J2M2MXP2.js";import{a as A}from"./chunk.M3QDAYD2.js";var he={POPUP_CLASSES:"popup-classes",OPTION_LIMIT:"option-limit",OBSERVE_SCROLL:"observe-scroll",OBSERVE_SCROLL_THRESHOLD:"observe-scroll-threshold",SYNC_POPUP_WIDTH:"sync-popup-width",CONSTRAIN_POPUP_WIDTH:"constrain-popup-width",WRAP_OPTION_TEXT:"wrap-option-text",CHECKBOX_ELEMENT:"data-list-dropdown-checkbox",DATA_ALLOW_FOCUS:"data-list-dropdown-allow-focus"},me={GROUP_WRAPPER:"forge-list-dropdown__group-wrapper"},u={attributes:he,classes:me},Z={options:[],syncWidth:!1,selectedValues:[],multiple:!1},ee=(o=>(o.None="none",o.Standard="standard",o.Menu="menu",o))(ee||{}),te=(t=>(t.Spinner="spinner",t.Skeleton="skeleton",t))(te||{});var E=class{constructor(){this._listenerMap=new Map}_emit(e,t){let o=this._listenerMap.get(e);o&&o.length&&o.forEach(n=>n({type:e,data:t}))}hasListeners(e){return e?this._listenerMap.has(e):this._listenerMap.size>0}addListener(e,t){if(!this._listenerMap.has(e))this._listenerMap.set(e,[t]);else{let o=this._listenerMap.get(e);o&&o.push(t)}}removeListener(e,t){let o=this._listenerMap.get(e);o&&o.length&&o.includes(t)&&(o.splice(o.indexOf(t),1),o.length||this._listenerMap.delete(e))}};var f;(function(i){i.Up="up",i.Down="down",i.Left="left",i.Right="right"})(f||(f={}));var c;(function(i){i.Scroll="scroll",i.Scrolled="scrolled",i.ScrolledStart="scrolled-start",i.ScrolledEnd="scrolled-end"})(c||(c={}));var _e=100,w=class extends E{constructor(e,t={}){super(),this._element=e,this._config=t,this._axis="vertical",this._scrollThreshold=0,this._lastScrollPosition=0,this._lastScrollTop=0,this._lastScrollLeft=0,this._isListening=!1,this._initialize()}destroy(){this.stop()}start(){this._isListening||(this._element.addEventListener("scroll",this._scrollListener),this._isListening=!0)}stop(){this._element.removeEventListener("scroll",this._scrollListener),this._isListening=!1}_initialize(){if(this._config.throttle){let e=this._config.throttleTime||_e;this._scrollListener=G(()=>this._onScroll(),e)}else this._scrollListener=()=>this._onScroll();(!_(this._config.paused)||!this._config.paused)&&this.start(),_(this._config.axis)&&(this._axis=this._config.axis),_(this._config.scrollThreshold)&&V(this._config.scrollThreshold)&&(this._scrollThreshold=this._config.scrollThreshold)}_isScrollAxis(){let e=this._lastScrollTop!==this._element.scrollTop,t=this._lastScrollLeft!==this._element.scrollLeft;return this._axis==="vertical"&&e||this._axis==="horizontal"&&t}_onScroll(){if(!this._isScrollAxis())return;let e=this.scrollPosition,t=this._lastScrollPosition-e<0?this._axis==="vertical"?f.Down:f.Right:this._axis==="vertical"?f.Up:f.Left;this._emit(c.Scroll,{direction:t,position:e}),this._lastScrollPosition<=this._scrollThreshold&&e>this._scrollThreshold?this._emit(c.Scrolled,!0):this._lastScrollPosition>=this._scrollThreshold&&(this._scrollThreshold>0?e<this._scrollThreshold:e===0)&&this._emit(c.Scrolled,!1);let o=Math.round(e-this._scrollThreshold),n=Math.round(this.scrollSize-e);this._lastScrollPosition>=this._scrollThreshold&&o<=0?this._emit(c.ScrolledStart):this._lastScrollPosition<=this.scrollSize-this._scrollThreshold&&n<=this._scrollThreshold&&this._emit(c.ScrolledEnd),this._lastScrollPosition=e||0,this._lastScrollTop=this._element.scrollTop||0,this._lastScrollLeft=this._element.scrollLeft||0}get scrollPosition(){return this._axis==="vertical"?this._element.scrollTop:this._element.scrollLeft}get isScrolled(){return this.scrollPosition>this._scrollThreshold}get isScrolledStart(){return this.scrollPosition===0}get isScrolledEnd(){return this.scrollPosition===this._element.scrollWidth}get isScrollable(){return this._axis==="vertical"?this._element.scrollHeight>this._element.clientHeight:this._element.scrollWidth>this._element.clientWidth}get scrollSize(){return(this._axis==="vertical"?this._element.scrollHeight:this._element.scrollWidth)-this.elementSize}get elementSize(){return this._axis==="vertical"?this._element.clientHeight:this._element.clientWidth}setScrollPosition(e){this._axis==="vertical"?this._element.scrollTop=e:this._element.scrollLeft=e}};function oe(i,e){let t=fe(i,e),o=`list-dropdown-popup-${i.id}`;switch(t.addEventListener("mousedown",n=>{let a=z(n);if(a.find(h=>h.nodeType===1&&h.hasAttribute(u.attributes.DATA_ALLOW_FOCUS)))return;a.find(h=>h.id===o||h.id===i.id)&&n.preventDefault()}),i.type){case"menu":t.setAttribute("role","menu"),t.setAttribute("aria-orientation","vertical");break;default:t.setAttribute("role","listbox")}return i.id&&(t.id=o),i.popupClasses&&B(i.popupClasses,t),t}function fe(i,e){var o;let t=document.createElement("forge-popup");switch(t.targetElement=e,t.placement=i.popupPlacement||"bottom-start",t.manageFocus=!1,t.static=!!i.popupStatic,(o=i.popupFallbackPlacements)!=null&&o.length&&(t.fallbackPlacements=i.popupFallbackPlacements),i.constrainViewportWidth&&t.setAttribute(b.attributes.CONSTRAIN_VIEWPORT_WIDTH,""),i.popupOffset&&(t.offset=i.popupOffset),i.type){case"menu":t.animationType="menu";break;case"none":t.animationType="none";break;default:t.animationType="dropdown"}return t}function ne(i){let e=document.createElement(Y.elementName);return e.id=`list-dropdown-list-${i.id}`,e.propagateClick=!1,e}function y(i,e,t,o=0,n=!0){let a=ge(t||i.options),d=N(a),L=!!i.optionLimit,h=i.optionLimit||0,ae=o;for(let m of a){let x=e;if(m.builder&&typeof m.builder=="function"){let s=m.builder(m);if(s){let p=document.createElement("div");p.classList.add(u.classes.GROUP_WRAPPER),x=p,typeof s=="string"?p.innerHTML=s:s instanceof HTMLElement&&p.appendChild(s),e.appendChild(p)}}else if(m.text){let s=document.createElement("div");s.classList.add(u.classes.GROUP_WRAPPER);let p=document.createElement("div");p.textContent=m.text,p.classList.add("forge-typography--overline"),p.style.fontFamily="Roboto,sans-serif",p.style.fontSize="0.75rem",p.style.lineHeight="2rem",p.style.letterSpacing="0.16667em",p.style.fontWeight="500",p.style.margin="4px 8px",x=s,s.appendChild(p),e.appendChild(s)}for(let s of m.options){if(s.divider){let r=ve();e.appendChild(r);continue}if(L&&--h<0)break;let p=i.selectedValues?i.selectedValues.some(r=>g(r,s.value)):!1;if(!n&&p)continue;let l=document.createElement("forge-list-item");switch(l.value=s.value,l.id=`list-dropdown-option-${i.id}-${ae++}`,l.style.cursor="pointer",i.wrapOptionText&&(l.wrap=!0),s.optionClass&&(typeof s.optionClass=="string"||Array.isArray(s.optionClass)&&s.optionClass.length)&&B(s.optionClass,l),i.type){case"menu":l.setAttribute("role","menuitem");break;case"none":break;default:l.setAttribute("role","option")}if(i.dense&&(l.dense=!0),i.optionBuilder&&typeof i.optionBuilder=="function"){let r=i.optionBuilder(s,l);r&&(typeof r=="string"?l.innerHTML=r:l.appendChild(r))}else if(typeof i.transform!="function")l.textContent=s.label||"";else{let r=i.transform(s.label);typeof r=="string"?l.textContent=r:typeof r=="object"&&r.nodeType!==void 0&&l.appendChild(r)}if(i.multiple){let r=C(p);l.appendChild(r),l.setAttribute("aria-selected",`${p}`),l.setAttribute("aria-checked",`${p}`)}if(s.elementAttributes&&s.elementAttributes.forEach((r,F)=>{l.setAttribute(F,r)}),s.leadingBuilder){let r=s.leadingBuilder();v(r)&&(r.slot="leading",l.appendChild(r))}else if(s.leadingIcon){let r=ie(s.leadingIconType,s.leadingIcon,s.leadingIconClass||i.iconClass);r.slot="leading",l.appendChild(r)}if(s.trailingBuilder){let r=s.trailingBuilder();v(r)&&(r.slot="trailing",l.appendChild(r))}else if(s.trailingIcon){let r=ie(s.trailingIconType,s.trailingIcon,s.trailingIconClass||i.iconClass);r.slot="trailing",l.appendChild(r)}if(s.disabled?(l.disabled=s.disabled,l.setAttribute("aria-disabled","true")):(l.style.cursor="pointer",l.setAttribute("aria-disabled","false")),p&&(l.selected=!0),l.setAttribute("aria-selected",p?"true":"false"),!s.disabled&&typeof i.cascadingElementFactory=="function"&&Array.isArray(s.options)&&s.options.length){let r=document.createElement("forge-icon");r.name="arrow_right",r.slot="trailing",l.appendChild(r);let ce={index:d.filter(ue=>!ue.divider).indexOf(s),options:s.options,parentValue:s.value},W=i.cascadingElementFactory.call(null,ce);W.appendChild(l),l=W}x.appendChild(l)}}}function C(i){let e=document.createElement("forge-icon");return e.setAttribute(u.attributes.CHECKBOX_ELEMENT,""),e.name=i?I.name:O.name,e.slot="leading",e.style.marginRight="16px",e.style.verticalAlign="middle",e}function ve(){let i=document.createElement("forge-divider");return i.setAttribute("aria-hidden","true"),i}function ie(i="font",e,t){if(i==="component"){let n=document.createElement("forge-icon");return t&&n.classList.add(t),n.setAttribute("aria-hidden","true"),n.name=e,n}let o=document.createElement("i");return o.classList.add(t||$),o.setAttribute("aria-hidden","true"),o.textContent=e,o}function se(i){switch(i){case"skeleton":return Le();default:return be()}}function be(){let i=document.createElement("div");i.style.display="flex",i.style.justifyContent="center",i.style.alignItems="center",i.style.padding="8px",i.style.boxSizing="border-box";let e=document.createElement("forge-circular-progress");return e.style.setProperty("--forge-circular-progress-size","24px"),i.appendChild(e),i}function Le(){let i=document.createElement("forge-list"),e=document.createElement("div");e.style.minWidth="192px";for(let t=0;t<3;t++){let o=document.createElement(Q.elementName);o.setAttribute("list-item",""),e.appendChild(o)}return i.appendChild(e),i}function re(){let i=document.createElement(X.elementName);return i.determinate=!1,i.style.position="absolute",i.style.top="0",i.style.left="0",i.style.right="0",i.style.width="100%",i}function ge(i){return le(i,1)?i:[{text:"",options:i}]}function le(i,e){let t=i.some(n=>_(n)&&v(n)&&n.hasOwnProperty("options")&&(n.hasOwnProperty("text")||n.hasOwnProperty("builder"))),o=i.some(n=>_(n)&&v(n)&&n.hasOwnProperty("label")&&n.hasOwnProperty("value"));return t&&e===1||o&&e===0}function N(i){return le(i,1)?i.reduce((t,o)=>t.concat(o.options),[]):[...i]}var S=class{constructor(e,t){this._adapter=e;this._open=!1;this._config=Object.assign(A({},Z),A({},t)),this._selectListener=(o,n)=>this._onSelect(o,n),this._closeListener=()=>{typeof this._config.closeCallback=="function"&&this._config.closeCallback()},this._scrollEndListener=()=>{this._config.observeScroll&&typeof this._config.scrollEndListener=="function"&&this._config.scrollEndListener()}}destroy(){this._open&&this.close()}open(){this._open||(this._open=!0,this._adapter.open(this._config,this._selectListener,this._closeListener),window.requestAnimationFrame(()=>{this._open&&this.activateInitialOption()}),this._config.observeScroll&&this._config.scrollEndListener&&this._adapter.setScrollBottomListener(this._scrollEndListener,this._config.observeScrollThreshold||0))}close(){this._open&&(this._open=!1,this._adapter.close(),this._config.observeScroll&&this._config.scrollEndListener&&this._adapter.removeScrollBottomListener(this._scrollEndListener))}_onSelect(e,t){if(typeof this._config.activeChangeCallback=="function"&&this._config.activeChangeCallback(t),typeof this._config.selectCallback=="function"&&this._config.selectCallback(e),this._open){let o=this._config.syncWidth===void 0;this._adapter.syncWidth(o)}}getActiveOptionIndex(){return this._adapter.getActiveOptionIndex()}getActiveOption(){let e=this.getActiveOptionIndex();return e>=0?this._nonDividerOptions[e]:void 0}toggleOptionMultiple(e,t){return this._adapter.toggleOptionMultiple(e,t)}activateSelectedOption(){this._adapter.activateSelectedOption(this._config)}activateFirstOption(){let e=this._nonDividerOptions.findIndex(t=>!t.disabled);return e!==-1&&this.activateOption(e),e}activateLastOption(){let e=this._nonDividerOptions,t=e.length-1-e.findIndex(o=>!o.disabled);return t!==-1&&this.activateOption(t),t}activateOption(e,t){return this._adapter.activateOption(e,this._config.activeChangeCallback,t)}activateInitialOption(){typeof this._config.activeStartIndex=="number"&&this._nonDividerOptions[this._config.activeStartIndex]?(this.activateOption(this._config.activeStartIndex,!1),this._adapter.scrollSelectedOptionIntoView(!1)):this._config.selectedValues&&this._config.selectedValues.length?this._adapter.scrollSelectedOptionIntoView(!1):typeof this._config.visibleStartIndex=="number"&&this._nonDividerOptions[this._config.visibleStartIndex]&&this._adapter.scrollOptionIntoView(this._config.visibleStartIndex)}setSelectedValues(e){Array.isArray(e)||(e=[e]),!this._config.multiple&&e.length>1&&(e=[e[0]]),this._config.selectedValues=e,this._adapter.setSelectedValues(e,this._config.multiple)}clearActiveOption(){this._adapter.clearActiveOption()}setOptions(e){this._config.options=e,this._open&&(this._adapter.setOptions(this._config),this.activateInitialOption())}appendOptions(e){this._config.options=[...this._config.options,...e],this._open&&this._adapter.appendOptions(e,this._config)}get dropdownElement(){return this._adapter.dropdownElement}scrollSelectedOptionIntoView(e=!0){this._adapter.scrollSelectedOptionIntoView(e)}setScrollBottomListener(e,t){this._config.scrollEndListener=e,this._config.observeScroll=!0,this._config.observeScrollThreshold=t,this._adapter.setScrollBottomListener(this._scrollEndListener,this._config.observeScrollThreshold||0)}removeScrollBottomListener(){this._config.scrollEndListener=void 0,this._adapter.removeScrollBottomListener(this._scrollEndListener)}setBusyVisibility(e){this._config.allowBusy&&this._adapter.setBusyVisibility(e)}handleKey(e){switch(e){case"Enter":case"NumpadEnter":let t=this.getActiveOptionIndex(),o=this._nonDividerOptions[t];if(this._canSelectOption(o)){let d=this._adapter.getActiveOptionIdByIndex(t);d&&this._onSelect(o.value,d)}break;case"Up":case"ArrowUp":case"Down":case"ArrowDown":let n=this._nonDividerOptions;if(n.length&&n.every(d=>!this._canSelectOption(d)))return;let a=this._getNextActiveOptionIndex(e);this.activateOption(a);break;case"Home":this.activateFirstOption();break;case"End":this.activateLastOption();break}}_canSelectOption(e){return e&&!e.disabled&&!e.divider}_getNextActiveOptionIndex(e){let t=this._adapter.getActiveOptionIndex();return t===-1&&(t=this._adapter.getSelectedOptionIndex()),e==="ArrowUp"||e==="Up"?this._getPreviousHighlightableOptionIndex(t,this._nonDividerOptions):this._getNextHighlightableOptionIndex(t,this._nonDividerOptions)}_getPreviousHighlightableOptionIndex(e,t){let o=e<=0?t.length-1:e-1;return t[o].disabled?this._getPreviousHighlightableOptionIndex(o,t):o}_getNextHighlightableOptionIndex(e,t){let o=e===t.length-1?0:e+1;return t[o].disabled?this._getNextHighlightableOptionIndex(o,t):o}get _flatOptions(){return N(this._config.options)}get _nonDividerOptions(){return this._flatOptions.filter(e=>!e.divider)}};var D=class{constructor(e){this._targetElement=e}get dropdownElement(){return this._dropdownElement}open(e,t,o){this._dropdownElement=oe(e,this._targetElement),this.syncWidth(!!e.syncWidth,e.targetWidthCallback),e.allowBusy&&(this._busyElement=re(),this._busyElement.style.display="none",this._dropdownElement.appendChild(this._busyElement)),e.headerBuilder&&(this._headerElement=e.headerBuilder(),this._headerElement&&this._headerElement.setAttribute(u.attributes.DATA_ALLOW_FOCUS,"")),e.footerBuilder&&(this._footerElement=e.footerBuilder(),this._footerElement&&this._footerElement.setAttribute(u.attributes.DATA_ALLOW_FOCUS,"")),this._listElement=ne(e),this._listElement.addEventListener("forge-list-item-select",n=>{n.detail.listItem.setAttribute("aria-selected","true"),t(n.detail.value,n.detail.listItem.id)}),e.options.length?(y(e,this._listElement),this._dropdownElement.appendChild(this._listElement),this._headerElement&&this._dropdownElement.insertAdjacentElement("afterbegin",this._headerElement),this._footerElement&&this._dropdownElement.appendChild(this._footerElement)):e.allowBusy&&(this._asyncElement=se(e.asyncStyle),this._dropdownElement.appendChild(this._asyncElement)),this._announcerElement=k(),this._announcerElement.id=`${e.id}-activedescendant`,this._dropdownElement.appendChild(this._announcerElement),this._dropdownElement.open=!0}close(){this._dropdownElement&&(this._dropdownElement.open=!1,this._dropdownElement=void 0,this._listElement=void 0,this._announcerElement=void 0)}setScrollBottomListener(e,t){if(this._dropdownElement&&!this._scrollObserver){let o=H(this._dropdownElement,b.selectors.CONTAINER),n={scrollThreshold:t};this._scrollObserver=new w(o,n),this._scrollObserver.addListener(c.ScrolledEnd,e)}}removeScrollBottomListener(e){this._scrollObserver&&this._scrollObserver.removeListener(c.ScrolledEnd,e)}getActiveOptionIndex(){if(!this._dropdownElement)return-1;let e=this._getListItemElements(),t=[...e].reverse().find(o=>o.active);return t?e.indexOf(t):-1}getSelectedOptionIndex(){return this._getListItemElements().findIndex(t=>t.selected)}getActiveOptionIdByIndex(e){if(!this._dropdownElement)return null;let o=this._getListItemElements()[e];return o?o.id:null}toggleOptionMultiple(e,t){if(!this._dropdownElement)return;let o=this._getListItemElements();o.length&&o[e]&&this._toggleSelectedOption(o[e],t)}scrollOptionIntoView(e,t=!0){let o=this._getListItemElements()[e];o&&this._scrollListItemIntoView(o,t?"smooth":"auto","center")}scrollSelectedOptionIntoView(e=!0){let t=this._getSelectedListItem();this._scrollListItemIntoView(t,e?"smooth":"auto","center")}activateSelectedOption(e){let t=this._getListItemElements();t.length&&t.filter(a=>a.active).forEach(a=>a.active=!1);let o=this._getSelectedListItem();o&&this._activateListOption(o,e.activeChangeCallback)}activateOption(e,t,o=!0){if(!this._dropdownElement)return;let n=this._getListItemElements();n.length&&(n.filter(d=>d.active).forEach(d=>d.active=!1),this._activateListOption(n[e],t),this._scrollListItemIntoView(n[e],o?"smooth":"auto"))}setSelectedValues(e,t=!1){if(!this._dropdownElement)return;let o=this._getListItemElements();for(let n of o){let a=e.some(d=>g(d,n.value));if(n.selected=a,t){let d=n.querySelector(`[${u.attributes.CHECKBOX_ELEMENT}]`);if(d){let L=C(a);M(L,d)}}}}clearActiveOption(){this._getListItemElements().forEach(t=>t.active=!1)}syncWidth(e,t){this._dropdownElement&&(this._dropdownElement.style[e?"width":"minWidth"]=`${this._getTargetElementWidth(t)}px`)}setOptions(e){!this._dropdownElement||!this._listElement||(this._asyncElement&&this._asyncElement.isConnected&&U(this._asyncElement),this._busyElement&&(this._busyElement.style.display="none"),this._listElement.isConnected||this._dropdownElement.appendChild(this._listElement),R(this._listElement),y(e,this._listElement),this._headerElement&&!this._headerElement.isConnected&&this._dropdownElement.insertAdjacentElement("afterbegin",this._headerElement),this._footerElement&&!this._footerElement.isConnected&&this._dropdownElement.insertAdjacentElement("beforeend",this._footerElement),"position"in this._dropdownElement&&typeof this._dropdownElement.position=="function"&&this._dropdownElement.position())}appendOptions(e,t){!this._dropdownElement||!this._listElement||y(t,this._listElement,e,this._listElement.childElementCount,!1)}setBusyVisibility(e){this._dropdownElement&&(e?this._busyElement.style.removeProperty("display"):this._busyElement.style.display="none")}getScreenWidth(){return window.innerWidth}_getListItemElements(){return this._dropdownElement?Array.from(this._dropdownElement.querySelectorAll(J.elementName)):[]}_toggleSelectedOption(e,t){if(!this._dropdownElement)return;let o=this._getListItemElements();if(o.length){let a=o.filter(d=>d!==e&&d.active);a.length&&a.forEach(d=>d.active=!1)}e.selected=t,e.setAttribute("aria-selected",`${t}`),e.setAttribute("aria-checked",`${t}`),t&&(e.active=!0);let n=e.querySelector(`${j.elementName}[slot=leading]`);if(n){let a=C(t);M(a,n)}}_getTargetElementWidth(e){return e&&P(e)?e():this._targetElement.getBoundingClientRect().width}_activateListOption(e,t){e&&!e.disabled&&(e.active=!0,t&&P(t)&&t(e.id))}_scrollListItemIntoView(e,t="auto",o="nearest"){if(e&&this._dropdownElement&&this._dropdownElement.isConnected){let n=H(this._dropdownElement,b.selectors.CONTAINER);n&&K(n,e,t,o)}}_getSelectedListItem(){return this._getListItemElements().find(t=>t.selected)}};var pe=class{constructor(e,t){this._targetElement=e;q.define([I,O]),this._foundation=new S(new D(this._targetElement),t)}destroy(){this._foundation.destroy()}open(){this._foundation.open()}close(){this._foundation.close()}getActiveOptionIndex(){return this._foundation.getActiveOptionIndex()}getActiveOption(){return this._foundation.getActiveOption()}toggleOptionMultiple(e,t){return this._foundation.toggleOptionMultiple(e,t)}activateSelectedOption(){this._foundation.activateSelectedOption()}activateFirstOption(){return this._foundation.activateFirstOption()}activateOption(e){return this._foundation.activateOption(e)}activateInitialOption(){return this._foundation.activateInitialOption()}clearActiveOption(){this._foundation.clearActiveOption()}setSelectedValues(e){return this._foundation.setSelectedValues(e)}get dropdownElement(){return this._foundation.dropdownElement}setOptions(e){this._foundation.setOptions(e)}appendOptions(e){this._foundation.appendOptions(e)}scrollSelectedOptionIntoView(e){this._foundation.scrollSelectedOptionIntoView()}setScrollBottomListener(e,t){this._foundation.setScrollBottomListener(e,t)}removeScrollBottomListener(){this._foundation.removeScrollBottomListener()}setBusyVisibility(e){this._foundation.setBusyVisibility(e)}handleKey(e){this._foundation.handleKey(e)}};var T=class{constructor(){this._popupClasses=[];this._syncPopupWidth=!1;this._optionLimit=0;this._observeScroll=!1;this._observeScrollThreshold=0;this._constrainPopupWidth=!0;this._wrapOptionText=!1}get syncPopupWidth(){return this._syncPopupWidth}set syncPopupWidth(e){this._syncPopupWidth=e}get popupClasses(){return this._popupClasses}set popupClasses(e){typeof e=="string"&&(e=[e]),Array.isArray(e)&&(this._popupClasses=e)}get observeScroll(){return this._observeScroll}set observeScroll(e){this._observeScroll=e}get observeScrollThreshold(){return this._observeScrollThreshold}set observeScrollThreshold(e){this._observeScrollThreshold=e}get optionLimit(){return this._optionLimit}set optionLimit(e){this._optionLimit=e}get popupHeaderBuilder(){return this._popupHeaderBuilder}set popupHeaderBuilder(e){this._popupHeaderBuilder=e}get popupFooterBuilder(){return this._popupFooterBuilder}set popupFooterBuilder(e){this._popupFooterBuilder=e}get constrainPopupWidth(){return this._constrainPopupWidth}set constrainPopupWidth(e){this._constrainPopupWidth=e}get wrapOptionText(){return this._wrapOptionText}set wrapOptionText(e){this._wrapOptionText=e}_applySelection(){}};var de=class extends T{constructor(t){super();this._config=t;this._open=!1;this._options=[];this._childOpen=!1;this._popupHasMouse=!1;this._targetMouseEnterListener=o=>this._onTargetMouseEnter(o),this._targetMouseLeaveListener=o=>this._onTargetMouseLeave(o),this._childPopupMouseEnterListener=()=>this._onChildPopupMouseEnter(),this._childPopupMouseLeaveListener=()=>this._onChildPopupMouseLeave(),this._documentMouseMoveListener=o=>this._mouseCoords={x:o.pageX,y:o.pageY}}_onChildPopupMouseEnter(){this._popupHasMouse=!0}_onChildPopupMouseLeave(){this._popupHasMouse=!1,setTimeout(()=>{let t=document.elementFromPoint(this._mouseCoords.x,this._mouseCoords.y);!this._popupHasMouse&&!this._childOpen&&(!t||!this._isOwnElement(t))&&(this._setCascadeTargetInactive(),this._closeDropdown())},this._config.popupTimeout)}_onTargetMouseEnter(t){this._options.length&&this._openDropdown({fromKeyboard:!1})}_onTargetMouseLeave(t){this._activeMouseLeaveTimeout=window.setTimeout(()=>{if(!(!this._open||this._childOpen)){if(this._mouseCoords){let o=document.elementFromPoint(this._mouseCoords.x,this._mouseCoords.y);if(o&&this._isOwnElement(o))return}this._setCascadeTargetInactive(),this._closeDropdown()}},this._config.targetTimeout)}_clearMouseLeaveTimeout(){this._activeMouseLeaveTimeout!==void 0&&window.clearTimeout(this._activeMouseLeaveTimeout)}};export{u as a,Z as b,ee as c,te as d,le as e,S as f,D as g,pe as h,T as i,de as j};
7
+ //# sourceMappingURL=chunk.SYZB7B4F.js.map