@rocketshow/designer 1.50.0 → 1.55.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.
@@ -1,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { Injectable, HostListener, ViewChild, Component, Pipe, EventEmitter, Input, Output, ChangeDetectionStrategy, ViewEncapsulation, NgModule } from '@angular/core';
2
+ import { Injectable, HostListener, ViewChild, Component, Pipe, EventEmitter, Input, Output, Directive, ChangeDetectionStrategy, ViewEncapsulation, NgModule } from '@angular/core';
3
3
  import * as i4 from '@ngx-translate/core';
4
4
  import { TranslateModule } from '@ngx-translate/core';
5
5
  import * as i1$1 from 'ngx-bootstrap/modal';
@@ -31,8 +31,7 @@ import { TypeaheadModule } from 'ngx-bootstrap/typeahead';
31
31
  import * as i3$3 from 'ngx-bootstrap-slider';
32
32
  import { NgxBootstrapSliderModule } from 'ngx-bootstrap-slider';
33
33
  import * as i9 from '@angular/common';
34
- import * as i7 from 'ngx-sortablejs-plus';
35
- import { SortablejsModule } from 'ngx-sortablejs-plus';
34
+ import Sortable from 'sortablejs';
36
35
  import * as i5$1 from 'ngx-bootstrap/accordion';
37
36
  import { AccordionModule } from 'ngx-bootstrap/accordion';
38
37
  import { KEYS, TREE_ACTIONS, TreeModule } from '@ali-hm/angular-tree-component';
@@ -6349,6 +6348,89 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
6349
6348
  args: ['document:keydown.enter', ['$event']]
6350
6349
  }] } });
6351
6350
 
6351
+ const DEFAULT_SORTABLE_OPTIONS = {
6352
+ animation: 300,
6353
+ handle: ".list-sort-handle",
6354
+ };
6355
+ class SortablejsDirective {
6356
+ constructor(element, zone) {
6357
+ this.element = element;
6358
+ this.zone = zone;
6359
+ this.sortablejsInit = new EventEmitter();
6360
+ }
6361
+ ngAfterViewInit() {
6362
+ this.create();
6363
+ }
6364
+ ngOnChanges(changes) {
6365
+ if (!this.sortableInstance || !changes.sortablejsOptions) {
6366
+ return;
6367
+ }
6368
+ const options = this.options;
6369
+ for (const optionName of Object.keys(options)) {
6370
+ this.sortableInstance.option(optionName, options[optionName]);
6371
+ }
6372
+ }
6373
+ ngOnDestroy() {
6374
+ this.sortableInstance?.destroy();
6375
+ }
6376
+ create() {
6377
+ const container = this.sortablejsContainer
6378
+ ? this.element.nativeElement.querySelector(this.sortablejsContainer)
6379
+ : this.element.nativeElement;
6380
+ if (!container) {
6381
+ return;
6382
+ }
6383
+ this.sortableInstance = Sortable.create(container, this.options);
6384
+ this.sortablejsInit.emit(this.sortableInstance);
6385
+ }
6386
+ get options() {
6387
+ const configuredOptions = {
6388
+ ...DEFAULT_SORTABLE_OPTIONS,
6389
+ ...(this.sortablejsOptions || {}),
6390
+ };
6391
+ return {
6392
+ ...configuredOptions,
6393
+ onUpdate: (event) => {
6394
+ this.zone.run(() => {
6395
+ this.moveItem(event);
6396
+ configuredOptions.onUpdate?.(event);
6397
+ });
6398
+ },
6399
+ };
6400
+ }
6401
+ moveItem(event) {
6402
+ if (!this.sortablejs) {
6403
+ return;
6404
+ }
6405
+ const oldIndex = event.oldDraggableIndex ?? event.oldIndex;
6406
+ const newIndex = event.newDraggableIndex ?? event.newIndex;
6407
+ if (oldIndex === undefined ||
6408
+ newIndex === undefined ||
6409
+ oldIndex === newIndex) {
6410
+ return;
6411
+ }
6412
+ const movedItems = this.sortablejs.splice(oldIndex, 1);
6413
+ this.sortablejs.splice(newIndex, 0, movedItems[0]);
6414
+ }
6415
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: SortablejsDirective, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive }); }
6416
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.16", type: SortablejsDirective, isStandalone: false, selector: "[sortablejs]", inputs: { sortablejs: "sortablejs", sortablejsContainer: "sortablejsContainer", sortablejsOptions: "sortablejsOptions" }, outputs: { sortablejsInit: "sortablejsInit" }, usesOnChanges: true, ngImport: i0 }); }
6417
+ }
6418
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: SortablejsDirective, decorators: [{
6419
+ type: Directive,
6420
+ args: [{
6421
+ selector: "[sortablejs]",
6422
+ standalone: false,
6423
+ }]
6424
+ }], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.NgZone }], propDecorators: { sortablejs: [{
6425
+ type: Input
6426
+ }], sortablejsContainer: [{
6427
+ type: Input
6428
+ }], sortablejsOptions: [{
6429
+ type: Input
6430
+ }], sortablejsInit: [{
6431
+ type: Output
6432
+ }] } });
6433
+
6352
6434
  class SceneComponent {
6353
6435
  constructor(sceneService, presetService, projectService, modalService, introService) {
6354
6436
  this.sceneService = sceneService;
@@ -6376,7 +6458,7 @@ class SceneComponent {
6376
6458
  });
6377
6459
  }
