@ngstarter-ui/components 1.0.21

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 (415) hide show
  1. package/README.md +0 -0
  2. package/fesm2022/ngstarter-ui-components-action-required.mjs +42 -0
  3. package/fesm2022/ngstarter-ui-components-action-required.mjs.map +1 -0
  4. package/fesm2022/ngstarter-ui-components-alert.mjs +132 -0
  5. package/fesm2022/ngstarter-ui-components-alert.mjs.map +1 -0
  6. package/fesm2022/ngstarter-ui-components-announcement.mjs +86 -0
  7. package/fesm2022/ngstarter-ui-components-announcement.mjs.map +1 -0
  8. package/fesm2022/ngstarter-ui-components-autocomplete.mjs +360 -0
  9. package/fesm2022/ngstarter-ui-components-autocomplete.mjs.map +1 -0
  10. package/fesm2022/ngstarter-ui-components-avatar.mjs +235 -0
  11. package/fesm2022/ngstarter-ui-components-avatar.mjs.map +1 -0
  12. package/fesm2022/ngstarter-ui-components-badge.mjs +97 -0
  13. package/fesm2022/ngstarter-ui-components-badge.mjs.map +1 -0
  14. package/fesm2022/ngstarter-ui-components-block-loader.mjs +48 -0
  15. package/fesm2022/ngstarter-ui-components-block-loader.mjs.map +1 -0
  16. package/fesm2022/ngstarter-ui-components-bottom-sheet.mjs +327 -0
  17. package/fesm2022/ngstarter-ui-components-bottom-sheet.mjs.map +1 -0
  18. package/fesm2022/ngstarter-ui-components-breadcrumbs.mjs +209 -0
  19. package/fesm2022/ngstarter-ui-components-breadcrumbs.mjs.map +1 -0
  20. package/fesm2022/ngstarter-ui-components-button-toggle.mjs +175 -0
  21. package/fesm2022/ngstarter-ui-components-button-toggle.mjs.map +1 -0
  22. package/fesm2022/ngstarter-ui-components-button.mjs +70 -0
  23. package/fesm2022/ngstarter-ui-components-button.mjs.map +1 -0
  24. package/fesm2022/ngstarter-ui-components-card-overlay.mjs +49 -0
  25. package/fesm2022/ngstarter-ui-components-card-overlay.mjs.map +1 -0
  26. package/fesm2022/ngstarter-ui-components-card.mjs +199 -0
  27. package/fesm2022/ngstarter-ui-components-card.mjs.map +1 -0
  28. package/fesm2022/ngstarter-ui-components-carousel.mjs +614 -0
  29. package/fesm2022/ngstarter-ui-components-carousel.mjs.map +1 -0
  30. package/fesm2022/ngstarter-ui-components-checkbox.mjs +300 -0
  31. package/fesm2022/ngstarter-ui-components-checkbox.mjs.map +1 -0
  32. package/fesm2022/ngstarter-ui-components-chips.mjs +589 -0
  33. package/fesm2022/ngstarter-ui-components-chips.mjs.map +1 -0
  34. package/fesm2022/ngstarter-ui-components-code-highlighter.mjs +347 -0
  35. package/fesm2022/ngstarter-ui-components-code-highlighter.mjs.map +1 -0
  36. package/fesm2022/ngstarter-ui-components-color-picker.mjs +713 -0
  37. package/fesm2022/ngstarter-ui-components-color-picker.mjs.map +1 -0
  38. package/fesm2022/ngstarter-ui-components-color-scheme.mjs +106 -0
  39. package/fesm2022/ngstarter-ui-components-color-scheme.mjs.map +1 -0
  40. package/fesm2022/ngstarter-ui-components-color-switcher.mjs +72 -0
  41. package/fesm2022/ngstarter-ui-components-color-switcher.mjs.map +1 -0
  42. package/fesm2022/ngstarter-ui-components-command-bar.mjs +57 -0
  43. package/fesm2022/ngstarter-ui-components-command-bar.mjs.map +1 -0
  44. package/fesm2022/ngstarter-ui-components-comment-editor.mjs +1024 -0
  45. package/fesm2022/ngstarter-ui-components-comment-editor.mjs.map +1 -0
  46. package/fesm2022/ngstarter-ui-components-comparison-slider.mjs +177 -0
  47. package/fesm2022/ngstarter-ui-components-comparison-slider.mjs.map +1 -0
  48. package/fesm2022/ngstarter-ui-components-confirm.mjs +85 -0
  49. package/fesm2022/ngstarter-ui-components-confirm.mjs.map +1 -0
  50. package/fesm2022/ngstarter-ui-components-content-editor-code-block.component-Bk6QTli8.mjs +173 -0
  51. package/fesm2022/ngstarter-ui-components-content-editor-code-block.component-Bk6QTli8.mjs.map +1 -0
  52. package/fesm2022/ngstarter-ui-components-content-editor-content-editor-content-editable.directive-Bvfa2dqh.mjs +124 -0
  53. package/fesm2022/ngstarter-ui-components-content-editor-content-editor-content-editable.directive-Bvfa2dqh.mjs.map +1 -0
  54. package/fesm2022/ngstarter-ui-components-content-editor-cursor-controller-4Ak8VqGX.mjs +99 -0
  55. package/fesm2022/ngstarter-ui-components-content-editor-cursor-controller-4Ak8VqGX.mjs.map +1 -0
  56. package/fesm2022/ngstarter-ui-components-content-editor-divider-block.component-C_iRTCPH.mjs +33 -0
  57. package/fesm2022/ngstarter-ui-components-content-editor-divider-block.component-C_iRTCPH.mjs.map +1 -0
  58. package/fesm2022/ngstarter-ui-components-content-editor-embed-block-BbkC_t86.mjs +354 -0
  59. package/fesm2022/ngstarter-ui-components-content-editor-embed-block-BbkC_t86.mjs.map +1 -0
  60. package/fesm2022/ngstarter-ui-components-content-editor-heading-block.component-D9_CxTY1.mjs +114 -0
  61. package/fesm2022/ngstarter-ui-components-content-editor-heading-block.component-D9_CxTY1.mjs.map +1 -0
  62. package/fesm2022/ngstarter-ui-components-content-editor-image-block.component-B4zJyUg1.mjs +146 -0
  63. package/fesm2022/ngstarter-ui-components-content-editor-image-block.component-B4zJyUg1.mjs.map +1 -0
  64. package/fesm2022/ngstarter-ui-components-content-editor-list-block.component-Cv6wx5Xe.mjs +215 -0
  65. package/fesm2022/ngstarter-ui-components-content-editor-list-block.component-Cv6wx5Xe.mjs.map +1 -0
  66. package/fesm2022/ngstarter-ui-components-content-editor-ngstarter-ui-components-content-editor-1Zi2nAX5.mjs +2548 -0
  67. package/fesm2022/ngstarter-ui-components-content-editor-ngstarter-ui-components-content-editor-1Zi2nAX5.mjs.map +1 -0
  68. package/fesm2022/ngstarter-ui-components-content-editor-paragraph-block.component-C9bQvDYU.mjs +110 -0
  69. package/fesm2022/ngstarter-ui-components-content-editor-paragraph-block.component-C9bQvDYU.mjs.map +1 -0
  70. package/fesm2022/ngstarter-ui-components-content-editor-quote-block.component-BbHds2r2.mjs +141 -0
  71. package/fesm2022/ngstarter-ui-components-content-editor-quote-block.component-BbHds2r2.mjs.map +1 -0
  72. package/fesm2022/ngstarter-ui-components-content-editor-table-block.component-DlDh7Fnn.mjs +1604 -0
  73. package/fesm2022/ngstarter-ui-components-content-editor-table-block.component-DlDh7Fnn.mjs.map +1 -0
  74. package/fesm2022/ngstarter-ui-components-content-editor-video-block.component-m4DTihP2.mjs +175 -0
  75. package/fesm2022/ngstarter-ui-components-content-editor-video-block.component-m4DTihP2.mjs.map +1 -0
  76. package/fesm2022/ngstarter-ui-components-content-editor.mjs +2 -0
  77. package/fesm2022/ngstarter-ui-components-content-editor.mjs.map +1 -0
  78. package/fesm2022/ngstarter-ui-components-content-fade.mjs +35 -0
  79. package/fesm2022/ngstarter-ui-components-content-fade.mjs.map +1 -0
  80. package/fesm2022/ngstarter-ui-components-cookie-popup.mjs +107 -0
  81. package/fesm2022/ngstarter-ui-components-cookie-popup.mjs.map +1 -0
  82. package/fesm2022/ngstarter-ui-components-core.mjs +1330 -0
  83. package/fesm2022/ngstarter-ui-components-core.mjs.map +1 -0
  84. package/fesm2022/ngstarter-ui-components-country-select.mjs +489 -0
  85. package/fesm2022/ngstarter-ui-components-country-select.mjs.map +1 -0
  86. package/fesm2022/ngstarter-ui-components-crop.mjs +183 -0
  87. package/fesm2022/ngstarter-ui-components-crop.mjs.map +1 -0
  88. package/fesm2022/ngstarter-ui-components-currency-select.mjs +397 -0
  89. package/fesm2022/ngstarter-ui-components-currency-select.mjs.map +1 -0
  90. package/fesm2022/ngstarter-ui-components-data-view.mjs +1494 -0
  91. package/fesm2022/ngstarter-ui-components-data-view.mjs.map +1 -0
  92. package/fesm2022/ngstarter-ui-components-date-format-select.mjs +154 -0
  93. package/fesm2022/ngstarter-ui-components-date-format-select.mjs.map +1 -0
  94. package/fesm2022/ngstarter-ui-components-datepicker.mjs +1159 -0
  95. package/fesm2022/ngstarter-ui-components-datepicker.mjs.map +1 -0
  96. package/fesm2022/ngstarter-ui-components-dialog.mjs +357 -0
  97. package/fesm2022/ngstarter-ui-components-dialog.mjs.map +1 -0
  98. package/fesm2022/ngstarter-ui-components-divider.mjs +42 -0
  99. package/fesm2022/ngstarter-ui-components-divider.mjs.map +1 -0
  100. package/fesm2022/ngstarter-ui-components-drawer.mjs +132 -0
  101. package/fesm2022/ngstarter-ui-components-drawer.mjs.map +1 -0
  102. package/fesm2022/ngstarter-ui-components-emoji-picker.mjs +245 -0
  103. package/fesm2022/ngstarter-ui-components-emoji-picker.mjs.map +1 -0
  104. package/fesm2022/ngstarter-ui-components-empty-state.mjs +75 -0
  105. package/fesm2022/ngstarter-ui-components-empty-state.mjs.map +1 -0
  106. package/fesm2022/ngstarter-ui-components-expand.mjs +56 -0
  107. package/fesm2022/ngstarter-ui-components-expand.mjs.map +1 -0
  108. package/fesm2022/ngstarter-ui-components-expansion.mjs +193 -0
  109. package/fesm2022/ngstarter-ui-components-expansion.mjs.map +1 -0
  110. package/fesm2022/ngstarter-ui-components-filter-builder.mjs +333 -0
  111. package/fesm2022/ngstarter-ui-components-filter-builder.mjs.map +1 -0
  112. package/fesm2022/ngstarter-ui-components-form-field.mjs +230 -0
  113. package/fesm2022/ngstarter-ui-components-form-field.mjs.map +1 -0
  114. package/fesm2022/ngstarter-ui-components-form-renderer-autocomplete-many-field-BKQVlZHV.mjs +124 -0
  115. package/fesm2022/ngstarter-ui-components-form-renderer-autocomplete-many-field-BKQVlZHV.mjs.map +1 -0
  116. package/fesm2022/ngstarter-ui-components-form-renderer-checkbox-field-CoyKdvhV.mjs +22 -0
  117. package/fesm2022/ngstarter-ui-components-form-renderer-checkbox-field-CoyKdvhV.mjs.map +1 -0
  118. package/fesm2022/ngstarter-ui-components-form-renderer-datepicker-field-Bzc0TPO9.mjs +44 -0
  119. package/fesm2022/ngstarter-ui-components-form-renderer-datepicker-field-Bzc0TPO9.mjs.map +1 -0
  120. package/fesm2022/ngstarter-ui-components-form-renderer-divider-content-CwGzDCZv.mjs +17 -0
  121. package/fesm2022/ngstarter-ui-components-form-renderer-divider-content-CwGzDCZv.mjs.map +1 -0
  122. package/fesm2022/ngstarter-ui-components-form-renderer-image-content-ICTwkZPa.mjs +17 -0
  123. package/fesm2022/ngstarter-ui-components-form-renderer-image-content-ICTwkZPa.mjs.map +1 -0
  124. package/fesm2022/ngstarter-ui-components-form-renderer-input-field-RYxi-Mpw.mjs +35 -0
  125. package/fesm2022/ngstarter-ui-components-form-renderer-input-field-RYxi-Mpw.mjs.map +1 -0
  126. package/fesm2022/ngstarter-ui-components-form-renderer-radio-group-field-Cv3AGpoq.mjs +38 -0
  127. package/fesm2022/ngstarter-ui-components-form-renderer-radio-group-field-Cv3AGpoq.mjs.map +1 -0
  128. package/fesm2022/ngstarter-ui-components-form-renderer-select-field-eLcwI-BY.mjs +39 -0
  129. package/fesm2022/ngstarter-ui-components-form-renderer-select-field-eLcwI-BY.mjs.map +1 -0
  130. package/fesm2022/ngstarter-ui-components-form-renderer-text-content-BjzH_M3-.mjs +24 -0
  131. package/fesm2022/ngstarter-ui-components-form-renderer-text-content-BjzH_M3-.mjs.map +1 -0
  132. package/fesm2022/ngstarter-ui-components-form-renderer-textarea-field-4zH7FTQ1.mjs +37 -0
  133. package/fesm2022/ngstarter-ui-components-form-renderer-textarea-field-4zH7FTQ1.mjs.map +1 -0
  134. package/fesm2022/ngstarter-ui-components-form-renderer-timezone-field-BpH65Hd-.mjs +35 -0
  135. package/fesm2022/ngstarter-ui-components-form-renderer-timezone-field-BpH65Hd-.mjs.map +1 -0
  136. package/fesm2022/ngstarter-ui-components-form-renderer-toggle-field-iyqUrWxt.mjs +22 -0
  137. package/fesm2022/ngstarter-ui-components-form-renderer-toggle-field-iyqUrWxt.mjs.map +1 -0
  138. package/fesm2022/ngstarter-ui-components-form-renderer.mjs +317 -0
  139. package/fesm2022/ngstarter-ui-components-form-renderer.mjs.map +1 -0
  140. package/fesm2022/ngstarter-ui-components-gauge.mjs +44 -0
  141. package/fesm2022/ngstarter-ui-components-gauge.mjs.map +1 -0
  142. package/fesm2022/ngstarter-ui-components-grid.mjs +78 -0
  143. package/fesm2022/ngstarter-ui-components-grid.mjs.map +1 -0
  144. package/fesm2022/ngstarter-ui-components-guided-tour.mjs +736 -0
  145. package/fesm2022/ngstarter-ui-components-guided-tour.mjs.map +1 -0
  146. package/fesm2022/ngstarter-ui-components-headless-stepper.mjs +192 -0
  147. package/fesm2022/ngstarter-ui-components-headless-stepper.mjs.map +1 -0
  148. package/fesm2022/ngstarter-ui-components-icon.mjs +61 -0
  149. package/fesm2022/ngstarter-ui-components-icon.mjs.map +1 -0
  150. package/fesm2022/ngstarter-ui-components-image-designer.mjs +4016 -0
  151. package/fesm2022/ngstarter-ui-components-image-designer.mjs.map +1 -0
  152. package/fesm2022/ngstarter-ui-components-image-placeholder.mjs +20 -0
  153. package/fesm2022/ngstarter-ui-components-image-placeholder.mjs.map +1 -0
  154. package/fesm2022/ngstarter-ui-components-image-resizer.mjs +151 -0
  155. package/fesm2022/ngstarter-ui-components-image-resizer.mjs.map +1 -0
  156. package/fesm2022/ngstarter-ui-components-image-viewer.mjs +349 -0
  157. package/fesm2022/ngstarter-ui-components-image-viewer.mjs.map +1 -0
  158. package/fesm2022/ngstarter-ui-components-image-zoom-viewer.mjs +162 -0
  159. package/fesm2022/ngstarter-ui-components-image-zoom-viewer.mjs.map +1 -0
  160. package/fesm2022/ngstarter-ui-components-incidents.mjs +257 -0
  161. package/fesm2022/ngstarter-ui-components-incidents.mjs.map +1 -0
  162. package/fesm2022/ngstarter-ui-components-inline-text-edit.mjs +179 -0
  163. package/fesm2022/ngstarter-ui-components-inline-text-edit.mjs.map +1 -0
  164. package/fesm2022/ngstarter-ui-components-input-mask.mjs +180 -0
  165. package/fesm2022/ngstarter-ui-components-input-mask.mjs.map +1 -0
  166. package/fesm2022/ngstarter-ui-components-input-validator.mjs +24 -0
  167. package/fesm2022/ngstarter-ui-components-input-validator.mjs.map +1 -0
  168. package/fesm2022/ngstarter-ui-components-input.mjs +152 -0
  169. package/fesm2022/ngstarter-ui-components-input.mjs.map +1 -0
  170. package/fesm2022/ngstarter-ui-components-kanban-board.mjs +156 -0
  171. package/fesm2022/ngstarter-ui-components-kanban-board.mjs.map +1 -0
  172. package/fesm2022/ngstarter-ui-components-kbd.mjs +31 -0
  173. package/fesm2022/ngstarter-ui-components-kbd.mjs.map +1 -0
  174. package/fesm2022/ngstarter-ui-components-layout.mjs +199 -0
  175. package/fesm2022/ngstarter-ui-components-layout.mjs.map +1 -0
  176. package/fesm2022/ngstarter-ui-components-list.mjs +279 -0
  177. package/fesm2022/ngstarter-ui-components-list.mjs.map +1 -0
  178. package/fesm2022/ngstarter-ui-components-logo.mjs +51 -0
  179. package/fesm2022/ngstarter-ui-components-logo.mjs.map +1 -0
  180. package/fesm2022/ngstarter-ui-components-marquee.mjs +76 -0
  181. package/fesm2022/ngstarter-ui-components-marquee.mjs.map +1 -0
  182. package/fesm2022/ngstarter-ui-components-menu.mjs +851 -0
  183. package/fesm2022/ngstarter-ui-components-menu.mjs.map +1 -0
  184. package/fesm2022/ngstarter-ui-components-micro-chart.mjs +928 -0
  185. package/fesm2022/ngstarter-ui-components-micro-chart.mjs.map +1 -0
  186. package/fesm2022/ngstarter-ui-components-navigation.mjs +439 -0
  187. package/fesm2022/ngstarter-ui-components-navigation.mjs.map +1 -0
  188. package/fesm2022/ngstarter-ui-components-notifications.mjs +181 -0
  189. package/fesm2022/ngstarter-ui-components-notifications.mjs.map +1 -0
  190. package/fesm2022/ngstarter-ui-components-number-input.mjs +293 -0
  191. package/fesm2022/ngstarter-ui-components-number-input.mjs.map +1 -0
  192. package/fesm2022/ngstarter-ui-components-option.mjs +157 -0
  193. package/fesm2022/ngstarter-ui-components-option.mjs.map +1 -0
  194. package/fesm2022/ngstarter-ui-components-overlay.mjs +112 -0
  195. package/fesm2022/ngstarter-ui-components-overlay.mjs.map +1 -0
  196. package/fesm2022/ngstarter-ui-components-page-loading-bar.mjs +77 -0
  197. package/fesm2022/ngstarter-ui-components-page-loading-bar.mjs.map +1 -0
  198. package/fesm2022/ngstarter-ui-components-paginator.mjs +297 -0
  199. package/fesm2022/ngstarter-ui-components-paginator.mjs.map +1 -0
  200. package/fesm2022/ngstarter-ui-components-panel.mjs +123 -0
  201. package/fesm2022/ngstarter-ui-components-panel.mjs.map +1 -0
  202. package/fesm2022/ngstarter-ui-components-password-strength.mjs +335 -0
  203. package/fesm2022/ngstarter-ui-components-password-strength.mjs.map +1 -0
  204. package/fesm2022/ngstarter-ui-components-phone-input.mjs +651 -0
  205. package/fesm2022/ngstarter-ui-components-phone-input.mjs.map +1 -0
  206. package/fesm2022/ngstarter-ui-components-pin-input.mjs +193 -0
  207. package/fesm2022/ngstarter-ui-components-pin-input.mjs.map +1 -0
  208. package/fesm2022/ngstarter-ui-components-popover.mjs +302 -0
  209. package/fesm2022/ngstarter-ui-components-popover.mjs.map +1 -0
  210. package/fesm2022/ngstarter-ui-components-progress-bar.mjs +68 -0
  211. package/fesm2022/ngstarter-ui-components-progress-bar.mjs.map +1 -0
  212. package/fesm2022/ngstarter-ui-components-radio-card.mjs +102 -0
  213. package/fesm2022/ngstarter-ui-components-radio-card.mjs.map +1 -0
  214. package/fesm2022/ngstarter-ui-components-radio.mjs +147 -0
  215. package/fesm2022/ngstarter-ui-components-radio.mjs.map +1 -0
  216. package/fesm2022/ngstarter-ui-components-rail-nav.mjs +87 -0
  217. package/fesm2022/ngstarter-ui-components-rail-nav.mjs.map +1 -0
  218. package/fesm2022/ngstarter-ui-components-resizable-container.mjs +74 -0
  219. package/fesm2022/ngstarter-ui-components-resizable-container.mjs.map +1 -0
  220. package/fesm2022/ngstarter-ui-components-screen-loader.mjs +95 -0
  221. package/fesm2022/ngstarter-ui-components-screen-loader.mjs.map +1 -0
  222. package/fesm2022/ngstarter-ui-components-scroll-spy.mjs +219 -0
  223. package/fesm2022/ngstarter-ui-components-scroll-spy.mjs.map +1 -0
  224. package/fesm2022/ngstarter-ui-components-scrollbar-area.mjs +459 -0
  225. package/fesm2022/ngstarter-ui-components-scrollbar-area.mjs.map +1 -0
  226. package/fesm2022/ngstarter-ui-components-segmented.mjs +218 -0
  227. package/fesm2022/ngstarter-ui-components-segmented.mjs.map +1 -0
  228. package/fesm2022/ngstarter-ui-components-select.mjs +496 -0
  229. package/fesm2022/ngstarter-ui-components-select.mjs.map +1 -0
  230. package/fesm2022/ngstarter-ui-components-side-panel.mjs +107 -0
  231. package/fesm2022/ngstarter-ui-components-side-panel.mjs.map +1 -0
  232. package/fesm2022/ngstarter-ui-components-sidebar.mjs +435 -0
  233. package/fesm2022/ngstarter-ui-components-sidebar.mjs.map +1 -0
  234. package/fesm2022/ngstarter-ui-components-sidenav.mjs +354 -0
  235. package/fesm2022/ngstarter-ui-components-sidenav.mjs.map +1 -0
  236. package/fesm2022/ngstarter-ui-components-signature-pad.mjs +452 -0
  237. package/fesm2022/ngstarter-ui-components-signature-pad.mjs.map +1 -0
  238. package/fesm2022/ngstarter-ui-components-skeleton.mjs +22 -0
  239. package/fesm2022/ngstarter-ui-components-skeleton.mjs.map +1 -0
  240. package/fesm2022/ngstarter-ui-components-slide-toggle.mjs +93 -0
  241. package/fesm2022/ngstarter-ui-components-slide-toggle.mjs.map +1 -0
  242. package/fesm2022/ngstarter-ui-components-slider.mjs +481 -0
  243. package/fesm2022/ngstarter-ui-components-slider.mjs.map +1 -0
  244. package/fesm2022/ngstarter-ui-components-snack-bar.mjs +354 -0
  245. package/fesm2022/ngstarter-ui-components-snack-bar.mjs.map +1 -0
  246. package/fesm2022/ngstarter-ui-components-sort.mjs +140 -0
  247. package/fesm2022/ngstarter-ui-components-sort.mjs.map +1 -0
  248. package/fesm2022/ngstarter-ui-components-spinner.mjs +75 -0
  249. package/fesm2022/ngstarter-ui-components-spinner.mjs.map +1 -0
  250. package/fesm2022/ngstarter-ui-components-splash-screen.mjs +93 -0
  251. package/fesm2022/ngstarter-ui-components-splash-screen.mjs.map +1 -0
  252. package/fesm2022/ngstarter-ui-components-split.mjs +948 -0
  253. package/fesm2022/ngstarter-ui-components-split.mjs.map +1 -0
  254. package/fesm2022/ngstarter-ui-components-stepper.mjs +103 -0
  255. package/fesm2022/ngstarter-ui-components-stepper.mjs.map +1 -0
  256. package/fesm2022/ngstarter-ui-components-suggestions.mjs +72 -0
  257. package/fesm2022/ngstarter-ui-components-suggestions.mjs.map +1 -0
  258. package/fesm2022/ngstarter-ui-components-tab-panel.mjs +265 -0
  259. package/fesm2022/ngstarter-ui-components-tab-panel.mjs.map +1 -0
  260. package/fesm2022/ngstarter-ui-components-table.mjs +648 -0
  261. package/fesm2022/ngstarter-ui-components-table.mjs.map +1 -0
  262. package/fesm2022/ngstarter-ui-components-tabs.mjs +591 -0
  263. package/fesm2022/ngstarter-ui-components-tabs.mjs.map +1 -0
  264. package/fesm2022/ngstarter-ui-components-text-editor.mjs +1012 -0
  265. package/fesm2022/ngstarter-ui-components-text-editor.mjs.map +1 -0
  266. package/fesm2022/ngstarter-ui-components-thumbnail-maker.mjs +212 -0
  267. package/fesm2022/ngstarter-ui-components-thumbnail-maker.mjs.map +1 -0
  268. package/fesm2022/ngstarter-ui-components-tiles.mjs +634 -0
  269. package/fesm2022/ngstarter-ui-components-tiles.mjs.map +1 -0
  270. package/fesm2022/ngstarter-ui-components-timeline.mjs +122 -0
  271. package/fesm2022/ngstarter-ui-components-timeline.mjs.map +1 -0
  272. package/fesm2022/ngstarter-ui-components-timepicker.mjs +486 -0
  273. package/fesm2022/ngstarter-ui-components-timepicker.mjs.map +1 -0
  274. package/fesm2022/ngstarter-ui-components-timezone-select.mjs +371 -0
  275. package/fesm2022/ngstarter-ui-components-timezone-select.mjs.map +1 -0
  276. package/fesm2022/ngstarter-ui-components-toolbar.mjs +299 -0
  277. package/fesm2022/ngstarter-ui-components-toolbar.mjs.map +1 -0
  278. package/fesm2022/ngstarter-ui-components-tooltip.mjs +506 -0
  279. package/fesm2022/ngstarter-ui-components-tooltip.mjs.map +1 -0
  280. package/fesm2022/ngstarter-ui-components-tree.mjs +200 -0
  281. package/fesm2022/ngstarter-ui-components-tree.mjs.map +1 -0
  282. package/fesm2022/ngstarter-ui-components-upload.mjs +330 -0
  283. package/fesm2022/ngstarter-ui-components-upload.mjs.map +1 -0
  284. package/fesm2022/ngstarter-ui-components-video-player.mjs +516 -0
  285. package/fesm2022/ngstarter-ui-components-video-player.mjs.map +1 -0
  286. package/fesm2022/ngstarter-ui-components-video-viewer.mjs +218 -0
  287. package/fesm2022/ngstarter-ui-components-video-viewer.mjs.map +1 -0
  288. package/fesm2022/ngstarter-ui-components-visual-builder.mjs +18 -0
  289. package/fesm2022/ngstarter-ui-components-visual-builder.mjs.map +1 -0
  290. package/fesm2022/ngstarter-ui-components.mjs +6 -0
  291. package/fesm2022/ngstarter-ui-components.mjs.map +1 -0
  292. package/package.json +535 -0
  293. package/styles/_common.scss +456 -0
  294. package/styles/_global.scss +91 -0
  295. package/styles/themes/default.scss +2 -0
  296. package/types/ngstarter-ui-components-action-required.d.ts +14 -0
  297. package/types/ngstarter-ui-components-alert.d.ts +50 -0
  298. package/types/ngstarter-ui-components-announcement.d.ts +59 -0
  299. package/types/ngstarter-ui-components-autocomplete.d.ts +83 -0
  300. package/types/ngstarter-ui-components-avatar.d.ts +69 -0
  301. package/types/ngstarter-ui-components-badge.d.ts +38 -0
  302. package/types/ngstarter-ui-components-block-loader.d.ts +21 -0
  303. package/types/ngstarter-ui-components-bottom-sheet.d.ts +149 -0
  304. package/types/ngstarter-ui-components-breadcrumbs.d.ts +104 -0
  305. package/types/ngstarter-ui-components-button-toggle.d.ts +54 -0
  306. package/types/ngstarter-ui-components-button.d.ts +27 -0
  307. package/types/ngstarter-ui-components-card-overlay.d.ts +20 -0
  308. package/types/ngstarter-ui-components-card.d.ts +85 -0
  309. package/types/ngstarter-ui-components-carousel.d.ts +76 -0
  310. package/types/ngstarter-ui-components-checkbox.d.ts +94 -0
  311. package/types/ngstarter-ui-components-chips.d.ts +189 -0
  312. package/types/ngstarter-ui-components-code-highlighter.d.ts +28 -0
  313. package/types/ngstarter-ui-components-color-picker.d.ts +92 -0
  314. package/types/ngstarter-ui-components-color-scheme.d.ts +44 -0
  315. package/types/ngstarter-ui-components-color-switcher.d.ts +26 -0
  316. package/types/ngstarter-ui-components-command-bar.d.ts +28 -0
  317. package/types/ngstarter-ui-components-comment-editor.d.ts +194 -0
  318. package/types/ngstarter-ui-components-comparison-slider.d.ts +42 -0
  319. package/types/ngstarter-ui-components-confirm.d.ts +34 -0
  320. package/types/ngstarter-ui-components-content-editor.d.ts +321 -0
  321. package/types/ngstarter-ui-components-content-fade.d.ts +17 -0
  322. package/types/ngstarter-ui-components-cookie-popup.d.ts +41 -0
  323. package/types/ngstarter-ui-components-core.d.ts +421 -0
  324. package/types/ngstarter-ui-components-country-select.d.ts +78 -0
  325. package/types/ngstarter-ui-components-crop.d.ts +59 -0
  326. package/types/ngstarter-ui-components-currency-select.d.ts +82 -0
  327. package/types/ngstarter-ui-components-data-view.d.ts +391 -0
  328. package/types/ngstarter-ui-components-date-format-select.d.ts +59 -0
  329. package/types/ngstarter-ui-components-datepicker.d.ts +384 -0
  330. package/types/ngstarter-ui-components-dialog.d.ts +115 -0
  331. package/types/ngstarter-ui-components-divider.d.ts +18 -0
  332. package/types/ngstarter-ui-components-drawer.d.ts +32 -0
  333. package/types/ngstarter-ui-components-emoji-picker.d.ts +49 -0
  334. package/types/ngstarter-ui-components-empty-state.d.ts +33 -0
  335. package/types/ngstarter-ui-components-expand.d.ts +26 -0
  336. package/types/ngstarter-ui-components-expansion.d.ts +68 -0
  337. package/types/ngstarter-ui-components-filter-builder.d.ts +106 -0
  338. package/types/ngstarter-ui-components-form-field.d.ts +107 -0
  339. package/types/ngstarter-ui-components-form-renderer.d.ts +121 -0
  340. package/types/ngstarter-ui-components-gauge.d.ts +21 -0
  341. package/types/ngstarter-ui-components-grid.d.ts +45 -0
  342. package/types/ngstarter-ui-components-guided-tour.d.ts +227 -0
  343. package/types/ngstarter-ui-components-headless-stepper.d.ts +65 -0
  344. package/types/ngstarter-ui-components-icon.d.ts +17 -0
  345. package/types/ngstarter-ui-components-image-designer.d.ts +357 -0
  346. package/types/ngstarter-ui-components-image-placeholder.d.ts +8 -0
  347. package/types/ngstarter-ui-components-image-resizer.d.ts +35 -0
  348. package/types/ngstarter-ui-components-image-viewer.d.ts +63 -0
  349. package/types/ngstarter-ui-components-image-zoom-viewer.d.ts +34 -0
  350. package/types/ngstarter-ui-components-incidents.d.ts +119 -0
  351. package/types/ngstarter-ui-components-inline-text-edit.d.ts +39 -0
  352. package/types/ngstarter-ui-components-input-mask.d.ts +36 -0
  353. package/types/ngstarter-ui-components-input-validator.d.ts +5 -0
  354. package/types/ngstarter-ui-components-input.d.ts +53 -0
  355. package/types/ngstarter-ui-components-kanban-board.d.ts +68 -0
  356. package/types/ngstarter-ui-components-kbd.d.ts +13 -0
  357. package/types/ngstarter-ui-components-layout.d.ts +83 -0
  358. package/types/ngstarter-ui-components-list.d.ts +98 -0
  359. package/types/ngstarter-ui-components-logo.d.ts +26 -0
  360. package/types/ngstarter-ui-components-marquee.d.ts +27 -0
  361. package/types/ngstarter-ui-components-menu.d.ts +199 -0
  362. package/types/ngstarter-ui-components-micro-chart.d.ts +195 -0
  363. package/types/ngstarter-ui-components-navigation.d.ts +136 -0
  364. package/types/ngstarter-ui-components-notifications.d.ts +84 -0
  365. package/types/ngstarter-ui-components-number-input.d.ts +99 -0
  366. package/types/ngstarter-ui-components-option.d.ts +61 -0
  367. package/types/ngstarter-ui-components-overlay.d.ts +12 -0
  368. package/types/ngstarter-ui-components-page-loading-bar.d.ts +20 -0
  369. package/types/ngstarter-ui-components-paginator.d.ts +145 -0
  370. package/types/ngstarter-ui-components-panel.d.ts +59 -0
  371. package/types/ngstarter-ui-components-password-strength.d.ts +109 -0
  372. package/types/ngstarter-ui-components-phone-input.d.ts +103 -0
  373. package/types/ngstarter-ui-components-pin-input.d.ts +48 -0
  374. package/types/ngstarter-ui-components-popover.d.ts +94 -0
  375. package/types/ngstarter-ui-components-progress-bar.d.ts +30 -0
  376. package/types/ngstarter-ui-components-radio-card.d.ts +37 -0
  377. package/types/ngstarter-ui-components-radio.d.ts +45 -0
  378. package/types/ngstarter-ui-components-rail-nav.d.ts +36 -0
  379. package/types/ngstarter-ui-components-resizable-container.d.ts +25 -0
  380. package/types/ngstarter-ui-components-screen-loader.d.ts +34 -0
  381. package/types/ngstarter-ui-components-scroll-spy.d.ts +63 -0
  382. package/types/ngstarter-ui-components-scrollbar-area.d.ts +67 -0
  383. package/types/ngstarter-ui-components-segmented.d.ts +65 -0
  384. package/types/ngstarter-ui-components-select.d.ts +126 -0
  385. package/types/ngstarter-ui-components-side-panel.d.ts +42 -0
  386. package/types/ngstarter-ui-components-sidebar.d.ts +143 -0
  387. package/types/ngstarter-ui-components-sidenav.d.ts +86 -0
  388. package/types/ngstarter-ui-components-signature-pad.d.ts +49 -0
  389. package/types/ngstarter-ui-components-skeleton.d.ts +9 -0
  390. package/types/ngstarter-ui-components-slide-toggle.d.ts +41 -0
  391. package/types/ngstarter-ui-components-slider.d.ts +85 -0
  392. package/types/ngstarter-ui-components-snack-bar.d.ts +142 -0
  393. package/types/ngstarter-ui-components-sort.d.ts +66 -0
  394. package/types/ngstarter-ui-components-spinner.d.ts +28 -0
  395. package/types/ngstarter-ui-components-splash-screen.d.ts +31 -0
  396. package/types/ngstarter-ui-components-split.d.ts +210 -0
  397. package/types/ngstarter-ui-components-stepper.d.ts +44 -0
  398. package/types/ngstarter-ui-components-suggestions.d.ts +32 -0
  399. package/types/ngstarter-ui-components-tab-panel.d.ts +96 -0
  400. package/types/ngstarter-ui-components-table.d.ts +277 -0
  401. package/types/ngstarter-ui-components-tabs.d.ts +145 -0
  402. package/types/ngstarter-ui-components-text-editor.d.ts +191 -0
  403. package/types/ngstarter-ui-components-thumbnail-maker.d.ts +35 -0
  404. package/types/ngstarter-ui-components-tiles.d.ts +109 -0
  405. package/types/ngstarter-ui-components-timeline.d.ts +57 -0
  406. package/types/ngstarter-ui-components-timepicker.d.ts +115 -0
  407. package/types/ngstarter-ui-components-timezone-select.d.ts +75 -0
  408. package/types/ngstarter-ui-components-toolbar.d.ts +74 -0
  409. package/types/ngstarter-ui-components-tooltip.d.ts +52 -0
  410. package/types/ngstarter-ui-components-tree.d.ts +60 -0
  411. package/types/ngstarter-ui-components-upload.d.ts +134 -0
  412. package/types/ngstarter-ui-components-video-player.d.ts +67 -0
  413. package/types/ngstarter-ui-components-video-viewer.d.ts +98 -0
  414. package/types/ngstarter-ui-components-visual-builder.d.ts +8 -0
  415. package/types/ngstarter-ui-components.d.ts +2 -0
