@tylertech/forge 2.18.0 → 2.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (190) hide show
  1. package/custom-elements.json +1538 -300
  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/banner/index.js +1 -1
  11. package/dist/esm/bottom-sheet/index.js +1 -1
  12. package/dist/esm/button-area/index.js +7 -0
  13. package/dist/esm/button-area/index.js.map +7 -0
  14. package/dist/esm/button-toggle/index.js +1 -1
  15. package/dist/esm/calendar/calendar-dropdown/index.js +1 -1
  16. package/dist/esm/calendar/calendar-menu/index.js +1 -1
  17. package/dist/esm/calendar/index.js +1 -1
  18. package/dist/esm/checkbox/index.js +1 -1
  19. package/dist/esm/chip-field/index.js +1 -1
  20. package/dist/esm/chips/chip/index.js +1 -1
  21. package/dist/esm/chips/chip-set/index.js +1 -1
  22. package/dist/esm/chips/index.js +1 -1
  23. package/dist/esm/chunks/{chunk.HHDEJSOK.js → chunk.23QPY6PU.js} +2 -2
  24. package/dist/esm/chunks/{chunk.6BTPAMJ7.js → chunk.2EAQ36QO.js} +2 -2
  25. package/dist/esm/chunks/{chunk.OYIW3AI6.js → chunk.3NHRJPT4.js} +2 -2
  26. package/dist/esm/chunks/{chunk.UW2HWAVL.js → chunk.42QTJZSF.js} +2 -2
  27. package/dist/esm/chunks/chunk.4DKCMH6P.js +7 -0
  28. package/dist/esm/chunks/chunk.4DKCMH6P.js.map +7 -0
  29. package/dist/esm/chunks/{chunk.QJ7LOIUK.js → chunk.54KXJVRY.js} +2 -2
  30. package/dist/esm/chunks/{chunk.T6NVM7TN.js → chunk.67G7HT5S.js} +2 -2
  31. package/dist/esm/chunks/{chunk.YMBLWKRP.js → chunk.7IHNVPY5.js} +2 -2
  32. package/dist/esm/chunks/{chunk.XFAOB6LU.js → chunk.7NHFZL6J.js} +2 -2
  33. package/dist/esm/chunks/{chunk.SATUJNQX.js → chunk.AD4NVLFA.js} +2 -2
  34. package/dist/esm/chunks/{chunk.D24CE6KE.js → chunk.AZFF62ZK.js} +2 -2
  35. package/dist/esm/chunks/{chunk.JPVIN4NH.js → chunk.BJRQ67AD.js} +2 -2
  36. package/dist/esm/chunks/{chunk.Y7N4KA4U.js → chunk.D43PPRFO.js} +2 -2
  37. package/dist/esm/chunks/chunk.DBKVUCUQ.js +7 -0
  38. package/dist/esm/chunks/chunk.DBKVUCUQ.js.map +7 -0
  39. package/dist/esm/chunks/{chunk.FBHCNPUL.js → chunk.GEWDZDXN.js} +2 -2
  40. package/dist/esm/chunks/{chunk.WVRUVLT4.js → chunk.GSFM6MH4.js} +2 -2
  41. package/dist/esm/chunks/{chunk.MSFGXRCM.js → chunk.IV2GMOPB.js} +2 -2
  42. package/dist/esm/chunks/chunk.IWICN773.js +7 -0
  43. package/dist/esm/chunks/chunk.IWICN773.js.map +7 -0
  44. package/dist/esm/chunks/{chunk.HTH3CEDN.js → chunk.J2PHUKSR.js} +2 -2
  45. package/dist/esm/chunks/{chunk.BKNYDA4V.js → chunk.JCDIPDQR.js} +2 -2
  46. package/dist/esm/chunks/{chunk.RGAPFLQE.js → chunk.JMRXBELV.js} +2 -2
  47. package/dist/esm/chunks/{chunk.WRV4KYM5.js → chunk.JOLJ7WVN.js} +2 -2
  48. package/dist/esm/chunks/{chunk.FOLQAW63.js → chunk.K55FBLTW.js} +2 -2
  49. package/dist/esm/chunks/{chunk.XNCXVZJA.js → chunk.KNVCEYY2.js} +2 -2
  50. package/dist/esm/chunks/{chunk.L4CNH27W.js → chunk.MXVJSEF3.js} +2 -2
  51. package/dist/esm/chunks/{chunk.SQTM36C3.js → chunk.N6XHXCZE.js} +2 -2
  52. package/dist/esm/chunks/{chunk.JDLEPQKN.js → chunk.OEZZ2NEY.js} +2 -2
  53. package/dist/esm/chunks/chunk.P4VJUJQN.js +7 -0
  54. package/dist/esm/chunks/{chunk.K4SWLH26.js.map → chunk.P4VJUJQN.js.map} +3 -3
  55. package/dist/esm/chunks/{chunk.Z7KJ4SA5.js → chunk.P67RC5S3.js} +2 -2
  56. package/dist/esm/chunks/chunk.PBWUHK7Q.js +7 -0
  57. package/dist/esm/chunks/chunk.PBWUHK7Q.js.map +7 -0
  58. package/dist/esm/chunks/{chunk.BKAZC53W.js → chunk.PILDKQOE.js} +2 -2
  59. package/dist/esm/chunks/{chunk.CR2XZYFM.js → chunk.QZ2NXIGY.js} +2 -2
  60. package/dist/esm/chunks/chunk.RH4E52PS.js +7 -0
  61. package/dist/esm/chunks/chunk.RH4E52PS.js.map +7 -0
  62. package/dist/esm/chunks/{chunk.CG5CVENX.js → chunk.RLWX5BFQ.js} +2 -2
  63. package/dist/esm/chunks/{chunk.ZPWB74RA.js → chunk.ROWBKHIO.js} +2 -2
  64. package/dist/esm/chunks/{chunk.274MFEUZ.js → chunk.SFTWKDQV.js} +2 -2
  65. package/dist/esm/chunks/{chunk.WO32MVS4.js → chunk.SNVWMZNK.js} +2 -2
  66. package/dist/esm/chunks/{chunk.WO32MVS4.js.map → chunk.SNVWMZNK.js.map} +1 -1
  67. package/dist/esm/chunks/{chunk.Q5YD3PKM.js → chunk.TH7RLTJK.js} +2 -2
  68. package/dist/esm/chunks/{chunk.K6LBO4KJ.js → chunk.UVL4TIK2.js} +2 -2
  69. package/dist/esm/chunks/{chunk.H5XOBZLW.js → chunk.WOTVTBJS.js} +2 -2
  70. package/dist/esm/chunks/{chunk.RW6UJSE4.js → chunk.WPJEXVHM.js} +2 -2
  71. package/dist/esm/chunks/{chunk.AMES2WWC.js → chunk.XAPKK4ZJ.js} +2 -2
  72. package/dist/esm/chunks/{chunk.NX4EECNP.js → chunk.XTMXGKUO.js} +2 -2
  73. package/dist/esm/chunks/{chunk.2DAPNN6B.js → chunk.Y2I2VRMF.js} +2 -2
  74. package/dist/esm/chunks/chunk.YG2UMTJN.js +12 -0
  75. package/dist/esm/chunks/chunk.YG2UMTJN.js.map +7 -0
  76. package/dist/esm/color-picker/index.js +1 -1
  77. package/dist/esm/core/index.js +1 -1
  78. package/dist/esm/date-picker/index.js +1 -1
  79. package/dist/esm/date-range-picker/index.js +1 -1
  80. package/dist/esm/expansion-panel/index.js +1 -1
  81. package/dist/esm/file-picker/index.js +1 -1
  82. package/dist/esm/floating-label/index.js +1 -1
  83. package/dist/esm/icon/index.js +1 -1
  84. package/dist/esm/icon-button/index.js +1 -1
  85. package/dist/esm/index.js +1 -1
  86. package/dist/esm/list-dropdown/index.js +1 -1
  87. package/dist/esm/menu/index.js +1 -1
  88. package/dist/esm/open-icon/index.js +1 -1
  89. package/dist/esm/paginator/index.js +1 -1
  90. package/dist/esm/profile-card/index.js +1 -1
  91. package/dist/esm/quantity-field/index.js +1 -1
  92. package/dist/esm/select/core/index.js +1 -1
  93. package/dist/esm/select/index.js +1 -1
  94. package/dist/esm/select/select/index.js +1 -1
  95. package/dist/esm/select/select-dropdown/index.js +1 -1
  96. package/dist/esm/slider/index.js +1 -1
  97. package/dist/esm/split-view/index.js +1 -1
  98. package/dist/esm/split-view/split-view/index.js +1 -1
  99. package/dist/esm/split-view/split-view-panel/index.js +1 -1
  100. package/dist/esm/stepper/index.js +1 -1
  101. package/dist/esm/stepper/step/index.js +1 -1
  102. package/dist/esm/stepper/stepper/index.js +1 -1
  103. package/dist/esm/switch/index.js +1 -1
  104. package/dist/esm/table/index.js +1 -1
  105. package/dist/esm/tabs/index.js +1 -1
  106. package/dist/esm/tabs/tab-bar/index.js +1 -1
  107. package/dist/esm/text-field/index.js +1 -1
  108. package/dist/esm/time-picker/index.js +1 -1
  109. package/dist/esm/toast/index.js +1 -1
  110. package/esm/button-area/button-area-adapter.d.ts +45 -0
  111. package/esm/button-area/button-area-adapter.js +106 -0
  112. package/esm/button-area/button-area-constants.d.ts +24 -0
  113. package/esm/button-area/button-area-constants.js +30 -0
  114. package/esm/button-area/button-area-foundation.d.ts +29 -0
  115. package/esm/button-area/button-area-foundation.js +93 -0
  116. package/esm/button-area/button-area.d.ts +24 -0
  117. package/esm/button-area/button-area.js +50 -0
  118. package/esm/button-area/index.d.ts +10 -0
  119. package/esm/button-area/index.js +14 -0
  120. package/esm/expansion-panel/expansion-panel-adapter.d.ts +1 -0
  121. package/esm/expansion-panel/expansion-panel-adapter.js +7 -2
  122. package/esm/field/field-foundation.d.ts +1 -0
  123. package/esm/field/field-foundation.js +17 -7
  124. package/esm/floating-label/floating-label-foundation.d.ts +4 -1
  125. package/esm/floating-label/floating-label-foundation.js +9 -6
  126. package/esm/floating-label/floating-label.d.ts +6 -2
  127. package/esm/floating-label/floating-label.js +2 -2
  128. package/esm/icon/icon-adapter.d.ts +0 -2
  129. package/esm/icon/icon-adapter.js +4 -5
  130. package/esm/icon/icon-foundation.js +0 -1
  131. package/esm/index.d.ts +1 -0
  132. package/esm/index.js +3 -0
  133. package/esm/paginator/paginator-adapter.d.ts +28 -24
  134. package/esm/paginator/paginator-adapter.js +55 -0
  135. package/esm/paginator/paginator-foundation.d.ts +33 -80
  136. package/esm/paginator/paginator-foundation.js +218 -255
  137. package/esm/paginator/paginator.d.ts +0 -2
  138. package/esm/paginator/paginator.js +0 -2
  139. package/esm/split-view/split-view-panel/split-view-panel.js +1 -1
  140. package/package.json +1 -1
  141. package/styles/button-area/_mixins.scss +47 -0
  142. package/styles/button-area/button-area.scss +16 -0
  143. package/dist/esm/chunks/chunk.AMWDVFAU.js +0 -7
  144. package/dist/esm/chunks/chunk.AMWDVFAU.js.map +0 -7
  145. package/dist/esm/chunks/chunk.K4SWLH26.js +0 -7
  146. package/dist/esm/chunks/chunk.KIBLZSFZ.js +0 -7
  147. package/dist/esm/chunks/chunk.KIBLZSFZ.js.map +0 -7
  148. package/dist/esm/chunks/chunk.MCIDFQOG.js +0 -12
  149. package/dist/esm/chunks/chunk.MCIDFQOG.js.map +0 -7
  150. package/dist/esm/chunks/chunk.S2YVOMLW.js +0 -7
  151. package/dist/esm/chunks/chunk.S2YVOMLW.js.map +0 -7
  152. package/dist/esm/chunks/chunk.USXO7YKN.js +0 -7
  153. package/dist/esm/chunks/chunk.USXO7YKN.js.map +0 -7
  154. /package/dist/esm/chunks/{chunk.HHDEJSOK.js.map → chunk.23QPY6PU.js.map} +0 -0
  155. /package/dist/esm/chunks/{chunk.6BTPAMJ7.js.map → chunk.2EAQ36QO.js.map} +0 -0
  156. /package/dist/esm/chunks/{chunk.OYIW3AI6.js.map → chunk.3NHRJPT4.js.map} +0 -0
  157. /package/dist/esm/chunks/{chunk.UW2HWAVL.js.map → chunk.42QTJZSF.js.map} +0 -0
  158. /package/dist/esm/chunks/{chunk.QJ7LOIUK.js.map → chunk.54KXJVRY.js.map} +0 -0
  159. /package/dist/esm/chunks/{chunk.T6NVM7TN.js.map → chunk.67G7HT5S.js.map} +0 -0
  160. /package/dist/esm/chunks/{chunk.YMBLWKRP.js.map → chunk.7IHNVPY5.js.map} +0 -0
  161. /package/dist/esm/chunks/{chunk.XFAOB6LU.js.map → chunk.7NHFZL6J.js.map} +0 -0
  162. /package/dist/esm/chunks/{chunk.SATUJNQX.js.map → chunk.AD4NVLFA.js.map} +0 -0
  163. /package/dist/esm/chunks/{chunk.D24CE6KE.js.map → chunk.AZFF62ZK.js.map} +0 -0
  164. /package/dist/esm/chunks/{chunk.JPVIN4NH.js.map → chunk.BJRQ67AD.js.map} +0 -0
  165. /package/dist/esm/chunks/{chunk.Y7N4KA4U.js.map → chunk.D43PPRFO.js.map} +0 -0
  166. /package/dist/esm/chunks/{chunk.FBHCNPUL.js.map → chunk.GEWDZDXN.js.map} +0 -0
  167. /package/dist/esm/chunks/{chunk.WVRUVLT4.js.map → chunk.GSFM6MH4.js.map} +0 -0
  168. /package/dist/esm/chunks/{chunk.MSFGXRCM.js.map → chunk.IV2GMOPB.js.map} +0 -0
  169. /package/dist/esm/chunks/{chunk.HTH3CEDN.js.map → chunk.J2PHUKSR.js.map} +0 -0
  170. /package/dist/esm/chunks/{chunk.BKNYDA4V.js.map → chunk.JCDIPDQR.js.map} +0 -0
  171. /package/dist/esm/chunks/{chunk.RGAPFLQE.js.map → chunk.JMRXBELV.js.map} +0 -0
  172. /package/dist/esm/chunks/{chunk.WRV4KYM5.js.map → chunk.JOLJ7WVN.js.map} +0 -0
  173. /package/dist/esm/chunks/{chunk.FOLQAW63.js.map → chunk.K55FBLTW.js.map} +0 -0
  174. /package/dist/esm/chunks/{chunk.XNCXVZJA.js.map → chunk.KNVCEYY2.js.map} +0 -0
  175. /package/dist/esm/chunks/{chunk.L4CNH27W.js.map → chunk.MXVJSEF3.js.map} +0 -0
  176. /package/dist/esm/chunks/{chunk.SQTM36C3.js.map → chunk.N6XHXCZE.js.map} +0 -0
  177. /package/dist/esm/chunks/{chunk.JDLEPQKN.js.map → chunk.OEZZ2NEY.js.map} +0 -0
  178. /package/dist/esm/chunks/{chunk.Z7KJ4SA5.js.map → chunk.P67RC5S3.js.map} +0 -0
  179. /package/dist/esm/chunks/{chunk.BKAZC53W.js.map → chunk.PILDKQOE.js.map} +0 -0
  180. /package/dist/esm/chunks/{chunk.CR2XZYFM.js.map → chunk.QZ2NXIGY.js.map} +0 -0
  181. /package/dist/esm/chunks/{chunk.CG5CVENX.js.map → chunk.RLWX5BFQ.js.map} +0 -0
  182. /package/dist/esm/chunks/{chunk.ZPWB74RA.js.map → chunk.ROWBKHIO.js.map} +0 -0
  183. /package/dist/esm/chunks/{chunk.274MFEUZ.js.map → chunk.SFTWKDQV.js.map} +0 -0
  184. /package/dist/esm/chunks/{chunk.Q5YD3PKM.js.map → chunk.TH7RLTJK.js.map} +0 -0
  185. /package/dist/esm/chunks/{chunk.K6LBO4KJ.js.map → chunk.UVL4TIK2.js.map} +0 -0
  186. /package/dist/esm/chunks/{chunk.H5XOBZLW.js.map → chunk.WOTVTBJS.js.map} +0 -0
  187. /package/dist/esm/chunks/{chunk.RW6UJSE4.js.map → chunk.WPJEXVHM.js.map} +0 -0
  188. /package/dist/esm/chunks/{chunk.AMES2WWC.js.map → chunk.XAPKK4ZJ.js.map} +0 -0
  189. /package/dist/esm/chunks/{chunk.NX4EECNP.js.map → chunk.XTMXGKUO.js.map} +0 -0
  190. /package/dist/esm/chunks/{chunk.2DAPNN6B.js.map → chunk.Y2I2VRMF.js.map} +0 -0
