ngwr 14.0.0 → 14.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (207) hide show
  1. package/README.md +57 -8
  2. package/aurora/aurora.scss +1 -1
  3. package/aurora/styles/_dark.scss +21 -0
  4. package/aurora/styles/_index.scss +11 -30
  5. package/aurora/styles/_rules.scss +25 -0
  6. package/border-glow/styles/_dark.scss +46 -0
  7. package/border-glow/styles/_index.scss +5 -0
  8. package/border-glow/styles/_rules.scss +0 -31
  9. package/button/styles/_index.scss +16 -0
  10. package/event-calendar/styles/_index.scss +15 -0
  11. package/fesm2022/ngwr-action-sheet.mjs +3 -3
  12. package/fesm2022/ngwr-affix.mjs +3 -3
  13. package/fesm2022/ngwr-alert.mjs +3 -3
  14. package/fesm2022/ngwr-anchor.mjs +3 -3
  15. package/fesm2022/ngwr-aurora.mjs +4 -4
  16. package/fesm2022/ngwr-aurora.mjs.map +1 -1
  17. package/fesm2022/ngwr-avatar.mjs +3 -3
  18. package/fesm2022/ngwr-back-top.mjs +3 -3
  19. package/fesm2022/ngwr-badge.mjs +6 -6
  20. package/fesm2022/ngwr-bar-chart.mjs +3 -3
  21. package/fesm2022/ngwr-blur-text.mjs +3 -3
  22. package/fesm2022/ngwr-border-glow.mjs +4 -4
  23. package/fesm2022/ngwr-border-glow.mjs.map +1 -1
  24. package/fesm2022/ngwr-breadcrumbs.mjs +7 -7
  25. package/fesm2022/ngwr-breadcrumbs.mjs.map +1 -1
  26. package/fesm2022/ngwr-burger.mjs +3 -3
  27. package/fesm2022/ngwr-button.mjs +86 -8
  28. package/fesm2022/ngwr-button.mjs.map +1 -1
  29. package/fesm2022/ngwr-calendar-heatmap.mjs +3 -3
  30. package/fesm2022/ngwr-calendar.mjs +3 -3
  31. package/fesm2022/ngwr-card.mjs +9 -9
  32. package/fesm2022/ngwr-carousel.mjs +6 -6
  33. package/fesm2022/ngwr-cascader.mjs +4 -4
  34. package/fesm2022/ngwr-cascader.mjs.map +1 -1
  35. package/fesm2022/ngwr-checkbox.mjs +6 -6
  36. package/fesm2022/ngwr-circular-text.mjs +3 -3
  37. package/fesm2022/ngwr-click-spark.mjs +3 -3
  38. package/fesm2022/ngwr-clipboard.mjs +3 -3
  39. package/fesm2022/ngwr-collapse.mjs +9 -9
  40. package/fesm2022/ngwr-color-picker.mjs +6 -6
  41. package/fesm2022/ngwr-command-palette.mjs +84 -7
  42. package/fesm2022/ngwr-command-palette.mjs.map +1 -1
  43. package/fesm2022/ngwr-compare.mjs +3 -3
  44. package/fesm2022/ngwr-confetti.mjs +3 -3
  45. package/fesm2022/ngwr-context-menu.mjs +12 -12
  46. package/fesm2022/ngwr-cookie.mjs +3 -3
  47. package/fesm2022/ngwr-counter.mjs +6 -6
  48. package/fesm2022/ngwr-date-adapters-fns.mjs +3 -3
  49. package/fesm2022/ngwr-date-adapters-luxon.mjs +3 -3
  50. package/fesm2022/ngwr-date-picker.mjs +18 -18
  51. package/fesm2022/ngwr-date.mjs +3 -3
  52. package/fesm2022/ngwr-decrypt-text.mjs +3 -3
  53. package/fesm2022/ngwr-density.mjs +6 -6
  54. package/fesm2022/ngwr-descriptions.mjs +6 -6
  55. package/fesm2022/ngwr-dialog.mjs +15 -15
  56. package/fesm2022/ngwr-directives.mjs +12 -12
  57. package/fesm2022/ngwr-divider.mjs +3 -3
  58. package/fesm2022/ngwr-donut-chart.mjs +3 -3
  59. package/fesm2022/ngwr-drag-drop.mjs +7 -7
  60. package/fesm2022/ngwr-drag-drop.mjs.map +1 -1
  61. package/fesm2022/ngwr-drawer.mjs +18 -18
  62. package/fesm2022/ngwr-dropdown.mjs +28 -12
  63. package/fesm2022/ngwr-dropdown.mjs.map +1 -1
  64. package/fesm2022/ngwr-empty.mjs +3 -3
  65. package/fesm2022/ngwr-event-calendar.mjs +6 -6
  66. package/fesm2022/ngwr-falling-text.mjs +3 -3
  67. package/fesm2022/ngwr-file-upload.mjs +3 -3
  68. package/fesm2022/ngwr-form-testing.mjs +13 -7
  69. package/fesm2022/ngwr-form-testing.mjs.map +1 -1
  70. package/fesm2022/ngwr-form.mjs +44 -25
  71. package/fesm2022/ngwr-form.mjs.map +1 -1
  72. package/fesm2022/ngwr-fuzzy-text.mjs +3 -3
  73. package/fesm2022/ngwr-gauge.mjs +3 -3
  74. package/fesm2022/ngwr-glitch-text.mjs +3 -3
  75. package/fesm2022/ngwr-gradient-text.mjs +3 -3
  76. package/fesm2022/ngwr-hotkey.mjs +6 -6
  77. package/fesm2022/ngwr-i18n-en.mjs +4 -0
  78. package/fesm2022/ngwr-i18n-en.mjs.map +1 -1
  79. package/fesm2022/ngwr-i18n-ru.mjs +1 -0
  80. package/fesm2022/ngwr-i18n-ru.mjs.map +1 -1
  81. package/fesm2022/ngwr-i18n.mjs +9 -9
  82. package/fesm2022/ngwr-icon.mjs +6 -6
  83. package/fesm2022/ngwr-image-cropper.mjs +3 -3
  84. package/fesm2022/ngwr-input-number.mjs +3 -3
  85. package/fesm2022/ngwr-input-otp.mjs +3 -3
  86. package/fesm2022/ngwr-input.mjs +24 -20
  87. package/fesm2022/ngwr-input.mjs.map +1 -1
  88. package/fesm2022/ngwr-keyboard.mjs +3 -3
  89. package/fesm2022/ngwr-knob.mjs +3 -3
  90. package/fesm2022/ngwr-layout.mjs +15 -15
  91. package/fesm2022/ngwr-lightbox.mjs +4 -4
  92. package/fesm2022/ngwr-lightbox.mjs.map +1 -1
  93. package/fesm2022/ngwr-line-chart.mjs +3 -3
  94. package/fesm2022/ngwr-list.mjs +7 -7
  95. package/fesm2022/ngwr-list.mjs.map +1 -1
  96. package/fesm2022/ngwr-loading-bar.mjs +6 -6
  97. package/fesm2022/ngwr-markdown.mjs +6 -6
  98. package/fesm2022/ngwr-marquee.mjs +3 -3
  99. package/fesm2022/ngwr-media.mjs +3 -3
  100. package/fesm2022/ngwr-mention.mjs +6 -6
  101. package/fesm2022/ngwr-meta.mjs +6 -6
  102. package/fesm2022/ngwr-meter-group.mjs +3 -3
  103. package/fesm2022/ngwr-overlay.mjs +6 -6
  104. package/fesm2022/ngwr-page-header.mjs +3 -3
  105. package/fesm2022/ngwr-pagination.mjs +3 -3
  106. package/fesm2022/ngwr-pipes.mjs +21 -21
  107. package/fesm2022/ngwr-platform.mjs +9 -9
  108. package/fesm2022/ngwr-popconfirm.mjs +6 -6
  109. package/fesm2022/ngwr-popover.mjs +6 -6
  110. package/fesm2022/ngwr-progress.mjs +3 -3
  111. package/fesm2022/ngwr-pull-to-refresh.mjs +3 -3
  112. package/fesm2022/ngwr-qr.mjs +3 -3
  113. package/fesm2022/ngwr-radio.mjs +6 -6
  114. package/fesm2022/ngwr-rating.mjs +48 -22
  115. package/fesm2022/ngwr-rating.mjs.map +1 -1
  116. package/fesm2022/ngwr-result.mjs +12 -12
  117. package/fesm2022/ngwr-rotating-text.mjs +3 -3
  118. package/fesm2022/ngwr-scroll.mjs +3 -3
  119. package/fesm2022/ngwr-segmented.mjs +12 -8
  120. package/fesm2022/ngwr-segmented.mjs.map +1 -1
  121. package/fesm2022/ngwr-select.mjs +125 -26
  122. package/fesm2022/ngwr-select.mjs.map +1 -1
  123. package/fesm2022/ngwr-shiny-text.mjs +7 -7
  124. package/fesm2022/ngwr-shiny-text.mjs.map +1 -1
  125. package/fesm2022/ngwr-sidebar.mjs +3 -3
  126. package/fesm2022/ngwr-skeleton.mjs +3 -3
  127. package/fesm2022/ngwr-slider.mjs +12 -8
  128. package/fesm2022/ngwr-slider.mjs.map +1 -1
  129. package/fesm2022/ngwr-sparkline.mjs +3 -3
  130. package/fesm2022/ngwr-speed-dial.mjs +3 -3
  131. package/fesm2022/ngwr-spinner.mjs +3 -3
  132. package/fesm2022/ngwr-splash-cursor.mjs +3 -3
  133. package/fesm2022/ngwr-split-text.mjs +3 -3
  134. package/fesm2022/ngwr-splitter.mjs +3 -3
  135. package/fesm2022/ngwr-spotlight-card.mjs +7 -7
  136. package/fesm2022/ngwr-spotlight-card.mjs.map +1 -1
  137. package/fesm2022/ngwr-squircle.mjs +6 -6
  138. package/fesm2022/ngwr-star-border.mjs +4 -4
  139. package/fesm2022/ngwr-star-border.mjs.map +1 -1
  140. package/fesm2022/ngwr-statistic.mjs +9 -9
  141. package/fesm2022/ngwr-stepper.mjs +6 -6
  142. package/fesm2022/ngwr-storage.mjs +11 -3
  143. package/fesm2022/ngwr-storage.mjs.map +1 -1
  144. package/fesm2022/ngwr-switch.mjs +3 -3
  145. package/fesm2022/ngwr-table.mjs +18 -18
  146. package/fesm2022/ngwr-tabs-router.mjs +3 -3
  147. package/fesm2022/ngwr-tabs.mjs +6 -6
  148. package/fesm2022/ngwr-textarea.mjs +26 -5
  149. package/fesm2022/ngwr-textarea.mjs.map +1 -1
  150. package/fesm2022/ngwr-theme.mjs +90 -4
  151. package/fesm2022/ngwr-theme.mjs.map +1 -1
  152. package/fesm2022/ngwr-tilt-card.mjs +7 -7
  153. package/fesm2022/ngwr-tilt-card.mjs.map +1 -1
  154. package/fesm2022/ngwr-timeline.mjs +6 -6
  155. package/fesm2022/ngwr-toast.mjs +116 -11
  156. package/fesm2022/ngwr-toast.mjs.map +1 -1
  157. package/fesm2022/ngwr-toolbar.mjs +3 -3
  158. package/fesm2022/ngwr-tour.mjs +6 -6
  159. package/fesm2022/ngwr-transfer.mjs +3 -3
  160. package/fesm2022/ngwr-tree.mjs +18 -11
  161. package/fesm2022/ngwr-tree.mjs.map +1 -1
  162. package/fesm2022/ngwr-typewriter.mjs +3 -3
  163. package/fesm2022/ngwr-typography.mjs +3 -3
  164. package/fesm2022/ngwr-version.mjs +1 -1
  165. package/fesm2022/ngwr-version.mjs.map +1 -1
  166. package/fesm2022/ngwr-virtual-scroll.mjs +3 -3
  167. package/fesm2022/ngwr-waves.mjs +4 -4
  168. package/fesm2022/ngwr-waves.mjs.map +1 -1
  169. package/fesm2022/ngwr-window.mjs +12 -12
  170. package/i18n/en.json +1 -0
  171. package/i18n/ru.json +1 -0
  172. package/llms-full.txt +9 -9
  173. package/llms.txt +82 -11
  174. package/package.json +1 -1
  175. package/shiny-text/styles/_dark.scss +20 -0
  176. package/shiny-text/styles/_index.scss +5 -0
  177. package/shiny-text/styles/_rules.scss +0 -4
  178. package/spotlight-card/styles/_dark.scss +21 -0
  179. package/spotlight-card/styles/_index.scss +5 -0
  180. package/spotlight-card/styles/_rules.scss +0 -6
  181. package/star-border/styles/_dark.scss +21 -0
  182. package/star-border/styles/_index.scss +5 -0
  183. package/star-border/styles/_rules.scss +0 -5
  184. package/theme/styles/_colors.scss +102 -0
  185. package/theme/styles/_focus.scss +31 -1
  186. package/tilt-card/styles/_dark.scss +21 -0
  187. package/tilt-card/styles/_index.scss +5 -0
  188. package/tilt-card/styles/_rules.scss +0 -5
  189. package/types/ngwr-button.d.ts +43 -0
  190. package/types/ngwr-command-palette.d.ts +59 -2
  191. package/types/ngwr-dropdown.d.ts +17 -1
  192. package/types/ngwr-form-testing.d.ts +13 -7
  193. package/types/ngwr-form.d.ts +47 -12
  194. package/types/ngwr-input.d.ts +2 -1
  195. package/types/ngwr-rating.d.ts +25 -4
  196. package/types/ngwr-segmented.d.ts +1 -0
  197. package/types/ngwr-select.d.ts +45 -9
  198. package/types/ngwr-slider.d.ts +1 -0
  199. package/types/ngwr-storage.d.ts +39 -1
  200. package/types/ngwr-textarea.d.ts +20 -0
  201. package/types/ngwr-theme.d.ts +92 -2
  202. package/types/ngwr-toast.d.ts +53 -0
  203. package/types/ngwr-tree.d.ts +3 -2
  204. package/types/ngwr-version.d.ts +1 -1
  205. package/waves/styles/_dark.scss +19 -0
  206. package/waves/styles/_index.scss +5 -0
  207. package/waves/styles/_rules.scss +0 -3