@@ -0,0 +1,1330 @@
1
+ import * as i0 from '@angular/core';
2
+ import { InjectionToken, inject, PLATFORM_ID, ElementRef, input, Directive, booleanAttribute, output, DestroyRef, afterNextRender, numberAttribute, forwardRef, NgZone, model, effect, Pipe, Injectable, DOCUMENT, isDevMode, EventEmitter } from '@angular/core';
3
+ import { isPlatformBrowser, isPlatformServer } from '@angular/common';
4
+ import { FocusMonitor, isFakeMousedownFromScreenReader, isFakeTouchstartFromScreenReader } from '@angular/cdk/a11y';
5
+ import { fromEvent, filter, merge, debounceTime, Observable, Subscription } from 'rxjs';
6
+ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
7
+ import { NG_VALUE_ACCESSOR } from '@angular/forms';
8
+ import { normalizePassiveListenerOptions, _getEventTarget, Platform } from '@angular/cdk/platform';
9
+ import { coerceElement } from '@angular/cdk/coercion';
10
+ import { DomSanitizer, Title, Meta } from '@angular/platform-browser';
11
+ import { Router, NavigationEnd, TitleStrategy } from '@angular/router';
12
+ import { signalStore, withState, withMethods, patchState } from '@ngrx/signals';
13
+
14
+ const AUTOFOCUSABLE = new InjectionToken('AUTOFOCUSABLE');
15
+
16
+ class AutoFocusDirective {
17
+ platformId = inject(PLATFORM_ID);
18
+ elementRef = inject(ElementRef);
19
+ autofocusable = inject(AUTOFOCUSABLE, { optional: true });
20
+ enabled = input(true, { ...(ngDevMode ? { debugName: "enabled" } : /* istanbul ignore next */ {}), alias: 'ngsAutoFocus' });
21
+ ngOnChanges(changes) {
22
+ if (changes['enabled'] && !changes['enabled'].firstChange) {
23
+ this._focus();
24
+ }
25
+ }
26
+ ngAfterViewInit() {
27
+ this._focus();
28
+ }
29
+ _focus() {
30
+ if (this.enabled() === false || this.enabled() === 'false') {
31
+ return;
32
+ }
33
+ if (this.autofocusable) {
34
+ this.autofocusable.focus();
35
+ }
36
+ else {
37
+ this.elementRef.nativeElement.focus();
38
+ }
39
+ this._moveCursorToEnd(this.elementRef.nativeElement);
40
+ }
41
+ _moveCursorToEnd(el) {
42
+ if (!isPlatformBrowser(this.platformId)) {
43
+ return;
44
+ }
45
+ const range = document.createRange();
46
+ const sel = window.getSelection();
47
+ range.selectNodeContents(el);
48
+ range.collapse(false);
49
+ sel?.removeAllRanges();
50
+ sel?.addRange(range);
51
+ }
52
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: AutoFocusDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
53
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.4", type: AutoFocusDirective, isStandalone: true, selector: "[ngsAutoFocus]", inputs: { enabled: { classPropertyName: "enabled", publicName: "ngsAutoFocus", isSignal: true, isRequired: false, transformFunction: null } }, exportAs: ["ngsAutoFocus"], usesOnChanges: true, ngImport: i0 });
54
+ }
55
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: AutoFocusDirective, decorators: [{
56
+ type: Directive,
57
+ args: [{
58
+ selector: '[ngsAutoFocus]',
59
+ exportAs: 'ngsAutoFocus',
60
+ standalone: true
61
+ }]
62
+ }], propDecorators: { enabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngsAutoFocus", required: false }] }] } });
63
+
64
+ class FocusElementDirective {
65
+ _elementRef = inject(ElementRef);
66
+ _focusMonitor = inject(FocusMonitor);
67
+ checkChildren = input(true, { ...(ngDevMode ? { debugName: "checkChildren" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
68
+ elementFocused = output();
69
+ elementBlurred = output();
70
+ ngAfterViewInit() {
71
+ this._focusMonitor
72
+ .monitor(this._elementRef.nativeElement, this.checkChildren())
73
+ .subscribe(origin => {
74
+ this._emitFocusEvent(origin);
75
+ });
76
+ }
77
+ ngOnDestroy() {
78
+ this._focusMonitor.stopMonitoring(this._elementRef.nativeElement);
79
+ }
80
+ _emitFocusEvent(origin) {
81
+ if (origin) {
82
+ this.elementFocused.emit();
83
+ }
84
+ else {
85
+ this.elementBlurred.emit();
86
+ }
87
+ }
88
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: FocusElementDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
89
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.4", type: FocusElementDirective, isStandalone: true, selector: "[ngsFocusElement]", inputs: { checkChildren: { classPropertyName: "checkChildren", publicName: "checkChildren", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { elementFocused: "elementFocused", elementBlurred: "elementBlurred" }, exportAs: ["ngsFocusElement"], ngImport: i0 });
90
+ }
91
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: FocusElementDirective, decorators: [{
92
+ type: Directive,
93
+ args: [{
94
+ selector: '[ngsFocusElement]',
95
+ exportAs: 'ngsFocusElement',
96
+ standalone: true
97
+ }]
98
+ }], propDecorators: { checkChildren: [{ type: i0.Input, args: [{ isSignal: true, alias: "checkChildren", required: false }] }], elementFocused: [{ type: i0.Output, args: ["elementFocused"] }], elementBlurred: [{ type: i0.Output, args: ["elementBlurred"] }] } });
99
+
100
+ class SoundEffectDirective {
101
+ soundSrc = input('assets/sound-effects/mouse-click.ogg', ...(ngDevMode ? [{ debugName: "soundSrc" }] : /* istanbul ignore next */ []));
102
+ _elementRef = inject(ElementRef);
103
+ _destroyRef = inject(DestroyRef);
104
+ constructor() {
105
+ afterNextRender(() => {
106
+ this._init();
107
+ });
108
+ }
109
+ _init() {
110
+ const audio = new Audio(this.soundSrc());
111
+ audio.volume = 0.15;
112
+ fromEvent(this._elementRef.nativeElement, 'click')
113
+ .pipe(takeUntilDestroyed(this._destroyRef))
114
+ .subscribe(async (e) => {
115
+ await audio.play();
116
+ });
117
+ }
118
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: SoundEffectDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
119
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.4", type: SoundEffectDirective, isStandalone: true, selector: "[ngsSoundEffect]", inputs: { soundSrc: { classPropertyName: "soundSrc", publicName: "soundSrc", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 });
120
+ }
121
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: SoundEffectDirective, decorators: [{
122
+ type: Directive,
123
+ args: [{
124
+ selector: '[ngsSoundEffect]',
125
+ standalone: true
126
+ }]
127
+ }], ctorParameters: () => [], propDecorators: { soundSrc: [{ type: i0.Input, args: [{ isSignal: true, alias: "soundSrc", required: false }] }] } });
128
+
129
+ class DebounceTimeDirective {
130
+ elementRef;
131
+ renderer;
132
+ debounceTimer;
133
+ debounceTime = input(300, { ...(ngDevMode ? { debugName: "debounceTime" } : /* istanbul ignore next */ {}), transform: numberAttribute });
134
+ onChange = () => { };
135
+ onTouched = () => { };
136
+ constructor(elementRef, renderer) {
137
+ this.elementRef = elementRef;
138
+ this.renderer = renderer;
139
+ }
140
+ writeValue(value) {
141
+ this.renderer.setProperty(this.elementRef.nativeElement, 'value', value ?? '');
142
+ }
143
+ registerOnChange(fn) {
144
+ this.onChange = fn;
145
+ }
146
+ registerOnTouched(fn) {
147
+ this.onTouched = fn;
148
+ }
149
+ setDisabledState(isDisabled) {
150
+ this.renderer.setProperty(this.elementRef.nativeElement, 'disabled', isDisabled);
151
+ }
152
+ handleInput(event) {
153
+ clearTimeout(this.debounceTimer);
154
+ const target = event.target;
155
+ const value = target?.value ?? '';
156
+ if (!this.debounceTime()) {
157
+ this.onChange(value);
158
+ }
159
+ else {
160
+ this.debounceTimer = setTimeout(() => {
161
+ this.onChange(value);
162
+ }, this.debounceTime());
163
+ }
164
+ }
165
+ handleBlur() {
166
+ this.onTouched();
167
+ }
168
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: DebounceTimeDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive });
169
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.4", type: DebounceTimeDirective, isStandalone: true, selector: "[ngsDebounceTime][ngModel]", inputs: { debounceTime: { classPropertyName: "debounceTime", publicName: "debounceTime", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "input": "handleInput($event)", "blur": "handleBlur()" } }, providers: [
170
+ {
171
+ provide: NG_VALUE_ACCESSOR,
172
+ useExisting: forwardRef(() => DebounceTimeDirective),
173
+ multi: true,
174
+ },
175
+ ], ngImport: i0 });
176
+ }
177
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: DebounceTimeDirective, decorators: [{
178
+ type: Directive,
179
+ args: [{
180
+ selector: '[ngsDebounceTime][ngModel]',
181
+ providers: [
182
+ {
183
+ provide: NG_VALUE_ACCESSOR,
184
+ useExisting: forwardRef(() => DebounceTimeDirective),
185
+ multi: true,
186
+ },
187
+ ],
188
+ host: {
189
+ '(input)': 'handleInput($event)',
190
+ '(blur)': 'handleBlur()'
191
+ }
192
+ }]
193
+ }], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.Renderer2 }], propDecorators: { debounceTime: [{ type: i0.Input, args: [{ isSignal: true, alias: "debounceTime", required: false }] }] } });
194
+
195
+ /** Possible states for a ripple element. */
196
+ var RippleState;
197
+ (function (RippleState) {
198
+ RippleState[RippleState["FADING_IN"] = 0] = "FADING_IN";
199
+ RippleState[RippleState["VISIBLE"] = 1] = "VISIBLE";
200
+ RippleState[RippleState["FADING_OUT"] = 2] = "FADING_OUT";
201
+ RippleState[RippleState["HIDDEN"] = 3] = "HIDDEN";
202
+ })(RippleState || (RippleState = {}));
203
+ /**
204
+ * Reference to a previously launched ripple element.
205
+ */
206
+ class RippleRef {
207
+ _renderer;
208
+ element;
209
+ config;
210
+ _animationForciblyDisabledThroughCss;
211
+ /** Current state of the ripple. */
212
+ state = RippleState.HIDDEN;
213
+ constructor(_renderer,
214
+ /** Reference to the ripple HTML element. */
215
+ element,
216
+ /** Ripple configuration used for the ripple. */
217
+ config,
218
+ /* Whether animations are forcibly disabled for ripples through CSS. */
219
+ _animationForciblyDisabledThroughCss = false) {
220
+ this._renderer = _renderer;
221
+ this.element = element;
222
+ this.config = config;
223
+ this._animationForciblyDisabledThroughCss = _animationForciblyDisabledThroughCss;
224
+ }
225
+ /** Fades out the ripple element. */
226
+ fadeOut() {
227
+ this._renderer.fadeOutRipple(this);
228
+ }
229
+ }
230
+ /** Options used to bind a passive capturing event. */
231
+ const passiveCapturingEventOptions = normalizePassiveListenerOptions({
232
+ passive: true,
233
+ capture: true,
234
+ });
235
+ /** Manages events through delegation so that as few event handlers as possible are bound. */
236
+ class RippleEventManager {
237
+ _events = new Map();
238
+ /** Adds an event handler. */
239
+ addHandler(ngZone, name, element, handler) {
240
+ const handlersForEvent = this._events.get(name);
241
+ if (handlersForEvent) {
242
+ const handlersForElement = handlersForEvent.get(element);
243
+ if (handlersForElement) {
244
+ handlersForElement.add(handler);
245
+ }
246
+ else {
247
+ handlersForEvent.set(element, new Set([handler]));
248
+ }
249
+ }
250
+ else {
251
+ this._events.set(name, new Map([[element, new Set([handler])]]));
252
+ ngZone.runOutsideAngular(() => {
253
+ document.addEventListener(name, this._delegateEventHandler, passiveCapturingEventOptions);
254
+ });
255
+ }
256
+ }
257
+ /** Removes an event handler. */
258
+ removeHandler(name, element, handler) {
259
+ const handlersForEvent = this._events.get(name);
260
+ if (!handlersForEvent) {
261
+ return;
262
+ }
263
+ const handlersForElement = handlersForEvent.get(element);
264
+ if (!handlersForElement) {
265
+ return;
266
+ }
267
+ handlersForElement.delete(handler);
268
+ if (handlersForElement.size === 0) {
269
+ handlersForEvent.delete(element);
270
+ }
271
+ if (handlersForEvent.size === 0) {
272
+ this._events.delete(name);
273
+ document.removeEventListener(name, this._delegateEventHandler, passiveCapturingEventOptions);
274
+ }
275
+ }
276
+ /** Event handler that is bound and which dispatches the events to the different targets. */
277
+ _delegateEventHandler = (event) => {
278
+ const target = _getEventTarget(event);
279
+ if (target) {
280
+ this._events.get(event.type)?.forEach((handlers, element) => {
281
+ if (element === target || element.contains(target)) {
282
+ handlers.forEach(handler => handler.handleEvent(event));
283
+ }
284
+ });
285
+ }
286
+ };
287
+ }
288
+ /**
289
+ * Default ripple animation configuration for ripples without an explicit
290
+ * animation config specified.
291
+ */
292
+ const defaultRippleAnimationConfig = {
293
+ enterDuration: 225,
294
+ exitDuration: 150,
295
+ };
296
+ /**
297
+ * Timeout for ignoring mouse events. Mouse events will be temporary ignored after touch
298
+ * events to avoid synthetic mouse events.
299
+ */
300
+ const ignoreMouseEventsTimeout = 800;
301
+ /** Events that signal that the pointer is down. */
302
+ const pointerDownEvents = ['mousedown', 'touchstart'];
303
+ /** Events that signal that the pointer is up. */
304
+ const pointerUpEvents = ['mouseup', 'mouseleave', 'touchend', 'touchcancel'];
305
+ /**
306
+ * Helper service that performs DOM manipulations. Not intended to be used outside this module.
307
+ */
308
+ class RippleRenderer {
309
+ _target;
310
+ _ngZone;
311
+ _platform;
312
+ /** Element where the ripples are being added to. */
313
+ _containerElement;
314
+ /** Element which triggers the ripple elements on mouse events. */
315
+ _triggerElement = null;
316
+ /** Whether the pointer is currently down or not. */
317
+ _isPointerDown = false;
318
+ /** Map of currently active ripple references. */
319
+ _activeRipples = new Map();
320
+ /** Latest non-persistent ripple that was triggered. */
321
+ _mostRecentTransientRipple = null;
322
+ /** Time in milliseconds when the last touchstart event happened. */
323
+ _lastTouchStartEvent = null;
324
+ /** Whether pointer-up event listeners have been registered. */
325
+ _pointerUpEventsRegistered = false;
326
+ /** Cached dimensions of the ripple container. */
327
+ _containerRect = null;
328
+ static _eventManager = new RippleEventManager();
329
+ constructor(_target, _ngZone, elementOrElementRef, _platform) {
330
+ this._target = _target;
331
+ this._ngZone = _ngZone;
332
+ this._platform = _platform;
333
+ // Only do anything if we're on the browser.
334
+ if (_platform.isBrowser) {
335
+ this._containerElement = coerceElement(elementOrElementRef);
336
+ }
337
+ }
338
+ /** Fades in a ripple at the given coordinates. */
339
+ fadeInRipple(x, y, config = {}) {
340
+ const containerRect = (this._containerRect =
341
+ this._containerRect || this._containerElement.getBoundingClientRect());
342
+ const animationConfig = { ...defaultRippleAnimationConfig, ...config.animation };
343
+ if (config.centered) {
344
+ x = containerRect.left + containerRect.width / 2;
345
+ y = containerRect.top + containerRect.height / 2;
346
+ }
347
+ const radius = config.radius || distanceToFurthestCorner(x, y, containerRect);
348
+ const offsetX = x - containerRect.left;
349
+ const offsetY = y - containerRect.top;
350
+ const enterDuration = animationConfig.enterDuration;
351
+ const ripple = document.createElement('div');
352
+ ripple.classList.add('ngs-ripple-element');
353
+ ripple.style.left = `${offsetX - radius}px`;
354
+ ripple.style.top = `${offsetY - radius}px`;
355
+ ripple.style.height = `${radius * 2}px`;
356
+ ripple.style.width = `${radius * 2}px`;
357
+ if (config.color != null) {
358
+ ripple.style.backgroundColor = config.color;
359
+ }
360
+ ripple.style.transitionDuration = `${enterDuration}ms`;
361
+ this._containerElement.appendChild(ripple);
362
+ const computedStyles = window.getComputedStyle(ripple);
363
+ const userTransitionProperty = computedStyles.transitionProperty;
364
+ const userTransitionDuration = computedStyles.transitionDuration;
365
+ const animationForciblyDisabledThroughCss = userTransitionProperty === 'none' ||
366
+ userTransitionDuration === '0s' ||
367
+ userTransitionDuration === '0s, 0s' ||
368
+ (containerRect.width === 0 && containerRect.height === 0);
369
+ const rippleRef = new RippleRef(this, ripple, config, animationForciblyDisabledThroughCss);
370
+ ripple.style.transform = 'scale3d(1, 1, 1)';
371
+ rippleRef.state = RippleState.FADING_IN;
372
+ if (!config.persistent) {
373
+ this._mostRecentTransientRipple = rippleRef;
374
+ }
375
+ let eventListeners = null;
376
+ if (!animationForciblyDisabledThroughCss && (enterDuration || animationConfig.exitDuration)) {
377
+ this._ngZone.runOutsideAngular(() => {
378
+ const onTransitionEnd = () => {
379
+ if (eventListeners) {
380
+ eventListeners.fallbackTimer = null;
381
+ }
382
+ clearTimeout(fallbackTimer);
383
+ this._finishRippleTransition(rippleRef);
384
+ };
385
+ const onTransitionCancel = () => this._destroyRipple(rippleRef);
386
+ const fallbackTimer = setTimeout(onTransitionCancel, (enterDuration || 0) + 100);
387
+ ripple.addEventListener('transitionend', onTransitionEnd);
388
+ ripple.addEventListener('transitioncancel', onTransitionCancel);
389
+ eventListeners = { onTransitionEnd, onTransitionCancel, fallbackTimer };
390
+ });
391
+ }
392
+ this._activeRipples.set(rippleRef, eventListeners);
393
+ if (animationForciblyDisabledThroughCss || !enterDuration) {
394
+ this._finishRippleTransition(rippleRef);
395
+ }
396
+ return rippleRef;
397
+ }
398
+ /** Fades out a ripple reference. */
399
+ fadeOutRipple(rippleRef) {
400
+ if (rippleRef.state === RippleState.FADING_OUT || rippleRef.state === RippleState.HIDDEN) {
401
+ return;
402
+ }
403
+ const rippleEl = rippleRef.element;
404
+ const animationConfig = { ...defaultRippleAnimationConfig, ...rippleRef.config.animation };
405
+ rippleEl.style.transitionDuration = `${animationConfig.exitDuration}ms`;
406
+ rippleEl.style.opacity = '0';
407
+ rippleRef.state = RippleState.FADING_OUT;
408
+ if (rippleRef._animationForciblyDisabledThroughCss || !animationConfig.exitDuration) {
409
+ this._finishRippleTransition(rippleRef);
410
+ }
411
+ }
412
+ /** Fades out all currently active ripples. */
413
+ fadeOutAll() {
414
+ this._getActiveRipples().forEach(ripple => ripple.fadeOut());
415
+ }
416
+ /** Fades out all currently showing non-persistent ripples. */
417
+ fadeOutAllNonPersistent() {
418
+ this._getActiveRipples().forEach(ripple => {
419
+ if (!ripple.config.persistent) {
420
+ ripple.fadeOut();
421
+ }
422
+ });
423
+ }
424
+ /** Sets up the trigger event listeners */
425
+ setupTriggerEvents(elementOrElementRef) {
426
+ const element = coerceElement(elementOrElementRef);
427
+ if (!this._platform.isBrowser || !element || element === this._triggerElement) {
428
+ return;
429
+ }
430
+ this._removeTriggerEvents();
431
+ this._triggerElement = element;
432
+ pointerDownEvents.forEach(type => {
433
+ RippleRenderer._eventManager.addHandler(this._ngZone, type, element, this);
434
+ });
435
+ }
436
+ /** Handles all registered events. */
437
+ handleEvent(event) {
438
+ if (event.type === 'mousedown') {
439
+ this._onMousedown(event);
440
+ }
441
+ else if (event.type === 'touchstart') {
442
+ this._onTouchStart(event);
443
+ }
444
+ else {
445
+ this._onPointerUp();
446
+ }
447
+ if (!this._pointerUpEventsRegistered && this._triggerElement) {
448
+ this._ngZone.runOutsideAngular(() => {
449
+ pointerUpEvents.forEach(type => {
450
+ this._triggerElement.addEventListener(type, this, passiveCapturingEventOptions);
451
+ });
452
+ });
453
+ this._pointerUpEventsRegistered = true;
454
+ }
455
+ }
456
+ /** Method that will be called if the fade-in or fade-in transition completed. */
457
+ _finishRippleTransition(rippleRef) {
458
+ if (rippleRef.state === RippleState.FADING_IN) {
459
+ this._startFadeOutTransition(rippleRef);
460
+ }
461
+ else if (rippleRef.state === RippleState.FADING_OUT) {
462
+ this._destroyRipple(rippleRef);
463
+ }
464
+ }
465
+ /** Starts the fade-out transition of the given ripple. */
466
+ _startFadeOutTransition(rippleRef) {
467
+ const isMostRecentTransientRipple = rippleRef === this._mostRecentTransientRipple;
468
+ const { persistent } = rippleRef.config;
469
+ rippleRef.state = RippleState.VISIBLE;
470
+ if (!persistent && (!isMostRecentTransientRipple || !this._isPointerDown)) {
471
+ rippleRef.fadeOut();
472
+ }
473
+ }
474
+ /** Destroys the given ripple. */
475
+ _destroyRipple(rippleRef) {
476
+ const eventListeners = this._activeRipples.get(rippleRef) ?? null;
477
+ this._activeRipples.delete(rippleRef);
478
+ if (!this._activeRipples.size) {
479
+ this._containerRect = null;
480
+ }
481
+ if (rippleRef === this._mostRecentTransientRipple) {
482
+ this._mostRecentTransientRipple = null;
483
+ }
484
+ rippleRef.state = RippleState.HIDDEN;
485
+ if (eventListeners !== null) {
486
+ rippleRef.element.removeEventListener('transitionend', eventListeners.onTransitionEnd);
487
+ rippleRef.element.removeEventListener('transitioncancel', eventListeners.onTransitionCancel);
488
+ if (eventListeners.fallbackTimer !== null) {
489
+ clearTimeout(eventListeners.fallbackTimer);
490
+ }
491
+ }
492
+ rippleRef.element.remove();
493
+ }
494
+ /** Function being called whenever the trigger is being pressed using mouse. */
495
+ _onMousedown(event) {
496
+ const isFakeMousedown = isFakeMousedownFromScreenReader(event);
497
+ const isSyntheticEvent = this._lastTouchStartEvent && Date.now() < this._lastTouchStartEvent + ignoreMouseEventsTimeout;
498
+ if (!this._target.rippleDisabled && !isFakeMousedown && !isSyntheticEvent) {
499
+ this._isPointerDown = true;
500
+ this.fadeInRipple(event.clientX, event.clientY, this._target.rippleConfig);
501
+ }
502
+ }
503
+ /** Function being called whenever the trigger is being pressed using touch. */
504
+ _onTouchStart(event) {
505
+ if (!this._target.rippleDisabled && !isFakeTouchstartFromScreenReader(event)) {
506
+ this._lastTouchStartEvent = Date.now();
507
+ this._isPointerDown = true;
508
+ const touches = event.changedTouches;
509
+ if (touches) {
510
+ for (let i = 0; i < touches.length; i++) {
511
+ this.fadeInRipple(touches[i].clientX, touches[i].clientY, this._target.rippleConfig);
512
+ }
513
+ }
514
+ }
515
+ }
516
+ /** Function being called whenever the trigger is being released. */
517
+ _onPointerUp() {
518
+ if (!this._isPointerDown) {
519
+ return;
520
+ }
521
+ this._isPointerDown = false;
522
+ this._getActiveRipples().forEach(ripple => {
523
+ const isVisible = ripple.state === RippleState.VISIBLE ||
524
+ (ripple.config.terminateOnPointerUp && ripple.state === RippleState.FADING_IN);
525
+ if (!ripple.config.persistent && isVisible) {
526
+ ripple.fadeOut();
527
+ }
528
+ });
529
+ }
530
+ _getActiveRipples() {
531
+ return Array.from(this._activeRipples.keys());
532
+ }
533
+ /** Removes previously registered event listeners from the trigger element. */
534
+ _removeTriggerEvents() {
535
+ const trigger = this._triggerElement;
536
+ if (trigger) {
537
+ pointerDownEvents.forEach(type => RippleRenderer._eventManager.removeHandler(type, trigger, this));
538
+ if (this._pointerUpEventsRegistered) {
539
+ pointerUpEvents.forEach(type => trigger.removeEventListener(type, this, passiveCapturingEventOptions));
540
+ this._pointerUpEventsRegistered = false;
541
+ }
542
+ }
543
+ }
544
+ }
545
+ /** Returns the distance from the point (x, y) to the furthest corner of a rectangle. */
546
+ function distanceToFurthestCorner(x, y, rect) {
547
+ const distX = Math.max(Math.abs(x - rect.left), Math.abs(x - rect.right));
548
+ const distY = Math.max(Math.abs(y - rect.top), Math.abs(y - rect.bottom));
549
+ return Math.sqrt(distX * distX + distY * distY);
550
+ }
551
+ const RIPPLE_GLOBAL_OPTIONS = new InjectionToken('ngs-ripple-global-options');
552
+ class Ripple {
553
+ _elementRef = inject(ElementRef);
554
+ _ngZone = inject(NgZone);
555
+ _platform = inject(Platform);
556
+ _globalOptions = inject(RIPPLE_GLOBAL_OPTIONS, { optional: true }) || {};
557
+ color = input(undefined, { ...(ngDevMode ? { debugName: "color" } : /* istanbul ignore next */ {}), alias: 'ngsRippleColor' });
558
+ unbounded = input(false, { ...(ngDevMode ? { debugName: "unbounded" } : /* istanbul ignore next */ {}), alias: 'ngsRippleUnbounded', transform: booleanAttribute });
559
+ centered = model(false, { ...(ngDevMode ? { debugName: "centered" } : /* istanbul ignore next */ {}), alias: 'ngsRippleCentered' });
560
+ radius = input(0, { ...(ngDevMode ? { debugName: "radius" } : /* istanbul ignore next */ {}), alias: 'ngsRippleRadius', transform: numberAttribute });
561
+ animation = input(undefined, { ...(ngDevMode ? { debugName: "animation" } : /* istanbul ignore next */ {}), alias: 'ngsRippleAnimation' });
562
+ disabled = model(false, { ...(ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {}), alias: 'ngsRippleDisabled' });
563
+ trigger = model(undefined, { ...(ngDevMode ? { debugName: "trigger" } : /* istanbul ignore next */ {}), alias: 'ngsRippleTrigger' });
564
+ _rippleRenderer;
565
+ _isInitialized = false;
566
+ constructor() {
567
+ this._rippleRenderer = new RippleRenderer(this, this._ngZone, this._elementRef, this._platform);
568
+ effect(() => {
569
+ if (this.disabled()) {
570
+ this.fadeOutAllNonPersistent();
571
+ }
572
+ this._setupTriggerEventsIfEnabled();
573
+ });
574
+ effect(() => {
575
+ this.trigger();
576
+ this._setupTriggerEventsIfEnabled();
577
+ });
578
+ }
579
+ ngOnInit() {
580
+ this._isInitialized = true;
581
+ this._setupTriggerEventsIfEnabled();
582
+ }
583
+ ngOnDestroy() {
584
+ this._rippleRenderer._removeTriggerEvents();
585
+ }
586
+ /** Fades out all currently showing ripple elements. */
587
+ fadeOutAll() {
588
+ this._rippleRenderer.fadeOutAll();
589
+ }
590
+ /** Fades out all currently showing non-persistent ripple elements. */
591
+ fadeOutAllNonPersistent() {
592
+ this._rippleRenderer.fadeOutAllNonPersistent();
593
+ }
594
+ get rippleConfig() {
595
+ return {
596
+ centered: this.centered(),
597
+ radius: this.radius(),
598
+ color: this.color(),
599
+ animation: {
600
+ ...this._globalOptions.animation,
601
+ ...this.animation(),
602
+ },
603
+ terminateOnPointerUp: this._globalOptions.terminateOnPointerUp,
604
+ };
605
+ }
606
+ get rippleDisabled() {
607
+ return this.disabled() || !!this._globalOptions.disabled;
608
+ }
609
+ _setupTriggerEventsIfEnabled() {
610
+ if (!this.disabled() && this._isInitialized) {
611
+ this._rippleRenderer.setupTriggerEvents(this.trigger() || this._elementRef.nativeElement);
612
+ }
613
+ }
614
+ /** Launches a manual ripple at the specified coordinates or just by the ripple config. */
615
+ launch(configOrX, y = 0, config) {
616
+ if (typeof configOrX === 'number') {
617
+ return this._rippleRenderer.fadeInRipple(configOrX, y, { ...this.rippleConfig, ...config });
618
+ }
619
+ else {
620
+ return this._rippleRenderer.fadeInRipple(0, 0, { ...this.rippleConfig, ...configOrX });
621
+ }
622
+ }
623
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: Ripple, deps: [], target: i0.ɵɵFactoryTarget.Directive });
624
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.4", type: Ripple, isStandalone: true, selector: "[ngsRipple]", inputs: { color: { classPropertyName: "color", publicName: "ngsRippleColor", isSignal: true, isRequired: false, transformFunction: null }, unbounded: { classPropertyName: "unbounded", publicName: "ngsRippleUnbounded", isSignal: true, isRequired: false, transformFunction: null }, centered: { classPropertyName: "centered", publicName: "ngsRippleCentered", isSignal: true, isRequired: false, transformFunction: null }, radius: { classPropertyName: "radius", publicName: "ngsRippleRadius", isSignal: true, isRequired: false, transformFunction: null }, animation: { classPropertyName: "animation", publicName: "ngsRippleAnimation", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "ngsRippleDisabled", isSignal: true, isRequired: false, transformFunction: null }, trigger: { classPropertyName: "trigger", publicName: "ngsRippleTrigger", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { centered: "ngsRippleCenteredChange", disabled: "ngsRippleDisabledChange", trigger: "ngsRippleTriggerChange" }, host: { properties: { "class.ngs-ripple-unbounded": "unbounded()" }, classAttribute: "ngs-ripple" }, exportAs: ["ngsRipple"], ngImport: i0 });
625
+ }
626
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: Ripple, decorators: [{
627
+ type: Directive,
628
+ args: [{
629
+ selector: '[ngsRipple]',
630
+ standalone: true,
631
+ exportAs: 'ngsRipple',
632
+ host: {
633
+ 'class': 'ngs-ripple',
634
+ '[class.ngs-ripple-unbounded]': 'unbounded()',
635
+ },
636
+ }]
637
+ }], ctorParameters: () => [], propDecorators: { color: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngsRippleColor", required: false }] }], unbounded: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngsRippleUnbounded", required: false }] }], centered: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngsRippleCentered", required: false }] }, { type: i0.Output, args: ["ngsRippleCenteredChange"] }], radius: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngsRippleRadius", required: false }] }], animation: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngsRippleAnimation", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngsRippleDisabled", required: false }] }, { type: i0.Output, args: ["ngsRippleDisabledChange"] }], trigger: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngsRippleTrigger", required: false }] }, { type: i0.Output, args: ["ngsRippleTriggerChange"] }] } });
638
+
639
+ function injectElement() {
640
+ return inject(ElementRef).nativeElement;
641
+ }
642
+ function isElement(node) {
643
+ return !!node && 'nodeType' in node && node.nodeType === Node.ELEMENT_NODE;
644
+ }
645
+ function getActualTarget(event) {
646
+ return (event.target ?? event.currentTarget);
647
+ }
648
+
649
+ class TextareaAutoSize {
650
+ _textarea = injectElement();
651
+ _ngZone = inject(NgZone);
652
+ _platform = inject(Platform);
653
+ minRows = input(1, { ...(ngDevMode ? { debugName: "minRows" } : /* istanbul ignore next */ {}), transform: numberAttribute });
654
+ maxRows = input(Number.MAX_SAFE_INTEGER, { ...(ngDevMode ? { debugName: "maxRows" } : /* istanbul ignore next */ {}), transform: numberAttribute });
655
+ _resizeObserver;
656
+ ngAfterViewInit() {
657
+ if (this._platform.isBrowser) {
658
+ this.resize();
659
+ this._ngZone.runOutsideAngular(() => {
660
+ this._resizeObserver = new ResizeObserver(() => this.resize());
661
+ this._resizeObserver.observe(this._textarea);
662
+ });
663
+ }
664
+ }
665
+ ngOnDestroy() {
666
+ this._resizeObserver?.disconnect();
667
+ }
668
+ resize() {
669
+ this._textarea.style.height = 'auto';
670
+ const style = window.getComputedStyle(this._textarea);
671
+ let lineHeight = parseFloat(style.lineHeight);
672
+ if (isNaN(lineHeight)) {
673
+ lineHeight = parseFloat(style.fontSize) * 1.2;
674
+ }
675
+ const paddingTop = parseFloat(style.paddingTop) || 0;
676
+ const paddingBottom = parseFloat(style.paddingBottom) || 0;
677
+ const borderTop = parseFloat(style.borderTopWidth) || 0;
678
+ const borderBottom = parseFloat(style.borderBottomWidth) || 0;
679
+ const minHeight = this.minRows() * lineHeight + paddingTop + paddingBottom + borderTop + borderBottom;
680
+ const maxHeight = this.maxRows() * lineHeight + paddingTop + paddingBottom + borderTop + borderBottom;
681
+ this._textarea.style.height = 'auto';
682
+ const currentScrollHeight = this._textarea.scrollHeight;
683
+ let height = Math.max(minHeight, currentScrollHeight);
684
+ height = Math.min(maxHeight, height);
685
+ this._textarea.style.height = `${height}px`;
686
+ if (currentScrollHeight > maxHeight) {
687
+ this._textarea.style.overflowY = 'auto';
688
+ }
689
+ else {
690
+ this._textarea.style.overflowY = 'hidden';
691
+ }
692
+ }
693
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: TextareaAutoSize, deps: [], target: i0.ɵɵFactoryTarget.Directive });
694
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.4", type: TextareaAutoSize, isStandalone: true, selector: "textarea[ngsTextareaAutoSize]", inputs: { minRows: { classPropertyName: "minRows", publicName: "minRows", isSignal: true, isRequired: false, transformFunction: null }, maxRows: { classPropertyName: "maxRows", publicName: "maxRows", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "rows": "1" }, listeners: { "input": "resize()" }, styleAttribute: "display: block; overflow: hidden; resize: none; box-sizing: border-box;" }, exportAs: ["ngsTextareaAutoSize"], ngImport: i0 });
695
+ }
696
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: TextareaAutoSize, decorators: [{
697
+ type: Directive,
698
+ args: [{
699
+ selector: 'textarea[ngsTextareaAutoSize]',
700
+ exportAs: 'ngsTextareaAutoSize',
701
+ host: {
702
+ 'rows': '1',
703
+ '(input)': 'resize()',
704
+ 'style': 'display: block; overflow: hidden; resize: none; box-sizing: border-box;',
705
+ },
706
+ }]
707
+ }], propDecorators: { minRows: [{ type: i0.Input, args: [{ isSignal: true, alias: "minRows", required: false }] }], maxRows: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxRows", required: false }] }] } });
708
+
709
+ class InitialsPipe {
710
+ transform(value) {
711
+ if (!value) {
712
+ return '';
713
+ }
714
+ const initials = [...value.toString().matchAll(/(\p{L}{1})\p{L}+/gu)];
715
+ const result = ((initials.shift()?.[1] || '') + (initials.pop()?.[1] || '')).toUpperCase();
716
+ return result ? result : value[0];
717
+ }
718
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: InitialsPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
719
+ static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.2.4", ngImport: i0, type: InitialsPipe, isStandalone: true, name: "initials" });
720
+ }
721
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: InitialsPipe, decorators: [{
722
+ type: Pipe,
723
+ args: [{
724
+ name: 'initials',
725
+ standalone: true
726
+ }]
727
+ }] });
728
+
729
+ class FormatFileSizePipe {
730
+ transform(bytes, decimalPoint = 2) {
731
+ if (bytes == 0) {
732
+ return '0 Bytes';
733
+ }
734
+ const k = 1000;
735
+ const dm = decimalPoint || 2;
736
+ const sizes = ['Bytes', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'];
737
+ const index = Math.floor(Math.log(bytes) / Math.log(k));
738
+ return parseFloat((bytes / Math.pow(k, index)).toFixed(dm)) + ' ' + sizes[index];
739
+ }
740
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: FormatFileSizePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
741
+ static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.2.4", ngImport: i0, type: FormatFileSizePipe, isStandalone: true, name: "formatFileSize" });
742
+ }
743
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: FormatFileSizePipe, decorators: [{
744
+ type: Pipe,
745
+ args: [{
746
+ name: 'formatFileSize',
747
+ standalone: true
748
+ }]
749
+ }] });
750
+
751
+ class OrderByPipe {
752
+ transform(value, property, direction = 'asc') {
753
+ if (!Array.isArray(value)) {
754
+ throw new Error('Order By value should be an array');
755
+ }
756
+ const sorted = value.sort((a, b) => {
757
+ if (a[property] < b[property]) {
758
+ return -1;
759
+ }
760
+ else if (a[property] > b[property]) {
761
+ return 1;
762
+ }
763
+ else {
764
+ return 0;
765
+ }
766
+ });
767
+ if (direction === 'asc') {
768
+ return sorted;
769
+ }
770
+ else if (direction === 'desc') {
771
+ return sorted.reverse();
772
+ }
773
+ }
774
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OrderByPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
775
+ static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.2.4", ngImport: i0, type: OrderByPipe, isStandalone: true, name: "orderBy" });
776
+ }
777
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: OrderByPipe, decorators: [{
778
+ type: Pipe,
779
+ args: [{
780
+ name: 'orderBy',
781
+ standalone: true
782
+ }]
783
+ }] });
784
+
785
+ class SafeHtmlPipe {
786
+ _domSanitizer = inject(DomSanitizer);
787
+ transform(value) {
788
+ return this._domSanitizer.bypassSecurityTrustHtml(value);
789
+ }
790
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: SafeHtmlPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
791
+ static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.2.4", ngImport: i0, type: SafeHtmlPipe, isStandalone: true, name: "safeHtml" });
792
+ }
793
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: SafeHtmlPipe, decorators: [{
794
+ type: Pipe,
795
+ args: [{
796
+ name: 'safeHtml',
797
+ standalone: true
798
+ }]
799
+ }] });
800
+
801
+ class SafeResourceUrlPipe {
802
+ _domSanitizer = inject(DomSanitizer);
803
+ transform(value) {
804
+ return this._domSanitizer.bypassSecurityTrustResourceUrl(value);
805
+ }
806
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: SafeResourceUrlPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
807
+ static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.2.4", ngImport: i0, type: SafeResourceUrlPipe, isStandalone: true, name: "safeResourceUrl" });
808
+ }
809
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: SafeResourceUrlPipe, decorators: [{
810
+ type: Pipe,
811
+ args: [{
812
+ name: 'safeResourceUrl',
813
+ standalone: true
814
+ }]
815
+ }] });
816
+
817
+ class FilterByPropertyPipe {
818
+ getNestedValue(obj, path) {
819
+ return path.split('.').reduce((acc, part) => acc && acc[part], obj);
820
+ }
821
+ transform(items, propPath, value, strict = false) {
822
+ if (!items) {
823
+ return [];
824
+ }
825
+ if (value === undefined || typeof value === 'undefined') {
826
+ return items;
827
+ }
828
+ if (!strict && (value === null || value === '')) {
829
+ return items;
830
+ }
831
+ return items.filter(item => {
832
+ const propertyValue = this.getNestedValue(item, propPath);
833
+ return propertyValue === value;
834
+ });
835
+ }
836
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: FilterByPropertyPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
837
+ static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.2.4", ngImport: i0, type: FilterByPropertyPipe, isStandalone: true, name: "filterByProperty" });
838
+ }
839
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: FilterByPropertyPipe, decorators: [{
840
+ type: Pipe,
841
+ args: [{
842
+ name: 'filterByProperty',
843
+ }]
844
+ }] });
845
+
846
+ class SearchByPropertyPipe {
847
+ getNestedValue(obj, path) {
848
+ return path.split('.').reduce((acc, part) => acc && acc[part], obj);
849
+ }
850
+ transform(items, propPath, searchValue) {
851
+ if (!items) {
852
+ return [];
853
+ }
854
+ if (!searchValue) {
855
+ return items;
856
+ }
857
+ const lowercasedSearchValue = searchValue.toLowerCase();
858
+ return items.filter(item => {
859
+ const propertyValue = this.getNestedValue(item, propPath);
860
+ if (typeof propertyValue === 'string') {
861
+ return propertyValue.toLowerCase().includes(lowercasedSearchValue);
862
+ }
863
+ return false;
864
+ });
865
+ }
866
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: SearchByPropertyPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
867
+ static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.2.4", ngImport: i0, type: SearchByPropertyPipe, isStandalone: true, name: "searchByProperty" });
868
+ }
869
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: SearchByPropertyPipe, decorators: [{
870
+ type: Pipe,
871
+ args: [{
872
+ name: 'searchByProperty',
873
+ }]
874
+ }] });
875
+
876
+ const ENVIRONMENT = new InjectionToken('ENVIRONMENT');
877
+ class EnvironmentService {
878
+ _environment = inject(ENVIRONMENT, {
879
+ optional: true
880
+ }) || {};
881
+ getValue(key, defaultValue) {
882
+ return this._environment[key] || defaultValue;
883
+ }
884
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: EnvironmentService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
885
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: EnvironmentService, providedIn: 'root' });
886
+ }
887
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: EnvironmentService, decorators: [{
888
+ type: Injectable,
889
+ args: [{
890
+ providedIn: 'root'
891
+ }]
892
+ }] });
893
+
894
+ class AnalyticsService {
895
+ _platformId = inject(PLATFORM_ID);
896
+ _router = inject(Router);
897
+ _document = inject(DOCUMENT);
898
+ _environmentService = inject(EnvironmentService);
899
+ trackPageViews() {
900
+ const googleAnalyticsId = this._environmentService.getValue('googleAnalyticsId');
901
+ if (isDevMode() || !googleAnalyticsId) {
902
+ return;
903
+ }
904
+ try {
905
+ const url = 'https://www.googletagmanager.com/gtag/js?id=';
906
+ const gTagScript = this._document.createElement('script');
907
+ gTagScript.async = true;
908
+ gTagScript.src = `${url}${googleAnalyticsId}`;
909
+ this._document.head.appendChild(gTagScript);
910
+ const dataLayerScript = this._document.createElement('script');
911
+ dataLayerScript.innerHTML = `
912
+ window.dataLayer = window.dataLayer || [];
913
+ function gtag(){dataLayer.push(arguments);}
914
+ gtag('js', new Date());
915
+ gtag('config', '${googleAnalyticsId}');`;
916
+ this._document.head.appendChild(dataLayerScript);
917
+ if (isPlatformServer(this._platformId)) {
918
+ return;
919
+ }
920
+ this._router.events.pipe(filter((event) => event instanceof NavigationEnd)).subscribe((event) => {
921
+ gtag('event', 'page_view', {
922
+ page_title: this._document.head.title,
923
+ page_path: event.urlAfterRedirects,
924
+ page_location: this._document.location.href
925
+ });
926
+ });
927
+ }
928
+ catch (e) {
929
+ }
930
+ }
931
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: AnalyticsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
932
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: AnalyticsService, providedIn: 'root' });
933
+ }
934
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: AnalyticsService, decorators: [{
935
+ type: Injectable,
936
+ args: [{
937
+ providedIn: 'root'
938
+ }]
939
+ }] });
940
+
941
+ class InactivityTrackerService {
942
+ _destroyRef = inject(DestroyRef);
943
+ _document = inject(DOCUMENT);
944
+ _interval = 10000 * 60; // 5 minutes
945
+ _timeout;
946
+ _interactionEvents$ = merge(fromEvent(this._document, 'click'), fromEvent(this._document, 'keydown'), fromEvent(this._document, 'mousemove'), fromEvent(this._document, 'scroll')).pipe(debounceTime(250));
947
+ _noInteraction = new EventEmitter();
948
+ setupInactivityTimer(interval) {
949
+ if (interval) {
950
+ this._interval = interval;
951
+ }
952
+ this._setupTimer();
953
+ this._interactionEvents$.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(() => {
954
+ this._setupTimer();
955
+ });
956
+ return this._noInteraction.pipe(takeUntilDestroyed(this._destroyRef));
957
+ }
958
+ reset() {
959
+ this._setupTimer();
960
+ }
961
+ _setupTimer() {
962
+ clearTimeout(this._timeout);
963
+ this._timeout = setTimeout(() => {
964
+ this._noInteraction.emit();
965
+ }, this._interval);
966
+ }
967
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: InactivityTrackerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
968
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: InactivityTrackerService, providedIn: 'root' });
969
+ }
970
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: InactivityTrackerService, decorators: [{
971
+ type: Injectable,
972
+ args: [{
973
+ providedIn: 'root'
974
+ }]
975
+ }] });
976
+
977
+ const initialGlobalState = {
978
+ screenLoading: true,
979
+ sidebarHidden: false,
980
+ pageTitle: ''
981
+ };
982
+ const GlobalStore = signalStore({ providedIn: 'root' }, withState(initialGlobalState), withMethods((store) => ({
983
+ setScreenLoading(isLoading) {
984
+ patchState(store, {
985
+ screenLoading: isLoading
986
+ });
987
+ },
988
+ setPageTitle(pageTitle) {
989
+ patchState(store, {
990
+ pageTitle
991
+ });
992
+ }
993
+ })));
994
+
995
+ class PageTitleStrategyService extends TitleStrategy {
996
+ _title = inject(Title);
997
+ _globalStore = inject(GlobalStore);
998
+ updateTitle(routerState) {
999
+ const title = this.buildTitle(routerState);
1000
+ if (title !== undefined) {
1001
+ this._title.setTitle(`${title} | ${this._globalStore.pageTitle()}`);
1002
+ }
1003
+ else {
1004
+ this._title.setTitle(this._globalStore.pageTitle());
1005
+ }
1006
+ }
1007
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: PageTitleStrategyService, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
1008
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: PageTitleStrategyService, providedIn: 'root' });
1009
+ }
1010
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: PageTitleStrategyService, decorators: [{
1011
+ type: Injectable,
1012
+ args: [{
1013
+ providedIn: 'root'
1014
+ }]
1015
+ }] });
1016
+
1017
+ class ScreenLoaderService {
1018
+ _globalStore = inject(GlobalStore);
1019
+ show() {
1020
+ this._globalStore.setScreenLoading(true);
1021
+ }
1022
+ hide() {
1023
+ this._globalStore.setScreenLoading(false);
1024
+ }
1025
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ScreenLoaderService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1026
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ScreenLoaderService, providedIn: 'root' });
1027
+ }
1028
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ScreenLoaderService, decorators: [{
1029
+ type: Injectable,
1030
+ args: [{
1031
+ providedIn: 'root'
1032
+ }]
1033
+ }] });
1034
+
1035
+ class SeoService {
1036
+ _router = inject(Router);
1037
+ _destroyRef = inject(DestroyRef);
1038
+ _document = inject(DOCUMENT);
1039
+ _platformId = inject(PLATFORM_ID);
1040
+ _linkCanonical;
1041
+ _title = inject(Title);
1042
+ _meta = inject(Meta);
1043
+ _globalStore = inject(GlobalStore);
1044
+ get meta() {
1045
+ return this._meta;
1046
+ }
1047
+ updateDescription(content) {
1048
+ if (!content) {
1049
+ return;
1050
+ }
1051
+ this.meta.updateTag({
1052
+ name: 'description',
1053
+ content
1054
+ });
1055
+ this.meta.updateTag({
1056
+ name: 'og:description',
1057
+ content
1058
+ });
1059
+ }
1060
+ updateOgUrl(content) {
1061
+ if (!content) {
1062
+ return;
1063
+ }
1064
+ this.meta.updateTag({
1065
+ name: 'og:url',
1066
+ content
1067
+ });
1068
+ }
1069
+ updateOgImage(content) {
1070
+ if (!content) {
1071
+ return;
1072
+ }
1073
+ this.meta.updateTag({
1074
+ name: 'og:image',
1075
+ content
1076
+ });
1077
+ }
1078
+ trackCanonicalChanges(siteUrl) {
1079
+ this._createCanonicalTag(siteUrl);
1080
+ if (isPlatformServer(this._platformId)) {
1081
+ return;
1082
+ }
1083
+ this._router.events
1084
+ .pipe(filter((event) => event instanceof NavigationEnd), takeUntilDestroyed(this._destroyRef))
1085
+ .subscribe(() => {
1086
+ const href = this.getCanonicalUrl(siteUrl);
1087
+ this._linkCanonical?.setAttribute('href', href);
1088
+ this.updateOgUrl(href);
1089
+ });
1090
+ }
1091
+ updateTitle(title) {
1092
+ this._title.setTitle(`${title} | ${this._globalStore.pageTitle()}`);
1093
+ this.meta.updateTag({
1094
+ name: 'og:title',
1095
+ content: title
1096
+ });
1097
+ }
1098
+ getCanonicalUrl(siteUrl) {
1099
+ if (this._document.URL.startsWith('http')) {
1100
+ return this._document.URL;
1101
+ }
1102
+ return siteUrl + this._document.URL;
1103
+ }
1104
+ _createCanonicalTag(siteUrl) {
1105
+ this._linkCanonical = this._document.querySelector('link[rel="canonical"]');
1106
+ if (!this._linkCanonical) {
1107
+ this._linkCanonical = this._document.createElement('link');
1108
+ this._linkCanonical.setAttribute('rel', 'canonical');
1109
+ this._document.head.appendChild(this._linkCanonical);
1110
+ }
1111
+ this._linkCanonical.setAttribute('href', this.getCanonicalUrl(siteUrl));
1112
+ }
1113
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: SeoService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1114
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: SeoService, providedIn: 'root' });
1115
+ }
1116
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: SeoService, decorators: [{
1117
+ type: Injectable,
1118
+ args: [{
1119
+ providedIn: 'root'
1120
+ }]
1121
+ }] });
1122
+
1123
+ const LOCAL_STORAGE_KEY = 'ngs-admin';
1124
+ class ThemeManagerService {
1125
+ _document = inject(DOCUMENT);
1126
+ _window = this._document.defaultView;
1127
+ _colorScheme;
1128
+ constructor() {
1129
+ afterNextRender(() => {
1130
+ if (this._window !== null && this._window.matchMedia) {
1131
+ this._window
1132
+ .matchMedia('(prefers-color-scheme: dark)')
1133
+ .addEventListener('change', () => {
1134
+ const storedColorScheme = this._getStoredColorScheme();
1135
+ if (storedColorScheme !== 'light' && storedColorScheme !== 'dark') {
1136
+ this.setColorScheme(this.getPreferredColorScheme());
1137
+ }
1138
+ });
1139
+ }
1140
+ });
1141
+ }
1142
+ getColorScheme() {
1143
+ return this._colorScheme;
1144
+ }
1145
+ toggleColorScheme() {
1146
+ if (this._getStoredColorScheme() === 'dark') {
1147
+ this.changeColorScheme('light');
1148
+ }
1149
+ else {
1150
+ this.changeColorScheme('dark');
1151
+ }
1152
+ }
1153
+ changeColorScheme(colorScheme) {
1154
+ this._colorScheme = colorScheme;
1155
+ this._setStoredColorScheme(colorScheme);
1156
+ this.setColorScheme(colorScheme);
1157
+ }
1158
+ _getStoredColorScheme() {
1159
+ if (typeof localStorage === 'undefined') {
1160
+ return;
1161
+ }
1162
+ return JSON.parse(localStorage.getItem(LOCAL_STORAGE_KEY) ?? '{}').colorScheme;
1163
+ }
1164
+ ;
1165
+ _setStoredColorScheme(colorScheme) {
1166
+ if (typeof localStorage === 'undefined') {
1167
+ return;
1168
+ }
1169
+ const meta = JSON.parse(localStorage.getItem(LOCAL_STORAGE_KEY) ?? '{}');
1170
+ meta.colorScheme = colorScheme;
1171
+ localStorage.setItem(LOCAL_STORAGE_KEY, JSON.stringify(meta));
1172
+ }
1173
+ ;
1174
+ getPreferredColorScheme() {
1175
+ const storedTheme = this._getStoredColorScheme();
1176
+ if (storedTheme) {
1177
+ return storedTheme;
1178
+ }
1179
+ if (this._window !== null && this._window.matchMedia) {
1180
+ return this._window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light';
1181
+ }
1182
+ return 'light';
1183
+ }
1184
+ ;
1185
+ setColorScheme(colorScheme) {
1186
+ if (this._window !== null && this._window.matchMedia) {
1187
+ if (colorScheme === 'auto' &&
1188
+ this._window.matchMedia('(prefers-color-scheme: dark)').matches) {
1189
+ this._colorScheme = 'dark';
1190
+ this._document.documentElement.classList.add('dark');
1191
+ }
1192
+ else {
1193
+ if (colorScheme === 'dark') {
1194
+ this._colorScheme = 'dark';
1195
+ this._document.documentElement.classList.add('dark');
1196
+ }
1197
+ else {
1198
+ this._colorScheme = 'light';
1199
+ this._document.documentElement.classList.remove('dark');
1200
+ }
1201
+ }
1202
+ }
1203
+ }
1204
+ ;
1205
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ThemeManagerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1206
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ThemeManagerService, providedIn: 'root' });
1207
+ }
1208
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ThemeManagerService, decorators: [{
1209
+ type: Injectable,
1210
+ args: [{
1211
+ providedIn: 'root'
1212
+ }]
1213
+ }], ctorParameters: () => [] });
1214
+
1215
+ class ResizeObserverService {
1216
+ ngZone;
1217
+ constructor(ngZone) {
1218
+ this.ngZone = ngZone;
1219
+ }
1220
+ observe(element) {
1221
+ return new Observable(observer => {
1222
+ const resizeObserver = new ResizeObserver(entries => {
1223
+ this.ngZone.run(() => {
1224
+ observer.next(entries);
1225
+ });
1226
+ });
1227
+ resizeObserver.observe(element);
1228
+ return () => {
1229
+ resizeObserver.disconnect();
1230
+ };
1231
+ });
1232
+ }
1233
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ResizeObserverService, deps: [{ token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable });
1234
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ResizeObserverService, providedIn: 'root' });
1235
+ }
1236
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ResizeObserverService, decorators: [{
1237
+ type: Injectable,
1238
+ args: [{
1239
+ providedIn: 'root',
1240
+ }]
1241
+ }], ctorParameters: () => [{ type: i0.NgZone }] });
1242
+
1243
+ class MutationObserverService {
1244
+ ngZone;
1245
+ constructor(ngZone) {
1246
+ this.ngZone = ngZone;
1247
+ }
1248
+ observe(element, options) {
1249
+ return new Observable(observer => {
1250
+ const mutationObserver = new MutationObserver(mutations => {
1251
+ this.ngZone.run(() => {
1252
+ observer.next(mutations);
1253
+ });
1254
+ });
1255
+ mutationObserver.observe(element, options);
1256
+ return () => {
1257
+ mutationObserver.disconnect();
1258
+ };
1259
+ });
1260
+ }
1261
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: MutationObserverService, deps: [{ token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable });
1262
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: MutationObserverService, providedIn: 'root' });
1263
+ }
1264
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: MutationObserverService, decorators: [{
1265
+ type: Injectable,
1266
+ args: [{
1267
+ providedIn: 'root',
1268
+ }]
1269
+ }], ctorParameters: () => [{ type: i0.NgZone }] });
1270
+
1271
+ /** Provider for managing the error state of a form control. */
1272
+ class ErrorStateMatcher {
1273
+ /**
1274
+ * Whether a control should be in an error state.
1275
+ * @param control The form control to check.
1276
+ * @param form The parent form that contains the control.
1277
+ * @returns Whether the control should be in an error state.
1278
+ */
1279
+ isErrorState(control, form) {
1280
+ return !!(control && control.invalid && (control.touched || (form && form.submitted)));
1281
+ }
1282
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ErrorStateMatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1283
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ErrorStateMatcher, providedIn: 'root' });
1284
+ }
1285
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ErrorStateMatcher, decorators: [{
1286
+ type: Injectable,
1287
+ args: [{ providedIn: 'root' }]
1288
+ }] });
1289
+ /** Error state matcher that displays an error when a control is dirty and invalid. */
1290
+ class ShowOnDirtyErrorStateMatcher {
1291
+ isErrorState(control, form) {
1292
+ return !!(control && control.invalid && (control.dirty || (form && form.submitted)));
1293
+ }
1294
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ShowOnDirtyErrorStateMatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1295
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ShowOnDirtyErrorStateMatcher });
1296
+ }
1297
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.4", ngImport: i0, type: ShowOnDirtyErrorStateMatcher, decorators: [{
1298
+ type: Injectable
1299
+ }] });
1300
+
1301
+ function px(value) {
1302
+ return `${value}px`;
1303
+ }
1304
+ function arrayShallowEquals(a, b) {
1305
+ return a.length === b.length && a.every((item, index) => item === b[index]);
1306
+ }
1307
+
1308
+ function zonefreeScheduler() {
1309
+ const zone = inject(NgZone);
1310
+ return {
1311
+ now: () => Date.now(),
1312
+ schedule: (work, delay, state) => {
1313
+ return zone.runOutsideAngular(() => {
1314
+ const id = setTimeout(() => work(state), delay);
1315
+ return new Subscription(() => clearTimeout(id));
1316
+ });
1317
+ },
1318
+ };
1319
+ }
1320
+
1321
+ function typedFromEvent(target, event, options) {
1322
+ return fromEvent(target, event, options);
1323
+ }
1324
+
1325
+ /**
1326
+ * Generated bundle index. Do not edit.
1327
+ */
1328
+
1329
+ export { AUTOFOCUSABLE, AnalyticsService, AutoFocusDirective, DebounceTimeDirective, ENVIRONMENT, EnvironmentService, ErrorStateMatcher, FilterByPropertyPipe, FocusElementDirective, FormatFileSizePipe, GlobalStore, InactivityTrackerService, InitialsPipe, MutationObserverService, OrderByPipe, PageTitleStrategyService, RIPPLE_GLOBAL_OPTIONS, ResizeObserverService, Ripple, RippleRef, RippleRenderer, RippleState, SafeHtmlPipe, SafeResourceUrlPipe, ScreenLoaderService, SearchByPropertyPipe, SeoService, ShowOnDirtyErrorStateMatcher, SoundEffectDirective, TextareaAutoSize, ThemeManagerService, arrayShallowEquals, defaultRippleAnimationConfig, getActualTarget, injectElement, isElement, px, typedFromEvent, zonefreeScheduler };
1330
+ //# sourceMappingURL=ngstarter-ui-components-core.mjs.map