ngwr 14.7.0 → 14.9.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 (482) hide show
  1. package/README.md +66 -332
  2. package/alert/styles/_index.scss +10 -0
  3. package/avatar/styles/_index.scss +18 -7
  4. package/badge/styles/_index.scss +7 -0
  5. package/badge/styles/_tag.scss +7 -1
  6. package/bar-chart/styles/_index.scss +1 -0
  7. package/button/styles/_index.scss +6 -0
  8. package/calendar-heatmap/styles/_index.scss +1 -0
  9. package/cascader/styles/_rules.scss +87 -15
  10. package/checkbox/styles/_index.scss +4 -0
  11. package/command-palette/styles/_index.scss +1 -1
  12. package/date-picker/styles/_index.scss +30 -0
  13. package/density/styles/_index.scss +4 -2
  14. package/divider/styles/_index.scss +2 -0
  15. package/donut-chart/styles/_index.scss +10 -0
  16. package/dropdown/styles/_index.scss +67 -5
  17. package/editor/styles/_index.scss +441 -0
  18. package/event-calendar/styles/_index.scss +209 -35
  19. package/fesm2022/ngwr-action-sheet-testing.mjs.map +1 -1
  20. package/fesm2022/ngwr-action-sheet.mjs +3 -3
  21. package/fesm2022/ngwr-action-sheet.mjs.map +1 -1
  22. package/fesm2022/ngwr-affix.mjs +3 -3
  23. package/fesm2022/ngwr-affix.mjs.map +1 -1
  24. package/fesm2022/ngwr-alert.mjs +3 -3
  25. package/fesm2022/ngwr-alert.mjs.map +1 -1
  26. package/fesm2022/ngwr-anchor.mjs +3 -3
  27. package/fesm2022/ngwr-anchor.mjs.map +1 -1
  28. package/fesm2022/ngwr-aurora.mjs +3 -3
  29. package/fesm2022/ngwr-aurora.mjs.map +1 -1
  30. package/fesm2022/ngwr-avatar.mjs +3 -3
  31. package/fesm2022/ngwr-avatar.mjs.map +1 -1
  32. package/fesm2022/ngwr-back-top.mjs +3 -3
  33. package/fesm2022/ngwr-back-top.mjs.map +1 -1
  34. package/fesm2022/ngwr-badge.mjs +28 -13
  35. package/fesm2022/ngwr-badge.mjs.map +1 -1
  36. package/fesm2022/ngwr-bar-chart-testing.mjs.map +1 -1
  37. package/fesm2022/ngwr-bar-chart.mjs +31 -6
  38. package/fesm2022/ngwr-bar-chart.mjs.map +1 -1
  39. package/fesm2022/ngwr-blur-text-testing.mjs.map +1 -1
  40. package/fesm2022/ngwr-blur-text.mjs +3 -3
  41. package/fesm2022/ngwr-blur-text.mjs.map +1 -1
  42. package/fesm2022/ngwr-border-glow-testing.mjs.map +1 -1
  43. package/fesm2022/ngwr-border-glow.mjs +3 -3
  44. package/fesm2022/ngwr-border-glow.mjs.map +1 -1
  45. package/fesm2022/ngwr-breadcrumbs.mjs +6 -6
  46. package/fesm2022/ngwr-breadcrumbs.mjs.map +1 -1
  47. package/fesm2022/ngwr-burger.mjs +3 -3
  48. package/fesm2022/ngwr-burger.mjs.map +1 -1
  49. package/fesm2022/ngwr-button-testing.mjs.map +1 -1
  50. package/fesm2022/ngwr-button.mjs +6 -6
  51. package/fesm2022/ngwr-button.mjs.map +1 -1
  52. package/fesm2022/ngwr-calendar-heatmap-testing.mjs.map +1 -1
  53. package/fesm2022/ngwr-calendar-heatmap.mjs +61 -6
  54. package/fesm2022/ngwr-calendar-heatmap.mjs.map +1 -1
  55. package/fesm2022/ngwr-calendar-testing.mjs.map +1 -1
  56. package/fesm2022/ngwr-calendar.mjs +3 -3
  57. package/fesm2022/ngwr-calendar.mjs.map +1 -1
  58. package/fesm2022/ngwr-card.mjs +9 -9
  59. package/fesm2022/ngwr-card.mjs.map +1 -1
  60. package/fesm2022/ngwr-carousel-testing.mjs.map +1 -1
  61. package/fesm2022/ngwr-carousel.mjs +6 -6
  62. package/fesm2022/ngwr-carousel.mjs.map +1 -1
  63. package/fesm2022/ngwr-cascader-testing.mjs.map +1 -1
  64. package/fesm2022/ngwr-cascader.mjs +4 -4
  65. package/fesm2022/ngwr-cascader.mjs.map +1 -1
  66. package/fesm2022/ngwr-checkbox-testing.mjs.map +1 -1
  67. package/fesm2022/ngwr-checkbox.mjs +18 -8
  68. package/fesm2022/ngwr-checkbox.mjs.map +1 -1
  69. package/fesm2022/ngwr-circular-text-testing.mjs.map +1 -1
  70. package/fesm2022/ngwr-circular-text.mjs +3 -3
  71. package/fesm2022/ngwr-circular-text.mjs.map +1 -1
  72. package/fesm2022/ngwr-click-spark.mjs +3 -3
  73. package/fesm2022/ngwr-click-spark.mjs.map +1 -1
  74. package/fesm2022/ngwr-clipboard.mjs +3 -3
  75. package/fesm2022/ngwr-clipboard.mjs.map +1 -1
  76. package/fesm2022/ngwr-collapse-testing.mjs.map +1 -1
  77. package/fesm2022/ngwr-collapse.mjs +9 -9
  78. package/fesm2022/ngwr-collapse.mjs.map +1 -1
  79. package/fesm2022/ngwr-color-picker-testing.mjs.map +1 -1
  80. package/fesm2022/ngwr-color-picker.mjs +6 -6
  81. package/fesm2022/ngwr-color-picker.mjs.map +1 -1
  82. package/fesm2022/ngwr-command-palette-testing.mjs.map +1 -1
  83. package/fesm2022/ngwr-command-palette.mjs +3 -3
  84. package/fesm2022/ngwr-command-palette.mjs.map +1 -1
  85. package/fesm2022/ngwr-compare.mjs +3 -3
  86. package/fesm2022/ngwr-compare.mjs.map +1 -1
  87. package/fesm2022/ngwr-confetti.mjs +3 -3
  88. package/fesm2022/ngwr-confetti.mjs.map +1 -1
  89. package/fesm2022/ngwr-config.mjs.map +1 -1
  90. package/fesm2022/ngwr-context-menu-testing.mjs.map +1 -1
  91. package/fesm2022/ngwr-context-menu.mjs +12 -12
  92. package/fesm2022/ngwr-context-menu.mjs.map +1 -1
  93. package/fesm2022/ngwr-cookie.mjs +3 -3
  94. package/fesm2022/ngwr-cookie.mjs.map +1 -1
  95. package/fesm2022/ngwr-counter.mjs +6 -6
  96. package/fesm2022/ngwr-counter.mjs.map +1 -1
  97. package/fesm2022/ngwr-date-adapters-fns.mjs +3 -3
  98. package/fesm2022/ngwr-date-adapters-fns.mjs.map +1 -1
  99. package/fesm2022/ngwr-date-adapters-luxon.mjs +3 -3
  100. package/fesm2022/ngwr-date-adapters-luxon.mjs.map +1 -1
  101. package/fesm2022/ngwr-date-picker-testing.mjs.map +1 -1
  102. package/fesm2022/ngwr-date-picker.mjs +721 -62
  103. package/fesm2022/ngwr-date-picker.mjs.map +1 -1
  104. package/fesm2022/ngwr-date.mjs +3 -3
  105. package/fesm2022/ngwr-date.mjs.map +1 -1
  106. package/fesm2022/ngwr-decrypt-text-testing.mjs.map +1 -1
  107. package/fesm2022/ngwr-decrypt-text.mjs +3 -3
  108. package/fesm2022/ngwr-decrypt-text.mjs.map +1 -1
  109. package/fesm2022/ngwr-density.mjs +6 -6
  110. package/fesm2022/ngwr-density.mjs.map +1 -1
  111. package/fesm2022/ngwr-descriptions.mjs +6 -6
  112. package/fesm2022/ngwr-descriptions.mjs.map +1 -1
  113. package/fesm2022/ngwr-dialog-testing.mjs.map +1 -1
  114. package/fesm2022/ngwr-dialog.mjs +15 -15
  115. package/fesm2022/ngwr-dialog.mjs.map +1 -1
  116. package/fesm2022/ngwr-directives.mjs +12 -12
  117. package/fesm2022/ngwr-directives.mjs.map +1 -1
  118. package/fesm2022/ngwr-divider.mjs +3 -3
  119. package/fesm2022/ngwr-divider.mjs.map +1 -1
  120. package/fesm2022/ngwr-donut-chart-testing.mjs.map +1 -1
  121. package/fesm2022/ngwr-donut-chart.mjs +48 -6
  122. package/fesm2022/ngwr-donut-chart.mjs.map +1 -1
  123. package/fesm2022/ngwr-drag-drop.mjs +6 -6
  124. package/fesm2022/ngwr-drag-drop.mjs.map +1 -1
  125. package/fesm2022/ngwr-drawer-testing.mjs.map +1 -1
  126. package/fesm2022/ngwr-drawer.mjs +18 -18
  127. package/fesm2022/ngwr-drawer.mjs.map +1 -1
  128. package/fesm2022/ngwr-dropdown-testing.mjs.map +1 -1
  129. package/fesm2022/ngwr-dropdown.mjs +174 -25
  130. package/fesm2022/ngwr-dropdown.mjs.map +1 -1
  131. package/fesm2022/ngwr-editor-testing.mjs +568 -0
  132. package/fesm2022/ngwr-editor-testing.mjs.map +1 -0
  133. package/fesm2022/ngwr-editor.mjs +2601 -0
  134. package/fesm2022/ngwr-editor.mjs.map +1 -0
  135. package/fesm2022/ngwr-empty.mjs +3 -3
  136. package/fesm2022/ngwr-empty.mjs.map +1 -1
  137. package/fesm2022/ngwr-event-calendar-testing.mjs.map +1 -1
  138. package/fesm2022/ngwr-event-calendar.mjs +14 -7
  139. package/fesm2022/ngwr-event-calendar.mjs.map +1 -1
  140. package/fesm2022/ngwr-falling-text-testing.mjs.map +1 -1
  141. package/fesm2022/ngwr-falling-text.mjs +3 -3
  142. package/fesm2022/ngwr-falling-text.mjs.map +1 -1
  143. package/fesm2022/ngwr-file-upload-testing.mjs.map +1 -1
  144. package/fesm2022/ngwr-file-upload.mjs +3 -3
  145. package/fesm2022/ngwr-file-upload.mjs.map +1 -1
  146. package/fesm2022/ngwr-form-testing.mjs.map +1 -1
  147. package/fesm2022/ngwr-form.mjs +61 -10
  148. package/fesm2022/ngwr-form.mjs.map +1 -1
  149. package/fesm2022/ngwr-fuzzy-text-testing.mjs.map +1 -1
  150. package/fesm2022/ngwr-fuzzy-text.mjs +3 -3
  151. package/fesm2022/ngwr-fuzzy-text.mjs.map +1 -1
  152. package/fesm2022/ngwr-gauge-testing.mjs.map +1 -1
  153. package/fesm2022/ngwr-gauge.mjs +35 -6
  154. package/fesm2022/ngwr-gauge.mjs.map +1 -1
  155. package/fesm2022/ngwr-glitch-text-testing.mjs.map +1 -1
  156. package/fesm2022/ngwr-glitch-text.mjs +3 -3
  157. package/fesm2022/ngwr-glitch-text.mjs.map +1 -1
  158. package/fesm2022/ngwr-gradient-text-testing.mjs.map +1 -1
  159. package/fesm2022/ngwr-gradient-text.mjs +3 -3
  160. package/fesm2022/ngwr-gradient-text.mjs.map +1 -1
  161. package/fesm2022/ngwr-graph-testing.mjs.map +1 -1
  162. package/fesm2022/ngwr-graph.mjs +6 -6
  163. package/fesm2022/ngwr-graph.mjs.map +1 -1
  164. package/fesm2022/ngwr-hotkey.mjs +6 -6
  165. package/fesm2022/ngwr-hotkey.mjs.map +1 -1
  166. package/fesm2022/ngwr-i18n-ar.mjs +31 -0
  167. package/fesm2022/ngwr-i18n-ar.mjs.map +1 -1
  168. package/fesm2022/ngwr-i18n-cs.mjs +31 -0
  169. package/fesm2022/ngwr-i18n-cs.mjs.map +1 -1
  170. package/fesm2022/ngwr-i18n-de.mjs +31 -0
  171. package/fesm2022/ngwr-i18n-de.mjs.map +1 -1
  172. package/fesm2022/ngwr-i18n-en.mjs +39 -0
  173. package/fesm2022/ngwr-i18n-en.mjs.map +1 -1
  174. package/fesm2022/ngwr-i18n-es.mjs +31 -0
  175. package/fesm2022/ngwr-i18n-es.mjs.map +1 -1
  176. package/fesm2022/ngwr-i18n-fr.mjs +31 -0
  177. package/fesm2022/ngwr-i18n-fr.mjs.map +1 -1
  178. package/fesm2022/ngwr-i18n-he.mjs +31 -0
  179. package/fesm2022/ngwr-i18n-he.mjs.map +1 -1
  180. package/fesm2022/ngwr-i18n-hi.mjs +31 -0
  181. package/fesm2022/ngwr-i18n-hi.mjs.map +1 -1
  182. package/fesm2022/ngwr-i18n-id.mjs +31 -0
  183. package/fesm2022/ngwr-i18n-id.mjs.map +1 -1
  184. package/fesm2022/ngwr-i18n-it.mjs +31 -0
  185. package/fesm2022/ngwr-i18n-it.mjs.map +1 -1
  186. package/fesm2022/ngwr-i18n-ja.mjs +31 -0
  187. package/fesm2022/ngwr-i18n-ja.mjs.map +1 -1
  188. package/fesm2022/ngwr-i18n-ko.mjs +31 -0
  189. package/fesm2022/ngwr-i18n-ko.mjs.map +1 -1
  190. package/fesm2022/ngwr-i18n-nl.mjs +31 -0
  191. package/fesm2022/ngwr-i18n-nl.mjs.map +1 -1
  192. package/fesm2022/ngwr-i18n-pl.mjs +31 -0
  193. package/fesm2022/ngwr-i18n-pl.mjs.map +1 -1
  194. package/fesm2022/ngwr-i18n-pt.mjs +31 -0
  195. package/fesm2022/ngwr-i18n-pt.mjs.map +1 -1
  196. package/fesm2022/ngwr-i18n-ru.mjs +31 -0
  197. package/fesm2022/ngwr-i18n-ru.mjs.map +1 -1
  198. package/fesm2022/ngwr-i18n-sv.mjs +31 -0
  199. package/fesm2022/ngwr-i18n-sv.mjs.map +1 -1
  200. package/fesm2022/ngwr-i18n-tr.mjs +31 -0
  201. package/fesm2022/ngwr-i18n-tr.mjs.map +1 -1
  202. package/fesm2022/ngwr-i18n-uk.mjs +31 -0
  203. package/fesm2022/ngwr-i18n-uk.mjs.map +1 -1
  204. package/fesm2022/ngwr-i18n-vi.mjs +31 -0
  205. package/fesm2022/ngwr-i18n-vi.mjs.map +1 -1
  206. package/fesm2022/ngwr-i18n-zh-TW.mjs +31 -0
  207. package/fesm2022/ngwr-i18n-zh-TW.mjs.map +1 -1
  208. package/fesm2022/ngwr-i18n-zh.mjs +31 -0
  209. package/fesm2022/ngwr-i18n-zh.mjs.map +1 -1
  210. package/fesm2022/ngwr-i18n.mjs +9 -9
  211. package/fesm2022/ngwr-i18n.mjs.map +1 -1
  212. package/fesm2022/ngwr-icon-adapters-feather.mjs.map +1 -1
  213. package/fesm2022/ngwr-icon-adapters-lucide.mjs.map +1 -1
  214. package/fesm2022/ngwr-icon.mjs +6 -6
  215. package/fesm2022/ngwr-icon.mjs.map +1 -1
  216. package/fesm2022/ngwr-image-cropper-testing.mjs.map +1 -1
  217. package/fesm2022/ngwr-image-cropper.mjs +3 -3
  218. package/fesm2022/ngwr-image-cropper.mjs.map +1 -1
  219. package/fesm2022/ngwr-input-number-testing.mjs.map +1 -1
  220. package/fesm2022/ngwr-input-number.mjs +15 -3
  221. package/fesm2022/ngwr-input-number.mjs.map +1 -1
  222. package/fesm2022/ngwr-input-otp-testing.mjs.map +1 -1
  223. package/fesm2022/ngwr-input-otp.mjs +3 -3
  224. package/fesm2022/ngwr-input-otp.mjs.map +1 -1
  225. package/fesm2022/ngwr-input-testing.mjs.map +1 -1
  226. package/fesm2022/ngwr-input.mjs +15 -15
  227. package/fesm2022/ngwr-input.mjs.map +1 -1
  228. package/fesm2022/ngwr-keyboard.mjs +3 -3
  229. package/fesm2022/ngwr-keyboard.mjs.map +1 -1
  230. package/fesm2022/ngwr-knob-testing.mjs.map +1 -1
  231. package/fesm2022/ngwr-knob.mjs +3 -3
  232. package/fesm2022/ngwr-knob.mjs.map +1 -1
  233. package/fesm2022/ngwr-layout.mjs +15 -15
  234. package/fesm2022/ngwr-layout.mjs.map +1 -1
  235. package/fesm2022/ngwr-lightbox-testing.mjs.map +1 -1
  236. package/fesm2022/ngwr-lightbox.mjs +3 -3
  237. package/fesm2022/ngwr-lightbox.mjs.map +1 -1
  238. package/fesm2022/ngwr-line-chart-testing.mjs.map +1 -1
  239. package/fesm2022/ngwr-line-chart.mjs +18 -7
  240. package/fesm2022/ngwr-line-chart.mjs.map +1 -1
  241. package/fesm2022/ngwr-list.mjs +6 -6
  242. package/fesm2022/ngwr-list.mjs.map +1 -1
  243. package/fesm2022/ngwr-loading-bar-router.mjs.map +1 -1
  244. package/fesm2022/ngwr-loading-bar.mjs +6 -6
  245. package/fesm2022/ngwr-loading-bar.mjs.map +1 -1
  246. package/fesm2022/ngwr-markdown-testing.mjs.map +1 -1
  247. package/fesm2022/ngwr-markdown.mjs +798 -17
  248. package/fesm2022/ngwr-markdown.mjs.map +1 -1
  249. package/fesm2022/ngwr-marquee-testing.mjs.map +1 -1
  250. package/fesm2022/ngwr-marquee.mjs +3 -3
  251. package/fesm2022/ngwr-marquee.mjs.map +1 -1
  252. package/fesm2022/ngwr-media.mjs +3 -3
  253. package/fesm2022/ngwr-media.mjs.map +1 -1
  254. package/fesm2022/ngwr-mention-testing.mjs.map +1 -1
  255. package/fesm2022/ngwr-mention.mjs +6 -6
  256. package/fesm2022/ngwr-mention.mjs.map +1 -1
  257. package/fesm2022/ngwr-meta.mjs +6 -6
  258. package/fesm2022/ngwr-meta.mjs.map +1 -1
  259. package/fesm2022/ngwr-meter-group-testing.mjs +7 -3
  260. package/fesm2022/ngwr-meter-group-testing.mjs.map +1 -1
  261. package/fesm2022/ngwr-meter-group.mjs +26 -6
  262. package/fesm2022/ngwr-meter-group.mjs.map +1 -1
  263. package/fesm2022/ngwr-overlay.mjs +6 -6
  264. package/fesm2022/ngwr-overlay.mjs.map +1 -1
  265. package/fesm2022/ngwr-page-header.mjs +13 -5
  266. package/fesm2022/ngwr-page-header.mjs.map +1 -1
  267. package/fesm2022/ngwr-pagination-testing.mjs.map +1 -1
  268. package/fesm2022/ngwr-pagination.mjs +3 -3
  269. package/fesm2022/ngwr-pagination.mjs.map +1 -1
  270. package/fesm2022/ngwr-pipes.mjs +21 -21
  271. package/fesm2022/ngwr-pipes.mjs.map +1 -1
  272. package/fesm2022/ngwr-platform.mjs +9 -9
  273. package/fesm2022/ngwr-platform.mjs.map +1 -1
  274. package/fesm2022/ngwr-popconfirm-testing.mjs.map +1 -1
  275. package/fesm2022/ngwr-popconfirm.mjs +6 -6
  276. package/fesm2022/ngwr-popconfirm.mjs.map +1 -1
  277. package/fesm2022/ngwr-popover-testing.mjs.map +1 -1
  278. package/fesm2022/ngwr-popover.mjs +578 -16
  279. package/fesm2022/ngwr-popover.mjs.map +1 -1
  280. package/fesm2022/ngwr-progress.mjs +3 -3
  281. package/fesm2022/ngwr-progress.mjs.map +1 -1
  282. package/fesm2022/ngwr-pull-to-refresh.mjs +3 -3
  283. package/fesm2022/ngwr-pull-to-refresh.mjs.map +1 -1
  284. package/fesm2022/ngwr-qr.mjs +3 -3
  285. package/fesm2022/ngwr-qr.mjs.map +1 -1
  286. package/fesm2022/ngwr-radio-testing.mjs.map +1 -1
  287. package/fesm2022/ngwr-radio.mjs +6 -6
  288. package/fesm2022/ngwr-radio.mjs.map +1 -1
  289. package/fesm2022/ngwr-rating-testing.mjs.map +1 -1
  290. package/fesm2022/ngwr-rating.mjs +3 -3
  291. package/fesm2022/ngwr-rating.mjs.map +1 -1
  292. package/fesm2022/ngwr-result.mjs +12 -12
  293. package/fesm2022/ngwr-result.mjs.map +1 -1
  294. package/fesm2022/ngwr-rotating-text-testing.mjs.map +1 -1
  295. package/fesm2022/ngwr-rotating-text.mjs +3 -3
  296. package/fesm2022/ngwr-rotating-text.mjs.map +1 -1
  297. package/fesm2022/ngwr-schema-form.mjs +3 -3
  298. package/fesm2022/ngwr-schema-form.mjs.map +1 -1
  299. package/fesm2022/ngwr-scroll.mjs +3 -3
  300. package/fesm2022/ngwr-scroll.mjs.map +1 -1
  301. package/fesm2022/ngwr-segmented-testing.mjs.map +1 -1
  302. package/fesm2022/ngwr-segmented.mjs +3 -3
  303. package/fesm2022/ngwr-segmented.mjs.map +1 -1
  304. package/fesm2022/ngwr-select-testing.mjs.map +1 -1
  305. package/fesm2022/ngwr-select.mjs +12 -12
  306. package/fesm2022/ngwr-select.mjs.map +1 -1
  307. package/fesm2022/ngwr-shiny-text-testing.mjs.map +1 -1
  308. package/fesm2022/ngwr-shiny-text.mjs +6 -6
  309. package/fesm2022/ngwr-shiny-text.mjs.map +1 -1
  310. package/fesm2022/ngwr-sidebar.mjs +10 -3
  311. package/fesm2022/ngwr-sidebar.mjs.map +1 -1
  312. package/fesm2022/ngwr-skeleton.mjs +3 -3
  313. package/fesm2022/ngwr-skeleton.mjs.map +1 -1
  314. package/fesm2022/ngwr-slider-testing.mjs.map +1 -1
  315. package/fesm2022/ngwr-slider.mjs +3 -3
  316. package/fesm2022/ngwr-slider.mjs.map +1 -1
  317. package/fesm2022/ngwr-sparkline-testing.mjs.map +1 -1
  318. package/fesm2022/ngwr-sparkline.mjs +84 -10
  319. package/fesm2022/ngwr-sparkline.mjs.map +1 -1
  320. package/fesm2022/ngwr-speed-dial-testing.mjs.map +1 -1
  321. package/fesm2022/ngwr-speed-dial.mjs +3 -3
  322. package/fesm2022/ngwr-speed-dial.mjs.map +1 -1
  323. package/fesm2022/ngwr-spinner.mjs +3 -3
  324. package/fesm2022/ngwr-spinner.mjs.map +1 -1
  325. package/fesm2022/ngwr-splash-cursor-testing.mjs.map +1 -1
  326. package/fesm2022/ngwr-splash-cursor.mjs +3 -3
  327. package/fesm2022/ngwr-splash-cursor.mjs.map +1 -1
  328. package/fesm2022/ngwr-split-text-testing.mjs.map +1 -1
  329. package/fesm2022/ngwr-split-text.mjs +3 -3
  330. package/fesm2022/ngwr-split-text.mjs.map +1 -1
  331. package/fesm2022/ngwr-splitter-testing.mjs.map +1 -1
  332. package/fesm2022/ngwr-splitter.mjs +3 -3
  333. package/fesm2022/ngwr-splitter.mjs.map +1 -1
  334. package/fesm2022/ngwr-spotlight-card-testing.mjs.map +1 -1
  335. package/fesm2022/ngwr-spotlight-card.mjs +6 -6
  336. package/fesm2022/ngwr-spotlight-card.mjs.map +1 -1
  337. package/fesm2022/ngwr-squircle.mjs +6 -6
  338. package/fesm2022/ngwr-squircle.mjs.map +1 -1
  339. package/fesm2022/ngwr-star-border-testing.mjs.map +1 -1
  340. package/fesm2022/ngwr-star-border.mjs +3 -3
  341. package/fesm2022/ngwr-star-border.mjs.map +1 -1
  342. package/fesm2022/ngwr-statistic.mjs +9 -9
  343. package/fesm2022/ngwr-statistic.mjs.map +1 -1
  344. package/fesm2022/ngwr-stepper-testing.mjs.map +1 -1
  345. package/fesm2022/ngwr-stepper.mjs +6 -6
  346. package/fesm2022/ngwr-stepper.mjs.map +1 -1
  347. package/fesm2022/ngwr-storage.mjs +3 -3
  348. package/fesm2022/ngwr-storage.mjs.map +1 -1
  349. package/fesm2022/ngwr-switch-testing.mjs.map +1 -1
  350. package/fesm2022/ngwr-switch.mjs +3 -3
  351. package/fesm2022/ngwr-switch.mjs.map +1 -1
  352. package/fesm2022/ngwr-table-testing.mjs.map +1 -1
  353. package/fesm2022/ngwr-table.mjs +18 -18
  354. package/fesm2022/ngwr-table.mjs.map +1 -1
  355. package/fesm2022/ngwr-tabs-router.mjs +3 -3
  356. package/fesm2022/ngwr-tabs-router.mjs.map +1 -1
  357. package/fesm2022/ngwr-tabs-testing.mjs.map +1 -1
  358. package/fesm2022/ngwr-tabs.mjs +6 -6
  359. package/fesm2022/ngwr-tabs.mjs.map +1 -1
  360. package/fesm2022/ngwr-textarea-testing.mjs.map +1 -1
  361. package/fesm2022/ngwr-textarea.mjs +3 -3
  362. package/fesm2022/ngwr-textarea.mjs.map +1 -1
  363. package/fesm2022/ngwr-theme.mjs +3 -3
  364. package/fesm2022/ngwr-theme.mjs.map +1 -1
  365. package/fesm2022/ngwr-tilt-card-testing.mjs.map +1 -1
  366. package/fesm2022/ngwr-tilt-card.mjs +6 -6
  367. package/fesm2022/ngwr-tilt-card.mjs.map +1 -1
  368. package/fesm2022/ngwr-timeline.mjs +6 -6
  369. package/fesm2022/ngwr-timeline.mjs.map +1 -1
  370. package/fesm2022/ngwr-toast-testing.mjs.map +1 -1
  371. package/fesm2022/ngwr-toast.mjs +9 -9
  372. package/fesm2022/ngwr-toast.mjs.map +1 -1
  373. package/fesm2022/ngwr-toolbar.mjs +10 -3
  374. package/fesm2022/ngwr-toolbar.mjs.map +1 -1
  375. package/fesm2022/ngwr-tour-testing.mjs.map +1 -1
  376. package/fesm2022/ngwr-tour.mjs +6 -6
  377. package/fesm2022/ngwr-tour.mjs.map +1 -1
  378. package/fesm2022/ngwr-transfer-testing.mjs.map +1 -1
  379. package/fesm2022/ngwr-transfer.mjs +3 -3
  380. package/fesm2022/ngwr-transfer.mjs.map +1 -1
  381. package/fesm2022/ngwr-tree-testing.mjs.map +1 -1
  382. package/fesm2022/ngwr-tree.mjs +3 -3
  383. package/fesm2022/ngwr-tree.mjs.map +1 -1
  384. package/fesm2022/ngwr-typewriter-testing.mjs.map +1 -1
  385. package/fesm2022/ngwr-typewriter.mjs +3 -3
  386. package/fesm2022/ngwr-typewriter.mjs.map +1 -1
  387. package/fesm2022/ngwr-typography.mjs +7 -3
  388. package/fesm2022/ngwr-typography.mjs.map +1 -1
  389. package/fesm2022/ngwr-utils.mjs.map +1 -1
  390. package/fesm2022/ngwr-validators.mjs.map +1 -1
  391. package/fesm2022/ngwr-version.mjs +1 -1
  392. package/fesm2022/ngwr-version.mjs.map +1 -1
  393. package/fesm2022/ngwr-virtual-scroll.mjs +3 -3
  394. package/fesm2022/ngwr-virtual-scroll.mjs.map +1 -1
  395. package/fesm2022/ngwr-waves-testing.mjs.map +1 -1
  396. package/fesm2022/ngwr-waves.mjs +3 -3
  397. package/fesm2022/ngwr-waves.mjs.map +1 -1
  398. package/fesm2022/ngwr-window-testing.mjs.map +1 -1
  399. package/fesm2022/ngwr-window.mjs +12 -12
  400. package/fesm2022/ngwr-window.mjs.map +1 -1
  401. package/form/styles/_index.scss +16 -1
  402. package/gauge/styles/_index.scss +1 -0
  403. package/i18n/ar.json +32 -1
  404. package/i18n/cs.json +32 -1
  405. package/i18n/de.json +32 -1
  406. package/i18n/en.json +32 -1
  407. package/i18n/es.json +32 -1
  408. package/i18n/fr.json +32 -1
  409. package/i18n/he.json +32 -1
  410. package/i18n/hi.json +32 -1
  411. package/i18n/id.json +32 -1
  412. package/i18n/it.json +32 -1
  413. package/i18n/ja.json +32 -1
  414. package/i18n/ko.json +32 -1
  415. package/i18n/nl.json +32 -1
  416. package/i18n/pl.json +32 -1
  417. package/i18n/pt.json +32 -1
  418. package/i18n/ru.json +32 -1
  419. package/i18n/sv.json +32 -1
  420. package/i18n/tr.json +32 -1
  421. package/i18n/uk.json +32 -1
  422. package/i18n/vi.json +32 -1
  423. package/i18n/zh-TW.json +32 -1
  424. package/i18n/zh.json +32 -1
  425. package/input/styles/_index.scss +24 -1
  426. package/input-number/styles/_index.scss +69 -0
  427. package/input-otp/styles/_index.scss +5 -5
  428. package/line-chart/styles/_index.scss +30 -2
  429. package/llms-full.txt +14 -4
  430. package/llms.txt +188 -132
  431. package/mcp/providers.js +2 -2
  432. package/mcp/server.js +1 -1
  433. package/meter-group/styles/_index.scss +1 -0
  434. package/overlay/styles/_arrow.scss +30 -2
  435. package/package.json +43 -2
  436. package/page-header/styles/_index.scss +37 -1
  437. package/pagination/styles/_index.scss +9 -5
  438. package/popover/styles/_index.scss +73 -5
  439. package/progress/styles/_index.scss +4 -0
  440. package/radio/styles/_index.scss +4 -1
  441. package/schematics/use/symbol-map.json +1 -0
  442. package/select/styles/_index.scss +51 -12
  443. package/sidebar/styles/_index.scss +44 -2
  444. package/skeleton/styles/_index.scss +3 -0
  445. package/skills/ngwr/SKILL.md +5 -5
  446. package/skills/ngwr/references/catalog.md +2 -0
  447. package/skills/ngwr/references/setup.md +3 -3
  448. package/sparkline/styles/_index.scss +19 -0
  449. package/styles.scss +1 -0
  450. package/table/styles/_index.scss +7 -0
  451. package/textarea/styles/_index.scss +12 -3
  452. package/theme/styles/_colors.scss +39 -13
  453. package/theme/styles/_contrast.scss +9 -7
  454. package/toast/styles/_index.scss +4 -0
  455. package/toolbar/styles/_index.scss +35 -1
  456. package/tree/styles/_index.scss +46 -7
  457. package/types/ngwr-badge.d.ts +22 -7
  458. package/types/ngwr-bar-chart.d.ts +19 -1
  459. package/types/ngwr-calendar-heatmap.d.ts +29 -1
  460. package/types/ngwr-checkbox.d.ts +2 -0
  461. package/types/ngwr-config.d.ts +12 -0
  462. package/types/ngwr-date-picker.d.ts +308 -43
  463. package/types/ngwr-donut-chart.d.ts +24 -1
  464. package/types/ngwr-dropdown.d.ts +22 -2
  465. package/types/ngwr-editor-testing.d.ts +378 -0
  466. package/types/ngwr-editor.d.ts +449 -0
  467. package/types/ngwr-event-calendar.d.ts +8 -0
  468. package/types/ngwr-form.d.ts +35 -5
  469. package/types/ngwr-gauge.d.ts +20 -1
  470. package/types/ngwr-input-number.d.ts +7 -0
  471. package/types/ngwr-line-chart.d.ts +9 -1
  472. package/types/ngwr-markdown.d.ts +61 -2
  473. package/types/ngwr-meter-group-testing.d.ts +3 -2
  474. package/types/ngwr-meter-group.d.ts +14 -1
  475. package/types/ngwr-page-header.d.ts +10 -2
  476. package/types/ngwr-popover.d.ts +154 -3
  477. package/types/ngwr-sidebar.d.ts +7 -0
  478. package/types/ngwr-sparkline.d.ts +43 -1
  479. package/types/ngwr-toolbar.d.ts +7 -0
  480. package/types/ngwr-typography.d.ts +4 -0
  481. package/types/ngwr-version.d.ts +1 -1
  482. package/typography/styles/_index.scss +16 -0