@@ -1,6 +1,6 @@
1
1
  import { coerceBooleanProperty } from '@angular/cdk/coercion';
2
2
  import * as i0 from '@angular/core';
3
- import { InjectionToken, input, inject, computed, ElementRef, ViewEncapsulation, Component, forwardRef } from '@angular/core';
3
+ import { InjectionToken, input, inject, computed, ElementRef, Injector, effect, afterNextRender, ViewEncapsulation, Component, forwardRef } from '@angular/core';
4
4
  import { useConfigValue } from 'ngwr/config';
5
5
  import { WrIcon } from 'ngwr/icon';
6
6
  import { WrSpinner } from 'ngwr/spinner';
@@ -49,6 +49,16 @@ const WR_BUTTON_GROUP = new InjectionToken('WR_BUTTON_GROUP');
49
49
  * every child — child `[shape]` inputs are ignored so the group reads as
50
50
  * one coherent control.
51
51
  *
52
+ * **Inside a `<form>`, use the native form.** `<wr-btn>` is a custom element
53
+ * carrying `role="button"`, and no custom element submits a form — the platform
54
+ * submits for `<button>`, `<input type="submit">` and `<input type="image">`
55
+ * and nothing else. That is why there is no `type` input: it would look like it
56
+ * worked. Implicit submission (Enter in a text field) does not reach it either.
57
+ *
58
+ * ```html
59
+ * <button wr-btn type="submit" color="primary">Save</button>
60
+ * ```
61
+ *
52
62
  * @see https://ngwr.dev/reference/components/button
53
63
  */
54
64
  class WrButton {
@@ -166,6 +176,72 @@ class WrButton {
166
176
  return;
167
177
  this.hostEl.nativeElement.click();
168
178
  }
179
+ injector = inject(Injector);
180
+ /**
181
+ * Whether this button is the one the caret was on, so it can be handed back
182
+ * the focus that goes missing while it is off.
183
+ *
184
+ * A control that becomes `disabled` while focused stops being a focusable
185
+ * area, and the browser runs the unfocusing steps: nothing else is nominated,
186
+ * so the caret lands on `<body>`. With `disabledWhenLoading` on by default
187
+ * that happens on EVERY async button — a keyboard user presses Enter on
188
+ * "Save" and the next Tab restarts from the top of the document, while a
189
+ * screen-reader user is told neither that the wait began nor that it ended,
190
+ * because the element they were on has left the a11y tree. The `<wr-btn>`
191
+ * element form loses its `tabindex` instead of gaining `disabled` and is
192
+ * unfocused for the same reason.
193
+ *
194
+ * Deliberately NOT keyed on reading `activeElement` when `isOff()` flips: an
195
+ * effect in this component's own view runs AFTER the parent has applied this
196
+ * directive's host bindings, so by then the attribute has landed and the
197
+ * browser has already moved the caret — the read would answer `<body>` on
198
+ * every real browser and the button on jsdom, which is the worst of both.
199
+ *
200
+ * The flag is written by the focus listeners instead, and a `blur` fired
201
+ * WHILE off keeps it set rather than clearing it: that blur is the browser
202
+ * taking the caret away, not the user leaving. A browser that fires no blur
203
+ * on disable at all is covered too — the flag simply stays as `focus` left it,
204
+ * and the `<body>` test below is what decides whether the focus is orphaned.
205
+ */
206
+ hadFocus = false;
207
+ /** @internal Host `focus` — see `hadFocus`. */
208
+ onHostFocus() {
209
+ this.hadFocus = true;
210
+ }
211
+ /** @internal Host `blur` — see `hadFocus`. */
212
+ onHostBlur() {
213
+ this.hadFocus = this.isOff();
214
+ }
215
+ constructor() {
216
+ effect(() => {
217
+ if (this.isOff())
218
+ return;
219
+ if (!this.hadFocus)
220
+ return;
221
+ const el = this.hostEl.nativeElement;
222
+ // Deferred: the host binding that drops `disabled` (or restores the
223
+ // `tabindex`) has not necessarily run yet, and `focus()` on a still
224
+ // disabled element is a silent no-op — the exact failure this is here to
225
+ // fix.
226
+ afterNextRender(() => {
227
+ if (!this.hadFocus || this.isOff())
228
+ return;
229
+ const doc = el.ownerDocument;
230
+ const active = doc?.activeElement ?? null;
231
+ // Still ours — nothing was ever taken away, so keep the flag for the
232
+ // cycle that does take it.
233
+ if (active === el)
234
+ return;
235
+ // Someone else owns the caret now: a user who tabbed on while the
236
+ // request was in flight must not be yanked back to a button they have
237
+ // finished with.
238
+ this.hadFocus = false;
239
+ if (active && doc && active !== doc.body)
240
+ return;
241
+ el.focus();
242
+ }, { injector: this.injector });
243
+ });
244
+ }
169
245
  classes = computed(() => {
170
246
  const parts = ['wr-btn'];
171
247
  const color = this.color();
@@ -189,10 +265,10 @@ class WrButton {
189
265
  return parts.join(' ');
190
266
  }, /* @ts-ignore */
191
267
  ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
192
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrButton, deps: [], target: i0.ɵɵFactoryTarget.Component });
193
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: WrButton, isStandalone: true, selector: "wr-btn, button[wr-btn], a[wr-btn]", inputs: { color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, shape: { classPropertyName: "shape", publicName: "shape", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, iconPosition: { classPropertyName: "iconPosition", publicName: "iconPosition", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, outlined: { classPropertyName: "outlined", publicName: "outlined", isSignal: true, isRequired: false, transformFunction: null }, block: { classPropertyName: "block", publicName: "block", isSignal: true, isRequired: false, transformFunction: null }, loading: { classPropertyName: "loading", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null }, disabledWhenLoading: { classPropertyName: "disabledWhenLoading", publicName: "disabledWhenLoading", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "keydown": "onHostKeydown($event)" }, properties: { "class": "classes()", "attr.disabled": "nativeDisabled()", "attr.aria-busy": "loading() ? \"true\" : null", "attr.role": "hostRole()", "attr.tabindex": "hostTabIndex()", "attr.aria-disabled": "hostAriaDisabled()" } }, ngImport: i0, template: "@if (loading()) {\n <wr-spinner class=\"wr-btn__spin\" size=\"sm\" />\n}\n\n@if (icon(); as name) {\n <wr-icon class=\"wr-btn__icon\" [name]=\"name\" />\n}\n\n<span class=\"wr-btn__label\">\n <ng-content />\n</span>\n", dependencies: [{ kind: "component", type: WrIcon, selector: "wr-icon", inputs: ["name"] }, { kind: "component", type: WrSpinner, selector: "wr-spinner", inputs: ["size", "ariaLabel"] }], encapsulation: i0.ViewEncapsulation.None });
268
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrButton, deps: [], target: i0.ɵɵFactoryTarget.Component });
269
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.5", type: WrButton, isStandalone: true, selector: "wr-btn, button[wr-btn], a[wr-btn]", inputs: { color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, shape: { classPropertyName: "shape", publicName: "shape", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, iconPosition: { classPropertyName: "iconPosition", publicName: "iconPosition", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, outlined: { classPropertyName: "outlined", publicName: "outlined", isSignal: true, isRequired: false, transformFunction: null }, block: { classPropertyName: "block", publicName: "block", isSignal: true, isRequired: false, transformFunction: null }, loading: { classPropertyName: "loading", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null }, disabledWhenLoading: { classPropertyName: "disabledWhenLoading", publicName: "disabledWhenLoading", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "keydown": "onHostKeydown($event)", "focus": "onHostFocus()", "blur": "onHostBlur()" }, properties: { "class": "classes()", "attr.disabled": "nativeDisabled()", "attr.aria-busy": "loading() ? \"true\" : null", "attr.role": "hostRole()", "attr.tabindex": "hostTabIndex()", "attr.aria-disabled": "hostAriaDisabled()" } }, ngImport: i0, template: "@if (loading()) {\n <wr-spinner class=\"wr-btn__spin\" size=\"sm\" />\n}\n\n@if (icon(); as name) {\n <wr-icon class=\"wr-btn__icon\" [name]=\"name\" />\n}\n\n<span class=\"wr-btn__label\">\n <ng-content />\n</span>\n", dependencies: [{ kind: "component", type: WrIcon, selector: "wr-icon", inputs: ["name"] }, { kind: "component", type: WrSpinner, selector: "wr-spinner", inputs: ["size", "ariaLabel"] }], encapsulation: i0.ViewEncapsulation.None });
194
270
  }
