@metadev/daga 1.5.5 → 1.5.7

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.
@@ -150,52 +150,52 @@ class CollapseButtonComponent {
150
150
  switch (this.direction) {
151
151
  case Side.Right:
152
152
  if (this.disabled) {
153
- return 'horizontal-none';
153
+ return 'daga-horizontal-none';
154
154
  }
155
155
  else if (this.collapsed) {
156
- return 'horizontal-right';
156
+ return 'daga-horizontal-right';
157
157
  }
158
158
  else {
159
- return 'horizontal-left';
159
+ return 'daga-horizontal-left';
160
160
  }
161
161
  case Side.Bottom:
162
162
  if (this.disabled) {
163
- return 'vertical-none';
163
+ return 'daga-vertical-none';
164
164
  }
165
165
  else if (this.collapsed) {
166
- return 'vertical-down';
166
+ return 'daga-vertical-down';
167
167
  }
168
168
  else {
169
- return 'vertical-up';
169
+ return 'daga-vertical-up';
170
170
  }
171
171
  case Side.Left:
172
172
  if (this.disabled) {
173
- return 'horizontal-none';
173
+ return 'daga-horizontal-none';
174
174
  }
175
175
  else if (this.collapsed) {
176
- return 'horizontal-left';
176
+ return 'daga-horizontal-left';
177
177
  }
178
178
  else {
179
- return 'horizontal-right';
179
+ return 'daga-horizontal-right';
180
180
  }
181
181
  case Side.Top:
182
182
  if (this.disabled) {
183
- return 'vertical-none';
183
+ return 'daga-vertical-none';
184
184
  }
185
185
  else if (this.collapsed) {
186
- return 'vertical-up';
186
+ return 'daga-vertical-up';
187
187
  }
188
188
  else {
189
- return 'vertical-down';
189
+ return 'daga-vertical-down';
190
190
  }
191
191
  }
192
192
  }
193
193
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: CollapseButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
194
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: CollapseButtonComponent, isStandalone: true, selector: "daga-collapse-button", inputs: { collapsableSelector: "collapsableSelector", collapsableAdditionalSelector: "collapsableAdditionalSelector", collapsed: "collapsed", disabled: "disabled", direction: "direction", rule: "rule", collapsedValue: "collapsedValue", visibleValue: "visibleValue" }, ngImport: i0, template: "<button class=\"collapse-button {{ direction }}\" (click)=\"toggleCollapse()\">\n <div [class]=\"getClass()\"></div>\n</button>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }] }); }
194
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: CollapseButtonComponent, isStandalone: true, selector: "daga-collapse-button", inputs: { collapsableSelector: "collapsableSelector", collapsableAdditionalSelector: "collapsableAdditionalSelector", collapsed: "collapsed", disabled: "disabled", direction: "direction", rule: "rule", collapsedValue: "collapsedValue", visibleValue: "visibleValue" }, ngImport: i0, template: "<button\r\n class=\"daga-collapse-button daga-{{ direction }}\"\r\n (click)=\"toggleCollapse()\"\r\n>\r\n <div [class]=\"getClass()\"></div>\r\n</button>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }] }); }
195
195
  }