@@ -0,0 +1,7 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2023 Tyler Technologies, Inc.
4
+ * License: Apache-2.0
5
+ */
6
+ import{e as E}from"./chunk.DONAMICM.js";import{d as f}from"./chunk.DBKVUCUQ.js";import{a as t}from"./chunk.GO5A4GKZ.js";import{a as m}from"./chunk.5KC43VFL.js";import{a as r}from"./chunk.KTGSZEAG.js";import{g as n,l as g}from"./chunk.HOXFK44F.js";import{f as _,g as b,m as u,o as L,s as c,t as h,z as v}from"./chunk.4LA6HEA7.js";import{k as d}from"./chunk.J2M2MXP2.js";import{f as o}from"./chunk.MCIQXNKY.js";var S=class extends m{constructor(e){super(e);this._valueChangeListeners=[]}initialize(e){this._rootElement=n(this._component,e),this._labelSlot=n(this._component,"slot[name=label]"),this._leadingSlot=n(this._component,"slot[name=leading]"),this._trailingSlot=n(this._component,"slot[name=trailing]"),this._addonEndSlot=n(this._component,"slot[name=addon-end]"),this._inputElement=this._component.querySelector("input:not([type=checkbox]):not([type=radio])"),this.detectLabel()}destroy(){this._inputMutationObserver&&this._inputMutationObserver.disconnect()}hasLabel(){return!!this._labelElement}ensureSlottedLabel(){this._labelElement.slot="label"}ensureLabelOrder(){if(this._labelElement){let e=Array.from(this._component.children);e.length>1&&e.indexOf(this._labelElement)<e.indexOf(this._inputElement)&&this._component.appendChild(this._labelElement)}}addLabelSlotListener(e){this._labelSlot.addEventListener("slotchange",e)}removeLabelSlotListener(e){this._labelSlot&&this._labelSlot.removeEventListener("slotchange",e)}addLeadingSlotListener(e){this._leadingSlot.addEventListener("slotchange",e)}removeLeadingSlotListener(e){this._leadingSlot&&this._leadingSlot.removeEventListener("slotchange",e)}addTrailingSlotListener(e){this._trailingSlot.addEventListener("slotchange",e)}removeTrailingSlotListener(e){this._trailingSlot&&this._trailingSlot.removeEventListener("slotchange",e)}addAddonEndSlotListener(e){this._addonEndSlot.addEventListener("slotchange",e)}removeAddonEndSlotListener(e){this._addonEndSlot&&this._addonEndSlot.removeEventListener("slotchange",e)}addInputListener(e,s){this._inputElement.addEventListener(e,s)}removeInputListener(e,s){this._inputElement&&this._inputElement.removeEventListener(e,s)}setValueChangedListener(e,s){this.destroyValueChangeListener();let a=E(e,this._inputElement,"value",s);this._valueChangeListeners.push(a)}destroyValueChangeListener(){this._valueChangeListeners.forEach(e=>e())}detectLabel(){this._labelElement=this._component.querySelector("label")}initializeFloatingLabel(){return new f(this._labelElement)}inputHasValue(){return this._inputElement.value?this._inputElement.value.trim().length>0:!1}fieldHasValue(){return this.inputHasValue()}hasPlaceholder(){return this._inputElement.placeholder?this._inputElement.placeholder.trim().length>0:!1}inputHasFocus(e){return this._inputElement===e||this._inputElement===c(this._component.ownerDocument)}setLabelClass(e){this._labelElement&&this._labelElement.classList.add(e)}removeLabelClass(e){this._labelElement&&this._labelElement.classList.remove(e)}isLabelFloating(){return this._component.hasAttribute(t.attributes.HOST_LABEL_FLOATING)}setRoomy(e){h(this._rootElement,e,t.classes.ROOMY)}setDense(e){h(this._rootElement,e,t.classes.DENSE)}hasLeadingNodes(){return this._leadingSlot?this._leadingSlot.assignedNodes().length>0:!1}hasTrailingNodes(){return this._trailingSlot?this._trailingSlot.assignedNodes().length>0:!1}hasAddonEndNodes(){return this._addonEndSlot?this._addonEndSlot.assignedNodes().length>0:!1}setInputClass(e){this._inputElement.classList.add(e)}removeInputClass(e){this._inputElement.classList.remove(e)}setRootClass(e){_(e,this._rootElement)}removeRootClass(e){b(e,this._rootElement)}setInputAttributeObserver(e){this._inputMutationObserver=v(this._inputElement,e,t.observedInputAttributes)}isDisabled(){return this._inputElement.hasAttribute("disabled")}isReadonly(){return this._inputElement.hasAttribute("readonly")}getLabelWidth(e,s){return L(this._labelElement.innerText,{fontSize:e,fontFamily:s})}getLabelFontMetrics(){let e=getComputedStyle(this._labelElement);return{fontSize:parseInt(e.fontSize||"16",10),fontFamily:e.fontFamily||"Roboto"}}};var y=class{constructor(i){this._adapter=i;this._density="default";this._shape="default";this._invalid=!1;this._required=!1;this._floatLabelType="auto";this._isInitialized=!1;this._labelSlotListener=e=>this._onLabelSlotChanged(e),this._leadingSlotListener=e=>this._onLeadingSlotChanged(e),this._trailingSlotListener=e=>this._onTrailingSlotChanged(e),this._addonEndSlotListener=e=>this._onAddonEndSlotChanged(e),this._focusListener=e=>this._onFocus(e),this._blurListener=e=>this._onBlur(e),this._valueChangedListener=e=>this._onValueChanged(e),this._inputAttributeChangedListener=(e,s)=>this._onInputAttributeChanged(e,s)}initialize(){this._adapter.initialize(""),this._adapter.hasLabel()&&this._adapter.ensureSlottedLabel(),this._initializeLabel(),this._adapter.hasPlaceholder()&&(this._floatLabelType="always"),this._detectSlottedContent(),this._adapter.addLabelSlotListener(this._labelSlotListener),this._adapter.addLeadingSlotListener(this._leadingSlotListener),this._adapter.addTrailingSlotListener(this._trailingSlotListener),this._adapter.addAddonEndSlotListener(this._addonEndSlotListener),this._adapter.setValueChangedListener(this,this._valueChangedListener),this._adapter.addInputListener("focus",this._focusListener),this._adapter.addInputListener("blur",this._blurListener),this._adapter.setInputAttributeObserver(this._inputAttributeChangedListener),this._applyDensity(),this._setShapeType(),this._setValidity(),this._adapter.isDisabled()?this._adapter.setRootClass(t.classes.DISABLED):this._adapter.removeRootClass(t.classes.DISABLED),this._adapter.isReadonly()?this._adapter.setRootClass(t.classes.READONLY):this._adapter.removeRootClass(t.classes.READONLY),this._floatLabelType==="always"&&this.floatLabel(!0),this._isInitialized=!0}disconnect(){this._isInitialized=!1,this._adapter.destroy(),this._adapter.removeHostAttribute(t.attributes.HOST_LABEL_FLOATING),this._adapter.removeRootClass(t.classes.LABEL),this._floatingLabel&&(this._floatingLabel.destroy(),this._floatingLabel=void 0),this._adapter.removeLabelSlotListener(this._labelSlotListener),this._adapter.removeLeadingSlotListener(this._leadingSlotListener),this._adapter.removeTrailingSlotListener(this._trailingSlotListener),this._adapter.removeAddonEndSlotListener(this._addonEndSlotListener),this._adapter.removeInputListener("focus",this._focusListener),this._adapter.removeInputListener("blur",this._blurListener),this._adapter.destroyValueChangeListener()}get density(){return this._density}set density(i){if(this._density!==i){let e=this._density;this._density=i,this._isInitialized&&(this._applyDensity(),this._density==="dense"?this._destroyFloatingLabel({cancelFloat:!0}):e==="dense"&&this._initializeLabel()),this._adapter.setHostAttribute(t.attributes.DENSITY,this._density.toString())}}get floatLabelType(){return this._floatLabelType}set floatLabelType(i){this._floatLabelType!==i&&(this._floatLabelType=i,this._isInitialized&&this.floatLabel(this._floatLabelType==="always"),this._adapter.setHostAttribute(t.attributes.FLOAT_LABEL_TYPE,this._floatLabelType))}get shape(){return this._shape}set shape(i){this._shape!==i&&(this._shape=i,this._isInitialized&&this._setShapeType(),this._adapter.setHostAttribute(t.attributes.SHAPE,this._shape))}get invalid(){return this._invalid}set invalid(i){this._invalid!==i&&(this._invalid=i,this._isInitialized&&this._setValidity())}get required(){return this._required}set required(i){this._required!==i&&(this._required=i,this._isInitialized&&this._setValidity(),this._required?this._adapter.setHostAttribute(t.attributes.REQUIRED):this._adapter.removeHostAttribute(t.attributes.REQUIRED))}floatLabel(i){var e,s;if(((e=this._floatingLabel)==null?void 0:e.isFloating)===i||this._adapter.isLabelFloating()===i){i&&this._adapter.setHostAttribute(t.attributes.HOST_LABEL_FLOATING,"");return}if(!i&&this._floatLabelType==="always"){(s=this._floatingLabel)==null||s.float(!0,!0),this._adapter.setHostAttribute(t.attributes.HOST_LABEL_FLOATING,"");return}this._floatingLabel&&(this._floatingLabel.float(i,this._floatLabelType==="always"),i?(this._adapter.setInputClass(t.classes.INPUT_FOCUSED),this._adapter.setHostAttribute(t.attributes.HOST_LABEL_FLOATING,"")):(this._adapter.removeInputClass(t.classes.INPUT_FOCUSED),this._adapter.removeHostAttribute(t.attributes.HOST_LABEL_FLOATING)))}_onLabelSlotChanged(i){this._initializeLabel()}_onLeadingSlotChanged(i){this._detectLeadingContent()}_onTrailingSlotChanged(i){this._detectTrailingContent()}_onAddonEndSlotChanged(i){this._detectAddonEndContent()}_initializeLabel(){var i;(i=this._floatingLabel)==null||i.destroy(),this._adapter.detectLabel(),this._adapter.hasLabel()&&this._density!=="dense"?(this._floatingLabel=this._adapter.initializeFloatingLabel(),this._adapter.ensureLabelOrder(),this.floatLabel(this._floatLabelType==="always"||this._adapter.fieldHasValue()||this._adapter.hasPlaceholder()),this._adapter.setRootClass(t.classes.LABEL)):this._destroyFloatingLabel()}_destroyFloatingLabel({cancelFloat:i=!1}={}){var e;this._adapter.removeHostAttribute(t.attributes.HOST_LABEL_FLOATING),this._adapter.removeRootClass(t.classes.LABEL),(e=this._floatingLabel)==null||e.destroy({cancelFloat:i}),this._floatingLabel=void 0}_detectLeadingContent(){this._adapter.hasLeadingNodes()?this._adapter.setRootClass(t.classes.LEADING):this._adapter.removeRootClass(t.classes.LEADING)}_detectTrailingContent(){this._adapter.hasTrailingNodes()?this._adapter.setRootClass(t.classes.TRAILING):this._adapter.removeRootClass(t.classes.TRAILING)}_detectAddonEndContent(){this._adapter.hasAddonEndNodes()?this._adapter.setRootClass(t.classes.ADDON_END):this._adapter.removeRootClass(t.classes.ADDON_END)}_detectSlottedContent(){this._detectLeadingContent(),this._detectTrailingContent(),this._detectAddonEndContent()}_onFocus(i){this._adapter.setRootClass(t.classes.FOCUSED),this._adapter.setLabelClass(t.classes.LABEL_FOCUSED),this.floatLabel(!0)}_onBlur(i){this._adapter.inputHasFocus(i.relatedTarget)||(this._adapter.removeRootClass(t.classes.FOCUSED),this._adapter.removeLabelClass(t.classes.LABEL_FOCUSED),!this._adapter.fieldHasValue()&&!this._adapter.hasPlaceholder()&&(this.floatLabel(!1),this._adapter.removeHostAttribute(t.attributes.HOST_LABEL_FLOATING)))}_onValueChanged(i){this._adapter.fieldHasValue()?this.floatLabel(!0):!this._adapter.inputHasFocus()&&!this._adapter.hasPlaceholder()&&this.floatLabel(!1)}_onInputAttributeChanged(i,e){switch(this._adapter.isDisabled()?(this._adapter.setRootClass(t.classes.DISABLED),this._adapter.removeRootClass(t.classes.FOCUSED),this._adapter.removeInputClass(t.classes.INPUT_FOCUSED),this._adapter.removeLabelClass(t.classes.LABEL_FOCUSED),!this._adapter.fieldHasValue()&&!this._adapter.hasPlaceholder()&&this._floatingLabel&&this.floatLabel(!1)):this._adapter.removeRootClass(t.classes.DISABLED),this._adapter.isReadonly()?this._adapter.setRootClass(t.classes.READONLY):(this._adapter.removeRootClass(t.classes.READONLY),this._adapter.removeRootClass(t.classes.FOCUSED),this._adapter.removeInputClass(t.classes.INPUT_FOCUSED)),i){case"readonly":case"disabled":this._adapter.inputHasFocus()&&(this._adapter.setRootClass(t.classes.FOCUSED),this._adapter.setInputClass(t.classes.INPUT_FOCUSED),this._adapter.setLabelClass(t.classes.LABEL_FOCUSED));break;case"value":this._floatingLabel&&this.floatLabel(this._adapter.fieldHasValue());break;case"placeholder":if(this._floatingLabel){let s=!!e&&!!e.trim()||this._adapter.fieldHasValue();s!==this._floatingLabel.isFloating&&this.floatLabel(s)}break}}_setShapeType(){this._shape==="rounded"?this._adapter.setRootClass(t.classes.SHAPE_ROUNDED):this._adapter.removeRootClass(t.classes.SHAPE_ROUNDED)}_setValidity(){this._invalid?this._adapter.setRootClass(t.classes.INVALID):this._adapter.removeRootClass(t.classes.INVALID),this._required?this._adapter.setRootClass(t.classes.REQUIRED):this._adapter.removeRootClass(t.classes.REQUIRED)}_applyDensity(){this._adapter.setRoomy(this._density==="roomy"),this._adapter.setDense(this._density==="dense")}};var l=class extends g{constructor(){super()}static get observedAttributes(){return[t.attributes.DENSITY,t.attributes.FLOAT_LABEL_TYPE,t.attributes.SHAPE,t.attributes.INVALID,t.attributes.REQUIRED]}connectedCallback(){this.querySelector(t.selectors.INPUT)?this._initialize():u(this,t.selectors.INPUT).then(()=>this._initialize())}_initialize(){this._foundation.initialize()}disconnectedCallback(){this._foundation.disconnect()}attributeChangedCallback(e,s,a){switch(e){case t.attributes.DENSITY:this.density=a;break;case t.attributes.FLOAT_LABEL_TYPE:this.floatLabelType=a;break;case t.attributes.SHAPE:this.shape=a;break;case t.attributes.INVALID:this.invalid=d(a);break;case t.attributes.REQUIRED:this.required=d(a);break}}floatLabel(e){this._foundation.floatLabel(e)}};o([r()],l.prototype,"density",2),o([r()],l.prototype,"floatLabelType",2),o([r()],l.prototype,"shape",2),o([r()],l.prototype,"invalid",2),o([r()],l.prototype,"required",2);export{S as a,y as b,l as c};
7
+ //# sourceMappingURL=chunk.P4VJUJQN.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/field/field-adapter.ts", "../../src/field/field-foundation.ts", "../../src/field/field.ts"],
4
- "sourcesContent": ["import { addClass, calculateFontWidth, getShadowElement, IFontInfo, listenOwnProperty, Platform, removeClass, getActiveElement, createElementAttributeObserver, toggleClass, toggleAttribute } from '@tylertech/forge-core';\nimport { BaseAdapter, IBaseAdapter } from '../core/base/base-adapter';\nimport { FloatingLabel, IFloatingLabel } from '../floating-label/floating-label';\nimport { IFieldComponent } from './field';\nimport { FIELD_CONSTANTS } from './field-constants';\n\nexport interface IFieldAdapter extends IBaseAdapter {\n // root\n setRootClass(classes: string | string[]): void;\n removeRootClass(classes: string | string[]): void;\n\n // input\n addInputListener(type: string, listener: (evt: Event) => void): void;\n removeInputListener(type: string, listener: (evt: Event) => void): void;\n setInputClass(className: string): void;\n removeInputClass(className: string): void;\n\n // label\n addLabelSlotListener(listener: (evt: Event) => void): void;\n removeLabelSlotListener(listener: (evt: Event) => void): void;\n setLabelClass(name: string): void;\n removeLabelClass(name: string): void;\n isLabelFloating(): boolean;\n\n // leading\n addLeadingSlotListener(listener: (evt: Event) => void): void;\n removeLeadingSlotListener(listener: (evt: Event) => void): void;\n\n // trailing\n addTrailingSlotListener(listener: (evt: Event) => void): void;\n removeTrailingSlotListener(listener: (evt: Event) => void): void;\n\n // add on end\n addAddonEndSlotListener(listener: (evt: Event) => void): void;\n removeAddonEndSlotListener(listener: (evt: Event) => void): void;\n\n // state selectors\n hasAddonEndNodes(): boolean;\n hasLabel(): boolean;\n hasLeadingNodes(): boolean;\n hasPlaceholder(): boolean;\n hasTrailingNodes(): boolean;\n inputHasFocus(target?: EventTarget | null): boolean;\n inputHasValue(): boolean;\n fieldHasValue(): boolean;\n isDisabled(): boolean;\n isReadonly(): boolean;\n getLabelFontMetrics(): IFontInfo;\n getLabelWidth(fontSize: number, fontFamily: string): number;\n\n // state actions\n initialize(rootSelector: string): void;\n initializeFloatingLabel(): IFloatingLabel;\n ensureLabelOrder(): void;\n ensureSlottedLabel(): void;\n destroy(): void;\n setValueChangedListener(context: any, listener: (value: any) => void): void;\n destroyValueChangeListener(): void;\n detectLabel(): void;\n setRoomy(isRoomy: boolean): void;\n setDense(isDense: boolean): void;\n setInputAttributeObserver(listener: (name: string, value: string | null) => void): void;\n}\n\nexport class FieldAdapter extends BaseAdapter<IFieldComponent> implements IFieldAdapter {\n protected _rootElement: HTMLElement;\n protected _labelSlot: HTMLSlotElement;\n protected _leadingSlot: HTMLSlotElement;\n protected _trailingSlot: HTMLSlotElement;\n protected _addonEndSlot: HTMLSlotElement;\n protected _labelElement: HTMLLabelElement;\n protected _inputElement: HTMLInputElement;\n protected _inputMutationObserver: MutationObserver;\n protected _valueChangeListeners: Array<() => void> = [];\n\n constructor(component: IFieldComponent) {\n super(component);\n }\n\n public initialize(rootSelector: string): void {\n this._rootElement = getShadowElement(this._component, rootSelector);\n this._labelSlot = getShadowElement(this._component, 'slot[name=label]') as HTMLSlotElement;\n this._leadingSlot = getShadowElement(this._component, 'slot[name=leading]') as HTMLSlotElement;\n this._trailingSlot = getShadowElement(this._component, 'slot[name=trailing]') as HTMLSlotElement;\n this._addonEndSlot = getShadowElement(this._component, 'slot[name=addon-end]') as HTMLSlotElement;\n this._inputElement = this._component.querySelector('input:not([type=checkbox]):not([type=radio])') as HTMLInputElement;\n this.detectLabel();\n }\n\n public destroy(): void {\n if (this._inputMutationObserver) {\n this._inputMutationObserver.disconnect();\n }\n }\n\n public hasLabel(): boolean {\n return !!this._labelElement;\n }\n\n public ensureSlottedLabel(): void {\n this._labelElement.slot = 'label';\n }\n\n public ensureLabelOrder(): void {\n if (this._labelElement) {\n const children = Array.from(this._component.children);\n if (children.length > 1 && children.indexOf(this._labelElement) < children.indexOf(this._inputElement)) {\n this._component.appendChild(this._labelElement);\n }\n }\n }\n\n public addLabelSlotListener(listener: (evt: Event) => void): void {\n this._labelSlot.addEventListener('slotchange', listener);\n }\n\n public removeLabelSlotListener(listener: (evt: Event) => void): void {\n if (this._labelSlot) {\n this._labelSlot.removeEventListener('slotchange', listener);\n }\n }\n\n public addLeadingSlotListener(listener: (evt: Event) => void): void {\n this._leadingSlot.addEventListener('slotchange', listener);\n }\n\n public removeLeadingSlotListener(listener: (evt: Event) => void): void {\n if (this._leadingSlot) {\n this._leadingSlot.removeEventListener('slotchange', listener);\n }\n }\n\n public addTrailingSlotListener(listener: (evt: Event) => void): void {\n this._trailingSlot.addEventListener('slotchange', listener);\n }\n\n public removeTrailingSlotListener(listener: (evt: Event) => void): void {\n if (this._trailingSlot) {\n this._trailingSlot.removeEventListener('slotchange', listener);\n }\n }\n\n public addAddonEndSlotListener(listener: (evt: Event) => void): void {\n this._addonEndSlot.addEventListener('slotchange', listener);\n }\n\n public removeAddonEndSlotListener(listener: (evt: Event) => void): void {\n if (this._addonEndSlot) {\n this._addonEndSlot.removeEventListener('slotchange', listener);\n }\n }\n\n public addInputListener(type: string, listener: (evt: Event) => void): void {\n this._inputElement.addEventListener(type, listener);\n }\n public removeInputListener(type: string, listener: (evt: Event) => void): void {\n if (this._inputElement) {\n this._inputElement.removeEventListener(type, listener);\n }\n }\n\n public setValueChangedListener(context: any, listener: (value: any) => void): void {\n this.destroyValueChangeListener();\n const destroyListener = listenOwnProperty(context, this._inputElement, 'value', listener);\n this._valueChangeListeners.push(destroyListener);\n }\n\n public destroyValueChangeListener(): void {\n this._valueChangeListeners.forEach(cb => cb());\n }\n\n public detectLabel(): void {\n this._labelElement = this._component.querySelector('label') as HTMLLabelElement;\n }\n\n public initializeFloatingLabel(): IFloatingLabel {\n return new FloatingLabel(this._labelElement);\n }\n\n public inputHasValue(): boolean {\n return this._inputElement.value ? this._inputElement.value.trim().length > 0 : false;\n }\n\n // An overrideable method for more generic field values where input.value is not the value.\n public fieldHasValue(): boolean {\n return this.inputHasValue();\n }\n\n public hasPlaceholder(): boolean {\n return this._inputElement.placeholder ? this._inputElement.placeholder.trim().length > 0 : false;\n }\n\n public inputHasFocus(target?: EventTarget | null): boolean {\n return this._inputElement === target || this._inputElement === getActiveElement(this._component.ownerDocument);\n }\n\n public setLabelClass(name: string): void {\n if (this._labelElement) {\n this._labelElement.classList.add(name);\n }\n }\n\n public removeLabelClass(name: string): void {\n if (this._labelElement) {\n this._labelElement.classList.remove(name);\n }\n }\n\n public isLabelFloating(): boolean {\n return this._component.hasAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING);\n }\n\n public setRoomy(isRoomy: boolean): void {\n toggleClass(this._rootElement, isRoomy, FIELD_CONSTANTS.classes.ROOMY);\n }\n\n public setDense(isDense: boolean): void {\n toggleClass(this._rootElement, isDense, FIELD_CONSTANTS.classes.DENSE);\n }\n\n public hasLeadingNodes(): boolean {\n if (!this._leadingSlot) {\n return false;\n }\n return this._leadingSlot.assignedNodes().length > 0;\n }\n\n public hasTrailingNodes(): boolean {\n if (!this._trailingSlot) {\n return false;\n }\n return this._trailingSlot.assignedNodes().length > 0;\n }\n\n public hasAddonEndNodes(): boolean {\n if (!this._addonEndSlot) {\n return false;\n }\n return this._addonEndSlot.assignedNodes().length > 0;\n }\n\n public setInputClass(className: string): void {\n this._inputElement.classList.add(className);\n }\n\n public removeInputClass(className: string): void {\n this._inputElement.classList.remove(className);\n }\n\n public setRootClass(classes: string | string[]): void {\n addClass(classes, this._rootElement);\n }\n\n public removeRootClass(classes: string | string[]): void {\n removeClass(classes, this._rootElement);\n }\n\n public setInputAttributeObserver(listener: (name: string, value: string | null) => void): void {\n this._inputMutationObserver = createElementAttributeObserver(this._inputElement, listener, FIELD_CONSTANTS.observedInputAttributes);\n }\n\n public isDisabled(): boolean {\n return this._inputElement.hasAttribute('disabled');\n }\n\n public isReadonly(): boolean {\n return this._inputElement.hasAttribute('readonly');\n }\n\n public getLabelWidth(fontSize: number, fontFamily: string): number {\n return calculateFontWidth(this._labelElement.innerText, { fontSize, fontFamily });\n }\n\n public getLabelFontMetrics(): IFontInfo {\n const style = getComputedStyle(this._labelElement);\n return {\n fontSize: parseInt(style.fontSize || '16', 10),\n fontFamily: style.fontFamily || 'Roboto'\n };\n }\n}\n", "import { ICustomElementFoundation } from '@tylertech/forge-core';\nimport { IFloatingLabel } from '../floating-label/floating-label';\nimport { IFieldAdapter } from './field-adapter';\nimport { FIELD_CONSTANTS, FieldFloatLabelType, FieldShapeType, FieldDensityType } from './field-constants';\n\nexport interface IFieldFoundation extends ICustomElementFoundation {\n density: FieldDensityType;\n floatLabelType: FieldFloatLabelType;\n shape: FieldShapeType;\n invalid: boolean;\n required: boolean;\n floatLabel(value: boolean, alwaysFloat?: boolean): void;\n}\n\nexport class FieldFoundation {\n protected _density: FieldDensityType = 'default';\n protected _floatingLabel: IFloatingLabel | undefined;\n protected _shape: FieldShapeType = 'default';\n protected _invalid = false;\n protected _required = false;\n protected _floatLabelType: FieldFloatLabelType = 'auto';\n protected _isInitialized = false;\n protected _labelSlotListener: (evt: Event) => void;\n protected _leadingSlotListener: (evt: Event) => void;\n protected _trailingSlotListener: (evt: Event) => void;\n protected _addonEndSlotListener: (evt: Event) => void;\n protected _focusListener: (evt: Event) => void;\n protected _blurListener: (evt: Event) => void;\n protected _valueChangedListener: (value: any) => void;\n protected _inputAttributeChangedListener: (name: string, value: string) => void;\n\n constructor(protected _adapter: IFieldAdapter) {\n this._labelSlotListener = evt => this._onLabelSlotChanged(evt);\n this._leadingSlotListener = evt => this._onLeadingSlotChanged(evt);\n this._trailingSlotListener = evt => this._onTrailingSlotChanged(evt);\n this._addonEndSlotListener = evt => this._onAddonEndSlotChanged(evt);\n this._focusListener = (evt: FocusEvent) => this._onFocus(evt);\n this._blurListener = (evt: FocusEvent) => this._onBlur(evt);\n this._valueChangedListener = (value: any) => this._onValueChanged(value);\n this._inputAttributeChangedListener = (name, value) => this._onInputAttributeChanged(name, value);\n }\n\n //\n // Public\n //\n\n public initialize(): void {\n this._adapter.initialize('');\n\n if (this._adapter.hasLabel()) {\n this._adapter.ensureSlottedLabel();\n }\n\n this._initializeLabel();\n\n if (this._adapter.hasPlaceholder()) {\n this._floatLabelType = 'always';\n }\n\n this._detectSlottedContent();\n this._adapter.addLabelSlotListener(this._labelSlotListener);\n this._adapter.addLeadingSlotListener(this._leadingSlotListener);\n this._adapter.addTrailingSlotListener(this._trailingSlotListener);\n this._adapter.addAddonEndSlotListener(this._addonEndSlotListener);\n this._adapter.setValueChangedListener(this, this._valueChangedListener);\n this._adapter.addInputListener('focus', this._focusListener);\n this._adapter.addInputListener('blur', this._blurListener);\n this._adapter.setInputAttributeObserver(this._inputAttributeChangedListener);\n this._applyDensity();\n this._setShapeType();\n this._setValidity();\n\n if (this._adapter.isDisabled()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.DISABLED);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.DISABLED);\n }\n\n if (this._adapter.isReadonly()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.READONLY);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.READONLY);\n }\n\n if (this._floatLabelType === 'always') {\n this.floatLabel(true);\n }\n\n this._isInitialized = true;\n }\n\n public disconnect(): void {\n this._isInitialized = false;\n this._adapter.destroy();\n\n this._adapter.removeHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING);\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.LABEL);\n\n if (this._floatingLabel) {\n this._floatingLabel.destroy();\n this._floatingLabel = undefined;\n }\n\n this._adapter.removeLabelSlotListener(this._labelSlotListener);\n this._adapter.removeLeadingSlotListener(this._leadingSlotListener);\n this._adapter.removeTrailingSlotListener(this._trailingSlotListener);\n this._adapter.removeAddonEndSlotListener(this._addonEndSlotListener);\n this._adapter.removeInputListener('focus', this._focusListener);\n this._adapter.removeInputListener('blur', this._blurListener);\n this._adapter.destroyValueChangeListener();\n }\n\n public get density(): FieldDensityType {\n return this._density;\n }\n public set density(value: FieldDensityType) {\n if (this._density !== value) {\n this._density = value;\n\n if (this._isInitialized) {\n this._applyDensity();\n this._initializeLabel();\n }\n\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.DENSITY, this._density.toString());\n }\n }\n\n public get floatLabelType(): FieldFloatLabelType {\n return this._floatLabelType;\n }\n public set floatLabelType(value: FieldFloatLabelType) {\n if (this._floatLabelType !== value) {\n this._floatLabelType = value;\n\n if (this._isInitialized) {\n this.floatLabel(this._floatLabelType === 'always');\n }\n\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.FLOAT_LABEL_TYPE, this._floatLabelType);\n }\n }\n\n public get shape(): FieldShapeType {\n return this._shape;\n }\n public set shape(value: FieldShapeType) {\n if (this._shape !== value) {\n this._shape = value;\n\n if (this._isInitialized) {\n this._setShapeType();\n }\n\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.SHAPE, this._shape);\n }\n }\n\n public get invalid(): boolean {\n return this._invalid;\n }\n public set invalid(value: boolean) {\n if (this._invalid !== value) {\n this._invalid = value;\n\n if (this._isInitialized) {\n this._setValidity();\n }\n }\n }\n\n public get required(): boolean {\n return this._required;\n }\n public set required(value: boolean) {\n if (this._required !== value) {\n this._required = value;\n\n if (this._isInitialized) {\n this._setValidity();\n }\n\n if (this._required) {\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.REQUIRED);\n } else {\n this._adapter.removeHostAttribute(FIELD_CONSTANTS.attributes.REQUIRED);\n }\n }\n }\n\n public floatLabel(value: boolean): void {\n if (this._floatingLabel?.isFloating === value || this._adapter.isLabelFloating() === value) {\n if (value) {\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING, '');\n }\n return;\n }\n\n if (!value && this._floatLabelType === 'always') {\n this._floatingLabel?.float(true, true);\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING, '');\n return;\n }\n\n if (this._floatingLabel) {\n this._floatingLabel.float(value, this._floatLabelType === 'always');\n\n if (value) {\n this._adapter.setInputClass(FIELD_CONSTANTS.classes.INPUT_FOCUSED);\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING, '');\n } else {\n this._adapter.removeInputClass(FIELD_CONSTANTS.classes.INPUT_FOCUSED);\n this._adapter.removeHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING);\n }\n }\n }\n\n //\n // Protected\n //\n\n protected _onLabelSlotChanged(evt: Event): void {\n this._initializeLabel();\n }\n\n protected _onLeadingSlotChanged(evt: Event): void {\n this._detectLeadingContent();\n }\n\n protected _onTrailingSlotChanged(evt: Event): void {\n this._detectTrailingContent();\n }\n\n protected _onAddonEndSlotChanged(evt: Event): void {\n this._detectAddonEndContent();\n }\n\n protected _initializeLabel(): void {\n if (this._floatingLabel) {\n this._floatingLabel.destroy();\n }\n this._adapter.detectLabel();\n if (this._adapter.hasLabel() && this._density !== 'dense') {\n this._floatingLabel = this._adapter.initializeFloatingLabel();\n this._adapter.ensureLabelOrder();\n this.floatLabel(this._floatLabelType === 'always' || this._adapter.fieldHasValue() || this._adapter.hasPlaceholder());\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.LABEL);\n } else {\n this._adapter.removeHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING);\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.LABEL);\n this._floatingLabel = undefined;\n }\n }\n\n protected _detectLeadingContent(): void {\n if (this._adapter.hasLeadingNodes()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.LEADING);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.LEADING);\n }\n }\n\n protected _detectTrailingContent(): void {\n if (this._adapter.hasTrailingNodes()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.TRAILING);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.TRAILING);\n }\n }\n\n protected _detectAddonEndContent(): void {\n if (this._adapter.hasAddonEndNodes()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.ADDON_END);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.ADDON_END);\n }\n }\n\n protected _detectSlottedContent(): void {\n this._detectLeadingContent();\n this._detectTrailingContent();\n this._detectAddonEndContent();\n }\n\n protected _onFocus(evt: FocusEvent): void {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.FOCUSED);\n this._adapter.setLabelClass(FIELD_CONSTANTS.classes.LABEL_FOCUSED);\n this.floatLabel(true);\n }\n\n protected _onBlur(evt: FocusEvent): void {\n if (this._adapter.inputHasFocus(evt.relatedTarget)) {\n return;\n }\n\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.FOCUSED);\n this._adapter.removeLabelClass(FIELD_CONSTANTS.classes.LABEL_FOCUSED);\n\n if (!this._adapter.fieldHasValue() && !this._adapter.hasPlaceholder()) {\n this.floatLabel(false);\n this._adapter.removeHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING);\n }\n }\n\n protected _onValueChanged(value: any): void {\n if (this._adapter.fieldHasValue()) {\n this.floatLabel(true);\n } else if (!this._adapter.inputHasFocus() && !this._adapter.hasPlaceholder()) {\n this.floatLabel(false);\n }\n }\n\n protected _onInputAttributeChanged(name: string, value: string | null): void {\n if (this._adapter.isDisabled()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.DISABLED);\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.FOCUSED);\n this._adapter.removeInputClass(FIELD_CONSTANTS.classes.INPUT_FOCUSED);\n this._adapter.removeLabelClass(FIELD_CONSTANTS.classes.LABEL_FOCUSED);\n\n if (!this._adapter.fieldHasValue() && !this._adapter.hasPlaceholder() && this._floatingLabel) {\n this.floatLabel(false);\n }\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.DISABLED);\n }\n\n if (this._adapter.isReadonly()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.READONLY);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.READONLY);\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.FOCUSED);\n this._adapter.removeInputClass(FIELD_CONSTANTS.classes.INPUT_FOCUSED);\n }\n\n switch (name) {\n case 'readonly':\n case 'disabled':\n // If we are changing the readonly or disabled attribute, we want to make sure that we apply\n // the focus state properly if the input element also now has focus\n if (this._adapter.inputHasFocus()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.FOCUSED);\n this._adapter.setInputClass(FIELD_CONSTANTS.classes.INPUT_FOCUSED);\n this._adapter.setLabelClass(FIELD_CONSTANTS.classes.LABEL_FOCUSED);\n }\n break;\n case 'value':\n if (this._floatingLabel) {\n this.floatLabel(this._adapter.fieldHasValue());\n }\n break;\n case 'placeholder':\n if (this._floatingLabel) {\n const float = (!!value && !!value.trim()) || this._adapter.fieldHasValue();\n if (float !== this._floatingLabel.isFloating) {\n this.floatLabel(float);\n }\n }\n break;\n }\n }\n\n protected _setShapeType(): void {\n if (this._shape === 'rounded') {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.SHAPE_ROUNDED);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.SHAPE_ROUNDED);\n }\n }\n\n protected _setValidity(): void {\n if (this._invalid) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.INVALID);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.INVALID);\n }\n\n if (this._required) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.REQUIRED);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.REQUIRED);\n }\n }\n\n protected _applyDensity(): void {\n this._adapter.setRoomy(this._density === 'roomy');\n this._adapter.setDense(this._density === 'dense');\n }\n}\n", "import { FieldDensityType, FieldFloatLabelType, FieldShapeType, FIELD_CONSTANTS } from './field-constants';\nimport { BaseComponent, IBaseComponent } from '../core/base/base-component';\nimport { FieldFoundation } from './field-foundation';\nimport { coerceBoolean, ensureChild, FoundationProperty } from '@tylertech/forge-core';\n\nexport interface IFieldComponent extends IBaseComponent {\n density: FieldDensityType;\n floatLabelType: FieldFloatLabelType;\n shape: FieldShapeType;\n invalid: boolean;\n required: boolean;\n floatLabel(value: boolean): void;\n}\n\nexport abstract class FieldComponent<T extends FieldFoundation> extends BaseComponent implements IFieldComponent {\n public static get observedAttributes(): string[] {\n return [\n FIELD_CONSTANTS.attributes.DENSITY,\n FIELD_CONSTANTS.attributes.FLOAT_LABEL_TYPE,\n FIELD_CONSTANTS.attributes.SHAPE,\n FIELD_CONSTANTS.attributes.INVALID,\n FIELD_CONSTANTS.attributes.REQUIRED\n ];\n }\n\n protected _foundation: T;\n\n constructor() {\n super();\n }\n\n public connectedCallback(): void {\n if (this.querySelector(FIELD_CONSTANTS.selectors.INPUT)) {\n this._initialize();\n } else {\n ensureChild(this, FIELD_CONSTANTS.selectors.INPUT).then(() => this._initialize());\n }\n }\n\n private _initialize(): 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 FIELD_CONSTANTS.attributes.DENSITY:\n this.density = newValue as FieldDensityType;\n break;\n case FIELD_CONSTANTS.attributes.FLOAT_LABEL_TYPE:\n this.floatLabelType = newValue as FieldFloatLabelType;\n break;\n case FIELD_CONSTANTS.attributes.SHAPE:\n this.shape = newValue as FieldShapeType;\n break;\n case FIELD_CONSTANTS.attributes.INVALID:\n this.invalid = coerceBoolean(newValue);\n break;\n case FIELD_CONSTANTS.attributes.REQUIRED:\n this.required = coerceBoolean(newValue);\n break;\n }\n }\n\n /** Controls the density type. */\n @FoundationProperty()\n public declare density: FieldDensityType;\n\n /** Whether the label should always float, never float or float as the user types. */\n @FoundationProperty()\n public declare floatLabelType: FieldFloatLabelType;\n\n /** The shape type to use. */\n @FoundationProperty()\n public declare shape: FieldShapeType;\n\n /** Gets/sets the invalid state. */\n @FoundationProperty()\n public declare invalid: boolean;\n\n /** Gets/sets the required state which controls the visibility of the asterisk in the label. */\n @FoundationProperty()\n public declare required: boolean;\n\n /**\n * Controls whether the label should be floating or not.\n * @param {boolean} value\n */\n public floatLabel(value: boolean): void {\n this._foundation.floatLabel(value);\n }\n}\n\n"],
5
- "mappings": "yZAgEO,IAAMA,EAAN,cAA2BC,CAAsD,CAWtF,YAAYC,EAA4B,CACtC,MAAMA,CAAS,EAHjB,KAAU,sBAA2C,CAAC,CAItD,CAEO,WAAWC,EAA4B,CAC5C,KAAK,aAAeC,EAAiB,KAAK,WAAYD,CAAY,EAClE,KAAK,WAAaC,EAAiB,KAAK,WAAY,kBAAkB,EACtE,KAAK,aAAeA,EAAiB,KAAK,WAAY,oBAAoB,EAC1E,KAAK,cAAgBA,EAAiB,KAAK,WAAY,qBAAqB,EAC5E,KAAK,cAAgBA,EAAiB,KAAK,WAAY,sBAAsB,EAC7E,KAAK,cAAgB,KAAK,WAAW,cAAc,8CAA8C,EACjG,KAAK,YAAY,CACnB,CAEO,SAAgB,CACjB,KAAK,wBACP,KAAK,uBAAuB,WAAW,CAE3C,CAEO,UAAoB,CACzB,MAAO,CAAC,CAAC,KAAK,aAChB,CA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,EAAA,CADdC,EAAmB,GA9DAV,EA+DL,qBAIAS,EAAA,CADdC,EAAmB,GAlEAV,EAmEL,uBAIAS,EAAA,CADdC,EAAmB,GAtEAV,EAuEL",
6
- "names": ["FieldAdapter", "BaseAdapter", "component", "rootSelector", "getShadowElement", "children", "listener", "type", "context", "destroyListener", "listenOwnProperty", "cb", "FloatingLabel", "target", "getActiveElement", "name", "FIELD_CONSTANTS", "isRoomy", "toggleClass", "isDense", "className", "classes", "addClass", "removeClass", "createElementAttributeObserver", "fontSize", "fontFamily", "calculateFontWidth", "style", "FieldFoundation", "_adapter", "evt", "value", "name", "FIELD_CONSTANTS", "_a", "_b", "float", "FieldComponent", "BaseComponent", "FIELD_CONSTANTS", "ensureChild", "name", "oldValue", "newValue", "coerceBoolean", "value", "__decorateClass", "FoundationProperty"]
4
+ "sourcesContent": ["import { addClass, calculateFontWidth, getShadowElement, IFontInfo, listenOwnProperty, Platform, removeClass, getActiveElement, createElementAttributeObserver, toggleClass, toggleAttribute } from '@tylertech/forge-core';\nimport { BaseAdapter, IBaseAdapter } from '../core/base/base-adapter';\nimport { FloatingLabel, IFloatingLabel } from '../floating-label/floating-label';\nimport { IFieldComponent } from './field';\nimport { FIELD_CONSTANTS } from './field-constants';\n\nexport interface IFieldAdapter extends IBaseAdapter {\n // root\n setRootClass(classes: string | string[]): void;\n removeRootClass(classes: string | string[]): void;\n\n // input\n addInputListener(type: string, listener: (evt: Event) => void): void;\n removeInputListener(type: string, listener: (evt: Event) => void): void;\n setInputClass(className: string): void;\n removeInputClass(className: string): void;\n\n // label\n addLabelSlotListener(listener: (evt: Event) => void): void;\n removeLabelSlotListener(listener: (evt: Event) => void): void;\n setLabelClass(name: string): void;\n removeLabelClass(name: string): void;\n isLabelFloating(): boolean;\n\n // leading\n addLeadingSlotListener(listener: (evt: Event) => void): void;\n removeLeadingSlotListener(listener: (evt: Event) => void): void;\n\n // trailing\n addTrailingSlotListener(listener: (evt: Event) => void): void;\n removeTrailingSlotListener(listener: (evt: Event) => void): void;\n\n // add on end\n addAddonEndSlotListener(listener: (evt: Event) => void): void;\n removeAddonEndSlotListener(listener: (evt: Event) => void): void;\n\n // state selectors\n hasAddonEndNodes(): boolean;\n hasLabel(): boolean;\n hasLeadingNodes(): boolean;\n hasPlaceholder(): boolean;\n hasTrailingNodes(): boolean;\n inputHasFocus(target?: EventTarget | null): boolean;\n inputHasValue(): boolean;\n fieldHasValue(): boolean;\n isDisabled(): boolean;\n isReadonly(): boolean;\n getLabelFontMetrics(): IFontInfo;\n getLabelWidth(fontSize: number, fontFamily: string): number;\n\n // state actions\n initialize(rootSelector: string): void;\n initializeFloatingLabel(): IFloatingLabel;\n ensureLabelOrder(): void;\n ensureSlottedLabel(): void;\n destroy(): void;\n setValueChangedListener(context: any, listener: (value: any) => void): void;\n destroyValueChangeListener(): void;\n detectLabel(): void;\n setRoomy(isRoomy: boolean): void;\n setDense(isDense: boolean): void;\n setInputAttributeObserver(listener: (name: string, value: string | null) => void): void;\n}\n\nexport class FieldAdapter extends BaseAdapter<IFieldComponent> implements IFieldAdapter {\n protected _rootElement: HTMLElement;\n protected _labelSlot: HTMLSlotElement;\n protected _leadingSlot: HTMLSlotElement;\n protected _trailingSlot: HTMLSlotElement;\n protected _addonEndSlot: HTMLSlotElement;\n protected _labelElement: HTMLLabelElement;\n protected _inputElement: HTMLInputElement;\n protected _inputMutationObserver: MutationObserver;\n protected _valueChangeListeners: Array<() => void> = [];\n\n constructor(component: IFieldComponent) {\n super(component);\n }\n\n public initialize(rootSelector: string): void {\n this._rootElement = getShadowElement(this._component, rootSelector);\n this._labelSlot = getShadowElement(this._component, 'slot[name=label]') as HTMLSlotElement;\n this._leadingSlot = getShadowElement(this._component, 'slot[name=leading]') as HTMLSlotElement;\n this._trailingSlot = getShadowElement(this._component, 'slot[name=trailing]') as HTMLSlotElement;\n this._addonEndSlot = getShadowElement(this._component, 'slot[name=addon-end]') as HTMLSlotElement;\n this._inputElement = this._component.querySelector('input:not([type=checkbox]):not([type=radio])') as HTMLInputElement;\n this.detectLabel();\n }\n\n public destroy(): void {\n if (this._inputMutationObserver) {\n this._inputMutationObserver.disconnect();\n }\n }\n\n public hasLabel(): boolean {\n return !!this._labelElement;\n }\n\n public ensureSlottedLabel(): void {\n this._labelElement.slot = 'label';\n }\n\n public ensureLabelOrder(): void {\n if (this._labelElement) {\n const children = Array.from(this._component.children);\n if (children.length > 1 && children.indexOf(this._labelElement) < children.indexOf(this._inputElement)) {\n this._component.appendChild(this._labelElement);\n }\n }\n }\n\n public addLabelSlotListener(listener: (evt: Event) => void): void {\n this._labelSlot.addEventListener('slotchange', listener);\n }\n\n public removeLabelSlotListener(listener: (evt: Event) => void): void {\n if (this._labelSlot) {\n this._labelSlot.removeEventListener('slotchange', listener);\n }\n }\n\n public addLeadingSlotListener(listener: (evt: Event) => void): void {\n this._leadingSlot.addEventListener('slotchange', listener);\n }\n\n public removeLeadingSlotListener(listener: (evt: Event) => void): void {\n if (this._leadingSlot) {\n this._leadingSlot.removeEventListener('slotchange', listener);\n }\n }\n\n public addTrailingSlotListener(listener: (evt: Event) => void): void {\n this._trailingSlot.addEventListener('slotchange', listener);\n }\n\n public removeTrailingSlotListener(listener: (evt: Event) => void): void {\n if (this._trailingSlot) {\n this._trailingSlot.removeEventListener('slotchange', listener);\n }\n }\n\n public addAddonEndSlotListener(listener: (evt: Event) => void): void {\n this._addonEndSlot.addEventListener('slotchange', listener);\n }\n\n public removeAddonEndSlotListener(listener: (evt: Event) => void): void {\n if (this._addonEndSlot) {\n this._addonEndSlot.removeEventListener('slotchange', listener);\n }\n }\n\n public addInputListener(type: string, listener: (evt: Event) => void): void {\n this._inputElement.addEventListener(type, listener);\n }\n public removeInputListener(type: string, listener: (evt: Event) => void): void {\n if (this._inputElement) {\n this._inputElement.removeEventListener(type, listener);\n }\n }\n\n public setValueChangedListener(context: any, listener: (value: any) => void): void {\n this.destroyValueChangeListener();\n const destroyListener = listenOwnProperty(context, this._inputElement, 'value', listener);\n this._valueChangeListeners.push(destroyListener);\n }\n\n public destroyValueChangeListener(): void {\n this._valueChangeListeners.forEach(cb => cb());\n }\n\n public detectLabel(): void {\n this._labelElement = this._component.querySelector('label') as HTMLLabelElement;\n }\n\n public initializeFloatingLabel(): IFloatingLabel {\n return new FloatingLabel(this._labelElement);\n }\n\n public inputHasValue(): boolean {\n return this._inputElement.value ? this._inputElement.value.trim().length > 0 : false;\n }\n\n // An overrideable method for more generic field values where input.value is not the value.\n public fieldHasValue(): boolean {\n return this.inputHasValue();\n }\n\n public hasPlaceholder(): boolean {\n return this._inputElement.placeholder ? this._inputElement.placeholder.trim().length > 0 : false;\n }\n\n public inputHasFocus(target?: EventTarget | null): boolean {\n return this._inputElement === target || this._inputElement === getActiveElement(this._component.ownerDocument);\n }\n\n public setLabelClass(name: string): void {\n if (this._labelElement) {\n this._labelElement.classList.add(name);\n }\n }\n\n public removeLabelClass(name: string): void {\n if (this._labelElement) {\n this._labelElement.classList.remove(name);\n }\n }\n\n public isLabelFloating(): boolean {\n return this._component.hasAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING);\n }\n\n public setRoomy(isRoomy: boolean): void {\n toggleClass(this._rootElement, isRoomy, FIELD_CONSTANTS.classes.ROOMY);\n }\n\n public setDense(isDense: boolean): void {\n toggleClass(this._rootElement, isDense, FIELD_CONSTANTS.classes.DENSE);\n }\n\n public hasLeadingNodes(): boolean {\n if (!this._leadingSlot) {\n return false;\n }\n return this._leadingSlot.assignedNodes().length > 0;\n }\n\n public hasTrailingNodes(): boolean {\n if (!this._trailingSlot) {\n return false;\n }\n return this._trailingSlot.assignedNodes().length > 0;\n }\n\n public hasAddonEndNodes(): boolean {\n if (!this._addonEndSlot) {\n return false;\n }\n return this._addonEndSlot.assignedNodes().length > 0;\n }\n\n public setInputClass(className: string): void {\n this._inputElement.classList.add(className);\n }\n\n public removeInputClass(className: string): void {\n this._inputElement.classList.remove(className);\n }\n\n public setRootClass(classes: string | string[]): void {\n addClass(classes, this._rootElement);\n }\n\n public removeRootClass(classes: string | string[]): void {\n removeClass(classes, this._rootElement);\n }\n\n public setInputAttributeObserver(listener: (name: string, value: string | null) => void): void {\n this._inputMutationObserver = createElementAttributeObserver(this._inputElement, listener, FIELD_CONSTANTS.observedInputAttributes);\n }\n\n public isDisabled(): boolean {\n return this._inputElement.hasAttribute('disabled');\n }\n\n public isReadonly(): boolean {\n return this._inputElement.hasAttribute('readonly');\n }\n\n public getLabelWidth(fontSize: number, fontFamily: string): number {\n return calculateFontWidth(this._labelElement.innerText, { fontSize, fontFamily });\n }\n\n public getLabelFontMetrics(): IFontInfo {\n const style = getComputedStyle(this._labelElement);\n return {\n fontSize: parseInt(style.fontSize || '16', 10),\n fontFamily: style.fontFamily || 'Roboto'\n };\n }\n}\n", "import { ICustomElementFoundation } from '@tylertech/forge-core';\nimport { IFloatingLabel } from '../floating-label/floating-label';\nimport { IFieldAdapter } from './field-adapter';\nimport { FIELD_CONSTANTS, FieldFloatLabelType, FieldShapeType, FieldDensityType } from './field-constants';\n\nexport interface IFieldFoundation extends ICustomElementFoundation {\n density: FieldDensityType;\n floatLabelType: FieldFloatLabelType;\n shape: FieldShapeType;\n invalid: boolean;\n required: boolean;\n floatLabel(value: boolean, alwaysFloat?: boolean): void;\n}\n\nexport class FieldFoundation {\n protected _density: FieldDensityType = 'default';\n protected _floatingLabel: IFloatingLabel | undefined;\n protected _shape: FieldShapeType = 'default';\n protected _invalid = false;\n protected _required = false;\n protected _floatLabelType: FieldFloatLabelType = 'auto';\n protected _isInitialized = false;\n protected _labelSlotListener: (evt: Event) => void;\n protected _leadingSlotListener: (evt: Event) => void;\n protected _trailingSlotListener: (evt: Event) => void;\n protected _addonEndSlotListener: (evt: Event) => void;\n protected _focusListener: (evt: Event) => void;\n protected _blurListener: (evt: Event) => void;\n protected _valueChangedListener: (value: any) => void;\n protected _inputAttributeChangedListener: (name: string, value: string) => void;\n\n constructor(protected _adapter: IFieldAdapter) {\n this._labelSlotListener = evt => this._onLabelSlotChanged(evt);\n this._leadingSlotListener = evt => this._onLeadingSlotChanged(evt);\n this._trailingSlotListener = evt => this._onTrailingSlotChanged(evt);\n this._addonEndSlotListener = evt => this._onAddonEndSlotChanged(evt);\n this._focusListener = (evt: FocusEvent) => this._onFocus(evt);\n this._blurListener = (evt: FocusEvent) => this._onBlur(evt);\n this._valueChangedListener = (value: any) => this._onValueChanged(value);\n this._inputAttributeChangedListener = (name, value) => this._onInputAttributeChanged(name, value);\n }\n\n //\n // Public\n //\n\n public initialize(): void {\n this._adapter.initialize('');\n\n if (this._adapter.hasLabel()) {\n this._adapter.ensureSlottedLabel();\n }\n\n this._initializeLabel();\n\n if (this._adapter.hasPlaceholder()) {\n this._floatLabelType = 'always';\n }\n\n this._detectSlottedContent();\n this._adapter.addLabelSlotListener(this._labelSlotListener);\n this._adapter.addLeadingSlotListener(this._leadingSlotListener);\n this._adapter.addTrailingSlotListener(this._trailingSlotListener);\n this._adapter.addAddonEndSlotListener(this._addonEndSlotListener);\n this._adapter.setValueChangedListener(this, this._valueChangedListener);\n this._adapter.addInputListener('focus', this._focusListener);\n this._adapter.addInputListener('blur', this._blurListener);\n this._adapter.setInputAttributeObserver(this._inputAttributeChangedListener);\n this._applyDensity();\n this._setShapeType();\n this._setValidity();\n\n if (this._adapter.isDisabled()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.DISABLED);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.DISABLED);\n }\n\n if (this._adapter.isReadonly()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.READONLY);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.READONLY);\n }\n\n if (this._floatLabelType === 'always') {\n this.floatLabel(true);\n }\n\n this._isInitialized = true;\n }\n\n public disconnect(): void {\n this._isInitialized = false;\n this._adapter.destroy();\n\n this._adapter.removeHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING);\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.LABEL);\n\n if (this._floatingLabel) {\n this._floatingLabel.destroy();\n this._floatingLabel = undefined;\n }\n\n this._adapter.removeLabelSlotListener(this._labelSlotListener);\n this._adapter.removeLeadingSlotListener(this._leadingSlotListener);\n this._adapter.removeTrailingSlotListener(this._trailingSlotListener);\n this._adapter.removeAddonEndSlotListener(this._addonEndSlotListener);\n this._adapter.removeInputListener('focus', this._focusListener);\n this._adapter.removeInputListener('blur', this._blurListener);\n this._adapter.destroyValueChangeListener();\n }\n\n public get density(): FieldDensityType {\n return this._density;\n }\n public set density(value: FieldDensityType) {\n if (this._density !== value) {\n const prevDensity = this._density;\n this._density = value;\n\n if (this._isInitialized) {\n this._applyDensity();\n\n if (this._density === 'dense') {\n this._destroyFloatingLabel({ cancelFloat: true });\n } else if (prevDensity === 'dense') {\n this._initializeLabel();\n }\n }\n\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.DENSITY, this._density.toString());\n }\n }\n\n public get floatLabelType(): FieldFloatLabelType {\n return this._floatLabelType;\n }\n public set floatLabelType(value: FieldFloatLabelType) {\n if (this._floatLabelType !== value) {\n this._floatLabelType = value;\n\n if (this._isInitialized) {\n this.floatLabel(this._floatLabelType === 'always');\n }\n\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.FLOAT_LABEL_TYPE, this._floatLabelType);\n }\n }\n\n public get shape(): FieldShapeType {\n return this._shape;\n }\n public set shape(value: FieldShapeType) {\n if (this._shape !== value) {\n this._shape = value;\n\n if (this._isInitialized) {\n this._setShapeType();\n }\n\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.SHAPE, this._shape);\n }\n }\n\n public get invalid(): boolean {\n return this._invalid;\n }\n public set invalid(value: boolean) {\n if (this._invalid !== value) {\n this._invalid = value;\n\n if (this._isInitialized) {\n this._setValidity();\n }\n }\n }\n\n public get required(): boolean {\n return this._required;\n }\n public set required(value: boolean) {\n if (this._required !== value) {\n this._required = value;\n\n if (this._isInitialized) {\n this._setValidity();\n }\n\n if (this._required) {\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.REQUIRED);\n } else {\n this._adapter.removeHostAttribute(FIELD_CONSTANTS.attributes.REQUIRED);\n }\n }\n }\n\n public floatLabel(value: boolean): void {\n if (this._floatingLabel?.isFloating === value || this._adapter.isLabelFloating() === value) {\n if (value) {\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING, '');\n }\n return;\n }\n\n if (!value && this._floatLabelType === 'always') {\n this._floatingLabel?.float(true, true);\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING, '');\n return;\n }\n\n if (this._floatingLabel) {\n this._floatingLabel.float(value, this._floatLabelType === 'always');\n\n if (value) {\n this._adapter.setInputClass(FIELD_CONSTANTS.classes.INPUT_FOCUSED);\n this._adapter.setHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING, '');\n } else {\n this._adapter.removeInputClass(FIELD_CONSTANTS.classes.INPUT_FOCUSED);\n this._adapter.removeHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING);\n }\n }\n }\n\n //\n // Protected\n //\n\n protected _onLabelSlotChanged(evt: Event): void {\n this._initializeLabel();\n }\n\n protected _onLeadingSlotChanged(evt: Event): void {\n this._detectLeadingContent();\n }\n\n protected _onTrailingSlotChanged(evt: Event): void {\n this._detectTrailingContent();\n }\n\n protected _onAddonEndSlotChanged(evt: Event): void {\n this._detectAddonEndContent();\n }\n\n protected _initializeLabel(): void {\n this._floatingLabel?.destroy();\n this._adapter.detectLabel();\n \n if (this._adapter.hasLabel() && this._density !== 'dense') {\n this._floatingLabel = this._adapter.initializeFloatingLabel();\n this._adapter.ensureLabelOrder();\n this.floatLabel(this._floatLabelType === 'always' || this._adapter.fieldHasValue() || this._adapter.hasPlaceholder());\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.LABEL);\n } else {\n this._destroyFloatingLabel();\n }\n }\n\n private _destroyFloatingLabel({ cancelFloat = false } = {}): void {\n this._adapter.removeHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING);\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.LABEL);\n this._floatingLabel?.destroy({ cancelFloat });\n this._floatingLabel = undefined;\n }\n\n protected _detectLeadingContent(): void {\n if (this._adapter.hasLeadingNodes()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.LEADING);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.LEADING);\n }\n }\n\n protected _detectTrailingContent(): void {\n if (this._adapter.hasTrailingNodes()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.TRAILING);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.TRAILING);\n }\n }\n\n protected _detectAddonEndContent(): void {\n if (this._adapter.hasAddonEndNodes()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.ADDON_END);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.ADDON_END);\n }\n }\n\n protected _detectSlottedContent(): void {\n this._detectLeadingContent();\n this._detectTrailingContent();\n this._detectAddonEndContent();\n }\n\n protected _onFocus(evt: FocusEvent): void {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.FOCUSED);\n this._adapter.setLabelClass(FIELD_CONSTANTS.classes.LABEL_FOCUSED);\n this.floatLabel(true);\n }\n\n protected _onBlur(evt: FocusEvent): void {\n if (this._adapter.inputHasFocus(evt.relatedTarget)) {\n return;\n }\n\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.FOCUSED);\n this._adapter.removeLabelClass(FIELD_CONSTANTS.classes.LABEL_FOCUSED);\n\n if (!this._adapter.fieldHasValue() && !this._adapter.hasPlaceholder()) {\n this.floatLabel(false);\n this._adapter.removeHostAttribute(FIELD_CONSTANTS.attributes.HOST_LABEL_FLOATING);\n }\n }\n\n protected _onValueChanged(value: any): void {\n if (this._adapter.fieldHasValue()) {\n this.floatLabel(true);\n } else if (!this._adapter.inputHasFocus() && !this._adapter.hasPlaceholder()) {\n this.floatLabel(false);\n }\n }\n\n protected _onInputAttributeChanged(name: string, value: string | null): void {\n if (this._adapter.isDisabled()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.DISABLED);\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.FOCUSED);\n this._adapter.removeInputClass(FIELD_CONSTANTS.classes.INPUT_FOCUSED);\n this._adapter.removeLabelClass(FIELD_CONSTANTS.classes.LABEL_FOCUSED);\n\n if (!this._adapter.fieldHasValue() && !this._adapter.hasPlaceholder() && this._floatingLabel) {\n this.floatLabel(false);\n }\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.DISABLED);\n }\n\n if (this._adapter.isReadonly()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.READONLY);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.READONLY);\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.FOCUSED);\n this._adapter.removeInputClass(FIELD_CONSTANTS.classes.INPUT_FOCUSED);\n }\n\n switch (name) {\n case 'readonly':\n case 'disabled':\n // If we are changing the readonly or disabled attribute, we want to make sure that we apply\n // the focus state properly if the input element also now has focus\n if (this._adapter.inputHasFocus()) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.FOCUSED);\n this._adapter.setInputClass(FIELD_CONSTANTS.classes.INPUT_FOCUSED);\n this._adapter.setLabelClass(FIELD_CONSTANTS.classes.LABEL_FOCUSED);\n }\n break;\n case 'value':\n if (this._floatingLabel) {\n this.floatLabel(this._adapter.fieldHasValue());\n }\n break;\n case 'placeholder':\n if (this._floatingLabel) {\n const float = (!!value && !!value.trim()) || this._adapter.fieldHasValue();\n if (float !== this._floatingLabel.isFloating) {\n this.floatLabel(float);\n }\n }\n break;\n }\n }\n\n protected _setShapeType(): void {\n if (this._shape === 'rounded') {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.SHAPE_ROUNDED);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.SHAPE_ROUNDED);\n }\n }\n\n protected _setValidity(): void {\n if (this._invalid) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.INVALID);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.INVALID);\n }\n\n if (this._required) {\n this._adapter.setRootClass(FIELD_CONSTANTS.classes.REQUIRED);\n } else {\n this._adapter.removeRootClass(FIELD_CONSTANTS.classes.REQUIRED);\n }\n }\n\n protected _applyDensity(): void {\n this._adapter.setRoomy(this._density === 'roomy');\n this._adapter.setDense(this._density === 'dense');\n }\n}\n", "import { FieldDensityType, FieldFloatLabelType, FieldShapeType, FIELD_CONSTANTS } from './field-constants';\nimport { BaseComponent, IBaseComponent } from '../core/base/base-component';\nimport { FieldFoundation } from './field-foundation';\nimport { coerceBoolean, ensureChild, FoundationProperty } from '@tylertech/forge-core';\n\nexport interface IFieldComponent extends IBaseComponent {\n density: FieldDensityType;\n floatLabelType: FieldFloatLabelType;\n shape: FieldShapeType;\n invalid: boolean;\n required: boolean;\n floatLabel(value: boolean): void;\n}\n\nexport abstract class FieldComponent<T extends FieldFoundation> extends BaseComponent implements IFieldComponent {\n public static get observedAttributes(): string[] {\n return [\n FIELD_CONSTANTS.attributes.DENSITY,\n FIELD_CONSTANTS.attributes.FLOAT_LABEL_TYPE,\n FIELD_CONSTANTS.attributes.SHAPE,\n FIELD_CONSTANTS.attributes.INVALID,\n FIELD_CONSTANTS.attributes.REQUIRED\n ];\n }\n\n protected _foundation: T;\n\n constructor() {\n super();\n }\n\n public connectedCallback(): void {\n if (this.querySelector(FIELD_CONSTANTS.selectors.INPUT)) {\n this._initialize();\n } else {\n ensureChild(this, FIELD_CONSTANTS.selectors.INPUT).then(() => this._initialize());\n }\n }\n\n private _initialize(): 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 FIELD_CONSTANTS.attributes.DENSITY:\n this.density = newValue as FieldDensityType;\n break;\n case FIELD_CONSTANTS.attributes.FLOAT_LABEL_TYPE:\n this.floatLabelType = newValue as FieldFloatLabelType;\n break;\n case FIELD_CONSTANTS.attributes.SHAPE:\n this.shape = newValue as FieldShapeType;\n break;\n case FIELD_CONSTANTS.attributes.INVALID:\n this.invalid = coerceBoolean(newValue);\n break;\n case FIELD_CONSTANTS.attributes.REQUIRED:\n this.required = coerceBoolean(newValue);\n break;\n }\n }\n\n /** Controls the density type. */\n @FoundationProperty()\n public declare density: FieldDensityType;\n\n /** Whether the label should always float, never float or float as the user types. */\n @FoundationProperty()\n public declare floatLabelType: FieldFloatLabelType;\n\n /** The shape type to use. */\n @FoundationProperty()\n public declare shape: FieldShapeType;\n\n /** Gets/sets the invalid state. */\n @FoundationProperty()\n public declare invalid: boolean;\n\n /** Gets/sets the required state which controls the visibility of the asterisk in the label. */\n @FoundationProperty()\n public declare required: boolean;\n\n /**\n * Controls whether the label should be floating or not.\n * @param {boolean} value\n */\n public floatLabel(value: boolean): void {\n this._foundation.floatLabel(value);\n }\n}\n\n"],
5
+ "mappings": "yZAgEO,IAAMA,EAAN,cAA2BC,CAAsD,CAWtF,YAAYC,EAA4B,CACtC,MAAMA,CAAS,EAHjB,KAAU,sBAA2C,CAAC,CAItD,CAEO,WAAWC,EAA4B,CAC5C,KAAK,aAAeC,EAAiB,KAAK,WAAYD,CAAY,EAClE,KAAK,WAAaC,EAAiB,KAAK,WAAY,kBAAkB,EACtE,KAAK,aAAeA,EAAiB,KAAK,WAAY,oBAAoB,EAC1E,KAAK,cAAgBA,EAAiB,KAAK,WAAY,qBAAqB,EAC5E,KAAK,cAAgBA,EAAiB,KAAK,WAAY,sBAAsB,EAC7E,KAAK,cAAgB,KAAK,WAAW,cAAc,8CAA8C,EACjG,KAAK,YAAY,CACnB,CAEO,SAAgB,CACjB,KAAK,wBACP,KAAK,uBAAuB,WAAW,CAE3C,CAEO,UAAoB,CACzB,MAAO,CAAC,CAAC,KAAK,aAChB,CAEO,o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B,KAAK,MAAQI,EACb,WACGJ,EAAgB,WAAW,QAC9B,KAAK,QAAUK,EAAcD,CAAQ,EACrC,WACGJ,EAAgB,WAAW,SAC9B,KAAK,SAAWK,EAAcD,CAAQ,EACtC,MAEN,CA0BO,WAAWE,EAAsB,CACtC,KAAK,YAAY,WAAWA,CAAK,CACnC,CACF,EAzBiBC,EAAA,CADdC,EAAmB,GAtDAV,EAuDL,uBAIAS,EAAA,CADdC,EAAmB,GA1DAV,EA2DL,8BAIAS,EAAA,CADdC,EAAmB,GA9DAV,EA+DL,qBAIAS,EAAA,CADdC,EAAmB,GAlEAV,EAmEL,uBAIAS,EAAA,CADdC,EAAmB,GAtEAV,EAuEL",
6
+ "names": ["FieldAdapter", "BaseAdapter", "component", "rootSelector", "getShadowElement", "children", "listener", "type", "context", "destroyListener", "listenOwnProperty", "cb", "FloatingLabel", "target", "getActiveElement", "name", "FIELD_CONSTANTS", "isRoomy", "toggleClass", "isDense", "className", "classes", "addClass", "removeClass", "createElementAttributeObserver", "fontSize", "fontFamily", "calculateFontWidth", "style", "FieldFoundation", "_adapter", "evt", "value", "name", "FIELD_CONSTANTS", "prevDensity", "_a", "_b", "cancelFloat", "float", "FieldComponent", "BaseComponent", "FIELD_CONSTANTS", "ensureChild", "name", "oldValue", "newValue", "coerceBoolean", "value", "__decorateClass", "FoundationProperty"]
7
7
  }