195
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrButton, decorators: [{
271
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrButton, decorators: [{
196
272
  type: Component,
197
273
  args: [{ selector: 'wr-btn, button[wr-btn], a[wr-btn]', encapsulation: ViewEncapsulation.None, host: {
198
274
  '[class]': 'classes()',
@@ -204,8 +280,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImpor
204
280
  '[attr.tabindex]': 'hostTabIndex()',
205
281
  '[attr.aria-disabled]': 'hostAriaDisabled()',
206
282
  '(keydown)': 'onHostKeydown($event)',
283
+ '(focus)': 'onHostFocus()',
284
+ '(blur)': 'onHostBlur()',
207
285
  }, imports: [WrIcon, WrSpinner], template: "@if (loading()) {\n <wr-spinner class=\"wr-btn__spin\" size=\"sm\" />\n}\n\n@if (icon(); as name) {\n <wr-icon class=\"wr-btn__icon\" [name]=\"name\" />\n}\n\n<span class=\"wr-btn__label\">\n <ng-content />\n</span>\n" }]
208
- }], propDecorators: { color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], shape: [{ type: i0.Input, args: [{ isSignal: true, alias: "shape", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], iconPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconPosition", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], outlined: [{ type: i0.Input, args: [{ isSignal: true, alias: "outlined", required: false }] }], block: [{ type: i0.Input, args: [{ isSignal: true, alias: "block", required: false }] }], loading: [{ type: i0.Input, args: [{ isSignal: true, alias: "loading", required: false }] }], disabledWhenLoading: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabledWhenLoading", required: false }] }] } });
286
+ }], ctorParameters: () => [], propDecorators: { color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], shape: [{ type: i0.Input, args: [{ isSignal: true, alias: "shape", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], iconPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconPosition", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], outlined: [{ type: i0.Input, args: [{ isSignal: true, alias: "outlined", required: false }] }], block: [{ type: i0.Input, args: [{ isSignal: true, alias: "block", required: false }] }], loading: [{ type: i0.Input, args: [{ isSignal: true, alias: "loading", required: false }] }], disabledWhenLoading: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabledWhenLoading", required: false }] }] } });
209
287
 
210
288
  /**
211
289
  * @license
@@ -253,10 +331,10 @@ class WrButtonGroup {
253
331
  return parts.join(' ');
254
332
  }, /* @ts-ignore */
255
333
  ...(ngDevMode ? [{ debugName: "hostClasses" }] : /* istanbul ignore next */ []));
256
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrButtonGroup, deps: [], target: i0.ɵɵFactoryTarget.Component });
257
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.4", type: WrButtonGroup, isStandalone: true, selector: "wr-btn-group", inputs: { shape: { classPropertyName: "shape", publicName: "shape", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "group" }, properties: { "class": "hostClasses()" } }, providers: [{ provide: WR_BUTTON_GROUP, useExisting: forwardRef(() => WrButtonGroup) }], ngImport: i0, template: '<ng-content />', isInline: true, encapsulation: i0.ViewEncapsulation.None });
334
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrButtonGroup, deps: [], target: i0.ɵɵFactoryTarget.Component });
335
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.5", type: WrButtonGroup, isStandalone: true, selector: "wr-btn-group", inputs: { shape: { classPropertyName: "shape", publicName: "shape", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "group" }, properties: { "class": "hostClasses()" } }, providers: [{ provide: WR_BUTTON_GROUP, useExisting: forwardRef(() => WrButtonGroup) }], ngImport: i0, template: '<ng-content />', isInline: true, encapsulation: i0.ViewEncapsulation.None });
258
336
  }
