ngwr 10.2.0 → 11.0.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 (471) hide show
  1. package/README.md +39 -19
  2. package/anchor/styles/_index.scss +4 -4
  3. package/back-top/styles/_index.scss +6 -1
  4. package/blur-text/styles/_index.scss +13 -0
  5. package/button/styles/_index.scss +11 -6
  6. package/carousel/styles/_index.scss +13 -2
  7. package/cascader/styles/_index.scss +2 -2
  8. package/circular-text/styles/_index.scss +2 -0
  9. package/collapse/styles/_index.scss +1 -1
  10. package/color-picker/styles/_index.scss +6 -1
  11. package/compare/styles/_index.scss +1 -2
  12. package/context-menu/styles/_index.scss +6 -1
  13. package/descriptions/styles/_index.scss +2 -2
  14. package/dialog/styles/_index.scss +38 -0
  15. package/drawer/styles/_index.scss +20 -1
  16. package/dropdown/styles/_index.scss +19 -5
  17. package/empty/styles/_index.scss +10 -0
  18. package/fesm2022/ngwr-action-sheet.mjs +15 -5
  19. package/fesm2022/ngwr-action-sheet.mjs.map +1 -1
  20. package/fesm2022/ngwr-affix.mjs +43 -16
  21. package/fesm2022/ngwr-affix.mjs.map +1 -1
  22. package/fesm2022/ngwr-alert.mjs +3 -3
  23. package/fesm2022/ngwr-anchor.mjs +20 -8
  24. package/fesm2022/ngwr-anchor.mjs.map +1 -1
  25. package/fesm2022/ngwr-aurora.mjs +4 -4
  26. package/fesm2022/ngwr-aurora.mjs.map +1 -1
  27. package/fesm2022/ngwr-avatar.mjs +33 -9
  28. package/fesm2022/ngwr-avatar.mjs.map +1 -1
  29. package/fesm2022/ngwr-back-top.mjs +8 -4
  30. package/fesm2022/ngwr-back-top.mjs.map +1 -1
  31. package/fesm2022/ngwr-badge.mjs +6 -6
  32. package/fesm2022/ngwr-badge.mjs.map +1 -1
  33. package/fesm2022/ngwr-bar-chart.mjs +32 -11
  34. package/fesm2022/ngwr-bar-chart.mjs.map +1 -1
  35. package/fesm2022/ngwr-blur-text.mjs +4 -4
  36. package/fesm2022/ngwr-blur-text.mjs.map +1 -1
  37. package/fesm2022/ngwr-border-glow.mjs +4 -4
  38. package/fesm2022/ngwr-border-glow.mjs.map +1 -1
  39. package/fesm2022/ngwr-breadcrumbs.mjs +9 -8
  40. package/fesm2022/ngwr-breadcrumbs.mjs.map +1 -1
  41. package/fesm2022/ngwr-burger.mjs +11 -6
  42. package/fesm2022/ngwr-burger.mjs.map +1 -1
  43. package/fesm2022/ngwr-button-testing.mjs +96 -0
  44. package/fesm2022/ngwr-button-testing.mjs.map +1 -0
  45. package/fesm2022/ngwr-button.mjs +89 -24
  46. package/fesm2022/ngwr-button.mjs.map +1 -1
  47. package/fesm2022/ngwr-calendar-heatmap.mjs +42 -10
  48. package/fesm2022/ngwr-calendar-heatmap.mjs.map +1 -1
  49. package/fesm2022/ngwr-calendar.mjs +108 -9
  50. package/fesm2022/ngwr-calendar.mjs.map +1 -1
  51. package/fesm2022/ngwr-card.mjs +10 -10
  52. package/fesm2022/ngwr-card.mjs.map +1 -1
  53. package/fesm2022/ngwr-carousel-testing.mjs +377 -0
  54. package/fesm2022/ngwr-carousel-testing.mjs.map +1 -0
  55. package/fesm2022/ngwr-carousel.mjs +72 -18
  56. package/fesm2022/ngwr-carousel.mjs.map +1 -1
  57. package/fesm2022/ngwr-cascader-testing.mjs +534 -0
  58. package/fesm2022/ngwr-cascader-testing.mjs.map +1 -0
  59. package/fesm2022/ngwr-cascader.mjs +4 -4
  60. package/fesm2022/ngwr-cascader.mjs.map +1 -1
  61. package/fesm2022/ngwr-checkbox-testing.mjs +90 -0
  62. package/fesm2022/ngwr-checkbox-testing.mjs.map +1 -0
  63. package/fesm2022/ngwr-checkbox.mjs +15 -9
  64. package/fesm2022/ngwr-checkbox.mjs.map +1 -1
  65. package/fesm2022/ngwr-circular-text.mjs +4 -4
  66. package/fesm2022/ngwr-circular-text.mjs.map +1 -1
  67. package/fesm2022/ngwr-click-spark.mjs +4 -4
  68. package/fesm2022/ngwr-click-spark.mjs.map +1 -1
  69. package/fesm2022/ngwr-clipboard.mjs +18 -4
  70. package/fesm2022/ngwr-clipboard.mjs.map +1 -1
  71. package/fesm2022/ngwr-collapse-testing.mjs +368 -0
  72. package/fesm2022/ngwr-collapse-testing.mjs.map +1 -0
  73. package/fesm2022/ngwr-collapse.mjs +9 -9
  74. package/fesm2022/ngwr-color-picker.mjs +139 -19
  75. package/fesm2022/ngwr-color-picker.mjs.map +1 -1
  76. package/fesm2022/ngwr-command-palette-testing.mjs +589 -0
  77. package/fesm2022/ngwr-command-palette-testing.mjs.map +1 -0
  78. package/fesm2022/ngwr-command-palette.mjs +60 -10
  79. package/fesm2022/ngwr-command-palette.mjs.map +1 -1
  80. package/fesm2022/ngwr-compare.mjs +105 -15
  81. package/fesm2022/ngwr-compare.mjs.map +1 -1
  82. package/fesm2022/ngwr-confetti.mjs +3 -3
  83. package/fesm2022/ngwr-config.mjs +106 -0
  84. package/fesm2022/ngwr-config.mjs.map +1 -0
  85. package/fesm2022/ngwr-context-menu-testing.mjs +631 -0
  86. package/fesm2022/ngwr-context-menu-testing.mjs.map +1 -0
  87. package/fesm2022/ngwr-context-menu.mjs +104 -18
  88. package/fesm2022/ngwr-context-menu.mjs.map +1 -1
  89. package/fesm2022/ngwr-cookie.mjs +8 -4
  90. package/fesm2022/ngwr-cookie.mjs.map +1 -1
  91. package/fesm2022/ngwr-counter.mjs +17 -9
  92. package/fesm2022/ngwr-counter.mjs.map +1 -1
  93. package/fesm2022/ngwr-date-adapter-fns.mjs +3 -3
  94. package/fesm2022/ngwr-date-adapter-luxon.mjs +55 -7
  95. package/fesm2022/ngwr-date-adapter-luxon.mjs.map +1 -1
  96. package/fesm2022/ngwr-date-adapter.mjs +57 -11
  97. package/fesm2022/ngwr-date-adapter.mjs.map +1 -1
  98. package/fesm2022/ngwr-date-picker-testing.mjs +766 -0
  99. package/fesm2022/ngwr-date-picker-testing.mjs.map +1 -0
  100. package/fesm2022/ngwr-date-picker.mjs +409 -57
  101. package/fesm2022/ngwr-date-picker.mjs.map +1 -1
  102. package/fesm2022/ngwr-decrypt-text.mjs +30 -12
  103. package/fesm2022/ngwr-decrypt-text.mjs.map +1 -1
  104. package/fesm2022/ngwr-density.mjs +6 -6
  105. package/fesm2022/ngwr-descriptions.mjs +6 -6
  106. package/fesm2022/ngwr-dialog-testing.mjs +89 -0
  107. package/fesm2022/ngwr-dialog-testing.mjs.map +1 -0
  108. package/fesm2022/ngwr-dialog.mjs +33 -17
  109. package/fesm2022/ngwr-dialog.mjs.map +1 -1
  110. package/fesm2022/ngwr-directives.mjs +48 -24
  111. package/fesm2022/ngwr-directives.mjs.map +1 -1
  112. package/fesm2022/ngwr-divider.mjs +3 -3
  113. package/fesm2022/ngwr-donut-chart.mjs +24 -7
  114. package/fesm2022/ngwr-donut-chart.mjs.map +1 -1
  115. package/fesm2022/ngwr-drag-drop.mjs +7 -7
  116. package/fesm2022/ngwr-drag-drop.mjs.map +1 -1
  117. package/fesm2022/ngwr-drawer-testing.mjs +250 -0
  118. package/fesm2022/ngwr-drawer-testing.mjs.map +1 -0
  119. package/fesm2022/ngwr-drawer.mjs +37 -19
  120. package/fesm2022/ngwr-drawer.mjs.map +1 -1
  121. package/fesm2022/ngwr-dropdown-testing.mjs +291 -0
  122. package/fesm2022/ngwr-dropdown-testing.mjs.map +1 -0
  123. package/fesm2022/ngwr-dropdown.mjs +19 -11
  124. package/fesm2022/ngwr-dropdown.mjs.map +1 -1
  125. package/fesm2022/ngwr-empty.mjs +26 -9
  126. package/fesm2022/ngwr-empty.mjs.map +1 -1
  127. package/fesm2022/ngwr-event-calendar.mjs +62 -15
  128. package/fesm2022/ngwr-event-calendar.mjs.map +1 -1
  129. package/fesm2022/ngwr-falling-text.mjs +4 -4
  130. package/fesm2022/ngwr-falling-text.mjs.map +1 -1
  131. package/fesm2022/ngwr-file-upload-testing.mjs +332 -0
  132. package/fesm2022/ngwr-file-upload-testing.mjs.map +1 -0
  133. package/fesm2022/ngwr-file-upload.mjs +3 -3
  134. package/fesm2022/ngwr-form-testing.mjs +451 -0
  135. package/fesm2022/ngwr-form-testing.mjs.map +1 -0
  136. package/fesm2022/ngwr-form.mjs +28 -12
  137. package/fesm2022/ngwr-form.mjs.map +1 -1
  138. package/fesm2022/ngwr-fuzzy-text.mjs +11 -4
  139. package/fesm2022/ngwr-fuzzy-text.mjs.map +1 -1
  140. package/fesm2022/ngwr-gauge.mjs +21 -7
  141. package/fesm2022/ngwr-gauge.mjs.map +1 -1
  142. package/fesm2022/ngwr-glitch-text.mjs +4 -4
  143. package/fesm2022/ngwr-glitch-text.mjs.map +1 -1
  144. package/fesm2022/ngwr-gradient-text.mjs +4 -4
  145. package/fesm2022/ngwr-gradient-text.mjs.map +1 -1
  146. package/fesm2022/ngwr-hotkey.mjs +31 -10
  147. package/fesm2022/ngwr-hotkey.mjs.map +1 -1
  148. package/fesm2022/ngwr-i18n-en.mjs +61 -0
  149. package/fesm2022/ngwr-i18n-en.mjs.map +1 -1
  150. package/fesm2022/ngwr-i18n-ru.mjs +59 -0
  151. package/fesm2022/ngwr-i18n-ru.mjs.map +1 -1
  152. package/fesm2022/ngwr-i18n.mjs +9 -9
  153. package/fesm2022/ngwr-icon.mjs +6 -6
  154. package/fesm2022/ngwr-image-cropper.mjs +26 -3
  155. package/fesm2022/ngwr-image-cropper.mjs.map +1 -1
  156. package/fesm2022/ngwr-input-number-testing.mjs +306 -0
  157. package/fesm2022/ngwr-input-number-testing.mjs.map +1 -0
  158. package/fesm2022/ngwr-input-number.mjs +37 -5
  159. package/fesm2022/ngwr-input-number.mjs.map +1 -1
  160. package/fesm2022/ngwr-input-otp-testing.mjs +419 -0
  161. package/fesm2022/ngwr-input-otp-testing.mjs.map +1 -0
  162. package/fesm2022/ngwr-input-otp.mjs +39 -8
  163. package/fesm2022/ngwr-input-otp.mjs.map +1 -1
  164. package/fesm2022/ngwr-input-testing.mjs +102 -0
  165. package/fesm2022/ngwr-input-testing.mjs.map +1 -0
  166. package/fesm2022/ngwr-input.mjs +62 -25
  167. package/fesm2022/ngwr-input.mjs.map +1 -1
  168. package/fesm2022/ngwr-keyboard.mjs +3 -3
  169. package/fesm2022/ngwr-knob.mjs +46 -10
  170. package/fesm2022/ngwr-knob.mjs.map +1 -1
  171. package/fesm2022/ngwr-layout.mjs +36 -20
  172. package/fesm2022/ngwr-layout.mjs.map +1 -1
  173. package/fesm2022/ngwr-lightbox.mjs +35 -8
  174. package/fesm2022/ngwr-lightbox.mjs.map +1 -1
  175. package/fesm2022/ngwr-line-chart.mjs +19 -6
  176. package/fesm2022/ngwr-line-chart.mjs.map +1 -1
  177. package/fesm2022/ngwr-list.mjs +14 -9
  178. package/fesm2022/ngwr-list.mjs.map +1 -1
  179. package/fesm2022/ngwr-loading-bar.mjs +71 -31
  180. package/fesm2022/ngwr-loading-bar.mjs.map +1 -1
  181. package/fesm2022/ngwr-markdown-testing.mjs +516 -0
  182. package/fesm2022/ngwr-markdown-testing.mjs.map +1 -0
  183. package/fesm2022/ngwr-markdown.mjs +1492 -0
  184. package/fesm2022/ngwr-markdown.mjs.map +1 -0
  185. package/fesm2022/ngwr-marquee.mjs +19 -8
  186. package/fesm2022/ngwr-marquee.mjs.map +1 -1
  187. package/fesm2022/ngwr-media.mjs +3 -3
  188. package/fesm2022/ngwr-mention-testing.mjs +513 -0
  189. package/fesm2022/ngwr-mention-testing.mjs.map +1 -0
  190. package/fesm2022/ngwr-mention.mjs +16 -7
  191. package/fesm2022/ngwr-mention.mjs.map +1 -1
  192. package/fesm2022/ngwr-meta.mjs +28 -13
  193. package/fesm2022/ngwr-meta.mjs.map +1 -1
  194. package/fesm2022/ngwr-meter-group.mjs +22 -8
  195. package/fesm2022/ngwr-meter-group.mjs.map +1 -1
  196. package/fesm2022/ngwr-overlay.mjs +57 -8
  197. package/fesm2022/ngwr-overlay.mjs.map +1 -1
  198. package/fesm2022/ngwr-page-header.mjs +3 -3
  199. package/fesm2022/ngwr-pagination-testing.mjs +389 -0
  200. package/fesm2022/ngwr-pagination-testing.mjs.map +1 -0
  201. package/fesm2022/ngwr-pagination.mjs +27 -11
  202. package/fesm2022/ngwr-pagination.mjs.map +1 -1
  203. package/fesm2022/ngwr-pipes.mjs +21 -21
  204. package/fesm2022/ngwr-platform.mjs +9 -9
  205. package/fesm2022/ngwr-popconfirm-testing.mjs +309 -0
  206. package/fesm2022/ngwr-popconfirm-testing.mjs.map +1 -0
  207. package/fesm2022/ngwr-popconfirm.mjs +99 -21
  208. package/fesm2022/ngwr-popconfirm.mjs.map +1 -1
  209. package/fesm2022/ngwr-popover-testing.mjs +316 -0
  210. package/fesm2022/ngwr-popover-testing.mjs.map +1 -0
  211. package/fesm2022/ngwr-popover.mjs +48 -10
  212. package/fesm2022/ngwr-popover.mjs.map +1 -1
  213. package/fesm2022/ngwr-progress.mjs +3 -3
  214. package/fesm2022/ngwr-pull-to-refresh.mjs +19 -4
  215. package/fesm2022/ngwr-pull-to-refresh.mjs.map +1 -1
  216. package/fesm2022/ngwr-qr.mjs +15 -5
  217. package/fesm2022/ngwr-qr.mjs.map +1 -1
  218. package/fesm2022/ngwr-radio-testing.mjs +392 -0
  219. package/fesm2022/ngwr-radio-testing.mjs.map +1 -0
  220. package/fesm2022/ngwr-radio.mjs +16 -9
  221. package/fesm2022/ngwr-radio.mjs.map +1 -1
  222. package/fesm2022/ngwr-rating-testing.mjs +384 -0
  223. package/fesm2022/ngwr-rating-testing.mjs.map +1 -0
  224. package/fesm2022/ngwr-rating.mjs +40 -5
  225. package/fesm2022/ngwr-rating.mjs.map +1 -1
  226. package/fesm2022/ngwr-result.mjs +12 -12
  227. package/fesm2022/ngwr-rotating-text.mjs +3 -3
  228. package/fesm2022/ngwr-scroll.mjs +3 -3
  229. package/fesm2022/ngwr-segmented-testing.mjs +512 -0
  230. package/fesm2022/ngwr-segmented-testing.mjs.map +1 -0
  231. package/fesm2022/ngwr-segmented.mjs +3 -3
  232. package/fesm2022/ngwr-select-testing.mjs +268 -0
  233. package/fesm2022/ngwr-select-testing.mjs.map +1 -0
  234. package/fesm2022/ngwr-select.mjs +96 -25
  235. package/fesm2022/ngwr-select.mjs.map +1 -1
  236. package/fesm2022/ngwr-shiny-text.mjs +7 -7
  237. package/fesm2022/ngwr-shiny-text.mjs.map +1 -1
  238. package/fesm2022/ngwr-sidebar.mjs +67 -14
  239. package/fesm2022/ngwr-sidebar.mjs.map +1 -1
  240. package/fesm2022/ngwr-skeleton.mjs +3 -3
  241. package/fesm2022/ngwr-slider-testing.mjs +478 -0
  242. package/fesm2022/ngwr-slider-testing.mjs.map +1 -0
  243. package/fesm2022/ngwr-slider.mjs +59 -15
  244. package/fesm2022/ngwr-slider.mjs.map +1 -1
  245. package/fesm2022/ngwr-sparkline.mjs +28 -8
  246. package/fesm2022/ngwr-sparkline.mjs.map +1 -1
  247. package/fesm2022/ngwr-speed-dial.mjs +39 -6
  248. package/fesm2022/ngwr-speed-dial.mjs.map +1 -1
  249. package/fesm2022/ngwr-spinner.mjs +14 -5
  250. package/fesm2022/ngwr-spinner.mjs.map +1 -1
  251. package/fesm2022/ngwr-splash-cursor.mjs +4 -4
  252. package/fesm2022/ngwr-splash-cursor.mjs.map +1 -1
  253. package/fesm2022/ngwr-split-text.mjs +4 -4
  254. package/fesm2022/ngwr-split-text.mjs.map +1 -1
  255. package/fesm2022/ngwr-splitter.mjs +72 -11
  256. package/fesm2022/ngwr-splitter.mjs.map +1 -1
  257. package/fesm2022/ngwr-spotlight-card.mjs +7 -7
  258. package/fesm2022/ngwr-spotlight-card.mjs.map +1 -1
  259. package/fesm2022/ngwr-squircle.mjs +6 -6
  260. package/fesm2022/ngwr-star-border.mjs +4 -4
  261. package/fesm2022/ngwr-star-border.mjs.map +1 -1
  262. package/fesm2022/ngwr-statistic.mjs +33 -16
  263. package/fesm2022/ngwr-statistic.mjs.map +1 -1
  264. package/fesm2022/ngwr-stepper-testing.mjs +477 -0
  265. package/fesm2022/ngwr-stepper-testing.mjs.map +1 -0
  266. package/fesm2022/ngwr-stepper.mjs +6 -6
  267. package/fesm2022/ngwr-storage.mjs +27 -17
  268. package/fesm2022/ngwr-storage.mjs.map +1 -1
  269. package/fesm2022/ngwr-switch-testing.mjs +77 -0
  270. package/fesm2022/ngwr-switch-testing.mjs.map +1 -0
  271. package/fesm2022/ngwr-switch.mjs +12 -6
  272. package/fesm2022/ngwr-switch.mjs.map +1 -1
  273. package/fesm2022/ngwr-table-testing.mjs +580 -0
  274. package/fesm2022/ngwr-table-testing.mjs.map +1 -0
  275. package/fesm2022/ngwr-table.mjs +105 -44
  276. package/fesm2022/ngwr-table.mjs.map +1 -1
  277. package/fesm2022/ngwr-tabs-testing.mjs +617 -0
  278. package/fesm2022/ngwr-tabs-testing.mjs.map +1 -0
  279. package/fesm2022/ngwr-tabs.mjs +44 -12
  280. package/fesm2022/ngwr-tabs.mjs.map +1 -1
  281. package/fesm2022/ngwr-textarea-testing.mjs +238 -0
  282. package/fesm2022/ngwr-textarea-testing.mjs.map +1 -0
  283. package/fesm2022/ngwr-textarea.mjs +35 -7
  284. package/fesm2022/ngwr-textarea.mjs.map +1 -1
  285. package/fesm2022/ngwr-theme.mjs +3 -3
  286. package/fesm2022/ngwr-tilt-card.mjs +7 -7
  287. package/fesm2022/ngwr-tilt-card.mjs.map +1 -1
  288. package/fesm2022/ngwr-timeline.mjs +6 -6
  289. package/fesm2022/ngwr-toast-testing.mjs +101 -0
  290. package/fesm2022/ngwr-toast-testing.mjs.map +1 -0
  291. package/fesm2022/ngwr-toast.mjs +55 -21
  292. package/fesm2022/ngwr-toast.mjs.map +1 -1
  293. package/fesm2022/ngwr-toolbar.mjs +3 -3
  294. package/fesm2022/ngwr-tour.mjs +67 -15
  295. package/fesm2022/ngwr-tour.mjs.map +1 -1
  296. package/fesm2022/ngwr-transfer-testing.mjs +538 -0
  297. package/fesm2022/ngwr-transfer-testing.mjs.map +1 -0
  298. package/fesm2022/ngwr-transfer.mjs +47 -16
  299. package/fesm2022/ngwr-transfer.mjs.map +1 -1
  300. package/fesm2022/ngwr-tree-testing.mjs +734 -0
  301. package/fesm2022/ngwr-tree-testing.mjs.map +1 -0
  302. package/fesm2022/ngwr-tree.mjs +75 -9
  303. package/fesm2022/ngwr-tree.mjs.map +1 -1
  304. package/fesm2022/ngwr-typewriter.mjs +7 -5
  305. package/fesm2022/ngwr-typewriter.mjs.map +1 -1
  306. package/fesm2022/ngwr-typography.mjs +3 -3
  307. package/fesm2022/ngwr-version.mjs +1 -1
  308. package/fesm2022/ngwr-version.mjs.map +1 -1
  309. package/fesm2022/ngwr-virtual-scroll.mjs +33 -7
  310. package/fesm2022/ngwr-virtual-scroll.mjs.map +1 -1
  311. package/fesm2022/ngwr-waves.mjs +5 -5
  312. package/fesm2022/ngwr-waves.mjs.map +1 -1
  313. package/fesm2022/ngwr-window.mjs +88 -18
  314. package/fesm2022/ngwr-window.mjs.map +1 -1
  315. package/gauge/styles/_index.scss +1 -1
  316. package/glitch-text/styles/_index.scss +4 -0
  317. package/i18n/en.json +56 -0
  318. package/i18n/ru.json +56 -0
  319. package/image-cropper/styles/_index.scss +13 -1
  320. package/input/styles/_index.scss +2 -2
  321. package/input-number/styles/_index.scss +7 -2
  322. package/knob/styles/_index.scss +8 -1
  323. package/layout/styles/_index.scss +3 -3
  324. package/lightbox/styles/_index.scss +10 -2
  325. package/line-chart/styles/_index.scss +6 -0
  326. package/llms-full.txt +151 -4
  327. package/llms.txt +57 -8
  328. package/loading-bar/styles/_index.scss +1 -2
  329. package/markdown/styles/_index.scss +296 -0
  330. package/marquee/styles/_index.scss +12 -0
  331. package/mcp/api.js +512 -0
  332. package/mcp/catalog.js +157 -0
  333. package/mcp/server.js +273 -0
  334. package/mcp/tools.js +366 -0
  335. package/meter-group/styles/_index.scss +1 -1
  336. package/package.json +186 -35
  337. package/pagination/styles/_index.scss +6 -6
  338. package/popover/styles/_index.scss +37 -5
  339. package/rating/styles/_index.scss +10 -0
  340. package/schematics/use/symbol-map.json +2 -0
  341. package/segmented/styles/_index.scss +7 -0
  342. package/select/styles/_index.scss +29 -9
  343. package/sidebar/styles/_index.scss +30 -5
  344. package/slider/styles/_index.scss +15 -0
  345. package/speed-dial/styles/_index.scss +20 -0
  346. package/split-text/styles/_index.scss +13 -0
  347. package/star-border/styles/_index.scss +2 -0
  348. package/stepper/styles/_index.scss +1 -1
  349. package/styles/_grid.scss +4 -4
  350. package/styles.scss +1 -0
  351. package/switch/styles/_index.scss +5 -3
  352. package/table/styles/_index.scss +22 -11
  353. package/tabs/styles/_index.scss +11 -1
  354. package/textarea/styles/_index.scss +5 -0
  355. package/theme/styles/_colors.scss +29 -13
  356. package/theme/styles/_dark.scss +11 -3
  357. package/theme/styles/_mixins.scss +3 -0
  358. package/timeline/styles/_index.scss +2 -2
  359. package/toast/styles/_index.scss +17 -8
  360. package/toolbar/styles/_index.scss +3 -3
  361. package/tour/styles/_index.scss +7 -1
  362. package/tree/styles/_index.scss +5 -3
  363. package/types/ngwr-action-sheet.d.ts +9 -1
  364. package/types/ngwr-affix.d.ts +7 -1
  365. package/types/ngwr-anchor.d.ts +8 -1
  366. package/types/ngwr-avatar.d.ts +13 -3
  367. package/types/ngwr-bar-chart.d.ts +16 -0
  368. package/types/ngwr-burger.d.ts +6 -2
  369. package/types/ngwr-button-testing.d.ts +85 -0
  370. package/types/ngwr-button.d.ts +58 -10
  371. package/types/ngwr-calendar-heatmap.d.ts +16 -2
  372. package/types/ngwr-calendar.d.ts +37 -1
  373. package/types/ngwr-carousel-testing.d.ts +257 -0
  374. package/types/ngwr-carousel.d.ts +20 -4
  375. package/types/ngwr-cascader-testing.d.ts +392 -0
  376. package/types/ngwr-checkbox-testing.d.ts +77 -0
  377. package/types/ngwr-checkbox.d.ts +7 -2
  378. package/types/ngwr-clipboard.d.ts +8 -1
  379. package/types/ngwr-collapse-testing.d.ts +290 -0
  380. package/types/ngwr-color-picker.d.ts +20 -11
  381. package/types/ngwr-command-palette-testing.d.ts +437 -0
  382. package/types/ngwr-command-palette.d.ts +25 -2
  383. package/types/ngwr-compare.d.ts +50 -2
  384. package/types/ngwr-config.d.ts +176 -0
  385. package/types/ngwr-context-menu-testing.d.ts +401 -0
  386. package/types/ngwr-context-menu.d.ts +65 -17
  387. package/types/ngwr-counter.d.ts +6 -1
  388. package/types/ngwr-date-adapter-luxon.d.ts +26 -0
  389. package/types/ngwr-date-picker-testing.d.ts +518 -0
  390. package/types/ngwr-date-picker.d.ts +128 -8
  391. package/types/ngwr-dialog-testing.d.ts +79 -0
  392. package/types/ngwr-dialog.d.ts +13 -0
  393. package/types/ngwr-directives.d.ts +10 -1
  394. package/types/ngwr-donut-chart.d.ts +8 -1
  395. package/types/ngwr-drawer-testing.d.ts +196 -0
  396. package/types/ngwr-drawer.d.ts +15 -0
  397. package/types/ngwr-dropdown-testing.d.ts +202 -0
  398. package/types/ngwr-dropdown.d.ts +7 -1
  399. package/types/ngwr-empty.d.ts +19 -4
  400. package/types/ngwr-event-calendar.d.ts +26 -1
  401. package/types/ngwr-file-upload-testing.d.ts +194 -0
  402. package/types/ngwr-form-testing.d.ts +379 -0
  403. package/types/ngwr-form.d.ts +17 -0
  404. package/types/ngwr-gauge.d.ts +13 -1
  405. package/types/ngwr-hotkey.d.ts +2 -0
  406. package/types/ngwr-image-cropper.d.ts +10 -0
  407. package/types/ngwr-input-number-testing.d.ts +226 -0
  408. package/types/ngwr-input-number.d.ts +29 -1
  409. package/types/ngwr-input-otp-testing.d.ts +299 -0
  410. package/types/ngwr-input-otp.d.ts +23 -2
  411. package/types/ngwr-input-testing.d.ts +84 -0
  412. package/types/ngwr-input.d.ts +20 -6
  413. package/types/ngwr-knob.d.ts +18 -0
  414. package/types/ngwr-layout.d.ts +1 -0
  415. package/types/ngwr-lightbox.d.ts +17 -3
  416. package/types/ngwr-line-chart.d.ts +9 -2
  417. package/types/ngwr-list.d.ts +7 -2
  418. package/types/ngwr-loading-bar.d.ts +4 -7
  419. package/types/ngwr-markdown-testing.d.ts +462 -0
  420. package/types/ngwr-markdown.d.ts +534 -0
  421. package/types/ngwr-marquee.d.ts +12 -2
  422. package/types/ngwr-mention-testing.d.ts +359 -0
  423. package/types/ngwr-meta.d.ts +4 -2
  424. package/types/ngwr-meter-group.d.ts +11 -1
  425. package/types/ngwr-overlay.d.ts +33 -2
  426. package/types/ngwr-pagination-testing.d.ts +291 -0
  427. package/types/ngwr-pagination.d.ts +7 -1
  428. package/types/ngwr-popconfirm-testing.d.ts +235 -0
  429. package/types/ngwr-popconfirm.d.ts +31 -21
  430. package/types/ngwr-popover-testing.d.ts +221 -0
  431. package/types/ngwr-popover.d.ts +19 -2
  432. package/types/ngwr-pull-to-refresh.d.ts +7 -0
  433. package/types/ngwr-qr.d.ts +9 -1
  434. package/types/ngwr-radio-testing.d.ts +296 -0
  435. package/types/ngwr-radio.d.ts +8 -2
  436. package/types/ngwr-rating-testing.d.ts +291 -0
  437. package/types/ngwr-rating.d.ts +23 -0
  438. package/types/ngwr-segmented-testing.d.ts +401 -0
  439. package/types/ngwr-select-testing.d.ts +175 -0
  440. package/types/ngwr-select.d.ts +45 -4
  441. package/types/ngwr-sidebar.d.ts +17 -2
  442. package/types/ngwr-slider-testing.d.ts +329 -0
  443. package/types/ngwr-slider.d.ts +35 -1
  444. package/types/ngwr-sparkline.d.ts +12 -2
  445. package/types/ngwr-speed-dial.d.ts +17 -18
  446. package/types/ngwr-spinner.d.ts +8 -1
  447. package/types/ngwr-splitter.d.ts +24 -1
  448. package/types/ngwr-statistic.d.ts +12 -2
  449. package/types/ngwr-stepper-testing.d.ts +346 -0
  450. package/types/ngwr-storage.d.ts +10 -1
  451. package/types/ngwr-switch-testing.d.ts +66 -0
  452. package/types/ngwr-switch.d.ts +7 -2
  453. package/types/ngwr-table-testing.d.ts +423 -0
  454. package/types/ngwr-table.d.ts +42 -0
  455. package/types/ngwr-tabs-testing.d.ts +470 -0
  456. package/types/ngwr-tabs.d.ts +9 -0
  457. package/types/ngwr-textarea-testing.d.ts +184 -0
  458. package/types/ngwr-textarea.d.ts +7 -2
  459. package/types/ngwr-toast-testing.d.ts +80 -0
  460. package/types/ngwr-toast.d.ts +19 -4
  461. package/types/ngwr-tour.d.ts +27 -0
  462. package/types/ngwr-transfer-testing.d.ts +444 -0
  463. package/types/ngwr-transfer.d.ts +16 -1
  464. package/types/ngwr-tree-testing.d.ts +501 -0
  465. package/types/ngwr-tree.d.ts +33 -0
  466. package/types/ngwr-version.d.ts +1 -1
  467. package/types/ngwr-virtual-scroll.d.ts +13 -1
  468. package/types/ngwr-window.d.ts +23 -2
  469. package/typewriter/styles/_index.scss +1 -1
  470. package/typography/styles/_index.scss +1 -1
  471. package/window/styles/_index.scss +32 -9
