ngwr 16.2.0 → 16.3.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 (398) hide show
  1. package/badge/styles/_tag.scss +73 -1
  2. package/calendar/styles/_index.scss +22 -0
  3. package/cascader/styles/_rules.scss +7 -0
  4. package/color-picker/styles/_index.scss +21 -0
  5. package/date-picker/styles/_index.scss +19 -0
  6. package/dropdown/styles/_index.scss +13 -19
  7. package/fesm2022/ngwr-affix.mjs +3 -3
  8. package/fesm2022/ngwr-alert-testing.mjs +70 -0
  9. package/fesm2022/ngwr-alert-testing.mjs.map +1 -0
  10. package/fesm2022/ngwr-alert.mjs +3 -3
  11. package/fesm2022/ngwr-anchor.mjs +17 -6
  12. package/fesm2022/ngwr-anchor.mjs.map +1 -1
  13. package/fesm2022/ngwr-animations-aurora.mjs +3 -3
  14. package/fesm2022/ngwr-animations-blur-reveal.mjs +3 -3
  15. package/fesm2022/ngwr-animations-click-sparks.mjs +3 -3
  16. package/fesm2022/ngwr-animations-confetti.mjs +3 -3
  17. package/fesm2022/ngwr-animations-decode.mjs +3 -3
  18. package/fesm2022/ngwr-animations-destruct.mjs +3 -3
  19. package/fesm2022/ngwr-animations-dot-grid.mjs +3 -3
  20. package/fesm2022/ngwr-animations-falling-letters.mjs +3 -3
  21. package/fesm2022/ngwr-animations-flow-lines.mjs +3 -3
  22. package/fesm2022/ngwr-animations-fluid-cursor.mjs +3 -3
  23. package/fesm2022/ngwr-animations-glitch.mjs +3 -3
  24. package/fesm2022/ngwr-animations-glow-border.mjs +3 -3
  25. package/fesm2022/ngwr-animations-gradient-flow.mjs +3 -3
  26. package/fesm2022/ngwr-animations-marquee.mjs +3 -3
  27. package/fesm2022/ngwr-animations-orbit.mjs +3 -3
  28. package/fesm2022/ngwr-animations-reveal.mjs +3 -3
  29. package/fesm2022/ngwr-animations-ripple-grid.mjs +3 -3
  30. package/fesm2022/ngwr-animations-rotate-reveal.mjs +3 -3
  31. package/fesm2022/ngwr-animations-shimmer.mjs +3 -3
  32. package/fesm2022/ngwr-animations-spotlight.mjs +3 -3
  33. package/fesm2022/ngwr-animations-thread-lines.mjs +3 -3
  34. package/fesm2022/ngwr-animations-tilt.mjs +3 -3
  35. package/fesm2022/ngwr-animations-typewriter.mjs +3 -3
  36. package/fesm2022/ngwr-avatar.mjs +3 -3
  37. package/fesm2022/ngwr-back-top.mjs +3 -3
  38. package/fesm2022/ngwr-badge.mjs +129 -11
  39. package/fesm2022/ngwr-badge.mjs.map +1 -1
  40. package/fesm2022/ngwr-breadcrumbs-testing.mjs +83 -0
  41. package/fesm2022/ngwr-breadcrumbs-testing.mjs.map +1 -0
  42. package/fesm2022/ngwr-breadcrumbs.mjs +8 -8
  43. package/fesm2022/ngwr-breadcrumbs.mjs.map +1 -1
  44. package/fesm2022/ngwr-burger-testing.mjs +45 -0
  45. package/fesm2022/ngwr-burger-testing.mjs.map +1 -0
  46. package/fesm2022/ngwr-burger.mjs +3 -3
  47. package/fesm2022/ngwr-button.mjs +6 -6
  48. package/fesm2022/ngwr-calendar-testing.mjs +18 -0
  49. package/fesm2022/ngwr-calendar-testing.mjs.map +1 -1
  50. package/fesm2022/ngwr-calendar.mjs +500 -73
  51. package/fesm2022/ngwr-calendar.mjs.map +1 -1
  52. package/fesm2022/ngwr-card.mjs +9 -9
  53. package/fesm2022/ngwr-carousel.mjs +6 -6
  54. package/fesm2022/ngwr-cascader.mjs +37 -16
  55. package/fesm2022/ngwr-cascader.mjs.map +1 -1
  56. package/fesm2022/ngwr-charts-bar-chart.mjs +5 -4
  57. package/fesm2022/ngwr-charts-bar-chart.mjs.map +1 -1
  58. package/fesm2022/ngwr-charts-boxplot-chart.mjs +3 -3
  59. package/fesm2022/ngwr-charts-bullet-chart.mjs +3 -3
  60. package/fesm2022/ngwr-charts-calendar-heatmap.mjs +3 -3
  61. package/fesm2022/ngwr-charts-candlestick-chart.mjs +3 -3
  62. package/fesm2022/ngwr-charts-chart-legend.mjs +26 -11
  63. package/fesm2022/ngwr-charts-chart-legend.mjs.map +1 -1
  64. package/fesm2022/ngwr-charts-core.mjs +3 -3
  65. package/fesm2022/ngwr-charts-donut-chart.mjs +5 -4
  66. package/fesm2022/ngwr-charts-donut-chart.mjs.map +1 -1
  67. package/fesm2022/ngwr-charts-funnel-chart.mjs +3 -3
  68. package/fesm2022/ngwr-charts-gauge.mjs +3 -3
  69. package/fesm2022/ngwr-charts-heatmap-chart.mjs +3 -3
  70. package/fesm2022/ngwr-charts-line-chart-testing.mjs +3 -2
  71. package/fesm2022/ngwr-charts-line-chart-testing.mjs.map +1 -1
  72. package/fesm2022/ngwr-charts-line-chart.mjs +17 -7
  73. package/fesm2022/ngwr-charts-line-chart.mjs.map +1 -1
  74. package/fesm2022/ngwr-charts-meter-group.mjs +5 -4
  75. package/fesm2022/ngwr-charts-meter-group.mjs.map +1 -1
  76. package/fesm2022/ngwr-charts-radar-chart.mjs +5 -4
  77. package/fesm2022/ngwr-charts-radar-chart.mjs.map +1 -1
  78. package/fesm2022/ngwr-charts-scatter-chart.mjs +5 -4
  79. package/fesm2022/ngwr-charts-scatter-chart.mjs.map +1 -1
  80. package/fesm2022/ngwr-charts-sparkline.mjs +3 -3
  81. package/fesm2022/ngwr-charts-treemap-chart.mjs +3 -3
  82. package/fesm2022/ngwr-charts-waterfall-chart.mjs +3 -3
  83. package/fesm2022/ngwr-checkbox.mjs +6 -6
  84. package/fesm2022/ngwr-clipboard.mjs +3 -3
  85. package/fesm2022/ngwr-collapse.mjs +9 -9
  86. package/fesm2022/ngwr-color-picker-testing.mjs +11 -1
  87. package/fesm2022/ngwr-color-picker-testing.mjs.map +1 -1
  88. package/fesm2022/ngwr-color-picker.mjs +153 -37
  89. package/fesm2022/ngwr-color-picker.mjs.map +1 -1
  90. package/fesm2022/ngwr-command-palette.mjs +3 -3
  91. package/fesm2022/ngwr-comment.mjs +10 -6
  92. package/fesm2022/ngwr-comment.mjs.map +1 -1
  93. package/fesm2022/ngwr-compare-testing.mjs +84 -0
  94. package/fesm2022/ngwr-compare-testing.mjs.map +1 -0
  95. package/fesm2022/ngwr-compare.mjs +3 -3
  96. package/fesm2022/ngwr-context-menu.mjs +12 -12
  97. package/fesm2022/ngwr-cookie.mjs +3 -3
  98. package/fesm2022/ngwr-copy-value.mjs +3 -3
  99. package/fesm2022/ngwr-counter.mjs +6 -6
  100. package/fesm2022/ngwr-date-picker-testing.mjs +30 -4
  101. package/fesm2022/ngwr-date-picker-testing.mjs.map +1 -1
  102. package/fesm2022/ngwr-date-picker.mjs +342 -69
  103. package/fesm2022/ngwr-date-picker.mjs.map +1 -1
  104. package/fesm2022/ngwr-date-stamp.mjs +3 -3
  105. package/fesm2022/ngwr-date.mjs +59 -8
  106. package/fesm2022/ngwr-date.mjs.map +1 -1
  107. package/fesm2022/ngwr-density.mjs +6 -6
  108. package/fesm2022/ngwr-descriptions.mjs +6 -6
  109. package/fesm2022/ngwr-dialog.mjs +18 -18
  110. package/fesm2022/ngwr-directives.mjs +15 -15
  111. package/fesm2022/ngwr-divider.mjs +3 -3
  112. package/fesm2022/ngwr-drawer.mjs +51 -29
  113. package/fesm2022/ngwr-drawer.mjs.map +1 -1
  114. package/fesm2022/ngwr-dropdown-testing.mjs +11 -3
  115. package/fesm2022/ngwr-dropdown-testing.mjs.map +1 -1
  116. package/fesm2022/ngwr-dropdown.mjs +52 -95
  117. package/fesm2022/ngwr-dropdown.mjs.map +1 -1
  118. package/fesm2022/ngwr-editor.mjs +4 -3
  119. package/fesm2022/ngwr-editor.mjs.map +1 -1
  120. package/fesm2022/ngwr-empty.mjs +3 -3
  121. package/fesm2022/ngwr-event-calendar.mjs +186 -33
  122. package/fesm2022/ngwr-event-calendar.mjs.map +1 -1
  123. package/fesm2022/ngwr-file-upload-testing.mjs +34 -2
  124. package/fesm2022/ngwr-file-upload-testing.mjs.map +1 -1
  125. package/fesm2022/ngwr-file-upload.mjs +274 -15
  126. package/fesm2022/ngwr-file-upload.mjs.map +1 -1
  127. package/fesm2022/ngwr-form.mjs +9 -9
  128. package/fesm2022/ngwr-form.mjs.map +1 -1
  129. package/fesm2022/ngwr-graph-testing.mjs +3 -0
  130. package/fesm2022/ngwr-graph-testing.mjs.map +1 -1
  131. package/fesm2022/ngwr-graph.mjs +102 -42
  132. package/fesm2022/ngwr-graph.mjs.map +1 -1
  133. package/fesm2022/ngwr-hotkey.mjs +6 -6
  134. package/fesm2022/ngwr-i18n-ar.mjs +19 -4
  135. package/fesm2022/ngwr-i18n-ar.mjs.map +1 -1
  136. package/fesm2022/ngwr-i18n-cs.mjs +19 -4
  137. package/fesm2022/ngwr-i18n-cs.mjs.map +1 -1
  138. package/fesm2022/ngwr-i18n-de.mjs +19 -4
  139. package/fesm2022/ngwr-i18n-de.mjs.map +1 -1
  140. package/fesm2022/ngwr-i18n-en.mjs +19 -4
  141. package/fesm2022/ngwr-i18n-en.mjs.map +1 -1
  142. package/fesm2022/ngwr-i18n-es.mjs +19 -4
  143. package/fesm2022/ngwr-i18n-es.mjs.map +1 -1
  144. package/fesm2022/ngwr-i18n-fr.mjs +19 -4
  145. package/fesm2022/ngwr-i18n-fr.mjs.map +1 -1
  146. package/fesm2022/ngwr-i18n-he.mjs +19 -4
  147. package/fesm2022/ngwr-i18n-he.mjs.map +1 -1
  148. package/fesm2022/ngwr-i18n-hi.mjs +19 -4
  149. package/fesm2022/ngwr-i18n-hi.mjs.map +1 -1
  150. package/fesm2022/ngwr-i18n-id.mjs +19 -4
  151. package/fesm2022/ngwr-i18n-id.mjs.map +1 -1
  152. package/fesm2022/ngwr-i18n-it.mjs +19 -4
  153. package/fesm2022/ngwr-i18n-it.mjs.map +1 -1
  154. package/fesm2022/ngwr-i18n-ja.mjs +19 -4
  155. package/fesm2022/ngwr-i18n-ja.mjs.map +1 -1
  156. package/fesm2022/ngwr-i18n-ko.mjs +19 -4
  157. package/fesm2022/ngwr-i18n-ko.mjs.map +1 -1
  158. package/fesm2022/ngwr-i18n-nl.mjs +19 -4
  159. package/fesm2022/ngwr-i18n-nl.mjs.map +1 -1
  160. package/fesm2022/ngwr-i18n-pl.mjs +19 -4
  161. package/fesm2022/ngwr-i18n-pl.mjs.map +1 -1
  162. package/fesm2022/ngwr-i18n-pt.mjs +19 -4
  163. package/fesm2022/ngwr-i18n-pt.mjs.map +1 -1
  164. package/fesm2022/ngwr-i18n-ru.mjs +19 -4
  165. package/fesm2022/ngwr-i18n-ru.mjs.map +1 -1
  166. package/fesm2022/ngwr-i18n-sv.mjs +19 -4
  167. package/fesm2022/ngwr-i18n-sv.mjs.map +1 -1
  168. package/fesm2022/ngwr-i18n-tr.mjs +19 -4
  169. package/fesm2022/ngwr-i18n-tr.mjs.map +1 -1
  170. package/fesm2022/ngwr-i18n-uk.mjs +19 -4
  171. package/fesm2022/ngwr-i18n-uk.mjs.map +1 -1
  172. package/fesm2022/ngwr-i18n-vi.mjs +19 -4
  173. package/fesm2022/ngwr-i18n-vi.mjs.map +1 -1
  174. package/fesm2022/ngwr-i18n-zh-tw.mjs +19 -4
  175. package/fesm2022/ngwr-i18n-zh-tw.mjs.map +1 -1
  176. package/fesm2022/ngwr-i18n-zh.mjs +19 -4
  177. package/fesm2022/ngwr-i18n-zh.mjs.map +1 -1
  178. package/fesm2022/ngwr-i18n.mjs +9 -9
  179. package/fesm2022/ngwr-icon.mjs +6 -6
  180. package/fesm2022/ngwr-image-cropper.mjs +3 -3
  181. package/fesm2022/ngwr-input-number-testing.mjs +11 -0
  182. package/fesm2022/ngwr-input-number-testing.mjs.map +1 -1
  183. package/fesm2022/ngwr-input-number.mjs +68 -7
  184. package/fesm2022/ngwr-input-number.mjs.map +1 -1
  185. package/fesm2022/ngwr-input-otp.mjs +23 -3
  186. package/fesm2022/ngwr-input-otp.mjs.map +1 -1
  187. package/fesm2022/ngwr-input-testing.mjs +24 -1
  188. package/fesm2022/ngwr-input-testing.mjs.map +1 -1
  189. package/fesm2022/ngwr-input.mjs +152 -36
  190. package/fesm2022/ngwr-input.mjs.map +1 -1
  191. package/fesm2022/ngwr-keyboard.mjs +3 -3
  192. package/fesm2022/ngwr-knob.mjs +3 -3
  193. package/fesm2022/ngwr-layout.mjs +15 -15
  194. package/fesm2022/ngwr-lightbox.mjs +8 -8
  195. package/fesm2022/ngwr-lightbox.mjs.map +1 -1
  196. package/fesm2022/ngwr-list.mjs +8 -8
  197. package/fesm2022/ngwr-list.mjs.map +1 -1
  198. package/fesm2022/ngwr-load-state.mjs +15 -15
  199. package/fesm2022/ngwr-loading-bar.mjs +6 -6
  200. package/fesm2022/ngwr-mention.mjs +6 -6
  201. package/fesm2022/ngwr-meta.mjs +6 -6
  202. package/fesm2022/ngwr-overlay.mjs +175 -13
  203. package/fesm2022/ngwr-overlay.mjs.map +1 -1
  204. package/fesm2022/ngwr-page-header.mjs +3 -3
  205. package/fesm2022/ngwr-pagination.mjs +5 -3
  206. package/fesm2022/ngwr-pagination.mjs.map +1 -1
  207. package/fesm2022/ngwr-pipes.mjs +31 -29
  208. package/fesm2022/ngwr-pipes.mjs.map +1 -1
  209. package/fesm2022/ngwr-platform.mjs +9 -9
  210. package/fesm2022/ngwr-popconfirm-testing.mjs +5 -2
  211. package/fesm2022/ngwr-popconfirm-testing.mjs.map +1 -1
  212. package/fesm2022/ngwr-popconfirm.mjs +44 -63
  213. package/fesm2022/ngwr-popconfirm.mjs.map +1 -1
  214. package/fesm2022/ngwr-popover-testing.mjs +7 -1
  215. package/fesm2022/ngwr-popover-testing.mjs.map +1 -1
  216. package/fesm2022/ngwr-popover.mjs +58 -156
  217. package/fesm2022/ngwr-popover.mjs.map +1 -1
  218. package/fesm2022/ngwr-progress.mjs +50 -9
  219. package/fesm2022/ngwr-progress.mjs.map +1 -1
  220. package/fesm2022/ngwr-pull-to-refresh-testing.mjs +57 -0
  221. package/fesm2022/ngwr-pull-to-refresh-testing.mjs.map +1 -0
  222. package/fesm2022/ngwr-pull-to-refresh.mjs +3 -3
  223. package/fesm2022/ngwr-qr.mjs +3 -3
  224. package/fesm2022/ngwr-radio.mjs +6 -6
  225. package/fesm2022/ngwr-rating.mjs +3 -3
  226. package/fesm2022/ngwr-resizable-testing.mjs +113 -0
  227. package/fesm2022/ngwr-resizable-testing.mjs.map +1 -0
  228. package/fesm2022/ngwr-resizable.mjs +3 -3
  229. package/fesm2022/ngwr-result.mjs +12 -12
  230. package/fesm2022/ngwr-schema-form-testing.mjs +336 -0
  231. package/fesm2022/ngwr-schema-form-testing.mjs.map +1 -0
  232. package/fesm2022/ngwr-schema-form.mjs +415 -19
  233. package/fesm2022/ngwr-schema-form.mjs.map +1 -1
  234. package/fesm2022/ngwr-scroll.mjs +3 -3
  235. package/fesm2022/ngwr-segmented.mjs +3 -3
  236. package/fesm2022/ngwr-select-testing.mjs +19 -0
  237. package/fesm2022/ngwr-select-testing.mjs.map +1 -1
  238. package/fesm2022/ngwr-select.mjs +263 -83
  239. package/fesm2022/ngwr-select.mjs.map +1 -1
  240. package/fesm2022/ngwr-sidebar-testing.mjs +176 -0
  241. package/fesm2022/ngwr-sidebar-testing.mjs.map +1 -0
  242. package/fesm2022/ngwr-sidebar.mjs +3 -3
  243. package/fesm2022/ngwr-skeleton.mjs +3 -3
  244. package/fesm2022/ngwr-slider-testing.mjs +6 -0
  245. package/fesm2022/ngwr-slider-testing.mjs.map +1 -1
  246. package/fesm2022/ngwr-slider.mjs +21 -3
  247. package/fesm2022/ngwr-slider.mjs.map +1 -1
  248. package/fesm2022/ngwr-sortable-list.mjs +29 -12
  249. package/fesm2022/ngwr-sortable-list.mjs.map +1 -1
  250. package/fesm2022/ngwr-speed-dial.mjs +3 -3
  251. package/fesm2022/ngwr-spinner.mjs +3 -3
  252. package/fesm2022/ngwr-splitter.mjs +3 -3
  253. package/fesm2022/ngwr-statistic.mjs +9 -9
  254. package/fesm2022/ngwr-stepper.mjs +42 -11
  255. package/fesm2022/ngwr-stepper.mjs.map +1 -1
  256. package/fesm2022/ngwr-storage.mjs +3 -3
  257. package/fesm2022/ngwr-switch.mjs +3 -3
  258. package/fesm2022/ngwr-table-testing.mjs +88 -2
  259. package/fesm2022/ngwr-table-testing.mjs.map +1 -1
  260. package/fesm2022/ngwr-table.mjs +891 -74
  261. package/fesm2022/ngwr-table.mjs.map +1 -1
  262. package/fesm2022/ngwr-tabs-router.mjs +3 -3
  263. package/fesm2022/ngwr-tabs-testing.mjs +1 -1
  264. package/fesm2022/ngwr-tabs-testing.mjs.map +1 -1
  265. package/fesm2022/ngwr-tabs.mjs +15 -10
  266. package/fesm2022/ngwr-tabs.mjs.map +1 -1
  267. package/fesm2022/ngwr-textarea-testing.mjs +11 -0
  268. package/fesm2022/ngwr-textarea-testing.mjs.map +1 -1
  269. package/fesm2022/ngwr-textarea.mjs +128 -16
  270. package/fesm2022/ngwr-textarea.mjs.map +1 -1
  271. package/fesm2022/ngwr-theme.mjs +3 -3
  272. package/fesm2022/ngwr-timeline.mjs +6 -6
  273. package/fesm2022/ngwr-toast.mjs +40 -19
  274. package/fesm2022/ngwr-toast.mjs.map +1 -1
  275. package/fesm2022/ngwr-toolbar.mjs +3 -3
  276. package/fesm2022/ngwr-tour.mjs +6 -6
  277. package/fesm2022/ngwr-transfer-testing.mjs +6 -0
  278. package/fesm2022/ngwr-transfer-testing.mjs.map +1 -1
  279. package/fesm2022/ngwr-transfer.mjs +24 -5
  280. package/fesm2022/ngwr-transfer.mjs.map +1 -1
  281. package/fesm2022/ngwr-tree-testing.mjs +62 -2
  282. package/fesm2022/ngwr-tree-testing.mjs.map +1 -1
  283. package/fesm2022/ngwr-tree.mjs +966 -78
  284. package/fesm2022/ngwr-tree.mjs.map +1 -1
  285. package/fesm2022/ngwr-typography.mjs +3 -3
  286. package/fesm2022/ngwr-utils-router.mjs +3 -3
  287. package/fesm2022/ngwr-utils.mjs +34 -1
  288. package/fesm2022/ngwr-utils.mjs.map +1 -1
  289. package/fesm2022/ngwr-version.mjs +1 -1
  290. package/fesm2022/ngwr-version.mjs.map +1 -1
  291. package/fesm2022/ngwr-virtual-scroll.mjs +3 -3
  292. package/fesm2022/ngwr-window.mjs +33 -22
  293. package/fesm2022/ngwr-window.mjs.map +1 -1
  294. package/file-upload/styles/_index.scss +156 -0
  295. package/i18n/ar.json +21 -4
  296. package/i18n/cs.json +21 -4
  297. package/i18n/de.json +21 -4
  298. package/i18n/en.json +21 -4
  299. package/i18n/es.json +21 -4
  300. package/i18n/fr.json +21 -4
  301. package/i18n/he.json +21 -4
  302. package/i18n/hi.json +21 -4
  303. package/i18n/id.json +21 -4
  304. package/i18n/it.json +21 -4
  305. package/i18n/ja.json +21 -4
  306. package/i18n/ko.json +21 -4
  307. package/i18n/nl.json +21 -4
  308. package/i18n/pl.json +21 -4
  309. package/i18n/pt.json +21 -4
  310. package/i18n/ru.json +21 -4
  311. package/i18n/sv.json +21 -4
  312. package/i18n/tr.json +21 -4
  313. package/i18n/uk.json +21 -4
  314. package/i18n/vi.json +21 -4
  315. package/i18n/zh-TW.json +21 -4
  316. package/i18n/zh.json +21 -4
  317. package/input/styles/_index.scss +68 -1
  318. package/input-otp/styles/_index.scss +14 -0
  319. package/llms-full.txt +52 -20
  320. package/overlay/styles/_arrow.scss +4 -4
  321. package/package.json +33 -1
  322. package/popconfirm/styles/_index.scss +3 -11
  323. package/progress/styles/_index.scss +32 -0
  324. package/schema-form/styles/_index.scss +78 -0
  325. package/schematics/use/rule.js +2 -0
  326. package/schematics/use/symbol-map.json +4 -0
  327. package/select/styles/_index.scss +114 -22
  328. package/skills/ngwr/SKILL.md +1 -1
  329. package/skills/ngwr/references/catalog.md +9 -1
  330. package/slider/styles/_index.scss +22 -0
  331. package/table/styles/_index.scss +167 -3
  332. package/textarea/styles/_index.scss +80 -0
  333. package/theme/styles/_focus.scss +5 -0
  334. package/theme/styles/_motion.scss +5 -0
  335. package/transfer/styles/_index.scss +84 -0
  336. package/tree/styles/_index.scss +138 -5
  337. package/types/ngwr-alert-testing.d.ts +88 -0
  338. package/types/ngwr-badge.d.ts +72 -2
  339. package/types/ngwr-breadcrumbs-testing.d.ts +92 -0
  340. package/types/ngwr-burger-testing.d.ts +51 -0
  341. package/types/ngwr-calendar-testing.d.ts +18 -6
  342. package/types/ngwr-calendar.d.ts +272 -22
  343. package/types/ngwr-cascader.d.ts +10 -1
  344. package/types/ngwr-charts-chart-legend.d.ts +9 -4
  345. package/types/ngwr-charts-line-chart-testing.d.ts +4 -1
  346. package/types/ngwr-charts-line-chart.d.ts +7 -4
  347. package/types/ngwr-color-picker-testing.d.ts +15 -4
  348. package/types/ngwr-color-picker.d.ts +76 -6
  349. package/types/ngwr-compare-testing.d.ts +72 -0
  350. package/types/ngwr-date-picker-testing.d.ts +23 -8
  351. package/types/ngwr-date-picker.d.ts +100 -9
  352. package/types/ngwr-date.d.ts +71 -1
  353. package/types/ngwr-drawer.d.ts +9 -0
  354. package/types/ngwr-dropdown-testing.d.ts +20 -0
  355. package/types/ngwr-dropdown.d.ts +24 -6
  356. package/types/ngwr-event-calendar.d.ts +66 -8
  357. package/types/ngwr-file-upload-testing.d.ts +31 -2
  358. package/types/ngwr-file-upload.d.ts +148 -1
  359. package/types/ngwr-form.d.ts +47 -3
  360. package/types/ngwr-graph-testing.d.ts +8 -3
  361. package/types/ngwr-graph.d.ts +147 -7
  362. package/types/ngwr-input-number-testing.d.ts +10 -0
  363. package/types/ngwr-input-number.d.ts +30 -1
  364. package/types/ngwr-input-otp.d.ts +10 -0
  365. package/types/ngwr-input-testing.d.ts +30 -0
  366. package/types/ngwr-input.d.ts +54 -3
  367. package/types/ngwr-overlay.d.ts +84 -5
  368. package/types/ngwr-pipes.d.ts +2 -1
  369. package/types/ngwr-popconfirm-testing.d.ts +12 -3
  370. package/types/ngwr-popconfirm.d.ts +28 -3
  371. package/types/ngwr-popover-testing.d.ts +19 -2
  372. package/types/ngwr-popover.d.ts +22 -2
  373. package/types/ngwr-progress.d.ts +29 -1
  374. package/types/ngwr-pull-to-refresh-testing.d.ts +83 -0
  375. package/types/ngwr-resizable-testing.d.ts +116 -0
  376. package/types/ngwr-schema-form-testing.d.ts +260 -0
  377. package/types/ngwr-schema-form.d.ts +76 -6
  378. package/types/ngwr-select-testing.d.ts +20 -0
  379. package/types/ngwr-select.d.ts +112 -11
  380. package/types/ngwr-sidebar-testing.d.ts +176 -0
  381. package/types/ngwr-slider-testing.d.ts +3 -1
  382. package/types/ngwr-slider.d.ts +21 -1
  383. package/types/ngwr-sortable-list.d.ts +6 -0
  384. package/types/ngwr-stepper.d.ts +20 -11
  385. package/types/ngwr-table-testing.d.ts +70 -6
  386. package/types/ngwr-table.d.ts +480 -50
  387. package/types/ngwr-tabs-testing.d.ts +14 -17
  388. package/types/ngwr-tabs.d.ts +6 -0
  389. package/types/ngwr-textarea-testing.d.ts +10 -0
  390. package/types/ngwr-textarea.d.ts +48 -2
  391. package/types/ngwr-toast.d.ts +8 -1
  392. package/types/ngwr-transfer-testing.d.ts +3 -0
  393. package/types/ngwr-transfer.d.ts +24 -1
  394. package/types/ngwr-tree-testing.d.ts +65 -1
  395. package/types/ngwr-tree.d.ts +333 -12
  396. package/types/ngwr-utils.d.ts +28 -0
  397. package/types/ngwr-version.d.ts +1 -1
  398. package/types/ngwr-window.d.ts +7 -4
