@c8y/ngx-components 1017.0.289 → 1017.0.290

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.
@@ -4,7 +4,7 @@ import * as i1 from '@angular/router';
4
4
  import { NavigationEnd, RouterModule as RouterModule$1, PRIMARY_OUTLET, ROUTES, RouterLinkActive, ROUTER_CONFIGURATION } from '@angular/router';
5
5
  import { merge, of, defer, combineLatest, race, isObservable, from, Subject, BehaviorSubject, NEVER, fromEvent, pipe, concat, Observable, throwError, timer, EMPTY, fromEventPattern, empty, ReplaySubject, forkJoin } from 'rxjs';
6
6
  import { filter, startWith, switchMap, map, distinctUntilChanged, shareReplay, scan, tap, catchError, takeUntil, debounceTime, first as first$1, concatMap, take, delay, retryWhen, combineLatest as combineLatest$1, mergeMap, every as every$1, toArray, merge as merge$1, debounce, share, expand, withLatestFrom, finalize } from 'rxjs/operators';
7
- import { castArray, flatten, uniq, sortBy, groupBy, camelCase, isUndefined, throttle as throttle$1, keys, get, each, mapValues, mapKeys, isString, isNaN as isNaN$1, isFinite, forEach, every, first, map as map$1, assign, memoize as memoize$1, upperFirst, property as property$1, some, find as find$1, entries, omitBy, flatMap, filter as filter$1, isEqual, snakeCase, matches, reduce, union, isEmpty, orderBy, clone, omit, pick, isEqualWith, escape as escape$1, escapeRegExp, assignWith, set as set$1, findIndex, cloneDeep, uniqBy, transform, identity, flow, isNil, chunk, without, indexOf, parseInt as parseInt$1, isFunction, kebabCase, forOwn } from 'lodash-es';
7
+ import { castArray, flatten, uniq, sortBy, groupBy, camelCase, isUndefined, throttle as throttle$1, keys, get, each, mapValues, mapKeys, isString, isNaN as isNaN$1, isFinite, forEach, every, first, map as map$1, assign, upperFirst, memoize as memoize$1, property, some, find as find$1, entries, omitBy, flatMap, filter as filter$1, isEqual, snakeCase, matches, reduce, union, isEmpty, orderBy, clone, omit, pick, isEqualWith, escape as escape$1, escapeRegExp, assignWith, set as set$1, findIndex, cloneDeep, uniqBy, transform, identity, flow, isNil, chunk, without, indexOf, parseInt as parseInt$1, isFunction, kebabCase, forOwn } from 'lodash-es';
8
8
  import * as i1$a from 'ngx-bootstrap/collapse';
9
9
  import { CollapseModule } from 'ngx-bootstrap/collapse';
10
10
  import * as i1$7 from 'ngx-bootstrap/dropdown';
@@ -31,7 +31,7 @@ import { BsDatepickerModule } from 'ngx-bootstrap/datepicker';
31
31
  import { defineLocale, enGbLocale, zhCnLocale, ruLocale, ptBrLocale, plLocale, nlLocale, koLocale, jaLocale, frLocale, esLocale, deLocale } from 'ngx-bootstrap/chronos';
32
32
  import { saveAs } from 'file-saver';
33
33
  import { coerceNumberProperty } from '@angular/cdk/coercion';
34
- import { property, get as get$1, find, negate, isUndefined as isUndefined$1, set, sortBy as sortBy$1, isEmpty as isEmpty$1, flatten as flatten$1, pick as pick$1 } from 'lodash';
34
+ import { get as get$1, find, negate, isUndefined as isUndefined$1, set, sortBy as sortBy$1, isEmpty as isEmpty$1, flatten as flatten$1, pick as pick$1 } from 'lodash';
35
35
  import * as i1$6 from '@angular/platform-browser';
36
36
  import * as i4 from '@angular/cdk/a11y';
37
37
  import { A11yModule } from '@angular/cdk/a11y';
@@ -5218,23 +5218,6 @@ var GroupFragment;
5218
5218
  GroupFragment["dynamicGroupQueryString"] = "c8y_DeviceQueryString";