@@ -34,10 +34,10 @@ class WrResult {
34
34
  ...(ngDevMode ? [{ debugName: "status" }] : /* istanbul ignore next */ []));
35
35
  classes = computed(() => `wr-result wr-result--${this.status()}`, /* @ts-ignore */
36
36
  ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
37
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrResult, deps: [], target: i0.ɵɵFactoryTarget.Component });
38
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: WrResult, isStandalone: true, selector: "wr-result", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null }, status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: "<div class=\"wr-result__icon\" aria-hidden=\"true\">\n @switch (status()) {\n @case ('success') {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M20 32 L28 40 L44 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n </svg>\n }\n @case ('warning') {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M32 18 L32 36 M32 44 L32 46\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3.5\"\n stroke-linecap=\"round\"\n />\n </svg>\n }\n @case ('error') {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M22 22 L42 42 M42 22 L22 42\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n stroke-linecap=\"round\"\n />\n </svg>\n }\n @case ('empty') {\n <svg width=\"72\" height=\"56\" viewBox=\"0 0 72 56\">\n <rect x=\"6\" y=\"14\" width=\"60\" height=\"36\" rx=\"4\" fill=\"currentColor\" opacity=\"0.12\" />\n <path d=\"M6 26 L36 26 L40 20 L66 20\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" />\n </svg>\n }\n @default {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M32 20 L32 36 M32 42 L32 44\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3.5\"\n stroke-linecap=\"round\"\n />\n </svg>\n }\n }\n</div>\n\n@if (title()) {\n <h2 class=\"wr-result__title\">{{ title() }}</h2>\n}\n@if (description()) {\n <p class=\"wr-result__description\">{{ description() }}</p>\n}\n\n<div class=\"wr-result__extra\">\n <ng-content select=\"[wrResultExtra]\" />\n</div>\n", encapsulation: i0.ViewEncapsulation.None });
37
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrResult, deps: [], target: i0.ɵɵFactoryTarget.Component });
38
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.1", type: WrResult, isStandalone: true, selector: "wr-result", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null }, status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: "<div class=\"wr-result__icon\" aria-hidden=\"true\">\n @switch (status()) {\n @case ('success') {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M20 32 L28 40 L44 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n </svg>\n }\n @case ('warning') {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M32 18 L32 36 M32 44 L32 46\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3.5\"\n stroke-linecap=\"round\"\n />\n </svg>\n }\n @case ('error') {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M22 22 L42 42 M42 22 L22 42\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n stroke-linecap=\"round\"\n />\n </svg>\n }\n @case ('empty') {\n <svg width=\"72\" height=\"56\" viewBox=\"0 0 72 56\">\n <rect x=\"6\" y=\"14\" width=\"60\" height=\"36\" rx=\"4\" fill=\"currentColor\" opacity=\"0.12\" />\n <path d=\"M6 26 L36 26 L40 20 L66 20\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" />\n </svg>\n }\n @default {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M32 20 L32 36 M32 42 L32 44\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3.5\"\n stroke-linecap=\"round\"\n />\n </svg>\n }\n }\n</div>\n\n@if (title()) {\n <h2 class=\"wr-result__title\">{{ title() }}</h2>\n}\n@if (description()) {\n <p class=\"wr-result__description\">{{ description() }}</p>\n}\n\n<div class=\"wr-result__extra\">\n <ng-content select=\"[wrResultExtra]\" />\n</div>\n", encapsulation: i0.ViewEncapsulation.None });
39
39
  }