@@ -40,7 +40,7 @@ var WrBytes = class WrBytes {
40
40
  }
41
41
  static ɵfac = i0.ɵɵngDeclareFactory({
42
42
  minVersion: "12.0.0",
43
- version: "22.2.5",
43
+ version: "22.2.6",
44
44
  ngImport: i0,
45
45
  type: WrBytes,
46
46
  deps: [],
@@ -48,7 +48,7 @@ var WrBytes = class WrBytes {
48
48
  });
49
49
  static ɵpipe = i0.ɵɵngDeclarePipe({
50
50
  minVersion: "14.0.0",
51
- version: "22.2.5",
51
+ version: "22.2.6",
52
52
  ngImport: i0,
53
53
  type: WrBytes,
54
54
  isStandalone: true,
@@ -57,7 +57,7 @@ var WrBytes = class WrBytes {
57
57
  };
58
58
  i0.ɵɵngDeclareClassMetadata({
59
59
  minVersion: "12.0.0",
60
- version: "22.2.5",
60
+ version: "22.2.6",
61
61
  ngImport: i0,
62
62
  type: WrBytes,
63
63
  decorators: [{
@@ -79,9 +79,11 @@ function wrFormatBytes(value, locale, decimals = 1) {
79
79
  * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
80
80
  */
81
81
  function wrFormatDate(value, adapter, format = "shortDate", options) {
82
+ const app = adapter.parseOptions();
82
83
  const date = wrParseDate(value, {
83
- ...adapter.parseOptions(),
84
- ...options
84
+ epochUnit: options?.epochUnit ?? app.epochUnit,
85
+ zonelessIn: options?.zonelessIn ?? app.zonelessIn,
86
+ timeZone: options?.timeZone === void 0 ? app.timeZone : options.timeZone
85
87
  });
86
88
  if (date === null) return "";
87
89
  return (wrIsDateOnly(value) ? adapter : adapter.zoned()).format(date, format);
@@ -105,7 +107,7 @@ var WrDate = class WrDate {
105
107
  }
106
108
  static ɵfac = i0.ɵɵngDeclareFactory({
107
109
  minVersion: "12.0.0",
108
- version: "22.2.5",
110
+ version: "22.2.6",
109
111
  ngImport: i0,
110
112
  type: WrDate,
111
113
  deps: [],
@@ -113,7 +115,7 @@ var WrDate = class WrDate {
113
115
  });
114
116
  static ɵpipe = i0.ɵɵngDeclarePipe({
115
117
  minVersion: "14.0.0",
116
- version: "22.2.5",
118
+ version: "22.2.6",
117
119
  ngImport: i0,
118
120
  type: WrDate,
119
121
  isStandalone: true,
@@ -123,7 +125,7 @@ var WrDate = class WrDate {
123
125
  };
124
126
  i0.ɵɵngDeclareClassMetadata({
125
127
  minVersion: "12.0.0",
126
- version: "22.2.5",
128
+ version: "22.2.6",
127
129
  ngImport: i0,
128
130
  type: WrDate,
129
131
  decorators: [{
@@ -226,7 +228,7 @@ var WrDuration = class WrDuration {
226
228
  }
227
229
  static ɵfac = i0.ɵɵngDeclareFactory({
228
230
  minVersion: "12.0.0",
229
- version: "22.2.5",
231
+ version: "22.2.6",
230
232
  ngImport: i0,
231
233
  type: WrDuration,
232
234
  deps: [],
@@ -234,7 +236,7 @@ var WrDuration = class WrDuration {
234
236
  });
235
237
  static ɵpipe = i0.ɵɵngDeclarePipe({
236
238
  minVersion: "14.0.0",
237
- version: "22.2.5",
239
+ version: "22.2.6",
238
240
  ngImport: i0,
239
241
  type: WrDuration,
240
242
  isStandalone: true,
@@ -243,7 +245,7 @@ var WrDuration = class WrDuration {
243
245
  };
244
246
  i0.ɵɵngDeclareClassMetadata({
245
247
  minVersion: "12.0.0",
246
- version: "22.2.5",
248
+ version: "22.2.6",
247
249
  ngImport: i0,
248
250
  type: WrDuration,
249
251
  decorators: [{
@@ -264,7 +266,7 @@ var WrInitials = class WrInitials {
264
266
  }
265
267
  static ɵfac = i0.ɵɵngDeclareFactory({
266
268
  minVersion: "12.0.0",
267
- version: "22.2.5",
269
+ version: "22.2.6",
268
270
  ngImport: i0,
269
271
  type: WrInitials,
270
272
  deps: [],
@@ -272,7 +274,7 @@ var WrInitials = class WrInitials {
272
274
  });
273
275
  static ɵpipe = i0.ɵɵngDeclarePipe({
274
276
  minVersion: "14.0.0",
275
- version: "22.2.5",
277
+ version: "22.2.6",
276
278
  ngImport: i0,
277
279
  type: WrInitials,
278
280
  isStandalone: true,
@@ -281,7 +283,7 @@ var WrInitials = class WrInitials {
281
283
  };
282
284
  i0.ɵɵngDeclareClassMetadata({
283
285
  minVersion: "12.0.0",
284
- version: "22.2.5",
286
+ version: "22.2.6",
285
287
  ngImport: i0,
286
288
  type: WrInitials,
287
289
  decorators: [{
@@ -311,7 +313,7 @@ var WrMark = class WrMark {
311
313
  }
312
314
  static ɵfac = i0.ɵɵngDeclareFactory({
313
315
  minVersion: "12.0.0",
314
- version: "22.2.5",
316
+ version: "22.2.6",
315
317
  ngImport: i0,
316
318
  type: WrMark,
317
319
  deps: [],
@@ -319,7 +321,7 @@ var WrMark = class WrMark {
319
321
  });
320
322
  static ɵpipe = i0.ɵɵngDeclarePipe({
321
323
  minVersion: "14.0.0",
322
- version: "22.2.5",
324
+ version: "22.2.6",
323
325
  ngImport: i0,
324
326
  type: WrMark,
325
327
  isStandalone: true,
@@ -328,7 +330,7 @@ var WrMark = class WrMark {
328
330
  };
329
331
  i0.ɵɵngDeclareClassMetadata({
330
332
  minVersion: "12.0.0",
331
- version: "22.2.5",
333
+ version: "22.2.6",
332
334
  ngImport: i0,
333
335
  type: WrMark,
334
336
  decorators: [{
@@ -372,7 +374,7 @@ var WrNumber = class WrNumber {
372
374
  }
373
375
  static ɵfac = i0.ɵɵngDeclareFactory({
374
376
  minVersion: "12.0.0",
375
- version: "22.2.5",
377
+ version: "22.2.6",
376
378
  ngImport: i0,
377
379
  type: WrNumber,
378
380
  deps: [],
@@ -380,7 +382,7 @@ var WrNumber = class WrNumber {
380
382
  });
381
383
  static ɵpipe = i0.ɵɵngDeclarePipe({
382
384
  minVersion: "14.0.0",
383
- version: "22.2.5",
385
+ version: "22.2.6",
384
386
  ngImport: i0,
385
387
  type: WrNumber,
386
388
  isStandalone: true,
@@ -389,7 +391,7 @@ var WrNumber = class WrNumber {
389
391
  };
390
392
  i0.ɵɵngDeclareClassMetadata({
391
393
  minVersion: "12.0.0",
392
- version: "22.2.5",
394
+ version: "22.2.6",
393
395
  ngImport: i0,
394
396
  type: WrNumber,
395
397
  decorators: [{
@@ -417,7 +419,7 @@ var WrPlural = class WrPlural {
417
419
  }
418
420
  static ɵfac = i0.ɵɵngDeclareFactory({
419
421
  minVersion: "12.0.0",
420
- version: "22.2.5",
422
+ version: "22.2.6",
421
423
  ngImport: i0,
422
424
  type: WrPlural,
423
425
  deps: [],
@@ -425,7 +427,7 @@ var WrPlural = class WrPlural {
425
427
  });
426
428
  static ɵpipe = i0.ɵɵngDeclarePipe({
427
429
  minVersion: "14.0.0",
428
- version: "22.2.5",
430
+ version: "22.2.6",
429
431
  ngImport: i0,
430
432
  type: WrPlural,
431
433
  isStandalone: true,
@@ -434,7 +436,7 @@ var WrPlural = class WrPlural {
434
436
  };
435
437
  i0.ɵɵngDeclareClassMetadata({
436
438
  minVersion: "12.0.0",
437
- version: "22.2.5",
439
+ version: "22.2.6",
438
440
  ngImport: i0,
439
441
  type: WrPlural,
440
442
  decorators: [{
@@ -454,7 +456,7 @@ var WrRange = class WrRange {
454
456
  }
455
457
  static ɵfac = i0.ɵɵngDeclareFactory({
456
458
  minVersion: "12.0.0",
457
- version: "22.2.5",
459
+ version: "22.2.6",
458
460
  ngImport: i0,
459
461
  type: WrRange,
460
462
  deps: [],
@@ -462,7 +464,7 @@ var WrRange = class WrRange {
462
464
  });
463
465
  static ɵpipe = i0.ɵɵngDeclarePipe({
464
466
  minVersion: "14.0.0",
465
- version: "22.2.5",
467
+ version: "22.2.6",
466
468
  ngImport: i0,
467
469
  type: WrRange,
468
470
  isStandalone: true,
@@ -471,7 +473,7 @@ var WrRange = class WrRange {
471
473
  };
472
474
  i0.ɵɵngDeclareClassMetadata({
473
475
  minVersion: "12.0.0",
474
- version: "22.2.5",
476
+ version: "22.2.6",
475
477
  ngImport: i0,
476
478
  type: WrRange,
477
479
  decorators: [{
@@ -502,7 +504,7 @@ var WrTruncate = class WrTruncate {
502
504
  }
503
505
  static ɵfac = i0.ɵɵngDeclareFactory({
504
506
  minVersion: "12.0.0",
505
- version: "22.2.5",
507
+ version: "22.2.6",
506
508
  ngImport: i0,
507
509
  type: WrTruncate,
508
510
  deps: [],
@@ -510,7 +512,7 @@ var WrTruncate = class WrTruncate {
510
512
  });
511
513
  static ɵpipe = i0.ɵɵngDeclarePipe({
512
514
  minVersion: "14.0.0",
513
- version: "22.2.5",
515
+ version: "22.2.6",
514
516
  ngImport: i0,
515
517
  type: WrTruncate,
516
518
  isStandalone: true,
@@ -519,7 +521,7 @@ var WrTruncate = class WrTruncate {
519
521
  };
520
522
  i0.ɵɵngDeclareClassMetadata({
521
523
  minVersion: "12.0.0",
522
- version: "22.2.5",
524
+ version: "22.2.6",
523
525
  ngImport: i0,
524
526
  type: WrTruncate,
525
527
  decorators: [{
@@ -1 +1 @@
1
- {"version":3,"file":"ngwr-pipes.mjs","names":[],"sources":["../../../projects/lib/pipes/bytes.ts","../../../projects/lib/pipes/date.ts","../../../projects/lib/pipes/duration.ts","../../../projects/lib/pipes/initials.ts","../../../projects/lib/pipes/mark.ts","../../../projects/lib/pipes/number.ts","../../../projects/lib/pipes/plural.ts","../../../projects/lib/pipes/range.ts","../../../projects/lib/pipes/truncate.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 { LOCALE_ID, Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\n/**\n * Binary magnitudes, as the `Intl` unit that labels each one. The COUNTING is\n * 1024-based and these names are decimal — which is the same thing the old\n * hand-written `['B', 'KB', 'MB', …]` table did, and what almost every file\n * manager does. Strictly, 1024 bytes is a kibibyte; `Intl` has no unit for it.\n */\nconst UNITS = ['byte', 'kilobyte', 'megabyte', 'gigabyte', 'terabyte', 'petabyte'] as const;\n\n/**\n * `Intl`'s NARROW unit, with one space put back between it and the number.\n *\n * Neither display mode is right on its own. `short` spells the smallest unit\n * as a word — \"512 byte\", \"0 byte\" in English, \"0 Byte\" in German — which is\n * both worse copy than the `B` this pipe has always rendered and a bigger\n * change than the fix is worth. `narrow` gives `B` / `Б` / `o` correctly and\n * then closes the gap: \"1.2kB\".\n *\n * So the parts are reassembled rather than the string. Going through\n * `formatToParts` is what keeps the ORDER the locale's own — Hebrew puts the\n * unit first, and hand-joining `${n} ${unit}` would silently straighten every\n * such locale into English order.\n */\nfunction format(locale: string, value: number, unit: number, fractionDigits: number): string {\n const parts = new Intl.NumberFormat(locale, {\n style: 'unit',\n unit: UNITS[unit],\n unitDisplay: 'narrow',\n minimumFractionDigits: fractionDigits,\n maximumFractionDigits: fractionDigits,\n }).formatToParts(value);\n\n const at = parts.findIndex(part => part.type === 'unit');\n if (at === -1) return parts.map(part => part.value).join('');\n\n const out = parts.map(part => part.value);\n // The slot on the number's side of the unit: already a separator in some\n // locales, absent in others.\n const gap = at === 0 ? 1 : at - 1;\n if (parts[gap]?.type === 'literal') out[gap] = ' ';\n else out.splice(at === 0 ? 1 : at, 0, ' ');\n return out.join('');\n}\n\n/**\n * Humanise a byte count using binary (1024-based) units, in the reader's locale.\n *\n * @example\n * ```html\n * {{ 1234 | wrBytes }} <!-- en: \"1.2 kB\" de: \"1,2 kB\" ru: \"1,2 кБ\" -->\n * {{ 1234567 | wrBytes: 0 }} <!-- en: \"1 MB\" fr: \"1 Mo\" -->\n * {{ 0 | wrBytes }} <!-- en: \"0 B\" ru: \"0 Б\" -->\n * ```\n *\n * **Both halves come from `Intl`, and the unit table is not the catalog's.** The\n * number always did need `LOCALE_ID` — it went through `toFixed`, which writes a\n * full stop in every language, so a German page read `1.2 KB` beside its own\n * `1,2` everywhere else — and the three formatting pipes beside this one\n * (`wrDate`, `wrNumber`, `wrPlural`) had injected it since they shipped.\n *\n * The unit could not follow them into `ngwr/i18n`, and the reason is the pipe\n * rather than the strings: a PURE pipe is re-invoked only when its argument\n * changes, so a catalog that lands after the first render — which is every\n * `provideWrI18nHttpLoader` app — would never reach it, and the pipe would be\n * correct under the static loader and silently English under the other one.\n * `LOCALE_ID` is a constant, so `Intl` has no such failure mode, and it knows\n * every locale ICU ships rather than the twenty-two this package translates.\n *\n * One visible change in English and it is the only one: `KB` became `kB`, which\n * is what CLDR calls that unit. `B`, the space before it and every other\n * magnitude read exactly as they did — see `format` for the part of that which\n * is not free.\n *\n * The other consequence, kept here so nobody rediscovers it as a bug:\n * `<wr-file-upload>` prints its own sizes from `fileUpload.unitKb` and friends,\n * which are public catalog keys a consumer may have overridden, so it renders\n * `KB` where this pipe renders `kB`. Retiring those keys would silently break\n * every override that had been translating them, which is a major-version move.\n *\n * {@link wrFormatBytes} is the same output as a function.\n */\n@Pipe({ name: 'wrBytes' })\nexport class WrBytes implements PipeTransform {\n private readonly locale = inject(LOCALE_ID);\n\n transform(value: number | string | null | undefined, decimals = 1): string {\n return wrFormatBytes(value, this.locale, decimals);\n }\n}\n\n/**\n * A byte count in binary (1024-based) units, in the given locale: the same\n * output as the `wrBytes` pipe, for a string built in TypeScript. `null`,\n * `undefined` and an empty string give an empty string; zero, a negative\n * number and a value that is not a number give `0 B`.\n *\n * @example\n * ```ts\n * wrFormatBytes(1234, 'en-US'); // \"1.2 kB\"\n * wrFormatBytes(1234567, 'fr-FR', 0); // \"1 Mo\"\n * ```\n */\nexport function wrFormatBytes(value: number | string | null | undefined, locale: string, decimals = 1): string {\n if (value === null || value === undefined || value === '') return '';\n const n = Number(value);\n if (!Number.isFinite(n) || n <= 0) return format(locale, 0, 0, 0);\n\n // Floored as well as capped: for `0 < n < 1` the log is negative, so an\n // unclamped index reads `UNITS[-1]` (`undefined`) and divides by `1024 ** -1`,\n // which rendered `0.5` as \"512.0 undefined\".\n const i = Math.min(Math.max(0, Math.floor(Math.log(n) / Math.log(1024))), UNITS.length - 1);\n // Whole bytes never show a fractional part.\n return format(locale, n / 1024 ** i, i, i === 0 ? 0 : Math.max(0, decimals));\n}\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\nimport { Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nimport { type WrDateFormat, type WrParseDateOptions, WrDateAdapter, wrIsDateOnly, wrParseDate } from 'ngwr/date';\n\n/**\n * A date through a `WrDateAdapter`: the same output as the `wrDate` pipe, for a\n * string built in TypeScript. A date-only string (`'2026-01-01'`) is that day in\n * the local zone, as `DatePipe` reads it, and `'2026-01-01 14:30:00'` is read\n * as its `T` form: the value goes through `wrParseDate`. `null`, `undefined`,\n * an empty string and a date the engine refuses give an empty string.\n *\n * An instant is printed on the wall clock of `withDates({ timeZone })`, through\n * the adapter's `zoned()`. A date-only string is a calendar day and is not\n * moved: `'2026-01-01'` prints as 1 January in every zone.\n *\n * The value is read as `withDates()` says: `epochUnit` for a number and\n * `zonelessIn` for a date-time string with no offset. The last argument\n * overrides either for one call, for a field whose unit differs from the app's.\n *\n * The adapter stands where `wrFormatNumber` takes a locale, because the output\n * is the adapter's: the native one formats in `WR_DATE_LOCALE`, and an app's own\n * adapter formats however it formats. Neither can be rebuilt from a locale\n * string, so the caller passes `inject(WrDateAdapter)` once.\n *\n * @example\n * ```ts\n * private readonly dates = inject(WrDateAdapter);\n *\n * wrFormatDate(row.createdAt, this.dates); // shortDate\n * wrFormatDate(row.createdAt, this.dates, 'mediumDateTime'); // named key\n * wrFormatDate(row.createdAt, this.dates, 'dd.MM.yyyy'); // raw token string\n * wrFormatDate(row.sentAt, this.dates, 'time', { epochUnit: 'us' }); // microseconds\n * ```\n */\nexport function wrFormatDate(\n value: Date | string | number | null | undefined,\n adapter: WrDateAdapter<Date>,\n format: WrDateFormat | (string & {}) = 'shortDate',\n options?: WrParseDateOptions\n): string {\n const date = wrParseDate(value, { ...adapter.parseOptions(), ...options });\n if (date === null) return '';\n return (wrIsDateOnly(value) ? adapter : adapter.zoned()).format(date, format);\n}\n\n/**\n * Locale-aware date formatting. Delegates to `WrDateAdapter` — the native one\n * unless the app provides its own — so both the named format keys\n * (`'shortDate'`, `'longDate'`, …) and raw token strings work with nothing to\n * set up. A date-only string (`'2026-01-01'`) is that day in the local zone,\n * as `DatePipe` reads it, not UTC midnight, and a backend's\n * `'2026-01-01 14:30:00'` is read as its `T` form. {@link wrFormatDate} is the\n * same output as a function.\n *\n * An instant is printed in the time zone of `withDates({ timeZone })`, and the\n * output follows that zone and the adapter's locale when they change at\n * runtime. A pure pipe cannot: Angular calls it again only when an argument\n * changes. So the pipe is impure and keeps its last result, and a\n * change-detection pass with nothing new costs three comparisons, not a\n * format.\n *\n * @example\n * ```html\n * {{ now | wrDate }} <!-- shortDate -->\n * {{ now | wrDate: 'mediumDateTime' }} <!-- named key -->\n * {{ now | wrDate: 'dd.MM.yyyy' }} <!-- raw token string -->\n * {{ sentAt | wrDate: 'time' : { epochUnit: 'us' } }} <!-- microseconds -->\n * ```\n */\n// eslint-disable-next-line @angular-eslint/no-pipe-impure -- a pure pipe cannot follow the zone or the locale; see above\n@Pipe({ name: 'wrDate', pure: false })\nexport class WrDate implements PipeTransform {\n private readonly adapter = inject<WrDateAdapter<Date>>(WrDateAdapter);\n\n private value: unknown;\n private format = '';\n private key: string | null = null;\n private text = '';\n\n transform(\n value: Date | string | number | null | undefined,\n format: WrDateFormat | (string & {}) = 'shortDate',\n options?: WrParseDateOptions\n ): string {\n // A signal read on the native adapter, which is what makes the template run\n // again when the zone or the locale moves.\n const display = this.adapter.zoned().displayKey();\n const key = options ? `${display}|${options.epochUnit}|${options.zonelessIn}|${options.timeZone}` : display;\n if (key !== this.key || format !== this.format || !Object.is(value, this.value)) {\n this.text = wrFormatDate(value, this.adapter, format, options);\n this.value = value;\n this.format = format;\n this.key = key;\n }\n return this.text;\n }\n}\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\nimport { LOCALE_ID, Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nimport type { WrDurationStyle, WrDurationUnit } from './types';\n\n/** Each unit's length in milliseconds, largest first. */\nconst UNIT_MS: readonly (readonly [WrDurationUnit, number])[] = [\n ['day', 86_400_000],\n ['hour', 3_600_000],\n ['minute', 60_000],\n ['second', 1000],\n ['millisecond', 1],\n];\n\nconst CLOCK_UNITS: ReadonlySet<WrDurationUnit> = new Set(['hour', 'minute', 'second']);\nconst LIST_UNITS: ReadonlySet<WrDurationUnit> = new Set(['day', 'hour', 'minute', 'second']);\n\nfunction formatClock(ms: number, locale: string): string {\n const { hour = 0, minute = 0, second = 0 } = wrSplitDuration(ms, CLOCK_UNITS);\n const digits = (n: number, width: number): string =>\n new Intl.NumberFormat(locale, { useGrouping: false, minimumIntegerDigits: width }).format(n);\n const tail = `${digits(minute, hour > 0 ? 2 : 1)}:${digits(second, 2)}`;\n return hour > 0 ? `${digits(hour, 1)}:${tail}` : tail;\n}\n\nfunction formatTimer(ms: number, locale: string): string {\n const { day = 0, hour = 0, minute = 0, second = 0 } = wrSplitDuration(ms, LIST_UNITS);\n const two = new Intl.NumberFormat(locale, { useGrouping: false, minimumIntegerDigits: 2 });\n const clock = [hour, minute, second].map(n => two.format(n)).join(':');\n if (day === 0) return clock;\n const days = new Intl.NumberFormat(locale, { style: 'unit', unit: 'day', unitDisplay: 'narrow' }).format(day);\n return `${days} ${clock}`;\n}\n\nfunction formatUnits(ms: number, locale: string): string {\n const parts = wrSplitDuration(ms, LIST_UNITS);\n const unit = (name: WrDurationUnit, n: number): string =>\n new Intl.NumberFormat(locale, { style: 'unit', unit: name, unitDisplay: 'short' }).format(n);\n\n const words = (Object.entries(parts) as [WrDurationUnit, number][])\n .filter(([, n]) => n > 0)\n .map(([name, n]) => unit(name, n));\n if (words.length === 0) return unit('second', 0);\n return new Intl.ListFormat(locale, { style: 'narrow', type: 'unit' }).format(words);\n}\n\n/**\n * Split a span of milliseconds into the units asked for. A unit left out is\n * carried into the next larger one that is kept, so `['hour', 'minute',\n * 'second']` over three days and an hour reads 73 hours; the smallest unit kept\n * floors whatever remains. Shared with `wr-statistic-countdown`, whose format\n * tokens pick the units.\n *\n * @internal\n */\nexport function wrSplitDuration(\n ms: number,\n units: ReadonlySet<WrDurationUnit>\n): Readonly<Partial<Record<WrDurationUnit, number>>> {\n const out: Partial<Record<WrDurationUnit, number>> = {};\n let rest = ms;\n for (const [unit, size] of UNIT_MS) {\n if (!units.has(unit)) continue;\n const n = Math.floor(rest / size);\n out[unit] = n;\n rest -= n * size;\n }\n return out;\n}\n\n/**\n * A span of milliseconds as text, in the given locale.\n *\n * Three styles. `'clock'` is digits and colons: `1:30:00`, and `5:07` under an\n * hour; days are carried into the hours, since a clock has no day digit, so two\n * days read `48:00:00`. `'units'` is every non-zero unit as a word the locale\n * writes, `1 hr 30 min` in English and `1 h 30 min` in French, through\n * `Intl.NumberFormat`'s unit style and `Intl.ListFormat` — `Intl.DurationFormat`\n * is above the browser floor. `'timer'` is what an elapsed-time counter shows:\n * always `HH:mm:ss`, each field two digits, `01:02:03` and `00:05:07`; from a\n * day on, the days stand in front as the locale's narrow unit, `1d 02:03:04`.\n * The digits are the locale's own in every style.\n *\n * A span is not an instant: no style reads a time zone, so the output is the\n * same wherever it runs. Formatting an elapsed time as a date would add the\n * display zone's offset to it.\n *\n * Whole seconds: a fraction of a second is floored in every style. Zero reads\n * `0:00`, `0 sec` and `00:00:00`. A negative span is its absolute value with\n * the locale's minus sign in front, `-5:07` and `-00:05:07`. `null`, `undefined`, an empty string and a value\n * that is not a finite number give an empty string, as `wrFormatNumber` does.\n *\n * The same output as the `wrDuration` pipe, for a string built in TypeScript.\n *\n * @example\n * ```ts\n * wrFormatDuration(5_400_000, 'en-US'); // \"1:30:00\"\n * wrFormatDuration(5_400_000, 'en-US', 'units'); // \"1 hr 30 min\"\n * wrFormatDuration(307_000, 'fr-FR', 'units'); // \"5 min 7 s\"\n * wrFormatDuration(3_723_000, 'en-US', 'timer'); // \"01:02:03\"\n * wrFormatDuration(93_784_000, 'en-US', 'timer'); // \"1d 02:03:04\"\n * ```\n */\nexport function wrFormatDuration(\n value: number | string | null | undefined,\n locale: string,\n style: WrDurationStyle = 'clock'\n): string {\n if (value === null || value === undefined || value === '') return '';\n const ms = Number(typeof value === 'string' ? value.trim() : value);\n if (!Number.isFinite(ms)) return '';\n\n const span = Math.abs(ms);\n const body =\n style === 'units'\n ? formatUnits(span, locale)\n : style === 'timer'\n ? formatTimer(span, locale)\n : formatClock(span, locale);\n // A span that floors to zero carries no sign: `-0:00` states nothing.\n if (ms >= 0 || span < 1000) return body;\n\n const minus = new Intl.NumberFormat(locale).formatToParts(-1).find(part => part.type === 'minusSign');\n return `${minus?.value ?? '-'}${body}`;\n}\n\n/**\n * A span of milliseconds as clock digits, as units or as a timer, in Angular's\n * `LOCALE_ID`. See {@link wrFormatDuration} for the three styles and the edge\n * cases.\n *\n * @example\n * ```html\n * {{ 5400000 | wrDuration }} <!-- \"1:30:00\" -->\n * {{ 5400000 | wrDuration: 'units' }} <!-- \"1 hr 30 min\" -->\n * {{ 307000 | wrDuration }} <!-- \"5:07\" -->\n * {{ 3723000 | wrDuration: 'timer' }} <!-- \"01:02:03\" -->\n * ```\n */\n@Pipe({ name: 'wrDuration' })\nexport class WrDuration implements PipeTransform {\n private readonly locale = inject(LOCALE_ID);\n\n transform(value: number | string | null | undefined, style: WrDurationStyle = 'clock'): string {\n return wrFormatDuration(value, this.locale, style);\n }\n}\n\nexport type { WrDurationStyle, WrDurationUnit } from './types';\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\nimport { LOCALE_ID, Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nimport { wrInitials } from 'ngwr/utils';\n\n/**\n * Up to two initials of a name: `wrInitials()` from `ngwr/utils`, upper-cased\n * in `LOCALE_ID`.\n *\n * @example\n * ```html\n * {{ 'Roman Khegay' | wrInitials }} <!-- \"RK\" -->\n * {{ 'madonna' | wrInitials }} <!-- \"M\" -->\n * {{ '王小明' | wrInitials }} <!-- \"王\" -->\n * ```\n *\n * @see https://ngwr.dev/reference/pipes/wr-initials\n */\n@Pipe({ name: 'wrInitials' })\nexport class WrInitials implements PipeTransform {\n private readonly locale = inject(LOCALE_ID);\n\n transform(value: string | null | undefined): string {\n return wrInitials(value, this.locale);\n }\n}\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\nimport { Pipe, type PipeTransform, inject } from '@angular/core';\nimport { DomSanitizer, type SafeHtml } from '@angular/platform-browser';\n\n/** Escapes RegExp metacharacters so user input is safe to inline. @internal */\nconst RE_META = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** HTML-entities for the four chars that matter inside our `<mark>` wrap. @internal */\nfunction escapeHtml(s: string): string {\n return s.replace(/&/g, '&amp;').replace(/</g, '&lt;').replace(/>/g, '&gt;').replace(/\"/g, '&quot;');\n}\n\n/**\n * Wrap every occurrence of `query` in `<mark>` tags. Useful for highlighting\n * search-term matches in autocomplete results, lists, and table cells.\n *\n * The output is `SafeHtml` — bind with `[innerHTML]`. Input is escaped first\n * so user-supplied values can't inject markup.\n *\n * @example\n * ```html\n * <span [innerHTML]=\"row.name | wrMark: query()\"></span>\n *\n * <!-- Case-sensitive: -->\n * <span [innerHTML]=\"row.name | wrMark: query() : true\"></span>\n * ```\n */\n@Pipe({ name: 'wrMark' })\nexport class WrMark implements PipeTransform {\n private readonly sanitizer = inject(DomSanitizer);\n\n /**\n * @param value Source text.\n * @param query Search term to highlight. Empty/null skips the wrap.\n * @param caseSensitive Match exactly. @default false\n */\n transform(value: string | null | undefined, query: string | null | undefined, caseSensitive = false): SafeHtml {\n if (value === null || value === undefined) return '';\n const text = String(value);\n // Escaped on this path too. The output is bound with `[innerHTML]`, so\n // handing back the raw string let markup in `value` render as elements the\n // moment the search box was cleared — the same value drawn as text while a\n // query was typed, as an `<img>` when it was not.\n if (!query) return escapeHtml(text);\n\n // Match the RAW text and escape the pieces afterwards, never the other way\n // round. Escaping first rewrites `&` as `&amp;`, and a query of `m` then lands\n // INSIDE that entity: the `<mark>` splits it and the browser paints the\n // entity's own letters, so `Tom & Jerry` renders as `Tom &amp; Jerry`. The\n // mirror failure is a match that can never happen — `<`, `>` and `\"` no longer\n // exist in escaped text. The pipe's promise is untouched: every piece that came\n // from `value` still goes through `escapeHtml`, matched or not, so the only\n // tags in the output are the `<mark>`s built here.\n const pattern = new RegExp(`(${query.replace(RE_META, '\\\\$&')})`, caseSensitive ? 'g' : 'gi');\n const html = text\n .split(pattern)\n .map((part, index) => (index % 2 ? `<mark>${escapeHtml(part)}</mark>` : escapeHtml(part)))\n .join('');\n\n return this.sanitizer.bypassSecurityTrustHtml(html);\n }\n}\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\nimport { LOCALE_ID, Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nimport type { WrNumberStyle } from './types';\n\n/** Digits with one optional point and a sign: the form `Intl` reads exactly. */\nconst PLAIN_DECIMAL = /^[+-]?(?:\\d+\\.?\\d*|\\.\\d+)$/;\n\nfunction toOptions(style: WrNumberStyle, currency: string): Intl.NumberFormatOptions {\n switch (style) {\n case 'percent':\n return { style: 'percent', maximumFractionDigits: 2 };\n case 'currency':\n return { style: 'currency', currency };\n case 'decimal':\n default:\n return { style: 'decimal' };\n }\n}\n\n/**\n * A number through `Intl.NumberFormat`, in the given locale: the same output as\n * the `wrNumber` pipe, for a string built in TypeScript. Takes a style shortcut\n * (with an optional currency code) or a full `Intl.NumberFormatOptions` object.\n * `null`, `undefined`, an empty string and a value that is not a finite number\n * give an empty string.\n *\n * @example\n * ```ts\n * wrFormatNumber(1234.5, 'en-US'); // \"1,234.5\"\n * wrFormatNumber(0.875, 'en-US', 'percent'); // \"87.5%\"\n * wrFormatNumber(19.99, 'de-DE', 'currency', 'EUR'); // \"19,99 €\"\n * wrFormatNumber(19.99, 'en-US', { minimumFractionDigits: 2 });\n * ```\n */\nexport function wrFormatNumber(\n value: number | string | null | undefined,\n locale: string,\n styleOrOptions: WrNumberStyle | Intl.NumberFormatOptions = 'decimal',\n currency = 'USD'\n): string {\n if (value === null || value === undefined || value === '') return '';\n const text = typeof value === 'string' ? value.trim() : null;\n const n = Number(text ?? value);\n if (!Number.isFinite(n)) return '';\n\n const options: Intl.NumberFormatOptions =\n typeof styleOrOptions === 'string' ? toOptions(styleOrOptions, currency) : styleOrOptions;\n\n // A plain decimal string goes to `Intl` as it is: through `Number()`,\n // `'12345678901234567.89'` printed as `12,345,678,901,234,568`. Any other\n // form keeps the number, since ICU throws on an exponent of a billion or more.\n // `format()` has read a string since ES2023 (Chrome 106, Firefox 116, Safari\n // 15.4); the ES2022 lib this builds against types it as a number only.\n const exact = text !== null && PLAIN_DECIMAL.test(text) ? (text as unknown as number) : n;\n return new Intl.NumberFormat(locale, options).format(exact);\n}\n\n/**\n * Locale-aware number formatting via `Intl.NumberFormat`. Uses Angular's\n * `LOCALE_ID` as the default locale.\n *\n * Accepts either a style shortcut (with optional currency code) or a full\n * `Intl.NumberFormatOptions` object for fine-grained control.\n * {@link wrFormatNumber} is the same output as a function.\n *\n * @example\n * ```html\n * {{ 1234.5 | wrNumber }} <!-- \"1,234.5\" -->\n * {{ 0.875 | wrNumber: 'percent' }} <!-- \"87.5%\" -->\n * {{ 19.99 | wrNumber: 'currency': 'USD' }} <!-- \"$19.99\" -->\n * {{ 19.99 | wrNumber: { minimumFractionDigits: 2 } }}\n * ```\n */\n@Pipe({ name: 'wrNumber' })\nexport class WrNumber implements PipeTransform {\n private readonly locale = inject(LOCALE_ID);\n\n transform(\n value: number | string | null | undefined,\n styleOrOptions: WrNumberStyle | Intl.NumberFormatOptions = 'decimal',\n currency = 'USD'\n ): string {\n return wrFormatNumber(value, this.locale, styleOrOptions, currency);\n }\n}\n\nexport type { WrNumberStyle } from './types';\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\nimport { LOCALE_ID, Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nimport type { WrPluralForms, WrPluralOptions } from './types';\n\n/**\n * A count and its word form through `Intl.PluralRules`, in the given locale:\n * the same output as the `wrPlural` pipe, for a string built in TypeScript.\n * `options.locale` still wins over `locale`, as it wins over `LOCALE_ID` in the\n * pipe. `null`, `undefined` and a value that is not a finite number give an\n * empty string.\n *\n * @example\n * ```ts\n * wrFormatPlural(1, 'en', { one: 'comment', other: 'comments' }); // \"1 comment\"\n * wrFormatPlural(5, 'ru', { one: 'файл', few: 'файла', other: 'файлов' }); // \"5 файлов\"\n * wrFormatPlural(5, 'en', forms, { includeValue: false }); // \"comments\"\n * ```\n */\nexport function wrFormatPlural(\n value: number | null | undefined,\n locale: string,\n forms: WrPluralForms,\n options: WrPluralOptions = {}\n): string {\n if (value === null || value === undefined || !Number.isFinite(value)) return '';\n const tag = options.locale ?? locale;\n const category = new Intl.PluralRules(tag).select(value);\n const word = forms[category] ?? forms.other;\n if (options.includeValue === false) return word;\n return `${new Intl.NumberFormat(tag).format(value)} ${word}`;\n}\n\n/**\n * Locale-aware pluralization via `Intl.PluralRules`. Picks the right word\n * form for the count — including languages with more than two forms\n * (Russian, Polish, Arabic, …) — without hand-rolled `n % 10` rules.\n *\n * Categories follow CLDR: `zero` / `one` / `two` / `few` / `many` /\n * `other`. Missing categories fall back to `other`. {@link wrFormatPlural} is\n * the same output as a function.\n *\n * @example\n * ```html\n * {{ 1 | wrPlural: { one: 'comment', other: 'comments' } }}\n * <!-- \"1 comment\" -->\n *\n * {{ 5 | wrPlural: { one: 'файл', few: 'файла', other: 'файлов' } }}\n * <!-- \"5 файлов\" (with LOCALE_ID = ru) -->\n *\n * {{ count() | wrPlural: forms : { includeValue: false } }}\n * <!-- word only -->\n * ```\n */\n@Pipe({ name: 'wrPlural' })\nexport class WrPlural implements PipeTransform {\n private readonly locale = inject(LOCALE_ID);\n\n transform(value: number | null | undefined, forms: WrPluralForms, options: WrPluralOptions = {}): string {\n return wrFormatPlural(value, this.locale, forms, options);\n }\n}\n\nexport type { WrPluralForms, WrPluralOptions } from './types';\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\nimport { Pipe } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\n/**\n * Creates an array of sequential indices `[0, 1, 2, ..., n-1]`.\n *\n * Useful for repeating template blocks a fixed number of times.\n *\n * @example\n * ```html\n * @for (i of (5 | wrRange); track i) {\n * <div>Item {{ i }}</div>\n * }\n * ```\n */\n@Pipe({ name: 'wrRange' })\nexport class WrRange implements PipeTransform {\n transform(length: number): number[] {\n return Array.from({ length }, (_, i) => i);\n }\n}\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\nimport { Pipe } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nlet segmenter: Intl.Segmenter | undefined;\n\n/**\n * Clamp a string to `length` characters, appending `ellipsis` when truncated.\n * A character is what a reader sees as one — a grapheme cluster — so an emoji,\n * a flag or a letter with a combining accent is kept whole or dropped whole,\n * never cut into half a surrogate pair that renders as a replacement box.\n *\n * @example\n * ```html\n * {{ 'Hello, world' | wrTruncate: 5 }} <!-- \"Hello…\" -->\n * {{ 'Hello, world' | wrTruncate: 8: '...' }} <!-- \"Hello, w...\" -->\n * ```\n */\n@Pipe({ name: 'wrTruncate' })\nexport class WrTruncate implements PipeTransform {\n transform(value: string | null | undefined, length = 80, ellipsis = '…'): string {\n if (value === null || value === undefined) return '';\n const s = String(value);\n // No more graphemes than UTF-16 units, so a string this short is never cut.\n if (s.length <= length) return s;\n // `slice`'s own coercion of the count, which is what this pipe did before it\n // counted graphemes: a fraction truncates, and NaN or a negative keeps nothing.\n const limit = Math.max(0, Math.trunc(length) || 0);\n segmenter ??= new Intl.Segmenter(undefined, { granularity: 'grapheme' });\n let count = 0;\n for (const { index } of segmenter.segment(s)) {\n if (count === limit) return s.slice(0, index) + ellipsis;\n count++;\n }\n return s;\n }\n}\n"],"mappings":";;;;;;;;;;;AAgBA,MAAM,QAAQ;CAAC;CAAQ;CAAY;CAAY;CAAY;CAAY;AAAU;AAgBjF,SAAS,OAAO,QAAgB,OAAe,MAAc,gBAAsB;CACjF,MAAM,QAAQ,IAAI,KAAK,aAAa,QAAQ;EAC1C,OAAO;EACP,MAAM,MAAM;EACZ,aAAa;EACb,uBAAuB;EACvB,uBAAuB;CACxB,CAAA,CAAC,CAAC,cAAc,KAAK;CAEtB,MAAM,KAAK,MAAM,WAAU,SAAQ,KAAK,SAAS,MAAM;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eJ,IAAa,aAAb,MAAa,WAAU;CACrB,UAAU,OAAkC,SAAS,IAAI,WAAW,KAAG;EACrE,IAAI,UAAU,QAAQ,UAAU,QAAW,OAAO;EAClD,MAAM,IAAI,OAAO,KAAK;EAEtB,IAAI,EAAE,UAAU,QAAQ,OAAO;EAG/B,MAAM,QAAQ,KAAK,IAAI,GAAG,KAAK,MAAM,MAAM,KAAK,CAAC;EACjD,cAAc,IAAI,KAAK,UAAU,QAAW,EAAE,aAAa,WAAU,CAAE;EACvE,IAAI,QAAQ;EACZ,KAAK,MAAM,EAAE,WAAW,UAAU,QAAQ,CAAC,GAAG;GAC5C,IAAI,UAAU,OAAO,OAAO,EAAE,MAAM,GAAG,KAAK,IAAI;GAChD;EACF;EACA,OAAO;CACT;CAhBW,OAAA,OAAA,GAAA,mBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,UAAA;EAAA,MAAA;EAAU,MAAA,CAAA;EAAA,QAAA,GAAA,gBAAA;CAAA,CAAA;CAAV,OAAA,QAAA,GAAA,gBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,UAAA;EAAA,MAAA;EAAU,cAAA;EAAA,MAAA;CAAA,CAAA;;AAAV,GAAA,yBAAA;CAAA,YAAA;CAAA,SAAA;CAAA,UAAA;CAAA,MAAA;CAAU,YAAA,CAAA;EADtB,MAAA;EAAK,MAAA,CAAA,EAAE,MAAM,aAAY,CAAE"}
1
+ {"version":3,"file":"ngwr-pipes.mjs","names":[],"sources":["../../../projects/lib/pipes/bytes.ts","../../../projects/lib/pipes/date.ts","../../../projects/lib/pipes/duration.ts","../../../projects/lib/pipes/initials.ts","../../../projects/lib/pipes/mark.ts","../../../projects/lib/pipes/number.ts","../../../projects/lib/pipes/plural.ts","../../../projects/lib/pipes/range.ts","../../../projects/lib/pipes/truncate.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 { LOCALE_ID, Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\n/**\n * Binary magnitudes, as the `Intl` unit that labels each one. The COUNTING is\n * 1024-based and these names are decimal — which is the same thing the old\n * hand-written `['B', 'KB', 'MB', …]` table did, and what almost every file\n * manager does. Strictly, 1024 bytes is a kibibyte; `Intl` has no unit for it.\n */\nconst UNITS = ['byte', 'kilobyte', 'megabyte', 'gigabyte', 'terabyte', 'petabyte'] as const;\n\n/**\n * `Intl`'s NARROW unit, with one space put back between it and the number.\n *\n * Neither display mode is right on its own. `short` spells the smallest unit\n * as a word — \"512 byte\", \"0 byte\" in English, \"0 Byte\" in German — which is\n * both worse copy than the `B` this pipe has always rendered and a bigger\n * change than the fix is worth. `narrow` gives `B` / `Б` / `o` correctly and\n * then closes the gap: \"1.2kB\".\n *\n * So the parts are reassembled rather than the string. Going through\n * `formatToParts` is what keeps the ORDER the locale's own — Hebrew puts the\n * unit first, and hand-joining `${n} ${unit}` would silently straighten every\n * such locale into English order.\n */\nfunction format(locale: string, value: number, unit: number, fractionDigits: number): string {\n const parts = new Intl.NumberFormat(locale, {\n style: 'unit',\n unit: UNITS[unit],\n unitDisplay: 'narrow',\n minimumFractionDigits: fractionDigits,\n maximumFractionDigits: fractionDigits,\n }).formatToParts(value);\n\n const at = parts.findIndex(part => part.type === 'unit');\n if (at === -1) return parts.map(part => part.value).join('');\n\n const out = parts.map(part => part.value);\n // The slot on the number's side of the unit: already a separator in some\n // locales, absent in others.\n const gap = at === 0 ? 1 : at - 1;\n if (parts[gap]?.type === 'literal') out[gap] = ' ';\n else out.splice(at === 0 ? 1 : at, 0, ' ');\n return out.join('');\n}\n\n/**\n * Humanise a byte count using binary (1024-based) units, in the reader's locale.\n *\n * @example\n * ```html\n * {{ 1234 | wrBytes }} <!-- en: \"1.2 kB\" de: \"1,2 kB\" ru: \"1,2 кБ\" -->\n * {{ 1234567 | wrBytes: 0 }} <!-- en: \"1 MB\" fr: \"1 Mo\" -->\n * {{ 0 | wrBytes }} <!-- en: \"0 B\" ru: \"0 Б\" -->\n * ```\n *\n * **Both halves come from `Intl`, and the unit table is not the catalog's.** The\n * number always did need `LOCALE_ID` — it went through `toFixed`, which writes a\n * full stop in every language, so a German page read `1.2 KB` beside its own\n * `1,2` everywhere else — and the three formatting pipes beside this one\n * (`wrDate`, `wrNumber`, `wrPlural`) had injected it since they shipped.\n *\n * The unit could not follow them into `ngwr/i18n`, and the reason is the pipe\n * rather than the strings: a PURE pipe is re-invoked only when its argument\n * changes, so a catalog that lands after the first render — which is every\n * `provideWrI18nHttpLoader` app — would never reach it, and the pipe would be\n * correct under the static loader and silently English under the other one.\n * `LOCALE_ID` is a constant, so `Intl` has no such failure mode, and it knows\n * every locale ICU ships rather than the twenty-two this package translates.\n *\n * One visible change in English and it is the only one: `KB` became `kB`, which\n * is what CLDR calls that unit. `B`, the space before it and every other\n * magnitude read exactly as they did — see `format` for the part of that which\n * is not free.\n *\n * The other consequence, kept here so nobody rediscovers it as a bug:\n * `<wr-file-upload>` prints its own sizes from `fileUpload.unitKb` and friends,\n * which are public catalog keys a consumer may have overridden, so it renders\n * `KB` where this pipe renders `kB`. Retiring those keys would silently break\n * every override that had been translating them, which is a major-version move.\n *\n * {@link wrFormatBytes} is the same output as a function.\n */\n@Pipe({ name: 'wrBytes' })\nexport class WrBytes implements PipeTransform {\n private readonly locale = inject(LOCALE_ID);\n\n transform(value: number | string | null | undefined, decimals = 1): string {\n return wrFormatBytes(value, this.locale, decimals);\n }\n}\n\n/**\n * A byte count in binary (1024-based) units, in the given locale: the same\n * output as the `wrBytes` pipe, for a string built in TypeScript. `null`,\n * `undefined` and an empty string give an empty string; zero, a negative\n * number and a value that is not a number give `0 B`.\n *\n * @example\n * ```ts\n * wrFormatBytes(1234, 'en-US'); // \"1.2 kB\"\n * wrFormatBytes(1234567, 'fr-FR', 0); // \"1 Mo\"\n * ```\n */\nexport function wrFormatBytes(value: number | string | null | undefined, locale: string, decimals = 1): string {\n if (value === null || value === undefined || value === '') return '';\n const n = Number(value);\n if (!Number.isFinite(n) || n <= 0) return format(locale, 0, 0, 0);\n\n // Floored as well as capped: for `0 < n < 1` the log is negative, so an\n // unclamped index reads `UNITS[-1]` (`undefined`) and divides by `1024 ** -1`,\n // which rendered `0.5` as \"512.0 undefined\".\n const i = Math.min(Math.max(0, Math.floor(Math.log(n) / Math.log(1024))), UNITS.length - 1);\n // Whole bytes never show a fractional part.\n return format(locale, n / 1024 ** i, i, i === 0 ? 0 : Math.max(0, decimals));\n}\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\nimport { Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nimport { type WrDateFormat, type WrParseDateOptions, WrDateAdapter, wrIsDateOnly, wrParseDate } from 'ngwr/date';\n\n/**\n * A date through a `WrDateAdapter`: the same output as the `wrDate` pipe, for a\n * string built in TypeScript. A date-only string (`'2026-01-01'`) is that day in\n * the local zone, as `DatePipe` reads it, and `'2026-01-01 14:30:00'` is read\n * as its `T` form: the value goes through `wrParseDate`. `null`, `undefined`,\n * an empty string and a date the engine refuses give an empty string.\n *\n * An instant is printed on the wall clock of `withDates({ timeZone })`, through\n * the adapter's `zoned()`. A date-only string is a calendar day and is not\n * moved: `'2026-01-01'` prints as 1 January in every zone.\n *\n * The value is read as `withDates()` says: `epochUnit` for a number and\n * `zonelessIn` for a date-time string with no offset. The last argument\n * overrides either for one call, for a field whose unit differs from the app's;\n * a key left `undefined` keeps the app's value.\n *\n * The adapter stands where `wrFormatNumber` takes a locale, because the output\n * is the adapter's: the native one formats in `WR_DATE_LOCALE`, and an app's own\n * adapter formats however it formats. Neither can be rebuilt from a locale\n * string, so the caller passes `inject(WrDateAdapter)` once.\n *\n * @example\n * ```ts\n * private readonly dates = inject(WrDateAdapter);\n *\n * wrFormatDate(row.createdAt, this.dates); // shortDate\n * wrFormatDate(row.createdAt, this.dates, 'mediumDateTime'); // named key\n * wrFormatDate(row.createdAt, this.dates, 'dd.MM.yyyy'); // raw token string\n * wrFormatDate(row.sentAt, this.dates, 'time', { epochUnit: 'us' }); // microseconds\n * ```\n */\nexport function wrFormatDate(\n value: Date | string | number | null | undefined,\n adapter: WrDateAdapter<Date>,\n format: WrDateFormat | (string & {}) = 'shortDate',\n options?: WrParseDateOptions\n): string {\n const app = adapter.parseOptions();\n // Not a spread: a key set to `undefined` would erase the app's value.\n const date = wrParseDate(value, {\n epochUnit: options?.epochUnit ?? app.epochUnit,\n zonelessIn: options?.zonelessIn ?? app.zonelessIn,\n timeZone: options?.timeZone === undefined ? app.timeZone : options.timeZone,\n });\n if (date === null) return '';\n return (wrIsDateOnly(value) ? adapter : adapter.zoned()).format(date, format);\n}\n\n/**\n * Locale-aware date formatting. Delegates to `WrDateAdapter` — the native one\n * unless the app provides its own — so both the named format keys\n * (`'shortDate'`, `'longDate'`, …) and raw token strings work with nothing to\n * set up. A date-only string (`'2026-01-01'`) is that day in the local zone,\n * as `DatePipe` reads it, not UTC midnight, and a backend's\n * `'2026-01-01 14:30:00'` is read as its `T` form. {@link wrFormatDate} is the\n * same output as a function.\n *\n * An instant is printed in the time zone of `withDates({ timeZone })`, and the\n * output follows that zone and the adapter's locale when they change at\n * runtime. A pure pipe cannot: Angular calls it again only when an argument\n * changes. So the pipe is impure and keeps its last result, and a\n * change-detection pass with nothing new costs three comparisons, not a\n * format.\n *\n * @example\n * ```html\n * {{ now | wrDate }} <!-- shortDate -->\n * {{ now | wrDate: 'mediumDateTime' }} <!-- named key -->\n * {{ now | wrDate: 'dd.MM.yyyy' }} <!-- raw token string -->\n * {{ sentAt | wrDate: 'time' : { epochUnit: 'us' } }} <!-- microseconds -->\n * ```\n */\n// eslint-disable-next-line @angular-eslint/no-pipe-impure -- a pure pipe cannot follow the zone or the locale; see above\n@Pipe({ name: 'wrDate', pure: false })\nexport class WrDate implements PipeTransform {\n private readonly adapter = inject<WrDateAdapter<Date>>(WrDateAdapter);\n\n private value: unknown;\n private format = '';\n private key: string | null = null;\n private text = '';\n\n transform(\n value: Date | string | number | null | undefined,\n format: WrDateFormat | (string & {}) = 'shortDate',\n options?: WrParseDateOptions\n ): string {\n // A signal read on the native adapter, which is what makes the template run\n // again when the zone or the locale moves.\n const display = this.adapter.zoned().displayKey();\n const key = options ? `${display}|${options.epochUnit}|${options.zonelessIn}|${options.timeZone}` : display;\n if (key !== this.key || format !== this.format || !Object.is(value, this.value)) {\n this.text = wrFormatDate(value, this.adapter, format, options);\n this.value = value;\n this.format = format;\n this.key = key;\n }\n return this.text;\n }\n}\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\nimport { LOCALE_ID, Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nimport type { WrDurationStyle, WrDurationUnit } from './types';\n\n/** Each unit's length in milliseconds, largest first. */\nconst UNIT_MS: readonly (readonly [WrDurationUnit, number])[] = [\n ['day', 86_400_000],\n ['hour', 3_600_000],\n ['minute', 60_000],\n ['second', 1000],\n ['millisecond', 1],\n];\n\nconst CLOCK_UNITS: ReadonlySet<WrDurationUnit> = new Set(['hour', 'minute', 'second']);\nconst LIST_UNITS: ReadonlySet<WrDurationUnit> = new Set(['day', 'hour', 'minute', 'second']);\n\nfunction formatClock(ms: number, locale: string): string {\n const { hour = 0, minute = 0, second = 0 } = wrSplitDuration(ms, CLOCK_UNITS);\n const digits = (n: number, width: number): string =>\n new Intl.NumberFormat(locale, { useGrouping: false, minimumIntegerDigits: width }).format(n);\n const tail = `${digits(minute, hour > 0 ? 2 : 1)}:${digits(second, 2)}`;\n return hour > 0 ? `${digits(hour, 1)}:${tail}` : tail;\n}\n\nfunction formatTimer(ms: number, locale: string): string {\n const { day = 0, hour = 0, minute = 0, second = 0 } = wrSplitDuration(ms, LIST_UNITS);\n const two = new Intl.NumberFormat(locale, { useGrouping: false, minimumIntegerDigits: 2 });\n const clock = [hour, minute, second].map(n => two.format(n)).join(':');\n if (day === 0) return clock;\n const days = new Intl.NumberFormat(locale, { style: 'unit', unit: 'day', unitDisplay: 'narrow' }).format(day);\n return `${days} ${clock}`;\n}\n\nfunction formatUnits(ms: number, locale: string): string {\n const parts = wrSplitDuration(ms, LIST_UNITS);\n const unit = (name: WrDurationUnit, n: number): string =>\n new Intl.NumberFormat(locale, { style: 'unit', unit: name, unitDisplay: 'short' }).format(n);\n\n const words = (Object.entries(parts) as [WrDurationUnit, number][])\n .filter(([, n]) => n > 0)\n .map(([name, n]) => unit(name, n));\n if (words.length === 0) return unit('second', 0);\n return new Intl.ListFormat(locale, { style: 'narrow', type: 'unit' }).format(words);\n}\n\n/**\n * Split a span of milliseconds into the units asked for. A unit left out is\n * carried into the next larger one that is kept, so `['hour', 'minute',\n * 'second']` over three days and an hour reads 73 hours; the smallest unit kept\n * floors whatever remains. Shared with `wr-statistic-countdown`, whose format\n * tokens pick the units.\n *\n * @internal\n */\nexport function wrSplitDuration(\n ms: number,\n units: ReadonlySet<WrDurationUnit>\n): Readonly<Partial<Record<WrDurationUnit, number>>> {\n const out: Partial<Record<WrDurationUnit, number>> = {};\n let rest = ms;\n for (const [unit, size] of UNIT_MS) {\n if (!units.has(unit)) continue;\n const n = Math.floor(rest / size);\n out[unit] = n;\n rest -= n * size;\n }\n return out;\n}\n\n/**\n * A span of milliseconds as text, in the given locale.\n *\n * Three styles. `'clock'` is digits and colons: `1:30:00`, and `5:07` under an\n * hour; days are carried into the hours, since a clock has no day digit, so two\n * days read `48:00:00`. `'units'` is every non-zero unit as a word the locale\n * writes, `1 hr 30 min` in English and `1 h 30 min` in French, through\n * `Intl.NumberFormat`'s unit style and `Intl.ListFormat` — `Intl.DurationFormat`\n * is above the browser floor. `'timer'` is what an elapsed-time counter shows:\n * always `HH:mm:ss`, each field two digits, `01:02:03` and `00:05:07`; from a\n * day on, the days stand in front as the locale's narrow unit, `1d 02:03:04`.\n * The digits are the locale's own in every style.\n *\n * A span is not an instant: no style reads a time zone, so the output is the\n * same wherever it runs. Formatting an elapsed time as a date would add the\n * display zone's offset to it.\n *\n * Whole seconds: a fraction of a second is floored in every style. Zero reads\n * `0:00`, `0 sec` and `00:00:00`. A negative span is its absolute value with\n * the locale's minus sign in front, `-5:07` and `-00:05:07`. `null`, `undefined`, an empty string and a value\n * that is not a finite number give an empty string, as `wrFormatNumber` does.\n *\n * The same output as the `wrDuration` pipe, for a string built in TypeScript.\n *\n * @example\n * ```ts\n * wrFormatDuration(5_400_000, 'en-US'); // \"1:30:00\"\n * wrFormatDuration(5_400_000, 'en-US', 'units'); // \"1 hr 30 min\"\n * wrFormatDuration(307_000, 'fr-FR', 'units'); // \"5 min 7 s\"\n * wrFormatDuration(3_723_000, 'en-US', 'timer'); // \"01:02:03\"\n * wrFormatDuration(93_784_000, 'en-US', 'timer'); // \"1d 02:03:04\"\n * ```\n */\nexport function wrFormatDuration(\n value: number | string | null | undefined,\n locale: string,\n style: WrDurationStyle = 'clock'\n): string {\n if (value === null || value === undefined || value === '') return '';\n const ms = Number(typeof value === 'string' ? value.trim() : value);\n if (!Number.isFinite(ms)) return '';\n\n const span = Math.abs(ms);\n const body =\n style === 'units'\n ? formatUnits(span, locale)\n : style === 'timer'\n ? formatTimer(span, locale)\n : formatClock(span, locale);\n // A span that floors to zero carries no sign: `-0:00` states nothing.\n if (ms >= 0 || span < 1000) return body;\n\n const minus = new Intl.NumberFormat(locale).formatToParts(-1).find(part => part.type === 'minusSign');\n return `${minus?.value ?? '-'}${body}`;\n}\n\n/**\n * A span of milliseconds as clock digits, as units or as a timer, in Angular's\n * `LOCALE_ID`. See {@link wrFormatDuration} for the three styles and the edge\n * cases.\n *\n * @example\n * ```html\n * {{ 5400000 | wrDuration }} <!-- \"1:30:00\" -->\n * {{ 5400000 | wrDuration: 'units' }} <!-- \"1 hr 30 min\" -->\n * {{ 307000 | wrDuration }} <!-- \"5:07\" -->\n * {{ 3723000 | wrDuration: 'timer' }} <!-- \"01:02:03\" -->\n * ```\n */\n@Pipe({ name: 'wrDuration' })\nexport class WrDuration implements PipeTransform {\n private readonly locale = inject(LOCALE_ID);\n\n transform(value: number | string | null | undefined, style: WrDurationStyle = 'clock'): string {\n return wrFormatDuration(value, this.locale, style);\n }\n}\n\nexport type { WrDurationStyle, WrDurationUnit } from './types';\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\nimport { LOCALE_ID, Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nimport { wrInitials } from 'ngwr/utils';\n\n/**\n * Up to two initials of a name: `wrInitials()` from `ngwr/utils`, upper-cased\n * in `LOCALE_ID`.\n *\n * @example\n * ```html\n * {{ 'Roman Khegay' | wrInitials }} <!-- \"RK\" -->\n * {{ 'madonna' | wrInitials }} <!-- \"M\" -->\n * {{ '王小明' | wrInitials }} <!-- \"王\" -->\n * ```\n *\n * @see https://ngwr.dev/reference/pipes/wr-initials\n */\n@Pipe({ name: 'wrInitials' })\nexport class WrInitials implements PipeTransform {\n private readonly locale = inject(LOCALE_ID);\n\n transform(value: string | null | undefined): string {\n return wrInitials(value, this.locale);\n }\n}\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\nimport { Pipe, type PipeTransform, inject } from '@angular/core';\nimport { DomSanitizer, type SafeHtml } from '@angular/platform-browser';\n\n/** Escapes RegExp metacharacters so user input is safe to inline. @internal */\nconst RE_META = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** HTML-entities for the four chars that matter inside our `<mark>` wrap. @internal */\nfunction escapeHtml(s: string): string {\n return s.replace(/&/g, '&amp;').replace(/</g, '&lt;').replace(/>/g, '&gt;').replace(/\"/g, '&quot;');\n}\n\n/**\n * Wrap every occurrence of `query` in `<mark>` tags. Useful for highlighting\n * search-term matches in autocomplete results, lists, and table cells.\n *\n * The output is `SafeHtml` — bind with `[innerHTML]`. Input is escaped first\n * so user-supplied values can't inject markup.\n *\n * @example\n * ```html\n * <span [innerHTML]=\"row.name | wrMark: query()\"></span>\n *\n * <!-- Case-sensitive: -->\n * <span [innerHTML]=\"row.name | wrMark: query() : true\"></span>\n * ```\n */\n@Pipe({ name: 'wrMark' })\nexport class WrMark implements PipeTransform {\n private readonly sanitizer = inject(DomSanitizer);\n\n /**\n * @param value Source text.\n * @param query Search term to highlight. Empty/null skips the wrap.\n * @param caseSensitive Match exactly. @default false\n */\n transform(value: string | null | undefined, query: string | null | undefined, caseSensitive = false): SafeHtml {\n if (value === null || value === undefined) return '';\n const text = String(value);\n // Escaped on this path too. The output is bound with `[innerHTML]`, so\n // handing back the raw string let markup in `value` render as elements the\n // moment the search box was cleared — the same value drawn as text while a\n // query was typed, as an `<img>` when it was not.\n if (!query) return escapeHtml(text);\n\n // Match the RAW text and escape the pieces afterwards, never the other way\n // round. Escaping first rewrites `&` as `&amp;`, and a query of `m` then lands\n // INSIDE that entity: the `<mark>` splits it and the browser paints the\n // entity's own letters, so `Tom & Jerry` renders as `Tom &amp; Jerry`. The\n // mirror failure is a match that can never happen — `<`, `>` and `\"` no longer\n // exist in escaped text. The pipe's promise is untouched: every piece that came\n // from `value` still goes through `escapeHtml`, matched or not, so the only\n // tags in the output are the `<mark>`s built here.\n const pattern = new RegExp(`(${query.replace(RE_META, '\\\\$&')})`, caseSensitive ? 'g' : 'gi');\n const html = text\n .split(pattern)\n .map((part, index) => (index % 2 ? `<mark>${escapeHtml(part)}</mark>` : escapeHtml(part)))\n .join('');\n\n return this.sanitizer.bypassSecurityTrustHtml(html);\n }\n}\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\nimport { LOCALE_ID, Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nimport type { WrNumberStyle } from './types';\n\n/** Digits with one optional point and a sign: the form `Intl` reads exactly. */\nconst PLAIN_DECIMAL = /^[+-]?(?:\\d+\\.?\\d*|\\.\\d+)$/;\n\nfunction toOptions(style: WrNumberStyle, currency: string): Intl.NumberFormatOptions {\n switch (style) {\n case 'percent':\n return { style: 'percent', maximumFractionDigits: 2 };\n case 'currency':\n return { style: 'currency', currency };\n case 'decimal':\n default:\n return { style: 'decimal' };\n }\n}\n\n/**\n * A number through `Intl.NumberFormat`, in the given locale: the same output as\n * the `wrNumber` pipe, for a string built in TypeScript. Takes a style shortcut\n * (with an optional currency code) or a full `Intl.NumberFormatOptions` object.\n * `null`, `undefined`, an empty string and a value that is not a finite number\n * give an empty string.\n *\n * @example\n * ```ts\n * wrFormatNumber(1234.5, 'en-US'); // \"1,234.5\"\n * wrFormatNumber(0.875, 'en-US', 'percent'); // \"87.5%\"\n * wrFormatNumber(19.99, 'de-DE', 'currency', 'EUR'); // \"19,99 €\"\n * wrFormatNumber(19.99, 'en-US', { minimumFractionDigits: 2 });\n * ```\n */\nexport function wrFormatNumber(\n value: number | string | null | undefined,\n locale: string,\n styleOrOptions: WrNumberStyle | Intl.NumberFormatOptions = 'decimal',\n currency = 'USD'\n): string {\n if (value === null || value === undefined || value === '') return '';\n const text = typeof value === 'string' ? value.trim() : null;\n const n = Number(text ?? value);\n if (!Number.isFinite(n)) return '';\n\n const options: Intl.NumberFormatOptions =\n typeof styleOrOptions === 'string' ? toOptions(styleOrOptions, currency) : styleOrOptions;\n\n // A plain decimal string goes to `Intl` as it is: through `Number()`,\n // `'12345678901234567.89'` printed as `12,345,678,901,234,568`. Any other\n // form keeps the number, since ICU throws on an exponent of a billion or more.\n // `format()` has read a string since ES2023 (Chrome 106, Firefox 116, Safari\n // 15.4); the ES2022 lib this builds against types it as a number only.\n const exact = text !== null && PLAIN_DECIMAL.test(text) ? (text as unknown as number) : n;\n return new Intl.NumberFormat(locale, options).format(exact);\n}\n\n/**\n * Locale-aware number formatting via `Intl.NumberFormat`. Uses Angular's\n * `LOCALE_ID` as the default locale.\n *\n * Accepts either a style shortcut (with optional currency code) or a full\n * `Intl.NumberFormatOptions` object for fine-grained control.\n * {@link wrFormatNumber} is the same output as a function.\n *\n * @example\n * ```html\n * {{ 1234.5 | wrNumber }} <!-- \"1,234.5\" -->\n * {{ 0.875 | wrNumber: 'percent' }} <!-- \"87.5%\" -->\n * {{ 19.99 | wrNumber: 'currency': 'USD' }} <!-- \"$19.99\" -->\n * {{ 19.99 | wrNumber: { minimumFractionDigits: 2 } }}\n * ```\n */\n@Pipe({ name: 'wrNumber' })\nexport class WrNumber implements PipeTransform {\n private readonly locale = inject(LOCALE_ID);\n\n transform(\n value: number | string | null | undefined,\n styleOrOptions: WrNumberStyle | Intl.NumberFormatOptions = 'decimal',\n currency = 'USD'\n ): string {\n return wrFormatNumber(value, this.locale, styleOrOptions, currency);\n }\n}\n\nexport type { WrNumberStyle } from './types';\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\nimport { LOCALE_ID, Pipe, inject } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nimport type { WrPluralForms, WrPluralOptions } from './types';\n\n/**\n * A count and its word form through `Intl.PluralRules`, in the given locale:\n * the same output as the `wrPlural` pipe, for a string built in TypeScript.\n * `options.locale` still wins over `locale`, as it wins over `LOCALE_ID` in the\n * pipe. `null`, `undefined` and a value that is not a finite number give an\n * empty string.\n *\n * @example\n * ```ts\n * wrFormatPlural(1, 'en', { one: 'comment', other: 'comments' }); // \"1 comment\"\n * wrFormatPlural(5, 'ru', { one: 'файл', few: 'файла', other: 'файлов' }); // \"5 файлов\"\n * wrFormatPlural(5, 'en', forms, { includeValue: false }); // \"comments\"\n * ```\n */\nexport function wrFormatPlural(\n value: number | null | undefined,\n locale: string,\n forms: WrPluralForms,\n options: WrPluralOptions = {}\n): string {\n if (value === null || value === undefined || !Number.isFinite(value)) return '';\n const tag = options.locale ?? locale;\n const category = new Intl.PluralRules(tag).select(value);\n const word = forms[category] ?? forms.other;\n if (options.includeValue === false) return word;\n return `${new Intl.NumberFormat(tag).format(value)} ${word}`;\n}\n\n/**\n * Locale-aware pluralization via `Intl.PluralRules`. Picks the right word\n * form for the count — including languages with more than two forms\n * (Russian, Polish, Arabic, …) — without hand-rolled `n % 10` rules.\n *\n * Categories follow CLDR: `zero` / `one` / `two` / `few` / `many` /\n * `other`. Missing categories fall back to `other`. {@link wrFormatPlural} is\n * the same output as a function.\n *\n * @example\n * ```html\n * {{ 1 | wrPlural: { one: 'comment', other: 'comments' } }}\n * <!-- \"1 comment\" -->\n *\n * {{ 5 | wrPlural: { one: 'файл', few: 'файла', other: 'файлов' } }}\n * <!-- \"5 файлов\" (with LOCALE_ID = ru) -->\n *\n * {{ count() | wrPlural: forms : { includeValue: false } }}\n * <!-- word only -->\n * ```\n */\n@Pipe({ name: 'wrPlural' })\nexport class WrPlural implements PipeTransform {\n private readonly locale = inject(LOCALE_ID);\n\n transform(value: number | null | undefined, forms: WrPluralForms, options: WrPluralOptions = {}): string {\n return wrFormatPlural(value, this.locale, forms, options);\n }\n}\n\nexport type { WrPluralForms, WrPluralOptions } from './types';\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\nimport { Pipe } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\n/**\n * Creates an array of sequential indices `[0, 1, 2, ..., n-1]`.\n *\n * Useful for repeating template blocks a fixed number of times.\n *\n * @example\n * ```html\n * @for (i of (5 | wrRange); track i) {\n * <div>Item {{ i }}</div>\n * }\n * ```\n */\n@Pipe({ name: 'wrRange' })\nexport class WrRange implements PipeTransform {\n transform(length: number): number[] {\n return Array.from({ length }, (_, i) => i);\n }\n}\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\nimport { Pipe } from '@angular/core';\nimport type { PipeTransform } from '@angular/core';\n\nlet segmenter: Intl.Segmenter | undefined;\n\n/**\n * Clamp a string to `length` characters, appending `ellipsis` when truncated.\n * A character is what a reader sees as one — a grapheme cluster — so an emoji,\n * a flag or a letter with a combining accent is kept whole or dropped whole,\n * never cut into half a surrogate pair that renders as a replacement box.\n *\n * @example\n * ```html\n * {{ 'Hello, world' | wrTruncate: 5 }} <!-- \"Hello…\" -->\n * {{ 'Hello, world' | wrTruncate: 8: '...' }} <!-- \"Hello, w...\" -->\n * ```\n */\n@Pipe({ name: 'wrTruncate' })\nexport class WrTruncate implements PipeTransform {\n transform(value: string | null | undefined, length = 80, ellipsis = '…'): string {\n if (value === null || value === undefined) return '';\n const s = String(value);\n // No more graphemes than UTF-16 units, so a string this short is never cut.\n if (s.length <= length) return s;\n // `slice`'s own coercion of the count, which is what this pipe did before it\n // counted graphemes: a fraction truncates, and NaN or a negative keeps nothing.\n const limit = Math.max(0, Math.trunc(length) || 0);\n segmenter ??= new Intl.Segmenter(undefined, { granularity: 'grapheme' });\n let count = 0;\n for (const { index } of segmenter.segment(s)) {\n if (count === limit) return s.slice(0, index) + ellipsis;\n count++;\n }\n return s;\n }\n}\n"],"mappings":";;;;;;;;;;;AAgBA,MAAM,QAAQ;CAAC;CAAQ;CAAY;CAAY;CAAY;CAAY;AAAU;AAgBjF,SAAS,OAAO,QAAgB,OAAe,MAAc,gBAAsB;CACjF,MAAM,QAAQ,IAAI,KAAK,aAAa,QAAQ;EAC1C,OAAO;EACP,MAAM,MAAM;EACZ,aAAa;EACb,uBAAuB;EACvB,uBAAuB;CACxB,CAAA,CAAC,CAAC,cAAc,KAAK;CAEtB,MAAM,KAAK,MAAM,WAAU,SAAQ,KAAK,SAAS,MAAM;CACvD,IAAI,OAAO,IAAI,OAAO,MAAM,KAAI,SAAQ,KAAK,KAAK,CAAC,CAAC,KAAK,EAAE;CAE3D,MAAM,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AAI;AAeJ,IAAa,aAAb,MAAa,WAAU;CACrB,UAAU,OAAkC,SAAS,IAAI,WAAW,KAAG;EACrE,IAAI,UAAU,QAAQ,UAAU,QAAW,OAAO;EAClD,MAAM,IAAI,OAAO,KAAK;EAEtB,IAAI,EAAE,UAAU,QAAQ,OAAO;EAG/B,MAAM,QAAQ,KAAK,IAAI,GAAG,KAAK,MAAM,MAAM,KAAK,CAAC;EACjD,cAAc,IAAI,KAAK,UAAU,QAAW,EAAE,aAAa,WAAU,CAAE;EACvE,IAAI,QAAQ;EACZ,KAAK,MAAM,EAAE,WAAW,UAAU,QAAQ,CAAC,GAAG;GAC5C,IAAI,UAAU,OAAO,OAAO,EAAE,MAAM,GAAG,KAAK,IAAI;GAChD;EACF;EACA,OAAO;CACT;CAhBW,OAAA,OAAA,GAAA,mBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,UAAA;EAAA,MAAA;EAAU,MAAA,CAAA;EAAA,QAAA,GAAA,gBAAA;CAAA,CAAA;CAAV,OAAA,QAAA,GAAA,gBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,UAAA;EAAA,MAAA;EAAU,cAAA;EAAA,MAAA;CAAA,CAAA;;AAAV,GAAA,yBAAA;CAAA,YAAA;CAAA,SAAA;CAAA,UAAA;CAAA,MAAA;CAAU,YAAA,CAAA;EADtB,MAAA;EAAK,MAAA,CAAA,EAAE,MAAM,aAAY,CAAE"}
@@ -78,7 +78,7 @@ var WrPlatform = class WrPlatform {
78
78
  }
79
79
  static ɵfac = i0.ɵɵngDeclareFactory({
80
80
  minVersion: "12.0.0",
81
- version: "22.2.5",
81
+ version: "22.2.6",
82
82
  ngImport: i0,
83
83
  type: WrPlatform,
84
84
  deps: [],
@@ -86,14 +86,14 @@ var WrPlatform = class WrPlatform {
86
86
  });
87
87
  static ɵprov = i0.ɵɵngDeclareService({
88
88
  minVersion: "22.0.0",
89
- version: "22.2.5",
89
+ version: "22.2.6",
90
90
  ngImport: i0,
91
91
  type: WrPlatform
92
92
  });
93
93
  };
94
94
  i0.ɵɵngDeclareClassMetadata({
95
95
  minVersion: "12.0.0",
96
- version: "22.2.5",
96
+ version: "22.2.6",
97
97
  ngImport: i0,
98
98
  type: WrPlatform,
99
99
  decorators: [{ type: Service }]
@@ -159,7 +159,7 @@ var WrHaptics = class WrHaptics {
159
159
  }
160
160
  static ɵfac = i0.ɵɵngDeclareFactory({
161
161
  minVersion: "12.0.0",
162
- version: "22.2.5",
162
+ version: "22.2.6",
163
163
  ngImport: i0,
164
164
  type: WrHaptics,
165
165
  deps: [],
@@ -167,14 +167,14 @@ var WrHaptics = class WrHaptics {
167
167
  });
168
168
  static ɵprov = i0.ɵɵngDeclareService({
169
169
  minVersion: "22.0.0",
170
- version: "22.2.5",
170
+ version: "22.2.6",
171
171
  ngImport: i0,
172
172
  type: WrHaptics
173
173
  });
174
174
  };
175
175
  i0.ɵɵngDeclareClassMetadata({
176
176
  minVersion: "12.0.0",
177
- version: "22.2.5",
177
+ version: "22.2.6",
178
178
  ngImport: i0,
179
179
  type: WrHaptics,
180
180
  decorators: [{ type: Service }]
@@ -228,7 +228,7 @@ var WrPollTicker = class WrPollTicker {
228
228
  }
229
229
  static ɵfac = i0.ɵɵngDeclareFactory({
230
230
  minVersion: "12.0.0",
231
- version: "22.2.5",
231
+ version: "22.2.6",
232
232
  ngImport: i0,
233
233
  type: WrPollTicker,
234
234
  deps: [],
@@ -236,14 +236,14 @@ var WrPollTicker = class WrPollTicker {
236
236
  });
237
237
  static ɵprov = i0.ɵɵngDeclareService({
238
238
  minVersion: "22.0.0",
239
- version: "22.2.5",
239
+ version: "22.2.6",
240
240
  ngImport: i0,
241
241
  type: WrPollTicker
242
242
  });
243
243
  };
244
244
  i0.ɵɵngDeclareClassMetadata({
245
245
  minVersion: "12.0.0",
246
- version: "22.2.5",
246
+ version: "22.2.6",
247
247
  ngImport: i0,
248
248
  type: WrPollTicker,
249
249
  decorators: [{ type: Service }],
@@ -9,7 +9,7 @@ import { WR_COLORS } from "ngwr/theme";
9
9
  var WrPopconfirmHarness = class WrPopconfirmHarness extends ContentContainerComponentHarness {
10
10
  static hostSelector = ".wr-popconfirm-trigger";
11
11
  static with(options = {}) {
12
- return new HarnessPredicate(WrPopconfirmHarness, options).addOption("triggerText", options.triggerText, (harness, text) => HarnessPredicate.stringMatches(harness.getTriggerText(), text)).addOption("open", options.open, async (harness, open) => await harness.isOpen() === open);
12
+ return new HarnessPredicate(WrPopconfirmHarness, options).addOption("triggerText", options.triggerText, (harness, text) => HarnessPredicate.stringMatches(harness.getTriggerText(), text)).addOption("open", options.open, async (harness, open) => await harness.isOpen() === open).addOption("disabled", options.disabled, async (harness, disabled) => await harness.isDisabled() === disabled);
13
13
  }
14
14
  async getTriggerText() {
15
15
  return (await this.host()).text();
@@ -17,6 +17,9 @@ var WrPopconfirmHarness = class WrPopconfirmHarness extends ContentContainerComp
17
17
  async isOpen() {
18
18
  return await (await this.host()).getAttribute("aria-expanded") === "true";
19
19
  }
20
+ async isDisabled() {
21
+ return (await this.host()).hasClass("wr-popconfirm-trigger--disabled");
22
+ }
20
23
  async isTriggerFocused() {
21
24
  return (await this.host()).isFocused();
22
25
  }
@@ -85,7 +88,7 @@ var WrPopconfirmHarness = class WrPopconfirmHarness extends ContentContainerComp
85
88
  }
86
89
  async getPosition() {
87
90
  const classes = await (await this.pane()).getAttribute("class") ?? "";
88
- const modifier = /wr-popconfirm-overlay--([a-z]+)/.exec(classes);
91
+ const modifier = /wr-popconfirm-overlay--([a-z-]+)/.exec(classes);
89
92
  return modifier ? modifier[1] : null;
90
93
  }
91
94
  async getRootHarnessLoader() {