@progress/kendo-angular-utils 19.0.0-develop.17 → 19.0.0-develop.19

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.
@@ -2,7 +2,7 @@
2
2
  * Copyright © 2025 Progress Software Corporation. All rights reserved.
3
3
  * Licensed under commercial license. See LICENSE.md in the project root for more information
4
4
  *-------------------------------------------------------------------------------------------*/
5
- import { OnDestroy } from '@angular/core';
5
+ import { NgZone, OnDestroy } from '@angular/core';
6
6
  import { Subject } from 'rxjs';
7
7
  import { AdaptiveSettings } from './models/adaptive-settings';
8
8
  import { AdaptiveSettingsService } from './adaptive-settings.service';
@@ -30,13 +30,20 @@ import * as i0 from "@angular/core";
30
30
  */
31
31
  export declare class AdaptiveService implements OnDestroy {
32
32
  private _adaptiveSettings;
33
+ private zone;
33
34
  /**
34
35
  * Notifies subscribers of the initial adaptive settings, and upon each call to `notify`.
35
36
  * @hidden
36
37
  */
37
38
  readonly changes: Subject<AdaptiveSettings>;
39
+ /**
40
+ * Notifies subscribers when the window size changes to any of small, medium, or large depending on the set adaptive size breakpoints.
41
+ * @hidden
42
+ */
43
+ readonly sizeChanges: Subject<AdaptiveSize>;
38
44
  private subs;
39
- constructor(_adaptiveSettings: AdaptiveSettings, adaptiveSettingsService: AdaptiveSettingsService);
45
+ private previousSize;
46
+ constructor(_adaptiveSettings: AdaptiveSettings, adaptiveSettingsService: AdaptiveSettingsService, zone: NgZone);
40
47
  /**
41
48
  * @hidden
42
49
  */
@@ -46,6 +53,6 @@ export declare class AdaptiveService implements OnDestroy {
46
53
  */
47
54
  get size(): AdaptiveSize;
48
55
  ngOnDestroy(): void;
49
- static ɵfac: i0.ɵɵFactoryDeclaration<AdaptiveService, [{ optional: true; }, { optional: true; }]>;
56
+ static ɵfac: i0.ɵɵFactoryDeclaration<AdaptiveService, [{ optional: true; }, { optional: true; }, null]>;
50
57
  static ɵprov: i0.ɵɵInjectableDeclaration<AdaptiveService>;
51
58
  }
@@ -2,9 +2,9 @@
2
2
  * Copyright © 2025 Progress Software Corporation. All rights reserved.
3
3
  * Licensed under commercial license. See LICENSE.md in the project root for more information
4
4
  *-------------------------------------------------------------------------------------------*/
5
- import { Inject, Injectable, Optional } from '@angular/core';
6
- import { BehaviorSubject, Subscription } from 'rxjs';
7
- import { map, tap } from 'rxjs/operators';
5
+ import { Inject, Injectable, NgZone, Optional } from '@angular/core';
6
+ import { BehaviorSubject, fromEvent, Subscription } from 'rxjs';
7
+ import { filter, map, tap } from 'rxjs/operators';
8
8
  import { AdaptiveSettingsService } from './adaptive-settings.service';
9
9
  import { ADAPTIVE_SETTINGS } from './adaptive-settings';
10
10
  import { areObjectsEqual, isDocumentAvailable, isPresent } from '@progress/kendo-angular-common';
@@ -36,14 +36,22 @@ const DEFAULT_ADAPTIVE_SETTINGS = {
36
36
  */
37
37
  export class AdaptiveService {
38
38
  _adaptiveSettings;
39
+ zone;
39
40
  /**
40
41
  * Notifies subscribers of the initial adaptive settings, and upon each call to `notify`.
41
42
  * @hidden
42
43
  */
43
44
  changes = new BehaviorSubject(this.adaptiveSettings || { small: 500, medium: 700 });
45
+ /**
46
+ * Notifies subscribers when the window size changes to any of small, medium, or large depending on the set adaptive size breakpoints.
47
+ * @hidden
48
+ */
49
+ sizeChanges = new BehaviorSubject(this.size);
44
50
  subs = new Subscription();
45
- constructor(_adaptiveSettings, adaptiveSettingsService) {
51
+ previousSize;
52
+ constructor(_adaptiveSettings, adaptiveSettingsService, zone) {
46
53
  this._adaptiveSettings = _adaptiveSettings;
54
+ this.zone = zone;
47
55
  if (adaptiveSettingsService) {
48
56
  this.subs.add(adaptiveSettingsService.changes
49
57
  .pipe(map(adaptiveSettings => isPresent(adaptiveSettings) ? adaptiveSettings : this._adaptiveSettings), tap(adaptiveSettings => this._adaptiveSettings = adaptiveSettings))
@@ -52,6 +60,18 @@ export class AdaptiveService {
52
60
  if (isPresent(this.adaptiveSettings) && !areObjectsEqual(this.adaptiveSettings, DEFAULT_ADAPTIVE_SETTINGS)) {
53
61
  this.changes.next(this.adaptiveSettings);
54
62
  }
63
+ if (isDocumentAvailable()) {
64
+ this.zone.runOutsideAngular(() => {
65
+ this.subs.add(fromEvent(window, 'resize')
66
+ .pipe(tap(() => !this.previousSize && (this.previousSize = this.size)), filter(() => this.previousSize !== this.size))
67
+ .subscribe(() => {
68
+ this.previousSize = this.size;
69
+ this.zone.run(() => {
70
+ this.sizeChanges.next(this.size);
71
+ });
72
+ }));
73
+ });
74
+ }
55
75
  }
56
76
  /**
57
77
  * @hidden
@@ -80,7 +100,7 @@ export class AdaptiveService {
80
100
  ngOnDestroy() {
81
101
  this.subs.unsubscribe();
82
102
  }
83
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AdaptiveService, deps: [{ token: ADAPTIVE_SETTINGS, optional: true }, { token: i1.AdaptiveSettingsService, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
103
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AdaptiveService, deps: [{ token: ADAPTIVE_SETTINGS, optional: true }, { token: i1.AdaptiveSettingsService, optional: true }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable });
84
104
  static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AdaptiveService, providedIn: 'root' });
85
105
  }
86
106
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AdaptiveService, decorators: [{
@@ -95,4 +115,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
95
115
  args: [ADAPTIVE_SETTINGS]
96
116
  }] }, { type: i1.AdaptiveSettingsService, decorators: [{
97
117
  type: Optional
98
- }] }]; } });
118
+ }] }, { type: i0.NgZone }]; } });
@@ -10,7 +10,7 @@ export const packageMetadata = {
10
10
  productName: 'Kendo UI for Angular',
11
11
  productCode: 'KENDOUIANGULAR',
12
12
  productCodes: ['KENDOUIANGULAR'],
13
- publishDate: 1747240080,
14
- version: '19.0.0-develop.17',
13
+ publishDate: 1747399768,
14
+ version: '19.0.0-develop.19',
15
15
  licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/'
16
16
  };
@@ -8,8 +8,8 @@ import { validatePackage } from '@progress/kendo-licensing';
8
8
  import { dispatchDragAndDrop, getScrollableParent, autoScroll } from '@progress/kendo-draggable-common';
9
9
  import { PreventableEvent, contains, isDocumentAvailable, parseCSSClassNames, isPresent as isPresent$1, areObjectsEqual } from '@progress/kendo-angular-common';
10
10
  import { NgTemplateOutlet } from '@angular/common';
11
- import { Subject, BehaviorSubject, Subscription } from 'rxjs';
12
- import { map, tap } from 'rxjs/operators';
11
+ import { Subject, BehaviorSubject, Subscription, fromEvent } from 'rxjs';
12
+ import { map, tap, filter } from 'rxjs/operators';
13
13
 
14
14
  /**
15
15
  * Represents the Kendo UI DragHandle directive for Angular.
@@ -55,8 +55,8 @@ const packageMetadata = {
55
55
  productName: 'Kendo UI for Angular',
56
56
  productCode: 'KENDOUIANGULAR',
57
57
  productCodes: ['KENDOUIANGULAR'],
58
- publishDate: 1747240080,
59
- version: '19.0.0-develop.17',
58
+ publishDate: 1747399768,
59
+ version: '19.0.0-develop.19',
60
60
  licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/'
61
61
  };
62
62
 
@@ -2406,14 +2406,22 @@ const DEFAULT_ADAPTIVE_SETTINGS = {
2406
2406
  */
2407
2407
  class AdaptiveService {
2408
2408
  _adaptiveSettings;
2409
+ zone;
2409
2410
  /**
2410
2411
  * Notifies subscribers of the initial adaptive settings, and upon each call to `notify`.
2411
2412
  * @hidden
2412
2413
  */
2413
2414
  changes = new BehaviorSubject(this.adaptiveSettings || { small: 500, medium: 700 });
2415
+ /**
2416
+ * Notifies subscribers when the window size changes to any of small, medium, or large depending on the set adaptive size breakpoints.
2417
+ * @hidden
2418
+ */
2419
+ sizeChanges = new BehaviorSubject(this.size);
2414
2420
  subs = new Subscription();
2415
- constructor(_adaptiveSettings, adaptiveSettingsService) {
2421
+ previousSize;
2422
+ constructor(_adaptiveSettings, adaptiveSettingsService, zone) {
2416
2423
  this._adaptiveSettings = _adaptiveSettings;
2424
+ this.zone = zone;
2417
2425
  if (adaptiveSettingsService) {
2418
2426
  this.subs.add(adaptiveSettingsService.changes
2419
2427
  .pipe(map(adaptiveSettings => isPresent$1(adaptiveSettings) ? adaptiveSettings : this._adaptiveSettings), tap(adaptiveSettings => this._adaptiveSettings = adaptiveSettings))
@@ -2422,6 +2430,18 @@ class AdaptiveService {
2422
2430
  if (isPresent$1(this.adaptiveSettings) && !areObjectsEqual(this.adaptiveSettings, DEFAULT_ADAPTIVE_SETTINGS)) {
2423
2431
  this.changes.next(this.adaptiveSettings);
2424
2432
  }
2433
+ if (isDocumentAvailable()) {
2434
+ this.zone.runOutsideAngular(() => {
2435
+ this.subs.add(fromEvent(window, 'resize')
2436
+ .pipe(tap(() => !this.previousSize && (this.previousSize = this.size)), filter(() => this.previousSize !== this.size))
2437
+ .subscribe(() => {
2438
+ this.previousSize = this.size;
2439
+ this.zone.run(() => {
2440
+ this.sizeChanges.next(this.size);
2441
+ });
2442
+ }));
2443
+ });
2444
+ }
2425
2445
  }
2426
2446
  /**
2427
2447
  * @hidden
@@ -2450,7 +2470,7 @@ class AdaptiveService {
2450
2470
  ngOnDestroy() {
2451
2471
  this.subs.unsubscribe();
2452
2472
  }
2453
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AdaptiveService, deps: [{ token: ADAPTIVE_SETTINGS, optional: true }, { token: AdaptiveSettingsService, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
2473
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AdaptiveService, deps: [{ token: ADAPTIVE_SETTINGS, optional: true }, { token: AdaptiveSettingsService, optional: true }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable });
2454
2474
  static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AdaptiveService, providedIn: 'root' });
2455
2475
  }
2456
2476
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: AdaptiveService, decorators: [{
@@ -2465,7 +2485,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
2465
2485
  args: [ADAPTIVE_SETTINGS]
2466
2486
  }] }, { type: AdaptiveSettingsService, decorators: [{
2467
2487
  type: Optional
2468
- }] }]; } });
2488
+ }] }, { type: i0.NgZone }]; } });
2469
2489
 
2470
2490
  /**
2471
2491
  * Generated bundle index. Do not edit.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@progress/kendo-angular-utils",
3
- "version": "19.0.0-develop.17",
3
+ "version": "19.0.0-develop.19",
4
4
  "description": "Kendo UI Angular utils component",
5
5
  "license": "SEE LICENSE IN LICENSE.md",
6
6
  "author": "Progress",
@@ -19,7 +19,7 @@
19
19
  "package": {
20
20
  "productName": "Kendo UI for Angular",
21
21
  "productCode": "KENDOUIANGULAR",
22
- "publishDate": 1747240080,
22
+ "publishDate": 1747399768,
23
23
  "licensingDocsUrl": "https://www.telerik.com/kendo-angular-ui/my-license/"
24
24
  }
25
25
  },
@@ -29,12 +29,12 @@
29
29
  "@angular/core": "16 - 19",
30
30
  "@angular/platform-browser": "16 - 19",
31
31
  "@progress/kendo-licensing": "^1.5.0",
32
- "@progress/kendo-angular-common": "19.0.0-develop.17",
32
+ "@progress/kendo-angular-common": "19.0.0-develop.19",
33
33
  "rxjs": "^6.5.3 || ^7.0.0"
34
34
  },
35
35
  "dependencies": {
36
36
  "tslib": "^2.3.1",
37
- "@progress/kendo-angular-schematics": "19.0.0-develop.17",
37
+ "@progress/kendo-angular-schematics": "19.0.0-develop.19",
38
38
  "@progress/kendo-draggable-common": "^0.2.3"
39
39
  },
40
40
  "schematics": "./schematics/collection.json",