40
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrResult, decorators: [{
40
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrResult, decorators: [{
41
41
  type: Component,
42
42
  args: [{ selector: 'wr-result', encapsulation: ViewEncapsulation.None, host: { '[class]': 'classes()' }, template: "<div class=\"wr-result__icon\" aria-hidden=\"true\">\n @switch (status()) {\n @case ('success') {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M20 32 L28 40 L44 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n </svg>\n }\n @case ('warning') {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M32 18 L32 36 M32 44 L32 46\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3.5\"\n stroke-linecap=\"round\"\n />\n </svg>\n }\n @case ('error') {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M22 22 L42 42 M42 22 L22 42\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3\"\n stroke-linecap=\"round\"\n />\n </svg>\n }\n @case ('empty') {\n <svg width=\"72\" height=\"56\" viewBox=\"0 0 72 56\">\n <rect x=\"6\" y=\"14\" width=\"60\" height=\"36\" rx=\"4\" fill=\"currentColor\" opacity=\"0.12\" />\n <path d=\"M6 26 L36 26 L40 20 L66 20\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" />\n </svg>\n }\n @default {\n <svg width=\"64\" height=\"64\" viewBox=\"0 0 64 64\">\n <circle cx=\"32\" cy=\"32\" r=\"28\" fill=\"currentColor\" opacity=\"0.12\" />\n <path\n d=\"M32 20 L32 36 M32 42 L32 44\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"3.5\"\n stroke-linecap=\"round\"\n />\n </svg>\n }\n }\n</div>\n\n@if (title()) {\n <h2 class=\"wr-result__title\">{{ title() }}</h2>\n}\n@if (description()) {\n <p class=\"wr-result__description\">{{ description() }}</p>\n}\n\n<div class=\"wr-result__extra\">\n <ng-content select=\"[wrResultExtra]\" />\n</div>\n" }]
43
43
  }], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], description: [{ type: i0.Input, args: [{ isSignal: true, alias: "description", required: false }] }], status: [{ type: i0.Input, args: [{ isSignal: true, alias: "status", required: false }] }] } });