@@ -3,5 +3,5 @@
3
3
  * Copyright 2023 Tyler Technologies, Inc.
4
4
  * License: Apache-2.0
5
5
  */
6
- import{b as N}from"./chunk.XQ5CDWDY.js";import{a as s,f as D,g as L,h as y}from"./chunk.FBHCNPUL.js";import{b as A}from"./chunk.3YT72ZWJ.js";import{d as C}from"./chunk.KQK2XX5H.js";import{c as b}from"./chunk.SXTM6OK4.js";import{e as E}from"./chunk.DYF2MREZ.js";import{d as f}from"./chunk.JD4APKZS.js";import{b as x}from"./chunk.ZCQO3N25.js";import{e as v}from"./chunk.3C44DXZ2.js";import{b as S}from"./chunk.CG5CVENX.js";import{a as c}from"./chunk.KTGSZEAG.js";import{a as _,b as h}from"./chunk.QOA2O575.js";import{a as u,e as T}from"./chunk.HOXFK44F.js";import{k as g}from"./chunk.J2M2MXP2.js";import{a as m,f as a}from"./chunk.MCIQXNKY.js";var O=`${h}select-dropdown`,w={TARGET:"target",SELECTED_TEXT_TARGET:"selected-text-target",SYNC_SELECTED_TEXT:"sync-selected-text"},B=m({},w),M={SCROLLED_BOTTOM:`${O}-scrolled-bottom`},o={elementName:O,attributes:B,events:M};var l=class extends D{constructor(t){super(t);this._syncSelectedText=!1;this._originalTargetText="";this._targetDisconnectedListener=()=>this._onTargetDisconnected()}initialize(){this._tryAttach(),super.initialize()}disconnect(){super.disconnect(),this._adapter.isAttached()&&this._detach()}_onDropdownScrollEnd(){this._adapter.emitHostEvent(o.events.SCROLLED_BOTTOM)}_applyValue(t){super._applyValue(t),this._applySelection()}_applySelection(){if(super._applySelection(),this._syncSelectedText||typeof this._selectedTextBuilder=="function"){let t=this._getSelectedText();t||(t=this._originalTargetText),this._adapter.setTargetText(t||"",this._selectedTextTarget)}}_tryAttach(){this._adapter.attach(this._target),this._adapter.isAttached()&&(this._targetDisconnectedDestructor=this._adapter.setTargetDisconnectedListener(this._targetDisconnectedListener),this._originalTargetText=this._adapter.getTargetText(this._selectedTextTarget),this.initializeTarget())}_detach(){this._adapter.detach(),this._targetDisconnectedDestructor&&(this._targetDisconnectedDestructor(),this._targetDisconnectedDestructor=void 0)}_onTargetDisconnected(){this._adapter.detach()}get target(){return this._target}set target(t){this._target!==t&&(this._target=t,this._adapter.isAttached()&&this._detach(),this._tryAttach())}get selectedTextTarget(){return this._selectedTextTarget}set selectedTextTarget(t){this._selectedTextTarget!==t&&(this._selectedTextTarget=t)}get syncSelectedText(){return this._syncSelectedText}set syncSelectedText(t){this._syncSelectedText!==t&&(this._syncSelectedText=t)}};var d=class extends y{constructor(e){super(e)}initializeAccessibility(){this._targetElement.setAttribute("role","listbox"),this._targetElement.setAttribute("aria-live","polite"),this._targetElement.setAttribute("aria-haspopup","true"),this._targetElement.setAttribute("aria-expanded","false")}addClickListener(e){this._targetElement.addEventListener("click",e)}removeClickListener(e){this._targetElement&&this._targetElement.removeEventListener("click",e)}addTargetListener(e,t){let i,r;e==="keydown"&&(i=!1,r=!0),this._targetElement.addEventListener(e,t,{passive:i,capture:r})}removeTargetListener(e,t){this._targetElement&&this._targetElement.removeEventListener(e,t)}updateActiveDescendant(e){e?this._targetElement.setAttribute("aria-activedescendant",e):this._targetElement.removeAttribute("aria-activedescendant")}open(e){super.open(e),this._targetElement.setAttribute("aria-controls",`list-dropdown-popup-${e.id}`),this._targetElement.setAttribute("aria-expanded","true")}close(){this._targetElement.setAttribute("aria-expanded","false"),this._targetElement.removeAttribute("aria-activedescendant"),this._targetElement.removeAttribute("aria-controls"),super.close()}attach(e){let r=(this._component.getRootNode()||HTMLDocument||this._component.ownerDocument||document).querySelector(e);r&&(this._targetElement=r)}detach(){this._targetElement=void 0}setMultiple(e){!this._targetElement||(e?this._targetElement.setAttribute("aria-multiselectable","true"):this._targetElement.removeAttribute("aria-multiselectable"))}setTargetDisconnectedListener(e){if(!this._targetElement||!this._targetElement.parentElement)return()=>{};let t=new MutationObserver(i=>{i.some(I=>Array.from(I.removedNodes).some(R=>R===this._targetElement))&&(t.disconnect(),e())});return t.observe(this._targetElement.parentElement,{childList:!0}),()=>t.disconnect()}isAttached(){return!!this._targetElement}setTargetText(e,t){let i=this._targetElement;if(t){let r=this._getElementBySelector(t);r&&(i=r)}i&&(i.textContent=e)}getTargetText(e){let t=e?this._getElementBySelector(e):this._targetElement;return t?t.innerText:""}_getElementBySelector(e){return this._targetElement.querySelector(e)||this._getRootNode().querySelector(e)}_getRootNode(){return this._component.getRootNode()||this._component.ownerDocument||document}};var P="<template></template>",H=":host{display:none}",n=class extends L{constructor(){super();T(this,P,H),this._foundation=new l(new d(this))}static get observedAttributes(){return[o.attributes.TARGET,o.attributes.SELECTED_TEXT_TARGET,o.attributes.SYNC_SELECTED_TEXT,s.attributes.VALUE,s.attributes.MULTIPLE,s.attributes.OBSERVE_SCROLL,s.attributes.OBSERVE_SCROLL_THRESHOLD,s.attributes.POPUP_CLASSES,s.attributes.OPTION_LIMIT,s.attributes.SYNC_POPUP_WIDTH]}attributeChangedCallback(t,i,r){switch(t){case o.attributes.TARGET:this.target=r;return;case o.attributes.SELECTED_TEXT_TARGET:this.selectedTextTarget=r;return;case o.attributes.SYNC_SELECTED_TEXT:this.syncSelectedText=g(r);return}super.attributeChangedCallback(t,i,r)}};a([c()],n.prototype,"target",2),a([c()],n.prototype,"selectedTextTarget",2),a([c()],n.prototype,"syncSelectedText",2),n=a([_({name:o.elementName,dependencies:[C,A,v,b,E,f,N,x,S]})],n);function pt(){u(n)}export{o as a,l as b,d as c,n as d,pt as e};
7
- //# sourceMappingURL=chunk.Z7KJ4SA5.js.map
6
+ import{a as s,f as D,g as L,h as y}from"./chunk.GEWDZDXN.js";import{b as A}from"./chunk.3YT72ZWJ.js";import{d as C}from"./chunk.KQK2XX5H.js";import{b as N}from"./chunk.XQ5CDWDY.js";import{c as b}from"./chunk.SXTM6OK4.js";import{e as E}from"./chunk.DYF2MREZ.js";import{d as f}from"./chunk.JD4APKZS.js";import{b as x}from"./chunk.ZCQO3N25.js";import{e as v}from"./chunk.3C44DXZ2.js";import{b as S}from"./chunk.RLWX5BFQ.js";import{a as c}from"./chunk.KTGSZEAG.js";import{a as _,b as h}from"./chunk.QOA2O575.js";import{a as u,e as T}from"./chunk.HOXFK44F.js";import{k as g}from"./chunk.J2M2MXP2.js";import{a as m,f as a}from"./chunk.MCIQXNKY.js";var O=`${h}select-dropdown`,w={TARGET:"target",SELECTED_TEXT_TARGET:"selected-text-target",SYNC_SELECTED_TEXT:"sync-selected-text"},B=m({},w),M={SCROLLED_BOTTOM:`${O}-scrolled-bottom`},o={elementName:O,attributes:B,events:M};var l=class extends D{constructor(t){super(t);this._syncSelectedText=!1;this._originalTargetText="";this._targetDisconnectedListener=()=>this._onTargetDisconnected()}initialize(){this._tryAttach(),super.initialize()}disconnect(){super.disconnect(),this._adapter.isAttached()&&this._detach()}_onDropdownScrollEnd(){this._adapter.emitHostEvent(o.events.SCROLLED_BOTTOM)}_applyValue(t){super._applyValue(t),this._applySelection()}_applySelection(){if(super._applySelection(),this._syncSelectedText||typeof this._selectedTextBuilder=="function"){let t=this._getSelectedText();t||(t=this._originalTargetText),this._adapter.setTargetText(t||"",this._selectedTextTarget)}}_tryAttach(){this._adapter.attach(this._target),this._adapter.isAttached()&&(this._targetDisconnectedDestructor=this._adapter.setTargetDisconnectedListener(this._targetDisconnectedListener),this._originalTargetText=this._adapter.getTargetText(this._selectedTextTarget),this.initializeTarget())}_detach(){this._adapter.detach(),this._targetDisconnectedDestructor&&(this._targetDisconnectedDestructor(),this._targetDisconnectedDestructor=void 0)}_onTargetDisconnected(){this._adapter.detach()}get target(){return this._target}set target(t){this._target!==t&&(this._target=t,this._adapter.isAttached()&&this._detach(),this._tryAttach())}get selectedTextTarget(){return this._selectedTextTarget}set selectedTextTarget(t){this._selectedTextTarget!==t&&(this._selectedTextTarget=t)}get syncSelectedText(){return this._syncSelectedText}set syncSelectedText(t){this._syncSelectedText!==t&&(this._syncSelectedText=t)}};var d=class extends y{constructor(e){super(e)}initializeAccessibility(){this._targetElement.setAttribute("role","listbox"),this._targetElement.setAttribute("aria-live","polite"),this._targetElement.setAttribute("aria-haspopup","true"),this._targetElement.setAttribute("aria-expanded","false")}addClickListener(e){this._targetElement.addEventListener("click",e)}removeClickListener(e){this._targetElement&&this._targetElement.removeEventListener("click",e)}addTargetListener(e,t){let i,r;e==="keydown"&&(i=!1,r=!0),this._targetElement.addEventListener(e,t,{passive:i,capture:r})}removeTargetListener(e,t){this._targetElement&&this._targetElement.removeEventListener(e,t)}updateActiveDescendant(e){e?this._targetElement.setAttribute("aria-activedescendant",e):this._targetElement.removeAttribute("aria-activedescendant")}open(e){super.open(e),this._targetElement.setAttribute("aria-controls",`list-dropdown-popup-${e.id}`),this._targetElement.setAttribute("aria-expanded","true")}close(){this._targetElement.setAttribute("aria-expanded","false"),this._targetElement.removeAttribute("aria-activedescendant"),this._targetElement.removeAttribute("aria-controls"),super.close()}attach(e){let r=(this._component.getRootNode()||HTMLDocument||this._component.ownerDocument||document).querySelector(e);r&&(this._targetElement=r)}detach(){this._targetElement=void 0}setMultiple(e){!this._targetElement||(e?this._targetElement.setAttribute("aria-multiselectable","true"):this._targetElement.removeAttribute("aria-multiselectable"))}setTargetDisconnectedListener(e){if(!this._targetElement||!this._targetElement.parentElement)return()=>{};let t=new MutationObserver(i=>{i.some(I=>Array.from(I.removedNodes).some(R=>R===this._targetElement))&&(t.disconnect(),e())});return t.observe(this._targetElement.parentElement,{childList:!0}),()=>t.disconnect()}isAttached(){return!!this._targetElement}setTargetText(e,t){let i=this._targetElement;if(t){let r=this._getElementBySelector(t);r&&(i=r)}i&&(i.textContent=e)}getTargetText(e){let t=e?this._getElementBySelector(e):this._targetElement;return t?t.innerText:""}_getElementBySelector(e){return this._targetElement.querySelector(e)||this._getRootNode().querySelector(e)}_getRootNode(){return this._component.getRootNode()||this._component.ownerDocument||document}};var P="<template></template>",H=":host{display:none}",n=class extends L{constructor(){super();T(this,P,H),this._foundation=new l(new d(this))}static get observedAttributes(){return[o.attributes.TARGET,o.attributes.SELECTED_TEXT_TARGET,o.attributes.SYNC_SELECTED_TEXT,s.attributes.VALUE,s.attributes.MULTIPLE,s.attributes.OBSERVE_SCROLL,s.attributes.OBSERVE_SCROLL_THRESHOLD,s.attributes.POPUP_CLASSES,s.attributes.OPTION_LIMIT,s.attributes.SYNC_POPUP_WIDTH]}attributeChangedCallback(t,i,r){switch(t){case o.attributes.TARGET:this.target=r;return;case o.attributes.SELECTED_TEXT_TARGET:this.selectedTextTarget=r;return;case o.attributes.SYNC_SELECTED_TEXT:this.syncSelectedText=g(r);return}super.attributeChangedCallback(t,i,r)}};a([c()],n.prototype,"target",2),a([c()],n.prototype,"selectedTextTarget",2),a([c()],n.prototype,"syncSelectedText",2),n=a([_({name:o.elementName,dependencies:[C,A,v,b,E,f,N,x,S]})],n);function pt(){u(n)}export{o as a,l as b,d as c,n as d,pt as e};
7
+ //# sourceMappingURL=chunk.P67RC5S3.js.map
@@ -0,0 +1,7 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2023 Tyler Technologies, Inc.
4
+ * License: Apache-2.0
5
+ */
6
+ import{d as w}from"./chunk.BJRQ67AD.js";import{b as F}from"./chunk.RLWX5BFQ.js";import{n as I,r as B,s as N,u as z}from"./chunk.MZLPUI6R.js";import{d as G}from"./chunk.73GVVX4K.js";import{d as O,l as k}from"./chunk.IWICN773.js";import{a as y}from"./chunk.5KC43VFL.js";import{a as p}from"./chunk.KTGSZEAG.js";import{a as S,b as x}from"./chunk.QOA2O575.js";import{a as A,e as L,g as r,j as d,l as T}from"./chunk.HOXFK44F.js";import{d as v,f as h,g as P,t as E}from"./chunk.4LA6HEA7.js";import{b as _,i as m,k as l,l as c}from"./chunk.J2M2MXP2.js";import{f as s}from"./chunk.MCIQXNKY.js";var R=`${x}paginator`,g={LABEL:"forge-paginator__label",PAGE_SIZE_OPTIONS:"forge-paginator__page-size-options",RANGE_LABEL:"forge-paginator__range-label",RANGE_LABEL_ALTERNATIVE:"forge-paginator__range-label--alternative",FIRST_PAGE_BUTTON:"forge-paginator__first-page",PREVIOUS_PAGE_BUTTON:"forge-paginator__previous-page",NEXT_PAGE_BUTTON:"forge-paginator__next-page",LAST_PAGE_BUTTON:"forge-paginator__last-page",ROOT:"forge-paginator",ALTERNATIVE:"forge-paginator--alternative",ALIGNMENT_START:"forge-paginator--alignment-start",ALIGNMENT_SPACE_BETWEEN:"forge-paginator--alignment-center",ALIGNMENT_END:"forge-paginator--alignment-end"},M={LABEL:`.${g.LABEL}`,PAGE_SIZE_SELECT:`.${g.PAGE_SIZE_OPTIONS}`,RANGE_LABEL:`.${g.RANGE_LABEL}`,FIRST_PAGE_BUTTON:`.${g.FIRST_PAGE_BUTTON} > button`,FIRST_PAGE_ICON_BUTTON:`.${g.FIRST_PAGE_BUTTON}`,PREVIOUS_PAGE_BUTTON:`.${g.PREVIOUS_PAGE_BUTTON} > button`,NEXT_PAGE_BUTTON:`.${g.NEXT_PAGE_BUTTON} > button`,LAST_PAGE_BUTTON:`.${g.LAST_PAGE_BUTTON} > button`,LAST_PAGE_ICON_BUTTON:`.${g.LAST_PAGE_BUTTON}`,ROOT:`.${g.ROOT}`,RANGE_LABEL_ALTERNATIVE:`.${g.RANGE_LABEL_ALTERNATIVE}`},U={PAGE_INDEX:"page-index",PAGE_SIZE:"page-size",OFFSET:"offset",PAGE_SIZE_OPTIONS:"page-size-options",TOTAL:"total",LABEL:"label",FIRST_LAST:"first-last",FIRST:"first",DISABLED:"disabled",ALTERNATIVE:"alternative",ALIGNMENT:"alignment"},D={CHANGE:`${R}-change`},H={DEFAULT_PAGE_INDEX:0,DEFAULT_TOTAL:0,DEFAULT_PAGE_SIZE:25,DEFAULT_PAGE_SIZE_OPTIONS:[5,15,25,50,100]},$={DEFAULT_LABEL:"Rows per page:",RANGE_SEPARATOR_LABEL:"of",FIRST_PAGE:"first-page",PREVIOUS_PAGE:"previous-page",NEXT_PAGE:"next-page",LAST_PAGE:"last-page",PAGE_SIZE:"page-size"},i={elementName:R,classes:g,selectors:M,attributes:U,events:D,numbers:H,strings:$};var b=class{constructor(e){this._adapter=e;this._pageIndex=i.numbers.DEFAULT_PAGE_INDEX;this._pageSize=i.numbers.DEFAULT_PAGE_SIZE;this._offset=0;this._total=i.numbers.DEFAULT_TOTAL;this._pageSizeOptions=i.numbers.DEFAULT_PAGE_SIZE_OPTIONS.map(e=>({label:`${e}`,value:`${e}`}));this._label=i.strings.DEFAULT_LABEL;this._firstLast=!1;this._first=!1;this._disabled=!1;this._alignment="space-between";this._pageSizeListener=t=>this._onPageSizeChanged(t),this._firstPageListener=t=>this._onFirstPage(t),this._previousPageListener=t=>this._onPreviousPage(t),this._nextPageListener=t=>this._onNextPage(t),this._lastPageListener=t=>this._onLastPage(t)}initialize(){this._updateRangeLabel(),this._adapter.setLabel(this._label),this._adapter.setPageSizeOptions(this._pageSizeOptions),this._adapter.setPageSize(this._pageSize),this._attachListeners(),this._toggleFirstLastButtons(),this._syncInteractionState()}disconnect(){this._detachListeners()}_attachListeners(){this._adapter.attachPageSizeChangeListener(this._pageSizeListener),this._adapter.attachFirstPageListener(this._firstPageListener),this._adapter.attachPreviousPageListener(this._previousPageListener),this._adapter.attachNextPageListener(this._nextPageListener),this._adapter.attachLastPageListener(this._lastPageListener)}_detachListeners(){this._adapter.detachPageSizeChangeListener(this._pageSizeListener),this._adapter.detachFirstPageListener(this._firstPageListener),this._adapter.detachPreviousPageListener(this._previousPageListener),this._adapter.detachNextPageListener(this._nextPageListener),this._adapter.detachLastPageListener(this._lastPageListener)}_onFirstPage(e){if(e.stopPropagation(),!this._hasFirstPage())return;let t=0;this._emitChangeEvent(i.strings.FIRST_PAGE,{pageIndex:t})&&this._applyPageIndex(t,{fromField:"first"})}_onPreviousPage(e){if(e.stopPropagation(),!this._hasPreviousPage())return;let t=this._pageIndex-1;this._emitChangeEvent(i.strings.PREVIOUS_PAGE,{pageIndex:t})&&this._applyPageIndex(t,{fromField:"previous"})}_onNextPage(e){if(e.stopPropagation(),!this._hasNextPage())return;let t=this._pageIndex+1;this._emitChangeEvent(i.strings.NEXT_PAGE,{pageIndex:t})&&this._applyPageIndex(t,{fromField:"next"})}_onLastPage(e){if(e.stopPropagation(),!this._hasLastPage())return;let t=this._getMaxPages();this._emitChangeEvent(i.strings.LAST_PAGE,{pageIndex:t})&&this._applyPageIndex(t,{fromField:"last"})}_onPageSizeChanged(e){e.stopPropagation();let t=Number(e.detail);this._emitChangeEvent(i.strings.PAGE_SIZE,{pageIndex:0,pageSize:t})?(this._applyPageIndex(0,{fromField:"page-size"}),this._applyPageSize(t)):e.preventDefault()}_emitChangeEvent(e,{pageSize:t=this._pageSize,pageIndex:a=this._pageIndex}={}){let n=a*t,C={type:e,pageSize:t,pageIndex:a,offset:n};return this._adapter.emitHostEvent(i.events.CHANGE,C,!0,!0)}_getMaxPages(){return Math.ceil(this._total/this._pageSize)-1}_updateRangeLabel(){if(this.pageSize>1){let e=this._pageIndex*this._pageSize,a=(Math.floor(e/this._pageSize)||0)*this._pageSize+1,n=e<this._total?Math.min(e+this._pageSize,this._total):e+this._pageSize;this._rangeLabel=`${a}-${n} ${i.strings.RANGE_SEPARATOR_LABEL} ${this._total}`}else this._rangeLabel=`${this._pageIndex+1} ${i.strings.RANGE_SEPARATOR_LABEL} ${this._total}`;this._adapter.setRangeLabel(this._rangeLabel)}_syncInteractionState(e=null){this._adapter.enableFirstPageButton(),this._adapter.enablePreviousPageButton(),this._adapter.enableNextPageButton(),this._adapter.enableLastPageButton(),this._hasFirstPage()||(e&&this._adapter.handleFocusMove(e),this._adapter.disableFirstPageButton()),this._hasPreviousPage()||(e&&this._adapter.handleFocusMove(e),this._adapter.disablePreviousPageButton()),this._hasNextPage()||(e&&this._adapter.handleFocusMove(e),this._adapter.disableNextPageButton()),this._hasLastPage()||(e&&this._adapter.handleFocusMove(e),this._adapter.disableLastPageButton())}_toggleFirstLastButtons(){this._toggleFirstButton(),this._firstLast?this._adapter.hasLastPageButton()||this._adapter.showLastPageButton():this._adapter.hasLastPageButton()&&this._adapter.hideLastPageButton()}_toggleFirstButton(){this._first||this._firstLast?this._adapter.hasFirstPageButton()||this._adapter.showFirstPageButton():this._adapter.hasFirstPageButton()&&this._adapter.hideFirstPageButton()}_hasFirstPage(){return this._hasPreviousPage()}_hasPreviousPage(){return this._pageIndex>0&&this._pageSize>0}_hasNextPage(){let e=this._getMaxPages();return this._pageIndex<e&&this._pageSize>0}_hasLastPage(){return this._hasNextPage()}_computePageIndexFromOffset(e){e>=this._total&&(this._total>=this._pageSize?e=this._total-this._pageSize:e=0);let t=Math.min(Math.max(e,0),this._total),a=Math.floor(t/this._pageSize);this._applyPageIndex(a)}_computeOffset(){this._total>0&&(this._offset=this._pageIndex*this._pageSize)}_applyPageIndex(e,{fromField:t=null}={}){this._pageIndex=e,this._computeOffset(),this._updateRangeLabel(),this._syncInteractionState(t),this._adapter.toggleHostAttribute(i.attributes.PAGE_INDEX,this._pageIndex!=null,this._pageIndex.toString())}_applyPageSize(e){this._pageSize=e,this._adapter.setPageSize(this._pageSize),this._computeOffset(),this._updateRangeLabel(),this._syncInteractionState()}_applyTotal(e){this._total=e,this._updateRangeLabel(),this._offset>0&&this._total>0&&this._computePageIndexFromOffset(this._offset),this._syncInteractionState()}_applyAlternativeAlignment(){this._adapter.setHostAttribute(i.attributes.ALIGNMENT,this._alignment),this._adapter.setAlignment(this._alignment)}_applyDisabled(e){this._disabled=e,e?(this._adapter.disablePageSizeSelect(),this._adapter.disableFirstPageButton(),this._adapter.disablePreviousPageButton(),this._adapter.disableNextPageButton(),this._adapter.disableLastPageButton()):(this._adapter.enablePageSizeSelect(),this._syncInteractionState())}get pageIndex(){return this._pageIndex}set pageIndex(e){this._pageIndex!==e&&(_(e)?this._applyPageIndex(e):this._adapter.removeHostAttribute(i.attributes.PAGE_INDEX))}get pageSize(){return this._pageSize}set pageSize(e){this._pageSize!==e&&(this._applyPageSize(e),this._adapter.setHostAttribute(i.attributes.PAGE_SIZE,`${this._pageSize}`))}get offset(){return this._offset}set offset(e){this._offset!==e&&(this._offset=e,this._computePageIndexFromOffset(e))}get total(){return this._total}set total(e){this._total!==e&&(this._applyTotal(e),this._adapter.setHostAttribute(i.attributes.TOTAL,`${this._total}`))}get pageSizeOptions(){return this._pageSizeOptions.map(e=>Number(e.value))}set pageSizeOptions(e){if(m(e)){if(this._pageSizeOptions=e.map(t=>({label:t.toString(),value:t.toString()})).sort((t,a)=>c(t.value)-c(a.value)),this._adapter.setPageSizeOptions(this._pageSizeOptions),this._adapter.attachPageSizeChangeListener(this._pageSizeListener),this._adapter.setPageSizeVisibility(!0),_(this._pageSize)&&this._pageSizeOptions.length&&!this._pageSizeOptions.find(t=>c(t.value)===this._pageSize)){let t=c(this._pageSizeOptions[0].value);this._applyPageSize(t)}}else e.toString().toLowerCase()==="false"&&(this._adapter.detachPageSizeChangeListener(this._pageSizeListener),this._adapter.setPageSizeVisibility(!1))}get label(){return this._label}set label(e){this._label!==e&&(this._label=e,this._adapter.setLabel(this._label),this._adapter.setHostAttribute(i.attributes.LABEL,_(this._label)?this._label.toString():""))}get firstLast(){return this._firstLast}set firstLast(e){e=Boolean(e),this._firstLast!==e&&(this._firstLast=e,this._toggleFirstLastButtons(),this._adapter.toggleHostAttribute(i.attributes.FIRST_LAST,this._firstLast))}get first(){return this._first}set first(e){e=Boolean(e),this._first!==e&&(this._first=e,this._toggleFirstButton(),this._adapter.toggleHostAttribute(i.attributes.FIRST,this._first))}get disabled(){return this._disabled}set disabled(e){e=Boolean(e),this._disabled!==e&&(this._applyDisabled(e),this._adapter.toggleHostAttribute(i.attributes.DISABLED,this._disabled))}get alternative(){return this._alternative}set alternative(e){e!==this._alternative&&(this._alternative=e,this._adapter.setAlternative(this._alternative),this._applyAlternativeAlignment(),this._adapter.toggleHostAttribute(i.attributes.ALTERNATIVE,this._alternative))}get alignment(){return this._alignment}set alignment(e){e!==this._alignment&&(this._alignment=e,this._applyAlternativeAlignment())}};var u=class extends y{constructor(t){super(t);this._labelElement=r(t,i.selectors.LABEL),this._root=r(t,i.selectors.ROOT),this._pageSizeSelect=r(t,i.selectors.PAGE_SIZE_SELECT),this._rangeLabel=r(t,i.selectors.RANGE_LABEL),this._rangeLabelAlternative=r(t,i.selectors.RANGE_LABEL_ALTERNATIVE),this._firstPageButton=r(t,i.selectors.FIRST_PAGE_BUTTON),this._firstPageIconButton=r(t,i.selectors.FIRST_PAGE_ICON_BUTTON),this._previousPageButton=r(t,i.selectors.PREVIOUS_PAGE_BUTTON),this._nextPageButton=r(t,i.selectors.NEXT_PAGE_BUTTON),this._lastPageButton=r(t,i.selectors.LAST_PAGE_BUTTON),this._lastPageIconButton=r(t,i.selectors.LAST_PAGE_ICON_BUTTON)}setLabel(t){this._labelElement.textContent=t}setPageSizeOptions(t){v(this._pageSizeSelect),this._pageSizeSelect.options=t}setPageSize(t){this._pageSizeSelect.value=t.toString()}setRangeLabel(t){this._rangeLabel.innerText=t,this._rangeLabelAlternative.innerText=t}hasFirstPageButton(){return!!r(this._component,i.selectors.FIRST_PAGE_ICON_BUTTON)}showFirstPageButton(){this._firstPagePlaceholder=d(this._component,!0,i.elementName,i.selectors.FIRST_PAGE_ICON_BUTTON,this._firstPageIconButton,this._firstPagePlaceholder)}hideFirstPageButton(){this._firstPagePlaceholder=d(this._component,!1,i.elementName,i.selectors.FIRST_PAGE_ICON_BUTTON,this._firstPageIconButton,this._firstPagePlaceholder)}hasLastPageButton(){return!!r(this._component,i.selectors.LAST_PAGE_ICON_BUTTON)}showLastPageButton(){this._lastPagePlaceholder=d(this._component,!0,i.elementName,i.selectors.LAST_PAGE_ICON_BUTTON,this._lastPageIconButton,this._lastPagePlaceholder)}hideLastPageButton(){this._lastPagePlaceholder=d(this._component,!1,i.elementName,i.selectors.LAST_PAGE_ICON_BUTTON,this._lastPageIconButton,this._lastPagePlaceholder)}attachPageSizeChangeListener(t){this._pageSizeSelect.addEventListener("change",t)}attachFirstPageListener(t){this._firstPageButton.addEventListener("click",t)}attachPreviousPageListener(t){this._previousPageButton.addEventListener("click",t)}attachNextPageListener(t){this._nextPageButton.addEventListener("click",t)}attachLastPageListener(t){this._lastPageButton.addEventListener("click",t)}detachPageSizeChangeListener(t){this._pageSizeSelect.removeEventListener("change",t)}detachFirstPageListener(t){this._firstPageButton.removeEventListener("click",t)}detachPreviousPageListener(t){this._previousPageButton.removeEventListener("click",t)}detachNextPageListener(t){this._nextPageButton.removeEventListener("click",t)}detachLastPageListener(t){this._lastPageButton.removeEventListener("click",t)}disableFirstPageButton(){this._firstPageButton.setAttribute("disabled","disabled")}enableFirstPageButton(){this._firstPageButton.removeAttribute("disabled")}disablePreviousPageButton(){this._previousPageButton.setAttribute("disabled","disabled")}enablePreviousPageButton(){this._previousPageButton.removeAttribute("disabled")}disableNextPageButton(){this._nextPageButton.setAttribute("disabled","disabled")}enableNextPageButton(){this._nextPageButton.removeAttribute("disabled")}disablePageSizeSelect(){this._pageSizeSelect.setAttribute("disabled","disabled")}enablePageSizeSelect(){this._pageSizeSelect.removeAttribute("disabled")}setPageSizeVisibility(t){t?this._pageSizeSelect.style.removeProperty("display"):this._pageSizeSelect.style.display="none"}disableLastPageButton(){this._lastPageButton.setAttribute("disabled","disabled")}enableLastPageButton(){this._lastPageButton.removeAttribute("disabled")}setAlternative(t){E(this._root,t,i.classes.ALTERNATIVE)}setAlignment(t){switch(P([i.classes.ALIGNMENT_SPACE_BETWEEN,i.classes.ALIGNMENT_START,i.classes.ALIGNMENT_END],this._root),t){case"start":h(i.classes.ALIGNMENT_START,this._root);break;case"end":h(i.classes.ALIGNMENT_END,this._root);break;case"space-between":default:h(i.classes.ALIGNMENT_SPACE_BETWEEN,this._root);break}}handleFocusMove(t){if(!!this._component.matches(":focus"))switch(t){case"first":this._tryFocus([this._nextPageButton,this._lastPageButton,this._previousPageButton,this._pageSizeSelect]);break;case"last":this._tryFocus([this._previousPageButton,this._firstPageButton,this._nextPageButton,this._pageSizeSelect]);break;case"previous":this._tryFocus([this._nextPageButton,this._lastPageButton,this._firstPageButton,this._pageSizeSelect]);break;case"next":this._tryFocus([this._previousPageButton,this._firstPageButton,this._lastPageButton,this._pageSizeSelect]);break;case"page-size":this._tryFocus([this._nextPageButton,this._lastPageButton,this._firstPageButton,this._previousPageButton]);break}}_tryFocus(t){for(let a of t)if(a&&a.isConnected&&!a.disabled){a.focus();return}}};var Z='<template><div class="forge-paginator" part="root"><div class="forge-paginator__container" part="container"><div class="forge-paginator__label" part="label"></div><forge-select class="forge-paginator__page-size-options" aria-label="Choose page size" density="dense" part="page-size-options"></forge-select><div class="forge-paginator__range-label" part="range-label"></div><forge-icon-button class="forge-paginator__first-page" part="first-page-button"><button aria-label="First Page" part="first-page-button-element"><forge-icon name="first_page" part="first-page-icon"></forge-icon></button><forge-tooltip position="top">Go to the first page</forge-tooltip></forge-icon-button><forge-icon-button class="forge-paginator__previous-page" part="previous-page-button"><button aria-label="Previous Page" part="previous-page-button-element"><forge-icon name="keyboard_arrow_left" part="previous-page-button-icon"></forge-icon></button><forge-tooltip position="top">Go to the previous page</forge-tooltip></forge-icon-button><div class="forge-paginator__range-label--alternative" part="range-label-alternative"></div><forge-icon-button class="forge-paginator__next-page" part="next-page-button"><button aria-label="Next Page" part="next-page-button-element"><forge-icon name="keyboard_arrow_right" part="next-page-icon"></forge-icon></button><forge-tooltip position="top">Go to the next page</forge-tooltip></forge-icon-button><forge-icon-button class="forge-paginator__last-page" part="last-page-button"><button aria-label="Last Page" part="last-page-button-element"><forge-icon name="last_page" part="last-page-icon"></forge-icon></button><forge-tooltip position="top">Go to the last page</forge-tooltip></forge-icon-button></div></div></template>',X='.forge-icon-button{display:-webkit-inline-box;display:inline-flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;border:none;outline:0;background-color:transparent;fill:currentColor;color:inherit;font-size:24px;text-decoration:none;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:48px;height:48px;padding:12px}.forge-icon-button forge-icon,.forge-icon-button img,.forge-icon-button svg{width:24px;height:24px}.forge-icon-button:disabled{color:rgba(0,0,0,.38);color:var(--mdc-theme-text-disabled-on-light,rgba(0,0,0,.38))}.forge-icon-button:disabled{cursor:default;pointer-events:none}.forge-icon-button__icon{display:inline-block}.forge-icon-button__icon.forge-icon-button__icon--on{display:none}.forge-icon-button--on .forge-icon-button__icon{display:none}.forge-icon-button--on .forge-icon-button__icon.forge-icon-button__icon--on{display:inline-block}@-webkit-keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@-webkit-keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@-webkit-keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}@keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.forge-icon-button{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:transparent;will-change:transform,opacity}.forge-icon-button::after,.forge-icon-button::before{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:""}.forge-icon-button::before{-webkit-transition:opacity 15ms linear,background-color 15ms linear;transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index,1)}.forge-icon-button::after{z-index:0;z-index:var(--mdc-ripple-z-index,0)}.forge-icon-button.mdc-ripple-upgraded::before{-webkit-transform:scale(var(--mdc-ripple-fg-scale,1));transform:scale(var(--mdc-ripple-fg-scale,1))}.forge-icon-button.mdc-ripple-upgraded::after{top:0;left:0;-webkit-transform:scale(0);transform:scale(0);-webkit-transform-origin:center center;transform-origin:center center}.forge-icon-button.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top,0);left:var(--mdc-ripple-left,0)}.forge-icon-button.mdc-ripple-upgraded--foreground-activation::after{-webkit-animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards;animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.forge-icon-button.mdc-ripple-upgraded--foreground-deactivation::after{-webkit-animation:mdc-ripple-fg-opacity-out 150ms;animation:mdc-ripple-fg-opacity-out 150ms;-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}.forge-icon-button::after,.forge-icon-button::before{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.forge-icon-button.mdc-ripple-upgraded::after,.forge-icon-button.mdc-ripple-upgraded::before{top:var(--mdc-ripple-top,calc(50% - 50%));left:var(--mdc-ripple-left,calc(50% - 50%));width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.forge-icon-button.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.forge-icon-button::after,.forge-icon-button::before{background-color:#000;background-color:var(--mdc-ripple-color,var(--mdc-theme-on-surface,#000))}.forge-icon-button.mdc-ripple-surface--hover::before,.forge-icon-button:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.forge-icon-button.mdc-ripple-upgraded--background-focused::before,.forge-icon-button:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.forge-icon-button:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.forge-icon-button:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.forge-icon-button.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}forge-icon-button{position:relative;display:inline-block;overflow:visible}.forge-icon-button--on{color:#3f51b5;color:var(--mdc-theme-primary,#3f51b5)}.forge-icon-button--on::after,.forge-icon-button--on::before{background-color:#3f51b5;background-color:var(--mdc-ripple-color,var(--mdc-theme-primary,#3f51b5))}.forge-icon-button--on.mdc-ripple-surface--hover::before,.forge-icon-button--on:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.forge-icon-button--on.mdc-ripple-upgraded--background-focused::before,.forge-icon-button--on:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.forge-icon-button--on:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.forge-icon-button--on:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.forge-icon-button--on.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.forge-icon-button--on::before{background-color:#3f51b5;background-color:var(--mdc-theme-primary,#3f51b5);opacity:.08}.forge-icon-button--dense{width:28px;height:28px;padding:2px;padding:0}.forge-icon-button--dense-1{width:44px;height:44px;padding:10px}.forge-icon-button--dense-2{width:40px;height:40px;padding:8px}.forge-icon-button--dense-3{width:36px;height:36px;padding:6px}.forge-icon-button--dense-4{width:32px;height:32px;padding:4px}.forge-icon-button--dense-5{width:28px;height:28px;padding:2px}.forge-icon-button--dense-6{width:24px;height:24px;padding:0}.forge-icon-button--with-badge forge-badge{z-index:1;z-index:var(--forge-z-index-surface,1);pointer-events:none;--forge-badge-max-width:32px;--forge-badge-border:1px solid transparent}.forge-icon-button--with-badge forge-badge[app-bar-context]{--forge-badge-border:2px solid var(--forge-app-bar-theme-background)}.forge-paginator{display:inline-block}.forge-paginator--alternative{display:-webkit-box;display:flex}.forge-paginator--alternative .forge-paginator__label,.forge-paginator--alternative .forge-paginator__page-size-options,.forge-paginator--alternative .forge-paginator__range-label{display:none}.forge-paginator--alternative .forge-paginator__range-label--alternative{display:inline-block;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-body2-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.875rem;font-size:var(--mdc-typography-body2-font-size, .875rem);line-height:1.25rem;line-height:var(--mdc-typography-body2-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-body2-font-weight,400);letter-spacing:.0178571429em;letter-spacing:var(--mdc-typography-body2-letter-spacing, .0178571429em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-body2-text-decoration,inherit);text-decoration:var(--mdc-typography-body2-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-body2-text-transform,inherit);margin:0 12px}.forge-paginator__range-label--alternative{display:none}.forge-paginator__container{display:-webkit-box;display:flex;-webkit-box-align:center;align-items:center}.forge-paginator__label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.75rem;font-size:var(--mdc-typography-caption-font-size, .75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight,400);letter-spacing:.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, .0333333333em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform,inherit);margin-right:16px}.forge-paginator__page-size-options{margin-right:16px}.forge-paginator__range-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.75rem;font-size:var(--mdc-typography-caption-font-size, .75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight,400);letter-spacing:.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, .0333333333em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform,inherit);margin-right:8px}.forge-paginator__first-page,.forge-paginator__last-page,.forge-paginator__next-page,.forge-paginator__previous-page{color:rgba(0,0,0,.87);color:var(--mdc-theme-text-primary-on-background,rgba(0,0,0,.87))}:host{display:inline-block}:host([hidden]){display:none}:host([alternative]) .forge-paginator--alignment-center .forge-paginator__container{-webkit-box-pack:center;justify-content:center}:host([alternative]) .forge-paginator--alignment-center .forge-paginator__range-label--alternative{margin:0 auto}:host([alternative]) .forge-paginator--alignment-start .forge-paginator__container{-webkit-box-pack:start;justify-content:flex-start}:host([alternative]) .forge-paginator--alignment-end .forge-paginator__container{-webkit-box-pack:end;justify-content:flex-end}:host([alternative]) .forge-paginator .forge-paginator__container{-webkit-box-flex:1;flex:1}',o=class extends T{constructor(){super();O.define([I,B,N,z]),L(this,Z,X),this._foundation=new b(new u(this))}static get observedAttributes(){return[i.attributes.PAGE_INDEX,i.attributes.PAGE_SIZE,i.attributes.OFFSET,i.attributes.TOTAL,i.attributes.PAGE_SIZE_OPTIONS,i.attributes.LABEL,i.attributes.FIRST_LAST,i.attributes.FIRST,i.attributes.DISABLED,i.attributes.ALTERNATIVE,i.attributes.ALIGNMENT]}connectedCallback(){this._foundation.initialize()}disconnectedCallback(){this._foundation.disconnect()}attributeChangedCallback(t,a,n){switch(t){case i.attributes.PAGE_INDEX:this.pageIndex=Number(n)||i.numbers.DEFAULT_PAGE_INDEX;break;case i.attributes.PAGE_SIZE:this.pageSize=Number(n)||i.numbers.DEFAULT_PAGE_SIZE;break;case i.attributes.OFFSET:this.offset=Number(n);break;case i.attributes.TOTAL:this.total=Number(n)||i.numbers.DEFAULT_TOTAL;break;case i.attributes.PAGE_SIZE_OPTIONS:this.pageSizeOptions=n;break;case i.attributes.LABEL:this.label=n;break;case i.attributes.FIRST_LAST:this.firstLast=l(n);break;case i.attributes.FIRST:this.first=l(n);break;case i.attributes.DISABLED:this.disabled=l(n);break;case i.attributes.ALTERNATIVE:this.alternative=l(n);break;case i.attributes.ALIGNMENT:this.alignment=n;break}}};s([p()],o.prototype,"pageIndex",2),s([p()],o.prototype,"pageSize",2),s([p()],o.prototype,"offset",2),s([p()],o.prototype,"total",2),s([p()],o.prototype,"pageSizeOptions",2),s([p()],o.prototype,"label",2),s([p()],o.prototype,"firstLast",2),s([p()],o.prototype,"first",2),s([p()],o.prototype,"disabled",2),s([p()],o.prototype,"alternative",2),s([p()],o.prototype,"alignment",2),o=s([S({name:i.elementName,dependencies:[F,w,k,G]})],o);function At(){A(o)}export{i as a,b,u as c,o as d,At as e};
7
+ //# sourceMappingURL=chunk.PBWUHK7Q.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/paginator/paginator-constants.ts", "../../src/paginator/paginator-foundation.ts", "../../src/paginator/paginator-adapter.ts", "../../src/paginator/paginator.ts", "../../src/paginator/index.ts"],
4
+ "sourcesContent": ["import { COMPONENT_NAME_PREFIX } from '../constants';\n\nconst elementName: keyof HTMLElementTagNameMap = `${COMPONENT_NAME_PREFIX}paginator`;\n\nconst classes = {\n LABEL: 'forge-paginator__label',\n PAGE_SIZE_OPTIONS: 'forge-paginator__page-size-options',\n RANGE_LABEL: 'forge-paginator__range-label',\n RANGE_LABEL_ALTERNATIVE: 'forge-paginator__range-label--alternative',\n FIRST_PAGE_BUTTON: 'forge-paginator__first-page',\n PREVIOUS_PAGE_BUTTON: 'forge-paginator__previous-page',\n NEXT_PAGE_BUTTON: 'forge-paginator__next-page',\n LAST_PAGE_BUTTON: 'forge-paginator__last-page',\n ROOT: 'forge-paginator',\n ALTERNATIVE: 'forge-paginator--alternative',\n ALIGNMENT_START: 'forge-paginator--alignment-start',\n ALIGNMENT_SPACE_BETWEEN: 'forge-paginator--alignment-center',\n ALIGNMENT_END: 'forge-paginator--alignment-end'\n};\n\nconst selectors = {\n LABEL: `.${classes.LABEL}`,\n PAGE_SIZE_SELECT: `.${classes.PAGE_SIZE_OPTIONS}`,\n RANGE_LABEL: `.${classes.RANGE_LABEL}`,\n FIRST_PAGE_BUTTON: `.${classes.FIRST_PAGE_BUTTON} > button`,\n FIRST_PAGE_ICON_BUTTON: `.${classes.FIRST_PAGE_BUTTON}`,\n PREVIOUS_PAGE_BUTTON: `.${classes.PREVIOUS_PAGE_BUTTON} > button`,\n NEXT_PAGE_BUTTON: `.${classes.NEXT_PAGE_BUTTON} > button`,\n LAST_PAGE_BUTTON: `.${classes.LAST_PAGE_BUTTON} > button`,\n LAST_PAGE_ICON_BUTTON: `.${classes.LAST_PAGE_BUTTON}`,\n ROOT: `.${classes.ROOT}`,\n RANGE_LABEL_ALTERNATIVE: `.${classes.RANGE_LABEL_ALTERNATIVE}`\n};\n\nconst attributes = {\n PAGE_INDEX: 'page-index',\n PAGE_SIZE: 'page-size',\n OFFSET: 'offset',\n PAGE_SIZE_OPTIONS: 'page-size-options',\n TOTAL: 'total',\n LABEL: 'label',\n FIRST_LAST: 'first-last',\n FIRST: 'first',\n DISABLED: 'disabled',\n ALTERNATIVE: 'alternative',\n ALIGNMENT: 'alignment'\n};\n\nconst events = {\n CHANGE: `${elementName}-change`\n};\n\nconst numbers = {\n DEFAULT_PAGE_INDEX: 0,\n DEFAULT_TOTAL: 0,\n DEFAULT_PAGE_SIZE: 25,\n DEFAULT_PAGE_SIZE_OPTIONS: [5, 15, 25, 50, 100]\n};\n\nconst strings = {\n DEFAULT_LABEL: 'Rows per page:',\n RANGE_SEPARATOR_LABEL: 'of',\n FIRST_PAGE: 'first-page',\n PREVIOUS_PAGE: 'previous-page',\n NEXT_PAGE: 'next-page',\n LAST_PAGE: 'last-page',\n PAGE_SIZE: 'page-size'\n};\n\nexport const PAGINATOR_CONSTANTS = {\n elementName,\n classes,\n selectors,\n attributes,\n events,\n numbers,\n strings\n};\n\nexport type PaginatorAlternativeAlignment = 'start' | 'space-between' | 'end';\nexport interface IPaginatorChangeEvent {\n type: string;\n pageSize: number;\n pageIndex: number;\n offset: number;\n}\n", "import { coerceNumber, ICustomElementFoundation, isArray, isDefined } from '@tylertech/forge-core';\nimport { IPaginatorAdapter, PaginatorFieldIdentifier } from './paginator-adapter';\nimport { PaginatorAlternativeAlignment, PAGINATOR_CONSTANTS, IPaginatorChangeEvent } from './paginator-constants';\nimport { ISelectOption } from '../select';\n\nexport interface IPaginatorFoundation extends ICustomElementFoundation {\n pageIndex: number;\n pageSize: number;\n offset: number;\n total: number;\n pageSizeOptions: number[] | boolean;\n pageSizeLabel: string;\n}\n\nexport class PaginatorFoundation {\n private _pageIndex = PAGINATOR_CONSTANTS.numbers.DEFAULT_PAGE_INDEX;\n private _pageSize = PAGINATOR_CONSTANTS.numbers.DEFAULT_PAGE_SIZE;\n private _offset = 0;\n private _total = PAGINATOR_CONSTANTS.numbers.DEFAULT_TOTAL;\n private _pageSizeOptions: ISelectOption[] = PAGINATOR_CONSTANTS.numbers.DEFAULT_PAGE_SIZE_OPTIONS.map(o => ({ label: `${o}`, value: `${o}` }));\n private _label = PAGINATOR_CONSTANTS.strings.DEFAULT_LABEL;\n private _firstLast = false;\n private _first = false;\n private _disabled = false;\n private _alternative: boolean;\n private _alignment: PaginatorAlternativeAlignment = 'space-between';\n private _rangeLabel: string;\n\n private _firstPageListener: (evt: Event) => void;\n private _previousPageListener: (evt: Event) => void;\n private _nextPageListener: (evt: Event) => void;\n private _lastPageListener: (evt: Event) => void;\n private _pageSizeListener: (evt: Event) => void;\n\n constructor(private _adapter: IPaginatorAdapter) {\n this._pageSizeListener = (evt: CustomEvent<number>) => this._onPageSizeChanged(evt);\n this._firstPageListener = (evt: Event) => this._onFirstPage(evt);\n this._previousPageListener = (evt: Event) => this._onPreviousPage(evt);\n this._nextPageListener = (evt: Event) => this._onNextPage(evt);\n this._lastPageListener = (evt: Event) => this._onLastPage(evt);\n }\n\n public initialize(): void {\n this._updateRangeLabel();\n this._adapter.setLabel(this._label);\n this._adapter.setPageSizeOptions(this._pageSizeOptions);\n this._adapter.setPageSize(this._pageSize);\n this._attachListeners();\n this._toggleFirstLastButtons();\n this._syncInteractionState();\n }\n\n public disconnect(): void {\n this._detachListeners();\n }\n\n private _attachListeners(): void {\n this._adapter.attachPageSizeChangeListener(this._pageSizeListener);\n this._adapter.attachFirstPageListener(this._firstPageListener);\n this._adapter.attachPreviousPageListener(this._previousPageListener);\n this._adapter.attachNextPageListener(this._nextPageListener);\n this._adapter.attachLastPageListener(this._lastPageListener);\n }\n\n private _detachListeners(): void {\n this._adapter.detachPageSizeChangeListener(this._pageSizeListener);\n this._adapter.detachFirstPageListener(this._firstPageListener);\n this._adapter.detachPreviousPageListener(this._previousPageListener);\n this._adapter.detachNextPageListener(this._nextPageListener);\n this._adapter.detachLastPageListener(this._lastPageListener);\n }\n\n private _onFirstPage(evt: Event): void {\n evt.stopPropagation();\n\n if (!this._hasFirstPage()) {\n return;\n }\n\n const firstPage = 0;\n const canPage = this._emitChangeEvent(PAGINATOR_CONSTANTS.strings.FIRST_PAGE, { pageIndex: firstPage });\n if (canPage) {\n this._applyPageIndex(firstPage, { fromField: 'first' });\n }\n }\n\n private _onPreviousPage(evt: Event): void {\n evt.stopPropagation();\n\n if (!this._hasPreviousPage()) {\n return;\n }\n \n const prevPage = this._pageIndex - 1;\n const canPage = this._emitChangeEvent(PAGINATOR_CONSTANTS.strings.PREVIOUS_PAGE, { pageIndex: prevPage });\n if (canPage) {\n this._applyPageIndex(prevPage, { fromField: 'previous' });\n }\n }\n\n private _onNextPage(evt: Event): void {\n evt.stopPropagation();\n\n if (!this._hasNextPage()) {\n return;\n }\n\n const nextPage = this._pageIndex + 1;\n const canPage = this._emitChangeEvent(PAGINATOR_CONSTANTS.strings.NEXT_PAGE, { pageIndex: nextPage });\n if (canPage) {\n this._applyPageIndex(nextPage, { fromField: 'next' });\n }\n }\n\n private _onLastPage(evt: Event): void {\n evt.stopPropagation();\n\n if (!this._hasLastPage()) {\n return;\n }\n\n const lastPage = this._getMaxPages();\n const canPage = this._emitChangeEvent(PAGINATOR_CONSTANTS.strings.LAST_PAGE, { pageIndex: lastPage });\n if (canPage) {\n this._applyPageIndex(lastPage, { fromField: 'last' });\n }\n }\n\n private _onPageSizeChanged(evt: CustomEvent): void {\n evt.stopPropagation();\n\n const pageSize = Number(evt.detail);\n const canPage = this._emitChangeEvent(PAGINATOR_CONSTANTS.strings.PAGE_SIZE, { pageIndex: 0, pageSize });\n if (canPage) {\n this._applyPageIndex(0, { fromField: 'page-size' });\n this._applyPageSize(pageSize);\n } else {\n evt.preventDefault();\n }\n }\n\n private _emitChangeEvent(type: string, { pageSize = this._pageSize, pageIndex = this._pageIndex } = {}): boolean {\n const offset = pageIndex * pageSize;\n const detail: IPaginatorChangeEvent = { type, pageSize, pageIndex, offset };\n return this._adapter.emitHostEvent(PAGINATOR_CONSTANTS.events.CHANGE, detail, true, true);\n }\n\n private _getMaxPages(): number {\n return Math.ceil(this._total / this._pageSize) - 1;\n }\n\n private _updateRangeLabel(): void {\n if (this.pageSize > 1) {\n const startIndex = this._pageIndex * this._pageSize;\n const indexStart = Math.floor(startIndex / this._pageSize) || 0;\n const pageStart = (indexStart * this._pageSize) + 1;\n const pageEnd = startIndex < this._total ? Math.min(startIndex + this._pageSize, this._total) : startIndex + this._pageSize;\n this._rangeLabel = `${pageStart}-${pageEnd} ${PAGINATOR_CONSTANTS.strings.RANGE_SEPARATOR_LABEL} ${this._total}`;\n } else {\n this._rangeLabel = `${this._pageIndex + 1} ${PAGINATOR_CONSTANTS.strings.RANGE_SEPARATOR_LABEL} ${this._total}`;\n }\n this._adapter.setRangeLabel(this._rangeLabel);\n }\n\n private _syncInteractionState(fromField: PaginatorFieldIdentifier | null = null): void {\n this._adapter.enableFirstPageButton();\n this._adapter.enablePreviousPageButton();\n this._adapter.enableNextPageButton();\n this._adapter.enableLastPageButton();\n\n if (!this._hasFirstPage()) {\n if (fromField) {\n this._adapter.handleFocusMove(fromField);\n }\n this._adapter.disableFirstPageButton();\n }\n\n if (!this._hasPreviousPage()) {\n if (fromField) {\n this._adapter.handleFocusMove(fromField);\n }\n this._adapter.disablePreviousPageButton();\n }\n\n if (!this._hasNextPage()) {\n if (fromField) {\n this._adapter.handleFocusMove(fromField);\n }\n this._adapter.disableNextPageButton();\n }\n\n if (!this._hasLastPage()) {\n if (fromField) {\n this._adapter.handleFocusMove(fromField);\n }\n this._adapter.disableLastPageButton();\n }\n }\n\n private _toggleFirstLastButtons(): void {\n this._toggleFirstButton();\n if (this._firstLast) {\n if (!this._adapter.hasLastPageButton()) {\n this._adapter.showLastPageButton();\n }\n } else {\n if (this._adapter.hasLastPageButton()) {\n this._adapter.hideLastPageButton();\n }\n }\n }\n\n private _toggleFirstButton(): void {\n if (this._first || this._firstLast) {\n if (!this._adapter.hasFirstPageButton()) {\n this._adapter.showFirstPageButton();\n }\n } else {\n if (this._adapter.hasFirstPageButton()) {\n this._adapter.hideFirstPageButton();\n }\n }\n }\n\n private _hasFirstPage(): boolean {\n return this._hasPreviousPage();\n }\n\n private _hasPreviousPage(): boolean {\n return this._pageIndex > 0 && this._pageSize > 0;\n }\n\n private _hasNextPage(): boolean {\n const maxPages = this._getMaxPages();\n return this._pageIndex < maxPages && this._pageSize > 0;\n }\n\n private _hasLastPage(): boolean {\n return this._hasNextPage();\n }\n\n private _computePageIndexFromOffset(value: number): void {\n if (value >= this._total) {\n if (this._total >= this._pageSize) {\n value = this._total - this._pageSize;\n } else {\n value = 0;\n }\n }\n const clampedValue = Math.min(Math.max(value, 0), this._total);\n const pageIndex = Math.floor(clampedValue / this._pageSize);\n this._applyPageIndex(pageIndex);\n }\n\n private _computeOffset(): void {\n if (this._total > 0) {\n this._offset = this._pageIndex * this._pageSize;\n }\n }\n\n private _applyPageIndex(value: number, { fromField = null }: { fromField?: PaginatorFieldIdentifier | null } = {}): void {\n this._pageIndex = value;\n this._computeOffset();\n this._updateRangeLabel();\n this._syncInteractionState(fromField);\n this._adapter.toggleHostAttribute(PAGINATOR_CONSTANTS.attributes.PAGE_INDEX, this._pageIndex != null, this._pageIndex.toString());\n }\n\n private _applyPageSize(value: number): void {\n this._pageSize = value;\n this._adapter.setPageSize(this._pageSize);\n this._computeOffset();\n this._updateRangeLabel();\n this._syncInteractionState();\n }\n\n private _applyTotal(value: number): void {\n this._total = value;\n this._updateRangeLabel();\n\n if (this._offset > 0 && this._total > 0) {\n this._computePageIndexFromOffset(this._offset);\n }\n\n this._syncInteractionState();\n }\n\n private _applyAlternativeAlignment(): void {\n this._adapter.setHostAttribute(PAGINATOR_CONSTANTS.attributes.ALIGNMENT, this._alignment);\n this._adapter.setAlignment(this._alignment);\n }\n\n private _applyDisabled(disabled: boolean): void {\n this._disabled = disabled;\n if (disabled) {\n this._adapter.disablePageSizeSelect();\n this._adapter.disableFirstPageButton();\n this._adapter.disablePreviousPageButton();\n this._adapter.disableNextPageButton();\n this._adapter.disableLastPageButton();\n } else {\n this._adapter.enablePageSizeSelect();\n this._syncInteractionState();\n }\n }\n\n public get pageIndex(): number {\n return this._pageIndex;\n }\n public set pageIndex(value: number) {\n if (this._pageIndex !== value) {\n if (isDefined(value)) {\n this._applyPageIndex(value);\n } else {\n this._adapter.removeHostAttribute(PAGINATOR_CONSTANTS.attributes.PAGE_INDEX);\n }\n }\n }\n\n public get pageSize(): number {\n return this._pageSize;\n }\n public set pageSize(value: number) {\n if (this._pageSize !== value) {\n this._applyPageSize(value);\n this._adapter.setHostAttribute(PAGINATOR_CONSTANTS.attributes.PAGE_SIZE, `${this._pageSize}`);\n }\n }\n\n public get offset(): number {\n return this._offset;\n }\n public set offset(value: number) {\n if (this._offset !== value) {\n this._offset = value;\n this._computePageIndexFromOffset(value);\n }\n }\n\n public get total(): number {\n return this._total;\n }\n public set total(value: number) {\n if (this._total !== value) {\n this._applyTotal(value);\n this._adapter.setHostAttribute(PAGINATOR_CONSTANTS.attributes.TOTAL, `${this._total}`);\n }\n }\n\n public get pageSizeOptions(): number[] | boolean {\n return this._pageSizeOptions.map(o => Number(o.value));\n }\n public set pageSizeOptions(options: number[] | boolean) {\n if (isArray(options)) {\n this._pageSizeOptions = (options as number[])\n .map(o => ({ label: o.toString(), value: o.toString() }))\n .sort((a, b) => coerceNumber(a.value) - coerceNumber(b.value));\n this._adapter.setPageSizeOptions(this._pageSizeOptions);\n this._adapter.attachPageSizeChangeListener(this._pageSizeListener);\n this._adapter.setPageSizeVisibility(true);\n if (isDefined(this._pageSize) && this._pageSizeOptions.length && !this._pageSizeOptions.find(o => coerceNumber(o.value) === this._pageSize)) {\n const pageSize = coerceNumber(this._pageSizeOptions[0].value);\n this._applyPageSize(pageSize);\n }\n } else if (options.toString().toLowerCase() === 'false') {\n this._adapter.detachPageSizeChangeListener(this._pageSizeListener);\n this._adapter.setPageSizeVisibility(false);\n }\n }\n\n public get label(): string {\n return this._label;\n }\n public set label(value: string) {\n if (this._label !== value) {\n this._label = value;\n this._adapter.setLabel(this._label);\n this._adapter.setHostAttribute(PAGINATOR_CONSTANTS.attributes.LABEL, isDefined(this._label) ? this._label.toString() : '');\n }\n }\n\n public get firstLast(): boolean {\n return this._firstLast;\n }\n public set firstLast(value: boolean) {\n value = Boolean(value);\n if (this._firstLast !== value) {\n this._firstLast = value;\n this._toggleFirstLastButtons();\n this._adapter.toggleHostAttribute(PAGINATOR_CONSTANTS.attributes.FIRST_LAST, this._firstLast);\n }\n }\n\n public get first(): boolean {\n return this._first;\n }\n public set first(value: boolean) {\n value = Boolean(value);\n if (this._first !== value) {\n this._first = value;\n this._toggleFirstButton();\n this._adapter.toggleHostAttribute(PAGINATOR_CONSTANTS.attributes.FIRST, this._first);\n }\n }\n\n public get disabled(): boolean {\n return this._disabled;\n }\n public set disabled(value: boolean) {\n value = Boolean(value);\n if (this._disabled !== value) {\n this._applyDisabled(value);\n this._adapter.toggleHostAttribute(PAGINATOR_CONSTANTS.attributes.DISABLED, this._disabled);\n }\n }\n\n public get alternative(): boolean {\n return this._alternative;\n }\n public set alternative(value: boolean) {\n if (value !== this._alternative) {\n this._alternative = value;\n this._adapter.setAlternative(this._alternative);\n this._applyAlternativeAlignment();\n this._adapter.toggleHostAttribute(PAGINATOR_CONSTANTS.attributes.ALTERNATIVE, this._alternative);\n }\n }\n\n public get alignment(): PaginatorAlternativeAlignment {\n return this._alignment;\n }\n public set alignment(value: PaginatorAlternativeAlignment) {\n if (value !== this._alignment) {\n this._alignment = value;\n this._applyAlternativeAlignment();\n }\n }\n}\n", "import { addClass, getShadowElement, removeAllChildren, removeClass, toggleElementPlaceholder, toggleClass } from '@tylertech/forge-core';\nimport { BaseAdapter, IBaseAdapter } from '../core/base/base-adapter';\nimport { IIconButtonComponent } from '../icon-button';\nimport { ISelectComponent, ISelectOption } from '../select';\nimport { IPaginatorComponent } from './paginator';\nimport { PaginatorAlternativeAlignment, PAGINATOR_CONSTANTS } from './paginator-constants';\n\nexport type PaginatorFieldIdentifier = 'first' | 'last' | 'previous' | 'next' | 'page-size';\n\nexport interface IPaginatorAdapter extends IBaseAdapter {\n setLabel(value: string): void;\n setPageSizeOptions(options: ISelectOption[]): void;\n setPageSize(value: number): void;\n setRangeLabel(value: string): void;\n hasFirstPageButton(): boolean;\n showFirstPageButton(): void;\n hideFirstPageButton(): void;\n hasLastPageButton(): boolean;\n showLastPageButton(): void;\n hideLastPageButton(): void;\n attachPageSizeChangeListener(listener: (evt: CustomEvent) => void): void;\n attachFirstPageListener(listener: (evt: Event) => void): void;\n attachPreviousPageListener(listener: (evt: Event) => void): void;\n attachNextPageListener(listener: (evt: Event) => void): void;\n attachLastPageListener(listener: (evt: Event) => void): void;\n detachPageSizeChangeListener(listener: (evt: CustomEvent) => void): void;\n detachFirstPageListener(listener: (evt: Event) => void): void;\n detachPreviousPageListener(listener: (evt: Event) => void): void;\n detachNextPageListener(listener: (evt: Event) => void): void;\n detachLastPageListener(listener: (evt: Event) => void): void;\n disableFirstPageButton(): void;\n enableFirstPageButton(): void;\n disablePreviousPageButton(): void;\n enablePreviousPageButton(): void;\n disableNextPageButton(): void;\n enableNextPageButton(): void;\n disablePageSizeSelect(): void;\n enablePageSizeSelect(): void;\n setPageSizeVisibility(visible: boolean): void;\n disableLastPageButton(): void;\n enableLastPageButton(): void;\n setAlternative(alternative: boolean): void;\n setAlignment(alignment: PaginatorAlternativeAlignment): void;\n handleFocusMove(from: PaginatorFieldIdentifier): void;\n}\n\n/**\n * Provides facilities for interacting with the internal DOM of `PaginatorComponent`.\n */\nexport class PaginatorAdapter extends BaseAdapter<IPaginatorComponent> implements IPaginatorAdapter {\n private _labelElement: HTMLElement;\n private _root: HTMLElement;\n private _pageSizeSelect: ISelectComponent;\n private _rangeLabel: HTMLElement;\n private _rangeLabelAlternative: HTMLElement;\n private _firstPageButton: HTMLButtonElement;\n private _firstPageIconButton: IIconButtonComponent;\n private _firstPagePlaceholder: Comment;\n private _previousPageButton: HTMLButtonElement;\n private _nextPageButton: HTMLButtonElement;\n private _lastPageButton: HTMLButtonElement;\n private _lastPageIconButton: IIconButtonComponent;\n private _lastPagePlaceholder: Comment;\n\n constructor(component: IPaginatorComponent) {\n super(component);\n this._labelElement = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.LABEL);\n this._root = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.ROOT);\n this._pageSizeSelect = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.PAGE_SIZE_SELECT) as ISelectComponent;\n this._rangeLabel = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.RANGE_LABEL);\n this._rangeLabelAlternative = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.RANGE_LABEL_ALTERNATIVE);\n this._firstPageButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.FIRST_PAGE_BUTTON) as HTMLButtonElement;\n this._firstPageIconButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.FIRST_PAGE_ICON_BUTTON) as IIconButtonComponent;\n this._previousPageButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.PREVIOUS_PAGE_BUTTON) as HTMLButtonElement;\n this._nextPageButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.NEXT_PAGE_BUTTON) as HTMLButtonElement;\n this._lastPageButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.LAST_PAGE_BUTTON) as HTMLButtonElement;\n this._lastPageIconButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.LAST_PAGE_ICON_BUTTON) as IIconButtonComponent;\n }\n\n public setLabel(value: string): void {\n this._labelElement.textContent = value;\n }\n\n public setPageSizeOptions(options: ISelectOption[]): void {\n removeAllChildren(this._pageSizeSelect);\n this._pageSizeSelect.options = options;\n }\n\n public setPageSize(value: number): void {\n this._pageSizeSelect.value = value.toString();\n }\n\n public setRangeLabel(value: string): void {\n this._rangeLabel.innerText = value;\n this._rangeLabelAlternative.innerText = value;\n }\n\n public hasFirstPageButton(): boolean {\n return !!getShadowElement(this._component, PAGINATOR_CONSTANTS.selectors.FIRST_PAGE_ICON_BUTTON);\n }\n\n public showFirstPageButton(): void {\n this._firstPagePlaceholder = toggleElementPlaceholder(\n this._component,\n true,\n PAGINATOR_CONSTANTS.elementName,\n PAGINATOR_CONSTANTS.selectors.FIRST_PAGE_ICON_BUTTON,\n this._firstPageIconButton,\n this._firstPagePlaceholder\n );\n }\n\n public hideFirstPageButton(): void {\n this._firstPagePlaceholder = toggleElementPlaceholder(\n this._component,\n false,\n PAGINATOR_CONSTANTS.elementName,\n PAGINATOR_CONSTANTS.selectors.FIRST_PAGE_ICON_BUTTON,\n this._firstPageIconButton,\n this._firstPagePlaceholder\n );\n }\n\n public hasLastPageButton(): boolean {\n return !!getShadowElement(this._component, PAGINATOR_CONSTANTS.selectors.LAST_PAGE_ICON_BUTTON);\n }\n\n public showLastPageButton(): void {\n this._lastPagePlaceholder = toggleElementPlaceholder(\n this._component,\n true,\n PAGINATOR_CONSTANTS.elementName,\n PAGINATOR_CONSTANTS.selectors.LAST_PAGE_ICON_BUTTON,\n this._lastPageIconButton,\n this._lastPagePlaceholder\n );\n }\n\n public hideLastPageButton(): void {\n this._lastPagePlaceholder = toggleElementPlaceholder(\n this._component,\n false,\n PAGINATOR_CONSTANTS.elementName,\n PAGINATOR_CONSTANTS.selectors.LAST_PAGE_ICON_BUTTON,\n this._lastPageIconButton,\n this._lastPagePlaceholder\n );\n }\n\n public attachPageSizeChangeListener(listener: (evt: CustomEvent) => void): void {\n this._pageSizeSelect.addEventListener('change', listener);\n }\n\n public attachFirstPageListener(listener: (evt: Event) => void): void {\n this._firstPageButton.addEventListener('click', listener);\n }\n\n public attachPreviousPageListener(listener: (evt: Event) => void): void {\n this._previousPageButton.addEventListener('click', listener);\n }\n\n public attachNextPageListener(listener: (evt: Event) => void): void {\n this._nextPageButton.addEventListener('click', listener);\n }\n\n public attachLastPageListener(listener: (evt: Event) => void): void {\n this._lastPageButton.addEventListener('click', listener);\n }\n\n public detachPageSizeChangeListener(listener: (evt: CustomEvent) => void): void {\n this._pageSizeSelect.removeEventListener('change', listener);\n }\n\n public detachFirstPageListener(listener: (evt: Event) => void): void {\n this._firstPageButton.removeEventListener('click', listener);\n }\n\n public detachPreviousPageListener(listener: (evt: Event) => void): void {\n this._previousPageButton.removeEventListener('click', listener);\n }\n\n public detachNextPageListener(listener: (evt: Event) => void): void {\n this._nextPageButton.removeEventListener('click', listener);\n }\n\n public detachLastPageListener(listener: (evt: Event) => void): void {\n this._lastPageButton.removeEventListener('click', listener);\n }\n\n public disableFirstPageButton(): void {\n this._firstPageButton.setAttribute('disabled', 'disabled');\n }\n\n public enableFirstPageButton(): void {\n this._firstPageButton.removeAttribute('disabled');\n }\n\n public disablePreviousPageButton(): void {\n this._previousPageButton.setAttribute('disabled', 'disabled');\n }\n\n public enablePreviousPageButton(): void {\n this._previousPageButton.removeAttribute('disabled');\n }\n\n public disableNextPageButton(): void {\n this._nextPageButton.setAttribute('disabled', 'disabled');\n }\n\n public enableNextPageButton(): void {\n this._nextPageButton.removeAttribute('disabled');\n }\n\n public disablePageSizeSelect(): void {\n this._pageSizeSelect.setAttribute('disabled', 'disabled');\n }\n\n public enablePageSizeSelect(): void {\n this._pageSizeSelect.removeAttribute('disabled');\n }\n\n public setPageSizeVisibility(visible: boolean): void {\n if (visible) {\n this._pageSizeSelect.style.removeProperty('display');\n } else {\n this._pageSizeSelect.style.display = 'none';\n }\n }\n\n public disableLastPageButton(): void {\n this._lastPageButton.setAttribute('disabled', 'disabled');\n }\n\n public enableLastPageButton(): void {\n this._lastPageButton.removeAttribute('disabled');\n }\n\n public setAlternative(alternative: boolean): void {\n toggleClass(this._root, alternative, PAGINATOR_CONSTANTS.classes.ALTERNATIVE);\n }\n\n public setAlignment(alignment: PaginatorAlternativeAlignment): void {\n removeClass([\n PAGINATOR_CONSTANTS.classes.ALIGNMENT_SPACE_BETWEEN,\n PAGINATOR_CONSTANTS.classes.ALIGNMENT_START,\n PAGINATOR_CONSTANTS.classes.ALIGNMENT_END\n ], this._root);\n\n switch (alignment) {\n case 'start':\n addClass(PAGINATOR_CONSTANTS.classes.ALIGNMENT_START, this._root);\n break;\n case 'end':\n addClass(PAGINATOR_CONSTANTS.classes.ALIGNMENT_END, this._root);\n break;\n case 'space-between':\n default:\n addClass(PAGINATOR_CONSTANTS.classes.ALIGNMENT_SPACE_BETWEEN, this._root);\n break;\n }\n }\n\n public handleFocusMove(from: PaginatorFieldIdentifier): void {\n if (!this._component.matches(':focus')) {\n return; // We can only move focus elsewhere within the element if the element already contains focus\n }\n\n switch (from) {\n case 'first':\n this._tryFocus([\n this._nextPageButton,\n this._lastPageButton,\n this._previousPageButton,\n this._pageSizeSelect\n ]);\n break;\n case 'last':\n this._tryFocus([\n this._previousPageButton,\n this._firstPageButton,\n this._nextPageButton,\n this._pageSizeSelect\n ]);\n break;\n case 'previous':\n this._tryFocus([\n this._nextPageButton,\n this._lastPageButton,\n this._firstPageButton,\n this._pageSizeSelect\n ]);\n break;\n case 'next':\n this._tryFocus([\n this._previousPageButton,\n this._firstPageButton,\n this._lastPageButton,\n this._pageSizeSelect\n ]);\n break;\n case 'page-size':\n this._tryFocus([\n this._nextPageButton,\n this._lastPageButton,\n this._firstPageButton,\n this._previousPageButton\n ]);\n break;\n }\n }\n\n private _tryFocus(elements: Array<HTMLButtonElement | ISelectComponent>): void {\n for (const el of elements) {\n if (el && el.isConnected && !el.disabled) {\n el.focus();\n return;\n }\n }\n }\n}\n", "import { CustomElement, attachShadowTemplate, FoundationProperty, coerceBoolean } from '@tylertech/forge-core';\nimport { tylIconFirstPage, tylIconLastPage, tylIconKeyboardArrowRight, tylIconKeyboardArrowLeft } from '@tylertech/tyler-icons/standard';\nimport { PaginatorAlternativeAlignment, PAGINATOR_CONSTANTS, IPaginatorChangeEvent } from './paginator-constants';\nimport { PaginatorFoundation } from './paginator-foundation';\nimport { PaginatorAdapter } from './paginator-adapter';\nimport { IconButtonComponent } from '../icon-button';\nimport { SelectComponent } from '../select';\nimport { IconComponent, IconRegistry } from '../icon';\nimport { BaseComponent, IBaseComponent } from '../core/base/base-component';\nimport { TooltipComponent } from '../tooltip';\n\nconst template = '<template><div class=\\\"forge-paginator\\\" part=\\\"root\\\"><div class=\\\"forge-paginator__container\\\" part=\\\"container\\\"><div class=\\\"forge-paginator__label\\\" part=\\\"label\\\"></div><forge-select class=\\\"forge-paginator__page-size-options\\\" aria-label=\\\"Choose page size\\\" density=\\\"dense\\\" part=\\\"page-size-options\\\"></forge-select><div class=\\\"forge-paginator__range-label\\\" part=\\\"range-label\\\"></div><forge-icon-button class=\\\"forge-paginator__first-page\\\" part=\\\"first-page-button\\\"><button aria-label=\\\"First Page\\\" part=\\\"first-page-button-element\\\"><forge-icon name=\\\"first_page\\\" part=\\\"first-page-icon\\\"></forge-icon></button><forge-tooltip position=\\\"top\\\">Go to the first page</forge-tooltip></forge-icon-button><forge-icon-button class=\\\"forge-paginator__previous-page\\\" part=\\\"previous-page-button\\\"><button aria-label=\\\"Previous Page\\\" part=\\\"previous-page-button-element\\\"><forge-icon name=\\\"keyboard_arrow_left\\\" part=\\\"previous-page-button-icon\\\"></forge-icon></button><forge-tooltip position=\\\"top\\\">Go to the previous page</forge-tooltip></forge-icon-button><div class=\\\"forge-paginator__range-label--alternative\\\" part=\\\"range-label-alternative\\\"></div><forge-icon-button class=\\\"forge-paginator__next-page\\\" part=\\\"next-page-button\\\"><button aria-label=\\\"Next Page\\\" part=\\\"next-page-button-element\\\"><forge-icon name=\\\"keyboard_arrow_right\\\" part=\\\"next-page-icon\\\"></forge-icon></button><forge-tooltip position=\\\"top\\\">Go to the next page</forge-tooltip></forge-icon-button><forge-icon-button class=\\\"forge-paginator__last-page\\\" part=\\\"last-page-button\\\"><button aria-label=\\\"Last Page\\\" part=\\\"last-page-button-element\\\"><forge-icon name=\\\"last_page\\\" part=\\\"last-page-icon\\\"></forge-icon></button><forge-tooltip position=\\\"top\\\">Go to the last page</forge-tooltip></forge-icon-button></div></div></template>';\nconst styles = '.forge-icon-button{display:-webkit-inline-box;display:inline-flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;border:none;outline:0;background-color:transparent;fill:currentColor;color:inherit;font-size:24px;text-decoration:none;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:48px;height:48px;padding:12px}.forge-icon-button forge-icon,.forge-icon-button img,.forge-icon-button svg{width:24px;height:24px}.forge-icon-button:disabled{color:rgba(0,0,0,.38);color:var(--mdc-theme-text-disabled-on-light,rgba(0,0,0,.38))}.forge-icon-button:disabled{cursor:default;pointer-events:none}.forge-icon-button__icon{display:inline-block}.forge-icon-button__icon.forge-icon-button__icon--on{display:none}.forge-icon-button--on .forge-icon-button__icon{display:none}.forge-icon-button--on .forge-icon-button__icon.forge-icon-button__icon--on{display:inline-block}@-webkit-keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@-webkit-keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@-webkit-keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}@keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.forge-icon-button{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:transparent;will-change:transform,opacity}.forge-icon-button::after,.forge-icon-button::before{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:\\\"\\\"}.forge-icon-button::before{-webkit-transition:opacity 15ms linear,background-color 15ms linear;transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index,1)}.forge-icon-button::after{z-index:0;z-index:var(--mdc-ripple-z-index,0)}.forge-icon-button.mdc-ripple-upgraded::before{-webkit-transform:scale(var(--mdc-ripple-fg-scale,1));transform:scale(var(--mdc-ripple-fg-scale,1))}.forge-icon-button.mdc-ripple-upgraded::after{top:0;left:0;-webkit-transform:scale(0);transform:scale(0);-webkit-transform-origin:center center;transform-origin:center center}.forge-icon-button.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top,0);left:var(--mdc-ripple-left,0)}.forge-icon-button.mdc-ripple-upgraded--foreground-activation::after{-webkit-animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards;animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.forge-icon-button.mdc-ripple-upgraded--foreground-deactivation::after{-webkit-animation:mdc-ripple-fg-opacity-out 150ms;animation:mdc-ripple-fg-opacity-out 150ms;-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}.forge-icon-button::after,.forge-icon-button::before{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.forge-icon-button.mdc-ripple-upgraded::after,.forge-icon-button.mdc-ripple-upgraded::before{top:var(--mdc-ripple-top,calc(50% - 50%));left:var(--mdc-ripple-left,calc(50% - 50%));width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.forge-icon-button.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.forge-icon-button::after,.forge-icon-button::before{background-color:#000;background-color:var(--mdc-ripple-color,var(--mdc-theme-on-surface,#000))}.forge-icon-button.mdc-ripple-surface--hover::before,.forge-icon-button:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.forge-icon-button.mdc-ripple-upgraded--background-focused::before,.forge-icon-button:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.forge-icon-button:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.forge-icon-button:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.forge-icon-button.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}forge-icon-button{position:relative;display:inline-block;overflow:visible}.forge-icon-button--on{color:#3f51b5;color:var(--mdc-theme-primary,#3f51b5)}.forge-icon-button--on::after,.forge-icon-button--on::before{background-color:#3f51b5;background-color:var(--mdc-ripple-color,var(--mdc-theme-primary,#3f51b5))}.forge-icon-button--on.mdc-ripple-surface--hover::before,.forge-icon-button--on:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.forge-icon-button--on.mdc-ripple-upgraded--background-focused::before,.forge-icon-button--on:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.forge-icon-button--on:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.forge-icon-button--on:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.forge-icon-button--on.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.forge-icon-button--on::before{background-color:#3f51b5;background-color:var(--mdc-theme-primary,#3f51b5);opacity:.08}.forge-icon-button--dense{width:28px;height:28px;padding:2px;padding:0}.forge-icon-button--dense-1{width:44px;height:44px;padding:10px}.forge-icon-button--dense-2{width:40px;height:40px;padding:8px}.forge-icon-button--dense-3{width:36px;height:36px;padding:6px}.forge-icon-button--dense-4{width:32px;height:32px;padding:4px}.forge-icon-button--dense-5{width:28px;height:28px;padding:2px}.forge-icon-button--dense-6{width:24px;height:24px;padding:0}.forge-icon-button--with-badge forge-badge{z-index:1;z-index:var(--forge-z-index-surface,1);pointer-events:none;--forge-badge-max-width:32px;--forge-badge-border:1px solid transparent}.forge-icon-button--with-badge forge-badge[app-bar-context]{--forge-badge-border:2px solid var(--forge-app-bar-theme-background)}.forge-paginator{display:inline-block}.forge-paginator--alternative{display:-webkit-box;display:flex}.forge-paginator--alternative .forge-paginator__label,.forge-paginator--alternative .forge-paginator__page-size-options,.forge-paginator--alternative .forge-paginator__range-label{display:none}.forge-paginator--alternative .forge-paginator__range-label--alternative{display:inline-block;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-body2-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.875rem;font-size:var(--mdc-typography-body2-font-size, .875rem);line-height:1.25rem;line-height:var(--mdc-typography-body2-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-body2-font-weight,400);letter-spacing:.0178571429em;letter-spacing:var(--mdc-typography-body2-letter-spacing, .0178571429em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-body2-text-decoration,inherit);text-decoration:var(--mdc-typography-body2-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-body2-text-transform,inherit);margin:0 12px}.forge-paginator__range-label--alternative{display:none}.forge-paginator__container{display:-webkit-box;display:flex;-webkit-box-align:center;align-items:center}.forge-paginator__label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.75rem;font-size:var(--mdc-typography-caption-font-size, .75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight,400);letter-spacing:.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, .0333333333em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform,inherit);margin-right:16px}.forge-paginator__page-size-options{margin-right:16px}.forge-paginator__range-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.75rem;font-size:var(--mdc-typography-caption-font-size, .75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight,400);letter-spacing:.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, .0333333333em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform,inherit);margin-right:8px}.forge-paginator__first-page,.forge-paginator__last-page,.forge-paginator__next-page,.forge-paginator__previous-page{color:rgba(0,0,0,.87);color:var(--mdc-theme-text-primary-on-background,rgba(0,0,0,.87))}:host{display:inline-block}:host([hidden]){display:none}:host([alternative]) .forge-paginator--alignment-center .forge-paginator__container{-webkit-box-pack:center;justify-content:center}:host([alternative]) .forge-paginator--alignment-center .forge-paginator__range-label--alternative{margin:0 auto}:host([alternative]) .forge-paginator--alignment-start .forge-paginator__container{-webkit-box-pack:start;justify-content:flex-start}:host([alternative]) .forge-paginator--alignment-end .forge-paginator__container{-webkit-box-pack:end;justify-content:flex-end}:host([alternative]) .forge-paginator .forge-paginator__container{-webkit-box-flex:1;flex:1}';\n\nexport interface IPaginatorComponent extends IBaseComponent {\n pageIndex: number;\n pageSize: number;\n offset: number;\n total: number;\n pageSizeOptions: number[] | boolean;\n label: string;\n firstLast: boolean;\n first: boolean;\n disabled: boolean;\n alternative: boolean;\n alignment: PaginatorAlternativeAlignment;\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'forge-paginator': IPaginatorComponent;\n }\n\n interface HTMLElementEventMap {\n 'forge-paginator-change': CustomEvent<IPaginatorChangeEvent>;\n }\n}\n\n/**\n * @tag forge-paginator\n */\n@CustomElement({\n name: PAGINATOR_CONSTANTS.elementName,\n dependencies: [\n IconButtonComponent,\n SelectComponent,\n IconComponent,\n TooltipComponent\n ]\n})\nexport class PaginatorComponent extends BaseComponent implements IPaginatorComponent {\n public static get observedAttributes(): string[] {\n return [\n PAGINATOR_CONSTANTS.attributes.PAGE_INDEX,\n PAGINATOR_CONSTANTS.attributes.PAGE_SIZE,\n PAGINATOR_CONSTANTS.attributes.OFFSET,\n PAGINATOR_CONSTANTS.attributes.TOTAL,\n PAGINATOR_CONSTANTS.attributes.PAGE_SIZE_OPTIONS,\n PAGINATOR_CONSTANTS.attributes.LABEL,\n PAGINATOR_CONSTANTS.attributes.FIRST_LAST,\n PAGINATOR_CONSTANTS.attributes.FIRST,\n PAGINATOR_CONSTANTS.attributes.DISABLED,\n PAGINATOR_CONSTANTS.attributes.ALTERNATIVE,\n PAGINATOR_CONSTANTS.attributes.ALIGNMENT\n ];\n }\n\n private _foundation: PaginatorFoundation;\n\n constructor() {\n super();\n IconRegistry.define([\n tylIconFirstPage,\n tylIconKeyboardArrowLeft,\n tylIconKeyboardArrowRight,\n tylIconLastPage\n ]);\n attachShadowTemplate(this, template, styles);\n this._foundation = new PaginatorFoundation(new PaginatorAdapter(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 PAGINATOR_CONSTANTS.attributes.PAGE_INDEX:\n this.pageIndex = Number(newValue) || PAGINATOR_CONSTANTS.numbers.DEFAULT_PAGE_INDEX;\n break;\n case PAGINATOR_CONSTANTS.attributes.PAGE_SIZE:\n this.pageSize = Number(newValue) || PAGINATOR_CONSTANTS.numbers.DEFAULT_PAGE_SIZE;\n break;\n case PAGINATOR_CONSTANTS.attributes.OFFSET:\n this.offset = Number(newValue);\n break;\n case PAGINATOR_CONSTANTS.attributes.TOTAL:\n this.total = Number(newValue) || PAGINATOR_CONSTANTS.numbers.DEFAULT_TOTAL;\n break;\n case PAGINATOR_CONSTANTS.attributes.PAGE_SIZE_OPTIONS:\n this.pageSizeOptions = newValue as any;\n break;\n case PAGINATOR_CONSTANTS.attributes.LABEL:\n this.label = newValue;\n break;\n case PAGINATOR_CONSTANTS.attributes.FIRST_LAST:\n this.firstLast = coerceBoolean(newValue);\n break;\n case PAGINATOR_CONSTANTS.attributes.FIRST:\n this.first = coerceBoolean(newValue);\n break;\n case PAGINATOR_CONSTANTS.attributes.DISABLED:\n this.disabled = coerceBoolean(newValue);\n break;\n case PAGINATOR_CONSTANTS.attributes.ALTERNATIVE:\n this.alternative = coerceBoolean(newValue);\n break;\n case PAGINATOR_CONSTANTS.attributes.ALIGNMENT:\n this.alignment = newValue as PaginatorAlternativeAlignment;\n break;\n }\n }\n\n /** The zero-based page index. Default is 0. */\n @FoundationProperty()\n public declare pageIndex: number;\n\n /** Number of items to display on a page. By default set to 25. */\n @FoundationProperty()\n public declare pageSize: number;\n\n /** Sets page index by providing the number of items to skip. The getter for this property returns the number of items to skip. */\n @FoundationProperty()\n public declare offset: number;\n\n /** The total number of items to be paginated. Default is 0. */\n @FoundationProperty()\n public declare total: number;\n\n /** The set of provided page size options to display to the user. */\n @FoundationProperty()\n public declare pageSizeOptions: number[] | boolean;\n\n /** A label for the paginator. Default is \"Rows per page:\". */\n @FoundationProperty()\n public declare label: string;\n\n /** Whether to show the first page and last page buttons. Default is false. */\n @FoundationProperty()\n public declare firstLast: boolean;\n\n /** Whether to show the first page button. Default is false. */\n @FoundationProperty()\n public declare first: boolean;\n\n /** Whether the paginator is disabled. Default is false. */\n @FoundationProperty()\n public declare disabled: boolean;\n\n @FoundationProperty()\n public declare alternative: boolean;\n\n @FoundationProperty()\n public declare alignment: PaginatorAlternativeAlignment;\n}\n", "import { defineCustomElement } from '@tylertech/forge-core';\n\nimport { PaginatorComponent } from './paginator';\n\nexport * from './paginator-adapter';\nexport * from './paginator-constants';\nexport * from './paginator-foundation';\nexport * from './paginator';\n\nexport function definePaginatorComponent(): void {\n defineCustomElement(PaginatorComponent);\n}\n"],
5
+ "mappings": "ykBAEA,IAAMA,EAA2C,GAAGC,aAE9CC,EAAU,CACd,MAAO,yBACP,kBAAmB,qCACnB,YAAa,+BACb,wBAAyB,4CACzB,kBAAmB,8BACnB,qBAAsB,iCACtB,iBAAkB,6BAClB,iBAAkB,6BAClB,KAAM,kBACN,YAAa,+BACb,gBAAiB,mCACjB,wBAAyB,oCACzB,cAAe,gCACjB,EAEMC,EAAY,CAChB,MAAO,IAAID,EAAQ,QACnB,iBAAkB,IAAIA,EAAQ,oBAC9B,YAAa,IAAIA,EAAQ,cACzB,kBAAmB,I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I,yBAIAe,EAAA,CADdC,EAAmB,GAlFThB,EAmFI,wBAIAe,EAAA,CADdC,EAAmB,GAtFThB,EAuFI,sBAIAe,EAAA,CADdC,EAAmB,GA1FThB,EA2FI,qBAIAe,EAAA,CADdC,EAAmB,GA9FThB,EA+FI,+BAIAe,EAAA,CADdC,EAAmB,GAlGThB,EAmGI,qBAIAe,EAAA,CADdC,EAAmB,GAtGThB,EAuGI,yBAIAe,EAAA,CADdC,EAAmB,GA1GThB,EA2GI,qBAIAe,EAAA,CADdC,EAAmB,GA9GThB,EA+GI,wBAGAe,EAAA,CADdC,EAAmB,GAjHThB,EAkHI,2BAGAe,EAAA,CADdC,EAAmB,GApHThB,EAqHI,yBArHJA,EAANe,EAAA,CATNE,EAAc,CACb,KAAMP,EAAoB,YAC1B,aAAc,CACZQ,EACAC,EACAC,EACAC,CACF,CACF,CAAC,GACYrB,GCzCN,SAASsB,IAAiC,CAC/CC,EAAoBC,CAAkB,CACxC",
6
+ "names": ["elementName", "COMPONENT_NAME_PREFIX", "classes", "selectors", "attributes", "events", "numbers", "strings", "PAGINATOR_CONSTANTS", "PaginatorFoundation", "_adapter", "PAGINATOR_CONSTANTS", "o", "evt", "firstPage", "prevPage", "nextPage", "lastPage", "pageSize", "type", "pageIndex", "offset", "detail", "startIndex", "pageStart", "pageEnd", "fromField", "maxPages", "value", "clampedValue", "disabled", "isDefined", "options", "isArray", "a", "b", "coerceNumber", "PaginatorAdapter", "BaseAdapter", "component", "getShadowElement", "PAGINATOR_CONSTANTS", "value", "options", "removeAllChildren", "toggleElementPlaceholder", "listener", "visible", "alternative", "toggleClass", "alignment", "removeClass", "addClass", "from", "elements", "el", "template", "styles", "PaginatorComponent", "BaseComponent", "IconRegistry", "tylIconFirstPage", "tylIconKeyboardArrowLeft", "tylIconKeyboardArrowRight", "tylIconLastPage", "attachShadowTemplate", "PaginatorFoundation", "PaginatorAdapter", "PAGINATOR_CONSTANTS", "name", "oldValue", "newValue", "coerceBoolean", "__decorateClass", "FoundationProperty", "CustomElement", "IconButtonComponent", "SelectComponent", "IconComponent", "TooltipComponent", "definePaginatorComponent", "defineCustomElement", "PaginatorComponent"]
7
+ }