259
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrButtonGroup, decorators: [{
337
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrButtonGroup, decorators: [{
260
338
  type: Component,
261
339
  args: [{
262
340
  selector: 'wr-btn-group',
@@ -1 +1 @@
1
- {"version":3,"file":"ngwr-button.mjs","sources":["../../../projects/lib/button/tokens/button-group.token.ts","../../../projects/lib/button/button.ts","../../../projects/lib/button/button.html","../../../projects/lib/button/button-group.ts","../../../projects/lib/button/ngwr-button.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 { InjectionToken, type Signal } from '@angular/core';\n\nimport type { WrButtonShape } from '../interfaces';\n\n/**\n * Contract a child `<wr-btn>` reads from its enclosing `<wr-btn-group>`.\n *\n * @internal\n */\nexport interface WrButtonGroupContext {\n /** Shape cascade — child buttons fall back to this when they don't set their own. */\n readonly shape: Signal<WrButtonShape | null>;\n}\n\n/**\n * Token a `<wr-btn>` injects to discover its parent `<wr-btn-group>`. The\n * group provides itself via this token so children can react to the\n * group's `shape` cascade.\n *\n * @internal\n */\nexport const WR_BUTTON_GROUP = new InjectionToken<WrButtonGroupContext>('WR_BUTTON_GROUP');\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 { coerceBooleanProperty } from '@angular/cdk/coercion';\nimport { Component, ElementRef, ViewEncapsulation, computed, inject, input } from '@angular/core';\n\nimport { useConfigValue } from 'ngwr/config';\nimport { WrIcon, type WrIconName } from 'ngwr/icon';\nimport { WrSpinner } from 'ngwr/spinner';\nimport type { WrColor } from 'ngwr/theme';\n\nimport type { WrButtonIconPosition, WrButtonShape, WrButtonSize } from './interfaces';\nimport { WR_BUTTON_GROUP } from './tokens';\n\n/**\n * Trigger an action. Renders as a `<wr-btn>` element, or attach to a\n * native `<button>` / `<a>` via the `wr-btn` attribute selector.\n *\n * @example\n * ```html\n * <button wr-btn color=\"primary\">Save</button>\n * <a wr-btn color=\"primary\" outlined>Cancel</a>\n * <wr-btn color=\"danger\" icon=\"trash\">Delete</wr-btn>\n * <wr-btn color=\"primary\" shape=\"pill\">Pill</wr-btn>\n * ```\n *\n * **Squircle?** Wrap with `[wrSquircle]` — the directive is the only\n * way ngwr ships smooth-corner clip-paths:\n *\n * ```html\n * <wr-btn wrSquircle [radius]=\"14\">Squircle</wr-btn>\n * ```\n *\n * Inside a `<wr-btn-group shape=\"…\">`, the group's shape is enforced on\n * every child — child `[shape]` inputs are ignored so the group reads as\n * one coherent control.\n *\n * @see https://ngwr.dev/reference/components/button\n */\n@Component({\n selector: 'wr-btn, button[wr-btn], a[wr-btn]',\n templateUrl: './button.html',\n encapsulation: ViewEncapsulation.None,\n host: {\n '[class]': 'classes()',\n '[attr.disabled]': 'nativeDisabled()',\n '[attr.aria-busy]': 'loading() ? \"true\" : null',\n // The three below apply ONLY to the `<wr-btn>` element form — see\n // `isCustomHost`. A native `<button>` / `<a>` already has all of it.\n '[attr.role]': 'hostRole()',\n '[attr.tabindex]': 'hostTabIndex()',\n '[attr.aria-disabled]': 'hostAriaDisabled()',\n '(keydown)': 'onHostKeydown($event)',\n },\n imports: [WrIcon, WrSpinner],\n})\nexport class WrButton {\n /**\n * Color variant. Omit for the neutral default style.\n *\n * Deliberately NOT configurable app-wide: the library's own chrome binds\n * `[color]=\"isCurrent ? 'primary' : null\"`, where `null` means neutral, and a\n * configured intent would repaint every one of those buttons. See `WrConfig`.\n *\n * @default null\n */\n readonly color = input<WrColor | null>(null);\n\n /**\n * Size variant. Unset, it resolves through\n * `provideWrConfig({ button: { size } })` and then to `md`.\n *\n * @default 'md'\n */\n readonly size = input<WrButtonSize | null>(null);\n\n /**\n * Corner treatment — `rounded`, `pill` or `squircle`. `null` (default) falls\n * back to `rounded`. Inside a `<wr-btn-group shape=\"…\">`, the group's shape\n * ALWAYS wins over this input — the group enforces a consistent corner\n * treatment across its members.\n *\n * @default null\n */\n readonly shape = input<WrButtonShape | null>(null);\n\n /**\n * Icon name to render alongside the label. The icon is hidden while\n * `loading` is `true` so the spinner can take its place.\n *\n * @default null\n */\n readonly icon = input<WrIconName | null>(null);\n\n /** Position of the icon relative to the label. @default 'start' */\n readonly iconPosition = input<WrButtonIconPosition>('start');\n\n /** Disable the button. @default false */\n readonly disabled = input(false, { transform: coerceBooleanProperty });\n\n /** Outlined variant — colored text and border on a transparent background. @default false */\n readonly outlined = input(false, { transform: coerceBooleanProperty });\n\n /** Stretch the button to fill its parent's width. @default false */\n readonly block = input(false, { transform: coerceBooleanProperty });\n\n /** Show a spinner overlaying the label. Layout is preserved. @default false */\n readonly loading = input(false, { transform: coerceBooleanProperty });\n\n /**\n * When `loading` is `true` and this is also `true`, pointer events are\n * suppressed and the button reports as disabled to assistive tech.\n *\n * @default true\n */\n readonly disabledWhenLoading = input(true, { transform: coerceBooleanProperty });\n\n private readonly group = inject(WR_BUTTON_GROUP, { optional: true });\n\n /** The size, or the app-wide default, or `md`. @see useConfigValue */\n protected readonly resolvedSize = useConfigValue<WrButtonSize>(this.size, c => c.button?.size, 'md');\n\n /**\n * Resolved shape. Inside a `<wr-btn-group>`, the group ALWAYS wins — child\n * `[shape]` is ignored entirely so the group reads as one coherent control.\n * Outside a group, the button's own `[shape]` is used, falling back to\n * `rounded`. Not config-resolved: see `WrConfig` for why a boolean cannot\n * express this three-valued input.\n */\n protected readonly resolvedShape = computed<WrButtonShape>(() =>\n this.group ? (this.group.shape() ?? 'rounded') : (this.shape() ?? 'rounded')\n );\n\n private readonly hostEl = inject<ElementRef<HTMLElement>>(ElementRef);\n\n /**\n * Whether this instance is the `<wr-btn>` ELEMENT rather than the attribute\n * form on a native `<button>` / `<a>`.\n *\n * The element form is documented as first-class and is what the pagination,\n * event-calendar and popconfirm chrome use — but a custom element has no\n * button semantics of its own. It was rendering with no `role`, no\n * `tabindex` and no keyboard activation, so it was invisible to assistive\n * tech and unreachable by Tab. Measured in Chromium against the built site:\n * the whole `wr-pagination` subtree, 26 elements, contained ZERO focusable\n * nodes and sixty Tab presses never entered it. axe cannot see this — an\n * unknown element with no role simply is not an interactive control to it,\n * which is the same blind spot that lets `disabled` pass unnoticed on a\n * custom element.\n */\n private readonly isCustomHost = this.hostEl.nativeElement.tagName === 'WR-BTN';\n\n private readonly isOff = computed(() => this.disabled() || (this.loading() && this.disabledWhenLoading()));\n\n protected readonly nativeDisabled = computed<'' | null>(() => (this.isOff() ? '' : null));\n\n protected readonly hostRole = computed<'button' | null>(() => (this.isCustomHost ? 'button' : null));\n\n /** Out of the tab order while off — `disabled` is inert on a custom element. */\n protected readonly hostTabIndex = computed<'0' | null>(() => (this.isCustomHost && !this.isOff() ? '0' : null));\n\n protected readonly hostAriaDisabled = computed<'true' | null>(() =>\n this.isCustomHost && this.isOff() ? 'true' : null\n );\n\n /**\n * Enter and Space activate a button. A native one does this for free; a\n * custom element does not, so without this the element form could be focused\n * (once it had a tabindex) and still not be operable.\n *\n * `preventDefault` on Space is not optional — it scrolls the page otherwise.\n * The pointer path needs no guard here: `.wr-btn[disabled]` already sets\n * `pointer-events: none`.\n */\n protected onHostKeydown(event: KeyboardEvent): void {\n if (!this.isCustomHost) return;\n if (event.key !== 'Enter' && event.key !== ' ') return;\n\n event.preventDefault();\n if (this.isOff()) return;\n this.hostEl.nativeElement.click();\n }\n\n protected readonly classes = computed(() => {\n const parts = ['wr-btn'];\n\n const color = this.color();\n if (color) parts.push(`wr-btn--${color}`);\n\n const size = this.resolvedSize();\n if (size !== 'md') parts.push(`wr-btn--${size}`);\n\n const shape = this.resolvedShape();\n if (shape !== 'rounded') parts.push(`wr-btn--${shape}`);\n\n if (this.outlined()) parts.push('wr-btn--outlined');\n if (this.block()) parts.push('wr-btn--block');\n if (this.loading()) parts.push('wr-btn--loading');\n\n const hasAdornment = !!this.icon() || this.loading();\n if (hasAdornment) parts.push(`wr-btn--icon-${this.iconPosition()}`);\n\n return parts.join(' ');\n });\n}\n","@if (loading()) {\n <wr-spinner class=\"wr-btn__spin\" size=\"sm\" />\n}\n\n@if (icon(); as name) {\n <wr-icon class=\"wr-btn__icon\" [name]=\"name\" />\n}\n\n<span class=\"wr-btn__label\">\n <ng-content />\n</span>\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 { Component, ViewEncapsulation, computed, forwardRef, input } from '@angular/core';\n\nimport type { WrButtonShape } from './interfaces';\nimport { WR_BUTTON_GROUP, type WrButtonGroupContext } from './tokens';\n\n/**\n * Visually group buttons by merging their borders. Optionally enforce a\n * single corner treatment across every child via `[shape]` — child\n * `<wr-btn>` `[shape]` inputs are ignored when set on the group.\n *\n * @example\n * ```html\n * <wr-btn-group>\n * <button wr-btn>Left</button>\n * <button wr-btn>Middle</button>\n * <button wr-btn>Right</button>\n * </wr-btn-group>\n *\n * <wr-btn-group shape=\"pill\">\n * <button wr-btn>One</button>\n * <button wr-btn>Two</button>\n * <button wr-btn>Three</button>\n * </wr-btn-group>\n * ```\n *\n * @see https://ngwr.dev/reference/components/button-group\n */\n@Component({\n selector: 'wr-btn-group',\n template: '<ng-content />',\n encapsulation: ViewEncapsulation.None,\n host: {\n '[class]': 'hostClasses()',\n role: 'group',\n },\n // forwardRef required: WrButtonGroup is self-referenced before its declaration ends.\n // eslint-disable-next-line @angular-eslint/no-forward-ref\n providers: [{ provide: WR_BUTTON_GROUP, useExisting: forwardRef(() => WrButtonGroup) }],\n})\nexport class WrButtonGroup implements WrButtonGroupContext {\n /**\n * Corner treatment enforced on every child `<wr-btn>`. Child `[shape]`\n * inputs are ignored when this is set — the group exists to make a\n * uniform control. `null` (default) leaves children alone.\n *\n * @default null\n */\n readonly shape = input<WrButtonShape | null>(null);\n\n protected readonly hostClasses = computed(() => {\n const parts = ['wr-btn-group'];\n const s = this.shape();\n if (s) parts.push(`wr-btn-group--${s}`);\n return parts.join(' ');\n });\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;AAAA;;;;;AAKG;AAgBH;;;;;;AAMG;AACI,MAAM,eAAe,GAAG,IAAI,cAAc,CAAuB,iBAAiB,CAAC;;AC5B1F;;;;;AAKG;AAaH;;;;;;;;;;;;;;;;;;;;;;;;AAwBG;MAkBU,QAAQ,CAAA;AACnB;;;;;;;;AAQG;IACM,KAAK,GAAG,KAAK,CAAiB,IAAI;8EAAC;AAE5C;;;;;AAKG;IACM,IAAI,GAAG,KAAK,CAAsB,IAAI;6EAAC;AAEhD;;;;;;;AAOG;IACM,KAAK,GAAG,KAAK,CAAuB,IAAI;8EAAC;AAElD;;;;;AAKG;IACM,IAAI,GAAG,KAAK,CAAoB,IAAI;6EAAC;;IAGrC,YAAY,GAAG,KAAK,CAAuB,OAAO;qFAAC;;IAGnD,QAAQ,GAAG,KAAK,CAAC,KAAK,gFAAI,SAAS,EAAE,qBAAqB,EAAA,CAAG;;IAG7D,QAAQ,GAAG,KAAK,CAAC,KAAK,gFAAI,SAAS,EAAE,qBAAqB,EAAA,CAAG;;IAG7D,KAAK,GAAG,KAAK,CAAC,KAAK,6EAAI,SAAS,EAAE,qBAAqB,EAAA,CAAG;;IAG1D,OAAO,GAAG,KAAK,CAAC,KAAK,+EAAI,SAAS,EAAE,qBAAqB,EAAA,CAAG;AAErE;;;;;AAKG;IACM,m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eAAe,EAAE,WAAW,EAAE,UAAU,CAAC,MAAM,aAAa,CAAC,EAAE,CAAC,0BAR7E,gBAAgB,EAAA,QAAA,EAAA,IAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA;;2FAUf,aAAa,EAAA,UAAA,EAAA,CAAA;kBAZzB,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,cAAc;AACxB,oBAAA,QAAQ,EAAE,gBAAgB;oBAC1B,aAAa,EAAE,iBAAiB,CAAC,IAAI;AACrC,oBAAA,IAAI,EAAE;AACJ,wBAAA,SAAS,EAAE,eAAe;AAC1B,wBAAA,IAAI,EAAE,OAAO;AACd,qBAAA;;;AAGD,oBAAA,SAAS,EAAE,CAAC,EAAE,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,UAAU,CAAC,MAAK,aAAc,CAAC,EAAE,CAAC;AACxF,iBAAA;;;AC7CD;;AAEG;;;;"}
1
+ {"version":3,"file":"ngwr-button.mjs","sources":["../../../projects/lib/button/tokens/button-group.token.ts","../../../projects/lib/button/button.ts","../../../projects/lib/button/button.html","../../../projects/lib/button/button-group.ts","../../../projects/lib/button/ngwr-button.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 { InjectionToken, type Signal } from '@angular/core';\n\nimport type { WrButtonShape } from '../interfaces';\n\n/**\n * Contract a child `<wr-btn>` reads from its enclosing `<wr-btn-group>`.\n *\n * @internal\n */\nexport interface WrButtonGroupContext {\n /** Shape cascade — child buttons fall back to this when they don't set their own. */\n readonly shape: Signal<WrButtonShape | null>;\n}\n\n/**\n * Token a `<wr-btn>` injects to discover its parent `<wr-btn-group>`. The\n * group provides itself via this token so children can react to the\n * group's `shape` cascade.\n *\n * @internal\n */\nexport const WR_BUTTON_GROUP = new InjectionToken<WrButtonGroupContext>('WR_BUTTON_GROUP');\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 { coerceBooleanProperty } from '@angular/cdk/coercion';\nimport {\n Component,\n ElementRef,\n Injector,\n ViewEncapsulation,\n afterNextRender,\n computed,\n effect,\n inject,\n input,\n} from '@angular/core';\n\nimport { useConfigValue } from 'ngwr/config';\nimport { WrIcon, type WrIconName } from 'ngwr/icon';\nimport { WrSpinner } from 'ngwr/spinner';\nimport type { WrColor } from 'ngwr/theme';\n\nimport type { WrButtonIconPosition, WrButtonShape, WrButtonSize } from './interfaces';\nimport { WR_BUTTON_GROUP } from './tokens';\n\n/**\n * Trigger an action. Renders as a `<wr-btn>` element, or attach to a\n * native `<button>` / `<a>` via the `wr-btn` attribute selector.\n *\n * @example\n * ```html\n * <button wr-btn color=\"primary\">Save</button>\n * <a wr-btn color=\"primary\" outlined>Cancel</a>\n * <wr-btn color=\"danger\" icon=\"trash\">Delete</wr-btn>\n * <wr-btn color=\"primary\" shape=\"pill\">Pill</wr-btn>\n * ```\n *\n * **Squircle?** Wrap with `[wrSquircle]` — the directive is the only\n * way ngwr ships smooth-corner clip-paths:\n *\n * ```html\n * <wr-btn wrSquircle [radius]=\"14\">Squircle</wr-btn>\n * ```\n *\n * Inside a `<wr-btn-group shape=\"…\">`, the group's shape is enforced on\n * every child — child `[shape]` inputs are ignored so the group reads as\n * one coherent control.\n *\n * **Inside a `<form>`, use the native form.** `<wr-btn>` is a custom element\n * carrying `role=\"button\"`, and no custom element submits a form — the platform\n * submits for `<button>`, `<input type=\"submit\">` and `<input type=\"image\">`\n * and nothing else. That is why there is no `type` input: it would look like it\n * worked. Implicit submission (Enter in a text field) does not reach it either.\n *\n * ```html\n * <button wr-btn type=\"submit\" color=\"primary\">Save</button>\n * ```\n *\n * @see https://ngwr.dev/reference/components/button\n */\n@Component({\n selector: 'wr-btn, button[wr-btn], a[wr-btn]',\n templateUrl: './button.html',\n encapsulation: ViewEncapsulation.None,\n host: {\n '[class]': 'classes()',\n '[attr.disabled]': 'nativeDisabled()',\n '[attr.aria-busy]': 'loading() ? \"true\" : null',\n // The three below apply ONLY to the `<wr-btn>` element form — see\n // `isCustomHost`. A native `<button>` / `<a>` already has all of it.\n '[attr.role]': 'hostRole()',\n '[attr.tabindex]': 'hostTabIndex()',\n '[attr.aria-disabled]': 'hostAriaDisabled()',\n '(keydown)': 'onHostKeydown($event)',\n '(focus)': 'onHostFocus()',\n '(blur)': 'onHostBlur()',\n },\n imports: [WrIcon, WrSpinner],\n})\nexport class WrButton {\n /**\n * Color variant. Omit for the neutral default style.\n *\n * Deliberately NOT configurable app-wide: the library's own chrome binds\n * `[color]=\"isCurrent ? 'primary' : null\"`, where `null` means neutral, and a\n * configured intent would repaint every one of those buttons. See `WrConfig`.\n *\n * @default null\n */\n readonly color = input<WrColor | null>(null);\n\n /**\n * Size variant. Unset, it resolves through\n * `provideWrConfig({ button: { size } })` and then to `md`.\n *\n * @default 'md'\n */\n readonly size = input<WrButtonSize | null>(null);\n\n /**\n * Corner treatment — `rounded`, `pill` or `squircle`. `null` (default) falls\n * back to `rounded`. Inside a `<wr-btn-group shape=\"…\">`, the group's shape\n * ALWAYS wins over this input — the group enforces a consistent corner\n * treatment across its members.\n *\n * @default null\n */\n readonly shape = input<WrButtonShape | null>(null);\n\n /**\n * Icon name to render alongside the label. The icon is hidden while\n * `loading` is `true` so the spinner can take its place.\n *\n * @default null\n */\n readonly icon = input<WrIconName | null>(null);\n\n /** Position of the icon relative to the label. @default 'start' */\n readonly iconPosition = input<WrButtonIconPosition>('start');\n\n /** Disable the button. @default false */\n readonly disabled = input(false, { transform: coerceBooleanProperty });\n\n /** Outlined variant — colored text and border on a transparent background. @default false */\n readonly outlined = input(false, { transform: coerceBooleanProperty });\n\n /** Stretch the button to fill its parent's width. @default false */\n readonly block = input(false, { transform: coerceBooleanProperty });\n\n /** Show a spinner overlaying the label. Layout is preserved. @default false */\n readonly loading = input(false, { transform: coerceBooleanProperty });\n\n /**\n * When `loading` is `true` and this is also `true`, pointer events are\n * suppressed and the button reports as disabled to assistive tech.\n *\n * @default true\n */\n readonly disabledWhenLoading = input(true, { transform: coerceBooleanProperty });\n\n private readonly group = inject(WR_BUTTON_GROUP, { optional: true });\n\n /** The size, or the app-wide default, or `md`. @see useConfigValue */\n protected readonly resolvedSize = useConfigValue<WrButtonSize>(this.size, c => c.button?.size, 'md');\n\n /**\n * Resolved shape. Inside a `<wr-btn-group>`, the group ALWAYS wins — child\n * `[shape]` is ignored entirely so the group reads as one coherent control.\n * Outside a group, the button's own `[shape]` is used, falling back to\n * `rounded`. Not config-resolved: see `WrConfig` for why a boolean cannot\n * express this three-valued input.\n */\n protected readonly resolvedShape = computed<WrButtonShape>(() =>\n this.group ? (this.group.shape() ?? 'rounded') : (this.shape() ?? 'rounded')\n );\n\n private readonly hostEl = inject<ElementRef<HTMLElement>>(ElementRef);\n\n /**\n * Whether this instance is the `<wr-btn>` ELEMENT rather than the attribute\n * form on a native `<button>` / `<a>`.\n *\n * The element form is documented as first-class and is what the pagination,\n * event-calendar and popconfirm chrome use — but a custom element has no\n * button semantics of its own. It was rendering with no `role`, no\n * `tabindex` and no keyboard activation, so it was invisible to assistive\n * tech and unreachable by Tab. Measured in Chromium against the built site:\n * the whole `wr-pagination` subtree, 26 elements, contained ZERO focusable\n * nodes and sixty Tab presses never entered it. axe cannot see this — an\n * unknown element with no role simply is not an interactive control to it,\n * which is the same blind spot that lets `disabled` pass unnoticed on a\n * custom element.\n */\n private readonly isCustomHost = this.hostEl.nativeElement.tagName === 'WR-BTN';\n\n private readonly isOff = computed(() => this.disabled() || (this.loading() && this.disabledWhenLoading()));\n\n protected readonly nativeDisabled = computed<'' | null>(() => (this.isOff() ? '' : null));\n\n protected readonly hostRole = computed<'button' | null>(() => (this.isCustomHost ? 'button' : null));\n\n /** Out of the tab order while off — `disabled` is inert on a custom element. */\n protected readonly hostTabIndex = computed<'0' | null>(() => (this.isCustomHost && !this.isOff() ? '0' : null));\n\n protected readonly hostAriaDisabled = computed<'true' | null>(() =>\n this.isCustomHost && this.isOff() ? 'true' : null\n );\n\n /**\n * Enter and Space activate a button. A native one does this for free; a\n * custom element does not, so without this the element form could be focused\n * (once it had a tabindex) and still not be operable.\n *\n * `preventDefault` on Space is not optional — it scrolls the page otherwise.\n * The pointer path needs no guard here: `.wr-btn[disabled]` already sets\n * `pointer-events: none`.\n */\n protected onHostKeydown(event: KeyboardEvent): void {\n if (!this.isCustomHost) return;\n if (event.key !== 'Enter' && event.key !== ' ') return;\n\n event.preventDefault();\n if (this.isOff()) return;\n this.hostEl.nativeElement.click();\n }\n\n private readonly injector = inject(Injector);\n\n /**\n * Whether this button is the one the caret was on, so it can be handed back\n * the focus that goes missing while it is off.\n *\n * A control that becomes `disabled` while focused stops being a focusable\n * area, and the browser runs the unfocusing steps: nothing else is nominated,\n * so the caret lands on `<body>`. With `disabledWhenLoading` on by default\n * that happens on EVERY async button — a keyboard user presses Enter on\n * \"Save\" and the next Tab restarts from the top of the document, while a\n * screen-reader user is told neither that the wait began nor that it ended,\n * because the element they were on has left the a11y tree. The `<wr-btn>`\n * element form loses its `tabindex` instead of gaining `disabled` and is\n * unfocused for the same reason.\n *\n * Deliberately NOT keyed on reading `activeElement` when `isOff()` flips: an\n * effect in this component's own view runs AFTER the parent has applied this\n * directive's host bindings, so by then the attribute has landed and the\n * browser has already moved the caret — the read would answer `<body>` on\n * every real browser and the button on jsdom, which is the worst of both.\n *\n * The flag is written by the focus listeners instead, and a `blur` fired\n * WHILE off keeps it set rather than clearing it: that blur is the browser\n * taking the caret away, not the user leaving. A browser that fires no blur\n * on disable at all is covered too — the flag simply stays as `focus` left it,\n * and the `<body>` test below is what decides whether the focus is orphaned.\n */\n private hadFocus = false;\n\n /** @internal Host `focus` — see `hadFocus`. */\n protected onHostFocus(): void {\n this.hadFocus = true;\n }\n\n /** @internal Host `blur` — see `hadFocus`. */\n protected onHostBlur(): void {\n this.hadFocus = this.isOff();\n }\n\n constructor() {\n effect(() => {\n if (this.isOff()) return;\n if (!this.hadFocus) return;\n const el = this.hostEl.nativeElement;\n\n // Deferred: the host binding that drops `disabled` (or restores the\n // `tabindex`) has not necessarily run yet, and `focus()` on a still\n // disabled element is a silent no-op — the exact failure this is here to\n // fix.\n afterNextRender(\n () => {\n if (!this.hadFocus || this.isOff()) return;\n const doc = el.ownerDocument;\n const active = doc?.activeElement ?? null;\n // Still ours — nothing was ever taken away, so keep the flag for the\n // cycle that does take it.\n if (active === el) return;\n // Someone else owns the caret now: a user who tabbed on while the\n // request was in flight must not be yanked back to a button they have\n // finished with.\n this.hadFocus = false;\n if (active && doc && active !== doc.body) return;\n el.focus();\n },\n { injector: this.injector }\n );\n });\n }\n\n protected readonly classes = computed(() => {\n const parts = ['wr-btn'];\n\n const color = this.color();\n if (color) parts.push(`wr-btn--${color}`);\n\n const size = this.resolvedSize();\n if (size !== 'md') parts.push(`wr-btn--${size}`);\n\n const shape = this.resolvedShape();\n if (shape !== 'rounded') parts.push(`wr-btn--${shape}`);\n\n if (this.outlined()) parts.push('wr-btn--outlined');\n if (this.block()) parts.push('wr-btn--block');\n if (this.loading()) parts.push('wr-btn--loading');\n\n const hasAdornment = !!this.icon() || this.loading();\n if (hasAdornment) parts.push(`wr-btn--icon-${this.iconPosition()}`);\n\n return parts.join(' ');\n });\n}\n","@if (loading()) {\n <wr-spinner class=\"wr-btn__spin\" size=\"sm\" />\n}\n\n@if (icon(); as name) {\n <wr-icon class=\"wr-btn__icon\" [name]=\"name\" />\n}\n\n<span class=\"wr-btn__label\">\n <ng-content />\n</span>\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 { Component, ViewEncapsulation, computed, forwardRef, input } from '@angular/core';\n\nimport type { WrButtonShape } from './interfaces';\nimport { WR_BUTTON_GROUP, type WrButtonGroupContext } from './tokens';\n\n/**\n * Visually group buttons by merging their borders. Optionally enforce a\n * single corner treatment across every child via `[shape]` — child\n * `<wr-btn>` `[shape]` inputs are ignored when set on the group.\n *\n * @example\n * ```html\n * <wr-btn-group>\n * <button wr-btn>Left</button>\n * <button wr-btn>Middle</button>\n * <button wr-btn>Right</button>\n * </wr-btn-group>\n *\n * <wr-btn-group shape=\"pill\">\n * <button wr-btn>One</button>\n * <button wr-btn>Two</button>\n * <button wr-btn>Three</button>\n * </wr-btn-group>\n * ```\n *\n * @see https://ngwr.dev/reference/components/button-group\n */\n@Component({\n selector: 'wr-btn-group',\n template: '<ng-content />',\n encapsulation: ViewEncapsulation.None,\n host: {\n '[class]': 'hostClasses()',\n role: 'group',\n },\n // forwardRef required: WrButtonGroup is self-referenced before its declaration ends.\n // eslint-disable-next-line @angular-eslint/no-forward-ref\n providers: [{ provide: WR_BUTTON_GROUP, useExisting: forwardRef(() => WrButtonGroup) }],\n})\nexport class WrButtonGroup implements WrButtonGroupContext {\n /**\n * Corner treatment enforced on every child `<wr-btn>`. Child `[shape]`\n * inputs are ignored when this is set — the group exists to make a\n * uniform control. `null` (default) leaves children alone.\n *\n * @default null\n */\n readonly shape = input<WrButtonShape | null>(null);\n\n protected readonly hostClasses = computed(() => {\n const parts = ['wr-btn-group'];\n const s = this.shape();\n if (s) parts.push(`wr-btn-group--${s}`);\n return parts.join(' ');\n });\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;AAAA;;;;;AAKG;AAgBH;;;;;;AAMG;AACI,MAAM,eAAe,GAAG,IAAI,cAAc,CAAuB,iBAAiB,CAAC;;AC5B1F;;;;;AAKG;AAuBH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAkCG;MAoBU,QAAQ,CAAA;AACnB;;;;;;;;AAQG;IACM,KAAK,GAAG,KAAK,CAAiB,IAAI;8EAAC;AAE5C;;;;;AAKG;IACM,IAAI,GAAG,KAAK,CAAsB,IAAI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C,IAAI,CAAC,iBAAiB,CAAC,CAAA,CAAE,CAAC;AACvC,QAAA,OAAO,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC;IACxB,CAAC;oFAAC;uGAfS,aAAa,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAb,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,aAAa,oRAFb,CAAC,EAAE,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,UAAU,CAAC,MAAM,aAAa,CAAC,EAAE,CAAC,0BAR7E,gBAAgB,EAAA,QAAA,EAAA,IAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA;;2FAUf,aAAa,EAAA,UAAA,EAAA,CAAA;kBAZzB,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,cAAc;AACxB,oBAAA,QAAQ,EAAE,gBAAgB;oBAC1B,aAAa,EAAE,iBAAiB,CAAC,IAAI;AACrC,oBAAA,IAAI,EAAE;AACJ,wBAAA,SAAS,EAAE,eAAe;AAC1B,wBAAA,IAAI,EAAE,OAAO;AACd,qBAAA;;;AAGD,oBAAA,SAAS,EAAE,CAAC,EAAE,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,UAAU,CAAC,MAAK,aAAc,CAAC,EAAE,CAAC;AACxF,iBAAA;;;AC7CD;;AAEG;;;;"}
@@ -173,10 +173,10 @@ class WrCalendarHeatmap {
173
173
  return 0.75;
174
174
  return 1;
175
175
  }
176
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCalendarHeatmap, deps: [], target: i0.ɵɵFactoryTarget.Component });
177
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: WrCalendarHeatmap, isStandalone: true, selector: "wr-calendar-heatmap", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, endDate: { classPropertyName: "endDate", publicName: "endDate", isSignal: true, isRequired: false, transformFunction: null }, weeks: { classPropertyName: "weeks", publicName: "weeks", isSignal: true, isRequired: false, transformFunction: null }, cellSize: { classPropertyName: "cellSize", publicName: "cellSize", isSignal: true, isRequired: false, transformFunction: null }, cellGap: { classPropertyName: "cellGap", publicName: "cellGap", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, emptyColor: { classPropertyName: "emptyColor", publicName: "emptyColor", isSignal: true, isRequired: false, transformFunction: null }, showLabels: { classPropertyName: "showLabels", publicName: "showLabels", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "wr-calendar-heatmap" }, ngImport: i0, template: "<div\n class=\"wr-calendar-heatmap__grid\"\n role=\"img\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [style.--wr-heatmap-cell-size.px]=\"cellSize()\"\n [style.--wr-heatmap-cell-gap.px]=\"cellGap()\"\n [style.--wr-heatmap-columns]=\"columnCount()\"\n>\n @if (showLabels()) {\n <div class=\"wr-calendar-heatmap__weekdays\">\n @for (label of weekdayLabels(); track $index) {\n <span class=\"wr-calendar-heatmap__weekday\">{{ label }}</span>\n }\n </div>\n }\n\n <div class=\"wr-calendar-heatmap__cells\">\n @for (cell of cells(); track cell.iso) {\n <span\n class=\"wr-calendar-heatmap__cell\"\n [style.background]=\"colorFor(cell.intensity)\"\n [style.opacity]=\"opacityFor(cell.intensity)\"\n [style.grid-column]=\"cell.week + 1\"\n [style.grid-row]=\"cell.day + 1\"\n [title]=\"`${cell.iso}: ${cell.value}`\"\n aria-hidden=\"true\"\n ></span>\n }\n </div>\n\n @if (showLabels()) {\n <div class=\"wr-calendar-heatmap__months\">\n @for (m of monthLabels(); track $index) {\n <span class=\"wr-calendar-heatmap__month\" [style.grid-column]=\"m.week + 1\">{{ m.label }}</span>\n }\n </div>\n }\n</div>\n", encapsulation: i0.ViewEncapsulation.None });
176
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCalendarHeatmap, deps: [], target: i0.ɵɵFactoryTarget.Component });
177
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.5", type: WrCalendarHeatmap, isStandalone: true, selector: "wr-calendar-heatmap", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, endDate: { classPropertyName: "endDate", publicName: "endDate", isSignal: true, isRequired: false, transformFunction: null }, weeks: { classPropertyName: "weeks", publicName: "weeks", isSignal: true, isRequired: false, transformFunction: null }, cellSize: { classPropertyName: "cellSize", publicName: "cellSize", isSignal: true, isRequired: false, transformFunction: null }, cellGap: { classPropertyName: "cellGap", publicName: "cellGap", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, emptyColor: { classPropertyName: "emptyColor", publicName: "emptyColor", isSignal: true, isRequired: false, transformFunction: null }, showLabels: { classPropertyName: "showLabels", publicName: "showLabels", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "wr-calendar-heatmap" }, ngImport: i0, template: "<div\n class=\"wr-calendar-heatmap__grid\"\n role=\"img\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [style.--wr-heatmap-cell-size.px]=\"cellSize()\"\n [style.--wr-heatmap-cell-gap.px]=\"cellGap()\"\n [style.--wr-heatmap-columns]=\"columnCount()\"\n>\n @if (showLabels()) {\n <div class=\"wr-calendar-heatmap__weekdays\">\n @for (label of weekdayLabels(); track $index) {\n <span class=\"wr-calendar-heatmap__weekday\">{{ label }}</span>\n }\n </div>\n }\n\n <div class=\"wr-calendar-heatmap__cells\">\n @for (cell of cells(); track cell.iso) {\n <span\n class=\"wr-calendar-heatmap__cell\"\n [style.background]=\"colorFor(cell.intensity)\"\n [style.opacity]=\"opacityFor(cell.intensity)\"\n [style.grid-column]=\"cell.week + 1\"\n [style.grid-row]=\"cell.day + 1\"\n [title]=\"`${cell.iso}: ${cell.value}`\"\n aria-hidden=\"true\"\n ></span>\n }\n </div>\n\n @if (showLabels()) {\n <div class=\"wr-calendar-heatmap__months\">\n @for (m of monthLabels(); track $index) {\n <span class=\"wr-calendar-heatmap__month\" [style.grid-column]=\"m.week + 1\">{{ m.label }}</span>\n }\n </div>\n }\n</div>\n", encapsulation: i0.ViewEncapsulation.None });
178
178
  }
