@fragiola/primitives-angular 0.0.0-stage → 0.1.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 (290) hide show
  1. package/CHANGELOG.md +67 -0
  2. package/LICENSE +21 -0
  3. package/README.md +54 -2
  4. package/fesm2022/fragiola-primitives-angular-accordion.mjs +567 -0
  5. package/fesm2022/fragiola-primitives-angular-accordion.mjs.map +1 -0
  6. package/fesm2022/fragiola-primitives-angular-alert-dialog.mjs +562 -0
  7. package/fesm2022/fragiola-primitives-angular-alert-dialog.mjs.map +1 -0
  8. package/fesm2022/fragiola-primitives-angular-aspect-ratio.mjs +79 -0
  9. package/fesm2022/fragiola-primitives-angular-aspect-ratio.mjs.map +1 -0
  10. package/fesm2022/fragiola-primitives-angular-async-list.mjs +44 -0
  11. package/fesm2022/fragiola-primitives-angular-async-list.mjs.map +1 -0
  12. package/fesm2022/fragiola-primitives-angular-autocomplete-virtual.mjs +243 -0
  13. package/fesm2022/fragiola-primitives-angular-autocomplete-virtual.mjs.map +1 -0
  14. package/fesm2022/fragiola-primitives-angular-autocomplete.mjs +1751 -0
  15. package/fesm2022/fragiola-primitives-angular-autocomplete.mjs.map +1 -0
  16. package/fesm2022/fragiola-primitives-angular-avatar.mjs +308 -0
  17. package/fesm2022/fragiola-primitives-angular-avatar.mjs.map +1 -0
  18. package/fesm2022/fragiola-primitives-angular-breadcrumbs.mjs +355 -0
  19. package/fesm2022/fragiola-primitives-angular-breadcrumbs.mjs.map +1 -0
  20. package/fesm2022/fragiola-primitives-angular-button.mjs +156 -0
  21. package/fesm2022/fragiola-primitives-angular-button.mjs.map +1 -0
  22. package/fesm2022/fragiola-primitives-angular-calendar-preset.mjs +126 -0
  23. package/fesm2022/fragiola-primitives-angular-calendar-preset.mjs.map +1 -0
  24. package/fesm2022/fragiola-primitives-angular-calendar-view.mjs +289 -0
  25. package/fesm2022/fragiola-primitives-angular-calendar-view.mjs.map +1 -0
  26. package/fesm2022/fragiola-primitives-angular-calendar.mjs +1222 -0
  27. package/fesm2022/fragiola-primitives-angular-calendar.mjs.map +1 -0
  28. package/fesm2022/fragiola-primitives-angular-carousel.mjs +1031 -0
  29. package/fesm2022/fragiola-primitives-angular-carousel.mjs.map +1 -0
  30. package/fesm2022/fragiola-primitives-angular-cascade-select.mjs +1391 -0
  31. package/fesm2022/fragiola-primitives-angular-cascade-select.mjs.map +1 -0
  32. package/fesm2022/fragiola-primitives-angular-checkbox-group.mjs +221 -0
  33. package/fesm2022/fragiola-primitives-angular-checkbox-group.mjs.map +1 -0
  34. package/fesm2022/fragiola-primitives-angular-checkbox.mjs +474 -0
  35. package/fesm2022/fragiola-primitives-angular-checkbox.mjs.map +1 -0
  36. package/fesm2022/fragiola-primitives-angular-clipboard.mjs +389 -0
  37. package/fesm2022/fragiola-primitives-angular-clipboard.mjs.map +1 -0
  38. package/fesm2022/fragiola-primitives-angular-collapsible.mjs +314 -0
  39. package/fesm2022/fragiola-primitives-angular-collapsible.mjs.map +1 -0
  40. package/fesm2022/fragiola-primitives-angular-color-area.mjs +609 -0
  41. package/fesm2022/fragiola-primitives-angular-color-area.mjs.map +1 -0
  42. package/fesm2022/fragiola-primitives-angular-color-field.mjs +675 -0
  43. package/fesm2022/fragiola-primitives-angular-color-field.mjs.map +1 -0
  44. package/fesm2022/fragiola-primitives-angular-color-picker-popover.mjs +572 -0
  45. package/fesm2022/fragiola-primitives-angular-color-picker-popover.mjs.map +1 -0
  46. package/fesm2022/fragiola-primitives-angular-color-picker.mjs +528 -0
  47. package/fesm2022/fragiola-primitives-angular-color-picker.mjs.map +1 -0
  48. package/fesm2022/fragiola-primitives-angular-color-slider.mjs +868 -0
  49. package/fesm2022/fragiola-primitives-angular-color-slider.mjs.map +1 -0
  50. package/fesm2022/fragiola-primitives-angular-color-swatch-picker.mjs +503 -0
  51. package/fesm2022/fragiola-primitives-angular-color-swatch-picker.mjs.map +1 -0
  52. package/fesm2022/fragiola-primitives-angular-color-swatch.mjs +141 -0
  53. package/fesm2022/fragiola-primitives-angular-color-swatch.mjs.map +1 -0
  54. package/fesm2022/fragiola-primitives-angular-color-wheel.mjs +554 -0
  55. package/fesm2022/fragiola-primitives-angular-color-wheel.mjs.map +1 -0
  56. package/fesm2022/fragiola-primitives-angular-combobox-virtual.mjs +247 -0
  57. package/fesm2022/fragiola-primitives-angular-combobox-virtual.mjs.map +1 -0
  58. package/fesm2022/fragiola-primitives-angular-combobox.mjs +2083 -0
  59. package/fesm2022/fragiola-primitives-angular-combobox.mjs.map +1 -0
  60. package/fesm2022/fragiola-primitives-angular-command-virtual.mjs +263 -0
  61. package/fesm2022/fragiola-primitives-angular-command-virtual.mjs.map +1 -0
  62. package/fesm2022/fragiola-primitives-angular-command.mjs +977 -0
  63. package/fesm2022/fragiola-primitives-angular-command.mjs.map +1 -0
  64. package/fesm2022/fragiola-primitives-angular-context-menu.mjs +1012 -0
  65. package/fesm2022/fragiola-primitives-angular-context-menu.mjs.map +1 -0
  66. package/fesm2022/fragiola-primitives-angular-date-field.mjs +1030 -0
  67. package/fesm2022/fragiola-primitives-angular-date-field.mjs.map +1 -0
  68. package/fesm2022/fragiola-primitives-angular-date-picker-input.mjs +511 -0
  69. package/fesm2022/fragiola-primitives-angular-date-picker-input.mjs.map +1 -0
  70. package/fesm2022/fragiola-primitives-angular-date-picker.mjs +991 -0
  71. package/fesm2022/fragiola-primitives-angular-date-picker.mjs.map +1 -0
  72. package/fesm2022/fragiola-primitives-angular-date-range-field.mjs +847 -0
  73. package/fesm2022/fragiola-primitives-angular-date-range-field.mjs.map +1 -0
  74. package/fesm2022/fragiola-primitives-angular-date-range-picker-input.mjs +260 -0
  75. package/fesm2022/fragiola-primitives-angular-date-range-picker-input.mjs.map +1 -0
  76. package/fesm2022/fragiola-primitives-angular-date-range-picker.mjs +128 -0
  77. package/fesm2022/fragiola-primitives-angular-date-range-picker.mjs.map +1 -0
  78. package/fesm2022/fragiola-primitives-angular-dialog.mjs +1076 -0
  79. package/fesm2022/fragiola-primitives-angular-dialog.mjs.map +1 -0
  80. package/fesm2022/fragiola-primitives-angular-direction.mjs +82 -0
  81. package/fesm2022/fragiola-primitives-angular-direction.mjs.map +1 -0
  82. package/fesm2022/fragiola-primitives-angular-drawer.mjs +890 -0
  83. package/fesm2022/fragiola-primitives-angular-drawer.mjs.map +1 -0
  84. package/fesm2022/fragiola-primitives-angular-drop-zone.mjs +189 -0
  85. package/fesm2022/fragiola-primitives-angular-drop-zone.mjs.map +1 -0
  86. package/fesm2022/fragiola-primitives-angular-editable.mjs +955 -0
  87. package/fesm2022/fragiola-primitives-angular-editable.mjs.map +1 -0
  88. package/fesm2022/fragiola-primitives-angular-field.mjs +929 -0
  89. package/fesm2022/fragiola-primitives-angular-field.mjs.map +1 -0
  90. package/fesm2022/fragiola-primitives-angular-fieldset.mjs +164 -0
  91. package/fesm2022/fragiola-primitives-angular-fieldset.mjs.map +1 -0
  92. package/fesm2022/fragiola-primitives-angular-file-upload.mjs +1370 -0
  93. package/fesm2022/fragiola-primitives-angular-file-upload.mjs.map +1 -0
  94. package/fesm2022/fragiola-primitives-angular-form.mjs +162 -0
  95. package/fesm2022/fragiola-primitives-angular-form.mjs.map +1 -0
  96. package/fesm2022/fragiola-primitives-angular-hover-card.mjs +906 -0
  97. package/fesm2022/fragiola-primitives-angular-hover-card.mjs.map +1 -0
  98. package/fesm2022/fragiola-primitives-angular-internal.mjs +980 -0
  99. package/fesm2022/fragiola-primitives-angular-internal.mjs.map +1 -0
  100. package/fesm2022/fragiola-primitives-angular-label.mjs +65 -0
  101. package/fesm2022/fragiola-primitives-angular-label.mjs.map +1 -0
  102. package/fesm2022/fragiola-primitives-angular-link.mjs +109 -0
  103. package/fesm2022/fragiola-primitives-angular-link.mjs.map +1 -0
  104. package/fesm2022/fragiola-primitives-angular-listbox-virtual.mjs +657 -0
  105. package/fesm2022/fragiola-primitives-angular-listbox-virtual.mjs.map +1 -0
  106. package/fesm2022/fragiola-primitives-angular-listbox.mjs +851 -0
  107. package/fesm2022/fragiola-primitives-angular-listbox.mjs.map +1 -0
  108. package/fesm2022/fragiola-primitives-angular-menu.mjs +2258 -0
  109. package/fesm2022/fragiola-primitives-angular-menu.mjs.map +1 -0
  110. package/fesm2022/fragiola-primitives-angular-menubar.mjs +303 -0
  111. package/fesm2022/fragiola-primitives-angular-menubar.mjs.map +1 -0
  112. package/fesm2022/fragiola-primitives-angular-meter.mjs +410 -0
  113. package/fesm2022/fragiola-primitives-angular-meter.mjs.map +1 -0
  114. package/fesm2022/fragiola-primitives-angular-month-calendar.mjs +1066 -0
  115. package/fesm2022/fragiola-primitives-angular-month-calendar.mjs.map +1 -0
  116. package/fesm2022/fragiola-primitives-angular-month-picker.mjs +514 -0
  117. package/fesm2022/fragiola-primitives-angular-month-picker.mjs.map +1 -0
  118. package/fesm2022/fragiola-primitives-angular-month-range-calendar.mjs +163 -0
  119. package/fesm2022/fragiola-primitives-angular-month-range-calendar.mjs.map +1 -0
  120. package/fesm2022/fragiola-primitives-angular-month-range-picker.mjs +177 -0
  121. package/fesm2022/fragiola-primitives-angular-month-range-picker.mjs.map +1 -0
  122. package/fesm2022/fragiola-primitives-angular-multiple-calendar.mjs +216 -0
  123. package/fesm2022/fragiola-primitives-angular-multiple-calendar.mjs.map +1 -0
  124. package/fesm2022/fragiola-primitives-angular-navigation-menu.mjs +1413 -0
  125. package/fesm2022/fragiola-primitives-angular-navigation-menu.mjs.map +1 -0
  126. package/fesm2022/fragiola-primitives-angular-number-field.mjs +1210 -0
  127. package/fesm2022/fragiola-primitives-angular-number-field.mjs.map +1 -0
  128. package/fesm2022/fragiola-primitives-angular-otp-field.mjs +751 -0
  129. package/fesm2022/fragiola-primitives-angular-otp-field.mjs.map +1 -0
  130. package/fesm2022/fragiola-primitives-angular-pagination.mjs +758 -0
  131. package/fesm2022/fragiola-primitives-angular-pagination.mjs.map +1 -0
  132. package/fesm2022/fragiola-primitives-angular-password-input.mjs +542 -0
  133. package/fesm2022/fragiola-primitives-angular-password-input.mjs.map +1 -0
  134. package/fesm2022/fragiola-primitives-angular-popover.mjs +1011 -0
  135. package/fesm2022/fragiola-primitives-angular-popover.mjs.map +1 -0
  136. package/fesm2022/fragiola-primitives-angular-progress.mjs +472 -0
  137. package/fesm2022/fragiola-primitives-angular-progress.mjs.map +1 -0
  138. package/fesm2022/fragiola-primitives-angular-radio-group.mjs +321 -0
  139. package/fesm2022/fragiola-primitives-angular-radio-group.mjs.map +1 -0
  140. package/fesm2022/fragiola-primitives-angular-radio.mjs +273 -0
  141. package/fesm2022/fragiola-primitives-angular-radio.mjs.map +1 -0
  142. package/fesm2022/fragiola-primitives-angular-range-calendar.mjs +108 -0
  143. package/fesm2022/fragiola-primitives-angular-range-calendar.mjs.map +1 -0
  144. package/fesm2022/fragiola-primitives-angular-rating.mjs +643 -0
  145. package/fesm2022/fragiola-primitives-angular-rating.mjs.map +1 -0
  146. package/fesm2022/fragiola-primitives-angular-render.mjs +1 -0
  147. package/fesm2022/fragiola-primitives-angular-scroll-area.mjs +553 -0
  148. package/fesm2022/fragiola-primitives-angular-scroll-area.mjs.map +1 -0
  149. package/fesm2022/fragiola-primitives-angular-search-field.mjs +487 -0
  150. package/fesm2022/fragiola-primitives-angular-search-field.mjs.map +1 -0
  151. package/fesm2022/fragiola-primitives-angular-segmented-control.mjs +762 -0
  152. package/fesm2022/fragiola-primitives-angular-segmented-control.mjs.map +1 -0
  153. package/fesm2022/fragiola-primitives-angular-select-virtual.mjs +246 -0
  154. package/fesm2022/fragiola-primitives-angular-select-virtual.mjs.map +1 -0
  155. package/fesm2022/fragiola-primitives-angular-select.mjs +1433 -0
  156. package/fesm2022/fragiola-primitives-angular-select.mjs.map +1 -0
  157. package/fesm2022/fragiola-primitives-angular-separator.mjs +102 -0
  158. package/fesm2022/fragiola-primitives-angular-separator.mjs.map +1 -0
  159. package/fesm2022/fragiola-primitives-angular-slider.mjs +1090 -0
  160. package/fesm2022/fragiola-primitives-angular-slider.mjs.map +1 -0
  161. package/fesm2022/fragiola-primitives-angular-steps.mjs +819 -0
  162. package/fesm2022/fragiola-primitives-angular-steps.mjs.map +1 -0
  163. package/fesm2022/fragiola-primitives-angular-switch.mjs +422 -0
  164. package/fesm2022/fragiola-primitives-angular-switch.mjs.map +1 -0
  165. package/fesm2022/fragiola-primitives-angular-tabs.mjs +726 -0
  166. package/fesm2022/fragiola-primitives-angular-tabs.mjs.map +1 -0
  167. package/fesm2022/fragiola-primitives-angular-tag-group.mjs +768 -0
  168. package/fesm2022/fragiola-primitives-angular-tag-group.mjs.map +1 -0
  169. package/fesm2022/fragiola-primitives-angular-tags-input.mjs +1126 -0
  170. package/fesm2022/fragiola-primitives-angular-tags-input.mjs.map +1 -0
  171. package/fesm2022/fragiola-primitives-angular-time-field.mjs +187 -0
  172. package/fesm2022/fragiola-primitives-angular-time-field.mjs.map +1 -0
  173. package/fesm2022/fragiola-primitives-angular-time-range-field.mjs +188 -0
  174. package/fesm2022/fragiola-primitives-angular-time-range-field.mjs.map +1 -0
  175. package/fesm2022/fragiola-primitives-angular-toast.mjs +744 -0
  176. package/fesm2022/fragiola-primitives-angular-toast.mjs.map +1 -0
  177. package/fesm2022/fragiola-primitives-angular-toggle-group.mjs +245 -0
  178. package/fesm2022/fragiola-primitives-angular-toggle-group.mjs.map +1 -0
  179. package/fesm2022/fragiola-primitives-angular-toggle.mjs +229 -0
  180. package/fesm2022/fragiola-primitives-angular-toggle.mjs.map +1 -0
  181. package/fesm2022/fragiola-primitives-angular-toolbar.mjs +623 -0
  182. package/fesm2022/fragiola-primitives-angular-toolbar.mjs.map +1 -0
  183. package/fesm2022/fragiola-primitives-angular-tooltip.mjs +975 -0
  184. package/fesm2022/fragiola-primitives-angular-tooltip.mjs.map +1 -0
  185. package/fesm2022/fragiola-primitives-angular-year-calendar.mjs +163 -0
  186. package/fesm2022/fragiola-primitives-angular-year-calendar.mjs.map +1 -0
  187. package/fesm2022/fragiola-primitives-angular-year-picker.mjs +177 -0
  188. package/fesm2022/fragiola-primitives-angular-year-picker.mjs.map +1 -0
  189. package/fesm2022/fragiola-primitives-angular-year-range-calendar.mjs +163 -0
  190. package/fesm2022/fragiola-primitives-angular-year-range-calendar.mjs.map +1 -0
  191. package/fesm2022/fragiola-primitives-angular-year-range-picker.mjs +177 -0
  192. package/fesm2022/fragiola-primitives-angular-year-range-picker.mjs.map +1 -0
  193. package/fesm2022/fragiola-primitives-angular.mjs +94 -0
  194. package/package.json +437 -3
  195. package/types/fragiola-primitives-angular-accordion.d.ts +154 -0
  196. package/types/fragiola-primitives-angular-alert-dialog.d.ts +176 -0
  197. package/types/fragiola-primitives-angular-aspect-ratio.d.ts +25 -0
  198. package/types/fragiola-primitives-angular-async-list.d.ts +32 -0
  199. package/types/fragiola-primitives-angular-autocomplete-virtual.d.ts +82 -0
  200. package/types/fragiola-primitives-angular-autocomplete.d.ts +496 -0
  201. package/types/fragiola-primitives-angular-avatar.d.ts +94 -0
  202. package/types/fragiola-primitives-angular-breadcrumbs.d.ts +62 -0
  203. package/types/fragiola-primitives-angular-button.d.ts +66 -0
  204. package/types/fragiola-primitives-angular-calendar-preset.d.ts +35 -0
  205. package/types/fragiola-primitives-angular-calendar-view.d.ts +80 -0
  206. package/types/fragiola-primitives-angular-calendar.d.ts +414 -0
  207. package/types/fragiola-primitives-angular-carousel.d.ts +300 -0
  208. package/types/fragiola-primitives-angular-cascade-select.d.ts +404 -0
  209. package/types/fragiola-primitives-angular-checkbox-group.d.ts +74 -0
  210. package/types/fragiola-primitives-angular-checkbox.d.ts +111 -0
  211. package/types/fragiola-primitives-angular-clipboard.d.ts +106 -0
  212. package/types/fragiola-primitives-angular-collapsible.d.ts +88 -0
  213. package/types/fragiola-primitives-angular-color-area.d.ts +174 -0
  214. package/types/fragiola-primitives-angular-color-field.d.ts +174 -0
  215. package/types/fragiola-primitives-angular-color-picker-popover.d.ts +180 -0
  216. package/types/fragiola-primitives-angular-color-picker.d.ts +137 -0
  217. package/types/fragiola-primitives-angular-color-slider.d.ts +228 -0
  218. package/types/fragiola-primitives-angular-color-swatch-picker.d.ts +146 -0
  219. package/types/fragiola-primitives-angular-color-swatch.d.ts +43 -0
  220. package/types/fragiola-primitives-angular-color-wheel.d.ts +144 -0
  221. package/types/fragiola-primitives-angular-combobox-virtual.d.ts +84 -0
  222. package/types/fragiola-primitives-angular-combobox.d.ts +582 -0
  223. package/types/fragiola-primitives-angular-command-virtual.d.ts +93 -0
  224. package/types/fragiola-primitives-angular-command.d.ts +283 -0
  225. package/types/fragiola-primitives-angular-context-menu.d.ts +278 -0
  226. package/types/fragiola-primitives-angular-date-field.d.ts +486 -0
  227. package/types/fragiola-primitives-angular-date-picker-input.d.ts +139 -0
  228. package/types/fragiola-primitives-angular-date-picker.d.ts +331 -0
  229. package/types/fragiola-primitives-angular-date-range-field.d.ts +333 -0
  230. package/types/fragiola-primitives-angular-date-range-picker-input.d.ts +89 -0
  231. package/types/fragiola-primitives-angular-date-range-picker.d.ts +35 -0
  232. package/types/fragiola-primitives-angular-dialog.d.ts +359 -0
  233. package/types/fragiola-primitives-angular-direction.d.ts +31 -0
  234. package/types/fragiola-primitives-angular-drawer.d.ts +242 -0
  235. package/types/fragiola-primitives-angular-drop-zone.d.ts +68 -0
  236. package/types/fragiola-primitives-angular-editable.d.ts +219 -0
  237. package/types/fragiola-primitives-angular-field.d.ts +397 -0
  238. package/types/fragiola-primitives-angular-fieldset.d.ts +47 -0
  239. package/types/fragiola-primitives-angular-file-upload.d.ts +351 -0
  240. package/types/fragiola-primitives-angular-form.d.ts +44 -0
  241. package/types/fragiola-primitives-angular-hover-card.d.ts +279 -0
  242. package/types/fragiola-primitives-angular-internal.d.ts +695 -0
  243. package/types/fragiola-primitives-angular-label.d.ts +14 -0
  244. package/types/fragiola-primitives-angular-link.d.ts +33 -0
  245. package/types/fragiola-primitives-angular-listbox-virtual.d.ts +193 -0
  246. package/types/fragiola-primitives-angular-listbox.d.ts +237 -0
  247. package/types/fragiola-primitives-angular-menu.d.ts +758 -0
  248. package/types/fragiola-primitives-angular-menubar.d.ts +76 -0
  249. package/types/fragiola-primitives-angular-meter.d.ts +117 -0
  250. package/types/fragiola-primitives-angular-month-calendar.d.ts +380 -0
  251. package/types/fragiola-primitives-angular-month-picker.d.ts +183 -0
  252. package/types/fragiola-primitives-angular-month-range-calendar.d.ts +54 -0
  253. package/types/fragiola-primitives-angular-month-range-picker.d.ts +56 -0
  254. package/types/fragiola-primitives-angular-multiple-calendar.d.ts +73 -0
  255. package/types/fragiola-primitives-angular-navigation-menu.d.ts +355 -0
  256. package/types/fragiola-primitives-angular-number-field.d.ts +305 -0
  257. package/types/fragiola-primitives-angular-otp-field.d.ts +210 -0
  258. package/types/fragiola-primitives-angular-pagination.d.ts +239 -0
  259. package/types/fragiola-primitives-angular-password-input.d.ts +149 -0
  260. package/types/fragiola-primitives-angular-popover.d.ts +303 -0
  261. package/types/fragiola-primitives-angular-progress.d.ts +126 -0
  262. package/types/fragiola-primitives-angular-radio-group.d.ts +123 -0
  263. package/types/fragiola-primitives-angular-radio.d.ts +67 -0
  264. package/types/fragiola-primitives-angular-range-calendar.d.ts +33 -0
  265. package/types/fragiola-primitives-angular-rating.d.ts +195 -0
  266. package/types/fragiola-primitives-angular-render.d.ts +2 -0
  267. package/types/fragiola-primitives-angular-scroll-area.d.ts +134 -0
  268. package/types/fragiola-primitives-angular-search-field.d.ts +129 -0
  269. package/types/fragiola-primitives-angular-segmented-control.d.ts +232 -0
  270. package/types/fragiola-primitives-angular-select-virtual.d.ts +81 -0
  271. package/types/fragiola-primitives-angular-select.d.ts +403 -0
  272. package/types/fragiola-primitives-angular-separator.d.ts +32 -0
  273. package/types/fragiola-primitives-angular-slider.d.ts +297 -0
  274. package/types/fragiola-primitives-angular-steps.d.ts +194 -0
  275. package/types/fragiola-primitives-angular-switch.d.ts +102 -0
  276. package/types/fragiola-primitives-angular-tabs.d.ts +215 -0
  277. package/types/fragiola-primitives-angular-tag-group.d.ts +232 -0
  278. package/types/fragiola-primitives-angular-tags-input.d.ts +318 -0
  279. package/types/fragiola-primitives-angular-time-field.d.ts +63 -0
  280. package/types/fragiola-primitives-angular-time-range-field.d.ts +65 -0
  281. package/types/fragiola-primitives-angular-toast.d.ts +196 -0
  282. package/types/fragiola-primitives-angular-toggle-group.d.ts +89 -0
  283. package/types/fragiola-primitives-angular-toggle.d.ts +86 -0
  284. package/types/fragiola-primitives-angular-toolbar.d.ts +187 -0
  285. package/types/fragiola-primitives-angular-tooltip.d.ts +330 -0
  286. package/types/fragiola-primitives-angular-year-calendar.d.ts +54 -0
  287. package/types/fragiola-primitives-angular-year-picker.d.ts +56 -0
  288. package/types/fragiola-primitives-angular-year-range-calendar.d.ts +54 -0
  289. package/types/fragiola-primitives-angular-year-range-picker.d.ts +56 -0
  290. package/types/fragiola-primitives-angular.d.ts +94 -0
