ngx-bootstrap 18.0.2 → 18.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/README.md +1 -1
- package/accordion/accordion-group.component.d.ts +1 -1
- package/accordion/accordion.component.d.ts +1 -1
- package/accordion/accordion.module.d.ts +2 -5
- package/accordion/esm2022/accordion-group.component.mjs +8 -7
- package/accordion/esm2022/accordion.component.mjs +4 -3
- package/accordion/esm2022/accordion.module.mjs +6 -8
- package/accordion/fesm2022/ngx-bootstrap-accordion.mjs +12 -12
- package/accordion/fesm2022/ngx-bootstrap-accordion.mjs.map +1 -1
- package/alert/alert.component.d.ts +1 -1
- package/alert/alert.module.d.ts +2 -4
- package/alert/esm2022/alert.component.mjs +4 -4
- package/alert/esm2022/alert.module.mjs +6 -7
- package/alert/fesm2022/ngx-bootstrap-alert.mjs +8 -9
- package/alert/fesm2022/ngx-bootstrap-alert.mjs.map +1 -1
- package/buttons/button-checkbox.directive.d.ts +1 -1
- package/buttons/button-radio-group.directive.d.ts +1 -1
- package/buttons/button-radio.directive.d.ts +1 -1
- package/buttons/buttons.module.d.ts +2 -3
- package/buttons/esm2022/button-checkbox.directive.mjs +4 -3
- package/buttons/esm2022/button-radio-group.directive.mjs +4 -3
- package/buttons/esm2022/button-radio.directive.mjs +4 -3
- package/buttons/esm2022/buttons.module.mjs +5 -4
- package/buttons/fesm2022/ngx-bootstrap-buttons.mjs +13 -9
- package/buttons/fesm2022/ngx-bootstrap-buttons.mjs.map +1 -1
- package/carousel/carousel.component.d.ts +1 -1
- package/carousel/carousel.module.d.ts +2 -4
- package/carousel/esm2022/carousel.component.mjs +4 -5
- package/carousel/esm2022/carousel.module.mjs +6 -7
- package/carousel/esm2022/slide.component.mjs +3 -3
- package/carousel/fesm2022/ngx-bootstrap-carousel.mjs +10 -11
- package/carousel/fesm2022/ngx-bootstrap-carousel.mjs.map +1 -1
- package/carousel/slide.component.d.ts +1 -1
- package/chronos/esm2022/i18n/fr-ca.mjs +69 -0
- package/chronos/esm2022/public_api.mjs +2 -1
- package/chronos/fesm2022/ngx-bootstrap-chronos.mjs +70 -1
- package/chronos/fesm2022/ngx-bootstrap-chronos.mjs.map +1 -1
- package/chronos/i18n/fr-ca.d.ts +2 -0
- package/chronos/public_api.d.ts +1 -0
- package/collapse/collapse.directive.d.ts +1 -1
- package/collapse/collapse.module.d.ts +2 -3
- package/collapse/esm2022/collapse.directive.mjs +4 -3
- package/collapse/esm2022/collapse.module.mjs +5 -4
- package/collapse/fesm2022/ngx-bootstrap-collapse.mjs +7 -5
- package/collapse/fesm2022/ngx-bootstrap-collapse.mjs.map +1 -1
- package/datepicker/bs-datepicker-inline.component.d.ts +1 -1
- package/datepicker/bs-datepicker-input.directive.d.ts +1 -1
- package/datepicker/bs-datepicker.component.d.ts +1 -1
- package/datepicker/bs-datepicker.module.d.ts +24 -25
- package/datepicker/bs-daterangepicker-inline.component.d.ts +1 -1
- package/datepicker/bs-daterangepicker-input.directive.d.ts +1 -1
- package/datepicker/bs-daterangepicker.component.d.ts +1 -1
- package/datepicker/esm2022/bs-datepicker-inline.component.mjs +5 -3
- package/datepicker/esm2022/bs-datepicker-input.directive.mjs +12 -3
- package/datepicker/esm2022/bs-datepicker.component.mjs +5 -3
- package/datepicker/esm2022/bs-datepicker.module.mjs +14 -28
- package/datepicker/esm2022/bs-daterangepicker-inline.component.mjs +9 -3
- package/datepicker/esm2022/bs-daterangepicker-input.directive.mjs +12 -3
- package/datepicker/esm2022/bs-daterangepicker.component.mjs +9 -3
- package/datepicker/esm2022/themes/bs/bs-calendar-layout.component.mjs +9 -7
- package/datepicker/esm2022/themes/bs/bs-current-date-view.component.mjs +4 -3
- package/datepicker/esm2022/themes/bs/bs-custom-dates-view.component.mjs +7 -5
- package/datepicker/esm2022/themes/bs/bs-datepicker-container.component.mjs +13 -10
- package/datepicker/esm2022/themes/bs/bs-datepicker-day-decorator.directive.mjs +4 -3
- package/datepicker/esm2022/themes/bs/bs-datepicker-inline-container.component.mjs +11 -10
- package/datepicker/esm2022/themes/bs/bs-datepicker-navigation-view.component.mjs +7 -5
- package/datepicker/esm2022/themes/bs/bs-daterangepicker-container.component.mjs +23 -10
- package/datepicker/esm2022/themes/bs/bs-daterangepicker-inline-container.component.mjs +11 -10
- package/datepicker/esm2022/themes/bs/bs-days-calendar-view.component.mjs +12 -9
- package/datepicker/esm2022/themes/bs/bs-months-calendar-view.component.mjs +9 -7
- package/datepicker/esm2022/themes/bs/bs-timepicker-view.component.mjs +4 -3
- package/datepicker/esm2022/themes/bs/bs-years-calendar-view.component.mjs +9 -7
- package/datepicker/fesm2022/ngx-bootstrap-datepicker.mjs +436 -382
- package/datepicker/fesm2022/ngx-bootstrap-datepicker.mjs.map +1 -1
- package/datepicker/themes/bs/bs-calendar-layout.component.d.ts +1 -1
- package/datepicker/themes/bs/bs-current-date-view.component.d.ts +1 -1
- package/datepicker/themes/bs/bs-custom-dates-view.component.d.ts +1 -1
- package/datepicker/themes/bs/bs-datepicker-container.component.d.ts +1 -1
- package/datepicker/themes/bs/bs-datepicker-day-decorator.directive.d.ts +1 -1
- package/datepicker/themes/bs/bs-datepicker-inline-container.component.d.ts +1 -1
- package/datepicker/themes/bs/bs-datepicker-navigation-view.component.d.ts +1 -1
- package/datepicker/themes/bs/bs-daterangepicker-container.component.d.ts +1 -1
- package/datepicker/themes/bs/bs-daterangepicker-inline-container.component.d.ts +1 -1
- package/datepicker/themes/bs/bs-days-calendar-view.component.d.ts +1 -1
- package/datepicker/themes/bs/bs-months-calendar-view.component.d.ts +1 -1
- package/datepicker/themes/bs/bs-timepicker-view.component.d.ts +1 -1
- package/datepicker/themes/bs/bs-years-calendar-view.component.d.ts +1 -1
- package/dropdown/bs-dropdown-container.component.d.ts +1 -1
- package/dropdown/bs-dropdown-menu.directive.d.ts +1 -1
- package/dropdown/bs-dropdown-toggle.directive.d.ts +1 -1
- package/dropdown/bs-dropdown.directive.d.ts +1 -1
- package/dropdown/bs-dropdown.module.d.ts +6 -8
- package/dropdown/esm2022/bs-dropdown-container.component.mjs +8 -5
- package/dropdown/esm2022/bs-dropdown-menu.directive.mjs +4 -3
- package/dropdown/esm2022/bs-dropdown-toggle.directive.mjs +4 -3
- package/dropdown/esm2022/bs-dropdown.directive.mjs +4 -3
- package/dropdown/esm2022/bs-dropdown.module.mjs +11 -22
- package/dropdown/fesm2022/ngx-bootstrap-dropdown.mjs +26 -29
- package/dropdown/fesm2022/ngx-bootstrap-dropdown.mjs.map +1 -1
- package/focus-trap/esm2022/focus-trap.mjs +15 -3
- package/focus-trap/esm2022/focus-trap.module.mjs +5 -15
- package/focus-trap/fesm2022/ngx-bootstrap-focus-trap.mjs +63 -60
- package/focus-trap/fesm2022/ngx-bootstrap-focus-trap.mjs.map +1 -1
- package/focus-trap/focus-trap.d.ts +1 -1
- package/focus-trap/focus-trap.module.d.ts +4 -5
- package/locale/esm2022/public_api.mjs +2 -1
- package/locale/fesm2022/ngx-bootstrap-locale.mjs +1 -1
- package/locale/public_api.d.ts +1 -0
- package/modal/bs-modal.service.d.ts +1 -0
- package/modal/esm2022/bs-modal.service.mjs +6 -1
- package/modal/esm2022/modal-backdrop.component.mjs +4 -3
- package/modal/esm2022/modal-container.component.mjs +9 -5
- package/modal/esm2022/modal.directive.mjs +4 -3
- package/modal/esm2022/modal.module.mjs +10 -8
- package/modal/fesm2022/ngx-bootstrap-modal.mjs +323 -312
- package/modal/fesm2022/ngx-bootstrap-modal.mjs.map +1 -1
- package/modal/modal-backdrop.component.d.ts +1 -1
- package/modal/modal-container.component.d.ts +1 -1
- package/modal/modal.directive.d.ts +1 -1
- package/modal/modal.module.d.ts +5 -7
- package/package.json +1 -1
- package/pagination/esm2022/pager.component.mjs +4 -4
- package/pagination/esm2022/pagination.component.mjs +4 -4
- package/pagination/esm2022/pagination.module.mjs +5 -5
- package/pagination/fesm2022/ngx-bootstrap-pagination.mjs +9 -10
- package/pagination/fesm2022/ngx-bootstrap-pagination.mjs.map +1 -1
- package/pagination/pager.component.d.ts +1 -1
- package/pagination/pagination.component.d.ts +1 -1
- package/pagination/pagination.module.d.ts +5 -6
- package/popover/esm2022/popover-container.component.mjs +4 -4
- package/popover/esm2022/popover.directive.mjs +8 -3
- package/popover/esm2022/popover.module.mjs +5 -10
- package/popover/fesm2022/ngx-bootstrap-popover.mjs +17 -16
- package/popover/fesm2022/ngx-bootstrap-popover.mjs.map +1 -1
- package/popover/popover-container.component.d.ts +1 -1
- package/popover/popover.directive.d.ts +1 -1
- package/popover/popover.module.d.ts +5 -6
- package/progressbar/bar.component.d.ts +1 -1
- package/progressbar/esm2022/bar.component.mjs +3 -3
- package/progressbar/esm2022/progressbar.component.mjs +5 -5
- package/progressbar/esm2022/progressbar.module.mjs +6 -7
- package/progressbar/fesm2022/ngx-bootstrap-progressbar.mjs +10 -11
- package/progressbar/fesm2022/ngx-bootstrap-progressbar.mjs.map +1 -1
- package/progressbar/progressbar.component.d.ts +1 -1
- package/progressbar/progressbar.module.d.ts +2 -4
- package/rating/esm2022/rating.component.mjs +4 -4
- package/rating/esm2022/rating.module.mjs +6 -10
- package/rating/fesm2022/ngx-bootstrap-rating.mjs +8 -12
- package/rating/fesm2022/ngx-bootstrap-rating.mjs.map +1 -1
- package/rating/rating.component.d.ts +1 -1
- package/rating/rating.module.d.ts +2 -4
- package/schematics/ng-add/index.js +5 -0
- package/schematics/ng-add/index.js.map +1 -1
- package/schematics/utils/current_dependency_versions.json +1 -1
- package/schematics/utils/index.js +4 -4
- package/schematics/utils/index.js.map +1 -1
- package/sortable/esm2022/sortable.component.mjs +11 -7
- package/sortable/esm2022/sortable.module.mjs +6 -8
- package/sortable/fesm2022/ngx-bootstrap-sortable.mjs +15 -12
- package/sortable/fesm2022/ngx-bootstrap-sortable.mjs.map +1 -1
- package/sortable/sortable.component.d.ts +1 -1
- package/sortable/sortable.module.d.ts +2 -4
- package/tabs/esm2022/ng-transclude.directive.mjs +4 -3
- package/tabs/esm2022/tab-heading.directive.mjs +6 -3
- package/tabs/esm2022/tab.directive.mjs +6 -3
- package/tabs/esm2022/tabs.module.mjs +7 -12
- package/tabs/esm2022/tabset.component.mjs +5 -5
- package/tabs/fesm2022/ngx-bootstrap-tabs.mjs +22 -21
- package/tabs/fesm2022/ngx-bootstrap-tabs.mjs.map +1 -1
- package/tabs/ng-transclude.directive.d.ts +1 -1
- package/tabs/tab-heading.directive.d.ts +1 -1
- package/tabs/tab.directive.d.ts +1 -1
- package/tabs/tabs.module.d.ts +7 -8
- package/tabs/tabset.component.d.ts +1 -1
- package/timepicker/esm2022/timepicker.component.mjs +4 -4
- package/timepicker/esm2022/timepicker.module.mjs +6 -13
- package/timepicker/fesm2022/ngx-bootstrap-timepicker.mjs +8 -13
- package/timepicker/fesm2022/ngx-bootstrap-timepicker.mjs.map +1 -1
- package/timepicker/timepicker.component.d.ts +1 -1
- package/timepicker/timepicker.module.d.ts +2 -4
- package/tooltip/esm2022/tooltip-container.component.mjs +3 -3
- package/tooltip/esm2022/tooltip.directive.mjs +9 -3
- package/tooltip/esm2022/tooltip.module.mjs +5 -10
- package/tooltip/fesm2022/ngx-bootstrap-tooltip.mjs +14 -11
- package/tooltip/fesm2022/ngx-bootstrap-tooltip.mjs.map +1 -1
- package/tooltip/tooltip-container.component.d.ts +1 -1
- package/tooltip/tooltip.directive.d.ts +1 -1
- package/tooltip/tooltip.module.d.ts +5 -6
- package/typeahead/esm2022/typeahead-container.component.mjs +4 -4
- package/typeahead/esm2022/typeahead.directive.mjs +6 -3
- package/typeahead/esm2022/typeahead.module.mjs +5 -10
- package/typeahead/fesm2022/ngx-bootstrap-typeahead.mjs +11 -13
- package/typeahead/fesm2022/ngx-bootstrap-typeahead.mjs.map +1 -1
- package/typeahead/typeahead-container.component.d.ts +1 -1
- package/typeahead/typeahead.directive.d.ts +1 -1
- package/typeahead/typeahead.module.d.ts +5 -6
@@ -1,22 +1,21 @@
|
|
1
|
-
import { CommonModule } from '@angular/common';
|
2
1
|
import { NgModule } from '@angular/core';
|
3
2
|
import { BarComponent } from './bar.component';
|
4
3
|
import { ProgressbarComponent } from './progressbar.component';
|
5
4
|
import * as i0 from "@angular/core";
|
6
5
|
export class ProgressbarModule {
|
6
|
+
// @deprecated method not required anymore, will be deleted in v19.0.0
|
7
7
|
static forRoot() {
|
8
|
-
return
|
8
|
+
return ProgressbarModule;
|
9
9
|
}
|
10
10
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
11
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule,
|
12
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule
|
11
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule, imports: [BarComponent, ProgressbarComponent], exports: [BarComponent, ProgressbarComponent] }); }
|
12
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule }); }
|
13
13
|
}
|
14
14
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule, decorators: [{
|
15
15
|
type: NgModule,
|
16
16
|
args: [{
|
17
|
-
imports: [
|
18
|
-
declarations: [BarComponent, ProgressbarComponent],
|
17
|
+
imports: [BarComponent, ProgressbarComponent],
|
19
18
|
exports: [BarComponent, ProgressbarComponent]
|
20
19
|
}]
|
21
20
|
}] });
|
22
|
-
//# sourceMappingURL=data:application/json;base64,
|
21
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHJvZ3Jlc3NiYXIubW9kdWxlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJj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hckNvbXBvbmVudF1cbn0pXG5leHBvcnQgY2xhc3MgUHJvZ3Jlc3NiYXJNb2R1bGUge1xuICAvLyBAZGVwcmVjYXRlZCBtZXRob2Qgbm90IHJlcXVpcmVkIGFueW1vcmUsIHdpbGwgYmUgZGVsZXRlZCBpbiB2MTkuMC4wXG4gIHN0YXRpYyBmb3JSb290KCkge1xuICAgIHJldHVybiBQcm9ncmVzc2Jhck1vZHVsZTtcbiAgfVxufVxuIl19
|
@@ -1,7 +1,6 @@
|
|
1
1
|
import * as i0 from '@angular/core';
|
2
2
|
import { Component, ChangeDetectionStrategy, Input, Injectable, NgModule } from '@angular/core';
|
3
|
-
import
|
4
|
-
import { CommonModule } from '@angular/common';
|
3
|
+
import { NgIf, NgFor } from '@angular/common';
|
5
4
|
|
6
5
|
class BarComponent {
|
7
6
|
constructor(el, renderer) {
|
@@ -45,7 +44,7 @@ class BarComponent {
|
|
45
44
|
}
|
46
45
|
}
|
47
46
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: BarComponent, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component }); }
|
48
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.0.1", type: BarComponent, selector: "bar", inputs: { max: "max", value: "value", animate: "animate", striped: "striped", type: "type" }, host: { attributes: { "role": "progressbar", "aria-valuemin": "0" }, properties: { "class.progress-bar": "true", "class.progress-bar-animated": "animate", "class.progress-bar-striped": "striped", "attr.aria-valuenow": "value", "attr.aria-valuetext": "percent ? percent.toFixed(0) + \"%\" : \"\"", "attr.aria-valuemax": "max", "style.height.%": "\"100\"", "style.width.%": "percent" } }, usesOnChanges: true, ngImport: i0, template: "<ng-content></ng-content>\n", changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
47
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.0.1", type: BarComponent, isStandalone: true, selector: "bar", inputs: { max: "max", value: "value", animate: "animate", striped: "striped", type: "type" }, host: { attributes: { "role": "progressbar", "aria-valuemin": "0" }, properties: { "class.progress-bar": "true", "class.progress-bar-animated": "animate", "class.progress-bar-striped": "striped", "attr.aria-valuenow": "value", "attr.aria-valuetext": "percent ? percent.toFixed(0) + \"%\" : \"\"", "attr.aria-valuemax": "max", "style.height.%": "\"100\"", "style.width.%": "percent" } }, usesOnChanges: true, ngImport: i0, template: "<ng-content></ng-content>\n", changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
49
48
|
}
|
50
49
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: BarComponent, decorators: [{
|
51
50
|
type: Component,
|
@@ -60,7 +59,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImpor
|
|
60
59
|
'[attr.aria-valuemax]': 'max',
|
61
60
|
'[style.height.%]': '"100"',
|
62
61
|
'[style.width.%]': 'percent'
|
63
|
-
}, template: "<ng-content></ng-content>\n" }]
|
62
|
+
}, standalone: true, template: "<ng-content></ng-content>\n" }]
|
64
63
|
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.Renderer2 }], propDecorators: { max: [{
|
65
64
|
type: Input
|
66
65
|
}], value: [{
|
@@ -117,14 +116,14 @@ class ProgressbarComponent {
|
|
117
116
|
Object.assign(this, config);
|
118
117
|
}
|
119
118
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarComponent, deps: [{ token: ProgressbarConfig }], target: i0.ɵɵFactoryTarget.Component }); }
|
120
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.0.1", type: ProgressbarComponent, selector: "progressbar", inputs: { max: "max", animate: "animate", striped: "striped", type: "type", value: "value" }, host: { properties: { "class.progress": "true", "attr.max": "max" } }, ngImport: i0, template: "<ng-container *ngIf=\"!isStacked then NotStacked else Stacked\"></ng-container>\n\n<ng-template #NotStacked>\n <bar [type]=\"type\" [value]=\"_value\" [max]=\"max\" [animate]=\"animate\" [striped]=\"striped\">\n <ng-content></ng-content>\n </bar>\n</ng-template>\n\n<ng-template #Stacked>\n <bar *ngFor=\"let item of _values\"\n [type]=\"item.type\" [value]=\"item.value\" [max]=\"item.max || max\" [animate]=\"animate\" [striped]=\"striped\">{{ item.label }}</bar>\n</ng-template>\n", styles: [":host{width:100%;display:flex}\n"], dependencies: [{ kind: "directive", type:
|
119
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.0.1", type: ProgressbarComponent, isStandalone: true, selector: "progressbar", inputs: { max: "max", animate: "animate", striped: "striped", type: "type", value: "value" }, host: { properties: { "class.progress": "true", "attr.max": "max" } }, ngImport: i0, template: "<ng-container *ngIf=\"!isStacked then NotStacked else Stacked\"></ng-container>\n\n<ng-template #NotStacked>\n <bar [type]=\"type\" [value]=\"_value\" [max]=\"max\" [animate]=\"animate\" [striped]=\"striped\">\n <ng-content></ng-content>\n </bar>\n</ng-template>\n\n<ng-template #Stacked>\n <bar *ngFor=\"let item of _values\"\n [type]=\"item.type\" [value]=\"item.value\" [max]=\"item.max || max\" [animate]=\"animate\" [striped]=\"striped\">{{ item.label }}</bar>\n</ng-template>\n", styles: [":host{width:100%;display:flex}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: BarComponent, selector: "bar", inputs: ["max", "value", "animate", "striped", "type"] }, { kind: "directive", type: NgFor, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
121
120
|
}
|
122
121
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarComponent, decorators: [{
|
123
122
|
type: Component,
|
124
123
|
args: [{ selector: 'progressbar', changeDetection: ChangeDetectionStrategy.OnPush, host: {
|
125
124
|
'[class.progress]': 'true',
|
126
125
|
'[attr.max]': 'max'
|
127
|
-
}, template: "<ng-container *ngIf=\"!isStacked then NotStacked else Stacked\"></ng-container>\n\n<ng-template #NotStacked>\n <bar [type]=\"type\" [value]=\"_value\" [max]=\"max\" [animate]=\"animate\" [striped]=\"striped\">\n <ng-content></ng-content>\n </bar>\n</ng-template>\n\n<ng-template #Stacked>\n <bar *ngFor=\"let item of _values\"\n [type]=\"item.type\" [value]=\"item.value\" [max]=\"item.max || max\" [animate]=\"animate\" [striped]=\"striped\">{{ item.label }}</bar>\n</ng-template>\n", styles: [":host{width:100%;display:flex}\n"] }]
|
126
|
+
}, standalone: true, imports: [NgIf, BarComponent, NgFor], template: "<ng-container *ngIf=\"!isStacked then NotStacked else Stacked\"></ng-container>\n\n<ng-template #NotStacked>\n <bar [type]=\"type\" [value]=\"_value\" [max]=\"max\" [animate]=\"animate\" [striped]=\"striped\">\n <ng-content></ng-content>\n </bar>\n</ng-template>\n\n<ng-template #Stacked>\n <bar *ngFor=\"let item of _values\"\n [type]=\"item.type\" [value]=\"item.value\" [max]=\"item.max || max\" [animate]=\"animate\" [striped]=\"striped\">{{ item.label }}</bar>\n</ng-template>\n", styles: [":host{width:100%;display:flex}\n"] }]
|
128
127
|
}], ctorParameters: () => [{ type: ProgressbarConfig }], propDecorators: { max: [{
|
129
128
|
type: Input
|
130
129
|
}], animate: [{
|
@@ -138,18 +137,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImpor
|
|
138
137
|
}] } });
|
139
138
|
|
140
139
|
class ProgressbarModule {
|
140
|
+
// @deprecated method not required anymore, will be deleted in v19.0.0
|
141
141
|
static forRoot() {
|
142
|
-
return
|
142
|
+
return ProgressbarModule;
|
143
143
|
}
|
144
144
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
145
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule,
|
146
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule
|
145
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule, imports: [BarComponent, ProgressbarComponent], exports: [BarComponent, ProgressbarComponent] }); }
|
146
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule }); }
|
147
147
|
}
|
148
148
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: ProgressbarModule, decorators: [{
|
149
149
|
type: NgModule,
|
150
150
|
args: [{
|
151
|
-
imports: [
|
152
|
-
declarations: [BarComponent, ProgressbarComponent],
|
151
|
+
imports: [BarComponent, ProgressbarComponent],
|
153
152
|
exports: [BarComponent, ProgressbarComponent]
|
154
153
|
}]
|
155
154
|
}] });
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ngx-bootstrap-progressbar.mjs","sources":["../../../../src/progressbar/bar.component.ts","../../../../src/progressbar/bar.component.html","../../../../src/progressbar/progressbar.config.ts","../../../../src/progressbar/progressbar.component.ts","../../../../src/progressbar/progressbar.component.html","../../../../src/progressbar/progressbar.module.ts","../../../../src/progressbar/ngx-bootstrap-progressbar.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n Input,\n OnChanges,\n Renderer2,\n SimpleChanges\n} from '@angular/core';\n\nimport { ProgressbarType } from './progressbar-type.interface';\n\n@Component({\n selector: 'bar',\n templateUrl: './bar.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n // eslint-disable-next-line @angular-eslint/no-host-metadata-property\n host: {\n role: 'progressbar',\n 'aria-valuemin': '0',\n '[class.progress-bar]': 'true',\n '[class.progress-bar-animated]': 'animate',\n '[class.progress-bar-striped]': 'striped',\n '[attr.aria-valuenow]': 'value',\n '[attr.aria-valuetext]': 'percent ? percent.toFixed(0) + \"%\" : \"\"',\n '[attr.aria-valuemax]': 'max',\n '[style.height.%]': '\"100\"',\n '[style.width.%]': 'percent'\n }\n})\nexport class BarComponent implements OnChanges {\n /** maximum total value of progress element */\n @Input() max = 100;\n\n /** current value of progress bar */\n @Input() value? = 0;\n\n /** if `true` changing value of progress bar will be animated */\n @Input() animate? = false;\n\n /** If `true`, striped classes are applied */\n @Input() striped? = false;\n\n /** provide one of the four supported contextual classes: `success`, `info`, `warning`, `danger` */\n @Input() type?: ProgressbarType = 'info';\n\n percent = 100;\n\n private _prevType?: string;\n\n constructor(\n private el: ElementRef,\n private renderer: Renderer2\n ) {}\n\n ngOnChanges(changes: SimpleChanges) {\n if (changes[\"value\"] || changes[\"max\"]) {\n this.percent = 100 * (Number(changes[\"value\"]?.currentValue || this.value)\n / Number((changes[\"max\"]?.currentValue || this.max) || 100));\n }\n\n if (changes[\"type\"]) {\n this.applyTypeClasses();\n }\n }\n\n private applyTypeClasses(): void {\n if (this._prevType) {\n const barTypeClass = `progress-bar-${this._prevType}`;\n const bgClass = `bg-${this._prevType}`;\n this.renderer.removeClass(this.el.nativeElement, barTypeClass);\n this.renderer.removeClass(this.el.nativeElement, bgClass);\n this._prevType = void 0;\n }\n\n if (this.type) {\n const barTypeClass = `progress-bar-${this.type}`;\n const bgClass = `bg-${this.type}`;\n this.renderer.addClass(this.el.nativeElement, barTypeClass);\n this.renderer.addClass(this.el.nativeElement, bgClass);\n this._prevType = this.type;\n }\n }\n}\n","<ng-content></ng-content>\n","import { Injectable } from '@angular/core';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class ProgressbarConfig {\n /** if `true` changing value of progress bar will be animated */\n animate = false;\n /** maximum total value of progress element */\n max = 100;\n}\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\nimport { BarValue, ProgressbarType } from './progressbar-type.interface';\nimport { ProgressbarConfig } from './progressbar.config';\n\n@Component({\n selector: 'progressbar',\n templateUrl: './progressbar.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n // eslint-disable-next-line @angular-eslint/no-host-metadata-property\n host: {\n '[class.progress]': 'true',\n '[attr.max]': 'max'\n },\n styles: [`\n :host {\n width: 100%;\n display: flex;\n } `]\n})\nexport class ProgressbarComponent {\n /** maximum total value of progress element */\n @Input() max = 100;\n\n /** if `true` changing value of progress bar will be animated */\n @Input() animate = false;\n\n /** If `true`, striped classes are applied */\n @Input() striped = false;\n\n /** provide one of the four supported contextual classes: `success`, `info`, `warning`, `danger` */\n @Input() type?: ProgressbarType;\n\n /** current value of progress bar. Could be a number or array of objects\n * like {\"value\":15,\"type\":\"info\",\"label\":\"15 %\"}\n */\n @Input()\n set value(value: number | BarValue[]) {\n this.isStacked = Array.isArray(value);\n if (typeof value === 'number') {\n this._value = value;\n this._values = void 0;\n } else {\n this._value = void 0;\n this._values = value;\n }\n }\n\n isStacked = false;\n _value? = 0;\n _values?: BarValue[];\n\n constructor(config: ProgressbarConfig) {\n Object.assign(this, config);\n }\n}\n","<ng-container *ngIf=\"!isStacked then NotStacked else Stacked\"></ng-container>\n\n<ng-template #NotStacked>\n <bar [type]=\"type\" [value]=\"_value\" [max]=\"max\" [animate]=\"animate\" [striped]=\"striped\">\n <ng-content></ng-content>\n </bar>\n</ng-template>\n\n<ng-template #Stacked>\n <bar *ngFor=\"let item of _values\"\n [type]=\"item.type\" [value]=\"item.value\" [max]=\"item.max || max\" [animate]=\"animate\" [striped]=\"striped\">{{ item.label }}</bar>\n</ng-template>\n","import { CommonModule } from '@angular/common';\nimport { NgModule, ModuleWithProviders } from '@angular/core';\n\nimport { BarComponent } from './bar.component';\nimport { ProgressbarComponent } from './progressbar.component';\n\n@NgModule({\n imports: [CommonModule],\n declarations: [BarComponent, ProgressbarComponent],\n exports: [BarComponent, ProgressbarComponent]\n})\nexport class ProgressbarModule {\n static forRoot(): ModuleWithProviders<ProgressbarModule> {\n return { ngModule: ProgressbarModule, providers: [] };\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1.ProgressbarConfig","i3.BarComponent"],"mappings":";;;;;MA8Ba,YAAY,CAAA;IAoBvB,WACU,CAAA,EAAc,EACd,QAAmB,EAAA;QADnB,IAAE,CAAA,EAAA,GAAF,EAAE,CAAY;QACd,IAAQ,CAAA,QAAA,GAAR,QAAQ,CAAW;;QApBpB,IAAG,CAAA,GAAA,GAAG,GAAG,CAAC;;QAGV,IAAK,CAAA,KAAA,GAAI,CAAC,CAAC;;QAGX,IAAO,CAAA,OAAA,GAAI,KAAK,CAAC;;QAGjB,IAAO,CAAA,OAAA,GAAI,KAAK,CAAC;;QAGjB,IAAI,CAAA,IAAA,GAAqB,MAAM,CAAC;QAEzC,IAAO,CAAA,OAAA,GAAG,GAAG,CAAC;KAOV;AAEJ,IAAA,WAAW,CAAC,OAAsB,EAAA;QAChC,IAAI,OAAO,CAAC,OAAO,CAAC,IAAI,OAAO,CAAC,KAAK,CAAC,EAAE;AACtC,YAAA,IAAI,CAAC,OAAO,GAAG,GAAG,IAAI,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE,YAAY,IAAI,IAAI,CAAC,KAAK,CAAC;AACtE,kBAAA,MAAM,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,YAAY,IAAI,IAAI,CAAC,GAAG,KAAK,GAAG,CAAC,CAAC,CAAC;SAChE;AAED,QAAA,IAAI,OAAO,CAAC,MAAM,CAAC,EAAE;YACnB,IAAI,CAAC,gBAAgB,EAAE,CAAC;SACzB;KACF;IAEO,gBAAgB,GAAA;AACtB,QAAA,IAAI,IAAI,CAAC,SAAS,EAAE;AAClB,YAAA,MAAM,YAA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OAAO,EAAE,QAAQ,EAAE,iBAAiB,EAAE,SAAS,EAAE,EAAE,EAAE,CAAC;KACvD;8GAHU,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA,EAAA;+GAAjB,iBAAiB,EAAA,YAAA,EAAA,CAHb,YAAY,EAAE,oBAAoB,aADvC,YAAY,CAAA,EAAA,OAAA,EAAA,CAEZ,YAAY,EAAE,oBAAoB,CAAA,EAAA,CAAA,CAAA,EAAA;AAEjC,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,iBAAiB,YAJlB,YAAY,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAIX,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAL7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,YAAY,CAAC;AACvB,oBAAA,YAAY,EAAE,CAAC,YAAY,EAAE,oBAAoB,CAAC;AAClD,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,oBAAoB,CAAC;AAC9C,iBAAA,CAAA;;;ACVD;;AAEG;;;;"}
|
1
|
+
{"version":3,"file":"ngx-bootstrap-progressbar.mjs","sources":["../../../../src/progressbar/bar.component.ts","../../../../src/progressbar/bar.component.html","../../../../src/progressbar/progressbar.config.ts","../../../../src/progressbar/progressbar.component.ts","../../../../src/progressbar/progressbar.component.html","../../../../src/progressbar/progressbar.module.ts","../../../../src/progressbar/ngx-bootstrap-progressbar.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n Input,\n OnChanges,\n Renderer2,\n SimpleChanges\n} from '@angular/core';\n\nimport { ProgressbarType } from './progressbar-type.interface';\n\n@Component({\n selector: 'bar',\n templateUrl: './bar.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n // eslint-disable-next-line @angular-eslint/no-host-metadata-property\n host: {\n role: 'progressbar',\n 'aria-valuemin': '0',\n '[class.progress-bar]': 'true',\n '[class.progress-bar-animated]': 'animate',\n '[class.progress-bar-striped]': 'striped',\n '[attr.aria-valuenow]': 'value',\n '[attr.aria-valuetext]': 'percent ? percent.toFixed(0) + \"%\" : \"\"',\n '[attr.aria-valuemax]': 'max',\n '[style.height.%]': '\"100\"',\n '[style.width.%]': 'percent'\n },\n standalone: true\n})\nexport class BarComponent implements OnChanges {\n /** maximum total value of progress element */\n @Input() max = 100;\n\n /** current value of progress bar */\n @Input() value? = 0;\n\n /** if `true` changing value of progress bar will be animated */\n @Input() animate? = false;\n\n /** If `true`, striped classes are applied */\n @Input() striped? = false;\n\n /** provide one of the four supported contextual classes: `success`, `info`, `warning`, `danger` */\n @Input() type?: ProgressbarType = 'info';\n\n percent = 100;\n\n private _prevType?: string;\n\n constructor(\n private el: ElementRef,\n private renderer: Renderer2\n ) {}\n\n ngOnChanges(changes: SimpleChanges) {\n if (changes[\"value\"] || changes[\"max\"]) {\n this.percent = 100 * (Number(changes[\"value\"]?.currentValue || this.value)\n / Number((changes[\"max\"]?.currentValue || this.max) || 100));\n }\n\n if (changes[\"type\"]) {\n this.applyTypeClasses();\n }\n }\n\n private applyTypeClasses(): void {\n if (this._prevType) {\n const barTypeClass = `progress-bar-${this._prevType}`;\n const bgClass = `bg-${this._prevType}`;\n this.renderer.removeClass(this.el.nativeElement, barTypeClass);\n this.renderer.removeClass(this.el.nativeElement, bgClass);\n this._prevType = void 0;\n }\n\n if (this.type) {\n const barTypeClass = `progress-bar-${this.type}`;\n const bgClass = `bg-${this.type}`;\n this.renderer.addClass(this.el.nativeElement, barTypeClass);\n this.renderer.addClass(this.el.nativeElement, bgClass);\n this._prevType = this.type;\n }\n }\n}\n","<ng-content></ng-content>\n","import { Injectable } from '@angular/core';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class ProgressbarConfig {\n /** if `true` changing value of progress bar will be animated */\n animate = false;\n /** maximum total value of progress element */\n max = 100;\n}\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\nimport { BarValue, ProgressbarType } from './progressbar-type.interface';\nimport { ProgressbarConfig } from './progressbar.config';\nimport { BarComponent } from './bar.component';\nimport { NgIf, NgFor } from '@angular/common';\n\n@Component({\n selector: 'progressbar',\n templateUrl: './progressbar.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n // eslint-disable-next-line @angular-eslint/no-host-metadata-property\n host: {\n '[class.progress]': 'true',\n '[attr.max]': 'max'\n },\n styles: [`\n :host {\n width: 100%;\n display: flex;\n } `],\n standalone: true,\n imports: [NgIf, BarComponent, NgFor]\n})\nexport class ProgressbarComponent {\n /** maximum total value of progress element */\n @Input() max = 100;\n\n /** if `true` changing value of progress bar will be animated */\n @Input() animate = false;\n\n /** If `true`, striped classes are applied */\n @Input() striped = false;\n\n /** provide one of the four supported contextual classes: `success`, `info`, `warning`, `danger` */\n @Input() type?: ProgressbarType;\n\n /** current value of progress bar. Could be a number or array of objects\n * like {\"value\":15,\"type\":\"info\",\"label\":\"15 %\"}\n */\n @Input()\n set value(value: number | BarValue[]) {\n this.isStacked = Array.isArray(value);\n if (typeof value === 'number') {\n this._value = value;\n this._values = void 0;\n } else {\n this._value = void 0;\n this._values = value;\n }\n }\n\n isStacked = false;\n _value? = 0;\n _values?: BarValue[];\n\n constructor(config: ProgressbarConfig) {\n Object.assign(this, config);\n }\n}\n","<ng-container *ngIf=\"!isStacked then NotStacked else Stacked\"></ng-container>\n\n<ng-template #NotStacked>\n <bar [type]=\"type\" [value]=\"_value\" [max]=\"max\" [animate]=\"animate\" [striped]=\"striped\">\n <ng-content></ng-content>\n </bar>\n</ng-template>\n\n<ng-template #Stacked>\n <bar *ngFor=\"let item of _values\"\n [type]=\"item.type\" [value]=\"item.value\" [max]=\"item.max || max\" [animate]=\"animate\" [striped]=\"striped\">{{ item.label }}</bar>\n</ng-template>\n","import { NgModule } from '@angular/core';\n\nimport { BarComponent } from './bar.component';\nimport { ProgressbarComponent } from './progressbar.component';\n\n@NgModule({\n imports: [BarComponent, ProgressbarComponent],\n exports: [BarComponent, ProgressbarComponent]\n})\nexport class ProgressbarModule {\n // @deprecated method not required anymore, will be deleted in v19.0.0\n static forRoot() {\n return ProgressbarModule;\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1.ProgressbarConfig"],"mappings":";;;;MA+Ba,YAAY,CAAA;IAoBvB,WACU,CAAA,EAAc,EACd,QAAmB,EAAA;QADnB,IAAE,CAAA,EAAA,GAAF,EAAE,CAAY;QACd,IAAQ,CAAA,QAAA,GAAR,QAAQ,CAAW;;QApBpB,IAAG,CAAA,GAAA,GAAG,GAAG,CAAC;;QAGV,IAAK,CAAA,KAAA,GAAI,CAAC,CAAC;;QAGX,IAAO,CAAA,OAAA,GAAI,KAAK,CAAC;;QAGjB,IAAO,CAAA,OAAA,GAAI,KAAK,CAAC;;QAGjB,IAAI,CAAA,IAAA,GAAqB,MAAM,CAAC;QAEzC,IAAO,CAAA,OAAA,GAAG,GAAG,CAAC;KAOV;AAEJ,IAAA,WAAW,CAAC,OAAsB,EAAA;QAChC,IAAI,OAAO,CAAC,OAAO,CAAC,IAAI,OAAO,CAAC,KAAK,CAAC,EAAE;AACtC,YAAA,IAAI,CAAC,OAAO,GAAG,GAAG,IAAI,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE,YAAY,IAAI,IAAI,CAAC,KAAK,CAAC;AACtE,kBAAA,MAAM,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,YAAY,IAAI,IAAI,CAAC,GAAG,KAAK,GAAG,CAAC,CAAC,CAAC;SAChE;AAED,QAAA,IAAI,OAAO,CAAC,MAAM,CAAC,EAAE;YACnB,IAAI,CAAC,gBAAgB,EAAE,CAAC;SACzB;KACF;IAEO,gBAAgB,GAAA;AACtB,QAAA,IAA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BAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA,EAAA;AAAjB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,iBAAiB,YAHhB,YAAY,EAAE,oBAAoB,CAClC,EAAA,OAAA,EAAA,CAAA,YAAY,EAAE,oBAAoB,CAAA,EAAA,CAAA,CAAA,EAAA;+GAEnC,iBAAiB,EAAA,CAAA,CAAA,EAAA;;2FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAJ7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,oBAAoB,CAAC;AAC7C,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,oBAAoB,CAAC;AAChD,iBAAA,CAAA;;;ACRD;;AAEG;;;;"}
|
@@ -19,5 +19,5 @@ export declare class ProgressbarComponent {
|
|
19
19
|
_values?: BarValue[];
|
20
20
|
constructor(config: ProgressbarConfig);
|
21
21
|
static ɵfac: i0.ɵɵFactoryDeclaration<ProgressbarComponent, never>;
|
22
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<ProgressbarComponent, "progressbar", never, { "max": { "alias": "max"; "required": false; }; "animate": { "alias": "animate"; "required": false; }; "striped": { "alias": "striped"; "required": false; }; "type": { "alias": "type"; "required": false; }; "value": { "alias": "value"; "required": false; }; }, {}, never, ["*"],
|
22
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ProgressbarComponent, "progressbar", never, { "max": { "alias": "max"; "required": false; }; "animate": { "alias": "animate"; "required": false; }; "striped": { "alias": "striped"; "required": false; }; "type": { "alias": "type"; "required": false; }; "value": { "alias": "value"; "required": false; }; }, {}, never, ["*"], true, never>;
|
23
23
|
}
|
@@ -1,11 +1,9 @@
|
|
1
|
-
import { ModuleWithProviders } from '@angular/core';
|
2
1
|
import * as i0 from "@angular/core";
|
3
2
|
import * as i1 from "./bar.component";
|
4
3
|
import * as i2 from "./progressbar.component";
|
5
|
-
import * as i3 from "@angular/common";
|
6
4
|
export declare class ProgressbarModule {
|
7
|
-
static forRoot():
|
5
|
+
static forRoot(): typeof ProgressbarModule;
|
8
6
|
static ɵfac: i0.ɵɵFactoryDeclaration<ProgressbarModule, never>;
|
9
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<ProgressbarModule, [typeof i1.BarComponent, typeof i2.ProgressbarComponent], [typeof
|
7
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<ProgressbarModule, never, [typeof i1.BarComponent, typeof i2.ProgressbarComponent], [typeof i1.BarComponent, typeof i2.ProgressbarComponent]>;
|
10
8
|
static ɵinj: i0.ɵɵInjectorDeclaration<ProgressbarModule>;
|
11
9
|
}
|
@@ -1,9 +1,9 @@
|
|
1
1
|
import { ChangeDetectionStrategy, ChangeDetectorRef, Component, EventEmitter, forwardRef, HostListener, Input, Output, TemplateRef } from '@angular/core';
|
2
2
|
import { NG_VALUE_ACCESSOR } from '@angular/forms';
|
3
3
|
import { RatingConfig } from './rating.config';
|
4
|
+
import { NgFor, NgTemplateOutlet } from '@angular/common';
|
4
5
|
import * as i0 from "@angular/core";
|
5
6
|
import * as i1 from "./rating.config";
|
6
|
-
import * as i2 from "@angular/common";
|
7
7
|
export const RATING_CONTROL_VALUE_ACCESSOR = {
|
8
8
|
provide: NG_VALUE_ACCESSOR,
|
9
9
|
useExisting: forwardRef(() => RatingComponent),
|
@@ -97,11 +97,11 @@ export class RatingComponent {
|
|
97
97
|
return result;
|
98
98
|
}
|
99
99
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1.RatingConfig }], target: i0.ɵɵFactoryTarget.Component }); }
|
100
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.0.1", type: RatingComponent, selector: "rating", inputs: { max: "max", readonly: "readonly", titles: "titles", customTemplate: "customTemplate" }, outputs: { onHover: "onHover", onLeave: "onLeave" }, host: { listeners: { "keydown": "onKeydown($event)" } }, providers: [RATING_CONTROL_VALUE_ACCESSOR], ngImport: i0, template: "<span (mouseleave)=\"reset()\" (keydown)=\"onKeydown($event)\" tabindex=\"0\"\n role=\"slider\" aria-valuemin=\"0\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-valuemax]=\"range.length\"\n [attr.aria-valuenow]=\"value\">\n <ng-template #star let-value=\"value\" let-index=\"index\">{{ index < value ? '★' : '☆' }}</ng-template>\n <ng-template ngFor let-r [ngForOf]=\"range\" let-index=\"index\">\n <span class=\"sr-only visually-hidden\">({{ index < value ? '*' : ' ' }})</span>\n <span class=\"bs-rating-star\"\n (mouseenter)=\"enter(index + 1)\"\n (click)=\"rate(index + 1)\"\n [title]=\"r.title\"\n [style.cursor]=\"readonly ? 'default' : 'pointer'\"\n [class.active]=\"index < value\">\n <ng-template [ngTemplateOutlet]=\"customTemplate || star\"\n [ngTemplateOutletContext]=\"{index: index, value: value}\">\n </ng-template>\n </span>\n </ng-template>\n</span>\n", dependencies: [{ kind: "directive", type:
|
100
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.0.1", type: RatingComponent, isStandalone: true, selector: "rating", inputs: { max: "max", readonly: "readonly", titles: "titles", customTemplate: "customTemplate" }, outputs: { onHover: "onHover", onLeave: "onLeave" }, host: { listeners: { "keydown": "onKeydown($event)" } }, providers: [RATING_CONTROL_VALUE_ACCESSOR], ngImport: i0, template: "<span (mouseleave)=\"reset()\" (keydown)=\"onKeydown($event)\" tabindex=\"0\"\n role=\"slider\" aria-valuemin=\"0\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-valuemax]=\"range.length\"\n [attr.aria-valuenow]=\"value\">\n <ng-template #star let-value=\"value\" let-index=\"index\">{{ index < value ? '★' : '☆' }}</ng-template>\n <ng-template ngFor let-r [ngForOf]=\"range\" let-index=\"index\">\n <span class=\"sr-only visually-hidden\">({{ index < value ? '*' : ' ' }})</span>\n <span class=\"bs-rating-star\"\n (mouseenter)=\"enter(index + 1)\"\n (click)=\"rate(index + 1)\"\n [title]=\"r.title\"\n [style.cursor]=\"readonly ? 'default' : 'pointer'\"\n [class.active]=\"index < value\">\n <ng-template [ngTemplateOutlet]=\"customTemplate || star\"\n [ngTemplateOutletContext]=\"{index: index, value: value}\">\n </ng-template>\n </span>\n </ng-template>\n</span>\n", dependencies: [{ kind: "directive", type: NgFor, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
101
101
|
}
|
102
102
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingComponent, decorators: [{
|
103
103
|
type: Component,
|
104
|
-
args: [{ selector: 'rating', providers: [RATING_CONTROL_VALUE_ACCESSOR], changeDetection: ChangeDetectionStrategy.OnPush, template: "<span (mouseleave)=\"reset()\" (keydown)=\"onKeydown($event)\" tabindex=\"0\"\n role=\"slider\" aria-valuemin=\"0\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-valuemax]=\"range.length\"\n [attr.aria-valuenow]=\"value\">\n <ng-template #star let-value=\"value\" let-index=\"index\">{{ index < value ? '★' : '☆' }}</ng-template>\n <ng-template ngFor let-r [ngForOf]=\"range\" let-index=\"index\">\n <span class=\"sr-only visually-hidden\">({{ index < value ? '*' : ' ' }})</span>\n <span class=\"bs-rating-star\"\n (mouseenter)=\"enter(index + 1)\"\n (click)=\"rate(index + 1)\"\n [title]=\"r.title\"\n [style.cursor]=\"readonly ? 'default' : 'pointer'\"\n [class.active]=\"index < value\">\n <ng-template [ngTemplateOutlet]=\"customTemplate || star\"\n [ngTemplateOutletContext]=\"{index: index, value: value}\">\n </ng-template>\n </span>\n </ng-template>\n</span>\n" }]
|
104
|
+
args: [{ selector: 'rating', providers: [RATING_CONTROL_VALUE_ACCESSOR], changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [NgFor, NgTemplateOutlet], template: "<span (mouseleave)=\"reset()\" (keydown)=\"onKeydown($event)\" tabindex=\"0\"\n role=\"slider\" aria-valuemin=\"0\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-valuemax]=\"range.length\"\n [attr.aria-valuenow]=\"value\">\n <ng-template #star let-value=\"value\" let-index=\"index\">{{ index < value ? '★' : '☆' }}</ng-template>\n <ng-template ngFor let-r [ngForOf]=\"range\" let-index=\"index\">\n <span class=\"sr-only visually-hidden\">({{ index < value ? '*' : ' ' }})</span>\n <span class=\"bs-rating-star\"\n (mouseenter)=\"enter(index + 1)\"\n (click)=\"rate(index + 1)\"\n [title]=\"r.title\"\n [style.cursor]=\"readonly ? 'default' : 'pointer'\"\n [class.active]=\"index < value\">\n <ng-template [ngTemplateOutlet]=\"customTemplate || star\"\n [ngTemplateOutletContext]=\"{index: index, value: value}\">\n </ng-template>\n </span>\n </ng-template>\n</span>\n" }]
|
105
105
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i1.RatingConfig }], propDecorators: { max: [{
|
106
106
|
type: Input
|
107
107
|
}], readonly: [{
|
@@ -118,4 +118,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImpor
|
|
118
118
|
type: HostListener,
|
119
119
|
args: ['keydown', ['$event']]
|
120
120
|
}] } });
|
121
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmF0aW5nLmNvbXBvbmVudC5qcyIsInNvdX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AgICA8L3NwYW4+XG4gIDwvbmctdGVtcGxhdGU+XG48L3NwYW4+XG4iXX0=
|
@@ -1,24 +1,20 @@
|
|
1
|
-
import { CommonModule } from '@angular/common';
|
2
1
|
import { NgModule } from '@angular/core';
|
3
2
|
import { RatingComponent } from './rating.component';
|
4
3
|
import * as i0 from "@angular/core";
|
5
4
|
export class RatingModule {
|
5
|
+
// @deprecated method not required anymore, will be deleted in v19.0.0
|
6
6
|
static forRoot() {
|
7
|
-
return
|
8
|
-
ngModule: RatingModule,
|
9
|
-
providers: []
|
10
|
-
};
|
7
|
+
return RatingModule;
|
11
8
|
}
|
12
9
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
13
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.1", ngImport: i0, type: RatingModule,
|
14
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingModule
|
10
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.1", ngImport: i0, type: RatingModule, imports: [RatingComponent], exports: [RatingComponent] }); }
|
11
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingModule }); }
|
15
12
|
}
|
16
13
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingModule, decorators: [{
|
17
14
|
type: NgModule,
|
18
15
|
args: [{
|
19
|
-
imports: [
|
20
|
-
declarations: [RatingComponent],
|
16
|
+
imports: [RatingComponent],
|
21
17
|
exports: [RatingComponent]
|
22
18
|
}]
|
23
19
|
}] });
|
24
|
-
//# sourceMappingURL=data:application/json;base64,
|
20
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJza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GluZ01vZHVsZTtcbiAgfVxufVxuIl19
|
@@ -1,8 +1,7 @@
|
|
1
1
|
import * as i0 from '@angular/core';
|
2
2
|
import { Injectable, forwardRef, EventEmitter, Component, ChangeDetectionStrategy, Input, Output, HostListener, NgModule } from '@angular/core';
|
3
3
|
import { NG_VALUE_ACCESSOR } from '@angular/forms';
|
4
|
-
import
|
5
|
-
import { CommonModule } from '@angular/common';
|
4
|
+
import { NgFor, NgTemplateOutlet } from '@angular/common';
|
6
5
|
|
7
6
|
/** Default values provider for rating */
|
8
7
|
class RatingConfig {
|
@@ -113,11 +112,11 @@ class RatingComponent {
|
|
113
112
|
return result;
|
114
113
|
}
|
115
114
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: RatingConfig }], target: i0.ɵɵFactoryTarget.Component }); }
|
116
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.0.1", type: RatingComponent, selector: "rating", inputs: { max: "max", readonly: "readonly", titles: "titles", customTemplate: "customTemplate" }, outputs: { onHover: "onHover", onLeave: "onLeave" }, host: { listeners: { "keydown": "onKeydown($event)" } }, providers: [RATING_CONTROL_VALUE_ACCESSOR], ngImport: i0, template: "<span (mouseleave)=\"reset()\" (keydown)=\"onKeydown($event)\" tabindex=\"0\"\n role=\"slider\" aria-valuemin=\"0\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-valuemax]=\"range.length\"\n [attr.aria-valuenow]=\"value\">\n <ng-template #star let-value=\"value\" let-index=\"index\">{{ index < value ? '★' : '☆' }}</ng-template>\n <ng-template ngFor let-r [ngForOf]=\"range\" let-index=\"index\">\n <span class=\"sr-only visually-hidden\">({{ index < value ? '*' : ' ' }})</span>\n <span class=\"bs-rating-star\"\n (mouseenter)=\"enter(index + 1)\"\n (click)=\"rate(index + 1)\"\n [title]=\"r.title\"\n [style.cursor]=\"readonly ? 'default' : 'pointer'\"\n [class.active]=\"index < value\">\n <ng-template [ngTemplateOutlet]=\"customTemplate || star\"\n [ngTemplateOutletContext]=\"{index: index, value: value}\">\n </ng-template>\n </span>\n </ng-template>\n</span>\n", dependencies: [{ kind: "directive", type:
|
115
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.0.1", type: RatingComponent, isStandalone: true, selector: "rating", inputs: { max: "max", readonly: "readonly", titles: "titles", customTemplate: "customTemplate" }, outputs: { onHover: "onHover", onLeave: "onLeave" }, host: { listeners: { "keydown": "onKeydown($event)" } }, providers: [RATING_CONTROL_VALUE_ACCESSOR], ngImport: i0, template: "<span (mouseleave)=\"reset()\" (keydown)=\"onKeydown($event)\" tabindex=\"0\"\n role=\"slider\" aria-valuemin=\"0\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-valuemax]=\"range.length\"\n [attr.aria-valuenow]=\"value\">\n <ng-template #star let-value=\"value\" let-index=\"index\">{{ index < value ? '★' : '☆' }}</ng-template>\n <ng-template ngFor let-r [ngForOf]=\"range\" let-index=\"index\">\n <span class=\"sr-only visually-hidden\">({{ index < value ? '*' : ' ' }})</span>\n <span class=\"bs-rating-star\"\n (mouseenter)=\"enter(index + 1)\"\n (click)=\"rate(index + 1)\"\n [title]=\"r.title\"\n [style.cursor]=\"readonly ? 'default' : 'pointer'\"\n [class.active]=\"index < value\">\n <ng-template [ngTemplateOutlet]=\"customTemplate || star\"\n [ngTemplateOutletContext]=\"{index: index, value: value}\">\n </ng-template>\n </span>\n </ng-template>\n</span>\n", dependencies: [{ kind: "directive", type: NgFor, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
117
116
|
}
|
118
117
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingComponent, decorators: [{
|
119
118
|
type: Component,
|
120
|
-
args: [{ selector: 'rating', providers: [RATING_CONTROL_VALUE_ACCESSOR], changeDetection: ChangeDetectionStrategy.OnPush, template: "<span (mouseleave)=\"reset()\" (keydown)=\"onKeydown($event)\" tabindex=\"0\"\n role=\"slider\" aria-valuemin=\"0\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-valuemax]=\"range.length\"\n [attr.aria-valuenow]=\"value\">\n <ng-template #star let-value=\"value\" let-index=\"index\">{{ index < value ? '★' : '☆' }}</ng-template>\n <ng-template ngFor let-r [ngForOf]=\"range\" let-index=\"index\">\n <span class=\"sr-only visually-hidden\">({{ index < value ? '*' : ' ' }})</span>\n <span class=\"bs-rating-star\"\n (mouseenter)=\"enter(index + 1)\"\n (click)=\"rate(index + 1)\"\n [title]=\"r.title\"\n [style.cursor]=\"readonly ? 'default' : 'pointer'\"\n [class.active]=\"index < value\">\n <ng-template [ngTemplateOutlet]=\"customTemplate || star\"\n [ngTemplateOutletContext]=\"{index: index, value: value}\">\n </ng-template>\n </span>\n </ng-template>\n</span>\n" }]
|
119
|
+
args: [{ selector: 'rating', providers: [RATING_CONTROL_VALUE_ACCESSOR], changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [NgFor, NgTemplateOutlet], template: "<span (mouseleave)=\"reset()\" (keydown)=\"onKeydown($event)\" tabindex=\"0\"\n role=\"slider\" aria-valuemin=\"0\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-valuemax]=\"range.length\"\n [attr.aria-valuenow]=\"value\">\n <ng-template #star let-value=\"value\" let-index=\"index\">{{ index < value ? '★' : '☆' }}</ng-template>\n <ng-template ngFor let-r [ngForOf]=\"range\" let-index=\"index\">\n <span class=\"sr-only visually-hidden\">({{ index < value ? '*' : ' ' }})</span>\n <span class=\"bs-rating-star\"\n (mouseenter)=\"enter(index + 1)\"\n (click)=\"rate(index + 1)\"\n [title]=\"r.title\"\n [style.cursor]=\"readonly ? 'default' : 'pointer'\"\n [class.active]=\"index < value\">\n <ng-template [ngTemplateOutlet]=\"customTemplate || star\"\n [ngTemplateOutletContext]=\"{index: index, value: value}\">\n </ng-template>\n </span>\n </ng-template>\n</span>\n" }]
|
121
120
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: RatingConfig }], propDecorators: { max: [{
|
122
121
|
type: Input
|
123
122
|
}], readonly: [{
|
@@ -136,21 +135,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImpor
|
|
136
135
|
}] } });
|
137
136
|
|
138
137
|
class RatingModule {
|
138
|
+
// @deprecated method not required anymore, will be deleted in v19.0.0
|
139
139
|
static forRoot() {
|
140
|
-
return
|
141
|
-
ngModule: RatingModule,
|
142
|
-
providers: []
|
143
|
-
};
|
140
|
+
return RatingModule;
|
144
141
|
}
|
145
142
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
146
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.1", ngImport: i0, type: RatingModule,
|
147
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingModule
|
143
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.0.1", ngImport: i0, type: RatingModule, imports: [RatingComponent], exports: [RatingComponent] }); }
|
144
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingModule }); }
|
148
145
|
}
|
149
146
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.1", ngImport: i0, type: RatingModule, decorators: [{
|
150
147
|
type: NgModule,
|
151
148
|
args: [{
|
152
|
-
imports: [
|
153
|
-
declarations: [RatingComponent],
|
149
|
+
imports: [RatingComponent],
|
154
150
|
exports: [RatingComponent]
|
155
151
|
}]
|
156
152
|
}] });
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ngx-bootstrap-rating.mjs","sources":["../../../../src/rating/rating.config.ts","../../../../src/rating/rating.component.ts","../../../../src/rating/rating.component.html","../../../../src/rating/rating.module.ts","../../../../src/rating/ngx-bootstrap-rating.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\n\n/** Default values provider for rating */\n@Injectable({\n providedIn: 'root'\n})\nexport class RatingConfig {\n /** aria label for rating */\n ariaLabel = 'rating';\n}\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n EventEmitter,\n forwardRef,\n HostListener,\n Input,\n OnInit,\n Output,\n Provider,\n TemplateRef\n} from '@angular/core';\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { RatingResults } from './models';\nimport { RatingConfig } from './rating.config';\n\nexport const RATING_CONTROL_VALUE_ACCESSOR: Provider = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => RatingComponent),\n multi: true\n};\n\n@Component({\n selector: 'rating',\n templateUrl: './rating.component.html',\n providers: [RATING_CONTROL_VALUE_ACCESSOR],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class RatingComponent implements ControlValueAccessor, OnInit {\n /** number of icons */\n @Input() max = 5;\n /** if true will not react on any user events */\n @Input() readonly = false;\n /** array of icons titles, default: ([\"one\", \"two\", \"three\", \"four\", \"five\"]) */\n @Input() titles: string[] = [];\n /** custom template for icons */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Input() customTemplate?: TemplateRef<any>;\n /** fired when icon selected, $event:number equals to selected rating */\n @Output() onHover = new EventEmitter<number>();\n /** fired when icon selected, $event:number equals to previous rating value */\n @Output() onLeave = new EventEmitter<number>();\n\n onChange = Function.prototype;\n onTouched = Function.prototype;\n /** aria label for rating */\n ariaLabel = 'rating';\n range: RatingResults[] = [];\n value = 0;\n protected preValue?: number;\n\n constructor(private changeDetection: ChangeDetectorRef, config: RatingConfig) {\n Object.assign(this, config);\n }\n\n @HostListener('keydown', ['$event'])\n onKeydown(event: KeyboardEvent): void {\n if ([37, 38, 39, 40].indexOf(event.which) === -1) {\n return;\n }\n\n event.preventDefault();\n event.stopPropagation();\n const sign = event.which === 38 || event.which === 39 ? 1 : -1;\n this.rate(this.value + sign);\n }\n\n ngOnInit(): void {\n this.max = this.max || 5;\n this.titles =\n typeof this.titles !== 'undefined' && this.titles.length > 0\n ? this.titles\n : [];\n this.range = this.buildTemplateObjects(this.max);\n }\n\n // model -> view\n writeValue(value: number): void {\n if (value % 1 !== value) {\n this.value = Math.round(value);\n this.preValue = value;\n this.changeDetection.markForCheck();\n\n return;\n }\n\n this.preValue = value;\n this.value = value;\n this.changeDetection.markForCheck();\n }\n\n enter(value: number): void {\n if (!this.readonly) {\n this.value = value;\n this.changeDetection.markForCheck();\n this.onHover.emit(value);\n }\n }\n\n reset(): void {\n if (typeof this.preValue === 'number') {\n this.value = Math.round(this.preValue);\n this.changeDetection.markForCheck();\n this.onLeave.emit(this.value);\n }\n }\n\n registerOnChange(fn: (_: number) => void): void {\n this.onChange = fn;\n }\n\n registerOnTouched(fn: () => void): void {\n this.onTouched = fn;\n }\n\n rate(value: number): void {\n if (!this.readonly && this.range\n && value >= 0 && value <= this.range.length) {\n this.writeValue(value);\n this.onChange(value);\n }\n }\n\n protected buildTemplateObjects(max: number): RatingResults[] {\n const result: RatingResults[] = [];\n\n for (let i = 0; i < max; i++) {\n result.push({\n index: i,\n title: this.titles[i] || i + 1\n });\n }\n\n return result;\n }\n}\n","<span (mouseleave)=\"reset()\" (keydown)=\"onKeydown($event)\" tabindex=\"0\"\n role=\"slider\" aria-valuemin=\"0\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-valuemax]=\"range.length\"\n [attr.aria-valuenow]=\"value\">\n <ng-template #star let-value=\"value\" let-index=\"index\">{{ index < value ? '★' : '☆' }}</ng-template>\n <ng-template ngFor let-r [ngForOf]=\"range\" let-index=\"index\">\n <span class=\"sr-only visually-hidden\">({{ index < value ? '*' : ' ' }})</span>\n <span class=\"bs-rating-star\"\n (mouseenter)=\"enter(index + 1)\"\n (click)=\"rate(index + 1)\"\n [title]=\"r.title\"\n [style.cursor]=\"readonly ? 'default' : 'pointer'\"\n [class.active]=\"index < value\">\n <ng-template [ngTemplateOutlet]=\"customTemplate || star\"\n [ngTemplateOutletContext]=\"{index: index, value: value}\">\n </ng-template>\n </span>\n </ng-template>\n</span>\n","import { CommonModule } from '@angular/common';\nimport { NgModule, ModuleWithProviders } from '@angular/core';\n\nimport { RatingComponent } from './rating.component';\n\n@NgModule({\n imports: [CommonModule],\n declarations: [RatingComponent],\n exports: [RatingComponent]\n})\nexport class RatingModule {\n static forRoot(): ModuleWithProviders<RatingModule> {\n return {\n ngModule: RatingModule,\n providers: []\n };\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1.RatingConfig"],"mappings":";;;;;;AAEA;MAIa,YAAY,CAAA;AAHzB,IAAA,WAAA,GAAA;;QAKE,IAAS,CAAA,SAAA,GAAG,QAAQ,CAAC;AACtB,KAAA;8GAHY,YAAY,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA,EAAA;AAAZ,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,YAAY,cAFX,MAAM,EAAA,CAAA,CAAA,EAAA;;2FAEP,YAAY,EAAA,UAAA,EAAA,CAAA;kBAHxB,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;A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+
{"version":3,"file":"ngx-bootstrap-rating.mjs","sources":["../../../../src/rating/rating.config.ts","../../../../src/rating/rating.component.ts","../../../../src/rating/rating.component.html","../../../../src/rating/rating.module.ts","../../../../src/rating/ngx-bootstrap-rating.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\n\n/** Default values provider for rating */\n@Injectable({\n providedIn: 'root'\n})\nexport class RatingConfig {\n /** aria label for rating */\n ariaLabel = 'rating';\n}\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n EventEmitter,\n forwardRef,\n HostListener,\n Input,\n OnInit,\n Output,\n Provider,\n TemplateRef\n} from '@angular/core';\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { RatingResults } from './models';\nimport { RatingConfig } from './rating.config';\nimport { NgFor, NgTemplateOutlet } from '@angular/common';\n\nexport const RATING_CONTROL_VALUE_ACCESSOR: Provider = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => RatingComponent),\n multi: true\n};\n\n@Component({\n selector: 'rating',\n templateUrl: './rating.component.html',\n providers: [RATING_CONTROL_VALUE_ACCESSOR],\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: true,\n imports: [NgFor, NgTemplateOutlet]\n})\nexport class RatingComponent implements ControlValueAccessor, OnInit {\n /** number of icons */\n @Input() max = 5;\n /** if true will not react on any user events */\n @Input() readonly = false;\n /** array of icons titles, default: ([\"one\", \"two\", \"three\", \"four\", \"five\"]) */\n @Input() titles: string[] = [];\n /** custom template for icons */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Input() customTemplate?: TemplateRef<any>;\n /** fired when icon selected, $event:number equals to selected rating */\n @Output() onHover = new EventEmitter<number>();\n /** fired when icon selected, $event:number equals to previous rating value */\n @Output() onLeave = new EventEmitter<number>();\n\n onChange = Function.prototype;\n onTouched = Function.prototype;\n /** aria label for rating */\n ariaLabel = 'rating';\n range: RatingResults[] = [];\n value = 0;\n protected preValue?: number;\n\n constructor(private changeDetection: ChangeDetectorRef, config: RatingConfig) {\n Object.assign(this, config);\n }\n\n @HostListener('keydown', ['$event'])\n onKeydown(event: KeyboardEvent): void {\n if ([37, 38, 39, 40].indexOf(event.which) === -1) {\n return;\n }\n\n event.preventDefault();\n event.stopPropagation();\n const sign = event.which === 38 || event.which === 39 ? 1 : -1;\n this.rate(this.value + sign);\n }\n\n ngOnInit(): void {\n this.max = this.max || 5;\n this.titles =\n typeof this.titles !== 'undefined' && this.titles.length > 0\n ? this.titles\n : [];\n this.range = this.buildTemplateObjects(this.max);\n }\n\n // model -> view\n writeValue(value: number): void {\n if (value % 1 !== value) {\n this.value = Math.round(value);\n this.preValue = value;\n this.changeDetection.markForCheck();\n\n return;\n }\n\n this.preValue = value;\n this.value = value;\n this.changeDetection.markForCheck();\n }\n\n enter(value: number): void {\n if (!this.readonly) {\n this.value = value;\n this.changeDetection.markForCheck();\n this.onHover.emit(value);\n }\n }\n\n reset(): void {\n if (typeof this.preValue === 'number') {\n this.value = Math.round(this.preValue);\n this.changeDetection.markForCheck();\n this.onLeave.emit(this.value);\n }\n }\n\n registerOnChange(fn: (_: number) => void): void {\n this.onChange = fn;\n }\n\n registerOnTouched(fn: () => void): void {\n this.onTouched = fn;\n }\n\n rate(value: number): void {\n if (!this.readonly && this.range\n && value >= 0 && value <= this.range.length) {\n this.writeValue(value);\n this.onChange(value);\n }\n }\n\n protected buildTemplateObjects(max: number): RatingResults[] {\n const result: RatingResults[] = [];\n\n for (let i = 0; i < max; i++) {\n result.push({\n index: i,\n title: this.titles[i] || i + 1\n });\n }\n\n return result;\n }\n}\n","<span (mouseleave)=\"reset()\" (keydown)=\"onKeydown($event)\" tabindex=\"0\"\n role=\"slider\" aria-valuemin=\"0\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-valuemax]=\"range.length\"\n [attr.aria-valuenow]=\"value\">\n <ng-template #star let-value=\"value\" let-index=\"index\">{{ index < value ? '★' : '☆' }}</ng-template>\n <ng-template ngFor let-r [ngForOf]=\"range\" let-index=\"index\">\n <span class=\"sr-only visually-hidden\">({{ index < value ? '*' : ' ' }})</span>\n <span class=\"bs-rating-star\"\n (mouseenter)=\"enter(index + 1)\"\n (click)=\"rate(index + 1)\"\n [title]=\"r.title\"\n [style.cursor]=\"readonly ? 'default' : 'pointer'\"\n [class.active]=\"index < value\">\n <ng-template [ngTemplateOutlet]=\"customTemplate || star\"\n [ngTemplateOutletContext]=\"{index: index, value: value}\">\n </ng-template>\n </span>\n </ng-template>\n</span>\n","import { NgModule } from '@angular/core';\n\nimport { RatingComponent } from './rating.component';\n\n@NgModule({\n imports: [RatingComponent],\n exports: [RatingComponent]\n})\nexport class RatingModule {\n // @deprecated method not required anymore, will be deleted in v19.0.0\n static forRoot() {\n return RatingModule;\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1.RatingConfig"],"mappings":";;;;;AAEA;MAIa,YAAY,CAAA;AAHzB,IAAA,WAAA,GAAA;;QAKE,IAAS,CAAA,SAAA,GAAG,QAAQ,CAAC;AACtB,KAAA;8GAHY,YAAY,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA,EAAA;AAAZ,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,YAAY,cAFX,MAAM,EAAA,CAAA,CAAA,EAAA;;2FAEP,YAAY,EAAA,UAAA,EAAA,CAAA;kBAHxB,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;AACnB,iBAAA,CAAA;;;ACaM,MAAM,6BAA6B,GAAa;AACrD,IAAA,OAAO,EAAE,iBAAiB;AAC1B,IAAA,WAAW,EAAE,UAAU,CAAC,MAAM,eAAe,CAAC;AAC9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AAA,CAAA;sBADR,YAAY;uBAAC,SAAS,EAAE,CAAC,QAAQ,CAAC,CAAA;;;MEnDxB,YAAY,CAAA;;AAEvB,IAAA,OAAO,OAAO,GAAA;AACZ,QAAA,OAAO,YAAY,CAAC;KACrB;8GAJU,YAAY,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA,EAAA;+GAAZ,YAAY,EAAA,OAAA,EAAA,CAHX,eAAe,CAAA,EAAA,OAAA,EAAA,CACf,eAAe,CAAA,EAAA,CAAA,CAAA,EAAA;+GAEhB,YAAY,EAAA,CAAA,CAAA,EAAA;;2FAAZ,YAAY,EAAA,UAAA,EAAA,CAAA;kBAJxB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,OAAO,EAAE,CAAC,eAAe,CAAC;oBAC1B,OAAO,EAAE,CAAC,eAAe,CAAC;AAC7B,iBAAA,CAAA;;;ACPD;;AAEG;;;;"}
|
@@ -36,5 +36,5 @@ export declare class RatingComponent implements ControlValueAccessor, OnInit {
|
|
36
36
|
rate(value: number): void;
|
37
37
|
protected buildTemplateObjects(max: number): RatingResults[];
|
38
38
|
static ɵfac: i0.ɵɵFactoryDeclaration<RatingComponent, never>;
|
39
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<RatingComponent, "rating", never, { "max": { "alias": "max"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; "titles": { "alias": "titles"; "required": false; }; "customTemplate": { "alias": "customTemplate"; "required": false; }; }, { "onHover": "onHover"; "onLeave": "onLeave"; }, never, never,
|
39
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<RatingComponent, "rating", never, { "max": { "alias": "max"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; "titles": { "alias": "titles"; "required": false; }; "customTemplate": { "alias": "customTemplate"; "required": false; }; }, { "onHover": "onHover"; "onLeave": "onLeave"; }, never, never, true, never>;
|
40
40
|
}
|
@@ -1,10 +1,8 @@
|
|
1
|
-
import { ModuleWithProviders } from '@angular/core';
|
2
1
|
import * as i0 from "@angular/core";
|
3
2
|
import * as i1 from "./rating.component";
|
4
|
-
import * as i2 from "@angular/common";
|
5
3
|
export declare class RatingModule {
|
6
|
-
static forRoot():
|
4
|
+
static forRoot(): typeof RatingModule;
|
7
5
|
static ɵfac: i0.ɵɵFactoryDeclaration<RatingModule, never>;
|
8
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<RatingModule, [typeof i1.RatingComponent], [typeof
|
6
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<RatingModule, never, [typeof i1.RatingComponent], [typeof i1.RatingComponent]>;
|
9
7
|
static ɵinj: i0.ɵɵInjectorDeclaration<RatingModule>;
|
10
8
|
}
|
@@ -10,6 +10,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
10
10
|
};
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
12
12
|
exports.checkComponentName = void 0;
|
13
|
+
const schematics_1 = require("@angular-devkit/schematics");
|
13
14
|
const tasks_1 = require("@angular-devkit/schematics/tasks");
|
14
15
|
const ng_ast_utils_1 = require("@schematics/angular/utility/ng-ast-utils");
|
15
16
|
const utils_1 = require("../utils");
|
@@ -80,6 +81,10 @@ function addModuleOfComponent(project, host, context, componentName) {
|
|
80
81
|
if (!project) {
|
81
82
|
return;
|
82
83
|
}
|
84
|
+
if ((0, ng_ast_utils_1.isStandaloneApp)(host, (0, project_main_file_1.getProjectMainFile)(project))) {
|
85
|
+
throw new schematics_1.SchematicsException(`ngx-bootstrap doesn't support moduleless approach if we couldn't find
|
86
|
+
your starting *.module.ts learn more here https://valor-software.com/ngx-bootstrap/#/documentation#installation`);
|
87
|
+
}
|
83
88
|
const appModulePath = (0, ng_ast_utils_1.getAppModulePath)(host, (0, project_main_file_1.getProjectMainFile)(project));
|
84
89
|
if (componentName && components[componentName]) {
|
85
90
|
if ((0, ng_module_imports_1.hasNgModuleImport)(host, appModulePath, components[componentName].moduleName)) {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/schematics/src/ng-add/index.ts"],"names":[],"mappings":";;;;;;;;;;;;
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/schematics/src/ng-add/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAQA,2DAA+F;AAC/F,4DAA0E;AAC1E,2EAA6F;AAC7F,oCAAgF;AAChF,kEAA+D;AAC/D,kEAAgE;AAEhE,kDAA+C;AAC/C,sDAAuD;AACvD,qEAAqE;AAErE,MAAM,uBAAuB,GAAG,YAAY,CAAC;AAC7C,MAAM,MAAM,GAAG,eAAe,CAAC;AAC/B,MAAM,0BAA0B,GAAG;IACjC,KAAK,EAAE,CAAC,qDAAqD,CAAC;IAC9D,MAAM,EAAE,CAAC;;;CAGV,CAAC;CACD,CAAC;AACF,MAAM,0BAA0B,GAAG;IACjC,KAAK,EAAE,CAAC,2DAA2D,CAAC;IACpE,MAAM,EAAE,CAAC;;;CAGV,CAAC;CACD,CAAC;AAEF,MAAM,UAAU,GAAgF;IAC9F,SAAS,EAAE,EAAE,UAAU,EAAE,iBAAiB,EAAE,IAAI,EAAE,GAAG,MAAM,YAAY,EAAE,QAAQ,EAAE,IAAI,EAAE;IACzF,MAAM,EAAE,EAAE,UAAU,EAAE,aAAa,EAAE,IAAI,EAAE,GAAG,MAAM,QAAQ,EAAE;IAC9D,OAAO,EAAE,EAAE,UAAU,EAAE,eAAe,EAAE,IAAI,EAAE,GAAG,MAAM,UAAU,EAAE;IACnE,QAAQ,EAAE,EAAE,UAAU,EAAE,gBAAgB,EAAE,IAAI,EAAE,GAAG,MAAM,WAAW,EAAE;IACtE,QAAQ,EAAE,EAAE,UAAU,EAAE,gBAAgB,EAAE,IAAI,EAAE,GAAG,MAAM,WAAW,EAAE,QAAQ,EAAE,IAAI,EAAE;IACtF,UAAU,EAAE,EAAE,UAAU,EAAE,oBAAo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EAAC,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,0BAA0B,EAAE,WAAW,EAAE,SAAS,CAAC,CAAC;AAC/F,CAAC;AAED,SAAS,kBAAkB,CAAC,OAAqC,EAAE,IAAU,EAAE,WAAmB,EAAE,SAAkB;IACpH,IAAI,CAAC,OAAO,EAAE,CAAC;QACb,OAAO;IACT,CAAC;IAED,qBAAqB,CAAC,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,SAAS,CAAC,CAAC;IAC7D,OAAO,IAAA,qBAAS,EAAC,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,0BAA0B,EAAE,WAAW,EAAE,SAAS,CAAC,CAAC;AAC/F,CAAC;AAED,SAAS,kBAAkB,CAAC,OAAqC,EAAE,IAAU,EAAE,OAAyB,EAAE,aAAqB;;IAC7H,IAAI,CAAC,OAAO,IAAI,CAAC,CAAC,CAAC,aAAa,KAAI,MAAA,UAAU,CAAC,aAAa,CAAC,0CAAE,QAAQ,CAAA,CAAC,EAAE,CAAC;QACzE,OAAO;IACT,CAAC;IAED,IAAA,mCAA2B,EAAC,IAAI,EAAE,yBAAyB,EAAE,sCAAsC,EAAE,OAAO,CAAC,CAAC;AAChH,CAAC;AAED,SAAgB,kBAAkB,CAAC,aAAqB;IACtD,OAAO,CAAC,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC;AACrC,CAAC;AAFD,gDAEC"}
|
@@ -78,15 +78,15 @@ function removePackageJsonDependency(tree, dependencyName) {
|
|
78
78
|
}
|
79
79
|
exports.removePackageJsonDependency = removePackageJsonDependency;
|
80
80
|
function addModuleImportToRootModule(host, moduleName, src, project) {
|
81
|
+
if ((0, ng_ast_utils_1.isStandaloneApp)(host, (0, project_main_file_1.getProjectMainFile)(project))) {
|
82
|
+
throw new schematics_1.SchematicsException(`ngx-bootstrap doesn't support moduleless approach if we couldn't find
|
83
|
+
your starting *.module.ts learn more here https://valor-software.com/ngx-bootstrap/#/documentation#installation`);
|
84
|
+
}
|
81
85
|
const modulePath = (0, ng_ast_utils_1.getAppModulePath)(host, (0, project_main_file_1.getProjectMainFile)(project));
|
82
86
|
const moduleSource = getSourceFile(host, modulePath);
|
83
87
|
if (!moduleSource) {
|
84
88
|
throw new schematics_1.SchematicsException(`Module not found: ${modulePath}`);
|
85
89
|
}
|
86
|
-
if (modulePath.includes('component')) {
|
87
|
-
throw new schematics_1.SchematicsException(`ngx-bootstrap doesn't support moduleless approach if we couldn't find
|
88
|
-
your starting *.module.ts learn more here https://valor-software.com/ngx-bootstrap/#/documentation#installation`);
|
89
|
-
}
|
90
90
|
const changes = (0, ast_utils_1.addImportToModule)(moduleSource, modulePath, moduleName, src);
|
91
91
|
const recorder = host.beginUpdate(modulePath);
|
92
92
|
changes.forEach((change) => {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/schematics/src/utils/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;GAMG;AACH,2DAAuE;AAEvE,qEAA0E;AAC1E,+DAA0E;AAC1E,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/schematics/src/utils/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;GAMG;AACH,2DAAuE;AAEvE,qEAA0E;AAC1E,+DAA0E;AAC1E,2EAA6F;AAC7F,iCAAiC;AACjC,2DAAyD;AAGzD,SAAgB,uBAAuB,CACrC,OAAqC,EACrC,WAAmB;;IAEnB,IAAI,MAAA,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,OAAO,0CAAE,GAAG,CAAC,WAAW,CAAC,0CAAE,OAAO,EAAE,CAAC;QAChD,OAAO,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC,OAAO,CAAC;IAClD,CAAC;IACD,MAAM,IAAI,KAAK,CAAC,sDAAsD,WAAW,GAAG,CAAC,CAAC;AACxF,CAAC;AARD,0DAQC;AAED,SAAS,gBAAgB,CAAC,G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