179
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCalendarHeatmap, decorators: [{
179
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCalendarHeatmap, decorators: [{
180
180
  type: Component,
181
181
  args: [{ selector: 'wr-calendar-heatmap', encapsulation: ViewEncapsulation.None, host: { class: 'wr-calendar-heatmap' }, template: "<div\n class=\"wr-calendar-heatmap__grid\"\n role=\"img\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [style.--wr-heatmap-cell-size.px]=\"cellSize()\"\n [style.--wr-heatmap-cell-gap.px]=\"cellGap()\"\n [style.--wr-heatmap-columns]=\"columnCount()\"\n>\n @if (showLabels()) {\n <div class=\"wr-calendar-heatmap__weekdays\">\n @for (label of weekdayLabels(); track $index) {\n <span class=\"wr-calendar-heatmap__weekday\">{{ label }}</span>\n }\n </div>\n }\n\n <div class=\"wr-calendar-heatmap__cells\">\n @for (cell of cells(); track cell.iso) {\n <span\n class=\"wr-calendar-heatmap__cell\"\n [style.background]=\"colorFor(cell.intensity)\"\n [style.opacity]=\"opacityFor(cell.intensity)\"\n [style.grid-column]=\"cell.week + 1\"\n [style.grid-row]=\"cell.day + 1\"\n [title]=\"`${cell.iso}: ${cell.value}`\"\n aria-hidden=\"true\"\n ></span>\n }\n </div>\n\n @if (showLabels()) {\n <div class=\"wr-calendar-heatmap__months\">\n @for (m of monthLabels(); track $index) {\n <span class=\"wr-calendar-heatmap__month\" [style.grid-column]=\"m.week + 1\">{{ m.label }}</span>\n }\n </div>\n }\n</div>\n" }]
182
182
  }], propDecorators: { data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], endDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "endDate", required: false }] }], weeks: [{ type: i0.Input, args: [{ isSignal: true, alias: "weeks", required: false }] }], cellSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "cellSize", required: false }] }], cellGap: [{ type: i0.Input, args: [{ isSignal: true, alias: "cellGap", required: false }] }], color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], emptyColor: [{ type: i0.Input, args: [{ isSignal: true, alias: "emptyColor", required: false }] }], showLabels: [{ type: i0.Input, args: [{ isSignal: true, alias: "showLabels", required: false }] }] } });
