@limble/limble-tree 0.12.2 → 0.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/README.md +149 -149
  2. package/{esm2015/lib/classes/Branch.js → esm2020/lib/classes/Branch.mjs} +1 -1
  3. package/{esm2015/lib/classes/DropZone.js → esm2020/lib/classes/DropZone.mjs} +1 -1
  4. package/{esm2015/lib/classes/DropZoneLocation.js → esm2020/lib/classes/DropZoneLocation.mjs} +1 -1
  5. package/{esm2015/lib/custom-event-bindings/dragleave-no-change-detect.directive.js → esm2020/lib/custom-event-bindings/dragleave-no-change-detect.directive.mjs} +0 -0
  6. package/{esm2015/lib/custom-event-bindings/dragover-no-change-detect.directive.js → esm2020/lib/custom-event-bindings/dragover-no-change-detect.directive.mjs} +1 -1
  7. package/esm2020/lib/drop-zone/drop-zone.component.mjs +75 -0
  8. package/esm2020/lib/limble-tree-branch/limble-tree-branch.component.mjs +110 -0
  9. package/esm2020/lib/limble-tree-node/limble-tree-node.component.mjs +467 -0
  10. package/{esm2015/lib/limble-tree-placeholder/limble-tree-placeholder.component.js → esm2020/lib/limble-tree-placeholder/limble-tree-placeholder.component.mjs} +3 -8
  11. package/esm2020/lib/limble-tree-root/drop-zone.service.mjs +376 -0
  12. package/esm2020/lib/limble-tree-root/limble-tree-root.component.mjs +172 -0
  13. package/{esm2015/lib/limble-tree-root/tree-construction-status.service.js → esm2020/lib/limble-tree-root/tree-construction-status.service.mjs} +1 -1
  14. package/esm2020/lib/limble-tree-root/tree.service.mjs +297 -0
  15. package/{esm2015/lib/limble-tree.module.js → esm2020/lib/limble-tree.module.mjs} +5 -5
  16. package/{esm2015/lib/singletons/component-creator.service.js → esm2020/lib/singletons/component-creator.service.mjs} +1 -1
  17. package/esm2020/lib/singletons/drag-state.service.mjs +63 -0
  18. package/esm2020/lib/singletons/global-events.service.mjs +136 -0
  19. package/{esm2015/lib/util.js → esm2020/lib/util.mjs} +1 -1
  20. package/{esm2015/limble-limble-tree.js → esm2020/limble-limble-tree.mjs} +0 -0
  21. package/{esm2015/public-api.js → esm2020/public-api.mjs} +1 -1
  22. package/fesm2015/limble-limble-tree.mjs +2256 -0
  23. package/fesm2015/limble-limble-tree.mjs.map +1 -0
  24. package/{fesm2015/limble-limble-tree.js → fesm2020/limble-limble-tree.mjs} +105 -147
  25. package/fesm2020/limble-limble-tree.mjs.map +1 -0
  26. package/{limble-limble-tree.d.ts → index.d.ts} +0 -0
  27. package/lib/custom-event-bindings/dragleave-no-change-detect.directive.d.ts +1 -1
  28. package/lib/custom-event-bindings/dragover-no-change-detect.directive.d.ts +1 -1
  29. package/lib/drop-zone/drop-zone.component.d.ts +1 -1
  30. package/lib/limble-tree-branch/limble-tree-branch.component.d.ts +1 -1
  31. package/lib/limble-tree-node/limble-tree-node.component.d.ts +1 -1
  32. package/lib/limble-tree-placeholder/limble-tree-placeholder.component.d.ts +1 -1
  33. package/lib/limble-tree-root/limble-tree-root.component.d.ts +1 -1
  34. package/package.json +24 -10
  35. package/bundles/limble-limble-tree.umd.js +0 -2905
  36. package/bundles/limble-limble-tree.umd.js.map +0 -1
  37. package/esm2015/lib/drop-zone/drop-zone.component.js +0 -81
  38. package/esm2015/lib/limble-tree-branch/limble-tree-branch.component.js +0 -116
  39. package/esm2015/lib/limble-tree-node/limble-tree-node.component.js +0 -484
  40. package/esm2015/lib/limble-tree-root/drop-zone.service.js +0 -372
  41. package/esm2015/lib/limble-tree-root/limble-tree-root.component.js +0 -178
  42. package/esm2015/lib/limble-tree-root/tree.service.js +0 -301
  43. package/esm2015/lib/singletons/drag-state.service.js +0 -64
  44. package/esm2015/lib/singletons/global-events.service.js +0 -137
  45. package/fesm2015/limble-limble-tree.js.map +0 -1
@@ -1,6 +1,6 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { Injectable, Component, ChangeDetectionStrategy, Input, ViewContainerRef, ViewChild, ElementRef, EventEmitter, Directive, Output, NgZone, NgModule } from '@angular/core';
3
- import { Subject, BehaviorSubject, EMPTY, fromEvent, merge } from 'rxjs';
3
+ import { Subject, BehaviorSubject, fromEvent, merge, EMPTY } from 'rxjs';
4
4
  import { tap, filter, debounce, throttleTime, skip, first, skipUntil, debounceTime } from 'rxjs/operators';
5
5
  import * as i2 from '@angular/common';
6
6
  import { CommonModule } from '@angular/common';
@@ -195,13 +195,12 @@ class DragStateService {
195
195
  }
196
196
  /** Called to indicate that a drop into a valid drop zone has occurred. Returns the item that was dropped. */
197
197
  capture() {
198
- var _a;
199
198
  if (this.state !== "droppable") {
200
199
  throw new Error("Can only move to `captured` state from `droppable` state");
201
200
  }
202
201
  this.state = "captured";
203
202
  this.state$.next(this.state);
204
- return (_a = this._tempData) === null || _a === void 0 ? void 0 : _a.branch;
203
+ return this._tempData?.branch;
205
204
  }
206
205
  /** Called to reset the service for future drags */
