ngwr 16.2.0 → 16.4.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.
- package/badge/styles/_tag.scss +73 -1
- package/calendar/styles/_index.scss +22 -0
- package/carousel/styles/_index.scss +53 -1
- package/cascader/styles/_rules.scss +7 -0
- package/color-picker/styles/_index.scss +21 -0
- package/date-picker/styles/_index.scss +19 -0
- package/dropdown/styles/_index.scss +13 -19
- package/fesm2022/ngwr-affix.mjs +3 -3
- package/fesm2022/ngwr-alert-testing.mjs +70 -0
- package/fesm2022/ngwr-alert-testing.mjs.map +1 -0
- package/fesm2022/ngwr-alert.mjs +3 -3
- package/fesm2022/ngwr-anchor.mjs +17 -6
- package/fesm2022/ngwr-anchor.mjs.map +1 -1
- package/fesm2022/ngwr-animations-aurora.mjs +3 -3
- package/fesm2022/ngwr-animations-blur-reveal.mjs +3 -3
- package/fesm2022/ngwr-animations-click-sparks.mjs +3 -3
- package/fesm2022/ngwr-animations-confetti.mjs +3 -3
- package/fesm2022/ngwr-animations-decode.mjs +3 -3
- package/fesm2022/ngwr-animations-destruct.mjs +3 -3
- package/fesm2022/ngwr-animations-dot-grid.mjs +3 -3
- package/fesm2022/ngwr-animations-falling-letters.mjs +3 -3
- package/fesm2022/ngwr-animations-flow-lines.mjs +3 -3
- package/fesm2022/ngwr-animations-fluid-cursor.mjs +3 -3
- package/fesm2022/ngwr-animations-glitch.mjs +3 -3
- package/fesm2022/ngwr-animations-glow-border.mjs +3 -3
- package/fesm2022/ngwr-animations-gradient-flow.mjs +3 -3
- package/fesm2022/ngwr-animations-marquee.mjs +3 -3
- package/fesm2022/ngwr-animations-orbit.mjs +3 -3
- package/fesm2022/ngwr-animations-reveal.mjs +3 -3
- package/fesm2022/ngwr-animations-ripple-grid.mjs +3 -3
- package/fesm2022/ngwr-animations-rotate-reveal.mjs +3 -3
- package/fesm2022/ngwr-animations-shimmer.mjs +3 -3
- package/fesm2022/ngwr-animations-spotlight.mjs +3 -3
- package/fesm2022/ngwr-animations-thread-lines.mjs +3 -3
- package/fesm2022/ngwr-animations-tilt.mjs +3 -3
- package/fesm2022/ngwr-animations-typewriter.mjs +3 -3
- package/fesm2022/ngwr-avatar.mjs +3 -3
- package/fesm2022/ngwr-back-top.mjs +3 -3
- package/fesm2022/ngwr-badge.mjs +129 -11
- package/fesm2022/ngwr-badge.mjs.map +1 -1
- package/fesm2022/ngwr-breadcrumbs-testing.mjs +83 -0
- package/fesm2022/ngwr-breadcrumbs-testing.mjs.map +1 -0
- package/fesm2022/ngwr-breadcrumbs.mjs +8 -8
- package/fesm2022/ngwr-breadcrumbs.mjs.map +1 -1
- package/fesm2022/ngwr-burger-testing.mjs +45 -0
- package/fesm2022/ngwr-burger-testing.mjs.map +1 -0
- package/fesm2022/ngwr-burger.mjs +3 -3
- package/fesm2022/ngwr-button.mjs +6 -6
- package/fesm2022/ngwr-calendar-testing.mjs +18 -0
- package/fesm2022/ngwr-calendar-testing.mjs.map +1 -1
- package/fesm2022/ngwr-calendar.mjs +500 -73
- package/fesm2022/ngwr-calendar.mjs.map +1 -1
- package/fesm2022/ngwr-card.mjs +9 -9
- package/fesm2022/ngwr-carousel-testing.mjs +24 -1
- package/fesm2022/ngwr-carousel-testing.mjs.map +1 -1
- package/fesm2022/ngwr-carousel.mjs +73 -10
- package/fesm2022/ngwr-carousel.mjs.map +1 -1
- package/fesm2022/ngwr-cascader.mjs +45 -37
- package/fesm2022/ngwr-cascader.mjs.map +1 -1
- package/fesm2022/ngwr-charts-bar-chart.mjs +5 -4
- package/fesm2022/ngwr-charts-bar-chart.mjs.map +1 -1
- package/fesm2022/ngwr-charts-boxplot-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-bullet-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-calendar-heatmap.mjs +3 -3
- package/fesm2022/ngwr-charts-candlestick-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-chart-legend.mjs +26 -11
- package/fesm2022/ngwr-charts-chart-legend.mjs.map +1 -1
- package/fesm2022/ngwr-charts-core.mjs +3 -3
- package/fesm2022/ngwr-charts-donut-chart.mjs +5 -4
- package/fesm2022/ngwr-charts-donut-chart.mjs.map +1 -1
- package/fesm2022/ngwr-charts-funnel-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-gauge.mjs +3 -3
- package/fesm2022/ngwr-charts-heatmap-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-line-chart-testing.mjs +3 -2
- package/fesm2022/ngwr-charts-line-chart-testing.mjs.map +1 -1
- package/fesm2022/ngwr-charts-line-chart.mjs +17 -7
- package/fesm2022/ngwr-charts-line-chart.mjs.map +1 -1
- package/fesm2022/ngwr-charts-meter-group.mjs +5 -4
- package/fesm2022/ngwr-charts-meter-group.mjs.map +1 -1
- package/fesm2022/ngwr-charts-radar-chart.mjs +5 -4
- package/fesm2022/ngwr-charts-radar-chart.mjs.map +1 -1
- package/fesm2022/ngwr-charts-scatter-chart.mjs +5 -4
- package/fesm2022/ngwr-charts-scatter-chart.mjs.map +1 -1
- package/fesm2022/ngwr-charts-sparkline.mjs +3 -3
- package/fesm2022/ngwr-charts-treemap-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-waterfall-chart.mjs +3 -3
- package/fesm2022/ngwr-checkbox.mjs +6 -6
- package/fesm2022/ngwr-clipboard.mjs +3 -3
- package/fesm2022/ngwr-collapse.mjs +9 -9
- package/fesm2022/ngwr-color-picker-testing.mjs +11 -1
- package/fesm2022/ngwr-color-picker-testing.mjs.map +1 -1
- package/fesm2022/ngwr-color-picker.mjs +153 -37
- package/fesm2022/ngwr-color-picker.mjs.map +1 -1
- package/fesm2022/ngwr-command-palette.mjs +3 -3
- package/fesm2022/ngwr-comment.mjs +10 -6
- package/fesm2022/ngwr-comment.mjs.map +1 -1
- package/fesm2022/ngwr-compare-testing.mjs +84 -0
- package/fesm2022/ngwr-compare-testing.mjs.map +1 -0
- package/fesm2022/ngwr-compare.mjs +3 -3
- package/fesm2022/ngwr-context-menu.mjs +28 -13
- package/fesm2022/ngwr-context-menu.mjs.map +1 -1
- package/fesm2022/ngwr-cookie.mjs +3 -3
- package/fesm2022/ngwr-copy-value.mjs +3 -3
- package/fesm2022/ngwr-counter.mjs +6 -6
- package/fesm2022/ngwr-date-picker-testing.mjs +30 -4
- package/fesm2022/ngwr-date-picker-testing.mjs.map +1 -1
- package/fesm2022/ngwr-date-picker.mjs +342 -69
- package/fesm2022/ngwr-date-picker.mjs.map +1 -1
- package/fesm2022/ngwr-date-stamp.mjs +3 -3
- package/fesm2022/ngwr-date.mjs +59 -8
- package/fesm2022/ngwr-date.mjs.map +1 -1
- package/fesm2022/ngwr-density.mjs +6 -6
- package/fesm2022/ngwr-descriptions.mjs +6 -6
- package/fesm2022/ngwr-dialog.mjs +18 -18
- package/fesm2022/ngwr-directives.mjs +15 -15
- package/fesm2022/ngwr-divider.mjs +3 -3
- package/fesm2022/ngwr-drawer.mjs +51 -29
- package/fesm2022/ngwr-drawer.mjs.map +1 -1
- package/fesm2022/ngwr-dropdown-testing.mjs +11 -3
- package/fesm2022/ngwr-dropdown-testing.mjs.map +1 -1
- package/fesm2022/ngwr-dropdown.mjs +70 -99
- package/fesm2022/ngwr-dropdown.mjs.map +1 -1
- package/fesm2022/ngwr-editor.mjs +4 -3
- package/fesm2022/ngwr-editor.mjs.map +1 -1
- package/fesm2022/ngwr-empty.mjs +3 -3
- package/fesm2022/ngwr-event-calendar.mjs +186 -33
- package/fesm2022/ngwr-event-calendar.mjs.map +1 -1
- package/fesm2022/ngwr-file-upload-testing.mjs +34 -2
- package/fesm2022/ngwr-file-upload-testing.mjs.map +1 -1
- package/fesm2022/ngwr-file-upload.mjs +279 -16
- package/fesm2022/ngwr-file-upload.mjs.map +1 -1
- package/fesm2022/ngwr-form.mjs +9 -9
- package/fesm2022/ngwr-form.mjs.map +1 -1
- package/fesm2022/ngwr-graph-testing.mjs +30 -0
- package/fesm2022/ngwr-graph-testing.mjs.map +1 -1
- package/fesm2022/ngwr-graph.mjs +664 -43
- package/fesm2022/ngwr-graph.mjs.map +1 -1
- package/fesm2022/ngwr-hotkey.mjs +6 -6
- package/fesm2022/ngwr-i18n-ar.mjs +27 -8
- package/fesm2022/ngwr-i18n-ar.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-cs.mjs +27 -8
- package/fesm2022/ngwr-i18n-cs.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-de.mjs +27 -8
- package/fesm2022/ngwr-i18n-de.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-en.mjs +27 -8
- package/fesm2022/ngwr-i18n-en.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-es.mjs +27 -8
- package/fesm2022/ngwr-i18n-es.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-fr.mjs +27 -8
- package/fesm2022/ngwr-i18n-fr.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-he.mjs +27 -8
- package/fesm2022/ngwr-i18n-he.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-hi.mjs +27 -8
- package/fesm2022/ngwr-i18n-hi.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-id.mjs +27 -8
- package/fesm2022/ngwr-i18n-id.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-it.mjs +27 -8
- package/fesm2022/ngwr-i18n-it.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-ja.mjs +27 -8
- package/fesm2022/ngwr-i18n-ja.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-ko.mjs +27 -8
- package/fesm2022/ngwr-i18n-ko.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-nl.mjs +27 -8
- package/fesm2022/ngwr-i18n-nl.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-pl.mjs +27 -8
- package/fesm2022/ngwr-i18n-pl.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-pt.mjs +27 -8
- package/fesm2022/ngwr-i18n-pt.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-ru.mjs +27 -8
- package/fesm2022/ngwr-i18n-ru.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-sv.mjs +27 -8
- package/fesm2022/ngwr-i18n-sv.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-tr.mjs +27 -8
- package/fesm2022/ngwr-i18n-tr.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-uk.mjs +27 -8
- package/fesm2022/ngwr-i18n-uk.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-vi.mjs +27 -8
- package/fesm2022/ngwr-i18n-vi.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-zh-tw.mjs +27 -8
- package/fesm2022/ngwr-i18n-zh-tw.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-zh.mjs +27 -8
- package/fesm2022/ngwr-i18n-zh.mjs.map +1 -1
- package/fesm2022/ngwr-i18n.mjs +9 -9
- package/fesm2022/ngwr-icon.mjs +6 -6
- package/fesm2022/ngwr-image-cropper.mjs +3 -3
- package/fesm2022/ngwr-input-number-testing.mjs +11 -0
- package/fesm2022/ngwr-input-number-testing.mjs.map +1 -1
- package/fesm2022/ngwr-input-number.mjs +68 -7
- package/fesm2022/ngwr-input-number.mjs.map +1 -1
- package/fesm2022/ngwr-input-otp.mjs +23 -3
- package/fesm2022/ngwr-input-otp.mjs.map +1 -1
- package/fesm2022/ngwr-input-testing.mjs +24 -1
- package/fesm2022/ngwr-input-testing.mjs.map +1 -1
- package/fesm2022/ngwr-input.mjs +152 -36
- package/fesm2022/ngwr-input.mjs.map +1 -1
- package/fesm2022/ngwr-keyboard.mjs +3 -3
- package/fesm2022/ngwr-knob.mjs +3 -3
- package/fesm2022/ngwr-layout.mjs +15 -15
- package/fesm2022/ngwr-lightbox.mjs +8 -8
- package/fesm2022/ngwr-lightbox.mjs.map +1 -1
- package/fesm2022/ngwr-list.mjs +8 -8
- package/fesm2022/ngwr-list.mjs.map +1 -1
- package/fesm2022/ngwr-load-state.mjs +15 -15
- package/fesm2022/ngwr-loading-bar.mjs +6 -6
- package/fesm2022/ngwr-mention.mjs +6 -6
- package/fesm2022/ngwr-meta.mjs +6 -6
- package/fesm2022/ngwr-overlay.mjs +175 -13
- package/fesm2022/ngwr-overlay.mjs.map +1 -1
- package/fesm2022/ngwr-page-header.mjs +3 -3
- package/fesm2022/ngwr-pagination.mjs +6 -3
- package/fesm2022/ngwr-pagination.mjs.map +1 -1
- package/fesm2022/ngwr-pipes.mjs +31 -29
- package/fesm2022/ngwr-pipes.mjs.map +1 -1
- package/fesm2022/ngwr-platform.mjs +9 -9
- package/fesm2022/ngwr-popconfirm-testing.mjs +5 -2
- package/fesm2022/ngwr-popconfirm-testing.mjs.map +1 -1
- package/fesm2022/ngwr-popconfirm.mjs +44 -63
- package/fesm2022/ngwr-popconfirm.mjs.map +1 -1
- package/fesm2022/ngwr-popover-testing.mjs +7 -1
- package/fesm2022/ngwr-popover-testing.mjs.map +1 -1
- package/fesm2022/ngwr-popover.mjs +58 -156
- package/fesm2022/ngwr-popover.mjs.map +1 -1
- package/fesm2022/ngwr-progress.mjs +50 -9
- package/fesm2022/ngwr-progress.mjs.map +1 -1
- package/fesm2022/ngwr-pull-to-refresh-testing.mjs +57 -0
- package/fesm2022/ngwr-pull-to-refresh-testing.mjs.map +1 -0
- package/fesm2022/ngwr-pull-to-refresh.mjs +3 -3
- package/fesm2022/ngwr-qr.mjs +3 -3
- package/fesm2022/ngwr-radio.mjs +6 -6
- package/fesm2022/ngwr-rating.mjs +3 -3
- package/fesm2022/ngwr-resizable-testing.mjs +113 -0
- package/fesm2022/ngwr-resizable-testing.mjs.map +1 -0
- package/fesm2022/ngwr-resizable.mjs +3 -3
- package/fesm2022/ngwr-result.mjs +12 -12
- package/fesm2022/ngwr-schema-form-testing.mjs +336 -0
- package/fesm2022/ngwr-schema-form-testing.mjs.map +1 -0
- package/fesm2022/ngwr-schema-form.mjs +416 -19
- package/fesm2022/ngwr-schema-form.mjs.map +1 -1
- package/fesm2022/ngwr-scroll.mjs +3 -3
- package/fesm2022/ngwr-segmented.mjs +3 -3
- package/fesm2022/ngwr-select-testing.mjs +19 -0
- package/fesm2022/ngwr-select-testing.mjs.map +1 -1
- package/fesm2022/ngwr-select.mjs +361 -84
- package/fesm2022/ngwr-select.mjs.map +1 -1
- package/fesm2022/ngwr-sidebar-testing.mjs +176 -0
- package/fesm2022/ngwr-sidebar-testing.mjs.map +1 -0
- package/fesm2022/ngwr-sidebar.mjs +3 -3
- package/fesm2022/ngwr-skeleton.mjs +3 -3
- package/fesm2022/ngwr-slider-testing.mjs +6 -0
- package/fesm2022/ngwr-slider-testing.mjs.map +1 -1
- package/fesm2022/ngwr-slider.mjs +21 -3
- package/fesm2022/ngwr-slider.mjs.map +1 -1
- package/fesm2022/ngwr-sortable-list.mjs +29 -12
- package/fesm2022/ngwr-sortable-list.mjs.map +1 -1
- package/fesm2022/ngwr-speed-dial.mjs +3 -3
- package/fesm2022/ngwr-spinner.mjs +3 -3
- package/fesm2022/ngwr-splitter.mjs +3 -3
- package/fesm2022/ngwr-statistic.mjs +9 -9
- package/fesm2022/ngwr-stepper.mjs +42 -11
- package/fesm2022/ngwr-stepper.mjs.map +1 -1
- package/fesm2022/ngwr-storage.mjs +3 -3
- package/fesm2022/ngwr-switch.mjs +3 -3
- package/fesm2022/ngwr-table-testing.mjs +157 -3
- package/fesm2022/ngwr-table-testing.mjs.map +1 -1
- package/fesm2022/ngwr-table.mjs +1051 -74
- package/fesm2022/ngwr-table.mjs.map +1 -1
- package/fesm2022/ngwr-tabs-router.mjs +3 -3
- package/fesm2022/ngwr-tabs-testing.mjs +1 -1
- package/fesm2022/ngwr-tabs-testing.mjs.map +1 -1
- package/fesm2022/ngwr-tabs.mjs +15 -10
- package/fesm2022/ngwr-tabs.mjs.map +1 -1
- package/fesm2022/ngwr-textarea-testing.mjs +11 -0
- package/fesm2022/ngwr-textarea-testing.mjs.map +1 -1
- package/fesm2022/ngwr-textarea.mjs +128 -16
- package/fesm2022/ngwr-textarea.mjs.map +1 -1
- package/fesm2022/ngwr-theme.mjs +3 -3
- package/fesm2022/ngwr-timeline.mjs +6 -6
- package/fesm2022/ngwr-toast.mjs +40 -19
- package/fesm2022/ngwr-toast.mjs.map +1 -1
- package/fesm2022/ngwr-toolbar.mjs +3 -3
- package/fesm2022/ngwr-tour-testing.mjs +13 -1
- package/fesm2022/ngwr-tour-testing.mjs.map +1 -1
- package/fesm2022/ngwr-tour.mjs +19 -15
- package/fesm2022/ngwr-tour.mjs.map +1 -1
- package/fesm2022/ngwr-transfer-testing.mjs +6 -0
- package/fesm2022/ngwr-transfer-testing.mjs.map +1 -1
- package/fesm2022/ngwr-transfer.mjs +24 -5
- package/fesm2022/ngwr-transfer.mjs.map +1 -1
- package/fesm2022/ngwr-tree-testing.mjs +62 -2
- package/fesm2022/ngwr-tree-testing.mjs.map +1 -1
- package/fesm2022/ngwr-tree.mjs +978 -79
- package/fesm2022/ngwr-tree.mjs.map +1 -1
- package/fesm2022/ngwr-typography.mjs +3 -3
- package/fesm2022/ngwr-utils-router.mjs +3 -3
- package/fesm2022/ngwr-utils.mjs +97 -1
- package/fesm2022/ngwr-utils.mjs.map +1 -1
- package/fesm2022/ngwr-version.mjs +1 -1
- package/fesm2022/ngwr-version.mjs.map +1 -1
- package/fesm2022/ngwr-virtual-scroll.mjs +3 -3
- package/fesm2022/ngwr-window.mjs +33 -22
- package/fesm2022/ngwr-window.mjs.map +1 -1
- package/file-upload/styles/_index.scss +156 -0
- package/graph/styles/_index.scss +87 -0
- package/i18n/ar.json +29 -8
- package/i18n/cs.json +29 -8
- package/i18n/de.json +29 -8
- package/i18n/en.json +29 -8
- package/i18n/es.json +29 -8
- package/i18n/fr.json +29 -8
- package/i18n/he.json +29 -8
- package/i18n/hi.json +29 -8
- package/i18n/id.json +29 -8
- package/i18n/it.json +29 -8
- package/i18n/ja.json +29 -8
- package/i18n/ko.json +29 -8
- package/i18n/nl.json +29 -8
- package/i18n/pl.json +29 -8
- package/i18n/pt.json +29 -8
- package/i18n/ru.json +29 -8
- package/i18n/sv.json +29 -8
- package/i18n/tr.json +29 -8
- package/i18n/uk.json +29 -8
- package/i18n/vi.json +29 -8
- package/i18n/zh-TW.json +29 -8
- package/i18n/zh.json +29 -8
- package/input/styles/_index.scss +68 -1
- package/input-otp/styles/_index.scss +14 -0
- package/llms-full.txt +53 -21
- package/llms.txt +57 -24
- package/overlay/styles/_arrow.scss +4 -4
- package/package.json +33 -1
- package/popconfirm/styles/_index.scss +3 -11
- package/progress/styles/_index.scss +32 -0
- package/schema-form/styles/_index.scss +78 -0
- package/schematics/collection.json +5 -0
- package/schematics/eject/index.js +158 -0
- package/schematics/eject/schema.js +8 -0
- package/schematics/eject/schema.json +24 -0
- package/schematics/eject/source.js +295 -0
- package/schematics/use/rule.js +2 -0
- package/schematics/use/symbol-map.json +5 -0
- package/select/styles/_index.scss +127 -22
- package/skills/ngwr/SKILL.md +31 -4
- package/skills/ngwr/references/catalog.md +9 -1
- package/slider/styles/_index.scss +22 -0
- package/table/styles/_index.scss +191 -3
- package/textarea/styles/_index.scss +80 -0
- package/theme/styles/_focus.scss +16 -1
- package/theme/styles/_motion.scss +5 -0
- package/transfer/styles/_index.scss +84 -0
- package/tree/styles/_index.scss +138 -5
- package/types/ngwr-alert-testing.d.ts +88 -0
- package/types/ngwr-badge.d.ts +72 -2
- package/types/ngwr-breadcrumbs-testing.d.ts +92 -0
- package/types/ngwr-burger-testing.d.ts +51 -0
- package/types/ngwr-calendar-testing.d.ts +18 -6
- package/types/ngwr-calendar.d.ts +272 -22
- package/types/ngwr-carousel-testing.d.ts +27 -6
- package/types/ngwr-carousel.d.ts +42 -6
- package/types/ngwr-cascader.d.ts +13 -6
- package/types/ngwr-charts-chart-legend.d.ts +9 -4
- package/types/ngwr-charts-line-chart-testing.d.ts +4 -1
- package/types/ngwr-charts-line-chart.d.ts +7 -4
- package/types/ngwr-color-picker-testing.d.ts +15 -4
- package/types/ngwr-color-picker.d.ts +76 -6
- package/types/ngwr-compare-testing.d.ts +72 -0
- package/types/ngwr-context-menu.d.ts +2 -0
- package/types/ngwr-date-picker-testing.d.ts +23 -8
- package/types/ngwr-date-picker.d.ts +100 -9
- package/types/ngwr-date.d.ts +71 -1
- package/types/ngwr-drawer.d.ts +9 -0
- package/types/ngwr-dropdown-testing.d.ts +20 -0
- package/types/ngwr-dropdown.d.ts +26 -6
- package/types/ngwr-event-calendar.d.ts +66 -8
- package/types/ngwr-file-upload-testing.d.ts +31 -2
- package/types/ngwr-file-upload.d.ts +156 -3
- package/types/ngwr-form.d.ts +47 -3
- package/types/ngwr-graph-testing.d.ts +36 -3
- package/types/ngwr-graph.d.ts +309 -13
- package/types/ngwr-input-number-testing.d.ts +10 -0
- package/types/ngwr-input-number.d.ts +30 -1
- package/types/ngwr-input-otp.d.ts +10 -0
- package/types/ngwr-input-testing.d.ts +30 -0
- package/types/ngwr-input.d.ts +54 -3
- package/types/ngwr-overlay.d.ts +84 -5
- package/types/ngwr-pipes.d.ts +2 -1
- package/types/ngwr-popconfirm-testing.d.ts +12 -3
- package/types/ngwr-popconfirm.d.ts +28 -3
- package/types/ngwr-popover-testing.d.ts +19 -2
- package/types/ngwr-popover.d.ts +22 -2
- package/types/ngwr-progress.d.ts +29 -1
- package/types/ngwr-pull-to-refresh-testing.d.ts +83 -0
- package/types/ngwr-resizable-testing.d.ts +116 -0
- package/types/ngwr-schema-form-testing.d.ts +260 -0
- package/types/ngwr-schema-form.d.ts +76 -6
- package/types/ngwr-select-testing.d.ts +20 -0
- package/types/ngwr-select.d.ts +149 -11
- package/types/ngwr-sidebar-testing.d.ts +176 -0
- package/types/ngwr-slider-testing.d.ts +3 -1
- package/types/ngwr-slider.d.ts +21 -1
- package/types/ngwr-sortable-list.d.ts +6 -0
- package/types/ngwr-stepper.d.ts +20 -11
- package/types/ngwr-table-testing.d.ts +122 -7
- package/types/ngwr-table.d.ts +572 -50
- package/types/ngwr-tabs-testing.d.ts +14 -17
- package/types/ngwr-tabs.d.ts +6 -0
- package/types/ngwr-textarea-testing.d.ts +10 -0
- package/types/ngwr-textarea.d.ts +48 -2
- package/types/ngwr-toast.d.ts +8 -1
- package/types/ngwr-tour-testing.d.ts +10 -0
- package/types/ngwr-tour.d.ts +11 -2
- package/types/ngwr-transfer-testing.d.ts +3 -0
- package/types/ngwr-transfer.d.ts +24 -1
- package/types/ngwr-tree-testing.d.ts +65 -1
- package/types/ngwr-tree.d.ts +335 -12
- package/types/ngwr-utils.d.ts +107 -1
- package/types/ngwr-version.d.ts +1 -1
- package/types/ngwr-window.d.ts +7 -4
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngwr-utils.mjs","names":["MAX_LENGTH","DOCUMENT"],"sources":["../../../projects/lib/utils/guards/is-defined.ts","../../../projects/lib/utils/guards/is-non-empty-array.ts","../../../projects/lib/utils/guards/is-observable.ts","../../../projects/lib/utils/math/clamp.ts","../../../projects/lib/utils/math/decimal.ts","../../../projects/lib/utils/math/round.ts","../../../projects/lib/utils/coercion/num-attr.ts","../../../projects/lib/utils/css-class/to-class-list.ts","../../../projects/lib/utils/css-value/is-safe-css-value.ts","../../../projects/lib/utils/dom/check-styles.ts","../../../projects/lib/utils/dom/content-disposition-file-name.ts","../../../projects/lib/utils/dom/download-blob.ts","../../../projects/lib/utils/dom/get-root-font-size.ts","../../../projects/lib/utils/dom/focus.ts","../../../projects/lib/utils/dom/resolve-css-color.ts","../../../projects/lib/utils/dom/watch-color-scheme.ts","../../../projects/lib/utils/css-size/resolve-css-size.ts","../../../projects/lib/utils/id/random-id.ts","../../../projects/lib/utils/fn/noop.ts","../../../projects/lib/utils/fn/debounce.ts","../../../projects/lib/utils/fn/throttle.ts","../../../projects/lib/utils/keyboard/keys.ts","../../../projects/lib/utils/keyboard/predicates.ts","../../../projects/lib/utils/log/badge-style.ts","../../../projects/lib/utils/log/badge-error.ts","../../../projects/lib/utils/log/badge-log.ts","../../../projects/lib/utils/log/badge-warn.ts","../../../projects/lib/utils/text/initials.ts","../../../projects/lib/utils/locale/live-locale.ts","../../../projects/lib/utils/feature/wr-feature.ts","../../../projects/lib/utils/async/action.ts","../../../projects/lib/utils/async/resource-value.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 type { WrMaybe } from '../types';\n\n/**\n * Type guard that checks if a value is neither `null` nor `undefined`.\n *\n * @example\n * ```ts\n * const maybeValue: WrMaybe<number> = getValue();\n *\n * if (wrIsDefined(maybeValue)) {\n * // here maybeValue is number\n * console.log(maybeValue.toFixed(2));\n * }\n * ```\n *\n * @see {@link WrMaybe}\n */\nexport function wrIsDefined<T>(value: WrMaybe<T>): value is T {\n return value !== null && value !== undefined;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport type { WrMaybe } from '../types';\n\n/**\n * Type guard that checks if a value is an array with at least one element.\n *\n * @example\n * ```ts\n * const items: WrMaybe<string[]> = getItems();\n *\n * if (wrIsNonEmptyArray(items)) {\n * // items is string[]\n * console.log(items[0]);\n * }\n * ```\n */\nexport function wrIsNonEmptyArray<T>(value: WrMaybe<T[]>): value is [T, ...T[]] {\n return Array.isArray(value) && value.length > 0;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport type { Observable } from 'rxjs';\n\n/**\n * Type guard that checks whether a value looks like an RxJS `Observable`.\n *\n * Uses duck-typing: verifies that the object has a `subscribe` function.\n * Does not require an actual `Observable` instance.\n *\n * @example\n * ```ts\n * if (wrIsObservable(stream)) {\n * stream.subscribe(value => console.log(value));\n * }\n * ```\n */\nexport function wrIsObservable<T = unknown>(value: unknown): value is Observable<T> {\n return !!value && typeof (value as { subscribe?: unknown }).subscribe === 'function';\n}\n","/**\n * Clamps `value` into the inclusive `[min, max]` range.\n *\n * @example\n * ```ts\n * wrClamp(140, 0, 100); // 100\n * wrClamp(-3, 0, 100); // 0\n * wrClamp(42, 0, 100); // 42\n * ```\n */\nexport function wrClamp(value: number, min: number, max: number): number {\n return Math.min(max, Math.max(min, value));\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** Fixed-point value: `units / 10^scale`. */\ninterface Decimal {\n readonly units: bigint;\n readonly scale: number;\n}\n\nconst DECIMAL_RE = /^([+-])?(\\d*)(?:\\.(\\d*))?(?:[eE]([+-]?\\d+))?$/;\n\n/** Past this an exponent is not a number anyone meant; `10n ** 10n ** 9n` would hang the tab. */\nconst MAX_EXPONENT = 1000;\n\nfunction parse(value: unknown): Decimal | null {\n let text: string;\n if (typeof value === 'string') text = value.trim();\n else if (typeof value === 'number') {\n if (!Number.isFinite(value)) return null;\n text = String(value);\n } else if (typeof value === 'bigint') text = value.toString();\n else return null;\n\n const match = DECIMAL_RE.exec(text);\n if (!match) return null;\n const [, sign, int = '', frac = '', exp = '0'] = match;\n if (!int && !frac) return null;\n const exponent = Number(exp);\n if (Math.abs(exponent) > MAX_EXPONENT) return null;\n\n let units = BigInt(int + frac);\n let scale = frac.length - exponent;\n if (scale < 0) {\n units *= 10n ** BigInt(-scale);\n scale = 0;\n }\n return { units: sign === '-' ? -units : units, scale };\n}\n\nfunction print({ units, scale }: Decimal): string {\n const negative = units < 0n;\n const digits = (negative ? -units : units).toString().padStart(scale + 1, '0');\n const split = digits.length - scale;\n const text = scale ? `${digits.slice(0, split)}.${digits.slice(split)}` : digits;\n return negative ? `-${text}` : text;\n}\n\nfunction align(a: Decimal, b: Decimal): [bigint, bigint, number] {\n const scale = Math.max(a.scale, b.scale);\n return [a.units * 10n ** BigInt(scale - a.scale), b.units * 10n ** BigInt(scale - b.scale), scale];\n}\n\n/** Half away from zero, the schoolbook rule. */\nfunction roundedQuotient(num: bigint, den: bigint): bigint {\n let q = num / den;\n const r = num % den;\n const absR = r < 0n ? -r : r;\n const absDen = den < 0n ? -den : den;\n if (absR * 2n >= absDen) q += num < 0n !== den < 0n ? -1n : 1n;\n return q;\n}\n\nfunction rescale(d: Decimal, decimals: number): Decimal {\n if (decimals >= d.scale) return { units: d.units * 10n ** BigInt(decimals - d.scale), scale: decimals };\n return { units: roundedQuotient(d.units, 10n ** BigInt(d.scale - decimals)), scale: decimals };\n}\n\nfunction isScale(decimals: number): boolean {\n return Number.isInteger(decimals) && decimals >= 0;\n}\n\n/**\n * Reads a value as an exact decimal and returns it in canonical form, or\n * `null` when it is not a number.\n *\n * Canonical is `-?\\d+(\\.\\d+)?`: no sign on zero, no leading zeros, no bare\n * point, no exponent. Trailing fraction zeros are kept, since they are\n * precision the data carries: `'1.50'` stays `'1.50'`. A number is read from\n * its shortest round-trip form (`0.1` is `'0.1'`), so a value already in a\n * double stays what it printed as; a string is read digit for digit, so\n * `'9007199254740993.01'` survives untouched. Exponent notation is read\n * exactly: `'1e5'` is `'100000'`, `'1.5E-3'` is `'0.0015'`.\n *\n * Malformed is `''`, `'abc'`, `'1.2.3'`, `'1,5'`, `'Infinity'`, `NaN`, `null`,\n * `undefined`, anything that is not a string, number or bigint, and an\n * exponent beyond 1000. None of them throws, and none reads as zero.\n *\n * @example\n * ```ts\n * wrDecimal('00.10'); // '0.10'\n * wrDecimal(' -5. '); // '-5'\n * wrDecimal(1e21); // '1000000000000000000000'\n * wrDecimal('abc'); // null\n * ```\n */\nexport function wrDecimal(value: unknown): string | null {\n const d = parse(value);\n return d === null ? null : print(d);\n}\n\n/**\n * `a + b`, exactly. The result carries the wider scale of the two:\n * `'0.1' + '0.2'` is `'0.3'`, `'10.00' + '0.5'` is `'10.50'`. `null` when\n * either side is malformed (see {@link wrDecimal}).\n */\nexport function wrDecimalAdd(a: WrDecimalLike, b: WrDecimalLike): string | null {\n const x = parse(a);\n const y = parse(b);\n if (x === null || y === null) return null;\n const [ux, uy, scale] = align(x, y);\n return print({ units: ux + uy, scale });\n}\n\n/** `a - b`, exactly. The scale and the malformed rule are {@link wrDecimalAdd}'s. */\nexport function wrDecimalSubtract(a: WrDecimalLike, b: WrDecimalLike): string | null {\n const x = parse(a);\n const y = parse(b);\n if (x === null || y === null) return null;\n const [ux, uy, scale] = align(x, y);\n return print({ units: ux - uy, scale });\n}\n\n/**\n * `a * b`, exactly. The scales add: `'1.5' * '0.25'` is `'0.375'`,\n * `'19.99' * 3` is `'59.97'`. `null` when either side is malformed.\n */\nexport function wrDecimalMultiply(a: WrDecimalLike, b: WrDecimalLike): string | null {\n const x = parse(a);\n const y = parse(b);\n if (x === null || y === null) return null;\n return print({ units: x.units * y.units, scale: x.scale + y.scale });\n}\n\n/**\n * `a / b` at exactly `decimals` fraction digits, rounded half away from zero:\n * `wrDecimalDivide('10', 3, 2)` is `'3.33'`, `wrDecimalDivide('-2.5', 1, 0)`\n * is `'-3'`. `null` when a side is malformed, `b` is zero, or `decimals` is\n * not a whole number of places.\n */\nexport function wrDecimalDivide(a: WrDecimalLike, b: WrDecimalLike, decimals: number): string | null {\n const x = parse(a);\n const y = parse(b);\n if (x === null || y === null || y.units === 0n || !isScale(decimals)) return null;\n const num = x.units * 10n ** BigInt(y.scale + decimals);\n const den = y.units * 10n ** BigInt(x.scale);\n return print({ units: roundedQuotient(num, den), scale: decimals });\n}\n\n/**\n * Orders two decimals: `-1`, `0` or `1`, the shape `Array.prototype.sort`\n * takes. Scale does not count: `'1.50'` and `'1.5'` are `0`. `null` when\n * either side is malformed.\n */\nexport function wrDecimalCompare(a: WrDecimalLike, b: WrDecimalLike): -1 | 0 | 1 | null {\n const x = parse(a);\n const y = parse(b);\n if (x === null || y === null) return null;\n const [ux, uy] = align(x, y);\n return ux < uy ? -1 : ux > uy ? 1 : 0;\n}\n\n/**\n * Sets the scale to exactly `decimals` places: pads with zeros\n * (`wrDecimalRound('1.5', 2)` is `'1.50'`) or rounds half away from zero\n * (`wrDecimalRound('2.345', 2)` is `'2.35'`, `wrDecimalRound('-2.5', 0)` is\n * `'-3'`). Unlike `wrRound` from the same entry point there is no float on the\n * way, so `'1.005'` rounds to `'1.01'` because that is what the digits say.\n * `null` when the value is malformed or `decimals` is not a whole number of\n * places.\n */\nexport function wrDecimalRound(value: WrDecimalLike, decimals: number): string | null {\n const d = parse(value);\n if (d === null || !isScale(decimals)) return null;\n return print(rescale(d, decimals));\n}\n\n/**\n * What the decimal helpers read: a decimal string, a finite number or a\n * bigint. `null` and `undefined` are accepted so a value can be passed\n * straight from data; they read as malformed, like any other text that is not\n * a number.\n */\nexport type WrDecimalLike = string | number | bigint | null | undefined;\n","/**\n * Rounds `value` to `decimals` fraction digits, compensating the usual\n * floating point drift (`0.1 + 0.2` rounds to `0.3`, not `0.30000000000000004`).\n *\n * The `Number.EPSILON` nudge only bites while `|value| < 2`: it is an absolute\n * 2^-52, which is one ulp in `[1, 2)` and a fraction of one above it, so\n * `value + Number.EPSILON === value` for anything larger and the result is\n * plain `Math.round`. Correct for what this is used for — step maths and\n * fraction digits on human-sized numbers — and not a general fixed-point\n * rounder.\n *\n * @example\n * ```ts\n * wrRound(0.1 + 0.2, 2); // 0.3\n * wrRound(1.005, 2); // 1.01\n * wrRound(7.4); // 7\n * ```\n */\nexport function wrRound(value: number, decimals = 0): number {\n const factor = 10 ** decimals;\n return Math.round((value + Number.EPSILON) * factor) / factor;\n}\n","import { coerceNumberProperty } from '@angular/cdk/coercion';\n\n/**\n * Input-transform factory: coerces any bound value to a number, falling\n * back to `fallback` for `null` / `undefined` / unparsable input. The\n * standard transform for numeric `input()`s across ngwr.\n *\n * @example\n * ```ts\n * readonly speed = input(4, { transform: wrNumAttr(4) });\n * ```\n */\nexport const wrNumAttr =\n (fallback: number) =>\n (value: unknown): number =>\n coerceNumberProperty(value, fallback);\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 type { WrClassInput } from '../types';\n\n/**\n * Flattens class inputs into the de-duplicated token array `classList.add()`\n * and the CDK both require.\n *\n * **Splitting on whitespace is the point of this function, not a nicety.** The\n * CDK hands `panelClass` to `element.classList.add(...coerceArray(value))`, and\n * `coerceArray` wraps a string rather than splitting it — so one `'p-4 rounded'`\n * reaches `classList.add('p-4 rounded')`, which throws `InvalidCharacterError`\n * and takes the whole overlay down with it. Which is the first thing anyone\n * writes: a Tailwind user reaches for a space-separated string before an array.\n *\n * `false` is accepted so a call site can spell a conditional class inline\n * (`this.arrow() && 'wr-dropdown-overlay--arrow'`) instead of building an array\n * first.\n *\n * @example\n * ```ts\n * wrToClassList('wr-dropdown-overlay', this.arrow() && 'wr-dropdown-overlay--arrow', this.panelClass());\n * // ['wr-dropdown-overlay', 'wr-dropdown-overlay--arrow', 'p-4', 'rounded-xl']\n * ```\n */\nexport function wrToClassList(...values: readonly (WrClassInput | false)[]): string[] {\n const out: string[] = [];\n const seen = new Set<string>();\n\n for (const value of values) {\n if (!value) continue;\n // Entries of an ARRAY are split too, not only a bare string: nothing stops\n // `['btn', 'p-4 rounded']`, and the entry holding the space would throw in\n // exactly the same place a bare `'p-4 rounded'` does.\n for (const entry of typeof value === 'string' ? [value] : value) {\n if (!entry) continue;\n for (const part of entry.split(/\\s+/)) {\n // A token can still be empty here: `' a '.split(/\\s+/)` keeps the ends.\n if (!part || seen.has(part)) continue;\n seen.add(part);\n out.push(part);\n }\n }\n }\n\n return out;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** Longest value worth composing. A colour is never near this. */\nconst MAX_LENGTH = 256;\n\n/**\n * Characters that end a declaration, open a string, or start a comment — none\n * of which belong in a value the library is about to wrap its own syntax around.\n */\nconst FORBIDDEN = /[;{}\"'\\\\@<>!]|\\/\\*|\\*\\//;\n\n/** Function name immediately preceding an open paren. */\nconst FUNCTION_NAME = /([\\w-]*)\\($/;\n\n/**\n * Functions a composed value may call. Every image-producing function is absent\n * on purpose — `url()`, `image-set()`, `cross-fade()`, `element()`, `paint()` —\n * because fetching is the whole impact of this class.\n */\nconst ALLOWED_FUNCTIONS = new Set([\n 'rgb',\n 'rgba',\n 'hsl',\n 'hsla',\n 'hwb',\n 'lab',\n 'lch',\n 'oklab',\n 'oklch',\n 'color',\n 'color-mix',\n 'light-dark',\n 'var',\n 'calc',\n 'min',\n 'max',\n 'clamp',\n]);\n\n/**\n * Answers whether a value can be composed **into** a larger CSS expression\n * without escaping the slot it was given — a colour inside a `linear-gradient()`\n * the component builds, an entry the component joins into a custom property a\n * stylesheet then substitutes.\n *\n * It is a containment check, not a colour parser. It says the value cannot\n * terminate the construct the library wrapped around it; it says nothing about\n * whether the value is a colour a browser will accept, and a rejected value\n * should fall back to the component's own default rather than be repaired.\n *\n * **A value bound straight to `[style.background]` needs none of this.** There\n * is nothing to break out of there, and Angular applies style values through\n * CSSOM by design — validating those would amount to refusing style values in a\n * style binding.\n *\n * Rejected, and each one is a way out of the slot:\n *\n * - a `)` the value never opened — `red), url(…), linear-gradient(red` is the\n * shape that turns a colour into an extra background layer the browser fetches;\n * - a top-level `,` — a `<color>` is one value, so a comma at depth 0 means the\n * payload has reached the slot next to the one it was handed;\n * - `;` `{` `}` a quote, a backslash, `!`, or a CSS comment delimiter;\n * - any function outside {@link ALLOWED_FUNCTIONS} — `url()` above all.\n *\n * Top-level whitespace is allowed: `red 20%` is a legitimate gradient stop, and\n * without a comma or a bare `)` it cannot reach anything.\n *\n * @example\n * ```ts\n * wrIsSafeCssValue('var(--wr-color-primary)'); // true\n * wrIsSafeCssValue('color-mix(in srgb, red 50%, blue)'); // true\n * wrIsSafeCssValue('red), url(\"https://x.test/beacon\"), linear-gradient(red'); // false\n * ```\n *\n * @param value Raw value handed to the component.\n * @returns `true` when the value stays inside its slot.\n */\nexport function wrIsSafeCssValue(value: string): boolean {\n if (typeof value !== 'string') return false;\n\n const trimmed = value.trim();\n if (trimmed === '' || trimmed.length > MAX_LENGTH) return false;\n if (FORBIDDEN.test(trimmed)) return false;\n\n let depth = 0;\n for (let i = 0; i < trimmed.length; i++) {\n const char = trimmed[i];\n\n if (char === '(') {\n const name = FUNCTION_NAME.exec(trimmed.slice(0, i + 1));\n if (!name || !ALLOWED_FUNCTIONS.has(name[1].toLowerCase())) return false;\n depth++;\n } else if (char === ')') {\n depth--;\n if (depth < 0) return false;\n } else if (depth === 0 && char === ',') {\n return false;\n }\n }\n\n return depth === 0;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { DOCUMENT, isPlatformBrowser } from '@angular/common';\nimport { ElementRef, PLATFORM_ID, afterNextRender, inject } from '@angular/core';\n\n/** Entry points already checked, per document: a page of forty buttons warns once. */\nconst checked = new WeakMap<Document, Set<string>>();\n\n/**\n * The property `theme/styles/_loaded.scss` declares for an entry:\n * `charts/bar-chart` reads `--wr-loaded-charts-bar-chart`.\n */\nfunction marker(entry: string): string {\n return `--wr-loaded-${entry.replace(/\\//g, '-')}`;\n}\n\n/**\n * Whether a stylesheet can reach this document at all.\n *\n * jsdom and happy-dom load no `<link>` and a unit test wires no global Sass,\n * so under either every component would warn once per entry point, in the\n * library's own specs and in a consumer's alike. There is nothing to add there.\n */\nfunction appliesStylesheets(doc: Document): boolean {\n const ua = doc.defaultView?.navigator.userAgent ?? '';\n return !/jsdom|happydom/i.test(ua);\n}\n\n/**\n * Warns, once per entry point and document, when a component renders without\n * its stylesheet.\n *\n * Every public entry sheet declares `--wr-loaded-<entry>` on `:root` (the\n * `loaded()` mixin in the theme layer), so a component can tell after its first\n * render whether `@use 'ngwr/<entry>'` ever ran. Without it a component renders\n * unstyled and nothing else says why.\n *\n * A component calls it from its constructor, behind the same guard Angular\n * puts on its own dev checks, so a production build drops the call and the\n * text with it:\n *\n * ```ts\n * constructor() {\n * if (typeof ngDevMode === 'undefined' || ngDevMode) wrCheckStyles('select');\n * }\n * ```\n *\n * The read happens in `afterNextRender`, never at construction, and in the\n * browser only: the server has no stylesheet to apply. A nested component stays\n * silent when its parent's sheet was added, because a parent sheet loads the\n * sheets of what it renders, markers included.\n *\n * @internal Shared by the entry points; not a consumer API.\n * @param entry The `exports` key under `ngwr/`, nested ones included: `select`, `charts/bar-chart`.\n */\nexport function wrCheckStyles(entry: string): void {\n // Guarded here as well as at the call site: the call site is what lets a\n // bundler drop the import, this is what keeps a direct call silent in\n // production and lets a spec observe it.\n if (!(typeof ngDevMode === 'undefined' || ngDevMode)) return;\n // `afterNextRender` is a no-op under `ngServerMode` already; the platform id\n // says the same thing where a spec can set it.\n if (!isPlatformBrowser(inject(PLATFORM_ID))) return;\n\n const doc = inject(DOCUMENT);\n const done = checked.get(doc) ?? new Set<string>();\n checked.set(doc, done);\n if (done.has(entry)) return;\n\n const host = inject<ElementRef<Element>>(ElementRef).nativeElement;\n\n afterNextRender(() => {\n // Every instance of the first render registers a hook; the first to run\n // answers for all of them.\n if (!appliesStylesheets(doc) || done.has(entry)) return;\n done.add(entry);\n\n const style = doc.defaultView!.getComputedStyle(doc.documentElement);\n const loaded = (name: string): boolean => style.getPropertyValue(marker(name)).trim() !== '';\n const tag = `<${host.localName}>`;\n\n if (!done.has('theme')) {\n done.add('theme');\n if (!loaded('theme')) {\n // eslint-disable-next-line no-console -- a dev-mode diagnostic, reported and never thrown\n console.warn(\n `[NGWR] ${tag} renders without the theme tokens. Add @use 'ngwr/theme'; first in your global stylesheet, ` +\n 'or run ng g ngwr:component-style theme.'\n );\n }\n }\n\n if (!loaded(entry)) {\n // eslint-disable-next-line no-console -- a dev-mode diagnostic, reported and never thrown\n console.warn(\n `[NGWR] ${tag} renders without its styles. Add @use 'ngwr/${entry}'; to your global stylesheet, ` +\n `or run ng g ngwr:component-style ${entry}.`\n );\n }\n });\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** `filename*=charset'language'percent-encoded`, the RFC 8187 form. */\nconst EXTENDED = /(?:^|;)\\s*filename\\*\\s*=\\s*([^;]+)/i;\n\n/** `filename=\"quoted\"` or `filename=token`. `filename*` does not match: the star is not whitespace. */\nconst PLAIN = /(?:^|;)\\s*filename\\s*=\\s*(?:\"((?:[^\"\\\\]|\\\\.)*)\"|([^;]*))/i;\n\nfunction decodeExtended(raw: string): string | null {\n const value = raw.trim().replace(/^\"(.*)\"$/, '$1');\n const match = /^([^']*)'[^']*'(.*)$/.exec(value);\n if (!match) return null;\n const charset = match[1].toLowerCase();\n const encoded = match[2];\n try {\n if (charset === 'utf-8' || charset === '') return decodeURIComponent(encoded);\n if (charset === 'iso-8859-1' || charset === 'latin1') {\n return encoded.replace(/%([0-9a-f]{2})/gi, (_, hex: string) => String.fromCharCode(Number.parseInt(hex, 16)));\n }\n } catch {\n // A malformed percent sequence: fall through to the plain parameter.\n }\n return null;\n}\n\n/**\n * Reads the file name a `Content-Disposition` header carries, or `null` when\n * it carries none.\n *\n * `filename*` wins over `filename` when both are present, as RFC 6266 asks;\n * its value is percent-decoded. A `filename*` that cannot be decoded falls back\n * to the plain `filename`. Parameter names are case-insensitive; a quoted\n * `filename` has its backslash escapes removed.\n *\n * @example\n * ```ts\n * wrContentDispositionFileName(response.headers.get('Content-Disposition'));\n *\n * wrContentDispositionFileName('attachment; filename=\"report.csv\"');\n * // 'report.csv'\n * wrContentDispositionFileName(\"attachment; filename*=UTF-8''%E2%82%AC.csv\");\n * // '€.csv'\n * wrContentDispositionFileName('inline');\n * // null\n * ```\n *\n * @param header - The header value, or what `Headers.get()` returned.\n * @returns The file name, or `null`.\n */\nexport function wrContentDispositionFileName(header: string | null | undefined): string | null {\n if (!header) return null;\n\n const extended = EXTENDED.exec(header);\n if (extended) {\n const decoded = decodeExtended(extended[1]);\n if (decoded) return decoded;\n }\n\n const plain = PLAIN.exec(header);\n if (!plain) return null;\n const name = plain[1] !== undefined ? plain[1].replace(/\\\\(.)/g, '$1') : plain[2].trim();\n return name || null;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/**\n * Safari starts the download after `click()` returns, so a revoke in the same\n * tick hands it a dead URL. One second covers the gap with room to spare.\n */\nconst REVOKE_DELAY_MS = 1000;\n\n/**\n * Saves `blob` as a file named `fileName`, through a temporary anchor and an\n * object URL.\n *\n * SSR-safe: a no-op without a `document`. The anchor is appended for the\n * click, which Firefox needs, and removed right after. The object URL is\n * revoked on a timer rather than synchronously, which Safari needs.\n *\n * @example\n * ```ts\n * const csv = new Blob([text], { type: 'text/csv;charset=utf-8;' });\n * wrDownloadBlob(csv, 'report.csv');\n * ```\n *\n * @param blob - The data to save.\n * @param fileName - The name the browser offers in its save dialog.\n */\nexport function wrDownloadBlob(blob: Blob, fileName: string): void {\n if (typeof document === 'undefined' || typeof URL.createObjectURL !== 'function') return;\n\n const url = URL.createObjectURL(blob);\n const link = document.createElement('a');\n link.href = url;\n link.download = fileName;\n document.body.appendChild(link);\n link.click();\n link.remove();\n setTimeout(() => URL.revokeObjectURL(url), REVOKE_DELAY_MS);\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/**\n * Reads the root font size (in pixels) from\n * `getComputedStyle(document.documentElement).fontSize`.\n *\n * Typical use case: converting `rem` values to pixels for layout calculations.\n *\n * Falls back to the provided value when:\n * - DOM is not available (SSR);\n * - `getComputedStyle` fails or returns an unparseable value.\n *\n * @example\n * ```ts\n * const rootFontSize = wrGetRootFontSize(); // e.g. 16\n * const customFallback = wrGetRootFontSize(14); // uses 14 if DOM is unavailable\n * ```\n *\n * @param fallback - Value in pixels when DOM is unavailable. Defaults to `16`.\n * @returns Root font size in pixels.\n */\nexport function wrGetRootFontSize(fallback = 16): number {\n try {\n if (typeof window === 'undefined' || typeof document === 'undefined') {\n return fallback;\n }\n\n const raw = window.getComputedStyle(document.documentElement).fontSize;\n const parsed = Number.parseFloat(raw);\n\n return Number.isFinite(parsed) ? parsed : fallback;\n } catch {\n return fallback;\n }\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport type { FocusMonitor } from '@angular/cdk/a11y';\n\nconst FOCUSABLE_SELECTOR = [\n 'a[href]',\n 'area[href]',\n 'button:not([disabled])',\n 'input:not([disabled]):not([type=\"hidden\"])',\n 'select:not([disabled])',\n 'textarea:not([disabled])',\n 'iframe',\n 'object',\n 'embed',\n 'audio[controls]',\n 'video[controls]',\n '[contenteditable]:not([contenteditable=\"false\"])',\n '[tabindex]:not([tabindex=\"-1\"])',\n].join(',');\n\n/**\n * Is `el` rendered? A layout test, not a style one: `getClientRects()` is empty\n * for `display: none` on the element OR on any ancestor, and non-empty for\n * everything that has a box — `position: fixed` included.\n *\n * It used to be `offsetParent !== null`, which is almost the same test and\n * wrong in one direction that matters here: a `position: fixed` element has no\n * offset parent at all, so every control inside a fixed panel — the one shape a\n * focus trap is most often wrapped around — was dropped as if it were hidden.\n *\n * `visibility: hidden` keeps its box, so it needs its own read. It is checked\n * second because it is the expensive one, and `getClientRects()` already\n * rejects the common case.\n */\nfunction isRendered(el: HTMLElement): boolean {\n if (el.getClientRects().length === 0) return false;\n return el.ownerDocument.defaultView?.getComputedStyle(el).visibility !== 'hidden';\n}\n\n/**\n * Return every focusable descendant of `root`, in DOM ORDER — not in tab order.\n * A positive `tabindex` is not reordered, because a trap that honoured it would\n * disagree with the browser about what Tab does for everything outside the trap;\n * APG says not to use positive values at all.\n *\n * Elements with no box are dropped (see `isRendered`), except the one that\n * currently has focus: a trap must still be able to find where it is standing,\n * and an element can be focused and then hidden by the same interaction.\n */\nexport function wrGetFocusableElements(root: HTMLElement): readonly HTMLElement[] {\n return Array.from(root.querySelectorAll<HTMLElement>(FOCUSABLE_SELECTOR)).filter(\n el => isRendered(el) || el === document.activeElement\n );\n}\n\n/**\n * Trap Tab navigation inside `root` for a keyboard event — call from a\n * `keydown` handler. Cycles focus from first ↔ last focusable element.\n * Returns `true` when focus was redirected (event was handled).\n */\nexport function wrTrapFocus(root: HTMLElement, event: KeyboardEvent): boolean {\n if (event.key !== 'Tab') return false;\n const focusable = wrGetFocusableElements(root);\n if (focusable.length === 0) return false;\n\n const first = focusable[0];\n const last = focusable[focusable.length - 1];\n const active = document.activeElement as HTMLElement | null;\n\n if (event.shiftKey && active === first) {\n event.preventDefault();\n last.focus();\n return true;\n }\n if (!event.shiftKey && active === last) {\n event.preventDefault();\n first.focus();\n return true;\n }\n return false;\n}\n\n/**\n * Hand focus back to `el` after something closed, as a PROGRAMMATIC focus.\n *\n * A plain `el.focus()` after Escape reads to the CDK `FocusMonitor` as keyboard\n * focus, because the last input was a key, and anything that reacts to keyboard\n * origin (a tooltip on the trigger) then treats the restore as the user tabbing\n * there. `focusVia(el, 'program')` reports the truth. Without a monitor it is a\n * plain `focus()`.\n */\nexport function wrRestoreFocus(el: HTMLElement, monitor?: FocusMonitor | null): void {\n if (monitor) monitor.focusVia(el, 'program');\n else el.focus();\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/**\n * Probes one element keeps alive at a time, one per expression. Generous for\n * what a component draws with — aurora resolves three stops, waves and\n * click-spark one colour each — and a bound on a caller that resolves a fresh\n * string every frame, where the oldest probe is retired instead of piling up.\n */\nconst MAX_PROBES = 8;\n\n/** `var()` hops the fallback chain follows before it gives up on a reference cycle. */\nconst MAX_HOPS = 8;\n\n/** A whole expression that is one `var(--name)` or `var(--name, fallback)`. */\nconst LONE_VAR = /^var\\(\\s*(--[\\w-]+)\\s*(?:,\\s*([\\s\\S]*?))?\\s*\\)$/;\n\nconst probes = new WeakMap<Element, Map<string, HTMLElement>>();\n\n/**\n * The probe holding `expression` inside `context`, appended on first use.\n *\n * The colour is written ONCE, when the probe is made, so a caller that resolves\n * every frame only ever reads: an inline-style write invalidates style, and\n * doing it per frame would recalculate the probe on every one of them.\n */\nfunction probeFor(context: Element, expression: string): HTMLElement {\n let byExpression = probes.get(context);\n if (!byExpression) {\n byExpression = new Map();\n probes.set(context, byExpression);\n }\n\n const kept = byExpression.get(expression);\n // A template that re-rendered the context's children takes the probe with\n // it, and a detached element computes nothing.\n if (kept?.parentNode === context) return kept;\n\n const probe = context.ownerDocument.createElement('span');\n probe.style.display = 'none';\n probe.style.color = expression;\n context.appendChild(probe);\n byExpression.set(expression, probe);\n\n if (byExpression.size > MAX_PROBES) {\n const [oldest, element] = byExpression.entries().next().value!;\n element.remove();\n byExpression.delete(oldest);\n }\n return probe;\n}\n\n/** The probe's computed colour, or `null` when the engine refused or did not resolve it. */\nfunction computedColor(view: Window, probe: HTMLElement): string | null {\n // An expression the parser refused never reaches the inline style at all, and\n // the probe would quietly report the colour it inherits instead.\n if (probe.style.color === '') return null;\n const color = view.getComputedStyle(probe).color;\n // A browser always substitutes; jsdom hands a `var()` back verbatim.\n return color !== '' && !color.includes('var(') ? color : null;\n}\n\n/**\n * A colour string as 0–1 sRGB channels with its alpha dropped, or `null` for a\n * form this does not read.\n *\n * A computed colour comes back in one of two shapes — `rgb()` / `rgba()` with\n * 0–255 channels for a legacy colour, `color(srgb r g b / a)` with 0–1 channels\n * for a `color-mix()` — and neither is hex, the one form the first WebGL caller\n * parsed, which turned a `light-dark()` hook into `NaN` uniforms. Hex and\n * percentages stay for the literal fallback a caller names: no computed value\n * carries either, and a fallback reaches this unresolved.\n */\nfunction parseChannels(color: string): [number, number, number] | null {\n const value = color.trim().toLowerCase();\n const fn = /^(rgba?|color)\\(\\s*(srgb\\s+)?([^)]*)\\)$/.exec(value);\n if (fn && (fn[1] !== 'color' || fn[2] !== undefined)) {\n const scale = fn[1] === 'color' ? 1 : 255;\n const channels = fn[3]\n .split(/[\\s,/]+/)\n .slice(0, 3)\n .map(part => {\n if (part === 'none') return 0;\n return Number.parseFloat(part) / (part.endsWith('%') ? 100 : scale);\n });\n if (channels.length !== 3 || !channels.every(Number.isFinite)) return null;\n return channels.map(channel => Math.min(1, Math.max(0, channel))) as [number, number, number];\n }\n const hex = /^#([\\da-f]{3,4}|[\\da-f]{6}|[\\da-f]{8})$/.exec(value)?.[1];\n if (hex === undefined) return null;\n const full = hex.length <= 4 ? [...hex].map(digit => digit + digit).join('') : hex;\n return [0, 2, 4].map(at => Number.parseInt(full.slice(at, at + 2), 16) / 255) as [number, number, number];\n}\n\n/**\n * Resolves a CSS colour expression against an element to the colour the cascade\n * computes for it, which a canvas can paint with: `rgb(…)` / `rgba(…)` for a\n * legacy colour, `color(srgb r g b / a)` (channels 0–1) for a `color-mix()`\n * result. A colour authored in another space — `oklch()`, `lab()` — computes\n * to itself; a caller that needs numbers wants {@link wrResolveCssColorChannels},\n * which reads all of these.\n *\n * A 2D context and a WebGL uniform cannot read CSS: a `var()` is refused\n * outright, and so is `light-dark()` — except in Firefox, which accepts it and\n * always paints the LIGHT colour, whatever scheme the page is in. Reading the\n * custom property does not help either, because `getPropertyValue()` returns\n * the declared text, `light-dark(…)` and all, never a resolved colour. What\n * does resolve it is the cascade itself, so this sets the expression as the\n * `color` of a hidden probe inside `context` and reads the probe's computed\n * value back. The probe inherits from `context`, so custom properties and the\n * colour scheme resolve exactly as they would for the element itself —\n * including a subtree that sets its own `color-scheme`.\n *\n * Pass the element whose children are never painted when there is one — a\n * `<canvas>` is ideal, and its fallback content is where the probe goes. One\n * `display: none` span is appended per expression and kept for the next call,\n * so resolving the same expression every frame costs a style read, not a DOM\n * write.\n *\n * Returns `fallback` when nothing can be resolved: the expression does not\n * parse as a colour, it is a lone `var()` holding something that is not a colour or\n * naming a property set nowhere with no fallback of its own (CSS itself would hand\n * the probe its inherited colour, which reads as a choice the author never made), or\n * the element has no style engine behind it. A `var()` inside another function —\n * `light-dark()`, `color-mix()`, the fallback of another `var()` — is CSS's to\n * substitute, and with its name unset or holding no colour still reads the inherited\n * colour; so does `var(--x, 12px)`, whose own fallback is no colour. Where the\n * computed read hands a `var()` back unresolved — jsdom does, a browser never does —\n * a lone `var()` is looked up with `getPropertyValue()` and the result resolved in\n * its turn, so a unit test still sees the colour a token holds.\n *\n * Browser only: call it from `afterNextRender` or a frame callback, never\n * during a server render.\n *\n * @example\n * ```ts\n * const canvas = this.canvasRef().nativeElement;\n * ctx.strokeStyle = wrResolveCssColor(canvas, 'var(--wr-color-on-surface)', '#0f172a');\n * ```\n *\n * @param context - Element to resolve against; the probe is appended inside it.\n * @param expression - Any CSS colour: a literal, `var()`, `light-dark()`, `color-mix()`.\n * @param fallback - Returned as-is when the expression cannot be resolved.\n * @returns The computed colour, or `fallback`.\n */\nexport function wrResolveCssColor(context: Element, expression: string, fallback: string): string {\n const view = context.ownerDocument.defaultView;\n if (!view) return fallback;\n\n try {\n let value = expression.trim();\n for (let hop = 0; hop < MAX_HOPS && value !== ''; hop++) {\n const ref = LONE_VAR.exec(value);\n const declared = ref ? view.getComputedStyle(context).getPropertyValue(ref[1]).trim() : '';\n if (ref && declared === '' && ref[2] === undefined) return fallback;\n // A browser's computed custom property has its own `var()` substituted already,\n // so this is the text the probe would be handed. Its own parser rather than\n // `CSS.supports`, which no jsdom before 30 has and no quirks document agrees with.\n if (ref && declared !== '' && probeFor(context, declared).style.color === '') return fallback;\n\n const color = computedColor(view, probeFor(context, value));\n if (color !== null) return color;\n if (!ref) break;\n value = declared || (ref[2] ?? '').trim();\n }\n } catch {\n // A detached view or a DOM with no style engine behind it.\n }\n return fallback;\n}\n\n/**\n * Resolves a CSS colour expression against an element to 0–1 sRGB channels, with\n * the alpha dropped, for what takes numbers rather than a string: a WebGL `vec3`\n * uniform, above all.\n *\n * {@link wrResolveCssColor} does the cascade, so a `var()`, a `light-dark()` and a\n * `color-mix()` all resolve as they would for the element itself, and this reads\n * the result: `rgb()`, `rgba()` and `color(srgb …)`, with `none` as 0 and every\n * channel clamped to 0–1, so a `color-mix()` from a wider gamut stays in range. A\n * colour authored in another space — `oklch()`, `lab()`, `display-p3` — computes\n * to itself, and mixing it into sRGB is what brings it to a form this reads.\n *\n * Total: it always returns three finite channels. When {@link wrResolveCssColor}\n * cannot resolve the expression it reads `fallback`, a literal colour in any form\n * CSS parses, hex included; when that cannot be read either, it returns\n * `[0, 0, 0]`, so a uniform never receives a `NaN`.\n *\n * It costs what {@link wrResolveCssColor} costs plus a parse, so a caller drawing\n * every frame can hold on to the string that function returns and call this only\n * when it changes.\n *\n * Browser only: call it from `afterNextRender` or a frame callback, never during\n * a server render.\n *\n * @example\n * ```ts\n * const canvas = this.canvasRef().nativeElement;\n * const [r, g, b] = wrResolveCssColorChannels(canvas, 'var(--wr-color-primary)', '#3969e2');\n * gl.uniform3f(this.tint, r, g, b);\n * ```\n *\n * @param context - Element to resolve against; a hidden probe is appended inside it.\n * @param expression - Any CSS colour: a literal, `var()`, `light-dark()`, `color-mix()`.\n * @param fallback - The literal colour to read when the expression cannot be resolved.\n * @returns The red, green and blue channels, each 0–1.\n */\nexport function wrResolveCssColorChannels(\n context: Element,\n expression: string,\n fallback: string\n): [number, number, number] {\n const read = (color: string): [number, number, number] | null =>\n parseChannels(color) ??\n parseChannels(wrResolveCssColor(context, `color-mix(in srgb, ${color} 100%, transparent)`, ''));\n\n return read(wrResolveCssColor(context, expression, fallback)) ?? read(fallback) ?? [0, 0, 0];\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport {\n DOCUMENT,\n DestroyRef,\n type Injector,\n PLATFORM_ID,\n type ProviderToken,\n assertInInjectionContext,\n inject,\n} from '@angular/core';\n\n/** The query `light dark` resolves through when the page leaves the choice to the OS. */\nconst DARK_QUERY = '(prefers-color-scheme: dark)';\n\n/**\n * What one `color-scheme` value resolves to, or `null` when it does not decide:\n * `normal`, empty, or nothing this reads. `light dark` (either order, `only`\n * included) is the OS's call.\n */\nfunction pick(value: string, osDark: boolean): WrColorScheme | null {\n const tokens = value.trim().toLowerCase().split(/\\s+/);\n const light = tokens.includes('light');\n const dark = tokens.includes('dark');\n if (light && dark) return osDark ? 'dark' : 'light';\n if (dark) return 'dark';\n if (light) return 'light';\n return null;\n}\n\n/**\n * The scheme `<html>` resolves to: its computed `color-scheme` first, which is\n * what an inline write, a class, an attribute selector and the theme's own\n * `light dark` all land on; then `<meta name=\"color-scheme\">`, which is what a\n * computed `normal` defers to; then light, the browser's default.\n */\nfunction resolveScheme(doc: Document, query: MediaQueryList | null): WrColorScheme {\n const osDark = query?.matches ?? false;\n const view = doc.defaultView;\n const declared = view ? view.getComputedStyle(doc.documentElement).getPropertyValue('color-scheme') : '';\n const meta = doc.querySelector<HTMLMetaElement>('meta[name=\"color-scheme\"]')?.content ?? '';\n return pick(declared, osDark) ?? pick(meta, osDark) ?? 'light';\n}\n\n/** The colour scheme a page resolves to: what `light-dark()` picks on its root. */\nexport type WrColorScheme = 'light' | 'dark';\n\n/** Options for {@link wrWatchColorScheme}. */\nexport interface WrWatchColorSchemeOptions {\n /**\n * The injector to take `DestroyRef`, `DOCUMENT` and `PLATFORM_ID` from, for\n * a call made outside an injection context — from `afterNextRender`, say.\n * The watch then ends when that injector is destroyed.\n */\n readonly injector?: Injector;\n}\n\n/**\n * Calls `callback` with the new scheme whenever the colour scheme the page\n * resolves to changes, and never for a change that leaves it where it was.\n *\n * A canvas or a WebGL uniform cannot take `light-dark()` or a `var()`, so a\n * drawing resolves its colours once, through {@link wrResolveCssColor}, and holds\n * pixels from then on. A frame loop repaints anyway; a still frame — the one a\n * reduced-motion visitor gets — keeps the old scheme's colours until something\n * asks it to redraw. This is that something.\n *\n * Two sources move the root scheme, and it listens to both: an attribute change\n * on `<html>`, which is where `WrTheme` writes its inline `color-scheme` (and\n * where a class or a `data-` attribute an app themes on lives), and\n * `prefers-color-scheme`, which decides it while the page says `light dark`.\n * Each is read back through the computed `color-scheme`, so a write that does\n * not change the outcome — CDK's scroll blocking styles `<html>` too — calls\n * nothing.\n *\n * It watches the ROOT. A subtree with a `color-scheme` of its own resolves on\n * its own terms, and a stylesheet that arrives later and re-declares the root's\n * scheme is not an attribute change; neither is seen.\n *\n * SSR-safe: on the server it does nothing and returns a no-op. Stops when the\n * injection context it was called in is destroyed, or when the returned\n * function is called.\n *\n * @example\n * ```ts\n * constructor() {\n * afterNextRender(() => this.draw());\n * wrWatchColorScheme(() => this.draw());\n * }\n *\n * private draw(): void {\n * const canvas = this.canvas().nativeElement;\n * const ctx = canvas.getContext('2d');\n * if (!ctx) return;\n * ctx.fillStyle = wrResolveCssColor(canvas, 'var(--wr-color-primary)', '#3969e2');\n * ctx.fillRect(0, 0, canvas.width, canvas.height);\n * }\n * ```\n *\n * @param callback - Receives the scheme now in effect on `<html>`.\n * @param options - An injector, for a call outside an injection context.\n * @returns A function that stops watching early.\n */\nexport function wrWatchColorScheme(\n callback: (scheme: WrColorScheme) => void,\n options: WrWatchColorSchemeOptions = {}\n): () => void {\n if (!options.injector) assertInInjectionContext(wrWatchColorScheme);\n const injector = options.injector;\n const get = <T>(token: ProviderToken<T>): T => (injector ? injector.get(token) : inject(token));\n\n if (get(PLATFORM_ID) !== 'browser') return () => undefined;\n const doc = get(DOCUMENT);\n const view = doc.defaultView;\n if (!view) return () => undefined;\n\n const query = typeof view.matchMedia === 'function' ? view.matchMedia(DARK_QUERY) : null;\n let current = resolveScheme(doc, query);\n const check = (): void => {\n const next = resolveScheme(doc, query);\n if (next === current) return;\n current = next;\n callback(next);\n };\n\n const observer = typeof MutationObserver === 'undefined' ? null : new MutationObserver(check);\n observer?.observe(doc.documentElement, { attributes: true });\n query?.addEventListener('change', check);\n\n let stopped = false;\n const stop = (): void => {\n if (stopped) return;\n stopped = true;\n observer?.disconnect();\n query?.removeEventListener('change', check);\n };\n get(DestroyRef).onDestroy(stop);\n return stop;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { wrGetRootFontSize } from '../dom';\n\nimport type { WrResolveCssSizeOptions } from './resolve-css-size-options';\nimport type { WrResolvedCssSize } from './resolved-css-size';\n\n/**\n * Resolves a raw size value into a CSS string and an optional pixel equivalent.\n *\n * Supported formats:\n * - `number` → pixels (`48` → `\"48px\"`)\n * - `\"12px\"` → pixels (`\"12px\"` → `\"12px\"`)\n * - `\"3rem\"` → rems via root (`\"3rem\"` → `\"3rem\"`, pxValue = 3 × root font size)\n * - `\"80%\"` → percentage (`\"80%\"` → `\"80%\"`, pxValue = null)\n * - `\"15\"` → pixels (`\"15\"` → `\"15px\"`)\n * - anything else → passed through as-is, pxValue = null\n *\n * @example\n * ```ts\n * const size = wrResolveCssSize('3rem', { defaultValue: '6rem' });\n * // size.cssValue === '3rem'\n * // size.pxValue === 3 * wrGetRootFontSize()\n * ```\n *\n * @param raw - Value to resolve. Accepts numbers, pixel/rem/percent strings, or `null`/`undefined`.\n * @param options - Optional configuration.\n * @returns Resolved CSS value and its pixel equivalent when computable.\n *\n * @see {@link WrResolvedCssSize}\n * @see {@link WrResolveCssSizeOptions}\n */\nexport function wrResolveCssSize(raw: unknown, options: WrResolveCssSizeOptions = {}): WrResolvedCssSize {\n const rootFontSize = wrGetRootFontSize();\n const value: unknown = raw ?? options.defaultValue;\n\n if (value == null) {\n return { cssValue: '0px', pxValue: 0 };\n }\n\n if (typeof value === 'number' && Number.isFinite(value)) {\n return { cssValue: `${value}px`, pxValue: value };\n }\n\n if (typeof value !== 'string') {\n return { cssValue: '0px', pxValue: 0 };\n }\n\n const trimmed = value.trim();\n\n const remMatch = /^([\\d.]+)\\s*rem$/i.exec(trimmed);\n if (remMatch) {\n const rem = Number.parseFloat(remMatch[1]);\n const px = rem * rootFontSize;\n return { cssValue: `${rem}rem`, pxValue: Number.isFinite(px) ? px : null };\n }\n\n const pxMatch = /^([\\d.]+)\\s*px$/i.exec(trimmed);\n if (pxMatch) {\n const px = Number.parseFloat(pxMatch[1]);\n return { cssValue: `${px}px`, pxValue: Number.isFinite(px) ? px : null };\n }\n\n const percentMatch = /^([\\d.]+)\\s*%$/.exec(trimmed);\n if (percentMatch) {\n return { cssValue: `${percentMatch[1]}%`, pxValue: null };\n }\n\n const numberMatch = /^([\\d.]+)$/.exec(trimmed);\n if (numberMatch) {\n const px = Number.parseFloat(numberMatch[1]);\n return { cssValue: `${px}px`, pxValue: Number.isFinite(px) ? px : null };\n }\n\n return { cssValue: trimmed, pxValue: null };\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nconst ALPHABET = 'abcdefghijklmnopqrstuvwxyz0123456789';\nconst MIN_LENGTH = 4;\nconst MAX_LENGTH = 64;\nconst DEFAULT_LENGTH = 12;\n\n/**\n * Returns random bytes using the best available source.\n *\n * @internal\n */\nfunction defaultRandomBytes(count: number): Uint8Array {\n // Covers: all browsers, Node ≥ 18, Deno, Bun, Cloudflare Workers\n if (typeof crypto !== 'undefined' && typeof crypto.getRandomValues === 'function') {\n return crypto.getRandomValues(new Uint8Array(count));\n }\n\n // Fallback: Node < 18 or exotic runtimes\n const buf = new Uint8Array(count);\n for (let i = 0; i < count; i++) {\n buf[i] = Math.floor(Math.random() * 256);\n }\n return buf;\n}\n\n/**\n * Generates a pseudo-random, DOM-safe identifier.\n *\n * Produced ids:\n * - are prefixed to avoid collisions with host-application ids;\n * - contain only `[a-z0-9-]` characters;\n * - use `crypto.getRandomValues` when available, falling back to `Math.random`.\n *\n * **Not suitable for cryptographic or security-sensitive purposes** —\n * intended only for UI element identifiers (`id`, `for`, `aria-*`, etc.).\n *\n * @example\n * ```ts\n * wrRandomId();\n * // → \"wr-a8f2bx1k9q4z\"\n *\n * wrRandomId('ng', 8);\n * // → \"ng-k2f9mbeo\"\n *\n * wrRandomId('wr', 24);\n * // → \"wr-a8f2bx1k9q4zmneo73wplr\"\n * ```\n *\n * @param prefix - Namespace prefix prepended before the random segment. Defaults to `'wr'`.\n * @param length - Length of the random segment. Clamped to `[4, 64]`. Defaults to `12`.\n * @param random - Custom random byte source `(byteLength) => Uint8Array`.\n * When omitted, uses `crypto.getRandomValues` with a `Math.random` fallback.\n * @returns A pseudo-random id string matching `/^[a-z]+-[a-z0-9]+$/`.\n */\nexport function wrRandomId(\n prefix = 'wr',\n length = DEFAULT_LENGTH,\n random?: (byteLength: number) => Uint8Array\n): string {\n const safeLength = Math.min(Math.max(Math.trunc(length), MIN_LENGTH), MAX_LENGTH);\n\n const bytes = random ? random(safeLength) : defaultRandomBytes(safeLength);\n\n let result = '';\n for (let i = 0; i < safeLength; i++) {\n result += ALPHABET[bytes[i] % ALPHABET.length];\n }\n\n return `${prefix}-${result}`;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/**\n * A function that does nothing.\n *\n * Useful as a default callback, placeholder event handler,\n * or to explicitly signal intentional no-ops.\n *\n * @example\n * ```ts\n * @Component({ ... })\n * export class MyComponent {\n * onTouched: () => void = noop;\n * }\n * ```\n */\nexport const wrNoop = (): void => undefined;\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\n/** A debounced function — same signature as the original plus `cancel`. */\nexport type WrDebouncedFn<TArgs extends readonly unknown[]> = ((...args: TArgs) => void) & {\n readonly cancel: () => void;\n};\n\n/**\n * Wrap `fn` so it only fires `waitMs` after the last invocation.\n * Useful for resize / scroll / input handlers.\n *\n * @example\n * ```ts\n * const onResize = wrDebounce(() => recalcLayout(), 150);\n * window.addEventListener('resize', onResize);\n * ```\n */\nexport function wrDebounce<TArgs extends readonly unknown[]>(\n fn: (...args: TArgs) => void,\n waitMs: number\n): WrDebouncedFn<TArgs> {\n let timer: ReturnType<typeof setTimeout> | null = null;\n\n const debounced = (...args: TArgs): void => {\n if (timer !== null) clearTimeout(timer);\n timer = setTimeout(() => {\n timer = null;\n fn(...args);\n }, waitMs);\n };\n\n debounced.cancel = (): void => {\n if (timer !== null) {\n clearTimeout(timer);\n timer = null;\n }\n };\n\n return debounced;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** A throttled function — same signature as the original plus `cancel`. */\nexport type WrThrottledFn<TArgs extends readonly unknown[]> = ((...args: TArgs) => void) & {\n readonly cancel: () => void;\n};\n\n/**\n * Wrap `fn` so it fires at most once every `waitMs`. Leading-edge call\n * fires immediately; trailing-edge call fires once at the end of the window\n * if there were further invocations.\n */\nexport function wrThrottle<TArgs extends readonly unknown[]>(\n fn: (...args: TArgs) => void,\n waitMs: number\n): WrThrottledFn<TArgs> {\n let lastInvoke = 0;\n let trailingTimer: ReturnType<typeof setTimeout> | null = null;\n let pendingArgs: TArgs | null = null;\n\n const throttled = (...args: TArgs): void => {\n const now = Date.now();\n const remaining = waitMs - (now - lastInvoke);\n\n if (remaining <= 0) {\n if (trailingTimer !== null) {\n clearTimeout(trailingTimer);\n trailingTimer = null;\n }\n lastInvoke = now;\n fn(...args);\n } else {\n pendingArgs = args;\n trailingTimer ??= setTimeout(() => {\n lastInvoke = Date.now();\n trailingTimer = null;\n if (pendingArgs) fn(...pendingArgs);\n pendingArgs = null;\n }, remaining);\n }\n };\n\n throttled.cancel = (): void => {\n if (trailingTimer !== null) {\n clearTimeout(trailingTimer);\n trailingTimer = null;\n }\n pendingArgs = null;\n lastInvoke = 0;\n };\n\n return throttled;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/**\n * Canonical `KeyboardEvent.key` values for your own `keydown` handlers.\n *\n * The spec spellings are easy to get wrong — arrows are `ArrowUp`, space is a\n * literal `' '` — and a typo like `'Esacpe'` never matches and never errors.\n * These give you autocomplete and the {@link WrKey} union to match against.\n */\nexport const WR_KEYS = {\n ENTER: 'Enter',\n ESCAPE: 'Escape',\n TAB: 'Tab',\n SPACE: ' ',\n BACKSPACE: 'Backspace',\n DELETE: 'Delete',\n ARROW_UP: 'ArrowUp',\n ARROW_DOWN: 'ArrowDown',\n ARROW_LEFT: 'ArrowLeft',\n ARROW_RIGHT: 'ArrowRight',\n HOME: 'Home',\n END: 'End',\n PAGE_UP: 'PageUp',\n PAGE_DOWN: 'PageDown',\n CONTROL: 'Control',\n SHIFT: 'Shift',\n ALT: 'Alt',\n META: 'Meta',\n} as const;\n\nexport type WrKey = (typeof WR_KEYS)[keyof typeof WR_KEYS];\n\n/**\n * What each key in {@link WR_KEYS} is called on a PC keycap, for a shortcut hint\n * or a cheat sheet: `Esc`, `Enter`, `Ctrl`, an arrow as its glyph. English, the\n * way the keys are printed: `wr-kbd` reads the words from the i18n catalog\n * instead. `wrFormatChord` in `ngwr/hotkey` prints a whole chord from these and\n * swaps in Apple's glyphs (`⌘`, `⇧`, `↩`) on macOS.\n */\nexport const WR_KEY_LABELS: Readonly<Record<WrKey, string>> = {\n [WR_KEYS.ENTER]: 'Enter',\n [WR_KEYS.ESCAPE]: 'Esc',\n [WR_KEYS.TAB]: 'Tab',\n [WR_KEYS.SPACE]: 'Space',\n [WR_KEYS.BACKSPACE]: 'Backspace',\n [WR_KEYS.DELETE]: 'Delete',\n [WR_KEYS.ARROW_UP]: '↑',\n [WR_KEYS.ARROW_DOWN]: '↓',\n [WR_KEYS.ARROW_LEFT]: '←',\n [WR_KEYS.ARROW_RIGHT]: '→',\n [WR_KEYS.HOME]: 'Home',\n [WR_KEYS.END]: 'End',\n [WR_KEYS.PAGE_UP]: 'Page Up',\n [WR_KEYS.PAGE_DOWN]: 'Page Down',\n [WR_KEYS.CONTROL]: 'Ctrl',\n [WR_KEYS.SHIFT]: 'Shift',\n [WR_KEYS.ALT]: 'Alt',\n [WR_KEYS.META]: 'Win',\n};\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** True when any modifier key (Ctrl / Cmd / Alt / Shift / Meta) is held. */\nexport function wrHasModifier(event: KeyboardEvent): boolean {\n return event.ctrlKey || event.altKey || event.metaKey || event.shiftKey;\n}\n\n/**\n * True when the key is a single printable character (letters, digits,\n * punctuation, etc.). Skips function keys, arrows, modifiers, and named\n * keys like `Backspace` or `Tab`.\n */\nexport function wrIsPrintableKey(event: KeyboardEvent): boolean {\n return event.key.length === 1 && !event.ctrlKey && !event.metaKey && !event.altKey;\n}\n\n/**\n * True while an input method is composing — the key belongs to the IME, not to\n * your handler. **Return early on it in every `keydown` handler that reads\n * Enter, Escape or an arrow on, or above, a field that accepts typed text.**\n *\n * A Japanese or Chinese user reaches every character through a conversion. From\n * `compositionstart` until `compositionend` a candidate window is open, and\n * those keys are how it is driven: Enter accepts the candidate, Escape cancels\n * the conversion back to kana, the arrows walk the candidate list. A component\n * that acts on them anyway takes the key away from the IME mid-word — the\n * overlay closes instead of the candidate window, and the half-composed reading\n * the user was still choosing between is gone with it.\n *\n * Both halves of the test are needed. `isComposing` is the standard flag, but\n * Safari fires `compositionend` *before* the `keydown` of the Enter that commits\n * a candidate, so that one arrives with `isComposing === false` and only the\n * legacy `keyCode` of `229` — the sentinel every engine sets on a key it handed\n * to the input method — to say where it came from.\n *\n * `keydown` is the whole scope. It does NOT answer \"is a composition in\n * progress\" for an `input` or `blur` handler: on the committing keystroke the\n * two disagree by design. A component that needs the state *between* events\n * tracks it with the `compositionstart` / `compositionend` pair instead.\n *\n * ```ts\n * protected onKeydown(event: KeyboardEvent): void {\n * if (wrIsComposing(event)) return;\n * // …\n * }\n * ```\n */\nexport function wrIsComposing(event: KeyboardEvent): boolean {\n // `keyCode` is deprecated and stays anyway: it is the only signal Safari\n // leaves on the committing keystroke. See the doc comment above.\n return event.isComposing || event.keyCode === 229;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** The pill the badge loggers share, as a `%c` console style. */\nexport const badgeStyle = (color: string): string => `\n display: inline-block;\n border: 1px solid ${color};\n color: ${color};\n padding: 1px 3px;\n border-radius: 4px;\n margin-right: 0\n `;\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { badgeStyle } from './badge-style';\n\n/**\n * Logs a coloured pill followed by a payload at error level.\n *\n * The same pill as `wrBadgeLog`, through `console.error`, so the message keeps\n * its stack trace and the browser's Errors filter still catches it.\n *\n * @example\n * ```ts\n * wrBadgeError('icons', '#fc6c6c', new Error('plus failed to load'));\n * // → [icons] Error: plus failed to load\n * ```\n *\n * @param badgeText Short label shown inside the pill.\n * @param color CSS colour applied to the pill border and text.\n * @param message Anything you'd pass to `console.error` as the second argument.\n */\nexport function wrBadgeError(badgeText: string, color: string, message: unknown): void {\n // eslint-disable-next-line no-console -- this helper exists to log\n console.error(`%c${badgeText}`, badgeStyle(color), message);\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { badgeStyle } from './badge-style';\n\n/**\n * Logs a coloured pill to the browser console followed by a payload.\n *\n * Useful when you need to scan a noisy console for a specific subsystem's\n * messages. The pill is rendered with the CSS `%c` console formatting trick.\n *\n * @example\n * ```ts\n * wrBadgeLog('icons', '#3969e2', { name: 'plus', registered: true });\n * // → [icons] { name: 'plus', registered: true }\n * ```\n *\n * @param badgeText Short label shown inside the pill.\n * @param color CSS colour applied to the pill border and text.\n * @param message Anything you'd pass to `console.log` as the second argument.\n */\nexport function wrBadgeLog(badgeText: string, color: string, message: unknown): void {\n // eslint-disable-next-line no-console -- this helper exists to log\n console.log(`%c${badgeText}`, badgeStyle(color), message);\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { badgeStyle } from './badge-style';\n\n/**\n * Logs a coloured pill followed by a payload at warning level.\n *\n * The same pill as `wrBadgeLog`, through `console.warn`, so the message keeps\n * its stack trace and the browser's Warnings filter still catches it.\n *\n * @example\n * ```ts\n * wrBadgeWarn('icons', '#fac72e', 'plus is registered twice');\n * // → [icons] plus is registered twice\n * ```\n *\n * @param badgeText Short label shown inside the pill.\n * @param color CSS colour applied to the pill border and text.\n * @param message Anything you'd pass to `console.warn` as the second argument.\n */\nexport function wrBadgeWarn(badgeText: string, color: string, message: unknown): void {\n // eslint-disable-next-line no-console -- this helper exists to log\n console.warn(`%c${badgeText}`, badgeStyle(color), message);\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nlet segmenter: Intl.Segmenter | undefined;\n\n/** A grapheme that can stand for a word: it holds a letter, a digit or a pictograph. */\nconst INITIAL = /[\\p{L}\\p{N}\\p{Extended_Pictographic}]/u;\n\n/** A script whose character is a syllable or a word rather than a letter. */\nconst SYLLABIC = /^[\\p{Script=Han}\\p{Script=Hangul}\\p{Script=Hiragana}\\p{Script=Katakana}]/u;\n\nfunction graphemes(text: string): string[] {\n segmenter ??= new Intl.Segmenter(undefined, { granularity: 'grapheme' });\n return [...segmenter.segment(text)].map(s => s.segment);\n}\n\nfunction initialOf(word: string): string | undefined {\n return graphemes(word).find(g => INITIAL.test(g));\n}\n\nfunction upperCase(initial: string, locale: string | undefined): string {\n const upper = locale === undefined ? initial.toUpperCase() : initial.toLocaleUpperCase(locale);\n return graphemes(upper).length === 1 ? upper : initial;\n}\n\nfunction surname(words: readonly string[], locale: string | undefined, order: WrInitialsOrder): string {\n const parts = words.flatMap(word => {\n const initial = initialOf(word);\n return initial === undefined ? [] : [{ word, initial }];\n });\n const family = order === 'family-first' ? parts.shift() : parts.pop();\n if (family === undefined) return '';\n return [family.word, ...parts.map(part => `${upperCase(part.initial, locale)}.`)].join(' ');\n}\n\n/** How `wrInitials` writes a name: its letters (`RK`), or the family name with initials (`Khegay R.`). */\nexport type WrInitialsStyle = 'letters' | 'surname';\n\n/** The order of the parts in the name given: `Roman Khegay`, or `Хегай Роман`. */\nexport type WrInitialsOrder = 'given-first' | 'family-first';\n\nexport interface WrInitialsOptions {\n /** `'letters'` gives up to two initials; `'surname'` the family name and an initial for each other part. */\n readonly style?: WrInitialsStyle;\n /** Where the family name sits in the input. Read by `'surname'` only. */\n readonly order?: WrInitialsOrder;\n}\n\n/**\n * Up to two initials of a name, one grapheme each, upper-cased.\n *\n * A word is a run between whitespace, so a hyphenated name is one word\n * (`Jean-Luc Picard` gives `JP`). The initial is the first grapheme of the word\n * that holds a letter, a digit or an emoji, so `(Ada)` gives `A` and a word of\n * punctuation alone is skipped. The first two words that yield one are taken:\n * `Ada King Lovelace` gives `AK`, a one-word name gives one initial.\n *\n * A grapheme is what a reader sees as one character: an emoji with a skin tone\n * or a ZWJ sequence, a letter with combining marks and a surrogate pair each\n * count as one initial, never half of one.\n *\n * A Han, Hangul, Hiragana or Katakana name gives ONE initial, its first\n * character: in those scripts a character is a syllable or a word, so two of\n * them read as a word rather than as initials.\n *\n * Upper-casing uses `toUpperCase()` by default, the locale-independent mapping,\n * so the output is the same on the server and the client; pass `locale` for a\n * language whose mapping differs (`tr` turns `i` into `İ`). A letter whose\n * upper case is more than one grapheme (`ß` becomes `SS`) is kept as written.\n *\n * `null`, `undefined`, an empty string and a name with no initial give `''`.\n *\n * `options.style: 'surname'` writes the family name whole, then each other part\n * as its initial and a dot: `Roman Khegay` gives `Khegay R.`. `options.order`\n * says where the family name sits in the input: last for `'given-first'` (the\n * default), so `Ada King Lovelace` gives `Lovelace A. K.`, and first for\n * `'family-first'`, so `Иванов Иван Иванович` gives `Иванов И. И.`. The family\n * name is kept as written, hyphen and case included, and a one-part name comes\n * back as it is. Every part gives an initial, not the first two, each taken and\n * upper-cased as above: a hyphenated given name gives one (`Jean-Luc Picard`\n * gives `Picard J.`) and a part of punctuation alone is dropped before the\n * family name is chosen. The one-initial rule for Han, Hangul and kana does not\n * apply: it keeps two characters from reading as a word, and here the dot\n * already marks an initial, so `王 小明` with `'family-first'` gives `王 小.`.\n *\n * `order` does nothing for `'letters'`, which reads the first two words in the\n * order written.\n *\n * @example\n * ```ts\n * wrInitials('Roman Khegay'); // 'RK'\n * wrInitials(' ada lovelace '); // 'AL'\n * wrInitials('Madonna'); // 'M'\n * wrInitials('王小明'); // '王'\n * wrInitials('👩🏽🚀 Valentina'); // '👩🏽🚀V'\n * wrInitials('...'); // ''\n *\n * wrInitials('Roman Khegay', undefined, { style: 'surname' }); // 'Khegay R.'\n * wrInitials('Хегай Роман', undefined, { style: 'surname', order: 'family-first' }); // 'Хегай Р.'\n * ```\n *\n * @see https://ngwr.dev/reference/utils/wr-initials\n */\nexport function wrInitials(name: string | null | undefined, locale?: string, options?: WrInitialsOptions): string {\n if (name === null || name === undefined) return '';\n const words = String(name).trim().split(/\\s+/u);\n if (options?.style === 'surname') return surname(words, locale, options.order ?? 'given-first');\n let out = '';\n let count = 0;\n for (const word of words) {\n const initial = initialOf(word);\n if (initial === undefined) continue;\n out += upperCase(initial, locale);\n if (++count === 2 || SYLLABIC.test(initial)) break;\n }\n return out;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { InjectionToken, type Signal } from '@angular/core';\n\n/**\n * The interface language as a signal, for what has to follow a language switch\n * without importing `ngwr/i18n`: `provideWrI18n()` provides it as\n * `WrI18n.locale`, and `ngwr/date` formats in it. Not provided when the app\n * does not call `provideWrI18n()`, so inject it as optional.\n */\nexport const WR_LIVE_LOCALE = new InjectionToken<Signal<string>>('WR_LIVE_LOCALE');\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 type { EnvironmentProviders, Provider } from '@angular/core';\n\n/**\n * One piece of app-wide configuration, passed to `provideWr()` from `ngwr` —\n * the shape Angular gives `RouterFeature` for `provideRouter(routes, withX())`.\n *\n * Each feature is exported by the entry point it configures (`withDensity()`\n * from `ngwr/density`, `withToast()` from `ngwr/toast`, …), so an app bundles\n * only the ones it imports. The type lives here rather than beside\n * `provideWr()` so that no secondary entry point has to import the root one.\n *\n * Both members are private API: build a feature with {@link wrFeature} and read\n * it only inside `provideWr()`.\n */\nexport interface WrFeature<K extends string = string> {\n /** Which feature this is. `provideWr()` refuses the same kind twice in dev mode. */\n readonly ɵkind: K;\n /** What the feature registers, flattened into `provideWr()`'s providers. */\n readonly ɵproviders: readonly (Provider | EnvironmentProviders)[];\n}\n\n/**\n * Build a {@link WrFeature} — what every `with*()` function returns.\n *\n * @example\n * ```ts\n * export function withMeta(defaults: WrMetaConfig = {}): WrFeature<'meta'> {\n * return wrFeature('meta', [{ provide: WR_META_DEFAULTS, useValue: defaults }]);\n * }\n * ```\n */\nexport function wrFeature<K extends string>(\n kind: K,\n providers: readonly (Provider | EnvironmentProviders)[]\n): WrFeature<K> {\n return { ɵkind: kind, ɵproviders: providers };\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { type Signal, computed, signal } from '@angular/core';\n\n/** Where a {@link WrAction} is: nothing ran yet, a run is in flight, or how the last one ended. */\nexport type WrActionStatus = 'idle' | 'pending' | 'success' | 'error';\n\n/** One async write with its state as signals. Built by {@link wrAction}. */\nexport interface WrAction<A = void, R = void> {\n /** `idle` until the first run, `pending` while one is in flight, then `success` or `error`. */\n readonly status: Signal<WrActionStatus>;\n /** `true` while a run is in flight: `status() === 'pending'`. */\n readonly loading: Signal<boolean>;\n /** What the last successful run resolved with. Kept through a later run and a later failure; `undefined` until one succeeds and after `reset()`. */\n readonly value: Signal<R | undefined>;\n /** What the last run rejected with, or `undefined`. Cleared when a run starts and by `reset()`. */\n readonly error: Signal<unknown>;\n /**\n * Starts the write, or joins the one in flight.\n *\n * Single-flight: a call while a run is pending starts nothing and returns\n * that run's promise, so the caller still gets the result it would have\n * waited for, never a dropped one. The promise never rejects: it resolves\n * with the result, or with `undefined` when the call threw (read `error()`)\n * or when `reset()` ran before it settled.\n */\n run(arg: A): Promise<R | undefined>;\n /** Back to `idle`, with `value` and `error` cleared. A run still in flight is disowned: its result is dropped when it arrives. */\n reset(): void;\n}\n\n/**\n * Holds one async write, a save or a delete, as signals a template can read:\n * `status`, `loading`, the last `value` and the last `error`, with a\n * single-flight `run()` and a `reset()`.\n *\n * Needs no injection context, holds no DOM and registers nothing to clean up:\n * a result that lands after the owner is destroyed writes plain signals, which\n * nothing reads any more.\n *\n * @example\n * ```ts\n * readonly save = wrAction((draft: Draft) => this.api.save(draft));\n * ```\n * ```html\n * <button wr-btn [loading]=\"save.loading()\" (click)=\"save.run(draft())\">Save</button>\n * @if (save.status() === 'error') { <wr-alert type=\"danger\">Could not save.</wr-alert> }\n * ```\n *\n * @param fn - The write. May throw synchronously; that counts as a rejection.\n * @returns The action, with `run()` and `reset()` bound so they can be passed around.\n */\nexport function wrAction<A = void, R = void>(fn: (arg: A) => Promise<R>): WrAction<A, R> {\n const status = signal<WrActionStatus>('idle');\n const value = signal<R | undefined>(undefined);\n const error = signal<unknown>(undefined);\n let flight: Promise<R | undefined> | null = null;\n // Bumped by reset(), so a run that started before it finds its result unwanted.\n let generation = 0;\n\n const run = (arg: A): Promise<R | undefined> => {\n if (flight) return flight;\n const mine = ++generation;\n status.set('pending');\n error.set(undefined);\n flight = new Promise<R>(resolve => resolve(fn(arg))).then(\n result => {\n if (mine !== generation) return undefined;\n flight = null;\n value.set(result);\n status.set('success');\n return result;\n },\n (reason: unknown) => {\n if (mine !== generation) return undefined;\n flight = null;\n error.set(reason);\n status.set('error');\n return undefined;\n }\n );\n return flight;\n };\n\n const reset = (): void => {\n generation++;\n flight = null;\n status.set('idle');\n value.set(undefined);\n error.set(undefined);\n };\n\n return { status, loading: computed(() => status() === 'pending'), value, error, run, reset };\n}\n\n/** The keyed form of {@link WrAction}: one write per key, each single-flight on its own. Built by {@link wrKeyedAction}. */\nexport interface WrKeyedAction<K, A = void, R = void> {\n /** `true` while `key` has a run in flight. Reactive: a template or a `computed()` re-reads it when the key settles. */\n pending(key: K): boolean;\n /** `true` while any key has a run in flight. */\n readonly loading: Signal<boolean>;\n /** What the most recently settled run rejected with, or `undefined` when it succeeded. Cleared by `reset()`. */\n readonly error: Signal<unknown>;\n /**\n * Starts the write for `key`, or joins the one in flight for that key.\n *\n * Single-flight per key: a second call for a pending key returns that run's\n * promise, while another key runs alongside. The promise never rejects: it\n * resolves with the result, or with `undefined` when the call threw (read\n * `error()`) or when `reset()` ran before it settled.\n */\n run(key: K, arg: A): Promise<R | undefined>;\n /** Forgets every pending key and clears `error`. Runs still in flight are disowned: their results are dropped when they arrive. */\n reset(): void;\n}\n\n/**\n * The row form of {@link wrAction}: the same write across many keys, a row id\n * say, so a list can show which rows are busy while one row cannot run twice.\n * A key is kept only while it is pending, so the state stays as small as the\n * number of runs in flight.\n *\n * Needs no injection context, like `wrAction`.\n *\n * @example\n * ```ts\n * readonly remove = wrKeyedAction((id: string) => this.api.remove(id));\n * ```\n * ```html\n * @for (row of rows(); track row.id) {\n * <button wr-btn [loading]=\"remove.pending(row.id)\" (click)=\"remove.run(row.id)\">Remove</button>\n * }\n * ```\n *\n * @param fn - The write. Gets the key and the argument `run()` was called with. May throw synchronously; that counts as a rejection.\n * @returns The keyed action, with its methods bound so they can be passed around.\n */\nexport function wrKeyedAction<K, A = void, R = void>(fn: (key: K, arg: A) => Promise<R>): WrKeyedAction<K, A, R> {\n const keys = signal<ReadonlySet<K>>(new Set());\n const error = signal<unknown>(undefined);\n const flights = new Map<K, Promise<R | undefined>>();\n let generation = 0;\n\n const drop = (key: K): void => {\n flights.delete(key);\n keys.update(set => {\n const next = new Set(set);\n next.delete(key);\n return next;\n });\n };\n\n const run = (key: K, arg: A): Promise<R | undefined> => {\n const live = flights.get(key);\n if (live) return live;\n const mine = generation;\n keys.update(set => new Set(set).add(key));\n const flight = new Promise<R>(resolve => resolve(fn(key, arg))).then(\n result => {\n if (mine !== generation) return undefined;\n drop(key);\n error.set(undefined);\n return result;\n },\n (reason: unknown) => {\n if (mine !== generation) return undefined;\n drop(key);\n error.set(reason);\n return undefined;\n }\n );\n flights.set(key, flight);\n return flight;\n };\n\n const reset = (): void => {\n generation++;\n flights.clear();\n keys.set(new Set());\n error.set(undefined);\n };\n\n return {\n pending: (key: K) => keys().has(key),\n loading: computed(() => keys().size > 0),\n error,\n run,\n reset,\n };\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { type Resource, type Signal, assertInInjectionContext, effect, linkedSignal } from '@angular/core';\n\n/** The source's answer while the resource has no settled value, distinct from any value it could hold. */\nconst NONE: unique symbol = Symbol('wrResourceValue.none');\n\n/**\n * A resource's value as a signal that never throws: the value while the\n * resource has one, the last settled value while it loads, reloads or sits in\n * its error state, and `fallback` before anything settled.\n *\n * `resource.value()` throws while the status is `error`, so a template that\n * reads it needs a guard at every read; and a `loading` for new params drops\n * the old value, so a list flickers empty on every page change. This keeps the\n * last `resolved` or `local` value through both.\n *\n * Takes anything that is a `Resource`: `resource()`, `rxResource()` and\n * `httpResource()` alike. Needs an injection context, like the resource it\n * reads: an effect records each settled value as it lands, so the memory does\n * not depend on something having read the signal in time, and ends with the\n * context.\n *\n * @example\n * ```ts\n * readonly users = httpResource<User[]>(() => `/api/users?page=${this.page()}`);\n * readonly rows = wrResourceValue(this.users, []);\n * ```\n * ```html\n * <wr-table [items]=\"rows()\" [loading]=\"users.isLoading()\" />\n * ```\n *\n * @param resource - The resource to read.\n * @param fallback - What to return until the resource first settles with a value.\n * @returns A read-only signal of the value.\n */\nexport function wrResourceValue<T>(resource: Resource<T | undefined>, fallback: NoInfer<T>): Signal<T> {\n assertInInjectionContext(wrResourceValue);\n const value = linkedSignal<T | typeof NONE, T>({\n source: () => {\n const status = resource.status();\n const settled = (status === 'resolved' || status === 'local') && resource.hasValue();\n return settled ? resource.value() : NONE;\n },\n computation: (next, previous) => (next !== NONE ? next : previous ? previous.value : fallback),\n });\n effect(() => value());\n return value.asReadonly();\n}\n"],"mappings":";;;;;;;;;AAwBA,SAAgB,YAAe,OAAiB;CAC9C,OAAO,UAAU,QAAQ,UAAU;AACrC;;;;;;;ACJA,SAAgB,kBAAqB,OAAmB;CACtD,OAAO,MAAM,QAAQ,KAAK,KAAK,MAAM,SAAS;AAChD;;;;;;;ACFA,SAAgB,eAA4B,OAAc;CACxD,OAAO,CAAC,CAAC,SAAS,OAAQ,MAAkC,cAAc;AAC5E;ACdA,SAAgB,QAAQ,OAAe,KAAa,KAAW;CAC7D,OAAO,KAAK,IAAI,KAAK,KAAK,IAAI,KAAK,KAAK,CAAC;AAC3C;;;;;;;ACCA,MAAM,aAAa;AAGnB,MAAM,eAAe;AAErB,SAAS,MAAM,OAAc;CAC3B,IAAI;CACJ,IAAI,OAAO,UAAU,UAAU,OAAO,MAAM,KAAI;MAC3C,IAAI,OAAO,UAAU,UAAU;EAClC,IAAI,CAAC,OAAO,SAAS,KAAK,GAAG,OAAO;EACpC,OAAO,OAAO,KAAK;CACrB,OAAO,IAAI,OAAO,UAAU,UAAU,OAAO,MAAM,SAAQ;MACtD,OAAO;CAEZ,MAAM,QAAQ,WAAW,KAAK,IAAI;CAClC,IAAI,CAAC,OAAO,OAAO;CACnB,MAAM,GAAG,MAAM,MAAM,IAAI,OAAO,IAAI,MAAM,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,IAAI,KAAK,MAAM;EACvB,OAAO;CACT;CAEA,MAAM,cAAmB;EACvB;EACA,QAAQ,MAAK;EACb,KAAK,oBAAI,IAAI,IAAG,CAAE;EAClB,MAAM,IAAI,MAAS;CACrB;CAEA,OAAO;EACL,UAAU,QAAW,KAAI,CAAE,CAAC,IAAI,GAAG;EACnC,SAAS,eAAe,KAAI,CAAE,CAAC,OAAO,CAAC;EACvC;EACA;EACA;CACD;AACH;;;;;;;ACxLA,MAAM,OAAsB,OAAO,sBAAsB;AA+BzD,SAAgB,gBAAmB,UAAmC,UAAoB;CACxF,yBAAyB,eAAe;CACxC,MAAM,QAAQ,aAAY;EAAA,GAAA,YAAA,EAAA,WAAA,QAAA,+BAAA,CAAA;EACxB,cAAa;GACX,MAAM,SAAS,SAAS,OAAM;GAE9B,QADiB,WAAW,cAAc,WAAW,YAAY,SAAS,SAAQ,IACjE,SAAS,MAAK,IAAK;EACtC;EACA,cAAc,MAAM,aAAc,SAAS,OAAO,OAAO,WAAW,SAAS,QAAQ;CAAS,CAAA;CAEhG,aAAa,MAAK,CAAE;CACpB,OAAO,MAAM,WAAU;AACzB"}
|
|
1
|
+
{"version":3,"file":"ngwr-utils.mjs","names":["MAX_LENGTH","DOCUMENT"],"sources":["../../../projects/lib/utils/guards/is-defined.ts","../../../projects/lib/utils/guards/is-non-empty-array.ts","../../../projects/lib/utils/guards/is-observable.ts","../../../projects/lib/utils/math/clamp.ts","../../../projects/lib/utils/math/decimal.ts","../../../projects/lib/utils/math/round.ts","../../../projects/lib/utils/coercion/num-attr.ts","../../../projects/lib/utils/css-class/to-class-list.ts","../../../projects/lib/utils/css-value/is-safe-css-value.ts","../../../projects/lib/utils/dom/check-styles.ts","../../../projects/lib/utils/dom/content-disposition-file-name.ts","../../../projects/lib/utils/dom/download-blob.ts","../../../projects/lib/utils/dom/get-root-font-size.ts","../../../projects/lib/utils/dom/focus.ts","../../../projects/lib/utils/dom/resolve-css-color.ts","../../../projects/lib/utils/dom/watch-color-scheme.ts","../../../projects/lib/utils/dom/watch-drag-cancel.ts","../../../projects/lib/utils/css-size/resolve-css-size.ts","../../../projects/lib/utils/id/random-id.ts","../../../projects/lib/utils/fn/noop.ts","../../../projects/lib/utils/fn/debounce.ts","../../../projects/lib/utils/fn/throttle.ts","../../../projects/lib/utils/keyboard/keys.ts","../../../projects/lib/utils/keyboard/predicates.ts","../../../projects/lib/utils/keyboard/typeahead.ts","../../../projects/lib/utils/log/badge-style.ts","../../../projects/lib/utils/log/badge-error.ts","../../../projects/lib/utils/log/badge-log.ts","../../../projects/lib/utils/log/badge-warn.ts","../../../projects/lib/utils/text/initials.ts","../../../projects/lib/utils/locale/live-locale.ts","../../../projects/lib/utils/feature/wr-feature.ts","../../../projects/lib/utils/async/action.ts","../../../projects/lib/utils/async/resource-value.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 type { WrMaybe } from '../types';\n\n/**\n * Type guard that checks if a value is neither `null` nor `undefined`.\n *\n * @example\n * ```ts\n * const maybeValue: WrMaybe<number> = getValue();\n *\n * if (wrIsDefined(maybeValue)) {\n * // here maybeValue is number\n * console.log(maybeValue.toFixed(2));\n * }\n * ```\n *\n * @see {@link WrMaybe}\n */\nexport function wrIsDefined<T>(value: WrMaybe<T>): value is T {\n return value !== null && value !== undefined;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport type { WrMaybe } from '../types';\n\n/**\n * Type guard that checks if a value is an array with at least one element.\n *\n * @example\n * ```ts\n * const items: WrMaybe<string[]> = getItems();\n *\n * if (wrIsNonEmptyArray(items)) {\n * // items is string[]\n * console.log(items[0]);\n * }\n * ```\n */\nexport function wrIsNonEmptyArray<T>(value: WrMaybe<T[]>): value is [T, ...T[]] {\n return Array.isArray(value) && value.length > 0;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport type { Observable } from 'rxjs';\n\n/**\n * Type guard that checks whether a value looks like an RxJS `Observable`.\n *\n * Uses duck-typing: verifies that the object has a `subscribe` function.\n * Does not require an actual `Observable` instance.\n *\n * @example\n * ```ts\n * if (wrIsObservable(stream)) {\n * stream.subscribe(value => console.log(value));\n * }\n * ```\n */\nexport function wrIsObservable<T = unknown>(value: unknown): value is Observable<T> {\n return !!value && typeof (value as { subscribe?: unknown }).subscribe === 'function';\n}\n","/**\n * Clamps `value` into the inclusive `[min, max]` range.\n *\n * @example\n * ```ts\n * wrClamp(140, 0, 100); // 100\n * wrClamp(-3, 0, 100); // 0\n * wrClamp(42, 0, 100); // 42\n * ```\n */\nexport function wrClamp(value: number, min: number, max: number): number {\n return Math.min(max, Math.max(min, value));\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** Fixed-point value: `units / 10^scale`. */\ninterface Decimal {\n readonly units: bigint;\n readonly scale: number;\n}\n\nconst DECIMAL_RE = /^([+-])?(\\d*)(?:\\.(\\d*))?(?:[eE]([+-]?\\d+))?$/;\n\n/** Past this an exponent is not a number anyone meant; `10n ** 10n ** 9n` would hang the tab. */\nconst MAX_EXPONENT = 1000;\n\nfunction parse(value: unknown): Decimal | null {\n let text: string;\n if (typeof value === 'string') text = value.trim();\n else if (typeof value === 'number') {\n if (!Number.isFinite(value)) return null;\n text = String(value);\n } else if (typeof value === 'bigint') text = value.toString();\n else return null;\n\n const match = DECIMAL_RE.exec(text);\n if (!match) return null;\n const [, sign, int = '', frac = '', exp = '0'] = match;\n if (!int && !frac) return null;\n const exponent = Number(exp);\n if (Math.abs(exponent) > MAX_EXPONENT) return null;\n\n let units = BigInt(int + frac);\n let scale = frac.length - exponent;\n if (scale < 0) {\n units *= 10n ** BigInt(-scale);\n scale = 0;\n }\n return { units: sign === '-' ? -units : units, scale };\n}\n\nfunction print({ units, scale }: Decimal): string {\n const negative = units < 0n;\n const digits = (negative ? -units : units).toString().padStart(scale + 1, '0');\n const split = digits.length - scale;\n const text = scale ? `${digits.slice(0, split)}.${digits.slice(split)}` : digits;\n return negative ? `-${text}` : text;\n}\n\nfunction align(a: Decimal, b: Decimal): [bigint, bigint, number] {\n const scale = Math.max(a.scale, b.scale);\n return [a.units * 10n ** BigInt(scale - a.scale), b.units * 10n ** BigInt(scale - b.scale), scale];\n}\n\n/** Half away from zero, the schoolbook rule. */\nfunction roundedQuotient(num: bigint, den: bigint): bigint {\n let q = num / den;\n const r = num % den;\n const absR = r < 0n ? -r : r;\n const absDen = den < 0n ? -den : den;\n if (absR * 2n >= absDen) q += num < 0n !== den < 0n ? -1n : 1n;\n return q;\n}\n\nfunction rescale(d: Decimal, decimals: number): Decimal {\n if (decimals >= d.scale) return { units: d.units * 10n ** BigInt(decimals - d.scale), scale: decimals };\n return { units: roundedQuotient(d.units, 10n ** BigInt(d.scale - decimals)), scale: decimals };\n}\n\nfunction isScale(decimals: number): boolean {\n return Number.isInteger(decimals) && decimals >= 0;\n}\n\n/**\n * Reads a value as an exact decimal and returns it in canonical form, or\n * `null` when it is not a number.\n *\n * Canonical is `-?\\d+(\\.\\d+)?`: no sign on zero, no leading zeros, no bare\n * point, no exponent. Trailing fraction zeros are kept, since they are\n * precision the data carries: `'1.50'` stays `'1.50'`. A number is read from\n * its shortest round-trip form (`0.1` is `'0.1'`), so a value already in a\n * double stays what it printed as; a string is read digit for digit, so\n * `'9007199254740993.01'` survives untouched. Exponent notation is read\n * exactly: `'1e5'` is `'100000'`, `'1.5E-3'` is `'0.0015'`.\n *\n * Malformed is `''`, `'abc'`, `'1.2.3'`, `'1,5'`, `'Infinity'`, `NaN`, `null`,\n * `undefined`, anything that is not a string, number or bigint, and an\n * exponent beyond 1000. None of them throws, and none reads as zero.\n *\n * @example\n * ```ts\n * wrDecimal('00.10'); // '0.10'\n * wrDecimal(' -5. '); // '-5'\n * wrDecimal(1e21); // '1000000000000000000000'\n * wrDecimal('abc'); // null\n * ```\n */\nexport function wrDecimal(value: unknown): string | null {\n const d = parse(value);\n return d === null ? null : print(d);\n}\n\n/**\n * `a + b`, exactly. The result carries the wider scale of the two:\n * `'0.1' + '0.2'` is `'0.3'`, `'10.00' + '0.5'` is `'10.50'`. `null` when\n * either side is malformed (see {@link wrDecimal}).\n */\nexport function wrDecimalAdd(a: WrDecimalLike, b: WrDecimalLike): string | null {\n const x = parse(a);\n const y = parse(b);\n if (x === null || y === null) return null;\n const [ux, uy, scale] = align(x, y);\n return print({ units: ux + uy, scale });\n}\n\n/** `a - b`, exactly. The scale and the malformed rule are {@link wrDecimalAdd}'s. */\nexport function wrDecimalSubtract(a: WrDecimalLike, b: WrDecimalLike): string | null {\n const x = parse(a);\n const y = parse(b);\n if (x === null || y === null) return null;\n const [ux, uy, scale] = align(x, y);\n return print({ units: ux - uy, scale });\n}\n\n/**\n * `a * b`, exactly. The scales add: `'1.5' * '0.25'` is `'0.375'`,\n * `'19.99' * 3` is `'59.97'`. `null` when either side is malformed.\n */\nexport function wrDecimalMultiply(a: WrDecimalLike, b: WrDecimalLike): string | null {\n const x = parse(a);\n const y = parse(b);\n if (x === null || y === null) return null;\n return print({ units: x.units * y.units, scale: x.scale + y.scale });\n}\n\n/**\n * `a / b` at exactly `decimals` fraction digits, rounded half away from zero:\n * `wrDecimalDivide('10', 3, 2)` is `'3.33'`, `wrDecimalDivide('-2.5', 1, 0)`\n * is `'-3'`. `null` when a side is malformed, `b` is zero, or `decimals` is\n * not a whole number of places.\n */\nexport function wrDecimalDivide(a: WrDecimalLike, b: WrDecimalLike, decimals: number): string | null {\n const x = parse(a);\n const y = parse(b);\n if (x === null || y === null || y.units === 0n || !isScale(decimals)) return null;\n const num = x.units * 10n ** BigInt(y.scale + decimals);\n const den = y.units * 10n ** BigInt(x.scale);\n return print({ units: roundedQuotient(num, den), scale: decimals });\n}\n\n/**\n * Orders two decimals: `-1`, `0` or `1`, the shape `Array.prototype.sort`\n * takes. Scale does not count: `'1.50'` and `'1.5'` are `0`. `null` when\n * either side is malformed.\n */\nexport function wrDecimalCompare(a: WrDecimalLike, b: WrDecimalLike): -1 | 0 | 1 | null {\n const x = parse(a);\n const y = parse(b);\n if (x === null || y === null) return null;\n const [ux, uy] = align(x, y);\n return ux < uy ? -1 : ux > uy ? 1 : 0;\n}\n\n/**\n * Sets the scale to exactly `decimals` places: pads with zeros\n * (`wrDecimalRound('1.5', 2)` is `'1.50'`) or rounds half away from zero\n * (`wrDecimalRound('2.345', 2)` is `'2.35'`, `wrDecimalRound('-2.5', 0)` is\n * `'-3'`). Unlike `wrRound` from the same entry point there is no float on the\n * way, so `'1.005'` rounds to `'1.01'` because that is what the digits say.\n * `null` when the value is malformed or `decimals` is not a whole number of\n * places.\n */\nexport function wrDecimalRound(value: WrDecimalLike, decimals: number): string | null {\n const d = parse(value);\n if (d === null || !isScale(decimals)) return null;\n return print(rescale(d, decimals));\n}\n\n/**\n * What the decimal helpers read: a decimal string, a finite number or a\n * bigint. `null` and `undefined` are accepted so a value can be passed\n * straight from data; they read as malformed, like any other text that is not\n * a number.\n */\nexport type WrDecimalLike = string | number | bigint | null | undefined;\n","/**\n * Rounds `value` to `decimals` fraction digits, compensating the usual\n * floating point drift (`0.1 + 0.2` rounds to `0.3`, not `0.30000000000000004`).\n *\n * The `Number.EPSILON` nudge only bites while `|value| < 2`: it is an absolute\n * 2^-52, which is one ulp in `[1, 2)` and a fraction of one above it, so\n * `value + Number.EPSILON === value` for anything larger and the result is\n * plain `Math.round`. Correct for what this is used for — step maths and\n * fraction digits on human-sized numbers — and not a general fixed-point\n * rounder.\n *\n * @example\n * ```ts\n * wrRound(0.1 + 0.2, 2); // 0.3\n * wrRound(1.005, 2); // 1.01\n * wrRound(7.4); // 7\n * ```\n */\nexport function wrRound(value: number, decimals = 0): number {\n const factor = 10 ** decimals;\n return Math.round((value + Number.EPSILON) * factor) / factor;\n}\n","import { coerceNumberProperty } from '@angular/cdk/coercion';\n\n/**\n * Input-transform factory: coerces any bound value to a number, falling\n * back to `fallback` for `null` / `undefined` / unparsable input. The\n * standard transform for numeric `input()`s across ngwr.\n *\n * @example\n * ```ts\n * readonly speed = input(4, { transform: wrNumAttr(4) });\n * ```\n */\nexport const wrNumAttr =\n (fallback: number) =>\n (value: unknown): number =>\n coerceNumberProperty(value, fallback);\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 type { WrClassInput } from '../types';\n\n/**\n * Flattens class inputs into the de-duplicated token array `classList.add()`\n * and the CDK both require.\n *\n * **Splitting on whitespace is the point of this function, not a nicety.** The\n * CDK hands `panelClass` to `element.classList.add(...coerceArray(value))`, and\n * `coerceArray` wraps a string rather than splitting it — so one `'p-4 rounded'`\n * reaches `classList.add('p-4 rounded')`, which throws `InvalidCharacterError`\n * and takes the whole overlay down with it. Which is the first thing anyone\n * writes: a Tailwind user reaches for a space-separated string before an array.\n *\n * `false` is accepted so a call site can spell a conditional class inline\n * (`this.arrow() && 'wr-dropdown-overlay--arrow'`) instead of building an array\n * first.\n *\n * @example\n * ```ts\n * wrToClassList('wr-dropdown-overlay', this.arrow() && 'wr-dropdown-overlay--arrow', this.panelClass());\n * // ['wr-dropdown-overlay', 'wr-dropdown-overlay--arrow', 'p-4', 'rounded-xl']\n * ```\n */\nexport function wrToClassList(...values: readonly (WrClassInput | false)[]): string[] {\n const out: string[] = [];\n const seen = new Set<string>();\n\n for (const value of values) {\n if (!value) continue;\n // Entries of an ARRAY are split too, not only a bare string: nothing stops\n // `['btn', 'p-4 rounded']`, and the entry holding the space would throw in\n // exactly the same place a bare `'p-4 rounded'` does.\n for (const entry of typeof value === 'string' ? [value] : value) {\n if (!entry) continue;\n for (const part of entry.split(/\\s+/)) {\n // A token can still be empty here: `' a '.split(/\\s+/)` keeps the ends.\n if (!part || seen.has(part)) continue;\n seen.add(part);\n out.push(part);\n }\n }\n }\n\n return out;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** Longest value worth composing. A colour is never near this. */\nconst MAX_LENGTH = 256;\n\n/**\n * Characters that end a declaration, open a string, or start a comment — none\n * of which belong in a value the library is about to wrap its own syntax around.\n */\nconst FORBIDDEN = /[;{}\"'\\\\@<>!]|\\/\\*|\\*\\//;\n\n/** Function name immediately preceding an open paren. */\nconst FUNCTION_NAME = /([\\w-]*)\\($/;\n\n/**\n * Functions a composed value may call. Every image-producing function is absent\n * on purpose — `url()`, `image-set()`, `cross-fade()`, `element()`, `paint()` —\n * because fetching is the whole impact of this class.\n */\nconst ALLOWED_FUNCTIONS = new Set([\n 'rgb',\n 'rgba',\n 'hsl',\n 'hsla',\n 'hwb',\n 'lab',\n 'lch',\n 'oklab',\n 'oklch',\n 'color',\n 'color-mix',\n 'light-dark',\n 'var',\n 'calc',\n 'min',\n 'max',\n 'clamp',\n]);\n\n/**\n * Answers whether a value can be composed **into** a larger CSS expression\n * without escaping the slot it was given — a colour inside a `linear-gradient()`\n * the component builds, an entry the component joins into a custom property a\n * stylesheet then substitutes.\n *\n * It is a containment check, not a colour parser. It says the value cannot\n * terminate the construct the library wrapped around it; it says nothing about\n * whether the value is a colour a browser will accept, and a rejected value\n * should fall back to the component's own default rather than be repaired.\n *\n * **A value bound straight to `[style.background]` needs none of this.** There\n * is nothing to break out of there, and Angular applies style values through\n * CSSOM by design — validating those would amount to refusing style values in a\n * style binding.\n *\n * Rejected, and each one is a way out of the slot:\n *\n * - a `)` the value never opened — `red), url(…), linear-gradient(red` is the\n * shape that turns a colour into an extra background layer the browser fetches;\n * - a top-level `,` — a `<color>` is one value, so a comma at depth 0 means the\n * payload has reached the slot next to the one it was handed;\n * - `;` `{` `}` a quote, a backslash, `!`, or a CSS comment delimiter;\n * - any function outside {@link ALLOWED_FUNCTIONS} — `url()` above all.\n *\n * Top-level whitespace is allowed: `red 20%` is a legitimate gradient stop, and\n * without a comma or a bare `)` it cannot reach anything.\n *\n * @example\n * ```ts\n * wrIsSafeCssValue('var(--wr-color-primary)'); // true\n * wrIsSafeCssValue('color-mix(in srgb, red 50%, blue)'); // true\n * wrIsSafeCssValue('red), url(\"https://x.test/beacon\"), linear-gradient(red'); // false\n * ```\n *\n * @param value Raw value handed to the component.\n * @returns `true` when the value stays inside its slot.\n */\nexport function wrIsSafeCssValue(value: string): boolean {\n if (typeof value !== 'string') return false;\n\n const trimmed = value.trim();\n if (trimmed === '' || trimmed.length > MAX_LENGTH) return false;\n if (FORBIDDEN.test(trimmed)) return false;\n\n let depth = 0;\n for (let i = 0; i < trimmed.length; i++) {\n const char = trimmed[i];\n\n if (char === '(') {\n const name = FUNCTION_NAME.exec(trimmed.slice(0, i + 1));\n if (!name || !ALLOWED_FUNCTIONS.has(name[1].toLowerCase())) return false;\n depth++;\n } else if (char === ')') {\n depth--;\n if (depth < 0) return false;\n } else if (depth === 0 && char === ',') {\n return false;\n }\n }\n\n return depth === 0;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { DOCUMENT, isPlatformBrowser } from '@angular/common';\nimport { ElementRef, PLATFORM_ID, afterNextRender, inject } from '@angular/core';\n\n/** Entry points already checked, per document: a page of forty buttons warns once. */\nconst checked = new WeakMap<Document, Set<string>>();\n\n/**\n * The property `theme/styles/_loaded.scss` declares for an entry:\n * `charts/bar-chart` reads `--wr-loaded-charts-bar-chart`.\n */\nfunction marker(entry: string): string {\n return `--wr-loaded-${entry.replace(/\\//g, '-')}`;\n}\n\n/**\n * Whether a stylesheet can reach this document at all.\n *\n * jsdom and happy-dom load no `<link>` and a unit test wires no global Sass,\n * so under either every component would warn once per entry point, in the\n * library's own specs and in a consumer's alike. There is nothing to add there.\n */\nfunction appliesStylesheets(doc: Document): boolean {\n const ua = doc.defaultView?.navigator.userAgent ?? '';\n return !/jsdom|happydom/i.test(ua);\n}\n\n/**\n * Warns, once per entry point and document, when a component renders without\n * its stylesheet.\n *\n * Every public entry sheet declares `--wr-loaded-<entry>` on `:root` (the\n * `loaded()` mixin in the theme layer), so a component can tell after its first\n * render whether `@use 'ngwr/<entry>'` ever ran. Without it a component renders\n * unstyled and nothing else says why.\n *\n * A component calls it from its constructor, behind the same guard Angular\n * puts on its own dev checks, so a production build drops the call and the\n * text with it:\n *\n * ```ts\n * constructor() {\n * if (typeof ngDevMode === 'undefined' || ngDevMode) wrCheckStyles('select');\n * }\n * ```\n *\n * The read happens in `afterNextRender`, never at construction, and in the\n * browser only: the server has no stylesheet to apply. A nested component stays\n * silent when its parent's sheet was added, because a parent sheet loads the\n * sheets of what it renders, markers included.\n *\n * @internal Shared by the entry points; not a consumer API.\n * @param entry The `exports` key under `ngwr/`, nested ones included: `select`, `charts/bar-chart`.\n */\nexport function wrCheckStyles(entry: string): void {\n // Guarded here as well as at the call site: the call site is what lets a\n // bundler drop the import, this is what keeps a direct call silent in\n // production and lets a spec observe it.\n if (!(typeof ngDevMode === 'undefined' || ngDevMode)) return;\n // `afterNextRender` is a no-op under `ngServerMode` already; the platform id\n // says the same thing where a spec can set it.\n if (!isPlatformBrowser(inject(PLATFORM_ID))) return;\n\n const doc = inject(DOCUMENT);\n const done = checked.get(doc) ?? new Set<string>();\n checked.set(doc, done);\n if (done.has(entry)) return;\n\n const host = inject<ElementRef<Element>>(ElementRef).nativeElement;\n\n afterNextRender(() => {\n // Every instance of the first render registers a hook; the first to run\n // answers for all of them.\n if (!appliesStylesheets(doc) || done.has(entry)) return;\n done.add(entry);\n\n const style = doc.defaultView!.getComputedStyle(doc.documentElement);\n const loaded = (name: string): boolean => style.getPropertyValue(marker(name)).trim() !== '';\n const tag = `<${host.localName}>`;\n\n if (!done.has('theme')) {\n done.add('theme');\n if (!loaded('theme')) {\n // eslint-disable-next-line no-console -- a dev-mode diagnostic, reported and never thrown\n console.warn(\n `[NGWR] ${tag} renders without the theme tokens. Add @use 'ngwr/theme'; first in your global stylesheet, ` +\n 'or run ng g ngwr:component-style theme.'\n );\n }\n }\n\n if (!loaded(entry)) {\n // eslint-disable-next-line no-console -- a dev-mode diagnostic, reported and never thrown\n console.warn(\n `[NGWR] ${tag} renders without its styles. Add @use 'ngwr/${entry}'; to your global stylesheet, ` +\n `or run ng g ngwr:component-style ${entry}.`\n );\n }\n });\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** `filename*=charset'language'percent-encoded`, the RFC 8187 form. */\nconst EXTENDED = /(?:^|;)\\s*filename\\*\\s*=\\s*([^;]+)/i;\n\n/** `filename=\"quoted\"` or `filename=token`. `filename*` does not match: the star is not whitespace. */\nconst PLAIN = /(?:^|;)\\s*filename\\s*=\\s*(?:\"((?:[^\"\\\\]|\\\\.)*)\"|([^;]*))/i;\n\nfunction decodeExtended(raw: string): string | null {\n const value = raw.trim().replace(/^\"(.*)\"$/, '$1');\n const match = /^([^']*)'[^']*'(.*)$/.exec(value);\n if (!match) return null;\n const charset = match[1].toLowerCase();\n const encoded = match[2];\n try {\n if (charset === 'utf-8' || charset === '') return decodeURIComponent(encoded);\n if (charset === 'iso-8859-1' || charset === 'latin1') {\n return encoded.replace(/%([0-9a-f]{2})/gi, (_, hex: string) => String.fromCharCode(Number.parseInt(hex, 16)));\n }\n } catch {\n // A malformed percent sequence: fall through to the plain parameter.\n }\n return null;\n}\n\n/**\n * Reads the file name a `Content-Disposition` header carries, or `null` when\n * it carries none.\n *\n * `filename*` wins over `filename` when both are present, as RFC 6266 asks;\n * its value is percent-decoded. A `filename*` that cannot be decoded falls back\n * to the plain `filename`. Parameter names are case-insensitive; a quoted\n * `filename` has its backslash escapes removed.\n *\n * @example\n * ```ts\n * wrContentDispositionFileName(response.headers.get('Content-Disposition'));\n *\n * wrContentDispositionFileName('attachment; filename=\"report.csv\"');\n * // 'report.csv'\n * wrContentDispositionFileName(\"attachment; filename*=UTF-8''%E2%82%AC.csv\");\n * // '€.csv'\n * wrContentDispositionFileName('inline');\n * // null\n * ```\n *\n * @param header - The header value, or what `Headers.get()` returned.\n * @returns The file name, or `null`.\n */\nexport function wrContentDispositionFileName(header: string | null | undefined): string | null {\n if (!header) return null;\n\n const extended = EXTENDED.exec(header);\n if (extended) {\n const decoded = decodeExtended(extended[1]);\n if (decoded) return decoded;\n }\n\n const plain = PLAIN.exec(header);\n if (!plain) return null;\n const name = plain[1] !== undefined ? plain[1].replace(/\\\\(.)/g, '$1') : plain[2].trim();\n return name || null;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/**\n * Safari starts the download after `click()` returns, so a revoke in the same\n * tick hands it a dead URL. One second covers the gap with room to spare.\n */\nconst REVOKE_DELAY_MS = 1000;\n\n/**\n * Saves `blob` as a file named `fileName`, through a temporary anchor and an\n * object URL.\n *\n * SSR-safe: a no-op without a `document`. The anchor is appended for the\n * click, which Firefox needs, and removed right after. The object URL is\n * revoked on a timer rather than synchronously, which Safari needs.\n *\n * @example\n * ```ts\n * const csv = new Blob([text], { type: 'text/csv;charset=utf-8;' });\n * wrDownloadBlob(csv, 'report.csv');\n * ```\n *\n * @param blob - The data to save.\n * @param fileName - The name the browser offers in its save dialog.\n */\nexport function wrDownloadBlob(blob: Blob, fileName: string): void {\n if (typeof document === 'undefined' || typeof URL.createObjectURL !== 'function') return;\n\n const url = URL.createObjectURL(blob);\n const link = document.createElement('a');\n link.href = url;\n link.download = fileName;\n document.body.appendChild(link);\n link.click();\n link.remove();\n setTimeout(() => URL.revokeObjectURL(url), REVOKE_DELAY_MS);\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/**\n * Reads the root font size (in pixels) from\n * `getComputedStyle(document.documentElement).fontSize`.\n *\n * Typical use case: converting `rem` values to pixels for layout calculations.\n *\n * Falls back to the provided value when:\n * - DOM is not available (SSR);\n * - `getComputedStyle` fails or returns an unparseable value.\n *\n * @example\n * ```ts\n * const rootFontSize = wrGetRootFontSize(); // e.g. 16\n * const customFallback = wrGetRootFontSize(14); // uses 14 if DOM is unavailable\n * ```\n *\n * @param fallback - Value in pixels when DOM is unavailable. Defaults to `16`.\n * @returns Root font size in pixels.\n */\nexport function wrGetRootFontSize(fallback = 16): number {\n try {\n if (typeof window === 'undefined' || typeof document === 'undefined') {\n return fallback;\n }\n\n const raw = window.getComputedStyle(document.documentElement).fontSize;\n const parsed = Number.parseFloat(raw);\n\n return Number.isFinite(parsed) ? parsed : fallback;\n } catch {\n return fallback;\n }\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport type { FocusMonitor } from '@angular/cdk/a11y';\n\nconst FOCUSABLE_SELECTOR = [\n 'a[href]',\n 'area[href]',\n 'button:not([disabled])',\n 'input:not([disabled]):not([type=\"hidden\"])',\n 'select:not([disabled])',\n 'textarea:not([disabled])',\n 'iframe',\n 'object',\n 'embed',\n 'audio[controls]',\n 'video[controls]',\n '[contenteditable]:not([contenteditable=\"false\"])',\n '[tabindex]:not([tabindex=\"-1\"])',\n].join(',');\n\n/**\n * Is `el` rendered? A layout test, not a style one: `getClientRects()` is empty\n * for `display: none` on the element OR on any ancestor, and non-empty for\n * everything that has a box — `position: fixed` included.\n *\n * It used to be `offsetParent !== null`, which is almost the same test and\n * wrong in one direction that matters here: a `position: fixed` element has no\n * offset parent at all, so every control inside a fixed panel — the one shape a\n * focus trap is most often wrapped around — was dropped as if it were hidden.\n *\n * `visibility: hidden` keeps its box, so it needs its own read. It is checked\n * second because it is the expensive one, and `getClientRects()` already\n * rejects the common case.\n */\nfunction isRendered(el: HTMLElement): boolean {\n if (el.getClientRects().length === 0) return false;\n return el.ownerDocument.defaultView?.getComputedStyle(el).visibility !== 'hidden';\n}\n\n/**\n * Return every focusable descendant of `root`, in DOM ORDER — not in tab order.\n * A positive `tabindex` is not reordered, because a trap that honoured it would\n * disagree with the browser about what Tab does for everything outside the trap;\n * APG says not to use positive values at all.\n *\n * Elements with no box are dropped (see `isRendered`), except the one that\n * currently has focus: a trap must still be able to find where it is standing,\n * and an element can be focused and then hidden by the same interaction.\n */\nexport function wrGetFocusableElements(root: HTMLElement): readonly HTMLElement[] {\n return Array.from(root.querySelectorAll<HTMLElement>(FOCUSABLE_SELECTOR)).filter(\n el => isRendered(el) || el === document.activeElement\n );\n}\n\n/**\n * Trap Tab navigation inside `root` for a keyboard event — call from a\n * `keydown` handler. Cycles focus from first ↔ last focusable element.\n * Returns `true` when focus was redirected (event was handled).\n */\nexport function wrTrapFocus(root: HTMLElement, event: KeyboardEvent): boolean {\n if (event.key !== 'Tab') return false;\n const focusable = wrGetFocusableElements(root);\n if (focusable.length === 0) return false;\n\n const first = focusable[0];\n const last = focusable[focusable.length - 1];\n const active = document.activeElement as HTMLElement | null;\n\n if (event.shiftKey && active === first) {\n event.preventDefault();\n last.focus();\n return true;\n }\n if (!event.shiftKey && active === last) {\n event.preventDefault();\n first.focus();\n return true;\n }\n return false;\n}\n\n/**\n * Hand focus back to `el` after something closed, as a PROGRAMMATIC focus.\n *\n * A plain `el.focus()` after Escape reads to the CDK `FocusMonitor` as keyboard\n * focus, because the last input was a key, and anything that reacts to keyboard\n * origin (a tooltip on the trigger) then treats the restore as the user tabbing\n * there. `focusVia(el, 'program')` reports the truth. Without a monitor it is a\n * plain `focus()`.\n */\nexport function wrRestoreFocus(el: HTMLElement, monitor?: FocusMonitor | null): void {\n if (monitor) monitor.focusVia(el, 'program');\n else el.focus();\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/**\n * Probes one element keeps alive at a time, one per expression. Generous for\n * what a component draws with — aurora resolves three stops, waves and\n * click-spark one colour each — and a bound on a caller that resolves a fresh\n * string every frame, where the oldest probe is retired instead of piling up.\n */\nconst MAX_PROBES = 8;\n\n/** `var()` hops the fallback chain follows before it gives up on a reference cycle. */\nconst MAX_HOPS = 8;\n\n/** A whole expression that is one `var(--name)` or `var(--name, fallback)`. */\nconst LONE_VAR = /^var\\(\\s*(--[\\w-]+)\\s*(?:,\\s*([\\s\\S]*?))?\\s*\\)$/;\n\nconst probes = new WeakMap<Element, Map<string, HTMLElement>>();\n\n/**\n * The probe holding `expression` inside `context`, appended on first use.\n *\n * The colour is written ONCE, when the probe is made, so a caller that resolves\n * every frame only ever reads: an inline-style write invalidates style, and\n * doing it per frame would recalculate the probe on every one of them.\n */\nfunction probeFor(context: Element, expression: string): HTMLElement {\n let byExpression = probes.get(context);\n if (!byExpression) {\n byExpression = new Map();\n probes.set(context, byExpression);\n }\n\n const kept = byExpression.get(expression);\n // A template that re-rendered the context's children takes the probe with\n // it, and a detached element computes nothing.\n if (kept?.parentNode === context) return kept;\n\n const probe = context.ownerDocument.createElement('span');\n probe.style.display = 'none';\n probe.style.color = expression;\n context.appendChild(probe);\n byExpression.set(expression, probe);\n\n if (byExpression.size > MAX_PROBES) {\n const [oldest, element] = byExpression.entries().next().value!;\n element.remove();\n byExpression.delete(oldest);\n }\n return probe;\n}\n\n/** The probe's computed colour, or `null` when the engine refused or did not resolve it. */\nfunction computedColor(view: Window, probe: HTMLElement): string | null {\n // An expression the parser refused never reaches the inline style at all, and\n // the probe would quietly report the colour it inherits instead.\n if (probe.style.color === '') return null;\n const color = view.getComputedStyle(probe).color;\n // A browser always substitutes; jsdom hands a `var()` back verbatim.\n return color !== '' && !color.includes('var(') ? color : null;\n}\n\n/**\n * A colour string as 0–1 sRGB channels with its alpha dropped, or `null` for a\n * form this does not read.\n *\n * A computed colour comes back in one of two shapes — `rgb()` / `rgba()` with\n * 0–255 channels for a legacy colour, `color(srgb r g b / a)` with 0–1 channels\n * for a `color-mix()` — and neither is hex, the one form the first WebGL caller\n * parsed, which turned a `light-dark()` hook into `NaN` uniforms. Hex and\n * percentages stay for the literal fallback a caller names: no computed value\n * carries either, and a fallback reaches this unresolved.\n */\nfunction parseChannels(color: string): [number, number, number] | null {\n const value = color.trim().toLowerCase();\n const fn = /^(rgba?|color)\\(\\s*(srgb\\s+)?([^)]*)\\)$/.exec(value);\n if (fn && (fn[1] !== 'color' || fn[2] !== undefined)) {\n const scale = fn[1] === 'color' ? 1 : 255;\n const channels = fn[3]\n .split(/[\\s,/]+/)\n .slice(0, 3)\n .map(part => {\n if (part === 'none') return 0;\n return Number.parseFloat(part) / (part.endsWith('%') ? 100 : scale);\n });\n if (channels.length !== 3 || !channels.every(Number.isFinite)) return null;\n return channels.map(channel => Math.min(1, Math.max(0, channel))) as [number, number, number];\n }\n const hex = /^#([\\da-f]{3,4}|[\\da-f]{6}|[\\da-f]{8})$/.exec(value)?.[1];\n if (hex === undefined) return null;\n const full = hex.length <= 4 ? [...hex].map(digit => digit + digit).join('') : hex;\n return [0, 2, 4].map(at => Number.parseInt(full.slice(at, at + 2), 16) / 255) as [number, number, number];\n}\n\n/**\n * Resolves a CSS colour expression against an element to the colour the cascade\n * computes for it, which a canvas can paint with: `rgb(…)` / `rgba(…)` for a\n * legacy colour, `color(srgb r g b / a)` (channels 0–1) for a `color-mix()`\n * result. A colour authored in another space — `oklch()`, `lab()` — computes\n * to itself; a caller that needs numbers wants {@link wrResolveCssColorChannels},\n * which reads all of these.\n *\n * A 2D context and a WebGL uniform cannot read CSS: a `var()` is refused\n * outright, and so is `light-dark()` — except in Firefox, which accepts it and\n * always paints the LIGHT colour, whatever scheme the page is in. Reading the\n * custom property does not help either, because `getPropertyValue()` returns\n * the declared text, `light-dark(…)` and all, never a resolved colour. What\n * does resolve it is the cascade itself, so this sets the expression as the\n * `color` of a hidden probe inside `context` and reads the probe's computed\n * value back. The probe inherits from `context`, so custom properties and the\n * colour scheme resolve exactly as they would for the element itself —\n * including a subtree that sets its own `color-scheme`.\n *\n * Pass the element whose children are never painted when there is one — a\n * `<canvas>` is ideal, and its fallback content is where the probe goes. One\n * `display: none` span is appended per expression and kept for the next call,\n * so resolving the same expression every frame costs a style read, not a DOM\n * write.\n *\n * Returns `fallback` when nothing can be resolved: the expression does not\n * parse as a colour, it is a lone `var()` holding something that is not a colour or\n * naming a property set nowhere with no fallback of its own (CSS itself would hand\n * the probe its inherited colour, which reads as a choice the author never made), or\n * the element has no style engine behind it. A `var()` inside another function —\n * `light-dark()`, `color-mix()`, the fallback of another `var()` — is CSS's to\n * substitute, and with its name unset or holding no colour still reads the inherited\n * colour; so does `var(--x, 12px)`, whose own fallback is no colour. Where the\n * computed read hands a `var()` back unresolved — jsdom does, a browser never does —\n * a lone `var()` is looked up with `getPropertyValue()` and the result resolved in\n * its turn, so a unit test still sees the colour a token holds.\n *\n * Browser only: call it from `afterNextRender` or a frame callback, never\n * during a server render.\n *\n * @example\n * ```ts\n * const canvas = this.canvasRef().nativeElement;\n * ctx.strokeStyle = wrResolveCssColor(canvas, 'var(--wr-color-on-surface)', '#0f172a');\n * ```\n *\n * @param context - Element to resolve against; the probe is appended inside it.\n * @param expression - Any CSS colour: a literal, `var()`, `light-dark()`, `color-mix()`.\n * @param fallback - Returned as-is when the expression cannot be resolved.\n * @returns The computed colour, or `fallback`.\n */\nexport function wrResolveCssColor(context: Element, expression: string, fallback: string): string {\n const view = context.ownerDocument.defaultView;\n if (!view) return fallback;\n\n try {\n let value = expression.trim();\n for (let hop = 0; hop < MAX_HOPS && value !== ''; hop++) {\n const ref = LONE_VAR.exec(value);\n const declared = ref ? view.getComputedStyle(context).getPropertyValue(ref[1]).trim() : '';\n if (ref && declared === '' && ref[2] === undefined) return fallback;\n // A browser's computed custom property has its own `var()` substituted already,\n // so this is the text the probe would be handed. Its own parser rather than\n // `CSS.supports`, which no jsdom before 30 has and no quirks document agrees with.\n if (ref && declared !== '' && probeFor(context, declared).style.color === '') return fallback;\n\n const color = computedColor(view, probeFor(context, value));\n if (color !== null) return color;\n if (!ref) break;\n value = declared || (ref[2] ?? '').trim();\n }\n } catch {\n // A detached view or a DOM with no style engine behind it.\n }\n return fallback;\n}\n\n/**\n * Resolves a CSS colour expression against an element to 0–1 sRGB channels, with\n * the alpha dropped, for what takes numbers rather than a string: a WebGL `vec3`\n * uniform, above all.\n *\n * {@link wrResolveCssColor} does the cascade, so a `var()`, a `light-dark()` and a\n * `color-mix()` all resolve as they would for the element itself, and this reads\n * the result: `rgb()`, `rgba()` and `color(srgb …)`, with `none` as 0 and every\n * channel clamped to 0–1, so a `color-mix()` from a wider gamut stays in range. A\n * colour authored in another space — `oklch()`, `lab()`, `display-p3` — computes\n * to itself, and mixing it into sRGB is what brings it to a form this reads.\n *\n * Total: it always returns three finite channels. When {@link wrResolveCssColor}\n * cannot resolve the expression it reads `fallback`, a literal colour in any form\n * CSS parses, hex included; when that cannot be read either, it returns\n * `[0, 0, 0]`, so a uniform never receives a `NaN`.\n *\n * It costs what {@link wrResolveCssColor} costs plus a parse, so a caller drawing\n * every frame can hold on to the string that function returns and call this only\n * when it changes.\n *\n * Browser only: call it from `afterNextRender` or a frame callback, never during\n * a server render.\n *\n * @example\n * ```ts\n * const canvas = this.canvasRef().nativeElement;\n * const [r, g, b] = wrResolveCssColorChannels(canvas, 'var(--wr-color-primary)', '#3969e2');\n * gl.uniform3f(this.tint, r, g, b);\n * ```\n *\n * @param context - Element to resolve against; a hidden probe is appended inside it.\n * @param expression - Any CSS colour: a literal, `var()`, `light-dark()`, `color-mix()`.\n * @param fallback - The literal colour to read when the expression cannot be resolved.\n * @returns The red, green and blue channels, each 0–1.\n */\nexport function wrResolveCssColorChannels(\n context: Element,\n expression: string,\n fallback: string\n): [number, number, number] {\n const read = (color: string): [number, number, number] | null =>\n parseChannels(color) ??\n parseChannels(wrResolveCssColor(context, `color-mix(in srgb, ${color} 100%, transparent)`, ''));\n\n return read(wrResolveCssColor(context, expression, fallback)) ?? read(fallback) ?? [0, 0, 0];\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport {\n DOCUMENT,\n DestroyRef,\n type Injector,\n PLATFORM_ID,\n type ProviderToken,\n assertInInjectionContext,\n inject,\n} from '@angular/core';\n\n/** The query `light dark` resolves through when the page leaves the choice to the OS. */\nconst DARK_QUERY = '(prefers-color-scheme: dark)';\n\n/**\n * What one `color-scheme` value resolves to, or `null` when it does not decide:\n * `normal`, empty, or nothing this reads. `light dark` (either order, `only`\n * included) is the OS's call.\n */\nfunction pick(value: string, osDark: boolean): WrColorScheme | null {\n const tokens = value.trim().toLowerCase().split(/\\s+/);\n const light = tokens.includes('light');\n const dark = tokens.includes('dark');\n if (light && dark) return osDark ? 'dark' : 'light';\n if (dark) return 'dark';\n if (light) return 'light';\n return null;\n}\n\n/**\n * The scheme `<html>` resolves to: its computed `color-scheme` first, which is\n * what an inline write, a class, an attribute selector and the theme's own\n * `light dark` all land on; then `<meta name=\"color-scheme\">`, which is what a\n * computed `normal` defers to; then light, the browser's default.\n */\nfunction resolveScheme(doc: Document, query: MediaQueryList | null): WrColorScheme {\n const osDark = query?.matches ?? false;\n const view = doc.defaultView;\n const declared = view ? view.getComputedStyle(doc.documentElement).getPropertyValue('color-scheme') : '';\n const meta = doc.querySelector<HTMLMetaElement>('meta[name=\"color-scheme\"]')?.content ?? '';\n return pick(declared, osDark) ?? pick(meta, osDark) ?? 'light';\n}\n\n/** The colour scheme a page resolves to: what `light-dark()` picks on its root. */\nexport type WrColorScheme = 'light' | 'dark';\n\n/** Options for {@link wrWatchColorScheme}. */\nexport interface WrWatchColorSchemeOptions {\n /**\n * The injector to take `DestroyRef`, `DOCUMENT` and `PLATFORM_ID` from, for\n * a call made outside an injection context — from `afterNextRender`, say.\n * The watch then ends when that injector is destroyed.\n */\n readonly injector?: Injector;\n}\n\n/**\n * Calls `callback` with the new scheme whenever the colour scheme the page\n * resolves to changes, and never for a change that leaves it where it was.\n *\n * A canvas or a WebGL uniform cannot take `light-dark()` or a `var()`, so a\n * drawing resolves its colours once, through {@link wrResolveCssColor}, and holds\n * pixels from then on. A frame loop repaints anyway; a still frame — the one a\n * reduced-motion visitor gets — keeps the old scheme's colours until something\n * asks it to redraw. This is that something.\n *\n * Two sources move the root scheme, and it listens to both: an attribute change\n * on `<html>`, which is where `WrTheme` writes its inline `color-scheme` (and\n * where a class or a `data-` attribute an app themes on lives), and\n * `prefers-color-scheme`, which decides it while the page says `light dark`.\n * Each is read back through the computed `color-scheme`, so a write that does\n * not change the outcome — CDK's scroll blocking styles `<html>` too — calls\n * nothing.\n *\n * It watches the ROOT. A subtree with a `color-scheme` of its own resolves on\n * its own terms, and a stylesheet that arrives later and re-declares the root's\n * scheme is not an attribute change; neither is seen.\n *\n * SSR-safe: on the server it does nothing and returns a no-op. Stops when the\n * injection context it was called in is destroyed, or when the returned\n * function is called.\n *\n * @example\n * ```ts\n * constructor() {\n * afterNextRender(() => this.draw());\n * wrWatchColorScheme(() => this.draw());\n * }\n *\n * private draw(): void {\n * const canvas = this.canvas().nativeElement;\n * const ctx = canvas.getContext('2d');\n * if (!ctx) return;\n * ctx.fillStyle = wrResolveCssColor(canvas, 'var(--wr-color-primary)', '#3969e2');\n * ctx.fillRect(0, 0, canvas.width, canvas.height);\n * }\n * ```\n *\n * @param callback - Receives the scheme now in effect on `<html>`.\n * @param options - An injector, for a call outside an injection context.\n * @returns A function that stops watching early.\n */\nexport function wrWatchColorScheme(\n callback: (scheme: WrColorScheme) => void,\n options: WrWatchColorSchemeOptions = {}\n): () => void {\n if (!options.injector) assertInInjectionContext(wrWatchColorScheme);\n const injector = options.injector;\n const get = <T>(token: ProviderToken<T>): T => (injector ? injector.get(token) : inject(token));\n\n if (get(PLATFORM_ID) !== 'browser') return () => undefined;\n const doc = get(DOCUMENT);\n const view = doc.defaultView;\n if (!view) return () => undefined;\n\n const query = typeof view.matchMedia === 'function' ? view.matchMedia(DARK_QUERY) : null;\n let current = resolveScheme(doc, query);\n const check = (): void => {\n const next = resolveScheme(doc, query);\n if (next === current) return;\n current = next;\n callback(next);\n };\n\n const observer = typeof MutationObserver === 'undefined' ? null : new MutationObserver(check);\n observer?.observe(doc.documentElement, { attributes: true });\n query?.addEventListener('change', check);\n\n let stopped = false;\n const stop = (): void => {\n if (stopped) return;\n stopped = true;\n observer?.disconnect();\n query?.removeEventListener('change', check);\n };\n get(DestroyRef).onDestroy(stop);\n return stop;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/**\n * CDK's `cdkDrag` has no cancel: a pointer drag ends on the release event of the\n * input that started it, and the drop always reorders. This listens for Escape\n * on the document and, when it comes, ends the drag the way the CDK ends it, so\n * the preview flies back and `cdkDragEnded` still fires.\n *\n * The release is `touchend` for a touch start and `mouseup` for a mouse start,\n * the two events the CDK's drag registry binds on the document. The caller marks\n * the drag cancelled in `onCancel`, which runs before the release, so the drop\n * handler that follows can ignore it. Escape is prevented and stopped (capture\n * phase) so a dialog around the drag does not close on the same key.\n *\n * Call it from `cdkDragStarted` and call the returned function from\n * `cdkDragEnded` and on destroy; the listener lives no longer than that.\n *\n * @internal Shared by the entry points; not a consumer API.\n * @param doc The document the drag runs in.\n * @param start The event the drag started with, `CdkDragStart.event`.\n * @param onCancel Runs once when Escape cancels the drag.\n * @returns Removes the listener. Safe to call twice.\n */\nexport function wrWatchDragCancel(doc: Document, start: Event, onCancel: () => void): () => void {\n const touch = start.type.startsWith('touch');\n const stop = (): void => doc.removeEventListener('keydown', onKeydown, true);\n\n function onKeydown(event: KeyboardEvent): void {\n if (event.key !== 'Escape') return;\n event.preventDefault();\n event.stopPropagation();\n stop();\n onCancel();\n if (touch) {\n // The CDK reads `targetTouches` and `changedTouches` off a touch release.\n const end = new Event('touchend', { bubbles: true, cancelable: true });\n Object.assign(end, { targetTouches: [], changedTouches: [] });\n doc.dispatchEvent(end);\n } else {\n doc.dispatchEvent(new MouseEvent('mouseup', { bubbles: true, cancelable: true }));\n }\n }\n\n doc.addEventListener('keydown', onKeydown, true);\n return stop;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { wrGetRootFontSize } from '../dom';\n\nimport type { WrResolveCssSizeOptions } from './resolve-css-size-options';\nimport type { WrResolvedCssSize } from './resolved-css-size';\n\n/**\n * Resolves a raw size value into a CSS string and an optional pixel equivalent.\n *\n * Supported formats:\n * - `number` → pixels (`48` → `\"48px\"`)\n * - `\"12px\"` → pixels (`\"12px\"` → `\"12px\"`)\n * - `\"3rem\"` → rems via root (`\"3rem\"` → `\"3rem\"`, pxValue = 3 × root font size)\n * - `\"80%\"` → percentage (`\"80%\"` → `\"80%\"`, pxValue = null)\n * - `\"15\"` → pixels (`\"15\"` → `\"15px\"`)\n * - anything else → passed through as-is, pxValue = null\n *\n * @example\n * ```ts\n * const size = wrResolveCssSize('3rem', { defaultValue: '6rem' });\n * // size.cssValue === '3rem'\n * // size.pxValue === 3 * wrGetRootFontSize()\n * ```\n *\n * @param raw - Value to resolve. Accepts numbers, pixel/rem/percent strings, or `null`/`undefined`.\n * @param options - Optional configuration.\n * @returns Resolved CSS value and its pixel equivalent when computable.\n *\n * @see {@link WrResolvedCssSize}\n * @see {@link WrResolveCssSizeOptions}\n */\nexport function wrResolveCssSize(raw: unknown, options: WrResolveCssSizeOptions = {}): WrResolvedCssSize {\n const rootFontSize = wrGetRootFontSize();\n const value: unknown = raw ?? options.defaultValue;\n\n if (value == null) {\n return { cssValue: '0px', pxValue: 0 };\n }\n\n if (typeof value === 'number' && Number.isFinite(value)) {\n return { cssValue: `${value}px`, pxValue: value };\n }\n\n if (typeof value !== 'string') {\n return { cssValue: '0px', pxValue: 0 };\n }\n\n const trimmed = value.trim();\n\n const remMatch = /^([\\d.]+)\\s*rem$/i.exec(trimmed);\n if (remMatch) {\n const rem = Number.parseFloat(remMatch[1]);\n const px = rem * rootFontSize;\n return { cssValue: `${rem}rem`, pxValue: Number.isFinite(px) ? px : null };\n }\n\n const pxMatch = /^([\\d.]+)\\s*px$/i.exec(trimmed);\n if (pxMatch) {\n const px = Number.parseFloat(pxMatch[1]);\n return { cssValue: `${px}px`, pxValue: Number.isFinite(px) ? px : null };\n }\n\n const percentMatch = /^([\\d.]+)\\s*%$/.exec(trimmed);\n if (percentMatch) {\n return { cssValue: `${percentMatch[1]}%`, pxValue: null };\n }\n\n const numberMatch = /^([\\d.]+)$/.exec(trimmed);\n if (numberMatch) {\n const px = Number.parseFloat(numberMatch[1]);\n return { cssValue: `${px}px`, pxValue: Number.isFinite(px) ? px : null };\n }\n\n return { cssValue: trimmed, pxValue: null };\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nconst ALPHABET = 'abcdefghijklmnopqrstuvwxyz0123456789';\nconst MIN_LENGTH = 4;\nconst MAX_LENGTH = 64;\nconst DEFAULT_LENGTH = 12;\n\n/**\n * Returns random bytes using the best available source.\n *\n * @internal\n */\nfunction defaultRandomBytes(count: number): Uint8Array {\n // Covers: all browsers, Node ≥ 18, Deno, Bun, Cloudflare Workers\n if (typeof crypto !== 'undefined' && typeof crypto.getRandomValues === 'function') {\n return crypto.getRandomValues(new Uint8Array(count));\n }\n\n // Fallback: Node < 18 or exotic runtimes\n const buf = new Uint8Array(count);\n for (let i = 0; i < count; i++) {\n buf[i] = Math.floor(Math.random() * 256);\n }\n return buf;\n}\n\n/**\n * Generates a pseudo-random, DOM-safe identifier.\n *\n * Produced ids:\n * - are prefixed to avoid collisions with host-application ids;\n * - contain only `[a-z0-9-]` characters;\n * - use `crypto.getRandomValues` when available, falling back to `Math.random`.\n *\n * **Not suitable for cryptographic or security-sensitive purposes** —\n * intended only for UI element identifiers (`id`, `for`, `aria-*`, etc.).\n *\n * @example\n * ```ts\n * wrRandomId();\n * // → \"wr-a8f2bx1k9q4z\"\n *\n * wrRandomId('ng', 8);\n * // → \"ng-k2f9mbeo\"\n *\n * wrRandomId('wr', 24);\n * // → \"wr-a8f2bx1k9q4zmneo73wplr\"\n * ```\n *\n * @param prefix - Namespace prefix prepended before the random segment. Defaults to `'wr'`.\n * @param length - Length of the random segment. Clamped to `[4, 64]`. Defaults to `12`.\n * @param random - Custom random byte source `(byteLength) => Uint8Array`.\n * When omitted, uses `crypto.getRandomValues` with a `Math.random` fallback.\n * @returns A pseudo-random id string matching `/^[a-z]+-[a-z0-9]+$/`.\n */\nexport function wrRandomId(\n prefix = 'wr',\n length = DEFAULT_LENGTH,\n random?: (byteLength: number) => Uint8Array\n): string {\n const safeLength = Math.min(Math.max(Math.trunc(length), MIN_LENGTH), MAX_LENGTH);\n\n const bytes = random ? random(safeLength) : defaultRandomBytes(safeLength);\n\n let result = '';\n for (let i = 0; i < safeLength; i++) {\n result += ALPHABET[bytes[i] % ALPHABET.length];\n }\n\n return `${prefix}-${result}`;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/**\n * A function that does nothing.\n *\n * Useful as a default callback, placeholder event handler,\n * or to explicitly signal intentional no-ops.\n *\n * @example\n * ```ts\n * @Component({ ... })\n * export class MyComponent {\n * onTouched: () => void = noop;\n * }\n * ```\n */\nexport const wrNoop = (): void => undefined;\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\n/** A debounced function — same signature as the original plus `cancel`. */\nexport type WrDebouncedFn<TArgs extends readonly unknown[]> = ((...args: TArgs) => void) & {\n readonly cancel: () => void;\n};\n\n/**\n * Wrap `fn` so it only fires `waitMs` after the last invocation.\n * Useful for resize / scroll / input handlers.\n *\n * @example\n * ```ts\n * const onResize = wrDebounce(() => recalcLayout(), 150);\n * window.addEventListener('resize', onResize);\n * ```\n */\nexport function wrDebounce<TArgs extends readonly unknown[]>(\n fn: (...args: TArgs) => void,\n waitMs: number\n): WrDebouncedFn<TArgs> {\n let timer: ReturnType<typeof setTimeout> | null = null;\n\n const debounced = (...args: TArgs): void => {\n if (timer !== null) clearTimeout(timer);\n timer = setTimeout(() => {\n timer = null;\n fn(...args);\n }, waitMs);\n };\n\n debounced.cancel = (): void => {\n if (timer !== null) {\n clearTimeout(timer);\n timer = null;\n }\n };\n\n return debounced;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** A throttled function — same signature as the original plus `cancel`. */\nexport type WrThrottledFn<TArgs extends readonly unknown[]> = ((...args: TArgs) => void) & {\n readonly cancel: () => void;\n};\n\n/**\n * Wrap `fn` so it fires at most once every `waitMs`. Leading-edge call\n * fires immediately; trailing-edge call fires once at the end of the window\n * if there were further invocations.\n */\nexport function wrThrottle<TArgs extends readonly unknown[]>(\n fn: (...args: TArgs) => void,\n waitMs: number\n): WrThrottledFn<TArgs> {\n let lastInvoke = 0;\n let trailingTimer: ReturnType<typeof setTimeout> | null = null;\n let pendingArgs: TArgs | null = null;\n\n const throttled = (...args: TArgs): void => {\n const now = Date.now();\n const remaining = waitMs - (now - lastInvoke);\n\n if (remaining <= 0) {\n if (trailingTimer !== null) {\n clearTimeout(trailingTimer);\n trailingTimer = null;\n }\n lastInvoke = now;\n fn(...args);\n } else {\n pendingArgs = args;\n trailingTimer ??= setTimeout(() => {\n lastInvoke = Date.now();\n trailingTimer = null;\n if (pendingArgs) fn(...pendingArgs);\n pendingArgs = null;\n }, remaining);\n }\n };\n\n throttled.cancel = (): void => {\n if (trailingTimer !== null) {\n clearTimeout(trailingTimer);\n trailingTimer = null;\n }\n pendingArgs = null;\n lastInvoke = 0;\n };\n\n return throttled;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/**\n * Canonical `KeyboardEvent.key` values for your own `keydown` handlers.\n *\n * The spec spellings are easy to get wrong — arrows are `ArrowUp`, space is a\n * literal `' '` — and a typo like `'Esacpe'` never matches and never errors.\n * These give you autocomplete and the {@link WrKey} union to match against.\n */\nexport const WR_KEYS = {\n ENTER: 'Enter',\n ESCAPE: 'Escape',\n TAB: 'Tab',\n SPACE: ' ',\n BACKSPACE: 'Backspace',\n DELETE: 'Delete',\n ARROW_UP: 'ArrowUp',\n ARROW_DOWN: 'ArrowDown',\n ARROW_LEFT: 'ArrowLeft',\n ARROW_RIGHT: 'ArrowRight',\n HOME: 'Home',\n END: 'End',\n PAGE_UP: 'PageUp',\n PAGE_DOWN: 'PageDown',\n CONTROL: 'Control',\n SHIFT: 'Shift',\n ALT: 'Alt',\n META: 'Meta',\n} as const;\n\nexport type WrKey = (typeof WR_KEYS)[keyof typeof WR_KEYS];\n\n/**\n * What each key in {@link WR_KEYS} is called on a PC keycap, for a shortcut hint\n * or a cheat sheet: `Esc`, `Enter`, `Ctrl`, an arrow as its glyph. English, the\n * way the keys are printed: `wr-kbd` reads the words from the i18n catalog\n * instead. `wrFormatChord` in `ngwr/hotkey` prints a whole chord from these and\n * swaps in Apple's glyphs (`⌘`, `⇧`, `↩`) on macOS.\n */\nexport const WR_KEY_LABELS: Readonly<Record<WrKey, string>> = {\n [WR_KEYS.ENTER]: 'Enter',\n [WR_KEYS.ESCAPE]: 'Esc',\n [WR_KEYS.TAB]: 'Tab',\n [WR_KEYS.SPACE]: 'Space',\n [WR_KEYS.BACKSPACE]: 'Backspace',\n [WR_KEYS.DELETE]: 'Delete',\n [WR_KEYS.ARROW_UP]: '↑',\n [WR_KEYS.ARROW_DOWN]: '↓',\n [WR_KEYS.ARROW_LEFT]: '←',\n [WR_KEYS.ARROW_RIGHT]: '→',\n [WR_KEYS.HOME]: 'Home',\n [WR_KEYS.END]: 'End',\n [WR_KEYS.PAGE_UP]: 'Page Up',\n [WR_KEYS.PAGE_DOWN]: 'Page Down',\n [WR_KEYS.CONTROL]: 'Ctrl',\n [WR_KEYS.SHIFT]: 'Shift',\n [WR_KEYS.ALT]: 'Alt',\n [WR_KEYS.META]: 'Win',\n};\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** True when any modifier key (Ctrl / Cmd / Alt / Shift / Meta) is held. */\nexport function wrHasModifier(event: KeyboardEvent): boolean {\n return event.ctrlKey || event.altKey || event.metaKey || event.shiftKey;\n}\n\n/**\n * True when the key is a single printable character (letters, digits,\n * punctuation, etc.). Skips function keys, arrows, modifiers, and named\n * keys like `Backspace` or `Tab`.\n */\nexport function wrIsPrintableKey(event: KeyboardEvent): boolean {\n return event.key.length === 1 && !event.ctrlKey && !event.metaKey && !event.altKey;\n}\n\n/**\n * True while an input method is composing — the key belongs to the IME, not to\n * your handler. **Return early on it in every `keydown` handler that reads\n * Enter, Escape or an arrow on, or above, a field that accepts typed text.**\n *\n * A Japanese or Chinese user reaches every character through a conversion. From\n * `compositionstart` until `compositionend` a candidate window is open, and\n * those keys are how it is driven: Enter accepts the candidate, Escape cancels\n * the conversion back to kana, the arrows walk the candidate list. A component\n * that acts on them anyway takes the key away from the IME mid-word — the\n * overlay closes instead of the candidate window, and the half-composed reading\n * the user was still choosing between is gone with it.\n *\n * Both halves of the test are needed. `isComposing` is the standard flag, but\n * Safari fires `compositionend` *before* the `keydown` of the Enter that commits\n * a candidate, so that one arrives with `isComposing === false` and only the\n * legacy `keyCode` of `229` — the sentinel every engine sets on a key it handed\n * to the input method — to say where it came from.\n *\n * `keydown` is the whole scope. It does NOT answer \"is a composition in\n * progress\" for an `input` or `blur` handler: on the committing keystroke the\n * two disagree by design. A component that needs the state *between* events\n * tracks it with the `compositionstart` / `compositionend` pair instead.\n *\n * ```ts\n * protected onKeydown(event: KeyboardEvent): void {\n * if (wrIsComposing(event)) return;\n * // …\n * }\n * ```\n */\nexport function wrIsComposing(event: KeyboardEvent): boolean {\n // `keyCode` is deprecated and stays anyway: it is the only signal Safari\n // leaves on the committing keystroke. See the doc comment above.\n return event.isComposing || event.keyCode === 229;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { wrIsComposing, wrIsPrintableKey } from './predicates';\n\n/** A key typed in a text field is that field's. */\nfunction isTextField(target: EventTarget | null): boolean {\n const el = target as (Partial<HTMLElement> & { tagName?: string }) | null;\n if (!el?.tagName) return false;\n return (\n el.tagName === 'INPUT' || el.tagName === 'TEXTAREA' || el.tagName === 'SELECT' || el.isContentEditable === true\n );\n}\n\n/** Options of {@link wrTypeahead}. */\nexport interface WrTypeaheadOptions {\n /**\n * The pause, in milliseconds, after which the next key starts a new run.\n * @default 500\n */\n readonly resetMs?: number;\n /**\n * The language the labels are written in, as a BCP 47 tag or a function that\n * returns one, for the case folding (`I` and `ı` in Turkish). The browser's\n * own locale when omitted.\n */\n readonly locale?: string | (() => string | undefined);\n}\n\n/** One row of the list a {@link WrTypeahead} searches. */\nexport interface WrTypeaheadItem {\n /** The text the row is matched by. */\n readonly label: string;\n /** A disabled row is never a match. */\n readonly disabled?: boolean;\n}\n\n/** What {@link wrTypeahead} returns. */\nexport interface WrTypeahead {\n /**\n * Feed a `keydown` and get the row to move to: `type()` and `find()` in one\n * call.\n *\n * @returns the index of the match, `-1` when the key joined the run and no row\n * matches it, or `null` when the key is not a typeahead key and the caller's\n * own handling goes on.\n */\n handleKey(event: KeyboardEvent, items: readonly (string | WrTypeaheadItem)[], current: number): number | null;\n /**\n * Add a `keydown` to the run. Returns whether the key was taken: a printable\n * character with no Ctrl, Meta or Alt, outside an IME composition and outside\n * a text field. Space is taken only while a run is active, so it keeps its\n * own job as the first key.\n */\n type(event: KeyboardEvent): boolean;\n /**\n * The row the run points at, or `-1`. One letter, typed once or repeated,\n * looks from the row after `current` and wraps, so the same letter cycles. A\n * longer run looks from `current` itself, so the row it already matches stays.\n */\n find(items: readonly (string | WrTypeaheadItem)[], current: number): number;\n /** Whether a run is in progress: a key was taken less than `resetMs` ago. */\n readonly active: boolean;\n /** Drop the run. */\n reset(): void;\n}\n\n/**\n * Type-to-jump for a list: the letters typed in a row select the next row whose\n * label starts with them, as the WAI-ARIA listbox, menu and tree patterns ask.\n *\n * It holds the letters typed so far and nothing else: the caller passes the\n * labels and the current row with each key, and moves its own cursor to the\n * index that comes back. Matching ignores case, skips disabled rows and wraps\n * past the end.\n *\n * @example\n * ```ts\n * private readonly typeahead = wrTypeahead();\n *\n * protected onKeydown(event: KeyboardEvent): void {\n * const index = this.typeahead.handleKey(event, this.labels(), this.cursor());\n * if (index === null) return this.onOtherKey(event);\n * event.preventDefault();\n * if (index >= 0) this.cursor.set(index);\n * }\n * ```\n */\nexport function wrTypeahead(options: WrTypeaheadOptions = {}): WrTypeahead {\n const resetMs = options.resetMs ?? 500;\n let typed = '';\n let typedAt = 0;\n\n const locale = (): string | undefined => (typeof options.locale === 'function' ? options.locale() : options.locale);\n const fold = (text: string, tag: string | undefined): string => {\n try {\n return text.toLocaleLowerCase(tag);\n } catch {\n // Not a language tag the engine knows.\n return text.toLocaleLowerCase();\n }\n };\n const isActive = (): boolean => typed !== '' && Date.now() - typedAt <= resetMs;\n\n const type = (event: KeyboardEvent): boolean => {\n if (!wrIsPrintableKey(event) || wrIsComposing(event) || isTextField(event.target)) return false;\n const active = isActive();\n if (event.key === ' ' && !active) return false;\n typed = active ? typed + event.key : event.key;\n typedAt = Date.now();\n return true;\n };\n\n const find = (items: readonly (string | WrTypeaheadItem)[], current: number): number => {\n if (typed === '' || items.length === 0) return -1;\n const tag = locale();\n const run = fold(typed, tag);\n const chars = [...run];\n const repeated = chars.every(ch => ch === chars[0]);\n const search = repeated ? chars[0] : run;\n const from = current >= 0 && current < items.length ? current : -1;\n const start = repeated ? from + 1 : Math.max(from, 0);\n for (let step = 0; step < items.length; step++) {\n const index = (start + step) % items.length;\n const item = items[index];\n if (typeof item !== 'string' && item.disabled) continue;\n const label = typeof item === 'string' ? item : item.label;\n if (fold(label.trim(), tag).startsWith(search)) return index;\n }\n return -1;\n };\n\n return {\n handleKey: (event, items, current) => (type(event) ? find(items, current) : null),\n type,\n find,\n get active() {\n return isActive();\n },\n reset: () => {\n typed = '';\n typedAt = 0;\n },\n };\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\n/** The pill the badge loggers share, as a `%c` console style. */\nexport const badgeStyle = (color: string): string => `\n display: inline-block;\n border: 1px solid ${color};\n color: ${color};\n padding: 1px 3px;\n border-radius: 4px;\n margin-right: 0\n `;\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { badgeStyle } from './badge-style';\n\n/**\n * Logs a coloured pill followed by a payload at error level.\n *\n * The same pill as `wrBadgeLog`, through `console.error`, so the message keeps\n * its stack trace and the browser's Errors filter still catches it.\n *\n * @example\n * ```ts\n * wrBadgeError('icons', '#fc6c6c', new Error('plus failed to load'));\n * // → [icons] Error: plus failed to load\n * ```\n *\n * @param badgeText Short label shown inside the pill.\n * @param color CSS colour applied to the pill border and text.\n * @param message Anything you'd pass to `console.error` as the second argument.\n */\nexport function wrBadgeError(badgeText: string, color: string, message: unknown): void {\n // eslint-disable-next-line no-console -- this helper exists to log\n console.error(`%c${badgeText}`, badgeStyle(color), message);\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { badgeStyle } from './badge-style';\n\n/**\n * Logs a coloured pill to the browser console followed by a payload.\n *\n * Useful when you need to scan a noisy console for a specific subsystem's\n * messages. The pill is rendered with the CSS `%c` console formatting trick.\n *\n * @example\n * ```ts\n * wrBadgeLog('icons', '#3969e2', { name: 'plus', registered: true });\n * // → [icons] { name: 'plus', registered: true }\n * ```\n *\n * @param badgeText Short label shown inside the pill.\n * @param color CSS colour applied to the pill border and text.\n * @param message Anything you'd pass to `console.log` as the second argument.\n */\nexport function wrBadgeLog(badgeText: string, color: string, message: unknown): void {\n // eslint-disable-next-line no-console -- this helper exists to log\n console.log(`%c${badgeText}`, badgeStyle(color), message);\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { badgeStyle } from './badge-style';\n\n/**\n * Logs a coloured pill followed by a payload at warning level.\n *\n * The same pill as `wrBadgeLog`, through `console.warn`, so the message keeps\n * its stack trace and the browser's Warnings filter still catches it.\n *\n * @example\n * ```ts\n * wrBadgeWarn('icons', '#fac72e', 'plus is registered twice');\n * // → [icons] plus is registered twice\n * ```\n *\n * @param badgeText Short label shown inside the pill.\n * @param color CSS colour applied to the pill border and text.\n * @param message Anything you'd pass to `console.warn` as the second argument.\n */\nexport function wrBadgeWarn(badgeText: string, color: string, message: unknown): void {\n // eslint-disable-next-line no-console -- this helper exists to log\n console.warn(`%c${badgeText}`, badgeStyle(color), message);\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nlet segmenter: Intl.Segmenter | undefined;\n\n/** A grapheme that can stand for a word: it holds a letter, a digit or a pictograph. */\nconst INITIAL = /[\\p{L}\\p{N}\\p{Extended_Pictographic}]/u;\n\n/** A script whose character is a syllable or a word rather than a letter. */\nconst SYLLABIC = /^[\\p{Script=Han}\\p{Script=Hangul}\\p{Script=Hiragana}\\p{Script=Katakana}]/u;\n\nfunction graphemes(text: string): string[] {\n segmenter ??= new Intl.Segmenter(undefined, { granularity: 'grapheme' });\n return [...segmenter.segment(text)].map(s => s.segment);\n}\n\nfunction initialOf(word: string): string | undefined {\n return graphemes(word).find(g => INITIAL.test(g));\n}\n\nfunction upperCase(initial: string, locale: string | undefined): string {\n const upper = locale === undefined ? initial.toUpperCase() : initial.toLocaleUpperCase(locale);\n return graphemes(upper).length === 1 ? upper : initial;\n}\n\nfunction surname(words: readonly string[], locale: string | undefined, order: WrInitialsOrder): string {\n const parts = words.flatMap(word => {\n const initial = initialOf(word);\n return initial === undefined ? [] : [{ word, initial }];\n });\n const family = order === 'family-first' ? parts.shift() : parts.pop();\n if (family === undefined) return '';\n return [family.word, ...parts.map(part => `${upperCase(part.initial, locale)}.`)].join(' ');\n}\n\n/** How `wrInitials` writes a name: its letters (`RK`), or the family name with initials (`Khegay R.`). */\nexport type WrInitialsStyle = 'letters' | 'surname';\n\n/** The order of the parts in the name given: `Roman Khegay`, or `Хегай Роман`. */\nexport type WrInitialsOrder = 'given-first' | 'family-first';\n\nexport interface WrInitialsOptions {\n /** `'letters'` gives up to two initials; `'surname'` the family name and an initial for each other part. */\n readonly style?: WrInitialsStyle;\n /** Where the family name sits in the input. Read by `'surname'` only. */\n readonly order?: WrInitialsOrder;\n}\n\n/**\n * Up to two initials of a name, one grapheme each, upper-cased.\n *\n * A word is a run between whitespace, so a hyphenated name is one word\n * (`Jean-Luc Picard` gives `JP`). The initial is the first grapheme of the word\n * that holds a letter, a digit or an emoji, so `(Ada)` gives `A` and a word of\n * punctuation alone is skipped. The first two words that yield one are taken:\n * `Ada King Lovelace` gives `AK`, a one-word name gives one initial.\n *\n * A grapheme is what a reader sees as one character: an emoji with a skin tone\n * or a ZWJ sequence, a letter with combining marks and a surrogate pair each\n * count as one initial, never half of one.\n *\n * A Han, Hangul, Hiragana or Katakana name gives ONE initial, its first\n * character: in those scripts a character is a syllable or a word, so two of\n * them read as a word rather than as initials.\n *\n * Upper-casing uses `toUpperCase()` by default, the locale-independent mapping,\n * so the output is the same on the server and the client; pass `locale` for a\n * language whose mapping differs (`tr` turns `i` into `İ`). A letter whose\n * upper case is more than one grapheme (`ß` becomes `SS`) is kept as written.\n *\n * `null`, `undefined`, an empty string and a name with no initial give `''`.\n *\n * `options.style: 'surname'` writes the family name whole, then each other part\n * as its initial and a dot: `Roman Khegay` gives `Khegay R.`. `options.order`\n * says where the family name sits in the input: last for `'given-first'` (the\n * default), so `Ada King Lovelace` gives `Lovelace A. K.`, and first for\n * `'family-first'`, so `Иванов Иван Иванович` gives `Иванов И. И.`. The family\n * name is kept as written, hyphen and case included, and a one-part name comes\n * back as it is. Every part gives an initial, not the first two, each taken and\n * upper-cased as above: a hyphenated given name gives one (`Jean-Luc Picard`\n * gives `Picard J.`) and a part of punctuation alone is dropped before the\n * family name is chosen. The one-initial rule for Han, Hangul and kana does not\n * apply: it keeps two characters from reading as a word, and here the dot\n * already marks an initial, so `王 小明` with `'family-first'` gives `王 小.`.\n *\n * `order` does nothing for `'letters'`, which reads the first two words in the\n * order written.\n *\n * @example\n * ```ts\n * wrInitials('Roman Khegay'); // 'RK'\n * wrInitials(' ada lovelace '); // 'AL'\n * wrInitials('Madonna'); // 'M'\n * wrInitials('王小明'); // '王'\n * wrInitials('👩🏽🚀 Valentina'); // '👩🏽🚀V'\n * wrInitials('...'); // ''\n *\n * wrInitials('Roman Khegay', undefined, { style: 'surname' }); // 'Khegay R.'\n * wrInitials('Хегай Роман', undefined, { style: 'surname', order: 'family-first' }); // 'Хегай Р.'\n * ```\n *\n * @see https://ngwr.dev/reference/utils/wr-initials\n */\nexport function wrInitials(name: string | null | undefined, locale?: string, options?: WrInitialsOptions): string {\n if (name === null || name === undefined) return '';\n const words = String(name).trim().split(/\\s+/u);\n if (options?.style === 'surname') return surname(words, locale, options.order ?? 'given-first');\n let out = '';\n let count = 0;\n for (const word of words) {\n const initial = initialOf(word);\n if (initial === undefined) continue;\n out += upperCase(initial, locale);\n if (++count === 2 || SYLLABIC.test(initial)) break;\n }\n return out;\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { InjectionToken, type Signal } from '@angular/core';\n\n/**\n * The interface language as a signal, for what has to follow a language switch\n * without importing `ngwr/i18n`: `provideWrI18n()` provides it as\n * `WrI18n.locale`, and `ngwr/date` formats in it. Not provided when the app\n * does not call `provideWrI18n()`, so inject it as optional.\n */\nexport const WR_LIVE_LOCALE = new InjectionToken<Signal<string>>('WR_LIVE_LOCALE');\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 type { EnvironmentProviders, Provider } from '@angular/core';\n\n/**\n * One piece of app-wide configuration, passed to `provideWr()` from `ngwr` —\n * the shape Angular gives `RouterFeature` for `provideRouter(routes, withX())`.\n *\n * Each feature is exported by the entry point it configures (`withDensity()`\n * from `ngwr/density`, `withToast()` from `ngwr/toast`, …), so an app bundles\n * only the ones it imports. The type lives here rather than beside\n * `provideWr()` so that no secondary entry point has to import the root one.\n *\n * Both members are private API: build a feature with {@link wrFeature} and read\n * it only inside `provideWr()`.\n */\nexport interface WrFeature<K extends string = string> {\n /** Which feature this is. `provideWr()` refuses the same kind twice in dev mode. */\n readonly ɵkind: K;\n /** What the feature registers, flattened into `provideWr()`'s providers. */\n readonly ɵproviders: readonly (Provider | EnvironmentProviders)[];\n}\n\n/**\n * Build a {@link WrFeature} — what every `with*()` function returns.\n *\n * @example\n * ```ts\n * export function withMeta(defaults: WrMetaConfig = {}): WrFeature<'meta'> {\n * return wrFeature('meta', [{ provide: WR_META_DEFAULTS, useValue: defaults }]);\n * }\n * ```\n */\nexport function wrFeature<K extends string>(\n kind: K,\n providers: readonly (Provider | EnvironmentProviders)[]\n): WrFeature<K> {\n return { ɵkind: kind, ɵproviders: providers };\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { type Signal, computed, signal } from '@angular/core';\n\n/** Where a {@link WrAction} is: nothing ran yet, a run is in flight, or how the last one ended. */\nexport type WrActionStatus = 'idle' | 'pending' | 'success' | 'error';\n\n/** One async write with its state as signals. Built by {@link wrAction}. */\nexport interface WrAction<A = void, R = void> {\n /** `idle` until the first run, `pending` while one is in flight, then `success` or `error`. */\n readonly status: Signal<WrActionStatus>;\n /** `true` while a run is in flight: `status() === 'pending'`. */\n readonly loading: Signal<boolean>;\n /** What the last successful run resolved with. Kept through a later run and a later failure; `undefined` until one succeeds and after `reset()`. */\n readonly value: Signal<R | undefined>;\n /** What the last run rejected with, or `undefined`. Cleared when a run starts and by `reset()`. */\n readonly error: Signal<unknown>;\n /**\n * Starts the write, or joins the one in flight.\n *\n * Single-flight: a call while a run is pending starts nothing and returns\n * that run's promise, so the caller still gets the result it would have\n * waited for, never a dropped one. The promise never rejects: it resolves\n * with the result, or with `undefined` when the call threw (read `error()`)\n * or when `reset()` ran before it settled.\n */\n run(arg: A): Promise<R | undefined>;\n /** Back to `idle`, with `value` and `error` cleared. A run still in flight is disowned: its result is dropped when it arrives. */\n reset(): void;\n}\n\n/**\n * Holds one async write, a save or a delete, as signals a template can read:\n * `status`, `loading`, the last `value` and the last `error`, with a\n * single-flight `run()` and a `reset()`.\n *\n * Needs no injection context, holds no DOM and registers nothing to clean up:\n * a result that lands after the owner is destroyed writes plain signals, which\n * nothing reads any more.\n *\n * @example\n * ```ts\n * readonly save = wrAction((draft: Draft) => this.api.save(draft));\n * ```\n * ```html\n * <button wr-btn [loading]=\"save.loading()\" (click)=\"save.run(draft())\">Save</button>\n * @if (save.status() === 'error') { <wr-alert type=\"danger\">Could not save.</wr-alert> }\n * ```\n *\n * @param fn - The write. May throw synchronously; that counts as a rejection.\n * @returns The action, with `run()` and `reset()` bound so they can be passed around.\n */\nexport function wrAction<A = void, R = void>(fn: (arg: A) => Promise<R>): WrAction<A, R> {\n const status = signal<WrActionStatus>('idle');\n const value = signal<R | undefined>(undefined);\n const error = signal<unknown>(undefined);\n let flight: Promise<R | undefined> | null = null;\n // Bumped by reset(), so a run that started before it finds its result unwanted.\n let generation = 0;\n\n const run = (arg: A): Promise<R | undefined> => {\n if (flight) return flight;\n const mine = ++generation;\n status.set('pending');\n error.set(undefined);\n flight = new Promise<R>(resolve => resolve(fn(arg))).then(\n result => {\n if (mine !== generation) return undefined;\n flight = null;\n value.set(result);\n status.set('success');\n return result;\n },\n (reason: unknown) => {\n if (mine !== generation) return undefined;\n flight = null;\n error.set(reason);\n status.set('error');\n return undefined;\n }\n );\n return flight;\n };\n\n const reset = (): void => {\n generation++;\n flight = null;\n status.set('idle');\n value.set(undefined);\n error.set(undefined);\n };\n\n return { status, loading: computed(() => status() === 'pending'), value, error, run, reset };\n}\n\n/** The keyed form of {@link WrAction}: one write per key, each single-flight on its own. Built by {@link wrKeyedAction}. */\nexport interface WrKeyedAction<K, A = void, R = void> {\n /** `true` while `key` has a run in flight. Reactive: a template or a `computed()` re-reads it when the key settles. */\n pending(key: K): boolean;\n /** `true` while any key has a run in flight. */\n readonly loading: Signal<boolean>;\n /** What the most recently settled run rejected with, or `undefined` when it succeeded. Cleared by `reset()`. */\n readonly error: Signal<unknown>;\n /**\n * Starts the write for `key`, or joins the one in flight for that key.\n *\n * Single-flight per key: a second call for a pending key returns that run's\n * promise, while another key runs alongside. The promise never rejects: it\n * resolves with the result, or with `undefined` when the call threw (read\n * `error()`) or when `reset()` ran before it settled.\n */\n run(key: K, arg: A): Promise<R | undefined>;\n /** Forgets every pending key and clears `error`. Runs still in flight are disowned: their results are dropped when they arrive. */\n reset(): void;\n}\n\n/**\n * The row form of {@link wrAction}: the same write across many keys, a row id\n * say, so a list can show which rows are busy while one row cannot run twice.\n * A key is kept only while it is pending, so the state stays as small as the\n * number of runs in flight.\n *\n * Needs no injection context, like `wrAction`.\n *\n * @example\n * ```ts\n * readonly remove = wrKeyedAction((id: string) => this.api.remove(id));\n * ```\n * ```html\n * @for (row of rows(); track row.id) {\n * <button wr-btn [loading]=\"remove.pending(row.id)\" (click)=\"remove.run(row.id)\">Remove</button>\n * }\n * ```\n *\n * @param fn - The write. Gets the key and the argument `run()` was called with. May throw synchronously; that counts as a rejection.\n * @returns The keyed action, with its methods bound so they can be passed around.\n */\nexport function wrKeyedAction<K, A = void, R = void>(fn: (key: K, arg: A) => Promise<R>): WrKeyedAction<K, A, R> {\n const keys = signal<ReadonlySet<K>>(new Set());\n const error = signal<unknown>(undefined);\n const flights = new Map<K, Promise<R | undefined>>();\n let generation = 0;\n\n const drop = (key: K): void => {\n flights.delete(key);\n keys.update(set => {\n const next = new Set(set);\n next.delete(key);\n return next;\n });\n };\n\n const run = (key: K, arg: A): Promise<R | undefined> => {\n const live = flights.get(key);\n if (live) return live;\n const mine = generation;\n keys.update(set => new Set(set).add(key));\n const flight = new Promise<R>(resolve => resolve(fn(key, arg))).then(\n result => {\n if (mine !== generation) return undefined;\n drop(key);\n error.set(undefined);\n return result;\n },\n (reason: unknown) => {\n if (mine !== generation) return undefined;\n drop(key);\n error.set(reason);\n return undefined;\n }\n );\n flights.set(key, flight);\n return flight;\n };\n\n const reset = (): void => {\n generation++;\n flights.clear();\n keys.set(new Set());\n error.set(undefined);\n };\n\n return {\n pending: (key: K) => keys().has(key),\n loading: computed(() => keys().size > 0),\n error,\n run,\n reset,\n };\n}\n","/**\n * @license\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE\n */\n\nimport { type Resource, type Signal, assertInInjectionContext, effect, linkedSignal } from '@angular/core';\n\n/** The source's answer while the resource has no settled value, distinct from any value it could hold. */\nconst NONE: unique symbol = Symbol('wrResourceValue.none');\n\n/**\n * A resource's value as a signal that never throws: the value while the\n * resource has one, the last settled value while it loads, reloads or sits in\n * its error state, and `fallback` before anything settled.\n *\n * `resource.value()` throws while the status is `error`, so a template that\n * reads it needs a guard at every read; and a `loading` for new params drops\n * the old value, so a list flickers empty on every page change. This keeps the\n * last `resolved` or `local` value through both.\n *\n * Takes anything that is a `Resource`: `resource()`, `rxResource()` and\n * `httpResource()` alike. Needs an injection context, like the resource it\n * reads: an effect records each settled value as it lands, so the memory does\n * not depend on something having read the signal in time, and ends with the\n * context.\n *\n * @example\n * ```ts\n * readonly users = httpResource<User[]>(() => `/api/users?page=${this.page()}`);\n * readonly rows = wrResourceValue(this.users, []);\n * ```\n * ```html\n * <wr-table [items]=\"rows()\" [loading]=\"users.isLoading()\" />\n * ```\n *\n * @param resource - The resource to read.\n * @param fallback - What to return until the resource first settles with a value.\n * @returns A read-only signal of the value.\n */\nexport function wrResourceValue<T>(resource: Resource<T | undefined>, fallback: NoInfer<T>): Signal<T> {\n assertInInjectionContext(wrResourceValue);\n const value = linkedSignal<T | typeof NONE, T>({\n source: () => {\n const status = resource.status();\n const settled = (status === 'resolved' || status === 'local') && resource.hasValue();\n return settled ? resource.value() : NONE;\n },\n computation: (next, previous) => (next !== NONE ? next : previous ? previous.value : fallback),\n });\n effect(() => value());\n return value.asReadonly();\n}\n"],"mappings":";;;;;;;;;AAwBA,SAAgB,YAAe,OAAiB;CAC9C,OAAO,UAAU,QAAQ,UAAU;AACrC;;;;;;;ACJA,SAAgB,kBAAqB,OAAmB;CACtD,OAAO,MAAM,QAAQ,KAAK,KAAK,MAAM,SAAS;AAChD;;;;;;;ACFA,SAAgB,eAA4B,OAAc;CACxD,OAAO,CAAC,CAAC,SAAS,OAAQ,MAAkC,cAAc;AAC5E;ACdA,SAAgB,QAAQ,OAAe,KAAa,KAAW;CAC7D,OAAO,KAAK,IAAI,KAAK,KAAK,IAAI,KAAK,KAAK,CAAC;AAC3C;;;;;;;ACCA,MAAM,aAAa;AAGnB,MAAM,eAAe;AAErB,SAA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AAC,MAC9D,WAAS;GACP,IAAI,SAAS,YAAY,OAAO;GAChC,KAAK,GAAG;GACR,MAAM,IAAI,MAAS;GACnB,OAAO;EACT,IACC,WAAmB;GAClB,IAAI,SAAS,YAAY,OAAO;GAChC,KAAK,GAAG;GACR,MAAM,IAAI,MAAM;EAElB,CAAC;EAEH,QAAQ,IAAI,KAAK,MAAM;EACvB,OAAO;CACT;CAEA,MAAM,cAAmB;EACvB;EACA,QAAQ,MAAK;EACb,KAAK,oBAAI,IAAI,IAAG,CAAE;EAClB,MAAM,IAAI,MAAS;CACrB;CAEA,OAAO;EACL,UAAU,QAAW,KAAI,CAAE,CAAC,IAAI,GAAG;EACnC,SAAS,eAAe,KAAI,CAAE,CAAC,OAAO,CAAC;EACvC;EACA;EACA;CACD;AACH;;;;;;;ACxLA,MAAM,OAAsB,OAAO,sBAAsB;AA+BzD,SAAgB,gBAAmB,UAAmC,UAAoB;CACxF,yBAAyB,eAAe;CACxC,MAAM,QAAQ,aAAY;EAAA,GAAA,YAAA,EAAA,WAAA,QAAA,+BAAA,CAAA;EACxB,cAAa;GACX,MAAM,SAAS,SAAS,OAAM;GAE9B,QADiB,WAAW,cAAc,WAAW,YAAY,SAAS,SAAQ,IACjE,SAAS,MAAK,IAAK;EACtC;EACA,cAAc,MAAM,aAAc,SAAS,OAAO,OAAO,WAAW,SAAS,QAAQ;CAAS,CAAA;CAEhG,aAAa,MAAK,CAAE;CACpB,OAAO,MAAM,WAAU;AACzB"}
|
|
@@ -5,7 +5,7 @@ import { InjectionToken } from "@angular/core";
|
|
|
5
5
|
* Use of this source code is governed by an MIT-style license that can be
|
|
6
6
|
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
7
7
|
*/
|
|
8
|
-
const NGWR_VERSION = "16.
|
|
8
|
+
const NGWR_VERSION = "16.4.0";
|
|
9
9
|
/**
|
|
10
10
|
* @license
|
|
11
11
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngwr-version.mjs","names":[],"sources":["../../../projects/lib/version/version.ts","../../../projects/lib/version/version.token.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 = '16.
|
|
1
|
+
{"version":3,"file":"ngwr-version.mjs","names":[],"sources":["../../../projects/lib/version/version.ts","../../../projects/lib/version/version.token.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 = '16.4.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"],"mappings":";;;;;;;AAiBA,MAAa,eAAe;;;;;;;ACQ5B,MAAa,qBAAqB,IAAI,eAAuB,sBAAsB;CACjF,YAAY;CACZ,eAAe;AAChB,CAAA"}
|
|
@@ -69,7 +69,7 @@ var WrVirtualScroll = class WrVirtualScroll {
|
|
|
69
69
|
}
|
|
70
70
|
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
71
71
|
minVersion: "12.0.0",
|
|
72
|
-
version: "22.2.
|
|
72
|
+
version: "22.2.6",
|
|
73
73
|
ngImport: i0,
|
|
74
74
|
type: WrVirtualScroll,
|
|
75
75
|
deps: [],
|
|
@@ -77,7 +77,7 @@ var WrVirtualScroll = class WrVirtualScroll {
|
|
|
77
77
|
});
|
|
78
78
|
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
79
79
|
minVersion: "17.2.0",
|
|
80
|
-
version: "22.2.
|
|
80
|
+
version: "22.2.6",
|
|
81
81
|
type: WrVirtualScroll,
|
|
82
82
|
isStandalone: true,
|
|
83
83
|
selector: "wr-virtual-scroll",
|
|
@@ -192,7 +192,7 @@ var WrVirtualScroll = class WrVirtualScroll {
|
|
|
192
192
|
};
|
|
193
193
|
i0.ɵɵngDeclareClassMetadata({
|
|
194
194
|
minVersion: "12.0.0",
|
|
195
|
-
version: "22.2.
|
|
195
|
+
version: "22.2.6",
|
|
196
196
|
ngImport: i0,
|
|
197
197
|
type: WrVirtualScroll,
|
|
198
198
|
decorators: [{
|