@kris701/ez-ui 1.2.7 → 1.2.9
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.
|
@@ -2957,7 +2957,9 @@ class EzUIMultiSelect {
|
|
|
2957
2957
|
disabled = false;
|
|
2958
2958
|
selected = undefined;
|
|
2959
2959
|
selectedChange = new EventEmitter();
|
|
2960
|
-
appearanceMap = {
|
|
2960
|
+
appearanceMap = {
|
|
2961
|
+
"b": "negative"
|
|
2962
|
+
};
|
|
2961
2963
|
ngOnChanges(changes) {
|
|
2962
2964
|
if (changes['selected'] && changes['selected'].currentValue != changes['selected'].previousValue) {
|
|
2963
2965
|
this.selected = changes['selected'].currentValue;
|
|
@@ -2987,13 +2989,13 @@ class EzUIMultiSelect {
|
|
|
2987
2989
|
<input tuiInputChip tuiSelectLike [(ngModel)]="selected" (ngModelChange)="selectedChange.emit(this.selected)" [disabled]="disabled"/>
|
|
2988
2990
|
<tui-input-chip
|
|
2989
2991
|
*tuiItem="let context"
|
|
2990
|
-
[appearance]="appearanceMap[
|
|
2992
|
+
[appearance]="appearanceMap[context.item] ? appearanceMap[context.item] : 'neutral'"/>
|
|
2991
2993
|
<tui-data-list *tuiDropdown tuiMultiSelectGroup >
|
|
2992
2994
|
@for (item of options; track getOptionValue(item)) {
|
|
2993
2995
|
@let value = getOptionValue(item);
|
|
2994
2996
|
@let label = getOptionLabel(item);
|
|
2995
2997
|
<button tuiOption [value]="value" >
|
|
2996
|
-
<span tuiChip size="xs" [appearance]="appearanceMap[value]">{{label}}</span>
|
|
2998
|
+
<span tuiChip size="xs" [appearance]="appearanceMap[value] ? appearanceMap[value] : 'neutral'">{{label}}</span>
|
|
2997
2999
|
</button>
|
|
2998
3000
|
}
|
|
2999
3001
|
</tui-data-list>
|
|
@@ -3023,13 +3025,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
3023
3025
|
<input tuiInputChip tuiSelectLike [(ngModel)]="selected" (ngModelChange)="selectedChange.emit(this.selected)" [disabled]="disabled"/>
|
|
3024
3026
|
<tui-input-chip
|
|
3025
3027
|
*tuiItem="let context"
|
|
3026
|
-
[appearance]="appearanceMap[
|
|
3028
|
+
[appearance]="appearanceMap[context.item] ? appearanceMap[context.item] : 'neutral'"/>
|
|
3027
3029
|
<tui-data-list *tuiDropdown tuiMultiSelectGroup >
|
|
3028
3030
|
@for (item of options; track getOptionValue(item)) {
|
|
3029
3031
|
@let value = getOptionValue(item);
|
|
3030
3032
|
@let label = getOptionLabel(item);
|
|
3031
3033
|
<button tuiOption [value]="value" >
|
|
3032
|
-
<span tuiChip size="xs" [appearance]="appearanceMap[value]">{{label}}</span>
|
|
3034
|
+
<span tuiChip size="xs" [appearance]="appearanceMap[value] ? appearanceMap[value] : 'neutral'">{{label}}</span>
|
|
3033
3035
|
</button>
|
|
3034
3036
|
}
|
|
3035
3037
|
</tui-data-list>
|
|
@@ -3201,7 +3203,7 @@ class EzUISelect {
|
|
|
3201
3203
|
}
|
|
3202
3204
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: EzUISelect, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
3203
3205
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: EzUISelect, isStandalone: true, selector: "ezui-select", inputs: { icon: "icon", label: "label", size: "size", optionLabel: "optionLabel", optionValue: "optionValue", options: "options", disabled: "disabled", selected: "selected", appearanceMap: "appearanceMap" }, outputs: { selectedChange: "selectedChange" }, usesOnChanges: true, ngImport: i0, template: `
|
|
3204
|
-
<tui-textfield tuiChevron [content]="
|
|
3206
|
+
<tui-textfield tuiChevron [content]="content" [tuiTextfieldSize]="size" [iconStart]="icon">
|
|
3205
3207
|
@if(label != ''){
|
|
3206
3208
|
<label tuiLabel>{{label}}</label>
|
|
3207
3209
|
}
|
|
@@ -3218,7 +3220,7 @@ class EzUISelect {
|
|
|
3218
3220
|
</tui-textfield>
|
|
3219
3221
|
|
|
3220
3222
|
<ng-template #content>
|
|
3221
|
-
<span tuiChip [size]="
|
|
3223
|
+
<span tuiChip [size]="label != '' ? 'xxs' : 'xs'" [appearance]="appearanceMap[selected]">{{stringify(selected)}}</span>
|
|
3222
3224
|
</ng-template>
|
|
3223
3225
|
`, isInline: true, styles: [""], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox]):not([ngNoCva])[formControlName],textarea:not([ngNoCva])[formControlName],input:not([type=checkbox]):not([ngNoCva])[formControl],textarea:not([ngNoCva])[formControl],input:not([type=checkbox]):not([ngNoCva])[ngModel],textarea:not([ngNoCva])[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i4$1.TuiSelectDirective, selector: "input[tuiSelect]" }, { kind: "directive", type: i2.TuiLabel, selector: "label[tuiLabel]" }, { kind: "component", type: i3.TuiTextfieldComponent, selector: "tui-textfield:not([multi])", inputs: ["content", "filler"] }, { kind: "directive", type: i3.TuiTextfieldOptionsDirective, selector: "[tuiTextfieldAppearance],[tuiTextfieldSize],[tuiTextfieldCleaner]", inputs: ["tuiTextfieldAppearance", "tuiTextfieldSize", "tuiTextfieldCleaner"] }, { kind: "directive", type: i4.TuiDropdownContent, selector: "ng-template[tuiDropdown]" }, { kind: "component", type: i3$1.TuiDataListComponent, selector: "tui-data-list", inputs: ["emptyContent", "size"] }, { kind: "directive", type: i3$1.TuiOption, selector: "button[tuiOption], a[tuiOption], label[tuiOption]", inputs: ["disabled"] }, { kind: "directive", type: i3$1.TuiOptionWithValue, selector: "button[tuiOption][value], a[tuiOption][value], label[tuiOption][value]", inputs: ["disabled", "value"] }, { kind: "directive", type: TuiChevron, selector: "[tuiChevron]", inputs: ["tuiChevron"] }, { kind: "directive", type: TuiChip, selector: "[tuiChip]", inputs: ["size"] }] });
|
|
3224
3226
|
}
|
|
@@ -3235,7 +3237,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
3235
3237
|
TuiInput,
|
|
3236
3238
|
TuiChip
|
|
3237
3239
|
], template: `
|
|
3238
|
-
<tui-textfield tuiChevron [content]="
|
|
3240
|
+
<tui-textfield tuiChevron [content]="content" [tuiTextfieldSize]="size" [iconStart]="icon">
|
|
3239
3241
|
@if(label != ''){
|
|
3240
3242
|
<label tuiLabel>{{label}}</label>
|
|
3241
3243
|
}
|
|
@@ -3252,7 +3254,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
3252
3254
|
</tui-textfield>
|
|
3253
3255
|
|
|
3254
3256
|
<ng-template #content>
|
|
3255
|
-
<span tuiChip [size]="
|
|
3257
|
+
<span tuiChip [size]="label != '' ? 'xxs' : 'xs'" [appearance]="appearanceMap[selected]">{{stringify(selected)}}</span>
|
|
3256
3258
|
</ng-template>
|
|
3257
3259
|
` }]
|
|
3258
3260
|
}], propDecorators: { icon: [{
|