6378
6460
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: SceneComponent, deps: [{ token: SceneService }, { token: PresetService }, { token: ProjectService }, { token: i1$1.BsModalService }, { token: IntroService }], target: i0.ɵɵFactoryTarget.Component }); }
6379
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: SceneComponent, isStandalone: false, selector: "lib-app-scene", ngImport: i0, template: "<div class=\"card border-secondary panel h-100\" [class.card-intro-active]=\"introService.showStep('scenes')\">\n <div class=\"card-header d-flex\">\n <div>\n {{ 'designer.scene.title' | translate }}\n </div>\n <div class=\"ml-auto\">\n <a\n href=\"#\"\n class=\"d-none d-md-inline-block btn btn-secondary m-0 p-0\"\n [class.text-primary]=\"sceneService.multipleSelection == true\"\n (click)=\"sceneService.multipleSelection = !sceneService.multipleSelection; (false)\"\n ><i class=\"fa fa-object-group fa-fw\" aria-hidden=\"true\"></i\n ></a>\n <a href=\"#\" class=\"d-none d-md-inline-block btn btn-secondary m-0 p-0\" (click)=\"removeScene(); (false)\"\n ><i class=\"fa fa-minus-circle fa-fw\" aria-hidden=\"true\"></i\n ></a>\n <a href=\"#\" class=\"d-none d-md-inline-block btn btn-secondary m-0 p-0\" (click)=\"sceneService.addScene(); (false)\"\n ><i class=\"fa fa-plus-circle fa-fw\" aria-hidden=\"true\"></i\n ></a>\n </div>\n </div>\n <div class=\"card-body border-secondary p-0\">\n <!-- List of scenes -->\n <div class=\"list-group\" [sortablejs]=\"projectService.project.scenes\">\n @for (scene of projectService.project.scenes; track scene; let i = $index) {\n <div\n class=\"list-group-item\"\n [class.active-light]=\"projectService.project.previewPreset && sceneService.sceneIsSelected(scene)\"\n [class.active]=\"!projectService.project.previewPreset && sceneService.sceneIsSelected(scene)\"\n >\n <div class=\"row d-flex\" (click)=\"selectScene($event, i)\" style=\"cursor: pointer\">\n <div class=\"d-none d-md-block col-auto list-sort-handle my-auto\" style=\"cursor: move; cursor: -webkit-grabbing\">\n <i class=\"fa fa-bars\" aria-hidden=\"true\"></i>\n </div>\n <div class=\"my-auto\">\n {{ scene.name }}\n </div>\n <div class=\"my-auto ml-auto mr-2 d-flex\">\n <svg class=\"my-auto\" height=\"20\" width=\"20\">\n <circle cx=\"10\" cy=\"10\" r=\"9\" stroke=\"white\" stroke-width=\"1\" [attr.fill]=\"scene.color\" />\n </svg>\n </div>\n <div class=\"d-none d-md-flex my-auto mr-2\">\n <button type=\"button\" class=\"btn btn-secondary btn-sm py-0 px-1\" (click)=\"openSettings(scene); (false)\">...</button>\n </div>\n </div>\n </div>\n }\n </div>\n </div>\n</div>\n", styles: [""], dependencies: [{ kind: "directive", type: i7.SortablejsDirective, selector: "[sortablejs]", inputs: ["sortablejs", "sortablejsContainer", "sortablejsOptions", "sortablejsCloneFunction"], outputs: ["sortablejsInit"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }] }); }
6461
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: SceneComponent, isStandalone: false, selector: "lib-app-scene", ngImport: i0, template: "<div class=\"card border-secondary panel h-100\" [class.card-intro-active]=\"introService.showStep('scenes')\">\n <div class=\"card-header d-flex\">\n <div>\n {{ 'designer.scene.title' | translate }}\n </div>\n <div class=\"ml-auto\">\n <a\n href=\"#\"\n class=\"d-none d-md-inline-block btn btn-secondary m-0 p-0\"\n [class.text-primary]=\"sceneService.multipleSelection == true\"\n (click)=\"sceneService.multipleSelection = !sceneService.multipleSelection; (false)\"\n ><i class=\"fa fa-object-group fa-fw\" aria-hidden=\"true\"></i\n ></a>\n <a href=\"#\" class=\"d-none d-md-inline-block btn btn-secondary m-0 p-0\" (click)=\"removeScene(); (false)\"\n ><i class=\"fa fa-minus-circle fa-fw\" aria-hidden=\"true\"></i\n ></a>\n <a href=\"#\" class=\"d-none d-md-inline-block btn btn-secondary m-0 p-0\" (click)=\"sceneService.addScene(); (false)\"\n ><i class=\"fa fa-plus-circle fa-fw\" aria-hidden=\"true\"></i\n ></a>\n </div>\n </div>\n <div class=\"card-body border-secondary p-0\">\n <!-- List of scenes -->\n <div class=\"list-group\" [sortablejs]=\"projectService.project.scenes\">\n @for (scene of projectService.project.scenes; track scene; let i = $index) {\n <div\n class=\"list-group-item\"\n [class.active-light]=\"projectService.project.previewPreset && sceneService.sceneIsSelected(scene)\"\n [class.active]=\"!projectService.project.previewPreset && sceneService.sceneIsSelected(scene)\"\n >\n <div class=\"row d-flex\" (click)=\"selectScene($event, i)\" style=\"cursor: pointer\">\n <div class=\"d-none d-md-block col-auto list-sort-handle my-auto\" style=\"cursor: move; cursor: -webkit-grabbing\">\n <i class=\"fa fa-bars\" aria-hidden=\"true\"></i>\n </div>\n <div class=\"my-auto\">\n {{ scene.name }}\n </div>\n <div class=\"my-auto ml-auto mr-2 d-flex\">\n <svg class=\"my-auto\" height=\"20\" width=\"20\">\n <circle cx=\"10\" cy=\"10\" r=\"9\" stroke=\"white\" stroke-width=\"1\" [attr.fill]=\"scene.color\" />\n </svg>\n </div>\n <div class=\"d-none d-md-flex my-auto mr-2\">\n <button type=\"button\" class=\"btn btn-secondary btn-sm py-0 px-1\" (click)=\"openSettings(scene); (false)\">...</button>\n </div>\n </div>\n </div>\n }\n </div>\n </div>\n</div>\n", styles: [""], dependencies: [{ kind: "directive", type: SortablejsDirective, selector: "[sortablejs]", inputs: ["sortablejs", "sortablejsContainer", "sortablejsOptions"], outputs: ["sortablejsInit"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }] }); }
6380
6462
  }
