ngwr 3.0.0 → 4.0.1
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/README.md +10 -7
- package/alert/alert-type.d.ts +7 -0
- package/alert/alert.component.d.ts +21 -0
- package/alert/alert.module.d.ts +7 -0
- package/alert/index.d.ts +5 -0
- package/alert/public-api.d.ts +9 -0
- package/alert/styles/_index.scss +58 -0
- package/alert/styles/theming.scss +26 -0
- package/alert/styles/vars.scss +11 -0
- package/avatar/avatar.component.d.ts +27 -0
- package/avatar/avatar.module.d.ts +7 -0
- package/avatar/index.d.ts +5 -0
- package/avatar/public-api.d.ts +8 -0
- package/avatar/styles/_index.scss +39 -0
- package/button/button-group.component.d.ts +12 -0
- package/button/button.component.d.ts +26 -58
- package/button/button.module.d.ts +2 -1
- package/button/index.d.ts +5 -2
- package/button/public-api.d.ts +9 -0
- package/button/styles/_index.scss +187 -0
- package/button/styles/vars.scss +13 -0
- package/{core/abstract/base.d.ts → cdk/base.directive.d.ts} +7 -1
- package/cdk/index.d.ts +5 -0
- package/cdk/public-api.d.ts +7 -0
- package/cdk/rxjs/index.d.ts +5 -0
- package/cdk/rxjs/is-array.d.ts +8 -0
- package/cdk/rxjs/is-defined.d.ts +8 -0
- package/cdk/rxjs/is-not-empty-array.d.ts +8 -0
- package/cdk/rxjs/is-observable.d.ts +9 -0
- package/cdk/rxjs/public-api.d.ts +10 -0
- package/cdk/types/index.d.ts +5 -0
- package/cdk/types/maybe.d.ts +7 -0
- package/cdk/types/public-api.d.ts +9 -0
- package/cdk/types/safe-any.d.ts +7 -0
- package/{core/color/color.d.ts → cdk/types/theme-color.d.ts} +6 -0
- package/cdk/utils/generate-random-id.d.ts +12 -0
- package/cdk/utils/index.d.ts +5 -0
- package/cdk/utils/public-api.d.ts +7 -0
- package/checkbox/checkbox.component.d.ts +24 -45
- package/checkbox/checkbox.module.d.ts +1 -1
- package/checkbox/index.d.ts +5 -2
- package/checkbox/public-api.d.ts +8 -0
- package/checkbox/styles/_index.scss +86 -0
- package/checkbox/styles/vars.scss +16 -0
- package/dialog/dialog-animations.d.ts +7 -1
- package/dialog/{dialog-base.d.ts → dialog-base.directive.d.ts} +13 -7
- package/dialog/dialog-close.directive.d.ts +9 -0
- package/dialog/dialog-content.directive.d.ts +6 -0
- package/dialog/dialog-data.token.d.ts +8 -0
- package/dialog/dialog-footer.directive.d.ts +8 -0
- package/dialog/dialog-options.d.ts +19 -0
- package/dialog/dialog-ref.d.ts +19 -13
- package/dialog/dialog-title.directive.d.ts +6 -0
- package/dialog/dialog.component.d.ts +28 -0
- package/dialog/dialog.module.d.ts +11 -0
- package/dialog/dialog.service.d.ts +28 -0
- package/dialog/index.d.ts +5 -9
- package/dialog/public-api.d.ts +18 -0
- package/dialog/{dialog.scss → styles/_index.scss} +2 -0
- package/dialog/styles/vars.scss +7 -0
- package/divider/divider.component.d.ts +8 -35
- package/divider/divider.module.d.ts +1 -1
- package/divider/index.d.ts +5 -2
- package/divider/public-api.d.ts +8 -0
- package/divider/{divider.scss → styles/_index.scss} +1 -1
- package/esm2022/alert/alert-type.mjs +8 -0
- package/esm2022/alert/alert.component.mjs +54 -0
- package/esm2022/alert/alert.module.mjs +22 -0
- package/esm2022/alert/ngwr-alert.mjs +5 -0
- package/esm2022/alert/public-api.mjs +10 -0
- package/esm2022/avatar/avatar.component.mjs +77 -0
- package/esm2022/avatar/avatar.module.mjs +22 -0
- package/esm2022/avatar/ngwr-avatar.mjs +5 -0
- package/esm2022/avatar/public-api.mjs +9 -0
- package/esm2022/button/button-group.component.mjs +36 -0
- package/esm2022/button/button.component.mjs +55 -163
- package/esm2022/button/button.module.mjs +15 -8
- package/esm2022/button/ngwr-button.mjs +2 -2
- package/esm2022/button/public-api.mjs +10 -0
- package/esm2022/cdk/base.directive.mjs +27 -0
- package/esm2022/cdk/ngwr-cdk.mjs +5 -0
- package/esm2022/cdk/public-api.mjs +8 -0
- package/esm2022/cdk/rxjs/is-array.mjs +10 -0
- package/esm2022/cdk/rxjs/is-defined.mjs +10 -0
- package/esm2022/cdk/rxjs/is-not-empty-array.mjs +10 -0
- package/esm2022/cdk/rxjs/is-observable.mjs +10 -0
- package/esm2022/cdk/rxjs/ngwr-cdk-rxjs.mjs +5 -0
- package/esm2022/cdk/rxjs/public-api.mjs +11 -0
- package/esm2022/cdk/types/maybe.mjs +8 -0
- package/esm2022/cdk/types/ngwr-cdk-types.mjs +5 -0
- package/esm2022/cdk/types/public-api.mjs +10 -0
- package/esm2022/cdk/types/safe-any.mjs +8 -0
- package/esm2022/cdk/types/theme-color.mjs +17 -0
- package/esm2022/cdk/utils/generate-random-id.mjs +17 -0
- package/esm2022/cdk/utils/ngwr-cdk-utils.mjs +5 -0
- package/esm2022/cdk/utils/public-api.mjs +8 -0
- package/esm2022/checkbox/checkbox.component.mjs +54 -120
- package/esm2022/checkbox/checkbox.module.mjs +14 -8
- package/esm2022/checkbox/ngwr-checkbox.mjs +2 -2
- package/esm2022/checkbox/public-api.mjs +9 -0
- package/esm2022/dialog/dialog-animations.mjs +8 -2
- package/esm2022/dialog/dialog-base.directive.mjs +95 -0
- package/esm2022/dialog/dialog-close.directive.mjs +33 -0
- package/esm2022/dialog/dialog-content.directive.mjs +25 -0
- package/esm2022/dialog/dialog-data.token.mjs +9 -0
- package/esm2022/dialog/dialog-footer.directive.mjs +36 -0
- package/esm2022/dialog/dialog-options.mjs +9 -0
- package/esm2022/dialog/dialog-ref.mjs +22 -16
- package/esm2022/dialog/dialog-title.directive.mjs +25 -0
- package/esm2022/dialog/dialog.component.mjs +57 -0
- package/esm2022/dialog/dialog.module.mjs +38 -0
- package/esm2022/dialog/dialog.service.mjs +107 -0
- package/esm2022/dialog/ngwr-dialog.mjs +2 -2
- package/esm2022/dialog/public-api.mjs +19 -0
- package/esm2022/divider/divider.component.mjs +16 -57
- package/esm2022/divider/divider.module.mjs +8 -8
- package/esm2022/divider/ngwr-divider.mjs +2 -2
- package/esm2022/divider/public-api.mjs +9 -0
- package/esm2022/form/form-error.component.mjs +33 -0
- package/esm2022/form/form-item.component.mjs +43 -0
- package/esm2022/form/form.module.mjs +23 -0
- package/esm2022/form/ngwr-form.mjs +2 -2
- package/esm2022/form/public-api.mjs +10 -0
- package/esm2022/icon/icon.component.mjs +82 -0
- package/esm2022/icon/icon.module.mjs +22 -0
- package/esm2022/icon/icon.service.mjs +40 -0
- package/esm2022/icon/icons.mjs +289 -279
- package/esm2022/icon/ngwr-icon.mjs +2 -2
- package/esm2022/icon/provide-wr-icons.mjs +17 -0
- package/esm2022/icon/public-api.mjs +12 -0
- package/esm2022/input/input-types.mjs +1 -1
- package/esm2022/input/input.component.mjs +123 -0
- package/esm2022/input/input.module.mjs +22 -0
- package/esm2022/input/ngwr-input.mjs +2 -2
- package/esm2022/input/public-api.mjs +10 -0
- package/esm2022/ngwr.mjs +2 -2
- package/esm2022/pipes/new-array.pipe.mjs +23 -0
- package/esm2022/pipes/ngwr-pipes.mjs +5 -0
- package/esm2022/pipes/pipes.module.mjs +22 -0
- package/esm2022/pipes/public-api.mjs +9 -0
- package/esm2022/progress/ngwr-progress.mjs +5 -0
- package/esm2022/progress/progress.component.mjs +42 -0
- package/esm2022/progress/progress.module.mjs +22 -0
- package/esm2022/progress/public-api.mjs +9 -0
- package/esm2022/public-api.mjs +3 -0
- package/esm2022/qr/generator.mjs +84 -0
- package/esm2022/qr/ngwr-qr.mjs +5 -0
- package/esm2022/qr/public-api.mjs +9 -0
- package/esm2022/qr/qr.component.mjs +90 -0
- package/esm2022/qr/qr.module.mjs +22 -0
- package/esm2022/qr/qrcodegen.mjs +872 -0
- package/esm2022/skeleton/index.mjs +3 -3
- package/esm2022/skeleton/skeleton.component.mjs +43 -0
- package/esm2022/skeleton/skeleton.module.mjs +16 -0
- package/esm2022/spinner/index.mjs +3 -3
- package/esm2022/spinner/spinner.component.mjs +33 -0
- package/esm2022/spinner/spinner.module.mjs +22 -0
- package/esm2022/tag/ngwr-tag.mjs +2 -2
- package/esm2022/tag/public-api.mjs +9 -0
- package/esm2022/tag/tag.component.mjs +74 -0
- package/esm2022/tag/tag.module.mjs +16 -0
- package/fesm2022/ngwr-alert.mjs +94 -0
- package/fesm2022/ngwr-alert.mjs.map +1 -0
- package/fesm2022/ngwr-avatar.mjs +110 -0
- package/fesm2022/ngwr-avatar.mjs.map +1 -0
- package/fesm2022/ngwr-button.mjs +108 -169
- package/fesm2022/ngwr-button.mjs.map +1 -1
- package/fesm2022/ngwr-cdk-rxjs.mjs +53 -0
- package/fesm2022/ngwr-cdk-rxjs.mjs.map +1 -0
- package/fesm2022/ngwr-cdk-types.mjs +44 -0
- package/fesm2022/ngwr-cdk-types.mjs.map +1 -0
- package/fesm2022/ngwr-cdk-utils.mjs +30 -0
- package/fesm2022/ngwr-cdk-utils.mjs.map +1 -0
- package/fesm2022/ngwr-cdk.mjs +41 -0
- package/fesm2022/ngwr-cdk.mjs.map +1 -0
- package/fesm2022/ngwr-checkbox.mjs +73 -126
- package/fesm2022/ngwr-checkbox.mjs.map +1 -1
- package/fesm2022/ngwr-dialog.mjs +225 -165
- package/fesm2022/ngwr-dialog.mjs.map +1 -1
- package/fesm2022/ngwr-divider.mjs +29 -63
- package/fesm2022/ngwr-divider.mjs.map +1 -1
- package/fesm2022/ngwr-form.mjs +72 -54
- package/fesm2022/ngwr-form.mjs.map +1 -1
- package/fesm2022/ngwr-icon.mjs +445 -368
- package/fesm2022/ngwr-icon.mjs.map +1 -1
- package/fesm2022/ngwr-input.mjs +101 -208
- package/fesm2022/ngwr-input.mjs.map +1 -1
- package/fesm2022/ngwr-pipes.mjs +56 -0
- package/fesm2022/ngwr-pipes.mjs.map +1 -0
- package/fesm2022/ngwr-progress.mjs +75 -0
- package/fesm2022/ngwr-progress.mjs.map +1 -0
- package/fesm2022/{ngwr-qrcode.mjs → ngwr-qr.mjs} +72 -113
- package/fesm2022/ngwr-qr.mjs.map +1 -0
- package/fesm2022/ngwr-skeleton.mjs +19 -22
- package/fesm2022/ngwr-skeleton.mjs.map +1 -1
- package/fesm2022/ngwr-spinner.mjs +35 -19
- package/fesm2022/ngwr-spinner.mjs.map +1 -1
- package/fesm2022/ngwr-tag.mjs +46 -49
- package/fesm2022/ngwr-tag.mjs.map +1 -1
- package/fesm2022/ngwr.mjs +1 -1
- package/fesm2022/ngwr.mjs.map +1 -1
- package/form/form-error.component.d.ts +11 -0
- package/form/form-item.component.d.ts +14 -0
- package/form/form.module.d.ts +8 -0
- package/form/index.d.ts +5 -3
- package/form/public-api.d.ts +9 -0
- package/icon/icon.component.d.ts +19 -0
- package/icon/icon.module.d.ts +7 -0
- package/icon/icon.service.d.ts +23 -0
- package/icon/icons.d.ts +115 -101
- package/icon/index.d.ts +5 -4
- package/icon/provide-wr-icons.d.ts +9 -0
- package/icon/public-api.d.ts +11 -0
- package/icon/{icon.scss → styles/_index.scss} +4 -2
- package/icon/styles/vars.scss +3 -0
- package/index.d.ts +5 -2
- package/input/index.d.ts +5 -2
- package/input/input-types.d.ts +0 -2
- package/input/input.component.d.ts +43 -0
- package/input/input.module.d.ts +7 -0
- package/input/public-api.d.ts +9 -0
- package/input/styles/_index.scss +107 -0
- package/input/styles/vars.scss +16 -0
- package/package.json +110 -57
- package/pipes/index.d.ts +5 -0
- package/pipes/new-array.pipe.d.ts +13 -0
- package/pipes/pipes.module.d.ts +7 -0
- package/pipes/public-api.d.ts +8 -0
- package/progress/index.d.ts +5 -0
- package/progress/progress.component.d.ts +10 -0
- package/progress/progress.module.d.ts +7 -0
- package/progress/public-api.d.ts +8 -0
- package/progress/styles/_index.scss +24 -0
- package/progress/styles/theming.scss +8 -0
- package/progress/styles/vars.scss +6 -0
- package/public-api.d.ts +2 -0
- package/qr/index.d.ts +5 -0
- package/qr/public-api.d.ts +8 -0
- package/qr/qr.component.d.ts +31 -0
- package/qr/qr.module.d.ts +7 -0
- package/skeleton/index.d.ts +2 -2
- package/skeleton/skeleton.component.d.ts +10 -0
- package/skeleton/{skeleton-module.d.ts → skeleton.module.d.ts} +2 -3
- package/skeleton/{skeleton.scss → styles/_index.scss} +1 -1
- package/spinner/index.d.ts +2 -2
- package/spinner/spinner.component.d.ts +11 -0
- package/spinner/{spinner-module.d.ts → spinner.module.d.ts} +2 -2
- package/spinner/{spinner.scss → styles/_index.scss} +2 -1
- package/styles/animations.scss +4 -4
- package/styles/cdk.scss +4 -0
- package/styles/colors.scss +72 -0
- package/styles/grid.scss +1 -2
- package/styles/reset.scss +2 -2
- package/styles/variables.scss +78 -0
- package/styles.scss +23 -0
- package/tag/index.d.ts +5 -2
- package/tag/public-api.d.ts +8 -0
- package/tag/styles/_index.scss +32 -0
- package/tag/styles/theming.scss +21 -0
- package/tag/styles/vars.scss +12 -0
- package/tag/tag.component.d.ts +21 -0
- package/tag/tag.module.d.ts +7 -0
- package/_grid.scss +0 -2
- package/_index.scss +0 -31
- package/backdrop/backdrop.scss +0 -3
- package/button/button.scss +0 -160
- package/checkbox/checkbox.scss +0 -103
- package/core/abstract/index.d.ts +0 -1
- package/core/color/index.d.ts +0 -2
- package/core/color/is-theme-color.d.ts +0 -2
- package/core/decorators/index.d.ts +0 -1
- package/core/decorators/input-boolean.d.ts +0 -1
- package/core/overlay/connected-overlay-directive.d.ts +0 -16
- package/core/overlay/get-placement-name.d.ts +0 -2
- package/core/overlay/index.d.ts +0 -5
- package/core/overlay/overlay-module.d.ts +0 -7
- package/core/overlay/overlay.scss +0 -9
- package/core/overlay/position-map.d.ts +0 -17
- package/core/overlay/position-type.d.ts +0 -2
- package/core/types/index.d.ts +0 -3
- package/core/types/on-change-type.d.ts +0 -2
- package/core/types/on-touched-type.d.ts +0 -2
- package/core/types/safe-any.d.ts +0 -1
- package/dialog/dialog-config.d.ts +0 -11
- package/dialog/dialog-container.d.ts +0 -22
- package/dialog/dialog-content-directives.d.ts +0 -31
- package/dialog/dialog-module.d.ts +0 -12
- package/dialog/dialog-service.d.ts +0 -27
- package/dialog/dialog-tokens.d.ts +0 -2
- package/esm2022/button/index.mjs +0 -3
- package/esm2022/checkbox/index.mjs +0 -3
- package/esm2022/core/abstract/base.mjs +0 -18
- package/esm2022/core/abstract/index.mjs +0 -2
- package/esm2022/core/abstract/ngwr-core-abstract.mjs +0 -5
- package/esm2022/core/color/color.mjs +0 -11
- package/esm2022/core/color/index.mjs +0 -3
- package/esm2022/core/color/is-theme-color.mjs +0 -9
- package/esm2022/core/color/ngwr-core-color.mjs +0 -5
- package/esm2022/core/decorators/index.mjs +0 -2
- package/esm2022/core/decorators/input-boolean.mjs +0 -15
- package/esm2022/core/decorators/ngwr-core-decorators.mjs +0 -5
- package/esm2022/core/overlay/connected-overlay-directive.mjs +0 -98
- package/esm2022/core/overlay/get-placement-name.mjs +0 -13
- package/esm2022/core/overlay/index.mjs +0 -5
- package/esm2022/core/overlay/ngwr-core-overlay.mjs +0 -5
- package/esm2022/core/overlay/overlay-module.mjs +0 -16
- package/esm2022/core/overlay/position-map.mjs +0 -18
- package/esm2022/core/overlay/position-type.mjs +0 -2
- package/esm2022/core/types/index.mjs +0 -4
- package/esm2022/core/types/ngwr-core-types.mjs +0 -5
- package/esm2022/core/types/on-change-type.mjs +0 -2
- package/esm2022/core/types/on-touched-type.mjs +0 -2
- package/esm2022/core/types/safe-any.mjs +0 -2
- package/esm2022/dialog/dialog-base.mjs +0 -92
- package/esm2022/dialog/dialog-config.mjs +0 -3
- package/esm2022/dialog/dialog-container.mjs +0 -58
- package/esm2022/dialog/dialog-content-directives.mjs +0 -98
- package/esm2022/dialog/dialog-module.mjs +0 -24
- package/esm2022/dialog/dialog-service.mjs +0 -109
- package/esm2022/dialog/dialog-tokens.mjs +0 -3
- package/esm2022/dialog/index.mjs +0 -10
- package/esm2022/divider/index.mjs +0 -3
- package/esm2022/form/form-error.mjs +0 -23
- package/esm2022/form/form-item.mjs +0 -46
- package/esm2022/form/form-module.mjs +0 -19
- package/esm2022/form/index.mjs +0 -4
- package/esm2022/icon/icon-module.mjs +0 -21
- package/esm2022/icon/icon-service.mjs +0 -21
- package/esm2022/icon/icon.mjs +0 -60
- package/esm2022/icon/index.mjs +0 -5
- package/esm2022/index.mjs +0 -3
- package/esm2022/input/index.mjs +0 -3
- package/esm2022/input/input-module.mjs +0 -20
- package/esm2022/input/input.mjs +0 -240
- package/esm2022/qrcode/generator.mjs +0 -84
- package/esm2022/qrcode/index.mjs +0 -3
- package/esm2022/qrcode/ngwr-qrcode.mjs +0 -5
- package/esm2022/qrcode/qrcode-module.mjs +0 -19
- package/esm2022/qrcode/qrcode.mjs +0 -142
- package/esm2022/qrcode/qrcodegen.mjs +0 -872
- package/esm2022/skeleton/skeleton-module.mjs +0 -18
- package/esm2022/skeleton/skeleton.mjs +0 -44
- package/esm2022/spinner/spinner-module.mjs +0 -16
- package/esm2022/spinner/spinner.mjs +0 -23
- package/esm2022/tag/index.mjs +0 -3
- package/esm2022/tag/tag-module.mjs +0 -20
- package/esm2022/tag/tag.mjs +0 -80
- package/esm2022/tooltip/index.mjs +0 -5
- package/esm2022/tooltip/ngwr-tooltip.mjs +0 -5
- package/esm2022/tooltip/tooltip-component.mjs +0 -93
- package/esm2022/tooltip/tooltip-default-positions.mjs +0 -8
- package/esm2022/tooltip/tooltip-directive.mjs +0 -85
- package/esm2022/tooltip/tooltip-module.mjs +0 -21
- package/esm2022/tooltip/tooltip-trigger.mjs +0 -2
- package/fesm2022/ngwr-core-abstract.mjs +0 -25
- package/fesm2022/ngwr-core-abstract.mjs.map +0 -1
- package/fesm2022/ngwr-core-color.mjs +0 -25
- package/fesm2022/ngwr-core-color.mjs.map +0 -1
- package/fesm2022/ngwr-core-decorators.mjs +0 -22
- package/fesm2022/ngwr-core-decorators.mjs.map +0 -1
- package/fesm2022/ngwr-core-overlay.mjs +0 -146
- package/fesm2022/ngwr-core-overlay.mjs.map +0 -1
- package/fesm2022/ngwr-core-types.mjs +0 -4
- package/fesm2022/ngwr-core-types.mjs.map +0 -1
- package/fesm2022/ngwr-qrcode.mjs.map +0 -1
- package/fesm2022/ngwr-tooltip.mjs +0 -204
- package/fesm2022/ngwr-tooltip.mjs.map +0 -1
- package/form/form-error.d.ts +0 -6
- package/form/form-item.d.ts +0 -15
- package/form/form-module.d.ts +0 -9
- package/icon/icon-module.d.ts +0 -9
- package/icon/icon-service.d.ts +0 -8
- package/icon/icon.d.ts +0 -20
- package/input/input-module.d.ts +0 -10
- package/input/input.d.ts +0 -65
- package/input/input.scss +0 -163
- package/qrcode/index.d.ts +0 -2
- package/qrcode/qrcode-module.d.ts +0 -9
- package/qrcode/qrcode.d.ts +0 -46
- package/skeleton/skeleton.d.ts +0 -11
- package/spinner/spinner.d.ts +0 -6
- package/styles/root.scss +0 -172
- package/tag/tag-module.d.ts +0 -10
- package/tag/tag.d.ts +0 -18
- package/tag/tag.scss +0 -106
- package/tooltip/index.d.ts +0 -5
- package/tooltip/tooltip-component.d.ts +0 -31
- package/tooltip/tooltip-default-positions.d.ts +0 -1
- package/tooltip/tooltip-directive.d.ts +0 -22
- package/tooltip/tooltip-module.d.ts +0 -11
- package/tooltip/tooltip-trigger.d.ts +0 -1
- package/tooltip/tooltip.scss +0 -67
- /package/form/{form.scss → styles/_index.scss} +0 -0
- /package/{qrcode → qr}/generator.d.ts +0 -0
- /package/{qrcode → qr}/qrcodegen.d.ts +0 -0
- /package/{qrcode/qrcode.scss → qr/styles/_index.scss} +0 -0
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export
|
|
2
|
-
export
|
|
3
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
1
|
+
export * from './skeleton.component';
|
|
2
|
+
export * from './skeleton.module';
|
|
3
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wcm9qZWN0cy9saWIvc2tlbGV0b24vaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsY0FBYyxzQkFBc0IsQ0FBQztBQUNyQyxjQUFjLG1CQUFtQixDQUFDIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0ICogZnJvbSAnLi9za2VsZXRvbi5jb21wb25lbnQnO1xuZXhwb3J0ICogZnJvbSAnLi9za2VsZXRvbi5tb2R1bGUnO1xuIl19
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { booleanAttribute, ChangeDetectionStrategy, Component, HostBinding, Input, ViewEncapsulation } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export class WrSkeletonComponent {
|
|
4
|
+
constructor() {
|
|
5
|
+
this.color = 'dark';
|
|
6
|
+
this.animated = true;
|
|
7
|
+
}
|
|
8
|
+
get elClasses() {
|
|
9
|
+
return {
|
|
10
|
+
'wr-skeleton': true,
|
|
11
|
+
'wr-skeleton--animated': this.animated,
|
|
12
|
+
'wr-skeleton--primary': this.color === 'primary',
|
|
13
|
+
'wr-skeleton--secondary': this.color === 'secondary',
|
|
14
|
+
'wr-skeleton--success': this.color === 'success',
|
|
15
|
+
'wr-skeleton--warning': this.color === 'warning',
|
|
16
|
+
'wr-skeleton--danger': this.color === 'danger',
|
|
17
|
+
'wr-skeleton--light': this.color === 'light',
|
|
18
|
+
'wr-skeleton--medium': this.color === 'medium',
|
|
19
|
+
'wr-skeleton--dark': this.color === 'dark',
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrSkeletonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
23
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "16.1.0", version: "18.0.4", type: WrSkeletonComponent, isStandalone: true, selector: "wr-skeleton", inputs: { color: "color", animated: ["animated", "animated", booleanAttribute] }, host: { properties: { "class": "this.elClasses" } }, ngImport: i0, template: '', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
24
|
+
}
|
|
25
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrSkeletonComponent, decorators: [{
|
|
26
|
+
type: Component,
|
|
27
|
+
args: [{
|
|
28
|
+
standalone: true,
|
|
29
|
+
selector: 'wr-skeleton',
|
|
30
|
+
template: '',
|
|
31
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
32
|
+
encapsulation: ViewEncapsulation.None,
|
|
33
|
+
}]
|
|
34
|
+
}], propDecorators: { color: [{
|
|
35
|
+
type: Input
|
|
36
|
+
}], animated: [{
|
|
37
|
+
type: Input,
|
|
38
|
+
args: [{ transform: booleanAttribute }]
|
|
39
|
+
}], elClasses: [{
|
|
40
|
+
type: HostBinding,
|
|
41
|
+
args: ['class']
|
|
42
|
+
}] } });
|
|
43
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2tlbGV0b24uY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vcHJvamVjdHMvbGliL3NrZWxldG9uL3NrZWxldG9uLmNvbXBvbmVudC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsZ0JBQWdCLEVBQUUsdUJBQXVCLEVBQUUsU0FBUyxFQUFFLFdBQVcsRUFBRSxLQUFLLEVBQUUsaUJBQWlCLEVBQUUsTUFBTSxlQUFlLENBQUM7O0FBVzVILE1BQU0sT0FBTyxtQkFBbUI7SUFQaEM7UUFRVyxVQUFLLEdBQWlCLE1BQU0sQ0FBQztRQUNFLGFBQVEsR0FBWSxJQUFJLENBQUM7S0FpQmxFO0lBZkMsSUFDSSxTQUFTO1FBQ1gsT0FBTztZQUNMLGFBQWEsRUFBRSxJQUFJO1lBQ25CLHVCQUF1QixFQUFFLElBQUksQ0FBQyxRQUFRO1lBQ3RDLHNCQUFzQixFQUFFLElBQUksQ0FBQyxL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b24tLWRhbmdlcic6IHRoaXMuY29sb3IgPT09ICdkYW5nZXInLFxuICAgICAgJ3dyLXNrZWxldG9uLS1saWdodCc6IHRoaXMuY29sb3IgPT09ICdsaWdodCcsXG4gICAgICAnd3Itc2tlbGV0b24tLW1lZGl1bSc6IHRoaXMuY29sb3IgPT09ICdtZWRpdW0nLFxuICAgICAgJ3dyLXNrZWxldG9uLS1kYXJrJzogdGhpcy5jb2xvciA9PT0gJ2RhcmsnLFxuICAgIH07XG4gIH1cbn1cbiJdfQ==
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { NgModule } from '@angular/core';
|
|
2
|
+
import { WrSkeletonComponent } from './skeleton.component';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export class WrSkeletonModule {
|
|
5
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrSkeletonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
6
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.4", ngImport: i0, type: WrSkeletonModule, imports: [WrSkeletonComponent], exports: [WrSkeletonComponent] }); }
|
|
7
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrSkeletonModule }); }
|
|
8
|
+
}
|
|
9
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrSkeletonModule, decorators: [{
|
|
10
|
+
type: NgModule,
|
|
11
|
+
args: [{
|
|
12
|
+
imports: [WrSkeletonComponent],
|
|
13
|
+
exports: [WrSkeletonComponent],
|
|
14
|
+
}]
|
|
15
|
+
}] });
|
|
16
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2tlbGV0b24ubW9kdWxlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vcHJvamVjdHMvbGliL3NrZWxldG9uL3NrZWxldG9uLm1vZHVsZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsUUFBUSxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBRXpDLE9BQU8sRUFBRSxtQkFBbUIsRUFBRSxNQUFNLHNCQUFzQixDQUFDOztBQU0zRCxNQUFNLE9BQU8sZ0JBQWdCOzhHQUFoQixnQkFBZ0I7K0dBQWhCLGdCQUFnQixZQUhqQixtQkFBbUIsYUFDbkIsbUJBQW1COytHQUVsQixnQkFBZ0I7OzJGQUFoQixnQkFBZ0I7a0JBSjVCLFFBQVE7bUJBQUM7b0JBQ1IsT0FBTyxFQUFFLENBQUMsbUJBQW1CLENBQUM7b0JBQzlCLE9BQU8sRUFBRSxDQUFDLG1CQUFtQixDQUFDO2lCQUMvQiIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IE5nTW9kdWxlIH0gZnJvbSAnQGFuZ3VsYXIvY29yZSc7XG5cbmltcG9ydCB7IFdyU2tlbGV0b25Db21wb25lbnQgfSBmcm9tICcuL3NrZWxldG9uLmNvbXBvbmVudCc7XG5cbkBOZ01vZHVsZSh7XG4gIGltcG9ydHM6IFtXclNrZWxldG9uQ29tcG9uZW50XSxcbiAgZXhwb3J0czogW1dyU2tlbGV0b25Db21wb25lbnRdLFxufSlcbmV4cG9ydCBjbGFzcyBXclNrZWxldG9uTW9kdWxlIHt9XG4iXX0=
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export
|
|
2
|
-
export
|
|
3
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
1
|
+
export * from './spinner.component';
|
|
2
|
+
export * from './spinner.module';
|
|
3
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wcm9qZWN0cy9saWIvc3Bpbm5lci9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxjQUFjLHFCQUFxQixDQUFDO0FBQ3BDLGNBQWMsa0JBQWtCLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyJleHBvcnQgKiBmcm9tICcuL3NwaW5uZXIuY29tcG9uZW50JztcbmV4cG9ydCAqIGZyb20gJy4vc3Bpbm5lci5tb2R1bGUnO1xuIl19
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*
|
|
4
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
5
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
6
|
+
*/
|
|
7
|
+
import { ChangeDetectionStrategy, Component, HostBinding, ViewEncapsulation } from '@angular/core';
|
|
8
|
+
import * as i0 from "@angular/core";
|
|
9
|
+
/**
|
|
10
|
+
* NGWR spinner component.
|
|
11
|
+
*
|
|
12
|
+
* {@tutorial} [How to use wr-spinner]{@link http://ngwr.dev/docs/components/spinner
|
|
13
|
+
*/
|
|
14
|
+
export class WrSpinnerComponent {
|
|
15
|
+
constructor() {
|
|
16
|
+
this.class = 'wr-spinner';
|
|
17
|
+
}
|
|
18
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrSpinnerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
19
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.0.4", type: WrSpinnerComponent, isStandalone: true, selector: "wr-spinner", host: { properties: { "class": "this.class" } }, ngImport: i0, template: '<svg viewBox="0 0 50 50"><circle class="path" cx="25" cy="25" r="20" stroke-width="5" fill="none"></circle></svg>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
20
|
+
}
|
|
21
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrSpinnerComponent, decorators: [{
|
|
22
|
+
type: Component,
|
|
23
|
+
args: [{
|
|
24
|
+
standalone: true,
|
|
25
|
+
selector: 'wr-spinner',
|
|
26
|
+
template: '<svg viewBox="0 0 50 50"><circle class="path" cx="25" cy="25" r="20" stroke-width="5" fill="none"></circle></svg>',
|
|
27
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
28
|
+
encapsulation: ViewEncapsulation.None,
|
|
29
|
+
}]
|
|
30
|
+
}], propDecorators: { class: [{
|
|
31
|
+
type: HostBinding
|
|
32
|
+
}] } });
|
|
33
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic3Bpbm5lci5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wcm9qZWN0cy9saWIvc3Bpbm5lci9zcGlubmVyLmNvbXBvbmVudC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTs7Ozs7R0FLRztBQUVILE9BQU8sRUFBRSx1QkFBdUIsRUFBRSxTQUFTLEVBQUUsV0FBVyxFQUFFLGlCQUFpQixFQUFFLE1BQU0sZUFBZSxDQUFDOztBQUVuRzs7OztHQUlHO0FBU0gsTUFBTSxPQUFPLGtCQUFrQjtJQVIvQjtRQVNpQixVQUFLLEdBQUcsWUFBWSxDQUFDO0tBQ3JDOzhHQUZZLGtCQUFrQjtrR0FBbEIsa0JBQWtCLHVIQUozQixtSEFBbUg7OzJGQUkxRyxrQkFBa0I7a0JBUjlCLFNBQVM7bUJBQUM7b0JBQ1QsVUFBVSxFQUFFLElBQUk7b0JBQ2hCLFFBQVEsRUFBRSxZQUFZO29CQUN0QixRQUFRLEVBQ04sbUhBQW1IO29CQUNySCxlQUFlLEVBQUUsdUJBQXVCLENBQUMsTUFBTTtvQkFDL0Ms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ob25lLFxufSlcbmV4cG9ydCBjbGFzcyBXclNwaW5uZXJDb21wb25lbnQge1xuICBASG9zdEJpbmRpbmcoKSBjbGFzcyA9ICd3ci1zcGlubmVyJztcbn1cbiJdfQ==
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*
|
|
4
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
5
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
6
|
+
*/
|
|
7
|
+
import { NgModule } from '@angular/core';
|
|
8
|
+
import { WrSpinnerComponent } from './spinner.component';
|
|
9
|
+
import * as i0 from "@angular/core";
|
|
10
|
+
export class WrSpinnerModule {
|
|
11
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrSpinnerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
12
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.4", ngImport: i0, type: WrSpinnerModule, imports: [WrSpinnerComponent], exports: [WrSpinnerComponent] }); }
|
|
13
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrSpinnerModule }); }
|
|
14
|
+
}
|
|
15
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrSpinnerModule, decorators: [{
|
|
16
|
+
type: NgModule,
|
|
17
|
+
args: [{
|
|
18
|
+
imports: [WrSpinnerComponent],
|
|
19
|
+
exports: [WrSpinnerComponent],
|
|
20
|
+
}]
|
|
21
|
+
}] });
|
|
22
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic3Bpbm5lci5tb2R1bGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wcm9qZWN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
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Generated bundle index. Do not edit.
|
|
3
3
|
*/
|
|
4
|
-
export * from './
|
|
5
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
4
|
+
export * from './public-api';
|
|
5
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibmd3ci10YWcuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wcm9qZWN0cy9saWIvdGFnL25nd3ItdGFnLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYyxjQUFjLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEdlbmVyYXRlZCBidW5kbGUgaW5kZXguIERvIG5vdCBlZGl0LlxuICovXG5cbmV4cG9ydCAqIGZyb20gJy4vcHVibGljLWFwaSc7XG4iXX0=
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*
|
|
4
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
5
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
6
|
+
*/
|
|
7
|
+
export * from './tag.component';
|
|
8
|
+
export * from './tag.module';
|
|
9
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3Byb2plY3RzL2xpYi90YWcvcHVibGljLWFwaS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTs7Ozs7R0FLRztBQUVILGNBQWMsaUJBQWlCLENBQUM7QUFDaEMsY0FBYyxjQUFjLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEBsaWNlbnNlXG4gKlxuICogVXNlIG9mIHRoaXMgc291cmNlIGNvZGUgaXMgZ292ZXJuZWQgYnkgYW4gTUlULXN0eWxlIGxpY2Vuc2UgdGhhdCBjYW4gYmVcbiAqIGZvdW5kIGluIHRoZSBMSUNFTlNFIGZpbGUgYXQgaHR0cHM6Ly9naXRodWIuY29tL3RoZWtoZWdheS9uZ3dyL2Jsb2IvbWFpbi9MSUNFTlNFXG4gKi9cblxuZXhwb3J0ICogZnJvbSAnLi90YWcuY29tcG9uZW50JztcbmV4cG9ydCAqIGZyb20gJy4vdGFnLm1vZHVsZSc7XG4iXX0=
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*
|
|
4
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
5
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
6
|
+
*/
|
|
7
|
+
import { booleanAttribute, ChangeDetectionStrategy, Component, HostBinding, Input, ViewEncapsulation, } from '@angular/core';
|
|
8
|
+
import { WrIconComponent } from 'ngwr/icon';
|
|
9
|
+
import { WrSpinnerModule } from 'ngwr/spinner';
|
|
10
|
+
import * as i0 from "@angular/core";
|
|
11
|
+
import * as i1 from "ngwr/spinner";
|
|
12
|
+
export class WrTagComponent {
|
|
13
|
+
constructor() {
|
|
14
|
+
this.color = 'primary';
|
|
15
|
+
this.icon = null;
|
|
16
|
+
this.iconPosition = 'start';
|
|
17
|
+
this.outlined = false;
|
|
18
|
+
this.rounded = false;
|
|
19
|
+
this.transparent = false;
|
|
20
|
+
this.hoverable = false;
|
|
21
|
+
this.loading = false;
|
|
22
|
+
}
|
|
23
|
+
get elClasses() {
|
|
24
|
+
return {
|
|
25
|
+
'wr-tag': true,
|
|
26
|
+
'wr-tag--color-primary': this.color === 'primary',
|
|
27
|
+
'wr-tag--color-secondary': this.color === 'secondary',
|
|
28
|
+
'wr-tag--color-success': this.color === 'success',
|
|
29
|
+
'wr-tag--color-warning': this.color === 'warning',
|
|
30
|
+
'wr-tag--color-danger': this.color === 'danger',
|
|
31
|
+
'wr-tag--color-light': this.color === 'light',
|
|
32
|
+
'wr-tag--color-medium': this.color === 'medium',
|
|
33
|
+
'wr-tag--color-dark': this.color === 'dark',
|
|
34
|
+
'wr-tag--icon-start': (this.icon || this.loading) && this.iconPosition === 'start',
|
|
35
|
+
'wr-tag--icon-end': (this.icon || this.loading) && this.iconPosition === 'end',
|
|
36
|
+
'wr-tag--loading': this.loading,
|
|
37
|
+
'wr-tag--rounded': this.rounded,
|
|
38
|
+
'wr-tag--outlined': this.outlined,
|
|
39
|
+
'wr-tag--transparent': this.transparent,
|
|
40
|
+
'wr-tag--hoverable': this.hoverable,
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrTagComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
44
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.0.4", type: WrTagComponent, isStandalone: true, selector: "wr-tag", inputs: { color: "color", icon: "icon", iconPosition: "iconPosition", outlined: ["outlined", "outlined", booleanAttribute], rounded: ["rounded", "rounded", booleanAttribute], transparent: ["transparent", "transparent", booleanAttribute], hoverable: ["hoverable", "hoverable", booleanAttribute], loading: ["loading", "loading", booleanAttribute] }, host: { properties: { "class": "this.elClasses" } }, ngImport: i0, template: "@if (loading && iconPosition === 'start') {\n <wr-spinner class=\"wr-tag__spin\" />\n}\n@if (icon && !loading && iconPosition === 'start') {\n <wr-icon class=\"wr-tag__icon\" [name]=\"icon\" />\n}\n<ng-content />\n@if (loading && iconPosition === 'end') {\n <wr-spinner class=\"wr-tag__spin\" />\n}\n@if (icon && !loading && iconPosition === 'end') {\n <wr-icon class=\"wr-tag__icon\" [name]=\"icon\" />\n}\n", dependencies: [{ kind: "component", type: WrIconComponent, selector: "wr-icon", inputs: ["name"] }, { kind: "ngmodule", type: WrSpinnerModule }, { kind: "component", type: i1.WrSpinnerComponent, selector: "wr-spinner" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
45
|
+
}
|
|
46
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrTagComponent, decorators: [{
|
|
47
|
+
type: Component,
|
|
48
|
+
args: [{ standalone: true, selector: 'wr-tag', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [WrIconComponent, WrSpinnerModule], template: "@if (loading && iconPosition === 'start') {\n <wr-spinner class=\"wr-tag__spin\" />\n}\n@if (icon && !loading && iconPosition === 'start') {\n <wr-icon class=\"wr-tag__icon\" [name]=\"icon\" />\n}\n<ng-content />\n@if (loading && iconPosition === 'end') {\n <wr-spinner class=\"wr-tag__spin\" />\n}\n@if (icon && !loading && iconPosition === 'end') {\n <wr-icon class=\"wr-tag__icon\" [name]=\"icon\" />\n}\n" }]
|
|
49
|
+
}], propDecorators: { color: [{
|
|
50
|
+
type: Input
|
|
51
|
+
}], icon: [{
|
|
52
|
+
type: Input
|
|
53
|
+
}], iconPosition: [{
|
|
54
|
+
type: Input
|
|
55
|
+
}], outlined: [{
|
|
56
|
+
type: Input,
|
|
57
|
+
args: [{ transform: booleanAttribute }]
|
|
58
|
+
}], rounded: [{
|
|
59
|
+
type: Input,
|
|
60
|
+
args: [{ transform: booleanAttribute }]
|
|
61
|
+
}], transparent: [{
|
|
62
|
+
type: Input,
|
|
63
|
+
args: [{ transform: booleanAttribute }]
|
|
64
|
+
}], hoverable: [{
|
|
65
|
+
type: Input,
|
|
66
|
+
args: [{ transform: booleanAttribute }]
|
|
67
|
+
}], loading: [{
|
|
68
|
+
type: Input,
|
|
69
|
+
args: [{ transform: booleanAttribute }]
|
|
70
|
+
}], elClasses: [{
|
|
71
|
+
type: HostBinding,
|
|
72
|
+
args: ['class']
|
|
73
|
+
}] }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bmcpICYmIHRoaXMuaWNvblBvc2l0aW9uID09PSAnZW5kJyxcbiAgICAgICd3ci10YWctLWxvYWRpbmcnOiB0aGlzLmxvYWRpbmcsXG4gICAgICAnd3ItdGFnLS1yb3VuZGVkJzogdGhpcy5yb3VuZGVkLFxuICAgICAgJ3dyLXRhZy0tb3V0bGluZWQnOiB0aGlzLm91dGxpbmVkLFxuICAgICAgJ3dyLXRhZy0tdHJhbnNwYXJlbnQnOiB0aGlzLnRyYW5zcGFyZW50LFxuICAgICAgJ3dyLXRhZy0taG92ZXJhYmxlJzogdGhpcy5ob3ZlcmFibGUsXG4gICAgfTtcbiAgfVxufVxuIiwiQGlmIChsb2FkaW5nICYmIGljb25Qb3NpdGlvbiA9PT0gJ3N0YXJ0Jykge1xuICA8d3Itc3Bpbm5lciBjbGFzcz1cIndyLXRhZ19fc3BpblwiIC8+XG59XG5AaWYgKGljb24gJiYgIWxvYWRpbmcgJiYgaWNvblBvc2l0aW9uID09PSAnc3RhcnQnKSB7XG4gIDx3ci1pY29uIGNsYXNzPVwid3ItdGFnX19pY29uXCIgW25hbWVdPVwiaWNvblwiIC8+XG59XG48bmctY29udGVudCAvPlxuQGlmIChsb2FkaW5nICYmIGljb25Qb3NpdGlvbiA9PT0gJ2VuZCcpIHtcbiAgPHdyLXNwaW5uZXIgY2xhc3M9XCJ3ci10YWdfX3NwaW5cIiAvPlxufVxuQGlmIChpY29uICYmICFsb2FkaW5nICYmIGljb25Qb3NpdGlvbiA9PT0gJ2VuZCcpIHtcbiAgPHdyLWljb24gY2xhc3M9XCJ3ci10YWdfX2ljb25cIiBbbmFtZV09XCJpY29uXCIgLz5cbn1cbiJdfQ==
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { NgModule } from '@angular/core';
|
|
2
|
+
import { WrTagComponent } from './tag.component';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export class WrTagModule {
|
|
5
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrTagModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
6
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.4", ngImport: i0, type: WrTagModule, imports: [WrTagComponent], exports: [WrTagComponent] }); }
|
|
7
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrTagModule, imports: [WrTagComponent] }); }
|
|
8
|
+
}
|
|
9
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrTagModule, decorators: [{
|
|
10
|
+
type: NgModule,
|
|
11
|
+
args: [{
|
|
12
|
+
imports: [WrTagComponent],
|
|
13
|
+
exports: [WrTagComponent],
|
|
14
|
+
}]
|
|
15
|
+
}] });
|
|
16
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGFnLm1vZHVsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3Byb2plY3RzL2xpYi90YWcvdGFnLm1vZHVsZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsUUFBUSxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBRXpDLE9BQU8sRUFBRSxjQUFjLEVBQUUsTUFBTSxpQkFBaUIsQ0FBQzs7QUFNakQsTUFBTSxPQUFPLFdBQVc7OEdBQVgsV0FBVzsrR0FBWCxXQUFXLFlBSFosY0FBYyxhQUNkLGNBQWM7K0dBRWIsV0FBVyxZQUhaLGNBQWM7OzJGQUdiLFdBQVc7a0JBSnZCLFFBQVE7bUJBQUM7b0JBQ1IsT0FBTyxFQUFFLENBQUMsY0FBYyxDQUFDO29CQUN6QixPQUFPLEVBQUUsQ0FBQyxjQUFjLENBQUM7aUJBQzFCIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgTmdNb2R1bGUgfSBmcm9tICdAYW5ndWxhci9jb3JlJztcblxuaW1wb3J0IHsgV3JUYWdDb21wb25lbnQgfSBmcm9tICcuL3RhZy5jb21wb25lbnQnO1xuXG5ATmdNb2R1bGUoe1xuICBpbXBvcnRzOiBbV3JUYWdDb21wb25lbnRdLFxuICBleHBvcnRzOiBbV3JUYWdDb21wb25lbnRdLFxufSlcbmV4cG9ydCBjbGFzcyBXclRhZ01vZHVsZSB7fVxuIl19
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { signal, booleanAttribute, Component, ChangeDetectionStrategy, ViewEncapsulation, Input, HostBinding, NgModule } from '@angular/core';
|
|
3
|
+
import * as i1 from 'ngwr/icon';
|
|
4
|
+
import { provideWrIcons, close, WrIconModule } from 'ngwr/icon';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* @license
|
|
8
|
+
*
|
|
9
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
10
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* @license
|
|
15
|
+
*
|
|
16
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
17
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
18
|
+
*/
|
|
19
|
+
/**
|
|
20
|
+
* NGWR alert component.
|
|
21
|
+
* Closeable component for feedback.
|
|
22
|
+
*
|
|
23
|
+
* {@tutorial} [How to use wr-alert]{@link http://ngwr.dev/docs/components/alert}
|
|
24
|
+
*/
|
|
25
|
+
class WrAlertComponent {
|
|
26
|
+
constructor() {
|
|
27
|
+
this.type = 'info';
|
|
28
|
+
this.closeable = false;
|
|
29
|
+
this.isClosed = signal(false);
|
|
30
|
+
}
|
|
31
|
+
get elClasses() {
|
|
32
|
+
return {
|
|
33
|
+
'wr-alert': true,
|
|
34
|
+
'wr-alert--success': this.type === 'success',
|
|
35
|
+
'wr-alert--warning': this.type === 'warning',
|
|
36
|
+
'wr-alert--danger': this.type === 'danger',
|
|
37
|
+
};
|
|
38
|
+
}
|
|
39
|
+
onClose() {
|
|
40
|
+
this.isClosed.set(true);
|
|
41
|
+
}
|
|
42
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrAlertComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
43
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.0.4", type: WrAlertComponent, isStandalone: true, selector: "wr-alert", inputs: { title: "title", message: "message", type: "type", closeable: ["closeable", "closeable", booleanAttribute] }, host: { properties: { "class": "this.elClasses" } }, providers: [provideWrIcons([close])], ngImport: i0, template: "@if (!isClosed()) {\n <div class=\"wr-alert__wrapper\">\n <div class=\"wr-alert__body\">\n <p class=\"wr-alert__title\">{{ title }}</p>\n @if (message) {\n <p class=\"wr-alert__message\">{{ message }}</p>\n }\n </div>\n\n @if (closeable) {\n <div class=\"wr-alert-close\">\n <wr-icon name=\"close\" (click)=\"onClose()\"></wr-icon>\n </div>\n }\n </div>\n}\n", dependencies: [{ kind: "ngmodule", type: WrIconModule }, { kind: "component", type: i1.WrIconComponent, selector: "wr-icon", inputs: ["name"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
44
|
+
}
|
|
45
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrAlertComponent, decorators: [{
|
|
46
|
+
type: Component,
|
|
47
|
+
args: [{ standalone: true, selector: 'wr-alert', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [WrIconModule], providers: [provideWrIcons([close])], template: "@if (!isClosed()) {\n <div class=\"wr-alert__wrapper\">\n <div class=\"wr-alert__body\">\n <p class=\"wr-alert__title\">{{ title }}</p>\n @if (message) {\n <p class=\"wr-alert__message\">{{ message }}</p>\n }\n </div>\n\n @if (closeable) {\n <div class=\"wr-alert-close\">\n <wr-icon name=\"close\" (click)=\"onClose()\"></wr-icon>\n </div>\n }\n </div>\n}\n" }]
|
|
48
|
+
}], propDecorators: { title: [{
|
|
49
|
+
type: Input,
|
|
50
|
+
args: [{ required: true }]
|
|
51
|
+
}], message: [{
|
|
52
|
+
type: Input
|
|
53
|
+
}], type: [{
|
|
54
|
+
type: Input
|
|
55
|
+
}], closeable: [{
|
|
56
|
+
type: Input,
|
|
57
|
+
args: [{ transform: booleanAttribute }]
|
|
58
|
+
}], elClasses: [{
|
|
59
|
+
type: HostBinding,
|
|
60
|
+
args: ['class']
|
|
61
|
+
}] } });
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* @license
|
|
65
|
+
*
|
|
66
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
67
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
68
|
+
*/
|
|
69
|
+
class WrAlertModule {
|
|
70
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrAlertModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
71
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.4", ngImport: i0, type: WrAlertModule, imports: [WrAlertComponent], exports: [WrAlertComponent] }); }
|
|
72
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrAlertModule, imports: [WrAlertComponent] }); }
|
|
73
|
+
}
|
|
74
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrAlertModule, decorators: [{
|
|
75
|
+
type: NgModule,
|
|
76
|
+
args: [{
|
|
77
|
+
imports: [WrAlertComponent],
|
|
78
|
+
exports: [WrAlertComponent],
|
|
79
|
+
}]
|
|
80
|
+
}] });
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* @license
|
|
84
|
+
*
|
|
85
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
86
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
87
|
+
*/
|
|
88
|
+
|
|
89
|
+
/**
|
|
90
|
+
* Generated bundle index. Do not edit.
|
|
91
|
+
*/
|
|
92
|
+
|
|
93
|
+
export { WrAlertComponent, WrAlertModule };
|
|
94
|
+
//# sourceMappingURL=ngwr-alert.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ngwr-alert.mjs","sources":["../../../projects/lib/alert/alert-type.ts","../../../projects/lib/alert/alert.component.ts","../../../projects/lib/alert/alert.component.html","../../../projects/lib/alert/alert.module.ts","../../../projects/lib/alert/public-api.ts","../../../projects/lib/alert/ngwr-alert.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\nexport type WrAlertType = 'info' | 'success' | 'warning' | 'danger';\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 booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n HostBinding,\n Input,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\n\nimport { SafeAny } from 'ngwr/cdk/types';\nimport { provideWrIcons, close, WrIconModule } from 'ngwr/icon';\n\nimport { WrAlertType } from './alert-type';\n\n/**\n * NGWR alert component.\n * Closeable component for feedback.\n *\n * {@tutorial} [How to use wr-alert]{@link http://ngwr.dev/docs/components/alert}\n */\n@Component({\n standalone: true,\n selector: 'wr-alert',\n templateUrl: './alert.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n imports: [WrIconModule],\n providers: [provideWrIcons([close])],\n})\nexport class WrAlertComponent {\n @Input({ required: true }) title!: string;\n @Input() message?: string;\n @Input() type: WrAlertType = 'info';\n @Input({ transform: booleanAttribute }) closeable = false;\n\n protected readonly isClosed = signal(false);\n\n @HostBinding('class')\n get elClasses(): SafeAny {\n return {\n 'wr-alert': true,\n 'wr-alert--success': this.type === 'success',\n 'wr-alert--warning': this.type === 'warning',\n 'wr-alert--danger': this.type === 'danger',\n };\n }\n\n onClose(): void {\n this.isClosed.set(true);\n }\n}\n","@if (!isClosed()) {\n <div class=\"wr-alert__wrapper\">\n <div class=\"wr-alert__body\">\n <p class=\"wr-alert__title\">{{ title }}</p>\n @if (message) {\n <p class=\"wr-alert__message\">{{ message }}</p>\n }\n </div>\n\n @if (closeable) {\n <div class=\"wr-alert-close\">\n <wr-icon name=\"close\" (click)=\"onClose()\"></wr-icon>\n </div>\n }\n </div>\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 { NgModule } from '@angular/core';\n\nimport { WrAlertComponent } from './alert.component';\n\n@NgModule({\n imports: [WrAlertComponent],\n exports: [WrAlertComponent],\n})\nexport class WrAlertModule {}\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\nexport * from './alert-type';\nexport * from './alert.component';\nexport * from './alert.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAAA;;;;;AAKG;;ACLH;;;;;AAKG;AAiBH;;;;;AAKG;MAUU,gBAAgB,CAAA;AAT7B,IAAA,WAAA,GAAA;QAYW,IAAI,CAAA,IAAA,GAAgB,MAAM,CAAC;QACI,IAAS,CAAA,SAAA,GAAG,KAAK,CAAC;AAEvC,QAAA,IA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;kBAJzB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,gBAAgB,CAAC;oBAC3B,OAAO,EAAE,CAAC,gBAAgB,CAAC;AAC5B,iBAAA,CAAA;;;ACdD;;;;;AAKG;;ACLH;;AAEG;;;;"}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { NgOptimizedImage } from '@angular/common';
|
|
2
|
+
import * as i0 from '@angular/core';
|
|
3
|
+
import { inject, ChangeDetectorRef, ElementRef, signal, booleanAttribute, numberAttribute, Component, ChangeDetectionStrategy, ViewEncapsulation, Input, HostBinding, NgModule } from '@angular/core';
|
|
4
|
+
import * as i1 from 'ngwr/spinner';
|
|
5
|
+
import { WrSpinnerModule } from 'ngwr/spinner';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* @license
|
|
9
|
+
*
|
|
10
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
11
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
12
|
+
*/
|
|
13
|
+
class WrAvatarComponent {
|
|
14
|
+
calcRemToPx() {
|
|
15
|
+
const nativeElement = this.elRef?.nativeElement;
|
|
16
|
+
const style = nativeElement?.ownerDocument?.documentElement;
|
|
17
|
+
const fontSize = getComputedStyle(style)?.fontSize;
|
|
18
|
+
return Number(fontSize) || 16;
|
|
19
|
+
}
|
|
20
|
+
constructor() {
|
|
21
|
+
this.cdr = inject(ChangeDetectorRef);
|
|
22
|
+
this.elRef = inject(ElementRef);
|
|
23
|
+
this.remSize = 16;
|
|
24
|
+
this.isImgLoaded = signal(false);
|
|
25
|
+
this.rounded = false;
|
|
26
|
+
this._size = 6 * this.remSize;
|
|
27
|
+
this.remSize = this.calcRemToPx();
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Width and height in rem
|
|
31
|
+
* @example size="6" transforms to 6 * remSize (16 by default)
|
|
32
|
+
*/
|
|
33
|
+
get size() {
|
|
34
|
+
return this._size;
|
|
35
|
+
}
|
|
36
|
+
set size(value) {
|
|
37
|
+
this._size = Number(value) * this.remSize;
|
|
38
|
+
this.cdr.markForCheck();
|
|
39
|
+
}
|
|
40
|
+
get elClasses() {
|
|
41
|
+
return {
|
|
42
|
+
'wr-avatar': true,
|
|
43
|
+
'wr-avatar--rounded': this.rounded,
|
|
44
|
+
'wr-avatar--loaded': this.isImgLoaded(),
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
get elStyles() {
|
|
48
|
+
return {
|
|
49
|
+
width: `${this.size}px`,
|
|
50
|
+
height: `${this.size}px`,
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrAvatarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
54
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.0.4", type: WrAvatarComponent, isStandalone: true, selector: "wr-avatar", inputs: { url: "url", alt: "alt", rounded: ["rounded", "rounded", booleanAttribute], size: ["size", "size", numberAttribute] }, host: { properties: { "class": "this.elClasses", "style": "this.elStyles" } }, ngImport: i0, template: "<ng-content />\n\n<!--\n img need to be wrapped with @if\n to check is url set\n to trigger (load) listener\n-->\n@if (url) {\n <img\n class=\"wr-avatar__img\"\n [ngSrc]=\"url\"\n (load)=\"isImgLoaded.set(true)\"\n [width]=\"size\"\n [height]=\"size\"\n [alt]=\"alt\"\n priority\n />\n}\n\n@if (!isImgLoaded()) {\n <wr-spinner class=\"wr-avatar__spin\" />\n}\n", dependencies: [{ kind: "directive", type: NgOptimizedImage, selector: "img[ngSrc]", inputs: ["ngSrc", "ngSrcset", "sizes", "width", "height", "loading", "priority", "loaderParams", "disableOptimizedSrcset", "fill", "placeholder", "placeholderConfig", "src", "srcset"] }, { kind: "ngmodule", type: WrSpinnerModule }, { kind: "component", type: i1.WrSpinnerComponent, selector: "wr-spinner" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
55
|
+
}
|
|
56
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrAvatarComponent, decorators: [{
|
|
57
|
+
type: Component,
|
|
58
|
+
args: [{ standalone: true, selector: 'wr-avatar', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [NgOptimizedImage, WrSpinnerModule], template: "<ng-content />\n\n<!--\n img need to be wrapped with @if\n to check is url set\n to trigger (load) listener\n-->\n@if (url) {\n <img\n class=\"wr-avatar__img\"\n [ngSrc]=\"url\"\n (load)=\"isImgLoaded.set(true)\"\n [width]=\"size\"\n [height]=\"size\"\n [alt]=\"alt\"\n priority\n />\n}\n\n@if (!isImgLoaded()) {\n <wr-spinner class=\"wr-avatar__spin\" />\n}\n" }]
|
|
59
|
+
}], ctorParameters: () => [], propDecorators: { url: [{
|
|
60
|
+
type: Input,
|
|
61
|
+
args: [{ required: true }]
|
|
62
|
+
}], alt: [{
|
|
63
|
+
type: Input,
|
|
64
|
+
args: [{ required: true }]
|
|
65
|
+
}], rounded: [{
|
|
66
|
+
type: Input,
|
|
67
|
+
args: [{ transform: booleanAttribute }]
|
|
68
|
+
}], size: [{
|
|
69
|
+
type: Input,
|
|
70
|
+
args: [{ transform: numberAttribute }]
|
|
71
|
+
}], elClasses: [{
|
|
72
|
+
type: HostBinding,
|
|
73
|
+
args: ['class']
|
|
74
|
+
}], elStyles: [{
|
|
75
|
+
type: HostBinding,
|
|
76
|
+
args: ['style']
|
|
77
|
+
}] } });
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* @license
|
|
81
|
+
*
|
|
82
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
83
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
84
|
+
*/
|
|
85
|
+
class WrAvatarModule {
|
|
86
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrAvatarModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
87
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.4", ngImport: i0, type: WrAvatarModule, imports: [WrAvatarComponent], exports: [WrAvatarComponent] }); }
|
|
88
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrAvatarModule, imports: [WrAvatarComponent] }); }
|
|
89
|
+
}
|
|
90
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: WrAvatarModule, decorators: [{
|
|
91
|
+
type: NgModule,
|
|
92
|
+
args: [{
|
|
93
|
+
imports: [WrAvatarComponent],
|
|
94
|
+
exports: [WrAvatarComponent],
|
|
95
|
+
}]
|
|
96
|
+
}] });
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* @license
|
|
100
|
+
*
|
|
101
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
102
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
103
|
+
*/
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* Generated bundle index. Do not edit.
|
|
107
|
+
*/
|
|
108
|
+
|
|
109
|
+
export { WrAvatarComponent, WrAvatarModule };
|
|
110
|
+
//# sourceMappingURL=ngwr-avatar.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ngwr-avatar.mjs","sources":["../../../projects/lib/avatar/avatar.component.ts","../../../projects/lib/avatar/avatar.component.html","../../../projects/lib/avatar/avatar.module.ts","../../../projects/lib/avatar/public-api.ts","../../../projects/lib/avatar/ngwr-avatar.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 { NgOptimizedImage } from '@angular/common';\nimport {\n booleanAttribute,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n HostBinding,\n inject,\n Input,\n numberAttribute,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\n\nimport { SafeAny } from 'ngwr/cdk/types';\nimport { WrSpinnerModule } from 'ngwr/spinner';\n\n@Component({\n standalone: true,\n selector: 'wr-avatar',\n templateUrl: './avatar.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n imports: [NgOptimizedImage, WrSpinnerModule],\n})\nexport class WrAvatarComponent {\n readonly cdr = inject(ChangeDetectorRef);\n readonly elRef = inject(ElementRef);\n readonly remSize: number = 16;\n\n readonly isImgLoaded = signal(false);\n\n private calcRemToPx(): number {\n const nativeElement = this.elRef?.nativeElement as HTMLElement;\n const style = nativeElement?.ownerDocument?.documentElement;\n const fontSize = getComputedStyle(style)?.fontSize;\n return Number(fontSize) || 16;\n }\n\n constructor() {\n this.remSize = this.calcRemToPx();\n }\n\n @Input({ required: true }) url!: string;\n @Input({ required: true }) alt!: string;\n @Input({ transform: booleanAttribute }) rounded = false;\n\n /**\n * Width and height in rem\n * @example size=\"6\" transforms to 6 * remSize (16 by default)\n */\n @Input({ transform: numberAttribute })\n get size(): number {\n return this._size;\n }\n set size(value: number | string) {\n this._size = Number(value) * this.remSize;\n this.cdr.markForCheck();\n }\n private _size: number = 6 * this.remSize;\n\n @HostBinding('class')\n get elClasses(): SafeAny {\n return {\n 'wr-avatar': true,\n 'wr-avatar--rounded': this.rounded,\n 'wr-avatar--loaded': this.isImgLoaded(),\n };\n }\n\n @HostBinding('style')\n get elStyles(): SafeAny {\n return {\n width: `${this.size}px`,\n height: `${this.size}px`,\n };\n }\n}\n","<ng-content />\n\n<!--\n img need to be wrapped with @if\n to check is url set\n to trigger (load) listener\n-->\n@if (url) {\n <img\n class=\"wr-avatar__img\"\n [ngSrc]=\"url\"\n (load)=\"isImgLoaded.set(true)\"\n [width]=\"size\"\n [height]=\"size\"\n [alt]=\"alt\"\n priority\n />\n}\n\n@if (!isImgLoaded()) {\n <wr-spinner class=\"wr-avatar__spin\" />\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 { NgModule } from '@angular/core';\n\nimport { WrAvatarComponent } from './avatar.component';\n\n@NgModule({\n imports: [WrAvatarComponent],\n exports: [WrAvatarComponent],\n})\nexport class WrAvatarModule {}\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\nexport * from './avatar.component';\nexport * from './avatar.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAAA;;;;;AAKG;MA4BU,iBAAiB,CAAA;IAOpB,WAAW,GAAA;AACjB,QAAA,MAAM,aAAa,GAAG,IAAI,CAAC,KAAK,EAAE,aAA4B,CAAC;AAC/D,QAAA,MAAM,KAAK,GAAG,aAAa,EAAE,aAAa,EAAE,eAAe,CAAC;QAC5D,MAAM,QAAQ,GAAG,gBAAgB,CAAC,KAAK,CAAC,EAAE,QAAQ,CAAC;AACnD,QAAA,OAAO,MAAM,CAAC,QAAQ,CAAC,IAAI,EAAE,CAAC;KAC/B;AAED,IAAA,WAAA,GAAA;AAbS,QAAA,IAAA,CAAA,GAAG,GAAG,MAAM,CAAC,iBAAiB,CAAC,CAAC;AAChC,QAAA,IAAA,CAAA,KAAK,GAAG,MAAM,CAAC,UAAU,CAAC,CAAC;QAC3B,IAAO,CAAA,OAAA,GAAW,EAAE,CAAC;AAErB,QAAA,IAAA,CAAA,WAAW,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC;QAeG,IAAO,CAAA,OAAA,GAAG,KAAK,CAAC;AAchD,QAAA,IAAA,C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