@@ -65,10 +65,10 @@ class WrResult404 {
65
65
  description = input(null, /* @ts-ignore */
66
66
  ...(ngDevMode ? [{ debugName: "description" }] : /* istanbul ignore next */ []));
67
67
  desc = useI18nText(this.description, 'result.notFound', 'Sorry, the page you visited does not exist.');
68
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrResult404, deps: [], target: i0.ɵɵFactoryTarget.Component });
69
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.0", type: WrResult404, isStandalone: true, selector: "wr-result-404", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: `<wr-result status="warning" [title]="title()" [description]="desc()"><ng-content /></wr-result>`, isInline: true, dependencies: [{ kind: "component", type: WrResult, selector: "wr-result", inputs: ["title", "description", "status"] }], encapsulation: i0.ViewEncapsulation.None });
68
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrResult404, deps: [], target: i0.ɵɵFactoryTarget.Component });
69
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.1", type: WrResult404, isStandalone: true, selector: "wr-result-404", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: `<wr-result status="warning" [title]="title()" [description]="desc()"><ng-content /></wr-result>`, isInline: true, dependencies: [{ kind: "component", type: WrResult, selector: "wr-result", inputs: ["title", "description", "status"] }], encapsulation: i0.ViewEncapsulation.None });
70
70
  }