6381
6463
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: SceneComponent, decorators: [{
6382
6464
  type: Component,
@@ -6435,7 +6517,7 @@ class FixtureComponent {
6435
6517
  this.fixturePoolService.open();
6436
6518
  }
6437
6519
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: FixtureComponent, deps: [{ token: ProjectService }, { token: PresetService }, { token: FixturePoolService }, { token: FixtureService }, { token: IntroService }], target: i0.ɵɵFactoryTarget.Component }); }
6438
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: FixtureComponent, isStandalone: false, selector: "lib-app-fixture", ngImport: i0, template: "<div class=\"card border-secondary h-100 panel\" [class.card-intro-active]=\"introService.showStep('fixtures')\">\n <div class=\"card-header d-flex\">\n <div>Fixtures</div>\n <div class=\"ml-auto\">\n <a href=\"#\" class=\"btn btn-secondary m-0, p-0\" (click)=\"selectNone(); (false)\"\n ><i class=\"fa fa-square-o fa-fw\" aria-hidden=\"true\"></i\n ></a>\n <a href=\"#\" class=\"btn btn-secondary m-0, p-0\" (click)=\"selectAll(); (false)\"\n ><i class=\"fa fa-check-square-o fa-fw\" aria-hidden=\"true\"></i\n ></a>\n <a href=\"#\" class=\"btn btn-secondary m-0, p-0\" (click)=\"openFixturePool(); (false)\"\n ><i class=\"fa fa-cog fa-fw\" aria-hidden=\"true\"></i\n ></a>\n </div>\n </div>\n\n <div class=\"card-body h-100 p-0\">\n <!-- List of fixtures -->\n @if (presetService.selectedPreset) {\n <div class=\"list-group\" [sortablejs]=\"projectService.project.presetFixtures\">\n @for (presetFixture of projectService.project.presetFixtures; track presetFixture) {\n <div class=\"list-group-item\" [class.inactive-list-item]=\"!fixtureIsSelected(presetFixture)\">\n <div class=\"row d-flex\" (click)=\"selectFixture($event, presetFixture)\" style=\"cursor: pointer\">\n <div class=\"col-auto list-sort-handle my-auto\" style=\"cursor: move; cursor: -webkit-grabbing\">\n <i class=\"fa fa-bars\" aria-hidden=\"true\"></i>\n </div>\n <div class=\"form-check\">\n <input type=\"checkbox\" class=\"form-check-input\" id=\"active\" [ngModel]=\"fixtureIsSelected(presetFixture)\" />\n </div>\n <div>\n <span\n class=\"icon-{{\n fixtureService.getFixtureIconClass(\n fixtureService.getProfileByUuid(fixtureService.getFixtureByUuid(presetFixture.fixtureUuid).profileUuid)\n )\n }} mr-1\"\n ></span>\n {{ fixtureName(presetFixture) }}\n </div>\n </div>\n </div>\n }\n </div>\n } @if (projectService.project.presetFixtures.length == 0) {\n <div class=\"w-100 h-100 d-flex p-3 text-center\">\n <a href=\"#\" class=\"m-auto\" (click)=\"openFixturePool(); (false)\"\n ><i class=\"fa fa-plus-circle fa-fw\" aria-hidden=\"true\"></i> {{ 'designer.fixture.no-fixtures' | translate }}</a\n >\n </div>\n }\n </div>\n</div>\n", styles: [""], dependencies: [{ kind: "directive", type: i3$2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i3$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.SortablejsDirective, selector: "[sortablejs]", inputs: ["sortablejs", "sortablejsContainer", "sortablejsOptions", "sortablejsCloneFunction"], outputs: ["sortablejsInit"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }] }); }
6520
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: FixtureComponent, isStandalone: false, selector: "lib-app-fixture", ngImport: i0, template: "<div class=\"card border-secondary h-100 panel\" [class.card-intro-active]=\"introService.showStep('fixtures')\">\n <div class=\"card-header d-flex\">\n <div>Fixtures</div>\n <div class=\"ml-auto\">\n <a href=\"#\" class=\"btn btn-secondary m-0, p-0\" (click)=\"selectNone(); (false)\"\n ><i class=\"fa fa-square-o fa-fw\" aria-hidden=\"true\"></i\n ></a>\n <a href=\"#\" class=\"btn btn-secondary m-0, p-0\" (click)=\"selectAll(); (false)\"\n ><i class=\"fa fa-check-square-o fa-fw\" aria-hidden=\"true\"></i\n ></a>\n <a href=\"#\" class=\"btn btn-secondary m-0, p-0\" (click)=\"openFixturePool(); (false)\"\n ><i class=\"fa fa-cog fa-fw\" aria-hidden=\"true\"></i\n ></a>\n </div>\n </div>\n\n <div class=\"card-body h-100 p-0\">\n <!-- List of fixtures -->\n @if (presetService.selectedPreset) {\n <div class=\"list-group\" [sortablejs]=\"projectService.project.presetFixtures\">\n @for (presetFixture of projectService.project.presetFixtures; track presetFixture) {\n <div class=\"list-group-item\" [class.inactive-list-item]=\"!fixtureIsSelected(presetFixture)\">\n <div class=\"row d-flex\" (click)=\"selectFixture($event, presetFixture)\" style=\"cursor: pointer\">\n <div class=\"col-auto list-sort-handle my-auto\" style=\"cursor: move; cursor: -webkit-grabbing\">\n <i class=\"fa fa-bars\" aria-hidden=\"true\"></i>\n </div>\n <div class=\"form-check\">\n <input type=\"checkbox\" class=\"form-check-input\" id=\"active\" [ngModel]=\"fixtureIsSelected(presetFixture)\" />\n </div>\n <div>\n <span\n class=\"icon-{{\n fixtureService.getFixtureIconClass(\n fixtureService.getProfileByUuid(fixtureService.getFixtureByUuid(presetFixture.fixtureUuid).profileUuid)\n )\n }} mr-1\"\n ></span>\n {{ fixtureName(presetFixture) }}\n </div>\n </div>\n </div>\n }\n </div>\n } @if (projectService.project.presetFixtures.length == 0) {\n <div class=\"w-100 h-100 d-flex p-3 text-center\">\n <a href=\"#\" class=\"m-auto\" (click)=\"openFixturePool(); (false)\"\n ><i class=\"fa fa-plus-circle fa-fw\" aria-hidden=\"true\"></i> {{ 'designer.fixture.no-fixtures' | translate }}</a\n >\n </div>\n }\n </div>\n</div>\n", styles: [""], dependencies: [{ kind: "directive", type: i3$2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i3$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: SortablejsDirective, selector: "[sortablejs]", inputs: ["sortablejs", "sortablejsContainer", "sortablejsOptions"], outputs: ["sortablejsInit"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }] }); }
6439
6521
  }