@@ -0,0 +1,1391 @@
1
+ import * as i0 from "@angular/core";
2
+ import { DestroyRef, Directive, ElementRef, TemplateRef, ViewContainerRef, afterNextRender, afterRenderEffect, booleanAttribute, computed, effect, inject, input, output, signal, untracked } from "@angular/core";
3
+ import { cascadeKeyAction, cascadeLevels, cascadePathItems, hasCascadeChildren } from "@fragiola/primitives/cascade";
4
+ import { createTypeahead, scrollIntoViewWithin } from "@fragiola/primitives/collection";
5
+ import { isInSafeArea } from "@fragiola/primitives/pointer";
6
+ import { controllable, createHiddenInput, createOverlayRoot, dataValues, injectFlush, injectHost, injectId, injectProvidedDirection, mountPortal, placementSignal, portalOptions, positionOverlay, registerHost, setInputAttribute } from "@fragiola/primitives-angular/internal";
7
+ import { bridgeForm } from "@fragiola/primitives/form";
8
+ import { fieldControl, writeFieldAria } from "@fragiola/primitives-angular/field";
9
+ import { openOverlaySession } from "@fragiola/primitives/overlay";
10
+ import { getDirection } from "@fragiola/primitives/direction";
11
+ const NONE = [];
12
+ function samePath(a, b) {
13
+ return a.length === b.length && a.every((entry, index) => entry === b[index]);
14
+ }
15
+ function firstItem(items) {
16
+ return (items.find((item) => !item.disabled) ?? items[0])?.value;
17
+ }
18
+ var CascadeSelectRoot = class CascadeSelectRoot {
19
+ constructor() {
20
+ this.open = input(void 0, ...ngDevMode ? [{ debugName: "open" }] : /* istanbul ignore next */ []);
21
+ this.openChange = output();
22
+ this.defaultOpen = input(false, ...ngDevMode ? [{ debugName: "defaultOpen" }] : /* istanbul ignore next */ []);
23
+ this.openChangeDetails = output();
24
+ this.openChangeComplete = output();
25
+ this.items = input.required(...ngDevMode ? [{ debugName: "items" }] : /* istanbul ignore next */ []);
26
+ this.value = input(void 0, ...ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []);
27
+ this.valueChange = output();
28
+ this.defaultValue = input(NONE, ...ngDevMode ? [{ debugName: "defaultValue" }] : /* istanbul ignore next */ []);
29
+ this.valueChangeDetails = output();
30
+ this.changeOnSelect = input(false, {
31
+ ...ngDevMode ? { debugName: "changeOnSelect" } : /* istanbul ignore next */ {},
32
+ transform: booleanAttribute
33
+ });
34
+ this.name = input(void 0, ...ngDevMode ? [{ debugName: "name" }] : /* istanbul ignore next */ []);
35
+ this.required = input(false, {
36
+ ...ngDevMode ? { debugName: "required" } : /* istanbul ignore next */ {},
37
+ transform: booleanAttribute
38
+ });
39
+ this.disabled = input(false, {
40
+ ...ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {},
41
+ transform: booleanAttribute
42
+ });
43
+ this.valueSeparator = input("/", ...ngDevMode ? [{ debugName: "valueSeparator" }] : /* istanbul ignore next */ []);
44
+ this.triggerElementId = signal(void 0, ...ngDevMode ? [{ debugName: "triggerElementId" }] : /* istanbul ignore next */ []);
45
+ this.hidden = createHiddenInput(inject(ElementRef).nativeElement, { "data-primitives-part": "cascade-select-input" });
46
+ this.overlay = createOverlayRoot(this, (event) => this.openChangeDetails.emit(event), "primitives-cascade-select");
47
+ this.selection = controllable(this.value, this.valueChange, () => this.defaultValue(), (value, details) => this.valueChangeDetails.emit({
48
+ value,
49
+ details
50
+ }));
51
+ this.selected = this.selection.value;
52
+ this.field = fieldControl({
53
+ id: this.triggerElementId,
54
+ labelable: true,
55
+ value: this.selected,
56
+ filled: computed(() => this.selected().length > 0),
57
+ input: () => this.hidden,
58
+ focusTarget: () => this.overlay.trigger()
59
+ });
60
+ this.isDisabled = computed(() => this.disabled() || this.field.disabled(), ...ngDevMode ? [{ debugName: "isDisabled" }] : /* istanbul ignore next */ []);
61
+ this.highlight = signal({
62
+ active: NONE,
63
+ peek: false
64
+ }, ...ngDevMode ? [{ debugName: "highlight" }] : /* istanbul ignore next */ []);
65
+ this.active = computed(() => this.highlight().active, ...ngDevMode ? [{ debugName: "active" }] : /* istanbul ignore next */ []);
66
+ this.peek = computed(() => this.highlight().peek, ...ngDevMode ? [{ debugName: "peek" }] : /* istanbul ignore next */ []);
67
+ this.levels = computed(() => {
68
+ const { active, peek } = this.highlight();
69
+ return cascadeLevels(this.items(), peek ? active : active.slice(0, -1));
70
+ }, ...ngDevMode ? [{ debugName: "levels" }] : /* istanbul ignore next */ []);
71
+ this.placed = placementSignal({
72
+ side: "bottom",
73
+ align: "start"
74
+ });
75
+ this.state = computed(() => ({
76
+ open: this.overlay.open(),
77
+ disabled: this.isDisabled(),
78
+ value: this.selected()
79
+ }), ...ngDevMode ? [{ debugName: "state" }] : /* istanbul ignore next */ []);
80
+ this.safeArea = null;
81
+ this.hoverTimer = void 0;
82
+ this.baseId = injectId("primitives-cascade-select");
83
+ const hidden = this.hidden;
84
+ effect(() => {
85
+ hidden.value = this.selected().join(this.valueSeparator());
86
+ setInputAttribute(hidden, "name", this.field.name() ?? this.name() ?? null);
87
+ hidden.required = this.required();
88
+ hidden.disabled = this.isDisabled();
89
+ });
90
+ effect(() => {
91
+ if (!this.overlay.open()) {
92
+ clearTimeout(this.hoverTimer);
93
+ this.hoverTimer = void 0;
94
+ this.safeArea = null;
95
+ }
96
+ });
97
+ let stop = null;
98
+ afterNextRender(() => {
99
+ stop = bridgeForm(hidden, {
100
+ reset: () => {
101
+ const fallback = this.defaultValue();
102
+ this.field.reset();
103
+ this.selection.set(fallback, { reason: "none" });
104
+ hidden.value = fallback.join(this.valueSeparator());
105
+ },
106
+ invalid: () => this.overlay.trigger()
107
+ });
108
+ });
109
+ inject(DestroyRef).onDestroy(() => {
110
+ stop?.();
111
+ clearTimeout(this.hoverTimer);
112
+ });
113
+ }
114
+ levelId(depth) {
115
+ return `${this.baseId}-level-${depth}`;
116
+ }
117
+ itemId(depth, value) {
118
+ const index = (this.levels()[depth] ?? []).findIndex((item) => item.value === value);
119
+ return `${this.baseId}-item-${depth}-${index}`;
120
+ }
121
+ setActive(active, peek = false) {
122
+ this.highlight.set({
123
+ active,
124
+ peek
125
+ });
126
+ }
127
+ initialActive() {
128
+ const items = this.items();
129
+ const value = this.selected();
130
+ const found = cascadePathItems(items, value);
131
+ if (found !== null && found.length > 0) return value;
132
+ const first = firstItem(items);
133
+ return first === void 0 ? NONE : [first];
134
+ }
135
+ openOn(active, reason, event) {
136
+ const previous = untracked(this.highlight);
137
+ this.highlight.set({
138
+ active,
139
+ peek: false
140
+ });
141
+ if (!this.overlay.setOpen(true, reason, event)) this.highlight.set(previous);
142
+ }
143
+ choose(path, reason, event, keepOpen = false) {
144
+ const found = cascadePathItems(this.items(), path);
145
+ if (found === null || found.length === 0 || found.some((item) => item.disabled)) return;
146
+ this.selection.set(path, {
147
+ reason,
148
+ event
149
+ });
150
+ if (!keepOpen) this.overlay.setOpen(false, reason, event);
151
+ }
152
+ close() {
153
+ this.overlay.close();
154
+ }
155
+ unmount() {
156
+ this.overlay.unmount();
157
+ }
158
+ static {
159
+ this.ɵfac = i0.ɵɵngDeclareFactory({
160
+ minVersion: "12.0.0",
161
+ version: "22.2.6",
162
+ ngImport: i0,
163
+ type: CascadeSelectRoot,
164
+ deps: [],
165
+ target: i0.ɵɵFactoryTarget.Directive
166
+ });
167
+ }
168
+ static {
169
+ this.ɵdir = i0.ɵɵngDeclareDirective({
170
+ minVersion: "17.1.0",
171
+ version: "22.2.6",
172
+ type: CascadeSelectRoot,
173
+ isStandalone: true,
174
+ selector: "[cascadeSelectRoot]",
175
+ inputs: {
176
+ open: {
177
+ classPropertyName: "open",
178
+ publicName: "open",
179
+ isSignal: true,
180
+ isRequired: false,
181
+ transformFunction: null
182
+ },
183
+ defaultOpen: {
184
+ classPropertyName: "defaultOpen",
185
+ publicName: "defaultOpen",
186
+ isSignal: true,
187
+ isRequired: false,
188
+ transformFunction: null
189
+ },
190
+ items: {
191
+ classPropertyName: "items",
192
+ publicName: "items",
193
+ isSignal: true,
194
+ isRequired: true,
195
+ transformFunction: null
196
+ },
197
+ value: {
198
+ classPropertyName: "value",
199
+ publicName: "value",
200
+ isSignal: true,
201
+ isRequired: false,
202
+ transformFunction: null
203
+ },
204
+ defaultValue: {
205
+ classPropertyName: "defaultValue",
206
+ publicName: "defaultValue",
207
+ isSignal: true,
208
+ isRequired: false,
209
+ transformFunction: null
210
+ },
211
+ changeOnSelect: {
212
+ classPropertyName: "changeOnSelect",
213
+ publicName: "changeOnSelect",
214
+ isSignal: true,
215
+ isRequired: false,
216
+ transformFunction: null
217
+ },
218
+ name: {
219
+ classPropertyName: "name",
220
+ publicName: "name",
221
+ isSignal: true,
222
+ isRequired: false,
223
+ transformFunction: null
224
+ },
225
+ required: {
226
+ classPropertyName: "required",
227
+ publicName: "required",
228
+ isSignal: true,
229
+ isRequired: false,
230
+ transformFunction: null
231
+ },
232
+ disabled: {
233
+ classPropertyName: "disabled",
234
+ publicName: "disabled",
235
+ isSignal: true,
236
+ isRequired: false,
237
+ transformFunction: null
238
+ },
239
+ valueSeparator: {
240
+ classPropertyName: "valueSeparator",
241
+ publicName: "valueSeparator",
242
+ isSignal: true,
243
+ isRequired: false,
244
+ transformFunction: null
245
+ }
246
+ },
247
+ outputs: {
248
+ openChange: "openChange",
249
+ openChangeDetails: "openChangeDetails",
250
+ openChangeComplete: "openChangeComplete",
251
+ valueChange: "valueChange",
252
+ valueChangeDetails: "valueChangeDetails"
253
+ },
254
+ exportAs: ["cascadeSelectRoot"],
255
+ ngImport: i0
256
+ });
257
+ }
258
+ };
259
+ i0.ɵɵngDeclareClassMetadata({
260
+ minVersion: "12.0.0",
261
+ version: "22.2.6",
262
+ ngImport: i0,
263
+ type: CascadeSelectRoot,
264
+ decorators: [{
265
+ type: Directive,
266
+ args: [{
267
+ selector: "[cascadeSelectRoot]",
268
+ exportAs: "cascadeSelectRoot"
269
+ }]
270
+ }],
271
+ ctorParameters: () => [],
272
+ propDecorators: {
273
+ open: [{
274
+ type: i0.Input,
275
+ args: [{
276
+ isSignal: true,
277
+ alias: "open",
278
+ required: false
279
+ }]
280
+ }],
281
+ openChange: [{
282
+ type: i0.Output,
283
+ args: ["openChange"]
284
+ }],
285
+ defaultOpen: [{
286
+ type: i0.Input,
287
+ args: [{
288
+ isSignal: true,
289
+ alias: "defaultOpen",
290
+ required: false
291
+ }]
292
+ }],
293
+ openChangeDetails: [{
294
+ type: i0.Output,
295
+ args: ["openChangeDetails"]
296
+ }],
297
+ openChangeComplete: [{
298
+ type: i0.Output,
299
+ args: ["openChangeComplete"]
300
+ }],
301
+ items: [{
302
+ type: i0.Input,
303
+ args: [{
304
+ isSignal: true,
305
+ alias: "items",
306
+ required: true
307
+ }]
308
+ }],
309
+ value: [{
310
+ type: i0.Input,
311
+ args: [{
312
+ isSignal: true,
313
+ alias: "value",
314
+ required: false
315
+ }]
316
+ }],
317
+ valueChange: [{
318
+ type: i0.Output,
319
+ args: ["valueChange"]
320
+ }],
321
+ defaultValue: [{
322
+ type: i0.Input,
323
+ args: [{
324
+ isSignal: true,
325
+ alias: "defaultValue",
326
+ required: false
327
+ }]
328
+ }],
329
+ valueChangeDetails: [{
330
+ type: i0.Output,
331
+ args: ["valueChangeDetails"]
332
+ }],
333
+ changeOnSelect: [{
334
+ type: i0.Input,
335
+ args: [{
336
+ isSignal: true,
337
+ alias: "changeOnSelect",
338
+ required: false
339
+ }]
340
+ }],
341
+ name: [{
342
+ type: i0.Input,
343
+ args: [{
344
+ isSignal: true,
345
+ alias: "name",
346
+ required: false
347
+ }]
348
+ }],
349
+ required: [{
350
+ type: i0.Input,
351
+ args: [{
352
+ isSignal: true,
353
+ alias: "required",
354
+ required: false
355
+ }]
356
+ }],
357
+ disabled: [{
358
+ type: i0.Input,
359
+ args: [{
360
+ isSignal: true,
361
+ alias: "disabled",
362
+ required: false
363
+ }]
364
+ }],
365
+ valueSeparator: [{
366
+ type: i0.Input,
367
+ args: [{
368
+ isSignal: true,
369
+ alias: "valueSeparator",
370
+ required: false
371
+ }]
372
+ }]
373
+ }
374
+ });
375
+ const NO_ITEMS = [];
376
+ var CascadeSelectLevel = class CascadeSelectLevel {
377
+ constructor() {
378
+ this.root = inject(CascadeSelectRoot);
379
+ this.depth = input.required(...ngDevMode ? [{ debugName: "depth" }] : /* istanbul ignore next */ []);
380
+ this.state = computed(() => ({
381
+ open: this.depth() < this.root.levels().length,
382
+ depth: this.depth()
383
+ }), ...ngDevMode ? [{ debugName: "state" }] : /* istanbul ignore next */ []);
384
+ this.items = computed(() => this.root.levels()[this.depth()] ?? NO_ITEMS, ...ngDevMode ? [{ debugName: "items" }] : /* istanbul ignore next */ []);
385
+ this.String = String;
386
+ }
387
+ labelledBy() {
388
+ const depth = this.depth();
389
+ if (depth === 0) return this.root.overlay.trigger()?.id || null;
390
+ const parent = this.root.active()[depth - 1];
391
+ return parent === void 0 ? null : this.root.itemId(depth - 1, parent);
392
+ }
393
+ static {
394
+ this.ɵfac = i0.ɵɵngDeclareFactory({
395
+ minVersion: "12.0.0",
396
+ version: "22.2.6",
397
+ ngImport: i0,
398
+ type: CascadeSelectLevel,
399
+ deps: [],
400
+ target: i0.ɵɵFactoryTarget.Directive
401
+ });
402
+ }
403
+ static {
404
+ this.ɵdir = i0.ɵɵngDeclareDirective({
405
+ minVersion: "17.1.0",
406
+ version: "22.2.6",
407
+ type: CascadeSelectLevel,
408
+ isStandalone: true,
409
+ selector: "[cascadeSelectLevel]",
410
+ inputs: { depth: {
411
+ classPropertyName: "depth",
412
+ publicName: "depth",
413
+ isSignal: true,
414
+ isRequired: true,
415
+ transformFunction: null
416
+ } },
417
+ host: {
418
+ attributes: {
419
+ "role": "listbox",
420
+ "data-primitives-part": "cascade-select-level"
421
+ },
422
+ properties: {
423
+ "attr.id": "root.levelId(depth())",
424
+ "attr.hidden": "state().open ? null : ''",
425
+ "attr.aria-labelledby": "labelledBy()",
426
+ "attr.data-depth": "String(depth())"
427
+ }
428
+ },
429
+ exportAs: ["cascadeSelectLevel"],
430
+ ngImport: i0
431
+ });
432
+ }
433
+ };
434
+ i0.ɵɵngDeclareClassMetadata({
435
+ minVersion: "12.0.0",
436
+ version: "22.2.6",
437
+ ngImport: i0,
438
+ type: CascadeSelectLevel,
439
+ decorators: [{
440
+ type: Directive,
441
+ args: [{
442
+ selector: "[cascadeSelectLevel]",
443
+ exportAs: "cascadeSelectLevel",
444
+ host: {
445
+ role: "listbox",
446
+ "data-primitives-part": "cascade-select-level",
447
+ "[attr.id]": "root.levelId(depth())",
448
+ "[attr.hidden]": "state().open ? null : ''",
449
+ "[attr.aria-labelledby]": "labelledBy()",
450
+ "[attr.data-depth]": "String(depth())"
451
+ }
452
+ }]
453
+ }],
454
+ propDecorators: { depth: [{
455
+ type: i0.Input,
456
+ args: [{
457
+ isSignal: true,
458
+ alias: "depth",
459
+ required: true
460
+ }]
461
+ }] }
462
+ });
463
+ const HOVER_DELAY = 100;
464
+ var CascadeSelectItem = class CascadeSelectItem {
465
+ constructor() {
466
+ this.root = inject(CascadeSelectRoot);
467
+ this.level = inject(CascadeSelectLevel);
468
+ this.value = input.required(...ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []);
469
+ this.entry = computed(() => this.level.items().find((item) => item.value === this.value()), ...ngDevMode ? [{ debugName: "entry" }] : /* istanbul ignore next */ []);
470
+ this.path = computed(() => [...this.root.active().slice(0, this.level.depth()), this.value()], ...ngDevMode ? [{ debugName: "path" }] : /* istanbul ignore next */ []);
471
+ this.state = computed(() => {
472
+ const depth = this.level.depth();
473
+ const value = this.value();
474
+ const active = this.root.active();
475
+ const hasChildren = hasCascadeChildren(this.entry());
476
+ return {
477
+ highlighted: active.length - 1 === depth && active[depth] === value,
478
+ selected: samePath(this.root.selected().slice(0, depth + 1), this.path()),
479
+ disabled: this.entry()?.disabled ?? false,
480
+ hasChildren,
481
+ expanded: hasChildren && active[depth] === value && depth + 1 < this.root.levels().length
482
+ };
483
+ }, ...ngDevMode ? [{ debugName: "state" }] : /* istanbul ignore next */ []);
484
+ this.data = computed(() => {
485
+ const { hasChildren, ...state } = this.state();
486
+ return dataValues({
487
+ ...state,
488
+ "has-children": hasChildren
489
+ });
490
+ }, ...ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []);
491
+ this.host = injectHost();
492
+ this.lastPoint = null;
493
+ afterRenderEffect(() => {
494
+ if (this.state().highlighted) scrollIntoViewWithin(this.host, this.root.overlay.positioner());
495
+ });
496
+ }
497
+ startHover() {
498
+ const root = this.root;
499
+ clearTimeout(root.hoverTimer);
500
+ root.hoverTimer = void 0;
501
+ const { hasChildren, disabled } = this.state();
502
+ if (!hasChildren || disabled) return;
503
+ const path = this.path();
504
+ root.hoverTimer = setTimeout(() => {
505
+ root.hoverTimer = void 0;
506
+ root.setActive(path, true);
507
+ }, HOVER_DELAY);
508
+ }
509
+ onPointerMove(event) {
510
+ const root = this.root;
511
+ this.lastPoint = {
512
+ x: event.clientX,
513
+ y: event.clientY
514
+ };
515
+ const depth = this.level.depth();
516
+ const value = this.value();
517
+ const active = root.active();
518
+ const area = root.safeArea;
519
+ const levelElement = area === null ? null : this.host.ownerDocument.getElementById(root.levelId(area.depth));
520
+ if (area !== null && levelElement && !levelElement.hidden && area.depth === depth + 1 && active[depth] !== value && isInSafeArea({
521
+ x: event.clientX,
522
+ y: event.clientY
523
+ }, area, levelElement)) return;
524
+ const { highlighted, expanded } = this.state();
525
+ if (highlighted) {
526
+ if (!root.peek() && root.hoverTimer === void 0) this.startHover();
527
+ return;
528
+ }
529
+ if (active[depth] === value && expanded) {
530
+ root.setActive(this.path(), true);
531
+ return;
532
+ }
533
+ root.setActive(this.path());
534
+ this.startHover();
535
+ }
536
+ onPointerLeave(event) {
537
+ const root = this.root;
538
+ clearTimeout(root.hoverTimer);
539
+ root.hoverTimer = void 0;
540
+ const from = this.lastPoint ?? {
541
+ x: event.clientX,
542
+ y: event.clientY
543
+ };
544
+ this.lastPoint = null;
545
+ if (this.state().expanded) root.safeArea = {
546
+ ...from,
547
+ depth: this.level.depth() + 1
548
+ };
549
+ }
550
+ onClick(event) {
551
+ const root = this.root;
552
+ const { disabled, hasChildren } = this.state();
553
+ if (disabled) return;
554
+ clearTimeout(root.hoverTimer);
555
+ root.hoverTimer = void 0;
556
+ const path = this.path();
557
+ if (hasChildren) {
558
+ if (root.changeOnSelect()) root.choose(path, "item-press", event, true);
559
+ root.setActive(path, true);
560
+ return;
561
+ }
562
+ root.choose(path, "item-press", event);
563
+ }
564
+ static {
565
+ this.ɵfac = i0.ɵɵngDeclareFactory({
566
+ minVersion: "12.0.0",
567
+ version: "22.2.6",
568
+ ngImport: i0,
569
+ type: CascadeSelectItem,
570
+ deps: [],
571
+ target: i0.ɵɵFactoryTarget.Directive
572
+ });
573
+ }
574
+ static {
575
+ this.ɵdir = i0.ɵɵngDeclareDirective({
576
+ minVersion: "17.1.0",
577
+ version: "22.2.6",
578
+ type: CascadeSelectItem,
579
+ isStandalone: true,
580
+ selector: "[cascadeSelectItem]",
581
+ inputs: { value: {
582
+ classPropertyName: "value",
583
+ publicName: "value",
584
+ isSignal: true,
585
+ isRequired: true,
586
+ transformFunction: null
587
+ } },
588
+ host: {
589
+ attributes: {
590
+ "role": "option",
591
+ "data-primitives-part": "cascade-select-item"
592
+ },
593
+ listeners: {
594
+ "pointermove": "onPointerMove($event)",
595
+ "pointerleave": "onPointerLeave($event)",
596
+ "pointerdown": "$event.preventDefault()",
597
+ "click": "onClick($event)"
598
+ },
599
+ properties: {
600
+ "attr.id": "root.itemId(level.depth(), value())",
601
+ "attr.aria-selected": "state().selected ? 'true' : 'false'",
602
+ "attr.aria-disabled": "state().disabled ? 'true' : null",
603
+ "attr.aria-controls": "state().expanded ? root.levelId(level.depth() + 1) : null",
604
+ "attr.data-highlighted": "data().highlighted",
605
+ "attr.data-selected": "data().selected",
606
+ "attr.data-disabled": "data().disabled",
607
+ "attr.data-has-children": "data()['has-children']",
608
+ "attr.data-expanded": "data().expanded"
609
+ }
610
+ },
611
+ exportAs: ["cascadeSelectItem"],
612
+ ngImport: i0
613
+ });
614
+ }
615
+ };
616
+ i0.ɵɵngDeclareClassMetadata({
617
+ minVersion: "12.0.0",
618
+ version: "22.2.6",
619
+ ngImport: i0,
620
+ type: CascadeSelectItem,
621
+ decorators: [{
622
+ type: Directive,
623
+ args: [{
624
+ selector: "[cascadeSelectItem]",
625
+ exportAs: "cascadeSelectItem",
626
+ host: {
627
+ role: "option",
628
+ "data-primitives-part": "cascade-select-item",
629
+ "[attr.id]": "root.itemId(level.depth(), value())",
630
+ "[attr.aria-selected]": "state().selected ? 'true' : 'false'",
631
+ "[attr.aria-disabled]": "state().disabled ? 'true' : null",
632
+ "[attr.aria-controls]": "state().expanded ? root.levelId(level.depth() + 1) : null",
633
+ "[attr.data-highlighted]": "data().highlighted",
634
+ "[attr.data-selected]": "data().selected",
635
+ "[attr.data-disabled]": "data().disabled",
636
+ "[attr.data-has-children]": "data()['has-children']",
637
+ "[attr.data-expanded]": "data().expanded",
638
+ "(pointermove)": "onPointerMove($event)",
639
+ "(pointerleave)": "onPointerLeave($event)",
640
+ "(pointerdown)": "$event.preventDefault()",
641
+ "(click)": "onClick($event)"
642
+ }
643
+ }]
644
+ }],
645
+ ctorParameters: () => [],
646
+ propDecorators: { value: [{
647
+ type: i0.Input,
648
+ args: [{
649
+ isSignal: true,
650
+ alias: "value",
651
+ required: true
652
+ }]
653
+ }] }
654
+ });
655
+ var CascadeSelectItemIndicator = class CascadeSelectItemIndicator {
656
+ constructor() {
657
+ this.item = inject(CascadeSelectItem);
658
+ this.keepMounted = input(false, {
659
+ ...ngDevMode ? { debugName: "keepMounted" } : /* istanbul ignore next */ {},
660
+ alias: "cascadeSelectItemIndicator",
661
+ transform: (value) => value === true || value === "true"
662
+ });
663
+ this.state = computed(() => ({ selected: this.item.state().selected }), ...ngDevMode ? [{ debugName: "state" }] : /* istanbul ignore next */ []);
664
+ const template = inject(TemplateRef);
665
+ const container = inject(ViewContainerRef);
666
+ let view = null;
667
+ effect(() => {
668
+ const show = this.state().selected || this.keepMounted();
669
+ untracked(() => {
670
+ if (!show) {
671
+ container.clear();
672
+ view = null;
673
+ return;
674
+ }
675
+ if (view !== null) return;
676
+ view = container.createEmbeddedView(template);
677
+ for (const node of view.rootNodes) if (node instanceof HTMLElement) {
678
+ node.setAttribute("aria-hidden", "true");
679
+ node.setAttribute("data-primitives-part", "cascade-select-item-indicator");
680
+ }
681
+ });
682
+ });
683
+ }
684
+ static {
685
+ this.ɵfac = i0.ɵɵngDeclareFactory({
686
+ minVersion: "12.0.0",
687
+ version: "22.2.6",
688
+ ngImport: i0,
689
+ type: CascadeSelectItemIndicator,
690
+ deps: [],
691
+ target: i0.ɵɵFactoryTarget.Directive
692
+ });
693
+ }
694
+ static {
695
+ this.ɵdir = i0.ɵɵngDeclareDirective({
696
+ minVersion: "17.1.0",
697
+ version: "22.2.6",
698
+ type: CascadeSelectItemIndicator,
699
+ isStandalone: true,
700
+ selector: "[cascadeSelectItemIndicator]",
701
+ inputs: { keepMounted: {
702
+ classPropertyName: "keepMounted",
703
+ publicName: "cascadeSelectItemIndicator",
704
+ isSignal: true,
705
+ isRequired: false,
706
+ transformFunction: null
707
+ } },
708
+ exportAs: ["cascadeSelectItemIndicator"],
709
+ ngImport: i0
710
+ });
711
+ }
712
+ };
713
+ i0.ɵɵngDeclareClassMetadata({
714
+ minVersion: "12.0.0",
715
+ version: "22.2.6",
716
+ ngImport: i0,
717
+ type: CascadeSelectItemIndicator,
718
+ decorators: [{
719
+ type: Directive,
720
+ args: [{
721
+ selector: "[cascadeSelectItemIndicator]",
722
+ exportAs: "cascadeSelectItemIndicator"
723
+ }]
724
+ }],
725
+ ctorParameters: () => [],
726
+ propDecorators: { keepMounted: [{
727
+ type: i0.Input,
728
+ args: [{
729
+ isSignal: true,
730
+ alias: "cascadeSelectItemIndicator",
731
+ required: false
732
+ }]
733
+ }] }
734
+ });
735
+ var CascadeSelectPopup = class CascadeSelectPopup {
736
+ constructor() {
737
+ this.root = inject(CascadeSelectRoot);
738
+ this.state = computed(() => ({
739
+ open: this.root.overlay.open(),
740
+ ...this.root.placed()
741
+ }), ...ngDevMode ? [{ debugName: "state" }] : /* istanbul ignore next */ []);
742
+ this.data = computed(() => {
743
+ const status = this.root.overlay.presence.status();
744
+ const state = this.state();
745
+ return dataValues({
746
+ ...state,
747
+ closed: !state.open,
748
+ "starting-style": status === "starting",
749
+ "ending-style": status === "ending"
750
+ });
751
+ }, ...ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []);
752
+ registerHost(this.root.overlay.popup);
753
+ }
754
+ static {
755
+ this.ɵfac = i0.ɵɵngDeclareFactory({
756
+ minVersion: "12.0.0",
757
+ version: "22.2.6",
758
+ ngImport: i0,
759
+ type: CascadeSelectPopup,
760
+ deps: [],
761
+ target: i0.ɵɵFactoryTarget.Directive
762
+ });
763
+ }
764
+ static {
765
+ this.ɵdir = i0.ɵɵngDeclareDirective({
766
+ minVersion: "14.0.0",
767
+ version: "22.2.6",
768
+ type: CascadeSelectPopup,
769
+ isStandalone: true,
770
+ selector: "[cascadeSelectPopup]",
771
+ host: {
772
+ attributes: { "data-primitives-part": "cascade-select-popup" },
773
+ properties: {
774
+ "attr.data-open": "data().open",
775
+ "attr.data-closed": "data().closed",
776
+ "attr.data-side": "data().side",
777
+ "attr.data-align": "data().align",
778
+ "attr.data-starting-style": "data()['starting-style']",
779
+ "attr.data-ending-style": "data()['ending-style']"
780
+ }
781
+ },
782
+ exportAs: ["cascadeSelectPopup"],
783
+ ngImport: i0
784
+ });
785
+ }
786
+ };
787
+ i0.ɵɵngDeclareClassMetadata({
788
+ minVersion: "12.0.0",
789
+ version: "22.2.6",
790
+ ngImport: i0,
791
+ type: CascadeSelectPopup,
792
+ decorators: [{
793
+ type: Directive,
794
+ args: [{
795
+ selector: "[cascadeSelectPopup]",
796
+ exportAs: "cascadeSelectPopup",
797
+ host: {
798
+ "data-primitives-part": "cascade-select-popup",
799
+ "[attr.data-open]": "data().open",
800
+ "[attr.data-closed]": "data().closed",
801
+ "[attr.data-side]": "data().side",
802
+ "[attr.data-align]": "data().align",
803
+ "[attr.data-starting-style]": "data()['starting-style']",
804
+ "[attr.data-ending-style]": "data()['ending-style']"
805
+ }
806
+ }]
807
+ }],
808
+ ctorParameters: () => []
809
+ });
810
+ var CascadeSelectPortal = class CascadeSelectPortal {
811
+ constructor() {
812
+ this.options = input({}, {
813
+ ...ngDevMode ? { debugName: "options" } : /* istanbul ignore next */ {},
814
+ alias: "cascadeSelectPortal",
815
+ transform: portalOptions
816
+ });
817
+ mountPortal(inject(CascadeSelectRoot).overlay.presence.mounted, this.options);
818
+ }
819
+ static {
820
+ this.ɵfac = i0.ɵɵngDeclareFactory({
821
+ minVersion: "12.0.0",
822
+ version: "22.2.6",
823
+ ngImport: i0,
824
+ type: CascadeSelectPortal,
825
+ deps: [],
826
+ target: i0.ɵɵFactoryTarget.Directive
827
+ });
828
+ }
829
+ static {
830
+ this.ɵdir = i0.ɵɵngDeclareDirective({
831
+ minVersion: "17.1.0",
832
+ version: "22.2.6",
833
+ type: CascadeSelectPortal,
834
+ isStandalone: true,
835
+ selector: "[cascadeSelectPortal]",
836
+ inputs: { options: {
837
+ classPropertyName: "options",
838
+ publicName: "cascadeSelectPortal",
839
+ isSignal: true,
840
+ isRequired: false,
841
+ transformFunction: null
842
+ } },
843
+ ngImport: i0
844
+ });
845
+ }
846
+ };
847
+ i0.ɵɵngDeclareClassMetadata({
848
+ minVersion: "12.0.0",
849
+ version: "22.2.6",
850
+ ngImport: i0,
851
+ type: CascadeSelectPortal,
852
+ decorators: [{
853
+ type: Directive,
854
+ args: [{ selector: "[cascadeSelectPortal]" }]
855
+ }],
856
+ ctorParameters: () => [],
857
+ propDecorators: { options: [{
858
+ type: i0.Input,
859
+ args: [{
860
+ isSignal: true,
861
+ alias: "cascadeSelectPortal",
862
+ required: false
863
+ }]
864
+ }] }
865
+ });
866
+ const NEVER = /* @__PURE__ */ new Set();
867
+ var CascadeSelectPositioner = class CascadeSelectPositioner {
868
+ constructor() {
869
+ this.root = inject(CascadeSelectRoot);
870
+ this.side = input(void 0, ...ngDevMode ? [{ debugName: "side" }] : /* istanbul ignore next */ []);
871
+ this.align = input(void 0, ...ngDevMode ? [{ debugName: "align" }] : /* istanbul ignore next */ []);
872
+ this.sideOffset = input(4, ...ngDevMode ? [{ debugName: "sideOffset" }] : /* istanbul ignore next */ []);
873
+ this.alignOffset = input(void 0, ...ngDevMode ? [{ debugName: "alignOffset" }] : /* istanbul ignore next */ []);
874
+ this.collisionPadding = input(void 0, ...ngDevMode ? [{ debugName: "collisionPadding" }] : /* istanbul ignore next */ []);
875
+ this.anchor = input(void 0, ...ngDevMode ? [{ debugName: "anchor" }] : /* istanbul ignore next */ []);
876
+ this.state = computed(() => ({
877
+ open: this.root.overlay.open(),
878
+ ...this.root.placed()
879
+ }), ...ngDevMode ? [{ debugName: "state" }] : /* istanbul ignore next */ []);
880
+ this.data = computed(() => dataValues({
881
+ ...this.state(),
882
+ closed: !this.state().open
883
+ }), ...ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []);
884
+ const overlay = this.root.overlay;
885
+ const positioner = registerHost(overlay.positioner);
886
+ positionOverlay(this, {
887
+ side: "bottom",
888
+ align: "start"
889
+ }, {
890
+ anchor: overlay.trigger,
891
+ positioner,
892
+ mounted: overlay.presence.mounted
893
+ }, this.root.placed);
894
+ afterRenderEffect((onCleanup) => {
895
+ const open = overlay.open();
896
+ const trigger = overlay.trigger();
897
+ if (!open) return;
898
+ untracked(() => {
899
+ onCleanup(openOverlaySession(positioner.ownerDocument, {
900
+ elements: () => [positioner],
901
+ ignore: () => [trigger],
902
+ dismiss: (reason, event) => overlay.setOpen(false, reason, event),
903
+ returnFocus: {
904
+ when: NEVER,
905
+ reason: () => overlay.lastReason.current,
906
+ to: () => trigger
907
+ }
908
+ }).end);
909
+ });
910
+ });
911
+ }
912
+ static {
913
+ this.ɵfac = i0.ɵɵngDeclareFactory({
914
+ minVersion: "12.0.0",
915
+ version: "22.2.6",
916
+ ngImport: i0,
917
+ type: CascadeSelectPositioner,
918
+ deps: [],
919
+ target: i0.ɵɵFactoryTarget.Directive
920
+ });
921
+ }
922
+ static {
923
+ this.ɵdir = i0.ɵɵngDeclareDirective({
924
+ minVersion: "17.1.0",
925
+ version: "22.2.6",
926
+ type: CascadeSelectPositioner,
927
+ isStandalone: true,
928
+ selector: "[cascadeSelectPositioner]",
929
+ inputs: {
930
+ side: {
931
+ classPropertyName: "side",
932
+ publicName: "side",
933
+ isSignal: true,
934
+ isRequired: false,
935
+ transformFunction: null
936
+ },
937
+ align: {
938
+ classPropertyName: "align",
939
+ publicName: "align",
940
+ isSignal: true,
941
+ isRequired: false,
942
+ transformFunction: null
943
+ },
944
+ sideOffset: {
945
+ classPropertyName: "sideOffset",
946
+ publicName: "sideOffset",
947
+ isSignal: true,
948
+ isRequired: false,
949
+ transformFunction: null
950
+ },
951
+ alignOffset: {
952
+ classPropertyName: "alignOffset",
953
+ publicName: "alignOffset",
954
+ isSignal: true,
955
+ isRequired: false,
956
+ transformFunction: null
957
+ },
958
+ collisionPadding: {
959
+ classPropertyName: "collisionPadding",
960
+ publicName: "collisionPadding",
961
+ isSignal: true,
962
+ isRequired: false,
963
+ transformFunction: null
964
+ },
965
+ anchor: {
966
+ classPropertyName: "anchor",
967
+ publicName: "anchor",
968
+ isSignal: true,
969
+ isRequired: false,
970
+ transformFunction: null
971
+ }
972
+ },
973
+ host: {
974
+ attributes: {
975
+ "role": "presentation",
976
+ "data-primitives-part": "cascade-select-positioner"
977
+ },
978
+ properties: {
979
+ "attr.hidden": "root.overlay.presence.mounted() ? null : ''",
980
+ "attr.data-open": "data().open",
981
+ "attr.data-closed": "data().closed",
982
+ "attr.data-side": "data().side",
983
+ "attr.data-align": "data().align"
984
+ }
985
+ },
986
+ exportAs: ["cascadeSelectPositioner"],
987
+ ngImport: i0
988
+ });
989
+ }
990
+ };
991
+ i0.ɵɵngDeclareClassMetadata({
992
+ minVersion: "12.0.0",
993
+ version: "22.2.6",
994
+ ngImport: i0,
995
+ type: CascadeSelectPositioner,
996
+ decorators: [{
997
+ type: Directive,
998
+ args: [{
999
+ selector: "[cascadeSelectPositioner]",
1000
+ exportAs: "cascadeSelectPositioner",
1001
+ host: {
1002
+ role: "presentation",
1003
+ "data-primitives-part": "cascade-select-positioner",
1004
+ "[attr.hidden]": "root.overlay.presence.mounted() ? null : ''",
1005
+ "[attr.data-open]": "data().open",
1006
+ "[attr.data-closed]": "data().closed",
1007
+ "[attr.data-side]": "data().side",
1008
+ "[attr.data-align]": "data().align"
1009
+ }
1010
+ }]
1011
+ }],
1012
+ ctorParameters: () => [],
1013
+ propDecorators: {
1014
+ side: [{
1015
+ type: i0.Input,
1016
+ args: [{
1017
+ isSignal: true,
1018
+ alias: "side",
1019
+ required: false
1020
+ }]
1021
+ }],
1022
+ align: [{
1023
+ type: i0.Input,
1024
+ args: [{
1025
+ isSignal: true,
1026
+ alias: "align",
1027
+ required: false
1028
+ }]
1029
+ }],
1030
+ sideOffset: [{
1031
+ type: i0.Input,
1032
+ args: [{
1033
+ isSignal: true,
1034
+ alias: "sideOffset",
1035
+ required: false
1036
+ }]
1037
+ }],
1038
+ alignOffset: [{
1039
+ type: i0.Input,
1040
+ args: [{
1041
+ isSignal: true,
1042
+ alias: "alignOffset",
1043
+ required: false
1044
+ }]
1045
+ }],
1046
+ collisionPadding: [{
1047
+ type: i0.Input,
1048
+ args: [{
1049
+ isSignal: true,
1050
+ alias: "collisionPadding",
1051
+ required: false
1052
+ }]
1053
+ }],
1054
+ anchor: [{
1055
+ type: i0.Input,
1056
+ args: [{
1057
+ isSignal: true,
1058
+ alias: "anchor",
1059
+ required: false
1060
+ }]
1061
+ }]
1062
+ }
1063
+ });
1064
+ const TYPEAHEAD_SPACE = 500;
1065
+ var CascadeSelectTrigger = class CascadeSelectTrigger {
1066
+ constructor() {
1067
+ this.root = inject(CascadeSelectRoot);
1068
+ this.state = computed(() => ({
1069
+ open: this.root.overlay.open(),
1070
+ disabled: this.root.isDisabled(),
1071
+ placeholder: this.root.selected().length === 0
1072
+ }), ...ngDevMode ? [{ debugName: "state" }] : /* istanbul ignore next */ []);
1073
+ this.data = computed(() => dataValues(this.state()), ...ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []);
1074
+ this.controls = computed(() => this.state().open ? this.root.levels().map((_, depth) => this.root.levelId(depth)).join(" ") : null, ...ngDevMode ? [{ debugName: "controls" }] : /* istanbul ignore next */ []);
1075
+ this.activeId = computed(() => {
1076
+ const active = this.root.active();
1077
+ const depth = active.length - 1;
1078
+ const highlighted = active[depth];
1079
+ return this.state().open && highlighted !== void 0 ? this.root.itemId(depth, highlighted) : null;
1080
+ }, ...ngDevMode ? [{ debugName: "activeId" }] : /* istanbul ignore next */ []);
1081
+ this.String = String;
1082
+ this.typeahead = createTypeahead();
1083
+ this.lastTyped = 0;
1084
+ this.flush = injectFlush();
1085
+ this.direction = injectProvidedDirection();
1086
+ const host = registerHost(this.root.overlay.singleTrigger);
1087
+ this.host = host;
1088
+ const { field } = this.root;
1089
+ writeFieldAria(field, host, {
1090
+ "aria-labelledby": field.labelledBy,
1091
+ "aria-describedby": field.describedBy,
1092
+ "aria-invalid": field.ariaInvalid
1093
+ });
1094
+ afterNextRender(() => {
1095
+ if (host.id === "") host.id = this.root.overlay.triggerId;
1096
+ this.root.triggerElementId.set(host.id);
1097
+ });
1098
+ }
1099
+ onClick(event) {
1100
+ const root = this.root;
1101
+ if (root.overlay.open()) root.overlay.setOpen(false, "trigger-press", event);
1102
+ else root.openOn(root.initialActive(), "trigger-press", event);
1103
+ }
1104
+ setActive(active) {
1105
+ this.root.setActive(active);
1106
+ this.flush();
1107
+ }
1108
+ onKeyDown(event) {
1109
+ const root = this.root;
1110
+ if (root.isDisabled()) return;
1111
+ const items = root.items();
1112
+ const open = root.overlay.open();
1113
+ const active = root.active();
1114
+ const depth = active.length - 1;
1115
+ const level = root.levels()[depth] ?? [];
1116
+ const highlighted = active[depth];
1117
+ const index = level.findIndex((item) => item.value === highlighted);
1118
+ const current = level[index];
1119
+ const typing = event.key === " " && Date.now() - this.lastTyped < TYPEAHEAD_SPACE;
1120
+ if (event.key.length === 1 && event.key !== " " || typing) {
1121
+ if (event.ctrlKey || event.metaKey || event.altKey) return;
1122
+ event.preventDefault();
1123
+ this.lastTyped = Date.now();
1124
+ if (!open) {
1125
+ const value = root.selected();
1126
+ const target = items[this.typeahead.match(event.key, items.map((item) => item.label), items.findIndex((item) => item.value === value[0]))]?.value;
1127
+ if (target !== void 0) root.openOn([target], "list-navigation", event);
1128
+ return;
1129
+ }
1130
+ const target = level[this.typeahead.match(event.key, level.map((item) => item.label), index)]?.value;
1131
+ if (target !== void 0) this.setActive([...active.slice(0, depth), target]);
1132
+ return;
1133
+ }
1134
+ if (!open) switch (event.key) {
1135
+ case "ArrowDown":
1136
+ case "ArrowUp":
1137
+ case "Enter":
1138
+ case " ":
1139
+ event.preventDefault();
1140
+ root.openOn(root.initialActive(), "list-navigation", event);
1141
+ return;
1142
+ case "Home":
1143
+ case "End": {
1144
+ event.preventDefault();
1145
+ const target = (event.key === "Home" ? items[0] : items.at(-1))?.value;
1146
+ root.openOn(target === void 0 ? [] : [target], "list-navigation", event);
1147
+ return;
1148
+ }
1149
+ default: return;
1150
+ }
1151
+ if (event.key === "Tab") {
1152
+ if (current !== void 0 && !current.disabled && (root.changeOnSelect() || !hasCascadeChildren(current))) root.choose(active, "focus-out", event);
1153
+ else root.overlay.setOpen(false, "focus-out", event);
1154
+ return;
1155
+ }
1156
+ const highlightAt = (next) => {
1157
+ const target = level[next]?.value;
1158
+ if (target !== void 0) this.setActive([...active.slice(0, depth), target]);
1159
+ };
1160
+ const enterLevel = () => {
1161
+ if (current === void 0 || current.disabled) return;
1162
+ const first = firstItem(current.children ?? []);
1163
+ if (first !== void 0) this.setActive([...active, first]);
1164
+ };
1165
+ const rtl = getDirection(this.host, this.direction()) === "rtl";
1166
+ switch (cascadeKeyAction(event, rtl)) {
1167
+ case "next":
1168
+ event.preventDefault();
1169
+ highlightAt(Math.min(index + 1, level.length - 1));
1170
+ return;
1171
+ case "previous":
1172
+ event.preventDefault();
1173
+ highlightAt(Math.max(index - 1, 0));
1174
+ return;
1175
+ case "first":
1176
+ event.preventDefault();
1177
+ highlightAt(0);
1178
+ return;
1179
+ case "last":
1180
+ event.preventDefault();
1181
+ highlightAt(level.length - 1);
1182
+ return;
1183
+ case "open-level":
1184
+ event.preventDefault();
1185
+ enterLevel();
1186
+ return;
1187
+ case "close-level":
1188
+ event.preventDefault();
1189
+ if (depth > 0) this.setActive(active.slice(0, -1));
1190
+ return;
1191
+ case "choose":
1192
+ event.preventDefault();
1193
+ if (current === void 0 || current.disabled) return;
1194
+ if (hasCascadeChildren(current)) {
1195
+ if (root.changeOnSelect()) root.choose(active, "item-press", event, true);
1196
+ enterLevel();
1197
+ return;
1198
+ }
1199
+ root.choose(active, "item-press", event);
1200
+ return;
1201
+ }
1202
+ }
1203
+ static {
1204
+ this.ɵfac = i0.ɵɵngDeclareFactory({
1205
+ minVersion: "12.0.0",
1206
+ version: "22.2.6",
1207
+ ngImport: i0,
1208
+ type: CascadeSelectTrigger,
1209
+ deps: [],
1210
+ target: i0.ɵɵFactoryTarget.Directive
1211
+ });
1212
+ }
1213
+ static {
1214
+ this.ɵdir = i0.ɵɵngDeclareDirective({
1215
+ minVersion: "14.0.0",
1216
+ version: "22.2.6",
1217
+ type: CascadeSelectTrigger,
1218
+ isStandalone: true,
1219
+ selector: "[cascadeSelectTrigger]",
1220
+ host: {
1221
+ attributes: {
1222
+ "type": "button",
1223
+ "role": "combobox",
1224
+ "aria-haspopup": "listbox",
1225
+ "data-primitives-part": "cascade-select-trigger"
1226
+ },
1227
+ listeners: {
1228
+ "click": "onClick($event)",
1229
+ "keydown": "onKeyDown($event)",
1230
+ "focus": "root.field.focused()",
1231
+ "blur": "root.field.blurred()"
1232
+ },
1233
+ properties: {
1234
+ "attr.disabled": "data().disabled",
1235
+ "attr.aria-expanded": "String(state().open)",
1236
+ "attr.aria-controls": "controls()",
1237
+ "attr.aria-activedescendant": "activeId()",
1238
+ "attr.aria-required": "root.required() ? 'true' : null",
1239
+ "attr.data-invalid": "root.field.data().invalid",
1240
+ "attr.data-valid": "root.field.data().valid",
1241
+ "attr.data-dirty": "root.field.data().dirty",
1242
+ "attr.data-touched": "root.field.data().touched",
1243
+ "attr.data-filled": "root.field.data().filled",
1244
+ "attr.data-focused": "root.field.data().focused",
1245
+ "attr.data-popup-open": "data().open",
1246
+ "attr.data-disabled": "data().disabled",
1247
+ "attr.data-placeholder": "data().placeholder"
1248
+ }
1249
+ },
1250
+ exportAs: ["cascadeSelectTrigger"],
1251
+ ngImport: i0
1252
+ });
1253
+ }
1254
+ };
1255
+ i0.ɵɵngDeclareClassMetadata({
1256
+ minVersion: "12.0.0",
1257
+ version: "22.2.6",
1258
+ ngImport: i0,
1259
+ type: CascadeSelectTrigger,
1260
+ decorators: [{
1261
+ type: Directive,
1262
+ args: [{
1263
+ selector: "[cascadeSelectTrigger]",
1264
+ exportAs: "cascadeSelectTrigger",
1265
+ host: {
1266
+ type: "button",
1267
+ role: "combobox",
1268
+ "aria-haspopup": "listbox",
1269
+ "data-primitives-part": "cascade-select-trigger",
1270
+ "[attr.disabled]": "data().disabled",
1271
+ "[attr.aria-expanded]": "String(state().open)",
1272
+ "[attr.aria-controls]": "controls()",
1273
+ "[attr.aria-activedescendant]": "activeId()",
1274
+ "[attr.aria-required]": "root.required() ? 'true' : null",
1275
+ "[attr.data-invalid]": "root.field.data().invalid",
1276
+ "[attr.data-valid]": "root.field.data().valid",
1277
+ "[attr.data-dirty]": "root.field.data().dirty",
1278
+ "[attr.data-touched]": "root.field.data().touched",
1279
+ "[attr.data-filled]": "root.field.data().filled",
1280
+ "[attr.data-focused]": "root.field.data().focused",
1281
+ "[attr.data-popup-open]": "data().open",
1282
+ "[attr.data-disabled]": "data().disabled",
1283
+ "[attr.data-placeholder]": "data().placeholder",
1284
+ "(click)": "onClick($event)",
1285
+ "(keydown)": "onKeyDown($event)",
1286
+ "(focus)": "root.field.focused()",
1287
+ "(blur)": "root.field.blurred()"
1288
+ }
1289
+ }]
1290
+ }],
1291
+ ctorParameters: () => []
1292
+ });
1293
+ var CascadeSelectValue = class CascadeSelectValue {
1294
+ constructor() {
1295
+ this.root = inject(CascadeSelectRoot);
1296
+ this.placeholder = input("", ...ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ []);
1297
+ this.separator = input(void 0, ...ngDevMode ? [{ debugName: "separator" }] : /* istanbul ignore next */ []);
1298
+ this.label = computed(() => {
1299
+ const labels = (cascadePathItems(this.root.items(), this.root.selected()) ?? []).map((item) => item.label);
1300
+ if (labels.length === 0) return;
1301
+ const separator = this.separator();
1302
+ return separator === void 0 ? labels.at(-1) : labels.join(separator);
1303
+ }, ...ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ []);
1304
+ this.state = computed(() => ({ placeholder: this.label() === void 0 }), ...ngDevMode ? [{ debugName: "state" }] : /* istanbul ignore next */ []);
1305
+ this.data = computed(() => dataValues(this.state()), ...ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []);
1306
+ this.text = computed(() => this.label() ?? this.placeholder(), ...ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []);
1307
+ }
1308
+ static {
1309
+ this.ɵfac = i0.ɵɵngDeclareFactory({
1310
+ minVersion: "12.0.0",
1311
+ version: "22.2.6",
1312
+ ngImport: i0,
1313
+ type: CascadeSelectValue,
1314
+ deps: [],
1315
+ target: i0.ɵɵFactoryTarget.Directive
1316
+ });
1317
+ }
1318
+ static {
1319
+ this.ɵdir = i0.ɵɵngDeclareDirective({
1320
+ minVersion: "17.1.0",
1321
+ version: "22.2.6",
1322
+ type: CascadeSelectValue,
1323
+ isStandalone: true,
1324
+ selector: "[cascadeSelectValue]",
1325
+ inputs: {
1326
+ placeholder: {
1327
+ classPropertyName: "placeholder",
1328
+ publicName: "placeholder",
1329
+ isSignal: true,
1330
+ isRequired: false,
1331
+ transformFunction: null
1332
+ },
1333
+ separator: {
1334
+ classPropertyName: "separator",
1335
+ publicName: "separator",
1336
+ isSignal: true,
1337
+ isRequired: false,
1338
+ transformFunction: null
1339
+ }
1340
+ },
1341
+ host: {
1342
+ attributes: { "data-primitives-part": "cascade-select-value" },
1343
+ properties: {
1344
+ "attr.data-placeholder": "data().placeholder",
1345
+ "textContent": "text()"
1346
+ }
1347
+ },
1348
+ exportAs: ["cascadeSelectValue"],
1349
+ ngImport: i0
1350
+ });
1351
+ }
1352
+ };
1353
+ i0.ɵɵngDeclareClassMetadata({
1354
+ minVersion: "12.0.0",
1355
+ version: "22.2.6",
1356
+ ngImport: i0,
1357
+ type: CascadeSelectValue,
1358
+ decorators: [{
1359
+ type: Directive,
1360
+ args: [{
1361
+ selector: "[cascadeSelectValue]",
1362
+ exportAs: "cascadeSelectValue",
1363
+ host: {
1364
+ "data-primitives-part": "cascade-select-value",
1365
+ "[attr.data-placeholder]": "data().placeholder",
1366
+ "[textContent]": "text()"
1367
+ }
1368
+ }]
1369
+ }],
1370
+ propDecorators: {
1371
+ placeholder: [{
1372
+ type: i0.Input,
1373
+ args: [{
1374
+ isSignal: true,
1375
+ alias: "placeholder",
1376
+ required: false
1377
+ }]
1378
+ }],
1379
+ separator: [{
1380
+ type: i0.Input,
1381
+ args: [{
1382
+ isSignal: true,
1383
+ alias: "separator",
1384
+ required: false
1385
+ }]
1386
+ }]
1387
+ }
1388
+ });
1389
+ export { CascadeSelectItem, CascadeSelectItemIndicator, CascadeSelectLevel, CascadeSelectPopup, CascadeSelectPortal, CascadeSelectPositioner, CascadeSelectRoot, CascadeSelectTrigger, CascadeSelectValue };
1390
+
1391
+ //# sourceMappingURL=fragiola-primitives-angular-cascade-select.mjs.map