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
@@ -164,8 +164,9 @@ class WrTree {
164
164
  /**
165
165
  * Form value — the current selection as seen by a bound field. Bound by
166
166
  * `[formField]`, or two-way via `[(value)]`. Shape follows `selectionMode`:
167
- * `TId | null` in single mode, `readonly TId[]` in multi mode. Meaningful in
168
- * `overlay` mode; inline mode drives selection via `[(selected)]` instead.
167
+ * `TId | null` in single mode, `readonly TId[]` in multi mode. Works in both
168
+ * `openOn` modes; `[(selected)]` stays the inline-native API and always
169
+ * carries an array, whatever the selection mode.
169
170
  */
170
171
  value = model(undefined, /* @ts-ignore */
171
172
  ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
@@ -690,12 +691,18 @@ class WrTree {
690
691
  }
691
692
  this.selected.set([...set]);
692
693
  }
693
- // Overlay mode: propagate to the bound value, close on single-mode pick.
694
- if (this.isOverlay()) {
695
- this.emit();
696
- if (mode === 'single' && this.selected().length > 0) {
697
- this.open.set(false);
698
- }
694
+ // Propagate to the bound value — in BOTH modes. The inbound half of this
695
+ // bridge (the `value` -> `selected` effect above) was never gated, so
696
+ // gating the outbound half left an inline tree in a form accepting a
697
+ // programmatic write and never reporting the user's pick: `[formField]`
698
+ // compiled, rows announced `aria-selected`, and the control stayed at its
699
+ // initial value forever. One-way is worse than unsupported, because it
700
+ // looks wired up. `[(selected)]` remains the inline-native API; `value`
701
+ // simply stops lying. Closing on a single pick stays overlay-only — an
702
+ // inline tree has no panel to close.
703
+ this.emit();
704
+ if (this.isOverlay() && mode === 'single' && this.selected().length > 0) {
705
+ this.open.set(false);
699
706
  }
700
707
  }
701
708
  emit() {
@@ -814,10 +821,10 @@ class WrTree {
814
821
  if (inPanel)
815
822
  this.host.nativeElement.querySelector('.wr-tree__trigger')?.focus();
816
823
  }
817
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrTree, deps: [], target: i0.ɵɵFactoryTarget.Component });
818
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: WrTree, isStandalone: true, selector: "wr-tree", inputs: { nodes: { classPropertyName: "nodes", publicName: "nodes", isSignal: true, isRequired: false, transformFunction: null }, selected: { classPropertyName: "selected", publicName: "selected", isSignal: true, isRequired: false, transformFunction: null }, expanded: { classPropertyName: "expanded", publicName: "expanded", isSignal: true, isRequired: false, transformFunction: null }, selectionMode: { classPropertyName: "selectionMode", publicName: "selectionMode", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, openOn: { classPropertyName: "openOn", publicName: "openOn", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, clearable: { classPropertyName: "clearable", publicName: "clearable", isSignal: true, isRequired: false, transformFunction: null }, maxTagCount: { classPropertyName: "maxTagCount", publicName: "maxTagCount", isSignal: true, isRequired: false, transformFunction: null }, defaultExpandAll: { classPropertyName: "defaultExpandAll", publicName: "defaultExpandAll", isSignal: true, isRequired: false, transformFunction: null }, virtualScroll: { classPropertyName: "virtualScroll", publicName: "virtualScroll", isSignal: true, isRequired: false, transformFunction: null }, rowHeight: { classPropertyName: "rowHeight", publicName: "rowHeight", isSignal: true, isRequired: false, transformFunction: null }, viewportHeight: { classPropertyName: "viewportHeight", publicName: "viewportHeight", isSignal: true, isRequired: false, transformFunction: null }, overscan: { classPropertyName: "overscan", publicName: "overscan", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { selected: "selectedChange", expanded: "expandedChange", value: "valueChange", touch: "touch" }, host: { properties: { "class": "classes()" } }, viewQueries: [{ propertyName: "panelTpl", first: true, predicate: ["panelTpl"], descendants: true, read: TemplateRef, isSignal: true }], ngImport: i0, template: "@if (isOverlay()) {\n <button\n type=\"button\"\n class=\"wr-tree__trigger\"\n role=\"combobox\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [disabled]=\"disabled()\"\n [attr.aria-haspopup]=\"'tree'\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"panelId\"\n [attr.aria-readonly]=\"readonly() || null\"\n [attr.aria-invalid]=\"fieldAria.ariaInvalid()\"\n [attr.aria-describedby]=\"fieldAria.describedBy()\"\n (click)=\"onTriggerClick()\"\n (blur)=\"onBlur()\"\n >\n @if (isMulti()) {\n @if (hasSelection()) {\n <span class=\"wr-tree__chips\">\n @for (chip of visibleChips(); track chip.id) {\n <span class=\"wr-tree__chip\">\n <span class=\"wr-tree__chip-label\">{{ chip.label }}</span>\n <span\n class=\"wr-tree__chip-remove\"\n role=\"button\"\n [attr.aria-label]=\"chipRemoveLabel({ label: chip.label })\"\n tabindex=\"-1\"\n (click)=\"removeChip(chip.id, $event)\"\n (keydown.enter)=\"removeChip(chip.id, $event)\"\n (keydown.space)=\"removeChip(chip.id, $event)\"\n >\n <svg\n class=\"wr-icon__svg\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"M18 6 6 18\" />\n <path d=\"m6 6 12 12\" />\n </svg>\n </span>\n </span>\n }\n @if (hiddenChipCount(); as extra) {\n <span class=\"wr-tree__chip wr-tree__chip--more\">{{ chipMoreLabel({ count: extra }) }}</span>\n }\n </span>\n } @else {\n <span class=\"wr-tree__placeholder\">{{ resolvedPlaceholder() }}</span>\n }\n } @else {\n @if (singleLabel(); as label) {\n <span class=\"wr-tree__value\">{{ label }}</span>\n } @else {\n <span class=\"wr-tree__placeholder\">{{ resolvedPlaceholder() }}</span>\n }\n }\n\n @if (clearable() && hasSelection() && !disabled() && !readonly()) {\n <span\n class=\"wr-tree__clear\"\n role=\"button\"\n [attr.aria-label]=\"clearLabel()\"\n tabindex=\"-1\"\n (click)=\"clearSelection($event)\"\n (keydown.enter)=\"clearSelection($event)\"\n (keydown.space)=\"clearSelection($event)\"\n >\n <svg\n class=\"wr-icon__svg\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"M18 6 6 18\" />\n <path d=\"m6 6 12 12\" />\n </svg>\n </span>\n }\n\n <svg\n class=\"wr-icon__svg wr-tree__chevron\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"m6 9 6 6 6-6\" />\n </svg>\n </button>\n\n <!-- Tree list lives inside the overlay panel. -->\n <ng-template #panelTpl>\n <div class=\"wr-tree-panel\" [class.wr-tree-panel--virtual]=\"virtualized()\" [attr.id]=\"panelId\">\n <ng-container [ngTemplateOutlet]=\"listTpl\" />\n </div>\n </ng-template>\n} @else {\n <ng-container [ngTemplateOutlet]=\"listTpl\" />\n}\n\n<!-- Shared row list \u2014 rendered inline (default) or projected into the\n overlay panel (when openOn=\"overlay\"). -->\n<ng-template #listTpl>\n <!-- Roving tabindex (non-virtual) / aria-activedescendant (virtual): the tree\n owns keyboard focus and routes arrow keys to its currently-focused row.\n The field's error state is bound here for the INLINE shape only \u2014 in\n overlay mode the trigger carries it, and the panel would otherwise\n describe the same error a second time. -->\n <ul\n class=\"wr-tree__list\"\n role=\"tree\"\n [attr.aria-multiselectable]=\"isMulti() ? 'true' : null\"\n [attr.aria-invalid]=\"isOverlay() ? null : fieldAria.ariaInvalid()\"\n [attr.aria-describedby]=\"isOverlay() ? null : fieldAria.describedBy()\"\n [class.wr-tree__list--virtual]=\"virtualized()\"\n [attr.tabindex]=\"virtualized() ? 0 : null\"\n [attr.aria-activedescendant]=\"activeRowId()\"\n [style.max-height]=\"virtualized() ? resolvedViewportHeight() : null\"\n [style.overflow-y]=\"virtualized() ? 'auto' : null\"\n (keydown)=\"onKeydown($event)\"\n >\n @if (virtualized() && virtualWindow().padTop > 0) {\n <!-- `aria-setsize` / `aria-posinset` in BOTH shapes: the list is flat with no\n `role=\"group\"` either way, so the set a row belongs to is never expressed\n by the DOM. Gated behind the virtual flag, the same tree announced a\n position with windowing on and nothing with it off. -->\n <li\n class=\"wr-tree__spacer\"\n role=\"presentation\"\n aria-hidden=\"true\"\n [style.height.px]=\"virtualWindow().padTop\"\n ></li>\n }\n @for (entry of windowRows(); track entry.node.id) {\n <!-- Click handler lives on focusable rows; keyboard handling is owned\n by the parent <ul> via the roving-tabindex pattern. -->\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events -->\n <li\n class=\"wr-tree__row\"\n role=\"treeitem\"\n [attr.id]=\"virtualized() ? rowId(entry.index) : null\"\n [class.wr-tree__row--selected]=\"selectedSet().has(entry.node.id)\"\n [class.wr-tree__row--active]=\"virtualized() && entry.index === cursorIndex()\"\n [class.wr-tree__row--disabled]=\"entry.node.disabled\"\n [attr.aria-level]=\"entry.depth + 1\"\n [attr.aria-setsize]=\"entry.setsize\"\n [attr.aria-posinset]=\"entry.posinset\"\n [attr.aria-expanded]=\"entry.hasChildren ? expandedSet().has(entry.node.id) : null\"\n [attr.aria-selected]=\"selectionMode() === 'none' ? null : selectedSet().has(entry.node.id)\"\n [attr.aria-disabled]=\"entry.node.disabled || disabled() || null\"\n [attr.data-tree-index]=\"entry.index\"\n [attr.tabindex]=\"virtualized() ? null : entry.index === cursorIndex() ? 0 : -1\"\n [style.--wr-tree-depth]=\"entry.depth\"\n (click)=\"onRowClick(entry, $event)\"\n >\n @if (entry.hasChildren) {\n <button\n type=\"button\"\n class=\"wr-tree__toggle\"\n tabindex=\"-1\"\n [attr.aria-label]=\"expandedSet().has(entry.node.id) ? collapseLabel() : expandLabel()\"\n (click)=\"onToggleClick(entry.node, $event)\"\n >\n <svg width=\"10\" height=\"10\" viewBox=\"0 0 10 10\" aria-hidden=\"true\">\n <path d=\"M3 1 L7 5 L3 9 Z\" fill=\"currentColor\" />\n </svg>\n </button>\n } @else {\n <span class=\"wr-tree__toggle wr-tree__toggle--leaf\" aria-hidden=\"true\"></span>\n }\n <span class=\"wr-tree__label\">{{ entry.node.label }}</span>\n </li>\n }\n @if (virtualized() && virtualWindow().padBottom > 0) {\n <li\n class=\"wr-tree__spacer\"\n role=\"presentation\"\n aria-hidden=\"true\"\n [style.height.px]=\"virtualWindow().padBottom\"\n ></li>\n }\n </ul>\n</ng-template>\n", dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], encapsulation: i0.ViewEncapsulation.None });
824
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrTree, deps: [], target: i0.ɵɵFactoryTarget.Component });
825
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.5", type: WrTree, isStandalone: true, selector: "wr-tree", inputs: { nodes: { classPropertyName: "nodes", publicName: "nodes", isSignal: true, isRequired: false, transformFunction: null }, selected: { classPropertyName: "selected", publicName: "selected", isSignal: true, isRequired: false, transformFunction: null }, expanded: { classPropertyName: "expanded", publicName: "expanded", isSignal: true, isRequired: false, transformFunction: null }, selectionMode: { classPropertyName: "selectionMode", publicName: "selectionMode", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, openOn: { classPropertyName: "openOn", publicName: "openOn", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, clearable: { classPropertyName: "clearable", publicName: "clearable", isSignal: true, isRequired: false, transformFunction: null }, maxTagCount: { classPropertyName: "maxTagCount", publicName: "maxTagCount", isSignal: true, isRequired: false, transformFunction: null }, defaultExpandAll: { classPropertyName: "defaultExpandAll", publicName: "defaultExpandAll", isSignal: true, isRequired: false, transformFunction: null }, virtualScroll: { classPropertyName: "virtualScroll", publicName: "virtualScroll", isSignal: true, isRequired: false, transformFunction: null }, rowHeight: { classPropertyName: "rowHeight", publicName: "rowHeight", isSignal: true, isRequired: false, transformFunction: null }, viewportHeight: { classPropertyName: "viewportHeight", publicName: "viewportHeight", isSignal: true, isRequired: false, transformFunction: null }, overscan: { classPropertyName: "overscan", publicName: "overscan", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { selected: "selectedChange", expanded: "expandedChange", value: "valueChange", touch: "touch" }, host: { properties: { "class": "classes()" } }, viewQueries: [{ propertyName: "panelTpl", first: true, predicate: ["panelTpl"], descendants: true, read: TemplateRef, isSignal: true }], ngImport: i0, template: "@if (isOverlay()) {\n <button\n type=\"button\"\n class=\"wr-tree__trigger\"\n role=\"combobox\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [disabled]=\"disabled()\"\n [attr.aria-haspopup]=\"'tree'\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"panelId\"\n [attr.aria-readonly]=\"readonly() || null\"\n [attr.aria-invalid]=\"fieldAria.ariaInvalid()\"\n [attr.aria-describedby]=\"fieldAria.describedBy()\"\n (click)=\"onTriggerClick()\"\n (blur)=\"onBlur()\"\n >\n @if (isMulti()) {\n @if (hasSelection()) {\n <span class=\"wr-tree__chips\">\n @for (chip of visibleChips(); track chip.id) {\n <span class=\"wr-tree__chip\">\n <span class=\"wr-tree__chip-label\">{{ chip.label }}</span>\n <span\n class=\"wr-tree__chip-remove\"\n role=\"button\"\n [attr.aria-label]=\"chipRemoveLabel({ label: chip.label })\"\n tabindex=\"-1\"\n (click)=\"removeChip(chip.id, $event)\"\n (keydown.enter)=\"removeChip(chip.id, $event)\"\n (keydown.space)=\"removeChip(chip.id, $event)\"\n >\n <svg\n class=\"wr-icon__svg\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"M18 6 6 18\" />\n <path d=\"m6 6 12 12\" />\n </svg>\n </span>\n </span>\n }\n @if (hiddenChipCount(); as extra) {\n <span class=\"wr-tree__chip wr-tree__chip--more\">{{ chipMoreLabel({ count: extra }) }}</span>\n }\n </span>\n } @else {\n <span class=\"wr-tree__placeholder\">{{ resolvedPlaceholder() }}</span>\n }\n } @else {\n @if (singleLabel(); as label) {\n <span class=\"wr-tree__value\">{{ label }}</span>\n } @else {\n <span class=\"wr-tree__placeholder\">{{ resolvedPlaceholder() }}</span>\n }\n }\n\n @if (clearable() && hasSelection() && !disabled() && !readonly()) {\n <span\n class=\"wr-tree__clear\"\n role=\"button\"\n [attr.aria-label]=\"clearLabel()\"\n tabindex=\"-1\"\n (click)=\"clearSelection($event)\"\n (keydown.enter)=\"clearSelection($event)\"\n (keydown.space)=\"clearSelection($event)\"\n >\n <svg\n class=\"wr-icon__svg\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"M18 6 6 18\" />\n <path d=\"m6 6 12 12\" />\n </svg>\n </span>\n }\n\n <svg\n class=\"wr-icon__svg wr-tree__chevron\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"m6 9 6 6 6-6\" />\n </svg>\n </button>\n\n <!-- Tree list lives inside the overlay panel. -->\n <ng-template #panelTpl>\n <div class=\"wr-tree-panel\" [class.wr-tree-panel--virtual]=\"virtualized()\" [attr.id]=\"panelId\">\n <ng-container [ngTemplateOutlet]=\"listTpl\" />\n </div>\n </ng-template>\n} @else {\n <ng-container [ngTemplateOutlet]=\"listTpl\" />\n}\n\n<!-- Shared row list \u2014 rendered inline (default) or projected into the\n overlay panel (when openOn=\"overlay\"). -->\n<ng-template #listTpl>\n <!-- Roving tabindex (non-virtual) / aria-activedescendant (virtual): the tree\n owns keyboard focus and routes arrow keys to its currently-focused row.\n The field's error state is bound here for the INLINE shape only \u2014 in\n overlay mode the trigger carries it, and the panel would otherwise\n describe the same error a second time. -->\n <ul\n class=\"wr-tree__list\"\n role=\"tree\"\n [attr.aria-multiselectable]=\"isMulti() ? 'true' : null\"\n [attr.aria-invalid]=\"isOverlay() ? null : fieldAria.ariaInvalid()\"\n [attr.aria-describedby]=\"isOverlay() ? null : fieldAria.describedBy()\"\n [class.wr-tree__list--virtual]=\"virtualized()\"\n [attr.tabindex]=\"virtualized() ? 0 : null\"\n [attr.aria-activedescendant]=\"activeRowId()\"\n [style.max-height]=\"virtualized() ? resolvedViewportHeight() : null\"\n [style.overflow-y]=\"virtualized() ? 'auto' : null\"\n (keydown)=\"onKeydown($event)\"\n >\n @if (virtualized() && virtualWindow().padTop > 0) {\n <!-- `aria-setsize` / `aria-posinset` in BOTH shapes: the list is flat with no\n `role=\"group\"` either way, so the set a row belongs to is never expressed\n by the DOM. Gated behind the virtual flag, the same tree announced a\n position with windowing on and nothing with it off. -->\n <li\n class=\"wr-tree__spacer\"\n role=\"presentation\"\n aria-hidden=\"true\"\n [style.height.px]=\"virtualWindow().padTop\"\n ></li>\n }\n @for (entry of windowRows(); track entry.node.id) {\n <!-- Click handler lives on focusable rows; keyboard handling is owned\n by the parent <ul> via the roving-tabindex pattern. -->\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events -->\n <li\n class=\"wr-tree__row\"\n role=\"treeitem\"\n [attr.id]=\"virtualized() ? rowId(entry.index) : null\"\n [class.wr-tree__row--selected]=\"selectedSet().has(entry.node.id)\"\n [class.wr-tree__row--active]=\"virtualized() && entry.index === cursorIndex()\"\n [class.wr-tree__row--disabled]=\"entry.node.disabled\"\n [attr.aria-level]=\"entry.depth + 1\"\n [attr.aria-setsize]=\"entry.setsize\"\n [attr.aria-posinset]=\"entry.posinset\"\n [attr.aria-expanded]=\"entry.hasChildren ? expandedSet().has(entry.node.id) : null\"\n [attr.aria-selected]=\"selectionMode() === 'none' ? null : selectedSet().has(entry.node.id)\"\n [attr.aria-disabled]=\"entry.node.disabled || disabled() || null\"\n [attr.data-tree-index]=\"entry.index\"\n [attr.tabindex]=\"virtualized() ? null : entry.index === cursorIndex() ? 0 : -1\"\n [style.--wr-tree-depth]=\"entry.depth\"\n (click)=\"onRowClick(entry, $event)\"\n >\n @if (entry.hasChildren) {\n <button\n type=\"button\"\n class=\"wr-tree__toggle\"\n tabindex=\"-1\"\n [attr.aria-label]=\"expandedSet().has(entry.node.id) ? collapseLabel() : expandLabel()\"\n (click)=\"onToggleClick(entry.node, $event)\"\n >\n <svg width=\"10\" height=\"10\" viewBox=\"0 0 10 10\" aria-hidden=\"true\">\n <path d=\"M3 1 L7 5 L3 9 Z\" fill=\"currentColor\" />\n </svg>\n </button>\n } @else {\n <span class=\"wr-tree__toggle wr-tree__toggle--leaf\" aria-hidden=\"true\"></span>\n }\n <span class=\"wr-tree__label\">{{ entry.node.label }}</span>\n </li>\n }\n @if (virtualized() && virtualWindow().padBottom > 0) {\n <li\n class=\"wr-tree__spacer\"\n role=\"presentation\"\n aria-hidden=\"true\"\n [style.height.px]=\"virtualWindow().padBottom\"\n ></li>\n }\n </ul>\n</ng-template>\n", dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], encapsulation: i0.ViewEncapsulation.None });
819
826
  }