196
196
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: CollapseButtonComponent, decorators: [{
197
197
  type: Component,
198
- args: [{ standalone: true, selector: 'daga-collapse-button', imports: [CommonModule], template: "<button class=\"collapse-button {{ direction }}\" (click)=\"toggleCollapse()\">\n <div [class]=\"getClass()\"></div>\n</button>\n" }]
198
+ args: [{ standalone: true, selector: 'daga-collapse-button', imports: [CommonModule], template: "<button\r\n class=\"daga-collapse-button daga-{{ direction }}\"\r\n (click)=\"toggleCollapse()\"\r\n>\r\n <div [class]=\"getClass()\"></div>\r\n</button>\r\n" }]
199
199
  }], propDecorators: { collapsableSelector: [{
200
200
  type: Input
201
201
  }], collapsableAdditionalSelector: [{
@@ -655,60 +655,6 @@ const addIfNotExists = (arr, obj) => {
655
655
  return arr;
656
656
  };
657
657
 
658
- /**
659
- * Default priority value for diagram elements.
660
- * @private
661
- */
662
- const DEFAULT_PRIORITY = 0;
663
- /**
664
- * Represents an object which exists as part of a specific diagram model and has a visual representation in a diagram canvas.
665
- * @public
666
- * @see DiagramModel
667
- * @see DiagramCanvas
668
- */
669
- class DiagramElement {
670
- get id() {
671
- return this._id;
672
- }
673
- constructor(model, id) {
674
- /**
675
- * Whether this diagram element is currently highlighted by the user.
676
- * @private
677
- */
678
- this.highlighted = false;
679
- /**
680
- * Whether this diagram element is currently selected by the user.
681
- * @private
682
- */
683
- this.selected = false;
684
- /**
685
- * Whether this diagram element has itself been explicitly removed.
686
- *
687
- * Override the `removed` getter so that it returns true if and only if:
688
- * - `selfRemoved` is true, or
689
- * - `removed` is true for any of this element's dependencies.
690
- *
691
- * For example, a DiagramConnection is removed if either of its ports are removed,
692
- * even if the connection's own `selfRemoved` field is false.
693
- * @private
694
- */
695
- this.selfRemoved = false;
696
- /**
697
- * Collaborative timestamp for selfRemoved.
698
- * @private
699
- */
700
- this.selfRemovedTimestamp = null;
701
- this.model = model;
702
- this._id = id;
703
- }
704
- /**
705
- * Obtain the selection of this element.
706
- * @private
707
- */
708
- select() {
709
- return this.model.canvas?.selectCanvasView()?.select(`g#${this.id}`);
710
- }
711
- }
712
658
  /**
713
659
  * Represents a collection of diagram entities of a type that exists as part of a diagram model.
714
660
  * @public
@@ -729,11 +675,11 @@ class DiagramEntitySet {
729
675
  this.entityMap = {};
730
676
  }
731
677
  /**
732
- * The number of entities of this set.
678
+ * The number of entities in this set.
733
679
  * @public
734
680
  */
735
681
  get length() {
736
- return this.entities.length;
682
+ return this.size();
737
683
  }
738
684
  /**
739
685
  * Gets all of the entities of this set.
@@ -774,6 +720,14 @@ class DiagramEntitySet {
774
720
  contains(id) {
775
721
  return this.entityMap[id] !== undefined;
776
722
  }
723
+ /**
724
+ * Counts the number of entities of this set following the given criteria.
725
+ * @public
726
+ * @returns The number of entities of this set following the given criteria.
727
+ */
728
+ count(predicate) {
729
+ return this.entities.filter(predicate).length;
730
+ }
777
731
  /**
778
732
  * Gets all of the entities of this set filtered following given criteria.
779
733
  * @public
@@ -799,6 +753,14 @@ class DiagramEntitySet {
799
753
  get(id) {
800
754
  return this.entityMap[id];
801
755
  }
756
+ /**
757
+ * Gets all of the entities of this set mapped to the result of the given function applied to them.
758
+ * @public
759
+ * @returns An array containing the entities of this set that meet the given criteria.
760
+ */
761
+ map(callback) {
762
+ return this.entities.map(callback);
763
+ }
802
764
  /**
803
765
  * Attempts to find and remove an entity with the given id. Has no effect if there are no entities with the given id.
804
766
  * @public
@@ -811,15 +773,159 @@ class DiagramEntitySet {
811
773
  removeIfExists(this.entities, entity);
812
774
  }
813
775
  }
776
+ /**
777
+ * Gets the number of entities in this set.
778
+ * @public
779
+ */
780
+ size() {
781
+ return this.entities.length;
782
+ }
814
783
  /**
815
784
  * Iterator to iterate over the entities of this set.
816
785
  * @public
817
786
  */
818
787
  *[Symbol.iterator]() {
819
- let counter = 0;
820
- while (counter < this.entities.length) {
821
- yield this.entities[counter];
822
- ++counter;
788
+ for (const entity of this.entities) {
789
+ yield entity;
790
+ }
791
+ }
792
+ }
793
+
794
+ /**
795
+ * Default priority value for diagram elements.
796
+ * @private
797
+ */
798
+ const DEFAULT_PRIORITY = 0;
799
+ /**
800
+ * Represents an object which exists as part of a specific diagram model and has a visual representation in a diagram canvas.
801
+ * @public
802
+ * @see DiagramModel
803
+ * @see DiagramCanvas
804
+ */
805
+ class DiagramElement {
806
+ get id() {
807
+ return this._id;
808
+ }
809
+ constructor(model, id) {
810
+ /**
811
+ * Whether this diagram element is currently highlighted by the user.
812
+ * @private
813
+ */
814
+ this.highlighted = false;
815
+ /**
816
+ * Whether this diagram element is currently selected by the user.
817
+ * @private
818
+ */
819
+ this.selected = false;
820
+ /**
821
+ * Whether this diagram element has itself been explicitly removed.
822
+ *
823
+ * Override the `removed` getter so that it returns true if and only if:
824
+ * - `selfRemoved` is true, or
825
+ * - `removed` is true for any of this element's dependencies.
826
+ *
827
+ * For example, a DiagramConnection is removed if either of its ports are removed,
828
+ * even if the connection's own `selfRemoved` field is false.
829
+ * @private
830
+ */
831
+ this.selfRemoved = false;
832
+ /**
833
+ * Collaborative timestamp for selfRemoved.
834
+ * @private
835
+ */
836
+ this.selfRemovedTimestamp = null;
837
+ this.model = model;
838
+ this._id = id;
839
+ }
840
+ /**
841
+ * Obtain the selection of this element.
842
+ * @private
843
+ */
844
+ select() {
845
+ return this.model.canvas?.selectCanvasView()?.select(`g#${this.id}`);
846
+ }
847
+ }
848
+ class DiagramElementSet extends DiagramEntitySet {
849
+ all(includeRemoved = false) {
850
+ if (includeRemoved) {
851
+ return super.all();
852
+ }
853
+ else {
854
+ return super.filter((e) => !e.removed);
855
+ }
856
+ }
857
+ contains(id, includeRemoved = false) {
858
+ if (includeRemoved) {
859
+ return super.contains(id);
860
+ }
861
+ else {
862
+ return super.contains(id) && !this.entityMap[id].removed;
863
+ }
864
+ }
865
+ count(predicate, includeRemoved = false) {
866
+ if (includeRemoved) {
867
+ return super.count(predicate);
868
+ }
869
+ else {
870
+ return super.count((e, i, a) => predicate(e, i, a) && !e.removed);
871
+ }
872
+ }
873
+ filter(predicate, includeRemoved = false) {
874
+ if (includeRemoved) {
875
+ return super.filter(predicate);
876
+ }
877
+ else {
878
+ return super.filter((e, i, a) => predicate(e, i, a) && !e.removed);
879
+ }
880
+ }
881
+ find(predicate, includeRemoved = false) {
882
+ if (includeRemoved) {
883
+ return super.find(predicate);
884
+ }
885
+ else {
886
+ return super.find((e, i, a) => predicate(e, i, a) && !e.removed);
887
+ }
888
+ }
889
+ get(id, includeRemoved = false) {
890
+ if (includeRemoved) {
891
+ return super.get(id);
892
+ }
893
+ else {
894
+ return super.contains(id) && !this.entityMap[id].removed
895
+ ? super.get(id)
896
+ : undefined;
897
+ }
898
+ }
899
+ map(callback, includeRemoved = false) {
900
+ if (includeRemoved) {
901
+ return super.map(callback);
902
+ }
903
+ else {
904
+ return super.filter((e) => !e.removed).map(callback);
905
+ }
906
+ }
907
+ /**
908
+ * Gets the number of entities in this set.
909
+ * @public
910
+ */
911
+ size(includeRemoved = false) {
912
+ if (includeRemoved) {
913
+ return super.size();
914
+ }
915
+ else {
916
+ return super.filter((e) => !e.removed).length;
917
+ }
918
+ }
919
+ *[Symbol.iterator](includeRemoved = false) {
920
+ if (includeRemoved) {
921
+ for (const entity of this.entities) {
922
+ yield entity;
923
+ }
924
+ }
925
+ else {
926
+ for (const entity of this.entities.filter((e) => !e.removed)) {
927
+ yield entity;
928
+ }
823
929
  }
824
930
  }
825
931
  }
@@ -1692,7 +1798,7 @@ class DiagramConnection extends DiagramElement {
1692
1798
  }
1693
1799
  }
1694
1800
  }
1695
- class DiagramConnectionSet extends DiagramEntitySet {
1801
+ class DiagramConnectionSet extends DiagramElementSet {
1696
1802
  /**
1697
1803
  * Instance a set of connections for the given model. This method is used internally.
1698
1804
  * @private
@@ -2263,10 +2369,13 @@ class DiagramSection extends DiagramElement {
2263
2369
  * @public
2264
2370
  * @returns A list of connections.
2265
2371
  */
2266
- getIncomingConnections() {
2372
+ getIncomingConnections(includeRemoved = false) {
2267
2373
  const result = [];
2268
2374
  for (const port of this.ports) {
2269
2375
  for (const incomingConnection of port.incomingConnections) {
2376
+ if (!includeRemoved && incomingConnection.removed) {
2377
+ continue;
2378
+ }
2270
2379
  result.push(incomingConnection);
2271
2380
  }
2272
2381
  }
@@ -2277,10 +2386,13 @@ class DiagramSection extends DiagramElement {
2277
2386
  * @public
2278
2387
  * @returns A list of connections.
2279
2388
  */
2280
- getOutgoingConnections() {
2389
+ getOutgoingConnections(includeRemoved = false) {
2281
2390
  const result = [];
2282
2391
  for (const port of this.ports) {
2283
2392
  for (const outgoingConnection of port.outgoingConnections) {
2393
+ if (!includeRemoved && outgoingConnection.removed) {
2394
+ continue;
2395
+ }
2284
2396
  result.push(outgoingConnection);
2285
2397
  }
2286
2398
  }
@@ -2291,13 +2403,19 @@ class DiagramSection extends DiagramElement {
2291
2403
  * @public
2292
2404
  * @returns A list of connections.
2293
2405
  */
2294
- getConnections() {
2406
+ getConnections(includeRemoved = false) {
2295
2407
  const result = [];
2296
2408
  for (const port of this.ports) {
2297
2409
  for (const incomingConnection of port.incomingConnections) {
2410
+ if (!includeRemoved && incomingConnection.removed) {
2411
+ continue;
2412
+ }
2298
2413
  result.push(incomingConnection);
2299
2414
  }
2300
2415
  for (const outgoingConnection of port.outgoingConnections) {
2416
+ if (!includeRemoved && outgoingConnection.removed) {
2417
+ continue;
2418
+ }
2301
2419
  result.push(outgoingConnection);
2302
2420
  }
2303
2421
  }
@@ -2392,13 +2510,17 @@ class DiagramSection extends DiagramElement {
2392
2510
  // Set label's dimensions as a function of ours.
2393
2511
  if (this.label) {
2394
2512
  this.label.coords = [
2395
- this.coords[0] + (this.getConfig()?.label?.margin || 0),
2396
- this.coords[1] + (this.getConfig()?.label?.margin || 0)
2513
+ this.coords[0] + getLeftMargin(this.getConfig()?.label),
2514
+ this.coords[1] + getTopMargin(this.getConfig()?.label)
2397
2515
  ];
2398
- (this.label.width =
2399
- this.width - (this.getConfig()?.label?.margin || 0) * 2),
2400
- (this.label.height =
2401
- this.height - (this.getConfig()?.label?.margin || 0) * 2);
2516
+ this.label.width =
2517
+ this.width -
2518
+ getLeftMargin(this.getConfig()?.label) -
2519
+ getRightMargin(this.getConfig()?.label);
2520
+ this.label.height =
2521
+ this.height -
2522
+ getTopMargin(this.getConfig()?.label) -
2523
+ getBottomMargin(this.getConfig()?.label);
2402
2524
  this.label.updateInView();
2403
2525
  }
2404
2526
  // Move decorators to match the new coords.
@@ -2410,7 +2532,7 @@ class DiagramSection extends DiagramElement {
2410
2532
  this.updateInView();
2411
2533
  }
2412
2534
  }
2413
- class DiagramSectionSet extends DiagramEntitySet {
2535
+ class DiagramSectionSet extends DiagramElementSet {
2414
2536
  /**
2415
2537
  * Instance a set of sections for the given model. This method is used internally.
2416
2538
  * @private
@@ -2480,9 +2602,13 @@ class DiagramSectionSet extends DiagramEntitySet {
2480
2602
  ...sectionLabel
2481
2603
  };
2482
2604
  this.model.fields.new(section, [
2483
- section.coords[0] + labelConfiguration.margin,
2484
- section.coords[1] + labelConfiguration.margin
2485
- ], labelConfiguration.fontSize, labelConfiguration.fontFamily, labelConfiguration.color, labelConfiguration.selectedColor, section.width - labelConfiguration.margin * 2, section.height - labelConfiguration.margin * 2, labelConfiguration.horizontalAlign, labelConfiguration.verticalAlign, '', labelConfiguration.editable, labelConfiguration.fit);
2605
+ section.coords[0] + getLeftMargin(labelConfiguration),
2606
+ section.coords[1] + getTopMargin(labelConfiguration)
2607
+ ], labelConfiguration.fontSize, labelConfiguration.fontFamily, labelConfiguration.color, labelConfiguration.selectedColor, section.width -
2608
+ getLeftMargin(labelConfiguration) -
2609
+ getRightMargin(labelConfiguration), section.height -
2610
+ getTopMargin(labelConfiguration) -
2611
+ getBottomMargin(labelConfiguration), labelConfiguration.horizontalAlign, labelConfiguration.verticalAlign, '', labelConfiguration.editable, labelConfiguration.fit);
2486
2612
  }
2487
2613
  return section;
2488
2614
  }
@@ -2656,10 +2782,13 @@ class DiagramNode extends DiagramElement {
2656
2782
  * @public
2657
2783
  * @returns A list of connections.
2658
2784
  */
2659
- getIncomingConnections() {
2785
+ getIncomingConnections(includeRemoved = false) {
2660
2786
  const result = [];
2661
2787
  for (const port of this.ports) {
2662
2788
  for (const incomingConnection of port.incomingConnections) {
2789
+ if (!includeRemoved && incomingConnection.removed) {
2790
+ continue;
2791
+ }
2663
2792
  result.push(incomingConnection);
2664
2793
  }
2665
2794
  }
@@ -2670,10 +2799,13 @@ class DiagramNode extends DiagramElement {
2670
2799
  * @public
2671
2800
  * @returns A list of connections.
2672
2801
  */
2673
- getOutgoingConnections() {
2802
+ getOutgoingConnections(includeRemoved = false) {
2674
2803
  const result = [];
2675
2804
  for (const port of this.ports) {
2676
2805
  for (const outgoingConnection of port.outgoingConnections) {
2806
+ if (!includeRemoved && outgoingConnection.removed) {
2807
+ continue;
2808
+ }
2677
2809
  result.push(outgoingConnection);
2678
2810
  }
2679
2811
  }
@@ -2684,13 +2816,19 @@ class DiagramNode extends DiagramElement {
2684
2816
  * @public
2685
2817
  * @returns A list of connections.
2686
2818
  */
2687
- getConnections() {
2819
+ getConnections(includeRemoved = false) {
2688
2820
  const result = [];
2689
2821
  for (const port of this.ports) {
2690
2822
  for (const incomingConnection of port.incomingConnections) {
2823
+ if (!includeRemoved && incomingConnection.removed) {
2824
+ continue;
2825
+ }
2691
2826
  result.push(incomingConnection);
2692
2827
  }
2693
2828
  for (const outgoingConnection of port.outgoingConnections) {
2829
+ if (!includeRemoved && outgoingConnection.removed) {
2830
+ continue;
2831
+ }
2694
2832
  result.push(outgoingConnection);
2695
2833
  }
2696
2834
  }
@@ -2701,18 +2839,30 @@ class DiagramNode extends DiagramElement {
2701
2839
  * @public
2702
2840
  * @returns A list of nodes.
2703
2841
  */
2704
- getAdjacentNodes() {
2842
+ getAdjacentNodes(includeRemoved = false) {
2705
2843
  const result = [];
2706
2844
  for (const port of this.ports) {
2707
2845
  for (const incomingConnection of port.incomingConnections) {
2846
+ if (!includeRemoved && incomingConnection.removed) {
2847
+ continue;
2848
+ }
2708
2849
  const otherNode = incomingConnection.start?.getNode();
2709
2850
  if (otherNode) {
2851
+ if (!includeRemoved && otherNode.removed) {
2852
+ continue;
2853
+ }
2710
2854
  result.push(otherNode);
2711
2855
  }
2712
2856
  }
2713
2857
  for (const outgoingConnection of port.outgoingConnections) {
2858
+ if (!includeRemoved && outgoingConnection.removed) {
2859
+ continue;
2860
+ }
2714
2861
  const otherNode = outgoingConnection.end?.getNode();
2715
2862
  if (otherNode) {
2863
+ if (!includeRemoved && otherNode.removed) {
2864
+ continue;
2865
+ }
2716
2866
  result.push(otherNode);
2717
2867
  }
2718
2868
  }
@@ -2920,11 +3070,17 @@ class DiagramNode extends DiagramElement {
2920
3070
  // Set label's dimensions as a function of ours.
2921
3071
  if (this.label) {
2922
3072
  this.label.coords = [
2923
- this.coords[0] + (this.type.label?.margin || 0),
2924
- this.coords[1] + (this.type.label?.margin || 0)
3073
+ this.coords[0] + getLeftMargin(this.type.label),
3074
+ this.coords[1] + getTopMargin(this.type.label)
2925
3075
  ];
2926
- (this.label.width = this.width - (this.type.label?.margin || 0) * 2),
2927
- (this.label.height = this.height - (this.type.label?.margin || 0) * 2);
3076
+ this.label.width =
3077
+ this.width -
3078
+ getLeftMargin(this.type.label) -
3079
+ getRightMargin(this.type.label);
3080
+ this.label.height =
3081
+ this.height -
3082
+ getTopMargin(this.type.label) -
3083
+ getBottomMargin(this.type.label);
2928
3084
  this.label.updateInView();
2929
3085
  }
2930
3086
  // Move decorators to match the new coords.
@@ -2936,7 +3092,7 @@ class DiagramNode extends DiagramElement {
2936
3092
  this.updateInView();
2937
3093
  }
2938
3094
  }
2939
- class DiagramNodeSet extends DiagramEntitySet {
3095
+ class DiagramNodeSet extends DiagramElementSet {
2940
3096
  /**
2941
3097
  * Instance a set of nodes for the given model. This method is used internally.
2942
3098
  * @private
@@ -3042,9 +3198,13 @@ class DiagramNodeSet extends DiagramEntitySet {
3042
3198
  ...nodeType.label
3043
3199
  };
3044
3200
  this.model.fields.new(node, [
3045
- node.coords[0] + labelConfiguration.margin,
3046
- node.coords[1] + labelConfiguration.margin
3047
- ], labelConfiguration.fontSize, labelConfiguration.fontFamily, labelConfiguration.color, labelConfiguration.selectedColor, node.width - labelConfiguration.margin * 2, node.height - labelConfiguration.margin * 2, labelConfiguration.horizontalAlign, labelConfiguration.verticalAlign, '', labelConfiguration.editable, labelConfiguration.fit);
3201
+ node.coords[0] + getLeftMargin(labelConfiguration),
3202
+ node.coords[1] + getTopMargin(labelConfiguration)
3203
+ ], labelConfiguration.fontSize, labelConfiguration.fontFamily, labelConfiguration.color, labelConfiguration.selectedColor, node.width -
3204
+ getLeftMargin(labelConfiguration) -
3205
+ getRightMargin(labelConfiguration), node.height -
3206
+ getTopMargin(labelConfiguration) -
3207
+ getBottomMargin(labelConfiguration), labelConfiguration.horizontalAlign, labelConfiguration.verticalAlign, '', labelConfiguration.editable, labelConfiguration.fit);
3048
3208
  }
3049
3209
  node.valueSet.resetValues();
3050
3210
  node.model.canvas?.fitNodeInView(node.id);
@@ -3183,7 +3343,7 @@ class DiagramPort extends DiagramElement {
3183
3343
  return distanceBetweenPoints(this.coords, coords);
3184
3344
  }
3185
3345
  }
3186
- class DiagramPortSet extends DiagramEntitySet {
3346
+ class DiagramPortSet extends DiagramElementSet {
3187
3347
  /**
3188
3348
  * Instance a set of ports for the given model. This method is used internally.
3189
3349
  * @private
@@ -3326,7 +3486,7 @@ class DiagramField extends DiagramElement {
3326
3486
  return this.rootElement?.getPriority() || DEFAULT_PRIORITY;
3327
3487
  }
3328
3488
  }
3329
- class DiagramFieldSet extends DiagramEntitySet {
3489
+ class DiagramFieldSet extends DiagramElementSet {
3330
3490
  /**
3331
3491
  * Instance a set of fields for the given model. This method is used internally.
3332
3492
  * @private
@@ -3367,6 +3527,206 @@ class DiagramFieldSet extends DiagramEntitySet {
3367
3527
  }
3368
3528
  }
3369
3529
  }
3530
+ const getBottomMargin = (config) => {
3531
+ if (config?.margin === null || config?.margin === undefined) {
3532
+ return DIAGRAM_FIELD_DEFAULTS.margin;
3533
+ }
3534
+ else if (typeof config.margin === 'number') {
3535
+ return config.margin;
3536
+ }
3537
+ else {
3538
+ if (config.margin.length === 0) {
3539
+ return DIAGRAM_FIELD_DEFAULTS.margin;
3540
+ }
3541
+ else if (config.margin.length === 1) {
3542
+ return config.margin[0];
3543
+ }
3544
+ else if (config.margin.length === 2) {
3545
+ return config.margin[0];
3546
+ }
3547
+ else if (config.margin.length === 3) {
3548
+ return config.margin[2];
3549
+ }
3550
+ else {
3551
+ return config.margin[2];
3552
+ }
3553
+ }
3554
+ };
3555
+ const getLeftMargin = (config) => {
3556
+ if (config?.margin === null || config?.margin === undefined) {
3557
+ return DIAGRAM_FIELD_DEFAULTS.margin;
3558
+ }
3559
+ else if (typeof config.margin === 'number') {
3560
+ return config.margin;
3561
+ }
3562
+ else {
3563
+ if (config.margin.length === 0) {
3564
+ return DIAGRAM_FIELD_DEFAULTS.margin;
3565
+ }
3566
+ else if (config.margin.length === 1) {
3567
+ return config.margin[0];
3568
+ }
3569
+ else if (config.margin.length === 2) {
3570
+ return config.margin[1];
3571
+ }
3572
+ else if (config.margin.length === 3) {
3573
+ return config.margin[1];
3574
+ }
3575
+ else {
3576
+ return config.margin[3];
3577
+ }
3578
+ }
3579
+ };
3580
+ const getRightMargin = (config) => {
3581
+ if (config?.margin === null || config?.margin === undefined) {
3582
+ return DIAGRAM_FIELD_DEFAULTS.margin;
3583
+ }
3584
+ else if (typeof config.margin === 'number') {
3585
+ return config.margin;
3586
+ }
3587
+ else {
3588
+ if (config.margin.length === 0) {
3589
+ return DIAGRAM_FIELD_DEFAULTS.margin;
3590
+ }
3591
+ else if (config.margin.length === 1) {
3592
+ return config.margin[0];
3593
+ }
3594
+ else if (config.margin.length === 2) {
3595
+ return config.margin[1];
3596
+ }
3597
+ else if (config.margin.length === 3) {
3598
+ return config.margin[1];
3599
+ }
3600
+ else {
3601
+ return config.margin[1];
3602
+ }
3603
+ }
3604
+ };
3605
+ const getTopMargin = (config) => {
3606
+ if (config?.margin === null || config?.margin === undefined) {
3607
+ return DIAGRAM_FIELD_DEFAULTS.margin;
3608
+ }
3609
+ else if (typeof config.margin === 'number') {
3610
+ return config.margin;
3611
+ }
3612
+ else {
3613
+ if (config.margin.length === 0) {
3614
+ return DIAGRAM_FIELD_DEFAULTS.margin;
3615
+ }
3616
+ else if (config.margin.length === 1) {
3617
+ return config.margin[0];
3618
+ }
3619
+ else if (config.margin.length === 2) {
3620
+ return config.margin[0];
3621
+ }
3622
+ else if (config.margin.length === 3) {
3623
+ return config.margin[0];
3624
+ }
3625
+ else {
3626
+ return config.margin[0];
3627
+ }
3628
+ }
3629
+ };
3630
+ const getBottomPadding = (config) => {
3631
+ if (config?.padding === null || config?.padding === undefined) {
3632
+ return DIAGRAM_FIELD_DEFAULTS.padding;
3633
+ }
3634
+ else if (typeof config.padding === 'number') {
3635
+ return config.padding;
3636
+ }
3637
+ else {
3638
+ if (config.padding.length === 0) {
3639
+ return DIAGRAM_FIELD_DEFAULTS.padding;
3640
+ }
3641
+ else if (config.padding.length === 1) {
3642
+ return config.padding[0];
3643
+ }
3644
+ else if (config.padding.length === 2) {
3645
+ return config.padding[0];
3646
+ }
3647
+ else if (config.padding.length === 3) {
3648
+ return config.padding[2];
3649
+ }
3650
+ else {
3651
+ return config.padding[2];
3652
+ }
3653
+ }
3654
+ };
3655
+ const getLeftPadding = (config) => {
3656
+ if (config?.padding === null || config?.padding === undefined) {
3657
+ return DIAGRAM_FIELD_DEFAULTS.padding;
3658
+ }
3659
+ else if (typeof config.padding === 'number') {
3660
+ return config.padding;
3661
+ }
3662
+ else {
3663
+ if (config.padding.length === 0) {
3664
+ return DIAGRAM_FIELD_DEFAULTS.padding;
3665
+ }
3666
+ else if (config.padding.length === 1) {
3667
+ return config.padding[0];
3668
+ }
3669
+ else if (config.padding.length === 2) {
3670
+ return config.padding[1];
3671
+ }
3672
+ else if (config.padding.length === 3) {
3673
+ return config.padding[1];
3674
+ }
3675
+ else {
3676
+ return config.padding[3];
3677
+ }
3678
+ }
3679
+ };
3680
+ const getRightPadding = (config) => {
3681
+ if (config?.padding === null || config?.padding === undefined) {
3682
+ return DIAGRAM_FIELD_DEFAULTS.padding;
3683
+ }
3684
+ else if (typeof config.padding === 'number') {
3685
+ return config.padding;
3686
+ }
3687
+ else {
3688
+ if (config.padding.length === 0) {
3689
+ return DIAGRAM_FIELD_DEFAULTS.padding;
3690
+ }
3691
+ else if (config.padding.length === 1) {
3692
+ return config.padding[0];
3693
+ }
3694
+ else if (config.padding.length === 2) {
3695
+ return config.padding[1];
3696
+ }
3697
+ else if (config.padding.length === 3) {
3698
+ return config.padding[1];
3699
+ }
3700
+ else {
3701
+ return config.padding[1];
3702
+ }
3703
+ }
3704
+ };
3705
+ const getTopPadding = (config) => {
3706
+ if (config?.padding === null || config?.padding === undefined) {
3707
+ return DIAGRAM_FIELD_DEFAULTS.padding;
3708
+ }
3709
+ else if (typeof config.padding === 'number') {
3710
+ return config.padding;
3711
+ }
3712
+ else {
3713
+ if (config.padding.length === 0) {
3714
+ return DIAGRAM_FIELD_DEFAULTS.padding;
3715
+ }
3716
+ else if (config.padding.length === 1) {
3717
+ return config.padding[0];
3718
+ }
3719
+ else if (config.padding.length === 2) {
3720
+ return config.padding[0];
3721
+ }
3722
+ else if (config.padding.length === 3) {
3723
+ return config.padding[0];
3724
+ }
3725
+ else {
3726
+ return config.padding[0];
3727
+ }
3728
+ }
3729
+ };
3370
3730
 
3371
3731
  /**
3372
3732
  * Importer which imports a diagram from its daga model representation.
@@ -3414,9 +3774,13 @@ class DagaImporter {
3414
3774
  ...newNodeType.label
3415
3775
  };
3416
3776
  const newField = new DiagramField(model, newNode, [
3417
- newNode.coords[0] + labelConfiguration.margin,
3418
- newNode.coords[1] + labelConfiguration.margin
3419
- ], newNode.width - labelConfiguration.margin * 2, newNode.height - labelConfiguration.margin * 2, labelConfiguration.fontSize, labelConfiguration.fontFamily, labelConfiguration.color, labelConfiguration.selectedColor, labelConfiguration.horizontalAlign, labelConfiguration.verticalAlign, '', labelConfiguration.editable, labelConfiguration.fit);
3777
+ newNode.coords[0] + getLeftMargin(labelConfiguration),
3778
+ newNode.coords[1] + getTopMargin(labelConfiguration)
3779
+ ], newNode.width -
3780
+ getLeftMargin(labelConfiguration) -
3781
+ getRightMargin(labelConfiguration), newNode.height -
3782
+ getTopMargin(labelConfiguration) -
3783
+ getBottomMargin(labelConfiguration), labelConfiguration.fontSize, labelConfiguration.fontFamily, labelConfiguration.color, labelConfiguration.selectedColor, labelConfiguration.horizontalAlign, labelConfiguration.verticalAlign, '', labelConfiguration.editable, labelConfiguration.fit);
3420
3784
  newField.text = node.label;
3421
3785
  newNode.label = newField;
3422
3786
  model.fields.add(newField);
@@ -3435,9 +3799,13 @@ class DagaImporter {
3435
3799
  ...newNodeType.sectionGrid?.sections?.[section.indexYInNode]?.[section.indexXInNode]?.label
3436
3800
  };
3437
3801
  const newField = new DiagramField(model, newSection, [
3438
- newSection.coords[0] + labelConfiguration.margin,
3439
- newSection.coords[1] + labelConfiguration.margin
3440
- ], newSection.width - labelConfiguration.margin * 2, newSection.height - labelConfiguration.margin * 2, labelConfiguration.fontSize, labelConfiguration.fontFamily, labelConfiguration.color, labelConfiguration.selectedColor, labelConfiguration.horizontalAlign, labelConfiguration.verticalAlign, '', labelConfiguration.editable, labelConfiguration.fit);
3802
+ newSection.coords[0] + getLeftMargin(labelConfiguration),
3803
+ newSection.coords[1] + getTopMargin(labelConfiguration)
3804
+ ], newSection.width -
3805
+ getLeftMargin(labelConfiguration) -
3806
+ getRightMargin(labelConfiguration), newSection.height -
3807
+ getTopMargin(labelConfiguration) -
3808
+ getBottomMargin(labelConfiguration), labelConfiguration.fontSize, labelConfiguration.fontFamily, labelConfiguration.color, labelConfiguration.selectedColor, labelConfiguration.horizontalAlign, labelConfiguration.verticalAlign, '', labelConfiguration.editable, labelConfiguration.fit);
3441
3809
  newField.text = section.label;
3442
3810
  newSection.label = newField;
3443
3811
  model.fields.add(newField);
@@ -3654,7 +4022,7 @@ class SetGeometryCollabAction {
3654
4022
  this.timestamp = timestamp;
3655
4023
  }
3656
4024
  do() {
3657
- const node = this.canvas.model.nodes.get(this.nodeId);
4025
+ const node = this.canvas.model.nodes.get(this.nodeId, true);
3658
4026
  if (node && timestampWins(this.timestamp, node.geometryTimestamp)) {
3659
4027
  node.setGeometry(this.to);
3660
4028
  // Re-fit the labels, in case their text has changed since `this.to` was measured.
@@ -3695,8 +4063,8 @@ class AddConnectionCollabAction {
3695
4063
  this.endId = endId;
3696
4064
  }
3697
4065
  do() {
3698
- const start = this.canvas.model.ports.get(this.startId);
3699
- const end = this.canvas.model.ports.get(this.endId);
4066
+ const start = this.canvas.model.ports.get(this.startId, true);
4067
+ const end = this.canvas.model.ports.get(this.endId, true);
3700
4068
  if (start && end) {
3701
4069
  this.canvas.model.connections.new(this.typeId, start, end, this.id);
3702
4070
  }
@@ -3727,7 +4095,7 @@ class EditFieldCollabAction {
3727
4095
  this.timestamp = timestamp;
3728
4096
  }
3729
4097
  do() {
3730
- const field = this.canvas.model.fields.get(this.fieldId);
4098
+ const field = this.canvas.model.fields.get(this.fieldId, true);
3731
4099
  if (field && timestampWins(this.timestamp, field.textTimestamp)) {
3732
4100
  field.text = this.to;
3733
4101
  field.textTimestamp = this.timestamp;
@@ -3762,8 +4130,8 @@ class UpdateValuesCollabAction {
3762
4130
  return this.canvas.model.valueSet;
3763
4131
  }
3764
4132
  else {
3765
- return (this.canvas.model.nodes.get(this.id) ||
3766
- this.canvas.model.connections.get(this.id))?.valueSet;
4133
+ return (this.canvas.model.nodes.get(this.id, true) ||
4134
+ this.canvas.model.connections.get(this.id, true))?.valueSet;
3767
4135
  }
3768
4136
  }
3769
4137
  do() {
@@ -3811,19 +4179,19 @@ class SetSelfRemovedCollabAction {
3811
4179
  }
3812
4180
  do() {
3813
4181
  for (const nodeId of this.nodeIds) {
3814
- this.doOne(this.canvas.model.nodes.get(nodeId));
4182
+ this.doOne(this.canvas.model.nodes.get(nodeId, true));
3815
4183
  }
3816
4184
  for (const sectionId of this.sectionIds) {
3817
- this.doOne(this.canvas.model.sections.get(sectionId));
4185
+ this.doOne(this.canvas.model.sections.get(sectionId, true));
3818
4186
  }
3819
4187
  for (const portId of this.portIds) {
3820
- this.doOne(this.canvas.model.ports.get(portId));
4188
+ this.doOne(this.canvas.model.ports.get(portId, true));
3821
4189
  }
3822
4190
  for (const connectionId of this.connectionIds) {
3823
- this.doOne(this.canvas.model.connections.get(connectionId));
4191
+ this.doOne(this.canvas.model.connections.get(connectionId, true));
3824
4192
  }
3825
4193
  for (const fieldId of this.fieldIds) {
3826
- this.doOne(this.canvas.model.fields.get(fieldId));
4194
+ this.doOne(this.canvas.model.fields.get(fieldId, true));
3827
4195
  }
3828
4196
  // update view
3829
4197
  this.canvas.updateNodesInView(...this.nodeIds);
@@ -4478,13 +4846,13 @@ class AdjacencyLayout {
4478
4846
  }
4479
4847
  // arrange nodes
4480
4848
  const nodeArrangement = new Grid();
4481
- const nodesToBeArranged = [...model.nodes];
4849
+ const nodesToBeArranged = model.nodes.all();
4482
4850
  while (nodesToBeArranged.length > 0) {
4483
4851
  arrangeNode(nodesToBeArranged[0], nodeArrangement, [0, 0], nodesToBeArranged);
4484
4852
  }
4485
4853
  // place nodes according to arrangement
4486
- const maximumWidth = Math.max(...model.nodes.all().map((n) => n.width));
4487
- const maximumHeight = Math.max(...model.nodes.all().map((n) => n.height));
4854
+ const maximumWidth = Math.max(...model.nodes.map((n) => n.width));
4855
+ const maximumHeight = Math.max(...model.nodes.map((n) => n.height));
4488
4856
  const gapSize = (model.canvas?.gridSize || 0) * 2;
4489
4857
  for (let y = nodeArrangement.minY(); y <= nodeArrangement.maxY(); ++y) {
4490
4858
  for (let x = nodeArrangement.minX(); x <= nodeArrangement.maxX(); ++x) {
@@ -4524,7 +4892,7 @@ class BreadthAdjacencyLayout {
4524
4892
  }
4525
4893
  // arrange nodes
4526
4894
  const nodeArrangement = new Grid();
4527
- const nodesToBeArranged = [...model.nodes];
4895
+ const nodesToBeArranged = model.nodes.all();
4528
4896
  const nodeGridIndices = {};
4529
4897
  const firstNode = nodesToBeArranged[0];
4530
4898
  let currentNodeLevel = [firstNode];
@@ -4554,8 +4922,8 @@ class BreadthAdjacencyLayout {
4554
4922
  }
4555
4923
  }
4556
4924
  // place nodes according to arrangement
4557
- const maximumWidth = Math.max(...model.nodes.all().map((n) => n.width));
4558
- const maximumHeight = Math.max(...model.nodes.all().map((n) => n.height));
4925
+ const maximumWidth = Math.max(...model.nodes.map((n) => n.width));
4926
+ const maximumHeight = Math.max(...model.nodes.map((n) => n.height));
4559
4927
  const gapSize = (model.canvas?.gridSize || 0) * 2;
4560
4928
  for (let y = nodeArrangement.minY(); y <= nodeArrangement.maxY(); ++y) {
4561
4929
  for (let x = nodeArrangement.minX(); x <= nodeArrangement.maxX(); ++x) {
@@ -4584,7 +4952,7 @@ class BreadthLayout {
4584
4952
  return model;
4585
4953
  }
4586
4954
  const gapSize = (model.canvas?.gridSize || 0) * 2;
4587
- let nodesToBeArranged = [...model.nodes];
4955
+ let nodesToBeArranged = model.nodes.all();
4588
4956
  // Arrange nodes by a breadth first search
4589
4957
  const firstNode = nodesToBeArranged[0];
4590
4958
  removeIfExists(nodesToBeArranged, firstNode);
@@ -4609,7 +4977,6 @@ class BreadthLayout {
4609
4977
  }
4610
4978
  }
4611
4979
  if (nodesInNextRow.length > 0) {
4612
- nodesInNextRow.sort((a, b) => b.type.priority - a.type.priority);
4613
4980
  nodeArrangement.push(nodesInNextRow);
4614
4981
  }
4615
4982
  else {
@@ -4805,17 +5172,17 @@ class PriorityLayout {
4805
5172
  // nothing to arrange...
4806
5173
  return model;
4807
5174
  }
4808
- const maximumPriority = Math.max(...model.nodes.filter((n) => !n.removed).map((n) => n.getPriority()));
4809
- const minimumPriority = Math.min(...model.nodes.filter((n) => !n.removed).map((n) => n.getPriority()));
5175
+ const maximumPriority = Math.max(...model.nodes.map((n) => n.getPriority()));
5176
+ const minimumPriority = Math.min(...model.nodes.map((n) => n.getPriority()));
4810
5177
  if (maximumPriority === minimumPriority) {
4811
5178
  // if there's no disparity in priorities, just use breadth layout
4812
5179
  new BreadthLayout().apply(model);
4813
5180
  return model;
4814
5181
  }
4815
5182
  const gapSize = (model.canvas?.gridSize || 0) * 2;
4816
- const nodesToBeArranged = [...model.nodes];
5183
+ const nodesToBeArranged = model.nodes.all();
4817
5184
  const nodeArrangement = [];
4818
- const nodesWithMaximumPriorityToBeArranged = model.nodes.filter((n) => !n.removed && n.getPriority() >= maximumPriority);
5185
+ const nodesWithMaximumPriorityToBeArranged = model.nodes.filter((n) => n.getPriority() >= maximumPriority);
4819
5186
  const nodesWithMaximumPriority = [];
4820
5187
  if (nodesWithMaximumPriorityToBeArranged.length > 1) {
4821
5188
  // use bfs to sort nodes by distance to the first node
@@ -4914,8 +5281,8 @@ class TreeLayout {
4914
5281
  // nothing to arrange...
4915
5282
  return model;
4916
5283
  }
4917
- const maximumPriority = Math.max(...model.nodes.filter((n) => !n.removed).map((n) => n.getPriority()));
4918
- const minimumPriority = Math.min(...model.nodes.filter((n) => !n.removed).map((n) => n.getPriority()));
5284
+ const maximumPriority = Math.max(...model.nodes.map((n) => n.getPriority()));
5285
+ const minimumPriority = Math.min(...model.nodes.map((n) => n.getPriority()));
4919
5286
  if (maximumPriority === minimumPriority) {
4920
5287
  // if there's no disparity in priorities, just use breadth layout
4921
5288
  new BreadthLayout().apply(model);
@@ -4936,7 +5303,7 @@ class TreeLayout {
4936
5303
  branchArrangement.push([branch]);
4937
5304
  arrangeBranches(branch, branchArrangement, branchArrangement.length);
4938
5305
  }
4939
- const maximumHeight = Math.max(...model.nodes.all().map((n) => n.height));
5306
+ const maximumHeight = Math.max(...model.nodes.map((n) => n.height));
4940
5307
  let widthAccumulator = 0;
4941
5308
  for (let i = 0; i < branchArrangement.length; ++i) {
4942
5309
  let heightAccumulator = 0;
@@ -4957,7 +5324,9 @@ class TreeLayout {
4957
5324
  }
4958
5325
  }
4959
5326
  const populateBranches = (branch, nodesToBeArranged) => {
4960
- for (const adjacentNode of branch.node.getAdjacentNodes()) {
5327
+ for (const adjacentNode of branch.node
5328
+ .getAdjacentNodes()
5329
+ .sort((n1, n2) => n2.getPriority() - n1.getPriority())) {
4961
5330
  const indexOfAdjacentNode = nodesToBeArranged.indexOf(adjacentNode);
4962
5331
  if (indexOfAdjacentNode >= 0) {
4963
5332
  nodesToBeArranged.splice(indexOfAdjacentNode, 1);
@@ -5266,12 +5635,12 @@ class DagaExporter {
5266
5635
  if (model.description) {
5267
5636
  result.description = model.description;
5268
5637
  }
5269
- for (const node of model.nodes) {
5638
+ for (const node of model.nodes.all(true)) {
5270
5639
  if (!includeCollabMeta && node.removed)
5271
5640
  continue;
5272
5641
  result.nodes.push(this.exportNode(node, includeCollabMeta));
5273
5642
  }
5274
- for (const connection of model.connections) {
5643
+ for (const connection of model.connections.all(true)) {
5275
5644
  if (!includeCollabMeta && connection.removed)
5276
5645
  continue;
5277
5646
  result.connections.push(this.exportConnection(connection, includeCollabMeta));
@@ -5467,7 +5836,7 @@ class DiagramDecorator extends DiagramElement {
5467
5836
  return this.priority;
5468
5837
  }
5469
5838
  }
5470
- class DiagramDecoratorSet extends DiagramEntitySet {
5839
+ class DiagramDecoratorSet extends DiagramElementSet {
5471
5840
  /**
5472
5841
  * Instance a set of decorators for the given model. This method is used internally.
5473
5842
  * @private
@@ -5547,7 +5916,7 @@ class DiagramObject extends DiagramElement {
5547
5916
  return this.priority;
5548
5917
  }
5549
5918
  }
5550
- class DiagramObjectSet extends DiagramEntitySet {
5919
+ class DiagramObjectSet extends DiagramElementSet {
5551
5920
  /**
5552
5921
  * Instance a set of objects for the given model. This method is used internally.
5553
5922
  * @private
@@ -5812,20 +6181,20 @@ class DiagramCanvas {
5812
6181
  if (event.ctrlKey && event.key === 'a') {
5813
6182
  event.preventDefault();
5814
6183
  // select all
5815
- for (const node of this.model.nodes.filter((n) => !n.removed)) {
6184
+ for (const node of this.model.nodes) {
5816
6185
  this.addToUserSelection(node);
5817
6186
  }
5818
- for (const connection of this.model.connections.filter((c) => !c.removed)) {
6187
+ for (const connection of this.model.connections) {
5819
6188
  this.addToUserSelection(connection);
5820
6189
  }
5821
6190
  }
5822
6191
  if (event.ctrlKey && event.key === 'i') {
5823
6192
  event.preventDefault();
5824
6193
  // invert selection
5825
- for (const node of this.model.nodes.filter((n) => !n.removed)) {
6194
+ for (const node of this.model.nodes) {
5826
6195
  this.toggleUserSelection(node);
5827
6196
  }
5828
- for (const connection of this.model.connections.filter((c) => !c.removed)) {
6197
+ for (const connection of this.model.connections) {
5829
6198
  this.toggleUserSelection(connection);
5830
6199
  }
5831
6200
  }
@@ -5853,17 +6222,49 @@ class DiagramCanvas {
5853
6222
  this.cancelAllUserActions();
5854
6223
  }
5855
6224
  if (event.ctrlKey && event.key === 'y') {
6225
+ event.preventDefault();
5856
6226
  // redo
5857
6227
  this.actionQueue.redo();
5858
6228
  }
5859
6229
  if (event.ctrlKey && event.key === 'z') {
6230
+ event.preventDefault();
5860
6231
  // undo
5861
6232
  this.actionQueue.undo();
5862
6233
  }
6234
+ if (event.key === '+') {
6235
+ event.preventDefault();
6236
+ // zoom in
6237
+ this.parentComponent.diagramButtons.zoomIn();
6238
+ }
6239
+ if (event.key === '-') {
6240
+ event.preventDefault();
6241
+ // zoom out
6242
+ this.parentComponent.diagramButtons.zoomOut();
6243
+ }
6244
+ if (event.key === Keys.ArrowLeft) {
6245
+ event.preventDefault();
6246
+ // move left, faster if we're zoomed out and slower if we're zoomed in
6247
+ this.translateBy(-100 / this.zoomTransform.k, 0);
6248
+ }
6249
+ if (event.key === Keys.ArrowRight) {
6250
+ event.preventDefault();
6251
+ // move right, faster if we're zoomed out and slower if we're zoomed in
6252
+ this.translateBy(100 / this.zoomTransform.k, 0);
6253
+ }
6254
+ if (event.key === Keys.ArrowDown) {
6255
+ event.preventDefault();
6256
+ // move down, faster if we're zoomed out and slower if we're zoomed in
6257
+ this.translateBy(0, -100 / this.zoomTransform.k);
6258
+ }
6259
+ if (event.key === Keys.ArrowUp) {
6260
+ event.preventDefault();
6261
+ // move up, faster if we're zoomed out and slower if we're zoomed in
6262
+ this.translateBy(0, 100 / this.zoomTransform.k);
6263
+ }
5863
6264
  });
5864
6265
  const canvasView = this.selectRoot()
5865
6266
  .append('g')
5866
- .attr('class', 'canvas-view')
6267
+ .attr('class', 'daga-canvas-view')
5867
6268
  .attr('width', `100%`)
5868
6269
  .attr('height', `100%`);
5869
6270
  const canvasBackground = canvasView
@@ -5948,14 +6349,14 @@ class DiagramCanvas {
5948
6349
  }
5949
6350
  const canvasElements = canvasView
5950
6351
  .append('g')
5951
- .attr('class', 'canvas-elements');
5952
- canvasElements.append('g').attr('class', 'canvas-nodes');
5953
- canvasElements.append('g').attr('class', 'canvas-sections');
5954
- canvasElements.append('g').attr('class', 'canvas-ports');
5955
- canvasElements.append('g').attr('class', 'canvas-connections');
5956
- canvasElements.append('g').attr('class', 'canvas-fields');
5957
- canvasElements.append('g').attr('class', 'canvas-objects');
5958
- canvasElements.append('g').attr('class', 'canvas-decorators');
6352
+ .attr('class', 'daga-canvas-elements');
6353
+ canvasElements.append('g').attr('class', 'daga-canvas-nodes');
6354
+ canvasElements.append('g').attr('class', 'daga-canvas-sections');
6355
+ canvasElements.append('g').attr('class', 'daga-canvas-ports');
6356
+ canvasElements.append('g').attr('class', 'daga-canvas-connections');
6357
+ canvasElements.append('g').attr('class', 'daga-canvas-fields');
6358
+ canvasElements.append('g').attr('class', 'daga-canvas-objects');
6359
+ canvasElements.append('g').attr('class', 'daga-canvas-decorators');
5959
6360
  this.viewInitialized$.next();
5960
6361
  }
5961
6362
  zoomBy(zoom) {
@@ -5982,13 +6383,14 @@ class DiagramCanvas {
5982
6383
  // if there are no nodes, we have nothing to do here
5983
6384
  if (this.model.nodes.length > 0) {
5984
6385
  const canvasViewBoundingBox = this.selectCanvasView().select('rect').node().getBBox();
5985
- const minimumX = Math.min(...this.model.nodes.all().map((n) => n.coords[0]));
5986
- const maximumX = Math.max(...this.model.nodes.all().map((n) => n.coords[0] + n.width));
6386
+ const nonRemovedNodes = this.model.nodes.all();
6387
+ const minimumX = Math.min(...nonRemovedNodes.map((n) => n.coords[0]));
6388
+ const maximumX = Math.max(...nonRemovedNodes.map((n) => n.coords[0] + n.width));
5987
6389
  const averageX = (minimumX + maximumX) / 2;
5988
6390
  const rangeX = maximumX - minimumX;
5989
6391
  const windowRangeX = canvasViewBoundingBox.width;
5990
- const minimumY = Math.min(...this.model.nodes.all().map((n) => n.coords[1]));
5991
- const maximumY = Math.max(...this.model.nodes.all().map((n) => n.coords[1] + n.height));
6392
+ const minimumY = Math.min(...nonRemovedNodes.map((n) => n.coords[1]));
6393
+ const maximumY = Math.max(...nonRemovedNodes.map((n) => n.coords[1] + n.height));
5992
6394
  const averageY = (minimumY + maximumY) / 2;
5993
6395
  const rangeY = maximumY - minimumY;
5994
6396
  const windowRangeY = canvasViewBoundingBox.height;
@@ -6084,10 +6486,9 @@ class DiagramCanvas {
6084
6486
  updateNodesInView(...ids) {
6085
6487
  let updateSelection = this.selectCanvasNodes()
6086
6488
  .selectAll('g.diagram-node')
6087
- .data(this.model.nodes.filter((e) => !e.removed &&
6088
- (this.priorityThreshold !== undefined
6089
- ? e.getPriority() >= this.priorityThreshold
6090
- : true)), (d) => d.id);
6489
+ .data(this.model.nodes.filter((e) => this.priorityThreshold !== undefined
6490
+ ? e.getPriority() >= this.priorityThreshold
6491
+ : true), (d) => d.id);
6091
6492
  const exitSelection = updateSelection.exit();
6092
6493
  const enterSelection = updateSelection
6093
6494
  .enter()
@@ -6623,10 +7024,9 @@ class DiagramCanvas {
6623
7024
  updateSectionsInView(...ids) {
6624
7025
  let updateSelection = this.selectCanvasSections()
6625
7026
  .selectAll('g.diagram-section')
6626
- .data(this.model.sections.filter((e) => !e.removed &&
6627
- (this.priorityThreshold !== undefined
6628
- ? e.getPriority() >= this.priorityThreshold
6629
- : true)), (d) => d.id);
7027
+ .data(this.model.sections.filter((e) => this.priorityThreshold !== undefined
7028
+ ? e.getPriority() >= this.priorityThreshold
7029
+ : true), (d) => d.id);
6630
7030
  const exitSelection = updateSelection.exit();
6631
7031
  const enterSelection = updateSelection
6632
7032
  .enter()
@@ -7181,10 +7581,9 @@ class DiagramCanvas {
7181
7581
  updatePortsInView(...ids) {
7182
7582
  let updateSelection = this.selectCanvasPorts()
7183
7583
  .selectAll('g.diagram-port')
7184
- .data(this.model.ports.filter((e) => !e.removed &&
7185
- (this.priorityThreshold !== undefined
7186
- ? e.getPriority() >= this.priorityThreshold
7187
- : true)), (d) => d.id);
7584
+ .data(this.model.ports.filter((e) => this.priorityThreshold !== undefined
7585
+ ? e.getPriority() >= this.priorityThreshold
7586
+ : true), (d) => d.id);
7188
7587
  const exitSelection = updateSelection.exit();
7189
7588
  const enterSelection = updateSelection
7190
7589
  .enter()
@@ -7287,7 +7686,7 @@ class DiagramCanvas {
7287
7686
  const pointerCoords = this.getPointerLocationRelativeToCanvas(event);
7288
7687
  let minDistanceFound = Number.POSITIVE_INFINITY;
7289
7688
  let closestPortFound = undefined;
7290
- for (const port of this.model.ports.filter((p) => !p.removed)) {
7689
+ for (const port of this.model.ports) {
7291
7690
  const distance = port.distanceTo(pointerCoords);
7292
7691
  if (distance < minDistanceFound) {
7293
7692
  minDistanceFound = distance;
@@ -7359,10 +7758,9 @@ class DiagramCanvas {
7359
7758
  .attr('opacity', (d) => (d.highlighted || d.selected ? 0.5 : 0));
7360
7759
  }
7361
7760
  updateConnectionsInView(...ids) {
7362
- const connectionList = this.model.connections.filter((e) => !e.removed &&
7363
- (this.priorityThreshold !== undefined
7364
- ? e.getPriority() >= this.priorityThreshold
7365
- : true));
7761
+ const connectionList = this.model.connections.filter((e) => this.priorityThreshold !== undefined
7762
+ ? e.getPriority() >= this.priorityThreshold
7763
+ : true);
7366
7764
  if (this.unfinishedConnection) {
7367
7765
  connectionList.push(this.unfinishedConnection);
7368
7766
  }
@@ -7466,10 +7864,9 @@ class DiagramCanvas {
7466
7864
  updateFieldsInView(...ids) {
7467
7865
  let updateSelection = this.selectCanvasFields()
7468
7866
  .selectAll('foreignObject.diagram-field')
7469
- .data(this.model.fields.filter((e) => !e.removed &&
7470
- (this.priorityThreshold !== undefined
7471
- ? e.getPriority() >= this.priorityThreshold
7472
- : true)), (d) => d.id);
7867
+ .data(this.model.fields.filter((e) => this.priorityThreshold !== undefined
7868
+ ? e.getPriority() >= this.priorityThreshold
7869
+ : true), (d) => d.id);
7473
7870
  const exitSelection = updateSelection.exit();
7474
7871
  const enterSelection = updateSelection
7475
7872
  .enter()
@@ -7643,10 +8040,9 @@ class DiagramCanvas {
7643
8040
  updateObjectsInView(...ids) {
7644
8041
  let updateSelection = this.selectCanvasObjects()
7645
8042
  .selectAll('foreignObject.diagram-object')
7646
- .data(this.model.objects.filter((e) => !e.removed &&
7647
- (this.priorityThreshold !== undefined
7648
- ? e.getPriority() >= this.priorityThreshold
7649
- : true)), (d) => d.id);
8043
+ .data(this.model.objects.filter((e) => this.priorityThreshold !== undefined
8044
+ ? e.getPriority() >= this.priorityThreshold
8045
+ : true), (d) => d.id);
7650
8046
  const exitSelection = updateSelection.exit();
7651
8047
  const enterSelection = updateSelection
7652
8048
  .enter()
@@ -7681,10 +8077,9 @@ class DiagramCanvas {
7681
8077
  updateDecoratorsInView(...ids) {
7682
8078
  let updateSelection = this.selectCanvasDecorators()
7683
8079
  .selectAll('foreignObject.diagram-decorator')
7684
- .data(this.model.decorators.filter((e) => !e.removed &&
7685
- (this.priorityThreshold !== undefined
7686
- ? e.getPriority() >= this.priorityThreshold
7687
- : true)), (d) => d.id);
8080
+ .data(this.model.decorators.filter((e) => this.priorityThreshold !== undefined
8081
+ ? e.getPriority() >= this.priorityThreshold
8082
+ : true), (d) => d.id);
7688
8083
  const exitSelection = updateSelection.exit();
7689
8084
  const enterSelection = updateSelection
7690
8085
  .enter()
@@ -7748,13 +8143,14 @@ class DiagramCanvas {
7748
8143
  const boundingWidth = !connection.startLabel
7749
8144
  ? 0
7750
8145
  : startLabelBoundingRect.width / this.zoomTransform.k +
7751
- labelConfiguration.padding * 2;
8146
+ getLeftPadding(labelConfiguration) +
8147
+ getRightPadding(labelConfiguration);
7752
8148
  const boundingHeight = !connection.startLabel
7753
8149
  ? 0
7754
8150
  : startLabelBoundingRect.height / this.zoomTransform.k +
7755
- labelConfiguration.padding * 2;
7756
- const pathStartLabelPoint = pathNode.getPointAtLength(labelConfiguration.margin +
7757
- Math.max(boundingWidth / 2, boundingHeight / 2));
8151
+ getTopPadding(labelConfiguration) +
8152
+ getBottomPadding(labelConfiguration);
8153
+ const pathStartLabelPoint = pathNode.getPointAtLength(Math.max(getLeftMargin(labelConfiguration) + boundingWidth / 2, getRightMargin(labelConfiguration) + boundingWidth / 2, getTopMargin(labelConfiguration) + boundingHeight / 2, getBottomMargin(labelConfiguration) + boundingHeight / 2));
7758
8154
  connectionSelection
7759
8155
  .select('g.diagram-connection-start-label path')
7760
8156
  .attr('d', pillPath(-boundingWidth / 2, -boundingHeight / 2, boundingWidth, boundingHeight))
@@ -7788,11 +8184,13 @@ class DiagramCanvas {
7788
8184
  const boundingWidth = !connection.middleLabel
7789
8185
  ? 0
7790
8186
  : middleLabelBoundingRect.width / this.zoomTransform.k +
7791
- labelConfiguration.padding * 2;
8187
+ getLeftPadding(labelConfiguration) +
8188
+ getRightPadding(labelConfiguration);
7792
8189
  const boundingHeight = !connection.middleLabel
7793
8190
  ? 0
7794
8191
  : middleLabelBoundingRect.height / this.zoomTransform.k +
7795
- labelConfiguration.padding * 2;
8192
+ getTopPadding(labelConfiguration) +
8193
+ getBottomPadding(labelConfiguration);
7796
8194
  const pathMiddleLabelPoint = pathNode.getPointAtLength(pathLength / 2);
7797
8195
  connectionSelection
7798
8196
  .select('g.diagram-connection-middle-label path')
@@ -7827,14 +8225,15 @@ class DiagramCanvas {
7827
8225
  const boundingWidth = !connection.endLabel
7828
8226
  ? 0
7829
8227
  : endLabelBoundingRect.width / this.zoomTransform.k +
7830
- labelConfiguration.padding * 2;
8228
+ getLeftPadding(labelConfiguration) +
8229
+ getRightPadding(labelConfiguration);
7831
8230
  const boundingHeight = !connection.endLabel
7832
8231
  ? 0
7833
8232
  : endLabelBoundingRect.height / this.zoomTransform.k +
7834
- labelConfiguration.padding * 2;
8233
+ getTopPadding(labelConfiguration) +
8234
+ getBottomPadding(labelConfiguration);
7835
8235
  const pathEndLabelPoint = pathNode.getPointAtLength(pathLength -
7836
- labelConfiguration.margin -
7837
- Math.max(boundingWidth / 2, boundingHeight / 2));
8236
+ Math.max(getLeftMargin(labelConfiguration) + boundingWidth / 2, getRightMargin(labelConfiguration) + boundingWidth / 2, getTopMargin(labelConfiguration) + boundingHeight / 2, getBottomMargin(labelConfiguration) + boundingHeight / 2));
7838
8237
  connectionSelection
7839
8238
  .select('g.diagram-connection-end-label path')
7840
8239
  .attr('d', pillPath(-boundingWidth / 2, -boundingHeight / 2, boundingWidth, boundingHeight))
@@ -7901,10 +8300,12 @@ class DiagramCanvas {
7901
8300
  if (field.rootElement instanceof DiagramNode && field.fit) {
7902
8301
  const fieldDimensions = this.minimumSizeOfField(field);
7903
8302
  let stretchX = fieldDimensions[0] +
7904
- 2 * (field.rootElement.type.label?.margin || 0) -
8303
+ getLeftMargin(field.rootElement.type.label) +
8304
+ getRightMargin(field.rootElement.type.label) -
7905
8305
  field.rootElement.width;
7906
8306
  let stretchY = fieldDimensions[1] +
7907
- 2 * (field.rootElement.type.label?.margin || 0) -
8307
+ getTopMargin(field.rootElement.type.label) +
8308
+ getBottomMargin(field.rootElement.type.label) -
7908
8309
  field.rootElement.height;
7909
8310
  if (this.snapToGrid) {
7910
8311
  stretchX = Math.ceil(stretchX / this.gridSize) * this.gridSize;
@@ -7945,10 +8346,12 @@ class DiagramCanvas {
7945
8346
  fieldDimensions[1] = minimumFieldHeight;
7946
8347
  }
7947
8348
  let stretchX = fieldDimensions[0] +
7948
- 2 * (field.rootElement?.getConfig()?.label?.margin || 0) -
8349
+ getLeftMargin(field.rootElement?.getConfig()?.label) +
8350
+ getRightMargin(field.rootElement?.getConfig()?.label) -
7949
8351
  field.rootElement.width;
7950
8352
  let stretchY = fieldDimensions[1] +
7951
- 2 * (field.rootElement?.getConfig()?.label?.margin || 0) -
8353
+ getTopMargin(field.rootElement?.getConfig()?.label) +
8354
+ getBottomMargin(field.rootElement?.getConfig()?.label) -
7952
8355
  field.rootElement.height;
7953
8356
  if (this.snapToGrid) {
7954
8357
  stretchX = Math.ceil(stretchX / this.gridSize) * this.gridSize;
@@ -7997,31 +8400,31 @@ class DiagramCanvas {
7997
8400
  return d3.select(this.diagramRoot).select('svg');
7998
8401
  }
7999
8402
  selectCanvasView() {
8000
- return this.selectRoot().select(`.canvas-view`);
8403
+ return this.selectRoot().select(`.daga-canvas-view`);
8001
8404
  }
8002
8405
  selectCanvasElements() {
8003
- return this.selectRoot().select(`.canvas-elements`);
8406
+ return this.selectRoot().select(`.daga-canvas-elements`);
8004
8407
  }
8005
8408
  selectCanvasNodes() {
8006
- return this.selectRoot().select(`.canvas-nodes`);
8409
+ return this.selectRoot().select(`.daga-canvas-nodes`);
8007
8410
  }
8008
8411
  selectCanvasSections() {
8009
- return this.selectRoot().select(`.canvas-sections`);
8412
+ return this.selectRoot().select(`.daga-canvas-sections`);
8010
8413
  }
8011
8414
  selectCanvasPorts() {
8012
- return this.selectRoot().select(`.canvas-ports`);
8415
+ return this.selectRoot().select(`.daga-canvas-ports`);
8013
8416
  }
8014
8417
  selectCanvasConnections() {
8015
- return this.selectRoot().select(`.canvas-connections`);
8418
+ return this.selectRoot().select(`.daga-canvas-connections`);
8016
8419
  }
8017
8420
  selectCanvasFields() {
8018
- return this.selectRoot().select(`.canvas-fields`);
8421
+ return this.selectRoot().select(`.daga-canvas-fields`);
8019
8422
  }
8020
8423
  selectCanvasObjects() {
8021
- return this.selectRoot().select(`.canvas-objects`);
8424
+ return this.selectRoot().select(`.daga-canvas-objects`);
8022
8425
  }
8023
8426
  selectCanvasDecorators() {
8024
- return this.selectRoot().select(`.canvas-decorators`);
8427
+ return this.selectRoot().select(`.daga-canvas-decorators`);
8025
8428
  }
8026
8429
  // User actions
8027
8430
  startConnection(port) {
@@ -8240,6 +8643,10 @@ class DiagramCanvas {
8240
8643
  return this.userSelection.indexOf(selection) >= 0;
8241
8644
  }
8242
8645
  addToUserSelection(selection) {
8646
+ if (selection.selected) {
8647
+ // if selection is already selected, do nothing
8648
+ return;
8649
+ }
8243
8650
  if (this.propertyEditorSelection === undefined &&
8244
8651
  (selection instanceof DiagramNode ||
8245
8652
  selection instanceof DiagramConnection)) {
@@ -8266,7 +8673,10 @@ class DiagramCanvas {
8266
8673
  if (this.propertyEditorSelection === selection) {
8267
8674
  this.setPropertyEditorSelection(undefined);
8268
8675
  }
8269
- this.userSelection.splice(this.userSelection.indexOf(selection), 1);
8676
+ const indexOfSelectionInUserSelection = this.userSelection.indexOf(selection);
8677
+ if (indexOfSelectionInUserSelection >= 0) {
8678
+ this.userSelection.splice(indexOfSelectionInUserSelection, 1);
8679
+ }
8270
8680
  selection.selected = false;
8271
8681
  selection.updateInView();
8272
8682
  // if selection is a node with sections, deselect the sections too so that sections don't show up as selected in the view
@@ -8357,7 +8767,7 @@ class DiagramCanvas {
8357
8767
  // append to the root (svg) element so the context menu is not affected by zoom transforms on the canvas view
8358
8768
  const contextMenuContainer = this.selectRoot()
8359
8769
  .append('foreignObject')
8360
- .attr('class', 'context-menu')
8770
+ .attr('class', 'daga-context-menu')
8361
8771
  .attr('x', `${coordsRelativeToRoot[0] - CONTEXT_MENU_TOTAL_RADIUS}px`)
8362
8772
  .attr('y', `${coordsRelativeToRoot[1] - CONTEXT_MENU_TOTAL_RADIUS}px`)
8363
8773
  .attr('width', `${2 * CONTEXT_MENU_TOTAL_RADIUS}px`)
@@ -8380,7 +8790,7 @@ class DiagramCanvas {
8380
8790
  this.canUserPerformAction(DiagramActions.Remove)) {
8381
8791
  buttons.push({
8382
8792
  name: 'CUT',
8383
- imageClass: 'cut',
8793
+ imageClass: 'daga-cut',
8384
8794
  onPress: (buttonPressEvent) => {
8385
8795
  buttonPressEvent.preventDefault();
8386
8796
  this.copyUserSelectionToClipboard();
@@ -8393,7 +8803,7 @@ class DiagramCanvas {
8393
8803
  this.canUserPerformAction(DiagramActions.Clipboard)) {
8394
8804
  buttons.push({
8395
8805
  name: 'COPY',
8396
- imageClass: 'copy',
8806
+ imageClass: 'daga-copy',
8397
8807
  onPress: (buttonPressEvent) => {
8398
8808
  buttonPressEvent.preventDefault();
8399
8809
  this.copyUserSelectionToClipboard();
@@ -8404,7 +8814,7 @@ class DiagramCanvas {
8404
8814
  if (this.canUserPerformAction(DiagramActions.Paste)) {
8405
8815
  buttons.push({
8406
8816
  name: 'PASTE',
8407
- imageClass: 'paste',
8817
+ imageClass: 'daga-paste',
8408
8818
  onPress: (buttonPressEvent) => {
8409
8819
  buttonPressEvent.preventDefault();
8410
8820
  this.pasteUserSelectionFromClipboard(this.getClosestGridPoint(coordsRelativeToCanvas));
@@ -8416,7 +8826,7 @@ class DiagramCanvas {
8416
8826
  this.canUserPerformAction(DiagramActions.Remove)) {
8417
8827
  buttons.push({
8418
8828
  name: 'DELETE',
8419
- imageClass: 'delete',
8829
+ imageClass: 'daga-delete',
8420
8830
  onPress: (buttonPressEvent) => {
8421
8831
  buttonPressEvent.preventDefault();
8422
8832
  this.deleteUserSelection();
@@ -8428,7 +8838,7 @@ class DiagramCanvas {
8428
8838
  if (buttons.length === 0) {
8429
8839
  buttons.push({
8430
8840
  name: 'NONE',
8431
- imageClass: 'cross',
8841
+ imageClass: 'daga-cross',
8432
8842
  onPress: undefined
8433
8843
  });
8434
8844
  }
@@ -8438,7 +8848,7 @@ class DiagramCanvas {
8438
8848
  const angle = (i + 0.5 - buttons.length / 2) * CONTEXT_MENU_BUTTON_PADDING_RADIANS;
8439
8849
  const buttonContainer = contextMenuContainer
8440
8850
  .append('xhtml:div')
8441
- .attr('class', `context-menu-button ${button.imageClass}-button${button.onPress != undefined ? ' clickable' : ''}`)
8851
+ .attr('class', `daga-context-menu-button ${button.imageClass}-button${button.onPress != undefined ? ' daga-clickable' : ''}`)
8442
8852
  .attr('tabindex', 0)
8443
8853
  .style('position', 'absolute')
8444
8854
  .style('box-sizing', 'border-box')
@@ -8789,11 +9199,11 @@ class DiagramButtonsComponent {
8789
9199
  this.canvas.actionQueue.redo();
8790
9200
  }
8791
9201
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DiagramButtonsComponent, deps: [{ token: CanvasProviderService }], target: i0.ɵɵFactoryTarget.Component }); }
8792
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: DiagramButtonsComponent, isStandalone: true, selector: "daga-diagram-buttons", inputs: { location: "location", direction: "direction", enableFilter: "enableFilter", enableLayout: "enableLayout", enableUndoRedo: "enableUndoRedo", enableZoom: "enableZoom", zoomRate: "zoomRate" }, viewQueries: [{ propertyName: "collapsableButtons", first: true, predicate: ["collapsableButtons"], descendants: true }], ngImport: i0, template: "<div class=\"diagram-buttons {{ location }} {{ direction }}\">\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"zoom-in\"\r\n (click)=\"zoomIn()\"\r\n >\r\n <span class=\"tooltip\">Zoom in</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"zoom-out\"\r\n (click)=\"zoomOut()\"\r\n >\r\n <span class=\"tooltip\">Zoom out</span>\r\n </button>\r\n <div #collapsableButtons class=\"collapsable-buttons collapsed\">\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"center\"\r\n (click)=\"center()\"\r\n >\r\n <span class=\"tooltip\">Fit diagram to screen</span>\r\n </button>\r\n <button *ngIf=\"enableUndoRedo\" class=\"undo\" (click)=\"undo()\">\r\n <span class=\"tooltip\">Undo</span>\r\n </button>\r\n <button *ngIf=\"enableUndoRedo\" class=\"redo\" (click)=\"redo()\">\r\n <span class=\"tooltip\">Redo</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableLayout && canvas.layoutFormat\"\r\n class=\"layout\"\r\n (click)=\"layout()\"\r\n >\r\n <span class=\"tooltip\">Apply layout</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableFilter\"\r\n class=\"filter\"\r\n [class]=\"filterOn ? 'on' : 'off'\"\r\n (click)=\"filter()\"\r\n >\r\n <span class=\"tooltip\">Apply filter</span>\r\n </button>\r\n </div>\r\n <button class=\"more-options\" (click)=\"toggleCollapse()\">\r\n <span *ngIf=\"!collapsed\" class=\"tooltip\">Less options</span>\r\n <span *ngIf=\"collapsed\" class=\"tooltip\">More options</span>\r\n </button>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] }); }
9202
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: DiagramButtonsComponent, isStandalone: true, selector: "daga-diagram-buttons", inputs: { location: "location", direction: "direction", enableFilter: "enableFilter", enableLayout: "enableLayout", enableUndoRedo: "enableUndoRedo", enableZoom: "enableZoom", zoomRate: "zoomRate" }, viewQueries: [{ propertyName: "collapsableButtons", first: true, predicate: ["collapsableButtons"], descendants: true }], ngImport: i0, template: "<div class=\"daga-diagram-buttons daga-{{ location }} daga-{{ direction }}\">\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"daga-zoom-in\"\r\n (click)=\"zoomIn()\"\r\n >\r\n <span class=\"daga-tooltip\">Zoom in</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"daga-zoom-out\"\r\n (click)=\"zoomOut()\"\r\n >\r\n <span class=\"daga-tooltip\">Zoom out</span>\r\n </button>\r\n <div #collapsableButtons class=\"daga-collapsable-buttons daga-collapsed\">\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"daga-center\"\r\n (click)=\"center()\"\r\n >\r\n <span class=\"daga-tooltip\">Fit diagram to screen</span>\r\n </button>\r\n <button *ngIf=\"enableUndoRedo\" class=\"daga-undo\" (click)=\"undo()\">\r\n <span class=\"daga-tooltip\">Undo</span>\r\n </button>\r\n <button *ngIf=\"enableUndoRedo\" class=\"daga-redo\" (click)=\"redo()\">\r\n <span class=\"daga-tooltip\">Redo</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableLayout && canvas.layoutFormat\"\r\n class=\"daga-layout\"\r\n (click)=\"layout()\"\r\n >\r\n <span class=\"daga-tooltip\">Apply layout</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableFilter\"\r\n class=\"daga-filter\"\r\n [class]=\"filterOn ? 'daga-on' : 'daga-off'\"\r\n (click)=\"filter()\"\r\n >\r\n <span class=\"daga-tooltip\">Apply filter</span>\r\n </button>\r\n </div>\r\n <button class=\"daga-more-options\" (click)=\"toggleCollapse()\">\r\n <span *ngIf=\"!collapsed\" class=\"daga-tooltip\">Less options</span>\r\n <span *ngIf=\"collapsed\" class=\"daga-tooltip\">More options</span>\r\n </button>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] }); }
8793
9203
  }
8794
9204
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DiagramButtonsComponent, decorators: [{
8795
9205
  type: Component,
8796
- args: [{ standalone: true, selector: 'daga-diagram-buttons', imports: [CommonModule], template: "<div class=\"diagram-buttons {{ location }} {{ direction }}\">\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"zoom-in\"\r\n (click)=\"zoomIn()\"\r\n >\r\n <span class=\"tooltip\">Zoom in</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"zoom-out\"\r\n (click)=\"zoomOut()\"\r\n >\r\n <span class=\"tooltip\">Zoom out</span>\r\n </button>\r\n <div #collapsableButtons class=\"collapsable-buttons collapsed\">\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"center\"\r\n (click)=\"center()\"\r\n >\r\n <span class=\"tooltip\">Fit diagram to screen</span>\r\n </button>\r\n <button *ngIf=\"enableUndoRedo\" class=\"undo\" (click)=\"undo()\">\r\n <span class=\"tooltip\">Undo</span>\r\n </button>\r\n <button *ngIf=\"enableUndoRedo\" class=\"redo\" (click)=\"redo()\">\r\n <span class=\"tooltip\">Redo</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableLayout && canvas.layoutFormat\"\r\n class=\"layout\"\r\n (click)=\"layout()\"\r\n >\r\n <span class=\"tooltip\">Apply layout</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableFilter\"\r\n class=\"filter\"\r\n [class]=\"filterOn ? 'on' : 'off'\"\r\n (click)=\"filter()\"\r\n >\r\n <span class=\"tooltip\">Apply filter</span>\r\n </button>\r\n </div>\r\n <button class=\"more-options\" (click)=\"toggleCollapse()\">\r\n <span *ngIf=\"!collapsed\" class=\"tooltip\">Less options</span>\r\n <span *ngIf=\"collapsed\" class=\"tooltip\">More options</span>\r\n </button>\r\n</div>\r\n" }]
9206
+ args: [{ standalone: true, selector: 'daga-diagram-buttons', imports: [CommonModule], template: "<div class=\"daga-diagram-buttons daga-{{ location }} daga-{{ direction }}\">\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"daga-zoom-in\"\r\n (click)=\"zoomIn()\"\r\n >\r\n <span class=\"daga-tooltip\">Zoom in</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"daga-zoom-out\"\r\n (click)=\"zoomOut()\"\r\n >\r\n <span class=\"daga-tooltip\">Zoom out</span>\r\n </button>\r\n <div #collapsableButtons class=\"daga-collapsable-buttons daga-collapsed\">\r\n <button\r\n *ngIf=\"enableZoom && canvas.canUserPerformAction(DiagramActions.Zoom)\"\r\n class=\"daga-center\"\r\n (click)=\"center()\"\r\n >\r\n <span class=\"daga-tooltip\">Fit diagram to screen</span>\r\n </button>\r\n <button *ngIf=\"enableUndoRedo\" class=\"daga-undo\" (click)=\"undo()\">\r\n <span class=\"daga-tooltip\">Undo</span>\r\n </button>\r\n <button *ngIf=\"enableUndoRedo\" class=\"daga-redo\" (click)=\"redo()\">\r\n <span class=\"daga-tooltip\">Redo</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableLayout && canvas.layoutFormat\"\r\n class=\"daga-layout\"\r\n (click)=\"layout()\"\r\n >\r\n <span class=\"daga-tooltip\">Apply layout</span>\r\n </button>\r\n <button\r\n *ngIf=\"enableFilter\"\r\n class=\"daga-filter\"\r\n [class]=\"filterOn ? 'daga-on' : 'daga-off'\"\r\n (click)=\"filter()\"\r\n >\r\n <span class=\"daga-tooltip\">Apply filter</span>\r\n </button>\r\n </div>\r\n <button class=\"daga-more-options\" (click)=\"toggleCollapse()\">\r\n <span *ngIf=\"!collapsed\" class=\"daga-tooltip\">Less options</span>\r\n <span *ngIf=\"collapsed\" class=\"daga-tooltip\">More options</span>\r\n </button>\r\n</div>\r\n" }]
8797
9207
  }], ctorParameters: () => [{ type: CanvasProviderService }], propDecorators: { collapsableButtons: [{
8798
9208
  type: ViewChild,
8799
9209
  args: ['collapsableButtons']
@@ -8835,7 +9245,9 @@ class ErrorsComponent {
8835
9245
  .subscribe();
8836
9246
  }
8837
9247
  selectPanel() {
8838
- return d3.select(this.errorsContainer.nativeElement).select('.error-panel');
9248
+ return d3
9249
+ .select(this.errorsContainer.nativeElement)
9250
+ .select('.daga-error-panel');
8839
9251
  }
8840
9252
  validate() {
8841
9253
  this.errors = [];
@@ -8845,23 +9257,39 @@ class ErrorsComponent {
8845
9257
  }
8846
9258
  }
8847
9259
  showError(error) {
8848
- if (error.elementId && error.propertyNames) {
9260
+ if (error.elementId &&
9261
+ (error.propertyNames === undefined || error.propertyNames.length === 0)) {
9262
+ const element = this.canvas.model.nodes.get(error.elementId) ||
9263
+ this.canvas.model.connections.get(error.elementId);
9264
+ if (element) {
9265
+ this.canvas.highlight(element);
9266
+ }
9267
+ }
9268
+ else if (error.elementId &&
9269
+ error.propertyNames !== undefined &&
9270
+ error.propertyNames.length > 0) {
8849
9271
  this.canvas.setPropertyEditorSelection(this.canvas.model.nodes.get(error.elementId) ||
8850
9272
  this.canvas.model.connections.get(error.elementId));
9273
+ const element = this.canvas.model.nodes.get(error.elementId) ||
9274
+ this.canvas.model.connections.get(error.elementId);
9275
+ if (element) {
9276
+ this.canvas.highlight(element);
9277
+ }
8851
9278
  this.canvas.parentComponent.propertyEditor?.highlightProperty(...error.propertyNames);
8852
9279
  }
8853
- else if (!error.elementId && error.propertyNames) {
9280
+ else if (!error.elementId &&
9281
+ error.propertyNames !== undefined &&
9282
+ error.propertyNames.length > 0) {
8854
9283
  this.canvas.setPropertyEditorSelection();
8855
9284
  this.canvas.parentComponent.propertyEditor?.highlightProperty(...error.propertyNames);
8856
9285
  }
8857
- // TODO: IF ERROR IS IN AN ELEMENT BUT NOT IN A SPECIFIC PROPERTY, WE COULD HIGHLIGHT THE ELEMENT
8858
9286
  }
8859
9287
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: ErrorsComponent, deps: [{ token: CanvasProviderService }], target: i0.ɵɵFactoryTarget.Component }); }
8860
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: ErrorsComponent, isStandalone: true, selector: "daga-errors", viewQueries: [{ propertyName: "errorsContainer", first: true, predicate: ["errors"], descendants: true }], ngImport: i0, template: "<div #errorsContainer class=\"errors\">\n <div\n *ngIf=\"errors.length === 0\"\n class=\"errors-summary no-errors prevent-user-select\"\n >\n <span>No errors found</span>\n </div>\n <div\n *ngIf=\"errors.length > 0\"\n class=\"errors-summary with-errors prevent-user-select\"\n >\n <span>{{ errors.length }} errors found</span>\n <div class=\"collapse-button-container\">\n <daga-collapse-button\n [collapsableSelector]=\"errorsContainer\"\n [collapsableAdditionalSelector]=\"'.error-panel'\"\n [direction]=\"Side.Top\"\n [rule]=\"'display'\"\n [collapsedValue]=\"'none'\"\n [visibleValue]=\"'block'\"\n />\n </div>\n </div>\n <div *ngIf=\"errors.length > 0\" class=\"error-panel\">\n <ol>\n <li\n *ngFor=\"let error of errors; index as i\"\n (click)=\"showError(error)\"\n [innerHTML]=\"error.message\"\n ></li>\n </ol>\n </div>\n</div>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: CollapseButtonComponent, selector: "daga-collapse-button", inputs: ["collapsableSelector", "collapsableAdditionalSelector", "collapsed", "disabled", "direction", "rule", "collapsedValue", "visibleValue"] }] }); }
9288
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: ErrorsComponent, isStandalone: true, selector: "daga-errors", viewQueries: [{ propertyName: "errorsContainer", first: true, predicate: ["errors"], descendants: true }], ngImport: i0, template: "<div #errorsContainer class=\"daga-errors\">\r\n <div\r\n *ngIf=\"errors.length === 0\"\r\n class=\"daga-errors-summary daga-no-errors daga-prevent-user-select\"\r\n >\r\n <span>No errors found</span>\r\n </div>\r\n <div\r\n *ngIf=\"errors.length > 0\"\r\n class=\"daga-errors-summary daga-with-errors daga-prevent-user-select\"\r\n >\r\n <span>{{ errors.length }} errors found</span>\r\n <div class=\"daga-collapse-button-container\">\r\n <daga-collapse-button\r\n [collapsableSelector]=\"errorsContainer\"\r\n [collapsableAdditionalSelector]=\"'.daga-error-panel'\"\r\n [direction]=\"Side.Top\"\r\n [rule]=\"'display'\"\r\n [collapsedValue]=\"'none'\"\r\n [visibleValue]=\"'block'\"\r\n />\r\n </div>\r\n </div>\r\n <div *ngIf=\"errors.length > 0\" class=\"daga-error-panel\">\r\n <ol>\r\n <li\r\n *ngFor=\"let error of errors; index as i\"\r\n (click)=\"showError(error)\"\r\n [innerHTML]=\"error.message\"\r\n ></li>\r\n </ol>\r\n </div>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: CollapseButtonComponent, selector: "daga-collapse-button", inputs: ["collapsableSelector", "collapsableAdditionalSelector", "collapsed", "disabled", "direction", "rule", "collapsedValue", "visibleValue"] }] }); }
8861
9289
  }
8862
9290
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: ErrorsComponent, decorators: [{
8863
9291
  type: Component,
8864
- args: [{ standalone: true, selector: 'daga-errors', imports: [CommonModule, CollapseButtonComponent], template: "<div #errorsContainer class=\"errors\">\n <div\n *ngIf=\"errors.length === 0\"\n class=\"errors-summary no-errors prevent-user-select\"\n >\n <span>No errors found</span>\n </div>\n <div\n *ngIf=\"errors.length > 0\"\n class=\"errors-summary with-errors prevent-user-select\"\n >\n <span>{{ errors.length }} errors found</span>\n <div class=\"collapse-button-container\">\n <daga-collapse-button\n [collapsableSelector]=\"errorsContainer\"\n [collapsableAdditionalSelector]=\"'.error-panel'\"\n [direction]=\"Side.Top\"\n [rule]=\"'display'\"\n [collapsedValue]=\"'none'\"\n [visibleValue]=\"'block'\"\n />\n </div>\n </div>\n <div *ngIf=\"errors.length > 0\" class=\"error-panel\">\n <ol>\n <li\n *ngFor=\"let error of errors; index as i\"\n (click)=\"showError(error)\"\n [innerHTML]=\"error.message\"\n ></li>\n </ol>\n </div>\n</div>\n" }]
9292
+ args: [{ standalone: true, selector: 'daga-errors', imports: [CommonModule, CollapseButtonComponent], template: "<div #errorsContainer class=\"daga-errors\">\r\n <div\r\n *ngIf=\"errors.length === 0\"\r\n class=\"daga-errors-summary daga-no-errors daga-prevent-user-select\"\r\n >\r\n <span>No errors found</span>\r\n </div>\r\n <div\r\n *ngIf=\"errors.length > 0\"\r\n class=\"daga-errors-summary daga-with-errors daga-prevent-user-select\"\r\n >\r\n <span>{{ errors.length }} errors found</span>\r\n <div class=\"daga-collapse-button-container\">\r\n <daga-collapse-button\r\n [collapsableSelector]=\"errorsContainer\"\r\n [collapsableAdditionalSelector]=\"'.daga-error-panel'\"\r\n [direction]=\"Side.Top\"\r\n [rule]=\"'display'\"\r\n [collapsedValue]=\"'none'\"\r\n [visibleValue]=\"'block'\"\r\n />\r\n </div>\r\n </div>\r\n <div *ngIf=\"errors.length > 0\" class=\"daga-error-panel\">\r\n <ol>\r\n <li\r\n *ngFor=\"let error of errors; index as i\"\r\n (click)=\"showError(error)\"\r\n [innerHTML]=\"error.message\"\r\n ></li>\r\n </ol>\r\n </div>\r\n</div>\r\n" }]
8865
9293
  }], ctorParameters: () => [{ type: CanvasProviderService }], propDecorators: { errorsContainer: [{
8866
9294
  type: ViewChild,
8867
9295
  args: ['errors']
@@ -8919,7 +9347,7 @@ class PaletteComponent {
8919
9347
  return d3.select(this.panel.nativeElement);
8920
9348
  }
8921
9349
  selectPalette() {
8922
- return this.selectPanel().select('.palette-view');
9350
+ return this.selectPanel().select('.daga-palette-view');
8923
9351
  }
8924
9352
  appendCategories(categories) {
8925
9353
  const thisComponent = this.selectPalette()
@@ -8940,14 +9368,14 @@ class PaletteComponent {
8940
9368
  thisComponent.on(Events.Change, () => {
8941
9369
  if (this.currentCategory) {
8942
9370
  this.selectPalette()
8943
- .selectAll(`.template-container.in-category`)
9371
+ .selectAll(`.daga-template-container.daga-in-category`)
8944
9372
  .remove();
8945
9373
  }
8946
9374
  const selectedKey = thisComponent.property('value');
8947
9375
  this.currentCategory = selectedKey;
8948
9376
  const templatesInCategory = categories[selectedKey] || [];
8949
9377
  for (const template of templatesInCategory) {
8950
- this.appendTemplate(template, 'in-category');
9378
+ this.appendTemplate(template, 'daga-in-category');
8951
9379
  }
8952
9380
  });
8953
9381
  if (this.currentCategory) {
@@ -8985,7 +9413,7 @@ class PaletteComponent {
8985
9413
  }
8986
9414
  const thisComponent = this.selectPalette()
8987
9415
  .append('div')
8988
- .attr('class', `template-container ${classes !== undefined ? classes : ''}`)
9416
+ .attr('class', `daga-template-container ${classes !== undefined ? classes : ''}`)
8989
9417
  .style('width', `${type.defaultWidth}px`)
8990
9418
  .style('height', `${type.defaultHeight}px`)
8991
9419
  .call(d3
@@ -9183,7 +9611,7 @@ class PaletteComponent {
9183
9611
  };
9184
9612
  thisComponent
9185
9613
  .append('text')
9186
- .attr('transform', `translate(${type.defaultWidth / 2},${type.defaultHeight / 2 + 5})`)
9614
+ .attr('transform', `translate(${(getLeftMargin(labelConfig) + type.defaultWidth) / 2},${(getTopMargin(labelConfig) + type.defaultHeight) / 2})`)
9187
9615
  .attr('x', 0)
9188
9616
  .attr('y', 0)
9189
9617
  .attr('font-size', `${labelConfig.fontSize}px`)
@@ -9200,7 +9628,7 @@ class PaletteComponent {
9200
9628
  appendConnectionTemplate(type, templateConfig, classes) {
9201
9629
  const thisComponent = this.selectPalette()
9202
9630
  .append('div')
9203
- .attr('class', `template-container ${classes !== undefined ? classes : ''}`)
9631
+ .attr('class', `daga-template-container ${classes !== undefined ? classes : ''}`)
9204
9632
  .style('width', `${templateConfig.width}px`)
9205
9633
  .style('height', `${templateConfig.height}px`)
9206
9634
  .append('svg')
@@ -9246,11 +9674,11 @@ class PaletteComponent {
9246
9674
  }
9247
9675
  }
9248
9676
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: PaletteComponent, deps: [{ token: CanvasProviderService }], target: i0.ɵɵFactoryTarget.Component }); }
9249
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: PaletteComponent, isStandalone: true, selector: "daga-palette", inputs: { palettes: "palettes", currentPalette: "currentPalette", currentCategory: "currentCategory", location: "location", direction: "direction", width: "width" }, viewQueries: [{ propertyName: "panel", first: true, predicate: ["panel"], descendants: true }], ngImport: i0, template: "<div #panel class=\"panel {{ location }} {{ direction }}\">\n <daga-collapse-button\n #collapseButton\n [direction]=\"direction\"\n [collapsableSelector]=\"panel\"\n collapsableAdditionalSelector=\".panel-content\"\n rule=\"display\"\n collapsedValue=\"none\"\n visibleValue=\"block\"\n />\n <div class=\"panel-content\">\n <div *ngIf=\"palettes.length > 1\" class=\"panel-tabs\">\n <div\n *ngFor=\"let palette of palettes\"\n class=\"panel-tab\"\n [class]=\"palette === currentPalette ? 'current-tab' : ''\"\n (click)=\"switchPalette(palette)\"\n >\n {{ palette.name }}\n </div>\n </div>\n <div class=\"palette-view\"></div>\n </div>\n</div>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: CollapseButtonComponent, selector: "daga-collapse-button", inputs: ["collapsableSelector", "collapsableAdditionalSelector", "collapsed", "disabled", "direction", "rule", "collapsedValue", "visibleValue"] }] }); }
9677
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: PaletteComponent, isStandalone: true, selector: "daga-palette", inputs: { palettes: "palettes", currentPalette: "currentPalette", currentCategory: "currentCategory", location: "location", direction: "direction", width: "width" }, viewQueries: [{ propertyName: "panel", first: true, predicate: ["panel"], descendants: true }], ngImport: i0, template: "<div #panel class=\"daga-panel daga-{{ location }} daga-{{ direction }}\">\r\n <daga-collapse-button\r\n #collapseButton\r\n [direction]=\"direction\"\r\n [collapsableSelector]=\"panel\"\r\n collapsableAdditionalSelector=\".daga-panel-content\"\r\n rule=\"display\"\r\n collapsedValue=\"none\"\r\n visibleValue=\"block\"\r\n />\r\n <div class=\"daga-panel-content\">\r\n <div *ngIf=\"palettes.length > 1\" class=\"daga-panel-tabs\">\r\n <div\r\n *ngFor=\"let palette of palettes\"\r\n class=\"daga-panel-tab\"\r\n [class]=\"palette === currentPalette ? 'daga-current-tab' : ''\"\r\n (click)=\"switchPalette(palette)\"\r\n >\r\n {{ palette.name }}\r\n </div>\r\n </div>\r\n <div class=\"daga-palette-view\"></div>\r\n </div>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: CollapseButtonComponent, selector: "daga-collapse-button", inputs: ["collapsableSelector", "collapsableAdditionalSelector", "collapsed", "disabled", "direction", "rule", "collapsedValue", "visibleValue"] }] }); }
9250
9678
  }
9251
9679
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: PaletteComponent, decorators: [{
9252
9680
  type: Component,
9253
- args: [{ standalone: true, selector: 'daga-palette', imports: [CommonModule, CollapseButtonComponent], template: "<div #panel class=\"panel {{ location }} {{ direction }}\">\n <daga-collapse-button\n #collapseButton\n [direction]=\"direction\"\n [collapsableSelector]=\"panel\"\n collapsableAdditionalSelector=\".panel-content\"\n rule=\"display\"\n collapsedValue=\"none\"\n visibleValue=\"block\"\n />\n <div class=\"panel-content\">\n <div *ngIf=\"palettes.length > 1\" class=\"panel-tabs\">\n <div\n *ngFor=\"let palette of palettes\"\n class=\"panel-tab\"\n [class]=\"palette === currentPalette ? 'current-tab' : ''\"\n (click)=\"switchPalette(palette)\"\n >\n {{ palette.name }}\n </div>\n </div>\n <div class=\"palette-view\"></div>\n </div>\n</div>\n" }]
9681
+ args: [{ standalone: true, selector: 'daga-palette', imports: [CommonModule, CollapseButtonComponent], template: "<div #panel class=\"daga-panel daga-{{ location }} daga-{{ direction }}\">\r\n <daga-collapse-button\r\n #collapseButton\r\n [direction]=\"direction\"\r\n [collapsableSelector]=\"panel\"\r\n collapsableAdditionalSelector=\".daga-panel-content\"\r\n rule=\"display\"\r\n collapsedValue=\"none\"\r\n visibleValue=\"block\"\r\n />\r\n <div class=\"daga-panel-content\">\r\n <div *ngIf=\"palettes.length > 1\" class=\"daga-panel-tabs\">\r\n <div\r\n *ngFor=\"let palette of palettes\"\r\n class=\"daga-panel-tab\"\r\n [class]=\"palette === currentPalette ? 'daga-current-tab' : ''\"\r\n (click)=\"switchPalette(palette)\"\r\n >\r\n {{ palette.name }}\r\n </div>\r\n </div>\r\n <div class=\"daga-palette-view\"></div>\r\n </div>\r\n</div>\r\n" }]
9254
9682
  }], ctorParameters: () => [{ type: CanvasProviderService }], propDecorators: { panel: [{
9255
9683
  type: ViewChild,
9256
9684
  args: ['panel']
@@ -9309,8 +9737,8 @@ class PropertySettingsComponent {
9309
9737
  let closestDropbarIndex = 0;
9310
9738
  const propertyElement = d3
9311
9739
  .select(this.element.nativeElement)
9312
- .select(`.property.${getStyleClassName(property.name)}.depth-${this.depth}`);
9313
- propertyElement.select('button.move-button').call(d3
9740
+ .select(`.daga-property.${getStyleClassName(property.name)}.daga-depth-${this.depth}`);
9741
+ propertyElement.select('button.daga-move-button').call(d3
9314
9742
  .drag()
9315
9743
  .on(DragEvents.Start, (event) => {
9316
9744
  cursorStyle(CursorStyle.Grabbing);
@@ -9349,12 +9777,12 @@ class PropertySettingsComponent {
9349
9777
  .style('height', `${propertyElementHeight}px`)
9350
9778
  .style('z-index', 1);
9351
9779
  d3.select(this.element.nativeElement)
9352
- .select(`.dropbar.index-${closestDropbarIndex}.depth-${this.depth}`)
9780
+ .select(`.daga-dropbar.daga-index-${closestDropbarIndex}.daga-depth-${this.depth}`)
9353
9781
  .style('visibility', 'hidden')
9354
9782
  .style('height', 0);
9355
9783
  closestDropbarIndex = this.getClosestDropbarIndex(pointerCoords);
9356
9784
  d3.select(this.element.nativeElement)
9357
- .select(`.dropbar.index-${closestDropbarIndex}.depth-${this.depth}`)
9785
+ .select(`.daga-dropbar.daga-index-${closestDropbarIndex}.daga-depth-${this.depth}`)
9358
9786
  .style('visibility', 'visible')
9359
9787
  .style('height', '0.25rem');
9360
9788
  })
@@ -9368,7 +9796,7 @@ class PropertySettingsComponent {
9368
9796
  .style('width', 'unset')
9369
9797
  .style('height', 'unset');
9370
9798
  d3.select(this.element.nativeElement)
9371
- .select(`.dropbar.index-${closestDropbarIndex}.depth-${this.depth}`)
9799
+ .select(`.daga-dropbar.daga-index-${closestDropbarIndex}.daga-depth-${this.depth}`)
9372
9800
  .style('visibility', 'hidden')
9373
9801
  .style('height', 0);
9374
9802
  const pointerCoords = this.canvas.getPointerLocationRelativeToScreen(event);
@@ -9390,7 +9818,7 @@ class PropertySettingsComponent {
9390
9818
  for (let i = 0; i <= propertyList.length; ++i) {
9391
9819
  const boundingRect = d3
9392
9820
  .select(this.element.nativeElement)
9393
- .select(`.dropbar.index-${i}.depth-${this.depth}`)
9821
+ .select(`.daga-dropbar.daga-index-${i}.daga-depth-${this.depth}`)
9394
9822
  .node()
9395
9823
  ?.getBoundingClientRect();
9396
9824
  if (boundingRect) {
@@ -9448,11 +9876,11 @@ class PropertySettingsComponent {
9448
9876
  this.addListeners();
9449
9877
  }
9450
9878
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: PropertySettingsComponent, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: CanvasProviderService }], target: i0.ɵɵFactoryTarget.Component }); }
9451
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: PropertySettingsComponent, isStandalone: true, selector: "daga-property-settings", inputs: { valueSet: "valueSet", depth: "depth" }, ngImport: i0, template: "<div class=\"dropbar\" [class]=\"'index-' + 0 + ' depth-' + depth\"></div>\r\n<div\r\n *ngFor=\"let property of valueSet?.displayedProperties || []; index as i\"\r\n class=\"property-and-dropbar\"\r\n [class]=\"getStyleClassName(property.name) + ' depth-' + depth\"\r\n>\r\n <div\r\n class=\"property\"\r\n [class]=\"getStyleClassName(property.name) + ' depth-' + depth\"\r\n >\r\n <div class=\"property-name\">\r\n <span>{{ property.name }}</span>\r\n <div class=\"buttons\">\r\n <button class=\"property-button move-button\">\r\n <div class=\"icon move-icon\"></div>\r\n </button>\r\n <button\r\n class=\"property-button hide-button\"\r\n (click)=\"hideProperty(property.name)\"\r\n >\r\n <div class=\"icon hide-icon\"></div>\r\n </button>\r\n </div>\r\n </div>\r\n <div *ngIf=\"property.type !== Type.Object\" class=\"property-value\">\r\n {{ asString(valueSet?.getValue(property.name)) }}\r\n </div>\r\n <div *ngIf=\"property.type === Type.Object\">\r\n <daga-property-settings\r\n [valueSet]=\"valueSet?.getSubValueSet(property.name)\"\r\n [depth]=\"depth + 1\"\r\n ></daga-property-settings>\r\n </div>\r\n </div>\r\n <div class=\"dropbar\" [class]=\"'index-' + (i + 1) + ' depth-' + depth\"></div>\r\n</div>\r\n<div class=\"property\" *ngIf=\"valueSet && valueSet.hiddenProperties.length > 0\">\r\n <p class=\"property-name\">Add property:</p>\r\n <select (change)=\"displayProperty($event)\">\r\n <option value=\"\">Select a property</option>\r\n <option\r\n *ngFor=\"let property of valueSet?.hiddenProperties || []\"\r\n [value]=\"property.name\"\r\n >\r\n {{ property.name }}\r\n </option>\r\n </select>\r\n</div>\r\n", dependencies: [{ kind: "component", type: PropertySettingsComponent, selector: "daga-property-settings", inputs: ["valueSet", "depth"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }] }); }
9879
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: PropertySettingsComponent, isStandalone: true, selector: "daga-property-settings", inputs: { valueSet: "valueSet", depth: "depth" }, ngImport: i0, template: "<div\r\n class=\"daga-dropbar\"\r\n [class]=\"'daga-index-' + 0 + ' daga-depth-' + depth\"\r\n></div>\r\n<div\r\n *ngFor=\"let property of valueSet?.displayedProperties || []; index as i\"\r\n class=\"daga-property-and-dropbar\"\r\n [class]=\"getStyleClassName(property.name) + ' daga-depth-' + depth\"\r\n>\r\n <div\r\n class=\"daga-property\"\r\n [class]=\"getStyleClassName(property.name) + ' daga-depth-' + depth\"\r\n >\r\n <div class=\"daga-property-name\">\r\n <span>{{ property.name }}</span>\r\n <div class=\"daga-buttons\">\r\n <button class=\"daga-property-button daga-move-button\">\r\n <div class=\"daga-icon daga-move-icon\"></div>\r\n </button>\r\n <button\r\n class=\"daga-property-button daga-hide-button\"\r\n (click)=\"hideProperty(property.name)\"\r\n >\r\n <div class=\"daga-icon daga-hide-icon\"></div>\r\n </button>\r\n </div>\r\n </div>\r\n <div *ngIf=\"property.type !== Type.Object\" class=\"daga-property-value\">\r\n {{ asString(valueSet?.getValue(property.name)) }}\r\n </div>\r\n <div *ngIf=\"property.type === Type.Object\">\r\n <daga-property-settings\r\n [valueSet]=\"valueSet?.getSubValueSet(property.name)\"\r\n [depth]=\"depth + 1\"\r\n ></daga-property-settings>\r\n </div>\r\n </div>\r\n <div\r\n class=\"daga-dropbar\"\r\n [class]=\"'daga-index-' + (i + 1) + ' daga-depth-' + depth\"\r\n ></div>\r\n</div>\r\n<div\r\n class=\"daga-property\"\r\n *ngIf=\"valueSet && valueSet.hiddenProperties.length > 0\"\r\n>\r\n <p class=\"daga-property-name\">Add property:</p>\r\n <select (change)=\"displayProperty($event)\">\r\n <option value=\"\">Select a property</option>\r\n <option\r\n *ngFor=\"let property of valueSet?.hiddenProperties || []\"\r\n [value]=\"property.name\"\r\n >\r\n {{ property.name }}\r\n </option>\r\n </select>\r\n</div>\r\n", dependencies: [{ kind: "component", type: PropertySettingsComponent, selector: "daga-property-settings", inputs: ["valueSet", "depth"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }] }); }
9452
9880
  }
9453
9881
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: PropertySettingsComponent, decorators: [{
9454
9882
  type: Component,
9455
- args: [{ standalone: true, selector: 'daga-property-settings', imports: [CommonModule, FormsModule], template: "<div class=\"dropbar\" [class]=\"'index-' + 0 + ' depth-' + depth\"></div>\r\n<div\r\n *ngFor=\"let property of valueSet?.displayedProperties || []; index as i\"\r\n class=\"property-and-dropbar\"\r\n [class]=\"getStyleClassName(property.name) + ' depth-' + depth\"\r\n>\r\n <div\r\n class=\"property\"\r\n [class]=\"getStyleClassName(property.name) + ' depth-' + depth\"\r\n >\r\n <div class=\"property-name\">\r\n <span>{{ property.name }}</span>\r\n <div class=\"buttons\">\r\n <button class=\"property-button move-button\">\r\n <div class=\"icon move-icon\"></div>\r\n </button>\r\n <button\r\n class=\"property-button hide-button\"\r\n (click)=\"hideProperty(property.name)\"\r\n >\r\n <div class=\"icon hide-icon\"></div>\r\n </button>\r\n </div>\r\n </div>\r\n <div *ngIf=\"property.type !== Type.Object\" class=\"property-value\">\r\n {{ asString(valueSet?.getValue(property.name)) }}\r\n </div>\r\n <div *ngIf=\"property.type === Type.Object\">\r\n <daga-property-settings\r\n [valueSet]=\"valueSet?.getSubValueSet(property.name)\"\r\n [depth]=\"depth + 1\"\r\n ></daga-property-settings>\r\n </div>\r\n </div>\r\n <div class=\"dropbar\" [class]=\"'index-' + (i + 1) + ' depth-' + depth\"></div>\r\n</div>\r\n<div class=\"property\" *ngIf=\"valueSet && valueSet.hiddenProperties.length > 0\">\r\n <p class=\"property-name\">Add property:</p>\r\n <select (change)=\"displayProperty($event)\">\r\n <option value=\"\">Select a property</option>\r\n <option\r\n *ngFor=\"let property of valueSet?.hiddenProperties || []\"\r\n [value]=\"property.name\"\r\n >\r\n {{ property.name }}\r\n </option>\r\n </select>\r\n</div>\r\n" }]
9883
+ args: [{ standalone: true, selector: 'daga-property-settings', imports: [CommonModule, FormsModule], template: "<div\r\n class=\"daga-dropbar\"\r\n [class]=\"'daga-index-' + 0 + ' daga-depth-' + depth\"\r\n></div>\r\n<div\r\n *ngFor=\"let property of valueSet?.displayedProperties || []; index as i\"\r\n class=\"daga-property-and-dropbar\"\r\n [class]=\"getStyleClassName(property.name) + ' daga-depth-' + depth\"\r\n>\r\n <div\r\n class=\"daga-property\"\r\n [class]=\"getStyleClassName(property.name) + ' daga-depth-' + depth\"\r\n >\r\n <div class=\"daga-property-name\">\r\n <span>{{ property.name }}</span>\r\n <div class=\"daga-buttons\">\r\n <button class=\"daga-property-button daga-move-button\">\r\n <div class=\"daga-icon daga-move-icon\"></div>\r\n </button>\r\n <button\r\n class=\"daga-property-button daga-hide-button\"\r\n (click)=\"hideProperty(property.name)\"\r\n >\r\n <div class=\"daga-icon daga-hide-icon\"></div>\r\n </button>\r\n </div>\r\n </div>\r\n <div *ngIf=\"property.type !== Type.Object\" class=\"daga-property-value\">\r\n {{ asString(valueSet?.getValue(property.name)) }}\r\n </div>\r\n <div *ngIf=\"property.type === Type.Object\">\r\n <daga-property-settings\r\n [valueSet]=\"valueSet?.getSubValueSet(property.name)\"\r\n [depth]=\"depth + 1\"\r\n ></daga-property-settings>\r\n </div>\r\n </div>\r\n <div\r\n class=\"daga-dropbar\"\r\n [class]=\"'daga-index-' + (i + 1) + ' daga-depth-' + depth\"\r\n ></div>\r\n</div>\r\n<div\r\n class=\"daga-property\"\r\n *ngIf=\"valueSet && valueSet.hiddenProperties.length > 0\"\r\n>\r\n <p class=\"daga-property-name\">Add property:</p>\r\n <select (change)=\"displayProperty($event)\">\r\n <option value=\"\">Select a property</option>\r\n <option\r\n *ngFor=\"let property of valueSet?.hiddenProperties || []\"\r\n [value]=\"property.name\"\r\n >\r\n {{ property.name }}\r\n </option>\r\n </select>\r\n</div>\r\n" }]
9456
9884
  }], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.ChangeDetectorRef }, { type: CanvasProviderService }], propDecorators: { valueSet: [{
9457
9885
  type: Input
9458
9886
  }], depth: [{
@@ -9638,11 +10066,11 @@ class AutocompleteComponent {
9638
10066
  }
9639
10067
  }
9640
10068
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: AutocompleteComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
9641
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: AutocompleteComponent, isStandalone: true, selector: "daga-autocomplete", inputs: { value: "value", valueInput: "valueInput", options: "options", disabled: "disabled" }, outputs: { valueChange: "valueChange" }, viewQueries: [{ propertyName: "mainElement", first: true, predicate: ["main"], descendants: true, static: true }], ngImport: i0, template: "<div\r\n #main\r\n class=\"autocomplete\"\r\n [class]=\"showOptions ? 'showing-options' : ''\"\r\n (blur)=\"closeOptions()\"\r\n>\r\n <div class=\"autocomplete-input\">\r\n <input\r\n [(ngModel)]=\"valueInput\"\r\n [disabled]=\"disabled\"\r\n (keyup)=\"onKeyup($event)\"\r\n (focus)=\"openOptions()\"\r\n (blur)=\"onLostFocus()\"\r\n />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"clear\"\r\n (click)=\"clearInput()\"\r\n ></button>\r\n </div>\r\n <div class=\"autocomplete-options\">\r\n <ul class=\"autocomplete-option-list\">\r\n <li\r\n *ngIf=\"(currentOptions?.length || 0) === 0\"\r\n class=\"autocomplete-option no-options\"\r\n >\r\n (No options)\r\n </li>\r\n <li\r\n *ngFor=\"let option of currentOptions; let index = index\"\r\n class=\"autocomplete-option\"\r\n [class]=\"index === focusIndex ? 'focused' : ''\"\r\n (mousemove)=\"focusOnOption(index)\"\r\n (click)=\"complete(option)\"\r\n >\r\n <span>{{ currentLabelStarts[index] }}</span>\r\n <span class=\"match\">{{ currentLabelMatches[index] }}</span>\r\n <span>{{ currentLabelEnds[index] }}</span>\r\n </li>\r\n </ul>\r\n </div>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] }); }
10069
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: AutocompleteComponent, isStandalone: true, selector: "daga-autocomplete", inputs: { value: "value", valueInput: "valueInput", options: "options", disabled: "disabled" }, outputs: { valueChange: "valueChange" }, viewQueries: [{ propertyName: "mainElement", first: true, predicate: ["main"], descendants: true, static: true }], ngImport: i0, template: "<div\r\n #main\r\n class=\"daga-autocomplete\"\r\n [class]=\"showOptions ? 'daga-showing-options' : ''\"\r\n (blur)=\"closeOptions()\"\r\n>\r\n <div class=\"daga-autocomplete-input\">\r\n <input\r\n [(ngModel)]=\"valueInput\"\r\n [disabled]=\"disabled\"\r\n (keyup)=\"onKeyup($event)\"\r\n (focus)=\"openOptions()\"\r\n (blur)=\"onLostFocus()\"\r\n />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"daga-clear\"\r\n (click)=\"clearInput()\"\r\n ></button>\r\n </div>\r\n <div class=\"daga-autocomplete-options\">\r\n <ul class=\"daga-autocomplete-option-list\">\r\n <li\r\n *ngIf=\"(currentOptions?.length || 0) === 0\"\r\n class=\"daga-autocomplete-option no-options\"\r\n >\r\n (No options)\r\n </li>\r\n <li\r\n *ngFor=\"let option of currentOptions; let index = index\"\r\n class=\"daga-autocomplete-option\"\r\n [class]=\"index === focusIndex ? 'daga-focused' : ''\"\r\n (mousemove)=\"focusOnOption(index)\"\r\n (click)=\"complete(option)\"\r\n >\r\n <span>{{ currentLabelStarts[index] }}</span>\r\n <span class=\"daga-match\">{{ currentLabelMatches[index] }}</span>\r\n <span>{{ currentLabelEnds[index] }}</span>\r\n </li>\r\n </ul>\r\n </div>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] }); }
9642
10070
  }
9643
10071
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: AutocompleteComponent, decorators: [{
9644
10072
  type: Component,
9645
- args: [{ standalone: true, selector: 'daga-autocomplete', imports: [CommonModule, FormsModule], template: "<div\r\n #main\r\n class=\"autocomplete\"\r\n [class]=\"showOptions ? 'showing-options' : ''\"\r\n (blur)=\"closeOptions()\"\r\n>\r\n <div class=\"autocomplete-input\">\r\n <input\r\n [(ngModel)]=\"valueInput\"\r\n [disabled]=\"disabled\"\r\n (keyup)=\"onKeyup($event)\"\r\n (focus)=\"openOptions()\"\r\n (blur)=\"onLostFocus()\"\r\n />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"clear\"\r\n (click)=\"clearInput()\"\r\n ></button>\r\n </div>\r\n <div class=\"autocomplete-options\">\r\n <ul class=\"autocomplete-option-list\">\r\n <li\r\n *ngIf=\"(currentOptions?.length || 0) === 0\"\r\n class=\"autocomplete-option no-options\"\r\n >\r\n (No options)\r\n </li>\r\n <li\r\n *ngFor=\"let option of currentOptions; let index = index\"\r\n class=\"autocomplete-option\"\r\n [class]=\"index === focusIndex ? 'focused' : ''\"\r\n (mousemove)=\"focusOnOption(index)\"\r\n (click)=\"complete(option)\"\r\n >\r\n <span>{{ currentLabelStarts[index] }}</span>\r\n <span class=\"match\">{{ currentLabelMatches[index] }}</span>\r\n <span>{{ currentLabelEnds[index] }}</span>\r\n </li>\r\n </ul>\r\n </div>\r\n</div>\r\n" }]
10073
+ args: [{ standalone: true, selector: 'daga-autocomplete', imports: [CommonModule, FormsModule], template: "<div\r\n #main\r\n class=\"daga-autocomplete\"\r\n [class]=\"showOptions ? 'daga-showing-options' : ''\"\r\n (blur)=\"closeOptions()\"\r\n>\r\n <div class=\"daga-autocomplete-input\">\r\n <input\r\n [(ngModel)]=\"valueInput\"\r\n [disabled]=\"disabled\"\r\n (keyup)=\"onKeyup($event)\"\r\n (focus)=\"openOptions()\"\r\n (blur)=\"onLostFocus()\"\r\n />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"daga-clear\"\r\n (click)=\"clearInput()\"\r\n ></button>\r\n </div>\r\n <div class=\"daga-autocomplete-options\">\r\n <ul class=\"daga-autocomplete-option-list\">\r\n <li\r\n *ngIf=\"(currentOptions?.length || 0) === 0\"\r\n class=\"daga-autocomplete-option no-options\"\r\n >\r\n (No options)\r\n </li>\r\n <li\r\n *ngFor=\"let option of currentOptions; let index = index\"\r\n class=\"daga-autocomplete-option\"\r\n [class]=\"index === focusIndex ? 'daga-focused' : ''\"\r\n (mousemove)=\"focusOnOption(index)\"\r\n (click)=\"complete(option)\"\r\n >\r\n <span>{{ currentLabelStarts[index] }}</span>\r\n <span class=\"daga-match\">{{ currentLabelMatches[index] }}</span>\r\n <span>{{ currentLabelEnds[index] }}</span>\r\n </li>\r\n </ul>\r\n </div>\r\n</div>\r\n" }]
9646
10074
  }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { mainElement: [{
9647
10075
  type: ViewChild,
9648
10076
  args: ['main', { static: true }]
@@ -9755,11 +10183,11 @@ class OptionListEditorComponent {
9755
10183
  }
9756
10184
  }
9757
10185
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: OptionListEditorComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
9758
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: OptionListEditorComponent, isStandalone: true, selector: "daga-option-list-editor", inputs: { value: "value", options: "options", valueInput: "valueInput", allowRepeats: "allowRepeats", optionsNotPresentInValue: "optionsNotPresentInValue", disabled: "disabled" }, outputs: { valueChange: "valueChange" }, ngImport: i0, template: "<div *ngFor=\"let item of value; let index = index\" class=\"value-item-element\">\r\n <span class=\"input\">{{ labelsOfValue[index] }}</span>\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"property-button\"\r\n (click)=\"removeFromValue(index)\"\r\n >\r\n <div class=\"icon close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"value-item-input\">\r\n <div class=\"input relatively-positioned\">\r\n <daga-autocomplete\r\n [disabled]=\"disabled\"\r\n [options]=\"allowRepeats ? options || [] : optionsNotPresentInValue || []\"\r\n [(value)]=\"valueInput\"\r\n />\r\n </div>\r\n <button class=\"property-button\" (click)=\"addToValue()\">\r\n <div class=\"icon add-icon\"></div>\r\n </button>\r\n</div>\r\n", dependencies: [{ kind: "component", type: AutocompleteComponent, selector: "daga-autocomplete", inputs: ["value", "valueInput", "options", "disabled"], outputs: ["valueChange"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: FormsModule }] }); }
10186
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: OptionListEditorComponent, isStandalone: true, selector: "daga-option-list-editor", inputs: { value: "value", options: "options", valueInput: "valueInput", allowRepeats: "allowRepeats", optionsNotPresentInValue: "optionsNotPresentInValue", disabled: "disabled" }, outputs: { valueChange: "valueChange" }, ngImport: i0, template: "<div\r\n *ngFor=\"let item of value; let index = index\"\r\n class=\"daga-value-item-element\"\r\n>\r\n <span class=\"daga-input\">{{ labelsOfValue[index] }}</span>\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"daga-property-button\"\r\n (click)=\"removeFromValue(index)\"\r\n >\r\n <div class=\"daga-icon daga-close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"daga-value-item-input\">\r\n <div class=\"daga-input daga-relatively-positioned\">\r\n <daga-autocomplete\r\n [disabled]=\"disabled\"\r\n [options]=\"allowRepeats ? options || [] : optionsNotPresentInValue || []\"\r\n [(value)]=\"valueInput\"\r\n />\r\n </div>\r\n <button class=\"daga-property-button\" (click)=\"addToValue()\">\r\n <div class=\"daga-icon daga-add-icon\"></div>\r\n </button>\r\n</div>\r\n", dependencies: [{ kind: "component", type: AutocompleteComponent, selector: "daga-autocomplete", inputs: ["value", "valueInput", "options", "disabled"], outputs: ["valueChange"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: FormsModule }] }); }
9759
10187
  }
9760
10188
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: OptionListEditorComponent, decorators: [{
9761
10189
  type: Component,
9762
- args: [{ standalone: true, selector: 'daga-option-list-editor', imports: [AutocompleteComponent, CommonModule, FormsModule], template: "<div *ngFor=\"let item of value; let index = index\" class=\"value-item-element\">\r\n <span class=\"input\">{{ labelsOfValue[index] }}</span>\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"property-button\"\r\n (click)=\"removeFromValue(index)\"\r\n >\r\n <div class=\"icon close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"value-item-input\">\r\n <div class=\"input relatively-positioned\">\r\n <daga-autocomplete\r\n [disabled]=\"disabled\"\r\n [options]=\"allowRepeats ? options || [] : optionsNotPresentInValue || []\"\r\n [(value)]=\"valueInput\"\r\n />\r\n </div>\r\n <button class=\"property-button\" (click)=\"addToValue()\">\r\n <div class=\"icon add-icon\"></div>\r\n </button>\r\n</div>\r\n" }]
10190
+ args: [{ standalone: true, selector: 'daga-option-list-editor', imports: [AutocompleteComponent, CommonModule, FormsModule], template: "<div\r\n *ngFor=\"let item of value; let index = index\"\r\n class=\"daga-value-item-element\"\r\n>\r\n <span class=\"daga-input\">{{ labelsOfValue[index] }}</span>\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"daga-property-button\"\r\n (click)=\"removeFromValue(index)\"\r\n >\r\n <div class=\"daga-icon daga-close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"daga-value-item-input\">\r\n <div class=\"daga-input daga-relatively-positioned\">\r\n <daga-autocomplete\r\n [disabled]=\"disabled\"\r\n [options]=\"allowRepeats ? options || [] : optionsNotPresentInValue || []\"\r\n [(value)]=\"valueInput\"\r\n />\r\n </div>\r\n <button class=\"daga-property-button\" (click)=\"addToValue()\">\r\n <div class=\"daga-icon daga-add-icon\"></div>\r\n </button>\r\n</div>\r\n" }]
9763
10191
  }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { value: [{
9764
10192
  type: Input
9765
10193
  }], options: [{
@@ -9850,11 +10278,11 @@ class TextListEditorComponent {
9850
10278
  }
9851
10279
  }
9852
10280
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: TextListEditorComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
9853
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: TextListEditorComponent, isStandalone: true, selector: "daga-text-list-editor", inputs: { value: "value", valueInput: "valueInput", allowRepeats: "allowRepeats", disabled: "disabled" }, outputs: { valueChange: "valueChange" }, ngImport: i0, template: "<div *ngFor=\"let item of value; let index = index\" class=\"value-item-element\">\r\n <input\r\n class=\"input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item\"\r\n (focusout)=\"editFromValue(getValueFromEvent($event), index)\"\r\n />\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"property-button\"\r\n (click)=\"removeFromValue(index)\"\r\n >\r\n <div class=\"icon close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"value-item-input\">\r\n <div class=\"input relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"valueInput\" />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"clear\"\r\n (click)=\"clearInput()\"\r\n ></button>\r\n </div>\r\n <button class=\"property-button\" (click)=\"addToValue()\">\r\n <div class=\"icon add-icon\"></div>\r\n </button>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] }); }
10281
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: TextListEditorComponent, isStandalone: true, selector: "daga-text-list-editor", inputs: { value: "value", valueInput: "valueInput", allowRepeats: "allowRepeats", disabled: "disabled" }, outputs: { valueChange: "valueChange" }, ngImport: i0, template: "<div\r\n *ngFor=\"let item of value; let index = index\"\r\n class=\"daga-value-item-element\"\r\n>\r\n <input\r\n class=\"daga-input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item\"\r\n (focusout)=\"editFromValue(getValueFromEvent($event), index)\"\r\n />\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"daga-property-button\"\r\n (click)=\"removeFromValue(index)\"\r\n >\r\n <div class=\"icon close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"daga-value-item-input\">\r\n <div class=\"daga-input daga-relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"valueInput\" />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"daga-clear\"\r\n (click)=\"clearInput()\"\r\n ></button>\r\n </div>\r\n <button class=\"daga-property-button\" (click)=\"addToValue()\">\r\n <div class=\"daga-icon daga-add-icon\"></div>\r\n </button>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] }); }
9854
10282
  }
9855
10283
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: TextListEditorComponent, decorators: [{
9856
10284
  type: Component,
9857
- args: [{ standalone: true, selector: 'daga-text-list-editor', imports: [CommonModule, FormsModule], template: "<div *ngFor=\"let item of value; let index = index\" class=\"value-item-element\">\r\n <input\r\n class=\"input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item\"\r\n (focusout)=\"editFromValue(getValueFromEvent($event), index)\"\r\n />\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"property-button\"\r\n (click)=\"removeFromValue(index)\"\r\n >\r\n <div class=\"icon close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"value-item-input\">\r\n <div class=\"input relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"valueInput\" />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"clear\"\r\n (click)=\"clearInput()\"\r\n ></button>\r\n </div>\r\n <button class=\"property-button\" (click)=\"addToValue()\">\r\n <div class=\"icon add-icon\"></div>\r\n </button>\r\n</div>\r\n" }]
10285
+ args: [{ standalone: true, selector: 'daga-text-list-editor', imports: [CommonModule, FormsModule], template: "<div\r\n *ngFor=\"let item of value; let index = index\"\r\n class=\"daga-value-item-element\"\r\n>\r\n <input\r\n class=\"daga-input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item\"\r\n (focusout)=\"editFromValue(getValueFromEvent($event), index)\"\r\n />\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"daga-property-button\"\r\n (click)=\"removeFromValue(index)\"\r\n >\r\n <div class=\"icon close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"daga-value-item-input\">\r\n <div class=\"daga-input daga-relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"valueInput\" />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"daga-clear\"\r\n (click)=\"clearInput()\"\r\n ></button>\r\n </div>\r\n <button class=\"daga-property-button\" (click)=\"addToValue()\">\r\n <div class=\"daga-icon daga-add-icon\"></div>\r\n </button>\r\n</div>\r\n" }]
9858
10286
  }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { value: [{
9859
10287
  type: Input
9860
10288
  }], valueInput: [{
@@ -9941,11 +10369,11 @@ class TextMapEditorComponent {
9941
10369
  }
9942
10370
  }
9943
10371
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: TextMapEditorComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
9944
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: TextMapEditorComponent, isStandalone: true, selector: "daga-text-map-editor", inputs: { value: "value", keyInput: "keyInput", valueInput: "valueInput", disabled: "disabled" }, outputs: { valueChange: "valueChange" }, ngImport: i0, template: "<div *ngFor=\"let item of value | keyvalue\" class=\"value-item-element\">\r\n <input\r\n class=\"input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item.key\"\r\n (focusout)=\"editKey(item.key, getValueFromEvent($event))\"\r\n />\r\n <input\r\n class=\"input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item.value\"\r\n (focusout)=\"editValue(item.key, getValueFromEvent($event))\"\r\n />\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"property-button\"\r\n (click)=\"removeFromValue(item.key)\"\r\n >\r\n <div class=\"icon close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"value-item-input\">\r\n <div class=\"input relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"keyInput\" />\r\n <button\r\n *ngIf=\"keyInput !== ''\"\r\n class=\"clear\"\r\n (click)=\"clearKeyInput()\"\r\n ></button>\r\n </div>\r\n <div class=\"input relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"valueInput\" />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"clear\"\r\n (click)=\"clearValueInput()\"\r\n ></button>\r\n </div>\r\n <button class=\"property-button\" (click)=\"addToValue()\">\r\n <div class=\"icon add-icon\"></div>\r\n </button>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1.KeyValuePipe, name: "keyvalue" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] }); }
10372
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: TextMapEditorComponent, isStandalone: true, selector: "daga-text-map-editor", inputs: { value: "value", keyInput: "keyInput", valueInput: "valueInput", disabled: "disabled" }, outputs: { valueChange: "valueChange" }, ngImport: i0, template: "<div *ngFor=\"let item of value | keyvalue\" class=\"daga-value-item-element\">\r\n <input\r\n class=\"daga-input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item.key\"\r\n (focusout)=\"editKey(item.key, getValueFromEvent($event))\"\r\n />\r\n <input\r\n class=\"daga-input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item.value\"\r\n (focusout)=\"editValue(item.key, getValueFromEvent($event))\"\r\n />\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"daga-property-button\"\r\n (click)=\"removeFromValue(item.key)\"\r\n >\r\n <div class=\"icon close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"daga-value-item-input\">\r\n <div class=\"daga-input daga-relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"keyInput\" />\r\n <button\r\n *ngIf=\"keyInput !== ''\"\r\n class=\"daga-clear\"\r\n (click)=\"clearKeyInput()\"\r\n ></button>\r\n </div>\r\n <div class=\"daga-input daga-relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"valueInput\" />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"daga-clear\"\r\n (click)=\"clearValueInput()\"\r\n ></button>\r\n </div>\r\n <button class=\"daga-property-button\" (click)=\"addToValue()\">\r\n <div class=\"daga-icon daga-add-icon\"></div>\r\n </button>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1.KeyValuePipe, name: "keyvalue" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] }); }
9945
10373
  }
9946
10374
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: TextMapEditorComponent, decorators: [{
9947
10375
  type: Component,
9948
- args: [{ standalone: true, selector: 'daga-text-map-editor', imports: [CommonModule, FormsModule], template: "<div *ngFor=\"let item of value | keyvalue\" class=\"value-item-element\">\r\n <input\r\n class=\"input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item.key\"\r\n (focusout)=\"editKey(item.key, getValueFromEvent($event))\"\r\n />\r\n <input\r\n class=\"input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item.value\"\r\n (focusout)=\"editValue(item.key, getValueFromEvent($event))\"\r\n />\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"property-button\"\r\n (click)=\"removeFromValue(item.key)\"\r\n >\r\n <div class=\"icon close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"value-item-input\">\r\n <div class=\"input relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"keyInput\" />\r\n <button\r\n *ngIf=\"keyInput !== ''\"\r\n class=\"clear\"\r\n (click)=\"clearKeyInput()\"\r\n ></button>\r\n </div>\r\n <div class=\"input relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"valueInput\" />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"clear\"\r\n (click)=\"clearValueInput()\"\r\n ></button>\r\n </div>\r\n <button class=\"property-button\" (click)=\"addToValue()\">\r\n <div class=\"icon add-icon\"></div>\r\n </button>\r\n</div>\r\n" }]
10376
+ args: [{ standalone: true, selector: 'daga-text-map-editor', imports: [CommonModule, FormsModule], template: "<div *ngFor=\"let item of value | keyvalue\" class=\"daga-value-item-element\">\r\n <input\r\n class=\"daga-input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item.key\"\r\n (focusout)=\"editKey(item.key, getValueFromEvent($event))\"\r\n />\r\n <input\r\n class=\"daga-input\"\r\n type=\"text\"\r\n [disabled]=\"disabled\"\r\n [value]=\"item.value\"\r\n (focusout)=\"editValue(item.key, getValueFromEvent($event))\"\r\n />\r\n <button\r\n *ngIf=\"!disabled\"\r\n class=\"daga-property-button\"\r\n (click)=\"removeFromValue(item.key)\"\r\n >\r\n <div class=\"icon close-icon\"></div>\r\n </button>\r\n</div>\r\n<div *ngIf=\"!disabled\" class=\"daga-value-item-input\">\r\n <div class=\"daga-input daga-relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"keyInput\" />\r\n <button\r\n *ngIf=\"keyInput !== ''\"\r\n class=\"daga-clear\"\r\n (click)=\"clearKeyInput()\"\r\n ></button>\r\n </div>\r\n <div class=\"daga-input daga-relatively-positioned\">\r\n <input type=\"text\" (keyup)=\"onKeyUp($event)\" [(ngModel)]=\"valueInput\" />\r\n <button\r\n *ngIf=\"valueInput !== ''\"\r\n class=\"daga-clear\"\r\n (click)=\"clearValueInput()\"\r\n ></button>\r\n </div>\r\n <button class=\"daga-property-button\" (click)=\"addToValue()\">\r\n <div class=\"daga-icon daga-add-icon\"></div>\r\n </button>\r\n</div>\r\n" }]
9949
10377
  }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { value: [{
9950
10378
  type: Input
9951
10379
  }], keyInput: [{
@@ -10021,7 +10449,7 @@ class ObjectEditorComponent {
10021
10449
  return new Date(string);
10022
10450
  }
10023
10451
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: ObjectEditorComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: CanvasProviderService }], target: i0.ɵɵFactoryTarget.Component }); }
10024
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: ObjectEditorComponent, isStandalone: true, selector: "daga-object-editor", inputs: { valueSet: "valueSet", depth: "depth" }, ngImport: i0, template: "<div\r\n *ngFor=\"let property of valueSet?.displayedProperties || []\"\r\n class=\"property\"\r\n [class]=\"getStyleClassName(property.name) + ' depth-' + depth\"\r\n>\r\n <p class=\"property-name\">\r\n {{ property.name }}\r\n </p>\r\n\r\n <input\r\n *ngIf=\"property.type === Type.Text\"\r\n type=\"text\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <textarea\r\n *ngIf=\"property.type === Type.TextArea\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n ></textarea>\r\n <input\r\n *ngIf=\"property.type === Type.Number\"\r\n type=\"number\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Color\"\r\n type=\"text\"\r\n pattern=\"#\\d{6}\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Datetime\"\r\n type=\"datetime-local\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"dateToLocalDatetimeString(valueSet?.getValue(property.name))\"\r\n (ngModelChange)=\"setValue(property, localDatetimeStringToDate($event))\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Date\"\r\n type=\"date\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Time\"\r\n type=\"time\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Url\"\r\n type=\"url\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <div class=\"radio\" *ngIf=\"property.type === Type.Boolean\">\r\n <label class=\"radio-item radio-start\">\r\n <input\r\n type=\"radio\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [name]=\"property.name\"\r\n value=\"false\"\r\n [checked]=\"valueSet?.getValue(property.name) === false\"\r\n (change)=\"setValue(property, false)\"\r\n />\r\n No\r\n </label>\r\n <label class=\"radio-item radio-end\">\r\n <input\r\n type=\"radio\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [name]=\"property.name\"\r\n value=\"true\"\r\n [checked]=\"valueSet?.getValue(property.name) === true\"\r\n (change)=\"setValue(property, true)\"\r\n />\r\n Yes\r\n </label>\r\n </div>\r\n <div class=\"relatively-positioned\" *ngIf=\"property.type === Type.Option\">\r\n <daga-autocomplete\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [options]=\"property.options || []\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n />\r\n </div>\r\n <daga-option-list-editor\r\n *ngIf=\"\r\n property.type === Type.OptionList || property.type === Type.OptionSet\r\n \"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [allowRepeats]=\"property.type === Type.OptionList\"\r\n [options]=\"property.options || []\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-option-list-editor>\r\n <daga-text-list-editor\r\n *ngIf=\"property.type === Type.TextList || property.type === Type.TextSet\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [allowRepeats]=\"property.type === Type.TextList\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-text-list-editor>\r\n <daga-text-map-editor\r\n *ngIf=\"property.type === Type.TextMap\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-text-map-editor>\r\n <div *ngIf=\"property.type === Type.Object\" class=\"left-bar\">\r\n <daga-object-editor\r\n [valueSet]=\"valueSet?.getSubValueSet(property.name)\"\r\n [depth]=\"depth + 1\"\r\n ></daga-object-editor>\r\n </div>\r\n</div>\r\n", dependencies: [{ kind: "component", type: ObjectEditorComponent, selector: "daga-object-editor", inputs: ["valueSet", "depth"] }, { kind: "component", type: AutocompleteComponent, selector: "daga-autocomplete", inputs: ["value", "valueInput", "options", "disabled"], outputs: ["valueChange"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: OptionListEditorComponent, selector: "daga-option-list-editor", inputs: ["value", "options", "valueInput", "allowRepeats", "optionsNotPresentInValue", "disabled"], outputs: ["valueChange"] }, { kind: "component", type: TextListEditorComponent, selector: "daga-text-list-editor", inputs: ["value", "valueInput", "allowRepeats", "disabled"], outputs: ["valueChange"] }, { kind: "component", type: TextMapEditorComponent, selector: "daga-text-map-editor", inputs: ["value", "keyInput", "valueInput", "disabled"], outputs: ["valueChange"] }] }); }
10452
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: ObjectEditorComponent, isStandalone: true, selector: "daga-object-editor", inputs: { valueSet: "valueSet", depth: "depth" }, ngImport: i0, template: "<div\r\n *ngFor=\"let property of valueSet?.displayedProperties || []\"\r\n class=\"daga-property\"\r\n [class]=\"getStyleClassName(property.name) + ' daga-depth-' + depth\"\r\n>\r\n <p class=\"daga-property-name\">\r\n {{ property.name }}\r\n </p>\r\n\r\n <input\r\n *ngIf=\"property.type === Type.Text\"\r\n type=\"daga-text\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <textarea\r\n *ngIf=\"property.type === Type.TextArea\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n ></textarea>\r\n <input\r\n *ngIf=\"property.type === Type.Number\"\r\n type=\"number\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Color\"\r\n type=\"text\"\r\n pattern=\"#\\d{6}\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Datetime\"\r\n type=\"datetime-local\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"dateToLocalDatetimeString(valueSet?.getValue(property.name))\"\r\n (ngModelChange)=\"setValue(property, localDatetimeStringToDate($event))\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Date\"\r\n type=\"date\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Time\"\r\n type=\"time\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Url\"\r\n type=\"url\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <div class=\"daga-radio\" *ngIf=\"property.type === Type.Boolean\">\r\n <label class=\"daga-radio-item daga-radio-start\">\r\n <input\r\n type=\"radio\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [name]=\"property.name\"\r\n value=\"false\"\r\n [checked]=\"valueSet?.getValue(property.name) === false\"\r\n (change)=\"setValue(property, false)\"\r\n />\r\n No\r\n </label>\r\n <label class=\"daga-radio-item daga-radio-end\">\r\n <input\r\n type=\"radio\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [name]=\"property.name\"\r\n value=\"true\"\r\n [checked]=\"valueSet?.getValue(property.name) === true\"\r\n (change)=\"setValue(property, true)\"\r\n />\r\n Yes\r\n </label>\r\n </div>\r\n <div class=\"daga-relatively-positioned\" *ngIf=\"property.type === Type.Option\">\r\n <daga-autocomplete\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [options]=\"property.options || []\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n />\r\n </div>\r\n <daga-option-list-editor\r\n *ngIf=\"\r\n property.type === Type.OptionList || property.type === Type.OptionSet\r\n \"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [allowRepeats]=\"property.type === Type.OptionList\"\r\n [options]=\"property.options || []\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-option-list-editor>\r\n <daga-text-list-editor\r\n *ngIf=\"property.type === Type.TextList || property.type === Type.TextSet\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [allowRepeats]=\"property.type === Type.TextList\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-text-list-editor>\r\n <daga-text-map-editor\r\n *ngIf=\"property.type === Type.TextMap\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-text-map-editor>\r\n <div *ngIf=\"property.type === Type.Object\" class=\"daga-left-bar\">\r\n <daga-object-editor\r\n [valueSet]=\"valueSet?.getSubValueSet(property.name)\"\r\n [depth]=\"depth + 1\"\r\n ></daga-object-editor>\r\n </div>\r\n</div>\r\n", dependencies: [{ kind: "component", type: ObjectEditorComponent, selector: "daga-object-editor", inputs: ["valueSet", "depth"] }, { kind: "component", type: AutocompleteComponent, selector: "daga-autocomplete", inputs: ["value", "valueInput", "options", "disabled"], outputs: ["valueChange"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: OptionListEditorComponent, selector: "daga-option-list-editor", inputs: ["value", "options", "valueInput", "allowRepeats", "optionsNotPresentInValue", "disabled"], outputs: ["valueChange"] }, { kind: "component", type: TextListEditorComponent, selector: "daga-text-list-editor", inputs: ["value", "valueInput", "allowRepeats", "disabled"], outputs: ["valueChange"] }, { kind: "component", type: TextMapEditorComponent, selector: "daga-text-map-editor", inputs: ["value", "keyInput", "valueInput", "disabled"], outputs: ["valueChange"] }] }); }
10025
10453
  }
10026
10454
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: ObjectEditorComponent, decorators: [{
10027
10455
  type: Component,
@@ -10032,13 +10460,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
10032
10460
  OptionListEditorComponent,
10033
10461
  TextListEditorComponent,
10034
10462
  TextMapEditorComponent
10035
- ], template: "<div\r\n *ngFor=\"let property of valueSet?.displayedProperties || []\"\r\n class=\"property\"\r\n [class]=\"getStyleClassName(property.name) + ' depth-' + depth\"\r\n>\r\n <p class=\"property-name\">\r\n {{ property.name }}\r\n </p>\r\n\r\n <input\r\n *ngIf=\"property.type === Type.Text\"\r\n type=\"text\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <textarea\r\n *ngIf=\"property.type === Type.TextArea\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n ></textarea>\r\n <input\r\n *ngIf=\"property.type === Type.Number\"\r\n type=\"number\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Color\"\r\n type=\"text\"\r\n pattern=\"#\\d{6}\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Datetime\"\r\n type=\"datetime-local\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"dateToLocalDatetimeString(valueSet?.getValue(property.name))\"\r\n (ngModelChange)=\"setValue(property, localDatetimeStringToDate($event))\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Date\"\r\n type=\"date\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Time\"\r\n type=\"time\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Url\"\r\n type=\"url\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <div class=\"radio\" *ngIf=\"property.type === Type.Boolean\">\r\n <label class=\"radio-item radio-start\">\r\n <input\r\n type=\"radio\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [name]=\"property.name\"\r\n value=\"false\"\r\n [checked]=\"valueSet?.getValue(property.name) === false\"\r\n (change)=\"setValue(property, false)\"\r\n />\r\n No\r\n </label>\r\n <label class=\"radio-item radio-end\">\r\n <input\r\n type=\"radio\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [name]=\"property.name\"\r\n value=\"true\"\r\n [checked]=\"valueSet?.getValue(property.name) === true\"\r\n (change)=\"setValue(property, true)\"\r\n />\r\n Yes\r\n </label>\r\n </div>\r\n <div class=\"relatively-positioned\" *ngIf=\"property.type === Type.Option\">\r\n <daga-autocomplete\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [options]=\"property.options || []\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n />\r\n </div>\r\n <daga-option-list-editor\r\n *ngIf=\"\r\n property.type === Type.OptionList || property.type === Type.OptionSet\r\n \"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [allowRepeats]=\"property.type === Type.OptionList\"\r\n [options]=\"property.options || []\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-option-list-editor>\r\n <daga-text-list-editor\r\n *ngIf=\"property.type === Type.TextList || property.type === Type.TextSet\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [allowRepeats]=\"property.type === Type.TextList\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-text-list-editor>\r\n <daga-text-map-editor\r\n *ngIf=\"property.type === Type.TextMap\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-text-map-editor>\r\n <div *ngIf=\"property.type === Type.Object\" class=\"left-bar\">\r\n <daga-object-editor\r\n [valueSet]=\"valueSet?.getSubValueSet(property.name)\"\r\n [depth]=\"depth + 1\"\r\n ></daga-object-editor>\r\n </div>\r\n</div>\r\n" }]
10463
+ ], template: "<div\r\n *ngFor=\"let property of valueSet?.displayedProperties || []\"\r\n class=\"daga-property\"\r\n [class]=\"getStyleClassName(property.name) + ' daga-depth-' + depth\"\r\n>\r\n <p class=\"daga-property-name\">\r\n {{ property.name }}\r\n </p>\r\n\r\n <input\r\n *ngIf=\"property.type === Type.Text\"\r\n type=\"daga-text\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <textarea\r\n *ngIf=\"property.type === Type.TextArea\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n ></textarea>\r\n <input\r\n *ngIf=\"property.type === Type.Number\"\r\n type=\"number\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Color\"\r\n type=\"text\"\r\n pattern=\"#\\d{6}\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Datetime\"\r\n type=\"datetime-local\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"dateToLocalDatetimeString(valueSet?.getValue(property.name))\"\r\n (ngModelChange)=\"setValue(property, localDatetimeStringToDate($event))\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Date\"\r\n type=\"date\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Time\"\r\n type=\"time\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <input\r\n *ngIf=\"property.type === Type.Url\"\r\n type=\"url\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [ngModel]=\"valueSet?.getValue(property.name)\"\r\n (ngModelChange)=\"setValue(property, $event)\"\r\n />\r\n <div class=\"daga-radio\" *ngIf=\"property.type === Type.Boolean\">\r\n <label class=\"daga-radio-item daga-radio-start\">\r\n <input\r\n type=\"radio\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [name]=\"property.name\"\r\n value=\"false\"\r\n [checked]=\"valueSet?.getValue(property.name) === false\"\r\n (change)=\"setValue(property, false)\"\r\n />\r\n No\r\n </label>\r\n <label class=\"daga-radio-item daga-radio-end\">\r\n <input\r\n type=\"radio\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [name]=\"property.name\"\r\n value=\"true\"\r\n [checked]=\"valueSet?.getValue(property.name) === true\"\r\n (change)=\"setValue(property, true)\"\r\n />\r\n Yes\r\n </label>\r\n </div>\r\n <div class=\"daga-relatively-positioned\" *ngIf=\"property.type === Type.Option\">\r\n <daga-autocomplete\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [options]=\"property.options || []\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n />\r\n </div>\r\n <daga-option-list-editor\r\n *ngIf=\"\r\n property.type === Type.OptionList || property.type === Type.OptionSet\r\n \"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [allowRepeats]=\"property.type === Type.OptionList\"\r\n [options]=\"property.options || []\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-option-list-editor>\r\n <daga-text-list-editor\r\n *ngIf=\"property.type === Type.TextList || property.type === Type.TextSet\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [allowRepeats]=\"property.type === Type.TextList\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-text-list-editor>\r\n <daga-text-map-editor\r\n *ngIf=\"property.type === Type.TextMap\"\r\n [disabled]=\"!property.editable || !userCanEdit\"\r\n [value]=\"valueSet?.getValue(property.name)\"\r\n (valueChange)=\"setValue(property, $event)\"\r\n ></daga-text-map-editor>\r\n <div *ngIf=\"property.type === Type.Object\" class=\"daga-left-bar\">\r\n <daga-object-editor\r\n [valueSet]=\"valueSet?.getSubValueSet(property.name)\"\r\n [depth]=\"depth + 1\"\r\n ></daga-object-editor>\r\n </div>\r\n</div>\r\n" }]
10036
10464
  }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: CanvasProviderService }], propDecorators: { valueSet: [{
10037
10465
  type: Input
10038
10466
  }], depth: [{
10039
10467
  type: Input
10040
10468
  }] } });
10041
10469
 
10470
+ /**
10471
+ * Duration of the highlight property animation in milliseconds.
10472
+ */
10473
+ const HIGHLIGHT_ANIMATION_DURATION_MS = 1000;
10042
10474
  /**
10043
10475
  * Editor of the values of a value set.
10044
10476
  * @see ValueSet
@@ -10078,14 +10510,14 @@ class PropertyEditorComponent {
10078
10510
  let selector = '';
10079
10511
  let depth = 0;
10080
10512
  for (const propertyName of propertyNames) {
10081
- selector += ` .property.${getStyleClassName(propertyName)}.depth-${depth}`;
10513
+ selector += ` .daga-property.${getStyleClassName(propertyName)}.daga-depth-${depth}`;
10082
10514
  ++depth;
10083
10515
  }
10084
10516
  if (this.valueSet) {
10085
10517
  d3.select(this.panel.nativeElement)
10086
10518
  .select(selector)
10087
10519
  .transition()
10088
- .duration(1000)
10520
+ .duration(HIGHLIGHT_ANIMATION_DURATION_MS)
10089
10521
  .ease(d3.easeLinear)
10090
10522
  .styleTween('background-color', () => {
10091
10523
  const interpolator = d3.interpolate('rgba(255, 0, 0, 0)', 'rgba(255, 0, 0, 0.4)');
@@ -10094,7 +10526,7 @@ class PropertyEditorComponent {
10094
10526
  }
10095
10527
  }
10096
10528
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: PropertyEditorComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
10097
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: PropertyEditorComponent, isStandalone: true, selector: "daga-property-editor", inputs: { location: "location", direction: "direction", width: "width", valueSet: "valueSet" }, viewQueries: [{ propertyName: "panel", first: true, predicate: ["panel"], descendants: true }], ngImport: i0, template: "<div #panel class=\"panel bottom {{ location }} {{ direction }}\">\r\n <daga-collapse-button\r\n #collapse\r\n [disabled]=\"\r\n !valueSet ||\r\n !valueSet.propertySet ||\r\n !valueSet.propertySet.hasProperties()\r\n \"\r\n [direction]=\"direction\"\r\n [collapsableSelector]=\"panel\"\r\n collapsableAdditionalSelector=\".panel-content\"\r\n rule=\"display\"\r\n collapsedValue=\"none\"\r\n visibleValue=\"block\"\r\n />\r\n <div\r\n *ngIf=\"\r\n valueSet &&\r\n valueSet.propertySet &&\r\n valueSet.propertySet.hasProperties() &&\r\n !collapse.collapsed\r\n \"\r\n class=\"panel-content\"\r\n >\r\n <p *ngIf=\"title\" class=\"title\">\r\n {{ title }}\r\n <button class=\"property-button\" (click)=\"settings = !settings\">\r\n <div\r\n class=\"icon settings-icon\"\r\n [class]=\"\r\n settings === undefined ? '' : settings ? 'unrotate' : 'rotate'\r\n \"\r\n ></div>\r\n </button>\r\n </p>\r\n <daga-object-editor *ngIf=\"!settings\" [valueSet]=\"valueSet\" />\r\n <daga-property-settings *ngIf=\"settings\" [valueSet]=\"valueSet\" />\r\n </div>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: CollapseButtonComponent, selector: "daga-collapse-button", inputs: ["collapsableSelector", "collapsableAdditionalSelector", "collapsed", "disabled", "direction", "rule", "collapsedValue", "visibleValue"] }, { kind: "component", type: ObjectEditorComponent, selector: "daga-object-editor", inputs: ["valueSet", "depth"] }, { kind: "component", type: PropertySettingsComponent, selector: "daga-property-settings", inputs: ["valueSet", "depth"] }] }); }
10529
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: PropertyEditorComponent, isStandalone: true, selector: "daga-property-editor", inputs: { location: "location", direction: "direction", width: "width", valueSet: "valueSet" }, viewQueries: [{ propertyName: "panel", first: true, predicate: ["panel"], descendants: true }], ngImport: i0, template: "<div\r\n #panel\r\n class=\"daga-panel daga-bottom daga-{{ location }} daga-{{ direction }}\"\r\n>\r\n <daga-collapse-button\r\n #collapse\r\n [disabled]=\"\r\n !valueSet ||\r\n !valueSet.propertySet ||\r\n !valueSet.propertySet.hasProperties()\r\n \"\r\n [direction]=\"direction\"\r\n [collapsableSelector]=\"panel\"\r\n collapsableAdditionalSelector=\".daga-panel-content\"\r\n rule=\"display\"\r\n collapsedValue=\"none\"\r\n visibleValue=\"block\"\r\n />\r\n <div\r\n *ngIf=\"\r\n valueSet &&\r\n valueSet.propertySet &&\r\n valueSet.propertySet.hasProperties() &&\r\n !collapse.collapsed\r\n \"\r\n class=\"daga-panel-content\"\r\n >\r\n <p *ngIf=\"title\" class=\"daga-title\">\r\n {{ title }}\r\n <button class=\"daga-property-button\" (click)=\"settings = !settings\">\r\n <div\r\n class=\"daga-icon daga-settings-icon\"\r\n [class]=\"\r\n settings === undefined\r\n ? ''\r\n : settings\r\n ? 'daga-unrotate'\r\n : 'daga-rotate'\r\n \"\r\n ></div>\r\n </button>\r\n </p>\r\n <daga-object-editor *ngIf=\"!settings\" [valueSet]=\"valueSet\" />\r\n <daga-property-settings *ngIf=\"settings\" [valueSet]=\"valueSet\" />\r\n </div>\r\n</div>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: CollapseButtonComponent, selector: "daga-collapse-button", inputs: ["collapsableSelector", "collapsableAdditionalSelector", "collapsed", "disabled", "direction", "rule", "collapsedValue", "visibleValue"] }, { kind: "component", type: ObjectEditorComponent, selector: "daga-object-editor", inputs: ["valueSet", "depth"] }, { kind: "component", type: PropertySettingsComponent, selector: "daga-property-settings", inputs: ["valueSet", "depth"] }] }); }
10098
10530
  }
10099
10531
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: PropertyEditorComponent, decorators: [{
10100
10532
  type: Component,
@@ -10103,7 +10535,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
10103
10535
  CollapseButtonComponent,
10104
10536
  ObjectEditorComponent,
10105
10537
  PropertySettingsComponent
10106
- ], template: "<div #panel class=\"panel bottom {{ location }} {{ direction }}\">\r\n <daga-collapse-button\r\n #collapse\r\n [disabled]=\"\r\n !valueSet ||\r\n !valueSet.propertySet ||\r\n !valueSet.propertySet.hasProperties()\r\n \"\r\n [direction]=\"direction\"\r\n [collapsableSelector]=\"panel\"\r\n collapsableAdditionalSelector=\".panel-content\"\r\n rule=\"display\"\r\n collapsedValue=\"none\"\r\n visibleValue=\"block\"\r\n />\r\n <div\r\n *ngIf=\"\r\n valueSet &&\r\n valueSet.propertySet &&\r\n valueSet.propertySet.hasProperties() &&\r\n !collapse.collapsed\r\n \"\r\n class=\"panel-content\"\r\n >\r\n <p *ngIf=\"title\" class=\"title\">\r\n {{ title }}\r\n <button class=\"property-button\" (click)=\"settings = !settings\">\r\n <div\r\n class=\"icon settings-icon\"\r\n [class]=\"\r\n settings === undefined ? '' : settings ? 'unrotate' : 'rotate'\r\n \"\r\n ></div>\r\n </button>\r\n </p>\r\n <daga-object-editor *ngIf=\"!settings\" [valueSet]=\"valueSet\" />\r\n <daga-property-settings *ngIf=\"settings\" [valueSet]=\"valueSet\" />\r\n </div>\r\n</div>\r\n" }]
10538
+ ], template: "<div\r\n #panel\r\n class=\"daga-panel daga-bottom daga-{{ location }} daga-{{ direction }}\"\r\n>\r\n <daga-collapse-button\r\n #collapse\r\n [disabled]=\"\r\n !valueSet ||\r\n !valueSet.propertySet ||\r\n !valueSet.propertySet.hasProperties()\r\n \"\r\n [direction]=\"direction\"\r\n [collapsableSelector]=\"panel\"\r\n collapsableAdditionalSelector=\".daga-panel-content\"\r\n rule=\"display\"\r\n collapsedValue=\"none\"\r\n visibleValue=\"block\"\r\n />\r\n <div\r\n *ngIf=\"\r\n valueSet &&\r\n valueSet.propertySet &&\r\n valueSet.propertySet.hasProperties() &&\r\n !collapse.collapsed\r\n \"\r\n class=\"daga-panel-content\"\r\n >\r\n <p *ngIf=\"title\" class=\"daga-title\">\r\n {{ title }}\r\n <button class=\"daga-property-button\" (click)=\"settings = !settings\">\r\n <div\r\n class=\"daga-icon daga-settings-icon\"\r\n [class]=\"\r\n settings === undefined\r\n ? ''\r\n : settings\r\n ? 'daga-unrotate'\r\n : 'daga-rotate'\r\n \"\r\n ></div>\r\n </button>\r\n </p>\r\n <daga-object-editor *ngIf=\"!settings\" [valueSet]=\"valueSet\" />\r\n <daga-property-settings *ngIf=\"settings\" [valueSet]=\"valueSet\" />\r\n </div>\r\n</div>\r\n" }]
10107
10539
  }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { panel: [{
10108
10540
  type: ViewChild,
10109
10541
  args: ['panel']
@@ -10117,7 +10549,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
10117
10549
  type: Input
10118
10550
  }] } });
10119
10551
  const getStyleClassName = (s) => {
10120
- return 'property-name-' + s.replace(/\s/g, '');
10552
+ return 'daga-property-name-' + s.replace(/\s/g, '');
10121
10553
  };
10122
10554
 
10123
10555
  /**
@@ -10177,7 +10609,7 @@ class DiagramEditorComponent {
10177
10609
  this.canvasProvider.initCanvasView(this.appendTo.nativeElement);
10178
10610
  }
10179
10611
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DiagramEditorComponent, deps: [{ token: DagaConfigurationService }, { token: CanvasProviderService }], target: i0.ɵɵFactoryTarget.Component }); }
10180
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: DiagramEditorComponent, isStandalone: true, selector: "daga-diagram-editor", outputs: { modelEvent: "modelEvent" }, viewQueries: [{ propertyName: "appendTo", first: true, predicate: ["appendTo"], descendants: true }, { propertyName: "diagramButtons", first: true, predicate: ["diagramButtons"], descendants: true }, { propertyName: "palette", first: true, predicate: ["palette"], descendants: true }, { propertyName: "propertyEditor", first: true, predicate: ["propertyEditor"], descendants: true }], ngImport: i0, template: "<div class=\"append-to\" #appendTo></div>\n<daga-diagram-buttons\n *ngIf=\"config.components?.buttons?.exists !== false\"\n #diagramButtons\n [location]=\"config.components?.buttons?.location || Corner.BottomRight\"\n [direction]=\"config.components?.buttons?.direction || Side.Top\"\n [enableFilter]=\"config.components?.buttons?.enableFilter !== false\"\n [enableLayout]=\"config.components?.buttons?.enableLayout !== false\"\n [enableUndoRedo]=\"config.components?.buttons?.enableUndoRedo !== false\"\n [enableZoom]=\"config.components?.buttons?.enableZoom !== false\"\n [zoomRate]=\"config.components?.buttons?.zoomRate || 2\"\n/>\n<daga-palette\n *ngIf=\"\n config.components?.palette?.exists !== false &&\n config.components?.palette?.sections &&\n (config.components?.palette?.sections?.length || 0) > 0\n \"\n #palette\n [location]=\"config.components?.palette?.location || Corner.TopLeft\"\n [direction]=\"config.components?.palette?.direction || Side.Bottom\"\n [width]=\"config.components?.palette?.width || '12rem'\"\n [palettes]=\"config.components?.palette?.sections || []\"\n/>\n<daga-property-editor\n *ngIf=\"config.components?.propertyEditor?.exists !== false\"\n #propertyEditor\n [location]=\"config.components?.propertyEditor?.location || Corner.TopRight\"\n [direction]=\"config.components?.propertyEditor?.direction || Side.Bottom\"\n [width]=\"config.components?.propertyEditor?.width || '24rem'\"\n/>\n<daga-errors *ngIf=\"config.components?.errors?.exists !== false\" />\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: DiagramButtonsComponent, selector: "daga-diagram-buttons", inputs: ["location", "direction", "enableFilter", "enableLayout", "enableUndoRedo", "enableZoom", "zoomRate"] }, { kind: "component", type: PaletteComponent, selector: "daga-palette", inputs: ["palettes", "currentPalette", "currentCategory", "location", "direction", "width"] }, { kind: "component", type: PropertyEditorComponent, selector: "daga-property-editor", inputs: ["location", "direction", "width", "valueSet"] }, { kind: "component", type: ErrorsComponent, selector: "daga-errors" }] }); }
10612
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.2", type: DiagramEditorComponent, isStandalone: true, selector: "daga-diagram-editor", outputs: { modelEvent: "modelEvent" }, viewQueries: [{ propertyName: "appendTo", first: true, predicate: ["appendTo"], descendants: true }, { propertyName: "diagramButtons", first: true, predicate: ["diagramButtons"], descendants: true }, { propertyName: "palette", first: true, predicate: ["palette"], descendants: true }, { propertyName: "propertyEditor", first: true, predicate: ["propertyEditor"], descendants: true }], ngImport: i0, template: "<div class=\"daga-append-to\" #appendTo></div>\r\n<daga-diagram-buttons\r\n *ngIf=\"config.components?.buttons?.exists !== false\"\r\n #diagramButtons\r\n [location]=\"config.components?.buttons?.location || Corner.BottomRight\"\r\n [direction]=\"config.components?.buttons?.direction || Side.Top\"\r\n [enableFilter]=\"config.components?.buttons?.enableFilter !== false\"\r\n [enableLayout]=\"config.components?.buttons?.enableLayout !== false\"\r\n [enableUndoRedo]=\"config.components?.buttons?.enableUndoRedo !== false\"\r\n [enableZoom]=\"config.components?.buttons?.enableZoom !== false\"\r\n [zoomRate]=\"config.components?.buttons?.zoomRate || 2\"\r\n/>\r\n<daga-palette\r\n *ngIf=\"\r\n config.components?.palette?.exists !== false &&\r\n config.components?.palette?.sections &&\r\n (config.components?.palette?.sections?.length || 0) > 0\r\n \"\r\n #palette\r\n [location]=\"config.components?.palette?.location || Corner.TopLeft\"\r\n [direction]=\"config.components?.palette?.direction || Side.Bottom\"\r\n [width]=\"config.components?.palette?.width || '12rem'\"\r\n [palettes]=\"config.components?.palette?.sections || []\"\r\n/>\r\n<daga-property-editor\r\n *ngIf=\"config.components?.propertyEditor?.exists !== false\"\r\n #propertyEditor\r\n [location]=\"config.components?.propertyEditor?.location || Corner.TopRight\"\r\n [direction]=\"config.components?.propertyEditor?.direction || Side.Bottom\"\r\n [width]=\"config.components?.propertyEditor?.width || '24rem'\"\r\n/>\r\n<daga-errors *ngIf=\"config.components?.errors?.exists !== false\" />\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: DiagramButtonsComponent, selector: "daga-diagram-buttons", inputs: ["location", "direction", "enableFilter", "enableLayout", "enableUndoRedo", "enableZoom", "zoomRate"] }, { kind: "component", type: PaletteComponent, selector: "daga-palette", inputs: ["palettes", "currentPalette", "currentCategory", "location", "direction", "width"] }, { kind: "component", type: PropertyEditorComponent, selector: "daga-property-editor", inputs: ["location", "direction", "width", "valueSet"] }, { kind: "component", type: ErrorsComponent, selector: "daga-errors" }] }); }
10181
10613
  }
10182
10614
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: DiagramEditorComponent, decorators: [{
10183
10615
  type: Component,
@@ -10187,7 +10619,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImpor
10187
10619
  PaletteComponent,
10188
10620
  PropertyEditorComponent,
10189
10621
  ErrorsComponent
10190
- ], template: "<div class=\"append-to\" #appendTo></div>\n<daga-diagram-buttons\n *ngIf=\"config.components?.buttons?.exists !== false\"\n #diagramButtons\n [location]=\"config.components?.buttons?.location || Corner.BottomRight\"\n [direction]=\"config.components?.buttons?.direction || Side.Top\"\n [enableFilter]=\"config.components?.buttons?.enableFilter !== false\"\n [enableLayout]=\"config.components?.buttons?.enableLayout !== false\"\n [enableUndoRedo]=\"config.components?.buttons?.enableUndoRedo !== false\"\n [enableZoom]=\"config.components?.buttons?.enableZoom !== false\"\n [zoomRate]=\"config.components?.buttons?.zoomRate || 2\"\n/>\n<daga-palette\n *ngIf=\"\n config.components?.palette?.exists !== false &&\n config.components?.palette?.sections &&\n (config.components?.palette?.sections?.length || 0) > 0\n \"\n #palette\n [location]=\"config.components?.palette?.location || Corner.TopLeft\"\n [direction]=\"config.components?.palette?.direction || Side.Bottom\"\n [width]=\"config.components?.palette?.width || '12rem'\"\n [palettes]=\"config.components?.palette?.sections || []\"\n/>\n<daga-property-editor\n *ngIf=\"config.components?.propertyEditor?.exists !== false\"\n #propertyEditor\n [location]=\"config.components?.propertyEditor?.location || Corner.TopRight\"\n [direction]=\"config.components?.propertyEditor?.direction || Side.Bottom\"\n [width]=\"config.components?.propertyEditor?.width || '24rem'\"\n/>\n<daga-errors *ngIf=\"config.components?.errors?.exists !== false\" />\n" }]
10622
+ ], template: "<div class=\"daga-append-to\" #appendTo></div>\r\n<daga-diagram-buttons\r\n *ngIf=\"config.components?.buttons?.exists !== false\"\r\n #diagramButtons\r\n [location]=\"config.components?.buttons?.location || Corner.BottomRight\"\r\n [direction]=\"config.components?.buttons?.direction || Side.Top\"\r\n [enableFilter]=\"config.components?.buttons?.enableFilter !== false\"\r\n [enableLayout]=\"config.components?.buttons?.enableLayout !== false\"\r\n [enableUndoRedo]=\"config.components?.buttons?.enableUndoRedo !== false\"\r\n [enableZoom]=\"config.components?.buttons?.enableZoom !== false\"\r\n [zoomRate]=\"config.components?.buttons?.zoomRate || 2\"\r\n/>\r\n<daga-palette\r\n *ngIf=\"\r\n config.components?.palette?.exists !== false &&\r\n config.components?.palette?.sections &&\r\n (config.components?.palette?.sections?.length || 0) > 0\r\n \"\r\n #palette\r\n [location]=\"config.components?.palette?.location || Corner.TopLeft\"\r\n [direction]=\"config.components?.palette?.direction || Side.Bottom\"\r\n [width]=\"config.components?.palette?.width || '12rem'\"\r\n [palettes]=\"config.components?.palette?.sections || []\"\r\n/>\r\n<daga-property-editor\r\n *ngIf=\"config.components?.propertyEditor?.exists !== false\"\r\n #propertyEditor\r\n [location]=\"config.components?.propertyEditor?.location || Corner.TopRight\"\r\n [direction]=\"config.components?.propertyEditor?.direction || Side.Bottom\"\r\n [width]=\"config.components?.propertyEditor?.width || '24rem'\"\r\n/>\r\n<daga-errors *ngIf=\"config.components?.errors?.exists !== false\" />\r\n" }]
10191
10623
  }], ctorParameters: () => [{ type: DagaConfigurationService }, { type: CanvasProviderService }], propDecorators: { appendTo: [{
10192
10624
  type: ViewChild,
10193
10625
  args: ['appendTo']
@@ -10541,5 +10973,5 @@ function now() {
10541
10973
  * Generated bundle index. Do not edit.
10542
10974
  */
10543
10975
 
10544
- export { ACTION_QUEUE_SIZE, ActionQueue, AddConnectionAction, AddNodeAction, AdjacencyLayout, BreadthAdjacencyLayout, BreadthLayout, CanvasProviderService, ClosedShape, CollabClient, CollapseButtonComponent, Corner, DagaConfigurationService, DagaExporter, DagaImporter, DagaModule, DiagramActions, DiagramButtonsComponent, DiagramCanvas, DiagramComponent, DiagramConnection, DiagramConnectionSet, DiagramConnectionType, DiagramDecorator, DiagramDecoratorSet, DiagramEditorComponent, DiagramElement, DiagramEntitySet, DiagramEvent, DiagramField, DiagramFieldSet, DiagramModel, DiagramNode, DiagramNodeSet, DiagramNodeType, DiagramObject, DiagramObjectSet, DiagramPort, DiagramPortSet, DiagramSection, DiagramSectionSet, EditFieldAction, ErrorsComponent, ForceLayout, HorizontalAlign, HorizontalLayout, LineShape, LineStyle, ObjectEditorComponent, PaletteComponent, PriorityLayout, Property, PropertyEditorComponent, PropertySet, RemoveAction, SetGeometryAction, Side, TextListEditorComponent, TextMapEditorComponent, TreeLayout, Type, UpdateValuesAction, ValueSet, VerticalAlign, VerticalLayout, layouts };
10976
+ export { ACTION_QUEUE_SIZE, ActionQueue, AddConnectionAction, AddNodeAction, AdjacencyLayout, BreadthAdjacencyLayout, BreadthLayout, CanvasProviderService, ClosedShape, CollabClient, CollapseButtonComponent, Corner, DagaConfigurationService, DagaExporter, DagaImporter, DagaModule, DiagramActions, DiagramButtonsComponent, DiagramCanvas, DiagramComponent, DiagramConnection, DiagramConnectionSet, DiagramConnectionType, DiagramDecorator, DiagramDecoratorSet, DiagramEditorComponent, DiagramElement, DiagramElementSet, DiagramEntitySet, DiagramEvent, DiagramField, DiagramFieldSet, DiagramModel, DiagramNode, DiagramNodeSet, DiagramNodeType, DiagramObject, DiagramObjectSet, DiagramPort, DiagramPortSet, DiagramSection, DiagramSectionSet, EditFieldAction, ErrorsComponent, ForceLayout, HorizontalAlign, HorizontalLayout, LineShape, LineStyle, ObjectEditorComponent, PaletteComponent, PriorityLayout, Property, PropertyEditorComponent, PropertySet, RemoveAction, SetGeometryAction, Side, TextListEditorComponent, TextMapEditorComponent, TreeLayout, Type, UpdateValuesAction, ValueSet, VerticalAlign, VerticalLayout, layouts };
10545
10977
  //# sourceMappingURL=metadev-daga.mjs.map