@@ -1 +1 @@
1
- {"version":3,"file":"ngwr-speed-dial.mjs","sources":["../../../projects/lib/speed-dial/speed-dial.ts","../../../projects/lib/speed-dial/speed-dial.html","../../../projects/lib/speed-dial/ngwr-speed-dial.ts"],"sourcesContent":["/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { coerceBooleanProperty } from '@angular/cdk/coercion';\nimport {\n Component,\n ElementRef,\n ViewEncapsulation,\n computed,\n effect,\n inject,\n input,\n model,\n output,\n viewChild,\n} from '@angular/core';\n\nimport { useI18nText } from 'ngwr/i18n';\nimport { WrIcon, type WrIconName } from 'ngwr/icon';\n\nimport type { WrSpeedDialAction, WrSpeedDialDirection } from './interfaces';\n\nlet menuUid = 0;\n\n/**\n * Floating action button that expands into a fan of secondary actions on click.\n * Place inside a positioned container or near `position: fixed` — the component\n * itself doesn't pin to the viewport.\n *\n * @example\n * ```html\n * <wr-speed-dial\n * [actions]=\"[\n * { id: 'new', label: 'New', icon: 'add' },\n * { id: 'edit', label: 'Edit', icon: 'cog' }\n * ]\"\n * (pick)=\"onPick($event)\"\n * />\n * ```\n *\n * @see https://ngwr.dev/reference/components/speed-dial\n */\n@Component({\n selector: 'wr-speed-dial',\n templateUrl: './speed-dial.html',\n encapsulation: ViewEncapsulation.None,\n host: { '[class]': 'classes()', '(keydown)': 'onKeydown($event)' },\n imports: [WrIcon],\n})\nexport class WrSpeedDial {\n readonly actions = input<readonly WrSpeedDialAction[]>([]);\n\n /**\n * Accessible name of the trigger. Falls back to `speedDial.label`, then\n * `'Actions'` — the trigger is icon-only, so without this it has no name at all.\n */\n readonly triggerLabel = input<string | null>(null);\n\n protected readonly resolvedTriggerLabel = useI18nText(this.triggerLabel, 'speedDial.label', 'Actions');\n\n /** Direction the actions fan out. @default 'up' */\n readonly direction = input<WrSpeedDialDirection>('up');\n\n /** Two-way bindable open state. @default false */\n readonly open = model(false);\n\n /** Icon for the main trigger button. @default 'add' */\n readonly icon = input<WrIconName>('add');\n\n /** Disable interaction. @default false */\n readonly disabled = input(false, { transform: coerceBooleanProperty });\n\n /**\n * Pad the host toward the dial `direction` with `env(safe-area-inset-*)`.\n * Only matters when the consumer pins the dial to that edge of the\n * viewport; otherwise it has no effect. @default false\n */\n readonly safeArea = input(false, { transform: coerceBooleanProperty });\n\n /** Fires when the user picks one of the actions. */\n readonly pick = output<WrSpeedDialAction>();\n\n /** Id the trigger's `aria-controls` points at. */\n protected readonly menuId = `wr-speed-dial-menu-${++menuUid}`;\n\n protected readonly triggerEl = viewChild<ElementRef<HTMLButtonElement>>('trigger');\n\n private readonly host = inject<ElementRef<HTMLElement>>(ElementRef);\n\n constructor() {\n // A disabled trigger cannot be pressed, and the trigger is the only way to close\n // the dial — so being disabled while open left it fanned out with no way back.\n effect(() => {\n if (this.disabled() && this.open()) this.open.set(false);\n });\n }\n\n protected readonly classes = computed(() => {\n const parts = ['wr-speed-dial', `wr-speed-dial--${this.direction()}`];\n if (this.open()) parts.push('wr-speed-dial--open');\n if (this.disabled()) parts.push('wr-speed-dial--disabled');\n if (this.safeArea()) parts.push('wr-speed-dial--safe-area');\n return parts.join(' ');\n });\n\n protected onTrigger(): void {\n if (this.disabled()) return;\n this.open.update(v => !v);\n }\n\n protected onPick(action: WrSpeedDialAction): void {\n if (this.disabled()) return;\n this.open.set(false);\n // Take the focus back before the action goes — the collapsed wrapper turns\n // `visibility: hidden`, and a browser blurs an element it hides, so the caret\n // landed on `<body>` and the next Tab restarted at the top of the document.\n // Escape already did this; the SUCCESS path did not.\n //\n // Before the emit, not after: `pick` is where a consumer opens a dialog or\n // navigates, and such a handler moves focus itself — focusing afterwards would\n // yank the caret back onto the trigger. `wr-dropdown` sequences it the same way.\n //\n // Only when the caret is inside the dial: Safari does not focus a button on\n // mouse-down, so an unguarded call would steal it from wherever the user is.\n if (this.host.nativeElement.contains(this.host.nativeElement.ownerDocument.activeElement)) {\n this.triggerEl()?.nativeElement.focus();\n }\n this.pick.emit(action);\n }\n\n /**\n * Escape closes the dial and hands the caret back. The actions are ordinary buttons\n * in the tab order, so without this a keyboard user who opened the dial had to tab\n * through every action to leave it.\n */\n protected onKeydown(event: KeyboardEvent): void {\n if (event.key !== 'Escape' || !this.open()) return;\n event.preventDefault();\n this.open.set(false);\n this.triggerEl()?.nativeElement.focus();\n }\n\n /**\n * First GLYPH of the label, for an action with no icon. `charAt(0)` returns one\n * UTF-16 code unit, which cuts an astral character (an emoji) in half and renders a\n * replacement character.\n */\n protected initial(label: string): string {\n return [...label][0] ?? '';\n }\n}\n\nexport type { WrSpeedDialAction, WrSpeedDialDirection } from './interfaces';\n","<button\n #trigger\n type=\"button\"\n class=\"wr-speed-dial__trigger\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"menuId\"\n [attr.aria-label]=\"resolvedTriggerLabel()\"\n [disabled]=\"disabled()\"\n (click)=\"onTrigger()\"\n>\n <wr-icon [name]=\"icon()\" />\n</button>\n\n<!--\n A LIST of buttons, deliberately not a `role=\"menu\"`. The dial used to announce\n aria-haspopup=\"menu\" over role=\"menuitem\" buttons while handling no menu key at\n all — no arrows, no Home/End, no focus moving in on open — and the actions were\n N tab stops rather than the pattern's one. That role also puts a screen reader\n into focus mode, so the arrow keys it promises stop reading the page and then do\n nothing here. The structure now says what the component does: a disclosure\n button (aria-expanded / aria-controls) revealing ordinary buttons that Tab\n reaches and Enter activates, with Escape as the way back.\n\n `role=\"list\"` is written out because `list-style: none` (styles/_index.scss)\n drops the implicit list semantics in Safari.\n-->\n<ul class=\"wr-speed-dial__actions\" role=\"list\" [attr.id]=\"menuId\">\n @for (action of actions(); track action.id) {\n <li class=\"wr-speed-dial__action-wrap\" [style.--wr-speed-dial-i]=\"$index + 1\">\n <button\n type=\"button\"\n class=\"wr-speed-dial__action\"\n [attr.aria-label]=\"action.label\"\n [title]=\"action.label\"\n [disabled]=\"disabled()\"\n (click)=\"onPick(action)\"\n >\n @if (action.icon) {\n <wr-icon [name]=\"action.icon\" />\n } @else {\n <span>{{ initial(action.label) }}</span>\n }\n </button>\n </li>\n }\n</ul>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAAA;;;;;AAKG;AAqBH,IAAI,OAAO,GAAG,CAAC;AAEf;;;;;;;;;;;;;;;;;AAiBG;MAQU,WAAW,CAAA;IACb,OAAO,GAAG,KAAK,CAA+B,EAAE;gFAAC;AAE1D;;;AAGG;IACM,YAAY,GAAG,KAAK,CAAgB,IAAI;qFAAC;IAE/B,oBAAoB,GAAG,WAAW,CAAC,IAAI,CAAC,YAAY,EAAE,iBAAiB,EAAE,SAAS,CAAC;;IAG7F,SAAS,GAAG,KAAK,CAAuB,IAAI;kFAAC;;IAG7C,IAAI,GAAG,KAAK,CAAC,KAAK;6EAAC;;IAGnB,IAAI,GAAG,KAAK,CAAa,KAAK;6EAAC;;IAG/B,QAAQ,GAAG,KAAK,CAAC,KAAK,gFAAI,SAAS,EAAE,qBAAqB,EAAA,CAAG;AAEtE;;;;AAIG;IACM,QAAQ,GAAG,KAAK,CAAC,KAAK,gFAAI,SAAS,EAAE,qBAAqB,EAAA,CAAG;;IAG7D,IAAI,GAAG,MAAM,EAAqB;;AAGxB,IAAA,MAAM,GAAG,CAAA,mBAAA,EAAsB,EAAE,OAAO,EAAE;IAE1C,SAAS,GAAG,SAAS,CAAgC,SAAS;kFAAC;AAEjE,IAAA,IAAI,GAAG,MAAM,CAA0B,UAAU,CAAC;AAEnE,IAAA,WAAA,GAAA;;;QAGE,MAAM,CAAC,MAAK;YACV,IAAI,IAAI,CAAC,QAAQ,EAAE,IAAI,IAAI,CAAC,IAAI,EAAE;AAAE,gBAAA,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC;AAC1D,QAAA,CAAC,CAAC;IACJ;AAEmB,IAAA,OAAO,GAAG,Q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wr-speed-dial.mjs","sources":["../../../projects/lib/speed-dial/speed-dial.ts","../../../projects/lib/speed-dial/speed-dial.html","../../../projects/lib/speed-dial/ngwr-speed-dial.ts"],"sourcesContent":["/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { coerceBooleanProperty } from '@angular/cdk/coercion';\nimport {\n Component,\n ElementRef,\n ViewEncapsulation,\n computed,\n effect,\n inject,\n input,\n model,\n output,\n viewChild,\n} from '@angular/core';\n\nimport { useI18nText } from 'ngwr/i18n';\nimport { WrIcon, type WrIconName } from 'ngwr/icon';\n\nimport type { WrSpeedDialAction, WrSpeedDialDirection } from './interfaces';\n\nlet menuUid = 0;\n\n/**\n * Floating action button that expands into a fan of secondary actions on click.\n * Place inside a positioned container or near `position: fixed` — the component\n * itself doesn't pin to the viewport.\n *\n * @example\n * ```html\n * <wr-speed-dial\n * [actions]=\"[\n * { id: 'new', label: 'New', icon: 'add' },\n * { id: 'edit', label: 'Edit', icon: 'cog' }\n * ]\"\n * (pick)=\"onPick($event)\"\n * />\n * ```\n *\n * @see https://ngwr.dev/reference/components/speed-dial\n */\n@Component({\n selector: 'wr-speed-dial',\n templateUrl: './speed-dial.html',\n encapsulation: ViewEncapsulation.None,\n host: { '[class]': 'classes()', '(keydown)': 'onKeydown($event)' },\n imports: [WrIcon],\n})\nexport class WrSpeedDial {\n readonly actions = input<readonly WrSpeedDialAction[]>([]);\n\n /**\n * Accessible name of the trigger. Falls back to `speedDial.label`, then\n * `'Actions'` — the trigger is icon-only, so without this it has no name at all.\n */\n readonly triggerLabel = input<string | null>(null);\n\n protected readonly resolvedTriggerLabel = useI18nText(this.triggerLabel, 'speedDial.label', 'Actions');\n\n /** Direction the actions fan out. @default 'up' */\n readonly direction = input<WrSpeedDialDirection>('up');\n\n /** Two-way bindable open state. @default false */\n readonly open = model(false);\n\n /** Icon for the main trigger button. @default 'add' */\n readonly icon = input<WrIconName>('add');\n\n /** Disable interaction. @default false */\n readonly disabled = input(false, { transform: coerceBooleanProperty });\n\n /**\n * Pad the host toward the dial `direction` with `env(safe-area-inset-*)`.\n * Only matters when the consumer pins the dial to that edge of the\n * viewport; otherwise it has no effect. @default false\n */\n readonly safeArea = input(false, { transform: coerceBooleanProperty });\n\n /** Fires when the user picks one of the actions. */\n readonly pick = output<WrSpeedDialAction>();\n\n /** Id the trigger's `aria-controls` points at. */\n protected readonly menuId = `wr-speed-dial-menu-${++menuUid}`;\n\n protected readonly triggerEl = viewChild<ElementRef<HTMLButtonElement>>('trigger');\n\n private readonly host = inject<ElementRef<HTMLElement>>(ElementRef);\n\n constructor() {\n // A disabled trigger cannot be pressed, and the trigger is the only way to close\n // the dial — so being disabled while open left it fanned out with no way back.\n effect(() => {\n if (this.disabled() && this.open()) this.open.set(false);\n });\n }\n\n protected readonly classes = computed(() => {\n const parts = ['wr-speed-dial', `wr-speed-dial--${this.direction()}`];\n if (this.open()) parts.push('wr-speed-dial--open');\n if (this.disabled()) parts.push('wr-speed-dial--disabled');\n if (this.safeArea()) parts.push('wr-speed-dial--safe-area');\n return parts.join(' ');\n });\n\n protected onTrigger(): void {\n if (this.disabled()) return;\n this.open.update(v => !v);\n }\n\n protected onPick(action: WrSpeedDialAction): void {\n if (this.disabled()) return;\n this.open.set(false);\n // Take the focus back before the action goes — the collapsed wrapper turns\n // `visibility: hidden`, and a browser blurs an element it hides, so the caret\n // landed on `<body>` and the next Tab restarted at the top of the document.\n // Escape already did this; the SUCCESS path did not.\n //\n // Before the emit, not after: `pick` is where a consumer opens a dialog or\n // navigates, and such a handler moves focus itself — focusing afterwards would\n // yank the caret back onto the trigger. `wr-dropdown` sequences it the same way.\n //\n // Only when the caret is inside the dial: Safari does not focus a button on\n // mouse-down, so an unguarded call would steal it from wherever the user is.\n if (this.host.nativeElement.contains(this.host.nativeElement.ownerDocument.activeElement)) {\n this.triggerEl()?.nativeElement.focus();\n }\n this.pick.emit(action);\n }\n\n /**\n * Escape closes the dial and hands the caret back. The actions are ordinary buttons\n * in the tab order, so without this a keyboard user who opened the dial had to tab\n * through every action to leave it.\n */\n protected onKeydown(event: KeyboardEvent): void {\n if (event.key !== 'Escape' || !this.open()) return;\n event.preventDefault();\n this.open.set(false);\n this.triggerEl()?.nativeElement.focus();\n }\n\n /**\n * First GLYPH of the label, for an action with no icon. `charAt(0)` returns one\n * UTF-16 code unit, which cuts an astral character (an emoji) in half and renders a\n * replacement character.\n */\n protected initial(label: string): string {\n return [...label][0] ?? '';\n }\n}\n\nexport type { WrSpeedDialAction, WrSpeedDialDirection } from './interfaces';\n","<button\n #trigger\n type=\"button\"\n class=\"wr-speed-dial__trigger\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"menuId\"\n [attr.aria-label]=\"resolvedTriggerLabel()\"\n [disabled]=\"disabled()\"\n (click)=\"onTrigger()\"\n>\n <wr-icon [name]=\"icon()\" />\n</button>\n\n<!--\n A LIST of buttons, deliberately not a `role=\"menu\"`. The dial used to announce\n aria-haspopup=\"menu\" over role=\"menuitem\" buttons while handling no menu key at\n all — no arrows, no Home/End, no focus moving in on open — and the actions were\n N tab stops rather than the pattern's one. That role also puts a screen reader\n into focus mode, so the arrow keys it promises stop reading the page and then do\n nothing here. The structure now says what the component does: a disclosure\n button (aria-expanded / aria-controls) revealing ordinary buttons that Tab\n reaches and Enter activates, with Escape as the way back.\n\n `role=\"list\"` is written out because `list-style: none` (styles/_index.scss)\n drops the implicit list semantics in Safari.\n-->\n<ul class=\"wr-speed-dial__actions\" role=\"list\" [attr.id]=\"menuId\">\n @for (action of actions(); track action.id) {\n <li class=\"wr-speed-dial__action-wrap\" [style.--wr-speed-dial-i]=\"$index + 1\">\n <button\n type=\"button\"\n class=\"wr-speed-dial__action\"\n [attr.aria-label]=\"action.label\"\n [title]=\"action.label\"\n [disabled]=\"disabled()\"\n (click)=\"onPick(action)\"\n >\n @if (action.icon) {\n <wr-icon [name]=\"action.icon\" />\n } @else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44
44
  ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
45
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: WrSpinner, deps: [], target: i0.ɵɵFactoryTarget.Component });
46
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.6", type: WrSpinner, isStandalone: true, selector: "wr-spinner", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "status" }, properties: { "attr.aria-label": "resolvedAriaLabel()", "class": "classes()" } }, ngImport: i0, template: "<svg viewBox=\"0 0 50 50\" aria-hidden=\"true\">\n <circle class=\"wr-spinner__path\" cx=\"25\" cy=\"25\" r=\"20\" fill=\"none\" stroke-width=\"5\" />\n</svg>\n", encapsulation: i0.ViewEncapsulation.None });
45
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: WrSpinner, deps: [], target: i0.ɵɵFactoryTarget.Component });
46
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.7", type: WrSpinner, isStandalone: true, selector: "wr-spinner", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "status" }, properties: { "attr.aria-label": "resolvedAriaLabel()", "class": "classes()" } }, ngImport: i0, template: "<svg viewBox=\"0 0 50 50\" aria-hidden=\"true\">\n <circle class=\"wr-spinner__path\" cx=\"25\" cy=\"25\" r=\"20\" fill=\"none\" stroke-width=\"5\" />\n</svg>\n", encapsulation: i0.ViewEncapsulation.None });
47
47
  }
