ato-water-lib 0.0.11 → 0.0.13

Sign up to get free protection for your applications and to get access to all the features.
@@ -3226,7 +3226,8 @@ class AtoDefaultGojsEditor {
3226
3226
  get editor() {
3227
3227
  return this._editor;
3228
3228
  }
3229
- constructor() {
3229
+ constructor(_elRef) {
3230
+ this._elRef = _elRef;
3230
3231
  this.actions = [];
3231
3232
  this.actionMenuId = 'actionMenuId';
3232
3233
  this.myDiagramDiv = this.constructor.name + '-' + moment().valueOf();
@@ -3518,7 +3519,8 @@ class AtoDefaultGojsEditor {
3518
3519
  if (this.animationInterval) {
3519
3520
  clearInterval(this.animationInterval);
3520
3521
  }
3521
- this.myDiagram = this.$(go.Diagram, this.myDiagramDiv, this.initialOptions);
3522
+ const diagramDiv = this._elRef.nativeElement.querySelector(`#${this.myDiagramDiv}`);
3523
+ this.myDiagram = this.$(go.Diagram, diagramDiv, this.initialOptions);
3522
3524
  // this.myDiagram.initialPosition = new go.Point(0, 0);
3523
3525
  this.addOrRemoveCompoentTemplate();
3524
3526
  this.makeLinkTemplate();
@@ -6270,11 +6272,11 @@ class AtoDefaultGojsEditor {
6270
6272
  });
6271
6273
  }
6272
6274
  }
6273
- AtoDefaultGojsEditor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AtoDefaultGojsEditor, deps: [], target: i0.ɵɵFactoryTarget.Directive });
6275
+ AtoDefaultGojsEditor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AtoDefaultGojsEditor, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
6274
6276
  AtoDefaultGojsEditor.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.10", type: AtoDefaultGojsEditor, inputs: { linkValidation: "linkValidation", initialOptions: "initialOptions", editor: "editor", isShowNodeInfo: "isShowNodeInfo", plantSatus: "plantSatus" }, outputs: { onModelChangeListenerEvent: "onModelChangeListenerEvent", onClickInfoButton: "onClickInfoButton", onOpenWizard: "onOpenWizard", onOpenDetail: "onOpenDetail", onOpenAssetParameter: "onOpenAssetParameter", onOpenInsightMapping: "onOpenInsightMapping", onHoverInfoButton: "onHoverInfoButton", onHoverAlert: "onHoverAlert", onDoubleClickNode: "onDoubleClickNode", onOpenChangeIcon: "onOpenChangeIcon", onClickCompoent: "onClickCompoent", callbackImageTopology: "callbackImageTopology", onClikParamOfTable: "onClikParamOfTable", onDeleteNode: "onDeleteNode", onUndo: "onUndo", onRename: "onRename" }, viewQueries: [{ propertyName: "menuTrigger", first: true, predicate: ["menuTrigger"], descendants: true }], ngImport: i0 });
6275
6277
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AtoDefaultGojsEditor, decorators: [{
6276
6278
  type: Directive
6277
- }], ctorParameters: function () { return []; }, propDecorators: { menuTrigger: [{
6279
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { menuTrigger: [{
6278
6280
  type: ViewChild,
6279
6281
  args: ['menuTrigger']
6280
6282
  }], linkValidation: [{
@@ -6403,8 +6405,8 @@ class AtoFlowDiagramLibComponent extends AtoDefaultGojsEditor {
6403
6405
  get data() {
6404
6406
  return this._data;
6405
6407
  }
6406
- constructor() {
6407
- super();
6408
+ constructor(_elRef) {
6409
+ super(_elRef);
6408
6410
  this._data = null;
6409
6411
  this.isLoading = false;
6410
6412
  this.actions = [
@@ -6443,12 +6445,12 @@ class AtoFlowDiagramLibComponent extends AtoDefaultGojsEditor {
6443
6445
  this.myDiagram.select(this.myDiagram.findNodeForKey(key));
6444
6446
  }
6445
6447
  }
6446
- AtoFlowDiagramLibComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AtoFlowDiagramLibComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
6448
+ AtoFlowDiagramLibComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AtoFlowDiagramLibComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
6447
6449
  AtoFlowDiagramLibComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: AtoFlowDiagramLibComponent, selector: "ato-flow-diagram-lib", inputs: { showNotificationIcon: "showNotificationIcon", data: "data", isLoading: "isLoading" }, viewQueries: [{ propertyName: "myDiagramDivTemp", first: true, predicate: ["myDiagramDivTemp"], descendants: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"w-100 h-100 gj-flow-diagram-wrapper\" style=\"height: 100%\">\n <!-- tqlSpin [spinning]=\"data === null || !!isLoading\" -->\n <div class=\"w-100 h-100 d-flex\" style=\"height: 100%\">\n <!-- <button\n id=\"actionMenuId\"\n class=\"invisible-btn\"\n mat-button\n [matMenuTriggerFor]=\"menu\"\n #menuTrigger=\"matMenuTrigger\"\n ></button>\n <mat-menu #menu=\"matMenu\">\n <button mat-menu-item *ngFor=\"let item of actions\" (click)=\"item?.onClick($event)\">\n <div class=\"d-flex flex-gap-2\">\n <div><i class=\"{{ item?.iconClassName }}\"></i></div>\n <div>{{ item?.name }}</div>\n </div>\n </button>\n </mat-menu> -->\n\n <div #myDiagramDivTemp [id]=\"myDiagramDiv\" class=\"flex-grow-1\" style=\"height: 100%\"></div>\n <!-- <div *ngIf=\"initialOptions?.isReadOnly && !data?.nodeDataArray?.length\" class=\"empty-data\">\n <nz-empty nzNotFoundImage=\"simple\"></nz-empty>\n </div> -->\n </div>\n</div>\n", styles: [""] });
6448
6450
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AtoFlowDiagramLibComponent, decorators: [{
6449
6451
  type: Component,
6450
6452
  args: [{ selector: 'ato-flow-diagram-lib', template: "<div class=\"w-100 h-100 gj-flow-diagram-wrapper\" style=\"height: 100%\">\n <!-- tqlSpin [spinning]=\"data === null || !!isLoading\" -->\n <div class=\"w-100 h-100 d-flex\" style=\"height: 100%\">\n <!-- <button\n id=\"actionMenuId\"\n class=\"invisible-btn\"\n mat-button\n [matMenuTriggerFor]=\"menu\"\n #menuTrigger=\"matMenuTrigger\"\n ></button>\n <mat-menu #menu=\"matMenu\">\n <button mat-menu-item *ngFor=\"let item of actions\" (click)=\"item?.onClick($event)\">\n <div class=\"d-flex flex-gap-2\">\n <div><i class=\"{{ item?.iconClassName }}\"></i></div>\n <div>{{ item?.name }}</div>\n </div>\n </button>\n </mat-menu> -->\n\n <div #myDiagramDivTemp [id]=\"myDiagramDiv\" class=\"flex-grow-1\" style=\"height: 100%\"></div>\n <!-- <div *ngIf=\"initialOptions?.isReadOnly && !data?.nodeDataArray?.length\" class=\"empty-data\">\n <nz-empty nzNotFoundImage=\"simple\"></nz-empty>\n </div> -->\n </div>\n</div>\n" }]
6451
- }], ctorParameters: function () { return []; }, propDecorators: { myDiagramDivTemp: [{
6453
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { myDiagramDivTemp: [{
6452
6454
  type: ViewChild,
6453
6455
  args: ['myDiagramDivTemp']
6454
6456
  }], showNotificationIcon: [{