@ardimedia/angular-portal-azure 0.2.106 → 0.2.108

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.
Files changed (3) hide show
  1. package/apn.d.ts +2 -1
  2. package/apn.js +14 -9
  3. package/package.json +4 -1
package/apn.d.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  /// <reference types="angulartics" />
2
2
  /// <reference types="angular" />
3
3
  /// <reference types="angular-resource" />
4
+ /// <reference types="angular-translate" />
4
5
  declare namespace angularportalazure {
5
6
  }
6
7
  declare namespace angularportalazure {
@@ -159,7 +160,6 @@ declare namespace angularportalazure {
159
160
  blades: Array<angularportalazure.Blade>;
160
161
  raiseAddBladeEvent(args: angularportalazure.IAddBladeEventArgs): void;
161
162
  setFirstBlade(path: string): angularportalazure.Blade;
162
- /** obsolete */
163
163
  addBlade(path: string, senderPath?: string): angularportalazure.Blade;
164
164
  clearAll(): void;
165
165
  clearPath(path: string): void;
@@ -301,6 +301,7 @@ declare namespace angularportalazure {
301
301
  $rootScope: angular.IRootScopeService;
302
302
  $window: angular.IWindowService;
303
303
  $scope: angular.IScope;
304
+ $translate: angular.translate.ITranslateService;
304
305
  }
305
306
  }
306
307
  declare namespace angularportalazure {
package/apn.js CHANGED
@@ -270,14 +270,21 @@ var angularportalazure;
270
270
  return _this;
271
271
  }
272
272
  /** OBSOLETE: end */
273
- // Register listener1
274
- _this.listener1 = that.portalService.$rootScope.$on('BladeArea.AddBlade', function (event, args) {
275
- if (that.comparePaths(args.path, that.path)) {
276
- console.log('listener1-BladeArea.AddBlade - function call: that.activate() will probably not work since this/that is not pointing to the right object. - deactivated');
273
+ //// Register listener1
274
+ //this.listener1 = that.portalService.$rootScope.$on('BladeArea.AddBlade', function (event, args: angularportalazure.IAddBladeEventArgs) {
275
+ // if (that.comparePaths(args.path, that.path)) {
276
+ // console.log('listener1-BladeArea.AddBlade - function call: that.activate() will probably not work since this/that is not pointing to the right object. - deactivated');
277
+ // //that.activate();
278
+ // }
279
+ //});
280
+ //#endregion
281
+ // Set this object to be the one, which was generated during AddBlade
282
+ _this.portalService.bladeArea.blades.forEach(function (blade, index) {
283
+ if (blade.path === _this.path) {
284
+ _this.portalService.bladeArea.blades[index] = _this;
277
285
  }
278
286
  });
279
287
  return _this;
280
- //#endregion
281
288
  }
282
289
  Object.defineProperty(Blade.prototype, "path", {
283
290
  //#region path
@@ -466,6 +473,7 @@ var angularportalazure;
466
473
  //#region Add BladeArea.AddBlade event listener
467
474
  /** OBSOLETE: remove when all OBSOLETE code has been removed */
468
475
  if (portalService instanceof angularportalazure.PortalService == false) {
476
+ console.log('BladeArea.constructor: This code cannot be removed yet.');
469
477
  return _this;
470
478
  }
471
479
  /** OBSOLETE: end */
@@ -482,9 +490,6 @@ var angularportalazure;
482
490
  var isActivated = false;
483
491
  this.blades.forEach(function (blade) {
484
492
  if (blade.path === args.path) {
485
- console.log('executing: blade.onActivate();');
486
- console.log(blade.activate);
487
- console.log(blade);
488
493
  blade.onActivate();
489
494
  isActivated = true;
490
495
  return;
@@ -500,7 +505,6 @@ var angularportalazure;
500
505
  this.hidePanorama();
501
506
  return this.addBlade(path);
502
507
  };
503
- /** obsolete */
504
508
  BladeArea.prototype.addBlade = function (path, senderPath) {
505
509
  if (senderPath === void 0) { senderPath = ''; }
506
510
  if (path == null) {
@@ -907,6 +911,7 @@ var angularportalazure;
907
911
  this.$rootScope = $injector.get('$rootScope');
908
912
  this.$window = $injector.get('$window');
909
913
  this.$analytics = $injector.get('$analytics');
914
+ this.$translate = $injector.get('$translate');
910
915
  this.ngDialog = $injector.get('ngDialog');
911
916
  this.ngDialog.openConfirm;
912
917
  }
package/package.json CHANGED
@@ -2,12 +2,14 @@
2
2
  "name": "@ardimedia/angular-portal-azure",
3
3
  "description": "Angular Portal Azure - GUI Framework.",
4
4
  "author": "Ardimedia Anstalt <info@ardimedia.com> (http://www.ardimedia.com)",
5
- "version": "0.2.106",
5
+ "version": "0.2.108",
6
6
  "main": "index.js",
7
7
  "typings": "apn.d.ts",
8
8
  "dependencies": {
9
9
  "angular": "^1.6.0",
10
10
  "angular-resource": "^1.6.0",
11
+ "angular-translate": "^2.13.1",
12
+ "angular-translate-storage-cookie": "^2.13.1",
11
13
  "angulartics": "^1.3.0",
12
14
  "angulartics-google-analytics": "^0.4.0",
13
15
  "ng-dialog": "^0.6.4"
@@ -15,6 +17,7 @@
15
17
  "devDependencies": {
16
18
  "@types/angular": "^1.5.21",
17
19
  "@types/angular-resource": "^1.5.8",
20
+ "@types/angular-translate": "^2.4.34",
18
21
  "@types/angulartics": "^1.3.0",
19
22
  "@types/ng-dialog": "^0.6.0",
20
23
  "typescript": "^2.1.4"