@ts-core/angular 11.0.84 → 11.0.85

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.
@@ -7328,15 +7328,17 @@
7328
7328
  // Constructor
7329
7329
  //
7330
7330
  // --------------------------------------------------------------------------
7331
- function ThemeAssetDirective(element, theme) {
7331
+ function ThemeAssetDirective(element, theme, themeAsset) {
7332
7332
  var _this = _super.call(this) || this;
7333
7333
  _this.theme = theme;
7334
+ _this.themeAsset = themeAsset;
7334
7335
  _this._extension = 'png';
7335
7336
  _this._isFile = false;
7336
7337
  _this._isImage = false;
7337
7338
  _this._isVideo = false;
7338
7339
  _this._isSound = false;
7339
7340
  _this._isBackground = false;
7341
+ _this._isIgnoreTheme = true;
7340
7342
  _this.element = ViewUtil.parseElement(element.nativeElement);
7341
7343
  _this.theme.changed.pipe(operators.takeUntil(_this.destroyed)).subscribe(function () {
7342
7344
  _this.isTriedThemeDefault = false;
@@ -7354,21 +7356,21 @@
7354
7356
  return null;
7355
7357
  }
7356
7358
  if (this.isImage) {
7357
- return asset.Assets.getImage(id, this.extension);
7359
+ return this.themeAsset.getImage(id, this.extension, this.isIgnoreTheme);
7358
7360
  }
7359
7361
  if (this.isBackground) {
7360
- return asset.Assets.getBackground(id, this.extension);
7362
+ return this.themeAsset.getBackground(id, this.extension, this.isIgnoreTheme);
7361
7363
  }
7362
7364
  if (this.isSound) {
7363
- return asset.Assets.getSound(id, this.extension);
7365
+ return this.themeAsset.getSound(id, this.extension, this.isIgnoreTheme);
7364
7366
  }
7365
7367
  if (this.isVideo) {
7366
- return asset.Assets.getVideo(id, this.extension);
7368
+ return this.themeAsset.getVideo(id, this.extension, this.isIgnoreTheme);
7367
7369
  }
7368
7370
  if (this.isFile) {
7369
- return asset.Assets.getFile(id, this.extension);
7371
+ return this.themeAsset.getFile(id, this.extension, this.isIgnoreTheme);
7370
7372
  }
7371
- return asset.Assets.getIcon(id, this.extension);
7373
+ return this.themeAsset.getIcon(id, this.extension, this.isIgnoreTheme);
7372
7374
  };
7373
7375
  // --------------------------------------------------------------------------
7374
7376
  //
@@ -7399,9 +7401,7 @@
7399
7401
  return !_.isNil(theme) ? this.name + _.capitalize(theme.name) : null;
7400
7402
  };
7401
7403
  ThemeAssetDirective.prototype.getDefaultSourceId = function (theme) {
7402
- var value = this.name;
7403
- value += theme.isDark ? 'Dark' : 'Light';
7404
- return value;
7404
+ return "" + this.name + (theme.isDark ? 'Dark' : 'Light');
7405
7405
  };
7406
7406
  // --------------------------------------------------------------------------
7407
7407
  //
@@ -7492,6 +7492,20 @@
7492
7492
  enumerable: false,
7493
7493
  configurable: true
7494
7494
  });