820
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrTree, decorators: [{
827
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrTree, decorators: [{
821
828
  type: Component,
822
829
  args: [{ selector: 'wr-tree', encapsulation: ViewEncapsulation.None, host: { '[class]': 'classes()' }, imports: [NgTemplateOutlet], template: "@if (isOverlay()) {\n <button\n type=\"button\"\n class=\"wr-tree__trigger\"\n role=\"combobox\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [disabled]=\"disabled()\"\n [attr.aria-haspopup]=\"'tree'\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"panelId\"\n [attr.aria-readonly]=\"readonly() || null\"\n [attr.aria-invalid]=\"fieldAria.ariaInvalid()\"\n [attr.aria-describedby]=\"fieldAria.describedBy()\"\n (click)=\"onTriggerClick()\"\n (blur)=\"onBlur()\"\n >\n @if (isMulti()) {\n @if (hasSelection()) {\n <span class=\"wr-tree__chips\">\n @for (chip of visibleChips(); track chip.id) {\n <span class=\"wr-tree__chip\">\n <span class=\"wr-tree__chip-label\">{{ chip.label }}</span>\n <span\n class=\"wr-tree__chip-remove\"\n role=\"button\"\n [attr.aria-label]=\"chipRemoveLabel({ label: chip.label })\"\n tabindex=\"-1\"\n (click)=\"removeChip(chip.id, $event)\"\n (keydown.enter)=\"removeChip(chip.id, $event)\"\n (keydown.space)=\"removeChip(chip.id, $event)\"\n >\n <svg\n class=\"wr-icon__svg\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"M18 6 6 18\" />\n <path d=\"m6 6 12 12\" />\n </svg>\n </span>\n </span>\n }\n @if (hiddenChipCount(); as extra) {\n <span class=\"wr-tree__chip wr-tree__chip--more\">{{ chipMoreLabel({ count: extra }) }}</span>\n }\n </span>\n } @else {\n <span class=\"wr-tree__placeholder\">{{ resolvedPlaceholder() }}</span>\n }\n } @else {\n @if (singleLabel(); as label) {\n <span class=\"wr-tree__value\">{{ label }}</span>\n } @else {\n <span class=\"wr-tree__placeholder\">{{ resolvedPlaceholder() }}</span>\n }\n }\n\n @if (clearable() && hasSelection() && !disabled() && !readonly()) {\n <span\n class=\"wr-tree__clear\"\n role=\"button\"\n [attr.aria-label]=\"clearLabel()\"\n tabindex=\"-1\"\n (click)=\"clearSelection($event)\"\n (keydown.enter)=\"clearSelection($event)\"\n (keydown.space)=\"clearSelection($event)\"\n >\n <svg\n class=\"wr-icon__svg\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"M18 6 6 18\" />\n <path d=\"m6 6 12 12\" />\n </svg>\n </span>\n }\n\n <svg\n class=\"wr-icon__svg wr-tree__chevron\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"m6 9 6 6 6-6\" />\n </svg>\n </button>\n\n <!-- Tree list lives inside the overlay panel. -->\n <ng-template #panelTpl>\n <div class=\"wr-tree-panel\" [class.wr-tree-panel--virtual]=\"virtualized()\" [attr.id]=\"panelId\">\n <ng-container [ngTemplateOutlet]=\"listTpl\" />\n </div>\n </ng-template>\n} @else {\n <ng-container [ngTemplateOutlet]=\"listTpl\" />\n}\n\n<!-- Shared row list \u2014 rendered inline (default) or projected into the\n overlay panel (when openOn=\"overlay\"). -->\n<ng-template #listTpl>\n <!-- Roving tabindex (non-virtual) / aria-activedescendant (virtual): the tree\n owns keyboard focus and routes arrow keys to its currently-focused row.\n The field's error state is bound here for the INLINE shape only \u2014 in\n overlay mode the trigger carries it, and the panel would otherwise\n describe the same error a second time. -->\n <ul\n class=\"wr-tree__list\"\n role=\"tree\"\n [attr.aria-multiselectable]=\"isMulti() ? 'true' : null\"\n [attr.aria-invalid]=\"isOverlay() ? null : fieldAria.ariaInvalid()\"\n [attr.aria-describedby]=\"isOverlay() ? null : fieldAria.describedBy()\"\n [class.wr-tree__list--virtual]=\"virtualized()\"\n [attr.tabindex]=\"virtualized() ? 0 : null\"\n [attr.aria-activedescendant]=\"activeRowId()\"\n [style.max-height]=\"virtualized() ? resolvedViewportHeight() : null\"\n [style.overflow-y]=\"virtualized() ? 'auto' : null\"\n (keydown)=\"onKeydown($event)\"\n >\n @if (virtualized() && virtualWindow().padTop > 0) {\n <!-- `aria-setsize` / `aria-posinset` in BOTH shapes: the list is flat with no\n `role=\"group\"` either way, so the set a row belongs to is never expressed\n by the DOM. Gated behind the virtual flag, the same tree announced a\n position with windowing on and nothing with it off. -->\n <li\n class=\"wr-tree__spacer\"\n role=\"presentation\"\n aria-hidden=\"true\"\n [style.height.px]=\"virtualWindow().padTop\"\n ></li>\n }\n @for (entry of windowRows(); track entry.node.id) {\n <!-- Click handler lives on focusable rows; keyboard handling is owned\n by the parent <ul> via the roving-tabindex pattern. -->\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events -->\n <li\n class=\"wr-tree__row\"\n role=\"treeitem\"\n [attr.id]=\"virtualized() ? rowId(entry.index) : null\"\n [class.wr-tree__row--selected]=\"selectedSet().has(entry.node.id)\"\n [class.wr-tree__row--active]=\"virtualized() && entry.index === cursorIndex()\"\n [class.wr-tree__row--disabled]=\"entry.node.disabled\"\n [attr.aria-level]=\"entry.depth + 1\"\n [attr.aria-setsize]=\"entry.setsize\"\n [attr.aria-posinset]=\"entry.posinset\"\n [attr.aria-expanded]=\"entry.hasChildren ? expandedSet().has(entry.node.id) : null\"\n [attr.aria-selected]=\"selectionMode() === 'none' ? null : selectedSet().has(entry.node.id)\"\n [attr.aria-disabled]=\"entry.node.disabled || disabled() || null\"\n [attr.data-tree-index]=\"entry.index\"\n [attr.tabindex]=\"virtualized() ? null : entry.index === cursorIndex() ? 0 : -1\"\n [style.--wr-tree-depth]=\"entry.depth\"\n (click)=\"onRowClick(entry, $event)\"\n >\n @if (entry.hasChildren) {\n <button\n type=\"button\"\n class=\"wr-tree__toggle\"\n tabindex=\"-1\"\n [attr.aria-label]=\"expandedSet().has(entry.node.id) ? collapseLabel() : expandLabel()\"\n (click)=\"onToggleClick(entry.node, $event)\"\n >\n <svg width=\"10\" height=\"10\" viewBox=\"0 0 10 10\" aria-hidden=\"true\">\n <path d=\"M3 1 L7 5 L3 9 Z\" fill=\"currentColor\" />\n </svg>\n </button>\n } @else {\n <span class=\"wr-tree__toggle wr-tree__toggle--leaf\" aria-hidden=\"true\"></span>\n }\n <span class=\"wr-tree__label\">{{ entry.node.label }}</span>\n </li>\n }\n @if (virtualized() && virtualWindow().padBottom > 0) {\n <li\n class=\"wr-tree__spacer\"\n role=\"presentation\"\n aria-hidden=\"true\"\n [style.height.px]=\"virtualWindow().padBottom\"\n ></li>\n }\n </ul>\n</ng-template>\n" }]
823
830
  }], ctorParameters: () => [], propDecorators: { nodes: [{ type: i0.Input, args: [{ isSignal: true, alias: "nodes", required: false }] }], selected: [{ type: i0.Input, args: [{ isSignal: true, alias: "selected", required: false }] }, { type: i0.Output, args: ["selectedChange"] }], expanded: [{ type: i0.Input, args: [{ isSignal: true, alias: "expanded", required: false }] }, { type: i0.Output, args: ["expandedChange"] }], selectionMode: [{ type: i0.Input, args: [{ isSignal: true, alias: "selectionMode", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], readonly: [{ type: i0.Input, args: [{ isSignal: true, alias: "readonly", required: false }] }], openOn: [{ type: i0.Input, args: [{ isSignal: true, alias: "openOn", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], clearable: [{ type: i0.Input, args: [{ isSignal: true, alias: "clearable", required: false }] }], maxTagCount: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxTagCount", required: false }] }], defaultExpandAll: [{ type: i0.Input, args: [{ isSignal: true, alias: "defaultExpandAll", required: false }] }], virtualScroll: [{ type: i0.Input, args: [{ isSignal: true, alias: "virtualScroll", required: false }] }], rowHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "rowHeight", required: false }] }], viewportHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "viewportHeight", required: false }] }], overscan: [{ type: i0.Input, args: [{ isSignal: true, alias: "overscan", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], touch: [{ type: i0.Output, args: ["touch"] }], panelTpl: [{ type: i0.ViewChild, args: ['panelTpl', { ...{ read: TemplateRef }, isSignal: true }] }] } });
@@ -1 +1 @@
1
- {"version":3,"file":"ngwr-tree.mjs","sources":["../../../projects/lib/tree/tree.ts","../../../projects/lib/tree/tree.html","../../../projects/lib/tree/ngwr-tree.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 { Directionality } from '@angular/cdk/bidi';\nimport { coerceBooleanProperty, coerceNumberProperty } from '@angular/cdk/coercion';\nimport { type OverlayRef, ScrollStrategyOptions } from '@angular/cdk/overlay';\nimport { TemplatePortal } from '@angular/cdk/portal';\nimport { NgTemplateOutlet, isPlatformBrowser } from '@angular/common';\nimport {\n Component,\n DestroyRef,\n ElementRef,\n Injector,\n PLATFORM_ID,\n TemplateRef,\n ViewContainerRef,\n ViewEncapsulation,\n afterNextRender,\n computed,\n effect,\n inject,\n input,\n model,\n output,\n signal,\n untracked,\n viewChild,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport type { FormValueControl } from '@angular/forms/signals';\n\nimport { useFormFieldAria } from 'ngwr/form';\nimport { readI18nText, useI18nFormatter, useI18nText } from 'ngwr/i18n';\nimport { WR_OVERLAY, WrOutsideClick } from 'ngwr/overlay';\n\nimport type { WrTreeNode, WrTreeSelectionMode } from './interfaces';\n\ninterface FlatNode<TId> {\n readonly node: WrTreeNode<TId>;\n readonly depth: number;\n readonly hasChildren: boolean;\n /** Absolute position in the flattened visible list. */\n readonly index: number;\n /** 1-based position within its sibling group (ARIA `aria-posinset`). */\n readonly posinset: number;\n /** Sibling count at this level (ARIA `aria-setsize`). */\n readonly setsize: number;\n}\n\ninterface SelectedChip<TId> {\n readonly id: TId;\n readonly label: string;\n}\n\nlet panelUid = 0;\n\n/**\n * Hierarchical tree. Data-driven — pass `[nodes]` with optional `children`\n * arrays. Supports single / multi selection (two-way `[(selected)]`),\n * controlled expand state (two-way `[(expanded)]`), and full keyboard\n * navigation.\n *\n * Two render shapes, picked by `[openOn]`:\n * - `'inline'` (default) — renders the tree list in-place. Use as a display\n * widget or form-less hierarchical picker.\n * - `'overlay'` — renders a `<wr-select>`-style trigger button (with chips\n * in multi mode) that opens a popover containing the tree. A signal-forms\n * native control: it implements `FormValueControl<unknown>`, so `[formField]`\n * binds straight to its `value` model — no `ControlValueAccessor` in between.\n * `[(value)]` and classic `[(ngModel)]` / reactive forms all keep working via\n * Angular's bridge. Replaces the standalone `<wr-tree-select>`.\n *\n * Value type in `overlay` mode: `TId | null` in single mode,\n * `readonly TId[]` in multi mode.\n *\n * @example\n * ```html\n * <!-- Inline tree (display widget) -->\n * <wr-tree [nodes]=\"folders\" [(selected)]=\"picked\" [(expanded)]=\"open\" />\n *\n * <!-- Form-bound combobox (signal forms) -->\n * <wr-tree\n * openOn=\"overlay\"\n * [nodes]=\"folders\"\n * selectionMode=\"single\"\n * [formField]=\"form.folder\"\n * placeholder=\"Pick a folder\"\n * />\n *\n * <!-- standalone two-way binding -->\n * <wr-tree openOn=\"overlay\" [nodes]=\"folders\" [(value)]=\"picked\" placeholder=\"Pick a folder\" />\n * ```\n *\n * @see https://ngwr.dev/reference/components/tree\n */\n@Component({\n selector: 'wr-tree',\n templateUrl: './tree.html',\n encapsulation: ViewEncapsulation.None,\n host: { '[class]': 'classes()' },\n imports: [NgTemplateOutlet],\n})\nexport class WrTree<TId = string> implements FormValueControl<unknown> {\n /** Tree data. */\n readonly nodes = input<readonly WrTreeNode<TId>[]>([]);\n\n /** Selected node ids (two-way bindable). */\n readonly selected = model<readonly TId[]>([]);\n\n /** Expanded node ids (two-way bindable). */\n readonly expanded = model<readonly TId[]>([]);\n\n /** Selection behavior. @default 'single' */\n readonly selectionMode = input<WrTreeSelectionMode>('single');\n\n /**\n * Disable the whole tree. Bound automatically from the field's disabled\n * state when used with `[formField]`.\n *\n * @default false\n */\n readonly disabled = input(false, { transform: coerceBooleanProperty });\n\n /**\n * Refuse selection changes while the tree stays focusable and the value still\n * submits. Bound automatically from the field's readonly state when used with\n * `[formField]`.\n *\n * Expanding and collapsing keep working: a branch is NAVIGATION, not a value,\n * so a read-only tree is still browsable — it is picking and un-picking that\n * stops. In `overlay` mode the trigger additionally refuses to open, because\n * there the panel exists only to choose from and it already shows what is\n * chosen.\n *\n * `aria-readonly` rides on the combobox trigger only; role `tree` does not\n * support the state, so the inline shape has nothing valid to mirror it onto.\n *\n * @default false\n */\n readonly readonly = input(false, { transform: coerceBooleanProperty });\n\n /** The surrounding `<wr-form-field>`'s error state. @internal */\n protected readonly fieldAria = useFormFieldAria();\n\n // Overlay-mode inputs (ignored when openOn='inline')\n\n /** Render shape. @default 'inline' */\n readonly openOn = input<'inline' | 'overlay'>('inline');\n\n /** Placeholder shown on the trigger when no node is selected. */\n readonly placeholder = input<string>('');\n\n /**\n * The same fall-through `wr-select` has had all along: an unset placeholder\n * takes the catalog's `tree.placeholder`, so an overlay trigger with nothing\n * selected reads \"Select…\" in the app's language instead of rendering an\n * empty span. The key shipped in both catalogs and nothing read it.\n */\n protected readonly resolvedPlaceholder = useI18nText(this.placeholder, 'tree.placeholder', '');\n\n /**\n * Accessible name of the overlay trigger. Falls back to the placeholder, then\n * to `select.label` — a `role=\"combobox\"` with nothing selected and no\n * placeholder otherwise has no name at all.\n */\n readonly ariaLabel = input<string | null>(null);\n\n private readonly labelText = useI18nText(this.ariaLabel, 'select.label', 'Select');\n protected readonly resolvedAriaLabel = computed(() => {\n // Not `??`: an empty placeholder must fall through to the catalog string.\n const explicit = this.ariaLabel();\n if (explicit) return explicit;\n const placeholder = this.resolvedPlaceholder();\n return placeholder ? placeholder : this.labelText();\n });\n\n /** Show a clear-all (×) button on the trigger when at least one node is selected. @default true */\n readonly clearable = input(true, { transform: coerceBooleanProperty });\n\n /**\n * Cap on the number of chips rendered on the trigger before\n * collapsing the rest into `+N more` (multi mode only). `0` = render\n * every chip. @default 0\n */\n readonly maxTagCount = input(0, {\n transform: (v: unknown): number => Math.max(0, Number(v) || 0),\n });\n\n /** Auto-expand every node that has children on first open of the overlay. @default false */\n readonly defaultExpandAll = input(false, { transform: coerceBooleanProperty });\n\n /**\n * Window the visible-node list so a large tree keeps only ~one viewport of\n * rows in the DOM. Opt-in and OFF by default — a tree without it renders\n * byte-identically to today. Works in both `inline` and `overlay` shapes;\n * while on, keyboard navigation switches to the `aria-activedescendant`\n * pattern so Arrow / Home / End / Enter keep working across un-rendered rows.\n * @default false\n */\n readonly virtualScroll = input(false, { transform: coerceBooleanProperty });\n\n /**\n * Uniform row height in px used to map scroll offset to node index. `0`\n * (default) measures the first rendered row once and reuses it, so it adapts\n * to the active density / touch target automatically. Read only when\n * `virtualScroll` is on. @default 0\n */\n readonly rowHeight = input(0, { transform: (v: unknown): number => Math.max(0, coerceNumberProperty(v, 0)) });\n\n /**\n * Height of the scroll viewport when `virtualScroll` is on — a number (px) or\n * any CSS length (`'60vh'`). A numeric px value lets the server prerender the\n * exact first window. @default 288\n */\n readonly viewportHeight = input<number | string>(288);\n\n /** Extra rows kept rendered above and below the viewport as scroll headroom. @default 6 */\n readonly overscan = input(6, { transform: (v: unknown): number => Math.max(0, coerceNumberProperty(v, 6)) });\n\n /**\n * Form value — the current selection as seen by a bound field. Bound by\n * `[formField]`, or two-way via `[(value)]`. Shape follows `selectionMode`:\n * `TId | null` in single mode, `readonly TId[]` in multi mode. Meaningful in\n * `overlay` mode; inline mode drives selection via `[(selected)]` instead.\n */\n readonly value = model<unknown>(undefined);\n\n /** Emitted on blur so a bound field can mark itself touched. */\n readonly touch = output<void>();\n\n // Internals\n\n private readonly host = inject<ElementRef<HTMLElement>>(ElementRef);\n private readonly overlay = inject(WR_OVERLAY);\n private readonly outsideClick = inject(WrOutsideClick);\n private readonly vcr = inject(ViewContainerRef);\n private readonly scrollStrategies = inject(ScrollStrategyOptions);\n private readonly destroyRef = inject(DestroyRef);\n private readonly platformId = inject(PLATFORM_ID);\n private readonly injector = inject(Injector);\n /**\n * Ambient reading direction. Optional so a bare `TestBed` — or a consumer who\n * never set a direction — needs no provider; `Directionality` is root-provided\n * anyway, and a missing one simply reads as `ltr`.\n *\n * Read at keystroke time rather than cached, so a runtime `dir` flip needs no\n * subscription to `change`.\n */\n private readonly dir = inject(Directionality, { optional: true });\n\n /** Currently focused row's index in the flattened visible list. */\n protected readonly focusedIndex = signal(0);\n\n /**\n * The cursor as the DOM sees it, clamped to the list that exists RIGHT NOW.\n *\n * The raw index is only ever written when a row is focused, and nothing shrank\n * it when the list did: collapsing a branch above the cursor left the index\n * past the end, which gave the tree zero rows with `tabindex=\"0\"` (no way back\n * in with Tab) and made every arrow key a no-op, because `onKeydown` bails when\n * `flat[i]` is undefined.\n */\n protected readonly cursorIndex = computed(() => {\n const last = Math.max(0, this.flat().length - 1);\n return Math.min(this.focusedIndex(), last);\n });\n\n /** Resolved ARIA labels — signals, so they follow both a late catalog and a locale switch. */\n protected readonly clearLabel = readI18nText('tree.clearSelection', 'Clear selection');\n protected readonly expandLabel = readI18nText('tree.expand', 'Expand');\n protected readonly collapseLabel = readI18nText('tree.collapse', 'Collapse');\n protected readonly chipRemoveLabel = useI18nFormatter('tree.removeItem', 'Remove {{label}}');\n\n /**\n * The overflow chip past `maxTagCount`. It was the literal `+{{ extra }} more`\n * in the template while `wr-select` — the same chip, the same string — read\n * `select.more` from the catalog, so a Russian tree rendered\n * `[\"Черновик\", \"+2 more\"]`.\n */\n protected readonly chipMoreLabel = useI18nFormatter('tree.more', '+{{count}} more');\n\n /** Flattened list of currently visible nodes — what the template renders. */\n protected readonly flat = computed<readonly FlatNode<TId>[]>(() => {\n const expanded = new Set(this.expanded());\n const out: FlatNode<TId>[] = [];\n const walk = (list: readonly WrTreeNode<TId>[], depth: number): void => {\n list.forEach((node, i) => {\n const hasChildren = (node.children?.length ?? 0) > 0;\n out.push({ node, depth, hasChildren, index: out.length, posinset: i + 1, setsize: list.length });\n if (hasChildren && expanded.has(node.id)) walk(node.children!, depth + 1);\n });\n };\n walk(this.nodes(), 0);\n return out;\n });\n\n protected readonly selectedSet = computed(() => new Set(this.selected()));\n protected readonly expandedSet = computed(() => new Set(this.expanded()));\n\n protected readonly isOverlay = computed(() => this.openOn() === 'overlay');\n protected readonly isMulti = computed(() => this.selectionMode() === 'multi');\n protected readonly hasSelection = computed(() => this.selected().length > 0);\n\n /** Overlay-mode trigger label / chip map. */\n private readonly labelMap = computed<ReadonlyMap<TId, string>>(() => {\n const map = new Map<TId, string>();\n const walk = (list: readonly WrTreeNode<TId>[]): void => {\n for (const n of list) {\n map.set(n.id, n.label);\n if (n.children?.length) walk(n.children);\n }\n };\n walk(this.nodes());\n return map;\n });\n\n protected readonly selectedChips = computed<readonly SelectedChip<TId>[]>(() => {\n const map = this.labelMap();\n return this.selected().map<SelectedChip<TId>>(id => ({ id, label: map.get(id) ?? String(id) }));\n });\n\n protected readonly visibleChips = computed<readonly SelectedChip<TId>[]>(() => {\n const cap = this.maxTagCount();\n const chips = this.selectedChips();\n return cap > 0 && chips.length > cap ? chips.slice(0, cap) : chips;\n });\n\n protected readonly hiddenChipCount = computed(() => {\n const cap = this.maxTagCount();\n const total = this.selectedChips().length;\n return cap > 0 && total > cap ? total - cap : 0;\n });\n\n protected readonly singleLabel = computed<string | null>(() => {\n if (this.isMulti()) return null;\n const first = this.selected()[0];\n if (first == null) return null;\n return this.labelMap().get(first) ?? null;\n });\n\n /** Overlay open state. Only meaningful when `openOn='overlay'`. */\n protected readonly open = signal(false);\n\n /** Trigger / panel id for `aria-controls`. */\n protected readonly panelId = `wr-tree-panel-${++panelUid}`;\n\n protected readonly classes = computed(() => {\n const parts = ['wr-tree'];\n if (this.disabled()) parts.push('wr-tree--disabled');\n else if (this.readonly()) parts.push('wr-tree--readonly');\n if (this.isOverlay()) {\n parts.push('wr-tree--combobox');\n if (this.open()) parts.push('wr-tree--open');\n if (this.isMulti()) parts.push('wr-tree--multi');\n }\n return parts.join(' ');\n });\n\n protected readonly panelTpl = viewChild('panelTpl', { read: TemplateRef });\n\n private overlayRef: OverlayRef | null = null;\n\n // --- Virtual scroll -------------------------------------------------------\n\n private static readonly FALLBACK_ROW_PX = 32;\n private static readonly FALLBACK_VIEWPORT_PX = 288;\n\n /** Live vertical scroll offset (px); 0 on the server / before first scroll. */\n private readonly scrollTop = signal(0);\n /** Measured viewport clientHeight (px); 0 until the browser observer fires. */\n private readonly viewportPx = signal(0);\n /** Measured first-row height (px) when `rowHeight` is auto; 0 until measured. */\n private readonly measuredRowPx = signal(0);\n\n /** Virtualization active (opt-in and there is anything to window). */\n protected readonly virtualized = computed(() => this.virtualScroll() && this.flat().length > 0);\n\n /** Effective uniform row height (px). */\n protected readonly effRowH = computed(() =>\n this.rowHeight() > 0 ? this.rowHeight() : this.measuredRowPx() || WrTree.FALLBACK_ROW_PX\n );\n\n /** Deterministic viewport px for SSR + first paint (numeric height, else fallback). */\n private readonly fallbackViewportPx = computed(() => {\n const h = this.viewportHeight();\n if (typeof h === 'number') return h;\n return /^\\d+$/.test(h) ? Number(h) : WrTree.FALLBACK_VIEWPORT_PX;\n });\n\n /** `viewportHeight` as a CSS length for the inline max-height (bare number → px). */\n protected readonly resolvedViewportHeight = computed(() => {\n const h = this.viewportHeight();\n return typeof h === 'number' || /^\\d+$/.test(h) ? `${h}px` : h;\n });\n\n /** Rendered window [start,end) + spacer pads (px). Pure math from `scrollTop`. */\n protected readonly virtualWindow = computed<{ start: number; end: number; padTop: number; padBottom: number }>(() => {\n const total = this.flat().length;\n if (!this.virtualized() || total === 0) return { start: 0, end: total, padTop: 0, padBottom: 0 };\n const h = this.effRowH();\n const vp = this.viewportPx() || this.fallbackViewportPx();\n const over = this.overscan();\n // Clamp `first` so a transient effRowH shrink (auto-measure landing below the\n // fallback within one frame) can't push it past the list and slice to empty.\n const first = Math.min(Math.floor(this.scrollTop() / h), total - 1);\n // `+ 1` covers the partial row at the viewport's bottom edge even at overscan 0.\n const count = Math.ceil(vp / h) + 1;\n const start = Math.max(0, first - over);\n const end = Math.min(total, first + count + over);\n return { start, end, padTop: start * h, padBottom: (total - end) * h };\n });\n\n /** Nodes placed in the list. SAME array instance as `flat()` when off → byte-identical DOM. */\n protected readonly windowRows = computed<readonly FlatNode<TId>[]>(() => {\n if (!this.virtualized()) return this.flat();\n const { start, end } = this.virtualWindow();\n return this.flat().slice(start, end);\n });\n\n /** Stable id for a row at flat index `i` — the `aria-activedescendant` target. */\n protected rowId(i: number): string {\n return `${this.panelId}-row-${i}`;\n }\n\n /**\n * Active-descendant id when virtualized (focus stays on the list container),\n * else `null`. Returns `null` while the focused row is outside the rendered\n * window (e.g. mouse-wheeled away) so `aria-activedescendant` never dangles at\n * a removed element — the next arrow key scrolls it back and re-establishes it.\n */\n protected readonly activeRowId = computed(() => {\n if (!this.virtualized()) return null;\n const i = this.cursorIndex();\n const { start, end } = this.virtualWindow();\n return i >= start && i < end ? this.rowId(i) : null;\n });\n\n /** The scrollable `<ul>` — inside the overlay panel in overlay mode, else in the host. */\n private get listElement(): HTMLElement | null {\n const root = this.overlayRef?.overlayElement ?? this.host.nativeElement;\n return root.querySelector<HTMLElement>('.wr-tree__list');\n }\n\n /** Scroll flat index `i` just into view (sets the `scrollTop` signal synchronously). */\n private ensureVisible(i: number): void {\n const h = this.effRowH();\n const vp = this.viewportPx() || this.fallbackViewportPx();\n const top = i * h;\n const cur = this.scrollTop();\n let next = cur;\n if (top < cur) next = top;\n else if (top + h > cur + vp) next = top + h - vp;\n if (next !== cur) {\n this.scrollTop.set(next);\n this.listElement?.scrollTo({ top: next });\n }\n }\n\n /** Whether this OPEN has already auto-expanded; reset when the panel closes. */\n private didExpandAll = false;\n\n constructor() {\n // Drive the overlay open/close in response to the `open` signal.\n effect(() => {\n if (!this.isOverlay()) return;\n if (this.open()) {\n this.openOverlay();\n // Once per OPEN, which is what the input documents. Reading `expanded()`\n // as part of the guard made it a dependency of this effect, so closing\n // the last branch re-ran it and inflated the tree again — collapsible one\n // branch at a time, never all the way.\n if (this.defaultExpandAll() && !this.didExpandAll) {\n this.didExpandAll = true;\n untracked(() => {\n if (this.expanded().length === 0) this.expanded.set(this.collectExpandableIds(this.nodes()));\n });\n }\n } else {\n this.didExpandAll = false;\n this.closeOverlay();\n }\n });\n\n // Disabling the control closes any open overlay (mirrors the side effect\n // of the old CVA setDisabledState).\n effect(() => {\n if (this.disabled() || this.readonly()) this.open.set(false);\n });\n\n // Bridge an external `value` write back into the internal `selected`\n // state (this is the old writeValue body). `undefined` is the untouched\n // sentinel — no field / ngModel has written yet, so leave any preset\n // `[(selected)]` alone; a real `null` still clears, exactly as\n // `writeValue(null)` did. Guarded against the echo of our own `emit()`\n // (equality check under `untracked`) so a live pick is never clobbered.\n effect(() => {\n const value = this.value();\n if (value === undefined) return;\n untracked(() => {\n const next: readonly TId[] = this.isMulti()\n ? Array.isArray(value)\n ? (value as readonly TId[])\n : []\n : value == null\n ? []\n : [value as TId];\n const current = this.selected();\n if (next.length === current.length && next.every((id, i) => id === current[i])) return;\n this.selected.set(next);\n });\n });\n\n // Wire the scroll listener + viewport/row measurement — only while virtual\n // and in the browser. Re-runs when the list (re)appears (overlay open, data\n // change), deferring the DOM read to a microtask so the portal / inline list\n // is attached. No-op on the server (SSR renders the deterministic first\n // window from inputs alone).\n effect(onCleanup => {\n if (!isPlatformBrowser(this.platformId) || !this.virtualScroll()) return;\n const open = this.isOverlay() ? this.open() : true;\n this.flat();\n if (!open) return;\n let raf = 0;\n let ro: ResizeObserver | null = null;\n let el: HTMLElement | null = null;\n // `onCleanup` can run BEFORE the microtask below — the effect re-runs, or\n // the component is destroyed, in the same task that scheduled it. It would\n // then tear down nothing (`el` and `ro` are still null) and the\n // continuation would go on to attach a scroll listener and a\n // `ResizeObserver` that nothing is left to remove.\n let cancelled = false;\n const onScroll = (): void => {\n if (raf) return;\n raf = requestAnimationFrame(() => {\n raf = 0;\n if (el) this.scrollTop.set(el.scrollTop);\n });\n };\n queueMicrotask(() => {\n if (cancelled) return;\n el = this.listElement;\n if (!el) return;\n // The overlay `<ul>` is destroyed + recreated on each open, but the\n // `scrollTop` signal persists — restore the fresh element to it so a\n // reopened panel isn't blank (window computed from a non-zero signal\n // while the new DOM sits at scrollTop 0). No-op on first open / inline.\n if (el.scrollTop !== this.scrollTop()) el.scrollTop = this.scrollTop();\n this.viewportPx.set(el.clientHeight);\n if (this.rowHeight() === 0) {\n const h = el.querySelector<HTMLElement>('.wr-tree__row')?.offsetHeight ?? 0;\n if (h > 0) this.measuredRowPx.set(h);\n }\n el.addEventListener('scroll', onScroll, { passive: true });\n if (typeof ResizeObserver !== 'undefined') {\n ro = new ResizeObserver(() => {\n if (el) this.viewportPx.set(el.clientHeight);\n });\n ro.observe(el);\n }\n });\n onCleanup(() => {\n cancelled = true;\n if (raf) cancelAnimationFrame(raf);\n if (el) el.removeEventListener('scroll', onScroll);\n ro?.disconnect();\n });\n });\n\n this.destroyRef.onDestroy(() => this.closeOverlay());\n }\n\n // Template handlers\n\n protected onRowClick(flat: FlatNode<TId>, event: MouseEvent): void {\n if (this.disabled() || flat.node.disabled) return;\n if (flat.hasChildren && (event.target as HTMLElement).closest('.wr-tree__toggle')) {\n this.toggleExpanded(flat.node.id);\n return;\n }\n this.focusIndex(flat.index);\n this.select(flat.node.id, event.ctrlKey || event.metaKey);\n }\n\n protected onToggleClick(node: WrTreeNode<TId>, event: MouseEvent): void {\n event.stopPropagation();\n if (this.disabled() || node.disabled) return;\n this.toggleExpanded(node.id);\n }\n\n /**\n * Map a physical arrow onto the expand / collapse axis.\n *\n * The APG gives ArrowRight the job of opening a branch and ArrowLeft the job\n * of closing it because the arrows follow the INDENT, and the indent grows\n * rightward. Under `dir=\"rtl\"` it grows leftward, so the two swap — without\n * this an RTL user cannot open a node at all.\n *\n * Up / Down travel the block axis and Home / End name a semantic position\n * (first / last), so all four are returned untouched in both directions.\n */\n private inlineKey(key: string): string {\n if (this.dir?.value !== 'rtl') return key;\n if (key === 'ArrowRight') return 'ArrowLeft';\n if (key === 'ArrowLeft') return 'ArrowRight';\n return key;\n }\n\n protected onKeydown(event: KeyboardEvent): void {\n if (this.disabled()) return;\n const flat = this.flat();\n const i = this.cursorIndex();\n const current = flat[i];\n if (!current) return;\n\n // The cursor move is identical in both render shapes — `focusIndex()` owns\n // the roving-tabindex / `aria-activedescendant` split — so mirroring here\n // covers the windowed tree too.\n switch (this.inlineKey(event.key)) {\n case 'ArrowDown':\n event.preventDefault();\n this.focusIndex(Math.min(flat.length - 1, i + 1));\n break;\n case 'ArrowUp':\n event.preventDefault();\n this.focusIndex(Math.max(0, i - 1));\n break;\n case 'ArrowRight':\n event.preventDefault();\n if (current.hasChildren && !this.expandedSet().has(current.node.id)) {\n this.toggleExpanded(current.node.id);\n } else if (current.hasChildren) {\n this.focusIndex(Math.min(flat.length - 1, i + 1));\n }\n break;\n case 'ArrowLeft':\n event.preventDefault();\n if (current.hasChildren && this.expandedSet().has(current.node.id)) {\n this.toggleExpanded(current.node.id);\n } else if (current.depth > 0) {\n for (let j = i - 1; j >= 0; j--) {\n if (flat[j].depth < current.depth) {\n this.focusIndex(j);\n break;\n }\n }\n }\n break;\n case 'Home':\n event.preventDefault();\n this.focusIndex(0);\n break;\n case 'End':\n event.preventDefault();\n this.focusIndex(flat.length - 1);\n break;\n case 'Enter':\n case ' ':\n event.preventDefault();\n if (!current.node.disabled) this.select(current.node.id, event.ctrlKey || event.metaKey);\n break;\n default:\n break;\n }\n }\n\n // Overlay-mode trigger handlers\n\n protected onTriggerClick(): void {\n if (this.disabled() || this.readonly()) return;\n this.open.update(v => !v);\n }\n\n /** Trigger blur — mark the bound field touched. */\n protected onBlur(): void {\n this.touch.emit();\n }\n\n protected removeChip(id: TId, event: Event): void {\n event.stopPropagation();\n if (this.disabled() || this.readonly()) return;\n const next = this.selected().filter(x => x !== id);\n this.selected.set(next);\n this.emit();\n }\n\n protected clearSelection(event: Event): void {\n event.stopPropagation();\n if (this.disabled() || this.readonly()) return;\n this.selected.set([]);\n this.emit();\n }\n\n // Selection / expansion plumbing\n\n private toggleExpanded(id: TId): void {\n const set = new Set(this.expanded());\n if (set.has(id)) set.delete(id);\n else set.add(id);\n this.expanded.set([...set]);\n }\n\n private select(id: TId, additive: boolean): void {\n // Every selection path funnels through here — row click, Enter, Space — so\n // one guard covers them all while expand / collapse stays reachable.\n if (this.readonly()) return;\n const mode = this.selectionMode();\n if (mode === 'none') return;\n if (mode === 'single') {\n this.selected.set([id]);\n } else {\n const set = new Set(this.selected());\n if (additive) {\n if (set.has(id)) set.delete(id);\n else set.add(id);\n } else {\n // Plain click toggles single id in multi mode — common UX.\n if (set.size === 1 && set.has(id)) set.delete(id);\n else {\n set.clear();\n set.add(id);\n }\n }\n this.selected.set([...set]);\n }\n\n // Overlay mode: propagate to the bound value, close on single-mode pick.\n if (this.isOverlay()) {\n this.emit();\n if (mode === 'single' && this.selected().length > 0) {\n this.open.set(false);\n }\n }\n }\n\n private emit(): void {\n this.touch.emit();\n if (this.isMulti()) {\n this.value.set(this.selected());\n } else {\n this.value.set(this.selected()[0] ?? null);\n }\n }\n\n private focusIndex(i: number): void {\n this.focusedIndex.set(i);\n if (this.virtualized()) {\n // Managed-focus (aria-activedescendant): focus stays on the list container.\n // Setting `scrollTop` synchronously materializes row `i` in the SAME change\n // detection pass, so the id referenced by `aria-activedescendant` is present\n // — no rAF/microtask race, no \"points at an absent id\" gap.\n this.ensureVisible(i);\n this.listElement?.focus();\n return;\n }\n // Non-virtual roving tabindex: defer so the DOM has updated tabindex, then\n // move focus to the row element.\n queueMicrotask(() => {\n const root = this.overlayRef?.overlayElement ?? this.host.nativeElement;\n const row = root.querySelector<HTMLElement>(`[data-tree-index=\"${i}\"]`);\n row?.focus();\n });\n }\n\n // Overlay\n\n private collectExpandableIds(list: readonly WrTreeNode<TId>[]): readonly TId[] {\n const out: TId[] = [];\n const walk = (items: readonly WrTreeNode<TId>[]): void => {\n for (const n of items) {\n if (n.children?.length) {\n out.push(n.id);\n walk(n.children);\n }\n }\n };\n walk(list);\n return out;\n }\n\n private openOverlay(): void {\n if (this.overlayRef) return;\n const tpl = this.panelTpl();\n if (!tpl) return;\n\n const positionStrategy = this.overlay\n .position()\n .flexibleConnectedTo(this.host)\n .withPositions([\n { originX: 'start', originY: 'bottom', overlayX: 'start', overlayY: 'top' },\n { originX: 'start', originY: 'top', overlayX: 'start', overlayY: 'bottom' },\n ])\n .withPush(true);\n\n this.overlayRef = this.overlay.create({\n positionStrategy,\n scrollStrategy: this.scrollStrategies.reposition(),\n width: this.host.nativeElement.getBoundingClientRect().width,\n panelClass: 'wr-tree-overlay',\n });\n\n this.overlayRef.attach(new TemplatePortal(tpl, this.vcr));\n\n // The panel owns the keyboard from here, in BOTH render shapes. `onKeydown`\n // lives on the `<ul>` inside the portal and the trigger has no handler of\n // its own, so leaving focus on the trigger — which is what the non-virtual\n // shape used to do — made an overlay tree mouse-only: arrows, Home/End and\n // Enter all did nothing, and the rows were reachable only by tabbing through\n // the rest of the page, since the pane is appended to `<body>`. Virtual mode\n // focuses the LIST (managed focus via `aria-activedescendant`); the\n // non-virtual shape focuses the roving row, which carries the tab stop.\n //\n // `afterNextRender`, NOT `queueMicrotask`: under zoneless CD the scheduler\n // runs change detection in a macrotask, so a microtask queued here fires\n // first and focuses whatever the panel held before this open — the same trap\n // that once left `wr-calendar`'s ring and real focus on different days.\n afterNextRender(\n () => {\n if (this.virtualized()) {\n this.listElement?.focus();\n return;\n }\n const row = this.overlayRef?.overlayElement.querySelector<HTMLElement>(\n `[data-tree-index=\"${this.cursorIndex()}\"]`\n );\n row?.focus();\n },\n { injector: this.injector }\n );\n\n this.outsideClick\n .outsidePointerEvents(this.overlayRef)\n .pipe(takeUntilDestroyed(this.destroyRef))\n .subscribe(event => {\n if (this.host.nativeElement.contains(event.target as Node)) return;\n this.open.set(false);\n });\n\n this.overlayRef\n .keydownEvents()\n .pipe(takeUntilDestroyed(this.destroyRef))\n .subscribe(event => {\n if (event.key === 'Escape') {\n event.preventDefault();\n this.open.set(false);\n }\n });\n }\n\n private closeOverlay(): void {\n if (!this.overlayRef) return;\n // Hand the focus back before the panel it lives in disappears. The keyboard\n // path in virtual mode focuses the list itself, so closing left the document\n // focused on `<body>` and the next Tab started from the top of the page —\n // `wr-dropdown` returns focus to its own trigger for the same reason.\n const active = this.host.nativeElement.ownerDocument.activeElement;\n const inPanel = active instanceof Node && this.overlayRef.overlayElement.contains(active);\n this.overlayRef.dispose();\n this.overlayRef = null;\n if (inPanel) this.host.nativeElement.querySelector<HTMLElement>('.wr-tree__trigger')?.focus();\n }\n}\n","@if (isOverlay()) {\n <button\n type=\"button\"\n class=\"wr-tree__trigger\"\n role=\"combobox\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [disabled]=\"disabled()\"\n [attr.aria-haspopup]=\"'tree'\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"panelId\"\n [attr.aria-readonly]=\"readonly() || null\"\n [attr.aria-invalid]=\"fieldAria.ariaInvalid()\"\n [attr.aria-describedby]=\"fieldAria.describedBy()\"\n (click)=\"onTriggerClick()\"\n (blur)=\"onBlur()\"\n >\n @if (isMulti()) {\n @if (hasSelection()) {\n <span class=\"wr-tree__chips\">\n @for (chip of visibleChips(); track chip.id) {\n <span class=\"wr-tree__chip\">\n <span class=\"wr-tree__chip-label\">{{ chip.label }}</span>\n <span\n class=\"wr-tree__chip-remove\"\n role=\"button\"\n [attr.aria-label]=\"chipRemoveLabel({ label: chip.label })\"\n tabindex=\"-1\"\n (click)=\"removeChip(chip.id, $event)\"\n (keydown.enter)=\"removeChip(chip.id, $event)\"\n (keydown.space)=\"removeChip(chip.id, $event)\"\n >\n <svg\n class=\"wr-icon__svg\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"M18 6 6 18\" />\n <path d=\"m6 6 12 12\" />\n </svg>\n </span>\n </span>\n }\n @if (hiddenChipCount(); as extra) {\n <span class=\"wr-tree__chip wr-tree__chip--more\">{{ chipMoreLabel({ count: extra }) }}</span>\n }\n </span>\n } @else {\n <span class=\"wr-tree__placeholder\">{{ resolvedPlaceholder() }}</span>\n }\n } @else {\n @if (singleLabel(); as label) {\n <span class=\"wr-tree__value\">{{ label }}</span>\n } @else {\n <span class=\"wr-tree__placeholder\">{{ resolvedPlaceholder() }}</span>\n }\n }\n\n @if (clearable() && hasSelection() && !disabled() && !readonly()) {\n <span\n class=\"wr-tree__clear\"\n role=\"button\"\n [attr.aria-label]=\"clearLabel()\"\n tabindex=\"-1\"\n (click)=\"clearSelection($event)\"\n (keydown.enter)=\"clearSelection($event)\"\n (keydown.space)=\"clearSelection($event)\"\n >\n <svg\n class=\"wr-icon__svg\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"M18 6 6 18\" />\n <path d=\"m6 6 12 12\" />\n </svg>\n </span>\n }\n\n <svg\n class=\"wr-icon__svg wr-tree__chevron\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"m6 9 6 6 6-6\" />\n </svg>\n </button>\n\n <!-- Tree list lives inside the overlay panel. -->\n <ng-template #panelTpl>\n <div class=\"wr-tree-panel\" [class.wr-tree-panel--virtual]=\"virtualized()\" [attr.id]=\"panelId\">\n <ng-container [ngTemplateOutlet]=\"listTpl\" />\n </div>\n </ng-template>\n} @else {\n <ng-container [ngTemplateOutlet]=\"listTpl\" />\n}\n\n<!-- Shared row list — rendered inline (default) or projected into the\n overlay panel (when openOn=\"overlay\"). -->\n<ng-template #listTpl>\n <!-- Roving tabindex (non-virtual) / aria-activedescendant (virtual): the tree\n owns keyboard focus and routes arrow keys to its currently-focused row.\n The field's error state is bound here for the INLINE shape only — in\n overlay mode the trigger carries it, and the panel would otherwise\n describe the same error a second time. -->\n <ul\n class=\"wr-tree__list\"\n role=\"tree\"\n [attr.aria-multiselectable]=\"isMulti() ? 'true' : null\"\n [attr.aria-invalid]=\"isOverlay() ? null : fieldAria.ariaInvalid()\"\n [attr.aria-describedby]=\"isOverlay() ? null : fieldAria.describedBy()\"\n [class.wr-tree__list--virtual]=\"virtualized()\"\n [attr.tabindex]=\"virtualized() ? 0 : null\"\n [attr.aria-activedescendant]=\"activeRowId()\"\n [style.max-height]=\"virtualized() ? resolvedViewportHeight() : null\"\n [style.overflow-y]=\"virtualized() ? 'auto' : null\"\n (keydown)=\"onKeydown($event)\"\n >\n @if (virtualized() && virtualWindow().padTop > 0) {\n <!-- `aria-setsize` / `aria-posinset` in BOTH shapes: the list is flat with no\n `role=\"group\"` either way, so the set a row belongs to is never expressed\n by the DOM. Gated behind the virtual flag, the same tree announced a\n position with windowing on and nothing with it off. -->\n <li\n class=\"wr-tree__spacer\"\n role=\"presentation\"\n aria-hidden=\"true\"\n [style.height.px]=\"virtualWindow().padTop\"\n ></li>\n }\n @for (entry of windowRows(); track entry.node.id) {\n <!-- Click handler lives on focusable rows; keyboard handling is owned\n by the parent <ul> via the roving-tabindex pattern. -->\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events -->\n <li\n class=\"wr-tree__row\"\n role=\"treeitem\"\n [attr.id]=\"virtualized() ? rowId(entry.index) : null\"\n [class.wr-tree__row--selected]=\"selectedSet().has(entry.node.id)\"\n [class.wr-tree__row--active]=\"virtualized() && entry.index === cursorIndex()\"\n [class.wr-tree__row--disabled]=\"entry.node.disabled\"\n [attr.aria-level]=\"entry.depth + 1\"\n [attr.aria-setsize]=\"entry.setsize\"\n [attr.aria-posinset]=\"entry.posinset\"\n [attr.aria-expanded]=\"entry.hasChildren ? expandedSet().has(entry.node.id) : null\"\n [attr.aria-selected]=\"selectionMode() === 'none' ? null : selectedSet().has(entry.node.id)\"\n [attr.aria-disabled]=\"entry.node.disabled || disabled() || null\"\n [attr.data-tree-index]=\"entry.index\"\n [attr.tabindex]=\"virtualized() ? null : entry.index === cursorIndex() ? 0 : -1\"\n [style.--wr-tree-depth]=\"entry.depth\"\n (click)=\"onRowClick(entry, $event)\"\n >\n @if (entry.hasChildren) {\n <button\n type=\"button\"\n class=\"wr-tree__toggle\"\n tabindex=\"-1\"\n [attr.aria-label]=\"expandedSet().has(entry.node.id) ? collapseLabel() : expandLabel()\"\n (click)=\"onToggleClick(entry.node, $event)\"\n >\n <svg width=\"10\" height=\"10\" viewBox=\"0 0 10 10\" aria-hidden=\"true\">\n <path d=\"M3 1 L7 5 L3 9 Z\" fill=\"currentColor\" />\n </svg>\n </button>\n } @else {\n <span class=\"wr-tree__toggle wr-tree__toggle--leaf\" aria-hidden=\"true\"></span>\n }\n <span class=\"wr-tree__label\">{{ entry.node.label }}</span>\n </li>\n }\n @if (virtualized() && virtualWindow().padBottom > 0) {\n <li\n class=\"wr-tree__spacer\"\n role=\"presentation\"\n aria-hidden=\"true\"\n [style.height.px]=\"virtualWindow().padBottom\"\n ></li>\n }\n </ul>\n</ng-template>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;AAKG;AAqDH,IAAI,QAAQ,GAAG,CAAC;AAEhB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAsCG;MAQU,MAAM,CAAA;;IAER,KAAK,GAAG,KAAK,CAA6B,EAAE;8EAAC;;IAG7C,QAAQ,GAAG,KAAK,CAAiB,EAAE;iFAAC;;IAGpC,QAAQ,GAAG,KAAK,CAAiB,EAAE;iFAAC;;IAGpC,aAAa,GAAG,KAAK,CAAsB,QAAQ;sFAAC;AAE7D;;;;;AAKG;IACM,QAAQ,GAAG,KAAK,CAAC,KAAK,gFAAI,SAAS,EAAE,qBAAqB,EAAA,CAAG;AAEtE;;;;;;;;;;;;;;;AAeG;IACM,QAAQ,GAAG,KAAK,CAAC,KAAK,gFAAI,SAAS,EAAE,qBAAqB,EAAA,CAAG;;IAGnD,SAAS,GAAG,gBAAgB,EAAE;;;IAKxC,MAAM,GAAG,KAAK,CAAuB,QAAQ;+EAAC;;IAG9C,WAAW,GAAG,KAAK,CAAS,EAAE;oFAAC;AAExC;;;;;AAKG;IACgB,mBAAmB,GAAG,WAAW,CAAC,IAAI,CAAC,WAAW,EAAE,kBAAkB,EAAE,EAAE,CAAC;AAE9F;;;;AAIG;IACM,SAAS,GAAG,KAAK,CAAgB,IAAI;kFAAC;IAE9B,SAAS,GAAG,WAAW,CAAC,IAAI,CAAC,SAAS,EAAE,cAAc,EAAE,QAAQ,CAAC;AAC/D,IAAA,iBAAiB,GAAG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AAA,EAAA,WAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,cAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,gBAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,QAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,UAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,KAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,OAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,EAAA,CAAA,MAAA,EAAA,IAAA,EAAA,CAAA,aAAA,CAAA,EAAA,CAAA,EAAA,KAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,MAAA,EAAA,IAAA,EAAA,CAAA,OAAA,CAAA,EAAA,CAAA,EAAA,QAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,SAAA,EAAA,IAAA,EAAA,CAAA,UAAU,EAAA,EAAA,GAAE,EAAE,IAAI,EAAE,WAAW,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;AE1W3E;;AAEG;;;;"}
1
+ {"version":3,"file":"ngwr-tree.mjs","sources":["../../../projects/lib/tree/tree.ts","../../../projects/lib/tree/tree.html","../../../projects/lib/tree/ngwr-tree.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 { Directionality } from '@angular/cdk/bidi';\nimport { coerceBooleanProperty, coerceNumberProperty } from '@angular/cdk/coercion';\nimport { type OverlayRef, ScrollStrategyOptions } from '@angular/cdk/overlay';\nimport { TemplatePortal } from '@angular/cdk/portal';\nimport { NgTemplateOutlet, isPlatformBrowser } from '@angular/common';\nimport {\n Component,\n DestroyRef,\n ElementRef,\n Injector,\n PLATFORM_ID,\n TemplateRef,\n ViewContainerRef,\n ViewEncapsulation,\n afterNextRender,\n computed,\n effect,\n inject,\n input,\n model,\n output,\n signal,\n untracked,\n viewChild,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport type { FormValueControl } from '@angular/forms/signals';\n\nimport { useFormFieldAria } from 'ngwr/form';\nimport { readI18nText, useI18nFormatter, useI18nText } from 'ngwr/i18n';\nimport { WR_OVERLAY, WrOutsideClick } from 'ngwr/overlay';\n\nimport type { WrTreeNode, WrTreeSelectionMode } from './interfaces';\n\ninterface FlatNode<TId> {\n readonly node: WrTreeNode<TId>;\n readonly depth: number;\n readonly hasChildren: boolean;\n /** Absolute position in the flattened visible list. */\n readonly index: number;\n /** 1-based position within its sibling group (ARIA `aria-posinset`). */\n readonly posinset: number;\n /** Sibling count at this level (ARIA `aria-setsize`). */\n readonly setsize: number;\n}\n\ninterface SelectedChip<TId> {\n readonly id: TId;\n readonly label: string;\n}\n\nlet panelUid = 0;\n\n/**\n * Hierarchical tree. Data-driven — pass `[nodes]` with optional `children`\n * arrays. Supports single / multi selection (two-way `[(selected)]`),\n * controlled expand state (two-way `[(expanded)]`), and full keyboard\n * navigation.\n *\n * Two render shapes, picked by `[openOn]`:\n * - `'inline'` (default) — renders the tree list in-place. Use as a display\n * widget or form-less hierarchical picker.\n * - `'overlay'` — renders a `<wr-select>`-style trigger button (with chips\n * in multi mode) that opens a popover containing the tree. A signal-forms\n * native control: it implements `FormValueControl<unknown>`, so `[formField]`\n * binds straight to its `value` model — no `ControlValueAccessor` in between.\n * `[(value)]` and classic `[(ngModel)]` / reactive forms all keep working via\n * Angular's bridge. Replaces the standalone `<wr-tree-select>`.\n *\n * Value type in `overlay` mode: `TId | null` in single mode,\n * `readonly TId[]` in multi mode.\n *\n * @example\n * ```html\n * <!-- Inline tree (display widget) -->\n * <wr-tree [nodes]=\"folders\" [(selected)]=\"picked\" [(expanded)]=\"open\" />\n *\n * <!-- Form-bound combobox (signal forms) -->\n * <wr-tree\n * openOn=\"overlay\"\n * [nodes]=\"folders\"\n * selectionMode=\"single\"\n * [formField]=\"form.folder\"\n * placeholder=\"Pick a folder\"\n * />\n *\n * <!-- standalone two-way binding -->\n * <wr-tree openOn=\"overlay\" [nodes]=\"folders\" [(value)]=\"picked\" placeholder=\"Pick a folder\" />\n * ```\n *\n * @see https://ngwr.dev/reference/components/tree\n */\n@Component({\n selector: 'wr-tree',\n templateUrl: './tree.html',\n encapsulation: ViewEncapsulation.None,\n host: { '[class]': 'classes()' },\n imports: [NgTemplateOutlet],\n})\nexport class WrTree<TId = string> implements FormValueControl<unknown> {\n /** Tree data. */\n readonly nodes = input<readonly WrTreeNode<TId>[]>([]);\n\n /** Selected node ids (two-way bindable). */\n readonly selected = model<readonly TId[]>([]);\n\n /** Expanded node ids (two-way bindable). */\n readonly expanded = model<readonly TId[]>([]);\n\n /** Selection behavior. @default 'single' */\n readonly selectionMode = input<WrTreeSelectionMode>('single');\n\n /**\n * Disable the whole tree. Bound automatically from the field's disabled\n * state when used with `[formField]`.\n *\n * @default false\n */\n readonly disabled = input(false, { transform: coerceBooleanProperty });\n\n /**\n * Refuse selection changes while the tree stays focusable and the value still\n * submits. Bound automatically from the field's readonly state when used with\n * `[formField]`.\n *\n * Expanding and collapsing keep working: a branch is NAVIGATION, not a value,\n * so a read-only tree is still browsable — it is picking and un-picking that\n * stops. In `overlay` mode the trigger additionally refuses to open, because\n * there the panel exists only to choose from and it already shows what is\n * chosen.\n *\n * `aria-readonly` rides on the combobox trigger only; role `tree` does not\n * support the state, so the inline shape has nothing valid to mirror it onto.\n *\n * @default false\n */\n readonly readonly = input(false, { transform: coerceBooleanProperty });\n\n /** The surrounding `<wr-form-field>`'s error state. @internal */\n protected readonly fieldAria = useFormFieldAria();\n\n // Overlay-mode inputs (ignored when openOn='inline')\n\n /** Render shape. @default 'inline' */\n readonly openOn = input<'inline' | 'overlay'>('inline');\n\n /** Placeholder shown on the trigger when no node is selected. */\n readonly placeholder = input<string>('');\n\n /**\n * The same fall-through `wr-select` has had all along: an unset placeholder\n * takes the catalog's `tree.placeholder`, so an overlay trigger with nothing\n * selected reads \"Select…\" in the app's language instead of rendering an\n * empty span. The key shipped in both catalogs and nothing read it.\n */\n protected readonly resolvedPlaceholder = useI18nText(this.placeholder, 'tree.placeholder', '');\n\n /**\n * Accessible name of the overlay trigger. Falls back to the placeholder, then\n * to `select.label` — a `role=\"combobox\"` with nothing selected and no\n * placeholder otherwise has no name at all.\n */\n readonly ariaLabel = input<string | null>(null);\n\n private readonly labelText = useI18nText(this.ariaLabel, 'select.label', 'Select');\n protected readonly resolvedAriaLabel = computed(() => {\n // Not `??`: an empty placeholder must fall through to the catalog string.\n const explicit = this.ariaLabel();\n if (explicit) return explicit;\n const placeholder = this.resolvedPlaceholder();\n return placeholder ? placeholder : this.labelText();\n });\n\n /** Show a clear-all (×) button on the trigger when at least one node is selected. @default true */\n readonly clearable = input(true, { transform: coerceBooleanProperty });\n\n /**\n * Cap on the number of chips rendered on the trigger before\n * collapsing the rest into `+N more` (multi mode only). `0` = render\n * every chip. @default 0\n */\n readonly maxTagCount = input(0, {\n transform: (v: unknown): number => Math.max(0, Number(v) || 0),\n });\n\n /** Auto-expand every node that has children on first open of the overlay. @default false */\n readonly defaultExpandAll = input(false, { transform: coerceBooleanProperty });\n\n /**\n * Window the visible-node list so a large tree keeps only ~one viewport of\n * rows in the DOM. Opt-in and OFF by default — a tree without it renders\n * byte-identically to today. Works in both `inline` and `overlay` shapes;\n * while on, keyboard navigation switches to the `aria-activedescendant`\n * pattern so Arrow / Home / End / Enter keep working across un-rendered rows.\n * @default false\n */\n readonly virtualScroll = input(false, { transform: coerceBooleanProperty });\n\n /**\n * Uniform row height in px used to map scroll offset to node index. `0`\n * (default) measures the first rendered row once and reuses it, so it adapts\n * to the active density / touch target automatically. Read only when\n * `virtualScroll` is on. @default 0\n */\n readonly rowHeight = input(0, { transform: (v: unknown): number => Math.max(0, coerceNumberProperty(v, 0)) });\n\n /**\n * Height of the scroll viewport when `virtualScroll` is on — a number (px) or\n * any CSS length (`'60vh'`). A numeric px value lets the server prerender the\n * exact first window. @default 288\n */\n readonly viewportHeight = input<number | string>(288);\n\n /** Extra rows kept rendered above and below the viewport as scroll headroom. @default 6 */\n readonly overscan = input(6, { transform: (v: unknown): number => Math.max(0, coerceNumberProperty(v, 6)) });\n\n /**\n * Form value — the current selection as seen by a bound field. Bound by\n * `[formField]`, or two-way via `[(value)]`. Shape follows `selectionMode`:\n * `TId | null` in single mode, `readonly TId[]` in multi mode. Works in both\n * `openOn` modes; `[(selected)]` stays the inline-native API and always\n * carries an array, whatever the selection mode.\n */\n readonly value = model<unknown>(undefined);\n\n /** Emitted on blur so a bound field can mark itself touched. */\n readonly touch = output<void>();\n\n // Internals\n\n private readonly host = inject<ElementRef<HTMLElement>>(ElementRef);\n private readonly overlay = inject(WR_OVERLAY);\n private readonly outsideClick = inject(WrOutsideClick);\n private readonly vcr = inject(ViewContainerRef);\n private readonly scrollStrategies = inject(ScrollStrategyOptions);\n private readonly destroyRef = inject(DestroyRef);\n private readonly platformId = inject(PLATFORM_ID);\n private readonly injector = inject(Injector);\n /**\n * Ambient reading direction. Optional so a bare `TestBed` — or a consumer who\n * never set a direction — needs no provider; `Directionality` is root-provided\n * anyway, and a missing one simply reads as `ltr`.\n *\n * Read at keystroke time rather than cached, so a runtime `dir` flip needs no\n * subscription to `change`.\n */\n private readonly dir = inject(Directionality, { optional: true });\n\n /** Currently focused row's index in the flattened visible list. */\n protected readonly focusedIndex = signal(0);\n\n /**\n * The cursor as the DOM sees it, clamped to the list that exists RIGHT NOW.\n *\n * The raw index is only ever written when a row is focused, and nothing shrank\n * it when the list did: collapsing a branch above the cursor left the index\n * past the end, which gave the tree zero rows with `tabindex=\"0\"` (no way back\n * in with Tab) and made every arrow key a no-op, because `onKeydown` bails when\n * `flat[i]` is undefined.\n */\n protected readonly cursorIndex = computed(() => {\n const last = Math.max(0, this.flat().length - 1);\n return Math.min(this.focusedIndex(), last);\n });\n\n /** Resolved ARIA labels — signals, so they follow both a late catalog and a locale switch. */\n protected readonly clearLabel = readI18nText('tree.clearSelection', 'Clear selection');\n protected readonly expandLabel = readI18nText('tree.expand', 'Expand');\n protected readonly collapseLabel = readI18nText('tree.collapse', 'Collapse');\n protected readonly chipRemoveLabel = useI18nFormatter('tree.removeItem', 'Remove {{label}}');\n\n /**\n * The overflow chip past `maxTagCount`. It was the literal `+{{ extra }} more`\n * in the template while `wr-select` — the same chip, the same string — read\n * `select.more` from the catalog, so a Russian tree rendered\n * `[\"Черновик\", \"+2 more\"]`.\n */\n protected readonly chipMoreLabel = useI18nFormatter('tree.more', '+{{count}} more');\n\n /** Flattened list of currently visible nodes — what the template renders. */\n protected readonly flat = computed<readonly FlatNode<TId>[]>(() => {\n const expanded = new Set(this.expanded());\n const out: FlatNode<TId>[] = [];\n const walk = (list: readonly WrTreeNode<TId>[], depth: number): void => {\n list.forEach((node, i) => {\n const hasChildren = (node.children?.length ?? 0) > 0;\n out.push({ node, depth, hasChildren, index: out.length, posinset: i + 1, setsize: list.length });\n if (hasChildren && expanded.has(node.id)) walk(node.children!, depth + 1);\n });\n };\n walk(this.nodes(), 0);\n return out;\n });\n\n protected readonly selectedSet = computed(() => new Set(this.selected()));\n protected readonly expandedSet = computed(() => new Set(this.expanded()));\n\n protected readonly isOverlay = computed(() => this.openOn() === 'overlay');\n protected readonly isMulti = computed(() => this.selectionMode() === 'multi');\n protected readonly hasSelection = computed(() => this.selected().length > 0);\n\n /** Overlay-mode trigger label / chip map. */\n private readonly labelMap = computed<ReadonlyMap<TId, string>>(() => {\n const map = new Map<TId, string>();\n const walk = (list: readonly WrTreeNode<TId>[]): void => {\n for (const n of list) {\n map.set(n.id, n.label);\n if (n.children?.length) walk(n.children);\n }\n };\n walk(this.nodes());\n return map;\n });\n\n protected readonly selectedChips = computed<readonly SelectedChip<TId>[]>(() => {\n const map = this.labelMap();\n return this.selected().map<SelectedChip<TId>>(id => ({ id, label: map.get(id) ?? String(id) }));\n });\n\n protected readonly visibleChips = computed<readonly SelectedChip<TId>[]>(() => {\n const cap = this.maxTagCount();\n const chips = this.selectedChips();\n return cap > 0 && chips.length > cap ? chips.slice(0, cap) : chips;\n });\n\n protected readonly hiddenChipCount = computed(() => {\n const cap = this.maxTagCount();\n const total = this.selectedChips().length;\n return cap > 0 && total > cap ? total - cap : 0;\n });\n\n protected readonly singleLabel = computed<string | null>(() => {\n if (this.isMulti()) return null;\n const first = this.selected()[0];\n if (first == null) return null;\n return this.labelMap().get(first) ?? null;\n });\n\n /** Overlay open state. Only meaningful when `openOn='overlay'`. */\n protected readonly open = signal(false);\n\n /** Trigger / panel id for `aria-controls`. */\n protected readonly panelId = `wr-tree-panel-${++panelUid}`;\n\n protected readonly classes = computed(() => {\n const parts = ['wr-tree'];\n if (this.disabled()) parts.push('wr-tree--disabled');\n else if (this.readonly()) parts.push('wr-tree--readonly');\n if (this.isOverlay()) {\n parts.push('wr-tree--combobox');\n if (this.open()) parts.push('wr-tree--open');\n if (this.isMulti()) parts.push('wr-tree--multi');\n }\n return parts.join(' ');\n });\n\n protected readonly panelTpl = viewChild('panelTpl', { read: TemplateRef });\n\n private overlayRef: OverlayRef | null = null;\n\n // --- Virtual scroll -------------------------------------------------------\n\n private static readonly FALLBACK_ROW_PX = 32;\n private static readonly FALLBACK_VIEWPORT_PX = 288;\n\n /** Live vertical scroll offset (px); 0 on the server / before first scroll. */\n private readonly scrollTop = signal(0);\n /** Measured viewport clientHeight (px); 0 until the browser observer fires. */\n private readonly viewportPx = signal(0);\n /** Measured first-row height (px) when `rowHeight` is auto; 0 until measured. */\n private readonly measuredRowPx = signal(0);\n\n /** Virtualization active (opt-in and there is anything to window). */\n protected readonly virtualized = computed(() => this.virtualScroll() && this.flat().length > 0);\n\n /** Effective uniform row height (px). */\n protected readonly effRowH = computed(() =>\n this.rowHeight() > 0 ? this.rowHeight() : this.measuredRowPx() || WrTree.FALLBACK_ROW_PX\n );\n\n /** Deterministic viewport px for SSR + first paint (numeric height, else fallback). */\n private readonly fallbackViewportPx = computed(() => {\n const h = this.viewportHeight();\n if (typeof h === 'number') return h;\n return /^\\d+$/.test(h) ? Number(h) : WrTree.FALLBACK_VIEWPORT_PX;\n });\n\n /** `viewportHeight` as a CSS length for the inline max-height (bare number → px). */\n protected readonly resolvedViewportHeight = computed(() => {\n const h = this.viewportHeight();\n return typeof h === 'number' || /^\\d+$/.test(h) ? `${h}px` : h;\n });\n\n /** Rendered window [start,end) + spacer pads (px). Pure math from `scrollTop`. */\n protected readonly virtualWindow = computed<{ start: number; end: number; padTop: number; padBottom: number }>(() => {\n const total = this.flat().length;\n if (!this.virtualized() || total === 0) return { start: 0, end: total, padTop: 0, padBottom: 0 };\n const h = this.effRowH();\n const vp = this.viewportPx() || this.fallbackViewportPx();\n const over = this.overscan();\n // Clamp `first` so a transient effRowH shrink (auto-measure landing below the\n // fallback within one frame) can't push it past the list and slice to empty.\n const first = Math.min(Math.floor(this.scrollTop() / h), total - 1);\n // `+ 1` covers the partial row at the viewport's bottom edge even at overscan 0.\n const count = Math.ceil(vp / h) + 1;\n const start = Math.max(0, first - over);\n const end = Math.min(total, first + count + over);\n return { start, end, padTop: start * h, padBottom: (total - end) * h };\n });\n\n /** Nodes placed in the list. SAME array instance as `flat()` when off → byte-identical DOM. */\n protected readonly windowRows = computed<readonly FlatNode<TId>[]>(() => {\n if (!this.virtualized()) return this.flat();\n const { start, end } = this.virtualWindow();\n return this.flat().slice(start, end);\n });\n\n /** Stable id for a row at flat index `i` — the `aria-activedescendant` target. */\n protected rowId(i: number): string {\n return `${this.panelId}-row-${i}`;\n }\n\n /**\n * Active-descendant id when virtualized (focus stays on the list container),\n * else `null`. Returns `null` while the focused row is outside the rendered\n * window (e.g. mouse-wheeled away) so `aria-activedescendant` never dangles at\n * a removed element — the next arrow key scrolls it back and re-establishes it.\n */\n protected readonly activeRowId = computed(() => {\n if (!this.virtualized()) return null;\n const i = this.cursorIndex();\n const { start, end } = this.virtualWindow();\n return i >= start && i < end ? this.rowId(i) : null;\n });\n\n /** The scrollable `<ul>` — inside the overlay panel in overlay mode, else in the host. */\n private get listElement(): HTMLElement | null {\n const root = this.overlayRef?.overlayElement ?? this.host.nativeElement;\n return root.querySelector<HTMLElement>('.wr-tree__list');\n }\n\n /** Scroll flat index `i` just into view (sets the `scrollTop` signal synchronously). */\n private ensureVisible(i: number): void {\n const h = this.effRowH();\n const vp = this.viewportPx() || this.fallbackViewportPx();\n const top = i * h;\n const cur = this.scrollTop();\n let next = cur;\n if (top < cur) next = top;\n else if (top + h > cur + vp) next = top + h - vp;\n if (next !== cur) {\n this.scrollTop.set(next);\n this.listElement?.scrollTo({ top: next });\n }\n }\n\n /** Whether this OPEN has already auto-expanded; reset when the panel closes. */\n private didExpandAll = false;\n\n constructor() {\n // Drive the overlay open/close in response to the `open` signal.\n effect(() => {\n if (!this.isOverlay()) return;\n if (this.open()) {\n this.openOverlay();\n // Once per OPEN, which is what the input documents. Reading `expanded()`\n // as part of the guard made it a dependency of this effect, so closing\n // the last branch re-ran it and inflated the tree again — collapsible one\n // branch at a time, never all the way.\n if (this.defaultExpandAll() && !this.didExpandAll) {\n this.didExpandAll = true;\n untracked(() => {\n if (this.expanded().length === 0) this.expanded.set(this.collectExpandableIds(this.nodes()));\n });\n }\n } else {\n this.didExpandAll = false;\n this.closeOverlay();\n }\n });\n\n // Disabling the control closes any open overlay (mirrors the side effect\n // of the old CVA setDisabledState).\n effect(() => {\n if (this.disabled() || this.readonly()) this.open.set(false);\n });\n\n // Bridge an external `value` write back into the internal `selected`\n // state (this is the old writeValue body). `undefined` is the untouched\n // sentinel — no field / ngModel has written yet, so leave any preset\n // `[(selected)]` alone; a real `null` still clears, exactly as\n // `writeValue(null)` did. Guarded against the echo of our own `emit()`\n // (equality check under `untracked`) so a live pick is never clobbered.\n effect(() => {\n const value = this.value();\n if (value === undefined) return;\n untracked(() => {\n const next: readonly TId[] = this.isMulti()\n ? Array.isArray(value)\n ? (value as readonly TId[])\n : []\n : value == null\n ? []\n : [value as TId];\n const current = this.selected();\n if (next.length === current.length && next.every((id, i) => id === current[i])) return;\n this.selected.set(next);\n });\n });\n\n // Wire the scroll listener + viewport/row measurement — only while virtual\n // and in the browser. Re-runs when the list (re)appears (overlay open, data\n // change), deferring the DOM read to a microtask so the portal / inline list\n // is attached. No-op on the server (SSR renders the deterministic first\n // window from inputs alone).\n effect(onCleanup => {\n if (!isPlatformBrowser(this.platformId) || !this.virtualScroll()) return;\n const open = this.isOverlay() ? this.open() : true;\n this.flat();\n if (!open) return;\n let raf = 0;\n let ro: ResizeObserver | null = null;\n let el: HTMLElement | null = null;\n // `onCleanup` can run BEFORE the microtask below — the effect re-runs, or\n // the component is destroyed, in the same task that scheduled it. It would\n // then tear down nothing (`el` and `ro` are still null) and the\n // continuation would go on to attach a scroll listener and a\n // `ResizeObserver` that nothing is left to remove.\n let cancelled = false;\n const onScroll = (): void => {\n if (raf) return;\n raf = requestAnimationFrame(() => {\n raf = 0;\n if (el) this.scrollTop.set(el.scrollTop);\n });\n };\n queueMicrotask(() => {\n if (cancelled) return;\n el = this.listElement;\n if (!el) return;\n // The overlay `<ul>` is destroyed + recreated on each open, but the\n // `scrollTop` signal persists — restore the fresh element to it so a\n // reopened panel isn't blank (window computed from a non-zero signal\n // while the new DOM sits at scrollTop 0). No-op on first open / inline.\n if (el.scrollTop !== this.scrollTop()) el.scrollTop = this.scrollTop();\n this.viewportPx.set(el.clientHeight);\n if (this.rowHeight() === 0) {\n const h = el.querySelector<HTMLElement>('.wr-tree__row')?.offsetHeight ?? 0;\n if (h > 0) this.measuredRowPx.set(h);\n }\n el.addEventListener('scroll', onScroll, { passive: true });\n if (typeof ResizeObserver !== 'undefined') {\n ro = new ResizeObserver(() => {\n if (el) this.viewportPx.set(el.clientHeight);\n });\n ro.observe(el);\n }\n });\n onCleanup(() => {\n cancelled = true;\n if (raf) cancelAnimationFrame(raf);\n if (el) el.removeEventListener('scroll', onScroll);\n ro?.disconnect();\n });\n });\n\n this.destroyRef.onDestroy(() => this.closeOverlay());\n }\n\n // Template handlers\n\n protected onRowClick(flat: FlatNode<TId>, event: MouseEvent): void {\n if (this.disabled() || flat.node.disabled) return;\n if (flat.hasChildren && (event.target as HTMLElement).closest('.wr-tree__toggle')) {\n this.toggleExpanded(flat.node.id);\n return;\n }\n this.focusIndex(flat.index);\n this.select(flat.node.id, event.ctrlKey || event.metaKey);\n }\n\n protected onToggleClick(node: WrTreeNode<TId>, event: MouseEvent): void {\n event.stopPropagation();\n if (this.disabled() || node.disabled) return;\n this.toggleExpanded(node.id);\n }\n\n /**\n * Map a physical arrow onto the expand / collapse axis.\n *\n * The APG gives ArrowRight the job of opening a branch and ArrowLeft the job\n * of closing it because the arrows follow the INDENT, and the indent grows\n * rightward. Under `dir=\"rtl\"` it grows leftward, so the two swap — without\n * this an RTL user cannot open a node at all.\n *\n * Up / Down travel the block axis and Home / End name a semantic position\n * (first / last), so all four are returned untouched in both directions.\n */\n private inlineKey(key: string): string {\n if (this.dir?.value !== 'rtl') return key;\n if (key === 'ArrowRight') return 'ArrowLeft';\n if (key === 'ArrowLeft') return 'ArrowRight';\n return key;\n }\n\n protected onKeydown(event: KeyboardEvent): void {\n if (this.disabled()) return;\n const flat = this.flat();\n const i = this.cursorIndex();\n const current = flat[i];\n if (!current) return;\n\n // The cursor move is identical in both render shapes — `focusIndex()` owns\n // the roving-tabindex / `aria-activedescendant` split — so mirroring here\n // covers the windowed tree too.\n switch (this.inlineKey(event.key)) {\n case 'ArrowDown':\n event.preventDefault();\n this.focusIndex(Math.min(flat.length - 1, i + 1));\n break;\n case 'ArrowUp':\n event.preventDefault();\n this.focusIndex(Math.max(0, i - 1));\n break;\n case 'ArrowRight':\n event.preventDefault();\n if (current.hasChildren && !this.expandedSet().has(current.node.id)) {\n this.toggleExpanded(current.node.id);\n } else if (current.hasChildren) {\n this.focusIndex(Math.min(flat.length - 1, i + 1));\n }\n break;\n case 'ArrowLeft':\n event.preventDefault();\n if (current.hasChildren && this.expandedSet().has(current.node.id)) {\n this.toggleExpanded(current.node.id);\n } else if (current.depth > 0) {\n for (let j = i - 1; j >= 0; j--) {\n if (flat[j].depth < current.depth) {\n this.focusIndex(j);\n break;\n }\n }\n }\n break;\n case 'Home':\n event.preventDefault();\n this.focusIndex(0);\n break;\n case 'End':\n event.preventDefault();\n this.focusIndex(flat.length - 1);\n break;\n case 'Enter':\n case ' ':\n event.preventDefault();\n if (!current.node.disabled) this.select(current.node.id, event.ctrlKey || event.metaKey);\n break;\n default:\n break;\n }\n }\n\n // Overlay-mode trigger handlers\n\n protected onTriggerClick(): void {\n if (this.disabled() || this.readonly()) return;\n this.open.update(v => !v);\n }\n\n /** Trigger blur — mark the bound field touched. */\n protected onBlur(): void {\n this.touch.emit();\n }\n\n protected removeChip(id: TId, event: Event): void {\n event.stopPropagation();\n if (this.disabled() || this.readonly()) return;\n const next = this.selected().filter(x => x !== id);\n this.selected.set(next);\n this.emit();\n }\n\n protected clearSelection(event: Event): void {\n event.stopPropagation();\n if (this.disabled() || this.readonly()) return;\n this.selected.set([]);\n this.emit();\n }\n\n // Selection / expansion plumbing\n\n private toggleExpanded(id: TId): void {\n const set = new Set(this.expanded());\n if (set.has(id)) set.delete(id);\n else set.add(id);\n this.expanded.set([...set]);\n }\n\n private select(id: TId, additive: boolean): void {\n // Every selection path funnels through here — row click, Enter, Space — so\n // one guard covers them all while expand / collapse stays reachable.\n if (this.readonly()) return;\n const mode = this.selectionMode();\n if (mode === 'none') return;\n if (mode === 'single') {\n this.selected.set([id]);\n } else {\n const set = new Set(this.selected());\n if (additive) {\n if (set.has(id)) set.delete(id);\n else set.add(id);\n } else {\n // Plain click toggles single id in multi mode — common UX.\n if (set.size === 1 && set.has(id)) set.delete(id);\n else {\n set.clear();\n set.add(id);\n }\n }\n this.selected.set([...set]);\n }\n\n // Propagate to the bound value — in BOTH modes. The inbound half of this\n // bridge (the `value` -> `selected` effect above) was never gated, so\n // gating the outbound half left an inline tree in a form accepting a\n // programmatic write and never reporting the user's pick: `[formField]`\n // compiled, rows announced `aria-selected`, and the control stayed at its\n // initial value forever. One-way is worse than unsupported, because it\n // looks wired up. `[(selected)]` remains the inline-native API; `value`\n // simply stops lying. Closing on a single pick stays overlay-only — an\n // inline tree has no panel to close.\n this.emit();\n if (this.isOverlay() && mode === 'single' && this.selected().length > 0) {\n this.open.set(false);\n }\n }\n\n private emit(): void {\n this.touch.emit();\n if (this.isMulti()) {\n this.value.set(this.selected());\n } else {\n this.value.set(this.selected()[0] ?? null);\n }\n }\n\n private focusIndex(i: number): void {\n this.focusedIndex.set(i);\n if (this.virtualized()) {\n // Managed-focus (aria-activedescendant): focus stays on the list container.\n // Setting `scrollTop` synchronously materializes row `i` in the SAME change\n // detection pass, so the id referenced by `aria-activedescendant` is present\n // — no rAF/microtask race, no \"points at an absent id\" gap.\n this.ensureVisible(i);\n this.listElement?.focus();\n return;\n }\n // Non-virtual roving tabindex: defer so the DOM has updated tabindex, then\n // move focus to the row element.\n queueMicrotask(() => {\n const root = this.overlayRef?.overlayElement ?? this.host.nativeElement;\n const row = root.querySelector<HTMLElement>(`[data-tree-index=\"${i}\"]`);\n row?.focus();\n });\n }\n\n // Overlay\n\n private collectExpandableIds(list: readonly WrTreeNode<TId>[]): readonly TId[] {\n const out: TId[] = [];\n const walk = (items: readonly WrTreeNode<TId>[]): void => {\n for (const n of items) {\n if (n.children?.length) {\n out.push(n.id);\n walk(n.children);\n }\n }\n };\n walk(list);\n return out;\n }\n\n private openOverlay(): void {\n if (this.overlayRef) return;\n const tpl = this.panelTpl();\n if (!tpl) return;\n\n const positionStrategy = this.overlay\n .position()\n .flexibleConnectedTo(this.host)\n .withPositions([\n { originX: 'start', originY: 'bottom', overlayX: 'start', overlayY: 'top' },\n { originX: 'start', originY: 'top', overlayX: 'start', overlayY: 'bottom' },\n ])\n .withPush(true);\n\n this.overlayRef = this.overlay.create({\n positionStrategy,\n scrollStrategy: this.scrollStrategies.reposition(),\n width: this.host.nativeElement.getBoundingClientRect().width,\n panelClass: 'wr-tree-overlay',\n });\n\n this.overlayRef.attach(new TemplatePortal(tpl, this.vcr));\n\n // The panel owns the keyboard from here, in BOTH render shapes. `onKeydown`\n // lives on the `<ul>` inside the portal and the trigger has no handler of\n // its own, so leaving focus on the trigger — which is what the non-virtual\n // shape used to do — made an overlay tree mouse-only: arrows, Home/End and\n // Enter all did nothing, and the rows were reachable only by tabbing through\n // the rest of the page, since the pane is appended to `<body>`. Virtual mode\n // focuses the LIST (managed focus via `aria-activedescendant`); the\n // non-virtual shape focuses the roving row, which carries the tab stop.\n //\n // `afterNextRender`, NOT `queueMicrotask`: under zoneless CD the scheduler\n // runs change detection in a macrotask, so a microtask queued here fires\n // first and focuses whatever the panel held before this open — the same trap\n // that once left `wr-calendar`'s ring and real focus on different days.\n afterNextRender(\n () => {\n if (this.virtualized()) {\n this.listElement?.focus();\n return;\n }\n const row = this.overlayRef?.overlayElement.querySelector<HTMLElement>(\n `[data-tree-index=\"${this.cursorIndex()}\"]`\n );\n row?.focus();\n },\n { injector: this.injector }\n );\n\n this.outsideClick\n .outsidePointerEvents(this.overlayRef)\n .pipe(takeUntilDestroyed(this.destroyRef))\n .subscribe(event => {\n if (this.host.nativeElement.contains(event.target as Node)) return;\n this.open.set(false);\n });\n\n this.overlayRef\n .keydownEvents()\n .pipe(takeUntilDestroyed(this.destroyRef))\n .subscribe(event => {\n if (event.key === 'Escape') {\n event.preventDefault();\n this.open.set(false);\n }\n });\n }\n\n private closeOverlay(): void {\n if (!this.overlayRef) return;\n // Hand the focus back before the panel it lives in disappears. The keyboard\n // path in virtual mode focuses the list itself, so closing left the document\n // focused on `<body>` and the next Tab started from the top of the page —\n // `wr-dropdown` returns focus to its own trigger for the same reason.\n const active = this.host.nativeElement.ownerDocument.activeElement;\n const inPanel = active instanceof Node && this.overlayRef.overlayElement.contains(active);\n this.overlayRef.dispose();\n this.overlayRef = null;\n if (inPanel) this.host.nativeElement.querySelector<HTMLElement>('.wr-tree__trigger')?.focus();\n }\n}\n","@if (isOverlay()) {\n <button\n type=\"button\"\n class=\"wr-tree__trigger\"\n role=\"combobox\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [disabled]=\"disabled()\"\n [attr.aria-haspopup]=\"'tree'\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"panelId\"\n [attr.aria-readonly]=\"readonly() || null\"\n [attr.aria-invalid]=\"fieldAria.ariaInvalid()\"\n [attr.aria-describedby]=\"fieldAria.describedBy()\"\n (click)=\"onTriggerClick()\"\n (blur)=\"onBlur()\"\n >\n @if (isMulti()) {\n @if (hasSelection()) {\n <span class=\"wr-tree__chips\">\n @for (chip of visibleChips(); track chip.id) {\n <span class=\"wr-tree__chip\">\n <span class=\"wr-tree__chip-label\">{{ chip.label }}</span>\n <span\n class=\"wr-tree__chip-remove\"\n role=\"button\"\n [attr.aria-label]=\"chipRemoveLabel({ label: chip.label })\"\n tabindex=\"-1\"\n (click)=\"removeChip(chip.id, $event)\"\n (keydown.enter)=\"removeChip(chip.id, $event)\"\n (keydown.space)=\"removeChip(chip.id, $event)\"\n >\n <svg\n class=\"wr-icon__svg\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"M18 6 6 18\" />\n <path d=\"m6 6 12 12\" />\n </svg>\n </span>\n </span>\n }\n @if (hiddenChipCount(); as extra) {\n <span class=\"wr-tree__chip wr-tree__chip--more\">{{ chipMoreLabel({ count: extra }) }}</span>\n }\n </span>\n } @else {\n <span class=\"wr-tree__placeholder\">{{ resolvedPlaceholder() }}</span>\n }\n } @else {\n @if (singleLabel(); as label) {\n <span class=\"wr-tree__value\">{{ label }}</span>\n } @else {\n <span class=\"wr-tree__placeholder\">{{ resolvedPlaceholder() }}</span>\n }\n }\n\n @if (clearable() && hasSelection() && !disabled() && !readonly()) {\n <span\n class=\"wr-tree__clear\"\n role=\"button\"\n [attr.aria-label]=\"clearLabel()\"\n tabindex=\"-1\"\n (click)=\"clearSelection($event)\"\n (keydown.enter)=\"clearSelection($event)\"\n (keydown.space)=\"clearSelection($event)\"\n >\n <svg\n class=\"wr-icon__svg\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"M18 6 6 18\" />\n <path d=\"m6 6 12 12\" />\n </svg>\n </span>\n }\n\n <svg\n class=\"wr-icon__svg wr-tree__chevron\"\n xmlns=\"http://www.w3.org/2000/svg\"\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=\"m6 9 6 6 6-6\" />\n </svg>\n </button>\n\n <!-- Tree list lives inside the overlay panel. -->\n <ng-template #panelTpl>\n <div class=\"wr-tree-panel\" [class.wr-tree-panel--virtual]=\"virtualized()\" [attr.id]=\"panelId\">\n <ng-container [ngTemplateOutlet]=\"listTpl\" />\n </div>\n </ng-template>\n} @else {\n <ng-container [ngTemplateOutlet]=\"listTpl\" />\n}\n\n<!-- Shared row list — rendered inline (default) or projected into the\n overlay panel (when openOn=\"overlay\"). -->\n<ng-template #listTpl>\n <!-- Roving tabindex (non-virtual) / aria-activedescendant (virtual): the tree\n owns keyboard focus and routes arrow keys to its currently-focused row.\n The field's error state is bound here for the INLINE shape only — in\n overlay mode the trigger carries it, and the panel would otherwise\n describe the same error a second time. -->\n <ul\n class=\"wr-tree__list\"\n role=\"tree\"\n [attr.aria-multiselectable]=\"isMulti() ? 'true' : null\"\n [attr.aria-invalid]=\"isOverlay() ? null : fieldAria.ariaInvalid()\"\n [attr.aria-describedby]=\"isOverlay() ? null : fieldAria.describedBy()\"\n [class.wr-tree__list--virtual]=\"virtualized()\"\n [attr.tabindex]=\"virtualized() ? 0 : null\"\n [attr.aria-activedescendant]=\"activeRowId()\"\n [style.max-height]=\"virtualized() ? resolvedViewportHeight() : null\"\n [style.overflow-y]=\"virtualized() ? 'auto' : null\"\n (keydown)=\"onKeydown($event)\"\n >\n @if (virtualized() && virtualWindow().padTop > 0) {\n <!-- `aria-setsize` / `aria-posinset` in BOTH shapes: the list is flat with no\n `role=\"group\"` either way, so the set a row belongs to is never expressed\n by the DOM. Gated behind the virtual flag, the same tree announced a\n position with windowing on and nothing with it off. -->\n <li\n class=\"wr-tree__spacer\"\n role=\"presentation\"\n aria-hidden=\"true\"\n [style.height.px]=\"virtualWindow().padTop\"\n ></li>\n }\n @for (entry of windowRows(); track entry.node.id) {\n <!-- Click handler lives on focusable rows; keyboard handling is owned\n by the parent <ul> via the roving-tabindex pattern. -->\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events -->\n <li\n class=\"wr-tree__row\"\n role=\"treeitem\"\n [attr.id]=\"virtualized() ? rowId(entry.index) : null\"\n [class.wr-tree__row--selected]=\"selectedSet().has(entry.node.id)\"\n [class.wr-tree__row--active]=\"virtualized() && entry.index === cursorIndex()\"\n [class.wr-tree__row--disabled]=\"entry.node.disabled\"\n [attr.aria-level]=\"entry.depth + 1\"\n [attr.aria-setsize]=\"entry.setsize\"\n [attr.aria-posinset]=\"entry.posinset\"\n [attr.aria-expanded]=\"entry.hasChildren ? expandedSet().has(entry.node.id) : null\"\n [attr.aria-selected]=\"selectionMode() === 'none' ? null : selectedSet().has(entry.node.id)\"\n [attr.aria-disabled]=\"entry.node.disabled || disabled() || null\"\n [attr.data-tree-index]=\"entry.index\"\n [attr.tabindex]=\"virtualized() ? null : entry.index === cursorIndex() ? 0 : -1\"\n [style.--wr-tree-depth]=\"entry.depth\"\n (click)=\"onRowClick(entry, $event)\"\n >\n @if (entry.hasChildren) {\n <button\n type=\"button\"\n class=\"wr-tree__toggle\"\n tabindex=\"-1\"\n [attr.aria-label]=\"expandedSet().has(entry.node.id) ? collapseLabel() : expandLabel()\"\n (click)=\"onToggleClick(entry.node, $event)\"\n >\n <svg width=\"10\" height=\"10\" viewBox=\"0 0 10 10\" aria-hidden=\"true\">\n <path d=\"M3 1 L7 5 L3 9 Z\" fill=\"currentColor\" />\n </svg>\n </button>\n } @else {\n <span class=\"wr-tree__toggle wr-tree__toggle--leaf\" aria-hidden=\"true\"></span>\n }\n <span class=\"wr-tree__label\">{{ entry.node.label }}</span>\n </li>\n }\n @if (virtualized() && virtualWindow().padBottom > 0) {\n <li\n class=\"wr-tree__spacer\"\n role=\"presentation\"\n aria-hidden=\"true\"\n [style.height.px]=\"virtualWindow().padBottom\"\n ></li>\n }\n </ul>\n</ng-template>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;AAKG;AAqDH,IAAI,QAAQ,GAAG,CAAC;AAEhB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAsCG;MAQU,MAAM,CAAA;;IAER,KAAK,GAAG,KAAK,CAA6B,EAAE;8EAAC;;IAG7C,QAAQ,GAAG,KAAK,CAAiB,EAAE;iFAAC;;IAGpC,QAAQ,GAAG,KAAK,CAAiB,EAAE;iFAAC;;IAGpC,aAAa,GAAG,KAAK,CAAsB,QAAQ;sFAAC;AAE7D;;;;;AAKG;IACM,QAAQ,GAAG,KAAK,CAAC,KAAK,gFAAI,SAAS,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,EAAA,IAAA,EAAA,EAAA,CAAA,MAAA,EAAA,IAAA,EAAA,CAAA,OAAA,CAAA,EAAA,CAAA,EAAA,QAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,SAAA,EAAA,IAAA,EAAA,CAAA,UAAU,EAAA,EAAA,GAAE,EAAE,IAAI,EAAE,WAAW,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;AE3W3E;;AAEG;;;;"}
@@ -224,10 +224,10 @@ class WrTypewriter {
224
224
  this.phase.set('deleting');
225
225
  this.scheduleNext(this.pauseDuration());
226
226
  }
227
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrTypewriter, deps: [], target: i0.ɵɵFactoryTarget.Component });
228
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: WrTypewriter, isStandalone: true, selector: "wr-typewriter", inputs: { text: { classPropertyName: "text", publicName: "text", isSignal: true, isRequired: false, transformFunction: null }, texts: { classPropertyName: "texts", publicName: "texts", isSignal: true, isRequired: false, transformFunction: null }, typingSpeed: { classPropertyName: "typingSpeed", publicName: "typingSpeed", isSignal: true, isRequired: false, transformFunction: null }, initialDelay: { classPropertyName: "initialDelay", publicName: "initialDelay", isSignal: true, isRequired: false, transformFunction: null }, pauseDuration: { classPropertyName: "pauseDuration", publicName: "pauseDuration", isSignal: true, isRequired: false, transformFunction: null }, deletingSpeed: { classPropertyName: "deletingSpeed", publicName: "deletingSpeed", isSignal: true, isRequired: false, transformFunction: null }, loop: { classPropertyName: "loop", publicName: "loop", isSignal: true, isRequired: false, transformFunction: null }, showCursor: { classPropertyName: "showCursor", publicName: "showCursor", isSignal: true, isRequired: false, transformFunction: null }, hideCursorWhileTyping: { classPropertyName: "hideCursorWhileTyping", publicName: "hideCursorWhileTyping", isSignal: true, isRequired: false, transformFunction: null }, cursorCharacter: { classPropertyName: "cursorCharacter", publicName: "cursorCharacter", isSignal: true, isRequired: false, transformFunction: null }, cursorBlinkDuration: { classPropertyName: "cursorBlinkDuration", publicName: "cursorBlinkDuration", isSignal: true, isRequired: false, transformFunction: null }, textColors: { classPropertyName: "textColors", publicName: "textColors", isSignal: true, isRequired: false, transformFunction: null }, variableSpeed: { classPropertyName: "variableSpeed", publicName: "variableSpeed", isSignal: true, isRequired: false, transformFunction: null }, reverseMode: { classPropertyName: "reverseMode", publicName: "reverseMode", isSignal: true, isRequired: false, transformFunction: null }, startOnVisible: { classPropertyName: "startOnVisible", publicName: "startOnVisible", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { sentenceComplete: "sentenceComplete" }, host: { properties: { "style.color": "activeColor()", "style.--wr-typewriter-cursor-blink": "cursorBlinkDuration() + 's'" }, classAttribute: "wr-typewriter" }, ngImport: i0, template: "<span class=\"wr-typewriter__content\">{{ displayed() }}</span>\n@if (cursorVisible()) {\n <span class=\"wr-typewriter__cursor\" aria-hidden=\"true\">{{ cursorCharacter() }}</span>\n}\n", styles: [".wr-typewriter{--wr-typewriter-cursor-blink: .5s;display:inline-flex;align-items:baseline}.wr-typewriter__content{white-space:pre}.wr-typewriter__cursor{display:inline-block;margin-inline-start:1px;animation:wr-typewriter-blink var(--wr-typewriter-cursor-blink) ease-in-out infinite alternate}@keyframes wr-typewriter-blink{0%{opacity:1}to{opacity:0}}@media(prefers-reduced-motion:reduce){.wr-typewriter__cursor{animation:none;opacity:1}}\n"], encapsulation: i0.ViewEncapsulation.None });
227
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrTypewriter, deps: [], target: i0.ɵɵFactoryTarget.Component });
228
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.5", type: WrTypewriter, isStandalone: true, selector: "wr-typewriter", inputs: { text: { classPropertyName: "text", publicName: "text", isSignal: true, isRequired: false, transformFunction: null }, texts: { classPropertyName: "texts", publicName: "texts", isSignal: true, isRequired: false, transformFunction: null }, typingSpeed: { classPropertyName: "typingSpeed", publicName: "typingSpeed", isSignal: true, isRequired: false, transformFunction: null }, initialDelay: { classPropertyName: "initialDelay", publicName: "initialDelay", isSignal: true, isRequired: false, transformFunction: null }, pauseDuration: { classPropertyName: "pauseDuration", publicName: "pauseDuration", isSignal: true, isRequired: false, transformFunction: null }, deletingSpeed: { classPropertyName: "deletingSpeed", publicName: "deletingSpeed", isSignal: true, isRequired: false, transformFunction: null }, loop: { classPropertyName: "loop", publicName: "loop", isSignal: true, isRequired: false, transformFunction: null }, showCursor: { classPropertyName: "showCursor", publicName: "showCursor", isSignal: true, isRequired: false, transformFunction: null }, hideCursorWhileTyping: { classPropertyName: "hideCursorWhileTyping", publicName: "hideCursorWhileTyping", isSignal: true, isRequired: false, transformFunction: null }, cursorCharacter: { classPropertyName: "cursorCharacter", publicName: "cursorCharacter", isSignal: true, isRequired: false, transformFunction: null }, cursorBlinkDuration: { classPropertyName: "cursorBlinkDuration", publicName: "cursorBlinkDuration", isSignal: true, isRequired: false, transformFunction: null }, textColors: { classPropertyName: "textColors", publicName: "textColors", isSignal: true, isRequired: false, transformFunction: null }, variableSpeed: { classPropertyName: "variableSpeed", publicName: "variableSpeed", isSignal: true, isRequired: false, transformFunction: null }, reverseMode: { classPropertyName: "reverseMode", publicName: "reverseMode", isSignal: true, isRequired: false, transformFunction: null }, startOnVisible: { classPropertyName: "startOnVisible", publicName: "startOnVisible", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { sentenceComplete: "sentenceComplete" }, host: { properties: { "style.color": "activeColor()", "style.--wr-typewriter-cursor-blink": "cursorBlinkDuration() + 's'" }, classAttribute: "wr-typewriter" }, ngImport: i0, template: "<span class=\"wr-typewriter__content\">{{ displayed() }}</span>\n@if (cursorVisible()) {\n <span class=\"wr-typewriter__cursor\" aria-hidden=\"true\">{{ cursorCharacter() }}</span>\n}\n", styles: [".wr-typewriter{--wr-typewriter-cursor-blink: .5s;display:inline-flex;align-items:baseline}.wr-typewriter__content{white-space:pre}.wr-typewriter__cursor{display:inline-block;margin-inline-start:1px;animation:wr-typewriter-blink var(--wr-typewriter-cursor-blink) ease-in-out infinite alternate}@keyframes wr-typewriter-blink{0%{opacity:1}to{opacity:0}}@media(prefers-reduced-motion:reduce){.wr-typewriter__cursor{animation:none;opacity:1}}\n"], encapsulation: i0.ViewEncapsulation.None });
229
229
  }
230
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrTypewriter, decorators: [{
230
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrTypewriter, decorators: [{
231
231
  type: Component,
232
232
  args: [{ selector: 'wr-typewriter', encapsulation: ViewEncapsulation.None, host: {
233
233
  class: 'wr-typewriter',
@@ -60,10 +60,10 @@ class WrTypography {
60
60
  return parts.join(' ');
61
61
  }, /* @ts-ignore */
62
62
  ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
63
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrTypography, deps: [], target: i0.ɵɵFactoryTarget.Directive });
64
- static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.1.4", type: WrTypography, isStandalone: true, selector: "[wrTypography]", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, tone: { classPropertyName: "tone", publicName: "tone", isSignal: true, isRequired: false, transformFunction: null }, align: { classPropertyName: "align", publicName: "align", isSignal: true, isRequired: false, transformFunction: null }, truncate: { classPropertyName: "truncate", publicName: "truncate", isSignal: true, isRequired: false, transformFunction: null }, mono: { classPropertyName: "mono", publicName: "mono", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0 });
63
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrTypography, deps: [], target: i0.ɵɵFactoryTarget.Directive });
64
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.1.5", type: WrTypography, isStandalone: true, selector: "[wrTypography]", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, tone: { classPropertyName: "tone", publicName: "tone", isSignal: true, isRequired: false, transformFunction: null }, align: { classPropertyName: "align", publicName: "align", isSignal: true, isRequired: false, transformFunction: null }, truncate: { classPropertyName: "truncate", publicName: "truncate", isSignal: true, isRequired: false, transformFunction: null }, mono: { classPropertyName: "mono", publicName: "mono", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0 });
65
65
  }
66
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrTypography, decorators: [{
66
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrTypography, decorators: [{
67
67
  type: Directive,
68
68
  args: [{
69
69
  selector: '[wrTypography]',
@@ -16,7 +16,7 @@ import { InjectionToken } from '@angular/core';
16
16
  * Distinct from `Version` exported by `@angular/core`, which reports the
17
17
  * loaded Angular runtime version (e.g. `'22.0.0'`), not ngwr's.
18
18
  */
19
- const NGWR_VERSION = '14.0.0';
19
+ const NGWR_VERSION = '14.1.0';
20
20
 
21
21
  /**
22
22
  * @license
@@ -1 +1 @@
1
- {"version":3,"file":"ngwr-version.mjs","sources":["../../../projects/lib/version/version.ts","../../../projects/lib/version/version.token.ts","../../../projects/lib/version/ngwr-version.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\n/**\n * The ngwr library version string, kept in sync with\n * `projects/lib/package.json` by `scripts/release-prepare.ts`.\n *\n * Prefer this over reading `package.json` at runtime — that requires a JSON\n * import or `require`, neither of which tree-shakes well in Angular builds.\n *\n * Distinct from `Version` exported by `@angular/core`, which reports the\n * loaded Angular runtime version (e.g. `'22.0.0'`), not ngwr's.\n */\nexport const NGWR_VERSION = '14.0.0';\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 { InjectionToken } from '@angular/core';\n\nimport { NGWR_VERSION } from './version';\n\n/**\n * Injection token holding the ngwr library version string.\n *\n * Default factory returns {@link NGWR_VERSION}. Override it in tests or in\n * apps that want to surface a custom build identifier.\n *\n * @example\n * ```ts\n * @Component({...})\n * export class FooterComponent {\n * readonly version = inject(NGWR_VERSION_TOKEN);\n * }\n * ```\n */\nexport const NGWR_VERSION_TOKEN = new InjectionToken<string>('NGWR_VERSION_TOKEN', {\n providedIn: 'root',\n factory: () => NGWR_VERSION,\n});\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;AAAA;;;;;AAKG;AAEH;;;;;;;;;AASG;AACI,MAAM,YAAY,GAAG;;ACjB5B;;;;;AAKG;AAMH;;;;;;;;;;;;;AAaG;MACU,kBAAkB,GAAG,IAAI,cAAc,CAAS,oBAAoB,EAAE;AACjF,IAAA,UAAU,EAAE,MAAM;AAClB,IAAA,OAAO,EAAE,MAAM,YAAY;AAC5B,CAAA;;AC5BD;;AAEG;;;;"}
1
+ {"version":3,"file":"ngwr-version.mjs","sources":["../../../projects/lib/version/version.ts","../../../projects/lib/version/version.token.ts","../../../projects/lib/version/ngwr-version.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\n/**\n * The ngwr library version string, kept in sync with\n * `projects/lib/package.json` by `scripts/release-prepare.ts`.\n *\n * Prefer this over reading `package.json` at runtime — that requires a JSON\n * import or `require`, neither of which tree-shakes well in Angular builds.\n *\n * Distinct from `Version` exported by `@angular/core`, which reports the\n * loaded Angular runtime version (e.g. `'22.0.0'`), not ngwr's.\n */\nexport const NGWR_VERSION = '14.1.0';\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 { InjectionToken } from '@angular/core';\n\nimport { NGWR_VERSION } from './version';\n\n/**\n * Injection token holding the ngwr library version string.\n *\n * Default factory returns {@link NGWR_VERSION}. Override it in tests or in\n * apps that want to surface a custom build identifier.\n *\n * @example\n * ```ts\n * @Component({...})\n * export class FooterComponent {\n * readonly version = inject(NGWR_VERSION_TOKEN);\n * }\n * ```\n */\nexport const NGWR_VERSION_TOKEN = new InjectionToken<string>('NGWR_VERSION_TOKEN', {\n providedIn: 'root',\n factory: () => NGWR_VERSION,\n});\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;AAAA;;;;;AAKG;AAEH;;;;;;;;;AASG;AACI,MAAM,YAAY,GAAG;;ACjB5B;;;;;AAKG;AAMH;;;;;;;;;;;;;AAaG;MACU,kBAAkB,GAAG,IAAI,cAAc,CAAS,oBAAoB,EAAE;AACjF,IAAA,UAAU,EAAE,MAAM;AAClB,IAAA,OAAO,EAAE,MAAM,YAAY;AAC5B,CAAA;;AC5BD;;AAEG;;;;"}
@@ -111,10 +111,10 @@ class WrVirtualScroll {
111
111
  checkViewportSize() {
112
112
  this.viewport().checkViewportSize();
113
113
  }
114
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrVirtualScroll, deps: [], target: i0.ɵɵFactoryTarget.Component });
115
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "22.1.4", type: WrVirtualScroll, isStandalone: true, selector: "wr-virtual-scroll", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: true, transformFunction: null }, itemSize: { classPropertyName: "itemSize", publicName: "itemSize", isSignal: true, isRequired: false, transformFunction: null }, height: { classPropertyName: "height", publicName: "height", isSignal: true, isRequired: false, transformFunction: null }, minBufferPx: { classPropertyName: "minBufferPx", publicName: "minBufferPx", isSignal: true, isRequired: false, transformFunction: null }, maxBufferPx: { classPropertyName: "maxBufferPx", publicName: "maxBufferPx", isSignal: true, isRequired: false, transformFunction: null }, trackBy: { classPropertyName: "trackBy", publicName: "trackBy", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "wr-virtual-scroll" }, queries: [{ propertyName: "rowTemplate", first: true, predicate: (TemplateRef), descendants: true, isSignal: true }], viewQueries: [{ propertyName: "viewport", first: true, predicate: CdkVirtualScrollViewport, descendants: true, isSignal: true }], ngImport: i0, template: "<cdk-virtual-scroll-viewport\n class=\"wr-virtual-scroll__viewport\"\n [itemSize]=\"itemSize()\"\n [minBufferPx]=\"resolvedMinBuffer()\"\n [maxBufferPx]=\"resolvedMaxBuffer()\"\n [style.height]=\"resolvedHeight()\"\n>\n <ng-container *cdkVirtualFor=\"let item of items(); let i = index; trackBy: trackBy()\">\n <ng-container *ngTemplateOutlet=\"rowTemplate(); context: { $implicit: item, index: i }\" />\n </ng-container>\n</cdk-virtual-scroll-viewport>\n", styles: [".wr-virtual-scroll{display:block;width:100%;overflow:hidden}.wr-virtual-scroll__viewport{width:100%;height:100%;scrollbar-width:thin}.wr-virtual-scroll__viewport::-webkit-scrollbar{width:.5rem;height:.5rem}.wr-virtual-scroll__viewport::-webkit-scrollbar-thumb{background:rgba(var(--wr-color-on-surface-rgb),.2);border-radius:999px}\n"], dependencies: [{ kind: "ngmodule", type: ScrollingModule }, { kind: "directive", type: i1.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { kind: "directive", type: i1.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }, { kind: "component", type: i1.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], encapsulation: i0.ViewEncapsulation.None });
114
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrVirtualScroll, deps: [], target: i0.ɵɵFactoryTarget.Component });
115
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "22.1.5", type: WrVirtualScroll, isStandalone: true, selector: "wr-virtual-scroll", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: true, transformFunction: null }, itemSize: { classPropertyName: "itemSize", publicName: "itemSize", isSignal: true, isRequired: false, transformFunction: null }, height: { classPropertyName: "height", publicName: "height", isSignal: true, isRequired: false, transformFunction: null }, minBufferPx: { classPropertyName: "minBufferPx", publicName: "minBufferPx", isSignal: true, isRequired: false, transformFunction: null }, maxBufferPx: { classPropertyName: "maxBufferPx", publicName: "maxBufferPx", isSignal: true, isRequired: false, transformFunction: null }, trackBy: { classPropertyName: "trackBy", publicName: "trackBy", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "wr-virtual-scroll" }, queries: [{ propertyName: "rowTemplate", first: true, predicate: (TemplateRef), descendants: true, isSignal: true }], viewQueries: [{ propertyName: "viewport", first: true, predicate: CdkVirtualScrollViewport, descendants: true, isSignal: true }], ngImport: i0, template: "<cdk-virtual-scroll-viewport\n class=\"wr-virtual-scroll__viewport\"\n [itemSize]=\"itemSize()\"\n [minBufferPx]=\"resolvedMinBuffer()\"\n [maxBufferPx]=\"resolvedMaxBuffer()\"\n [style.height]=\"resolvedHeight()\"\n>\n <ng-container *cdkVirtualFor=\"let item of items(); let i = index; trackBy: trackBy()\">\n <ng-container *ngTemplateOutlet=\"rowTemplate(); context: { $implicit: item, index: i }\" />\n </ng-container>\n</cdk-virtual-scroll-viewport>\n", styles: [".wr-virtual-scroll{display:block;width:100%;overflow:hidden}.wr-virtual-scroll__viewport{width:100%;height:100%;scrollbar-width:thin}.wr-virtual-scroll__viewport::-webkit-scrollbar{width:.5rem;height:.5rem}.wr-virtual-scroll__viewport::-webkit-scrollbar-thumb{background:rgba(var(--wr-color-on-surface-rgb),.2);border-radius:999px}\n"], dependencies: [{ kind: "ngmodule", type: ScrollingModule }, { kind: "directive", type: i1.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { kind: "directive", type: i1.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }, { kind: "component", type: i1.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], encapsulation: i0.ViewEncapsulation.None });
116
116
  }
117
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: WrVirtualScroll, decorators: [{
117
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.5", ngImport: i0, type: WrVirtualScroll, decorators: [{
118
118
  type: Component,
119
119
  args: [{ selector: 'wr-virtual-scroll', encapsulation: ViewEncapsulation.None, imports: [ScrollingModule, NgTemplateOutlet], host: { class: 'wr-virtual-scroll' }, template: "<cdk-virtual-scroll-viewport\n class=\"wr-virtual-scroll__viewport\"\n [itemSize]=\"itemSize()\"\n [minBufferPx]=\"resolvedMinBuffer()\"\n [maxBufferPx]=\"resolvedMaxBuffer()\"\n [style.height]=\"resolvedHeight()\"\n>\n <ng-container *cdkVirtualFor=\"let item of items(); let i = index; trackBy: trackBy()\">\n <ng-container *ngTemplateOutlet=\"rowTemplate(); context: { $implicit: item, index: i }\" />\n </ng-container>\n</cdk-virtual-scroll-viewport>\n", styles: [".wr-virtual-scroll{display:block;width:100%;overflow:hidden}.wr-virtual-scroll__viewport{width:100%;height:100%;scrollbar-width:thin}.wr-virtual-scroll__viewport::-webkit-scrollbar{width:.5rem;height:.5rem}.wr-virtual-scroll__viewport::-webkit-scrollbar-thumb{background:rgba(var(--wr-color-on-surface-rgb),.2);border-radius:999px}\n"] }]
120
120
  }], propDecorators: { items: [{ type: i0.Input, args: [{ isSignal: true, alias: "items", required: true }] }], itemSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "itemSize", required: false }] }], height: [{ type: i0.Input, args: [{ isSignal: true, alias: "height", required: false }] }], minBufferPx: [{ type: i0.Input, args: [{ isSignal: true, alias: "minBufferPx", required: false }] }], maxBufferPx: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxBufferPx", required: false }] }], trackBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "trackBy", required: false }] }], rowTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => TemplateRef), { isSignal: true }] }], viewport: [{ type: i0.ViewChild, args: [i0.forwardRef(() => CdkVirtualScrollViewport), { isSignal: true }] }] } });