@progress/kendo-angular-treelist 4.0.2 → 4.0.4-dev.202202240728

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.
@@ -9,7 +9,7 @@ export const packageMetadata = {
9
9
  name: '@progress/kendo-angular-treelist',
10
10
  productName: 'Kendo UI for Angular',
11
11
  productCodes: ['KENDOUIANGULAR', 'KENDOUICOMPLETE'],
12
- publishDate: 1642687822,
12
+ publishDate: 1645687388,
13
13
  version: '',
14
14
  licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning'
15
15
  };
@@ -13,7 +13,11 @@ export declare const NON_DATA_ROW_CLASSES = "k-grouping-row k-group-footer k-det
13
13
  /**
14
14
  * @hidden
15
15
  */
16
- export declare const IGNORE_TARGET_CLASSSES = "k-icon";
16
+ export declare const EMPTY_ICON_CLASS = "k-i-none";
17
+ /**
18
+ * @hidden
19
+ */
20
+ export declare const ICON_CLASS = "k-icon";
17
21
  /**
18
22
  * @hidden
19
23
  */
@@ -13,7 +13,11 @@ export const NON_DATA_ROW_CLASSES = 'k-grouping-row k-group-footer k-detail-row
13
13
  /**
14
14
  * @hidden
15
15
  */
16
- export const IGNORE_TARGET_CLASSSES = 'k-icon';
16
+ export const EMPTY_ICON_CLASS = 'k-i-none';
17
+ /**
18
+ * @hidden
19
+ */
20
+ export const ICON_CLASS = 'k-icon';
17
21
  /**
18
22
  * @hidden
19
23
  */
@@ -76,6 +76,7 @@ export declare class TableBodyComponent implements OnInit, OnDestroy, OnChanges
76
76
  logicalRowIndex(rowIndex: number): number;
77
77
  isCellSelected(dataItem: any, column: any, columnIndex: number): boolean;
78
78
  targetArgs(target: any, skipFocusable?: boolean): any;
79
+ private checkIfClickable;
79
80
  private clickHandler;
80
81
  private emitCellClick;
81
82
  private cellKeydownHandler;
@@ -19,7 +19,7 @@ import { Keys } from '@progress/kendo-angular-common';
19
19
  import { defaultTrackBy } from '../common/default-track-by';
20
20
  import { ExpandStateService } from '../expand-state/expand-state.service';
21
21
  import { SelectionService } from '../selection/selection.service';
