@progress/kendo-angular-filter 13.4.0-develop.1 → 13.4.0-develop.3
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/base-filter-row.component.d.ts +0 -2
- package/esm2020/base-filter-row.component.mjs +1 -8
- package/esm2020/editors/boolean-editor.component.mjs +1 -1
- package/esm2020/filter-expression-operators.component.mjs +1 -1
- package/esm2020/filter-expression.component.mjs +29 -31
- package/esm2020/filter-group.component.mjs +34 -42
- package/esm2020/filter.component.mjs +7 -6
- package/esm2020/navigation.service.mjs +7 -21
- package/esm2020/package-metadata.mjs +2 -2
- package/esm2020/util.mjs +2 -1
- package/fesm2015/progress-kendo-angular-filter.mjs +84 -113
- package/fesm2020/progress-kendo-angular-filter.mjs +84 -113
- package/package.json +11 -11
- package/schematics/ngAdd/index.js +3 -3
|
@@ -224,7 +224,8 @@ const selectors = {
|
|
|
224
224
|
textAreaElement: `textarea`,
|
|
225
225
|
kendoToolbar: `.k-toolbar`,
|
|
226
226
|
kendoButton: `.k-button`,
|
|
227
|
-
kendoFilterToolbarItem: `.k-
|
|
227
|
+
kendoFilterToolbarItem: `.k-toolbar-item`,
|
|
228
|
+
kendoFilterToolbarButton: `.k-toolbar-button`
|
|
228
229
|
};
|
|
229
230
|
|
|
230
231
|
/**
|
|
@@ -234,8 +235,8 @@ const packageMetadata = {
|
|
|
234
235
|
name: '@progress/kendo-angular-filter',
|
|
235
236
|
productName: 'Kendo UI for Angular',
|
|
236
237
|
productCodes: ['KENDOUIANGULAR', 'KENDOUICOMPLETE'],
|
|
237
|
-
publishDate:
|
|
238
|
-
version: '13.4.0-develop.
|
|
238
|
+
publishDate: 1692370799,
|
|
239
|
+
version: '13.4.0-develop.3',
|
|
239
240
|
licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/'
|
|
240
241
|
};
|
|
241
242
|
|
|
@@ -327,38 +328,32 @@ class NavigationService {
|
|
|
327
328
|
this.flattenFilterItems = [];
|
|
328
329
|
this.currentToolbarItemIndex = 0;
|
|
329
330
|
this.currentToolbarItemChildrenIndex = 0;
|
|
330
|
-
this.isInnerNavigationActivated =
|
|
331
|
+
this.isInnerNavigationActivated = true;
|
|
331
332
|
this.isFilterExpressionComponentFocused = false;
|
|
332
333
|
}
|
|
333
334
|
processKeyDown(key, event) {
|
|
334
335
|
switch (key) {
|
|
335
336
|
case Keys.ArrowUp: {
|
|
336
337
|
event.preventDefault();
|
|
337
|
-
if (!this.
|
|
338
|
+
if (!this.isFilterExpressionComponentFocused) {
|
|
339
|
+
this.currentToolbarItemChildrenIndex = 0;
|
|
338
340
|
this.currentToolbarItemIndex > 0 ? this.currentToolbarItemIndex-- : this.currentToolbarItemIndex;
|
|
339
|
-
const elementToFocus = this.flattenFilterItems[this.currentToolbarItemIndex].
|
|
341
|
+
const elementToFocus = this.flattenFilterItems[this.currentToolbarItemIndex].focusableChildren[0];
|
|
340
342
|
this.focusCurrentElement(elementToFocus);
|
|
341
343
|
}
|
|
342
344
|
break;
|
|
343
345
|
}
|
|
344
346
|
case Keys.ArrowDown: {
|
|
345
347
|
event.preventDefault();
|
|
346
|
-
if (!this.
|
|
348
|
+
if (!this.isFilterExpressionComponentFocused) {
|
|
349
|
+
this.currentToolbarItemChildrenIndex = 0;
|
|
347
350
|
this.currentToolbarItemIndex < this.flattenFilterItems.length - 1 ? this.currentToolbarItemIndex++ : this.currentToolbarItemIndex;
|
|
348
|
-
const elementToFocus = this.flattenFilterItems[this.currentToolbarItemIndex].
|
|
351
|
+
const elementToFocus = this.flattenFilterItems[this.currentToolbarItemIndex].focusableChildren[0];
|
|
349
352
|
this.focusCurrentElement(elementToFocus);
|
|
350
353
|
}
|
|
351
354
|
break;
|
|
352
355
|
}
|
|
353
356
|
case Keys.Enter: {
|
|
354
|
-
const isEventTargetFilterToolbar = event.target.closest(selectors.kendoToolbar);
|
|
355
|
-
if (!this.isInnerNavigationActivated && isEventTargetFilterToolbar) {
|
|
356
|
-
event.preventDefault();
|
|
357
|
-
this.isInnerNavigationActivated = true;
|
|
358
|
-
this.currentToolbarItemChildrenIndex = 0;
|
|
359
|
-
const elementToFocus = this.flattenFilterItems[this.currentToolbarItemIndex].focusableChildren[this.currentToolbarItemChildrenIndex];
|
|
360
|
-
this.focusCurrentElement(elementToFocus);
|
|
361
|
-
}
|
|
362
357
|
const isEventTargetKendoFilterToolbarItem = event.target.closest(selectors.kendoFilterToolbarItem);
|
|
363
358
|
const isEventTargetButton = event.target.closest(selectors.kendoButton);
|
|
364
359
|
if (this.isInnerNavigationActivated &&
|
|
@@ -377,17 +372,9 @@ class NavigationService {
|
|
|
377
372
|
break;
|
|
378
373
|
}
|
|
379
374
|
case Keys.Escape: {
|
|
380
|
-
if (this.isInnerNavigationActivated && !this.isFilterExpressionComponentFocused) {
|
|
381
|
-
event.preventDefault();
|
|
382
|
-
this.isInnerNavigationActivated = false;
|
|
383
|
-
this.currentToolbarItemChildrenIndex = 0;
|
|
384
|
-
const elementToFocus = this.flattenFilterItems[this.currentToolbarItemIndex].toolbarElement;
|
|
385
|
-
this.focusCurrentElement(elementToFocus);
|
|
386
|
-
}
|
|
387
375
|
if (this.isFilterExpressionComponentFocused) {
|
|
388
376
|
event.preventDefault();
|
|
389
377
|
this.isFilterExpressionComponentFocused = false;
|
|
390
|
-
this.isInnerNavigationActivated = true;
|
|
391
378
|
const elementToFocus = this.flattenFilterItems[this.currentToolbarItemIndex].focusableChildren[this.currentToolbarItemChildrenIndex];
|
|
392
379
|
this.focusCurrentElement(elementToFocus);
|
|
393
380
|
}
|
|
@@ -501,13 +488,6 @@ class BaseFilterRowComponent {
|
|
|
501
488
|
get toolbarElement() {
|
|
502
489
|
return this.element.nativeElement.querySelector('.k-toolbar');
|
|
503
490
|
}
|
|
504
|
-
onFocus() {
|
|
505
|
-
this.renderer.addClass(this.navigationService.flattenFilterItems[this.itemNumber].toolbarElement, 'k-focus');
|
|
506
|
-
this.navigationService.isInnerNavigationActivated = false;
|
|
507
|
-
}
|
|
508
|
-
onBlur() {
|
|
509
|
-
this.renderer.removeClass(this.navigationService.flattenFilterItems[this.itemNumber].toolbarElement, 'k-focus');
|
|
510
|
-
}
|
|
511
491
|
messageFor(key) {
|
|
512
492
|
return this.localization.get(key);
|
|
513
493
|
}
|
|
@@ -531,7 +511,7 @@ class BaseFilterRowComponent {
|
|
|
531
511
|
this.navigationService.currentToolbarItemChildrenIndex = 0;
|
|
532
512
|
this.navigationService.isInnerNavigationActivated = false;
|
|
533
513
|
this.navigationService.isFilterExpressionComponentFocused = false;
|
|
534
|
-
elementToFocus = this.navigationService.flattenFilterItems[this.itemNumber].
|
|
514
|
+
elementToFocus = this.navigationService.flattenFilterItems[this.itemNumber].focusableChildren[0];
|
|
535
515
|
}
|
|
536
516
|
this.navigationService.currentToolbarItemIndex = this.itemNumber;
|
|
537
517
|
this.navigationService.focusCurrentElement(elementToFocus, true);
|
|
@@ -610,7 +590,7 @@ FilterExpressionOperatorsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersio
|
|
|
610
590
|
<span>{{ getOperator(dataItem.value) }}</span>
|
|
611
591
|
</ng-template>
|
|
612
592
|
</kendo-dropdownlist>
|
|
613
|
-
`, isInline: true, components: [{ type: i2.DropDownListComponent, selector: "kendo-dropdownlist", inputs: ["iconClass", "loading", "data", "value", "textField", "valueField", "adaptiveMode", "title", "subtitle", "popupSettings", "listHeight", "defaultItem", "disabled", "itemDisabled", "readonly", "filterable", "virtual", "ignoreCase", "delay", "valuePrimitive", "tabindex", "tabIndex", "size", "rounded", "fillMode", "id"], outputs: ["valueChange", "filterChange", "selectionChange", "open", "opened", "close", "closed", "focus", "blur"], exportAs: ["kendoDropDownList"] }], directives: [{ type: AriaLabelValueDirective, selector: "[kendoAriaLabelValue]", inputs: ["kendoAriaLabelValue"] }, { type: i2.ValueTemplateDirective, selector: "[kendoDropDownListValueTemplate],[kendoDropDownTreeValueTemplate]" }, { type: i2.ItemTemplateDirective, selector: "[kendoDropDownListItemTemplate],[kendoComboBoxItemTemplate],[kendoAutoCompleteItemTemplate],[kendoMultiSelectItemTemplate]" }] });
|
|
593
|
+
`, isInline: true, components: [{ type: i2.DropDownListComponent, selector: "kendo-dropdownlist", inputs: ["showStickyHeader", "iconClass", "loading", "data", "value", "textField", "valueField", "adaptiveMode", "title", "subtitle", "popupSettings", "listHeight", "defaultItem", "disabled", "itemDisabled", "readonly", "filterable", "virtual", "ignoreCase", "delay", "valuePrimitive", "tabindex", "tabIndex", "size", "rounded", "fillMode", "id"], outputs: ["valueChange", "filterChange", "selectionChange", "open", "opened", "close", "closed", "focus", "blur"], exportAs: ["kendoDropDownList"] }], directives: [{ type: AriaLabelValueDirective, selector: "[kendoAriaLabelValue]", inputs: ["kendoAriaLabelValue"] }, { type: i2.ValueTemplateDirective, selector: "[kendoDropDownListValueTemplate],[kendoDropDownTreeValueTemplate]" }, { type: i2.ItemTemplateDirective, selector: "[kendoDropDownListItemTemplate],[kendoComboBoxItemTemplate],[kendoAutoCompleteItemTemplate],[kendoMultiSelectItemTemplate]" }] });
|
|
614
594
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: FilterExpressionOperatorsComponent, decorators: [{
|
|
615
595
|
type: Component,
|
|
616
596
|
args: [{
|
|
@@ -808,7 +788,7 @@ FilterBooleanEditorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12
|
|
|
808
788
|
valueField="value"
|
|
809
789
|
>
|
|
810
790
|
</kendo-dropdownlist>
|
|
811
|
-
`, isInline: true, components: [{ type: i2.DropDownListComponent, selector: "kendo-dropdownlist", inputs: ["iconClass", "loading", "data", "value", "textField", "valueField", "adaptiveMode", "title", "subtitle", "popupSettings", "listHeight", "defaultItem", "disabled", "itemDisabled", "readonly", "filterable", "virtual", "ignoreCase", "delay", "valuePrimitive", "tabindex", "tabIndex", "size", "rounded", "fillMode", "id"], outputs: ["valueChange", "filterChange", "selectionChange", "open", "opened", "close", "closed", "focus", "blur"], exportAs: ["kendoDropDownList"] }], directives: [{ type: AriaLabelValueDirective, selector: "[kendoAriaLabelValue]", inputs: ["kendoAriaLabelValue"] }] });
|
|
791
|
+
`, isInline: true, components: [{ type: i2.DropDownListComponent, selector: "kendo-dropdownlist", inputs: ["showStickyHeader", "iconClass", "loading", "data", "value", "textField", "valueField", "adaptiveMode", "title", "subtitle", "popupSettings", "listHeight", "defaultItem", "disabled", "itemDisabled", "readonly", "filterable", "virtual", "ignoreCase", "delay", "valuePrimitive", "tabindex", "tabIndex", "size", "rounded", "fillMode", "id"], outputs: ["valueChange", "filterChange", "selectionChange", "open", "opened", "close", "closed", "focus", "blur"], exportAs: ["kendoDropDownList"] }], directives: [{ type: AriaLabelValueDirective, selector: "[kendoAriaLabelValue]", inputs: ["kendoAriaLabelValue"] }] });
|
|
812
792
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: FilterBooleanEditorComponent, decorators: [{
|
|
813
793
|
type: Component,
|
|
814
794
|
args: [{
|
|
@@ -1072,8 +1052,8 @@ FilterExpressionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.
|
|
|
1072
1052
|
useExisting: forwardRef(() => FilterExpressionComponent)
|
|
1073
1053
|
}], usesInheritance: true, ngImport: i0, template: `
|
|
1074
1054
|
<div class="k-filter-toolbar">
|
|
1075
|
-
<div class="k-toolbar k-toolbar-md" role="toolbar" [attr.aria-label]="messageFor('filterToolbarAriaLabel')" (
|
|
1076
|
-
<div class="k-filter-
|
|
1055
|
+
<div class="k-toolbar k-toolbar-md" role="toolbar" [attr.aria-label]="messageFor('filterToolbarAriaLabel')" (mousedown)="onMouseDown($event)">
|
|
1056
|
+
<div class="k-filter-field k-toolbar-item" >
|
|
1077
1057
|
<kendo-dropdownlist
|
|
1078
1058
|
[tabindex]="-1"
|
|
1079
1059
|
[kendoAriaLabelValue]="messageFor('filterFieldAriaLabel')"
|
|
@@ -1086,7 +1066,7 @@ FilterExpressionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.
|
|
|
1086
1066
|
(valueChange)="filterValueChange($event)">
|
|
1087
1067
|
</kendo-dropdownlist>
|
|
1088
1068
|
</div>
|
|
1089
|
-
<div *ngIf="!isBoolean" class="k-filter-
|
|
1069
|
+
<div *ngIf="!isBoolean" class="k-filter-operator k-toolbar-item" >
|
|
1090
1070
|
<kendo-filter-expression-operators
|
|
1091
1071
|
[currentItem]="currentItem"
|
|
1092
1072
|
[operators]="operators"
|
|
@@ -1095,7 +1075,7 @@ FilterExpressionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.
|
|
|
1095
1075
|
</kendo-filter-expression-operators>
|
|
1096
1076
|
</div>
|
|
1097
1077
|
|
|
1098
|
-
<div class="k-filter-
|
|
1078
|
+
<div class="k-filter-value k-toolbar-item">
|
|
1099
1079
|
<ng-container *ngIf="!editorTemplate" [ngSwitch]="getEditorType()">
|
|
1100
1080
|
<kendo-filter-text-editor *ngSwitchCase="'string'" [currentItem]="currentItem" [isDisabled]="isEditorDisabled" (valueChange)="valueChange.emit()"></kendo-filter-text-editor>
|
|
1101
1081
|
<kendo-filter-numeric-editor *ngSwitchCase="'number'" [currentItem]="currentItem" [isDisabled]="isEditorDisabled" [format]="numericEditorFormat" (valueChange)="valueChange.emit()"></kendo-filter-numeric-editor>
|
|
@@ -1109,20 +1089,19 @@ FilterExpressionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.
|
|
|
1109
1089
|
</ng-container>
|
|
1110
1090
|
</div>
|
|
1111
1091
|
|
|
1112
|
-
<
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
</div>
|
|
1092
|
+
<button
|
|
1093
|
+
kendoButton
|
|
1094
|
+
class="k-toolbar-button"
|
|
1095
|
+
tabindex="-1"
|
|
1096
|
+
icon="x"
|
|
1097
|
+
[svgIcon]="xIcon"
|
|
1098
|
+
fillMode="flat"
|
|
1099
|
+
[title]="messageFor('remove')"
|
|
1100
|
+
(click)="removeFilterExpression()">
|
|
1101
|
+
</button>
|
|
1123
1102
|
</div>
|
|
1124
1103
|
</div>
|
|
1125
|
-
`, isInline: true, components: [{ type: i2.DropDownListComponent, selector: "kendo-dropdownlist", inputs: ["iconClass", "loading", "data", "value", "textField", "valueField", "adaptiveMode", "title", "subtitle", "popupSettings", "listHeight", "defaultItem", "disabled", "itemDisabled", "readonly", "filterable", "virtual", "ignoreCase", "delay", "valuePrimitive", "tabindex", "tabIndex", "size", "rounded", "fillMode", "id"], outputs: ["valueChange", "filterChange", "selectionChange", "open", "opened", "close", "closed", "focus", "blur"], exportAs: ["kendoDropDownList"] }, { type: FilterExpressionOperatorsComponent, selector: "kendo-filter-expression-operators", inputs: ["currentItem", "editorType", "operators"], outputs: ["valueChange"] }, { type: FilterTextEditorComponent, selector: "kendo-filter-text-editor", inputs: ["currentItem", "isDisabled"], outputs: ["valueChange"] }, { type: FilterNumericEditorComponent, selector: "kendo-filter-numeric-editor", inputs: ["currentItem", "isDisabled", "format"], outputs: ["valueChange"] }, { type: FilterBooleanEditorComponent, selector: "kendo-filter-boolean-editor", inputs: ["currentItem"], outputs: ["valueChange"] }, { type: FilterDateEditorComponent, selector: "kendo-filter-date-editor", inputs: ["currentItem", "isDisabled", "format"], outputs: ["valueChange"] }, { type: i10.ButtonComponent, selector: "button[kendoButton], span[kendoButton], kendo-button", inputs: ["toggleable", "togglable", "selected", "tabIndex", "imageUrl", "iconClass", "icon", "disabled", "size", "rounded", "fillMode", "themeColor", "svgIcon", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }], directives: [{ type: AriaLabelValueDirective, selector: "[kendoAriaLabelValue]", inputs: ["kendoAriaLabelValue"] }, { type: i12.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i12.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i12.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i10.TemplateContextDirective, selector: "[templateContext]", inputs: ["templateContext"] }] });
|
|
1104
|
+
`, isInline: true, components: [{ type: i2.DropDownListComponent, selector: "kendo-dropdownlist", inputs: ["showStickyHeader", "iconClass", "loading", "data", "value", "textField", "valueField", "adaptiveMode", "title", "subtitle", "popupSettings", "listHeight", "defaultItem", "disabled", "itemDisabled", "readonly", "filterable", "virtual", "ignoreCase", "delay", "valuePrimitive", "tabindex", "tabIndex", "size", "rounded", "fillMode", "id"], outputs: ["valueChange", "filterChange", "selectionChange", "open", "opened", "close", "closed", "focus", "blur"], exportAs: ["kendoDropDownList"] }, { type: FilterExpressionOperatorsComponent, selector: "kendo-filter-expression-operators", inputs: ["currentItem", "editorType", "operators"], outputs: ["valueChange"] }, { type: FilterTextEditorComponent, selector: "kendo-filter-text-editor", inputs: ["currentItem", "isDisabled"], outputs: ["valueChange"] }, { type: FilterNumericEditorComponent, selector: "kendo-filter-numeric-editor", inputs: ["currentItem", "isDisabled", "format"], outputs: ["valueChange"] }, { type: FilterBooleanEditorComponent, selector: "kendo-filter-boolean-editor", inputs: ["currentItem"], outputs: ["valueChange"] }, { type: FilterDateEditorComponent, selector: "kendo-filter-date-editor", inputs: ["currentItem", "isDisabled", "format"], outputs: ["valueChange"] }, { type: i10.ButtonComponent, selector: "button[kendoButton], span[kendoButton], kendo-button", inputs: ["toggleable", "togglable", "selected", "tabIndex", "imageUrl", "iconClass", "icon", "disabled", "size", "rounded", "fillMode", "themeColor", "svgIcon", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }], directives: [{ type: AriaLabelValueDirective, selector: "[kendoAriaLabelValue]", inputs: ["kendoAriaLabelValue"] }, { type: i12.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i12.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i12.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i10.TemplateContextDirective, selector: "[templateContext]", inputs: ["templateContext"] }] });
|
|
1126
1105
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: FilterExpressionComponent, decorators: [{
|
|
1127
1106
|
type: Component,
|
|
1128
1107
|
args: [{
|
|
@@ -1133,8 +1112,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1133
1112
|
selector: 'kendo-filter-expression',
|
|
1134
1113
|
template: `
|
|
1135
1114
|
<div class="k-filter-toolbar">
|
|
1136
|
-
<div class="k-toolbar k-toolbar-md" role="toolbar" [attr.aria-label]="messageFor('filterToolbarAriaLabel')" (
|
|
1137
|
-
<div class="k-filter-
|
|
1115
|
+
<div class="k-toolbar k-toolbar-md" role="toolbar" [attr.aria-label]="messageFor('filterToolbarAriaLabel')" (mousedown)="onMouseDown($event)">
|
|
1116
|
+
<div class="k-filter-field k-toolbar-item" >
|
|
1138
1117
|
<kendo-dropdownlist
|
|
1139
1118
|
[tabindex]="-1"
|
|
1140
1119
|
[kendoAriaLabelValue]="messageFor('filterFieldAriaLabel')"
|
|
@@ -1147,7 +1126,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1147
1126
|
(valueChange)="filterValueChange($event)">
|
|
1148
1127
|
</kendo-dropdownlist>
|
|
1149
1128
|
</div>
|
|
1150
|
-
<div *ngIf="!isBoolean" class="k-filter-
|
|
1129
|
+
<div *ngIf="!isBoolean" class="k-filter-operator k-toolbar-item" >
|
|
1151
1130
|
<kendo-filter-expression-operators
|
|
1152
1131
|
[currentItem]="currentItem"
|
|
1153
1132
|
[operators]="operators"
|
|
@@ -1156,7 +1135,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1156
1135
|
</kendo-filter-expression-operators>
|
|
1157
1136
|
</div>
|
|
1158
1137
|
|
|
1159
|
-
<div class="k-filter-
|
|
1138
|
+
<div class="k-filter-value k-toolbar-item">
|
|
1160
1139
|
<ng-container *ngIf="!editorTemplate" [ngSwitch]="getEditorType()">
|
|
1161
1140
|
<kendo-filter-text-editor *ngSwitchCase="'string'" [currentItem]="currentItem" [isDisabled]="isEditorDisabled" (valueChange)="valueChange.emit()"></kendo-filter-text-editor>
|
|
1162
1141
|
<kendo-filter-numeric-editor *ngSwitchCase="'number'" [currentItem]="currentItem" [isDisabled]="isEditorDisabled" [format]="numericEditorFormat" (valueChange)="valueChange.emit()"></kendo-filter-numeric-editor>
|
|
@@ -1170,17 +1149,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1170
1149
|
</ng-container>
|
|
1171
1150
|
</div>
|
|
1172
1151
|
|
|
1173
|
-
<
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
</div>
|
|
1152
|
+
<button
|
|
1153
|
+
kendoButton
|
|
1154
|
+
class="k-toolbar-button"
|
|
1155
|
+
tabindex="-1"
|
|
1156
|
+
icon="x"
|
|
1157
|
+
[svgIcon]="xIcon"
|
|
1158
|
+
fillMode="flat"
|
|
1159
|
+
[title]="messageFor('remove')"
|
|
1160
|
+
(click)="removeFilterExpression()">
|
|
1161
|
+
</button>
|
|
1184
1162
|
</div>
|
|
1185
1163
|
</div>
|
|
1186
1164
|
`
|
|
@@ -1256,24 +1234,18 @@ class FilterGroupComponent extends BaseFilterRowComponent {
|
|
|
1256
1234
|
this.valueChange.emit(true);
|
|
1257
1235
|
}
|
|
1258
1236
|
onMouseDown(event) {
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
}
|
|
1265
|
-
if (event.target.closest(selectors.orButton)) {
|
|
1266
|
-
index = 1;
|
|
1267
|
-
}
|
|
1268
|
-
this.navigationService.currentToolbarItemChildrenIndex = index;
|
|
1269
|
-
this.navigationService.isInnerNavigationActivated = true;
|
|
1270
|
-
elementToFocus = this.navigationService.flattenFilterItems[this.itemNumber].focusableChildren[index];
|
|
1237
|
+
const toolbarItemElement = Array.from(event.target.closest(selectors.kendoToolbar).children).indexOf(event.target.closest(selectors.kendoFilterToolbarItem));
|
|
1238
|
+
const buttonElement = Array.from(event.target.closest(selectors.kendoToolbar).children).indexOf(event.target.closest(selectors.kendoFilterToolbarButton));
|
|
1239
|
+
let index = (toolbarItemElement > -1 ? toolbarItemElement : buttonElement) + 1;
|
|
1240
|
+
if (event.target.closest(selectors.andButton)) {
|
|
1241
|
+
index = 0;
|
|
1271
1242
|
}
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
this.navigationService.isInnerNavigationActivated = false;
|
|
1275
|
-
elementToFocus = this.navigationService.flattenFilterItems[this.itemNumber].toolbarElement;
|
|
1243
|
+
if (event.target.closest(selectors.orButton)) {
|
|
1244
|
+
index = 1;
|
|
1276
1245
|
}
|
|
1246
|
+
this.navigationService.currentToolbarItemChildrenIndex = index;
|
|
1247
|
+
this.navigationService.isInnerNavigationActivated = true;
|
|
1248
|
+
const elementToFocus = this.navigationService.flattenFilterItems[this.itemNumber].focusableChildren[index];
|
|
1277
1249
|
this.navigationService.isFilterExpressionComponentFocused = false;
|
|
1278
1250
|
this.navigationService.currentToolbarItemIndex = this.itemNumber;
|
|
1279
1251
|
this.navigationService.focusCurrentElement(elementToFocus, true);
|
|
@@ -1285,26 +1257,26 @@ FilterGroupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
1285
1257
|
useExisting: forwardRef(() => FilterGroupComponent)
|
|
1286
1258
|
}], viewQueries: [{ propertyName: "_filterItems", predicate: FilterItem, descendants: true }], usesInheritance: true, ngImport: i0, template: `
|
|
1287
1259
|
<div class="k-filter-toolbar">
|
|
1288
|
-
<div class="k-toolbar k-toolbar-md" role="toolbar" [attr.aria-label]="messageFor('filterToolbarAriaLabel')" (
|
|
1289
|
-
<div class="k-
|
|
1290
|
-
|
|
1291
|
-
<button
|
|
1260
|
+
<div class="k-toolbar k-toolbar-md" role="toolbar" [attr.aria-label]="messageFor('filterToolbarAriaLabel')" (mousedown)="onMouseDown($event)">
|
|
1261
|
+
<div class="k-toolbar-button-group k-button-group k-button-group-solid" role="group">
|
|
1262
|
+
<button
|
|
1292
1263
|
tabindex="-1"
|
|
1293
1264
|
*ngFor="let operator of operators"
|
|
1294
1265
|
kendoButton
|
|
1266
|
+
class="k-toolbar-button"
|
|
1295
1267
|
[ngClass]="{'k-group-start': operator.value === 'and', 'k-group-end': operator.value === 'or'}"
|
|
1296
1268
|
[selected]="currentItem.logic === operator.value"
|
|
1297
1269
|
[attr.aria-pressed]="currentItem.logic === operator.value"
|
|
1298
1270
|
[title]="operator.text"
|
|
1299
1271
|
(click)="selectedChange(operator.value)"
|
|
1300
|
-
|
|
1272
|
+
>
|
|
1301
1273
|
{{getOperator(operator.value)}}
|
|
1302
|
-
|
|
1303
|
-
</div>
|
|
1274
|
+
</button>
|
|
1304
1275
|
</div>
|
|
1305
|
-
|
|
1276
|
+
|
|
1306
1277
|
<button
|
|
1307
1278
|
kendoButton
|
|
1279
|
+
class="k-toolbar-button"
|
|
1308
1280
|
tabindex="-1"
|
|
1309
1281
|
[title]="messageFor('addFilter')"
|
|
1310
1282
|
icon="filter-add-expression"
|
|
@@ -1312,10 +1284,10 @@ FilterGroupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
1312
1284
|
(click)="addFilterExpression()">
|
|
1313
1285
|
{{messageFor('addFilter')}}
|
|
1314
1286
|
</button>
|
|
1315
|
-
|
|
1316
|
-
<div class="k-filter-toolbar-item">
|
|
1287
|
+
|
|
1317
1288
|
<button
|
|
1318
1289
|
kendoButton
|
|
1290
|
+
class="k-toolbar-button"
|
|
1319
1291
|
tabindex="-1"
|
|
1320
1292
|
[title]="messageFor('addGroup')"
|
|
1321
1293
|
icon="filter-add-group"
|
|
@@ -1323,10 +1295,10 @@ FilterGroupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
1323
1295
|
(click)="addFilterGroup()">
|
|
1324
1296
|
{{messageFor('addGroup')}}
|
|
1325
1297
|
</button>
|
|
1326
|
-
|
|
1327
|
-
<div class="k-filter-toolbar-item">
|
|
1298
|
+
|
|
1328
1299
|
<button
|
|
1329
1300
|
kendoButton
|
|
1301
|
+
class="k-toolbar-button"
|
|
1330
1302
|
tabindex="-1"
|
|
1331
1303
|
icon="x"
|
|
1332
1304
|
[svgIcon]="xIcon"
|
|
@@ -1334,7 +1306,6 @@ FilterGroupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
1334
1306
|
[title]="messageFor('remove')"
|
|
1335
1307
|
(click)="removeFilterGroup()">
|
|
1336
1308
|
</button>
|
|
1337
|
-
</div>
|
|
1338
1309
|
</div>
|
|
1339
1310
|
</div>
|
|
1340
1311
|
|
|
@@ -1365,26 +1336,26 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1365
1336
|
selector: 'kendo-filter-group',
|
|
1366
1337
|
template: `
|
|
1367
1338
|
<div class="k-filter-toolbar">
|
|
1368
|
-
<div class="k-toolbar k-toolbar-md" role="toolbar" [attr.aria-label]="messageFor('filterToolbarAriaLabel')" (
|
|
1369
|
-
<div class="k-
|
|
1370
|
-
|
|
1371
|
-
<button
|
|
1339
|
+
<div class="k-toolbar k-toolbar-md" role="toolbar" [attr.aria-label]="messageFor('filterToolbarAriaLabel')" (mousedown)="onMouseDown($event)">
|
|
1340
|
+
<div class="k-toolbar-button-group k-button-group k-button-group-solid" role="group">
|
|
1341
|
+
<button
|
|
1372
1342
|
tabindex="-1"
|
|
1373
1343
|
*ngFor="let operator of operators"
|
|
1374
1344
|
kendoButton
|
|
1345
|
+
class="k-toolbar-button"
|
|
1375
1346
|
[ngClass]="{'k-group-start': operator.value === 'and', 'k-group-end': operator.value === 'or'}"
|
|
1376
1347
|
[selected]="currentItem.logic === operator.value"
|
|
1377
1348
|
[attr.aria-pressed]="currentItem.logic === operator.value"
|
|
1378
1349
|
[title]="operator.text"
|
|
1379
1350
|
(click)="selectedChange(operator.value)"
|
|
1380
|
-
|
|
1351
|
+
>
|
|
1381
1352
|
{{getOperator(operator.value)}}
|
|
1382
|
-
|
|
1383
|
-
</div>
|
|
1353
|
+
</button>
|
|
1384
1354
|
</div>
|
|
1385
|
-
|
|
1355
|
+
|
|
1386
1356
|
<button
|
|
1387
1357
|
kendoButton
|
|
1358
|
+
class="k-toolbar-button"
|
|
1388
1359
|
tabindex="-1"
|
|
1389
1360
|
[title]="messageFor('addFilter')"
|
|
1390
1361
|
icon="filter-add-expression"
|
|
@@ -1392,10 +1363,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1392
1363
|
(click)="addFilterExpression()">
|
|
1393
1364
|
{{messageFor('addFilter')}}
|
|
1394
1365
|
</button>
|
|
1395
|
-
|
|
1396
|
-
<div class="k-filter-toolbar-item">
|
|
1366
|
+
|
|
1397
1367
|
<button
|
|
1398
1368
|
kendoButton
|
|
1369
|
+
class="k-toolbar-button"
|
|
1399
1370
|
tabindex="-1"
|
|
1400
1371
|
[title]="messageFor('addGroup')"
|
|
1401
1372
|
icon="filter-add-group"
|
|
@@ -1403,10 +1374,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1403
1374
|
(click)="addFilterGroup()">
|
|
1404
1375
|
{{messageFor('addGroup')}}
|
|
1405
1376
|
</button>
|
|
1406
|
-
|
|
1407
|
-
<div class="k-filter-toolbar-item">
|
|
1377
|
+
|
|
1408
1378
|
<button
|
|
1409
1379
|
kendoButton
|
|
1380
|
+
class="k-toolbar-button"
|
|
1410
1381
|
tabindex="-1"
|
|
1411
1382
|
icon="x"
|
|
1412
1383
|
[svgIcon]="xIcon"
|
|
@@ -1414,7 +1385,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1414
1385
|
[title]="messageFor('remove')"
|
|
1415
1386
|
(click)="removeFilterGroup()">
|
|
1416
1387
|
</button>
|
|
1417
|
-
</div>
|
|
1418
1388
|
</div>
|
|
1419
1389
|
</div>
|
|
1420
1390
|
|
|
@@ -1616,7 +1586,7 @@ class FilterComponent {
|
|
|
1616
1586
|
setTimeout(() => {
|
|
1617
1587
|
if (!(document.activeElement.closest('.k-filter'))) {
|
|
1618
1588
|
this.renderer.setAttribute(this.navigationService.currentlyFocusedElement, 'tabindex', '-1');
|
|
1619
|
-
this.navigationService.currentlyFocusedElement = this.navigationService.flattenFilterItems[this.navigationService.currentToolbarItemIndex].
|
|
1589
|
+
this.navigationService.currentlyFocusedElement = this.navigationService.flattenFilterItems[this.navigationService.currentToolbarItemIndex].focusableChildren[0];
|
|
1620
1590
|
this.renderer.setAttribute(this.navigationService.currentlyFocusedElement, 'tabindex', '0');
|
|
1621
1591
|
this.navigationService.isInnerNavigationActivated = false;
|
|
1622
1592
|
this.navigationService.isFilterExpressionComponentFocused = false;
|
|
@@ -1689,7 +1659,7 @@ class FilterComponent {
|
|
|
1689
1659
|
}
|
|
1690
1660
|
this.navigationService.reset(this.filterItems);
|
|
1691
1661
|
if (!this.navigationService.currentlyFocusedElement) {
|
|
1692
|
-
const firstElement = this.navigationService.flattenFilterItems[0].
|
|
1662
|
+
const firstElement = this.navigationService.flattenFilterItems[0].focusableChildren[0];
|
|
1693
1663
|
this.navigationService.currentlyFocusedElement = firstElement;
|
|
1694
1664
|
this.renderer.setAttribute(firstElement, 'tabindex', '0');
|
|
1695
1665
|
}
|
|
@@ -1716,9 +1686,10 @@ class FilterComponent {
|
|
|
1716
1686
|
if (this.navigationService.currentToolbarItemIndex === this.navigationService.flattenFilterItems.length) {
|
|
1717
1687
|
this.navigationService.currentToolbarItemIndex -= 1;
|
|
1718
1688
|
}
|
|
1719
|
-
this.navigationService.isInnerNavigationActivated = false;
|
|
1720
1689
|
this.navigationService.isFilterExpressionComponentFocused = false;
|
|
1721
|
-
|
|
1690
|
+
const itemIndex = this.navigationService.currentToolbarItemIndex;
|
|
1691
|
+
const activeChildIndex = this.navigationService.currentToolbarItemChildrenIndex;
|
|
1692
|
+
this.navigationService.currentlyFocusedElement = this.navigationService.flattenFilterItems[itemIndex].focusableChildren[activeChildIndex];
|
|
1722
1693
|
this.renderer.setAttribute(this.navigationService.currentlyFocusedElement, 'tabindex', '0');
|
|
1723
1694
|
this.renderer.addClass(this.navigationService.currentlyFocusedElement, 'k-focus');
|
|
1724
1695
|
this.navigationService.currentlyFocusedElement.focus();
|
|
@@ -1900,7 +1871,7 @@ FilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", versio
|
|
|
1900
1871
|
filterComponentAriaLabel="filter component"
|
|
1901
1872
|
>
|
|
1902
1873
|
</ng-container>
|
|
1903
|
-
<div class="k-
|
|
1874
|
+
<div class="k-filter" [attr.dir]="direction">
|
|
1904
1875
|
<ul class='k-filter-container' role="tree" [attr.aria-label]="messageFor('filterComponentAriaLabel')">
|
|
1905
1876
|
<li class='k-filter-group-main' role="treeitem">
|
|
1906
1877
|
<kendo-filter-group
|
|
@@ -2039,7 +2010,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
2039
2010
|
filterComponentAriaLabel="filter component"
|
|
2040
2011
|
>
|
|
2041
2012
|
</ng-container>
|
|
2042
|
-
<div class="k-
|
|
2013
|
+
<div class="k-filter" [attr.dir]="direction">
|
|
2043
2014
|
<ul class='k-filter-container' role="tree" [attr.aria-label]="messageFor('filterComponentAriaLabel')">
|
|
2044
2015
|
<li class='k-filter-group-main' role="treeitem">
|
|
2045
2016
|
<kendo-filter-group
|