71
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrResult404, decorators: [{
71
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrResult404, decorators: [{
72
72
  type: Component,
73
73
  args: [{
74
74
  selector: 'wr-result-404',
@@ -85,10 +85,10 @@ class WrResult403 {
85
85
  description = input(null, /* @ts-ignore */
86
86
  ...(ngDevMode ? [{ debugName: "description" }] : /* istanbul ignore next */ []));
87
87
  desc = useI18nText(this.description, 'result.forbidden', 'Sorry, you are not authorized to access this page.');
88
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrResult403, deps: [], target: i0.ɵɵFactoryTarget.Component });
89
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.0", type: WrResult403, isStandalone: true, selector: "wr-result-403", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: `<wr-result status="error" [title]="title()" [description]="desc()"><ng-content /></wr-result>`, isInline: true, dependencies: [{ kind: "component", type: WrResult, selector: "wr-result", inputs: ["title", "description", "status"] }], encapsulation: i0.ViewEncapsulation.None });
88
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrResult403, deps: [], target: i0.ɵɵFactoryTarget.Component });
89
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.1", type: WrResult403, isStandalone: true, selector: "wr-result-403", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: `<wr-result status="error" [title]="title()" [description]="desc()"><ng-content /></wr-result>`, isInline: true, dependencies: [{ kind: "component", type: WrResult, selector: "wr-result", inputs: ["title", "description", "status"] }], encapsulation: i0.ViewEncapsulation.None });
90
90
  }
91
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrResult403, decorators: [{
91
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrResult403, decorators: [{
92
92
  type: Component,
93
93
  args: [{
94
94
  selector: 'wr-result-403',
@@ -105,10 +105,10 @@ class WrResult500 {
105
105
  description = input(null, /* @ts-ignore */
106
106
  ...(ngDevMode ? [{ debugName: "description" }] : /* istanbul ignore next */ []));
107
107
  desc = useI18nText(this.description, 'result.serverError', 'Sorry, something went wrong.');
108
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrResult500, deps: [], target: i0.ɵɵFactoryTarget.Component });
109
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.0", type: WrResult500, isStandalone: true, selector: "wr-result-500", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: `<wr-result status="error" [title]="title()" [description]="desc()"><ng-content /></wr-result>`, isInline: true, dependencies: [{ kind: "component", type: WrResult, selector: "wr-result", inputs: ["title", "description", "status"] }], encapsulation: i0.ViewEncapsulation.None });
108
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrResult500, deps: [], target: i0.ɵɵFactoryTarget.Component });
109
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.1", type: WrResult500, isStandalone: true, selector: "wr-result-500", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: `<wr-result status="error" [title]="title()" [description]="desc()"><ng-content /></wr-result>`, isInline: true, dependencies: [{ kind: "component", type: WrResult, selector: "wr-result", inputs: ["title", "description", "status"] }], encapsulation: i0.ViewEncapsulation.None });
110
110
  }
111
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrResult500, decorators: [{
111
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrResult500, decorators: [{
112
112
  type: Component,
113
113
  args: [{
114
114
  selector: 'wr-result-500',
@@ -262,10 +262,10 @@ class WrRotatingText {
262
262
  return i * stagger;
263
263
  }
264
264
  }
265
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrRotatingText, deps: [], target: i0.ɵɵFactoryTarget.Component });
266
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: WrRotatingText, isStandalone: true, selector: "wr-rotating-text", inputs: { texts: { classPropertyName: "texts", publicName: "texts", isSignal: true, isRequired: true, transformFunction: null }, rotationInterval: { classPropertyName: "rotationInterval", publicName: "rotationInterval", isSignal: true, isRequired: false, transformFunction: null }, splitBy: { classPropertyName: "splitBy", publicName: "splitBy", isSignal: true, isRequired: false, transformFunction: null }, auto: { classPropertyName: "auto", publicName: "auto", isSignal: true, isRequired: false, transformFunction: null }, loop: { classPropertyName: "loop", publicName: "loop", isSignal: true, isRequired: false, transformFunction: null }, duration: { classPropertyName: "duration", publicName: "duration", isSignal: true, isRequired: false, transformFunction: null }, easing: { classPropertyName: "easing", publicName: "easing", isSignal: true, isRequired: false, transformFunction: null }, staggerDuration: { classPropertyName: "staggerDuration", publicName: "staggerDuration", isSignal: true, isRequired: false, transformFunction: null }, staggerFrom: { classPropertyName: "staggerFrom", publicName: "staggerFrom", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { nextChange: "nextChange" }, host: { classAttribute: "wr-rotating-text" }, ngImport: i0, template: "<!-- Screen-reader-only live region with the canonical text. -->\n<span class=\"wr-rotating-text__sr-only\">{{ current() }}</span>\n\n<!-- Animated visual content. -->\n<span class=\"wr-rotating-text__inner\" aria-hidden=\"true\">\n @for (word of words(); track $index) {\n <span class=\"wr-rotating-text__word\">\n @for (char of word.characters; track $index) {\n <span class=\"wr-rotating-text__char\">{{ char }}</span>\n }\n @if (word.needsSpace) {\n <span class=\"wr-rotating-text__space\">&nbsp;</span>\n }\n </span>\n }\n</span>\n", styles: [".wr-rotating-text{display:inline-flex;align-items:center;overflow:hidden;vertical-align:bottom}.wr-rotating-text__sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);clip-path:inset(50%);white-space:nowrap}.wr-rotating-text__inner{display:inline-flex;flex-wrap:wrap}.wr-rotating-text__word{display:inline-flex;align-items:center}.wr-rotating-text__char{display:inline-block;will-change:transform,opacity}.wr-rotating-text__space{display:inline;white-space:pre}\n"], encapsulation: i0.ViewEncapsulation.None });
265
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrRotatingText, deps: [], target: i0.ɵɵFactoryTarget.Component });
266
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.1", type: WrRotatingText, isStandalone: true, selector: "wr-rotating-text", inputs: { texts: { classPropertyName: "texts", publicName: "texts", isSignal: true, isRequired: true, transformFunction: null }, rotationInterval: { classPropertyName: "rotationInterval", publicName: "rotationInterval", isSignal: true, isRequired: false, transformFunction: null }, splitBy: { classPropertyName: "splitBy", publicName: "splitBy", isSignal: true, isRequired: false, transformFunction: null }, auto: { classPropertyName: "auto", publicName: "auto", isSignal: true, isRequired: false, transformFunction: null }, loop: { classPropertyName: "loop", publicName: "loop", isSignal: true, isRequired: false, transformFunction: null }, duration: { classPropertyName: "duration", publicName: "duration", isSignal: true, isRequired: false, transformFunction: null }, easing: { classPropertyName: "easing", publicName: "easing", isSignal: true, isRequired: false, transformFunction: null }, staggerDuration: { classPropertyName: "staggerDuration", publicName: "staggerDuration", isSignal: true, isRequired: false, transformFunction: null }, staggerFrom: { classPropertyName: "staggerFrom", publicName: "staggerFrom", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { nextChange: "nextChange" }, host: { classAttribute: "wr-rotating-text" }, ngImport: i0, template: "<!-- Screen-reader-only live region with the canonical text. -->\n<span class=\"wr-rotating-text__sr-only\">{{ current() }}</span>\n\n<!-- Animated visual content. -->\n<span class=\"wr-rotating-text__inner\" aria-hidden=\"true\">\n @for (word of words(); track $index) {\n <span class=\"wr-rotating-text__word\">\n @for (char of word.characters; track $index) {\n <span class=\"wr-rotating-text__char\">{{ char }}</span>\n }\n @if (word.needsSpace) {\n <span class=\"wr-rotating-text__space\">&nbsp;</span>\n }\n </span>\n }\n</span>\n", styles: [".wr-rotating-text{display:inline-flex;align-items:center;overflow:hidden;vertical-align:bottom}.wr-rotating-text__sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);clip-path:inset(50%);white-space:nowrap}.wr-rotating-text__inner{display:inline-flex;flex-wrap:wrap}.wr-rotating-text__word{display:inline-flex;align-items:center}.wr-rotating-text__char{display:inline-block;will-change:transform,opacity}.wr-rotating-text__space{display:inline;white-space:pre}\n"], encapsulation: i0.ViewEncapsulation.None });
267
267
  }
268
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrRotatingText, decorators: [{
268
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrRotatingText, decorators: [{
269
269
  type: Component,
270
270
  args: [{ selector: 'wr-rotating-text', encapsulation: ViewEncapsulation.None, host: { class: 'wr-rotating-text' }, template: "<!-- Screen-reader-only live region with the canonical text. -->\n<span class=\"wr-rotating-text__sr-only\">{{ current() }}</span>\n\n<!-- Animated visual content. -->\n<span class=\"wr-rotating-text__inner\" aria-hidden=\"true\">\n @for (word of words(); track $index) {\n <span class=\"wr-rotating-text__word\">\n @for (char of word.characters; track $index) {\n <span class=\"wr-rotating-text__char\">{{ char }}</span>\n }\n @if (word.needsSpace) {\n <span class=\"wr-rotating-text__space\">&nbsp;</span>\n }\n </span>\n }\n</span>\n", styles: [".wr-rotating-text{display:inline-flex;align-items:center;overflow:hidden;vertical-align:bottom}.wr-rotating-text__sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);clip-path:inset(50%);white-space:nowrap}.wr-rotating-text__inner{display:inline-flex;flex-wrap:wrap}.wr-rotating-text__word{display:inline-flex;align-items:center}.wr-rotating-text__char{display:inline-block;will-change:transform,opacity}.wr-rotating-text__space{display:inline;white-space:pre}\n"] }]
271
271
  }], ctorParameters: () => [], propDecorators: { texts: [{ type: i0.Input, args: [{ isSignal: true, alias: "texts", required: true }] }], rotationInterval: [{ type: i0.Input, args: [{ isSignal: true, alias: "rotationInterval", required: false }] }], splitBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "splitBy", required: false }] }], auto: [{ type: i0.Input, args: [{ isSignal: true, alias: "auto", required: false }] }], loop: [{ type: i0.Input, args: [{ isSignal: true, alias: "loop", required: false }] }], duration: [{ type: i0.Input, args: [{ isSignal: true, alias: "duration", required: false }] }], easing: [{ type: i0.Input, args: [{ isSignal: true, alias: "easing", required: false }] }], staggerDuration: [{ type: i0.Input, args: [{ isSignal: true, alias: "staggerDuration", required: false }] }], staggerFrom: [{ type: i0.Input, args: [{ isSignal: true, alias: "staggerFrom", required: false }] }], nextChange: [{ type: i0.Output, args: ["nextChange"] }] } });
