ngwr 6.1.1 → 7.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -3
- package/README.md +179 -32
- package/affix/styles/_index.scss +12 -0
- package/alert/styles/_index.scss +75 -32
- package/anchor/styles/_index.scss +59 -0
- package/aurora/aurora.scss +1 -0
- package/aurora/styles/_index.scss +30 -0
- package/avatar/styles/_index.scss +30 -14
- package/back-top/styles/_index.scss +42 -0
- package/badge/styles/_index.scss +80 -0
- package/badge/styles/_tag.scss +81 -0
- package/bar-chart/styles/_index.scss +56 -0
- package/blur-text/blur-text.scss +1 -0
- package/blur-text/styles/_index.scss +14 -0
- package/border-glow/border-glow.scss +4 -0
- package/border-glow/styles/_index.scss +228 -0
- package/breadcrumbs/breadcrumbs.scss +1 -0
- package/breadcrumbs/styles/_index.scss +76 -0
- package/burger/styles/_index.scss +101 -0
- package/button/styles/_index.scss +148 -125
- package/calendar/styles/_index.scss +252 -0
- package/calendar-heatmap/styles/_index.scss +69 -0
- package/card/card.scss +1 -0
- package/card/styles/_index.scss +96 -0
- package/carousel/styles/_index.scss +102 -0
- package/cascader/cascader.scss +1 -0
- package/cascader/styles/_index.scss +174 -0
- package/checkbox/styles/_index.scss +76 -60
- package/circular-text/circular-text.scss +1 -0
- package/circular-text/styles/_index.scss +45 -0
- package/click-spark/click-spark.scss +1 -0
- package/click-spark/styles/_index.scss +16 -0
- package/collapse/styles/_index.scss +92 -0
- package/color-picker/styles/_index.scss +247 -0
- package/command-palette/styles/_index.scss +188 -0
- package/compare/styles/_index.scss +100 -0
- package/context-menu/styles/_index.scss +112 -0
- package/counter/styles/_index.scss +44 -0
- package/date-picker/styles/_index.scss +204 -0
- package/decrypt-text/decrypt-text.scss +1 -0
- package/decrypt-text/styles/_index.scss +26 -0
- package/density/styles/_index.scss +37 -0
- package/descriptions/styles/_index.scss +104 -0
- package/dialog/styles/_index.scss +101 -27
- package/divider/styles/_index.scss +43 -24
- package/donut-chart/styles/_index.scss +76 -0
- package/drag-drop/sortable-list.scss +1 -0
- package/drag-drop/styles/_index.scss +99 -0
- package/drawer/styles/_index.scss +164 -0
- package/dropdown/styles/_index.scss +76 -56
- package/empty/styles/_index.scss +49 -0
- package/falling-text/falling-text.scss +1 -0
- package/falling-text/styles/_index.scss +30 -0
- package/fesm2022/ngwr-affix.mjs +102 -0
- package/fesm2022/ngwr-affix.mjs.map +1 -0
- package/fesm2022/ngwr-alert.mjs +70 -52
- package/fesm2022/ngwr-alert.mjs.map +1 -1
- package/fesm2022/ngwr-anchor.mjs +103 -0
- package/fesm2022/ngwr-anchor.mjs.map +1 -0
- package/fesm2022/ngwr-aurora.mjs +309 -0
- package/fesm2022/ngwr-aurora.mjs.map +1 -0
- package/fesm2022/ngwr-avatar.mjs +81 -71
- package/fesm2022/ngwr-avatar.mjs.map +1 -1
- package/fesm2022/ngwr-back-top.mjs +81 -0
- package/fesm2022/ngwr-back-top.mjs.map +1 -0
- package/fesm2022/ngwr-badge.mjs +192 -0
- package/fesm2022/ngwr-badge.mjs.map +1 -0
- package/fesm2022/ngwr-bar-chart.mjs +69 -0
- package/fesm2022/ngwr-bar-chart.mjs.map +1 -0
- package/fesm2022/ngwr-blur-text.mjs +181 -0
- package/fesm2022/ngwr-blur-text.mjs.map +1 -0
- package/fesm2022/ngwr-border-glow.mjs +278 -0
- package/fesm2022/ngwr-border-glow.mjs.map +1 -0
- package/fesm2022/ngwr-breadcrumbs.mjs +101 -0
- package/fesm2022/ngwr-breadcrumbs.mjs.map +1 -0
- package/fesm2022/ngwr-burger.mjs +60 -0
- package/fesm2022/ngwr-burger.mjs.map +1 -0
- package/fesm2022/ngwr-button.mjs +179 -104
- package/fesm2022/ngwr-button.mjs.map +1 -1
- package/fesm2022/ngwr-calendar-heatmap.mjs +145 -0
- package/fesm2022/ngwr-calendar-heatmap.mjs.map +1 -0
- package/fesm2022/ngwr-calendar.mjs +402 -0
- package/fesm2022/ngwr-calendar.mjs.map +1 -0
- package/fesm2022/ngwr-card.mjs +100 -0
- package/fesm2022/ngwr-card.mjs.map +1 -0
- package/fesm2022/ngwr-carousel.mjs +128 -0
- package/fesm2022/ngwr-carousel.mjs.map +1 -0
- package/fesm2022/ngwr-cascader.mjs +280 -0
- package/fesm2022/ngwr-cascader.mjs.map +1 -0
- package/fesm2022/ngwr-checkbox.mjs +214 -54
- package/fesm2022/ngwr-checkbox.mjs.map +1 -1
- package/fesm2022/ngwr-circular-text.mjs +168 -0
- package/fesm2022/ngwr-circular-text.mjs.map +1 -0
- package/fesm2022/ngwr-click-spark.mjs +163 -0
- package/fesm2022/ngwr-click-spark.mjs.map +1 -0
- package/fesm2022/ngwr-clipboard.mjs +130 -0
- package/fesm2022/ngwr-clipboard.mjs.map +1 -0
- package/fesm2022/ngwr-collapse.mjs +232 -0
- package/fesm2022/ngwr-collapse.mjs.map +1 -0
- package/fesm2022/ngwr-color-picker.mjs +646 -0
- package/fesm2022/ngwr-color-picker.mjs.map +1 -0
- package/fesm2022/ngwr-command-palette.mjs +259 -0
- package/fesm2022/ngwr-command-palette.mjs.map +1 -0
- package/fesm2022/ngwr-compare.mjs +137 -0
- package/fesm2022/ngwr-compare.mjs.map +1 -0
- package/fesm2022/ngwr-confetti.mjs +160 -0
- package/fesm2022/ngwr-confetti.mjs.map +1 -0
- package/fesm2022/ngwr-context-menu.mjs +653 -0
- package/fesm2022/ngwr-context-menu.mjs.map +1 -0
- package/fesm2022/ngwr-cookie.mjs +127 -0
- package/fesm2022/ngwr-cookie.mjs.map +1 -0
- package/fesm2022/ngwr-counter.mjs +415 -0
- package/fesm2022/ngwr-counter.mjs.map +1 -0
- package/fesm2022/ngwr-date-adapter-fns.mjs +180 -0
- package/fesm2022/ngwr-date-adapter-fns.mjs.map +1 -0
- package/fesm2022/ngwr-date-adapter-luxon.mjs +201 -0
- package/fesm2022/ngwr-date-adapter-luxon.mjs.map +1 -0
- package/fesm2022/ngwr-date-adapter.mjs +419 -0
- package/fesm2022/ngwr-date-adapter.mjs.map +1 -0
- package/fesm2022/ngwr-date-picker.mjs +624 -0
- package/fesm2022/ngwr-date-picker.mjs.map +1 -0
- package/fesm2022/ngwr-decrypt-text.mjs +396 -0
- package/fesm2022/ngwr-decrypt-text.mjs.map +1 -0
- package/fesm2022/ngwr-density.mjs +157 -0
- package/fesm2022/ngwr-density.mjs.map +1 -0
- package/fesm2022/ngwr-descriptions.mjs +83 -0
- package/fesm2022/ngwr-descriptions.mjs.map +1 -0
- package/fesm2022/ngwr-dialog.mjs +249 -377
- package/fesm2022/ngwr-dialog.mjs.map +1 -1
- package/fesm2022/ngwr-directives.mjs +315 -0
- package/fesm2022/ngwr-directives.mjs.map +1 -0
- package/fesm2022/ngwr-divider.mjs +74 -59
- package/fesm2022/ngwr-divider.mjs.map +1 -1
- package/fesm2022/ngwr-donut-chart.mjs +131 -0
- package/fesm2022/ngwr-donut-chart.mjs.map +1 -0
- package/fesm2022/ngwr-drag-drop.mjs +117 -0
- package/fesm2022/ngwr-drag-drop.mjs.map +1 -0
- package/fesm2022/ngwr-drawer.mjs +315 -0
- package/fesm2022/ngwr-drawer.mjs.map +1 -0
- package/fesm2022/ngwr-dropdown.mjs +276 -229
- package/fesm2022/ngwr-dropdown.mjs.map +1 -1
- package/fesm2022/ngwr-empty.mjs +57 -0
- package/fesm2022/ngwr-empty.mjs.map +1 -0
- package/fesm2022/ngwr-falling-text.mjs +316 -0
- package/fesm2022/ngwr-falling-text.mjs.map +1 -0
- package/fesm2022/ngwr-file-upload.mjs +260 -0
- package/fesm2022/ngwr-file-upload.mjs.map +1 -0
- package/fesm2022/ngwr-form.mjs +133 -48
- package/fesm2022/ngwr-form.mjs.map +1 -1
- package/fesm2022/ngwr-fuzzy-text.mjs +373 -0
- package/fesm2022/ngwr-fuzzy-text.mjs.map +1 -0
- package/fesm2022/ngwr-gauge.mjs +83 -0
- package/fesm2022/ngwr-gauge.mjs.map +1 -0
- package/fesm2022/ngwr-glitch-text.mjs +67 -0
- package/fesm2022/ngwr-glitch-text.mjs.map +1 -0
- package/fesm2022/ngwr-gradient-text.mjs +109 -0
- package/fesm2022/ngwr-gradient-text.mjs.map +1 -0
- package/fesm2022/ngwr-hotkey.mjs +263 -0
- package/fesm2022/ngwr-hotkey.mjs.map +1 -0
- package/fesm2022/ngwr-i18n-en.mjs +168 -0
- package/fesm2022/ngwr-i18n-en.mjs.map +1 -0
- package/fesm2022/ngwr-i18n-ru.mjs +156 -0
- package/fesm2022/ngwr-i18n-ru.mjs.map +1 -0
- package/fesm2022/ngwr-i18n.mjs +478 -0
- package/fesm2022/ngwr-i18n.mjs.map +1 -0
- package/fesm2022/ngwr-icon-adapters-feather.mjs +74 -0
- package/fesm2022/ngwr-icon-adapters-feather.mjs.map +1 -0
- package/fesm2022/ngwr-icon-adapters-lucide.mjs +88 -0
- package/fesm2022/ngwr-icon-adapters-lucide.mjs.map +1 -0
- package/fesm2022/ngwr-icon.mjs +189 -649
- package/fesm2022/ngwr-icon.mjs.map +1 -1
- package/fesm2022/ngwr-image-cropper.mjs +299 -0
- package/fesm2022/ngwr-image-cropper.mjs.map +1 -0
- package/fesm2022/ngwr-input-number.mjs +239 -0
- package/fesm2022/ngwr-input-number.mjs.map +1 -0
- package/fesm2022/ngwr-input-otp.mjs +216 -0
- package/fesm2022/ngwr-input-otp.mjs.map +1 -0
- package/fesm2022/ngwr-input.mjs +183 -104
- package/fesm2022/ngwr-input.mjs.map +1 -1
- package/fesm2022/ngwr-keyboard.mjs +47 -0
- package/fesm2022/ngwr-keyboard.mjs.map +1 -0
- package/fesm2022/ngwr-knob.mjs +227 -0
- package/fesm2022/ngwr-knob.mjs.map +1 -0
- package/fesm2022/ngwr-layout.mjs +197 -0
- package/fesm2022/ngwr-layout.mjs.map +1 -0
- package/fesm2022/ngwr-lightbox.mjs +131 -0
- package/fesm2022/ngwr-lightbox.mjs.map +1 -0
- package/fesm2022/ngwr-line-chart.mjs +176 -0
- package/fesm2022/ngwr-line-chart.mjs.map +1 -0
- package/fesm2022/ngwr-list.mjs +132 -0
- package/fesm2022/ngwr-list.mjs.map +1 -0
- package/fesm2022/ngwr-loading-bar.mjs +160 -0
- package/fesm2022/ngwr-loading-bar.mjs.map +1 -0
- package/fesm2022/ngwr-marquee.mjs +224 -0
- package/fesm2022/ngwr-marquee.mjs.map +1 -0
- package/fesm2022/ngwr-media.mjs +132 -0
- package/fesm2022/ngwr-media.mjs.map +1 -0
- package/fesm2022/ngwr-mention.mjs +374 -0
- package/fesm2022/ngwr-mention.mjs.map +1 -0
- package/fesm2022/ngwr-meta.mjs +323 -0
- package/fesm2022/ngwr-meta.mjs.map +1 -0
- package/fesm2022/ngwr-meter-group.mjs +73 -0
- package/fesm2022/ngwr-meter-group.mjs.map +1 -0
- package/fesm2022/ngwr-overlay.mjs +145 -0
- package/fesm2022/ngwr-overlay.mjs.map +1 -0
- package/fesm2022/ngwr-page-header.mjs +53 -0
- package/fesm2022/ngwr-page-header.mjs.map +1 -0
- package/fesm2022/ngwr-pagination.mjs +152 -96
- package/fesm2022/ngwr-pagination.mjs.map +1 -1
- package/fesm2022/ngwr-pipes.mjs +290 -11
- package/fesm2022/ngwr-pipes.mjs.map +1 -1
- package/fesm2022/ngwr-platform.mjs +63 -0
- package/fesm2022/ngwr-platform.mjs.map +1 -0
- package/fesm2022/ngwr-popconfirm.mjs +188 -0
- package/fesm2022/ngwr-popconfirm.mjs.map +1 -0
- package/fesm2022/ngwr-popover.mjs +365 -0
- package/fesm2022/ngwr-popover.mjs.map +1 -0
- package/fesm2022/ngwr-progress.mjs +47 -39
- package/fesm2022/ngwr-progress.mjs.map +1 -1
- package/fesm2022/ngwr-qr.mjs +160 -179
- package/fesm2022/ngwr-qr.mjs.map +1 -1
- package/fesm2022/ngwr-radio.mjs +204 -0
- package/fesm2022/ngwr-radio.mjs.map +1 -0
- package/fesm2022/ngwr-rating.mjs +180 -0
- package/fesm2022/ngwr-rating.mjs.map +1 -0
- package/fesm2022/ngwr-result.mjs +119 -0
- package/fesm2022/ngwr-result.mjs.map +1 -0
- package/fesm2022/ngwr-rotating-text.mjs +256 -0
- package/fesm2022/ngwr-rotating-text.mjs.map +1 -0
- package/fesm2022/ngwr-scramble-text.mjs +165 -0
- package/fesm2022/ngwr-scramble-text.mjs.map +1 -0
- package/fesm2022/ngwr-scroll.mjs +107 -0
- package/fesm2022/ngwr-scroll.mjs.map +1 -0
- package/fesm2022/ngwr-segmented.mjs +96 -0
- package/fesm2022/ngwr-segmented.mjs.map +1 -0
- package/fesm2022/ngwr-select.mjs +844 -309
- package/fesm2022/ngwr-select.mjs.map +1 -1
- package/fesm2022/ngwr-shiny-text.mjs +127 -0
- package/fesm2022/ngwr-shiny-text.mjs.map +1 -0
- package/fesm2022/ngwr-sidebar.mjs +134 -0
- package/fesm2022/ngwr-sidebar.mjs.map +1 -0
- package/fesm2022/ngwr-skeleton.mjs +59 -34
- package/fesm2022/ngwr-skeleton.mjs.map +1 -1
- package/fesm2022/ngwr-slider.mjs +234 -0
- package/fesm2022/ngwr-slider.mjs.map +1 -0
- package/fesm2022/ngwr-sparkline.mjs +104 -0
- package/fesm2022/ngwr-sparkline.mjs.map +1 -0
- package/fesm2022/ngwr-speed-dial.mjs +79 -0
- package/fesm2022/ngwr-speed-dial.mjs.map +1 -0
- package/fesm2022/ngwr-spinner.mjs +34 -28
- package/fesm2022/ngwr-spinner.mjs.map +1 -1
- package/fesm2022/ngwr-splash-cursor.mjs +970 -0
- package/fesm2022/ngwr-splash-cursor.mjs.map +1 -0
- package/fesm2022/ngwr-split-text.mjs +200 -0
- package/fesm2022/ngwr-split-text.mjs.map +1 -0
- package/fesm2022/ngwr-splitter.mjs +125 -0
- package/fesm2022/ngwr-splitter.mjs.map +1 -0
- package/fesm2022/ngwr-spotlight-card.mjs +138 -0
- package/fesm2022/ngwr-spotlight-card.mjs.map +1 -0
- package/fesm2022/ngwr-squircle.mjs +320 -0
- package/fesm2022/ngwr-squircle.mjs.map +1 -0
- package/fesm2022/ngwr-star-border.mjs +72 -0
- package/fesm2022/ngwr-star-border.mjs.map +1 -0
- package/fesm2022/ngwr-statistic.mjs +220 -0
- package/fesm2022/ngwr-statistic.mjs.map +1 -0
- package/fesm2022/ngwr-stepper.mjs +186 -0
- package/fesm2022/ngwr-stepper.mjs.map +1 -0
- package/fesm2022/ngwr-storage.mjs +317 -0
- package/fesm2022/ngwr-storage.mjs.map +1 -0
- package/fesm2022/ngwr-switch.mjs +99 -0
- package/fesm2022/ngwr-switch.mjs.map +1 -0
- package/fesm2022/ngwr-table.mjs +217 -206
- package/fesm2022/ngwr-table.mjs.map +1 -1
- package/fesm2022/ngwr-tabs.mjs +217 -0
- package/fesm2022/ngwr-tabs.mjs.map +1 -0
- package/fesm2022/ngwr-textarea.mjs +106 -120
- package/fesm2022/ngwr-textarea.mjs.map +1 -1
- package/fesm2022/ngwr-theme.mjs +152 -0
- package/fesm2022/ngwr-theme.mjs.map +1 -0
- package/fesm2022/ngwr-tilt-card.mjs +137 -0
- package/fesm2022/ngwr-tilt-card.mjs.map +1 -0
- package/fesm2022/ngwr-timeline.mjs +73 -0
- package/fesm2022/ngwr-timeline.mjs.map +1 -0
- package/fesm2022/ngwr-toast.mjs +446 -0
- package/fesm2022/ngwr-toast.mjs.map +1 -0
- package/fesm2022/ngwr-toolbar.mjs +46 -0
- package/fesm2022/ngwr-toolbar.mjs.map +1 -0
- package/fesm2022/ngwr-tree.mjs +483 -0
- package/fesm2022/ngwr-tree.mjs.map +1 -0
- package/fesm2022/ngwr-typewriter.mjs +229 -0
- package/fesm2022/ngwr-typewriter.mjs.map +1 -0
- package/fesm2022/ngwr-typography.mjs +79 -0
- package/fesm2022/ngwr-typography.mjs.map +1 -0
- package/fesm2022/ngwr-utils.mjs +535 -0
- package/fesm2022/ngwr-utils.mjs.map +1 -0
- package/fesm2022/ngwr-validators.mjs +214 -0
- package/fesm2022/ngwr-validators.mjs.map +1 -0
- package/fesm2022/ngwr-version.mjs +51 -0
- package/fesm2022/ngwr-version.mjs.map +1 -0
- package/fesm2022/ngwr-virtual-scroll.mjs +99 -0
- package/fesm2022/ngwr-virtual-scroll.mjs.map +1 -0
- package/fesm2022/ngwr-waves.mjs +356 -0
- package/fesm2022/ngwr-waves.mjs.map +1 -0
- package/fesm2022/ngwr-window.mjs +1141 -0
- package/fesm2022/ngwr-window.mjs.map +1 -0
- package/fesm2022/ngwr.mjs +0 -3
- package/fesm2022/ngwr.mjs.map +1 -1
- package/file-upload/styles/_index.scss +152 -0
- package/form/styles/_index.scss +85 -42
- package/gauge/styles/_index.scss +37 -0
- package/glitch-text/glitch-text.scss +1 -0
- package/glitch-text/styles/_index.scss +144 -0
- package/gradient-text/gradient-text.scss +1 -0
- package/gradient-text/styles/_index.scss +113 -0
- package/icon/styles/_index.scss +21 -15
- package/image-cropper/styles/_index.scss +114 -0
- package/input/styles/_index.scss +133 -93
- package/input-number/styles/_index.scss +75 -0
- package/input-otp/styles/_index.scss +53 -0
- package/keyboard/styles/_index.scss +55 -0
- package/knob/styles/_index.scss +54 -0
- package/layout/styles/_index.scss +65 -0
- package/lightbox/lightbox.scss +1 -0
- package/lightbox/styles/_index.scss +144 -0
- package/line-chart/styles/_index.scss +93 -0
- package/list/list.scss +1 -0
- package/list/styles/_index.scss +101 -0
- package/loading-bar/loading-bar.scss +1 -0
- package/loading-bar/styles/_index.scss +29 -0
- package/marquee/marquee.scss +1 -0
- package/marquee/styles/_index.scss +138 -0
- package/mention/styles/_index.scss +47 -0
- package/meter-group/styles/_index.scss +61 -0
- package/package.json +586 -104
- package/page-header/styles/_index.scss +78 -0
- package/pagination/styles/_index.scss +89 -34
- package/popconfirm/styles/_index.scss +32 -0
- package/popover/styles/_index.scss +99 -0
- package/progress/styles/_index.scss +29 -14
- package/qr/styles/_index.scss +6 -3
- package/radio/styles/_index.scss +111 -0
- package/rating/styles/_index.scss +63 -0
- package/result/styles/_index.scss +69 -0
- package/rotating-text/rotating-text.scss +1 -0
- package/rotating-text/styles/_index.scss +39 -0
- package/schematics/collection.json +37 -0
- package/schematics/component-style/index.js +49 -0
- package/{cdk/utils/index.d.ts → schematics/component-style/schema.js} +2 -8
- package/schematics/component-style/schema.json +20 -0
- package/schematics/icon-set/index.js +96 -0
- package/schematics/icon-set/schema.js +8 -0
- package/schematics/icon-set/schema.json +39 -0
- package/schematics/migrations/v7/index.js +187 -0
- package/schematics/migrations.json +10 -0
- package/schematics/ng-add/index.js +180 -0
- package/schematics/ng-add/schema.js +8 -0
- package/schematics/ng-add/schema.json +80 -0
- package/schematics/page/index.js +63 -0
- package/schematics/page/schema.js +8 -0
- package/schematics/page/schema.json +39 -0
- package/schematics/page/templates.js +198 -0
- package/schematics/provider/index.js +126 -0
- package/schematics/provider/schema.js +8 -0
- package/schematics/provider/schema.json +52 -0
- package/schematics/use/index.js +143 -0
- package/schematics/use/schema.js +8 -0
- package/schematics/use/schema.json +25 -0
- package/schematics/use/symbol-map.json +357 -0
- package/scramble-text/scramble-text.scss +1 -0
- package/scramble-text/styles/_index.scss +8 -0
- package/segmented/styles/_index.scss +92 -0
- package/select/styles/_index.scss +245 -159
- package/shiny-text/shiny-text.scss +1 -0
- package/shiny-text/styles/_index.scss +101 -0
- package/sidebar/styles/_index.scss +208 -0
- package/skeleton/styles/_index.scss +33 -33
- package/slider/styles/_index.scss +77 -0
- package/sparkline/styles/_index.scss +9 -0
- package/speed-dial/styles/_index.scss +158 -0
- package/spinner/styles/_index.scss +38 -22
- package/splash-cursor/splash-cursor.scss +1 -0
- package/splash-cursor/styles/_index.scss +27 -0
- package/split-text/split-text.scss +1 -0
- package/split-text/styles/_index.scss +22 -0
- package/splitter/styles/_index.scss +85 -0
- package/spotlight-card/spotlight-card.scss +1 -0
- package/spotlight-card/styles/_index.scss +43 -0
- package/squircle/styles/_index.scss +34 -0
- package/star-border/star-border.scss +1 -0
- package/star-border/styles/_index.scss +118 -0
- package/statistic/styles/_index.scss +54 -0
- package/stepper/styles/_index.scss +162 -0
- package/styles/_animations.scss +198 -0
- package/styles/_breakpoints.scss +75 -0
- package/styles/_grid.scss +71 -0
- package/styles/_reset.scss +123 -0
- package/styles/_typography.scss +122 -0
- package/styles.scss +103 -13
- package/switch/styles/_index.scss +82 -0
- package/table/styles/_index.scss +255 -4
- package/tabs/styles/_index.scss +71 -0
- package/textarea/styles/_index.scss +47 -56
- package/theme/styles/_colors.scss +83 -0
- package/theme/styles/_dark.scss +85 -0
- package/theme/styles/_focus.scss +93 -0
- package/theme/styles/_index.scss +5 -0
- package/theme/styles/_mixins.scss +57 -0
- package/theme/styles/_variables.scss +118 -0
- package/tilt-card/styles/_index.scss +40 -0
- package/tilt-card/tilt-card.scss +1 -0
- package/timeline/styles/_index.scss +127 -0
- package/toast/styles/_index.scss +263 -0
- package/toolbar/styles/_index.scss +65 -0
- package/tree/styles/_index.scss +271 -0
- package/types/ngwr-affix.d.ts +43 -0
- package/types/ngwr-alert.d.ts +68 -0
- package/types/ngwr-anchor.d.ts +53 -0
- package/types/ngwr-aurora.d.ts +52 -0
- package/types/ngwr-avatar.d.ts +90 -0
- package/types/ngwr-back-top.d.ts +37 -0
- package/types/ngwr-badge.d.ts +158 -0
- package/types/ngwr-bar-chart.d.ts +47 -0
- package/types/ngwr-blur-text.d.ts +62 -0
- package/types/ngwr-border-glow.d.ts +66 -0
- package/types/ngwr-breadcrumbs.d.ts +61 -0
- package/types/ngwr-burger.d.ts +36 -0
- package/types/ngwr-button.d.ts +176 -0
- package/types/ngwr-calendar-heatmap.d.ts +58 -0
- package/types/ngwr-calendar.d.ts +116 -0
- package/types/ngwr-card.d.ts +50 -0
- package/types/ngwr-carousel.d.ts +57 -0
- package/types/ngwr-cascader.d.ts +107 -0
- package/types/ngwr-checkbox.d.ts +139 -0
- package/types/ngwr-circular-text.d.ts +49 -0
- package/types/ngwr-click-spark.d.ts +52 -0
- package/types/ngwr-clipboard.d.ts +53 -0
- package/types/ngwr-collapse.d.ts +139 -0
- package/types/ngwr-color-picker.d.ts +302 -0
- package/types/ngwr-command-palette.d.ts +113 -0
- package/types/ngwr-compare.d.ts +55 -0
- package/types/ngwr-confetti.d.ts +70 -0
- package/types/ngwr-context-menu.d.ts +207 -0
- package/types/ngwr-cookie.d.ts +60 -0
- package/types/ngwr-counter.d.ts +182 -0
- package/types/ngwr-date-adapter-fns.d.ts +73 -0
- package/types/ngwr-date-adapter-luxon.d.ts +73 -0
- package/types/ngwr-date-adapter.d.ts +198 -0
- package/types/ngwr-date-picker.d.ts +117 -0
- package/types/ngwr-decrypt-text.d.ts +85 -0
- package/types/ngwr-density.d.ts +97 -0
- package/types/ngwr-descriptions.d.ts +41 -0
- package/types/ngwr-dialog.d.ts +210 -0
- package/types/ngwr-directives.d.ts +125 -0
- package/types/ngwr-divider.d.ts +73 -0
- package/types/ngwr-donut-chart.d.ts +53 -0
- package/types/ngwr-drag-drop.d.ts +83 -0
- package/types/ngwr-drawer.d.ts +155 -0
- package/types/ngwr-dropdown.d.ts +124 -0
- package/types/ngwr-empty.d.ts +38 -0
- package/types/ngwr-falling-text.d.ts +63 -0
- package/types/ngwr-file-upload.d.ts +94 -0
- package/types/ngwr-form.d.ts +95 -0
- package/types/ngwr-fuzzy-text.d.ts +74 -0
- package/types/ngwr-gauge.d.ts +39 -0
- package/types/ngwr-glitch-text.d.ts +31 -0
- package/types/ngwr-gradient-text.d.ts +46 -0
- package/types/ngwr-hotkey.d.ts +142 -0
- package/types/ngwr-i18n-en.d.ts +18 -0
- package/types/ngwr-i18n-ru.d.ts +6 -0
- package/types/ngwr-i18n.d.ts +336 -0
- package/types/ngwr-icon-adapters-feather.d.ts +44 -0
- package/types/ngwr-icon-adapters-lucide.d.ts +54 -0
- package/types/ngwr-icon.d.ts +180 -0
- package/types/ngwr-image-cropper.d.ts +110 -0
- package/types/ngwr-input-number.d.ts +77 -0
- package/types/ngwr-input-otp.d.ts +78 -0
- package/types/ngwr-input.d.ts +131 -0
- package/types/ngwr-keyboard.d.ts +34 -0
- package/types/ngwr-knob.d.ts +77 -0
- package/types/ngwr-layout.d.ts +89 -0
- package/types/ngwr-lightbox.d.ts +50 -0
- package/types/ngwr-line-chart.d.ts +90 -0
- package/types/ngwr-list.d.ts +71 -0
- package/types/ngwr-loading-bar.d.ts +79 -0
- package/types/ngwr-marquee.d.ts +95 -0
- package/types/ngwr-media.d.ts +74 -0
- package/types/ngwr-mention.d.ts +110 -0
- package/types/ngwr-meta.d.ts +188 -0
- package/types/ngwr-meter-group.d.ts +57 -0
- package/types/ngwr-overlay.d.ts +110 -0
- package/types/ngwr-page-header.d.ts +35 -0
- package/types/ngwr-pagination.d.ts +119 -0
- package/types/ngwr-pipes.d.ts +177 -0
- package/types/ngwr-platform.d.ts +38 -0
- package/types/ngwr-popconfirm.d.ts +79 -0
- package/types/ngwr-popover.d.ts +90 -0
- package/types/ngwr-progress.d.ts +33 -0
- package/types/ngwr-qr.d.ts +56 -0
- package/types/ngwr-radio.d.ts +120 -0
- package/types/ngwr-rating.d.ts +62 -0
- package/types/ngwr-result.d.ts +64 -0
- package/types/ngwr-rotating-text.d.ts +72 -0
- package/types/ngwr-scramble-text.d.ts +49 -0
- package/types/ngwr-scroll.d.ts +65 -0
- package/types/ngwr-segmented.d.ts +65 -0
- package/types/ngwr-select.d.ts +413 -0
- package/types/ngwr-shiny-text.d.ts +70 -0
- package/types/ngwr-sidebar.d.ts +83 -0
- package/types/ngwr-skeleton.d.ts +41 -0
- package/types/ngwr-slider.d.ts +86 -0
- package/types/ngwr-sparkline.d.ts +48 -0
- package/types/ngwr-speed-dial.d.ts +51 -0
- package/types/ngwr-spinner.d.ts +41 -0
- package/types/ngwr-splash-cursor.d.ts +94 -0
- package/types/ngwr-split-text.d.ts +83 -0
- package/types/ngwr-splitter.d.ts +52 -0
- package/types/ngwr-spotlight-card.d.ts +71 -0
- package/types/ngwr-squircle.d.ts +132 -0
- package/types/ngwr-star-border.d.ts +40 -0
- package/types/ngwr-statistic.d.ts +88 -0
- package/types/ngwr-stepper.d.ts +99 -0
- package/types/ngwr-storage.d.ts +178 -0
- package/types/ngwr-switch.d.ts +39 -0
- package/types/ngwr-table.d.ts +237 -0
- package/types/ngwr-tabs.d.ts +125 -0
- package/types/ngwr-textarea.d.ts +60 -0
- package/types/ngwr-theme.d.ts +124 -0
- package/types/ngwr-tilt-card.d.ts +63 -0
- package/types/ngwr-timeline.d.ts +40 -0
- package/types/ngwr-toast.d.ts +230 -0
- package/types/ngwr-toolbar.d.ts +30 -0
- package/types/ngwr-tree.d.ts +150 -0
- package/types/ngwr-typewriter.d.ts +84 -0
- package/types/ngwr-typography.d.ts +56 -0
- package/types/ngwr-utils.d.ts +447 -0
- package/types/ngwr-validators.d.ts +70 -0
- package/types/ngwr-version.d.ts +44 -0
- package/types/ngwr-virtual-scroll.d.ts +64 -0
- package/types/ngwr-waves.d.ts +71 -0
- package/types/ngwr-window.d.ts +437 -0
- package/typewriter/styles/_index.scss +33 -0
- package/typewriter/typewriter.scss +1 -0
- package/typography/styles/_index.scss +211 -0
- package/virtual-scroll/styles/_index.scss +27 -0
- package/virtual-scroll/virtual-scroll.scss +1 -0
- package/waves/styles/_index.scss +24 -0
- package/waves/waves.scss +1 -0
- package/window/styles/_index.scss +430 -0
- package/alert/index.d.ts +0 -32
- package/alert/styles/theming.scss +0 -26
- package/alert/styles/vars.scss +0 -11
- package/avatar/index.d.ts +0 -30
- package/button/index.d.ts +0 -45
- package/button/styles/vars.scss +0 -13
- package/cdk/index.d.ts +0 -24
- package/cdk/rxjs/index.d.ts +0 -40
- package/cdk/types/index.d.ts +0 -27
- package/checkbox/index.d.ts +0 -31
- package/checkbox/styles/vars.scss +0 -16
- package/dialog/index.d.ts +0 -193
- package/dialog/styles/vars.scss +0 -7
- package/divider/index.d.ts +0 -16
- package/dropdown/index.d.ts +0 -68
- package/dropdown/styles/vars.scss +0 -18
- package/fesm2022/ngwr-cdk-rxjs.mjs +0 -53
- package/fesm2022/ngwr-cdk-rxjs.mjs.map +0 -1
- package/fesm2022/ngwr-cdk-types.mjs +0 -44
- package/fesm2022/ngwr-cdk-types.mjs.map +0 -1
- package/fesm2022/ngwr-cdk-utils.mjs +0 -30
- package/fesm2022/ngwr-cdk-utils.mjs.map +0 -1
- package/fesm2022/ngwr-cdk.mjs +0 -46
- package/fesm2022/ngwr-cdk.mjs.map +0 -1
- package/fesm2022/ngwr-tag.mjs +0 -87
- package/fesm2022/ngwr-tag.mjs.map +0 -1
- package/form/index.d.ts +0 -28
- package/icon/index.d.ts +0 -830
- package/icon/styles/vars.scss +0 -3
- package/input/index.d.ts +0 -43
- package/input/styles/vars.scss +0 -17
- package/pagination/index.d.ts +0 -34
- package/pagination/styles/vars.scss +0 -14
- package/pipes/index.d.ts +0 -17
- package/progress/index.d.ts +0 -13
- package/progress/styles/theming.scss +0 -8
- package/progress/styles/vars.scss +0 -6
- package/qr/index.d.ts +0 -127
- package/select/index.d.ts +0 -121
- package/select/styles/vars.scss +0 -32
- package/skeleton/index.d.ts +0 -13
- package/spinner/index.d.ts +0 -23
- package/styles/animations.scss +0 -92
- package/styles/cdk.scss +0 -5
- package/styles/colors.scss +0 -72
- package/styles/grid.scss +0 -99
- package/styles/maps.scss +0 -31
- package/styles/reset.scss +0 -112
- package/styles/variables.scss +0 -72
- package/table/index.d.ts +0 -101
- package/table/styles/table-filter.scss +0 -202
- package/table/styles/table-sort.scss +0 -47
- package/table/styles/table.scss +0 -232
- package/table/styles/vars.scss +0 -21
- package/tag/index.d.ts +0 -24
- package/tag/styles/_index.scss +0 -32
- package/tag/styles/theming.scss +0 -21
- package/tag/styles/vars.scss +0 -12
- package/textarea/index.d.ts +0 -47
- package/textarea/styles/vars.scss +0 -17
- /package/{index.d.ts → types/ngwr.d.ts} +0 -0
|
@@ -0,0 +1,415 @@
|
|
|
1
|
+
import { coerceNumberProperty } from '@angular/cdk/coercion';
|
|
2
|
+
import { isPlatformBrowser } from '@angular/common';
|
|
3
|
+
import * as i0 from '@angular/core';
|
|
4
|
+
import { input, signal, inject, LOCALE_ID, PLATFORM_ID, computed, DestroyRef, effect, ViewEncapsulation, Component, output, ElementRef, afterNextRender } from '@angular/core';
|
|
5
|
+
import { numAttr } from 'ngwr/utils';
|
|
6
|
+
|
|
7
|
+
/** Cubic ease-out — the shared tween curve for counter / count-up. */
|
|
8
|
+
function easeOutCubic(t) {
|
|
9
|
+
return 1 - Math.pow(1 - t, 3);
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* @license
|
|
14
|
+
*
|
|
15
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
16
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
17
|
+
*/
|
|
18
|
+
/**
|
|
19
|
+
* Animated number display with two modes:
|
|
20
|
+
*
|
|
21
|
+
* - **`odometer`** (default) — each digit is a vertical strip of 0-9 that
|
|
22
|
+
* rolls into place, continuously interpolated for smooth motion when the
|
|
23
|
+
* value changes.
|
|
24
|
+
* - **`tween`** — a single eased count-up between the previous and new value,
|
|
25
|
+
* rendered through `Intl.NumberFormat`.
|
|
26
|
+
*
|
|
27
|
+
* Reacts to `[value]` changes — animate from any number to any number.
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* ```html
|
|
31
|
+
* <wr-counter [value]="123456" mode="odometer" />
|
|
32
|
+
* <wr-counter [value]="9.99" mode="tween" [decimals]="2" prefix="$" />
|
|
33
|
+
* ```
|
|
34
|
+
*
|
|
35
|
+
* @see https://ngwr.dev/components/counter
|
|
36
|
+
*/
|
|
37
|
+
class WrCounter {
|
|
38
|
+
/** Target value. */
|
|
39
|
+
value = input.required(/* @ts-ignore */
|
|
40
|
+
...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
|
|
41
|
+
/** Animation mode. @default 'odometer' */
|
|
42
|
+
mode = input('odometer', /* @ts-ignore */
|
|
43
|
+
...(ngDevMode ? [{ debugName: "mode" }] : /* istanbul ignore next */ []));
|
|
44
|
+
/** Duration (ms). @default 900 */
|
|
45
|
+
duration = input(900, { ...(ngDevMode ? { debugName: "duration" } : /* istanbul ignore next */ {}), transform: (v) => Math.max(100, coerceNumberProperty(v, 900)) });
|
|
46
|
+
/** Fixed number of decimals. @default 0 */
|
|
47
|
+
decimals = input(0, { ...(ngDevMode ? { debugName: "decimals" } : /* istanbul ignore next */ {}), transform: (v) => Math.max(0, coerceNumberProperty(v, 0)) });
|
|
48
|
+
/** Optional prefix (e.g. `'$'`). */
|
|
49
|
+
prefix = input('', /* @ts-ignore */
|
|
50
|
+
...(ngDevMode ? [{ debugName: "prefix" }] : /* istanbul ignore next */ []));
|
|
51
|
+
/** Optional suffix (e.g. `'%'`). */
|
|
52
|
+
suffix = input('', /* @ts-ignore */
|
|
53
|
+
...(ngDevMode ? [{ debugName: "suffix" }] : /* istanbul ignore next */ []));
|
|
54
|
+
/** Group thousands. @default true */
|
|
55
|
+
grouping = input(true, /* @ts-ignore */
|
|
56
|
+
...(ngDevMode ? [{ debugName: "grouping" }] : /* istanbul ignore next */ []));
|
|
57
|
+
/** Pad integer part to at least this many digits. @default 0 (no padding) */
|
|
58
|
+
minIntegerDigits = input(0, { ...(ngDevMode ? { debugName: "minIntegerDigits" } : /* istanbul ignore next */ {}), transform: (v) => Math.max(0, coerceNumberProperty(v, 0)) });
|
|
59
|
+
current = signal(0, /* @ts-ignore */
|
|
60
|
+
...(ngDevMode ? [{ debugName: "current" }] : /* istanbul ignore next */ []));
|
|
61
|
+
locale = inject(LOCALE_ID);
|
|
62
|
+
isBrowser = isPlatformBrowser(inject(PLATFORM_ID));
|
|
63
|
+
rafId = null;
|
|
64
|
+
/** Tween-mode formatted output. */
|
|
65
|
+
tweenText = computed(() => this.format(this.current()), /* @ts-ignore */
|
|
66
|
+
...(ngDevMode ? [{ debugName: "tweenText" }] : /* istanbul ignore next */ []));
|
|
67
|
+
/** Odometer cells — one per character in the formatted target string. */
|
|
68
|
+
cells = computed(() => {
|
|
69
|
+
// Build the string with target sign + max length so we can interpolate
|
|
70
|
+
// each digit position smoothly.
|
|
71
|
+
const target = this.value();
|
|
72
|
+
const live = this.current();
|
|
73
|
+
const formattedTarget = this.format(target);
|
|
74
|
+
const formattedLive = this.format(live);
|
|
75
|
+
// Right-align so trailing digits line up.
|
|
76
|
+
const maxLen = Math.max(formattedTarget.length, formattedLive.length);
|
|
77
|
+
const padTarget = formattedTarget.padStart(maxLen, ' ');
|
|
78
|
+
const padLive = formattedLive.padStart(maxLen, ' ');
|
|
79
|
+
const cells = [];
|
|
80
|
+
for (let i = 0; i < maxLen; i++) {
|
|
81
|
+
const t = padTarget[i];
|
|
82
|
+
const l = padLive[i];
|
|
83
|
+
if (/[0-9]/.test(t) && /[0-9]/.test(l)) {
|
|
84
|
+
// Interpolate the fractional digit so the strip rolls smoothly —
|
|
85
|
+
// multi-digit rollover (9 → 0 carries 1) looks continuous.
|
|
86
|
+
const fraction = this.digitFractionAt(live, target, i, maxLen);
|
|
87
|
+
cells.push({ kind: 'digit', fraction });
|
|
88
|
+
}
|
|
89
|
+
else {
|
|
90
|
+
cells.push({ kind: 'static', char: t === ' ' ? '' : t });
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
return cells;
|
|
94
|
+
}, /* @ts-ignore */
|
|
95
|
+
...(ngDevMode ? [{ debugName: "cells" }] : /* istanbul ignore next */ []));
|
|
96
|
+
constructor() {
|
|
97
|
+
inject(DestroyRef).onDestroy(() => this.cancel());
|
|
98
|
+
effect(() => {
|
|
99
|
+
const target = this.value();
|
|
100
|
+
const start = this.current();
|
|
101
|
+
if (!this.isBrowser) {
|
|
102
|
+
this.current.set(target);
|
|
103
|
+
return;
|
|
104
|
+
}
|
|
105
|
+
this.cancel();
|
|
106
|
+
const startTs = performance.now();
|
|
107
|
+
const dur = this.duration();
|
|
108
|
+
const tick = (now) => {
|
|
109
|
+
const t = Math.min(1, (now - startTs) / dur);
|
|
110
|
+
// Snap exactly to target on the final frame. Without this,
|
|
111
|
+
// `start + (target - start) * 1` carries FP rounding (e.g.
|
|
112
|
+
// 0.1 + (0.3 - 0.1) * 1 = 0.30000000000000004), so
|
|
113
|
+
// `digitFractionAt`'s `live === target` rest-state check
|
|
114
|
+
// fails — wheels visibly stop on a fractional position and
|
|
115
|
+
// never settle to the clean integer glyph.
|
|
116
|
+
const v = t >= 1 ? target : start + (target - start) * easeOutCubic(t);
|
|
117
|
+
this.current.set(v);
|
|
118
|
+
if (t < 1)
|
|
119
|
+
this.rafId = requestAnimationFrame(tick);
|
|
120
|
+
else
|
|
121
|
+
this.rafId = null;
|
|
122
|
+
};
|
|
123
|
+
this.rafId = requestAnimationFrame(tick);
|
|
124
|
+
});
|
|
125
|
+
}
|
|
126
|
+
cancel() {
|
|
127
|
+
if (this.rafId !== null)
|
|
128
|
+
cancelAnimationFrame(this.rafId);
|
|
129
|
+
this.rafId = null;
|
|
130
|
+
}
|
|
131
|
+
format(n) {
|
|
132
|
+
return new Intl.NumberFormat(this.locale, {
|
|
133
|
+
minimumFractionDigits: this.decimals(),
|
|
134
|
+
maximumFractionDigits: this.decimals(),
|
|
135
|
+
minimumIntegerDigits: this.minIntegerDigits() || 1,
|
|
136
|
+
useGrouping: this.grouping(),
|
|
137
|
+
}).format(n);
|
|
138
|
+
}
|
|
139
|
+
/**
|
|
140
|
+
* Compute the smoothly-interpolated digit (0..10) at column `i` of the
|
|
141
|
+
* formatted live string. Returns the integer digit + a fraction so the
|
|
142
|
+
* strip CSS translate looks like a real rolling odometer.
|
|
143
|
+
*/
|
|
144
|
+
digitFractionAt(live, target, columnIndex, totalLen) {
|
|
145
|
+
// Determine the place value at this column. Account for grouping separators
|
|
146
|
+
// and the decimal point by counting digits to the right of this column in
|
|
147
|
+
// the formatted target.
|
|
148
|
+
const formattedTarget = this.format(target);
|
|
149
|
+
const padded = formattedTarget.padStart(totalLen, ' ');
|
|
150
|
+
const tail = padded.slice(columnIndex + 1);
|
|
151
|
+
const digitsRight = (tail.match(/[0-9]/g) ?? []).length;
|
|
152
|
+
const placePower = digitsRight - this.decimals();
|
|
153
|
+
const place = Math.pow(10, placePower);
|
|
154
|
+
const absLive = Math.abs(live);
|
|
155
|
+
const raw = absLive / place;
|
|
156
|
+
// Modulo 10 gives the digit at this column with fractional rollover —
|
|
157
|
+
// mid-animation this looks like a real wheel rolling between digits.
|
|
158
|
+
const mod = raw - Math.floor(raw / 10) * 10;
|
|
159
|
+
// At rest (live === target) every wheel must rest on an exact integer
|
|
160
|
+
// — otherwise upper digits show as partial (e.g. tens reads "5.6"
|
|
161
|
+
// for value 123456, visibly clipping between 5 and 6 in the
|
|
162
|
+
// overflow:hidden window). The continuous-mechanical look is only
|
|
163
|
+
// wanted DURING the tween, not after it settles.
|
|
164
|
+
if (live === target)
|
|
165
|
+
return Math.floor(mod + 1e-9);
|
|
166
|
+
return mod;
|
|
167
|
+
}
|
|
168
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: WrCounter, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
169
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.2", type: WrCounter, isStandalone: true, selector: "wr-counter", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: true, transformFunction: null }, mode: { classPropertyName: "mode", publicName: "mode", isSignal: true, isRequired: false, transformFunction: null }, duration: { classPropertyName: "duration", publicName: "duration", isSignal: true, isRequired: false, transformFunction: null }, decimals: { classPropertyName: "decimals", publicName: "decimals", isSignal: true, isRequired: false, transformFunction: null }, prefix: { classPropertyName: "prefix", publicName: "prefix", isSignal: true, isRequired: false, transformFunction: null }, suffix: { classPropertyName: "suffix", publicName: "suffix", isSignal: true, isRequired: false, transformFunction: null }, grouping: { classPropertyName: "grouping", publicName: "grouping", isSignal: true, isRequired: false, transformFunction: null }, minIntegerDigits: { classPropertyName: "minIntegerDigits", publicName: "minIntegerDigits", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "wr-counter" }, ngImport: i0, template: "@if (mode() === 'tween') {\n <span class=\"wr-counter__tween\">{{ prefix() }}{{ tweenText() }}{{ suffix() }}</span>\n} @else {\n <span class=\"wr-counter__odo\">\n @if (prefix()) {\n <span class=\"wr-counter__static\">{{ prefix() }}</span>\n }\n @for (cell of cells(); track $index) {\n @if (cell.kind === 'digit') {\n <span class=\"wr-counter__digit\">\n <span class=\"wr-counter__strip\" [style.transform]=\"`translateY(-${cell.fraction}em)`\">\n <span>0</span><span>1</span><span>2</span><span>3</span><span>4</span><span>5</span><span>6</span\n ><span>7</span><span>8</span><span>9</span>\n </span>\n </span>\n } @else {\n <span class=\"wr-counter__static\">{{ cell.char }}</span>\n }\n }\n @if (suffix()) {\n <span class=\"wr-counter__static\">{{ suffix() }}</span>\n }\n </span>\n}\n", encapsulation: i0.ViewEncapsulation.None });
|
|
170
|
+
}
|
|
171
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: WrCounter, decorators: [{
|
|
172
|
+
type: Component,
|
|
173
|
+
args: [{ selector: 'wr-counter', encapsulation: ViewEncapsulation.None, host: { class: 'wr-counter' }, template: "@if (mode() === 'tween') {\n <span class=\"wr-counter__tween\">{{ prefix() }}{{ tweenText() }}{{ suffix() }}</span>\n} @else {\n <span class=\"wr-counter__odo\">\n @if (prefix()) {\n <span class=\"wr-counter__static\">{{ prefix() }}</span>\n }\n @for (cell of cells(); track $index) {\n @if (cell.kind === 'digit') {\n <span class=\"wr-counter__digit\">\n <span class=\"wr-counter__strip\" [style.transform]=\"`translateY(-${cell.fraction}em)`\">\n <span>0</span><span>1</span><span>2</span><span>3</span><span>4</span><span>5</span><span>6</span\n ><span>7</span><span>8</span><span>9</span>\n </span>\n </span>\n } @else {\n <span class=\"wr-counter__static\">{{ cell.char }}</span>\n }\n }\n @if (suffix()) {\n <span class=\"wr-counter__static\">{{ suffix() }}</span>\n }\n </span>\n}\n" }]
|
|
174
|
+
}], ctorParameters: () => [], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: true }] }], mode: [{ type: i0.Input, args: [{ isSignal: true, alias: "mode", required: false }] }], duration: [{ type: i0.Input, args: [{ isSignal: true, alias: "duration", required: false }] }], decimals: [{ type: i0.Input, args: [{ isSignal: true, alias: "decimals", required: false }] }], prefix: [{ type: i0.Input, args: [{ isSignal: true, alias: "prefix", required: false }] }], suffix: [{ type: i0.Input, args: [{ isSignal: true, alias: "suffix", required: false }] }], grouping: [{ type: i0.Input, args: [{ isSignal: true, alias: "grouping", required: false }] }], minIntegerDigits: [{ type: i0.Input, args: [{ isSignal: true, alias: "minIntegerDigits", required: false }] }] } });
|
|
175
|
+
|
|
176
|
+
/**
|
|
177
|
+
* @license
|
|
178
|
+
*
|
|
179
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
180
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
181
|
+
*
|
|
182
|
+
* The spring-physics path is an adaptation of the CountUp effect by
|
|
183
|
+
* David Haz / reactbits.dev (https://www.reactbits.dev/text-animations/count-up).
|
|
184
|
+
* Same critically-damped formula, implemented inline with rAF — no
|
|
185
|
+
* external dependency.
|
|
186
|
+
*/
|
|
187
|
+
/**
|
|
188
|
+
* Animated number tick. Animates from `from` to the current `to`, formatting
|
|
189
|
+
* via `Intl.NumberFormat`. Re-runs whenever `to` changes.
|
|
190
|
+
*
|
|
191
|
+
* @example Basic
|
|
192
|
+
* ```html
|
|
193
|
+
* <wr-count-up [to]="12345" />
|
|
194
|
+
* <wr-count-up [to]="9.99" [decimals]="2" prefix="$" />
|
|
195
|
+
* ```
|
|
196
|
+
*
|
|
197
|
+
* @example Reactbits-style — spring curve + viewport trigger
|
|
198
|
+
* ```html
|
|
199
|
+
* <wr-count-up [to]="100" easing="spring" trigger="visible" [delay]="200" />
|
|
200
|
+
* ```
|
|
201
|
+
*
|
|
202
|
+
* @example Count down
|
|
203
|
+
* ```html
|
|
204
|
+
* <wr-count-up [from]="60" [to]="0" direction="down" />
|
|
205
|
+
* ```
|
|
206
|
+
*
|
|
207
|
+
* @see https://ngwr.dev/components/counter
|
|
208
|
+
*/
|
|
209
|
+
class WrCountUp {
|
|
210
|
+
/** Starting value. @default 0 */
|
|
211
|
+
from = input(0, { ...(ngDevMode ? { debugName: "from" } : /* istanbul ignore next */ {}), transform: numAttr(0) });
|
|
212
|
+
/** Target value. */
|
|
213
|
+
to = input.required(/* @ts-ignore */
|
|
214
|
+
...(ngDevMode ? [{ debugName: "to" }] : /* istanbul ignore next */ []));
|
|
215
|
+
/**
|
|
216
|
+
* Animation duration. Units depend on `easing`:
|
|
217
|
+
*
|
|
218
|
+
* - `ease-out` — milliseconds (default 1200, min 100)
|
|
219
|
+
* - `spring` — seconds (tunes spring stiffness; default 2)
|
|
220
|
+
*/
|
|
221
|
+
duration = input(1200, { ...(ngDevMode ? { debugName: "duration" } : /* istanbul ignore next */ {}), transform: numAttr(1200) });
|
|
222
|
+
/** Optional delay (ms) before the animation starts. @default 0 */
|
|
223
|
+
delay = input(0, { ...(ngDevMode ? { debugName: "delay" } : /* istanbul ignore next */ {}), transform: numAttr(0) });
|
|
224
|
+
/** Animation curve. @default 'ease-out' */
|
|
225
|
+
easing = input('ease-out', /* @ts-ignore */
|
|
226
|
+
...(ngDevMode ? [{ debugName: "easing" }] : /* istanbul ignore next */ []));
|
|
227
|
+
/**
|
|
228
|
+
* When to start the animation.
|
|
229
|
+
*
|
|
230
|
+
* - `'mount'` (default) — start as soon as the component is rendered.
|
|
231
|
+
* - `'visible'` — wait for the host to enter the viewport
|
|
232
|
+
* (IntersectionObserver). Useful for long pages or hero numbers
|
|
233
|
+
* below the fold.
|
|
234
|
+
*/
|
|
235
|
+
trigger = input('mount', /* @ts-ignore */
|
|
236
|
+
...(ngDevMode ? [{ debugName: "trigger" }] : /* istanbul ignore next */ []));
|
|
237
|
+
/** Counting direction. `'down'` swaps `from` ↔ `to`. @default 'up' */
|
|
238
|
+
direction = input('up', /* @ts-ignore */
|
|
239
|
+
...(ngDevMode ? [{ debugName: "direction" }] : /* istanbul ignore next */ []));
|
|
240
|
+
/** Fixed number of decimals. @default 0 */
|
|
241
|
+
decimals = input(0, { ...(ngDevMode ? { debugName: "decimals" } : /* istanbul ignore next */ {}), transform: (v) => Math.max(0, coerceNumberProperty(v, 0)) });
|
|
242
|
+
/** Optional prefix (e.g. `'$'`). */
|
|
243
|
+
prefix = input('', /* @ts-ignore */
|
|
244
|
+
...(ngDevMode ? [{ debugName: "prefix" }] : /* istanbul ignore next */ []));
|
|
245
|
+
/** Optional suffix (e.g. `'%'`). */
|
|
246
|
+
suffix = input('', /* @ts-ignore */
|
|
247
|
+
...(ngDevMode ? [{ debugName: "suffix" }] : /* istanbul ignore next */ []));
|
|
248
|
+
/** Disable grouping separators (`1,234` → `1234`). @default true (grouping on) */
|
|
249
|
+
grouping = input(true, /* @ts-ignore */
|
|
250
|
+
...(ngDevMode ? [{ debugName: "grouping" }] : /* istanbul ignore next */ []));
|
|
251
|
+
/** Emits when the animation begins. */
|
|
252
|
+
started = output();
|
|
253
|
+
/** Emits when the animation settles. */
|
|
254
|
+
completed = output();
|
|
255
|
+
value = signal(0, /* @ts-ignore */
|
|
256
|
+
...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
|
|
257
|
+
host = inject(ElementRef);
|
|
258
|
+
locale = inject(LOCALE_ID);
|
|
259
|
+
isBrowser = isPlatformBrowser(inject(PLATFORM_ID));
|
|
260
|
+
destroyRef = inject(DestroyRef);
|
|
261
|
+
rafId = null;
|
|
262
|
+
delayTimer;
|
|
263
|
+
observer = null;
|
|
264
|
+
hasFiredForVisible = false;
|
|
265
|
+
formatted = computed(() => {
|
|
266
|
+
return new Intl.NumberFormat(this.locale, {
|
|
267
|
+
minimumFractionDigits: this.decimals(),
|
|
268
|
+
maximumFractionDigits: this.decimals(),
|
|
269
|
+
useGrouping: this.grouping(),
|
|
270
|
+
}).format(this.value());
|
|
271
|
+
}, /* @ts-ignore */
|
|
272
|
+
...(ngDevMode ? [{ debugName: "formatted" }] : /* istanbul ignore next */ []));
|
|
273
|
+
constructor() {
|
|
274
|
+
// Seed the resting value so SSR / first paint show the start, not 0.
|
|
275
|
+
effect(() => {
|
|
276
|
+
const initial = this.direction() === 'down' ? this.to() : this.from();
|
|
277
|
+
this.value.set(initial);
|
|
278
|
+
});
|
|
279
|
+
if (!this.isBrowser)
|
|
280
|
+
return;
|
|
281
|
+
// Run the animation whenever the `to` target changes (or on first mount).
|
|
282
|
+
// For `trigger="visible"` the first run waits for the IntersectionObserver
|
|
283
|
+
// to fire; subsequent `to` changes re-run immediately.
|
|
284
|
+
effect(() => {
|
|
285
|
+
// Establish dependencies so the effect re-runs on `to` changes.
|
|
286
|
+
this.to();
|
|
287
|
+
this.from();
|
|
288
|
+
this.direction();
|
|
289
|
+
this.duration();
|
|
290
|
+
this.easing();
|
|
291
|
+
this.delay();
|
|
292
|
+
if (this.trigger() === 'visible' && !this.hasFiredForVisible)
|
|
293
|
+
return;
|
|
294
|
+
this.scheduleRun();
|
|
295
|
+
});
|
|
296
|
+
afterNextRender(() => {
|
|
297
|
+
if (this.trigger() === 'visible')
|
|
298
|
+
this.setupViewportTrigger();
|
|
299
|
+
});
|
|
300
|
+
this.destroyRef.onDestroy(() => this.cancel());
|
|
301
|
+
}
|
|
302
|
+
// Scheduling
|
|
303
|
+
setupViewportTrigger() {
|
|
304
|
+
this.observer = new IntersectionObserver((entries, obs) => {
|
|
305
|
+
for (const e of entries) {
|
|
306
|
+
if (e.isIntersecting && !this.hasFiredForVisible) {
|
|
307
|
+
obs.disconnect();
|
|
308
|
+
this.hasFiredForVisible = true;
|
|
309
|
+
this.scheduleRun();
|
|
310
|
+
break;
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
}, { threshold: 0, rootMargin: '0px' });
|
|
314
|
+
this.observer.observe(this.host.nativeElement);
|
|
315
|
+
}
|
|
316
|
+
scheduleRun() {
|
|
317
|
+
this.cancel();
|
|
318
|
+
const d = this.delay();
|
|
319
|
+
if (d > 0) {
|
|
320
|
+
this.delayTimer = setTimeout(() => this.run(), d);
|
|
321
|
+
}
|
|
322
|
+
else {
|
|
323
|
+
this.run();
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
run() {
|
|
327
|
+
const start = this.direction() === 'down' ? this.to() : this.from();
|
|
328
|
+
const end = this.direction() === 'down' ? this.from() : this.to();
|
|
329
|
+
this.started.emit();
|
|
330
|
+
if (this.easing() === 'spring')
|
|
331
|
+
this.tweenSpring(start, end);
|
|
332
|
+
else
|
|
333
|
+
this.tweenEaseOut(start, end);
|
|
334
|
+
}
|
|
335
|
+
// Tweens
|
|
336
|
+
tweenEaseOut(start, target) {
|
|
337
|
+
const duration = Math.max(100, this.duration());
|
|
338
|
+
const startTs = performance.now();
|
|
339
|
+
const tick = (now) => {
|
|
340
|
+
const t = Math.min(1, (now - startTs) / duration);
|
|
341
|
+
const v = start + (target - start) * easeOutCubic(t);
|
|
342
|
+
this.value.set(v);
|
|
343
|
+
if (t < 1) {
|
|
344
|
+
this.rafId = requestAnimationFrame(tick);
|
|
345
|
+
}
|
|
346
|
+
else {
|
|
347
|
+
this.completed.emit();
|
|
348
|
+
}
|
|
349
|
+
};
|
|
350
|
+
this.rafId = requestAnimationFrame(tick);
|
|
351
|
+
}
|
|
352
|
+
/**
|
|
353
|
+
* Critically-damped spring tween. Same formula as `motion/react`'s
|
|
354
|
+
* `useSpring` with mass = 1:
|
|
355
|
+
*
|
|
356
|
+
* damping = 20 + 40 / duration
|
|
357
|
+
* stiffness = 100 / duration
|
|
358
|
+
*
|
|
359
|
+
* We integrate `(spring force − damping force)` each frame until both
|
|
360
|
+
* displacement and velocity fall below epsilon.
|
|
361
|
+
*/
|
|
362
|
+
tweenSpring(start, target) {
|
|
363
|
+
const duration = Math.max(0.05, this.duration());
|
|
364
|
+
const damping = 20 + 40 / duration;
|
|
365
|
+
const stiffness = 100 / duration;
|
|
366
|
+
let current = start;
|
|
367
|
+
let velocity = 0;
|
|
368
|
+
let lastTs = 0;
|
|
369
|
+
const epsilon = 0.001 * Math.max(1, Math.abs(target - start));
|
|
370
|
+
const step = (ts) => {
|
|
371
|
+
const dt = lastTs === 0 ? 1 / 60 : Math.min(0.05, (ts - lastTs) / 1000);
|
|
372
|
+
lastTs = ts;
|
|
373
|
+
const displacement = current - target;
|
|
374
|
+
const accel = -stiffness * displacement - damping * velocity;
|
|
375
|
+
velocity += accel * dt;
|
|
376
|
+
current += velocity * dt;
|
|
377
|
+
this.value.set(current);
|
|
378
|
+
if (Math.abs(current - target) < epsilon && Math.abs(velocity) < epsilon * 10) {
|
|
379
|
+
this.value.set(target);
|
|
380
|
+
this.completed.emit();
|
|
381
|
+
return;
|
|
382
|
+
}
|
|
383
|
+
this.rafId = requestAnimationFrame(step);
|
|
384
|
+
};
|
|
385
|
+
this.rafId = requestAnimationFrame(step);
|
|
386
|
+
}
|
|
387
|
+
// Cleanup
|
|
388
|
+
cancel() {
|
|
389
|
+
if (this.rafId !== null)
|
|
390
|
+
cancelAnimationFrame(this.rafId);
|
|
391
|
+
this.rafId = null;
|
|
392
|
+
if (this.delayTimer !== undefined) {
|
|
393
|
+
clearTimeout(this.delayTimer);
|
|
394
|
+
this.delayTimer = undefined;
|
|
395
|
+
}
|
|
396
|
+
}
|
|
397
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: WrCountUp, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
398
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: WrCountUp, isStandalone: true, selector: "wr-count-up", inputs: { from: { classPropertyName: "from", publicName: "from", isSignal: true, isRequired: false, transformFunction: null }, to: { classPropertyName: "to", publicName: "to", isSignal: true, isRequired: true, transformFunction: null }, duration: { classPropertyName: "duration", publicName: "duration", isSignal: true, isRequired: false, transformFunction: null }, delay: { classPropertyName: "delay", publicName: "delay", isSignal: true, isRequired: false, transformFunction: null }, easing: { classPropertyName: "easing", publicName: "easing", isSignal: true, isRequired: false, transformFunction: null }, trigger: { classPropertyName: "trigger", publicName: "trigger", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, decimals: { classPropertyName: "decimals", publicName: "decimals", isSignal: true, isRequired: false, transformFunction: null }, prefix: { classPropertyName: "prefix", publicName: "prefix", isSignal: true, isRequired: false, transformFunction: null }, suffix: { classPropertyName: "suffix", publicName: "suffix", isSignal: true, isRequired: false, transformFunction: null }, grouping: { classPropertyName: "grouping", publicName: "grouping", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { started: "started", completed: "completed" }, host: { classAttribute: "wr-count-up" }, ngImport: i0, template: `{{ prefix() }}{{ formatted() }}{{ suffix() }}`, isInline: true, encapsulation: i0.ViewEncapsulation.None });
|
|
399
|
+
}
|
|
400
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: WrCountUp, decorators: [{
|
|
401
|
+
type: Component,
|
|
402
|
+
args: [{
|
|
403
|
+
selector: 'wr-count-up',
|
|
404
|
+
template: `{{ prefix() }}{{ formatted() }}{{ suffix() }}`,
|
|
405
|
+
encapsulation: ViewEncapsulation.None,
|
|
406
|
+
host: { class: 'wr-count-up' },
|
|
407
|
+
}]
|
|
408
|
+
}], ctorParameters: () => [], propDecorators: { from: [{ type: i0.Input, args: [{ isSignal: true, alias: "from", required: false }] }], to: [{ type: i0.Input, args: [{ isSignal: true, alias: "to", required: true }] }], duration: [{ type: i0.Input, args: [{ isSignal: true, alias: "duration", required: false }] }], delay: [{ type: i0.Input, args: [{ isSignal: true, alias: "delay", required: false }] }], easing: [{ type: i0.Input, args: [{ isSignal: true, alias: "easing", required: false }] }], trigger: [{ type: i0.Input, args: [{ isSignal: true, alias: "trigger", required: false }] }], direction: [{ type: i0.Input, args: [{ isSignal: true, alias: "direction", required: false }] }], decimals: [{ type: i0.Input, args: [{ isSignal: true, alias: "decimals", required: false }] }], prefix: [{ type: i0.Input, args: [{ isSignal: true, alias: "prefix", required: false }] }], suffix: [{ type: i0.Input, args: [{ isSignal: true, alias: "suffix", required: false }] }], grouping: [{ type: i0.Input, args: [{ isSignal: true, alias: "grouping", required: false }] }], started: [{ type: i0.Output, args: ["started"] }], completed: [{ type: i0.Output, args: ["completed"] }] } });
|
|
409
|
+
|
|
410
|
+
/**
|
|
411
|
+
* Generated bundle index. Do not edit.
|
|
412
|
+
*/
|
|
413
|
+
|
|
414
|
+
export { WrCountUp, WrCounter };
|
|
415
|
+
//# sourceMappingURL=ngwr-counter.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ngwr-counter.mjs","sources":["../../../projects/lib/counter/easing.ts","../../../projects/lib/counter/counter.ts","../../../projects/lib/counter/counter.html","../../../projects/lib/counter/count-up.ts","../../../projects/lib/counter/ngwr-counter.ts"],"sourcesContent":["/** Cubic ease-out — the shared tween curve for counter / count-up. */\nexport function easeOutCubic(t: number): number {\n return 1 - Math.pow(1 - t, 3);\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 { coerceNumberProperty } from '@angular/cdk/coercion';\nimport { isPlatformBrowser } from '@angular/common';\nimport {\n Component,\n DestroyRef,\n LOCALE_ID,\n PLATFORM_ID,\n ViewEncapsulation,\n computed,\n effect,\n inject,\n input,\n signal,\n} from '@angular/core';\n\nimport { easeOutCubic } from './easing';\nimport type { WrCounterMode } from './interfaces';\n\n/** Visual cell in odometer mode — either a 0-9 column or a static glyph. */\ntype Cell = { readonly kind: 'digit'; readonly fraction: number } | { readonly kind: 'static'; readonly char: string };\n\n/**\n * Animated number display with two modes:\n *\n * - **`odometer`** (default) — each digit is a vertical strip of 0-9 that\n * rolls into place, continuously interpolated for smooth motion when the\n * value changes.\n * - **`tween`** — a single eased count-up between the previous and new value,\n * rendered through `Intl.NumberFormat`.\n *\n * Reacts to `[value]` changes — animate from any number to any number.\n *\n * @example\n * ```html\n * <wr-counter [value]=\"123456\" mode=\"odometer\" />\n * <wr-counter [value]=\"9.99\" mode=\"tween\" [decimals]=\"2\" prefix=\"$\" />\n * ```\n *\n * @see https://ngwr.dev/components/counter\n */\n@Component({\n selector: 'wr-counter',\n templateUrl: './counter.html',\n encapsulation: ViewEncapsulation.None,\n host: { class: 'wr-counter' },\n})\nexport class WrCounter {\n /** Target value. */\n readonly value = input.required<number>();\n\n /** Animation mode. @default 'odometer' */\n readonly mode = input<WrCounterMode>('odometer');\n\n /** Duration (ms). @default 900 */\n readonly duration = input(900, {\n transform: (v: unknown): number => Math.max(100, coerceNumberProperty(v, 900)),\n });\n\n /** Fixed number of decimals. @default 0 */\n readonly decimals = input(0, { transform: (v: unknown): number => Math.max(0, coerceNumberProperty(v, 0)) });\n\n /** Optional prefix (e.g. `'$'`). */\n readonly prefix = input<string>('');\n\n /** Optional suffix (e.g. `'%'`). */\n readonly suffix = input<string>('');\n\n /** Group thousands. @default true */\n readonly grouping = input<boolean>(true);\n\n /** Pad integer part to at least this many digits. @default 0 (no padding) */\n readonly minIntegerDigits = input(0, {\n transform: (v: unknown): number => Math.max(0, coerceNumberProperty(v, 0)),\n });\n\n private readonly current = signal<number>(0);\n private readonly locale = inject(LOCALE_ID);\n private readonly isBrowser = isPlatformBrowser(inject(PLATFORM_ID));\n private rafId: number | null = null;\n\n /** Tween-mode formatted output. */\n protected readonly tweenText = computed(() => this.format(this.current()));\n\n /** Odometer cells — one per character in the formatted target string. */\n protected readonly cells = computed<readonly Cell[]>(() => {\n // Build the string with target sign + max length so we can interpolate\n // each digit position smoothly.\n const target = this.value();\n const live = this.current();\n const formattedTarget = this.format(target);\n const formattedLive = this.format(live);\n\n // Right-align so trailing digits line up.\n const maxLen = Math.max(formattedTarget.length, formattedLive.length);\n const padTarget = formattedTarget.padStart(maxLen, ' ');\n const padLive = formattedLive.padStart(maxLen, ' ');\n\n const cells: Cell[] = [];\n for (let i = 0; i < maxLen; i++) {\n const t = padTarget[i];\n const l = padLive[i];\n if (/[0-9]/.test(t) && /[0-9]/.test(l)) {\n // Interpolate the fractional digit so the strip rolls smoothly —\n // multi-digit rollover (9 → 0 carries 1) looks continuous.\n const fraction = this.digitFractionAt(live, target, i, maxLen);\n cells.push({ kind: 'digit', fraction });\n } else {\n cells.push({ kind: 'static', char: t === ' ' ? '' : t });\n }\n }\n return cells;\n });\n\n constructor() {\n inject(DestroyRef).onDestroy(() => this.cancel());\n\n effect(() => {\n const target = this.value();\n const start = this.current();\n if (!this.isBrowser) {\n this.current.set(target);\n return;\n }\n this.cancel();\n const startTs = performance.now();\n const dur = this.duration();\n const tick = (now: number): void => {\n const t = Math.min(1, (now - startTs) / dur);\n // Snap exactly to target on the final frame. Without this,\n // `start + (target - start) * 1` carries FP rounding (e.g.\n // 0.1 + (0.3 - 0.1) * 1 = 0.30000000000000004), so\n // `digitFractionAt`'s `live === target` rest-state check\n // fails — wheels visibly stop on a fractional position and\n // never settle to the clean integer glyph.\n const v = t >= 1 ? target : start + (target - start) * easeOutCubic(t);\n this.current.set(v);\n if (t < 1) this.rafId = requestAnimationFrame(tick);\n else this.rafId = null;\n };\n this.rafId = requestAnimationFrame(tick);\n });\n }\n\n private cancel(): void {\n if (this.rafId !== null) cancelAnimationFrame(this.rafId);\n this.rafId = null;\n }\n\n private format(n: number): string {\n return new Intl.NumberFormat(this.locale, {\n minimumFractionDigits: this.decimals(),\n maximumFractionDigits: this.decimals(),\n minimumIntegerDigits: this.minIntegerDigits() || 1,\n useGrouping: this.grouping(),\n }).format(n);\n }\n\n /**\n * Compute the smoothly-interpolated digit (0..10) at column `i` of the\n * formatted live string. Returns the integer digit + a fraction so the\n * strip CSS translate looks like a real rolling odometer.\n */\n private digitFractionAt(live: number, target: number, columnIndex: number, totalLen: number): number {\n // Determine the place value at this column. Account for grouping separators\n // and the decimal point by counting digits to the right of this column in\n // the formatted target.\n const formattedTarget = this.format(target);\n const padded = formattedTarget.padStart(totalLen, ' ');\n const tail = padded.slice(columnIndex + 1);\n const digitsRight = (tail.match(/[0-9]/g) ?? []).length;\n const placePower = digitsRight - this.decimals();\n const place = Math.pow(10, placePower);\n const absLive = Math.abs(live);\n const raw = absLive / place;\n // Modulo 10 gives the digit at this column with fractional rollover —\n // mid-animation this looks like a real wheel rolling between digits.\n const mod = raw - Math.floor(raw / 10) * 10;\n // At rest (live === target) every wheel must rest on an exact integer\n // — otherwise upper digits show as partial (e.g. tens reads \"5.6\"\n // for value 123456, visibly clipping between 5 and 6 in the\n // overflow:hidden window). The continuous-mechanical look is only\n // wanted DURING the tween, not after it settles.\n if (live === target) return Math.floor(mod + 1e-9);\n return mod;\n }\n}\n","@if (mode() === 'tween') {\n <span class=\"wr-counter__tween\">{{ prefix() }}{{ tweenText() }}{{ suffix() }}</span>\n} @else {\n <span class=\"wr-counter__odo\">\n @if (prefix()) {\n <span class=\"wr-counter__static\">{{ prefix() }}</span>\n }\n @for (cell of cells(); track $index) {\n @if (cell.kind === 'digit') {\n <span class=\"wr-counter__digit\">\n <span class=\"wr-counter__strip\" [style.transform]=\"`translateY(-${cell.fraction}em)`\">\n <span>0</span><span>1</span><span>2</span><span>3</span><span>4</span><span>5</span><span>6</span\n ><span>7</span><span>8</span><span>9</span>\n </span>\n </span>\n } @else {\n <span class=\"wr-counter__static\">{{ cell.char }}</span>\n }\n }\n @if (suffix()) {\n <span class=\"wr-counter__static\">{{ suffix() }}</span>\n }\n </span>\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 * The spring-physics path is an adaptation of the CountUp effect by\n * David Haz / reactbits.dev (https://www.reactbits.dev/text-animations/count-up).\n * Same critically-damped formula, implemented inline with rAF — no\n * external dependency.\n */\n\nimport { coerceNumberProperty } from '@angular/cdk/coercion';\nimport { isPlatformBrowser } from '@angular/common';\nimport {\n Component,\n DestroyRef,\n ElementRef,\n LOCALE_ID,\n PLATFORM_ID,\n ViewEncapsulation,\n afterNextRender,\n computed,\n effect,\n inject,\n input,\n output,\n signal,\n} from '@angular/core';\n\nimport { numAttr } from 'ngwr/utils';\n\nimport { easeOutCubic } from './easing';\nimport type { WrCountUpDirection, WrCountUpEasing, WrCountUpTrigger } from './interfaces';\n\n/**\n * Animated number tick. Animates from `from` to the current `to`, formatting\n * via `Intl.NumberFormat`. Re-runs whenever `to` changes.\n *\n * @example Basic\n * ```html\n * <wr-count-up [to]=\"12345\" />\n * <wr-count-up [to]=\"9.99\" [decimals]=\"2\" prefix=\"$\" />\n * ```\n *\n * @example Reactbits-style — spring curve + viewport trigger\n * ```html\n * <wr-count-up [to]=\"100\" easing=\"spring\" trigger=\"visible\" [delay]=\"200\" />\n * ```\n *\n * @example Count down\n * ```html\n * <wr-count-up [from]=\"60\" [to]=\"0\" direction=\"down\" />\n * ```\n *\n * @see https://ngwr.dev/components/counter\n */\n@Component({\n selector: 'wr-count-up',\n template: `{{ prefix() }}{{ formatted() }}{{ suffix() }}`,\n encapsulation: ViewEncapsulation.None,\n host: { class: 'wr-count-up' },\n})\nexport class WrCountUp {\n /** Starting value. @default 0 */\n readonly from = input(0, { transform: numAttr(0) });\n\n /** Target value. */\n readonly to = input.required<number>();\n\n /**\n * Animation duration. Units depend on `easing`:\n *\n * - `ease-out` — milliseconds (default 1200, min 100)\n * - `spring` — seconds (tunes spring stiffness; default 2)\n */\n readonly duration = input(1200, { transform: numAttr(1200) });\n\n /** Optional delay (ms) before the animation starts. @default 0 */\n readonly delay = input(0, { transform: numAttr(0) });\n\n /** Animation curve. @default 'ease-out' */\n readonly easing = input<WrCountUpEasing>('ease-out');\n\n /**\n * When to start the animation.\n *\n * - `'mount'` (default) — start as soon as the component is rendered.\n * - `'visible'` — wait for the host to enter the viewport\n * (IntersectionObserver). Useful for long pages or hero numbers\n * below the fold.\n */\n readonly trigger = input<WrCountUpTrigger>('mount');\n\n /** Counting direction. `'down'` swaps `from` ↔ `to`. @default 'up' */\n readonly direction = input<WrCountUpDirection>('up');\n\n /** Fixed number of decimals. @default 0 */\n readonly decimals = input(0, { transform: (v: unknown): number => Math.max(0, coerceNumberProperty(v, 0)) });\n\n /** Optional prefix (e.g. `'$'`). */\n readonly prefix = input<string>('');\n\n /** Optional suffix (e.g. `'%'`). */\n readonly suffix = input<string>('');\n\n /** Disable grouping separators (`1,234` → `1234`). @default true (grouping on) */\n readonly grouping = input<boolean>(true);\n\n /** Emits when the animation begins. */\n readonly started = output<void>();\n\n /** Emits when the animation settles. */\n readonly completed = output<void>();\n\n private readonly value = signal<number>(0);\n private readonly host = inject<ElementRef<HTMLElement>>(ElementRef);\n private readonly locale = inject(LOCALE_ID);\n private readonly isBrowser = isPlatformBrowser(inject(PLATFORM_ID));\n private readonly destroyRef = inject(DestroyRef);\n\n private rafId: number | null = null;\n private delayTimer: ReturnType<typeof setTimeout> | undefined;\n private observer: IntersectionObserver | null = null;\n private hasFiredForVisible = false;\n\n protected readonly formatted = computed(() => {\n return new Intl.NumberFormat(this.locale, {\n minimumFractionDigits: this.decimals(),\n maximumFractionDigits: this.decimals(),\n useGrouping: this.grouping(),\n }).format(this.value());\n });\n\n constructor() {\n // Seed the resting value so SSR / first paint show the start, not 0.\n effect(() => {\n const initial = this.direction() === 'down' ? this.to() : this.from();\n this.value.set(initial);\n });\n\n if (!this.isBrowser) return;\n\n // Run the animation whenever the `to` target changes (or on first mount).\n // For `trigger=\"visible\"` the first run waits for the IntersectionObserver\n // to fire; subsequent `to` changes re-run immediately.\n effect(() => {\n // Establish dependencies so the effect re-runs on `to` changes.\n this.to();\n this.from();\n this.direction();\n this.duration();\n this.easing();\n this.delay();\n\n if (this.trigger() === 'visible' && !this.hasFiredForVisible) return;\n this.scheduleRun();\n });\n\n afterNextRender(() => {\n if (this.trigger() === 'visible') this.setupViewportTrigger();\n });\n\n this.destroyRef.onDestroy(() => this.cancel());\n }\n\n // Scheduling\n\n private setupViewportTrigger(): void {\n this.observer = new IntersectionObserver(\n (entries, obs) => {\n for (const e of entries) {\n if (e.isIntersecting && !this.hasFiredForVisible) {\n obs.disconnect();\n this.hasFiredForVisible = true;\n this.scheduleRun();\n break;\n }\n }\n },\n { threshold: 0, rootMargin: '0px' }\n );\n this.observer.observe(this.host.nativeElement);\n }\n\n private scheduleRun(): void {\n this.cancel();\n const d = this.delay();\n if (d > 0) {\n this.delayTimer = setTimeout(() => this.run(), d);\n } else {\n this.run();\n }\n }\n\n private run(): void {\n const start = this.direction() === 'down' ? this.to() : this.from();\n const end = this.direction() === 'down' ? this.from() : this.to();\n this.started.emit();\n if (this.easing() === 'spring') this.tweenSpring(start, end);\n else this.tweenEaseOut(start, end);\n }\n\n // Tweens\n\n private tweenEaseOut(start: number, target: number): void {\n const duration = Math.max(100, this.duration());\n const startTs = performance.now();\n const tick = (now: number): void => {\n const t = Math.min(1, (now - startTs) / duration);\n const v = start + (target - start) * easeOutCubic(t);\n this.value.set(v);\n if (t < 1) {\n this.rafId = requestAnimationFrame(tick);\n } else {\n this.completed.emit();\n }\n };\n this.rafId = requestAnimationFrame(tick);\n }\n\n /**\n * Critically-damped spring tween. Same formula as `motion/react`'s\n * `useSpring` with mass = 1:\n *\n * damping = 20 + 40 / duration\n * stiffness = 100 / duration\n *\n * We integrate `(spring force − damping force)` each frame until both\n * displacement and velocity fall below epsilon.\n */\n private tweenSpring(start: number, target: number): void {\n const duration = Math.max(0.05, this.duration());\n const damping = 20 + 40 / duration;\n const stiffness = 100 / duration;\n let current = start;\n let velocity = 0;\n let lastTs = 0;\n const epsilon = 0.001 * Math.max(1, Math.abs(target - start));\n\n const step = (ts: number): void => {\n const dt = lastTs === 0 ? 1 / 60 : Math.min(0.05, (ts - lastTs) / 1000);\n lastTs = ts;\n\n const displacement = current - target;\n const accel = -stiffness * displacement - damping * velocity;\n velocity += accel * dt;\n current += velocity * dt;\n this.value.set(current);\n\n if (Math.abs(current - target) < epsilon && Math.abs(velocity) < epsilon * 10) {\n this.value.set(target);\n this.completed.emit();\n return;\n }\n this.rafId = requestAnimationFrame(step);\n };\n this.rafId = requestAnimationFrame(step);\n }\n\n // Cleanup\n\n private cancel(): void {\n if (this.rafId !== null) cancelAnimationFrame(this.rafId);\n this.rafId = null;\n if (this.delayTimer !== undefined) {\n clearTimeout(this.delayTimer);\n this.delayTimer = undefined;\n }\n }\n}\n\nexport type { WrCountUpEasing, WrCountUpTrigger, WrCountUpDirection } from './interfaces';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAAA;AACM,SAAU,YAAY,CAAC,CAAS,EAAA;AACpC,IAAA,OAAO,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;AAC/B;;ACHA;;;;;AAKG;AAuBH;;;;;;;;;;;;;;;;;;AAkBG;MAOU,SAAS,CAAA;;IAEX,KAAK,GAAG,KAAK,CAAC,QAAQ;8EAAU;;IAGhC,IAAI,GAAG,KAAK,CAAgB,UAAU;6EAAC;;IAGvC,QAAQ,GAAG,KAAK,CAAC,GAAG,EAAA,EAAA,IAAA,SAAA,GAAA,EAAA,SAAA,EAAA,UAAA,EAAA,8BAAA,EAAA,CAAA,EAC3B,SAAS,EAAE,CAAC,CAAU,KAAa,IAAI,CAAC,GAAG,CAAC,GAAG,EAAE,oBAAoB,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC,EAAA,CAC9E;;IAGO,QAAQ,GAAG,KAAK,CAAC,CAAC,EAAA,EAAA,IAAA,SAAA,GAAA,EAAA,SAAA,EAAA,UAAA,EAAA,8BAAA,EAAA,CAAA,EAAI,SAAS,EAAE,CAAC,CAAU,KAAa,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,oBAAoB,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAA,CAAG;;IAGnG,MAAM,GAAG,KAAK,CAAS,EAAE;+EAAC;;IAG1B,MAAM,GAAG,KAAK,CAAS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