@@ -745,10 +745,10 @@ class WrCalendar {
745
745
  return 'ArrowRight';
746
746
  return key;
747
747
  }
748
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCalendar, deps: [], target: i0.ɵɵFactoryTarget.Component });
749
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: WrCalendar, isStandalone: true, selector: "wr-calendar", inputs: { mode: { classPropertyName: "mode", publicName: "mode", isSignal: true, isRequired: false, transformFunction: null }, date: { classPropertyName: "date", publicName: "date", isSignal: true, isRequired: false, transformFunction: null }, range: { classPropertyName: "range", publicName: "range", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, dateFilter: { classPropertyName: "dateFilter", publicName: "dateFilter", isSignal: true, isRequired: false, transformFunction: null }, autoFocus: { classPropertyName: "autoFocus", publicName: "autoFocus", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { date: "dateChange", range: "rangeChange" }, host: { listeners: { "keydown": "onKeyDown($event)" }, properties: { "class": "classes()" } }, ngImport: i0, template: "<div class=\"wr-calendar__header\">\n <button\n type=\"button\"\n class=\"wr-calendar__nav wr-calendar__nav--prev\"\n [attr.aria-label]=\"prevLabel()\"\n [disabled]=\"disabled()\"\n (click)=\"prev()\"\n >\n <svg\n width=\"18\"\n height=\"18\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"2\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n aria-hidden=\"true\"\n >\n <path d=\"m15 18-6-6 6-6\" />\n </svg>\n </button>\n <button\n type=\"button\"\n class=\"wr-calendar__label\"\n [disabled]=\"disabled() || viewMode() === 'year'\"\n (click)=\"onLabelClick()\"\n >\n {{ headerLabel() }}\n </button>\n <button\n type=\"button\"\n class=\"wr-calendar__nav wr-calendar__nav--next\"\n [attr.aria-label]=\"nextLabel()\"\n [disabled]=\"disabled()\"\n (click)=\"next()\"\n >\n <svg\n width=\"18\"\n height=\"18\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"2\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n aria-hidden=\"true\"\n >\n <path d=\"m9 18 6-6-6-6\" />\n </svg>\n </button>\n</div>\n\n@switch (viewMode()) {\n @case ('day') {\n <!--\n The weekday strip and the week rows are one grid, so they share a wrapper:\n `role=\"grid\"` may only own rows, and as siblings the header row had no grid\n parent at all. `.wr-calendar__body` repeats the host's column gap, so the\n rendered spacing is unchanged.\n -->\n <div class=\"wr-calendar__body\" role=\"grid\">\n <div class=\"wr-calendar__weekdays\" role=\"row\">\n @for (name of weekdayNames(); track name) {\n <span class=\"wr-calendar__weekday\" role=\"columnheader\">{{ name }}</span>\n }\n </div>\n\n <div class=\"wr-calendar__grid\" role=\"rowgroup\" (mouseleave)=\"onCellLeave()\">\n @for (week of weeks(); track $index) {\n <div class=\"wr-calendar__week\" role=\"row\">\n @for (day of week; track trackByTime($index, day)) {\n <button\n type=\"button\"\n class=\"wr-calendar__day\"\n role=\"gridcell\"\n [class.wr-calendar__day--today]=\"isToday(day)\"\n [class.wr-calendar__day--out-of-month]=\"isOutOfMonth(day)\"\n [class.wr-calendar__day--selected]=\"isSelected(day)\"\n [class.wr-calendar__day--in-range]=\"isInRange(day)\"\n [class.wr-calendar__day--range-preview]=\"isInRangePreview(day)\"\n [class.wr-calendar__day--focused]=\"isFocused(day)\"\n [disabled]=\"isDisabled(day)\"\n [attr.tabindex]=\"isFocused(day) ? 0 : -1\"\n [attr.aria-label]=\"dayLabel(day)\"\n [attr.aria-selected]=\"isSelected(day)\"\n [attr.aria-disabled]=\"isDisabled(day)\"\n (click)=\"onCellClick(day)\"\n (mouseenter)=\"onCellEnter(day)\"\n >\n {{ day.getDate() }}\n </button>\n }\n </div>\n }\n </div>\n </div>\n }\n\n @case ('month') {\n <!--\n A listbox owns its arrows, so its options share ONE tab stop: twelve months\n that were each tabbable announced a keyboard model \u2014 arrow to a month, Tab\n out of the list \u2014 that the component did not have. `activeChip()` is where\n the ring is, and it is always an enabled chip.\n -->\n <div class=\"wr-calendar__months\" role=\"listbox\">\n @for (name of monthsView(); track name) {\n <button\n type=\"button\"\n class=\"wr-calendar__chip\"\n role=\"option\"\n [class.wr-calendar__chip--current]=\"isMonthCurrent($index)\"\n [class.wr-calendar__chip--selected]=\"isMonthSelected($index)\"\n [disabled]=\"isMonthDisabled($index)\"\n [attr.tabindex]=\"activeChip() === $index ? 0 : -1\"\n [attr.aria-selected]=\"isMonthSelected($index)\"\n [attr.aria-disabled]=\"isMonthDisabled($index)\"\n (click)=\"onMonthSelect($index)\"\n >\n {{ name }}\n </button>\n }\n </div>\n }\n\n @case ('year') {\n <div class=\"wr-calendar__years\" role=\"listbox\">\n @for (year of yearsView(); track year) {\n <button\n type=\"button\"\n class=\"wr-calendar__chip\"\n role=\"option\"\n [class.wr-calendar__chip--current]=\"isYearCurrent(year)\"\n [class.wr-calendar__chip--selected]=\"isYearSelected(year)\"\n [disabled]=\"isYearDisabled(year)\"\n [attr.tabindex]=\"activeChip() === $index ? 0 : -1\"\n [attr.aria-selected]=\"isYearSelected(year)\"\n [attr.aria-disabled]=\"isYearDisabled(year)\"\n (click)=\"onYearSelect(year)\"\n >\n {{ year }}\n </button>\n }\n </div>\n }\n}\n", encapsulation: i0.ViewEncapsulation.None });
748
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCalendar, deps: [], target: i0.ɵɵFactoryTarget.Component });
749
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.5", type: WrCalendar, isStandalone: true, selector: "wr-calendar", inputs: { mode: { classPropertyName: "mode", publicName: "mode", isSignal: true, isRequired: false, transformFunction: null }, date: { classPropertyName: "date", publicName: "date", isSignal: true, isRequired: false, transformFunction: null }, range: { classPropertyName: "range", publicName: "range", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, dateFilter: { classPropertyName: "dateFilter", publicName: "dateFilter", isSignal: true, isRequired: false, transformFunction: null }, autoFocus: { classPropertyName: "autoFocus", publicName: "autoFocus", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { date: "dateChange", range: "rangeChange" }, host: { listeners: { "keydown": "onKeyDown($event)" }, properties: { "class": "classes()" } }, ngImport: i0, template: "<div class=\"wr-calendar__header\">\n <button\n type=\"button\"\n class=\"wr-calendar__nav wr-calendar__nav--prev\"\n [attr.aria-label]=\"prevLabel()\"\n [disabled]=\"disabled()\"\n (click)=\"prev()\"\n >\n <svg\n width=\"18\"\n height=\"18\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"2\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n aria-hidden=\"true\"\n >\n <path d=\"m15 18-6-6 6-6\" />\n </svg>\n </button>\n <button\n type=\"button\"\n class=\"wr-calendar__label\"\n [disabled]=\"disabled() || viewMode() === 'year'\"\n (click)=\"onLabelClick()\"\n >\n {{ headerLabel() }}\n </button>\n <button\n type=\"button\"\n class=\"wr-calendar__nav wr-calendar__nav--next\"\n [attr.aria-label]=\"nextLabel()\"\n [disabled]=\"disabled()\"\n (click)=\"next()\"\n >\n <svg\n width=\"18\"\n height=\"18\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n stroke-width=\"2\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n aria-hidden=\"true\"\n >\n <path d=\"m9 18 6-6-6-6\" />\n </svg>\n </button>\n</div>\n\n@switch (viewMode()) {\n @case ('day') {\n <!--\n The weekday strip and the week rows are one grid, so they share a wrapper:\n `role=\"grid\"` may only own rows, and as siblings the header row had no grid\n parent at all. `.wr-calendar__body` repeats the host's column gap, so the\n rendered spacing is unchanged.\n -->\n <div class=\"wr-calendar__body\" role=\"grid\">\n <div class=\"wr-calendar__weekdays\" role=\"row\">\n @for (name of weekdayNames(); track name) {\n <span class=\"wr-calendar__weekday\" role=\"columnheader\">{{ name }}</span>\n }\n </div>\n\n <div class=\"wr-calendar__grid\" role=\"rowgroup\" (mouseleave)=\"onCellLeave()\">\n @for (week of weeks(); track $index) {\n <div class=\"wr-calendar__week\" role=\"row\">\n @for (day of week; track trackByTime($index, day)) {\n <button\n type=\"button\"\n class=\"wr-calendar__day\"\n role=\"gridcell\"\n [class.wr-calendar__day--today]=\"isToday(day)\"\n [class.wr-calendar__day--out-of-month]=\"isOutOfMonth(day)\"\n [class.wr-calendar__day--selected]=\"isSelected(day)\"\n [class.wr-calendar__day--in-range]=\"isInRange(day)\"\n [class.wr-calendar__day--range-preview]=\"isInRangePreview(day)\"\n [class.wr-calendar__day--focused]=\"isFocused(day)\"\n [disabled]=\"isDisabled(day)\"\n [attr.tabindex]=\"isFocused(day) ? 0 : -1\"\n [attr.aria-label]=\"dayLabel(day)\"\n [attr.aria-selected]=\"isSelected(day)\"\n [attr.aria-disabled]=\"isDisabled(day)\"\n (click)=\"onCellClick(day)\"\n (mouseenter)=\"onCellEnter(day)\"\n >\n {{ day.getDate() }}\n </button>\n }\n </div>\n }\n </div>\n </div>\n }\n\n @case ('month') {\n <!--\n A listbox owns its arrows, so its options share ONE tab stop: twelve months\n that were each tabbable announced a keyboard model \u2014 arrow to a month, Tab\n out of the list \u2014 that the component did not have. `activeChip()` is where\n the ring is, and it is always an enabled chip.\n -->\n <div class=\"wr-calendar__months\" role=\"listbox\">\n @for (name of monthsView(); track name) {\n <button\n type=\"button\"\n class=\"wr-calendar__chip\"\n role=\"option\"\n [class.wr-calendar__chip--current]=\"isMonthCurrent($index)\"\n [class.wr-calendar__chip--selected]=\"isMonthSelected($index)\"\n [disabled]=\"isMonthDisabled($index)\"\n [attr.tabindex]=\"activeChip() === $index ? 0 : -1\"\n [attr.aria-selected]=\"isMonthSelected($index)\"\n [attr.aria-disabled]=\"isMonthDisabled($index)\"\n (click)=\"onMonthSelect($index)\"\n >\n {{ name }}\n </button>\n }\n </div>\n }\n\n @case ('year') {\n <div class=\"wr-calendar__years\" role=\"listbox\">\n @for (year of yearsView(); track year) {\n <button\n type=\"button\"\n class=\"wr-calendar__chip\"\n role=\"option\"\n [class.wr-calendar__chip--current]=\"isYearCurrent(year)\"\n [class.wr-calendar__chip--selected]=\"isYearSelected(year)\"\n [disabled]=\"isYearDisabled(year)\"\n [attr.tabindex]=\"activeChip() === $index ? 0 : -1\"\n [attr.aria-selected]=\"isYearSelected(year)\"\n [attr.aria-disabled]=\"isYearDisabled(year)\"\n (click)=\"onYearSelect(year)\"\n >\n {{ year }}\n </button>\n }\n </div>\n }\n}\n", encapsulation: i0.ViewEncapsulation.None });
750
750
  }