7495
+ Object.defineProperty(ThemeAssetDirective.prototype, "isIgnoreTheme", {
7496
+ get: function () {
7497
+ return this._isIgnoreTheme;
7498
+ },
7499
+ set: function (value) {
7500
+ if (value === this._isIgnoreTheme) {
7501
+ return;
7502
+ }
7503
+ this._isIgnoreTheme = value;
7504
+ this.setSourceProperties();
7505
+ },
7506
+ enumerable: false,
7507
+ configurable: true
7508
+ });
7495
7509
  Object.defineProperty(ThemeAssetDirective.prototype, "name", {
7496
7510
  get: function () {
7497
7511
  return this._name;
@@ -7536,6 +7550,7 @@
7536
7550
  isFile: [{ type: i0.Input }],
7537
7551
  isImage: [{ type: i0.Input }],
7538
7552
  isBackground: [{ type: i0.Input }],
7553
+ isIgnoreTheme: [{ type: i0.Input }],
7539
7554
  name: [{ type: i0.Input }],
7540
7555
  extension: [{ type: i0.Input }]
7541
7556
  };
@@ -7547,8 +7562,8 @@
7547
7562
  // Constructor
7548
7563
  //
7549
7564
  // --------------------------------------------------------------------------
7550
- function ThemeAssetBackgroundDirective(element, theme) {
7551
- return _super.call(this, element, theme) || this;
7565
+ function ThemeAssetBackgroundDirective(element, theme, themeAsset) {
7566
+ return _super.call(this, element, theme, themeAsset) || this;
7552
7567
  }
7553
7568
  // --------------------------------------------------------------------------
7554
7569
  //
@@ -7571,7 +7586,8 @@
7571
7586
  ];
7572
7587
  ThemeAssetBackgroundDirective.ctorParameters = function () { return [
7573
7588
  { type: i0.ElementRef },
7574
- { type: theme.ThemeService }
7589
+ { type: theme.ThemeService },
7590
+ { type: theme.ThemeAssetService }
7575
7591
  ]; };
7576
7592
 
7577
7593
  var ThemeAssetImageDirective = /** @class */ (function (_super) {
@@ -7581,8 +7597,8 @@
7581
7597
  // Constructor
7582
7598
  //
7583
7599
  // --------------------------------------------------------------------------
7584
- function ThemeAssetImageDirective(element, theme) {
7585
- return _super.call(this, element, theme) || this;
7600
+ function ThemeAssetImageDirective(element, theme, themeAsset) {
7601
+ return _super.call(this, element, theme, themeAsset) || this;
7586
7602
  }
7587
7603
  // --------------------------------------------------------------------------
7588
7604
  //
@@ -7604,7 +7620,8 @@
7604
7620
  ];
7605
7621
  ThemeAssetImageDirective.ctorParameters = function () { return [
7606
7622
  { type: i0.ElementRef },
7607
- { type: theme.ThemeService }
7623
+ { type: theme.ThemeService },
7624
+ { type: theme.ThemeAssetService }
7608
7625
  ]; };
7609
7626
 
7610
7627
  var ThemeToggleDirective = /** @class */ (function (_super) {
@@ -7932,6 +7949,11 @@
7932
7949
  provide: theme.ThemeService,
7933
7950
  deps: [CookieService, THEME_OPTIONS],
7934
7951
  useFactory: themeServiceFactory
7952
+ },
7953
+ {
7954
+ provide: theme.ThemeAssetService,
7955
+ deps: [theme.ThemeService],
7956
+ useFactory: themeAssetServiceFactory
7935
7957
  }
7936
7958
  ]
7937
7959
  };
@@ -7951,6 +7973,9 @@
7951
7973
  }
7952
7974
  return new theme.ThemeService(options);
7953
7975
  }
7976
+ function themeAssetServiceFactory(theme$1) {
7977
+ return new theme.ThemeAssetService(theme$1);
7978
+ }
7954
7979
  var THEME_OPTIONS = new i0.InjectionToken("THEME_OPTIONS");
7955
7980
 
7956
7981
  var WindowDragAreaDirective = /** @class */ (function (_super) {
@@ -9115,6 +9140,7 @@
9115
9140
  this._loginData = null;
9116
9141
  };
9117
9142
  LoginBaseService.prototype.parseLoginErrorResponse = function (error) { };
9143
+ LoginBaseService.prototype.parseLogoutErrorResponse = function (error) { };
9118
9144
  LoginBaseService.prototype.parseLoginSidResponse = function (response) {
9119
9145
  this._loginData = response;
9120
9146
  };
@@ -9124,6 +9150,7 @@
9124
9150
  }
9125
9151
  this.reset();
9126
9152
  };