@@ -92,10 +92,10 @@ class WrScroll {
92
92
  else
93
93
  container.scrollTo(options);
94
94
  }
95
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrScroll, deps: [], target: i0.ɵɵFactoryTarget.Service });
96
- static ɵprov = i0.ɵɵngDeclareService({ minVersion: "22.0.0", version: "22.1.0", ngImport: i0, type: WrScroll });
95
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrScroll, deps: [], target: i0.ɵɵFactoryTarget.Service });
96
+ static ɵprov = i0.ɵɵngDeclareService({ minVersion: "22.0.0", version: "22.1.1", ngImport: i0, type: WrScroll });
97
97
  }
98
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: WrScroll, decorators: [{
98
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.1", ngImport: i0, type: WrScroll, decorators: [{
99
99
  type: Service
100
100
  }] });
101
101
 
@@ -0,0 +1,512 @@
1
+ import { ComponentHarness, HarnessPredicate } from '@angular/cdk/testing';
2
+
3
+ /**
4
+ * @license
5
+ *
6
+ * Use of this source code is governed by an MIT-style license that can be
7
+ * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
8
+ */
9
+ /**
10
+ * Test harness for one segment of a `<wr-segmented>` — an option, not a control.
11
+ *
12
+ * A segment is a real `<button type="button">` carrying `aria-pressed`, so it is a
13
+ * TOGGLE BUTTON to a screen reader: it announces its own pressed state and its own
14
+ * name, and it is its own tab stop. That is why this exists as a harness of its own,
15
+ * and why the questions below are worth asking per segment rather than in bulk on
16
+ * `WrSegmentedHarness` — which is where the SELECTION lives.
17
+ *
18
+ * Three name-shaped methods, because a segment has three different names and only
19
+ * one of them is what a person hears:
20
+ *
21
+ * - {@link getText} — the visible label, `null` for an icon-only segment.
22
+ * - {@link getAccessibleName} — what is announced, `null` when nothing names it.
23
+ * - {@link getLabel} — the same, but it refuses to answer `null`, so a spec
24
+ * addressing segments by label fails where the mistake is rather than three
25
+ * lines later.
26
+ *
27
+ * @example
28
+ * ```ts
29
+ * const segmented = await loader.getHarness(WrSegmentedHarness);
30
+ * const [, week] = await segmented.getOptions();
31
+ *
32
+ * await week.select();
33
+ * expect(await week.isSelected()).toBe(true);
34
+ * ```
35
+ *
36
+ * @see https://ngwr.dev/guides/testing
37
+ */
38
+ class WrSegmentedOptionHarness extends ComponentHarness {
39
+ /** The segment is a plain `<button>` — the BEM class is what identifies it. */
40
+ static hostSelector = '.wr-segmented__option';
41
+ /** Build a predicate that narrows the query — pass to `getHarness` / `getAllHarnesses`. */
42
+ static with(options = {}) {
43
+ return (new HarnessPredicate(WrSegmentedOptionHarness, options)
44
+ // Matched on the nullable name, not on `getLabel()`: a predicate runs against
45
+ // EVERY segment, so one unnamed sibling would otherwise throw a query for the
46
+ // others out of the water.
47
+ .addOption('label', options.label, (harness, label) => HarnessPredicate.stringMatches(harness.getAccessibleName(), label))
48
+ .addOption('selected', options.selected, async (harness, selected) => (await harness.isSelected()) === selected)
49
+ .addOption('disabled', options.disabled, async (harness, disabled) => (await harness.isDisabled()) === disabled));
50
+ }
51
+ labelText = this.locatorForOptional('.wr-segmented__label');
52
+ icon = this.locatorForOptional('.wr-segmented__icon');
53
+ /**
54
+ * The visible label, or `null` for an icon-only segment.
55
+ *
56
+ * `null` rather than `''`: the label element is only rendered when the option
57
+ * carries a `label`, and "no text at all" and "an empty label" are different
58
+ * mistakes to be looking at.
59
+ */
60
+ async getText() {
61
+ const label = await this.labelText();
62
+ return label ? label.text() : null;
63
+ }
64
+ /**
65
+ * The name a screen reader announces for this segment, or `null` when nothing
66
+ * names it.
67
+ *
68
+ * The component's own fallback chain, read back off the page: a labelled segment
69
+ * is named by its text and carries no `aria-label`; an icon-only one is named by
70
+ * `aria-label`, which the template fills from the option's `ariaLabel` or — as a
71
+ * last resort — from its stringified `value`.
72
+ *
73
+ * `null` is a finding, not a detail: an icon-only segment whose option supplied
74
+ * neither an `ariaLabel` nor a stringifiable value is announced as a bare unnamed
75
+ * button.
76
+ */
77
+ async getAccessibleName() {
78
+ const text = await this.getText();
79
+ if (text !== null)
80
+ return text;
81
+ return (await this.host()).getAttribute('aria-label');
82
+ }
83
+ /**
84
+ * The segment's accessible name, for addressing it — and a targeted failure when
85
+ * it has none.
86
+ *
87
+ * {@link getAccessibleName} is the same answer without the refusal; use that one
88
+ * when `null` is what a spec is checking for.
89
+ */
90
+ async getLabel() {
91
+ const name = await this.getAccessibleName();
92
+ if (name === null) {
93
+ throw new Error('WrSegmentedOptionHarness.getLabel(): this segment has no name — it renders no label and carries no ' +
94
+ '`aria-label`, so a screen reader announces an unnamed button. Give the option a `label`, or an ' +
95
+ '`ariaLabel` when it is icon-only.');
96
+ }
97
+ return name;
98
+ }
99
+ /**
100
+ * Whether this segment is the control's current answer.
101
+ *
102
+ * From `aria-pressed`, in preference to the `wr-segmented__option--selected`
103
+ * class: both are public and they move together, but the class only recolours the
104
+ * label while the attribute is the entire state a screen reader is given.
105
+ */
106
+ async isSelected() {
107
+ return (await (await this.host()).getAttribute('aria-pressed')) === 'true';
108
+ }
109
+ /**
110
+ * Whether the segment refuses selection — for either reason.
111
+ *
112
+ * The native `disabled` PROPERTY, which is what actually blocks activation. The
113
+ * option's own `disabled` and the whole control's land on it identically, and from
114
+ * outside they are the same thing: this segment cannot be picked. Ask
115
+ * `WrSegmentedHarness.isDisabled()` for which of the two it was.
116
+ */
117
+ async isDisabled() {
118
+ return (await this.host()).getProperty('disabled');
119
+ }
120
+ /** Whether the segment renders an icon beside (or instead of) its label. */
121
+ async hasIcon() {
122
+ return (await this.icon()) !== null;
123
+ }
124
+ /**
125
+ * The name of the segment's icon, or `null` when it renders none.
126
+ *
127
+ * From `data-icon`, which `<wr-icon>` reflects. The glyph itself is markup the
128
+ * icon registry writes into the element, and an UNREGISTERED name leaves that
129
+ * empty — so the attribute is the only place the wiring survives, and it is the
130
+ * one that tells "no icon asked for" from "icon asked for, never registered".
131
+ */
132
+ async getIconName() {
133
+ const icon = await this.icon();
134
+ return icon ? icon.getAttribute('data-icon') : null;
135
+ }
136
+ /**
137
+ * Pick this segment.
138
+ *
139
+ * A click, and deliberately not a keypress: activating a `<button>` from the
140
+ * keyboard is the BROWSER's default action for Enter / Space — the component
141
+ * implements no key handling of its own — and jsdom implements none of it either,
142
+ * so there is nothing here for a key to drive. A no-arg CDK click needs no
143
+ * layout, which is the other half of why this is the drivable path.
144
+ *
145
+ * Nothing happens when the segment is already selected (a segmented control has no
146
+ * untoggle), and nothing happens when it is disabled — but not for the reason the
147
+ * `pointer-events: none` on a whole disabled control suggests, which is CSS a unit
148
+ * test never applies. The CDK's own `click()` reads the native `disabled` PROPERTY
149
+ * and dispatches the mouse sequence WITHOUT the final `click` event, so on a
150
+ * disabled segment the component's handler is never reached at all (measured: zero
151
+ * click events). Either way the value does not move and this resolves quietly, so
152
+ * assert the result rather than assume it, or reach for
153
+ * `WrSegmentedHarness.select()`, which says which of the two it was.
154
+ */
155
+ async select() {
156
+ return (await this.host()).click();
157
+ }
158
+ /** Move keyboard focus to the segment. Each segment is its own tab stop. */
159
+ async focus() {
160
+ return (await this.host()).focus();
161
+ }
162
+ /** Take focus off the segment. */
163
+ async blur() {
164
+ return (await this.host()).blur();
165
+ }
166
+ async isFocused() {
167
+ return (await this.host()).isFocused();
168
+ }
169
+ }
170
+
171
+ /**
172
+ * @license
173
+ *
174
+ * Use of this source code is governed by an MIT-style license that can be
175
+ * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
176
+ */
177
+ /** Sizes that earn a modifier class — `md` is the default and carries none. */
178
+ const SIZES = ['sm', 'lg'];
179
+ /**
180
+ * Test harness for `<wr-segmented>` — the root of a two-class family with
181
+ * {@link WrSegmentedOptionHarness}.
182
+ *
183
+ * **What the control actually is**, because it decides everything below: not a
184
+ * `radiogroup`, not a `tablist` and not native radios. The host is a plain
185
+ * `role="group"` and each segment is a `<button aria-pressed>` — a row of toggle
186
+ * buttons over one value. Three consequences a spec has to know about:
187
+ *
188
+ * - The selection is `aria-pressed`, on exactly one segment. There is no
189
+ * `aria-checked`, no `aria-selected`, and no "2 of 3" position announced.
190
+ * - **There is no roving tab stop.** The component authors no `tabindex` and no
191
+ * arrow-key handler, so every enabled segment is its OWN tab stop —
192
+ * {@link getTabStopLabels} returns a list where a radiogroup or a tablist would
193
+ * have one entry. Focus and selection are therefore independent here:
194
+ * {@link getFocusedLabel} implies nothing about {@link getSelectedIndex}, and
195
+ * arrowing along the strip moves neither.
196
+ * - Activation is the browser's own default action on a button, which jsdom does not
197
+ * implement, so {@link select} clicks — see {@link WrSegmentedOptionHarness.select}.
198
+ *
199
+ * **There is deliberately no `getValue()` and no selection by value.** `options` is
200
+ * a bound array of `{ value, label, … }` and the value is a generic `T` the component
201
+ * writes nowhere — not on the host, not on a segment. The single exception is an
202
+ * accident rather than an addressing scheme: an icon-only option with no `ariaLabel`
203
+ * has its value stringified into the segment's `aria-label`, which for an object
204
+ * value reads `[object Object]`. So address segments by their label
205
+ * ({@link select}) or by position ({@link selectAt}), and assert the picked value on
206
+ * the host's own model — the only place it exists, and the assertion that would have
207
+ * caught the bug anyway.
208
+ *
209
+ * The sliding thumb is decoration (`aria-hidden`), and the four methods that mention
210
+ * it read what the component PUBLISHES for the stylesheet — two custom properties and
211
+ * two modifier classes — never painted geometry, which a DOM without layout does not
212
+ * have. {@link getThumbIndex} in particular is not the selection; it is the trap that
213
+ * method documents.
214
+ *
215
+ * @example
216
+ * ```ts
217
+ * const range = await loader.getHarness(WrSegmentedHarness.with({ label: 'Range' }));
218
+ *
219
+ * expect(await range.getOptionLabels()).toEqual(['Day', 'Week', 'Month']);
220
+ * await range.select({ label: 'Week' });
221
+ * expect(await range.getSelectedIndex()).toBe(1);
222
+ * ```
223
+ *
224
+ * @see https://ngwr.dev/guides/testing
225
+ */
226
+ class WrSegmentedHarness extends ComponentHarness {
227
+ static hostSelector = 'wr-segmented';
228
+ /** Build a predicate that narrows the query — pass to `getHarness` / `getAllHarnesses`. */
229
+ static with(options = {}) {
230
+ return new HarnessPredicate(WrSegmentedHarness, options)
231
+ .addOption('label', options.label, (harness, label) => HarnessPredicate.stringMatches(harness.getAccessibleName(), label))
232
+ .addOption('size', options.size, async (harness, size) => (await harness.getSize()) === size)
233
+ .addOption('disabled', options.disabled, async (harness, disabled) => (await harness.isDisabled()) === disabled);
234
+ }
235
+ /**
236
+ * The role the host announces — `group`.
237
+ *
238
+ * Worth pinning precisely because it is the weaker of the shapes this component
239
+ * could have had: a `group` of toggle buttons tells a screen reader that the
240
+ * segments belong together, and nothing more. Were this to become a `radiogroup` or
241
+ * a `tablist`, the keyboard contract would change with it (one tab stop, arrow keys
242
+ * moving the selection), and every spec written against {@link getTabStopLabels}
243
+ * would need to change too.
244
+ */
245
+ async getRole() {
246
+ return (await this.host()).getAttribute('role');
247
+ }
248
+ /**
249
+ * The control's accessible name, resolved the way a screen reader resolves it: the
250
+ * text of every element `aria-labelledby` points at, and `aria-label` only when
251
+ * that named nothing. `null` when the consumer wired neither.
252
+ *
253
+ * The order is not interchangeable — `aria-labelledby` WINS in the accessible-name
254
+ * computation — so a control carrying both is announced by the heading it points at,
255
+ * and reporting the `aria-label` would describe a name nobody hears.
256
+ *
257
+ * The component ships no label input on purpose (the question is the consumer's own
258
+ * heading), so this is the only way to check that wiring held, and a `null` on a
259
+ * group of three unrelated-sounding buttons is a real finding.
260
+ */
261
+ async getAccessibleName() {
262
+ const host = await this.host();
263
+ const labelledBy = await host.getAttribute('aria-labelledby');
264
+ if (labelledBy !== null) {
265
+ // Resolved from the document root: `aria-labelledby` may point anywhere on the
266
+ // page, and the heading above a control is normally outside it.
267
+ const root = this.documentRootLocatorFactory();
268
+ const texts = [];
269
+ for (const id of labelledBy.split(/\s+/).filter(Boolean)) {
270
+ const target = await root.locatorForOptional(`#${id}`)();
271
+ if (target)
272
+ texts.push(await target.text());
273
+ }
274
+ // A reference that resolves to nothing names nothing, and the computation falls
275
+ // through to `aria-label` exactly as it does in a browser.
276
+ if (texts.length)
277
+ return texts.join(' ');
278
+ }
279
+ return host.getAttribute('aria-label');
280
+ }
281
+ /** This control's own segments, in DOM order. A sibling control's are not here. */
282
+ async getOptions(filters = {}) {
283
+ return this.locatorForAll(WrSegmentedOptionHarness.with(filters))();
284
+ }
285
+ /**
286
+ * The accessible name of every segment, in DOM order — the visible labels, with an
287
+ * icon-only segment answering with the `aria-label` that stands in for its text.
288
+ *
289
+ * Throws when a segment has no name at all, rather than leaving a hole in the list:
290
+ * see {@link WrSegmentedOptionHarness.getLabel}.
291
+ */
292
+ async getOptionLabels() {
293
+ const options = await this.getOptions();
294
+ return Promise.all(options.map(option => option.getLabel()));
295
+ }
296
+ /** The pressed segment, or `null` when nothing is selected. */
297
+ async getSelectedOption() {
298
+ const [selected] = await this.getOptions({ selected: true });
299
+ return selected ?? null;
300
+ }
301
+ /**
302
+ * The accessible name of the pressed segment, or `null` when nothing is selected.
303
+ *
304
+ * `null` is also the answer for a bound value that matches no option — the control
305
+ * holds it, no segment is pressed, and the page shows an unanswered control. See
306
+ * {@link getThumbIndex}, which does NOT answer `null` in that state.
307
+ */
308
+ async getSelectedLabel() {
309
+ const selected = await this.getSelectedOption();
310
+ return selected ? selected.getLabel() : null;
311
+ }
312
+ /**
313
+ * The position of the pressed segment, or `-1` when nothing is selected.
314
+ *
315
+ * Derived from `aria-pressed`, which is the selection. The other index on the page —
316
+ * the thumb's — is not; it clamps at 0 (see {@link getThumbIndex}).
317
+ */
318
+ async getSelectedIndex() {
319
+ const options = await this.getOptions();
320
+ for (let index = 0; index < options.length; index++) {
321
+ if (await options[index].isSelected())
322
+ return index;
323
+ }
324
+ return -1;
325
+ }
326
+ /**
327
+ * Pick the first segment matching the filters — this is how the control's value
328
+ * changes.
329
+ *
330
+ * Throws when nothing matches, naming the segments that do exist, and throws again
331
+ * when the segment is still unpressed afterwards. That second failure has exactly
332
+ * two causes and reports both, because a click that quietly did nothing surfaces as
333
+ * an unrelated assertion three lines later.
334
+ */
335
+ async select(filters) {
336
+ const [option] = await this.getOptions(filters);
337
+ if (!option) {
338
+ throw new Error(`WrSegmentedHarness.select(): no segment matched ${JSON.stringify(filters)}. This control offers: ` +
339
+ `${(await this.describeOptions()).join(', ')}.`);
340
+ }
341
+ await this.pick(option, 'select');
342
+ }
343
+ /**
344
+ * Pick the segment at a position, counting from zero — the addressing route for an
345
+ * icon-only strip, or for one whose labels a spec would rather not hard-code.
346
+ *
347
+ * Throws on an index outside the control, saying how many segments there are: an
348
+ * off-by-one that resolved to nothing would otherwise read as "the click did not
349
+ * take".
350
+ */
351
+ async selectAt(index) {
352
+ const options = await this.getOptions();
353
+ const option = options[index];
354
+ if (!option) {
355
+ throw new Error(`WrSegmentedHarness.selectAt(): index ${index} is outside this control, which has ${options.length} ` +
356
+ `segment(s): ${(await this.describeOptions()).join(', ')}.`);
357
+ }
358
+ await this.pick(option, 'selectAt');
359
+ }
360
+ /**
361
+ * Whether the control was disabled AS A WHOLE, from the `wr-segmented--disabled`
362
+ * modifier.
363
+ *
364
+ * Deliberately not "every segment is disabled": a control whose options each carry
365
+ * their own `disabled` looks identical to a user, and the modifier is the only thing
366
+ * on the page that tells the two apart. What actually blocks a click is the native
367
+ * `disabled` each button gets either way — ask a segment
368
+ * ({@link WrSegmentedOptionHarness.isDisabled}) for that.
369
+ */
370
+ async isDisabled() {
371
+ return (await this.host()).hasClass('wr-segmented--disabled');
372
+ }
373
+ /**
374
+ * The rendered control size.
375
+ *
376
+ * `md` is the component's own default and earns NO modifier class, so a bare host
377
+ * IS `md` — the absence is the answer rather than a missing one. Read from the
378
+ * class instead of the input, which is also why this reports what was rendered:
379
+ * unlike the form controls, `<wr-segmented>` does not resolve its size through
380
+ * `provideWrConfig()`, so an app-wide default set there does not reach it and this
381
+ * will say so.
382
+ */
383
+ async getSize() {
384
+ const host = await this.host();
385
+ for (const size of SIZES) {
386
+ if (await host.hasClass(`wr-segmented--${size}`))
387
+ return size;
388
+ }
389
+ return 'md';
390
+ }
391
+ /**
392
+ * The accessible name of every segment a Tab press can reach, in tab order.
393
+ *
394
+ * A LIST, not one label, and that is the shape worth pinning: the component authors
395
+ * no roving `tabindex`, so each enabled segment is its own tab stop and reaching the
396
+ * third one takes three Tabs. An all-disabled control is skipped over entirely and
397
+ * answers `[]`.
398
+ *
399
+ * Unnamed segments are reported as `(unnamed)` rather than throwing — a tab order is
400
+ * still a fact worth reading on a page that has that bug in it.
401
+ */
402
+ async getTabStopLabels() {
403
+ const enabled = await this.getOptions({ disabled: false });
404
+ return this.describe(enabled);
405
+ }
406
+ /**
407
+ * The accessible name of the segment that currently holds focus, or `null` when
408
+ * focus is elsewhere.
409
+ *
410
+ * Independent of the selection here — see the note on the class. Reported as
411
+ * `(unnamed)` for a segment with no name, for the reason
412
+ * {@link getTabStopLabels} gives.
413
+ */
414
+ async getFocusedLabel() {
415
+ for (const option of await this.getOptions()) {
416
+ if (await option.isFocused()) {
417
+ return (await option.getAccessibleName()) ?? '(unnamed)';
418
+ }
419
+ }
420
+ return null;
421
+ }
422
+ /**
423
+ * The index the component publishes for the thumb, from the
424
+ * `--wr-segmented-thumb-index` custom property it sets inline.
425
+ *
426
+ * **Not the selection, and this is the difference that bites.** The property is
427
+ * `Math.max(0, selectedIndex)`, so a control holding a value that matches no option
428
+ * publishes `0` — the thumb parks under the FIRST segment and is hidden by
429
+ * {@link isThumbVisible} instead of being moved out of the way. A harness that read
430
+ * this to answer "which segment is selected" would report segment one for a control
431
+ * with no selection at all. {@link getSelectedIndex} is the selection.
432
+ *
433
+ * It is also not where the thumb IS: the stylesheet turns this into a `translateX`,
434
+ * and no measurement of that survives a DOM without layout. This is the input to
435
+ * that, which is the part a unit test can honestly check.
436
+ */
437
+ async getThumbIndex() {
438
+ return this.thumbVar('--wr-segmented-thumb-index');
439
+ }
440
+ /**
441
+ * The segment count the component publishes for the thumb, from
442
+ * `--wr-segmented-thumb-count` — the divisor the stylesheet computes the thumb's
443
+ * width with.
444
+ *
445
+ * Should always equal the number of segments, and the reason to ask is that nothing
446
+ * else notices when it does not: a count that fell out of step with the options
447
+ * leaves the thumb the wrong width and sliding to the wrong place, while every ARIA
448
+ * state on the page stays correct. It is clamped to a minimum of `1`, so an empty
449
+ * control reports `1` rather than dividing by zero.
450
+ */
451
+ async getThumbCount() {
452
+ return this.thumbVar('--wr-segmented-thumb-count');
453
+ }
454
+ /**
455
+ * Whether the thumb is being shown at all.
456
+ *
457
+ * Read from the ABSENCE of the `wr-segmented--unselected` modifier, which is the
458
+ * hook the stylesheet zeroes the thumb's opacity through. The computed opacity is
459
+ * not the answer here — a unit test applies no stylesheet — so the public modifier
460
+ * is the contract, and it is what tells "parked under segment one" from "hidden
461
+ * because nothing is selected".
462
+ */
463
+ async isThumbVisible() {
464
+ return !(await (await this.host()).hasClass('wr-segmented--unselected'));
465
+ }
466
+ /**
467
+ * Whether the thumb will animate its next move, from the `wr-segmented--mounted`
468
+ * modifier that gates the transition.
469
+ *
470
+ * Not "the thumb is animating now": nothing about a running animation is visible to
471
+ * a unit test. What this pins is the deliberate asymmetry — the class is added in
472
+ * `afterNextRender`, so the FIRST snap to the initial value is instant and every
473
+ * user-driven move after it slides. Deferred work like that only lands once the
474
+ * fixture is stable, which every harness read already waits for.
475
+ */
476
+ async isThumbTransitionEnabled() {
477
+ return (await this.host()).hasClass('wr-segmented--mounted');
478
+ }
479
+ /** Click a segment and turn a click that did nothing into a failure that says why. */
480
+ async pick(option, caller) {
481
+ await option.select();
482
+ if (!(await option.isSelected())) {
483
+ const name = (await option.getAccessibleName()) ?? '(unnamed)';
484
+ throw new Error(`WrSegmentedHarness.${caller}(): "${name}" is still unpressed after being clicked — either that ` +
485
+ 'option carries `disabled` or the whole control does.');
486
+ }
487
+ }
488
+ /** Segment names for an error message, which must not throw on its way out. */
489
+ async describeOptions() {
490
+ return this.describe(await this.getOptions());
491
+ }
492
+ async describe(options) {
493
+ return Promise.all(options.map(async (option) => (await option.getAccessibleName()) ?? '(unnamed)'));
494
+ }
495
+ /** One of the thumb's inline custom properties, as a number. */
496
+ async thumbVar(property) {
497
+ const raw = (await (await this.host()).getCssValue(property)).trim();
498
+ const value = Number.parseInt(raw, 10);
499
+ if (Number.isNaN(value)) {
500
+ throw new Error(`WrSegmentedHarness: could not read \`${property}\`, which computed to "${raw}". The component sets it ` +
501
+ 'inline on the host; an environment that drops custom properties cannot answer this.');
502
+ }
503
+ return value;
504
+ }
505
+ }
506
+
507
+ /**
508
+ * Generated bundle index. Do not edit.
509
+ */
510
+
511
+ export { WrSegmentedHarness, WrSegmentedOptionHarness };
512
+ //# sourceMappingURL=ngwr-segmented-testing.mjs.map