@pepperi-addons/ngx-lib 0.3.15-beta.70 → 0.3.15-beta.76
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/bundles/pepperi-addons-ngx-lib-chips.umd.js +37 -6
- package/bundles/pepperi-addons-ngx-lib-chips.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-lib-textbox.umd.js +3 -3
- package/bundles/pepperi-addons-ngx-lib-textbox.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-lib.umd.js +1 -1
- package/bundles/pepperi-addons-ngx-lib.umd.js.map +1 -1
- package/chips/chips.component.d.ts +8 -3
- package/chips/chips.model.d.ts +5 -1
- package/chips/chips.service.d.ts +1 -0
- package/chips/pepperi-addons-ngx-lib-chips.metadata.json +1 -1
- package/esm2015/chips/chips.component.js +27 -7
- package/esm2015/chips/chips.model.js +1 -1
- package/esm2015/chips/chips.service.js +4 -1
- package/esm2015/core/customization/customization.model.js +2 -2
- package/esm2015/textbox/textbox.component.js +4 -4
- package/fesm2015/pepperi-addons-ngx-lib-chips.js +29 -6
- package/fesm2015/pepperi-addons-ngx-lib-chips.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-textbox.js +3 -3
- package/fesm2015/pepperi-addons-ngx-lib-textbox.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib.js +1 -1
- package/fesm2015/pepperi-addons-ngx-lib.js.map +1 -1
- package/package.json +1 -1
- package/textbox/pepperi-addons-ngx-lib-textbox.metadata.json +1 -1
|
@@ -16,6 +16,13 @@
|
|
|
16
16
|
enumerable: false,
|
|
17
17
|
configurable: true
|
|
18
18
|
});
|
|
19
|
+
Object.defineProperty(PepChipsService.prototype, "selected", {
|
|
20
|
+
get: function () {
|
|
21
|
+
return this._chips.filter(function (chip) { return chip.selected; }).map(function (chip) { return chip.value; });
|
|
22
|
+
},
|
|
23
|
+
enumerable: false,
|
|
24
|
+
configurable: true
|
|
25
|
+
});
|
|
19
26
|
PepChipsService.prototype.initData = function (chips) {
|
|
20
27
|
var _this = this;
|
|
21
28
|
this._chips = [];
|
|
@@ -94,6 +101,7 @@
|
|
|
94
101
|
* @memberof PepButtonComponent
|
|
95
102
|
*/
|
|
96
103
|
this.fieldClick = new core.EventEmitter();
|
|
104
|
+
this.selectionChange = new core.EventEmitter();
|
|
97
105
|
//
|
|
98
106
|
}
|
|
99
107
|
Object.defineProperty(PepChipsComponent.prototype, "chips", {
|
|
@@ -101,7 +109,7 @@
|
|
|
101
109
|
return this.chipsService.chips;
|
|
102
110
|
},
|
|
103
111
|
/**
|
|
104
|
-
*
|
|
112
|
+
* The chips within the chip list.
|
|
105
113
|
*
|
|
106
114
|
* @memberof PepChipsComponent
|
|
107
115
|
*/
|
|
@@ -111,12 +119,30 @@
|
|
|
111
119
|
enumerable: false,
|
|
112
120
|
configurable: true
|
|
113
121
|
});
|
|
122
|
+
Object.defineProperty(PepChipsComponent.prototype, "selected", {
|
|
123
|
+
/**
|
|
124
|
+
* Selected chip(s)
|
|
125
|
+
*/
|
|
126
|
+
get: function () {
|
|
127
|
+
var selected = this.chipsService.selected;
|
|
128
|
+
if (this.multiSelect) {
|
|
129
|
+
return selected.length ? selected : [];
|
|
130
|
+
}
|
|
131
|
+
else {
|
|
132
|
+
return selected.length ? selected[0] : null;
|
|
133
|
+
}
|
|
134
|
+
},
|
|
135
|
+
enumerable: false,
|
|
136
|
+
configurable: true
|
|
137
|
+
});
|
|
114
138
|
PepChipsComponent.prototype.ngOnInit = function () {
|
|
115
139
|
var _this = this;
|
|
116
|
-
|
|
140
|
+
if (!this.placeholder) {
|
|
141
|
+
this._translate.get("CHIPS.ADD_CHIP").pipe(this.chipsService.destroyer).subscribe(function (text) { return _this.placeholder = text; });
|
|
142
|
+
}
|
|
117
143
|
};
|
|
118
144
|
/**
|
|
119
|
-
* Adding chip(s) to current
|
|
145
|
+
* Adding chip(s) to current chip list
|
|
120
146
|
* @param chips Chip(s) to add
|
|
121
147
|
*/
|
|
122
148
|
PepChipsComponent.prototype.addChipsToList = function (chips) {
|
|
@@ -154,6 +180,10 @@
|
|
|
154
180
|
*/
|
|
155
181
|
PepChipsComponent.prototype.onSelectionChanged = function (isSelected, chip) {
|
|
156
182
|
chip.selected = isSelected;
|
|
183
|
+
this.selectionChange.emit({
|
|
184
|
+
value: chip.value,
|
|
185
|
+
isSelected: isSelected
|
|
186
|
+
});
|
|
157
187
|
};
|
|
158
188
|
/**
|
|
159
189
|
* On Add new chip(s) clicked
|
|
@@ -169,9 +199,9 @@
|
|
|
169
199
|
PepChipsComponent.decorators = [
|
|
170
200
|
{ type: core.Component, args: [{
|
|
171
201
|
selector: 'pep-chips',
|
|
172
|
-
template: "<mat-form-field class=\"pep-chips-container\" appearance=\"outline\">\n
|
|
202
|
+
template: "<ng-container *ngIf=\"type !== 'none'\">\n <mat-form-field class=\"pep-chips-container\" appearance=\"outline\">\n <mat-chip-list #chipList aria-label=\"Chip selection\"\n [ngClass]=\"{'mat-chip-list-stacked': orientation === 'vertical'}\" [multiple]=\"multiSelect\">\n <mat-chip *ngFor=\"let chip of chips\" class=\"pep-chips {{ styleType }}\" [disabled]=\"chip.disabled\"\n [selected]=\"chip.selected\" [removable]=\"chip.removable\" [selectable]=\"chip.selectable\"\n (removed)=\"onChipRemoved(chip)\" (selectionChange)=\"onSelectionChanged($event.selected, chip)\">\n <span class=\"ellipsis pull-left flip\" title=\"{{chip.value}}\">{{chip.value}}</span>\n <pep-button *ngIf=\"chip.removable\" matChipRemove sizeType=\"xs\" iconName=\"system_close\"\n [disabled]=\"chip.disabled\">\n </pep-button>\n </mat-chip>\n <input *ngIf=\"type === 'input'\" matInput [placeholder]=\"placeholder\" [matChipInputFor]=\"chipList\"\n [matChipInputAddOnBlur]=\"true\" (matChipInputTokenEnd)=\"onChipAdded($event)\">\n <div *ngIf=\"type === 'select'\" class=\"chips-select\" (click)=\"onChipsSelectClicked()\">{{ placeholder\n }}</div>\n </mat-chip-list>\n </mat-form-field>\n</ng-container>\n\n<div *ngIf=\"type === 'none'\" class=\"pep-chips-container pep-list-static\">\n <mat-chip-list #chipList aria-label=\"Chip selection\"\n [ngClass]=\"{'mat-chip-list-stacked': orientation === 'vertical'}\" [multiple]=\"multiSelect\">\n <mat-chip *ngFor=\"let chip of chips\" class=\"pep-chips {{ styleType }}\" [disabled]=\"chip.disabled\"\n [selected]=\"chip.selected\" [removable]=\"chip.removable\" [selectable]=\"chip.selectable\"\n (removed)=\"onChipRemoved(chip)\" (selectionChange)=\"onSelectionChanged($event.selected, chip)\">\n <span class=\"ellipsis pull-left flip\" title=\"{{chip.value}}\">{{chip.value}}</span>\n <!-- <pep-button *ngIf=\"chip.removable\" matChipRemove sizeType=\"xs\" iconName=\"system_close\" [disabled]=\"chip.disabled\">\n </pep-button> -->\n </mat-chip>\n </mat-chip-list>\n</div>",
|
|
173
203
|
providers: [PepChipsService],
|
|
174
|
-
styles: [".pep-chips-container ::ng-deep.mat-chip-list{width:100%}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper{grid-gap:.5rem;gap:.5rem;grid-gap:var(--pep-spacing-sm,.5rem);gap:var(--pep-spacing-sm,.5rem);margin:.5rem;margin:var(--pep-spacing-sm,.5rem)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips{font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-family:var(--pep-font-family-body,Inter),-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Oxygen-Sans,Ubuntu,Cantarell,\"Helvetica Neue\",sans-serif;font-size:.75rem;font-size:var(--pep-font-size-xs,.75rem);font-weight:400;font-weight:var(--pep-font-weight-normal,400);line-height:1rem;line-height:var(--pep-line-height-xs,1rem);margin:0;padding-top:0;padding-bottom:0;height:1.5rem;height:var(--pep-line-height-md,1.5rem);min-height:unset;z-index:1;grid-gap:.25rem;gap:.25rem;grid-gap:var(--pep-spacing-xs,.25rem);gap:var(--pep-spacing-xs,.25rem);max-width:100%}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips .mat-chip-remove{height:unset;width:unset;margin:0}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips .mat-chip-remove .pep-button{flex-shrink:0;border-radius:50%;min-width:unset;height:1rem;height:var(--pep-spacing-lg,1rem);width:1rem;width:var(--pep-spacing-lg,1rem)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips .mat-chip-remove .pep-button .mat-icon{height:.75rem;height:var(--pep-spacing-md,.75rem);width:.75rem;width:var(--pep-spacing-md,.75rem);font-size:1rem;font-size:var(--pep-font-size-md,1rem);margin:unset}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .mat-chip-input{font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-family:var(--pep-font-family-body,Inter),-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Oxygen-Sans,Ubuntu,Cantarell,\"Helvetica Neue\",sans-serif;font-size:.75rem;font-size:var(--pep-font-size-xs,.75rem);font-weight:400;font-weight:var(--pep-font-weight-normal,400);line-height:1.5rem;line-height:var(--pep-line-height-md,1.5rem);margin:0}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .chips-select{font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-family:var(--pep-font-family-body,Inter),-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Oxygen-Sans,Ubuntu,Cantarell,\"Helvetica Neue\",sans-serif;font-size:.75rem;font-size:var(--pep-font-size-xs,.75rem);font-weight:400;font-weight:var(--pep-font-weight-normal,400);line-height:1.5rem;line-height:var(--pep-line-height-md,1.5rem);z-index:1}.pep-chips-container ::ng-deep.mat-chip-list.mat-chip-list-stacked .pep-chips{justify-content:space-between;width:-webkit-fit-content!important;width:-moz-fit-content!important;width:fit-content!important}.pep-chips-container ::ng-deep.mat-chip-list.mat-chip-list-stacked .mat-chip-input{flex:unset;width:100%}", ".pep-chips-container ::ng-deep.mat-chip-list .mat-chip.mat-standard-chip:after{background:unset}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip.mat-standard-chip:focus:after{opacity:unset}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.regular{background:#fafafa;background:hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),98%);box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);border:1px solid hsl(0,0%,calc(10% + 30%));border:1px solid hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),calc(var(--pep-color-regular-l, 10%) + 30%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.regular:hover{background:#fafafa;background:hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),98%);box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.16);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.16);border:1px solid hsl(0,0%,calc(10% + 20%));border:1px solid hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),calc(var(--pep-color-regular-l, 10%) + 20%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.regular.mat-chip-selected{background:#e0e0e0;background:hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),88%);box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.32);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.32);border:1px solid #1a1a1a;border:1px solid hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),var(--pep-color-regular-l,10%));color:#1a1a1a!important;color:hsl(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%))!important}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.regular:focus{background:#e0e0e0;background:hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),88%);box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.16);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.16);border:1px solid #1a1a1a;border:1px solid hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),var(--pep-color-regular-l,10%));box-shadow:0 0 0 .25rem rgba(23,102,166,.5);box-shadow:0 0 0 var(--pep-spacing-xs,.25rem) hsla(var(--pep-color-text-link-h,207),var(--pep-color-text-link-s,76%),var(--pep-color-text-link-l,37%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak{background:rgba(26,26,26,.12);background:hsla(var(--pep-color-weak-h,0),var(--pep-color-weak-s,0%),var(--pep-color-weak-l,10%),.12)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak:hover{background:rgba(26,26,26,.16);background:hsla(var(--pep-color-weak-h,0),var(--pep-color-weak-s,0%),var(--pep-color-weak-l,10%),.16)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak.mat-chip-selected{box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);position:relative;color:#1a1a1a!important;color:hsl(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%))!important}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak.mat-chip-selected:not(.keep-background-on-focus){background:#fff;background:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak.mat-chip-selected:after{z-index:0;content:\"\";transition:all .25s;display:block;position:absolute;top:0;bottom:0;left:0;right:0;border-radius:inherit;border:1px solid #1a1a1a;border:1px solid hsl(var(--pep-color-weak-h,0),var(--pep-color-weak-s,0%),var(--pep-color-weak-l,10%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak:focus{box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);position:relative;box-shadow:0 0 0 .25rem rgba(23,102,166,.5);box-shadow:0 0 0 var(--pep-spacing-xs,.25rem) hsla(var(--pep-color-text-link-h,207),var(--pep-color-text-link-s,76%),var(--pep-color-text-link-l,37%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak:focus:not(.keep-background-on-focus){background:#fff;background:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak:focus:after{z-index:0;content:\"\";transition:all .25s;display:block;position:absolute;top:0;bottom:0;left:0;right:0;border-radius:inherit;border:1px solid #1a1a1a;border:1px solid hsl(var(--pep-color-weak-h,0),var(--pep-color-weak-s,0%),var(--pep-color-weak-l,10%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak-invert{background:hsla(0,0%,100%,.5);background:hsla(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak-invert:hover{background:hsla(0,0%,100%,.5);background:hsla(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%),.5);box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);cursor:pointer}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak-invert.mat-chip-selected{background:#fff;background:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%));box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.16);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.16);color:#1a1a1a!important;color:hsl(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%))!important}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak-invert:focus{background:#fff;background:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%));box-shadow:0 0 0 .25rem rgba(23,102,166,.5);box-shadow:0 0 0 var(--pep-spacing-xs,.25rem) hsla(var(--pep-color-text-link-h,207),var(--pep-color-text-link-s,76%),var(--pep-color-text-link-l,37%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong{font-weight:600;font-weight:var(--pep-font-weight-bold,600);background:#5d8109;background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),var(--pep-color-strong-l,27%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);color:#fff;color:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .svg-icon{fill:#fff;fill:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .svg-icon.stroke{fill:unset;stroke:#fff;stroke:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong:hover{background:hsl(78,87%,calc(27% - 8%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 8%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.16);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.16)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong.mat-chip-selected{background:hsl(78,87%,calc(27% - 15%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 15%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.32);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.32)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong:focus{background:hsl(78,87%,calc(27% - 15%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 15%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);box-shadow:0 0 0 .25rem rgba(23,102,166,.5);box-shadow:0 0 0 var(--pep-spacing-xs,.25rem) hsla(var(--pep-color-text-link-h,207),var(--pep-color-text-link-s,76%),var(--pep-color-text-link-l,37%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button{font-weight:600;font-weight:var(--pep-font-weight-bold,600);background:#5d8109;background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),var(--pep-color-strong-l,27%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);color:#fff;color:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button .svg-icon{fill:#fff;fill:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button .svg-icon.stroke{fill:unset;stroke:#fff;stroke:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:hover{background:hsl(78,87%,calc(27% - 8%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 8%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.16);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.16)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:focus{background:hsl(78,87%,calc(27% - 15%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 15%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);box-shadow:0 0 0 .25rem rgba(23,102,166,.5);box-shadow:0 0 0 var(--pep-spacing-xs,.25rem) hsla(var(--pep-color-text-link-h,207),var(--pep-color-text-link-s,76%),var(--pep-color-text-link-l,37%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:active{background:hsl(78,87%,calc(27% - 15%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 15%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.32);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.32)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled){box-shadow:unset;border:unset;background:#5d8109!important;background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),var(--pep-color-strong-l,27%))!important;opacity:.5!important;color:#fff;color:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled):after{border:unset}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled) .svg-icon{fill:rgba(26,26,26,.35);fill:hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.35)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled) .svg-icon.stroke{stroke:rgba(26,26,26,.35);stroke:hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.35)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled) .svg-icon{fill:#fff;fill:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled) .svg-icon.stroke{fill:unset;stroke:#fff;stroke:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}"]
|
|
204
|
+
styles: [".pep-chips-container ::ng-deep.mat-chip-list{width:100%}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper{grid-gap:.5rem;gap:.5rem;grid-gap:var(--pep-spacing-sm,.5rem);gap:var(--pep-spacing-sm,.5rem);margin:.5rem;margin:var(--pep-spacing-sm,.5rem)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips{font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-family:var(--pep-font-family-body,Inter),-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Oxygen-Sans,Ubuntu,Cantarell,\"Helvetica Neue\",sans-serif;font-size:.75rem;font-size:var(--pep-font-size-xs,.75rem);font-weight:400;font-weight:var(--pep-font-weight-normal,400);line-height:1rem;line-height:var(--pep-line-height-xs,1rem);margin:0;padding-top:0;padding-bottom:0;height:1.5rem;height:var(--pep-line-height-md,1.5rem);min-height:unset;z-index:1;grid-gap:.25rem;gap:.25rem;grid-gap:var(--pep-spacing-xs,.25rem);gap:var(--pep-spacing-xs,.25rem);max-width:100%}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips .mat-chip-remove{height:unset;width:unset;margin:0}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips .mat-chip-remove .pep-button{flex-shrink:0;border-radius:50%;min-width:unset;height:1rem;height:var(--pep-spacing-lg,1rem);width:1rem;width:var(--pep-spacing-lg,1rem)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips .mat-chip-remove .pep-button .mat-icon{height:.75rem;height:var(--pep-spacing-md,.75rem);width:.75rem;width:var(--pep-spacing-md,.75rem);font-size:1rem;font-size:var(--pep-font-size-md,1rem);margin:unset}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .mat-chip-input{font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-family:var(--pep-font-family-body,Inter),-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Oxygen-Sans,Ubuntu,Cantarell,\"Helvetica Neue\",sans-serif;font-size:.75rem;font-size:var(--pep-font-size-xs,.75rem);font-weight:400;font-weight:var(--pep-font-weight-normal,400);line-height:1.5rem;line-height:var(--pep-line-height-md,1.5rem);margin:0}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .chips-select{font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-family:var(--pep-font-family-body,Inter),-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Oxygen-Sans,Ubuntu,Cantarell,\"Helvetica Neue\",sans-serif;font-size:.75rem;font-size:var(--pep-font-size-xs,.75rem);font-weight:400;font-weight:var(--pep-font-weight-normal,400);line-height:1.5rem;line-height:var(--pep-line-height-md,1.5rem);z-index:1}.pep-chips-container ::ng-deep.mat-chip-list.mat-chip-list-stacked .pep-chips{justify-content:space-between;width:-webkit-fit-content!important;width:-moz-fit-content!important;width:fit-content!important}.pep-chips-container ::ng-deep.mat-chip-list.mat-chip-list-stacked .mat-chip-input{flex:unset;width:100%}.pep-chips-container ::ng-deep.mat-form-field-flex{padding:0}.pep-chips-container.pep-list-static ::ng-deep.mat-chip-list-wrapper{margin:0}", ".pep-chips-container ::ng-deep.mat-chip-list .mat-chip.mat-standard-chip:after{background:unset}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip.mat-standard-chip:focus:after{opacity:unset}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.regular{background:#fafafa;background:hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),98%);box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);border:1px solid hsl(0,0%,calc(10% + 30%));border:1px solid hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),calc(var(--pep-color-regular-l, 10%) + 30%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.regular:hover{background:#fafafa;background:hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),98%);box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.16);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.16);border:1px solid hsl(0,0%,calc(10% + 20%));border:1px solid hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),calc(var(--pep-color-regular-l, 10%) + 20%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.regular.mat-chip-selected{background:#e0e0e0;background:hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),88%);box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.32);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.32);border:1px solid #1a1a1a;border:1px solid hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),var(--pep-color-regular-l,10%));color:#1a1a1a!important;color:hsl(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%))!important}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.regular:focus{background:#e0e0e0;background:hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),88%);box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.16);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.16);border:1px solid #1a1a1a;border:1px solid hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),var(--pep-color-regular-l,10%));box-shadow:0 0 0 .25rem rgba(23,102,166,.5);box-shadow:0 0 0 var(--pep-spacing-xs,.25rem) hsla(var(--pep-color-text-link-h,207),var(--pep-color-text-link-s,76%),var(--pep-color-text-link-l,37%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak{background:rgba(26,26,26,.12);background:hsla(var(--pep-color-weak-h,0),var(--pep-color-weak-s,0%),var(--pep-color-weak-l,10%),.12)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak:hover{background:rgba(26,26,26,.16);background:hsla(var(--pep-color-weak-h,0),var(--pep-color-weak-s,0%),var(--pep-color-weak-l,10%),.16)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak.mat-chip-selected{box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);position:relative;color:#1a1a1a!important;color:hsl(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%))!important}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak.mat-chip-selected:not(.keep-background-on-focus){background:#fff;background:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak.mat-chip-selected:after{z-index:0;content:\"\";transition:all .25s;display:block;position:absolute;top:0;bottom:0;left:0;right:0;border-radius:inherit;border:1px solid #1a1a1a;border:1px solid hsl(var(--pep-color-weak-h,0),var(--pep-color-weak-s,0%),var(--pep-color-weak-l,10%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak:focus{box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);position:relative;box-shadow:0 0 0 .25rem rgba(23,102,166,.5);box-shadow:0 0 0 var(--pep-spacing-xs,.25rem) hsla(var(--pep-color-text-link-h,207),var(--pep-color-text-link-s,76%),var(--pep-color-text-link-l,37%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak:focus:not(.keep-background-on-focus){background:#fff;background:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak:focus:after{z-index:0;content:\"\";transition:all .25s;display:block;position:absolute;top:0;bottom:0;left:0;right:0;border-radius:inherit;border:1px solid #1a1a1a;border:1px solid hsl(var(--pep-color-weak-h,0),var(--pep-color-weak-s,0%),var(--pep-color-weak-l,10%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak-invert{background:hsla(0,0%,100%,.5);background:hsla(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak-invert:hover{background:hsla(0,0%,100%,.5);background:hsla(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%),.5);box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);cursor:pointer}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak-invert.mat-chip-selected{background:#fff;background:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%));box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.16);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.16);color:#1a1a1a!important;color:hsl(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%))!important}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.weak-invert:focus{background:#fff;background:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%));box-shadow:0 0 0 .25rem rgba(23,102,166,.5);box-shadow:0 0 0 var(--pep-spacing-xs,.25rem) hsla(var(--pep-color-text-link-h,207),var(--pep-color-text-link-s,76%),var(--pep-color-text-link-l,37%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong{font-weight:600;font-weight:var(--pep-font-weight-bold,600);background:#5d8109;background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),var(--pep-color-strong-l,27%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);color:#fff;color:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .svg-icon{fill:#fff;fill:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .svg-icon.stroke{fill:unset;stroke:#fff;stroke:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong:hover{background:hsl(78,87%,calc(27% - 8%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 8%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.16);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.16)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong.mat-chip-selected{background:hsl(78,87%,calc(27% - 15%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 15%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.32);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.32)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong:focus{background:hsl(78,87%,calc(27% - 15%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 15%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);box-shadow:0 0 0 .25rem rgba(23,102,166,.5);box-shadow:0 0 0 var(--pep-spacing-xs,.25rem) hsla(var(--pep-color-text-link-h,207),var(--pep-color-text-link-s,76%),var(--pep-color-text-link-l,37%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button{font-weight:600;font-weight:var(--pep-font-weight-bold,600);background:#5d8109;background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),var(--pep-color-strong-l,27%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);color:#fff;color:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button .svg-icon{fill:#fff;fill:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button .svg-icon.stroke{fill:unset;stroke:#fff;stroke:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:hover{background:hsl(78,87%,calc(27% - 8%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 8%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.16);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.16)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:focus{background:hsl(78,87%,calc(27% - 15%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 15%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);box-shadow:0 0 0 .25rem rgba(23,102,166,.5);box-shadow:0 0 0 var(--pep-spacing-xs,.25rem) hsla(var(--pep-color-text-link-h,207),var(--pep-color-text-link-s,76%),var(--pep-color-text-link-l,37%),.5)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:active{background:hsl(78,87%,calc(27% - 15%));background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),calc(var(--pep-color-strong-l, 27%) - 15%));box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.32);box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.32)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled){box-shadow:unset;border:unset;background:#5d8109!important;background:hsl(var(--pep-color-strong-h,78),var(--pep-color-strong-s,87%),var(--pep-color-strong-l,27%))!important;opacity:.5!important;color:#fff;color:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled):after{border:unset}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled) .svg-icon{fill:rgba(26,26,26,.35);fill:hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.35)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled) .svg-icon.stroke{stroke:rgba(26,26,26,.35);stroke:hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.35)}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled) .svg-icon{fill:#fff;fill:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}.pep-chips-container ::ng-deep.mat-chip-list .mat-chip-list-wrapper .pep-chips.strong .pep-button:disabled:not(.ignore-disabled) .svg-icon.stroke{fill:unset;stroke:#fff;stroke:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}"]
|
|
175
205
|
},] }
|
|
176
206
|
];
|
|
177
207
|
PepChipsComponent.ctorParameters = function () { return [
|
|
@@ -185,7 +215,8 @@
|
|
|
185
215
|
styleType: [{ type: core.Input }],
|
|
186
216
|
multiSelect: [{ type: core.Input }],
|
|
187
217
|
placeholder: [{ type: core.Input }],
|
|
188
|
-
fieldClick: [{ type: core.Output }]
|
|
218
|
+
fieldClick: [{ type: core.Output }],
|
|
219
|
+
selectionChange: [{ type: core.Output }]
|
|
189
220
|
};
|
|
190
221
|
|
|
191
222
|
var pepIcons = [
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pepperi-addons-ngx-lib-chips.umd.js","sources":["../../../projects/ngx-lib/chips/chips.service.ts","../../../projects/ngx-lib/chips/chips.component.ts","../../../projects/ngx-lib/chips/chips.module.ts","../../../projects/ngx-lib/chips/public-api.ts","../../../projects/ngx-lib/chips/pepperi-addons-ngx-lib-chips.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\nimport { Subject } from 'rxjs';\nimport { takeUntil } from 'rxjs/operators';\nimport { IPepChip } from './chips.model';\n\n@Injectable()\nexport class PepChipsService {\n private readonly _destroyer: Subject<void>;\n private _chips: IPepChip[] = []; \n\n constructor() {\n this._destroyer = new Subject();\n }\n\n get chips() {\n return this._chips;\n }\n\n initData(chips: IPepChip[]) {\n this._chips = []; \n if (chips?.length) {\n chips.forEach(chip => this.addChip(chip));\n } \n }\n\n addChip(chip: IPepChip) {\n this._chips.push({\n value: chip.value,\n disabled: chip.disabled !== undefined ? chip.disabled : false,\n selected: chip.selected !== undefined ? chip.selected : false,\n removable: chip.removable !== undefined ? chip.removable : true,\n selectable: chip.selectable !== undefined ? chip.selectable : true\n })\n }\n\n destroy() {\n this._destroyer.next();\n this._destroyer.complete();\n }\n\n get destroyer() {\n return takeUntil(this._destroyer);\n } \n\n}","import {\n Component,\n OnInit,\n Input,\n Output,\n EventEmitter,\n OnDestroy\n} from '@angular/core';\nimport { MatChipInputEvent, } from '@angular/material/chips';\nimport { TranslateService } from '@ngx-translate/core';\nimport { PepStyleType } from '@pepperi-addons/ngx-lib';\nimport { IPepChip, PepChipsOrientationType, PepChipsInputType } from './chips.model';\nimport { PepChipsService } from './chips.service';\n\n\n@Component({\n selector: 'pep-chips',\n templateUrl: './chips.component.html',\n styleUrls: ['./chips.component.scss', './chips.component.theme.scss'],\n providers: [PepChipsService]\n})\nexport class PepChipsComponent implements OnInit, OnDestroy {\n /**\n * Initial chip list.\n * \n * @memberof PepChipsComponent\n */\n @Input()\n set chips(chips: IPepChip[]) {\n this.chipsService.initData(chips);\n }\n get chips() {\n return this.chipsService.chips;\n }\n\n /**\n * The add chip emitter type.\n *\n * @type {PepChipsInputType}\n * @memberof PepChipsComponent\n */\n @Input() type: PepChipsInputType = 'input';\n\n /**\n * The chip layput direction type.\n *\n * @type {PepChipsOrientationType}\n * @memberof PepChipsComponent\n */\n @Input() orientation: PepChipsOrientationType = 'horizontal';\n\n /**\n * The style of the button.\n *\n * @type {PepStyleType}\n * @memberof PepButtonComponent\n */\n @Input() styleType: PepStyleType = 'regular';\n\n /**\n * Whether chip multi select allowed.\n * \n * @memberof PepChipsComponent\n */\n @Input() multiSelect = false;\n\n /**\n * Add new chip placeholder.\n * \n * @memberof PepChipsComponent\n */\n @Input() placeholder = '';\n\n /**\n * Add new chip(s) event.\n *\n * @type {EventEmitter<void>}\n * @memberof PepButtonComponent\n */\n @Output() fieldClick: EventEmitter<void> = new EventEmitter<void>();\n\n constructor(public chipsService: PepChipsService, private _translate: TranslateService) {\n //\n }\n\n ngOnInit(): void {\n this._translate.get(\"CHIPS.ADD_CHIP\").pipe(this.chipsService.destroyer).subscribe((text: string) => this.placeholder = text);\n }\n\n /**\n * Adding chip(s) to current chips list\n * @param chips Chip(s) to add\n */\n addChipsToList(chips: IPepChip[]) {\n chips.forEach(chip => this.chipsService.addChip(chip));\n }\n\n /**\n * On new chip added\n * @param event Chip addition event\n */\n onChipAdded(event: MatChipInputEvent): void {\n const value = (event.value || '').trim();\n\n if (value) {\n this.chipsService.addChip({\n value: value\n });\n // clear the input value\n event.chipInput!.clear();\n }\n }\n\n /**\n * On chip removed\n * @param chip Removed chip item\n */\n onChipRemoved(chip: IPepChip): void {\n const index = this.chips.indexOf(chip);\n\n if (index >= 0) {\n this.chips.splice(index, 1);\n }\n }\n\n /**\n * On chip selection status changed\n * @param isSelected Whether the chip is selected\n * @param chip Selected chip item\n */\n onSelectionChanged(isSelected: boolean, chip: IPepChip) {\n chip.selected = isSelected;\n }\n\n /**\n * On Add new chip(s) clicked\n */\n onChipsSelectClicked() {\n this.fieldClick.emit();\n }\n\n ngOnDestroy(): void {\n this.chipsService.destroy();\n }\n}","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ReactiveFormsModule } from '@angular/forms';\n\nimport { MatCommonModule } from '@angular/material/core';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatChipsModule, MAT_CHIPS_DEFAULT_OPTIONS } from '@angular/material/chips';\nimport { MatIconModule } from '@angular/material/icon';\nimport { COMMA, ENTER, TAB, SEMICOLON } from '@angular/cdk/keycodes';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport { \n PepIconModule,\n PepIconRegistry,\n pepIconSystemBolt,\n pepIconSystemClose\n} from '@pepperi-addons/ngx-lib/icon';\n\n//import { PepFieldTitleModule } from '@pepperi-addons/ngx-lib/field-title';\nimport { PepButtonModule } from '@pepperi-addons/ngx-lib/button';\nimport { PepChipsComponent } from './chips.component';\n\nconst pepIcons = [\n pepIconSystemBolt,\n pepIconSystemClose\n];\n\n\n@NgModule({\n declarations: [PepChipsComponent],\n imports: [\n CommonModule,\n ReactiveFormsModule, \n MatCommonModule,\n MatFormFieldModule,\n MatChipsModule,\n MatIconModule,\n PepNgxLibModule,\n PepIconModule,\n //PepFieldTitleModule, \n PepButtonModule\n ],\n exports: [PepChipsComponent],\n providers: [\n {\n provide: MAT_CHIPS_DEFAULT_OPTIONS,\n useValue: {\n separatorKeyCodes: [ENTER, COMMA]\n }\n }\n ] \n})\nexport class PepChipsModule {\n constructor(private pepIconRegistry: PepIconRegistry) {\n this.pepIconRegistry.registerIcons(pepIcons);\n }\n}\n","/*\n * Public API Surface of ngx-lib/chips\n */\nexport * from './chips.module';\nexport * from './chips.component';\nexport * from './chips.model';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {PepChipsService as ɵa} from './chips.service';"],"names":["Subject","takeUntil","Injectable","EventEmitter","Component","TranslateService","Input","Output","pepIconSystemBolt","pepIconSystemClose","ENTER","COMMA","NgModule","CommonModule","ReactiveFormsModule","MatCommonModule","MatFormFieldModule","MatChipsModule","MatIconModule","PepNgxLibModule","PepIconModule","PepButtonModule","MAT_CHIPS_DEFAULT_OPTIONS","PepIconRegistry"],"mappings":";;;;;;;QAUI;YAFQ,WAAM,GAAe,EAAE,CAAC;YAG5B,IAAI,CAAC,UAAU,GAAG,IAAIA,YAAO,EAAE,CAAC;SACnC;QAED,sBAAI,kCAAK;iBAAT;gBACI,OAAO,IAAI,CAAC,MAAM,CAAC;aACtB;;;WAAA;QAED,kCAAQ,GAAR,UAAS,KAAiB;YAA1B,iBAKC;YAJG,IAAI,CAAC,MAAM,GAAG,EAAE,CAAC;YACjB,IAAI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CAAC,QAAQ,GAAG,UAAU,CAAC;SAC9B;;;;QAKD,gDAAoB,GAApB;YACI,IAAI,CAAC,UAAU,CAAC,IAAI,EAAE,CAAC;SAC1B;QAED,uCAAW,GAAX;YACI,IAAI,CAAC,YAAY,CAAC,OAAO,EAAE,CAAC;SAC/B;;;;gBAhIJC,cAAS,SAAC;oBACP,QAAQ,EAAE,WAAW;oBACrB,8oCAAqC;oBAErC,SAAS,EAAE,CAAC,eAAe,CAAC;;iBAC/B;;;gBARQ,eAAe;gBAHfC,uBAAgB;;;wBAkBpBC,UAAK;uBAcLA,UAAK;8BAQLA,UAAK;4BAQLA,UAAK;8BAOLA,UAAK;8BAOLA,UAAK;6BAQLC,WAAM;;;ICzDX,IAAM,QAAQ,GAAG;QACbC,sBAAiB;QACjBC,uBAAkB;KACrB,CAAC;aAqBkB;QACR,iBAAiB,EAAE,CAACC,cAAK,EAAEC,cAAK,CAAC;;;QAMzC,wBAAoB,eAAgC;YAAhC,oBAAe,GAAf,eAAe,CAAiB;YAChD,IAAI,CAAC,eAAe,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC;SAChD;;;;gBA3BJC,aAAQ,SAAC;oBACN,YAAY,EAAE,CAAC,iBAAiB,CAAC;oBACjC,OAAO,EAAE;wBACLC,mBAAY;wBACZC,yBAAmB;wBACnBC,sBAAe;wBACfC,4BAAkB;wBAClBC,oBAAc;wBACdC,oBAAa;wBACbC,sBAAe;wBACfC,kBAAa;;wBAEbC,sBAAe;qBAClB;oBACD,OAAO,EAAE,CAAC,iBAAiB,CAAC;oBAC5B,SAAS,EAAE;wBACP;4BACE,OAAO,EAAEC,+BAAyB;4BAClC,QAAQ,IAEP;yBACF;qBACF;iBACN;;;gBAtCGC,oBAAe;;;ICbnB;;;;ICAA;;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"pepperi-addons-ngx-lib-chips.umd.js","sources":["../../../projects/ngx-lib/chips/chips.service.ts","../../../projects/ngx-lib/chips/chips.component.ts","../../../projects/ngx-lib/chips/chips.module.ts","../../../projects/ngx-lib/chips/public-api.ts","../../../projects/ngx-lib/chips/pepperi-addons-ngx-lib-chips.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\nimport { Subject } from 'rxjs';\nimport { takeUntil } from 'rxjs/operators';\nimport { IPepChip } from './chips.model';\n\n@Injectable()\nexport class PepChipsService {\n private readonly _destroyer: Subject<void>;\n private _chips: IPepChip[] = []; \n\n constructor() {\n this._destroyer = new Subject();\n }\n\n get chips() {\n return this._chips;\n }\n\n get selected() {\n return this._chips.filter(chip => chip.selected).map(chip => chip.value);\n }\n\n initData(chips: IPepChip[]) {\n this._chips = []; \n if (chips?.length) {\n chips.forEach(chip => this.addChip(chip));\n } \n }\n\n addChip(chip: IPepChip) {\n this._chips.push({\n value: chip.value,\n disabled: chip.disabled !== undefined ? chip.disabled : false,\n selected: chip.selected !== undefined ? chip.selected : false,\n removable: chip.removable !== undefined ? chip.removable : true,\n selectable: chip.selectable !== undefined ? chip.selectable : true\n })\n }\n\n destroy() {\n this._destroyer.next();\n this._destroyer.complete();\n }\n\n get destroyer() {\n return takeUntil(this._destroyer);\n } \n\n}","import {\n Component,\n OnInit,\n Input,\n Output,\n EventEmitter,\n OnDestroy\n} from '@angular/core';\nimport { MatChipInputEvent, } from '@angular/material/chips';\nimport { TranslateService } from '@ngx-translate/core';\nimport { PepStyleType } from '@pepperi-addons/ngx-lib';\nimport { IPepChip, PepChipsOrientationType, PepChipsInputType, IPepChipSelection } from './chips.model';\nimport { PepChipsService } from './chips.service';\n\n\n@Component({\n selector: 'pep-chips',\n templateUrl: './chips.component.html',\n styleUrls: ['./chips.component.scss', './chips.component.theme.scss'],\n providers: [PepChipsService]\n})\nexport class PepChipsComponent implements OnInit, OnDestroy {\n /**\n * The chips within the chip list.\n * \n * @memberof PepChipsComponent\n */\n @Input()\n set chips(chips: IPepChip[]) {\n this.chipsService.initData(chips);\n }\n get chips() {\n return this.chipsService.chips;\n }\n\n /**\n * The add chip emitter type.\n *\n * @type {PepChipsInputType}\n * @memberof PepChipsComponent\n */\n @Input() type: PepChipsInputType = 'input';\n\n /**\n * The chip layput direction type.\n *\n * @type {PepChipsOrientationType}\n * @memberof PepChipsComponent\n */\n @Input() orientation: PepChipsOrientationType = 'horizontal';\n\n /**\n * The style of the button.\n *\n * @type {PepStyleType}\n * @memberof PepButtonComponent\n */\n @Input() styleType: PepStyleType = 'regular';\n\n /**\n * Whether chip multi select allowed.\n * \n * @memberof PepChipsComponent\n */\n @Input() multiSelect = false;\n\n /**\n * Add new chip placeholder.\n * \n * @memberof PepChipsComponent\n */\n @Input() placeholder = '';\n\n /**\n * Add new chip(s) event.\n *\n * @type {EventEmitter<void>}\n * @memberof PepButtonComponent\n */\n @Output() fieldClick: EventEmitter<void> = new EventEmitter<void>();\n @Output() selectionChange: EventEmitter<IPepChipSelection> = new EventEmitter<IPepChipSelection>();\n\n /**\n * Selected chip(s)\n */\n get selected() {\n const selected = this.chipsService.selected; \n if (this.multiSelect) {\n return selected.length ? selected : [];\n } else {\n return selected.length ? selected[0] : null;\n } \n }\n\n constructor(public chipsService: PepChipsService, private _translate: TranslateService) {\n //\n }\n\n ngOnInit(): void {\n if (!this.placeholder) {\n this._translate.get(\"CHIPS.ADD_CHIP\").pipe(this.chipsService.destroyer).subscribe((text: string) => this.placeholder = text);\n } \n }\n\n /**\n * Adding chip(s) to current chip list\n * @param chips Chip(s) to add\n */\n addChipsToList(chips: IPepChip[]) {\n chips.forEach(chip => this.chipsService.addChip(chip));\n } \n\n /**\n * On new chip added\n * @param event Chip addition event\n */\n onChipAdded(event: MatChipInputEvent): void {\n const value = (event.value || '').trim();\n\n if (value) {\n this.chipsService.addChip({\n value: value\n });\n // clear the input value\n event.chipInput!.clear();\n }\n }\n\n /**\n * On chip removed\n * @param chip Removed chip item\n */\n onChipRemoved(chip: IPepChip): void {\n const index = this.chips.indexOf(chip);\n\n if (index >= 0) {\n this.chips.splice(index, 1);\n }\n }\n\n /**\n * On chip selection status changed\n * @param isSelected Whether the chip is selected\n * @param chip Selected chip item\n */\n onSelectionChanged(isSelected: boolean, chip: IPepChip) {\n chip.selected = isSelected;\n this.selectionChange.emit({\n value: chip.value,\n isSelected: isSelected\n })\n }\n\n /**\n * On Add new chip(s) clicked\n */\n onChipsSelectClicked() {\n this.fieldClick.emit();\n }\n\n ngOnDestroy(): void {\n this.chipsService.destroy();\n }\n}","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ReactiveFormsModule } from '@angular/forms';\n\nimport { MatCommonModule } from '@angular/material/core';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatChipsModule, MAT_CHIPS_DEFAULT_OPTIONS } from '@angular/material/chips';\nimport { MatIconModule } from '@angular/material/icon';\nimport { COMMA, ENTER, TAB, SEMICOLON } from '@angular/cdk/keycodes';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport { \n PepIconModule,\n PepIconRegistry,\n pepIconSystemBolt,\n pepIconSystemClose\n} from '@pepperi-addons/ngx-lib/icon';\n\n//import { PepFieldTitleModule } from '@pepperi-addons/ngx-lib/field-title';\nimport { PepButtonModule } from '@pepperi-addons/ngx-lib/button';\nimport { PepChipsComponent } from './chips.component';\n\nconst pepIcons = [\n pepIconSystemBolt,\n pepIconSystemClose\n];\n\n\n@NgModule({\n declarations: [PepChipsComponent],\n imports: [\n CommonModule,\n ReactiveFormsModule, \n MatCommonModule,\n MatFormFieldModule,\n MatChipsModule,\n MatIconModule,\n PepNgxLibModule,\n PepIconModule,\n //PepFieldTitleModule, \n PepButtonModule\n ],\n exports: [PepChipsComponent],\n providers: [\n {\n provide: MAT_CHIPS_DEFAULT_OPTIONS,\n useValue: {\n separatorKeyCodes: [ENTER, COMMA]\n }\n }\n ] \n})\nexport class PepChipsModule {\n constructor(private pepIconRegistry: PepIconRegistry) {\n this.pepIconRegistry.registerIcons(pepIcons);\n }\n}\n","/*\n * Public API Surface of ngx-lib/chips\n */\nexport * from './chips.module';\nexport * from './chips.component';\nexport * from './chips.model';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {PepChipsService as ɵa} from './chips.service';"],"names":["Subject","takeUntil","Injectable","EventEmitter","Component","TranslateService","Input","Output","pepIconSystemBolt","pepIconSystemClose","ENTER","COMMA","NgModule","CommonModule","ReactiveFormsModule","MatCommonModule","MatFormFieldModule","MatChipsModule","MatIconModule","PepNgxLibModule","PepIconModule","PepButtonModule","MAT_CHIPS_DEFAULT_OPTIONS","PepIconRegistry"],"mappings":";;;;;;;QAUI;YAFQ,WAAM,GAAe,EAAE,CAAC;YAG5B,IAAI,CAAC,UAAU,GAAG,IAAIA,YAAO,EAAE,CAAC;SACnC;QAED,sBAAI,kCAAK;iBAAT;gBACI,OAAO,IAAI,CAAC,MAAM,CAAC;aACtB;;;WAAA;QAED,sBAAI,qCAAQ;iBAAZ;gBACI,OAAO,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,UAAA,IAAI,IAAI,OAAA,IAAI,CAAC,QAAQ,GAAA,CAAC,CAAC,GAAG,CAAC,UAAA,IAAI,IAAI,OAAA,IAAI,CAAC,KAAK,GAAA,CAAC,CAAC;aAC5E;;;WAAA;QAED,kCAAQ,GAAR,UAAS,KAAiB;YAA1B,iBAKC;YAJG,IAAI,CAAC,MAAM,GAAG,EAAE,CAAC;YACjB,IAAI,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,MAAM,EAAE;gBACf,KAAK,CAAC,OAAO,CAAC,UAAA,IAAI,IAAI,OAAA,KAAI,CAAC,OAAO,CAAC,IAAI,CAAC,GAAA,CAAC,CAAC;aAC7C;SACJ;QAED,iCAAO,GAAP,UAAQ,IAAc;YAClB,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC;gBACb,KAAK,EAAE,IAAI,CAAC,KAAK;gBACjB,QAAQ,EAAE,IAAI,CAAC,QAAQ,KAAK,SAAS,GAAG,IAAI,CAAC,QAAQ,GAAG,KAAK;gBAC7D,QAAQ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tCGC,oBAAe;;;ICbnB;;;;ICAA;;;;;;;;;;;;;;;"}
|
|
@@ -308,10 +308,10 @@
|
|
|
308
308
|
}
|
|
309
309
|
}
|
|
310
310
|
//flag to indicate whether validation on dirty is required
|
|
311
|
-
this.form.addControl('validateOnDirty', new forms.FormControl(this.type === 'text'));
|
|
311
|
+
this.form.addControl('validateOnDirty', new forms.FormControl(this.type === 'text' || this.type === 'duration'));
|
|
312
312
|
this.readonly = this.type === 'duration' ? true : this.readonly; // Hack until we develop Timer UI for editing Duration field
|
|
313
313
|
//load default error text
|
|
314
|
-
if (this.type === 'text' && this.regex && !this.regexError) {
|
|
314
|
+
if ((this.type === 'text' || this.type === 'duration') && this.regex && !this.regexError) {
|
|
315
315
|
this.translate.get('MESSAGES.ERROR_INVALID_PATTERN').subscribe(function (text) { return _this.regexError = text; });
|
|
316
316
|
}
|
|
317
317
|
this.updateFormFieldValue();
|
|
@@ -441,7 +441,7 @@
|
|
|
441
441
|
PepTextboxComponent.decorators = [
|
|
442
442
|
{ type: core.Component, args: [{
|
|
443
443
|
selector: 'pep-textbox',
|
|
444
|
-
template: "<ng-container [formGroup]=\"form\">\n <ng-template #pepTemplate let-isFormView=\"isFormView\" let-hasParent=\"hasParent\">\n <pep-field-title *ngIf=\"renderTitle && isFormView && !hasParent\" [label]=\"label\" [mandatory]=\"mandatory\"\n [disabled]=\"disabled\" [maxFieldCharacters]=\"maxFieldCharacters\" [hint]=\"hint\" [xAlignment]=\"xAlignment\"\n [showTitle]=\"showTitle\" [inputLength]=\"input.value?.length\">\n </pep-field-title>\n <mat-form-field appearance=\"outline\">\n <input #input matInput pepTextboxValidation [formControlName]=\"key\" [errorStateMatcher]=\"matcher\" [id]=\"key\"\n [name]=\"key\" class=\" body-sm \" autocomplete=\"off\"\n maxlength=\"{{ maxFieldCharacters > 0 ? maxFieldCharacters : 99999 }}\"\n [placeholder]=\"
|
|
444
|
+
template: "<ng-container [formGroup]=\"form\">\n <ng-template #pepTemplate let-isFormView=\"isFormView\" let-hasParent=\"hasParent\">\n <pep-field-title *ngIf=\"renderTitle && isFormView && !hasParent\" [label]=\"label\" [mandatory]=\"mandatory\"\n [disabled]=\"disabled\" [maxFieldCharacters]=\"maxFieldCharacters\" [hint]=\"hint\" [xAlignment]=\"xAlignment\"\n [showTitle]=\"showTitle\" [inputLength]=\"input.value?.length\">\n </pep-field-title>\n <mat-form-field appearance=\"outline\">\n <input #input matInput pepTextboxValidation [formControlName]=\"key\" [errorStateMatcher]=\"matcher\" [id]=\"key\"\n [name]=\"key\" class=\" body-sm \" autocomplete=\"off\"\n maxlength=\"{{ maxFieldCharacters > 0 ? maxFieldCharacters : 99999 }}\"\n [placeholder]=\"!disabled ? placeholder : ''\"\n [ngStyle]=\"{ color: textColor, 'text-align': xAlignment == 'center' ? 'center' : xAlignment == 'right' ? 'right' : 'left' }\"\n title=\"{{ formattedValue }}\" [type]=\"type\" [value]=\"displayValue\"\n (keyup.enter)=\"$event?.currentTarget?.blur()\" (focus)=\"onFocus($event)\" (blur)=\"onBlur($event)\"\n (change)=\"onChange($event)\"\n [ngClass]=\"{'disable-hidden': disabled && formattedValue?.length > 0 && (type === 'phone' || type === 'email' || type === 'link')}\" />\n\n <span\n *ngIf=\"disabled && formattedValue?.length > 0 && (type === 'phone' || type === 'email' || type === 'link')\"\n class=\"dis-grid\">\n <a href=\"javascript:void(0)\" (click)=\"anchorClicked()\" [id]=\"key\" [name]=\"key\"\n class=\"color-link body-sm \"> {{formattedValue}}</a>\n </span>\n <mat-error *ngIf=\"renderError\"> \n <ng-container *ngIf=\"mandatory && input.value.length == 0 then requiredError else otherErrorContainer\">\n </ng-container>\n <ng-template #requiredError>\n <span class=\"body-xs\" [title]=\"('MESSAGES.ERROR_IS_REQUIRED' | translate: { field: label })\"\n [innerText]=\"('MESSAGES.ERROR_IS_REQUIRED' | translate: { field: label })\">\n </span>\n </ng-template>\n <ng-template #otherErrorContainer>\n <ng-template *ngIf=\"form.get(key).errors?.pattern then patternError else otherError\"></ng-template>\n <ng-template #patternError>\n <span class=\"body-xs\">\n {{ regexError }}\n </span>\n </ng-template>\n <ng-template #otherError>\n <span class=\"body-xs\" [title]=\"(input.value | pepToNumber) > this.maxValue || (input.value | pepToNumber) < this.minValue ?\n ('MESSAGES.ERROR_RANGE_IS_NOT_VALID' | translate: { min: minValue, max: maxValue }) :\n ('MESSAGES.ERROR_IS_NOT_VALID' | translate: { field: label })\" [innerText]=\"(input.value | pepToNumber) > this.maxValue || (input.value | pepToNumber) < this.minValue ?\n ('MESSAGES.ERROR_RANGE_IS_NOT_VALID' | translate: { min: minValue, max: maxValue }) :\n ('MESSAGES.ERROR_IS_NOT_VALID' | translate: { field: label })\">\n </span>\n </ng-template>\n </ng-template>\n </mat-error> \n <pep-textbox-icon *ngIf=\"renderSymbol && isFormView && xAlignment == 'right'\" matPrefix [value]=\"value\"\n [label]=\"label\" [type]=\"type\" [disabled]=\"disabled\">\n </pep-textbox-icon>\n <pep-textbox-icon *ngIf=\"renderSymbol && isFormView && (xAlignment == 'left')\" matSuffix [value]=\"value\"\n [label]=\"label\" [type]=\"type\" [disabled]=\"disabled\">\n </pep-textbox-icon>\n </mat-form-field>\n </ng-template> \n <ng-container *ngIf=\"layoutType === 'form'\">\n <ng-container *ngIf=\"parentFieldKey; then groupedBlock; else regularBlock\"></ng-container>\n <ng-template #regularBlock>\n <ng-container *ngTemplateOutlet=\"pepTemplate; context: { isFormView: true, hasParent: false }\">\n </ng-container>\n </ng-template>\n <ng-template #groupedBlock>\n <ng-container [formGroupName]=\"parentFieldKey\">\n <mat-form-field appearance=\"outline\">\n <!-- (keyup)=\"onKeyUp($event)\" -->\n <input pepTextboxValidation [id]=\"key\" [name]=\"key\" class=\" body-sm \" matInput autocomplete=\"off\"\n [placeholder]=\"!disabled ? placeholder : ''\" title=\"{{ formattedValue }}\"\n [formControlName]=\"key\" [value]=\"value\" (blur)=\"onBlur($event)\" (change)=\"onChange($event)\"\n (keyup.enter)=\"$event?.currentTarget?.blur()\" (focus)=\"onFocus($event)\" />\n </mat-form-field>\n <!-- <ng-container *ngTemplateOutlet=\"pepTemplate; context: { isFormView: true, hasParent: true }\"></ng-container> -->\n </ng-container>\n </ng-template>\n </ng-container>\n\n <ng-container *ngIf=\"layoutType === 'card'\">\n <ng-container *ngIf=\"isInEditMode; then editBlock; else readOnlyBlock\"></ng-container>\n <ng-template #editBlock>\n <div [ngClass]=\"{'one-row': rowSpan === 1}\">\n <ng-container *ngTemplateOutlet=\"pepTemplate; context: { isFormView: false, hasParent: false }\">\n </ng-container>\n </div>\n </ng-template>\n <ng-template #readOnlyBlock>\n <div class=\"pep-card-input card-flex-container\" [ngStyle]=\"{ color: textColor }\"\n [class]=\"'text-align-' + xAlignment\" [ngClass]=\"{'one-row': rowSpan === 1,\n 'multi-rows': rowSpan > 1,\n 'pep-button weak': isActive && !disabled}\"\n (click)=\"!disabled ? cardTemplateClicked($event) : ''\">\n <span *ngIf=\"showTitle && label != ''\" class=\"body-xs title\" title=\"{{ label }}\">{{ label\n }} </span>\n <span [id]=\"key\" title=\"{{ formattedValue }}\" class=\"body-sm value\"\n [ngClass]=\"{'multi-rows-text': rowSpan > 1}\" [ngStyle]=\"{ '-webkit-line-clamp': rowSpan }\">{{\n formattedValue }}</span>\n <button *ngIf=\"isActive && !disabled\" class=\"pep-button weak card-edit-button\" mat-button>\n <mat-icon>\n <pep-icon name=\"system_edit\">\n </pep-icon>\n </mat-icon>\n </button>\n </div>\n </ng-template>\n\n </ng-container>\n\n <ng-container *ngIf=\"layoutType === 'table'\">\n <ng-container *ngIf=\"isActive && !disabled; then selectedBlock; else notSelectedBlock\"></ng-container>\n <ng-template #selectedBlock>\n <ng-container *ngTemplateOutlet=\"pepTemplate; context: { isFormView: false, hasParent: false }\">\n </ng-container>\n </ng-template>\n <ng-template #notSelectedBlock>\n <ng-container *ngIf=\"formattedValue?.length > 0; then notEmptyBlock; else emptyBlock\"></ng-container>\n <ng-template #notEmptyBlock>\n <ng-container [ngSwitch]=\"type\">\n <ng-container *ngSwitchCase=\"'link'\">\n <a [id]=\"key\" class=\"color-link body-sm pep-report-input\"\n [ngClass]=\"{'disable': (disabled && value === '')}\" *ngIf=\"formattedValue != null\"\n title=\"{{ formattedValue }}\" target=\"_blank\" href=\"{{ value ? value : formattedValue }}\">{{\n formattedValue }}</a>\n </ng-container>\n <ng-container *ngSwitchDefault>\n <span [id]=\"key\" class=\"body-sm pep-report-input\" [ngClass]=\"{'readonly': disabled}\"\n title=\"{{ formattedValue }}\" [ngStyle]=\"{ color: textColor }\">{{ formattedValue }}</span>\n </ng-container>\n </ng-container>\n </ng-template>\n <ng-template #emptyBlock>\n <span [id]=\"key\"> </span>\n </ng-template>\n </ng-template>\n </ng-container>\n\n</ng-container>",
|
|
445
445
|
changeDetection: core.ChangeDetectionStrategy.OnPush,
|
|
446
446
|
styles: [":host{height:inherit;display:grid}:host>*{align-self:center;align-items:baseline}.disable-hidden{display:none}.dis-grid{display:grid}.multi-rows-text{display:-webkit-box;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;white-space:normal!important}", ""]
|
|
447
447
|
},] }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pepperi-addons-ngx-lib-textbox.umd.js","sources":["../../../projects/ngx-lib/textbox/textbox.component.ts","../../../projects/ngx-lib/textbox/textbox-validation.directive.ts","../../../projects/ngx-lib/textbox/textbox.module.ts","../../../projects/ngx-lib/textbox/public-api.ts","../../../projects/ngx-lib/textbox/pepperi-addons-ngx-lib-textbox.ts"],"sourcesContent":["import {\n Component,\n OnInit,\n OnChanges,\n Input,\n Output,\n EventEmitter,\n ChangeDetectionStrategy,\n ElementRef,\n ViewChild,\n Renderer2,\n OnDestroy,\n ChangeDetectorRef,\n HostBinding,\n} from '@angular/core';\nimport { FormGroup, FormBuilder } from '@angular/forms';\nimport { TranslateService } from '@ngx-translate/core';\nimport {\n PepLayoutType,\n PepCustomizationService,\n PepHorizontalAlignment,\n DEFAULT_HORIZONTAL_ALIGNMENT,\n PepTextboxFieldType,\n PepTextboxField,\n PepFieldBase,\n PepUtilitiesService,\n} from '@pepperi-addons/ngx-lib';\nimport { FormControl, FormGroupDirective, NgForm, Validators } from '@angular/forms';\nimport { ErrorStateMatcher } from '@angular/material/core';\n\n/** error when invalid control is dirty or touched */\nexport class TextErrorStateMatcher implements ErrorStateMatcher {\n isErrorState(control: FormControl | null, form: FormGroupDirective | NgForm | null): boolean {\n const validateOnDirty = form?.form?.controls?.['validateOnDirty']?.value;\n return !!(validateOnDirty && control && control.invalid && (control.dirty || control.touched));\n }\n}\n\n/**\n * This is a text box input component that can be use to\n *\n * @export\n * @class PepTextboxComponent\n * @implements {OnChanges}\n * @implements {OnInit}\n * @implements {OnDestroy}\n */\n@Component({\n selector: 'pep-textbox',\n templateUrl: './textbox.component.html',\n styleUrls: ['./textbox.component.scss', './textbox.component.theme.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class PepTextboxComponent implements OnChanges, OnInit, OnDestroy {\n\n @HostBinding('attr.data-qa') dataQa = '';\n\n private _key = '';\n /**\n * The text box key\n *\n * @memberof PepTextboxComponent\n */\n @Input()\n set key(value) {\n this._key = value;\n this.dataQa = value;\n }\n get key(): string {\n return this._key;\n }\n\n private _value = '';\n /**\n * The value of the text box.\n *\n * @memberof PepTextboxComponent\n */\n @Input()\n set value(value: string) {\n if (!value) {\n value = '';\n }\n\n this._value = value;\n this.setFormattedValue(value);\n }\n get value(): string {\n return this._value;\n }\n\n private _formattedValue = '';\n /**\n * The formatted value.\n *\n * @memberof PepTextboxComponent\n */\n @Input()\n set formattedValue(value: string) {\n // Do nothing.\n // if (!value) {\n // value = '';\n // }\n\n // if (this._calculateFormattedValue) {\n // this._calculateFormattedValue = false;\n // }\n\n // this.setFormattedValue(value);\n }\n get formattedValue(): string {\n return this._formattedValue;\n }\n\n private _minFractionDigits: number = NaN;\n @Input()\n set minFractionDigits(value: number) {\n this._minFractionDigits = value;\n this.setFormattedValue(this.value);\n }\n get minFractionDigits(): number {\n return this._minFractionDigits;\n }\n\n private _maxFractionDigits: number = NaN;\n @Input()\n set maxFractionDigits(value: number) {\n this._maxFractionDigits = value;\n this.setFormattedValue(this.value);\n }\n get maxFractionDigits(): number {\n return this._maxFractionDigits;\n }\n\n /**\n * The accessory sign.\n *\n * @memberof PepTextboxComponent\n */\n @Input() accessory = '';\n\n /**\n * The title of the textbox.\n *\n * @memberof PepTextboxComponent\n */\n @Input() label = '';\n\n /**\n * The placeholder (relevant only for children - if parent isn't null).\n *\n * @memberof PepTextboxComponent\n */\n @Input() placeholder = '';\n\n /**\n * The type of the textbox.\n *\n * @type {PepTextboxFieldType}\n * @memberof PepTextboxComponent\n */\n private _type: PepTextboxFieldType = 'text';\n @Input()\n set type(value: PepTextboxFieldType) {\n this._type = value;\n\n if (this.value) {\n this.setFormattedValue(this.value);\n }\n }\n get type(): PepTextboxFieldType {\n return this._type;\n }\n\n /**\n * If the textbox is mandatory\n *\n * @memberof PepTextboxComponent\n */\n @Input() mandatory = false;\n\n // TODO: Check if should remove disabled and keep only readonly.\n /**\n * If the textbox is disabled.\n *\n * @memberof PepTextboxComponent\n */\n @Input() disabled = false;\n\n /**\n * If the textbox is readonly\n *\n * @memberof PepTextboxComponent\n */\n @Input() readonly = false;\n @Input() maxFieldCharacters: number;\n @Input() hint: string;\n @Input() textColor = '';\n @Input() xAlignment: PepHorizontalAlignment = DEFAULT_HORIZONTAL_ALIGNMENT;\n @Input() rowSpan = 1;\n // @Input() lastFocusField: any;\n @Input() minValue = NaN;\n @Input() maxValue = NaN;\n\n private _visible = true;\n @Input()\n set visible(visible: boolean) {\n this._visible = visible;\n if (visible) {\n this.renderer.removeClass(\n this.element.nativeElement,\n 'hidden-element'\n );\n } else {\n this.renderer.addClass(\n this.element.nativeElement,\n 'hidden-element'\n );\n }\n }\n get visible(): boolean {\n return this._visible;\n }\n\n @Input() form: FormGroup = null;\n @Input() isActive = false;\n @Input() showTitle = true;\n @Input() renderTitle = true;\n @Input() renderError = true;\n @Input() renderSymbol = true;\n @Input() layoutType: PepLayoutType = 'form';\n @Input() parentFieldKey: string = null;\n @Input() regex: string | RegExp;\n @Input() regexError = '';\n\n /**\n * The value change event.\n *\n * @type {EventEmitter<string>}\n * @memberof PepTextboxComponent\n */\n @Output()\n valueChange: EventEmitter<string> = new EventEmitter<string>();\n\n @Output()\n formValidationChange: EventEmitter<boolean> = new EventEmitter<boolean>();\n\n @ViewChild('input') input: ElementRef;\n\n private _calculateFormattedValue = true;\n get calculateFormattedValue(): boolean {\n return this._calculateFormattedValue;\n }\n\n controlType = 'textbox';\n\n standAlone = false;\n isInEditMode = false;\n isInFocus: boolean;\n\n matcher = new TextErrorStateMatcher();\n\n constructor(\n public fb: FormBuilder,\n private customizationService: PepCustomizationService,\n private renderer: Renderer2,\n private element: ElementRef,\n private translate: TranslateService,\n private utilitiesService: PepUtilitiesService\n ) {\n this.isInFocus = false;\n }\n\n private setFormattedValue(value: string) {\n if (this._calculateFormattedValue) {\n if (this.type === 'currency') {\n this._formattedValue = this.utilitiesService.formatCurrency(value, this.accessory, this.minFractionDigits, this.maxFractionDigits);\n } else if (this.type === 'percentage') {\n this._formattedValue = this.utilitiesService.formatPercent(value, this.minFractionDigits, this.maxFractionDigits);\n } else if (this.type === 'real') {\n this._formattedValue = this.utilitiesService.formatDecimal(value, this.minFractionDigits, this.maxFractionDigits);\n } else if (this.type === 'int') {\n this._formattedValue = this.utilitiesService.formatNumber(value);\n } else if (this.type === 'duration') {\n this._formattedValue = this.utilitiesService.formatDuration(value, { duration: 'seconds' });\n } else {\n this._formattedValue = value;\n }\n } else {\n this._formattedValue = value;\n }\n\n this.updateFormFieldValue();\n }\n\n private updateFormFieldValue() {\n this.customizationService.updateFormFieldValue(\n this.form,\n this.key,\n this.formattedValue,\n this.parentFieldKey\n );\n }\n\n get displayValue(): string {\n let res = '';\n\n if (this.type == 'link') {\n res = this.formattedValue;\n } else if (this.isNumberType()) {\n res = this.isInFocus ? (this.value.length > 0 ? this.utilitiesService.formatDecimal(this.value, this.minFractionDigits, this.maxFractionDigits) : '') : this.formattedValue;\n } else {\n res = this.isInFocus ? this.value : this.formattedValue;\n }\n\n return res;\n }\n\n private setDefaultForm(): void {\n const pepField = new PepTextboxField({\n key: this.key,\n value: this.value,\n mandatory: this.mandatory,\n readonly: this.readonly,\n disabled: this.disabled,\n maxFieldCharacters: this.maxFieldCharacters,\n type: this.type,\n minValue: this.minValue,\n maxValue: this.maxValue,\n regex: this.regex\n });\n this.form = this.customizationService.getDefaultFromGroup(\n pepField,\n this.renderError\n ); \n }\n\n ngOnInit(): void {\n if (this.form === null) {\n this.standAlone = true;\n\n this.minValue =\n isNaN(this.minValue) && !isNaN(this.maxValue)\n ? 0\n : this.minValue;\n this.maxValue =\n isNaN(this.maxValue) && !isNaN(this.minValue)\n ? 99999\n : this.maxValue;\n\n this.setDefaultForm();\n\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_CLASS_NAME\n );\n\n if (!this.renderTitle) {\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_NO_SPACING_CLASS_NAME\n );\n }\n }\n //flag to indicate whether validation on dirty is required \n this.form.addControl('validateOnDirty', new FormControl(this.type === 'text'));\n\n this.readonly = this.type === 'duration' ? true : this.readonly; // Hack until we develop Timer UI for editing Duration field\n\n //load default error text\n if (this.type === 'text' && this.regex && !this.regexError) {\n this.translate.get('MESSAGES.ERROR_INVALID_PATTERN').subscribe(text => this.regexError = text);\n }\n\n this.updateFormFieldValue();\n }\n\n ngOnChanges(changes: any): void {\n if (this.standAlone) {\n this.setDefaultForm();\n }\n\n this.readonly = this.type === 'duration' ? true : this.readonly; // Hack until we develop Timer UI for editing Duration field\n }\n\n ngOnDestroy(): void {\n //\n }\n\n onFocus(event: any): void {\n this.isInFocus = true;\n\n // select the value in focus (DI-18246 improvement)\n setTimeout(() => {\n const eventTarget = event.target || event.srcElement;\n if (eventTarget) {\n eventTarget.select();\n }\n }, 0);\n }\n\n isDecimal(): boolean {\n let res = false;\n\n if (this.isNumberType()) {\n if (this.type === 'currency' || this.type === 'real') {\n res = true;\n }\n }\n\n return res;\n }\n\n isNumberType(): boolean {\n return (\n this.type === 'percentage' ||\n this.type === 'int' ||\n this.type === 'currency' ||\n this.type === 'real'\n );\n }\n\n isValueValid(value: string): boolean {\n let res = false;\n\n if (this.isNumberType()) {\n if (value === '') {\n res = this.mandatory ? false : true;\n } else {\n const numberValue = this.utilitiesService.coerceNumberProperty(\n value\n );\n res =\n numberValue >= this.minValue &&\n numberValue <= this.maxValue;\n }\n } else {\n // TODO: Maybe need to check other types.\n res = true;\n }\n\n return res;\n }\n\n isDifferentValue(value: string): boolean {\n let res = false;\n\n if (this.isNumberType()) {\n if (this.value === '' || value === '') {\n res = true;\n } else {\n const currentValue = this.utilitiesService.coerceNumberProperty(\n this.value\n );\n const newValue = this.utilitiesService.coerceNumberProperty(\n value\n );\n\n res = currentValue !== newValue;\n }\n } else {\n res = true;\n }\n\n return res;\n }\n\n onChange(e: any): void {\n const value = e.target ? e.target.value : e;\n\n this.valueChange.emit(value);\n }\n\n onBlur(e: any): void {\n this.isInFocus = false;\n const value = e.target ? e.target.value : e;\n if (value !== this.value && this.isDifferentValue(value)) {\n // If renderError is false and the new value is not valid.\n if (!this.renderError && !this.isValueValid(value)) {\n this.renderer.setProperty(\n this.input.nativeElement,\n 'value',\n this.value\n );\n } else {\n this.value = value;\n\n // // If the user is setting the formatted value then set the value till the user format it and return it back.\n // if (!this._calculateFormattedValue) {\n // this._formattedValue = value;\n // }\n\n this.valueChange.emit(value);\n }\n }\n\n if (this.isInEditMode) {\n this.isInEditMode = false;\n }\n }\n\n anchorClicked(): void {\n const currentValue = this.value;\n if (currentValue.trim().length > 0) {\n switch (this.type) {\n case 'email':\n window.open('mailto:' + currentValue, 'email');\n break;\n case 'phone':\n window.open('tel:' + currentValue, 'tel');\n break;\n case 'link':\n window.open(currentValue);\n break;\n default:\n break;\n }\n }\n }\n\n cardTemplateClicked(event: any): void {\n this.isInEditMode = true;\n\n setTimeout(() => {\n this.input.nativeElement.focus();\n }, 0);\n }\n}\n","import {\n Directive,\n ElementRef,\n HostListener,\n Input,\n OnInit,\n} from '@angular/core';\nimport {\n PepTextboxFieldType,\n PepValidatorService,\n} from '@pepperi-addons/ngx-lib';\n\n@Directive({\n selector: '[pepTextboxValidation]',\n})\nexport class PepTextboxValidationDirective implements OnInit {\n @Input() type: PepTextboxFieldType = 'text';\n\n previousValue = '';\n\n constructor(\n private hostElement: ElementRef,\n private validatorService: PepValidatorService\n ) {}\n\n ngOnInit() {\n //\n }\n\n private isNumber(): boolean {\n return this.isInteger() || this.isDecimal();\n }\n\n private isInteger(): boolean {\n return this.type === 'int';\n }\n\n private isDecimal(): boolean {\n return (\n this.type === 'currency' ||\n this.type === 'percentage' ||\n this.type === 'real'\n );\n }\n\n private isPhone(): boolean {\n return this.type === 'phone';\n }\n\n private isText(): boolean {\n return (\n this.type === 'email' ||\n this.type === 'link' ||\n this.type === 'text'\n );\n }\n\n @HostListener('change', ['$event'])\n onChange(e) {\n this.validateValue(this.hostElement.nativeElement.value);\n }\n\n @HostListener('keydown', ['$event'])\n onKeyDown(e: KeyboardEvent) {\n const originalValue: string = e.target['value'];\n\n if (this.isNumber()) {\n // save value before keydown event\n this.previousValue = originalValue;\n const isNumber = this.validatorService.isNumber(\n e,\n this.isDecimal()\n );\n\n if (isNumber) return;\n else e.preventDefault();\n } else if (this.isPhone()) {\n const isPhone = this.validatorService.isPhone(e);\n if (isPhone) return;\n else e.preventDefault();\n }\n }\n\n validateValue(value: string): void {\n if (this.isNumber()) {\n const newValue = this.validatorService.validateNumber(\n value,\n this.isDecimal()\n );\n this.hostElement.nativeElement['value'] = newValue ? newValue : 0;\n } else if (this.isPhone()) {\n // test phone with regular expression, when\n // phone is invalid, replace it with the previousValue\n const valid = this.validatorService.validatePhone(value);\n this.hostElement.nativeElement['value'] = valid\n ? value\n : this.previousValue;\n } else if (this.isText()) {\n this.hostElement.nativeElement['value'] = value;\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ReactiveFormsModule } from '@angular/forms';\n\nimport { MatCommonModule } from '@angular/material/core';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatInputModule } from '@angular/material/input';\nimport { MatIconModule } from '@angular/material/icon';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport {\n PepIconModule,\n PepIconRegistry,\n pepIconSystemEdit,\n} from '@pepperi-addons/ngx-lib/icon';\nimport { PepTextboxIconModule } from '@pepperi-addons/ngx-lib/textbox-icon';\nimport { PepFieldTitleModule } from '@pepperi-addons/ngx-lib/field-title';\n\nimport { PepTextboxComponent } from './textbox.component';\nimport { PepTextboxValidationDirective } from './textbox-validation.directive';\n\n@NgModule({\n imports: [\n CommonModule,\n ReactiveFormsModule,\n // Material modules,\n MatCommonModule,\n MatButtonModule,\n MatFormFieldModule,\n MatInputModule,\n MatIconModule,\n // ngx-lib modules\n PepNgxLibModule,\n PepIconModule,\n PepFieldTitleModule,\n PepTextboxIconModule,\n ],\n exports: [PepTextboxComponent],\n declarations: [PepTextboxComponent, PepTextboxValidationDirective],\n})\nexport class PepTextboxModule {\n constructor(private pepIconRegistry: PepIconRegistry) {\n this.pepIconRegistry.registerIcons([pepIconSystemEdit]);\n }\n}\n","/*\n * Public API Surface of ngx-lib/textbox\n */\nexport * from './textbox.module';\nexport * from './textbox.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {PepTextboxValidationDirective as ɵa} from './textbox-validation.directive';"],"names":["DEFAULT_HORIZONTAL_ALIGNMENT","EventEmitter","PepTextboxField","PepCustomizationService","FormControl","Component","ChangeDetectionStrategy","FormBuilder","Renderer2","ElementRef","TranslateService","PepUtilitiesService","HostBinding","Input","Output","ViewChild","Directive","PepValidatorService","HostListener","pepIconSystemEdit","NgModule","CommonModule","ReactiveFormsModule","MatCommonModule","MatButtonModule","MatFormFieldModule","MatInputModule","MatIconModule","PepNgxLibModule","PepIconModule","PepFieldTitleModule","PepTextboxIconModule","PepIconRegistry"],"mappings":";;;;;;IA8BA;;QACA;SAKC;QAJG,4CAAY,GAAZ,UAAa,OAA2B,EAAE,IAAwC;;YAC9E,IAAM,eAAe,GAAG,MAAA,MAAA,MAAA,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,IAAI,0CAAE,QAAQ,0CAAG,iBAAiB,CAAC,0CAAE,KAAK,CAAC;YACzE,OAAO,CAAC,EAAE,eAAe,IAAI,OAAO,IAAI,OAAO,CAAC,OAAO,KAAK,OAAO,CAAC,KAAK,IAAI,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC;SAClG;oCACJ;KAAA,IAAA;IAED;;;;;;;;;;QAgOI,6BACW,EAAe,EACd,oBAA6C,EAC7C,QAAmB,EACnB,OAAmB,EACnB,SAA2B,EAC3B,gBAAqC;YALtC,OAAE,GAAF,EAAE,CAAa;YACd,yBAAoB,GAApB,oBAAoB,CAAyB;YAC7C,aAAQ,GAAR,QAAQ,CAAW;YACnB,YAAO,GAAP,OAAO,CAAY;YACnB,cAAS,GAAT,SAAS,CAAkB;YAC3B,qBAAgB,GAAhB,gBAAgB,CAAqB;YArNpB,WAAM,GAAG,EAAE,CAAC;YAEjC,SAAI,GAAG,EAAE,CAAC;YAeV,WAAM,GAAG,EAAE,CAAC;YAmBZ,oBAAe,GAAG,EAAE,CAAC;YAuBrB,uBAAkB,GAAW,GAAG,CAAC;YAUjC,uBAAkB,GAAW,GAAG,CAAC;;;;;;YAehC,cAAS,GAAG,EAAE,CAAC;;;;;;YAOf,UAAK,GAAG,EAAE,CAAC;;;;;;YAOX,gBAAW,GAAG,EAAE,CAAC;;;;;;;YAQlB,UAAK,GAAwB,MAAM,CAAC;;;;;;YAkBnC,cAAS,GAAG,KAAK,CAAC;;;;;;;YAQlB,aAAQ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EAAE,CAAC,mBAAmB,EAAE,6BAA6B,CAAC;iBACrE;;;gBA3BGC,oBAAe;;;ICbnB;;;;ICAA;;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"pepperi-addons-ngx-lib-textbox.umd.js","sources":["../../../projects/ngx-lib/textbox/textbox.component.ts","../../../projects/ngx-lib/textbox/textbox-validation.directive.ts","../../../projects/ngx-lib/textbox/textbox.module.ts","../../../projects/ngx-lib/textbox/public-api.ts","../../../projects/ngx-lib/textbox/pepperi-addons-ngx-lib-textbox.ts"],"sourcesContent":["import {\n Component,\n OnInit,\n OnChanges,\n Input,\n Output,\n EventEmitter,\n ChangeDetectionStrategy,\n ElementRef,\n ViewChild,\n Renderer2,\n OnDestroy,\n ChangeDetectorRef,\n HostBinding,\n} from '@angular/core';\nimport { FormGroup, FormBuilder } from '@angular/forms';\nimport { TranslateService } from '@ngx-translate/core';\nimport {\n PepLayoutType,\n PepCustomizationService,\n PepHorizontalAlignment,\n DEFAULT_HORIZONTAL_ALIGNMENT,\n PepTextboxFieldType,\n PepTextboxField,\n PepFieldBase,\n PepUtilitiesService,\n} from '@pepperi-addons/ngx-lib';\nimport { FormControl, FormGroupDirective, NgForm, Validators } from '@angular/forms';\nimport { ErrorStateMatcher } from '@angular/material/core';\n\n/** error when invalid control is dirty or touched */\nexport class TextErrorStateMatcher implements ErrorStateMatcher {\n isErrorState(control: FormControl | null, form: FormGroupDirective | NgForm | null): boolean {\n const validateOnDirty = form?.form?.controls?.['validateOnDirty']?.value;\n return !!(validateOnDirty && control && control.invalid && (control.dirty || control.touched));\n }\n}\n\n/**\n * This is a text box input component that can be use to\n *\n * @export\n * @class PepTextboxComponent\n * @implements {OnChanges}\n * @implements {OnInit}\n * @implements {OnDestroy}\n */\n@Component({\n selector: 'pep-textbox',\n templateUrl: './textbox.component.html',\n styleUrls: ['./textbox.component.scss', './textbox.component.theme.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class PepTextboxComponent implements OnChanges, OnInit, OnDestroy {\n\n @HostBinding('attr.data-qa') dataQa = '';\n\n private _key = '';\n /**\n * The text box key\n *\n * @memberof PepTextboxComponent\n */\n @Input()\n set key(value) {\n this._key = value;\n this.dataQa = value;\n }\n get key(): string {\n return this._key;\n }\n\n private _value = '';\n /**\n * The value of the text box.\n *\n * @memberof PepTextboxComponent\n */\n @Input()\n set value(value: string) {\n if (!value) {\n value = '';\n }\n\n this._value = value;\n this.setFormattedValue(value);\n }\n get value(): string {\n return this._value;\n }\n\n private _formattedValue = '';\n /**\n * The formatted value.\n *\n * @memberof PepTextboxComponent\n */\n @Input()\n set formattedValue(value: string) {\n // Do nothing.\n // if (!value) {\n // value = '';\n // }\n\n // if (this._calculateFormattedValue) {\n // this._calculateFormattedValue = false;\n // }\n\n // this.setFormattedValue(value);\n }\n get formattedValue(): string {\n return this._formattedValue;\n }\n\n private _minFractionDigits: number = NaN;\n @Input()\n set minFractionDigits(value: number) {\n this._minFractionDigits = value;\n this.setFormattedValue(this.value);\n }\n get minFractionDigits(): number {\n return this._minFractionDigits;\n }\n\n private _maxFractionDigits: number = NaN;\n @Input()\n set maxFractionDigits(value: number) {\n this._maxFractionDigits = value;\n this.setFormattedValue(this.value);\n }\n get maxFractionDigits(): number {\n return this._maxFractionDigits;\n }\n\n /**\n * The accessory sign.\n *\n * @memberof PepTextboxComponent\n */\n @Input() accessory = '';\n\n /**\n * The title of the textbox.\n *\n * @memberof PepTextboxComponent\n */\n @Input() label = '';\n\n /**\n * The placeholder (relevant only for children - if parent isn't null).\n *\n * @memberof PepTextboxComponent\n */\n @Input() placeholder = '';\n\n /**\n * The type of the textbox.\n *\n * @type {PepTextboxFieldType}\n * @memberof PepTextboxComponent\n */\n private _type: PepTextboxFieldType = 'text';\n @Input()\n set type(value: PepTextboxFieldType) {\n this._type = value;\n\n if (this.value) {\n this.setFormattedValue(this.value);\n }\n }\n get type(): PepTextboxFieldType {\n return this._type;\n }\n\n /**\n * If the textbox is mandatory\n *\n * @memberof PepTextboxComponent\n */\n @Input() mandatory = false;\n\n // TODO: Check if should remove disabled and keep only readonly.\n /**\n * If the textbox is disabled.\n *\n * @memberof PepTextboxComponent\n */\n @Input() disabled = false;\n\n /**\n * If the textbox is readonly\n *\n * @memberof PepTextboxComponent\n */\n @Input() readonly = false;\n @Input() maxFieldCharacters: number;\n @Input() hint: string;\n @Input() textColor = '';\n @Input() xAlignment: PepHorizontalAlignment = DEFAULT_HORIZONTAL_ALIGNMENT;\n @Input() rowSpan = 1;\n // @Input() lastFocusField: any;\n @Input() minValue = NaN;\n @Input() maxValue = NaN;\n\n private _visible = true;\n @Input()\n set visible(visible: boolean) {\n this._visible = visible;\n if (visible) {\n this.renderer.removeClass(\n this.element.nativeElement,\n 'hidden-element'\n );\n } else {\n this.renderer.addClass(\n this.element.nativeElement,\n 'hidden-element'\n );\n }\n }\n get visible(): boolean {\n return this._visible;\n }\n\n @Input() form: FormGroup = null;\n @Input() isActive = false;\n @Input() showTitle = true;\n @Input() renderTitle = true;\n @Input() renderError = true;\n @Input() renderSymbol = true;\n @Input() layoutType: PepLayoutType = 'form';\n @Input() parentFieldKey: string = null;\n @Input() regex: string | RegExp;\n @Input() regexError = '';\n\n /**\n * The value change event.\n *\n * @type {EventEmitter<string>}\n * @memberof PepTextboxComponent\n */\n @Output()\n valueChange: EventEmitter<string> = new EventEmitter<string>();\n\n @Output()\n formValidationChange: EventEmitter<boolean> = new EventEmitter<boolean>();\n\n @ViewChild('input') input: ElementRef;\n\n private _calculateFormattedValue = true;\n get calculateFormattedValue(): boolean {\n return this._calculateFormattedValue;\n }\n\n controlType = 'textbox';\n\n standAlone = false;\n isInEditMode = false;\n isInFocus: boolean;\n\n matcher = new TextErrorStateMatcher();\n\n constructor(\n public fb: FormBuilder,\n private customizationService: PepCustomizationService,\n private renderer: Renderer2,\n private element: ElementRef,\n private translate: TranslateService,\n private utilitiesService: PepUtilitiesService\n ) {\n this.isInFocus = false;\n }\n\n private setFormattedValue(value: string) {\n if (this._calculateFormattedValue) {\n if (this.type === 'currency') {\n this._formattedValue = this.utilitiesService.formatCurrency(value, this.accessory, this.minFractionDigits, this.maxFractionDigits);\n } else if (this.type === 'percentage') {\n this._formattedValue = this.utilitiesService.formatPercent(value, this.minFractionDigits, this.maxFractionDigits);\n } else if (this.type === 'real') {\n this._formattedValue = this.utilitiesService.formatDecimal(value, this.minFractionDigits, this.maxFractionDigits);\n } else if (this.type === 'int') {\n this._formattedValue = this.utilitiesService.formatNumber(value);\n } else if (this.type === 'duration') {\n this._formattedValue = this.utilitiesService.formatDuration(value, { duration: 'seconds' });\n } else {\n this._formattedValue = value;\n }\n } else {\n this._formattedValue = value;\n }\n\n this.updateFormFieldValue();\n }\n\n private updateFormFieldValue() {\n this.customizationService.updateFormFieldValue(\n this.form,\n this.key,\n this.formattedValue,\n this.parentFieldKey\n );\n }\n\n get displayValue(): string {\n let res = '';\n\n if (this.type == 'link') {\n res = this.formattedValue;\n } else if (this.isNumberType()) {\n res = this.isInFocus ? (this.value.length > 0 ? this.utilitiesService.formatDecimal(this.value, this.minFractionDigits, this.maxFractionDigits) : '') : this.formattedValue;\n } else {\n res = this.isInFocus ? this.value : this.formattedValue;\n }\n\n return res;\n }\n\n private setDefaultForm(): void {\n const pepField = new PepTextboxField({\n key: this.key,\n value: this.value,\n mandatory: this.mandatory,\n readonly: this.readonly,\n disabled: this.disabled,\n maxFieldCharacters: this.maxFieldCharacters,\n type: this.type,\n minValue: this.minValue,\n maxValue: this.maxValue,\n regex: this.regex\n }); \n this.form = this.customizationService.getDefaultFromGroup(\n pepField,\n this.renderError\n ); \n }\n\n ngOnInit(): void {\n if (this.form === null) {\n this.standAlone = true;\n\n this.minValue =\n isNaN(this.minValue) && !isNaN(this.maxValue)\n ? 0\n : this.minValue;\n this.maxValue =\n isNaN(this.maxValue) && !isNaN(this.minValue)\n ? 99999\n : this.maxValue;\n\n this.setDefaultForm();\n\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_CLASS_NAME\n );\n\n if (!this.renderTitle) {\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_NO_SPACING_CLASS_NAME\n );\n }\n }\n //flag to indicate whether validation on dirty is required \n this.form.addControl('validateOnDirty', new FormControl(this.type === 'text' || this.type === 'duration'));\n\n this.readonly = this.type === 'duration' ? true : this.readonly; // Hack until we develop Timer UI for editing Duration field\n\n //load default error text\n if ((this.type === 'text' || this.type === 'duration') && this.regex && !this.regexError) {\n this.translate.get('MESSAGES.ERROR_INVALID_PATTERN').subscribe(text => this.regexError = text);\n }\n\n this.updateFormFieldValue();\n }\n\n ngOnChanges(changes: any): void { \n if (this.standAlone) {\n this.setDefaultForm();\n }\n\n this.readonly = this.type === 'duration' ? true : this.readonly; // Hack until we develop Timer UI for editing Duration field\n }\n\n ngOnDestroy(): void {\n //\n }\n\n onFocus(event: any): void {\n this.isInFocus = true;\n\n // select the value in focus (DI-18246 improvement)\n setTimeout(() => {\n const eventTarget = event.target || event.srcElement;\n if (eventTarget) {\n eventTarget.select();\n }\n }, 0);\n }\n\n isDecimal(): boolean {\n let res = false;\n\n if (this.isNumberType()) {\n if (this.type === 'currency' || this.type === 'real') {\n res = true;\n }\n }\n\n return res;\n }\n\n isNumberType(): boolean {\n return (\n this.type === 'percentage' ||\n this.type === 'int' ||\n this.type === 'currency' ||\n this.type === 'real'\n );\n }\n\n isValueValid(value: string): boolean {\n let res = false;\n\n if (this.isNumberType()) {\n if (value === '') {\n res = this.mandatory ? false : true;\n } else {\n const numberValue = this.utilitiesService.coerceNumberProperty(\n value\n );\n res =\n numberValue >= this.minValue &&\n numberValue <= this.maxValue;\n }\n } else {\n // TODO: Maybe need to check other types.\n res = true;\n }\n\n return res;\n }\n\n isDifferentValue(value: string): boolean {\n let res = false;\n\n if (this.isNumberType()) {\n if (this.value === '' || value === '') {\n res = true;\n } else {\n const currentValue = this.utilitiesService.coerceNumberProperty(\n this.value\n );\n const newValue = this.utilitiesService.coerceNumberProperty(\n value\n );\n\n res = currentValue !== newValue;\n }\n } else {\n res = true;\n }\n\n return res;\n }\n\n onChange(e: any): void {\n const value = e.target ? e.target.value : e;\n\n this.valueChange.emit(value);\n }\n\n onBlur(e: any): void {\n this.isInFocus = false;\n const value = e.target ? e.target.value : e;\n if (value !== this.value && this.isDifferentValue(value)) {\n // If renderError is false and the new value is not valid.\n if (!this.renderError && !this.isValueValid(value)) {\n this.renderer.setProperty(\n this.input.nativeElement,\n 'value',\n this.value\n );\n } else {\n this.value = value;\n\n // // If the user is setting the formatted value then set the value till the user format it and return it back.\n // if (!this._calculateFormattedValue) {\n // this._formattedValue = value;\n // }\n\n this.valueChange.emit(value);\n }\n }\n\n if (this.isInEditMode) {\n this.isInEditMode = false;\n }\n }\n\n anchorClicked(): void {\n const currentValue = this.value;\n if (currentValue.trim().length > 0) {\n switch (this.type) {\n case 'email':\n window.open('mailto:' + currentValue, 'email');\n break;\n case 'phone':\n window.open('tel:' + currentValue, 'tel');\n break;\n case 'link':\n window.open(currentValue);\n break;\n default:\n break;\n }\n }\n }\n\n cardTemplateClicked(event: any): void {\n this.isInEditMode = true;\n\n setTimeout(() => {\n this.input.nativeElement.focus();\n }, 0);\n }\n}\n","import {\n Directive,\n ElementRef,\n HostListener,\n Input,\n OnInit,\n} from '@angular/core';\nimport {\n PepTextboxFieldType,\n PepValidatorService,\n} from '@pepperi-addons/ngx-lib';\n\n@Directive({\n selector: '[pepTextboxValidation]',\n})\nexport class PepTextboxValidationDirective implements OnInit {\n @Input() type: PepTextboxFieldType = 'text';\n\n previousValue = '';\n\n constructor(\n private hostElement: ElementRef,\n private validatorService: PepValidatorService\n ) {}\n\n ngOnInit() {\n //\n }\n\n private isNumber(): boolean {\n return this.isInteger() || this.isDecimal();\n }\n\n private isInteger(): boolean {\n return this.type === 'int';\n }\n\n private isDecimal(): boolean {\n return (\n this.type === 'currency' ||\n this.type === 'percentage' ||\n this.type === 'real'\n );\n }\n\n private isPhone(): boolean {\n return this.type === 'phone';\n }\n\n private isText(): boolean {\n return (\n this.type === 'email' ||\n this.type === 'link' ||\n this.type === 'text'\n );\n }\n\n @HostListener('change', ['$event'])\n onChange(e) {\n this.validateValue(this.hostElement.nativeElement.value);\n }\n\n @HostListener('keydown', ['$event'])\n onKeyDown(e: KeyboardEvent) {\n const originalValue: string = e.target['value'];\n\n if (this.isNumber()) {\n // save value before keydown event\n this.previousValue = originalValue;\n const isNumber = this.validatorService.isNumber(\n e,\n this.isDecimal()\n );\n\n if (isNumber) return;\n else e.preventDefault();\n } else if (this.isPhone()) {\n const isPhone = this.validatorService.isPhone(e);\n if (isPhone) return;\n else e.preventDefault();\n }\n }\n\n validateValue(value: string): void {\n if (this.isNumber()) {\n const newValue = this.validatorService.validateNumber(\n value,\n this.isDecimal()\n );\n this.hostElement.nativeElement['value'] = newValue ? newValue : 0;\n } else if (this.isPhone()) {\n // test phone with regular expression, when\n // phone is invalid, replace it with the previousValue\n const valid = this.validatorService.validatePhone(value);\n this.hostElement.nativeElement['value'] = valid\n ? value\n : this.previousValue;\n } else if (this.isText()) {\n this.hostElement.nativeElement['value'] = value;\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ReactiveFormsModule } from '@angular/forms';\n\nimport { MatCommonModule } from '@angular/material/core';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatInputModule } from '@angular/material/input';\nimport { MatIconModule } from '@angular/material/icon';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport {\n PepIconModule,\n PepIconRegistry,\n pepIconSystemEdit,\n} from '@pepperi-addons/ngx-lib/icon';\nimport { PepTextboxIconModule } from '@pepperi-addons/ngx-lib/textbox-icon';\nimport { PepFieldTitleModule } from '@pepperi-addons/ngx-lib/field-title';\n\nimport { PepTextboxComponent } from './textbox.component';\nimport { PepTextboxValidationDirective } from './textbox-validation.directive';\n\n@NgModule({\n imports: [\n CommonModule,\n ReactiveFormsModule,\n // Material modules,\n MatCommonModule,\n MatButtonModule,\n MatFormFieldModule,\n MatInputModule,\n MatIconModule,\n // ngx-lib modules\n PepNgxLibModule,\n PepIconModule,\n PepFieldTitleModule,\n PepTextboxIconModule,\n ],\n exports: [PepTextboxComponent],\n declarations: [PepTextboxComponent, PepTextboxValidationDirective],\n})\nexport class PepTextboxModule {\n constructor(private pepIconRegistry: PepIconRegistry) {\n this.pepIconRegistry.registerIcons([pepIconSystemEdit]);\n }\n}\n","/*\n * Public API Surface of ngx-lib/textbox\n */\nexport * from './textbox.module';\nexport * from './textbox.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {PepTextboxValidationDirective as ɵa} from './textbox-validation.directive';"],"names":["DEFAULT_HORIZONTAL_ALIGNMENT","EventEmitter","PepTextboxField","PepCustomizationService","FormControl","Component","ChangeDetectionStrategy","FormBuilder","Renderer2","ElementRef","TranslateService","PepUtilitiesService","HostBinding","Input","Output","ViewChild","Directive","PepValidatorService","HostListener","pepIconSystemEdit","NgModule","CommonModule","ReactiveFormsModule","MatCommonModule","MatButtonModule","MatFormFieldModule","MatInputModule","MatIconModule","PepNgxLibModule","PepIconModule","PepFieldTitleModule","PepTextboxIconModule","PepIconRegistry"],"mappings":";;;;;;IA8BA;;QACA;SAKC;QAJG,4CAAY,GAAZ,UAAa,OAA2B,EAAE,IAAwC;;YAC9E,IAAM,eAAe,GAAG,MAAA,MAAA,MAAA,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,IAAI,0CAAE,QAAQ,0CAAG,iBAAiB,CAAC,0CAAE,KAAK,CAAC;YACzE,OAAO,CAAC,EAAE,eAAe,IAAI,OAAO,IAAI,OAAO,CAAC,OAAO,KAAK,OAAO,CAAC,KAAK,IAAI,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC;SAClG;oCACJ;KAAA,IAAA;IAED;;;;;;;;;;QAgOI,6BACW,EAAe,EACd,oBAA6C,EAC7C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;gBACtB,IAAI,CAAC,WAAW,CAAC,aAAa,CAAC,OAAO,CAAC,GAAG,KAAK,CAAC;aACnD;SACJ;;;;gBAxFJC,cAAS,SAAC;oBACP,QAAQ,EAAE,wBAAwB;iBACrC;;;gBAZGP,eAAU;gBAOVQ,0BAAmB;;;uBAOlBJ,UAAK;2BAyCLK,iBAAY,SAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC;4BAKjCA,iBAAY,SAAC,SAAS,EAAE,CAAC,QAAQ,CAAC;;;;QCpBnC,0BAAoB,eAAgC;YAAhC,oBAAe,GAAf,eAAe,CAAiB;YAChD,IAAI,CAAC,eAAe,CAAC,aAAa,CAAC,CAACC,sBAAiB,CAAC,CAAC,CAAC;SAC3D;;;;gBAtBJC,aAAQ,SAAC;oBACN,OAAO,EAAE;wBACLC,mBAAY;wBACZC,yBAAmB;;wBAEnBC,sBAAe;wBACfC,sBAAe;wBACfC,4BAAkB;wBAClBC,oBAAc;wBACdC,oBAAa;;wBAEbC,sBAAe;wBACfC,kBAAa;wBACbC,8BAAmB;wBACnBC,gCAAoB;qBACvB;oBACD,OAAO,EAAE,CAAC,mBAAmB,CAAC;oBAC9B,YAAY,EAAE,CAAC,mBAAmB,EAAE,6BAA6B,CAAC;iBACrE;;;gBA3BGC,oBAAe;;;ICbnB;;;;ICAA;;;;;;;;;;;;;;;"}
|
|
@@ -3909,7 +3909,7 @@
|
|
|
3909
3909
|
validators.push(i3$1.Validators.max(this.maxValue));
|
|
3910
3910
|
}
|
|
3911
3911
|
}
|
|
3912
|
-
if (this.type === 'text' && this.regex) {
|
|
3912
|
+
if ((this.type === 'text' || this.type === 'duration') && this.regex) {
|
|
3913
3913
|
validators.push(i3$1.Validators.pattern(this.regex));
|
|
3914
3914
|
}
|
|
3915
3915
|
return validators;
|