6440
6522
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: FixtureComponent, decorators: [{
6441
6523
  type: Component,
@@ -7740,7 +7822,7 @@ class PresetComponent {
7740
7822
  });
7741
7823
  }
7742
7824
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PresetComponent, deps: [{ token: PresetService }, { token: SceneService }, { token: ProjectService }, { token: IntroService }, { token: i1$1.BsModalService }], target: i0.ɵɵFactoryTarget.Component }); }
7743
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: PresetComponent, isStandalone: false, selector: "lib-app-preset", viewQueries: [{ propertyName: "tree", first: true, predicate: ["tree"], descendants: true }], ngImport: i0, template: "<div\n class=\"card border-secondary h-100 panel card-intro-preset card-intro-active\"\n [class.card-intro-active]=\"introService.showStep('presets')\"\n>\n <div class=\"card-header d-flex\">\n <div>\n {{ 'designer.preset.title' | translate }}\n </div>\n <div class=\"ml-auto\">\n <a href=\"#\" class=\"btn btn-secondary m-0, p-0\" (click)=\"removePreset(); (false)\"\n ><i class=\"fa fa-minus-circle fa-fw\" aria-hidden=\"true\"></i\n ></a>\n <a href=\"#\" class=\"btn btn-secondary m-0, p-0\" (click)=\"addPreset(); (false)\"\n ><i class=\"fa fa-plus-circle fa-fw\" aria-hidden=\"true\"></i\n ></a>\n </div>\n </div>\n\n <div class=\"card-body h-100 p-0\">\n <!-- List of presets -->\n <!-- <tree-root #tree [nodes]=\"treeNodes\" [options]=\"treeOptions\" (activate)=\"onActivate($event)\">\n <ng-template #treeNodeTemplate let-node let-index=\"index\">\n <span>{{ node.data.name }}</span>\n </ng-template>\n </tree-root> -->\n\n <div class=\"list-group\" [sortablejs]=\"projectService.project.presets\">\n @for (item of projectService.project.presets; track item; let i = $index) {\n <div\n class=\"list-group-item\"\n (click)=\"selectPreset(i)\"\n [class.active-light]=\"!projectService.project.previewPreset && item == presetService.selectedPreset\"\n [class.active]=\"projectService.project.previewPreset && item == presetService.selectedPreset\"\n [class.inactive-list-item]=\"!sceneService.presetIsSelected(item)\"\n >\n <div class=\"row d-flex\" style=\"cursor: pointer\">\n <div class=\"col-auto list-sort-handle my-auto\" style=\"cursor: move; cursor: -webkit-grabbing\">\n <i class=\"fa fa-bars\" aria-hidden=\"true\"></i>\n </div>\n <div class=\"form-check\">\n <input\n type=\"checkbox\"\n [disabled]=\"!enableCheckbox()\"\n class=\"form-check-input\"\n id=\"active\"\n [ngModel]=\"sceneService.presetIsSelected(item)\"\n (ngModelChange)=\"activatePreset($event, i)\"\n (click)=\"$event.stopPropagation()\"\n />\n </div>\n <div>\n {{ item.name }}\n </div>\n <div class=\"my-auto ml-auto mr-2 d-flex\">\n <button type=\"button\" class=\"btn btn-secondary btn-sm py-0 px-1\" (click)=\"openSettings(item); (false)\">...</button>\n </div>\n </div>\n </div>\n }\n </div>\n </div>\n</div>\n", styles: [""], dependencies: [{ kind: "directive", type: i3$2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i3$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.SortablejsDirective, selector: "[sortablejs]", inputs: ["sortablejs", "sortablejsContainer", "sortablejsOptions", "sortablejsCloneFunction"], outputs: ["sortablejsInit"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }] }); }
7825
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: PresetComponent, isStandalone: false, selector: "lib-app-preset", viewQueries: [{ propertyName: "tree", first: true, predicate: ["tree"], descendants: true }], ngImport: i0, template: "<div\n class=\"card border-secondary h-100 panel card-intro-preset card-intro-active\"\n [class.card-intro-active]=\"introService.showStep('presets')\"\n>\n <div class=\"card-header d-flex\">\n <div>\n {{ 'designer.preset.title' | translate }}\n </div>\n <div class=\"ml-auto\">\n <a href=\"#\" class=\"btn btn-secondary m-0, p-0\" (click)=\"removePreset(); (false)\"\n ><i class=\"fa fa-minus-circle fa-fw\" aria-hidden=\"true\"></i\n ></a>\n <a href=\"#\" class=\"btn btn-secondary m-0, p-0\" (click)=\"addPreset(); (false)\"\n ><i class=\"fa fa-plus-circle fa-fw\" aria-hidden=\"true\"></i\n ></a>\n </div>\n </div>\n\n <div class=\"card-body h-100 p-0\">\n <!-- List of presets -->\n <!-- <tree-root #tree [nodes]=\"treeNodes\" [options]=\"treeOptions\" (activate)=\"onActivate($event)\">\n <ng-template #treeNodeTemplate let-node let-index=\"index\">\n <span>{{ node.data.name }}</span>\n </ng-template>\n </tree-root> -->\n\n <div class=\"list-group\" [sortablejs]=\"projectService.project.presets\">\n @for (item of projectService.project.presets; track item; let i = $index) {\n <div\n class=\"list-group-item\"\n (click)=\"selectPreset(i)\"\n [class.active-light]=\"!projectService.project.previewPreset && item == presetService.selectedPreset\"\n [class.active]=\"projectService.project.previewPreset && item == presetService.selectedPreset\"\n [class.inactive-list-item]=\"!sceneService.presetIsSelected(item)\"\n >\n <div class=\"row d-flex\" style=\"cursor: pointer\">\n <div class=\"col-auto list-sort-handle my-auto\" style=\"cursor: move; cursor: -webkit-grabbing\">\n <i class=\"fa fa-bars\" aria-hidden=\"true\"></i>\n </div>\n <div class=\"form-check\">\n <input\n type=\"checkbox\"\n [disabled]=\"!enableCheckbox()\"\n class=\"form-check-input\"\n id=\"active\"\n [ngModel]=\"sceneService.presetIsSelected(item)\"\n (ngModelChange)=\"activatePreset($event, i)\"\n (click)=\"$event.stopPropagation()\"\n />\n </div>\n <div>\n {{ item.name }}\n </div>\n <div class=\"my-auto ml-auto mr-2 d-flex\">\n <button type=\"button\" class=\"btn btn-secondary btn-sm py-0 px-1\" (click)=\"openSettings(item); (false)\">...</button>\n </div>\n </div>\n </div>\n }\n </div>\n </div>\n</div>\n", styles: [""], dependencies: [{ kind: "directive", type: i3$2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i3$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: SortablejsDirective, selector: "[sortablejs]", inputs: ["sortablejs", "sortablejsContainer", "sortablejsOptions"], outputs: ["sortablejsInit"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }] }); }
7744
7826
  }