9153
+ // public abstract registration(param: any): void;
9127
9154
  LoginBaseService.prototype.loginByResponse = function (param) {
9128
9155
  return __awaiter(this, void 0, void 0, function () {
9129
9156
  return __generator(this, function (_a) {
@@ -9159,17 +9186,38 @@
9159
9186
  return true;
9160
9187
  };
9161
9188
  LoginBaseService.prototype.logout = function () {
9162
- if (!this.isLoggedIn) {
9163
- return;
9164
- }
9165
- this.observer.next(new observer.ObservableData(common.LoadableEvent.STARTED));
9166
- this.observer.next(new observer.ObservableData(exports.LoginBaseServiceEvent.LOGOUT_STARTED));
9167
- this.logoutRequest();
9168
- this.reset();
9169
- this._isLoggedIn = false;
9170
- this.status = common.LoadableStatus.NOT_LOADED;
9171
- this.observer.next(new observer.ObservableData(common.LoadableEvent.FINISHED));
9172
- this.observer.next(new observer.ObservableData(exports.LoginBaseServiceEvent.LOGOUT_FINISHED));
9189
+ return __awaiter(this, void 0, void 0, function () {
9190
+ var error_3;
9191
+ return __generator(this, function (_a) {
9192
+ switch (_a.label) {
9193
+ case 0:
9194
+ if (!this.isLoggedIn) {
9195
+ return [2 /*return*/];
9196
+ }
9197
+ this.observer.next(new observer.ObservableData(common.LoadableEvent.STARTED));
9198
+ this.observer.next(new observer.ObservableData(exports.LoginBaseServiceEvent.LOGOUT_STARTED));
9199
+ _a.label = 1;
9200
+ case 1:
9201
+ _a.trys.push([1, 3, 4, 5]);
9202
+ return [4 /*yield*/, this.logoutRequest()];
9203
+ case 2:
9204
+ _a.sent();
9205
+ return [3 /*break*/, 5];
9206
+ case 3:
9207
+ error_3 = _a.sent();
9208
+ this.parseLogoutErrorResponse(error.ExtendedError.create(error_3));
9209
+ return [3 /*break*/, 5];
9210
+ case 4:
9211
+ this.reset();
9212
+ this._isLoggedIn = false;
9213
+ this.status = common.LoadableStatus.NOT_LOADED;
9214
+ this.observer.next(new observer.ObservableData(common.LoadableEvent.FINISHED));
9215
+ this.observer.next(new observer.ObservableData(exports.LoginBaseServiceEvent.LOGOUT_FINISHED));
9216
+ return [7 /*endfinally*/];
9217
+ case 5: return [2 /*return*/];
9218
+ }
9219
+ });
9220
+ });
9173
9221
  };
9174
9222
  LoginBaseService.prototype.isCanLoginWithSid = function () {
9175
9223
  return this.sid != null || this.getSavedSid() != null;
@@ -10737,7 +10785,7 @@
10737
10785
  }
10738
10786
  return this.user.id === value;
10739
10787
  };
10740
- UserBaseService.prototype.updateUser = function (data) {
10788
+ UserBaseService.prototype.userUpdate = function (data) {
10741
10789
  if (!this.hasUser) {
10742
10790
  return;
10743
10791
  }
@@ -10933,6 +10981,7 @@
10933
10981
  exports.cookieServiceFactory = cookieServiceFactory;
10934
10982
  exports.languageServiceFactory = languageServiceFactory;
10935
10983
  exports.loggerServiceFactory = loggerServiceFactory;
10984
+ exports.themeAssetServiceFactory = themeAssetServiceFactory;
10936
10985
  exports.themeServiceFactory = themeServiceFactory;
10937
10986
  exports.ɵa = AssetFilePipe;
10938
10987
  exports.ɵb = AssetSoundPipe;