22
- import { NON_DATA_CELL_CLASSES, NON_DATA_ROW_CLASSES, IGNORE_TARGET_CLASSSES, IGNORE_CONTAINER_CLASSES } from './constants';
22
+ import { NON_DATA_CELL_CLASSES, NON_DATA_ROW_CLASSES, IGNORE_CONTAINER_CLASSES, ICON_CLASS, EMPTY_ICON_CLASS } from './constants';
23
23
  const columnCellIndex = (cell, cells) => {
24
24
  for (let idx = 0; idx < cells.length; idx++) {
25
25
  if (cells[idx] === cell) {
@@ -176,6 +176,11 @@ let TableBodyComponent = class TableBodyComponent {
176
176
  };
177
177
  }
178
178
  }
179
+ checkIfClickable(target, cell) {
180
+ return !matchesNodeName('label')(target) &&
181
+ (!hasClasses(target, ICON_CLASS) || hasClasses(target, EMPTY_ICON_CLASS)) &&
182
+ !closestInScope(target, matchesClasses(IGNORE_CONTAINER_CLASSES), cell);
183
+ }
179
184
  clickHandler(eventArg) {
180
185
  const target = eventArg.target;
181
186
  const { cell, row } = this.targetElements(target);
@@ -186,8 +191,8 @@ let TableBodyComponent = class TableBodyComponent {
186
191
  }
187
192
  this.editService.preventCellClose();
188
193
  const focusable = target !== cell && isFocusableWithTabKey(target, false);
189
- if (!focusable && !matchesNodeName('label')(target) && !hasClasses(target, IGNORE_TARGET_CLASSSES) &&
190
- !closestInScope(target, matchesClasses(IGNORE_CONTAINER_CLASSES), cell)) {
194
+ const targetClickable = this.checkIfClickable(target, cell);
195
+ if (!focusable && targetClickable) {
191
196
  const args = this.cellClickArgs(cell, row, eventArg);
192
197
  if (!args) {
193
198
  return;
@@ -33,7 +33,7 @@ const packageMetadata = {
33
33
  name: '@progress/kendo-angular-treelist',
34
34
  productName: 'Kendo UI for Angular',
35
35
  productCodes: ['KENDOUIANGULAR', 'KENDOUICOMPLETE'],
36
- publishDate: 1642687822,
36
+ publishDate: 1645687388,
37
37
  version: '',
38
38
  licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning'
39
39
  };
@@ -7530,7 +7530,11 @@ const NON_DATA_ROW_CLASSES = 'k-grouping-row k-group-footer k-detail-row k-grid-
7530
7530
  /**
7531
7531
  * @hidden
7532
7532
  */
7533
- const IGNORE_TARGET_CLASSSES = 'k-icon';
7533
+ const EMPTY_ICON_CLASS = 'k-i-none';
7534
+ /**
7535
+ * @hidden
7536
+ */
7537
+ const ICON_CLASS = 'k-icon';
7534
7538
  /**
7535
7539
  * @hidden
7536
7540
  */
@@ -15596,6 +15600,11 @@ let TableBodyComponent = class TableBodyComponent {
15596
15600
  };
15597
15601
  }
15598
15602
  }
15603
+ checkIfClickable(target, cell) {
15604
+ return !matchesNodeName('label')(target) &&
15605
+ (!hasClasses(target, ICON_CLASS) || hasClasses(target, EMPTY_ICON_CLASS)) &&
15606
+ !closestInScope(target, matchesClasses(IGNORE_CONTAINER_CLASSES), cell);
15607
+ }
15599
15608
  clickHandler(eventArg) {
15600
15609
  const target = eventArg.target;
15601
15610
  const { cell, row } = this.targetElements(target);
@@ -15606,8 +15615,8 @@ let TableBodyComponent = class TableBodyComponent {
15606
15615
  }
15607
15616
  this.editService.preventCellClose();
15608
15617
  const focusable = target !== cell && isFocusableWithTabKey(target, false);
15609
- if (!focusable && !matchesNodeName('label')(target) && !hasClasses(target, IGNORE_TARGET_CLASSSES) &&
15610
- !closestInScope(target, matchesClasses(IGNORE_CONTAINER_CLASSES), cell)) {
15618
+ const targetClickable = this.checkIfClickable(target, cell);
15619
+ if (!focusable && targetClickable) {
15611
15620
  const args = this.cellClickArgs(cell, row, eventArg);
15612
15621
  if (!args) {
15613
15622
  return;
@@ -33,7 +33,7 @@ var packageMetadata = {
33
33
  name: '@progress/kendo-angular-treelist',
34
34
  productName: 'Kendo UI for Angular',
35
35
  productCodes: ['KENDOUIANGULAR', 'KENDOUICOMPLETE'],
36
- publishDate: 1642687822,
36
+ publishDate: 1645687388,
37
37
  version: '',
38
38
  licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning'
39
39
  };
@@ -7990,7 +7990,11 @@ var NON_DATA_ROW_CLASSES = 'k-grouping-row k-group-footer k-detail-row k-grid-no
7990
7990
  /**
7991
7991
  * @hidden
7992
7992
  */
7993
- var IGNORE_TARGET_CLASSSES = 'k-icon';
7993
+ var EMPTY_ICON_CLASS = 'k-i-none';
7994
+ /**
7995
+ * @hidden
7996
+ */
7997
+ var ICON_CLASS = 'k-icon';
7994
7998
  /**
7995
7999
  * @hidden
7996
8000
  */
@@ -16067,6 +16071,11 @@ var TableBodyComponent = /** @class */ (function () {
16067
16071
  };
16068
16072
  }
16069
16073
  };
16074
+ TableBodyComponent.prototype.checkIfClickable = function (target, cell) {
16075
+ return !matchesNodeName('label')(target) &&
16076
+ (!hasClasses(target, ICON_CLASS) || hasClasses(target, EMPTY_ICON_CLASS)) &&
16077
+ !closestInScope(target, matchesClasses(IGNORE_CONTAINER_CLASSES), cell);
16078
+ };
16070
16079
  TableBodyComponent.prototype.clickHandler = function (eventArg) {
16071
16080
  var _this = this;
16072
16081
  var target = eventArg.target;
@@ -16078,8 +16087,8 @@ var TableBodyComponent = /** @class */ (function () {
16078
16087
  }
16079
16088
  this.editService.preventCellClose();
16080
16089
  var focusable = target !== cell && isFocusableWithTabKey(target, false);
16081
- if (!focusable && !matchesNodeName('label')(target) && !hasClasses(target, IGNORE_TARGET_CLASSSES) &&
16082
- !closestInScope(target, matchesClasses(IGNORE_CONTAINER_CLASSES), cell)) {
16090
+ var targetClickable = this.checkIfClickable(target, cell);
16091
+ if (!focusable && targetClickable) {
16083
16092
  var args_1 = this.cellClickArgs(cell, row, eventArg);
16084
16093
  if (!args_1) {
16085
16094
  return;
@@ -11,7 +11,7 @@ exports.packageMetadata = {
11
11
  name: '@progress/kendo-angular-treelist',
12
12
  productName: 'Kendo UI for Angular',
13
13
  productCodes: ['KENDOUIANGULAR', 'KENDOUICOMPLETE'],
14
- publishDate: 1642687822,
14
+ publishDate: 1645687388,
15
15
  version: '',
16
16
  licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning'
17
17
  };
@@ -15,7 +15,11 @@ exports.NON_DATA_ROW_CLASSES = 'k-grouping-row k-group-footer k-detail-row k-gri
15
15
  /**
16
16
  * @hidden
17
17
  */
18
- exports.IGNORE_TARGET_CLASSSES = 'k-icon';
18
+ exports.EMPTY_ICON_CLASS = 'k-i-none';
19
+ /**
20
+ * @hidden
21
+ */
22
+ exports.ICON_CLASS = 'k-icon';
19
23
  /**
20
24
  * @hidden
21
25
  */
@@ -213,6 +213,11 @@ var TableBodyComponent = /** @class */ (function () {
213
213
  };
214
214
  }
215
215
  };
216
+ TableBodyComponent.prototype.checkIfClickable = function (target, cell) {
217
+ return !dom_queries_1.matchesNodeName('label')(target) &&
218
+ (!dom_queries_1.hasClasses(target, constants_1.ICON_CLASS) || dom_queries_1.hasClasses(target, constants_1.EMPTY_ICON_CLASS)) &&
219
+ !dom_queries_1.closestInScope(target, dom_queries_1.matchesClasses(constants_1.IGNORE_CONTAINER_CLASSES), cell);
220
+ };
216
221
  TableBodyComponent.prototype.clickHandler = function (eventArg) {
217
222
  var _this = this;
218
223
  var target = eventArg.target;
@@ -224,8 +229,8 @@ var TableBodyComponent = /** @class */ (function () {
224
229
  }
225
230
  this.editService.preventCellClose();
226
231
  var focusable = target !== cell && dom_queries_1.isFocusableWithTabKey(target, false);
227
- if (!focusable && !dom_queries_1.matchesNodeName('label')(target) && !dom_queries_1.hasClasses(target, constants_1.IGNORE_TARGET_CLASSSES) &&
228
- !dom_queries_1.closestInScope(target, dom_queries_1.matchesClasses(constants_1.IGNORE_CONTAINER_CLASSES), cell)) {
232
+ var targetClickable = this.checkIfClickable(target, cell);
233
+ if (!focusable && targetClickable) {
229
234
  var args_1 = this.cellClickArgs(cell, row, eventArg);
230
235
  if (!args_1) {
231
236
  return;