207
206
  release() {
@@ -284,7 +283,7 @@ class DropZoneService {
284
283
  .pipe(debounce(() => {
285
284
  if (treeIsStable === true) {
286
285
  //If tree is stable, continue right away
287
- return EMPTY;
286
+ return Promise.resolve();
288
287
  }
289
288
  //If tree is not stable, wait for it to become so.
290
289
  return treeIsStable$;
@@ -478,15 +477,14 @@ class DropZoneService {
478
477
  location.parentCoordinates.length > 0);
479
478
  })
480
479
  .sort((valueA, valueB) => {
481
- var _a, _b, _c, _d;
482
480
  const aCoordinates = valueA.getFullInsertCoordinates();
483
481
  const bCoordinates = valueB.getFullInsertCoordinates();
484
482
  const length = Math.max(aCoordinates.length, bCoordinates.length);
485
483
  for (let index = 0; index < length; index++) {
486
- if (((_a = aCoordinates[index]) !== null && _a !== void 0 ? _a : -1) > ((_b = bCoordinates[index]) !== null && _b !== void 0 ? _b : -1)) {
484
+ if ((aCoordinates[index] ?? -1) > (bCoordinates[index] ?? -1)) {
487
485
  return -1;
488
486
  }
489
- else if (((_c = aCoordinates[index]) !== null && _c !== void 0 ? _c : -1) < ((_d = bCoordinates[index]) !== null && _d !== void 0 ? _d : -1)) {
487
+ else if ((aCoordinates[index] ?? -1) < (bCoordinates[index] ?? -1)) {
490
488
  return 1;
491
489
  }
492
490
  }
@@ -596,19 +594,24 @@ class DropZoneService {
596
594
  if (data === undefined) {
597
595
  throw new Error("Can't get dragged node");
598
596
  }
599
- const dropZoneParent = this.tree.findByCoordinates(dropZone.getLocation().parentCoordinates);
597
+ const parentCoordinates = dropZone.getLocation().parentCoordinates;
598
+ const dropZoneParent = this.tree.findByCoordinates(parentCoordinates);
600
599
  if (dropZoneParent === undefined) {
601
600
  throw new Error("Could not get drop zone parent");
602
601
  }
602
+ if (parentCoordinates.length > 0 &&
603
+ !isNestingAllowed(this.treeOptions, dropZoneParent.data)) {
604
+ return false;
605
+ }
603
606
  const dropZoneIndex = dropZone.getLocation().insertIndex;
604
607
  if (dropZoneIndex === undefined) {
605
608
  throw new Error("Could not get drop zone index");
606
609
  }
607
610
  const draggedNode = data.branch;
608
- if (this.treeOptions.allowDrop(draggedNode.data, dropZoneParent.data, dropZoneIndex)) {
609
- return true;
611
+ if (!this.treeOptions.allowDrop(draggedNode.data, dropZoneParent.data, dropZoneIndex)) {
612
+ return false;
610
613
  }
611
- return false;
614
+ return true;
612
615
  }
613
616
  }
614
617
  DropZoneService.ɵfac = function DropZoneService_Factory(t) { return new (t || DropZoneService)(i0.ɵɵinject(DragStateService), i0.ɵɵinject(TreeConstructionStatus)); };
@@ -774,7 +777,7 @@ const _c0$3 = function (a0, a1) { return { active: a0, related: a1 }; };
774
777
  function DropZoneComponent_div_0_Template(rf, ctx) { if (rf & 1) {
775
778
  const _r2 = i0.ɵɵgetCurrentView();
776
779
  i0.ɵɵelementStart(0, "div", 1);
777
- i0.ɵɵlistener("dragenter", function DropZoneComponent_div_0_Template_div_dragenter_0_listener() { i0.ɵɵrestoreView(_r2); const ctx_r1 = i0.ɵɵnextContext(); return ctx_r1.dragenterHandler(); });
780
+ i0.ɵɵlistener("dragenter", function DropZoneComponent_div_0_Template_div_dragenter_0_listener() { i0.ɵɵrestoreView(_r2); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.dragenterHandler()); });
778
781
  i0.ɵɵelement(1, "div", 2);
779
782
  i0.ɵɵelementEnd();
780
783
  } if (rf & 2) {
@@ -802,14 +805,13 @@ class DropZoneComponent {
802
805
  this.commSubscription = this.dropZone
803
806
  .getCommChannel()
804
807
  .subscribe((message) => {
805
- var _a, _b, _c, _d;
806
808
  switch (message) {
807
809
  case "checkVisible": {
808
- this.visible = (_b = (_a = this.dropZone) === null || _a === void 0 ? void 0 : _a.isVisible()) !== null && _b !== void 0 ? _b : false;
810
+ this.visible = this.dropZone?.isVisible() ?? false;
809
811
  break;
810
812
  }
811
813
  case "checkActive": {
812
- this.active = (_d = (_c = this.dropZone) === null || _c === void 0 ? void 0 : _c.isActive()) !== null && _d !== void 0 ? _d : false;
814
+ this.active = this.dropZone?.isActive() ?? false;
813
815
  break;
814
816
  }
815
817
  case "checkRendered": {
@@ -834,15 +836,10 @@ DropZoneComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: DropZoneC
834
836
  i0.ɵɵtemplate(0, DropZoneComponent_div_0_Template, 2, 4, "div", 0);
835
837
  } if (rf & 2) {
836
838
  i0.ɵɵproperty("ngIf", ctx.visible);
837
- } }, directives: [i2.NgIf, i2.NgClass], styles: [".active[_ngcontent-%COMP%]{height:105px;border-radius:5px;background:#f0f9ff;border:2px dashed #bed2db}.active[_ngcontent-%COMP%], .related[_ngcontent-%COMP%]{margin:10px 0;width:calc(100% - 20px);box-sizing:border-box}.related[_ngcontent-%COMP%]{height:30px;border-radius:5px;background:#fff6f0;border:1px dashed #dbccbe;opacity:.8}.dropZoneContainer[_ngcontent-%COMP%]{position:relative}"], changeDetection: 0 });
839
+ } }, dependencies: [i2.NgClass, i2.NgIf], styles: [".active[_ngcontent-%COMP%]{margin:10px 0;width:calc(100% - 20px);height:105px;border-radius:5px;background:#f0f9ff;border:2px dashed #bed2db;box-sizing:border-box}.related[_ngcontent-%COMP%]{margin:10px 0;width:calc(100% - 20px);height:30px;border-radius:5px;background:#fff6f0;border:1px dashed #dbccbe;box-sizing:border-box;opacity:.8}.dropZoneContainer[_ngcontent-%COMP%]{position:relative}"], changeDetection: 0 });
838
840
  (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(DropZoneComponent, [{
839
841
  type: Component,
840
- args: [{
841
- selector: "drop-zone",
842
- templateUrl: "./drop-zone.component.html",
843
- styleUrls: ["./drop-zone.component.scss"],
844
- changeDetection: ChangeDetectionStrategy.OnPush
845
- }]
842
+ args: [{ selector: "drop-zone", changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"dropZoneContainer\" (dragenter)=\"dragenterHandler()\" *ngIf=\"visible\">\n <div [ngClass]=\"{ active: active, related: !active }\"></div>\n</div>\n", styles: [".active{margin:10px 0;width:calc(100% - 20px);height:105px;border-radius:5px;background:#f0f9ff;border:2px dashed #bed2db;box-sizing:border-box}.related{margin:10px 0;width:calc(100% - 20px);height:30px;border-radius:5px;background:#fff6f0;border:1px dashed #dbccbe;box-sizing:border-box;opacity:.8}.dropZoneContainer{position:relative}\n"] }]
846
843
  }], function () { return [{ type: DropZoneService }, { type: i0.ChangeDetectorRef }]; }, { dropZone: [{
847
844
  type: Input
848
845
  }] }); })();
@@ -857,14 +854,13 @@ function LimbleTreeBranchComponent_drop_zone_1_Template(rf, ctx) { if (rf & 1) {
857
854
  function LimbleTreeBranchComponent_ng_template_3_Template(rf, ctx) { }
858
855
  class LimbleTreeBranchComponent {
859
856
  constructor(treeService, changeDetectorRef, dropZoneService, treeConstructionStatus, ngZone) {
860
- var _a;
861
857
  this.treeService = treeService;
862
858
  this.changeDetectorRef = changeDetectorRef;
863
859
  this.dropZoneService = dropZoneService;
864
860
  this.treeConstructionStatus = treeConstructionStatus;
865
861
  this.ngZone = ngZone;
866
862
  this.treeConstructionStatus.constructing();
867
- this.indent = (_a = this.treeService.treeOptions) === null || _a === void 0 ? void 0 : _a.indent;
863
+ this.indent = this.treeService.treeOptions?.indent;
868
864
  this.renderDropZoneInside = false;
869
865
  }
870
866
  ngOnInit() {
@@ -930,22 +926,17 @@ LimbleTreeBranchComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: L
930
926
  i0.ɵɵtemplate(1, LimbleTreeBranchComponent_drop_zone_1_Template, 1, 1, "drop-zone", 0);
931
927
  i0.ɵɵelementStart(2, "span", 1);
932
928
  i0.ɵɵtemplate(3, LimbleTreeBranchComponent_ng_template_3_Template, 0, 0, "ng-template", null, 2, i0.ɵɵtemplateRefExtractor);
933
- i0.ɵɵelementEnd();
934
- i0.ɵɵelementEnd();
929
+ i0.ɵɵelementEnd()();
935
930
  } if (rf & 2) {
936
931
  i0.ɵɵstyleProp("margin-left", ctx.indent, "px");
937
932
  i0.ɵɵadvance(1);
938
933
  i0.ɵɵproperty("ngIf", ctx.renderDropZoneInside);
939
934
  i0.ɵɵadvance(1);
940
935
  i0.ɵɵproperty("hidden", ctx.branch && ctx.branch.data.collapsed);
941
- } }, directives: [i2.NgIf, DropZoneComponent], styles: [""] });
936
+ } }, dependencies: [i2.NgIf, DropZoneComponent] });
942
937
  (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LimbleTreeBranchComponent, [{
943
938
  type: Component,
944
- args: [{
945
- selector: "limble-tree-branch",
946
- templateUrl: "./limble-tree-branch.component.html",
947
- styleUrls: ["./limble-tree-branch.component.scss"]
948
- }]
939
+ args: [{ selector: "limble-tree-branch", template: "<div [style.marginLeft.px]=\"indent\">\n <drop-zone\n *ngIf=\"renderDropZoneInside\"\n [dropZone]=\"dropZoneInside\"\n ></drop-zone>\n <span [hidden]=\"branch && branch.data.collapsed\" class=\"limble-child-nodes\">\n <ng-template #children></ng-template>\n </span>\n</div>\n" }]
949
940
  }], function () { return [{ type: TreeService }, { type: i0.ChangeDetectorRef }, { type: DropZoneService }, { type: TreeConstructionStatus }, { type: i0.NgZone }]; }, { branch: [{
950
941
  type: Input
951
942
  }], children: [{
@@ -971,7 +962,6 @@ ComponentCreatorService.ɵprov = /*@__PURE__*/ i0.ɵɵdefineInjectable({ token:
971
962
  }], function () { return [{ type: i0.ComponentFactoryResolver }]; }, null); })();
972
963
 
973
964
  function getScrollParent(element) {
974
- var _a;
975
965
  const regex = /(auto|scroll)/;
976
966
  const parents = (_node, parentList) => {
977
967
  if (_node === null || _node.parentNode === null) {
@@ -990,7 +980,7 @@ function getScrollParent(element) {
990
980
  return parent;
991
981
  }
992
982
  }
993
- return ((_a = document.scrollingElement) !== null && _a !== void 0 ? _a : document.documentElement);
983
+ return (document.scrollingElement ?? document.documentElement);
994
984
  }
995
985
  class GlobalEventsService {
996
986
  constructor(ngZone) {
@@ -1162,20 +1152,19 @@ class LimbleTreeNodeComponent {
1162
1152
  }
1163
1153
  }
1164
1154
  ngOnInit() {
1165
- var _a, _b, _c;
1166
- if (((_a = this.treeService.treeOptions) === null || _a === void 0 ? void 0 : _a.allowDragging) === false) {
1155
+ if (this.treeService.treeOptions?.allowDragging === false) {
1167
1156
  return;
1168
1157
  }
1169
- const parent = (_b = this.branch) === null || _b === void 0 ? void 0 : _b.getParent();
1170
- if ((parent === null || parent === void 0 ? void 0 : parent.data) !== null) {
1171
- const parentData = parent === null || parent === void 0 ? void 0 : parent.data;
1158
+ const parent = this.branch?.getParent();
1159
+ if (parent?.data !== null) {
1160
+ const parentData = parent?.data;
1172
1161
  if (!isNestingAllowed(this.treeService.treeOptions, parentData)) {
1173
1162
  this.renderInnerBranch = false;
1174
1163
  return;
1175
1164
  }
1176
1165
  }
1177
1166
  this.registerDropZones();
1178
- this.currentBranchCoordinates = (_c = this.branch) === null || _c === void 0 ? void 0 : _c.getCoordinates();
1167
+ this.currentBranchCoordinates = this.branch?.getCoordinates();
1179
1168
  this.ngZone.runOutsideAngular(() => {
1180
1169
  if (this.dropZoneAbove === undefined ||
1181
1170
  this.dropZoneBelow === undefined) {
@@ -1212,7 +1201,6 @@ class LimbleTreeNodeComponent {
1212
1201
  this.treeService.cleanupSignal$.next(true);
1213
1202
  }
1214
1203
  dragstartHandler(event) {
1215
- var _a;
1216
1204
  event.stopPropagation();
1217
1205
  if (event.dataTransfer === null ||
1218
1206
  this.branch === undefined ||
@@ -1220,7 +1208,7 @@ class LimbleTreeNodeComponent {
1220
1208
  throw new Error("failed to run dragstartHandler");
1221
1209
  }
1222
1210
  const draggedElement = event.target;
1223
- if (((_a = draggedElement.parentElement) === null || _a === void 0 ? void 0 : _a.tagName) !== "LIMBLE-TREE-NODE") {
1211
+ if (draggedElement.parentElement?.tagName !== "LIMBLE-TREE-NODE") {
1224
1212
  //Don't drag stuff that isn't part of the tree
1225
1213
  event.preventDefault();
1226
1214
  return;
@@ -1234,10 +1222,9 @@ class LimbleTreeNodeComponent {
1234
1222
  this.ngZone.runOutsideAngular(() => {
1235
1223
  //We have to use a setTimeout due to a bug in chrome: https://stackoverflow.com/a/20733870/8796651
1236
1224
  setTimeout(() => {
1237
- var _a, _b;
1238
1225
  draggedElement.classList.add("dragging");
1239
- if (((_a = this.treeService.treeData) === null || _a === void 0 ? void 0 : _a.length) === 1 &&
1240
- ((_b = this.branch) === null || _b === void 0 ? void 0 : _b.getCoordinates().length) === 1) {
1226
+ if (this.treeService.treeData?.length === 1 &&
1227
+ this.branch?.getCoordinates().length === 1) {
1241
1228
  //We are dragging the only element in the tree, so we have to use the placeholder system
1242
1229
  this.treeService.placeholder$.next(true);
1243
1230
  }
@@ -1258,8 +1245,8 @@ class LimbleTreeNodeComponent {
1258
1245
  const parent = this.branch.getParent();
1259
1246
  let parentData;
1260
1247
  let parentNestingAllowed = true;
1261
- if ((parent === null || parent === void 0 ? void 0 : parent.data) !== null) {
1262
- parentData = parent === null || parent === void 0 ? void 0 : parent.data;
1248
+ if (parent?.data !== null) {
1249
+ parentData = parent?.data;
1263
1250
  parentNestingAllowed = isNestingAllowed(this.treeService.treeOptions, parentData);
1264
1251
  }
1265
1252
  if (this.dropZoneAbove !== undefined && parentNestingAllowed) {
@@ -1276,8 +1263,7 @@ class LimbleTreeNodeComponent {
1276
1263
  });
1277
1264
  }
1278
1265
  dragendHandler(event) {
1279
- var _a, _b;
1280
- event === null || event === void 0 ? void 0 : event.stopPropagation();
1266
+ event?.stopPropagation();
1281
1267
  if (this.draggableDiv === undefined) {
1282
1268
  throw new Error("could not get draggable div");
1283
1269
  }
@@ -1299,8 +1285,8 @@ class LimbleTreeNodeComponent {
1299
1285
  this.dragStateService.release();
1300
1286
  this.dropZoneService.clearVisibleZones();
1301
1287
  this.dropZoneService.restoreFamilies();
1302
- if (((_a = this.treeService.treeData) === null || _a === void 0 ? void 0 : _a.length) === 1 &&
1303
- ((_b = this.branch) === null || _b === void 0 ? void 0 : _b.getCoordinates().length) === 1) {
1288
+ if (this.treeService.treeData?.length === 1 &&
1289
+ this.branch?.getCoordinates().length === 1) {
1304
1290
  //We were dragging the only element in the tree, so we have to
1305
1291
  //remove the placeholder that we added in the dragstart
1306
1292
  this.treeService.placeholder$.next(false);
@@ -1308,7 +1294,6 @@ class LimbleTreeNodeComponent {
1308
1294
  }
1309
1295
  }
1310
1296
  dragoverHandler(event) {
1311
- var _a, _b, _c;
1312
1297
  if (this.globalEventsService.scrolling === true) {
1313
1298
  return;
1314
1299
  }
@@ -1332,7 +1317,7 @@ class LimbleTreeNodeComponent {
1332
1317
  }
1333
1318
  let topLine;
1334
1319
  let bottomLine;
1335
- if (((_a = this.innerBranch) === null || _a === void 0 ? void 0 : _a.renderDropZoneInside) === false) {
1320
+ if (this.innerBranch?.renderDropZoneInside === false) {
1336
1321
  topLine = target.offsetHeight / 2 - 6;
1337
1322
  bottomLine = topLine;
1338
1323
  }
@@ -1343,8 +1328,8 @@ class LimbleTreeNodeComponent {
1343
1328
  const parent = this.branch.getParent();
1344
1329
  let parentData;
1345
1330
  let parentNestingAllowed = true;
1346
- if ((parent === null || parent === void 0 ? void 0 : parent.data) !== null) {
1347
- parentData = parent === null || parent === void 0 ? void 0 : parent.data;
1331
+ if (parent?.data !== null) {
1332
+ parentData = parent?.data;
1348
1333
  parentNestingAllowed = isNestingAllowed(this.treeService.treeOptions, parentData);
1349
1334
  }
1350
1335
  /** The y-coordinates of the mouse in relation to the node it is hovering over */
@@ -1352,9 +1337,9 @@ class LimbleTreeNodeComponent {
1352
1337
  const activeDropZone = this.dropZoneService.getActiveDropZone();
1353
1338
  if (offsetY < topLine &&
1354
1339
  this.dropZoneAbove !== undefined &&
1340
+ parentNestingAllowed &&
1355
1341
  (activeDropZone === null ||
1356
- !DropZone.dropZoneLocationsAreEqual(activeDropZone, this.dropZoneAbove)) &&
1357
- parentNestingAllowed) {
1342
+ !DropZone.dropZoneLocationsAreEqual(activeDropZone, this.dropZoneAbove))) {
1358
1343
  const index = this.branch.getIndex();
1359
1344
  if (index === undefined || index === null) {
1360
1345
  throw new Error("can't get branch index");
@@ -1368,8 +1353,8 @@ class LimbleTreeNodeComponent {
1368
1353
  }
1369
1354
  else if (offsetY < bottomLine &&
1370
1355
  offsetY > topLine &&
1371
- ((_b = this.innerBranch) === null || _b === void 0 ? void 0 : _b.renderDropZoneInside) === true &&
1372
- ((_c = this.innerBranch) === null || _c === void 0 ? void 0 : _c.dropZoneInside) !== undefined &&
1356
+ this.innerBranch?.renderDropZoneInside === true &&
1357
+ this.innerBranch?.dropZoneInside !== undefined &&
1373
1358
  (activeDropZone === null ||
1374
1359
  !DropZone.dropZoneLocationsAreEqual(activeDropZone, this.innerBranch.dropZoneInside))) {
1375
1360
  this.dropZoneService.showDropZoneFamily(this.innerBranch.dropZoneInside);
@@ -1379,10 +1364,10 @@ class LimbleTreeNodeComponent {
1379
1364
  }
1380
1365
  else if (offsetY >= bottomLine &&
1381
1366
  this.dropZoneBelow !== undefined &&
1367
+ parentNestingAllowed &&
1382
1368
  (activeDropZone === null ||
1383
1369
  !DropZone.dropZoneLocationsAreEqual(activeDropZone, this.dropZoneBelow)) &&
1384
- this.branch.getChildren().length === 0 &&
1385
- parentNestingAllowed) {
1370
+ this.branch.getChildren().length === 0) {
1386
1371
  const index = this.branch.getIndex();
1387
1372
  if (index === undefined || index === null) {
1388
1373
  throw new Error("can't get branch index");
@@ -1394,13 +1379,12 @@ class LimbleTreeNodeComponent {
1394
1379
  }
1395
1380
  }
1396
1381
  renderNode() {
1397
- var _a;
1398
1382
  if (this.nodeHost === undefined || this.branch === undefined) {
1399
1383
  throw new Error("Failed to render tree node");
1400
1384
  }
1401
1385
  let component = this.branch.data.component;
1402
1386
  if (component === undefined) {
1403
- component = (_a = this.treeService.treeOptions) === null || _a === void 0 ? void 0 : _a.defaultComponent;
1387
+ component = this.treeService.treeOptions?.defaultComponent;
1404
1388
  }
1405
1389
  if (component === undefined) {
1406
1390
  throw new Error("limbleTree requires a component to render");
@@ -1416,37 +1400,33 @@ class LimbleTreeNodeComponent {
1416
1400
  this.addDropZoneBelow();
1417
1401
  }
1418
1402
  addDropZoneAbove() {
1419
- var _a;
1420
1403
  if (this.branch === undefined) {
1421
1404
  throw new Error("failed to register drop zone above");
1422
1405
  }
1423
1406
  const parent = this.branch.getParent();
1424
1407
  const currentCoordinates = this.branch.getCoordinates();
1425
1408
  const index = currentCoordinates[currentCoordinates.length - 1];
1426
- this.dropZoneAbove = new DropZone([...((_a = parent === null || parent === void 0 ? void 0 : parent.getCoordinates()) !== null && _a !== void 0 ? _a : [])], index);
1409
+ this.dropZoneAbove = new DropZone([...(parent?.getCoordinates() ?? [])], index);
1427
1410
  this.dropZoneService.addDropZone(this.dropZoneAbove);
1428
1411
  }
1429
1412
  addDropZoneBelow() {
1430
- var _a;
1431
1413
  if (this.branch === undefined) {
1432
1414
  throw new Error("failed to register drop zone below");
1433
1415
  }
1434
1416
  const parent = this.branch.getParent();
1435
1417
  const currentCoordinates = this.branch.getCoordinates();
1436
1418
  const index = currentCoordinates[currentCoordinates.length - 1];
1437
- this.dropZoneBelow = new DropZone([...((_a = parent === null || parent === void 0 ? void 0 : parent.getCoordinates()) !== null && _a !== void 0 ? _a : [])], index + 1);
1419
+ this.dropZoneBelow = new DropZone([...(parent?.getCoordinates() ?? [])], index + 1);
1438
1420
  this.dropZoneService.addDropZone(this.dropZoneBelow);
1439
1421
  }
1440
1422
  updateDropZones() {
1441
- var _a;
1442
- this.currentBranchCoordinates = (_a = this.branch) === null || _a === void 0 ? void 0 : _a.getCoordinates();
1423
+ this.currentBranchCoordinates = this.branch?.getCoordinates();
1443
1424
  this.updateDropZoneAbove();
1444
1425
  this.updateDropZoneBelow();
1445
1426
  this.updateDropZoneInside();
1446
1427
  this.setDropZoneHosts();
1447
1428
  }
1448
1429
  updateDropZoneAbove() {
1449
- var _a;
1450
1430
  if (this.branch === undefined || this.dropZoneAbove === undefined) {
1451
1431
  throw new Error("failed to update drop zone above");
1452
1432
  }
@@ -1454,11 +1434,10 @@ class LimbleTreeNodeComponent {
1454
1434
  const currentCoordinates = this.branch.getCoordinates();
1455
1435
  const index = currentCoordinates[currentCoordinates.length - 1];
1456
1436
  const location = this.dropZoneAbove.getLocation();
1457
- location.setParentCoordinates([...((_a = parent === null || parent === void 0 ? void 0 : parent.getCoordinates()) !== null && _a !== void 0 ? _a : [])]);
1437
+ location.setParentCoordinates([...(parent?.getCoordinates() ?? [])]);
1458
1438
  location.setInsertIndex(index);
1459
1439
  }
1460
1440
  updateDropZoneBelow() {
1461
- var _a;
1462
1441
  if (this.branch === undefined || this.dropZoneBelow === undefined) {
1463
1442
  throw new Error("failed to update drop zone below");
1464
1443
  }
@@ -1466,12 +1445,11 @@ class LimbleTreeNodeComponent {
1466
1445
  const currentCoordinates = this.branch.getCoordinates();
1467
1446
  const index = currentCoordinates[currentCoordinates.length - 1];
1468
1447
  const location = this.dropZoneBelow.getLocation();
1469
- location.setParentCoordinates([...((_a = parent === null || parent === void 0 ? void 0 : parent.getCoordinates()) !== null && _a !== void 0 ? _a : [])]);
1448
+ location.setParentCoordinates([...(parent?.getCoordinates() ?? [])]);
1470
1449
  location.setInsertIndex(index + 1);
1471
1450
  }
1472
1451
  updateDropZoneInside() {
1473
- var _a;
1474
- if (((_a = this.innerBranch) === null || _a === void 0 ? void 0 : _a.dropZoneInside) === undefined) {
1452
+ if (this.innerBranch?.dropZoneInside === undefined) {
1475
1453
  return;
1476
1454
  }
1477
1455
  if (this.branch === undefined) {
@@ -1489,7 +1467,6 @@ class LimbleTreeNodeComponent {
1489
1467
  this.dropZoneBelow.setHost(this.parentHost);
1490
1468
  }
1491
1469
  checkForHandle() {
1492
- var _a;
1493
1470
  if (this.nodeHostContainer === undefined ||
1494
1471
  this.draggableDiv === undefined) {
1495
1472
  return;
@@ -1497,7 +1474,7 @@ class LimbleTreeNodeComponent {
1497
1474
  const nodeHostContainerElement = this.nodeHostContainer.nativeElement;
1498
1475
  const handle = nodeHostContainerElement.querySelector(".limble-tree-handle");
1499
1476
  const draggableDivElement = this.draggableDiv.nativeElement;
1500
- if (!isDraggingAllowed(this.treeService.treeOptions, (_a = this.branch) === null || _a === void 0 ? void 0 : _a.data)) {
1477
+ if (!isDraggingAllowed(this.treeService.treeOptions, this.branch?.data)) {
1501
1478
  draggableDivElement.setAttribute("draggable", "false");
1502
1479
  }
1503
1480
  else if (handle === null) {
@@ -1548,14 +1525,10 @@ LimbleTreeNodeComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: Lim
1548
1525
  i0.ɵɵproperty("ngIf", ctx.branch !== undefined && ctx.renderInnerBranch === true);
1549
1526
  i0.ɵɵadvance(1);
1550
1527
  i0.ɵɵproperty("ngIf", ctx.renderDropZoneBelow === true);
1551
- } }, styles: [".dragging[_ngcontent-%COMP%]{position:absolute;transition:transform .01s;transform:translateX(-9999px)}"] });
1528
+ } }, styles: [".dragging[_ngcontent-%COMP%]{position:absolute;transition:transform .01s;transform:translate(-9999px)}"] });
1552
1529
  (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LimbleTreeNodeComponent, [{
1553
1530
  type: Component,
1554
- args: [{
1555
- selector: "limble-tree-node",
1556
- templateUrl: "./limble-tree-node.component.html",
1557
- styleUrls: ["./limble-tree-node.component.scss"]
1558
- }]
1531
+ args: [{ selector: "limble-tree-node", template: "<drop-zone\n *ngIf=\"renderDropZoneAbove === true\"\n [dropZone]=\"dropZoneAbove\"\n></drop-zone>\n<div\n (dragstart)=\"dragstartHandler($event)\"\n (dragend)=\"dragendHandler($event)\"\n class=\"limble-parent-container\"\n #draggableDiv\n>\n <div\n class=\"node-host-container\"\n (dragoverNoChangeDetect)=\"dragoverHandler($event)\"\n [dragoverEventThrottle]=\"10\"\n #nodeHostContainer\n >\n <ng-template #nodeHost></ng-template>\n </div>\n <limble-tree-branch\n *ngIf=\"branch !== undefined && renderInnerBranch === true\"\n [branch]=\"branch\"\n #innerBranch\n ></limble-tree-branch>\n</div>\n<drop-zone\n *ngIf=\"renderDropZoneBelow === true\"\n [dropZone]=\"dropZoneBelow\"\n></drop-zone>\n", styles: [".dragging{position:absolute;transition:transform .01s;transform:translate(-9999px)}\n"] }]
1559
1532
  }], function () { return [{ type: ComponentCreatorService }, { type: i0.ChangeDetectorRef }, { type: DragStateService }, { type: DropZoneService }, { type: TreeService }, { type: GlobalEventsService }, { type: i0.NgZone }, { type: TreeConstructionStatus }]; }, { branch: [{
1560
1533
  type: Input
1561
1534
  }], nodeHost: [{
@@ -1616,7 +1589,6 @@ class TreeService {
1616
1589
  });
1617
1590
  }
1618
1591
  drop(source, targetCoordinates) {
1619
- var _a;
1620
1592
  //prep
1621
1593
  const sourceParent = source.getParent();
1622
1594
  if (sourceParent === null) {
@@ -1644,9 +1616,9 @@ class TreeService {
1644
1616
  throw new Error("could not get to target");
1645
1617
  }
1646
1618
  const target = this.dropZoneService.getDropZone(targetCoordinates);
1647
- const targetIndex = target === null || target === void 0 ? void 0 : target.getLocation().insertIndex;
1648
- const targetHost = target === null || target === void 0 ? void 0 : target.getHost();
1649
- const sourceHost = (_a = this.dragStateService.getData()) === null || _a === void 0 ? void 0 : _a.parentContainer;
1619
+ const targetIndex = target?.getLocation().insertIndex;
1620
+ const targetHost = target?.getHost();
1621
+ const sourceHost = this.dragStateService.getData()?.parentContainer;
1650
1622
  if (this.placeholder === true) {
1651
1623
  this.placeholder$.next(false);
1652
1624
  }
@@ -1714,11 +1686,10 @@ class TreeService {
1714
1686
  this.render();
1715
1687
  }
1716
1688
  cleanup(rebuild = false) {
1717
- var _a;
1718
1689
  if (rebuild) {
1719
1690
  this.rebuildTreeData();
1720
1691
  }
1721
- if (((_a = this.treeData) === null || _a === void 0 ? void 0 : _a.length) === 0) {
1692
+ if (this.treeData?.length === 0) {
1722
1693
  //We do a full render here because it isn't actually any slower
1723
1694
  //when there are no nodes, and it is a little more straightforward
1724
1695
  this.render();
@@ -1763,13 +1734,12 @@ class TreeService {
1763
1734
  }
1764
1735
  /** Renders a branch of the tree and all of its descendants */
1765
1736
  renderBranch(host, branch) {
1766
- var _a, _b;
1767
1737
  if (this.treeModel === undefined) {
1768
1738
  throw new Error("TreeModel not initialized");
1769
1739
  }
1770
1740
  host.clear();
1771
1741
  branch.clearChildren();
1772
- for (const node of (_b = (_a = branch.data) === null || _a === void 0 ? void 0 : _a.nodes) !== null && _b !== void 0 ? _b : []) {
1742
+ for (const node of branch.data?.nodes ?? []) {
1773
1743
  const newBranch = new Branch(node);
1774
1744
  branch.appendChild(newBranch);
1775
1745
  const componentRef = this.componentCreatorService.appendComponent(LimbleTreeNodeComponent, host);
@@ -1780,7 +1750,6 @@ class TreeService {
1780
1750
  }
1781
1751
  }
1782
1752
  processOptions(options = {}, itemsPerPage = Infinity, page = 1) {
1783
- var _a, _b, _c, _d, _e;
1784
1753
  if (options.listMode === true &&
1785
1754
  options.allowNesting !== undefined &&
1786
1755
  options.allowNesting !== false) {
@@ -1788,11 +1757,11 @@ class TreeService {
1788
1757
  }
1789
1758
  const result = {
1790
1759
  defaultComponent: options.defaultComponent,
1791
- indent: (_a = options.indent) !== null && _a !== void 0 ? _a : INDENT,
1792
- allowNesting: options.listMode !== true && ((_b = options.allowNesting) !== null && _b !== void 0 ? _b : true),
1793
- allowDragging: (_c = options.allowDragging) !== null && _c !== void 0 ? _c : true,
1794
- allowDrop: (_d = options.allowDrop) !== null && _d !== void 0 ? _d : (() => true),
1795
- listMode: (_e = options.listMode) !== null && _e !== void 0 ? _e : false,
1760
+ indent: options.indent ?? INDENT,
1761
+ allowNesting: options.listMode !== true && (options.allowNesting ?? true),
1762
+ allowDragging: options.allowDragging ?? true,
1763
+ allowDrop: options.allowDrop ?? (() => true),
1764
+ listMode: options.listMode ?? false,
1796
1765
  itemsPerPage: options.listMode ? itemsPerPage : undefined,
1797
1766
  page: options.listMode ? page : undefined
1798
1767
  };
@@ -1899,36 +1868,6 @@ DragoverNoChangeDetectDirective.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ t
1899
1868
  type: Output
1900
1869
  }] }); })();
1901
1870
 
1902
- class DragleaveNoChangeDetectDirective {
1903
- constructor(ngZone, el) {
1904
- this.ngZone = ngZone;
1905
- this.el = el;
1906
- this.dragleaveNoChangeDetect = new EventEmitter();
1907
- }
1908
- ngOnInit() {
1909
- this.ngZone.runOutsideAngular(() => {
1910
- this.eventSubscription = fromEvent(this.el.nativeElement, "dragleave").subscribe(($event) => {
1911
- this.dragleaveNoChangeDetect.emit($event);
1912
- });
1913
- });
1914
- }
1915
- ngOnDestroy() {
1916
- if (this.eventSubscription !== undefined) {
1917
- this.eventSubscription.unsubscribe();
1918
- }
1919
- }
1920
- }
1921
- DragleaveNoChangeDetectDirective.ɵfac = function DragleaveNoChangeDetectDirective_Factory(t) { return new (t || DragleaveNoChangeDetectDirective)(i0.ɵɵdirectiveInject(i0.NgZone), i0.ɵɵdirectiveInject(i0.ElementRef)); };
1922
- DragleaveNoChangeDetectDirective.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: DragleaveNoChangeDetectDirective, selectors: [["", "dragleaveNoChangeDetect", ""]], outputs: { dragleaveNoChangeDetect: "dragleaveNoChangeDetect" } });
1923
- (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(DragleaveNoChangeDetectDirective, [{
1924
- type: Directive,
1925
- args: [{
1926
- selector: "[dragleaveNoChangeDetect]"
1927
- }]
1928
- }], function () { return [{ type: i0.NgZone }, { type: i0.ElementRef }]; }, { dragleaveNoChangeDetect: [{
1929
- type: Output
1930
- }] }); })();
1931
-
1932
1871
  class LimbleTreePlaceholderComponent {
1933
1872
  constructor(dropZoneService, changeDetectorRef, treeService, treeConstructionStatus) {
1934
1873
  this.dropZoneService = dropZoneService;
@@ -1985,16 +1924,41 @@ LimbleTreePlaceholderComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ ty
1985
1924
  i0.ɵɵelementEnd();
1986
1925
  } if (rf & 2) {
1987
1926
  i0.ɵɵproperty("dropZone", ctx.dropZone);
1988
- } }, directives: [DropZoneComponent, DragoverNoChangeDetectDirective], styles: [".placeholder[_ngcontent-%COMP%]{width:100%;height:20px}"], changeDetection: 0 });
1927
+ } }, dependencies: [DropZoneComponent, DragoverNoChangeDetectDirective], styles: [".placeholder[_ngcontent-%COMP%]{width:100%;height:20px}"], changeDetection: 0 });
1989
1928
  (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LimbleTreePlaceholderComponent, [{
1990
1929
  type: Component,
1930
+ args: [{ selector: "limble-tree-placeholder", changeDetection: ChangeDetectionStrategy.OnPush, template: "<drop-zone [dropZone]=\"dropZone\"></drop-zone>\n<div class=\"placeholder\" (dragoverNoChangeDetect)=\"dragoverHandler()\"></div>\n", styles: [".placeholder{width:100%;height:20px}\n"] }]
1931
+ }], function () { return [{ type: DropZoneService }, { type: i0.ChangeDetectorRef }, { type: TreeService }, { type: TreeConstructionStatus }]; }, null); })();
1932
+
1933
+ class DragleaveNoChangeDetectDirective {
1934
+ constructor(ngZone, el) {
1935
+ this.ngZone = ngZone;
1936
+ this.el = el;
1937
+ this.dragleaveNoChangeDetect = new EventEmitter();
1938
+ }
1939
+ ngOnInit() {
1940
+ this.ngZone.runOutsideAngular(() => {
1941
+ this.eventSubscription = fromEvent(this.el.nativeElement, "dragleave").subscribe(($event) => {
1942
+ this.dragleaveNoChangeDetect.emit($event);
1943
+ });
1944
+ });
1945
+ }
1946
+ ngOnDestroy() {
1947
+ if (this.eventSubscription !== undefined) {
1948
+ this.eventSubscription.unsubscribe();
1949
+ }
1950
+ }
1951
+ }
1952
+ DragleaveNoChangeDetectDirective.ɵfac = function DragleaveNoChangeDetectDirective_Factory(t) { return new (t || DragleaveNoChangeDetectDirective)(i0.ɵɵdirectiveInject(i0.NgZone), i0.ɵɵdirectiveInject(i0.ElementRef)); };
1953
+ DragleaveNoChangeDetectDirective.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: DragleaveNoChangeDetectDirective, selectors: [["", "dragleaveNoChangeDetect", ""]], outputs: { dragleaveNoChangeDetect: "dragleaveNoChangeDetect" } });
1954
+ (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(DragleaveNoChangeDetectDirective, [{
1955
+ type: Directive,
1991
1956
  args: [{
1992
- selector: "limble-tree-placeholder",
1993
- templateUrl: "./limble-tree-placeholder.component.html",
1994
- styleUrls: ["./limble-tree-placeholder.component.scss"],
1995
- changeDetection: ChangeDetectionStrategy.OnPush
1957
+ selector: "[dragleaveNoChangeDetect]"
1996
1958
  }]
1997
- }], function () { return [{ type: DropZoneService }, { type: i0.ChangeDetectorRef }, { type: TreeService }, { type: TreeConstructionStatus }]; }, null); })();
1959
+ }], function () { return [{ type: i0.NgZone }, { type: i0.ElementRef }]; }, { dragleaveNoChangeDetect: [{
1960
+ type: Output
1961
+ }] }); })();
1998
1962
 
1999
1963
  const _c0 = ["host"];
2000
1964
  function LimbleTreeRootComponent_limble_tree_placeholder_1_Template(rf, ctx) { if (rf & 1) {
@@ -2036,8 +2000,7 @@ class LimbleTreeRootComponent {
2036
2000
  });
2037
2001
  }
2038
2002
  ngAfterViewInit() {
2039
- var _a;
2040
- if (((_a = this.options) === null || _a === void 0 ? void 0 : _a.listMode) !== true &&
2003
+ if (this.options?.listMode !== true &&
2041
2004
  (this.itemsPerPage !== undefined || this.page !== undefined)) {
2042
2005
  console.warn("pagination is only allowed in listMode; `itemsPerPage` and `page` inputs will be ignored");
2043
2006
  }
@@ -2133,15 +2096,10 @@ LimbleTreeRootComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: Lim
2133
2096
  } if (rf & 2) {
2134
2097
  i0.ɵɵadvance(1);
2135
2098
  i0.ɵɵproperty("ngIf", ctx.placeholder === true);
2136
- } }, directives: [DragoverNoChangeDetectDirective, DragleaveNoChangeDetectDirective, i2.NgIf, LimbleTreePlaceholderComponent], styles: [""] });
2099
+ } }, dependencies: [i2.NgIf, LimbleTreePlaceholderComponent, DragoverNoChangeDetectDirective, DragleaveNoChangeDetectDirective] });
2137
2100
  (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LimbleTreeRootComponent, [{
2138
2101
  type: Component,
2139
- args: [{
2140
- selector: "limble-tree-root",
2141
- templateUrl: "./limble-tree-root.component.html",
2142
- styleUrls: ["./limble-tree-root.component.scss"],
2143
- providers: [TreeService, DropZoneService, TreeConstructionStatus]
2144
- }]
2102
+ args: [{ selector: "limble-tree-root", providers: [TreeService, DropZoneService, TreeConstructionStatus], template: "<div\n (dragoverNoChangeDetect)=\"dragoverHandler($event)\"\n (dragleaveNoChangeDetect)=\"dragleaveHandler($event)\"\n (drop)=\"dropHandler($event)\"\n class=\"tree-event-host\"\n>\n <limble-tree-placeholder\n *ngIf=\"placeholder === true\"\n ></limble-tree-placeholder>\n <ng-template #host></ng-template>\n</div>\n" }]
2145
2103
  }], function () { return [{ type: TreeService }, { type: DropZoneService }, { type: DragStateService }, { type: GlobalEventsService }, { type: i0.NgZone }, { type: i0.ChangeDetectorRef }, { type: i0.ElementRef }]; }, { data: [{
2146
2104
  type: Input
2147
2105
  }], options: [{
@@ -2163,7 +2121,7 @@ class LimbleTreeModule {
2163
2121
  }
2164
2122
  LimbleTreeModule.ɵfac = function LimbleTreeModule_Factory(t) { return new (t || LimbleTreeModule)(); };
2165
2123
  LimbleTreeModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: LimbleTreeModule });
2166
- LimbleTreeModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ providers: [ComponentCreatorService, DragStateService, GlobalEventsService], imports: [[CommonModule]] });
2124
+ LimbleTreeModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ providers: [ComponentCreatorService, DragStateService, GlobalEventsService], imports: [CommonModule] });
2167
2125
  (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LimbleTreeModule, [{
2168
2126
  type: NgModule,
2169
2127
  args: [{
@@ -2188,9 +2146,9 @@ LimbleTreeModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ providers: [Compo
2188
2146
  LimbleTreePlaceholderComponent,
2189
2147
  DragoverNoChangeDetectDirective,
2190
2148
  DragleaveNoChangeDetectDirective], imports: [CommonModule], exports: [LimbleTreeRootComponent] }); })();
2191
- i0.ɵɵsetComponentScope(LimbleTreeNodeComponent, [i2.NgIf, DropZoneComponent,
2192
- DragoverNoChangeDetectDirective,
2193
- LimbleTreeBranchComponent], []);
2149
+ i0.ɵɵsetComponentScope(LimbleTreeNodeComponent, [i2.NgIf, LimbleTreeBranchComponent,
2150
+ DropZoneComponent,
2151
+ DragoverNoChangeDetectDirective], []);
2194
2152
 
2195
2153
  /*
2196
2154
  * Public API Surface of limble-tree
@@ -2201,4 +2159,4 @@ i0.ɵɵsetComponentScope(LimbleTreeNodeComponent, [i2.NgIf, DropZoneComponent,
2201
2159
  */
2202
2160
 
2203
2161
  export { LimbleTreeModule, LimbleTreeRootComponent };
2204
- //# sourceMappingURL=limble-limble-tree.js.map
2162
+ //# sourceMappingURL=limble-limble-tree.mjs.map