7745
7827
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: PresetComponent, decorators: [{
7746
7828
  type: Component,
@@ -8425,7 +8507,8 @@ class DesignerModule {
8425
8507
  SceneSettingsComponent,
8426
8508
  ProjectSaveComponent,
8427
8509
  FixturePoolCreateFromFileComponent,
8428
- DropzoneComponent], imports: [i3.RouterModule, BrowserModule,
8510
+ DropzoneComponent,
8511
+ SortablejsDirective], imports: [i3.RouterModule, BrowserModule,
8429
8512
  BrowserAnimationsModule,
8430
8513
  FormsModule,
8431
8514
  NgxBootstrapSliderModule,
@@ -8433,7 +8516,6 @@ class DesignerModule {
8433
8516
  AccordionModule,
8434
8517
  PopoverModule,
8435
8518
  TypeaheadModule,
8436
- SortablejsModule,
8437
8519
  DropzoneModule, i3$1.ToastrModule, TreeModule], exports: [DesignerComponent] }); }
8438
8520
  static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: DesignerModule, providers: [provideHttpClient(withInterceptorsFromDi())], imports: [RouterModule.forRoot([], {}),
8439
8521
  BrowserModule,
@@ -8444,7 +8526,6 @@ class DesignerModule {
8444
8526
  AccordionModule,
8445
8527
  PopoverModule,
8446
8528
  TypeaheadModule,
8447
- SortablejsModule,
8448
8529
  DropzoneModule,
8449
8530
  ToastrModule.forRoot({
8450
8531
  newestOnTop: true,
@@ -8493,6 +8574,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
8493
8574
  ProjectSaveComponent,
8494
8575
  FixturePoolCreateFromFileComponent,
8495
8576
  DropzoneComponent,
8577
+ SortablejsDirective,
8496
8578
  ],
8497
8579
  exports: [DesignerComponent],
8498
8580
  imports: [
@@ -8505,7 +8587,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
8505
8587
  AccordionModule,
8506
8588
  PopoverModule,
8507
8589
  TypeaheadModule,
8508
- SortablejsModule,
8509
8590
  DropzoneModule,
8510
8591
  ToastrModule.forRoot({
8511
8592
  newestOnTop: true,