751
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCalendar, decorators: [{
751
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCalendar, decorators: [{
752
752
  type: Component,
753
753
  args: [{ selector: 'wr-calendar', encapsulation: ViewEncapsulation.None, host: {
754
754
  '[class]': 'classes()',
@@ -53,10 +53,10 @@ class WrCard {
53
53
  return parts.join(' ');
54
54
  }, /* @ts-ignore */
55
55
  ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
56
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCard, deps: [], target: i0.ɵɵFactoryTarget.Component });
57
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: WrCard, isStandalone: true, selector: "wr-card", inputs: { bordered: { classPropertyName: "bordered", publicName: "bordered", isSignal: true, isRequired: false, transformFunction: null }, hoverable: { classPropertyName: "hoverable", publicName: "hoverable", isSignal: true, isRequired: false, transformFunction: null }, loading: { classPropertyName: "loading", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null }, compact: { classPropertyName: "compact", publicName: "compact", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.aria-busy": "loading() ? true : null" } }, ngImport: i0, template: "<ng-content select=\"wr-card-header\" />\n<div class=\"wr-card__body\"><ng-content /></div>\n<ng-content select=\"wr-card-footer\" />\n@if (loading()) {\n <div class=\"wr-card__loading\" aria-hidden=\"true\">\n <span class=\"wr-card__spinner\"></span>\n </div>\n}\n", styles: [".wr-card{--wr-card-bg: var(--wr-color-surface);--wr-card-color: var(--wr-color-on-surface);--wr-card-border: var(--wr-color-outline);--wr-card-radius: var(--wr-border-radius-base);--wr-card-padding-y: 1rem;--wr-card-padding-x: 1.25rem;--wr-card-shadow: var(--wr-shadow-xs);--wr-card-shadow-hover: var(--wr-shadow-overlay);position:relative;display:flex;flex-direction:column;background:var(--wr-card-bg);color:var(--wr-card-color);border-radius:var(--wr-card-radius)}@supports (corner-shape: squircle){.wr-card{corner-shape:squircle;border-radius:calc(var(--wr-card-radius) * 1.85)}}.wr-card{box-shadow:var(--wr-card-shadow);font-family:var(--wr-font-family-base);transition:box-shadow var(--wr-transition-base),transform var(--wr-transition-base)}.wr-card--bordered{border:1px solid var(--wr-card-border)}.wr-card--hoverable{cursor:pointer}.wr-card--hoverable:hover{box-shadow:var(--wr-card-shadow-hover);transform:translateY(-1px)}.wr-card--compact{--wr-card-padding-y: .5rem;--wr-card-padding-x: .75rem}.wr-card--loading .wr-card__body{opacity:.6}.wr-card__header{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:var(--wr-card-padding-y) var(--wr-card-padding-x);border-bottom:1px solid var(--wr-card-border);font-weight:500}.wr-card__body{flex:1 1 auto;padding:var(--wr-card-padding-y) var(--wr-card-padding-x)}.wr-card__footer{display:flex;align-items:center;justify-content:flex-end;gap:.5rem;padding:var(--wr-card-padding-y) var(--wr-card-padding-x);border-top:1px solid var(--wr-card-border)}.wr-card__loading{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;border-radius:var(--wr-card-radius)}@supports (corner-shape: squircle){.wr-card__loading{corner-shape:squircle;border-radius:calc(var(--wr-card-radius) * 1.85)}}.wr-card__loading{background:rgba(var(--wr-color-surface-rgb),.5);pointer-events:none}.wr-card__spinner{width:1.5rem;height:1.5rem;border:2px solid rgb(var(--wr-color-on-surface-muted-rgb)/30%);border-top-color:var(--wr-color-primary);border-radius:50%;animation:wr-card-spin .7s linear infinite}@keyframes wr-card-spin{to{transform:rotate(360deg)}}\n"], encapsulation: i0.ViewEncapsulation.None });
56
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCard, deps: [], target: i0.ɵɵFactoryTarget.Component });
57
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.5", type: WrCard, isStandalone: true, selector: "wr-card", inputs: { bordered: { classPropertyName: "bordered", publicName: "bordered", isSignal: true, isRequired: false, transformFunction: null }, hoverable: { classPropertyName: "hoverable", publicName: "hoverable", isSignal: true, isRequired: false, transformFunction: null }, loading: { classPropertyName: "loading", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null }, compact: { classPropertyName: "compact", publicName: "compact", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.aria-busy": "loading() ? true : null" } }, ngImport: i0, template: "<ng-content select=\"wr-card-header\" />\n<div class=\"wr-card__body\"><ng-content /></div>\n<ng-content select=\"wr-card-footer\" />\n@if (loading()) {\n <div class=\"wr-card__loading\" aria-hidden=\"true\">\n <span class=\"wr-card__spinner\"></span>\n </div>\n}\n", styles: [".wr-card{--wr-card-bg: var(--wr-color-surface);--wr-card-color: var(--wr-color-on-surface);--wr-card-border: var(--wr-color-outline);--wr-card-radius: var(--wr-border-radius-base);--wr-card-padding-y: 1rem;--wr-card-padding-x: 1.25rem;--wr-card-shadow: var(--wr-shadow-xs);--wr-card-shadow-hover: var(--wr-shadow-overlay);position:relative;display:flex;flex-direction:column;background:var(--wr-card-bg);color:var(--wr-card-color);border-radius:var(--wr-card-radius)}@supports (corner-shape: squircle){.wr-card{corner-shape:squircle;border-radius:calc(var(--wr-card-radius) * 1.85)}}.wr-card{box-shadow:var(--wr-card-shadow);font-family:var(--wr-font-family-base);transition:box-shadow var(--wr-transition-base),transform var(--wr-transition-base)}.wr-card--bordered{border:1px solid var(--wr-card-border)}.wr-card--hoverable{cursor:pointer}.wr-card--hoverable:hover{box-shadow:var(--wr-card-shadow-hover);transform:translateY(-1px)}.wr-card--compact{--wr-card-padding-y: .5rem;--wr-card-padding-x: .75rem}.wr-card--loading .wr-card__body{opacity:.6}.wr-card__header{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:var(--wr-card-padding-y) var(--wr-card-padding-x);border-bottom:1px solid var(--wr-card-border);font-weight:500}.wr-card__body{flex:1 1 auto;padding:var(--wr-card-padding-y) var(--wr-card-padding-x)}.wr-card__footer{display:flex;align-items:center;justify-content:flex-end;gap:.5rem;padding:var(--wr-card-padding-y) var(--wr-card-padding-x);border-top:1px solid var(--wr-card-border)}.wr-card__loading{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;border-radius:var(--wr-card-radius)}@supports (corner-shape: squircle){.wr-card__loading{corner-shape:squircle;border-radius:calc(var(--wr-card-radius) * 1.85)}}.wr-card__loading{background:rgba(var(--wr-color-surface-rgb),.5);pointer-events:none}.wr-card__spinner{width:1.5rem;height:1.5rem;border:2px solid rgb(var(--wr-color-on-surface-muted-rgb)/30%);border-top-color:var(--wr-color-primary);border-radius:50%;animation:wr-card-spin .7s linear infinite}@keyframes wr-card-spin{to{transform:rotate(360deg)}}\n"], encapsulation: i0.ViewEncapsulation.None });
58
58
  }