5219
5219
  })(GroupFragment || (GroupFragment = {}));
5220
5220
 
5221
- /**
5222
- * Decorator to memoize function results.
5223
- * @param resolver Cache key resolver function, used by memoize from lodash.
5224
- */
5225
- function memoize(resolver) {
5226
- return (target, fnName, descriptor) => {
5227
- const fn = descriptor.value;
5228
- descriptor.value = function (...args) {
5229
- const memoizedFnName = `_${fnName}Memoized`;
5230
- if (!this[memoizedFnName]) {
5231
- this[memoizedFnName] = memoize$1(fn, resolver);
5232
- }
5233
- return this[memoizedFnName](...args);
5234
- };
5235
- };
5236
- }
5237
-
5238
5221
  const MO_TYPES = [
5239
5222
  'asset',
5240
5223
  'dynamicGroup',
@@ -5372,18 +5355,12 @@ class GroupService {
5372
5355
  }
5373
5356
  GroupService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.6", ngImport: i0, type: GroupService, deps: [{ token: AssetTypesService }], target: i0.ɵɵFactoryTarget.Injectable });
5374
5357
  GroupService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.0.6", ngImport: i0, type: GroupService, providedIn: 'root' });
5375
- __decorate([
5376
- memoize(property('id')),
5377
- __metadata("design:type", Function),
5378
- __metadata("design:paramtypes", [Object, Object]),
5379
- __metadata("design:returntype", Promise)
5380
- ], GroupService.prototype, "getIcon", null);
5381
5358
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.6", ngImport: i0, type: GroupService, decorators: [{
5382
5359
  type: Injectable,
5383
5360
  args: [{
5384
5361
  providedIn: 'root'
5385
5362
  }]
5386
- }], ctorParameters: function () { return [{ type: AssetTypesService }]; }, propDecorators: { getIcon: [] } });
5363
+ }], ctorParameters: function () { return [{ type: AssetTypesService }]; } });
5387
5364
 
5388
5365
  class GetGroupIconPipe {
5389
5366
  constructor(groupService) {
@@ -5484,6 +5461,23 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.6", ngImpor
5484
5461
  args: [{ name: 'humanize' }]
5485
5462
  }] });
5486
5463
 
5464
+ /**
5465
+ * Decorator to memoize function results.
5466
+ * @param resolver Cache key resolver function, used by memoize from lodash.
5467
+ */
5468
+ function memoize(resolver) {
5469
+ return (target, fnName, descriptor) => {
5470
+ const fn = descriptor.value;
5471
+ descriptor.value = function (...args) {
5472
+ const memoizedFnName = `_${fnName}Memoized`;
5473
+ if (!this[memoizedFnName]) {
5474
+ this[memoizedFnName] = memoize$1(fn, resolver);
5475
+ }
5476
+ return this[memoizedFnName](...args);
5477
+ };
5478
+ };
5479
+ }
5480
+
5487
5481
  class Permissions {
5488
5482
  constructor(appState, inventory, user) {
5489
5483
  this.appState = appState;
@@ -5573,13 +5567,13 @@ class Permissions {
5573
5567
  Permissions.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.6", ngImport: i0, type: Permissions, deps: [{ token: AppStateService }, { token: i1$2.InventoryService }, { token: i1$2.UserService }], target: i0.ɵɵFactoryTarget.Injectable });
5574
5568
  Permissions.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.0.6", ngImport: i0, type: Permissions });
5575
5569
  __decorate([
5576
- memoize(property$1('id')),
5570
+ memoize(property('id')),
5577
5571
  __metadata("design:type", Function),
5578
5572
  __metadata("design:paramtypes", [Object]),
5579
5573
  __metadata("design:returntype", Promise)
5580
5574
  ], Permissions.prototype, "checkIfOwner", null);
5581
5575
  __decorate([
5582
- memoize(property$1('id')),
5576
+ memoize(property('id')),
5583
5577
  __metadata("design:type", Function),
5584
5578
  __metadata("design:paramtypes", [Object]),
5585
5579
  __metadata("design:returntype", void 0)