48
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: WrSpinner, decorators: [{
48
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: WrSpinner, decorators: [{
49
49
  type: Component,
50
50
  args: [{ selector: 'wr-spinner', encapsulation: ViewEncapsulation.None, host: {
51
51
  role: 'status',
@@ -1 +1 @@
1
- {"version":3,"file":"ngwr-spinner.mjs","sources":["../../../projects/lib/spinner/spinner.ts","../../../projects/lib/spinner/spinner.html","../../../projects/lib/spinner/ngwr-spinner.ts"],"sourcesContent":["/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { Component, ViewEncapsulation, computed, input } from '@angular/core';\n\nimport { useI18nText } from 'ngwr/i18n';\n\nimport type { WrSpinnerSize } from './interfaces';\n\n/**\n * Inline loading indicator.\n *\n * Inherits color from the surrounding text (uses `currentColor`).\n *\n * @example\n * ```html\n * <wr-spinner />\n * <wr-spinner size=\"lg\" />\n * ```\n *\n * @see https://ngwr.dev/reference/components/spinner\n */\n@Component({\n selector: 'wr-spinner',\n templateUrl: './spinner.html',\n encapsulation: ViewEncapsulation.None,\n host: {\n role: 'status',\n '[attr.aria-label]': 'resolvedAriaLabel()',\n '[class]': 'classes()',\n },\n})\nexport class WrSpinner {\n /**\n * Size variant. Em-based — scales with surrounding font-size.\n *\n * @default 'md'\n */\n readonly size = input<WrSpinnerSize>('md');\n\n /**\n * Accessible name for the live region. Falls back to `spinner.label`, then\n * `'Loading'` — which the host used to carry as a hard-coded attribute, while\n * the catalog had the translated key for it all along.\n */\n readonly ariaLabel = input<string | null>(null);\n\n protected readonly resolvedAriaLabel = useI18nText(this.ariaLabel, 'spinner.label', 'Loading');\n\n protected readonly classes = computed(() => {\n const size = this.size();\n return size === 'md' ? 'wr-spinner' : `wr-spinner wr-spinner--${size}`;\n });\n}\n","<svg viewBox=\"0 0 50 50\" aria-hidden=\"true\">\n <circle class=\"wr-spinner__path\" cx=\"25\" cy=\"25\" r=\"20\" fill=\"none\" stroke-width=\"5\" />\n</svg>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;AAAA;;;;;AAKG;AAQH;;;;;;;;;;;;AAYG;MAWU,SAAS,CAAA;AACpB;;;;AAIG;IACM,IAAI,GAAG,KAAK,CAAgB,IAAI;6EAAC;AAE1C;;;;AAIG;IACM,SAAS,GAAG,KAAK,CAAgB,IAAI;kFAAC;IAE5B,iBAAiB,GAAG,WAAW,CAAC,IAAI,CAAC,SAAS,EAAE,eAAe,EAAE,SAAS,CAAC;AAE3E,IAAA,OAAO,GAAG,QAAQ,CAAC,MAAK;AACzC,QAAA,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,EAAE;AACxB,QAAA,OAAO,IAAI,KAAK,IAAI,GAAG,YAAY,GAAG,CAAA,uBAAA,EAA0B,IAAI,EAAE;IACxE,CAAC;gFAAC;uGApBS,SAAS,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAT,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,SAAS,ucCpCtB,mKAGA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA;;2FDiCa,SAAS,EAAA,UAAA,EAAA,CAAA;kBAVrB,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,YAAY,EAAA,aAAA,EAEP,iBAAiB,CAAC,IAAI,EAAA,IAAA,EAC/B;AACJ,wBAAA,IAAI,EAAE,QAAQ;AACd,wBAAA,mBAAmB,EAAE,qBAAqB;AAC1C,wBAAA,SAAS,EAAE,WAAW;AACvB,qBAAA,EAAA,QAAA,EAAA,mKAAA,EAAA;;;AElCH;;AAEG;;;;"}
1
+ {"version":3,"file":"ngwr-spinner.mjs","sources":["../../../projects/lib/spinner/spinner.ts","../../../projects/lib/spinner/spinner.html","../../../projects/lib/spinner/ngwr-spinner.ts"],"sourcesContent":["/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { Component, ViewEncapsulation, computed, input } from '@angular/core';\n\nimport { useI18nText } from 'ngwr/i18n';\n\nimport type { WrSpinnerSize } from './interfaces';\n\n/**\n * Inline loading indicator.\n *\n * Inherits color from the surrounding text (uses `currentColor`).\n *\n * @example\n * ```html\n * <wr-spinner />\n * <wr-spinner size=\"lg\" />\n * ```\n *\n * @see https://ngwr.dev/reference/components/spinner\n */\n@Component({\n selector: 'wr-spinner',\n templateUrl: './spinner.html',\n encapsulation: ViewEncapsulation.None,\n host: {\n role: 'status',\n '[attr.aria-label]': 'resolvedAriaLabel()',\n '[class]': 'classes()',\n },\n})\nexport class WrSpinner {\n /**\n * Size variant. Em-based — scales with surrounding font-size.\n *\n * @default 'md'\n */\n readonly size = input<WrSpinnerSize>('md');\n\n /**\n * Accessible name for the live region. Falls back to `spinner.label`, then\n * `'Loading'` — which the host used to carry as a hard-coded attribute, while\n * the catalog had the translated key for it all along.\n */\n readonly ariaLabel = input<string | null>(null);\n\n protected readonly resolvedAriaLabel = useI18nText(this.ariaLabel, 'spinner.label', 'Loading');\n\n protected readonly classes = computed(() => {\n const size = this.size();\n return size === 'md' ? 'wr-spinner' : `wr-spinner wr-spinner--${size}`;\n });\n}\n","<svg viewBox=\"0 0 50 50\" aria-hidden=\"true\">\n <circle class=\"wr-spinner__path\" cx=\"25\" cy=\"25\" r=\"20\" fill=\"none\" stroke-width=\"5\" />\n</svg>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;AAAA;;;;;AAKG;AAQH;;;;;;;;;;;;AAYG;MAWU,SAAS,CAAA;AACpB;;;;AAIG;IACM,IAAI,GAAG,KAAK,CAAgB,IAAI;6EAAC;AAE1C;;;;AAIG;IACM,SAAS,GAAG,KAAK,CAAgB,IAAI;kFAAC;IAE5B,iBAAiB,GAAG,WAAW,CAAC,IAAI,CAAC,SAAS,EAAE,eAAe,EAAE,SAAS,CAAC;AAE3E,IAAA,OAAO,GAAG,QAAQ,CAAC,MAAK;AACzC,QAAA,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,EAAE;AACxB,QAAA,OAAO,IAAI,KAAK,IAAI,GAAG,YAAY,GAAG,CAAA,uBAAA,EAA0B,IAAI,EAAE;IACxE,CAAC;gFAAC;uGApBS,SAAS,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAT,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,SAAS,ucCpCtB,mKAGA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA;;2FDiCa,SAAS,EAAA,UAAA,EAAA,CAAA;kBAVrB,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,YAAY,EAAA,aAAA,EAEP,iBAAiB,CAAC,IAAI,EAAA,IAAA,EAC/B;AACJ,wBAAA,IAAI,EAAE,QAAQ;AACd,wBAAA,mBAAmB,EAAE,qBAAqB;AAC1C,wBAAA,SAAS,EAAE,WAAW;AACvB,qBAAA,EAAA,QAAA,EAAA,mKAAA,EAAA;;;AElCH;;AAEG;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"ngwr-splash-cursor-testing.mjs","sources":["../../../projects/lib/splash-cursor/testing/wr-splash-cursor-harness.ts","../../../projects/lib/splash-cursor/testing/ngwr-splash-cursor-testing.ts"],"sourcesContent":["/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { ComponentHarness, HarnessPredicate } from '@angular/cdk/testing';\n\nimport type { WrSplashCursorHarnessFilters } from './interfaces';\n\n/**\n * Test harness for `<wr-splash-cursor>` — a WebGL fluid that splashes dye under the\n * pointer.\n *\n * **This is a deliberately small surface, and the reason is the component.** The\n * simulation is GL programs and framebuffers driven by `window` pointer listeners; the\n * layout is `position: fixed`, `inset: 0`, `z-index: 50` and a `100dvh` canvas, all of\n * it in the stylesheet. A unit test gets no WebGL context — the simulation is never\n * constructed — and loads no stylesheet, so asking `getCssValue('position')` would\n * answer `static` about a component whose whole layout contract is `fixed`. Three\n * questions survive that, and they are the three below.\n *\n * There is no `isSimulating()`, `getSplatCount()` or `splat()`: the simulation returns\n * `null` the moment the context is refused, so every one of those would report on\n * something that was never built. No `moveMouse()` either — the listeners live on\n * `window` and are only attached once a context exists, so a dispatched move reaches\n * nothing. And no `isReducedMotion()` or `hasWebGL()`: the component renders\n * byte-identical DOM whether it is running, standing down for reduced motion, or on a\n * machine with no WebGL at all, so any answer would be the same for a working component\n * and a broken one.\n *\n * @example\n * ```ts\n * const splash = await loader.getHarness(WrSplashCursorHarness);\n *\n * expect(await splash.isFullscreen()).toBe(true);\n * expect(await splash.isDecorative()).toBe(true);\n * ```\n *\n * @see https://ngwr.dev/guides/testing\n */\nexport class WrSplashCursorHarness extends ComponentHarness {\n static hostSelector = 'wr-splash-cursor';\n\n /** Build a predicate that narrows the query — pass to `getHarness` / `getAllHarnesses`. */\n static with(options: WrSplashCursorHarnessFilters = {}): HarnessPredicate<WrSplashCursorHarness> {\n return new HarnessPredicate(WrSplashCursorHarness, options).addOption(\n 'fullscreen',\n options.fullscreen,\n async (harness, fullscreen) => (await harness.isFullscreen()) === fullscreen\n );\n }\n\n /**\n * Whether the effect covers the whole viewport, rather than filling the nearest\n * positioned ancestor.\n *\n * The component's one behavioural switch: fullscreen is a fixed, click-through\n * overlay above the page, contained is an absolutely positioned box whose walls the\n * dye collides with. Note what is being read — there is no `--fullscreen` class, only\n * a `--contained` one written from a NEGATED binding, so this method answers the\n * absence of a class. That inversion is exactly the kind that gets flipped in a\n * refactor and looks fine on a page where the effect is full-viewport anyway, which\n * is the whole reason the method exists.\n */\n async isFullscreen(): Promise<boolean> {\n return !(await (await this.host()).hasClass('wr-splash-cursor--contained'));\n }\n\n /**\n * Whether the effect is hidden from assistive tech.\n *\n * It has no text and nothing to say, and at full size it sits in front of the entire\n * page — so losing this puts a nameless graphic over everything a screen reader is\n * trying to get through.\n */\n async isDecorative(): Promise<boolean> {\n return (await (await this.locatorFor('.wr-splash-cursor__canvas')()).getAttribute('aria-hidden')) === 'true';\n }\n\n /**\n * Whether the drawing surface is in the markup.\n *\n * It is there in all three states where nothing is ever drawn on it — prerendered on\n * the server, WebGL refused, or reduced motion — because the documented contract is\n * that the component renders nothing VISIBLE and stops, never that it renders no\n * element and never that it throws on a null context.\n */\n async hasCanvas(): Promise<boolean> {\n return (await this.locatorForOptional('.wr-splash-cursor__canvas')()) !== null;\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;AAAA;;;;;AAKG;AAMH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA8BG;AACG,MAAO,qBAAsB,SAAQ,gBAAgB,CAAA;AACzD,IAAA,OAAO,YAAY,GAAG,kBAAkB;;AAGxC,IAAA,OAAO,IAAI,CAAC,OAAA,GAAwC,EAAE,EAAA;AACpD,QAAA,OAAO,IAAI,gBAAgB,CAAC,qBAAqB,EAAE,OAAO,CAAC,CAAC,SAAS,CACnE,YAAY,EACZ,OAAO,CAAC,UAAU,EAClB,OAAO,OAAO,EAAE,UAAU,KAAK,CAAC,MAAM,OAAO,CAAC,YAAY,EAAE,MAAM,UAAU,CAC7E;IACH;AAEA;;;;;;;;;;;AAWG;AACH,IAAA,MAAM,YAAY,GAAA;AAChB,QAAA,OAAO,EAAE,MAAM,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,QAAQ,CAAC,6BAA6B,CAAC,CAAC;IAC7E;AAEA;;;;;;AAMG;AACH,IAAA,MAAM,YAAY,GAAA;QAChB,OAAO,CAAC,MAAM,CAAC,MAAM,IAAI,CAAC,UAAU,CAAC,2BAA2B,CAAC,EAAE,EAAE,YAAY,CAAC,aAAa,CAAC,MAAM,MAAM;IAC9G;AAEA;;;;;;;AAOG;AACH,IAAA,MAAM,SAAS,GAAA;AACb,QAAA,OAAO,CAAC,MAAM,IAAI,CAAC,kBAAkB,CAAC,2BAA2B,CAAC,EAAE,MAAM,IAAI;IAChF;;;AC3FF;;AAEG;;;;"}
1
+ {"version":3,"file":"ngwr-splash-cursor-testing.mjs","sources":["../../../projects/lib/splash-cursor/testing/wr-splash-cursor-harness.ts","../../../projects/lib/splash-cursor/testing/ngwr-splash-cursor-testing.ts"],"sourcesContent":["/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { ComponentHarness, HarnessPredicate } from '@angular/cdk/testing';\n\nimport type { WrSplashCursorHarnessFilters } from './interfaces';\n\n/**\n * Test harness for `<wr-splash-cursor>` — a WebGL fluid that splashes dye under the\n * pointer.\n *\n * **This is a deliberately small surface, and the reason is the component.** The\n * simulation is GL programs and framebuffers driven by `window` pointer listeners; the\n * layout is `position: fixed`, `inset: 0`, `z-index: 50` and a `100dvh` canvas, all of\n * it in the stylesheet. A unit test gets no WebGL context — the simulation is never\n * constructed — and loads no stylesheet, so asking `getCssValue('position')` would\n * answer `static` about a component whose whole layout contract is `fixed`. Three\n * questions survive that, and they are the three below.\n *\n * There is no `isSimulating()`, `getSplatCount()` or `splat()`: the simulation returns\n * `null` the moment the context is refused, so every one of those would report on\n * something that was never built. No `moveMouse()` either — the listeners live on\n * `window` and are only attached once a context exists, so a dispatched move reaches\n * nothing. And no `isReducedMotion()` or `hasWebGL()`: the component renders\n * byte-identical DOM whether it is running, standing down for reduced motion, or on a\n * machine with no WebGL at all, so any answer would be the same for a working component\n * and a broken one.\n *\n * @example\n * ```ts\n * const splash = await loader.getHarness(WrSplashCursorHarness);\n *\n * expect(await splash.isFullscreen()).toBe(true);\n * expect(await splash.isDecorative()).toBe(true);\n * ```\n *\n * @see https://ngwr.dev/guides/testing\n */\nexport class WrSplashCursorHarness extends ComponentHarness {\n static hostSelector = 'wr-splash-cursor';\n\n /** Build a predicate that narrows the query — pass to `getHarness` / `getAllHarnesses`. */\n static with(options: WrSplashCursorHarnessFilters = {}): HarnessPredicate<WrSplashCursorHarness> {\n return new HarnessPredicate(WrSplashCursorHarness, options).addOption(\n 'fullscreen',\n options.fullscreen,\n async (harness, fullscreen) => (await harness.isFullscreen()) === fullscreen\n );\n }\n\n /**\n * Whether the effect covers the whole viewport, rather than filling the nearest\n * positioned ancestor.\n *\n * The component's one behavioural switch: fullscreen is a fixed, click-through\n * overlay above the page, contained is an absolutely positioned box whose walls the\n * dye collides with. Note what is being read — there is no `--fullscreen` class, only\n * a `--contained` one written from a NEGATED binding, so this method answers the\n * absence of a class. That inversion is exactly the kind that gets flipped in a\n * refactor and looks fine on a page where the effect is full-viewport anyway, which\n * is the whole reason the method exists.\n */\n async isFullscreen(): Promise<boolean> {\n return !(await (await this.host()).hasClass('wr-splash-cursor--contained'));\n }\n\n /**\n * Whether the effect is hidden from assistive tech.\n *\n * It has no text and nothing to say, and at full size it sits in front of the entire\n * page — so losing this puts a nameless graphic over everything a screen reader is\n * trying to get through.\n */\n async isDecorative(): Promise<boolean> {\n return (await (await this.locatorFor('.wr-splash-cursor__canvas')()).getAttribute('aria-hidden')) === 'true';\n }\n\n /**\n * Whether the drawing surface is in the markup.\n *\n * It is there in all three states where nothing is ever drawn on it — prerendered on\n * the server, WebGL refused, or reduced motion — because the documented contract is\n * that the component renders nothing VISIBLE and stops, never that it renders no\n * element and never that it throws on a null context.\n */\n async hasCanvas(): Promise<boolean> {\n return (await this.locatorForOptional('.wr-splash-cursor__canvas')()) !== null;\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;AAAA;;;;;AAKG;AAMH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA8BG;AACG,MAAO,qBAAsB,SAAQ,gBAAgB,CAAA;AACzD,IAAA,OAAO,YAAY,GAAG,kBAAkB;;AAGxC,IAAA,OAAO,IAAI,CAAC,OAAA,GAAwC,EAAE,EAAA;AACpD,QAAA,OAAO,IAAI,gBAAgB,CAAC,qBAAqB,EAAE,OAAO,CAAC,CAAC,SAAS,CACnE,YAAY,EACZ,OAAO,CAAC,UAAU,EAClB,OAAO,OAAO,EAAE,UAAU,KAAK,CAAC,MAAM,OAAO,CAAC,YAAY,EAAE,MAAM,UAAU,CAC7E;IACH;AAEA;;;;;;;;;;;AAWG;AACH,IAAA,MAAM,YAAY,GAAA;AAChB,QAAA,OAAO,EAAE,MAAM,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,QAAQ,CAAC,6BAA6B,CAAC,CAAC;IAC7E;AAEA;;;;;;AAMG;AACH,IAAA,MAAM,YAAY,GAAA;QAChB,OAAO,CAAC,MAAM,CAAC,MAAM,IAAI,CAAC,UAAU,CAAC,2BAA2B,CAAC,EAAE,EAAE,YAAY,CAAC,aAAa,CAAC,MAAM,MAAM;IAC9G;AAEA;;;;;;;AAOG;AACH,IAAA,MAAM,SAAS,GAAA;AACb,QAAA,OAAO,CAAC,MAAM,IAAI,CAAC,kBAAkB,CAAC,2BAA2B,CAAC,EAAE,MAAM,IAAI;IAChF;;;AC3FF;;AAEG;;"}
@@ -951,10 +951,10 @@ class WrSplashCursor {
951
951
  onCleanup(teardown);
952
952
  });
953
953
  }
954
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: WrSplashCursor, deps: [], target: i0.ɵɵFactoryTarget.Component });
955
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "22.1.6", type: WrSplashCursor, isStandalone: true, selector: "wr-splash-cursor", inputs: { fullscreen: { classPropertyName: "fullscreen", publicName: "fullscreen", isSignal: true, isRequired: false, transformFunction: null }, simResolution: { classPropertyName: "simResolution", publicName: "simResolution", isSignal: true, isRequired: false, transformFunction: null }, dyeResolution: { classPropertyName: "dyeResolution", publicName: "dyeResolution", isSignal: true, isRequired: false, transformFunction: null }, densityDissipation: { classPropertyName: "densityDissipation", publicName: "densityDissipation", isSignal: true, isRequired: false, transformFunction: null }, velocityDissipation: { classPropertyName: "velocityDissipation", publicName: "velocityDissipation", isSignal: true, isRequired: false, transformFunction: null }, pressure: { classPropertyName: "pressure", publicName: "pressure", isSignal: true, isRequired: false, transformFunction: null }, pressureIterations: { classPropertyName: "pressureIterations", publicName: "pressureIterations", isSignal: true, isRequired: false, transformFunction: null }, curl: { classPropertyName: "curl", publicName: "curl", isSignal: true, isRequired: false, transformFunction: null }, splatRadius: { classPropertyName: "splatRadius", publicName: "splatRadius", isSignal: true, isRequired: false, transformFunction: null }, splatForce: { classPropertyName: "splatForce", publicName: "splatForce", isSignal: true, isRequired: false, transformFunction: null }, shading: { classPropertyName: "shading", publicName: "shading", isSignal: true, isRequired: false, transformFunction: null }, colorUpdateSpeed: { classPropertyName: "colorUpdateSpeed", publicName: "colorUpdateSpeed", isSignal: true, isRequired: false, transformFunction: null }, rainbow: { classPropertyName: "rainbow", publicName: "rainbow", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class.wr-splash-cursor--contained": "!fullscreen()" }, classAttribute: "wr-splash-cursor" }, viewQueries: [{ propertyName: "canvasRef", first: true, predicate: ["canvas"], descendants: true, isSignal: true }], ngImport: i0, template: '<canvas #canvas class="wr-splash-cursor__canvas" aria-hidden="true"></canvas>', isInline: true, styles: [".wr-splash-cursor{position:fixed;inset:0;z-index:50;display:block;pointer-events:none}.wr-splash-cursor__canvas{display:block;width:100vw;height:100vh;height:100dvh}.wr-splash-cursor--contained{position:absolute;z-index:0}.wr-splash-cursor--contained .wr-splash-cursor__canvas{width:100%;height:100%}\n"], encapsulation: i0.ViewEncapsulation.None });
954
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: WrSplashCursor, deps: [], target: i0.ɵɵFactoryTarget.Component });
955
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "22.1.7", type: WrSplashCursor, isStandalone: true, selector: "wr-splash-cursor", inputs: { fullscreen: { classPropertyName: "fullscreen", publicName: "fullscreen", isSignal: true, isRequired: false, transformFunction: null }, simResolution: { classPropertyName: "simResolution", publicName: "simResolution", isSignal: true, isRequired: false, transformFunction: null }, dyeResolution: { classPropertyName: "dyeResolution", publicName: "dyeResolution", isSignal: true, isRequired: false, transformFunction: null }, densityDissipation: { classPropertyName: "densityDissipation", publicName: "densityDissipation", isSignal: true, isRequired: false, transformFunction: null }, velocityDissipation: { classPropertyName: "velocityDissipation", publicName: "velocityDissipation", isSignal: true, isRequired: false, transformFunction: null }, pressure: { classPropertyName: "pressure", publicName: "pressure", isSignal: true, isRequired: false, transformFunction: null }, pressureIterations: { classPropertyName: "pressureIterations", publicName: "pressureIterations", isSignal: true, isRequired: false, transformFunction: null }, curl: { classPropertyName: "curl", publicName: "curl", isSignal: true, isRequired: false, transformFunction: null }, splatRadius: { classPropertyName: "splatRadius", publicName: "splatRadius", isSignal: true, isRequired: false, transformFunction: null }, splatForce: { classPropertyName: "splatForce", publicName: "splatForce", isSignal: true, isRequired: false, transformFunction: null }, shading: { classPropertyName: "shading", publicName: "shading", isSignal: true, isRequired: false, transformFunction: null }, colorUpdateSpeed: { classPropertyName: "colorUpdateSpeed", publicName: "colorUpdateSpeed", isSignal: true, isRequired: false, transformFunction: null }, rainbow: { classPropertyName: "rainbow", publicName: "rainbow", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class.wr-splash-cursor--contained": "!fullscreen()" }, classAttribute: "wr-splash-cursor" }, viewQueries: [{ propertyName: "canvasRef", first: true, predicate: ["canvas"], descendants: true, isSignal: true }], ngImport: i0, template: '<canvas #canvas class="wr-splash-cursor__canvas" aria-hidden="true"></canvas>', isInline: true, styles: [".wr-splash-cursor{position:fixed;inset:0;z-index:50;display:block;pointer-events:none}.wr-splash-cursor__canvas{display:block;width:100vw;height:100vh;height:100dvh}.wr-splash-cursor--contained{position:absolute;z-index:0}.wr-splash-cursor--contained .wr-splash-cursor__canvas{width:100%;height:100%}\n"], encapsulation: i0.ViewEncapsulation.None });
956
956
  }
957
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: WrSplashCursor, decorators: [{
957
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: WrSplashCursor, decorators: [{
958
958
  type: Component,
959
959
  args: [{ selector: 'wr-splash-cursor', template: '<canvas #canvas class="wr-splash-cursor__canvas" aria-hidden="true"></canvas>', encapsulation: ViewEncapsulation.None, host: {
960
960
  class: 'wr-splash-cursor',
@@ -1 +1 @@
1
- {"version":3,"file":"ngwr-splash-cursor.mjs","sources":["../../../projects/lib/splash-cursor/fluid.ts","../../../projects/lib/splash-cursor/splash-cursor.ts","../../../projects/lib/splash-cursor/ngwr-splash-cursor.ts"],"sourcesContent":["/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n *\n * WebGL fluid simulation behind `<wr-splash-cursor>`. Port of the engine\n * used by reactbits.dev's SplashCursor (itself based on Pavel Dobryakov's\n * WebGL-Fluid-Simulation, MIT).\n *\n * Framework-free on purpose: `createFluidSimulation(canvas, config)` boots\n * the sim and returns a teardown, or `null` when WebGL isn't available.\n */\n\n/* eslint-disable no-bitwise -- GL bitmasks + string hashing are inherently bitwise */\n\ninterface WrFluidConfig {\n readonly simResolution: number;\n readonly dyeResolution: number;\n readonly densityDissipation: number;\n readonly velocityDissipation: number;\n readonly pressure: number;\n readonly pressureIterations: number;\n readonly curl: number;\n readonly splatRadius: number;\n readonly splatForce: number;\n readonly shading: boolean;\n readonly colorUpdateSpeed: number;\n /** Cycle splat colours through the rainbow; `false` uses `color`. */\n readonly rainbow: boolean;\n /** Fixed splat colour (hex) when `rainbow` is off. */\n readonly color: string;\n}\n\ninterface RGB {\n r: number;\n g: number;\n b: number;\n}\n\ninterface TexFormat {\n readonly internalFormat: number;\n readonly format: number;\n}\n\ninterface GlExt {\n readonly formatRGBA: TexFormat;\n readonly formatRG: TexFormat;\n readonly formatR: TexFormat;\n readonly halfFloatTexType: number;\n readonly supportLinearFiltering: boolean;\n}\n\ninterface FBO {\n readonly texture: WebGLTexture;\n readonly fbo: WebGLFramebuffer;\n readonly width: number;\n readonly height: number;\n readonly texelSizeX: number;\n readonly texelSizeY: number;\n attach(id: number): number;\n}\n\ninterface DoubleFBO {\n width: number;\n height: number;\n texelSizeX: number;\n texelSizeY: number;\n read: FBO;\n write: FBO;\n swap(): void;\n}\n\ninterface Pointer {\n texcoordX: number;\n texcoordY: number;\n prevTexcoordX: number;\n prevTexcoordY: number;\n deltaX: number;\n deltaY: number;\n moved: boolean;\n color: RGB;\n}\n\ntype GL = WebGLRenderingContext | WebGL2RenderingContext;\ntype Uniforms = Record<string, WebGLUniformLocation | null>;\n\nfunction createFluidSimulation(canvas: HTMLCanvasElement, config: WrFluidConfig): (() => void) | null {\n const ctx = getWebGLContext(canvas);\n if (!ctx) return null;\n const { gl, ext } = ctx;\n\n let dyeResolution = config.dyeResolution;\n let shading = config.shading;\n if (!ext.supportLinearFiltering) {\n dyeResolution = 256;\n shading = false;\n }\n\n let active = true;\n let rafId = 0;\n\n const pointer: Pointer = {\n texcoordX: 0,\n texcoordY: 0,\n prevTexcoordX: 0,\n prevTexcoordY: 0,\n deltaX: 0,\n deltaY: 0,\n moved: false,\n color: { r: 0, g: 0, b: 0 },\n };\n\n // Shader plumbing\n\n function compile(type: number, source: string, keywords?: readonly string[]): WebGLShader {\n const prefixed = keywords ? keywords.map(k => `#define ${k}\\n`).join('') + source : source;\n const shader = gl.createShader(type)!;\n gl.shaderSource(shader, prefixed);\n gl.compileShader(shader);\n if (!gl.getShaderParameter(shader, gl.COMPILE_STATUS)) {\n // eslint-disable-next-line no-console -- GPU shader failures are otherwise invisible\n console.error('wr-splash-cursor shader error:', gl.getShaderInfoLog(shader));\n }\n return shader;\n }\n\n function link(vertex: WebGLShader, fragment: WebGLShader): WebGLProgram {\n const program = gl.createProgram();\n gl.attachShader(program, vertex);\n gl.attachShader(program, fragment);\n gl.linkProgram(program);\n if (!gl.getProgramParameter(program, gl.LINK_STATUS)) {\n // eslint-disable-next-line no-console -- GPU link failures are otherwise invisible\n console.error('wr-splash-cursor program error:', gl.getProgramInfoLog(program));\n }\n return program;\n }\n\n function uniformsOf(program: WebGLProgram): Uniforms {\n const out: Uniforms = {};\n const count = gl.getProgramParameter(program, gl.ACTIVE_UNIFORMS) as number;\n for (let i = 0; i < count; i++) {\n const name = gl.getActiveUniform(program, i)!.name;\n out[name] = gl.getUniformLocation(program, name);\n }\n return out;\n }\n\n class ShaderProgram {\n readonly program: WebGLProgram;\n readonly uniforms: Uniforms;\n\n constructor(vertex: WebGLShader, fragment: WebGLShader) {\n this.program = link(vertex, fragment);\n this.uniforms = uniformsOf(this.program);\n }\n\n bind(): void {\n gl.useProgram(this.program);\n }\n }\n\n /** Display shader with `#define`-keyword program variants. */\n class DisplayMaterial {\n private readonly programs = new Map<number, WebGLProgram>();\n private activeProgram: WebGLProgram | null = null;\n uniforms: Uniforms = {};\n\n constructor(\n private readonly vertex: WebGLShader,\n private readonly fragmentSource: string\n ) {}\n\n setKeywords(keywords: readonly string[]): void {\n let hash = 0;\n for (const k of keywords) hash += hashCode(k);\n let program = this.programs.get(hash);\n if (!program) {\n program = link(this.vertex, compile(gl.FRAGMENT_SHADER, this.fragmentSource, keywords));\n this.programs.set(hash, program);\n }\n if (program === this.activeProgram) return;\n this.uniforms = uniformsOf(program);\n this.activeProgram = program;\n }\n\n bind(): void {\n gl.useProgram(this.activeProgram);\n }\n }\n\n // Shaders\n\n const baseVertexShader = compile(\n gl.VERTEX_SHADER,\n `\n precision highp float;\n attribute vec2 aPosition;\n varying vec2 vUv;\n varying vec2 vL;\n varying vec2 vR;\n varying vec2 vT;\n varying vec2 vB;\n uniform vec2 texelSize;\n\n void main () {\n vUv = aPosition * 0.5 + 0.5;\n vL = vUv - vec2(texelSize.x, 0.0);\n vR = vUv + vec2(texelSize.x, 0.0);\n vT = vUv + vec2(0.0, texelSize.y);\n vB = vUv - vec2(0.0, texelSize.y);\n gl_Position = vec4(aPosition, 0.0, 1.0);\n }\n `\n );\n\n const copyShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n uniform sampler2D uTexture;\n\n void main () {\n gl_FragColor = texture2D(uTexture, vUv);\n }\n `\n );\n\n const clearShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n uniform sampler2D uTexture;\n uniform float value;\n\n void main () {\n gl_FragColor = value * texture2D(uTexture, vUv);\n }\n `\n );\n\n const displayShaderSource = `\n precision highp float;\n precision highp sampler2D;\n varying vec2 vUv;\n varying vec2 vL;\n varying vec2 vR;\n varying vec2 vT;\n varying vec2 vB;\n uniform sampler2D uTexture;\n uniform vec2 texelSize;\n\n void main () {\n vec3 c = texture2D(uTexture, vUv).rgb;\n #ifdef SHADING\n vec3 lc = texture2D(uTexture, vL).rgb;\n vec3 rc = texture2D(uTexture, vR).rgb;\n vec3 tc = texture2D(uTexture, vT).rgb;\n vec3 bc = texture2D(uTexture, vB).rgb;\n\n float dx = length(rc) - length(lc);\n float dy = length(tc) - length(bc);\n\n vec3 n = normalize(vec3(dx, dy, length(texelSize)));\n vec3 l = vec3(0.0, 0.0, 1.0);\n\n float diffuse = clamp(dot(n, l) + 0.7, 0.7, 1.0);\n c *= diffuse;\n #endif\n\n float a = max(c.r, max(c.g, c.b));\n gl_FragColor = vec4(c, a);\n }\n `;\n\n const splatShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision highp float;\n precision highp sampler2D;\n varying vec2 vUv;\n uniform sampler2D uTarget;\n uniform float aspectRatio;\n uniform vec3 color;\n uniform vec2 point;\n uniform float radius;\n\n void main () {\n vec2 p = vUv - point.xy;\n p.x *= aspectRatio;\n vec3 splat = exp(-dot(p, p) / radius) * color;\n vec3 base = texture2D(uTarget, vUv).xyz;\n gl_FragColor = vec4(base + splat, 1.0);\n }\n `\n );\n\n const advectionShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision highp float;\n precision highp sampler2D;\n varying vec2 vUv;\n uniform sampler2D uVelocity;\n uniform sampler2D uSource;\n uniform vec2 texelSize;\n uniform vec2 dyeTexelSize;\n uniform float dt;\n uniform float dissipation;\n\n vec4 bilerp (sampler2D sam, vec2 uv, vec2 tsize) {\n vec2 st = uv / tsize - 0.5;\n vec2 iuv = floor(st);\n vec2 fuv = fract(st);\n\n vec4 a = texture2D(sam, (iuv + vec2(0.5, 0.5)) * tsize);\n vec4 b = texture2D(sam, (iuv + vec2(1.5, 0.5)) * tsize);\n vec4 c = texture2D(sam, (iuv + vec2(0.5, 1.5)) * tsize);\n vec4 d = texture2D(sam, (iuv + vec2(1.5, 1.5)) * tsize);\n\n return mix(mix(a, b, fuv.x), mix(c, d, fuv.x), fuv.y);\n }\n\n void main () {\n #ifdef MANUAL_FILTERING\n vec2 coord = vUv - dt * bilerp(uVelocity, vUv, texelSize).xy * texelSize;\n vec4 result = bilerp(uSource, coord, dyeTexelSize);\n #else\n vec2 coord = vUv - dt * texture2D(uVelocity, vUv).xy * texelSize;\n vec4 result = texture2D(uSource, coord);\n #endif\n float decay = 1.0 + dissipation * dt;\n gl_FragColor = result / decay;\n }\n `,\n ext.supportLinearFiltering ? undefined : ['MANUAL_FILTERING']\n );\n\n const divergenceShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n varying highp vec2 vL;\n varying highp vec2 vR;\n varying highp vec2 vT;\n varying highp vec2 vB;\n uniform sampler2D uVelocity;\n\n void main () {\n float L = texture2D(uVelocity, vL).x;\n float R = texture2D(uVelocity, vR).x;\n float T = texture2D(uVelocity, vT).y;\n float B = texture2D(uVelocity, vB).y;\n\n vec2 C = texture2D(uVelocity, vUv).xy;\n if (vL.x < 0.0) { L = -C.x; }\n if (vR.x > 1.0) { R = -C.x; }\n if (vT.y > 1.0) { T = -C.y; }\n if (vB.y < 0.0) { B = -C.y; }\n\n float div = 0.5 * (R - L + T - B);\n gl_FragColor = vec4(div, 0.0, 0.0, 1.0);\n }\n `\n );\n\n const curlShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n varying highp vec2 vL;\n varying highp vec2 vR;\n varying highp vec2 vT;\n varying highp vec2 vB;\n uniform sampler2D uVelocity;\n\n void main () {\n float L = texture2D(uVelocity, vL).y;\n float R = texture2D(uVelocity, vR).y;\n float T = texture2D(uVelocity, vT).x;\n float B = texture2D(uVelocity, vB).x;\n float vorticity = R - L - T + B;\n gl_FragColor = vec4(0.5 * vorticity, 0.0, 0.0, 1.0);\n }\n `\n );\n\n const vorticityShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision highp float;\n precision highp sampler2D;\n varying vec2 vUv;\n varying vec2 vL;\n varying vec2 vR;\n varying vec2 vT;\n varying vec2 vB;\n uniform sampler2D uVelocity;\n uniform sampler2D uCurl;\n uniform float curl;\n uniform float dt;\n\n void main () {\n float L = texture2D(uCurl, vL).x;\n float R = texture2D(uCurl, vR).x;\n float T = texture2D(uCurl, vT).x;\n float B = texture2D(uCurl, vB).x;\n float C = texture2D(uCurl, vUv).x;\n\n vec2 force = 0.5 * vec2(abs(T) - abs(B), abs(R) - abs(L));\n force /= length(force) + 0.0001;\n force *= curl * C;\n force.y *= -1.0;\n\n vec2 velocity = texture2D(uVelocity, vUv).xy;\n velocity += force * dt;\n velocity = min(max(velocity, -1000.0), 1000.0);\n gl_FragColor = vec4(velocity, 0.0, 1.0);\n }\n `\n );\n\n const pressureShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n varying highp vec2 vL;\n varying highp vec2 vR;\n varying highp vec2 vT;\n varying highp vec2 vB;\n uniform sampler2D uPressure;\n uniform sampler2D uDivergence;\n\n void main () {\n float L = texture2D(uPressure, vL).x;\n float R = texture2D(uPressure, vR).x;\n float T = texture2D(uPressure, vT).x;\n float B = texture2D(uPressure, vB).x;\n float C = texture2D(uPressure, vUv).x;\n float divergence = texture2D(uDivergence, vUv).x;\n float pressure = (L + R + B + T - divergence) * 0.25;\n gl_FragColor = vec4(pressure, 0.0, 0.0, 1.0);\n }\n `\n );\n\n const gradientSubtractShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n varying highp vec2 vL;\n varying highp vec2 vR;\n varying highp vec2 vT;\n varying highp vec2 vB;\n uniform sampler2D uPressure;\n uniform sampler2D uVelocity;\n\n void main () {\n float L = texture2D(uPressure, vL).x;\n float R = texture2D(uPressure, vR).x;\n float T = texture2D(uPressure, vT).x;\n float B = texture2D(uPressure, vB).x;\n vec2 velocity = texture2D(uVelocity, vUv).xy;\n velocity.xy -= vec2(R - L, T - B);\n gl_FragColor = vec4(velocity, 0.0, 1.0);\n }\n `\n );\n\n // Fullscreen blit\n\n gl.bindBuffer(gl.ARRAY_BUFFER, gl.createBuffer());\n gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([-1, -1, -1, 1, 1, 1, 1, -1]), gl.STATIC_DRAW);\n gl.bindBuffer(gl.ELEMENT_ARRAY_BUFFER, gl.createBuffer());\n gl.bufferData(gl.ELEMENT_ARRAY_BUFFER, new Uint16Array([0, 1, 2, 0, 2, 3]), gl.STATIC_DRAW);\n gl.vertexAttribPointer(0, 2, gl.FLOAT, false, 0, 0);\n gl.enableVertexAttribArray(0);\n\n function blit(target: FBO | null, clear = false): void {\n if (target === null) {\n gl.viewport(0, 0, gl.drawingBufferWidth, gl.drawingBufferHeight);\n gl.bindFramebuffer(gl.FRAMEBUFFER, null);\n } else {\n gl.viewport(0, 0, target.width, target.height);\n gl.bindFramebuffer(gl.FRAMEBUFFER, target.fbo);\n }\n if (clear) {\n gl.clearColor(0.0, 0.0, 0.0, 1.0);\n gl.clear(gl.COLOR_BUFFER_BIT);\n }\n gl.drawElements(gl.TRIANGLES, 6, gl.UNSIGNED_SHORT, 0);\n }\n\n // Framebuffers\n\n function createFBO(w: number, h: number, internalFormat: number, format: number, type: number, param: number): FBO {\n gl.activeTexture(gl.TEXTURE0);\n const texture = gl.createTexture();\n gl.bindTexture(gl.TEXTURE_2D, texture);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, param);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, param);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);\n gl.texImage2D(gl.TEXTURE_2D, 0, internalFormat, w, h, 0, format, type, null);\n\n const fbo = gl.createFramebuffer();\n gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);\n gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texture, 0);\n gl.viewport(0, 0, w, h);\n gl.clear(gl.COLOR_BUFFER_BIT);\n\n return {\n texture,\n fbo,\n width: w,\n height: h,\n texelSizeX: 1 / w,\n texelSizeY: 1 / h,\n attach(id: number): number {\n gl.activeTexture(gl.TEXTURE0 + id);\n gl.bindTexture(gl.TEXTURE_2D, texture);\n return id;\n },\n };\n }\n\n function createDoubleFBO(\n w: number,\n h: number,\n internalFormat: number,\n format: number,\n type: number,\n param: number\n ): DoubleFBO {\n let fbo1 = createFBO(w, h, internalFormat, format, type, param);\n let fbo2 = createFBO(w, h, internalFormat, format, type, param);\n return {\n width: w,\n height: h,\n texelSizeX: fbo1.texelSizeX,\n texelSizeY: fbo1.texelSizeY,\n get read() {\n return fbo1;\n },\n set read(value: FBO) {\n fbo1 = value;\n },\n get write() {\n return fbo2;\n },\n set write(value: FBO) {\n fbo2 = value;\n },\n swap(): void {\n const temp = fbo1;\n fbo1 = fbo2;\n fbo2 = temp;\n },\n };\n }\n\n function resizeFBO(\n target: FBO,\n w: number,\n h: number,\n internalFormat: number,\n format: number,\n type: number,\n param: number\n ): FBO {\n const newFBO = createFBO(w, h, internalFormat, format, type, param);\n copyProgram.bind();\n gl.uniform1i(copyProgram.uniforms['uTexture'], target.attach(0));\n blit(newFBO);\n return newFBO;\n }\n\n function resizeDoubleFBO(\n target: DoubleFBO,\n w: number,\n h: number,\n internalFormat: number,\n format: number,\n type: number,\n param: number\n ): DoubleFBO {\n if (target.width === w && target.height === h) return target;\n target.read = resizeFBO(target.read, w, h, internalFormat, format, type, param);\n target.write = createFBO(w, h, internalFormat, format, type, param);\n target.width = w;\n target.height = h;\n target.texelSizeX = 1 / w;\n target.texelSizeY = 1 / h;\n return target;\n }\n\n // Programs + state\n\n const copyProgram = new ShaderProgram(baseVertexShader, copyShader);\n const clearProgram = new ShaderProgram(baseVertexShader, clearShader);\n const splatProgram = new ShaderProgram(baseVertexShader, splatShader);\n const advectionProgram = new ShaderProgram(baseVertexShader, advectionShader);\n const divergenceProgram = new ShaderProgram(baseVertexShader, divergenceShader);\n const curlProgram = new ShaderProgram(baseVertexShader, curlShader);\n const vorticityProgram = new ShaderProgram(baseVertexShader, vorticityShader);\n const pressureProgram = new ShaderProgram(baseVertexShader, pressureShader);\n const gradientSubtractProgram = new ShaderProgram(baseVertexShader, gradientSubtractShader);\n const displayMaterial = new DisplayMaterial(baseVertexShader, displayShaderSource);\n\n let dye!: DoubleFBO;\n let velocity!: DoubleFBO;\n let divergence!: FBO;\n let curl!: FBO;\n let pressure!: DoubleFBO;\n\n function initFramebuffers(): void {\n const simRes = getResolution(config.simResolution);\n const dyeRes = getResolution(dyeResolution);\n const texType = ext.halfFloatTexType;\n const rgba = ext.formatRGBA;\n const rg = ext.formatRG;\n const r = ext.formatR;\n const filtering = ext.supportLinearFiltering ? gl.LINEAR : gl.NEAREST;\n gl.disable(gl.BLEND);\n\n dye = dye\n ? resizeDoubleFBO(dye, dyeRes.width, dyeRes.height, rgba.internalFormat, rgba.format, texType, filtering)\n : createDoubleFBO(dyeRes.width, dyeRes.height, rgba.internalFormat, rgba.format, texType, filtering);\n\n velocity = velocity\n ? resizeDoubleFBO(velocity, simRes.width, simRes.height, rg.internalFormat, rg.format, texType, filtering)\n : createDoubleFBO(simRes.width, simRes.height, rg.internalFormat, rg.format, texType, filtering);\n\n divergence = createFBO(simRes.width, simRes.height, r.internalFormat, r.format, texType, gl.NEAREST);\n curl = createFBO(simRes.width, simRes.height, r.internalFormat, r.format, texType, gl.NEAREST);\n pressure = createDoubleFBO(simRes.width, simRes.height, r.internalFormat, r.format, texType, gl.NEAREST);\n }\n\n displayMaterial.setKeywords(shading ? ['SHADING'] : []);\n initFramebuffers();\n let lastUpdateTime = Date.now();\n let colorUpdateTimer = 0;\n\n // Frame loop\n\n function updateFrame(): void {\n if (!active) return;\n const dt = calcDeltaTime();\n if (resizeCanvas()) initFramebuffers();\n updateColors(dt);\n applyInputs();\n step(dt);\n render();\n rafId = requestAnimationFrame(updateFrame);\n }\n\n function calcDeltaTime(): number {\n const now = Date.now();\n const dt = Math.min((now - lastUpdateTime) / 1000, 0.016666);\n lastUpdateTime = now;\n return dt;\n }\n\n function resizeCanvas(): boolean {\n const width = scaleByPixelRatio(canvas.clientWidth);\n const height = scaleByPixelRatio(canvas.clientHeight);\n if (canvas.width !== width || canvas.height !== height) {\n canvas.width = width;\n canvas.height = height;\n return true;\n }\n return false;\n }\n\n function updateColors(dt: number): void {\n colorUpdateTimer += dt * config.colorUpdateSpeed;\n if (colorUpdateTimer >= 1) {\n colorUpdateTimer = wrap(colorUpdateTimer, 0, 1);\n pointer.color = generateColor();\n }\n }\n\n function applyInputs(): void {\n if (pointer.moved) {\n pointer.moved = false;\n splatPointer();\n }\n }\n\n function step(dt: number): void {\n gl.disable(gl.BLEND);\n curlProgram.bind();\n gl.uniform2f(curlProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n gl.uniform1i(curlProgram.uniforms['uVelocity'], velocity.read.attach(0));\n blit(curl);\n\n vorticityProgram.bind();\n gl.uniform2f(vorticityProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n gl.uniform1i(vorticityProgram.uniforms['uVelocity'], velocity.read.attach(0));\n gl.uniform1i(vorticityProgram.uniforms['uCurl'], curl.attach(1));\n gl.uniform1f(vorticityProgram.uniforms['curl'], config.curl);\n gl.uniform1f(vorticityProgram.uniforms['dt'], dt);\n blit(velocity.write);\n velocity.swap();\n\n divergenceProgram.bind();\n gl.uniform2f(divergenceProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n gl.uniform1i(divergenceProgram.uniforms['uVelocity'], velocity.read.attach(0));\n blit(divergence);\n\n clearProgram.bind();\n gl.uniform1i(clearProgram.uniforms['uTexture'], pressure.read.attach(0));\n gl.uniform1f(clearProgram.uniforms['value'], config.pressure);\n blit(pressure.write);\n pressure.swap();\n\n pressureProgram.bind();\n gl.uniform2f(pressureProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n gl.uniform1i(pressureProgram.uniforms['uDivergence'], divergence.attach(0));\n for (let i = 0; i < config.pressureIterations; i++) {\n gl.uniform1i(pressureProgram.uniforms['uPressure'], pressure.read.attach(1));\n blit(pressure.write);\n pressure.swap();\n }\n\n gradientSubtractProgram.bind();\n gl.uniform2f(gradientSubtractProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n gl.uniform1i(gradientSubtractProgram.uniforms['uPressure'], pressure.read.attach(0));\n gl.uniform1i(gradientSubtractProgram.uniforms['uVelocity'], velocity.read.attach(1));\n blit(velocity.write);\n velocity.swap();\n\n advectionProgram.bind();\n gl.uniform2f(advectionProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n if (!ext.supportLinearFiltering) {\n gl.uniform2f(advectionProgram.uniforms['dyeTexelSize'], velocity.texelSizeX, velocity.texelSizeY);\n }\n const velocityId = velocity.read.attach(0);\n gl.uniform1i(advectionProgram.uniforms['uVelocity'], velocityId);\n gl.uniform1i(advectionProgram.uniforms['uSource'], velocityId);\n gl.uniform1f(advectionProgram.uniforms['dt'], dt);\n gl.uniform1f(advectionProgram.uniforms['dissipation'], config.velocityDissipation);\n blit(velocity.write);\n velocity.swap();\n\n if (!ext.supportLinearFiltering) {\n gl.uniform2f(advectionProgram.uniforms['dyeTexelSize'], dye.texelSizeX, dye.texelSizeY);\n }\n gl.uniform1i(advectionProgram.uniforms['uVelocity'], velocity.read.attach(0));\n gl.uniform1i(advectionProgram.uniforms['uSource'], dye.read.attach(1));\n gl.uniform1f(advectionProgram.uniforms['dissipation'], config.densityDissipation);\n blit(dye.write);\n dye.swap();\n }\n\n function render(): void {\n gl.blendFunc(gl.ONE, gl.ONE_MINUS_SRC_ALPHA);\n gl.enable(gl.BLEND);\n displayMaterial.bind();\n if (shading) {\n gl.uniform2f(displayMaterial.uniforms['texelSize'], 1 / gl.drawingBufferWidth, 1 / gl.drawingBufferHeight);\n }\n gl.uniform1i(displayMaterial.uniforms['uTexture'], dye.read.attach(0));\n blit(null);\n }\n\n // Splats\n\n function splatPointer(): void {\n const dx = pointer.deltaX * config.splatForce;\n const dy = pointer.deltaY * config.splatForce;\n splat(pointer.texcoordX, pointer.texcoordY, dx, dy, pointer.color);\n }\n\n function clickSplat(): void {\n const color = generateColor();\n color.r *= 10;\n color.g *= 10;\n color.b *= 10;\n const dx = 10 * (Math.random() - 0.5);\n const dy = 30 * (Math.random() - 0.5);\n splat(pointer.texcoordX, pointer.texcoordY, dx, dy, color);\n }\n\n function splat(x: number, y: number, dx: number, dy: number, color: RGB): void {\n splatProgram.bind();\n gl.uniform1i(splatProgram.uniforms['uTarget'], velocity.read.attach(0));\n gl.uniform1f(splatProgram.uniforms['aspectRatio'], canvas.width / canvas.height);\n gl.uniform2f(splatProgram.uniforms['point'], x, y);\n gl.uniform3f(splatProgram.uniforms['color'], dx, dy, 0);\n gl.uniform1f(splatProgram.uniforms['radius'], correctRadius(config.splatRadius / 100));\n blit(velocity.write);\n velocity.swap();\n\n gl.uniform1i(splatProgram.uniforms['uTarget'], dye.read.attach(0));\n gl.uniform3f(splatProgram.uniforms['color'], color.r, color.g, color.b);\n blit(dye.write);\n dye.swap();\n }\n\n function correctRadius(radius: number): number {\n const aspectRatio = canvas.width / canvas.height;\n return aspectRatio > 1 ? radius * aspectRatio : radius;\n }\n\n // Pointer\n\n function pointerDown(posX: number, posY: number): void {\n pointer.moved = false;\n pointer.texcoordX = posX / canvas.width;\n pointer.texcoordY = 1 - posY / canvas.height;\n pointer.prevTexcoordX = pointer.texcoordX;\n pointer.prevTexcoordY = pointer.texcoordY;\n pointer.deltaX = 0;\n pointer.deltaY = 0;\n pointer.color = generateColor();\n }\n\n function pointerMove(posX: number, posY: number, color: RGB): void {\n pointer.prevTexcoordX = pointer.texcoordX;\n pointer.prevTexcoordY = pointer.texcoordY;\n pointer.texcoordX = posX / canvas.width;\n pointer.texcoordY = 1 - posY / canvas.height;\n pointer.deltaX = correctDeltaX(pointer.texcoordX - pointer.prevTexcoordX);\n pointer.deltaY = correctDeltaY(pointer.texcoordY - pointer.prevTexcoordY);\n pointer.moved = Math.abs(pointer.deltaX) > 0 || Math.abs(pointer.deltaY) > 0;\n pointer.color = color;\n }\n\n function correctDeltaX(delta: number): number {\n const aspectRatio = canvas.width / canvas.height;\n return aspectRatio < 1 ? delta * aspectRatio : delta;\n }\n\n function correctDeltaY(delta: number): number {\n const aspectRatio = canvas.width / canvas.height;\n return aspectRatio > 1 ? delta / aspectRatio : delta;\n }\n\n // Colours\n\n function hexToRGB(hex: string): RGB {\n let val = hex.replace('#', '');\n if (val.length === 3) val = val[0] + val[0] + val[1] + val[1] + val[2] + val[2];\n return {\n r: (Number.parseInt(val.slice(0, 2), 16) / 255) * 0.15,\n g: (Number.parseInt(val.slice(2, 4), 16) / 255) * 0.15,\n b: (Number.parseInt(val.slice(4, 6), 16) / 255) * 0.15,\n };\n }\n\n function generateColor(): RGB {\n if (!config.rainbow) return hexToRGB(config.color);\n const c = hsvToRgb(Math.random(), 1, 1);\n c.r *= 0.15;\n c.g *= 0.15;\n c.b *= 0.15;\n return c;\n }\n\n function hsvToRgb(h: number, s: number, v: number): RGB {\n const i = Math.floor(h * 6);\n const f = h * 6 - i;\n const p = v * (1 - s);\n const q = v * (1 - f * s);\n const t = v * (1 - (1 - f) * s);\n switch (i % 6) {\n case 0:\n return { r: v, g: t, b: p };\n case 1:\n return { r: q, g: v, b: p };\n case 2:\n return { r: p, g: v, b: t };\n case 3:\n return { r: p, g: q, b: v };\n case 4:\n return { r: t, g: p, b: v };\n default:\n return { r: v, g: p, b: q };\n }\n }\n\n function wrap(value: number, min: number, max: number): number {\n const range = max - min;\n if (range === 0) return min;\n return ((value - min) % range) + min;\n }\n\n function getResolution(resolution: number): { width: number; height: number } {\n let aspectRatio = gl.drawingBufferWidth / gl.drawingBufferHeight;\n if (aspectRatio < 1) aspectRatio = 1 / aspectRatio;\n const min = Math.round(resolution);\n const max = Math.round(resolution * aspectRatio);\n return gl.drawingBufferWidth > gl.drawingBufferHeight ? { width: max, height: min } : { width: min, height: max };\n }\n\n function scaleByPixelRatio(input: number): number {\n return Math.floor(input * (window.devicePixelRatio || 1));\n }\n\n function hashCode(s: string): number {\n let hash = 0;\n for (let i = 0; i < s.length; i++) {\n hash = (hash << 5) - hash + s.charCodeAt(i);\n hash |= 0;\n }\n return hash;\n }\n\n // Events + boot\n\n let firstMoveHandled = false;\n\n // Coordinates are taken relative to the canvas box: identical to the\n // raw client position for the fullscreen overlay, and it makes a\n // contained canvas track the pointer correctly too.\n const toLocal = (clientX: number, clientY: number): { x: number; y: number } => {\n const rect = canvas.getBoundingClientRect();\n return { x: scaleByPixelRatio(clientX - rect.left), y: scaleByPixelRatio(clientY - rect.top) };\n };\n\n const onMouseDown = (e: MouseEvent): void => {\n const pos = toLocal(e.clientX, e.clientY);\n pointerDown(pos.x, pos.y);\n clickSplat();\n };\n\n const onMouseMove = (e: MouseEvent): void => {\n const pos = toLocal(e.clientX, e.clientY);\n const color = firstMoveHandled ? pointer.color : generateColor();\n firstMoveHandled = true;\n pointerMove(pos.x, pos.y, color);\n };\n\n const onTouchStart = (e: TouchEvent): void => {\n const t = e.targetTouches[0];\n if (!t) return;\n const pos = toLocal(t.clientX, t.clientY);\n pointerDown(pos.x, pos.y);\n };\n\n const onTouchMove = (e: TouchEvent): void => {\n const t = e.targetTouches[0];\n if (!t) return;\n const pos = toLocal(t.clientX, t.clientY);\n pointerMove(pos.x, pos.y, pointer.color);\n };\n\n window.addEventListener('mousedown', onMouseDown);\n window.addEventListener('mousemove', onMouseMove);\n window.addEventListener('touchstart', onTouchStart, { passive: true });\n window.addEventListener('touchmove', onTouchMove, { passive: true });\n\n updateFrame();\n\n return () => {\n active = false;\n cancelAnimationFrame(rafId);\n window.removeEventListener('mousedown', onMouseDown);\n window.removeEventListener('mousemove', onMouseMove);\n window.removeEventListener('touchstart', onTouchStart);\n window.removeEventListener('touchmove', onTouchMove);\n // The context is NOT lost here on purpose — input changes reboot the\n // sim on the same canvas, and a lost context can't be re-acquired.\n };\n}\n\n// WebGL context bootstrap\n\nfunction getWebGLContext(canvas: HTMLCanvasElement): { gl: GL; ext: GlExt } | null {\n const params: WebGLContextAttributes = {\n alpha: true,\n depth: false,\n stencil: false,\n antialias: false,\n preserveDrawingBuffer: false,\n };\n\n const gl2 = canvas.getContext('webgl2', params);\n const gl = gl2 ?? canvas.getContext('webgl', params);\n if (!gl) return null;\n const isWebGL2 = !!gl2;\n\n let halfFloat: OES_texture_half_float | null = null;\n let supportLinearFiltering: boolean;\n if (isWebGL2) {\n gl.getExtension('EXT_color_buffer_float');\n supportLinearFiltering = !!gl.getExtension('OES_texture_float_linear');\n } else {\n halfFloat = gl.getExtension('OES_texture_half_float');\n supportLinearFiltering = !!gl.getExtension('OES_texture_half_float_linear');\n }\n gl.clearColor(0, 0, 0, 1);\n\n const halfFloatTexType = isWebGL2\n ? (gl as WebGL2RenderingContext).HALF_FLOAT\n : (halfFloat?.HALF_FLOAT_OES ?? gl.UNSIGNED_BYTE);\n\n let formatRGBA: TexFormat | null;\n let formatRG: TexFormat | null;\n let formatR: TexFormat | null;\n if (isWebGL2) {\n const g2 = gl as WebGL2RenderingContext;\n formatRGBA = getSupportedFormat(g2, g2.RGBA16F, g2.RGBA, halfFloatTexType);\n formatRG = getSupportedFormat(g2, g2.RG16F, g2.RG, halfFloatTexType);\n formatR = getSupportedFormat(g2, g2.R16F, g2.RED, halfFloatTexType);\n } else {\n formatRGBA = getSupportedFormat(gl, gl.RGBA, gl.RGBA, halfFloatTexType);\n formatRG = formatRGBA;\n formatR = formatRGBA;\n }\n if (!formatRGBA || !formatRG || !formatR) return null;\n\n return { gl, ext: { formatRGBA, formatRG, formatR, halfFloatTexType, supportLinearFiltering } };\n}\n\nfunction getSupportedFormat(gl: GL, internalFormat: number, format: number, type: number): TexFormat | null {\n if (!supportRenderTextureFormat(gl, internalFormat, format, type)) {\n const g2 = gl as WebGL2RenderingContext;\n switch (internalFormat) {\n case g2.R16F:\n return getSupportedFormat(gl, g2.RG16F, g2.RG, type);\n case g2.RG16F:\n return getSupportedFormat(gl, g2.RGBA16F, g2.RGBA, type);\n default:\n return null;\n }\n }\n return { internalFormat, format };\n}\n\nfunction supportRenderTextureFormat(gl: GL, internalFormat: number, format: number, type: number): boolean {\n const texture = gl.createTexture();\n gl.bindTexture(gl.TEXTURE_2D, texture);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);\n gl.texImage2D(gl.TEXTURE_2D, 0, internalFormat, 4, 4, 0, format, type, null);\n const fbo = gl.createFramebuffer();\n gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);\n gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texture, 0);\n return gl.checkFramebufferStatus(gl.FRAMEBUFFER) === gl.FRAMEBUFFER_COMPLETE;\n}\n\nexport { createFluidSimulation };\nexport type { WrFluidConfig };\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n *\n * Angular adaptation of the SplashCursor effect by David Haz / reactbits.dev.\n * Original: https://www.reactbits.dev/animations/splash-cursor\n */\n\nimport { coerceBooleanProperty } from '@angular/cdk/coercion';\nimport { isPlatformBrowser } from '@angular/common';\nimport type { ElementRef } from '@angular/core';\nimport { Component, NgZone, PLATFORM_ID, ViewEncapsulation, effect, inject, input, viewChild } from '@angular/core';\n\nimport { WrPlatform } from 'ngwr/platform';\nimport { numAttr } from 'ngwr/utils';\n\nimport { createFluidSimulation } from './fluid';\n\n/**\n * Splash cursor — a WebGL fluid simulation that splashes colourful dye\n * wherever the pointer moves or clicks. Renders as a fixed, full-viewport,\n * click-through overlay; mount it once on a page (it follows the pointer\n * everywhere) and it tears down with the component.\n *\n * Renders nothing under `prefers-reduced-motion` or when WebGL is\n * unavailable.\n *\n * @example\n * ```html\n * <wr-splash-cursor />\n * <wr-splash-cursor [rainbow]=\"false\" color=\"#5227ff\" />\n * ```\n *\n * @see https://ngwr.dev/animations/splash-cursor\n */\n@Component({\n selector: 'wr-splash-cursor',\n template: '<canvas #canvas class=\"wr-splash-cursor__canvas\" aria-hidden=\"true\"></canvas>',\n styleUrl: './splash-cursor.scss',\n encapsulation: ViewEncapsulation.None,\n host: {\n class: 'wr-splash-cursor',\n '[class.wr-splash-cursor--contained]': '!fullscreen()',\n },\n})\nexport class WrSplashCursor {\n /**\n * `true` overlays the whole viewport (reactbits behaviour); `false`\n * fills the nearest positioned ancestor instead — handy for demo boxes,\n * and the dye collides with the box walls. @default true\n */\n readonly fullscreen = input(true, { transform: coerceBooleanProperty });\n\n /** Velocity / pressure grid resolution. @default 128 */\n readonly simResolution = input(128, { transform: numAttr(128) });\n\n /** Dye texture resolution — the visible detail. @default 1440 */\n readonly dyeResolution = input(1440, { transform: numAttr(1440) });\n\n /** How fast the dye fades, higher = shorter trails. @default 3.5 */\n readonly densityDissipation = input(3.5, { transform: numAttr(3.5) });\n\n /** How fast motion settles. @default 2 */\n readonly velocityDissipation = input(2, { transform: numAttr(2) });\n\n /** Pressure retained between frames, 0..1. @default 0.1 */\n readonly pressure = input(0.1, { transform: numAttr(0.1) });\n\n /** Jacobi iterations for the pressure solve. @default 20 */\n readonly pressureIterations = input(20, { transform: numAttr(20) });\n\n /** Vorticity confinement — swirliness. @default 3 */\n readonly curl = input(3, { transform: numAttr(3) });\n\n /** Splat size. @default 0.2 */\n readonly splatRadius = input(0.2, { transform: numAttr(0.2) });\n\n /** Velocity a pointer move injects. @default 6000 */\n readonly splatForce = input(6000, { transform: numAttr(6000) });\n\n /** Pseudo-3D shading on the dye. @default true */\n readonly shading = input(true, { transform: coerceBooleanProperty });\n\n /** How fast the splat colour cycles. @default 10 */\n readonly colorUpdateSpeed = input(10, { transform: numAttr(10) });\n\n /** Cycle splat colours through the rainbow. @default true */\n readonly rainbow = input(true, { transform: coerceBooleanProperty });\n\n /** Fixed splat colour when `rainbow` is off. @default '#ff0000' */\n readonly color = input('#ff0000');\n\n private readonly canvasRef = viewChild<ElementRef<HTMLCanvasElement>>('canvas');\n\n private readonly zone = inject(NgZone);\n private readonly platform = inject(WrPlatform);\n private readonly isBrowser = isPlatformBrowser(inject(PLATFORM_ID));\n\n constructor() {\n if (!this.isBrowser) return;\n\n // (Re)boot whenever the canvas appears, any input changes, or the OS\n // reduced-motion preference flips. `onCleanup` tears the old sim down.\n effect(onCleanup => {\n const canvas = this.canvasRef()?.nativeElement;\n const config = {\n simResolution: this.simResolution(),\n dyeResolution: this.dyeResolution(),\n densityDissipation: this.densityDissipation(),\n velocityDissipation: this.velocityDissipation(),\n pressure: this.pressure(),\n pressureIterations: this.pressureIterations(),\n curl: this.curl(),\n splatRadius: this.splatRadius(),\n splatForce: this.splatForce(),\n shading: this.shading(),\n colorUpdateSpeed: this.colorUpdateSpeed(),\n rainbow: this.rainbow(),\n color: this.color(),\n };\n if (!canvas || this.platform.prefersReducedMotion()) return;\n const teardown = this.zone.runOutsideAngular(() => createFluidSimulation(canvas, config));\n if (teardown) onCleanup(teardown);\n });\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;AAAA;;;;;;;;;;;;AAYG;AA2EH,SAAS,qBAAqB,CAAC,MAAyB,EAAE,MAAqB,EAAA;AAC7E,IAAA,MAAM,GAAG,GAAG,eAAe,CAAC,MAAM,CAAC;AACnC,IAAA,IAAI,CAAC,GAAG;AAAE,QAAA,OAAO,IAAI;AACrB,IAAA,MAAM,EAAE,EAAE,EAAE,GAAG,EAAE,GAAG,GAAG;AAEvB,IAAA,IAAI,aAAa,GAAG,MAAM,CAAC,aAAa;AACxC,IAAA,IAAI,OAAO,GAAG,MAAM,CAAC,OAAO;AAC5B,IAAA,IAAI,CAAC,GA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nC,QAAA,CAAC,CAAC;IACJ;uGA/EW,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAd,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,cAAc,4tEARf,+EAA+E,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,gTAAA,CAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA;;2FAQ9E,cAAc,EAAA,UAAA,EAAA,CAAA;kBAV1B,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,kBAAkB,YAClB,+EAA+E,EAAA,aAAA,EAE1E,iBAAiB,CAAC,IAAI,EAAA,IAAA,EAC/B;AACJ,wBAAA,KAAK,EAAE,kBAAkB;AACzB,wBAAA,qCAAqC,EAAE,eAAe;AACvD,qBAAA,EAAA,MAAA,EAAA,CAAA,gTAAA,CAAA,EAAA;+/CAiDqE,QAAQ,EAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;AC9FhF;;AAEG;;;;"}
1
+ {"version":3,"file":"ngwr-splash-cursor.mjs","sources":["../../../projects/lib/splash-cursor/fluid.ts","../../../projects/lib/splash-cursor/splash-cursor.ts","../../../projects/lib/splash-cursor/ngwr-splash-cursor.ts"],"sourcesContent":["/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n *\n * WebGL fluid simulation behind `<wr-splash-cursor>`. Port of the engine\n * used by reactbits.dev's SplashCursor (itself based on Pavel Dobryakov's\n * WebGL-Fluid-Simulation, MIT).\n *\n * Framework-free on purpose: `createFluidSimulation(canvas, config)` boots\n * the sim and returns a teardown, or `null` when WebGL isn't available.\n */\n\n/* eslint-disable no-bitwise -- GL bitmasks + string hashing are inherently bitwise */\n\ninterface WrFluidConfig {\n readonly simResolution: number;\n readonly dyeResolution: number;\n readonly densityDissipation: number;\n readonly velocityDissipation: number;\n readonly pressure: number;\n readonly pressureIterations: number;\n readonly curl: number;\n readonly splatRadius: number;\n readonly splatForce: number;\n readonly shading: boolean;\n readonly colorUpdateSpeed: number;\n /** Cycle splat colours through the rainbow; `false` uses `color`. */\n readonly rainbow: boolean;\n /** Fixed splat colour (hex) when `rainbow` is off. */\n readonly color: string;\n}\n\ninterface RGB {\n r: number;\n g: number;\n b: number;\n}\n\ninterface TexFormat {\n readonly internalFormat: number;\n readonly format: number;\n}\n\ninterface GlExt {\n readonly formatRGBA: TexFormat;\n readonly formatRG: TexFormat;\n readonly formatR: TexFormat;\n readonly halfFloatTexType: number;\n readonly supportLinearFiltering: boolean;\n}\n\ninterface FBO {\n readonly texture: WebGLTexture;\n readonly fbo: WebGLFramebuffer;\n readonly width: number;\n readonly height: number;\n readonly texelSizeX: number;\n readonly texelSizeY: number;\n attach(id: number): number;\n}\n\ninterface DoubleFBO {\n width: number;\n height: number;\n texelSizeX: number;\n texelSizeY: number;\n read: FBO;\n write: FBO;\n swap(): void;\n}\n\ninterface Pointer {\n texcoordX: number;\n texcoordY: number;\n prevTexcoordX: number;\n prevTexcoordY: number;\n deltaX: number;\n deltaY: number;\n moved: boolean;\n color: RGB;\n}\n\ntype GL = WebGLRenderingContext | WebGL2RenderingContext;\ntype Uniforms = Record<string, WebGLUniformLocation | null>;\n\nfunction createFluidSimulation(canvas: HTMLCanvasElement, config: WrFluidConfig): (() => void) | null {\n const ctx = getWebGLContext(canvas);\n if (!ctx) return null;\n const { gl, ext } = ctx;\n\n let dyeResolution = config.dyeResolution;\n let shading = config.shading;\n if (!ext.supportLinearFiltering) {\n dyeResolution = 256;\n shading = false;\n }\n\n let active = true;\n let rafId = 0;\n\n const pointer: Pointer = {\n texcoordX: 0,\n texcoordY: 0,\n prevTexcoordX: 0,\n prevTexcoordY: 0,\n deltaX: 0,\n deltaY: 0,\n moved: false,\n color: { r: 0, g: 0, b: 0 },\n };\n\n // Shader plumbing\n\n function compile(type: number, source: string, keywords?: readonly string[]): WebGLShader {\n const prefixed = keywords ? keywords.map(k => `#define ${k}\\n`).join('') + source : source;\n const shader = gl.createShader(type)!;\n gl.shaderSource(shader, prefixed);\n gl.compileShader(shader);\n if (!gl.getShaderParameter(shader, gl.COMPILE_STATUS)) {\n // eslint-disable-next-line no-console -- GPU shader failures are otherwise invisible\n console.error('wr-splash-cursor shader error:', gl.getShaderInfoLog(shader));\n }\n return shader;\n }\n\n function link(vertex: WebGLShader, fragment: WebGLShader): WebGLProgram {\n const program = gl.createProgram();\n gl.attachShader(program, vertex);\n gl.attachShader(program, fragment);\n gl.linkProgram(program);\n if (!gl.getProgramParameter(program, gl.LINK_STATUS)) {\n // eslint-disable-next-line no-console -- GPU link failures are otherwise invisible\n console.error('wr-splash-cursor program error:', gl.getProgramInfoLog(program));\n }\n return program;\n }\n\n function uniformsOf(program: WebGLProgram): Uniforms {\n const out: Uniforms = {};\n const count = gl.getProgramParameter(program, gl.ACTIVE_UNIFORMS) as number;\n for (let i = 0; i < count; i++) {\n const name = gl.getActiveUniform(program, i)!.name;\n out[name] = gl.getUniformLocation(program, name);\n }\n return out;\n }\n\n class ShaderProgram {\n readonly program: WebGLProgram;\n readonly uniforms: Uniforms;\n\n constructor(vertex: WebGLShader, fragment: WebGLShader) {\n this.program = link(vertex, fragment);\n this.uniforms = uniformsOf(this.program);\n }\n\n bind(): void {\n gl.useProgram(this.program);\n }\n }\n\n /** Display shader with `#define`-keyword program variants. */\n class DisplayMaterial {\n private readonly programs = new Map<number, WebGLProgram>();\n private activeProgram: WebGLProgram | null = null;\n uniforms: Uniforms = {};\n\n constructor(\n private readonly vertex: WebGLShader,\n private readonly fragmentSource: string\n ) {}\n\n setKeywords(keywords: readonly string[]): void {\n let hash = 0;\n for (const k of keywords) hash += hashCode(k);\n let program = this.programs.get(hash);\n if (!program) {\n program = link(this.vertex, compile(gl.FRAGMENT_SHADER, this.fragmentSource, keywords));\n this.programs.set(hash, program);\n }\n if (program === this.activeProgram) return;\n this.uniforms = uniformsOf(program);\n this.activeProgram = program;\n }\n\n bind(): void {\n gl.useProgram(this.activeProgram);\n }\n }\n\n // Shaders\n\n const baseVertexShader = compile(\n gl.VERTEX_SHADER,\n `\n precision highp float;\n attribute vec2 aPosition;\n varying vec2 vUv;\n varying vec2 vL;\n varying vec2 vR;\n varying vec2 vT;\n varying vec2 vB;\n uniform vec2 texelSize;\n\n void main () {\n vUv = aPosition * 0.5 + 0.5;\n vL = vUv - vec2(texelSize.x, 0.0);\n vR = vUv + vec2(texelSize.x, 0.0);\n vT = vUv + vec2(0.0, texelSize.y);\n vB = vUv - vec2(0.0, texelSize.y);\n gl_Position = vec4(aPosition, 0.0, 1.0);\n }\n `\n );\n\n const copyShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n uniform sampler2D uTexture;\n\n void main () {\n gl_FragColor = texture2D(uTexture, vUv);\n }\n `\n );\n\n const clearShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n uniform sampler2D uTexture;\n uniform float value;\n\n void main () {\n gl_FragColor = value * texture2D(uTexture, vUv);\n }\n `\n );\n\n const displayShaderSource = `\n precision highp float;\n precision highp sampler2D;\n varying vec2 vUv;\n varying vec2 vL;\n varying vec2 vR;\n varying vec2 vT;\n varying vec2 vB;\n uniform sampler2D uTexture;\n uniform vec2 texelSize;\n\n void main () {\n vec3 c = texture2D(uTexture, vUv).rgb;\n #ifdef SHADING\n vec3 lc = texture2D(uTexture, vL).rgb;\n vec3 rc = texture2D(uTexture, vR).rgb;\n vec3 tc = texture2D(uTexture, vT).rgb;\n vec3 bc = texture2D(uTexture, vB).rgb;\n\n float dx = length(rc) - length(lc);\n float dy = length(tc) - length(bc);\n\n vec3 n = normalize(vec3(dx, dy, length(texelSize)));\n vec3 l = vec3(0.0, 0.0, 1.0);\n\n float diffuse = clamp(dot(n, l) + 0.7, 0.7, 1.0);\n c *= diffuse;\n #endif\n\n float a = max(c.r, max(c.g, c.b));\n gl_FragColor = vec4(c, a);\n }\n `;\n\n const splatShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision highp float;\n precision highp sampler2D;\n varying vec2 vUv;\n uniform sampler2D uTarget;\n uniform float aspectRatio;\n uniform vec3 color;\n uniform vec2 point;\n uniform float radius;\n\n void main () {\n vec2 p = vUv - point.xy;\n p.x *= aspectRatio;\n vec3 splat = exp(-dot(p, p) / radius) * color;\n vec3 base = texture2D(uTarget, vUv).xyz;\n gl_FragColor = vec4(base + splat, 1.0);\n }\n `\n );\n\n const advectionShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision highp float;\n precision highp sampler2D;\n varying vec2 vUv;\n uniform sampler2D uVelocity;\n uniform sampler2D uSource;\n uniform vec2 texelSize;\n uniform vec2 dyeTexelSize;\n uniform float dt;\n uniform float dissipation;\n\n vec4 bilerp (sampler2D sam, vec2 uv, vec2 tsize) {\n vec2 st = uv / tsize - 0.5;\n vec2 iuv = floor(st);\n vec2 fuv = fract(st);\n\n vec4 a = texture2D(sam, (iuv + vec2(0.5, 0.5)) * tsize);\n vec4 b = texture2D(sam, (iuv + vec2(1.5, 0.5)) * tsize);\n vec4 c = texture2D(sam, (iuv + vec2(0.5, 1.5)) * tsize);\n vec4 d = texture2D(sam, (iuv + vec2(1.5, 1.5)) * tsize);\n\n return mix(mix(a, b, fuv.x), mix(c, d, fuv.x), fuv.y);\n }\n\n void main () {\n #ifdef MANUAL_FILTERING\n vec2 coord = vUv - dt * bilerp(uVelocity, vUv, texelSize).xy * texelSize;\n vec4 result = bilerp(uSource, coord, dyeTexelSize);\n #else\n vec2 coord = vUv - dt * texture2D(uVelocity, vUv).xy * texelSize;\n vec4 result = texture2D(uSource, coord);\n #endif\n float decay = 1.0 + dissipation * dt;\n gl_FragColor = result / decay;\n }\n `,\n ext.supportLinearFiltering ? undefined : ['MANUAL_FILTERING']\n );\n\n const divergenceShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n varying highp vec2 vL;\n varying highp vec2 vR;\n varying highp vec2 vT;\n varying highp vec2 vB;\n uniform sampler2D uVelocity;\n\n void main () {\n float L = texture2D(uVelocity, vL).x;\n float R = texture2D(uVelocity, vR).x;\n float T = texture2D(uVelocity, vT).y;\n float B = texture2D(uVelocity, vB).y;\n\n vec2 C = texture2D(uVelocity, vUv).xy;\n if (vL.x < 0.0) { L = -C.x; }\n if (vR.x > 1.0) { R = -C.x; }\n if (vT.y > 1.0) { T = -C.y; }\n if (vB.y < 0.0) { B = -C.y; }\n\n float div = 0.5 * (R - L + T - B);\n gl_FragColor = vec4(div, 0.0, 0.0, 1.0);\n }\n `\n );\n\n const curlShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n varying highp vec2 vL;\n varying highp vec2 vR;\n varying highp vec2 vT;\n varying highp vec2 vB;\n uniform sampler2D uVelocity;\n\n void main () {\n float L = texture2D(uVelocity, vL).y;\n float R = texture2D(uVelocity, vR).y;\n float T = texture2D(uVelocity, vT).x;\n float B = texture2D(uVelocity, vB).x;\n float vorticity = R - L - T + B;\n gl_FragColor = vec4(0.5 * vorticity, 0.0, 0.0, 1.0);\n }\n `\n );\n\n const vorticityShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision highp float;\n precision highp sampler2D;\n varying vec2 vUv;\n varying vec2 vL;\n varying vec2 vR;\n varying vec2 vT;\n varying vec2 vB;\n uniform sampler2D uVelocity;\n uniform sampler2D uCurl;\n uniform float curl;\n uniform float dt;\n\n void main () {\n float L = texture2D(uCurl, vL).x;\n float R = texture2D(uCurl, vR).x;\n float T = texture2D(uCurl, vT).x;\n float B = texture2D(uCurl, vB).x;\n float C = texture2D(uCurl, vUv).x;\n\n vec2 force = 0.5 * vec2(abs(T) - abs(B), abs(R) - abs(L));\n force /= length(force) + 0.0001;\n force *= curl * C;\n force.y *= -1.0;\n\n vec2 velocity = texture2D(uVelocity, vUv).xy;\n velocity += force * dt;\n velocity = min(max(velocity, -1000.0), 1000.0);\n gl_FragColor = vec4(velocity, 0.0, 1.0);\n }\n `\n );\n\n const pressureShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n varying highp vec2 vL;\n varying highp vec2 vR;\n varying highp vec2 vT;\n varying highp vec2 vB;\n uniform sampler2D uPressure;\n uniform sampler2D uDivergence;\n\n void main () {\n float L = texture2D(uPressure, vL).x;\n float R = texture2D(uPressure, vR).x;\n float T = texture2D(uPressure, vT).x;\n float B = texture2D(uPressure, vB).x;\n float C = texture2D(uPressure, vUv).x;\n float divergence = texture2D(uDivergence, vUv).x;\n float pressure = (L + R + B + T - divergence) * 0.25;\n gl_FragColor = vec4(pressure, 0.0, 0.0, 1.0);\n }\n `\n );\n\n const gradientSubtractShader = compile(\n gl.FRAGMENT_SHADER,\n `\n precision mediump float;\n precision mediump sampler2D;\n varying highp vec2 vUv;\n varying highp vec2 vL;\n varying highp vec2 vR;\n varying highp vec2 vT;\n varying highp vec2 vB;\n uniform sampler2D uPressure;\n uniform sampler2D uVelocity;\n\n void main () {\n float L = texture2D(uPressure, vL).x;\n float R = texture2D(uPressure, vR).x;\n float T = texture2D(uPressure, vT).x;\n float B = texture2D(uPressure, vB).x;\n vec2 velocity = texture2D(uVelocity, vUv).xy;\n velocity.xy -= vec2(R - L, T - B);\n gl_FragColor = vec4(velocity, 0.0, 1.0);\n }\n `\n );\n\n // Fullscreen blit\n\n gl.bindBuffer(gl.ARRAY_BUFFER, gl.createBuffer());\n gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([-1, -1, -1, 1, 1, 1, 1, -1]), gl.STATIC_DRAW);\n gl.bindBuffer(gl.ELEMENT_ARRAY_BUFFER, gl.createBuffer());\n gl.bufferData(gl.ELEMENT_ARRAY_BUFFER, new Uint16Array([0, 1, 2, 0, 2, 3]), gl.STATIC_DRAW);\n gl.vertexAttribPointer(0, 2, gl.FLOAT, false, 0, 0);\n gl.enableVertexAttribArray(0);\n\n function blit(target: FBO | null, clear = false): void {\n if (target === null) {\n gl.viewport(0, 0, gl.drawingBufferWidth, gl.drawingBufferHeight);\n gl.bindFramebuffer(gl.FRAMEBUFFER, null);\n } else {\n gl.viewport(0, 0, target.width, target.height);\n gl.bindFramebuffer(gl.FRAMEBUFFER, target.fbo);\n }\n if (clear) {\n gl.clearColor(0.0, 0.0, 0.0, 1.0);\n gl.clear(gl.COLOR_BUFFER_BIT);\n }\n gl.drawElements(gl.TRIANGLES, 6, gl.UNSIGNED_SHORT, 0);\n }\n\n // Framebuffers\n\n function createFBO(w: number, h: number, internalFormat: number, format: number, type: number, param: number): FBO {\n gl.activeTexture(gl.TEXTURE0);\n const texture = gl.createTexture();\n gl.bindTexture(gl.TEXTURE_2D, texture);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, param);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, param);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);\n gl.texImage2D(gl.TEXTURE_2D, 0, internalFormat, w, h, 0, format, type, null);\n\n const fbo = gl.createFramebuffer();\n gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);\n gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texture, 0);\n gl.viewport(0, 0, w, h);\n gl.clear(gl.COLOR_BUFFER_BIT);\n\n return {\n texture,\n fbo,\n width: w,\n height: h,\n texelSizeX: 1 / w,\n texelSizeY: 1 / h,\n attach(id: number): number {\n gl.activeTexture(gl.TEXTURE0 + id);\n gl.bindTexture(gl.TEXTURE_2D, texture);\n return id;\n },\n };\n }\n\n function createDoubleFBO(\n w: number,\n h: number,\n internalFormat: number,\n format: number,\n type: number,\n param: number\n ): DoubleFBO {\n let fbo1 = createFBO(w, h, internalFormat, format, type, param);\n let fbo2 = createFBO(w, h, internalFormat, format, type, param);\n return {\n width: w,\n height: h,\n texelSizeX: fbo1.texelSizeX,\n texelSizeY: fbo1.texelSizeY,\n get read() {\n return fbo1;\n },\n set read(value: FBO) {\n fbo1 = value;\n },\n get write() {\n return fbo2;\n },\n set write(value: FBO) {\n fbo2 = value;\n },\n swap(): void {\n const temp = fbo1;\n fbo1 = fbo2;\n fbo2 = temp;\n },\n };\n }\n\n function resizeFBO(\n target: FBO,\n w: number,\n h: number,\n internalFormat: number,\n format: number,\n type: number,\n param: number\n ): FBO {\n const newFBO = createFBO(w, h, internalFormat, format, type, param);\n copyProgram.bind();\n gl.uniform1i(copyProgram.uniforms['uTexture'], target.attach(0));\n blit(newFBO);\n return newFBO;\n }\n\n function resizeDoubleFBO(\n target: DoubleFBO,\n w: number,\n h: number,\n internalFormat: number,\n format: number,\n type: number,\n param: number\n ): DoubleFBO {\n if (target.width === w && target.height === h) return target;\n target.read = resizeFBO(target.read, w, h, internalFormat, format, type, param);\n target.write = createFBO(w, h, internalFormat, format, type, param);\n target.width = w;\n target.height = h;\n target.texelSizeX = 1 / w;\n target.texelSizeY = 1 / h;\n return target;\n }\n\n // Programs + state\n\n const copyProgram = new ShaderProgram(baseVertexShader, copyShader);\n const clearProgram = new ShaderProgram(baseVertexShader, clearShader);\n const splatProgram = new ShaderProgram(baseVertexShader, splatShader);\n const advectionProgram = new ShaderProgram(baseVertexShader, advectionShader);\n const divergenceProgram = new ShaderProgram(baseVertexShader, divergenceShader);\n const curlProgram = new ShaderProgram(baseVertexShader, curlShader);\n const vorticityProgram = new ShaderProgram(baseVertexShader, vorticityShader);\n const pressureProgram = new ShaderProgram(baseVertexShader, pressureShader);\n const gradientSubtractProgram = new ShaderProgram(baseVertexShader, gradientSubtractShader);\n const displayMaterial = new DisplayMaterial(baseVertexShader, displayShaderSource);\n\n let dye!: DoubleFBO;\n let velocity!: DoubleFBO;\n let divergence!: FBO;\n let curl!: FBO;\n let pressure!: DoubleFBO;\n\n function initFramebuffers(): void {\n const simRes = getResolution(config.simResolution);\n const dyeRes = getResolution(dyeResolution);\n const texType = ext.halfFloatTexType;\n const rgba = ext.formatRGBA;\n const rg = ext.formatRG;\n const r = ext.formatR;\n const filtering = ext.supportLinearFiltering ? gl.LINEAR : gl.NEAREST;\n gl.disable(gl.BLEND);\n\n dye = dye\n ? resizeDoubleFBO(dye, dyeRes.width, dyeRes.height, rgba.internalFormat, rgba.format, texType, filtering)\n : createDoubleFBO(dyeRes.width, dyeRes.height, rgba.internalFormat, rgba.format, texType, filtering);\n\n velocity = velocity\n ? resizeDoubleFBO(velocity, simRes.width, simRes.height, rg.internalFormat, rg.format, texType, filtering)\n : createDoubleFBO(simRes.width, simRes.height, rg.internalFormat, rg.format, texType, filtering);\n\n divergence = createFBO(simRes.width, simRes.height, r.internalFormat, r.format, texType, gl.NEAREST);\n curl = createFBO(simRes.width, simRes.height, r.internalFormat, r.format, texType, gl.NEAREST);\n pressure = createDoubleFBO(simRes.width, simRes.height, r.internalFormat, r.format, texType, gl.NEAREST);\n }\n\n displayMaterial.setKeywords(shading ? ['SHADING'] : []);\n initFramebuffers();\n let lastUpdateTime = Date.now();\n let colorUpdateTimer = 0;\n\n // Frame loop\n\n function updateFrame(): void {\n if (!active) return;\n const dt = calcDeltaTime();\n if (resizeCanvas()) initFramebuffers();\n updateColors(dt);\n applyInputs();\n step(dt);\n render();\n rafId = requestAnimationFrame(updateFrame);\n }\n\n function calcDeltaTime(): number {\n const now = Date.now();\n const dt = Math.min((now - lastUpdateTime) / 1000, 0.016666);\n lastUpdateTime = now;\n return dt;\n }\n\n function resizeCanvas(): boolean {\n const width = scaleByPixelRatio(canvas.clientWidth);\n const height = scaleByPixelRatio(canvas.clientHeight);\n if (canvas.width !== width || canvas.height !== height) {\n canvas.width = width;\n canvas.height = height;\n return true;\n }\n return false;\n }\n\n function updateColors(dt: number): void {\n colorUpdateTimer += dt * config.colorUpdateSpeed;\n if (colorUpdateTimer >= 1) {\n colorUpdateTimer = wrap(colorUpdateTimer, 0, 1);\n pointer.color = generateColor();\n }\n }\n\n function applyInputs(): void {\n if (pointer.moved) {\n pointer.moved = false;\n splatPointer();\n }\n }\n\n function step(dt: number): void {\n gl.disable(gl.BLEND);\n curlProgram.bind();\n gl.uniform2f(curlProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n gl.uniform1i(curlProgram.uniforms['uVelocity'], velocity.read.attach(0));\n blit(curl);\n\n vorticityProgram.bind();\n gl.uniform2f(vorticityProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n gl.uniform1i(vorticityProgram.uniforms['uVelocity'], velocity.read.attach(0));\n gl.uniform1i(vorticityProgram.uniforms['uCurl'], curl.attach(1));\n gl.uniform1f(vorticityProgram.uniforms['curl'], config.curl);\n gl.uniform1f(vorticityProgram.uniforms['dt'], dt);\n blit(velocity.write);\n velocity.swap();\n\n divergenceProgram.bind();\n gl.uniform2f(divergenceProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n gl.uniform1i(divergenceProgram.uniforms['uVelocity'], velocity.read.attach(0));\n blit(divergence);\n\n clearProgram.bind();\n gl.uniform1i(clearProgram.uniforms['uTexture'], pressure.read.attach(0));\n gl.uniform1f(clearProgram.uniforms['value'], config.pressure);\n blit(pressure.write);\n pressure.swap();\n\n pressureProgram.bind();\n gl.uniform2f(pressureProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n gl.uniform1i(pressureProgram.uniforms['uDivergence'], divergence.attach(0));\n for (let i = 0; i < config.pressureIterations; i++) {\n gl.uniform1i(pressureProgram.uniforms['uPressure'], pressure.read.attach(1));\n blit(pressure.write);\n pressure.swap();\n }\n\n gradientSubtractProgram.bind();\n gl.uniform2f(gradientSubtractProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n gl.uniform1i(gradientSubtractProgram.uniforms['uPressure'], pressure.read.attach(0));\n gl.uniform1i(gradientSubtractProgram.uniforms['uVelocity'], velocity.read.attach(1));\n blit(velocity.write);\n velocity.swap();\n\n advectionProgram.bind();\n gl.uniform2f(advectionProgram.uniforms['texelSize'], velocity.texelSizeX, velocity.texelSizeY);\n if (!ext.supportLinearFiltering) {\n gl.uniform2f(advectionProgram.uniforms['dyeTexelSize'], velocity.texelSizeX, velocity.texelSizeY);\n }\n const velocityId = velocity.read.attach(0);\n gl.uniform1i(advectionProgram.uniforms['uVelocity'], velocityId);\n gl.uniform1i(advectionProgram.uniforms['uSource'], velocityId);\n gl.uniform1f(advectionProgram.uniforms['dt'], dt);\n gl.uniform1f(advectionProgram.uniforms['dissipation'], config.velocityDissipation);\n blit(velocity.write);\n velocity.swap();\n\n if (!ext.supportLinearFiltering) {\n gl.uniform2f(advectionProgram.uniforms['dyeTexelSize'], dye.texelSizeX, dye.texelSizeY);\n }\n gl.uniform1i(advectionProgram.uniforms['uVelocity'], velocity.read.attach(0));\n gl.uniform1i(advectionProgram.uniforms['uSource'], dye.read.attach(1));\n gl.uniform1f(advectionProgram.uniforms['dissipation'], config.densityDissipation);\n blit(dye.write);\n dye.swap();\n }\n\n function render(): void {\n gl.blendFunc(gl.ONE, gl.ONE_MINUS_SRC_ALPHA);\n gl.enable(gl.BLEND);\n displayMaterial.bind();\n if (shading) {\n gl.uniform2f(displayMaterial.uniforms['texelSize'], 1 / gl.drawingBufferWidth, 1 / gl.drawingBufferHeight);\n }\n gl.uniform1i(displayMaterial.uniforms['uTexture'], dye.read.attach(0));\n blit(null);\n }\n\n // Splats\n\n function splatPointer(): void {\n const dx = pointer.deltaX * config.splatForce;\n const dy = pointer.deltaY * config.splatForce;\n splat(pointer.texcoordX, pointer.texcoordY, dx, dy, pointer.color);\n }\n\n function clickSplat(): void {\n const color = generateColor();\n color.r *= 10;\n color.g *= 10;\n color.b *= 10;\n const dx = 10 * (Math.random() - 0.5);\n const dy = 30 * (Math.random() - 0.5);\n splat(pointer.texcoordX, pointer.texcoordY, dx, dy, color);\n }\n\n function splat(x: number, y: number, dx: number, dy: number, color: RGB): void {\n splatProgram.bind();\n gl.uniform1i(splatProgram.uniforms['uTarget'], velocity.read.attach(0));\n gl.uniform1f(splatProgram.uniforms['aspectRatio'], canvas.width / canvas.height);\n gl.uniform2f(splatProgram.uniforms['point'], x, y);\n gl.uniform3f(splatProgram.uniforms['color'], dx, dy, 0);\n gl.uniform1f(splatProgram.uniforms['radius'], correctRadius(config.splatRadius / 100));\n blit(velocity.write);\n velocity.swap();\n\n gl.uniform1i(splatProgram.uniforms['uTarget'], dye.read.attach(0));\n gl.uniform3f(splatProgram.uniforms['color'], color.r, color.g, color.b);\n blit(dye.write);\n dye.swap();\n }\n\n function correctRadius(radius: number): number {\n const aspectRatio = canvas.width / canvas.height;\n return aspectRatio > 1 ? radius * aspectRatio : radius;\n }\n\n // Pointer\n\n function pointerDown(posX: number, posY: number): void {\n pointer.moved = false;\n pointer.texcoordX = posX / canvas.width;\n pointer.texcoordY = 1 - posY / canvas.height;\n pointer.prevTexcoordX = pointer.texcoordX;\n pointer.prevTexcoordY = pointer.texcoordY;\n pointer.deltaX = 0;\n pointer.deltaY = 0;\n pointer.color = generateColor();\n }\n\n function pointerMove(posX: number, posY: number, color: RGB): void {\n pointer.prevTexcoordX = pointer.texcoordX;\n pointer.prevTexcoordY = pointer.texcoordY;\n pointer.texcoordX = posX / canvas.width;\n pointer.texcoordY = 1 - posY / canvas.height;\n pointer.deltaX = correctDeltaX(pointer.texcoordX - pointer.prevTexcoordX);\n pointer.deltaY = correctDeltaY(pointer.texcoordY - pointer.prevTexcoordY);\n pointer.moved = Math.abs(pointer.deltaX) > 0 || Math.abs(pointer.deltaY) > 0;\n pointer.color = color;\n }\n\n function correctDeltaX(delta: number): number {\n const aspectRatio = canvas.width / canvas.height;\n return aspectRatio < 1 ? delta * aspectRatio : delta;\n }\n\n function correctDeltaY(delta: number): number {\n const aspectRatio = canvas.width / canvas.height;\n return aspectRatio > 1 ? delta / aspectRatio : delta;\n }\n\n // Colours\n\n function hexToRGB(hex: string): RGB {\n let val = hex.replace('#', '');\n if (val.length === 3) val = val[0] + val[0] + val[1] + val[1] + val[2] + val[2];\n return {\n r: (Number.parseInt(val.slice(0, 2), 16) / 255) * 0.15,\n g: (Number.parseInt(val.slice(2, 4), 16) / 255) * 0.15,\n b: (Number.parseInt(val.slice(4, 6), 16) / 255) * 0.15,\n };\n }\n\n function generateColor(): RGB {\n if (!config.rainbow) return hexToRGB(config.color);\n const c = hsvToRgb(Math.random(), 1, 1);\n c.r *= 0.15;\n c.g *= 0.15;\n c.b *= 0.15;\n return c;\n }\n\n function hsvToRgb(h: number, s: number, v: number): RGB {\n const i = Math.floor(h * 6);\n const f = h * 6 - i;\n const p = v * (1 - s);\n const q = v * (1 - f * s);\n const t = v * (1 - (1 - f) * s);\n switch (i % 6) {\n case 0:\n return { r: v, g: t, b: p };\n case 1:\n return { r: q, g: v, b: p };\n case 2:\n return { r: p, g: v, b: t };\n case 3:\n return { r: p, g: q, b: v };\n case 4:\n return { r: t, g: p, b: v };\n default:\n return { r: v, g: p, b: q };\n }\n }\n\n function wrap(value: number, min: number, max: number): number {\n const range = max - min;\n if (range === 0) return min;\n return ((value - min) % range) + min;\n }\n\n function getResolution(resolution: number): { width: number; height: number } {\n let aspectRatio = gl.drawingBufferWidth / gl.drawingBufferHeight;\n if (aspectRatio < 1) aspectRatio = 1 / aspectRatio;\n const min = Math.round(resolution);\n const max = Math.round(resolution * aspectRatio);\n return gl.drawingBufferWidth > gl.drawingBufferHeight ? { width: max, height: min } : { width: min, height: max };\n }\n\n function scaleByPixelRatio(input: number): number {\n return Math.floor(input * (window.devicePixelRatio || 1));\n }\n\n function hashCode(s: string): number {\n let hash = 0;\n for (let i = 0; i < s.length; i++) {\n hash = (hash << 5) - hash + s.charCodeAt(i);\n hash |= 0;\n }\n return hash;\n }\n\n // Events + boot\n\n let firstMoveHandled = false;\n\n // Coordinates are taken relative to the canvas box: identical to the\n // raw client position for the fullscreen overlay, and it makes a\n // contained canvas track the pointer correctly too.\n const toLocal = (clientX: number, clientY: number): { x: number; y: number } => {\n const rect = canvas.getBoundingClientRect();\n return { x: scaleByPixelRatio(clientX - rect.left), y: scaleByPixelRatio(clientY - rect.top) };\n };\n\n const onMouseDown = (e: MouseEvent): void => {\n const pos = toLocal(e.clientX, e.clientY);\n pointerDown(pos.x, pos.y);\n clickSplat();\n };\n\n const onMouseMove = (e: MouseEvent): void => {\n const pos = toLocal(e.clientX, e.clientY);\n const color = firstMoveHandled ? pointer.color : generateColor();\n firstMoveHandled = true;\n pointerMove(pos.x, pos.y, color);\n };\n\n const onTouchStart = (e: TouchEvent): void => {\n const t = e.targetTouches[0];\n if (!t) return;\n const pos = toLocal(t.clientX, t.clientY);\n pointerDown(pos.x, pos.y);\n };\n\n const onTouchMove = (e: TouchEvent): void => {\n const t = e.targetTouches[0];\n if (!t) return;\n const pos = toLocal(t.clientX, t.clientY);\n pointerMove(pos.x, pos.y, pointer.color);\n };\n\n window.addEventListener('mousedown', onMouseDown);\n window.addEventListener('mousemove', onMouseMove);\n window.addEventListener('touchstart', onTouchStart, { passive: true });\n window.addEventListener('touchmove', onTouchMove, { passive: true });\n\n updateFrame();\n\n return () => {\n active = false;\n cancelAnimationFrame(rafId);\n window.removeEventListener('mousedown', onMouseDown);\n window.removeEventListener('mousemove', onMouseMove);\n window.removeEventListener('touchstart', onTouchStart);\n window.removeEventListener('touchmove', onTouchMove);\n // The context is NOT lost here on purpose — input changes reboot the\n // sim on the same canvas, and a lost context can't be re-acquired.\n };\n}\n\n// WebGL context bootstrap\n\nfunction getWebGLContext(canvas: HTMLCanvasElement): { gl: GL; ext: GlExt } | null {\n const params: WebGLContextAttributes = {\n alpha: true,\n depth: false,\n stencil: false,\n antialias: false,\n preserveDrawingBuffer: false,\n };\n\n const gl2 = canvas.getContext('webgl2', params);\n const gl = gl2 ?? canvas.getContext('webgl', params);\n if (!gl) return null;\n const isWebGL2 = !!gl2;\n\n let halfFloat: OES_texture_half_float | null = null;\n let supportLinearFiltering: boolean;\n if (isWebGL2) {\n gl.getExtension('EXT_color_buffer_float');\n supportLinearFiltering = !!gl.getExtension('OES_texture_float_linear');\n } else {\n halfFloat = gl.getExtension('OES_texture_half_float');\n supportLinearFiltering = !!gl.getExtension('OES_texture_half_float_linear');\n }\n gl.clearColor(0, 0, 0, 1);\n\n const halfFloatTexType = isWebGL2\n ? (gl as WebGL2RenderingContext).HALF_FLOAT\n : (halfFloat?.HALF_FLOAT_OES ?? gl.UNSIGNED_BYTE);\n\n let formatRGBA: TexFormat | null;\n let formatRG: TexFormat | null;\n let formatR: TexFormat | null;\n if (isWebGL2) {\n const g2 = gl as WebGL2RenderingContext;\n formatRGBA = getSupportedFormat(g2, g2.RGBA16F, g2.RGBA, halfFloatTexType);\n formatRG = getSupportedFormat(g2, g2.RG16F, g2.RG, halfFloatTexType);\n formatR = getSupportedFormat(g2, g2.R16F, g2.RED, halfFloatTexType);\n } else {\n formatRGBA = getSupportedFormat(gl, gl.RGBA, gl.RGBA, halfFloatTexType);\n formatRG = formatRGBA;\n formatR = formatRGBA;\n }\n if (!formatRGBA || !formatRG || !formatR) return null;\n\n return { gl, ext: { formatRGBA, formatRG, formatR, halfFloatTexType, supportLinearFiltering } };\n}\n\nfunction getSupportedFormat(gl: GL, internalFormat: number, format: number, type: number): TexFormat | null {\n if (!supportRenderTextureFormat(gl, internalFormat, format, type)) {\n const g2 = gl as WebGL2RenderingContext;\n switch (internalFormat) {\n case g2.R16F:\n return getSupportedFormat(gl, g2.RG16F, g2.RG, type);\n case g2.RG16F:\n return getSupportedFormat(gl, g2.RGBA16F, g2.RGBA, type);\n default:\n return null;\n }\n }\n return { internalFormat, format };\n}\n\nfunction supportRenderTextureFormat(gl: GL, internalFormat: number, format: number, type: number): boolean {\n const texture = gl.createTexture();\n gl.bindTexture(gl.TEXTURE_2D, texture);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);\n gl.texImage2D(gl.TEXTURE_2D, 0, internalFormat, 4, 4, 0, format, type, null);\n const fbo = gl.createFramebuffer();\n gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);\n gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texture, 0);\n return gl.checkFramebufferStatus(gl.FRAMEBUFFER) === gl.FRAMEBUFFER_COMPLETE;\n}\n\nexport { createFluidSimulation };\nexport type { WrFluidConfig };\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n *\n * Angular adaptation of the SplashCursor effect by David Haz / reactbits.dev.\n * Original: https://www.reactbits.dev/animations/splash-cursor\n */\n\nimport { coerceBooleanProperty } from '@angular/cdk/coercion';\nimport { isPlatformBrowser } from '@angular/common';\nimport type { ElementRef } from '@angular/core';\nimport { Component, NgZone, PLATFORM_ID, ViewEncapsulation, effect, inject, input, viewChild } from '@angular/core';\n\nimport { WrPlatform } from 'ngwr/platform';\nimport { numAttr } from 'ngwr/utils';\n\nimport { createFluidSimulation } from './fluid';\n\n/**\n * Splash cursor — a WebGL fluid simulation that splashes colourful dye\n * wherever the pointer moves or clicks. Renders as a fixed, full-viewport,\n * click-through overlay; mount it once on a page (it follows the pointer\n * everywhere) and it tears down with the component.\n *\n * Renders nothing under `prefers-reduced-motion` or when WebGL is\n * unavailable.\n *\n * @example\n * ```html\n * <wr-splash-cursor />\n * <wr-splash-cursor [rainbow]=\"false\" color=\"#5227ff\" />\n * ```\n *\n * @see https://ngwr.dev/animations/splash-cursor\n */\n@Component({\n selector: 'wr-splash-cursor',\n template: '<canvas #canvas class=\"wr-splash-cursor__canvas\" aria-hidden=\"true\"></canvas>',\n styleUrl: './splash-cursor.scss',\n encapsulation: ViewEncapsulation.None,\n host: {\n class: 'wr-splash-cursor',\n '[class.wr-splash-cursor--contained]': '!fullscreen()',\n },\n})\nexport class WrSplashCursor {\n /**\n * `true` overlays the whole viewport (reactbits behaviour); `false`\n * fills the nearest positioned ancestor instead — handy for demo boxes,\n * and the dye collides with the box walls. @default true\n */\n readonly fullscreen = input(true, { transform: coerceBooleanProperty });\n\n /** Velocity / pressure grid resolution. @default 128 */\n readonly simResolution = input(128, { transform: numAttr(128) });\n\n /** Dye texture resolution — the visible detail. @default 1440 */\n readonly dyeResolution = input(1440, { transform: numAttr(1440) });\n\n /** How fast the dye fades, higher = shorter trails. @default 3.5 */\n readonly densityDissipation = input(3.5, { transform: numAttr(3.5) });\n\n /** How fast motion settles. @default 2 */\n readonly velocityDissipation = input(2, { transform: numAttr(2) });\n\n /** Pressure retained between frames, 0..1. @default 0.1 */\n readonly pressure = input(0.1, { transform: numAttr(0.1) });\n\n /** Jacobi iterations for the pressure solve. @default 20 */\n readonly pressureIterations = input(20, { transform: numAttr(20) });\n\n /** Vorticity confinement — swirliness. @default 3 */\n readonly curl = input(3, { transform: numAttr(3) });\n\n /** Splat size. @default 0.2 */\n readonly splatRadius = input(0.2, { transform: numAttr(0.2) });\n\n /** Velocity a pointer move injects. @default 6000 */\n readonly splatForce = input(6000, { transform: numAttr(6000) });\n\n /** Pseudo-3D shading on the dye. @default true */\n readonly shading = input(true, { transform: coerceBooleanProperty });\n\n /** How fast the splat colour cycles. @default 10 */\n readonly colorUpdateSpeed = input(10, { transform: numAttr(10) });\n\n /** Cycle splat colours through the rainbow. @default true */\n readonly rainbow = input(true, { transform: coerceBooleanProperty });\n\n /** Fixed splat colour when `rainbow` is off. @default '#ff0000' */\n readonly color = input('#ff0000');\n\n private readonly canvasRef = viewChild<ElementRef<HTMLCanvasElement>>('canvas');\n\n private readonly zone = inject(NgZone);\n private readonly platform = inject(WrPlatform);\n private readonly isBrowser = isPlatformBrowser(inject(PLATFORM_ID));\n\n constructor() {\n if (!this.isBrowser) return;\n\n // (Re)boot whenever the canvas appears, any input changes, or the OS\n // reduced-motion preference flips. `onCleanup` tears the old sim down.\n effect(onCleanup => {\n const canvas = this.canvasRef()?.nativeElement;\n const config = {\n simResolution: this.simResolution(),\n dyeResolution: this.dyeResolution(),\n densityDissipation: this.densityDissipation(),\n velocityDissipation: this.velocityDissipation(),\n pressure: this.pressure(),\n pressureIterations: this.pressureIterations(),\n curl: this.curl(),\n splatRadius: this.splatRadius(),\n splatForce: this.splatForce(),\n shading: this.shading(),\n colorUpdateSpeed: this.colorUpdateSpeed(),\n rainbow: this.rainbow(),\n color: this.color(),\n };\n if (!canvas || this.platform.prefersReducedMotion()) return;\n const teardown = this.zone.runOutsideAngular(() => createFluidSimulation(canvas, config));\n if (teardown) onCleanup(teardown);\n });\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;AAAA;;;;;;;;;;;;AAYG;AA2EH,SAAS,qBAAqB,CAAC,MAAyB,EAAE,MAAqB,EAAA;AAC7E,IAAA,MAAM,GAAG,GAAG,eAAe,CAAC,MAAM,CAAC;AACnC,IAAA,IAAI,CAAC,GAAG;AAAE,QAAA,OAAO,IAAI;AACrB,IAAA,MAAM,EAAE,EAAE,EAAE,GAAG,EAAE,GAAG,GAAG;AAEvB,IAAA,IAAI,aAAa,GAAG,MAAM,CAAC,aAAa;AACxC,IAAA,IAAI,OAAO,GAAG,MAAM,CAAC,OAAO;AAC5B,IA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C,QAAQ,CAAC;AACnC,QAAA,CAAC,CAAC;IACJ;uGA/EW,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAd,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,cAAc,4tEARf,+EAA+E,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,gTAAA,CAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA;;2FAQ9E,cAAc,EAAA,UAAA,EAAA,CAAA;kBAV1B,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,kBAAkB,YAClB,+EAA+E,EAAA,aAAA,EAE1E,iBAAiB,CAAC,IAAI,EAAA,IAAA,EAC/B;AACJ,wBAAA,KAAK,EAAE,kBAAkB;AACzB,wBAAA,qCAAqC,EAAE,eAAe;AACvD,qBAAA,EAAA,MAAA,EAAA,CAAA,gTAAA,CAAA,EAAA;+/CAiDqE,QAAQ,EAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;AC9FhF;;AAEG;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"ngwr-split-text-testing.mjs","sources":["../../../projects/lib/split-text/testing/wr-split-text-harness.ts","../../../projects/lib/split-text/testing/ngwr-split-text-testing.ts"],"sourcesContent":["/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { ComponentHarness, HarnessPredicate, type TestElement } from '@angular/cdk/testing';\n\nimport type { WrSplitTextHarnessFilters } from './interfaces';\n\n/** The animated pieces — one per character or per word, whitespace excluded. */\nconst PIECE = '.wr-split-text__piece';\n\n/** The whitespace runs between them, rendered but never staggered. */\nconst SPACE = '.wr-split-text__space';\n\n/** The readable copy of the string, carried once and hidden with CSS. */\nconst SR_ONLY = '.wr-split-text__sr-only';\n\n/**\n * An inline `opacity` declaration — written on every piece the tween touches.\n *\n * `motionToStyle` always produces an opacity, whether or not `from` declared one, and\n * the same property is re-committed when the tween finishes. Matched off the `style`\n * ATTRIBUTE, never through `getCssValue`: a computed style answers `1` for a piece\n * nothing was ever written to, which is the exact case this has to distinguish.\n */\nconst INLINE_OPACITY = /(?:^|;)\\s*opacity\\s*:/;\n\n/** The host's own alignment declaration, as the host binding wrote it. */\nconst INLINE_TEXT_ALIGN = /(?:^|;)\\s*text-align\\s*:\\s*([^;]+)/;\n\n/** Exactly what the element holds — untrimmed, unlike `TestElement.text()`. */\nasync function rawText(element: TestElement): Promise<string> {\n return (await element.getProperty<string | null>('textContent')) ?? '';\n}\n\n/**\n * Test harness for `<wr-split-text>`.\n *\n * **The tween is unreadable from a test, and the absent methods are absent for that\n * reason.** Each piece is animated from a `from` motion state to a `to` one through the\n * Web Animations API, started by an `IntersectionObserver`. A unit test has no layout,\n * no compositor and no WAAPI, so there is no `getOpacity()` and no `getTransform()`:\n * both would report the frozen staged value in jsdom and a value the compositor is not\n * painting in a browser. There is no `getFromState()` / `getToState()` either — those\n * objects only reach the DOM as staged inline styles, on the one path that throws here,\n * so reporting them would mean re-deriving an input from a string the component may\n * never have written. No `isAnimating()`, no `whenAnimationComplete()`: nothing in the\n * document says a tween is running, and completion is the `animationComplete` OUTPUT,\n * which the host binds. No `enterViewport()` / `trigger()`, because an observer is not\n * reachable from a `TestElement` — and observation here is additionally gated behind\n * `document.fonts.ready`, which jsdom does not have, so a `waitForFonts()` would resolve\n * instantly and prove nothing about the gating it claimed to test. Nothing measures\n * either: `getLineCount()` / `didItWrap()` would need layout (and `lines` is not a split\n * this port supports), and the `overflow: hidden` mask with its descender compensation\n * is a stylesheet, which a test runs none of.\n *\n * **What is real is the split, the accessible layer and the alignment.** The string is\n * carried once in a visually-hidden span and every drawn piece is `aria-hidden`, so\n * {@link getAccessibleText} is what is heard while {@link getPieces} is what is drawn —\n * two questions, and a spec asserting only the second would pass on a component that\n * spells the text out letter by letter. {@link getRenderedText} closes the loop by\n * putting the pieces and the spaces back together: the split has to be lossless, and\n * that comparison is what catches a dropped space or a halved surrogate pair. Whether\n * the hidden copy is genuinely off-screen is CSS, so nothing here claims to know.\n *\n * **{@link getTextAlign} is the one input this component reflects**, written straight\n * onto the host as an inline style — an honest read with no layout involved, unlike\n * anything else about how the text is arranged. And {@link hasStagedMotion} is the one\n * fact about the tween worth pinning: that the pieces were taken over, not that anything\n * is moving.\n *\n * Driving the reveal is the spec's job — jsdom supplies neither half of it, and the font\n * gate defers observation by a microtask:\n *\n * ```ts\n * // Before TestBed.createComponent — keep the callbacks so the spec can fire them.\n * vi.stubGlobal('IntersectionObserver', StubObserver);\n * // Otherwise `el.animate(...)` throws mid-stagger and leaves the DOM half-staged.\n * Reflect.set(Element.prototype, 'animate', () => ({ cancel: () => undefined, onfinish: null }));\n * // …and always settle before tearing down: observation is queued off a promise, and\n * // landing after destroy() registers a teardown on a dead DestroyRef (NG0911).\n * await fixture.whenStable();\n * ```\n *\n * @example\n * ```ts\n * const hero = await loader.getHarness(WrSplitTextHarness.with({ textAlign: 'center' }));\n *\n * expect(await hero.getPieces()).toEqual(['H', 'e', 'l', 'l', 'o']);\n * expect(await hero.getRenderedText()).toBe(await hero.getAccessibleText());\n * expect(await hero.isTextHidden()).toBe(true);\n * ```\n *\n * @see https://ngwr.dev/guides/testing\n */\nexport class WrSplitTextHarness extends ComponentHarness {\n static hostSelector = 'wr-split-text';\n\n /** Build a predicate that narrows the query — pass to `getHarness` / `getAllHarnesses`. */\n static with(options: WrSplitTextHarnessFilters = {}): HarnessPredicate<WrSplitTextHarness> {\n return new HarnessPredicate(WrSplitTextHarness, options)\n .addOption('text', options.text, (harness, text) =>\n HarnessPredicate.stringMatches(harness.getAccessibleText(), text)\n )\n .addOption('pieceCount', options.pieceCount, async (harness, count) => (await harness.getPieceCount()) === count)\n .addOption('textAlign', options.textAlign, async (harness, align) => (await harness.getTextAlign()) === align);\n }\n\n private readonly pieces = this.locatorForAll(PIECE);\n private readonly spaces = this.locatorForAll(SPACE);\n\n /**\n * The whole string, as the one readable copy holds it.\n *\n * All a screen reader gets, since every drawn piece is out of the tree — lose this\n * span and the component becomes a nameless pile of hidden spans, with no other\n * symptom anywhere in the DOM.\n *\n * Untrimmed, deliberately: leading and trailing whitespace is content the split has to\n * carry, and {@link getRenderedText} is meant to compare equal to this. A trimmed read\n * on one side of that comparison would forgive the case it exists to catch.\n */\n async getAccessibleText(): Promise<string> {\n return rawText(await this.locatorFor(SR_ONLY)());\n }\n\n /**\n * The animated pieces, in document order — one per character, or one per word.\n *\n * The split the stagger runs over: `['H', 'i']` at the default `splitType=\"chars\"`\n * against `['Hi', 'there']` for `\"words\"`, and `['a', '🚀']` for a surrogate pair the\n * code-point split kept whole instead of halving into two broken glyphs. Whitespace is\n * not here — it is drawn separately and never staggered, so see {@link getSpaceCount}.\n */\n async getPieces(): Promise<string[]> {\n return Promise.all((await this.pieces()).map(rawText));\n }\n\n /**\n * How many pieces the stagger runs over.\n *\n * `delay` × this is the real length of the effect, and the only number about the\n * animation present in the document.\n */\n async getPieceCount(): Promise<number> {\n return (await this.pieces()).length;\n }\n\n /**\n * How many whitespace runs sit between the pieces.\n *\n * Its own method because whitespace is deliberately excluded from the animated set:\n * reclassifying spaces as pieces would leave {@link getRenderedText} identical, change\n * the stagger count and the rhythm of the reveal, and show up nowhere else.\n */\n async getSpaceCount(): Promise<number> {\n return (await this.spaces()).length;\n }\n\n /**\n * Everything the component drew, pieces and spaces together, in document order.\n *\n * The assertion this exists for is `getRenderedText() === getAccessibleText()`: the\n * split must be lossless. A swallowed space, a re-split that dropped a character or a\n * surrogate pair cut in half all leave the accessible copy intact and are invisible\n * from anywhere else.\n */\n async getRenderedText(): Promise<string> {\n const parts = await this.locatorForAll(`${PIECE}, ${SPACE}`)();\n return (await Promise.all(parts.map(rawText))).join('');\n }\n\n /**\n * Whether every drawn piece is out of the accessibility tree.\n *\n * The defect this component exists to avoid is a screen reader reading\n * `H. e. l. l. o.`, and one piece missing `aria-hidden` brings it back — so this is\n * all-or-nothing, across both element kinds: a readable space is heard as a pause in\n * the middle of a word.\n *\n * Throws when the split produced nothing at all. An empty run of elements satisfies\n * \"every one of them is hidden\" without anything being hidden, which is also what a\n * component that stopped rendering its pieces would report.\n */\n async isTextHidden(): Promise<boolean> {\n const parts = await this.locatorForAll(`${PIECE}, ${SPACE}`)();\n\n if (parts.length === 0) {\n throw new Error(\n 'WrSplitTextHarness.isTextHidden(): this <wr-split-text> drew no pieces, so there is nothing to be ' +\n 'hidden from a screen reader and \"true\" would be a vacuous answer — the same one a component that ' +\n 'stopped splitting its text would give. Check `text` is set, or ask getPieceCount().'\n );\n }\n\n const hidden = await Promise.all(parts.map(part => part.getAttribute('aria-hidden')));\n return hidden.every(value => value === 'true');\n }\n\n /**\n * The alignment the host was given, as the component wrote it.\n *\n * Off the inline `style` attribute rather than through `getCssValue`, and the\n * difference is not pedantry: computed style answers for an element nobody wrote to —\n * with the inherited or user-agent value — so a host that stopped reflecting the input\n * altogether would keep reporting a plausible `left` or `start`. The attribute is the\n * fact being asserted.\n *\n * `null` means the host carries no alignment at all, which the component never does:\n * the binding is unconditional and the input defaults to `'center'`.\n */\n async getTextAlign(): Promise<string | null> {\n const match = INLINE_TEXT_ALIGN.exec((await (await this.host()).getAttribute('style')) ?? '');\n return match ? match[1].trim() : null;\n }\n\n /**\n * Whether the reveal has taken the pieces over — NOT whether anything is animating.\n *\n * Read off the inline `style` attribute the component writes itself, so it stays\n * `true` once the reveal has finished: the tween commits its end state back to the\n * same inline properties on `onfinish`. Anyone reaching for `isAnimating()` wants a\n * frame, and there are no frames here.\n *\n * `false` is the answer worth asserting. It means no piece was written to, which is\n * both the pre-trigger state and the reduced-motion promise — the component returns\n * before staging anything, so a reader who asked for less motion cannot be left with\n * text parked at `from.opacity: 0` by a tween that never runs.\n *\n * ANY piece counts, not all of them, and that is the conservative reading rather than\n * a loose one: a stagger that stages the first piece and then throws leaves exactly\n * one glyph invisible, which is a real failure — and one jsdom reproduces every time\n * `Element.prototype.animate` is missing.\n */\n async hasStagedMotion(): Promise<boolean> {\n const styles = await Promise.all((await this.pieces()).map(piece => piece.getAttribute('style')));\n return styles.some(style => INLINE_OPACITY.test(style ?? ''));\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;AAAA;;;;;AAKG;AAMH;AACA,MAAM,KAAK,GAAG,uBAAuB;AAErC;AACA,MAAM,KAAK,GAAG,uBAAuB;AAErC;AACA,MAAM,OAAO,GAAG,yBAAyB;AAEzC;;;;;;;AAOG;AACH,MAAM,cAAc,GAAG,uBAAuB;AAE9C;AACA,MAAM,iBAAiB,GAAG,oCAAoC;AAE9D;AACA,eAAe,OAAO,CAAC,OAAoB,EAAA;IACzC,OAAO,CAAC,MAAM,OAAO,CAAC,WAAW,CAAgB,aAAa,CAAC,KAAK,EAAE;AACxE;AAEA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2DG;AACG,MAAO,kBAAmB,SAAQ,gBAAgB,CAAA;AACtD,IAAA,OAAO,YAAY,GAAG,eAAe;;AAGrC,IAAA,OAAO,IAAI,CAAC,OAAA,GAAqC,EAAE,EAAA;AACjD,QAAA,OAAO,IAAI,gBAAgB,CAAC,kBAAkB,EAAE,OAAO;aACpD,SAAS,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI,EAAE,CAAC,OAAO,EAAE,IAAI,KAC7C,gBAAgB,CAAC,aAAa,CAAC,OAAO,CAAC,iBAAiB,EAAE,EAAE,IAAI,CAAC;aAElE,SAAS,CAAC,YAAY,EAAE,OAAO,CAAC,UAAU,EAAE,OAAO,OAAO,EAAE,KAAK,KAAK,CAAC,MAAM,OAAO,CAAC,a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AAa,CAAC,CAAA,EAAG,KAAK,CAAA,EAAA,EAAK,KAAK,CAAA,CAAE,CAAC,EAAE;AAE9D,QAAA,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE;YACtB,MAAM,IAAI,KAAK,CACb,oGAAoG;gBAClG,mGAAmG;AACnG,gBAAA,qFAAqF,CACxF;QACH;QAEA,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,IAAI,IAAI,IAAI,CAAC,YAAY,CAAC,aAAa,CAAC,CAAC,CAAC;AACrF,QAAA,OAAO,MAAM,CAAC,KAAK,CAAC,KAAK,IAAI,KAAK,KAAK,MAAM,CAAC;IAChD;AAEA;;;;;;;;;;;AAWG;AACH,IAAA,MAAM,YAAY,GAAA;QAChB,MAAM,KAAK,GAAG,iBAAiB,CAAC,IAAI,CAAC,CAAC,MAAM,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,YAAY,CAAC,OAAO,CAAC,KAAK,EAAE,CAAC;AAC7F,QAAA,OAAO,KAAK,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,EAAE,GAAG,IAAI;IACvC;AAEA;;;;;;;;;;;;;;;;;AAiBG;AACH,IAAA,MAAM,eAAe,GAAA;AACnB,QAAA,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,CAAC,MAAM,IAAI,CAAC,MAAM,EAAE,EAAE,GAAG,CAAC,KAAK,IAAI,KAAK,CAAC,YAAY,CAAC,OAAO,CAAC,CAAC,CAAC;AACjG,QAAA,OAAO,MAAM,CAAC,IAAI,CAAC,KAAK,IAAI,cAAc,CAAC,IAAI,CAAC,KAAK,IAAI,EAAE,CAAC,CAAC;IAC/D;;;AChPF;;AAEG;;;;"}
1
+ {"version":3,"file":"ngwr-split-text-testing.mjs","sources":["../../../projects/lib/split-text/testing/wr-split-text-harness.ts","../../../projects/lib/split-text/testing/ngwr-split-text-testing.ts"],"sourcesContent":["/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { ComponentHarness, HarnessPredicate, type TestElement } from '@angular/cdk/testing';\n\nimport type { WrSplitTextHarnessFilters } from './interfaces';\n\n/** The animated pieces — one per character or per word, whitespace excluded. */\nconst PIECE = '.wr-split-text__piece';\n\n/** The whitespace runs between them, rendered but never staggered. */\nconst SPACE = '.wr-split-text__space';\n\n/** The readable copy of the string, carried once and hidden with CSS. */\nconst SR_ONLY = '.wr-split-text__sr-only';\n\n/**\n * An inline `opacity` declaration — written on every piece the tween touches.\n *\n * `motionToStyle` always produces an opacity, whether or not `from` declared one, and\n * the same property is re-committed when the tween finishes. Matched off the `style`\n * ATTRIBUTE, never through `getCssValue`: a computed style answers `1` for a piece\n * nothing was ever written to, which is the exact case this has to distinguish.\n */\nconst INLINE_OPACITY = /(?:^|;)\\s*opacity\\s*:/;\n\n/** The host's own alignment declaration, as the host binding wrote it. */\nconst INLINE_TEXT_ALIGN = /(?:^|;)\\s*text-align\\s*:\\s*([^;]+)/;\n\n/** Exactly what the element holds — untrimmed, unlike `TestElement.text()`. */\nasync function rawText(element: TestElement): Promise<string> {\n return (await element.getProperty<string | null>('textContent')) ?? '';\n}\n\n/**\n * Test harness for `<wr-split-text>`.\n *\n * **The tween is unreadable from a test, and the absent methods are absent for that\n * reason.** Each piece is animated from a `from` motion state to a `to` one through the\n * Web Animations API, started by an `IntersectionObserver`. A unit test has no layout,\n * no compositor and no WAAPI, so there is no `getOpacity()` and no `getTransform()`:\n * both would report the frozen staged value in jsdom and a value the compositor is not\n * painting in a browser. There is no `getFromState()` / `getToState()` either — those\n * objects only reach the DOM as staged inline styles, on the one path that throws here,\n * so reporting them would mean re-deriving an input from a string the component may\n * never have written. No `isAnimating()`, no `whenAnimationComplete()`: nothing in the\n * document says a tween is running, and completion is the `animationComplete` OUTPUT,\n * which the host binds. No `enterViewport()` / `trigger()`, because an observer is not\n * reachable from a `TestElement` — and observation here is additionally gated behind\n * `document.fonts.ready`, which jsdom does not have, so a `waitForFonts()` would resolve\n * instantly and prove nothing about the gating it claimed to test. Nothing measures\n * either: `getLineCount()` / `didItWrap()` would need layout (and `lines` is not a split\n * this port supports), and the `overflow: hidden` mask with its descender compensation\n * is a stylesheet, which a test runs none of.\n *\n * **What is real is the split, the accessible layer and the alignment.** The string is\n * carried once in a visually-hidden span and every drawn piece is `aria-hidden`, so\n * {@link getAccessibleText} is what is heard while {@link getPieces} is what is drawn —\n * two questions, and a spec asserting only the second would pass on a component that\n * spells the text out letter by letter. {@link getRenderedText} closes the loop by\n * putting the pieces and the spaces back together: the split has to be lossless, and\n * that comparison is what catches a dropped space or a halved surrogate pair. Whether\n * the hidden copy is genuinely off-screen is CSS, so nothing here claims to know.\n *\n * **{@link getTextAlign} is the one input this component reflects**, written straight\n * onto the host as an inline style — an honest read with no layout involved, unlike\n * anything else about how the text is arranged. And {@link hasStagedMotion} is the one\n * fact about the tween worth pinning: that the pieces were taken over, not that anything\n * is moving.\n *\n * Driving the reveal is the spec's job — jsdom supplies neither half of it, and the font\n * gate defers observation by a microtask:\n *\n * ```ts\n * // Before TestBed.createComponent — keep the callbacks so the spec can fire them.\n * vi.stubGlobal('IntersectionObserver', StubObserver);\n * // Otherwise `el.animate(...)` throws mid-stagger and leaves the DOM half-staged.\n * Reflect.set(Element.prototype, 'animate', () => ({ cancel: () => undefined, onfinish: null }));\n * // …and always settle before tearing down: observation is queued off a promise, and\n * // landing after destroy() registers a teardown on a dead DestroyRef (NG0911).\n * await fixture.whenStable();\n * ```\n *\n * @example\n * ```ts\n * const hero = await loader.getHarness(WrSplitTextHarness.with({ textAlign: 'center' }));\n *\n * expect(await hero.getPieces()).toEqual(['H', 'e', 'l', 'l', 'o']);\n * expect(await hero.getRenderedText()).toBe(await hero.getAccessibleText());\n * expect(await hero.isTextHidden()).toBe(true);\n * ```\n *\n * @see https://ngwr.dev/guides/testing\n */\nexport class WrSplitTextHarness extends ComponentHarness {\n static hostSelector = 'wr-split-text';\n\n /** Build a predicate that narrows the query — pass to `getHarness` / `getAllHarnesses`. */\n static with(options: WrSplitTextHarnessFilters = {}): HarnessPredicate<WrSplitTextHarness> {\n return new HarnessPredicate(WrSplitTextHarness, options)\n .addOption('text', options.text, (harness, text) =>\n HarnessPredicate.stringMatches(harness.getAccessibleText(), text)\n )\n .addOption('pieceCount', options.pieceCount, async (harness, count) => (await harness.getPieceCount()) === count)\n .addOption('textAlign', options.textAlign, async (harness, align) => (await harness.getTextAlign()) === align);\n }\n\n private readonly pieces = this.locatorForAll(PIECE);\n private readonly spaces = this.locatorForAll(SPACE);\n\n /**\n * The whole string, as the one readable copy holds it.\n *\n * All a screen reader gets, since every drawn piece is out of the tree — lose this\n * span and the component becomes a nameless pile of hidden spans, with no other\n * symptom anywhere in the DOM.\n *\n * Untrimmed, deliberately: leading and trailing whitespace is content the split has to\n * carry, and {@link getRenderedText} is meant to compare equal to this. A trimmed read\n * on one side of that comparison would forgive the case it exists to catch.\n */\n async getAccessibleText(): Promise<string> {\n return rawText(await this.locatorFor(SR_ONLY)());\n }\n\n /**\n * The animated pieces, in document order — one per character, or one per word.\n *\n * The split the stagger runs over: `['H', 'i']` at the default `splitType=\"chars\"`\n * against `['Hi', 'there']` for `\"words\"`, and `['a', '🚀']` for a surrogate pair the\n * code-point split kept whole instead of halving into two broken glyphs. Whitespace is\n * not here — it is drawn separately and never staggered, so see {@link getSpaceCount}.\n */\n async getPieces(): Promise<string[]> {\n return Promise.all((await this.pieces()).map(rawText));\n }\n\n /**\n * How many pieces the stagger runs over.\n *\n * `delay` × this is the real length of the effect, and the only number about the\n * animation present in the document.\n */\n async getPieceCount(): Promise<number> {\n return (await this.pieces()).length;\n }\n\n /**\n * How many whitespace runs sit between the pieces.\n *\n * Its own method because whitespace is deliberately excluded from the animated set:\n * reclassifying spaces as pieces would leave {@link getRenderedText} identical, change\n * the stagger count and the rhythm of the reveal, and show up nowhere else.\n */\n async getSpaceCount(): Promise<number> {\n return (await this.spaces()).length;\n }\n\n /**\n * Everything the component drew, pieces and spaces together, in document order.\n *\n * The assertion this exists for is `getRenderedText() === getAccessibleText()`: the\n * split must be lossless. A swallowed space, a re-split that dropped a character or a\n * surrogate pair cut in half all leave the accessible copy intact and are invisible\n * from anywhere else.\n */\n async getRenderedText(): Promise<string> {\n const parts = await this.locatorForAll(`${PIECE}, ${SPACE}`)();\n return (await Promise.all(parts.map(rawText))).join('');\n }\n\n /**\n * Whether every drawn piece is out of the accessibility tree.\n *\n * The defect this component exists to avoid is a screen reader reading\n * `H. e. l. l. o.`, and one piece missing `aria-hidden` brings it back — so this is\n * all-or-nothing, across both element kinds: a readable space is heard as a pause in\n * the middle of a word.\n *\n * Throws when the split produced nothing at all. An empty run of elements satisfies\n * \"every one of them is hidden\" without anything being hidden, which is also what a\n * component that stopped rendering its pieces would report.\n */\n async isTextHidden(): Promise<boolean> {\n const parts = await this.locatorForAll(`${PIECE}, ${SPACE}`)();\n\n if (parts.length === 0) {\n throw new Error(\n 'WrSplitTextHarness.isTextHidden(): this <wr-split-text> drew no pieces, so there is nothing to be ' +\n 'hidden from a screen reader and \"true\" would be a vacuous answer — the same one a component that ' +\n 'stopped splitting its text would give. Check `text` is set, or ask getPieceCount().'\n );\n }\n\n const hidden = await Promise.all(parts.map(part => part.getAttribute('aria-hidden')));\n return hidden.every(value => value === 'true');\n }\n\n /**\n * The alignment the host was given, as the component wrote it.\n *\n * Off the inline `style` attribute rather than through `getCssValue`, and the\n * difference is not pedantry: computed style answers for an element nobody wrote to —\n * with the inherited or user-agent value — so a host that stopped reflecting the input\n * altogether would keep reporting a plausible `left` or `start`. The attribute is the\n * fact being asserted.\n *\n * `null` means the host carries no alignment at all, which the component never does:\n * the binding is unconditional and the input defaults to `'center'`.\n */\n async getTextAlign(): Promise<string | null> {\n const match = INLINE_TEXT_ALIGN.exec((await (await this.host()).getAttribute('style')) ?? '');\n return match ? match[1].trim() : null;\n }\n\n /**\n * Whether the reveal has taken the pieces over — NOT whether anything is animating.\n *\n * Read off the inline `style` attribute the component writes itself, so it stays\n * `true` once the reveal has finished: the tween commits its end state back to the\n * same inline properties on `onfinish`. Anyone reaching for `isAnimating()` wants a\n * frame, and there are no frames here.\n *\n * `false` is the answer worth asserting. It means no piece was written to, which is\n * both the pre-trigger state and the reduced-motion promise — the component returns\n * before staging anything, so a reader who asked for less motion cannot be left with\n * text parked at `from.opacity: 0` by a tween that never runs.\n *\n * ANY piece counts, not all of them, and that is the conservative reading rather than\n * a loose one: a stagger that stages the first piece and then throws leaves exactly\n * one glyph invisible, which is a real failure — and one jsdom reproduces every time\n * `Element.prototype.animate` is missing.\n */\n async hasStagedMotion(): Promise<boolean> {\n const styles = await Promise.all((await this.pieces()).map(piece => piece.getAttribute('style')));\n return styles.some(style => INLINE_OPACITY.test(style ?? ''));\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;AAAA;;;;;AAKG;AAMH;AACA,MAAM,KAAK,GAAG,uBAAuB;AAErC;AACA,MAAM,KAAK,GAAG,uBAAuB;AAErC;AACA,MAAM,OAAO,GAAG,yBAAyB;AAEzC;;;;;;;AAOG;AACH,MAAM,cAAc,GAAG,uBAAuB;AAE9C;AACA,MAAM,iBAAiB,GAAG,oCAAoC;AAE9D;AACA,eAAe,OAAO,CAAC,OAAoB,EAAA;IACzC,OAAO,CAAC,MAAM,OAAO,CAAC,WAAW,CAAgB,aAAa,CAAC,KAAK,EAAE;AACxE;AAEA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2DG;AACG,MAAO,kBAAmB,SAAQ,gBAAgB,CAAA;AACtD,IAAA,OAAO,YAAY,GAAG,eAAe;;AAGrC,IAAA,OAAO,IAAI,CAAC,OAAA,GAAqC,EAAE,EAAA;AACjD,QAAA,OAAO,IAAI,gBAAgB,CAAC,kBAAkB,EAAE,OAAO;aACp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