59
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCard, decorators: [{
59
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCard, decorators: [{
60
60
  type: Component,
61
61
  args: [{ selector: 'wr-card', encapsulation: ViewEncapsulation.None, host: {
62
62
  '[class]': 'classes()',
@@ -65,10 +65,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImpor
65
65
  }], propDecorators: { bordered: [{ type: i0.Input, args: [{ isSignal: true, alias: "bordered", required: false }] }], hoverable: [{ type: i0.Input, args: [{ isSignal: true, alias: "hoverable", required: false }] }], loading: [{ type: i0.Input, args: [{ isSignal: true, alias: "loading", required: false }] }], compact: [{ type: i0.Input, args: [{ isSignal: true, alias: "compact", required: false }] }] } });
66
66
  /** Header slot — projects content under `.wr-card__header`. */
67
67
  class WrCardHeader {
68
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCardHeader, deps: [], target: i0.ɵɵFactoryTarget.Component });
69
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.4", type: WrCardHeader, isStandalone: true, selector: "wr-card-header", host: { classAttribute: "wr-card__header" }, ngImport: i0, template: `<ng-content />`, isInline: true, encapsulation: i0.ViewEncapsulation.None });
68
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCardHeader, deps: [], target: i0.ɵɵFactoryTarget.Component });
69
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.5", type: WrCardHeader, isStandalone: true, selector: "wr-card-header", host: { classAttribute: "wr-card__header" }, ngImport: i0, template: `<ng-content />`, isInline: true, encapsulation: i0.ViewEncapsulation.None });
70
70
  }
71
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCardHeader, decorators: [{
71
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCardHeader, decorators: [{
72
72
  type: Component,
73
73
  args: [{
74
74
  selector: 'wr-card-header',
@@ -79,10 +79,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImpor
79
79
  }] });
80
80
  /** Footer slot — projects content under `.wr-card__footer`. */
81
81
  class WrCardFooter {
82
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCardFooter, deps: [], target: i0.ɵɵFactoryTarget.Component });
83
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.4", type: WrCardFooter, isStandalone: true, selector: "wr-card-footer", host: { classAttribute: "wr-card__footer" }, ngImport: i0, template: `<ng-content />`, isInline: true, encapsulation: i0.ViewEncapsulation.None });
82
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCardFooter, deps: [], target: i0.ɵɵFactoryTarget.Component });
83
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.5", type: WrCardFooter, isStandalone: true, selector: "wr-card-footer", host: { classAttribute: "wr-card__footer" }, ngImport: i0, template: `<ng-content />`, isInline: true, encapsulation: i0.ViewEncapsulation.None });
84
84
  }
85
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCardFooter, decorators: [{
85
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCardFooter, decorators: [{
86
86
  type: Component,
87
87
  args: [{
88
88
  selector: 'wr-card-footer',
@@ -62,10 +62,10 @@ class WrCarouselSlide {
62
62
  return index >= 0 && index !== this.carousel.active();
63
63
  }, /* @ts-ignore */
64
64
  ...(ngDevMode ? [{ debugName: "offScreen" }] : /* istanbul ignore next */ []));
65
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCarouselSlide, deps: [], target: i0.ɵɵFactoryTarget.Component });
66
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.4", type: WrCarouselSlide, isStandalone: true, selector: "wr-carousel-slide", inputs: { roledescription: { classPropertyName: "roledescription", publicName: "roledescription", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "group" }, properties: { "attr.aria-roledescription": "resolvedRoledescription()", "attr.inert": "offScreen() ? \"\" : null", "attr.aria-hidden": "offScreen() ? \"true\" : null" }, classAttribute: "wr-carousel-slide" }, ngImport: i0, template: '<ng-content />', isInline: true, encapsulation: i0.ViewEncapsulation.None });
65
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCarouselSlide, deps: [], target: i0.ɵɵFactoryTarget.Component });
66
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.5", type: WrCarouselSlide, isStandalone: true, selector: "wr-carousel-slide", inputs: { roledescription: { classPropertyName: "roledescription", publicName: "roledescription", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "group" }, properties: { "attr.aria-roledescription": "resolvedRoledescription()", "attr.inert": "offScreen() ? \"\" : null", "attr.aria-hidden": "offScreen() ? \"true\" : null" }, classAttribute: "wr-carousel-slide" }, ngImport: i0, template: '<ng-content />', isInline: true, encapsulation: i0.ViewEncapsulation.None });
67
67
  }
68
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCarouselSlide, decorators: [{
68
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCarouselSlide, decorators: [{
69
69
  type: Component,
70
70
  args: [{
71
71
  selector: 'wr-carousel-slide',
@@ -302,8 +302,8 @@ class WrCarousel {
302
302
  else if (retreat)
303
303
  this.prev();
304
304
  }
305
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCarousel, deps: [], target: i0.ɵɵFactoryTarget.Component });
306
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: WrCarousel, isStandalone: true, selector: "wr-carousel", inputs: { prevLabel: { classPropertyName: "prevLabel", publicName: "prevLabel", isSignal: true, isRequired: false, transformFunction: null }, nextLabel: { classPropertyName: "nextLabel", publicName: "nextLabel", isSignal: true, isRequired: false, transformFunction: null }, paginationLabel: { classPropertyName: "paginationLabel", publicName: "paginationLabel", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, roledescription: { classPropertyName: "roledescription", publicName: "roledescription", isSignal: true, isRequired: false, transformFunction: null }, active: { classPropertyName: "active", publicName: "active", isSignal: true, isRequired: false, transformFunction: null }, showArrows: { classPropertyName: "showArrows", publicName: "showArrows", isSignal: true, isRequired: false, transformFunction: null }, showDots: { classPropertyName: "showDots", publicName: "showDots", isSignal: true, isRequired: false, transformFunction: null }, autoplay: { classPropertyName: "autoplay", publicName: "autoplay", isSignal: true, isRequired: false, transformFunction: null }, intervalMs: { classPropertyName: "intervalMs", publicName: "intervalMs", isSignal: true, isRequired: false, transformFunction: null }, loop: { classPropertyName: "loop", publicName: "loop", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { active: "activeChange" }, host: { listeners: { "mouseenter": "onHoverIn()", "mouseleave": "onHoverOut()", "focusin": "onFocusIn()", "focusout": "onFocusOut()" }, classAttribute: "wr-carousel" }, providers: [
305
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCarousel, deps: [], target: i0.ɵɵFactoryTarget.Component });
306
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.5", type: WrCarousel, isStandalone: true, selector: "wr-carousel", inputs: { prevLabel: { classPropertyName: "prevLabel", publicName: "prevLabel", isSignal: true, isRequired: false, transformFunction: null }, nextLabel: { classPropertyName: "nextLabel", publicName: "nextLabel", isSignal: true, isRequired: false, transformFunction: null }, paginationLabel: { classPropertyName: "paginationLabel", publicName: "paginationLabel", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, roledescription: { classPropertyName: "roledescription", publicName: "roledescription", isSignal: true, isRequired: false, transformFunction: null }, active: { classPropertyName: "active", publicName: "active", isSignal: true, isRequired: false, transformFunction: null }, showArrows: { classPropertyName: "showArrows", publicName: "showArrows", isSignal: true, isRequired: false, transformFunction: null }, showDots: { classPropertyName: "showDots", publicName: "showDots", isSignal: true, isRequired: false, transformFunction: null }, autoplay: { classPropertyName: "autoplay", publicName: "autoplay", isSignal: true, isRequired: false, transformFunction: null }, intervalMs: { classPropertyName: "intervalMs", publicName: "intervalMs", isSignal: true, isRequired: false, transformFunction: null }, loop: { classPropertyName: "loop", publicName: "loop", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { active: "activeChange" }, host: { listeners: { "mouseenter": "onHoverIn()", "mouseleave": "onHoverOut()", "focusin": "onFocusIn()", "focusout": "onFocusOut()" }, classAttribute: "wr-carousel" }, providers: [
307
307
  {
308
308
  provide: WR_CAROUSEL,
309
309
  // eslint-disable-next-line @angular-eslint/no-forward-ref
@@ -311,7 +311,7 @@ class WrCarousel {
311
311
  },
312
312
  ], queries: [{ propertyName: "slides", predicate: WrCarouselSlide, isSignal: true }], ngImport: i0, template: "<div\n #viewport\n class=\"wr-carousel__viewport\"\n role=\"group\"\n [attr.aria-roledescription]=\"resolvedRoledescription()\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n (touchstart)=\"onSwipeStart($event)\"\n (touchmove)=\"onSwipeMove($event)\"\n (touchend)=\"onSwipeEnd($event, viewport)\"\n (touchcancel)=\"onSwipeEnd($event, viewport)\"\n>\n <div class=\"wr-carousel__track\" [style.transform]=\"trackStyle()\" [style.transition]=\"dragging() ? 'none' : null\">\n <ng-content />\n </div>\n</div>\n\n@if (showArrows() && count() > 1) {\n <button\n type=\"button\"\n class=\"wr-carousel__nav wr-carousel__nav--prev\"\n [attr.aria-label]=\"resolvedPrevLabel()\"\n (click)=\"prev()\"\n >\n <svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" aria-hidden=\"true\">\n <path d=\"M9 2 L4 7 L9 12\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" />\n </svg>\n </button>\n <button\n type=\"button\"\n class=\"wr-carousel__nav wr-carousel__nav--next\"\n [attr.aria-label]=\"resolvedNextLabel()\"\n (click)=\"next()\"\n >\n <svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" aria-hidden=\"true\">\n <path d=\"M5 2 L10 7 L5 12\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" />\n </svg>\n </button>\n}\n\n@if (showDots() && count() > 1) {\n <div class=\"wr-carousel__dots\" role=\"group\" [attr.aria-label]=\"resolvedPaginationLabel()\">\n @for (slide of slides(); track $index) {\n <button\n type=\"button\"\n class=\"wr-carousel__dot\"\n [class.wr-carousel__dot--active]=\"$index === active()\"\n [attr.aria-current]=\"$index === active() ? 'true' : null\"\n [attr.aria-label]=\"slideLabel({ index: $index + 1 })\"\n (click)=\"goTo($index)\"\n ></button>\n }\n </div>\n}\n", encapsulation: i0.ViewEncapsulation.None });
313
313
  }
314
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrCarousel, decorators: [{
314
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrCarousel, decorators: [{
315
315
  type: Component,
316
316
  args: [{ selector: 'wr-carousel', encapsulation: ViewEncapsulation.None, host: {
317
317
  class: 'wr-carousel',