@ajf/material 13.0.0-next.9 → 13.0.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.
- package/{report-builder/index.d.ts → barcode/barcode_public_index.d.ts} +1 -1
- package/barcode/index.d.ts +19 -1
- package/barcode/package.json +2 -2
- package/calendar/calendar_public_index.d.ts +4 -0
- package/calendar/index.d.ts +19 -1
- package/calendar/package.json +2 -2
- package/checkbox-group/checkbox-group_public_index.d.ts +4 -0
- package/checkbox-group/index.d.ts +19 -1
- package/checkbox-group/package.json +2 -2
- package/esm2020/barcode/barcode-module.mjs +7 -11
- package/esm2020/barcode/barcode.mjs +6 -6
- package/esm2020/barcode/barcode_public_index.mjs +5 -0
- package/esm2020/barcode/index.mjs +20 -2
- package/esm2020/calendar/calendar-module.mjs +8 -28
- package/esm2020/calendar/calendar.mjs +7 -11
- package/esm2020/calendar/calendar_public_index.mjs +5 -0
- package/esm2020/calendar/index.mjs +20 -2
- package/esm2020/checkbox-group/checkbox-group-item.mjs +6 -6
- package/esm2020/checkbox-group/checkbox-group-module.mjs +8 -27
- package/esm2020/checkbox-group/checkbox-group_public_index.mjs +5 -0
- package/esm2020/checkbox-group/index.mjs +20 -2
- package/esm2020/form-builder/branch-line.mjs +5 -5
- package/esm2020/form-builder/choices-origin-data-source.mjs +1 -1
- package/esm2020/form-builder/choices-origin-editor-dialog.mjs +10 -7
- package/esm2020/form-builder/choices-origin-editor.mjs +4 -4
- package/esm2020/form-builder/condition-editor-dialog.mjs +4 -4
- package/esm2020/form-builder/condition-editor.mjs +12 -11
- package/esm2020/form-builder/form-builder-module.mjs +85 -34
- package/esm2020/form-builder/form-builder-service.mjs +135 -128
- package/esm2020/form-builder/form-builder-utils.mjs +4 -3
- package/esm2020/form-builder/form-builder.mjs +33 -29
- package/esm2020/form-builder/form-builder_public_index.mjs +5 -0
- package/esm2020/form-builder/index.mjs +20 -2
- package/esm2020/form-builder/node-entry.mjs +10 -8
- package/esm2020/form-builder/node-properties.mjs +320 -315
- package/esm2020/form-builder/node-type-entry.mjs +5 -5
- package/esm2020/form-builder/string-identifier-dialog.mjs +8 -10
- package/esm2020/form-builder/validation-condition-editor-dialog.mjs +4 -4
- package/esm2020/form-builder/warning-condition-editor-dialog.mjs +4 -4
- package/esm2020/forms/barcode-field.mjs +6 -6
- package/esm2020/forms/boolean-field.mjs +6 -6
- package/esm2020/forms/date-field.mjs +5 -5
- package/esm2020/forms/date-input-field.mjs +6 -6
- package/esm2020/forms/empty-field.mjs +6 -6
- package/esm2020/forms/field-service.mjs +45 -45
- package/esm2020/forms/field-warning-dialog.mjs +4 -4
- package/esm2020/forms/field.mjs +5 -5
- package/esm2020/forms/form.mjs +5 -5
- package/esm2020/forms/forms-module.mjs +119 -43
- package/esm2020/forms/forms_public_index.mjs +5 -0
- package/esm2020/forms/index.mjs +20 -2
- package/esm2020/forms/input-field.mjs +5 -5
- package/esm2020/forms/multiple-choice-field.mjs +6 -6
- package/esm2020/forms/range-field.mjs +6 -6
- package/esm2020/forms/single-choice-field.mjs +6 -6
- package/esm2020/forms/table-field.mjs +6 -6
- package/esm2020/forms/text-field.mjs +5 -5
- package/esm2020/forms/time-field.mjs +6 -6
- package/esm2020/forms/video-url-field.mjs +5 -5
- package/esm2020/forms/warning-alert-service.mjs +4 -4
- package/esm2020/image/image-module.mjs +8 -19
- package/esm2020/image/image.mjs +5 -5
- package/esm2020/image/image_public_index.mjs +5 -0
- package/esm2020/image/index.mjs +20 -2
- package/esm2020/monaco-editor/autocomplete-singleton-model.mjs +3 -2
- package/esm2020/monaco-editor/editor-options-model.mjs +1 -1
- package/esm2020/monaco-editor/index.mjs +20 -2
- package/esm2020/monaco-editor/monaco-editor-module.mjs +7 -11
- package/esm2020/monaco-editor/monaco-editor.mjs +6 -6
- package/esm2020/monaco-editor/monaco-editor_public_index.mjs +5 -0
- package/esm2020/node-icon/index.mjs +20 -2
- package/esm2020/node-icon/node-icon-module.mjs +8 -19
- package/esm2020/node-icon/node-icon.mjs +4 -4
- package/esm2020/node-icon/node-icon_public_index.mjs +5 -0
- package/esm2020/page-slider/index.mjs +20 -2
- package/esm2020/page-slider/page-slider-module.mjs +8 -14
- package/esm2020/page-slider/page-slider.mjs +5 -5
- package/esm2020/page-slider/page-slider_public_index.mjs +5 -0
- package/esm2020/reports/chart-widget.mjs +5 -5
- package/esm2020/reports/filter-widget.mjs +71 -0
- package/esm2020/reports/formula-widget.mjs +5 -5
- package/esm2020/reports/image-container-widget.mjs +5 -5
- package/esm2020/reports/image-widget.mjs +5 -5
- package/esm2020/reports/index.mjs +20 -2
- package/esm2020/reports/map-widget.mjs +5 -5
- package/esm2020/reports/page-break-widget.mjs +5 -5
- package/esm2020/reports/public-api.mjs +2 -1
- package/esm2020/reports/report.mjs +5 -5
- package/esm2020/reports/reports-module.mjs +15 -12
- package/esm2020/reports/reports_public_index.mjs +5 -0
- package/esm2020/reports/table-widget.mjs +6 -6
- package/esm2020/reports/text-widget.mjs +5 -5
- package/esm2020/reports/widget.mjs +19 -16
- package/esm2020/time/index.mjs +20 -2
- package/esm2020/time/time-module.mjs +8 -22
- package/esm2020/time/time.mjs +6 -6
- package/esm2020/time/time_public_index.mjs +5 -0
- package/fesm2015/barcode.mjs +32 -14
- package/fesm2015/barcode.mjs.map +1 -1
- package/fesm2015/calendar.mjs +34 -36
- package/fesm2015/calendar.mjs.map +1 -1
- package/fesm2015/checkbox-group.mjs +33 -30
- package/fesm2015/checkbox-group.mjs.map +1 -1
- package/fesm2015/form-builder.mjs +638 -544
- package/fesm2015/form-builder.mjs.map +1 -1
- package/fesm2015/forms.mjs +235 -137
- package/fesm2015/forms.mjs.map +1 -1
- package/fesm2015/image.mjs +32 -21
- package/fesm2015/image.mjs.map +1 -1
- package/fesm2015/monaco-editor.mjs +34 -15
- package/fesm2015/monaco-editor.mjs.map +1 -1
- package/fesm2015/node-icon.mjs +32 -21
- package/fesm2015/node-icon.mjs.map +1 -1
- package/fesm2015/page-slider.mjs +32 -16
- package/fesm2015/page-slider.mjs.map +1 -1
- package/fesm2015/reports.mjs +156 -66
- package/fesm2015/reports.mjs.map +1 -1
- package/fesm2015/time.mjs +33 -25
- package/fesm2015/time.mjs.map +1 -1
- package/fesm2020/barcode.mjs +32 -14
- package/fesm2020/barcode.mjs.map +1 -1
- package/fesm2020/calendar.mjs +34 -36
- package/fesm2020/calendar.mjs.map +1 -1
- package/fesm2020/checkbox-group.mjs +33 -30
- package/fesm2020/checkbox-group.mjs.map +1 -1
- package/fesm2020/form-builder.mjs +638 -544
- package/fesm2020/form-builder.mjs.map +1 -1
- package/fesm2020/forms.mjs +235 -137
- package/fesm2020/forms.mjs.map +1 -1
- package/fesm2020/image.mjs +32 -21
- package/fesm2020/image.mjs.map +1 -1
- package/fesm2020/monaco-editor.mjs +34 -15
- package/fesm2020/monaco-editor.mjs.map +1 -1
- package/fesm2020/node-icon.mjs +32 -21
- package/fesm2020/node-icon.mjs.map +1 -1
- package/fesm2020/page-slider.mjs +32 -16
- package/fesm2020/page-slider.mjs.map +1 -1
- package/fesm2020/reports.mjs +156 -66
- package/fesm2020/reports.mjs.map +1 -1
- package/fesm2020/time.mjs +33 -25
- package/fesm2020/time.mjs.map +1 -1
- package/form-builder/form-builder_public_index.d.ts +4 -0
- package/form-builder/index.d.ts +19 -1
- package/form-builder/node-properties.d.ts +1 -0
- package/form-builder/package.json +2 -2
- package/forms/forms_public_index.d.ts +4 -0
- package/forms/index.d.ts +19 -1
- package/forms/package.json +2 -2
- package/image/image_public_index.d.ts +4 -0
- package/image/index.d.ts +19 -1
- package/image/package.json +2 -2
- package/monaco-editor/index.d.ts +19 -1
- package/monaco-editor/monaco-editor_public_index.d.ts +4 -0
- package/monaco-editor/package.json +2 -2
- package/node-icon/index.d.ts +19 -1
- package/node-icon/node-icon_public_index.d.ts +4 -0
- package/node-icon/package.json +2 -2
- package/package.json +26 -36
- package/page-slider/index.d.ts +19 -1
- package/page-slider/package.json +2 -2
- package/page-slider/page-slider_public_index.d.ts +4 -0
- package/reports/filter-widget.d.ts +37 -0
- package/reports/index.d.ts +19 -1
- package/reports/package.json +2 -2
- package/reports/public-api.d.ts +1 -0
- package/reports/reports-module.d.ts +21 -19
- package/reports/reports_public_index.d.ts +4 -0
- package/time/index.d.ts +19 -1
- package/time/package.json +2 -2
- package/time/time_public_index.d.ts +4 -0
- package/esm2020/report-builder/column.mjs +0 -76
- package/esm2020/report-builder/condition-editor.mjs +0 -162
- package/esm2020/report-builder/content.mjs +0 -256
- package/esm2020/report-builder/custom-widget-dialog.mjs +0 -50
- package/esm2020/report-builder/custom-widget-toolbar-button.mjs +0 -67
- package/esm2020/report-builder/custom-widgets-toolbar.mjs +0 -124
- package/esm2020/report-builder/forms-analyzer-dialog.mjs +0 -328
- package/esm2020/report-builder/forms-analyzer.mjs +0 -244
- package/esm2020/report-builder/image-filter.mjs +0 -38
- package/esm2020/report-builder/image-group.mjs +0 -112
- package/esm2020/report-builder/index.mjs +0 -5
- package/esm2020/report-builder/models.mjs +0 -23
- package/esm2020/report-builder/operations.mjs +0 -23
- package/esm2020/report-builder/properties.mjs +0 -761
- package/esm2020/report-builder/public-api.mjs +0 -26
- package/esm2020/report-builder/quill-editor.mjs +0 -307
- package/esm2020/report-builder/renderer-widget.mjs +0 -243
- package/esm2020/report-builder/report-builder-drag-data.mjs +0 -23
- package/esm2020/report-builder/report-builder-module.mjs +0 -155
- package/esm2020/report-builder/report-builder-service.mjs +0 -1690
- package/esm2020/report-builder/report-builder.mjs +0 -51
- package/esm2020/report-builder/theme-color-dialog.mjs +0 -67
- package/esm2020/report-builder/theme-color.mjs +0 -196
- package/esm2020/report-builder/tokens.mjs +0 -24
- package/esm2020/report-builder/toolbar-dialog.mjs +0 -54
- package/esm2020/report-builder/toolbar.mjs +0 -91
- package/esm2020/report-builder/utils.mjs +0 -48
- package/esm2020/report-builder/widget-toolbar-button.mjs +0 -46
- package/esm2020/report-builder/widgets-row-buttons.mjs +0 -136
- package/esm2020/report-builder/widgets-toolbar.mjs +0 -80
- package/fesm2015/report-builder.mjs +0 -5184
- package/fesm2015/report-builder.mjs.map +0 -1
- package/fesm2020/report-builder.mjs +0 -5182
- package/fesm2020/report-builder.mjs.map +0 -1
- package/report-builder/_report-builder.scss +0 -0
- package/report-builder/column.d.ts +0 -66
- package/report-builder/condition-editor.d.ts +0 -70
- package/report-builder/content.d.ts +0 -145
- package/report-builder/custom-widget-dialog.d.ts +0 -13
- package/report-builder/custom-widget-toolbar-button.d.ts +0 -48
- package/report-builder/custom-widgets-toolbar.d.ts +0 -74
- package/report-builder/forms-analyzer-dialog.d.ts +0 -94
- package/report-builder/forms-analyzer.d.ts +0 -105
- package/report-builder/image-filter.d.ts +0 -29
- package/report-builder/image-group.d.ts +0 -72
- package/report-builder/models.d.ts +0 -43
- package/report-builder/operations.d.ts +0 -45
- package/report-builder/package.json +0 -9
- package/report-builder/properties.d.ts +0 -368
- package/report-builder/public-api.d.ts +0 -26
- package/report-builder/quill-editor.d.ts +0 -116
- package/report-builder/renderer-widget.d.ts +0 -83
- package/report-builder/report-builder-drag-data.d.ts +0 -32
- package/report-builder/report-builder-module.d.ts +0 -52
- package/report-builder/report-builder-service.d.ts +0 -725
- package/report-builder/report-builder.d.ts +0 -39
- package/report-builder/theme-color-dialog.d.ts +0 -45
- package/report-builder/theme-color.d.ts +0 -111
- package/report-builder/tokens.d.ts +0 -24
- package/report-builder/toolbar-dialog.d.ts +0 -12
- package/report-builder/toolbar.d.ts +0 -30
- package/report-builder/utils.d.ts +0 -29
- package/report-builder/widget-toolbar-button.d.ts +0 -31
- package/report-builder/widgets-row-buttons.d.ts +0 -60
- package/report-builder/widgets-toolbar.d.ts +0 -26
|
@@ -50,7 +50,7 @@ import { MatToolbarModule } from '@angular/material/toolbar';
|
|
|
50
50
|
import * as i6$2 from '@angular/material/tooltip';
|
|
51
51
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
52
52
|
import * as i1 from '@ajf/core/forms';
|
|
53
|
-
import { isChoicesFixedOrigin, isContainerNode, AjfNodeType, AjfFieldType, createField, createContainerNode, createForm, createChoicesFixedOrigin, isSlidesNode, isFieldWithChoices, isRepeatingContainerNode, isField, createValidationGroup, notEmptyValidation, minValidation, maxValidation, minDigitsValidation, maxDigitsValidation, createValidation, createWarningGroup, notEmptyWarning, createWarning, isNumberField } from '@ajf/core/forms';
|
|
53
|
+
import { isChoicesFixedOrigin, isContainerNode, AjfNodeType, AjfFieldType, createField, createContainerNode, createForm, createChoicesFixedOrigin, isSlidesNode, isFieldWithChoices, isRepeatingContainerNode, isField, createValidationGroup, notEmptyValidation, minValidation, maxValidation, minDigitsValidation, maxDigitsValidation, createValidation, createWarningGroup, notEmptyWarning, createWarning, isRangeField, isNumberField } from '@ajf/core/forms';
|
|
54
54
|
import { DataSource } from '@angular/cdk/collections';
|
|
55
55
|
import { BehaviorSubject, Subject, Subscription, combineLatest } from 'rxjs';
|
|
56
56
|
import * as i6$1 from '@ngneat/transloco';
|
|
@@ -113,9 +113,9 @@ class AjfFbBranchLine {
|
|
|
113
113
|
this._renderer.setStyle(this._el.nativeElement, 'border-color', this._color);
|
|
114
114
|
}
|
|
115
115
|
}
|
|
116
|
-
AjfFbBranchLine.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
117
|
-
AjfFbBranchLine.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-
|
|
118
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
116
|
+
AjfFbBranchLine.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbBranchLine, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component });
|
|
117
|
+
AjfFbBranchLine.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFbBranchLine, selector: "ajf-fb-branch-line", inputs: { offset: "offset", color: "color", height: "height" }, ngImport: i0, template: "", styles: ["ajf-fb-branch-line{display:block;position:absolute;top:25px;left:25px;width:25px;border-top:2px solid;border-left:2px solid;border-top-left-radius:6px;transition:height .5s ease-in-out}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
118
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbBranchLine, decorators: [{
|
|
119
119
|
type: Component,
|
|
120
120
|
args: [{ selector: 'ajf-fb-branch-line', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "", styles: ["ajf-fb-branch-line{display:block;position:absolute;top:25px;left:25px;width:25px;border-top:2px solid;border-left:2px solid;border-top-left-radius:6px;transition:height .5s ease-in-out}\n"] }]
|
|
121
121
|
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.Renderer2 }]; }, propDecorators: { offset: [{
|
|
@@ -224,9 +224,9 @@ class AjfFbChoicesOriginEditor {
|
|
|
224
224
|
this._choices.updateChoices(this._choicesArr);
|
|
225
225
|
}
|
|
226
226
|
}
|
|
227
|
-
AjfFbChoicesOriginEditor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
228
|
-
AjfFbChoicesOriginEditor.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-
|
|
229
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
227
|
+
AjfFbChoicesOriginEditor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbChoicesOriginEditor, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
228
|
+
AjfFbChoicesOriginEditor.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFbChoicesOriginEditor, selector: "ajf-fb-choices-origin-editor", inputs: { choicesOrigin: "choicesOrigin" }, ngImport: i0, template: "<div>\n <mat-form-field>\n <input matInput [(ngModel)]=\"name\" [placeholder]=\"'Name' | transloco\" />\n </mat-form-field>\n <mat-form-field>\n <input matInput [(ngModel)]=\"label\" [placeholder]=\"'Label' | transloco\" />\n </mat-form-field>\n <ng-template [ngIf]=\"canEditChoices\">\n <button (click)=\"addRow()\" mat-button>\n <mat-icon>add</mat-icon>\n <span>{{'Add value'|transloco}}</span>\n </button>\n <mat-table [dataSource]=\"choices\">\n <ng-container matColumnDef=\"label\">\n <mat-header-cell *matHeaderCellDef\n >{{'Label'|transloco}}</mat-header-cell\n >\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <input matInput [(ngModel)]=\"row.label\" type=\"text\" />\n </mat-cell>\n </ng-container>\n <ng-container matColumnDef=\"value\">\n <mat-header-cell *matHeaderCellDef\n >{{'Value'|transloco}}</mat-header-cell\n >\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <input matInput [(ngModel)]=\"row.value\" type=\"text\" />\n </mat-cell>\n </ng-container>\n <ng-container matColumnDef=\"delete\">\n <mat-header-cell *matHeaderCellDef\n >{{'Delete'|transloco}}</mat-header-cell\n >\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <mat-icon (click)=\"deleteRow(idx)\">{{'delete'|transloco}}</mat-icon>\n </mat-cell>\n </ng-container>\n\n <mat-header-row *matHeaderRowDef=\"displayedColumns\"></mat-header-row>\n <mat-row *matRowDef=\"let row; columns: displayedColumns;\"></mat-row>\n </mat-table>\n </ng-template>\n</div>\n", styles: ["ajf-fb-choices-origin-editor mat-form-field+mat-form-field{margin-left:1em}ajf-fb-choices-origin-editor mat-table{max-height:300px}ajf-fb-choices-origin-editor mat-table mat-icon{cursor:pointer}\n"], components: [{ type: i5.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { type: i4.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { type: i4.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }], directives: [{ type: i6.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i3$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i3$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i3$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4.MatColumnDef, selector: "[matColumnDef]", inputs: ["sticky", "matColumnDef"] }, { type: i4.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { type: i4.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { type: i4.MatCellDef, selector: "[matCellDef]" }, { type: i4.MatCell, selector: "mat-cell, td[mat-cell]" }, { type: i4.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { type: i4.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }], pipes: { "transloco": i6$1.TranslocoPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
229
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbChoicesOriginEditor, decorators: [{
|
|
230
230
|
type: Component,
|
|
231
231
|
args: [{ selector: 'ajf-fb-choices-origin-editor', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div>\n <mat-form-field>\n <input matInput [(ngModel)]=\"name\" [placeholder]=\"'Name' | transloco\" />\n </mat-form-field>\n <mat-form-field>\n <input matInput [(ngModel)]=\"label\" [placeholder]=\"'Label' | transloco\" />\n </mat-form-field>\n <ng-template [ngIf]=\"canEditChoices\">\n <button (click)=\"addRow()\" mat-button>\n <mat-icon>add</mat-icon>\n <span>{{'Add value'|transloco}}</span>\n </button>\n <mat-table [dataSource]=\"choices\">\n <ng-container matColumnDef=\"label\">\n <mat-header-cell *matHeaderCellDef\n >{{'Label'|transloco}}</mat-header-cell\n >\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <input matInput [(ngModel)]=\"row.label\" type=\"text\" />\n </mat-cell>\n </ng-container>\n <ng-container matColumnDef=\"value\">\n <mat-header-cell *matHeaderCellDef\n >{{'Value'|transloco}}</mat-header-cell\n >\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <input matInput [(ngModel)]=\"row.value\" type=\"text\" />\n </mat-cell>\n </ng-container>\n <ng-container matColumnDef=\"delete\">\n <mat-header-cell *matHeaderCellDef\n >{{'Delete'|transloco}}</mat-header-cell\n >\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <mat-icon (click)=\"deleteRow(idx)\">{{'delete'|transloco}}</mat-icon>\n </mat-cell>\n </ng-container>\n\n <mat-header-row *matHeaderRowDef=\"displayedColumns\"></mat-header-row>\n <mat-row *matRowDef=\"let row; columns: displayedColumns;\"></mat-row>\n </mat-table>\n </ng-template>\n</div>\n", styles: ["ajf-fb-choices-origin-editor mat-form-field+mat-form-field{margin-left:1em}ajf-fb-choices-origin-editor mat-table{max-height:300px}ajf-fb-choices-origin-editor mat-table mat-icon{cursor:pointer}\n"] }]
|
|
232
232
|
}], propDecorators: { choicesOrigin: [{
|
|
@@ -269,7 +269,8 @@ function getNodeContainer(c, node) {
|
|
|
269
269
|
return null;
|
|
270
270
|
}
|
|
271
271
|
function buildFormBuilderNodesSubtree(nodes, parent, ignoreConditionalBranches = false) {
|
|
272
|
-
const entries = nodes
|
|
272
|
+
const entries = nodes
|
|
273
|
+
.filter(n => n.parent === parent.id)
|
|
273
274
|
.sort((n1, n2) => n1.parentNode - n2.parentNode)
|
|
274
275
|
.map(n => {
|
|
275
276
|
const children = buildFormBuilderNodesSubtree(nodes, n);
|
|
@@ -279,7 +280,7 @@ function buildFormBuilderNodesSubtree(nodes, parent, ignoreConditionalBranches =
|
|
|
279
280
|
return {
|
|
280
281
|
node: n,
|
|
281
282
|
children,
|
|
282
|
-
content: buildFormBuilderNodesContent(nodes, n)
|
|
283
|
+
content: buildFormBuilderNodesContent(nodes, n),
|
|
283
284
|
};
|
|
284
285
|
});
|
|
285
286
|
if (!ignoreConditionalBranches) {
|
|
@@ -308,9 +309,9 @@ function flattenNodes(nodes) {
|
|
|
308
309
|
return flatNodes;
|
|
309
310
|
}
|
|
310
311
|
function getDescendants(flatNodes, parentNode, branch = null) {
|
|
311
|
-
return branch != null
|
|
312
|
-
flatNodes.filter(n => n.parent === parentNode.id && n.parentNode === branch)
|
|
313
|
-
flatNodes.filter(n => n.parent === parentNode.id);
|
|
312
|
+
return branch != null
|
|
313
|
+
? flatNodes.filter(n => n.parent === parentNode.id && n.parentNode === branch)
|
|
314
|
+
: flatNodes.filter(n => n.parent === parentNode.id);
|
|
314
315
|
}
|
|
315
316
|
function removeNodes(nodes, ids) {
|
|
316
317
|
const len = nodes.length;
|
|
@@ -342,74 +343,74 @@ class AjfFormBuilderService {
|
|
|
342
343
|
label: 'Slide',
|
|
343
344
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-slide' },
|
|
344
345
|
nodeType: { node: AjfNodeType.AjfSlide },
|
|
345
|
-
isSlide: true
|
|
346
|
+
isSlide: true,
|
|
346
347
|
},
|
|
347
348
|
{
|
|
348
349
|
label: 'Repeating slide',
|
|
349
350
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-repeatingslide' },
|
|
350
351
|
nodeType: { node: AjfNodeType.AjfRepeatingSlide },
|
|
351
|
-
isSlide: true
|
|
352
|
+
isSlide: true,
|
|
352
353
|
},
|
|
353
354
|
{
|
|
354
355
|
label: 'String',
|
|
355
356
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-string' },
|
|
356
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.String }
|
|
357
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.String },
|
|
357
358
|
},
|
|
358
359
|
{
|
|
359
360
|
label: 'Text',
|
|
360
361
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-text' },
|
|
361
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Text }
|
|
362
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Text },
|
|
362
363
|
},
|
|
363
364
|
{
|
|
364
365
|
label: 'Number',
|
|
365
366
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-number' },
|
|
366
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Number }
|
|
367
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Number },
|
|
367
368
|
},
|
|
368
369
|
{
|
|
369
370
|
label: 'Boolean',
|
|
370
371
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-boolean' },
|
|
371
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Boolean }
|
|
372
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Boolean },
|
|
372
373
|
},
|
|
373
374
|
{
|
|
374
375
|
label: 'Single choice',
|
|
375
376
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-singlechoice' },
|
|
376
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.SingleChoice }
|
|
377
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.SingleChoice },
|
|
377
378
|
},
|
|
378
379
|
{
|
|
379
380
|
label: 'Multiple choice',
|
|
380
381
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-multiplechoice' },
|
|
381
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.MultipleChoice }
|
|
382
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.MultipleChoice },
|
|
382
383
|
},
|
|
383
384
|
{
|
|
384
385
|
label: 'Formula',
|
|
385
386
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-formula' },
|
|
386
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Formula }
|
|
387
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Formula },
|
|
387
388
|
},
|
|
388
389
|
{
|
|
389
390
|
label: 'Date',
|
|
390
391
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-date' },
|
|
391
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Date }
|
|
392
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Date },
|
|
392
393
|
},
|
|
393
394
|
{
|
|
394
395
|
label: 'Date input',
|
|
395
396
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-dateinput' },
|
|
396
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.DateInput }
|
|
397
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.DateInput },
|
|
397
398
|
},
|
|
398
399
|
{
|
|
399
400
|
label: 'Time',
|
|
400
401
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-time' },
|
|
401
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Time }
|
|
402
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Time },
|
|
402
403
|
},
|
|
403
404
|
{
|
|
404
405
|
label: 'Table',
|
|
405
406
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-table' },
|
|
406
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Table }
|
|
407
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Table },
|
|
407
408
|
},
|
|
408
409
|
{
|
|
409
410
|
label: 'Range',
|
|
410
411
|
icon: { fontSet: 'ajf-icon', fontIcon: 'field-range' },
|
|
411
|
-
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Range }
|
|
412
|
-
}
|
|
412
|
+
nodeType: { node: AjfNodeType.AjfField, field: AjfFieldType.Range },
|
|
413
|
+
},
|
|
413
414
|
];
|
|
414
415
|
this._form = new BehaviorSubject(null);
|
|
415
416
|
this._formObs = this._form;
|
|
@@ -418,11 +419,14 @@ class AjfFormBuilderService {
|
|
|
418
419
|
*/
|
|
419
420
|
this._connectedDropLists = new BehaviorSubject([]);
|
|
420
421
|
this._editedNodeEntry = new BehaviorSubject(null);
|
|
421
|
-
this._editedNodeEntryObs = this
|
|
422
|
+
this._editedNodeEntryObs = this
|
|
423
|
+
._editedNodeEntry;
|
|
422
424
|
this._editedCondition = new BehaviorSubject(null);
|
|
423
|
-
this._editedConditionObs = this
|
|
425
|
+
this._editedConditionObs = this
|
|
426
|
+
._editedCondition;
|
|
424
427
|
this._editedChoicesOrigin = new BehaviorSubject(null);
|
|
425
|
-
this._editedChoicesOriginObs = this
|
|
428
|
+
this._editedChoicesOriginObs = this
|
|
429
|
+
._editedChoicesOrigin;
|
|
426
430
|
this._beforeNodesUpdate = new EventEmitter();
|
|
427
431
|
this._beforeNodesUpdateObs = this._beforeNodesUpdate;
|
|
428
432
|
this._afterNodeUpdate = new EventEmitter();
|
|
@@ -572,9 +576,9 @@ class AjfFormBuilderService {
|
|
|
572
576
|
}
|
|
573
577
|
this._beforeNodesUpdate.emit();
|
|
574
578
|
this._nodesUpdates.next((nodes) => {
|
|
575
|
-
const cn = isContainerNode(parent) && inContent
|
|
576
|
-
parent
|
|
577
|
-
getNodeContainer({ nodes }, parent);
|
|
579
|
+
const cn = isContainerNode(parent) && inContent
|
|
580
|
+
? parent
|
|
581
|
+
: getNodeContainer({ nodes }, parent);
|
|
578
582
|
if (!isFieldNode) {
|
|
579
583
|
let newNodes = nodes.slice(0);
|
|
580
584
|
newNodes.splice(insertInIndex, 0, node);
|
|
@@ -609,10 +613,12 @@ class AjfFormBuilderService {
|
|
|
609
613
|
}
|
|
610
614
|
getCurrentForm() {
|
|
611
615
|
return combineLatest([
|
|
612
|
-
this.form,
|
|
613
|
-
this.
|
|
614
|
-
|
|
615
|
-
.
|
|
616
|
+
this.form,
|
|
617
|
+
this._nodesWithoutChoiceOrigins,
|
|
618
|
+
this.attachmentsOrigins,
|
|
619
|
+
this.choicesOrigins,
|
|
620
|
+
this.stringIdentifier,
|
|
621
|
+
]).pipe(filter(([form]) => form != null), map(([form, nodes, attachmentsOrigins, choicesOrigins, stringIdentifier]) => {
|
|
616
622
|
return createForm({
|
|
617
623
|
choicesOrigins: choicesOrigins.slice(0),
|
|
618
624
|
attachmentsOrigins: attachmentsOrigins.slice(0),
|
|
@@ -639,7 +645,7 @@ class AjfFormBuilderService {
|
|
|
639
645
|
if (isChoicesFixedOrigin(choicesOrigin)) {
|
|
640
646
|
choicesOrigin.choices = params.choices;
|
|
641
647
|
}
|
|
642
|
-
this._choicesOriginsUpdates.next(
|
|
648
|
+
this._choicesOriginsUpdates.next(choicesOrigins => {
|
|
643
649
|
const idx = choicesOrigins.indexOf(choicesOrigin);
|
|
644
650
|
if (idx > -1) {
|
|
645
651
|
choicesOrigins = [
|
|
@@ -672,7 +678,7 @@ class AjfFormBuilderService {
|
|
|
672
678
|
node: rootNode,
|
|
673
679
|
container: null,
|
|
674
680
|
children: buildFormBuilderNodesSubtree(nodes, rootNode),
|
|
675
|
-
content: buildFormBuilderNodesContent(nodes, rootNode)
|
|
681
|
+
content: buildFormBuilderNodesContent(nodes, rootNode),
|
|
676
682
|
});
|
|
677
683
|
return tree;
|
|
678
684
|
}
|
|
@@ -688,7 +694,7 @@ class AjfFormBuilderService {
|
|
|
688
694
|
}
|
|
689
695
|
_findMaxNodeId(nodes, _curMaxId = 0) {
|
|
690
696
|
let maxId = 0;
|
|
691
|
-
nodes.forEach(
|
|
697
|
+
nodes.forEach(n => {
|
|
692
698
|
maxId = Math.max(maxId, n.id);
|
|
693
699
|
if (isContainerNode(n)) {
|
|
694
700
|
maxId = Math.max(maxId, this._findMaxNodeId(n.nodes));
|
|
@@ -706,25 +712,24 @@ class AjfFormBuilderService {
|
|
|
706
712
|
return form != null && form.nodes != null ? form.nodes.slice(0) : [];
|
|
707
713
|
});
|
|
708
714
|
this._attachmentsOriginsUpdates.next((_attachmentsOrigins) => {
|
|
709
|
-
return form != null && form.attachmentsOrigins != null
|
|
710
|
-
form.attachmentsOrigins.slice(0)
|
|
711
|
-
[];
|
|
715
|
+
return form != null && form.attachmentsOrigins != null
|
|
716
|
+
? form.attachmentsOrigins.slice(0)
|
|
717
|
+
: [];
|
|
712
718
|
});
|
|
713
719
|
this._choicesOriginsUpdates.next((_choicesOrigins) => {
|
|
714
720
|
return form != null && form.choicesOrigins != null ? form.choicesOrigins.slice(0) : [];
|
|
715
721
|
});
|
|
716
722
|
this._stringIdentifierUpdates.next((_) => {
|
|
717
|
-
return form != null && form.stringIdentifier != null
|
|
718
|
-
|
|
723
|
+
return form != null && form.stringIdentifier != null
|
|
724
|
+
? form.stringIdentifier.slice(0)
|
|
725
|
+
: [];
|
|
719
726
|
});
|
|
720
727
|
});
|
|
721
728
|
}
|
|
722
729
|
_initChoicesOriginsStreams() {
|
|
723
|
-
this._choicesOrigins =
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
return op(choicesOrigins);
|
|
727
|
-
}, []), publishReplay(1), refCount());
|
|
730
|
+
this._choicesOrigins = (this._choicesOriginsUpdates).pipe(scan((choicesOrigins, op) => {
|
|
731
|
+
return op(choicesOrigins);
|
|
732
|
+
}, []), publishReplay(1), refCount());
|
|
728
733
|
}
|
|
729
734
|
_initAttachmentsOriginsStreams() {
|
|
730
735
|
this._attachmentsOrigins = this._attachmentsOriginsUpdates.pipe(scan((attachmentsOrigins, op) => {
|
|
@@ -737,27 +742,25 @@ class AjfFormBuilderService {
|
|
|
737
742
|
}, []), publishReplay(1), refCount());
|
|
738
743
|
}
|
|
739
744
|
_initNodesStreams() {
|
|
740
|
-
this._nodes = this._nodesUpdates
|
|
741
|
-
.pipe(scan((nodes, op) => {
|
|
745
|
+
this._nodes = this._nodesUpdates.pipe(scan((nodes, op) => {
|
|
742
746
|
return op(nodes);
|
|
743
747
|
}, []), publishReplay(1), refCount());
|
|
744
|
-
this._nodesWithoutChoiceOrigins =
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
delete fwc.choices;
|
|
751
|
-
}
|
|
752
|
-
if (fwc && fwc.choicesOrigin) {
|
|
753
|
-
delete fwc.choicesOrigin;
|
|
754
|
-
}
|
|
755
|
-
return fwc;
|
|
748
|
+
this._nodesWithoutChoiceOrigins = this._nodes.pipe(map(slides => slides.map(slide => {
|
|
749
|
+
slide.nodes = slide.nodes.map((node) => {
|
|
750
|
+
if (isFieldWithChoices(node)) {
|
|
751
|
+
const fwc = deepCopy(node);
|
|
752
|
+
if (fwc && fwc.choices) {
|
|
753
|
+
delete fwc.choices;
|
|
756
754
|
}
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
755
|
+
if (fwc && fwc.choicesOrigin) {
|
|
756
|
+
delete fwc.choicesOrigin;
|
|
757
|
+
}
|
|
758
|
+
return fwc;
|
|
759
|
+
}
|
|
760
|
+
return node;
|
|
761
|
+
});
|
|
762
|
+
return slide;
|
|
763
|
+
})));
|
|
761
764
|
this._flatNodes = this._nodes.pipe(map((nodes) => flattenNodes(nodes)), publishReplay(1), refCount());
|
|
762
765
|
this._flatFields = this._flatNodes.pipe(map((nodes) => nodes.filter(n => !isContainerNode(n))), publishReplay(1), refCount());
|
|
763
766
|
this._nodeEntriesTree = this._nodes.pipe(map(nodes => this._buildFormBuilderNodesTree(nodes)), publishReplay(1), refCount());
|
|
@@ -772,19 +775,22 @@ class AjfFormBuilderService {
|
|
|
772
775
|
node.id = nodeEntry.node.id;
|
|
773
776
|
node.name = properties.name;
|
|
774
777
|
node.label = properties.label;
|
|
775
|
-
node.visibility =
|
|
776
|
-
|
|
777
|
-
|
|
778
|
+
node.visibility =
|
|
779
|
+
properties.visibility != null
|
|
780
|
+
? createCondition({ condition: properties.visibility })
|
|
781
|
+
: null;
|
|
778
782
|
const oldConditionalBranches = node.conditionalBranches.length;
|
|
779
|
-
node.conditionalBranches =
|
|
780
|
-
properties.conditionalBranches
|
|
781
|
-
|
|
783
|
+
node.conditionalBranches =
|
|
784
|
+
properties.conditionalBranches != null
|
|
785
|
+
? properties.conditionalBranches.map((condition) => createCondition({ condition }))
|
|
786
|
+
: [alwaysCondition()];
|
|
782
787
|
const newConditionalBranches = node.conditionalBranches.length;
|
|
783
788
|
if (isRepeatingContainerNode(node)) {
|
|
784
789
|
const repNode = node;
|
|
785
|
-
repNode.formulaReps =
|
|
786
|
-
|
|
787
|
-
|
|
790
|
+
repNode.formulaReps =
|
|
791
|
+
properties.formulaReps != null
|
|
792
|
+
? createFormula({ formula: properties.formulaReps })
|
|
793
|
+
: undefined;
|
|
788
794
|
repNode.minReps = properties.minReps;
|
|
789
795
|
repNode.maxReps = properties.maxReps;
|
|
790
796
|
}
|
|
@@ -792,9 +798,8 @@ class AjfFormBuilderService {
|
|
|
792
798
|
const field = node;
|
|
793
799
|
field.description = properties.description;
|
|
794
800
|
field.defaultValue = properties.defaultValue;
|
|
795
|
-
field.formula =
|
|
796
|
-
createFormula({ formula: properties.formula }) :
|
|
797
|
-
undefined;
|
|
801
|
+
field.formula =
|
|
802
|
+
properties.formula != null ? createFormula({ formula: properties.formula }) : undefined;
|
|
798
803
|
const forceValue = properties.value;
|
|
799
804
|
const notEmpty = properties.notEmpty;
|
|
800
805
|
const validationConditions = properties.validationConditions;
|
|
@@ -814,25 +819,24 @@ class AjfFormBuilderService {
|
|
|
814
819
|
if (isNaN(maxDigits)) {
|
|
815
820
|
maxDigits = null;
|
|
816
821
|
}
|
|
817
|
-
if (forceValue != null ||
|
|
822
|
+
if (forceValue != null ||
|
|
823
|
+
notEmpty != null ||
|
|
818
824
|
(validationConditions != null && validationConditions.length > 0) ||
|
|
819
|
-
minValue != null ||
|
|
825
|
+
minValue != null ||
|
|
826
|
+
maxValue != null ||
|
|
827
|
+
minDigits != null ||
|
|
820
828
|
maxDigits != null) {
|
|
821
829
|
const validation = field.validation || createValidationGroup({});
|
|
822
830
|
validation.forceValue = forceValue;
|
|
823
831
|
validation.notEmpty = notEmpty ? notEmptyValidation() : undefined;
|
|
824
832
|
validation.minValue = minValue != null ? minValidation(minValue) : undefined;
|
|
825
833
|
validation.maxValue = maxValue != null ? maxValidation(maxValue) : undefined;
|
|
826
|
-
validation.minDigits =
|
|
827
|
-
|
|
828
|
-
validation.
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
[]).map((c) => createValidation({
|
|
833
|
-
condition: c.condition,
|
|
834
|
-
errorMessage: c.errorMessage
|
|
835
|
-
}));
|
|
834
|
+
validation.minDigits = minDigits != null ? minDigitsValidation(minDigits) : undefined;
|
|
835
|
+
validation.maxDigits = maxDigits != null ? maxDigitsValidation(maxDigits) : undefined;
|
|
836
|
+
validation.conditions = (validationConditions || []).map((c) => createValidation({
|
|
837
|
+
condition: c.condition,
|
|
838
|
+
errorMessage: c.errorMessage,
|
|
839
|
+
}));
|
|
836
840
|
field.validation = validation;
|
|
837
841
|
}
|
|
838
842
|
else {
|
|
@@ -844,20 +848,19 @@ class AjfFormBuilderService {
|
|
|
844
848
|
(warningConditions != null && warningConditions.length > 0)) {
|
|
845
849
|
const warning = field.warning || createWarningGroup({});
|
|
846
850
|
warning.notEmpty = notEmptyWarn ? notEmptyWarning() : undefined;
|
|
847
|
-
warning.conditions =
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
warningMessage: w.warningMessage
|
|
852
|
-
}));
|
|
851
|
+
warning.conditions = (warningConditions || []).map((w) => createWarning({
|
|
852
|
+
condition: w.condition,
|
|
853
|
+
warningMessage: w.warningMessage,
|
|
854
|
+
}));
|
|
853
855
|
field.warning = warning;
|
|
854
856
|
}
|
|
855
857
|
else {
|
|
856
858
|
field.warning = undefined;
|
|
857
859
|
}
|
|
858
|
-
field.nextSlideCondition =
|
|
859
|
-
|
|
860
|
-
|
|
860
|
+
field.nextSlideCondition =
|
|
861
|
+
properties.nextSlideCondition != null
|
|
862
|
+
? createCondition({ condition: properties.nextSlideCondition })
|
|
863
|
+
: undefined;
|
|
861
864
|
field.size = properties.size;
|
|
862
865
|
field.defaultValue = properties.defaultValue;
|
|
863
866
|
if (isFieldWithChoices(field)) {
|
|
@@ -865,8 +868,13 @@ class AjfFormBuilderService {
|
|
|
865
868
|
fwc.choicesOriginRef = properties.choicesOriginRef;
|
|
866
869
|
fwc.forceExpanded = properties.forceExpanded;
|
|
867
870
|
fwc.forceNarrow = properties.forceNarrow;
|
|
868
|
-
fwc.triggerConditions = (properties.triggerConditions ||
|
|
869
|
-
|
|
871
|
+
fwc.triggerConditions = (properties.triggerConditions || []).map((t) => createCondition({ condition: t }));
|
|
872
|
+
}
|
|
873
|
+
if (isRangeField(field)) {
|
|
874
|
+
const rf = field;
|
|
875
|
+
rf.start = properties.start;
|
|
876
|
+
rf.end = properties.end;
|
|
877
|
+
rf.step = properties.step;
|
|
870
878
|
}
|
|
871
879
|
}
|
|
872
880
|
this._editedNodeEntry.next(null);
|
|
@@ -932,32 +940,31 @@ class AjfFormBuilderService {
|
|
|
932
940
|
*/
|
|
933
941
|
_initMoveNode() {
|
|
934
942
|
this._moveNodeSub.unsubscribe();
|
|
935
|
-
this._moveNodeSub =
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
nodes = newNodes;
|
|
952
|
-
}
|
|
953
|
-
else {
|
|
954
|
-
nodes = nodes.slice(0);
|
|
955
|
-
}
|
|
943
|
+
this._moveNodeSub = this._moveNodeEntryEvent
|
|
944
|
+
.pipe(map((moveEvent) => {
|
|
945
|
+
this._beforeNodesUpdate.emit();
|
|
946
|
+
return (nodes) => {
|
|
947
|
+
const nodeEntry = moveEvent.nodeEntry;
|
|
948
|
+
const node = nodeEntry.node;
|
|
949
|
+
let cn = getNodeContainer({ nodes }, node);
|
|
950
|
+
let newNodes = nodes;
|
|
951
|
+
if (cn != null) {
|
|
952
|
+
const replaceNodes = cn.nodes === nodes;
|
|
953
|
+
newNodes = cn.nodes;
|
|
954
|
+
moveItemInArray(newNodes, moveEvent.fromIndex, moveEvent.toIndex);
|
|
955
|
+
newNodes = this._updateNodesList(cn.id, newNodes);
|
|
956
|
+
cn.nodes = newNodes;
|
|
957
|
+
if (replaceNodes) {
|
|
958
|
+
nodes = newNodes;
|
|
956
959
|
}
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
960
|
+
else {
|
|
961
|
+
nodes = nodes.slice(0);
|
|
962
|
+
}
|
|
963
|
+
}
|
|
964
|
+
return nodes;
|
|
965
|
+
};
|
|
966
|
+
}))
|
|
967
|
+
.subscribe(this._nodesUpdates);
|
|
961
968
|
}
|
|
962
969
|
/**
|
|
963
970
|
* Updates the "id" and "parent" fields of a modified or rearranged list of nodes.
|
|
@@ -971,8 +978,8 @@ class AjfFormBuilderService {
|
|
|
971
978
|
const contId = containerId != undefined ? containerId : 0;
|
|
972
979
|
for (let idx = 0; idx < nodesList.length; idx++) {
|
|
973
980
|
let currentNode = nodesList[idx];
|
|
974
|
-
currentNode.id =
|
|
975
|
-
currentNode.parent = idx == 0 ? contId :
|
|
981
|
+
currentNode.id = contId * 1000 + idx + 1;
|
|
982
|
+
currentNode.parent = idx == 0 ? contId : contId * 1000 + idx;
|
|
976
983
|
if (currentNode.nodeType == AjfNodeType.AjfSlide ||
|
|
977
984
|
currentNode.nodeType == AjfNodeType.AjfRepeatingSlide) {
|
|
978
985
|
const currentSlide = currentNode;
|
|
@@ -984,31 +991,34 @@ class AjfFormBuilderService {
|
|
|
984
991
|
return nodesList;
|
|
985
992
|
}
|
|
986
993
|
}
|
|
987
|
-
AjfFormBuilderService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
988
|
-
AjfFormBuilderService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.0.0-
|
|
989
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
994
|
+
AjfFormBuilderService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFormBuilderService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
995
|
+
AjfFormBuilderService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFormBuilderService });
|
|
996
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFormBuilderService, decorators: [{
|
|
990
997
|
type: Injectable
|
|
991
998
|
}], ctorParameters: function () { return []; } });
|
|
992
999
|
|
|
993
1000
|
class AjfFbChoicesOriginEditorDialog {
|
|
994
1001
|
constructor(_service) {
|
|
995
1002
|
this._service = _service;
|
|
996
|
-
this._choicesOrigin =
|
|
997
|
-
this._service.editedChoicesOrigin.pipe(filter(c => c != null), map(c => c));
|
|
1003
|
+
this._choicesOrigin = this._service.editedChoicesOrigin.pipe(filter(c => c != null), map(c => c));
|
|
998
1004
|
}
|
|
999
1005
|
get choicesOrigin() {
|
|
1000
1006
|
return this._choicesOrigin;
|
|
1001
1007
|
}
|
|
1002
1008
|
saveChoicesOrigin() {
|
|
1003
|
-
this._service.saveChoicesOrigin({
|
|
1009
|
+
this._service.saveChoicesOrigin({
|
|
1010
|
+
label: this.editor.label,
|
|
1011
|
+
name: this.editor.name,
|
|
1012
|
+
choices: this.editor.choicesArr,
|
|
1013
|
+
});
|
|
1004
1014
|
}
|
|
1005
1015
|
cancelChoicesOriginEdit() {
|
|
1006
1016
|
this._service.cancelChoicesOriginEdit();
|
|
1007
1017
|
}
|
|
1008
1018
|
}
|
|
1009
|
-
AjfFbChoicesOriginEditorDialog.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
1010
|
-
AjfFbChoicesOriginEditorDialog.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-
|
|
1011
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
1019
|
+
AjfFbChoicesOriginEditorDialog.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbChoicesOriginEditorDialog, deps: [{ token: AjfFormBuilderService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1020
|
+
AjfFbChoicesOriginEditorDialog.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFbChoicesOriginEditorDialog, selector: "ajf-fb-choices-origin-editor-dialog", viewQueries: [{ propertyName: "editor", first: true, predicate: AjfFbChoicesOriginEditor, descendants: true }], ngImport: i0, template: "<h3 matDialogTitle>{{'Edit choices origin'|transloco}}</h3>\n<mat-dialog-content>\n <ajf-fb-choices-origin-editor\n *ngIf=\"choicesOrigin|async as co\"\n [choicesOrigin]=\"co!\"\n ></ajf-fb-choices-origin-editor>\n</mat-dialog-content>\n<mat-dialog-actions>\n <button mat-button (click)=\"saveChoicesOrigin()\">{{'Save'|transloco}}</button>\n <button mat-button (click)=\"cancelChoicesOriginEdit()\">\n {{'Close'|transloco}}\n </button>\n</mat-dialog-actions>\n", styles: ["\n"], components: [{ type: AjfFbChoicesOriginEditor, selector: "ajf-fb-choices-origin-editor", inputs: ["choicesOrigin"] }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i2$1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { type: i2$1.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]" }], pipes: { "transloco": i6$1.TranslocoPipe, "async": i8.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1021
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbChoicesOriginEditorDialog, decorators: [{
|
|
1012
1022
|
type: Component,
|
|
1013
1023
|
args: [{ selector: 'ajf-fb-choices-origin-editor-dialog', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<h3 matDialogTitle>{{'Edit choices origin'|transloco}}</h3>\n<mat-dialog-content>\n <ajf-fb-choices-origin-editor\n *ngIf=\"choicesOrigin|async as co\"\n [choicesOrigin]=\"co!\"\n ></ajf-fb-choices-origin-editor>\n</mat-dialog-content>\n<mat-dialog-actions>\n <button mat-button (click)=\"saveChoicesOrigin()\">{{'Save'|transloco}}</button>\n <button mat-button (click)=\"cancelChoicesOriginEdit()\">\n {{'Close'|transloco}}\n </button>\n</mat-dialog-actions>\n", styles: ["\n"] }]
|
|
1014
1024
|
}], ctorParameters: function () { return [{ type: AjfFormBuilderService }]; }, propDecorators: { editor: [{
|
|
@@ -1064,12 +1074,15 @@ class AjfFbConditionEditor {
|
|
|
1064
1074
|
}
|
|
1065
1075
|
}
|
|
1066
1076
|
onEditorInit() {
|
|
1067
|
-
monaco.languages.typescript.javascriptDefaults.setDiagnosticsOptions({
|
|
1077
|
+
monaco.languages.typescript.javascriptDefaults.setDiagnosticsOptions({
|
|
1078
|
+
noSemanticValidation: false,
|
|
1079
|
+
noSyntaxValidation: false,
|
|
1080
|
+
});
|
|
1068
1081
|
monaco.languages.typescript.javascriptDefaults.setCompilerOptions({
|
|
1069
1082
|
target: monaco.languages.typescript.ScriptTarget.ES2015,
|
|
1070
1083
|
allowNonTsExtensions: true,
|
|
1071
1084
|
allowJs: true,
|
|
1072
|
-
module: monaco.languages.typescript.ModuleKind.None
|
|
1085
|
+
module: monaco.languages.typescript.ModuleKind.None,
|
|
1073
1086
|
});
|
|
1074
1087
|
try {
|
|
1075
1088
|
monaco.languages.typescript.javascriptDefaults.addExtraLib('', 'condition-editor-variables.d.ts');
|
|
@@ -1100,16 +1113,14 @@ class AjfFbConditionEditor {
|
|
|
1100
1113
|
})
|
|
1101
1114
|
.join('\n');
|
|
1102
1115
|
}
|
|
1103
|
-
catch (e) {
|
|
1104
|
-
}
|
|
1116
|
+
catch (e) { }
|
|
1105
1117
|
}
|
|
1106
1118
|
_updateFunctions() {
|
|
1107
1119
|
try {
|
|
1108
1120
|
monaco.languages.typescript.javascriptDefaults._extraLibs['condition-editor-functions.d.ts'] =
|
|
1109
1121
|
AjfExpressionUtils.UTIL_FUNCTIONS;
|
|
1110
1122
|
}
|
|
1111
|
-
catch (e) {
|
|
1112
|
-
}
|
|
1123
|
+
catch (e) { }
|
|
1113
1124
|
}
|
|
1114
1125
|
_fieldVarType(fieldType) {
|
|
1115
1126
|
switch (fieldType) {
|
|
@@ -1137,9 +1148,9 @@ class AjfFbConditionEditor {
|
|
|
1137
1148
|
return null;
|
|
1138
1149
|
}
|
|
1139
1150
|
}
|
|
1140
|
-
AjfFbConditionEditor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
1141
|
-
AjfFbConditionEditor.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-
|
|
1142
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
1151
|
+
AjfFbConditionEditor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbConditionEditor, deps: [{ token: i1.AjfValidationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1152
|
+
AjfFbConditionEditor.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFbConditionEditor, selector: "ajf-condition-editor", inputs: { fields: "fields", condition: "condition" }, viewQueries: [{ propertyName: "monacoEditor", first: true, predicate: AjfMonacoEditor, descendants: true, static: true }], ngImport: i0, template: "<div class=\"ajf-editor\">\n <ajf-monaco-editor\n (init)=\"onEditorInit()\"\n (valueChange)=\"editedValue = $event\"\n [value]=\"condition\" language=\"javascript\"></ajf-monaco-editor>\n</div>\n<div class=\"ajf-editor-panel\">\n <ng-container *ngIf=\"fields as curFields\">\n <mat-nav-list dense *ngIf=\"curFields!.length > 0\">\n <a mat-list-item\n (click)=\"insertVariable(field.name)\"\n [matTooltip]=\"field.label\"\n *ngFor=\"let field of curFields!\">\n <ajf-node-icon [node]=\"field\"></ajf-node-icon>\n {{ field.name }}\n </a>\n </mat-nav-list>\n </ng-container>\n</div>\n", styles: ["ajf-condition-editor{display:flex;flex-direction:row;align-items:stretch;max-height:512px}ajf-condition-editor .ajf-editor{flex:.75 0 auto;display:flex;flex-direction:row;align-items:stretch}ajf-condition-editor .ajf-editor monaco-editor{flex:1 0 auto;min-width:512px;min-height:256px}ajf-condition-editor .ajf-editor-panel{flex:.25 0 auto;overflow-y:auto}ajf-condition-editor ajf-monaco-editor{min-width:400px}\n"], components: [{ type: i2$2.AjfMonacoEditor, selector: "ajf-monaco-editor", inputs: ["experimentalScreenReader", "ariaLabel", "rulers", "wordSeparators", "selectionClipboard", "lineNumbers", "selectOnLineNumbers", "lineNumbersMinChars", "glyphMargin", "lineDecorationsWidth", "revealHorizontalRightPadding", "roundedSelection", "theme", "readOnly", "scrollbar", "overviewRulerLanes", "cursorBlinking", "mouseWheelZoom", "cursorStyle", "fontLigatures", "disableTranslate3d", "hideCursorInOverviewRuler", "scrollBeyondLastLine", "automaticLayout", "wrappingColumn", "wordWrap", "wrappingIndent", "wordWrapBreakBeforeCharacters", "wordWrapBreakAfterCharacters", "wordWrapBreakObtrusiveCharacters", "stopRenderingLineAfter", "hover", "contextmenu", "mouseWheelScrollSensitivity", "quickSuggestions", "quickSuggestionsDelay", "parameterHints", "iconsInSuggestions", "autoClosingBrackets", "formatOnType", "suggestOnTriggerCharacters", "acceptSuggestionOnEnter", "snippetSuggestions", "tabCompletion", "wordBasedSuggestions", "selectionHighlight", "codeLens", "folding", "renderWhitespace", "renderControlCharacters", "renderIndentGuides", "renderLineHighlight", "useTabStops", "fontFamily", "fontWeight", "fontSize", "lineHeight", "language", "disableAutocomplete", "autoFormatOnLoad", "monacoLibPath", "valueToCompare", "value"], outputs: ["valueChange", "valueToCompareChange", "init"] }, { type: i3$2.MatNavList, selector: "mat-nav-list", inputs: ["disableRipple", "disabled"], exportAs: ["matNavList"] }, { type: i3$2.MatListItem, selector: "mat-list-item, a[mat-list-item], button[mat-list-item]", inputs: ["disableRipple", "disabled"], exportAs: ["matListItem"] }, { type: i4$1.AjfNodeIcon, selector: "ajf-node-icon" }], directives: [{ type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i6$2.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1153
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbConditionEditor, decorators: [{
|
|
1143
1154
|
type: Component,
|
|
1144
1155
|
args: [{ selector: 'ajf-condition-editor', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<div class=\"ajf-editor\">\n <ajf-monaco-editor\n (init)=\"onEditorInit()\"\n (valueChange)=\"editedValue = $event\"\n [value]=\"condition\" language=\"javascript\"></ajf-monaco-editor>\n</div>\n<div class=\"ajf-editor-panel\">\n <ng-container *ngIf=\"fields as curFields\">\n <mat-nav-list dense *ngIf=\"curFields!.length > 0\">\n <a mat-list-item\n (click)=\"insertVariable(field.name)\"\n [matTooltip]=\"field.label\"\n *ngFor=\"let field of curFields!\">\n <ajf-node-icon [node]=\"field\"></ajf-node-icon>\n {{ field.name }}\n </a>\n </mat-nav-list>\n </ng-container>\n</div>\n", styles: ["ajf-condition-editor{display:flex;flex-direction:row;align-items:stretch;max-height:512px}ajf-condition-editor .ajf-editor{flex:.75 0 auto;display:flex;flex-direction:row;align-items:stretch}ajf-condition-editor .ajf-editor monaco-editor{flex:1 0 auto;min-width:512px;min-height:256px}ajf-condition-editor .ajf-editor-panel{flex:.25 0 auto;overflow-y:auto}ajf-condition-editor ajf-monaco-editor{min-width:400px}\n"] }]
|
|
1145
1156
|
}], ctorParameters: function () { return [{ type: i1.AjfValidationService }]; }, propDecorators: { monacoEditor: [{
|
|
@@ -1167,9 +1178,9 @@ class AjfFbConditionEditorDialog {
|
|
|
1167
1178
|
this.dialogRef.close(newValue);
|
|
1168
1179
|
}
|
|
1169
1180
|
}
|
|
1170
|
-
AjfFbConditionEditorDialog.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
1171
|
-
AjfFbConditionEditorDialog.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-
|
|
1172
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
1181
|
+
AjfFbConditionEditorDialog.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbConditionEditorDialog, deps: [{ token: AjfFormBuilderService }, { token: i2$1.MatDialogRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
1182
|
+
AjfFbConditionEditorDialog.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFbConditionEditorDialog, selector: "ajf-condition-editor-dialog", viewQueries: [{ propertyName: "editor", first: true, predicate: AjfFbConditionEditor, descendants: true }], ngImport: i0, template: "<h3 matDialogTitle>{{'Edit condition'|transloco}}</h3>\n<mat-dialog-content>\n <ajf-condition-editor\n *ngIf=\"fields|async as curFields\"\n [fields]=\"curFields!\"\n [condition]=\"condition\"\n ></ajf-condition-editor>\n</mat-dialog-content>\n<mat-dialog-actions>\n <button mat-button (click)=\"saveCondition()\">{{'Save'|transloco}}</button>\n <button mat-button matDialogClose>{{'Close'|transloco}}</button>\n</mat-dialog-actions>\n", styles: ["ajf-condition-editor-dialog mat-dialog-content{overflow:visible}\n"], components: [{ type: AjfFbConditionEditor, selector: "ajf-condition-editor", inputs: ["fields", "condition"] }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i2$1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { type: i2$1.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]" }, { type: i2$1.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }], pipes: { "transloco": i6$1.TranslocoPipe, "async": i8.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1183
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbConditionEditorDialog, decorators: [{
|
|
1173
1184
|
type: Component,
|
|
1174
1185
|
args: [{ selector: 'ajf-condition-editor-dialog', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<h3 matDialogTitle>{{'Edit condition'|transloco}}</h3>\n<mat-dialog-content>\n <ajf-condition-editor\n *ngIf=\"fields|async as curFields\"\n [fields]=\"curFields!\"\n [condition]=\"condition\"\n ></ajf-condition-editor>\n</mat-dialog-content>\n<mat-dialog-actions>\n <button mat-button (click)=\"saveCondition()\">{{'Save'|transloco}}</button>\n <button mat-button matDialogClose>{{'Close'|transloco}}</button>\n</mat-dialog-actions>\n", styles: ["ajf-condition-editor-dialog mat-dialog-content{overflow:visible}\n"] }]
|
|
1175
1186
|
}], ctorParameters: function () { return [{ type: AjfFormBuilderService }, { type: i2$1.MatDialogRef }]; }, propDecorators: { editor: [{
|
|
@@ -1213,8 +1224,9 @@ function onDropProcess(event, fbService, nodeEntry, content = false) {
|
|
|
1213
1224
|
fbService.insertNode(itemData, null, 0, content, event.currentIndex);
|
|
1214
1225
|
return;
|
|
1215
1226
|
}
|
|
1216
|
-
const emptySlot = content
|
|
1217
|
-
nodeEntry
|
|
1227
|
+
const emptySlot = content
|
|
1228
|
+
? { parent: nodeEntry.node, parentNode: 0 }
|
|
1229
|
+
: nodeEntry;
|
|
1218
1230
|
fbService.insertNode(itemData, emptySlot.parent, emptySlot.parentNode, content, event.currentIndex);
|
|
1219
1231
|
return;
|
|
1220
1232
|
}
|
|
@@ -1251,7 +1263,8 @@ class AjfFbStringIdentifierDialogComponent {
|
|
|
1251
1263
|
this._stringIdentifierSub = _service.stringIdentifier.subscribe(identifier => {
|
|
1252
1264
|
this.dataSource.data = [...identifier];
|
|
1253
1265
|
});
|
|
1254
|
-
this.fields$ = _service.flatFields.pipe(map(fields => fields
|
|
1266
|
+
this.fields$ = _service.flatFields.pipe(map(fields => fields
|
|
1267
|
+
.sort((f1, f2) => f1.name.localeCompare(f2.name))
|
|
1255
1268
|
.map(f => f.name)
|
|
1256
1269
|
.filter(f => f.length > 0)), shareReplay(1));
|
|
1257
1270
|
}
|
|
@@ -1275,10 +1288,7 @@ class AjfFbStringIdentifierDialogComponent {
|
|
|
1275
1288
|
removeValue(row, value) {
|
|
1276
1289
|
const idx = row.value.indexOf(value);
|
|
1277
1290
|
if (idx > -1) {
|
|
1278
|
-
row.value = [
|
|
1279
|
-
...row.value.slice(0, idx),
|
|
1280
|
-
...row.value.slice(idx + 1),
|
|
1281
|
-
];
|
|
1291
|
+
row.value = [...row.value.slice(0, idx), ...row.value.slice(idx + 1)];
|
|
1282
1292
|
this._cdr.markForCheck();
|
|
1283
1293
|
}
|
|
1284
1294
|
}
|
|
@@ -1293,9 +1303,9 @@ class AjfFbStringIdentifierDialogComponent {
|
|
|
1293
1303
|
this._cdr.markForCheck();
|
|
1294
1304
|
}
|
|
1295
1305
|
}
|
|
1296
|
-
AjfFbStringIdentifierDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
1297
|
-
AjfFbStringIdentifierDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-
|
|
1298
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
1306
|
+
AjfFbStringIdentifierDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbStringIdentifierDialogComponent, deps: [{ token: AjfFormBuilderService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
1307
|
+
AjfFbStringIdentifierDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFbStringIdentifierDialogComponent, selector: "ajf-fb-string-identifier-dialog", ngImport: i0, template: "<h3 matDialogTitle>{{'Edit identifier'|transloco}}</h3>\n<mat-dialog-content>\n <button (click)=\"addRow()\" mat-button>\n <mat-icon>add</mat-icon>\n <span>{{'Add value'|transloco}}</span>\n </button>\n <mat-table [dataSource]=\"dataSource\">\n <ng-container matColumnDef=\"label\">\n <mat-header-cell *matHeaderCellDef>{{'Label'|transloco}}</mat-header-cell>\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <mat-form-field>\n <input\n matInput\n [placeholder]=\"'Label'|transloco\"\n autofocus\n [(ngModel)]=\"row.label\"\n />\n </mat-form-field>\n </mat-cell>\n </ng-container>\n <ng-container matColumnDef=\"value\">\n <mat-header-cell *matHeaderCellDef>{{'Value'|transloco}}</mat-header-cell>\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <mat-form-field>\n <mat-chip-list #chipList>\n <mat-chip\n *ngFor=\"let field of row.value\"\n (removed)=\"removeValue(row, field)\"\n >\n {{ field }}\n <mat-icon matChipRemove>cancel</mat-icon>\n </mat-chip>\n </mat-chip-list>\n <input\n #valueInput\n [ngModel]=\"row.value\"\n [matAutocomplete]=\"valueAc\"\n [matChipInputFor]=\"chipList\"\n [matChipInputSeparatorKeyCodes]=\"separatorKeysCodes\"\n [matChipInputAddOnBlur]=\"true\"\n (matChipInputTokenEnd)=\"addValue(row, $event, valueInput)\"\n [placeholder]=\"'Value'|transloco\"\n />\n <mat-autocomplete\n #valueAc=\"matAutocomplete\"\n (optionSelected)=\"selected(row, $event)\"\n >\n <mat-option *ngFor=\"let field of fields$ | async\" [value]=\"field\"\n >{{field}}</mat-option\n >\n </mat-autocomplete>\n </mat-form-field>\n </mat-cell>\n </ng-container>\n <ng-container matColumnDef=\"show\">\n <mat-header-cell *matHeaderCellDef>{{'Show'|transloco}}</mat-header-cell>\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <mat-form-field>\n <mat-select matNativeControl [(ngModel)]=\"row.show\">\n <mat-option value=\"all\">{{'All'|transloco}}</mat-option>\n <mat-option value=\"first\">{{'First'|transloco}}</mat-option>\n <mat-option value=\"last\">{{'Last'|transloco}}</mat-option>\n </mat-select>\n </mat-form-field>\n </mat-cell>\n </ng-container>\n <ng-container matColumnDef=\"delete\">\n <mat-header-cell *matHeaderCellDef\n >{{'Delete'|transloco}}</mat-header-cell\n >\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <mat-icon (click)=\"deleteRow(idx)\">delete</mat-icon>\n </mat-cell>\n </ng-container>\n\n <mat-header-row *matHeaderRowDef=\"displayedColumns\"></mat-header-row>\n <mat-row *matRowDef=\"let row; columns: displayedColumns;\"></mat-row>\n </mat-table>\n</mat-dialog-content>\n<mat-dialog-actions>\n <button mat-button matDialogClose (click)=\"saveStringIdentifier()\">\n {{'Save'|transloco}}\n </button>\n</mat-dialog-actions>\n", styles: ["\n"], components: [{ type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { type: i5.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i6$3.MatChipList, selector: "mat-chip-list", inputs: ["errorStateMatcher", "multiple", "compareWith", "value", "required", "placeholder", "disabled", "aria-orientation", "selectable", "tabIndex"], outputs: ["change", "valueChange"], exportAs: ["matChipList"] }, { type: i7.MatAutocomplete, selector: "mat-autocomplete", inputs: ["disableRipple"], exportAs: ["matAutocomplete"] }, { type: i8$1.MatOption, selector: "mat-option", exportAs: ["matOption"] }, { type: i9.MatSelect, selector: "mat-select", inputs: ["disabled", "disableRipple", "tabIndex"], exportAs: ["matSelect"] }, { type: i4.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { type: i4.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }], directives: [{ type: i2$1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { type: i2$1.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { type: i4.MatColumnDef, selector: "[matColumnDef]", inputs: ["sticky", "matColumnDef"] }, { type: i4.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { type: i4.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { type: i4.MatCellDef, selector: "[matCellDef]" }, { type: i4.MatCell, selector: "mat-cell, td[mat-cell]" }, { type: i6.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i3$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i3$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i3$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i8.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i6$3.MatChip, selector: "mat-basic-chip, [mat-basic-chip], mat-chip, [mat-chip]", inputs: ["color", "disableRipple", "tabIndex", "selected", "value", "selectable", "disabled", "removable"], outputs: ["selectionChange", "destroyed", "removed"], exportAs: ["matChip"] }, { type: i6$3.MatChipRemove, selector: "[matChipRemove]" }, { type: i7.MatAutocompleteTrigger, selector: "input[matAutocomplete], textarea[matAutocomplete]", exportAs: ["matAutocompleteTrigger"] }, { type: i6$3.MatChipInput, selector: "input[matChipInputFor]", inputs: ["matChipInputFor", "matChipInputAddOnBlur", "matChipInputSeparatorKeyCodes", "placeholder", "id", "disabled"], outputs: ["matChipInputTokenEnd"], exportAs: ["matChipInput", "matChipInputFor"] }, { type: i4.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { type: i4.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { type: i2$1.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]" }, { type: i2$1.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }], pipes: { "transloco": i6$1.TranslocoPipe, "async": i8.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1308
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbStringIdentifierDialogComponent, decorators: [{
|
|
1299
1309
|
type: Component,
|
|
1300
1310
|
args: [{ selector: 'ajf-fb-string-identifier-dialog', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<h3 matDialogTitle>{{'Edit identifier'|transloco}}</h3>\n<mat-dialog-content>\n <button (click)=\"addRow()\" mat-button>\n <mat-icon>add</mat-icon>\n <span>{{'Add value'|transloco}}</span>\n </button>\n <mat-table [dataSource]=\"dataSource\">\n <ng-container matColumnDef=\"label\">\n <mat-header-cell *matHeaderCellDef>{{'Label'|transloco}}</mat-header-cell>\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <mat-form-field>\n <input\n matInput\n [placeholder]=\"'Label'|transloco\"\n autofocus\n [(ngModel)]=\"row.label\"\n />\n </mat-form-field>\n </mat-cell>\n </ng-container>\n <ng-container matColumnDef=\"value\">\n <mat-header-cell *matHeaderCellDef>{{'Value'|transloco}}</mat-header-cell>\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <mat-form-field>\n <mat-chip-list #chipList>\n <mat-chip\n *ngFor=\"let field of row.value\"\n (removed)=\"removeValue(row, field)\"\n >\n {{ field }}\n <mat-icon matChipRemove>cancel</mat-icon>\n </mat-chip>\n </mat-chip-list>\n <input\n #valueInput\n [ngModel]=\"row.value\"\n [matAutocomplete]=\"valueAc\"\n [matChipInputFor]=\"chipList\"\n [matChipInputSeparatorKeyCodes]=\"separatorKeysCodes\"\n [matChipInputAddOnBlur]=\"true\"\n (matChipInputTokenEnd)=\"addValue(row, $event, valueInput)\"\n [placeholder]=\"'Value'|transloco\"\n />\n <mat-autocomplete\n #valueAc=\"matAutocomplete\"\n (optionSelected)=\"selected(row, $event)\"\n >\n <mat-option *ngFor=\"let field of fields$ | async\" [value]=\"field\"\n >{{field}}</mat-option\n >\n </mat-autocomplete>\n </mat-form-field>\n </mat-cell>\n </ng-container>\n <ng-container matColumnDef=\"show\">\n <mat-header-cell *matHeaderCellDef>{{'Show'|transloco}}</mat-header-cell>\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <mat-form-field>\n <mat-select matNativeControl [(ngModel)]=\"row.show\">\n <mat-option value=\"all\">{{'All'|transloco}}</mat-option>\n <mat-option value=\"first\">{{'First'|transloco}}</mat-option>\n <mat-option value=\"last\">{{'Last'|transloco}}</mat-option>\n </mat-select>\n </mat-form-field>\n </mat-cell>\n </ng-container>\n <ng-container matColumnDef=\"delete\">\n <mat-header-cell *matHeaderCellDef\n >{{'Delete'|transloco}}</mat-header-cell\n >\n <mat-cell *matCellDef=\"let row; let idx = index\">\n <mat-icon (click)=\"deleteRow(idx)\">delete</mat-icon>\n </mat-cell>\n </ng-container>\n\n <mat-header-row *matHeaderRowDef=\"displayedColumns\"></mat-header-row>\n <mat-row *matRowDef=\"let row; columns: displayedColumns;\"></mat-row>\n </mat-table>\n</mat-dialog-content>\n<mat-dialog-actions>\n <button mat-button matDialogClose (click)=\"saveStringIdentifier()\">\n {{'Save'|transloco}}\n </button>\n</mat-dialog-actions>\n", styles: ["\n"] }]
|
|
1301
1311
|
}], ctorParameters: function () { return [{ type: AjfFormBuilderService }, { type: i0.ChangeDetectorRef }]; } });
|
|
@@ -1333,9 +1343,9 @@ class AjfFbNodeTypeEntry {
|
|
|
1333
1343
|
this._cdr.markForCheck();
|
|
1334
1344
|
}
|
|
1335
1345
|
}
|
|
1336
|
-
AjfFbNodeTypeEntry.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
1337
|
-
AjfFbNodeTypeEntry.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-
|
|
1338
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
1346
|
+
AjfFbNodeTypeEntry.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbNodeTypeEntry, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
1347
|
+
AjfFbNodeTypeEntry.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFbNodeTypeEntry, selector: "ajf-fb-node-type-entry", inputs: { nodeType: "nodeType" }, ngImport: i0, template: "<ng-container *ngIf=\"nodeType\">\n <mat-icon\n [fontSet]=\"nodeType.icon.fontSet\" [fontIcon]=\"nodeType.icon.fontIcon\"></mat-icon>\n {{ nodeType.label }}\n</ng-container>\n", styles: ["ajf-fb-node-type-entry{display:block;padding:1em 1.5em}ajf-fb-node-type-entry mat-icon{vertical-align:middle}\n"], components: [{ type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1348
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbNodeTypeEntry, decorators: [{
|
|
1339
1349
|
type: Component,
|
|
1340
1350
|
args: [{ selector: 'ajf-fb-node-type-entry', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container *ngIf=\"nodeType\">\n <mat-icon\n [fontSet]=\"nodeType.icon.fontSet\" [fontIcon]=\"nodeType.icon.fontIcon\"></mat-icon>\n {{ nodeType.label }}\n</ng-container>\n", styles: ["ajf-fb-node-type-entry{display:block;padding:1em 1.5em}ajf-fb-node-type-entry mat-icon{vertical-align:middle}\n"] }]
|
|
1341
1351
|
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { nodeType: [{
|
|
@@ -1358,9 +1368,9 @@ class AjfFbValidationConditionEditorDialog {
|
|
|
1358
1368
|
this.dialogRef.close({ condition: newValue, errorMessage: this.errorMessage });
|
|
1359
1369
|
}
|
|
1360
1370
|
}
|
|
1361
|
-
AjfFbValidationConditionEditorDialog.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
1362
|
-
AjfFbValidationConditionEditorDialog.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-
|
|
1363
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
1371
|
+
AjfFbValidationConditionEditorDialog.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbValidationConditionEditorDialog, deps: [{ token: AjfFormBuilderService }, { token: i2$1.MatDialogRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
1372
|
+
AjfFbValidationConditionEditorDialog.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFbValidationConditionEditorDialog, selector: "ajf-fb-validation-condition-editor-dialog", viewQueries: [{ propertyName: "editor", first: true, predicate: AjfFbConditionEditor, descendants: true }], ngImport: i0, template: "<h3 matDialogTitle>{{'Edit condition'|transloco}}</h3>\n<mat-dialog-content>\n <mat-form-field>\n <input\n matInput\n [(ngModel)]=\"errorMessage\"\n [placeholder]=\"'Error message'|transloco\"\n />\n </mat-form-field>\n <ajf-condition-editor\n *ngIf=\"fields|async as curFields\"\n [fields]=\"curFields!\"\n [condition]=\"condition\"\n ></ajf-condition-editor>\n</mat-dialog-content>\n<mat-dialog-actions>\n <button mat-button (click)=\"saveCondition()\">{{'Save'|transloco}}</button>\n <button mat-button matDialogClose>{{'Close'|transloco}}</button>\n</mat-dialog-actions>\n", styles: ["ajf-fb-validation-condition-editor-dialog mat-dialog-content{overflow:visible}\n"], components: [{ type: i5.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: AjfFbConditionEditor, selector: "ajf-condition-editor", inputs: ["fields", "condition"] }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i2$1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { type: i2$1.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { type: i6.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i3$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i3$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i3$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]" }, { type: i2$1.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }], pipes: { "transloco": i6$1.TranslocoPipe, "async": i8.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1373
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbValidationConditionEditorDialog, decorators: [{
|
|
1364
1374
|
type: Component,
|
|
1365
1375
|
args: [{ selector: 'ajf-fb-validation-condition-editor-dialog', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<h3 matDialogTitle>{{'Edit condition'|transloco}}</h3>\n<mat-dialog-content>\n <mat-form-field>\n <input\n matInput\n [(ngModel)]=\"errorMessage\"\n [placeholder]=\"'Error message'|transloco\"\n />\n </mat-form-field>\n <ajf-condition-editor\n *ngIf=\"fields|async as curFields\"\n [fields]=\"curFields!\"\n [condition]=\"condition\"\n ></ajf-condition-editor>\n</mat-dialog-content>\n<mat-dialog-actions>\n <button mat-button (click)=\"saveCondition()\">{{'Save'|transloco}}</button>\n <button mat-button matDialogClose>{{'Close'|transloco}}</button>\n</mat-dialog-actions>\n", styles: ["ajf-fb-validation-condition-editor-dialog mat-dialog-content{overflow:visible}\n"] }]
|
|
1366
1376
|
}], ctorParameters: function () { return [{ type: AjfFormBuilderService }, { type: i2$1.MatDialogRef }]; }, propDecorators: { editor: [{
|
|
@@ -1384,9 +1394,9 @@ class AjfFbWarningConditionEditorDialog {
|
|
|
1384
1394
|
this.dialogRef.close({ condition: newValue, warningMessage: this.warningMessage });
|
|
1385
1395
|
}
|
|
1386
1396
|
}
|
|
1387
|
-
AjfFbWarningConditionEditorDialog.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
1388
|
-
AjfFbWarningConditionEditorDialog.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-
|
|
1389
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
1397
|
+
AjfFbWarningConditionEditorDialog.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbWarningConditionEditorDialog, deps: [{ token: AjfFormBuilderService }, { token: i2$1.MatDialogRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
1398
|
+
AjfFbWarningConditionEditorDialog.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFbWarningConditionEditorDialog, selector: "ajf-fb-warning-condition-editor-dialog", viewQueries: [{ propertyName: "editor", first: true, predicate: AjfFbConditionEditor, descendants: true }], ngImport: i0, template: "<h3 matDialogTitle>{{'Edit condition'|transloco}}</h3>\n<mat-dialog-content>\n <mat-form-field>\n <input\n matInput\n [(ngModel)]=\"warningMessage\"\n [placeholder]=\"'Warning message' | transloco\"\n />\n </mat-form-field>\n <ajf-condition-editor\n *ngIf=\"fields|async as curFields\"\n [fields]=\"curFields!\"\n [condition]=\"condition\"\n ></ajf-condition-editor>\n</mat-dialog-content>\n<mat-dialog-actions>\n <button mat-button (click)=\"saveCondition()\">{{'Save'|transloco}}</button>\n <button mat-button matDialogClose>{{'Close'|transloco}}</button>\n</mat-dialog-actions>\n", styles: ["ajf-fb-warning-condition-editor-dialog mat-dialog-content{overflow:visible}\n"], components: [{ type: i5.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: AjfFbConditionEditor, selector: "ajf-condition-editor", inputs: ["fields", "condition"] }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i2$1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { type: i2$1.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { type: i6.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i3$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i3$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i3$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]" }, { type: i2$1.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }], pipes: { "transloco": i6$1.TranslocoPipe, "async": i8.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1399
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbWarningConditionEditorDialog, decorators: [{
|
|
1390
1400
|
type: Component,
|
|
1391
1401
|
args: [{ selector: 'ajf-fb-warning-condition-editor-dialog', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<h3 matDialogTitle>{{'Edit condition'|transloco}}</h3>\n<mat-dialog-content>\n <mat-form-field>\n <input\n matInput\n [(ngModel)]=\"warningMessage\"\n [placeholder]=\"'Warning message' | transloco\"\n />\n </mat-form-field>\n <ajf-condition-editor\n *ngIf=\"fields|async as curFields\"\n [fields]=\"curFields!\"\n [condition]=\"condition\"\n ></ajf-condition-editor>\n</mat-dialog-content>\n<mat-dialog-actions>\n <button mat-button (click)=\"saveCondition()\">{{'Save'|transloco}}</button>\n <button mat-button matDialogClose>{{'Close'|transloco}}</button>\n</mat-dialog-actions>\n", styles: ["ajf-fb-warning-condition-editor-dialog mat-dialog-content{overflow:visible}\n"] }]
|
|
1392
1402
|
}], ctorParameters: function () { return [{ type: AjfFormBuilderService }, { type: i2$1.MatDialogRef }]; }, propDecorators: { editor: [{
|
|
@@ -1439,6 +1449,13 @@ function checkDigitsValidity(c) {
|
|
|
1439
1449
|
}
|
|
1440
1450
|
return null;
|
|
1441
1451
|
}
|
|
1452
|
+
function checkRangeValidity(c) {
|
|
1453
|
+
const { start, end } = c.value;
|
|
1454
|
+
if (start != null && end != null && start > end) {
|
|
1455
|
+
return { range: 'End must be greater than start' };
|
|
1456
|
+
}
|
|
1457
|
+
return null;
|
|
1458
|
+
}
|
|
1442
1459
|
class AjfFbNodeProperties {
|
|
1443
1460
|
constructor(_cdr, _service, _dialog, _fb) {
|
|
1444
1461
|
this._cdr = _cdr;
|
|
@@ -1446,15 +1463,17 @@ class AjfFbNodeProperties {
|
|
|
1446
1463
|
this._dialog = _dialog;
|
|
1447
1464
|
this._fb = _fb;
|
|
1448
1465
|
this._fieldSizes = [
|
|
1449
|
-
{ label: 'Normal', value: 'normal' },
|
|
1450
|
-
{ label: '
|
|
1451
|
-
{ label: '
|
|
1466
|
+
{ label: 'Normal', value: 'normal' },
|
|
1467
|
+
{ label: 'Small', value: 'small' },
|
|
1468
|
+
{ label: 'Smaller', value: 'smaller' },
|
|
1469
|
+
{ label: 'Tiny', value: 'tiny' },
|
|
1470
|
+
{ label: 'Mini', value: 'mini' },
|
|
1452
1471
|
];
|
|
1453
1472
|
this._choicesOrigins = [];
|
|
1454
1473
|
this._conditionalBranches = [];
|
|
1455
1474
|
this._validationConditions = [];
|
|
1456
1475
|
this._warningConditions = [];
|
|
1457
|
-
this.isRepeatingContainerNode =
|
|
1476
|
+
this.isRepeatingContainerNode = nodeEntry => {
|
|
1458
1477
|
return nodeEntry != null && isRepeatingContainerNode(nodeEntry.node);
|
|
1459
1478
|
};
|
|
1460
1479
|
this._visibilityOptSub = Subscription.EMPTY;
|
|
@@ -1507,9 +1526,8 @@ class AjfFbNodeProperties {
|
|
|
1507
1526
|
this._saveEvt = new EventEmitter();
|
|
1508
1527
|
this._saveSub = Subscription.EMPTY;
|
|
1509
1528
|
this._nodeEntry = _service.editedNodeEntry;
|
|
1510
|
-
this._choicesOriginsSub =
|
|
1511
|
-
|
|
1512
|
-
this._enabled = this._nodeEntry.pipe(map((n) => n != null));
|
|
1529
|
+
this._choicesOriginsSub = _service.choicesOrigins.subscribe(c => (this._choicesOrigins = c || []));
|
|
1530
|
+
this._enabled = this._nodeEntry.pipe(map(n => n != null));
|
|
1513
1531
|
this._initForm();
|
|
1514
1532
|
this._initVisibilityEdit();
|
|
1515
1533
|
this._initConditionalBranchEdit();
|
|
@@ -1655,6 +1673,9 @@ class AjfFbNodeProperties {
|
|
|
1655
1673
|
isFieldWithChoices(node) {
|
|
1656
1674
|
return isField(node) && isFieldWithChoices(node);
|
|
1657
1675
|
}
|
|
1676
|
+
isRangeField(node) {
|
|
1677
|
+
return isField(node) && isRangeField(node);
|
|
1678
|
+
}
|
|
1658
1679
|
save() {
|
|
1659
1680
|
this._saveEvt.emit();
|
|
1660
1681
|
}
|
|
@@ -1700,11 +1721,12 @@ class AjfFbNodeProperties {
|
|
|
1700
1721
|
.subscribe(([_, formGroup]) => {
|
|
1701
1722
|
const fg = formGroup;
|
|
1702
1723
|
const val = { ...fg.value, conditionalBranches: this._conditionalBranches };
|
|
1724
|
+
console.log(val);
|
|
1703
1725
|
this._service.saveNodeEntry(val);
|
|
1704
1726
|
});
|
|
1705
1727
|
}
|
|
1706
1728
|
_initForm() {
|
|
1707
|
-
this._propertiesForm = this._nodeEntry.pipe(filter(
|
|
1729
|
+
this._propertiesForm = this._nodeEntry.pipe(filter(n => n != null), map(n => {
|
|
1708
1730
|
if (this._visibilityOptSub != null) {
|
|
1709
1731
|
this._visibilityOptSub.unsubscribe();
|
|
1710
1732
|
}
|
|
@@ -1722,7 +1744,7 @@ class AjfFbNodeProperties {
|
|
|
1722
1744
|
label: n.node.label,
|
|
1723
1745
|
visibilityOpt: [visibilityOpt, Validators.required],
|
|
1724
1746
|
visibility: [visibility, Validators.required],
|
|
1725
|
-
conditionalBranchesNum: n.node.conditionalBranches.length
|
|
1747
|
+
conditionalBranchesNum: n.node.conditionalBranches.length,
|
|
1726
1748
|
};
|
|
1727
1749
|
const validators = [];
|
|
1728
1750
|
if (isRepeatingContainerNode(n.node)) {
|
|
@@ -1787,12 +1809,10 @@ class AjfFbNodeProperties {
|
|
|
1787
1809
|
maxValue = (numField.validation.maxValue.condition || '').replace('$value <= ', '');
|
|
1788
1810
|
}
|
|
1789
1811
|
if (numField.validation.minDigits != null) {
|
|
1790
|
-
minDigits = (numField.validation.minDigits.condition ||
|
|
1791
|
-
'').replace('$value.toString().length >= ', '');
|
|
1812
|
+
minDigits = (numField.validation.minDigits.condition || '').replace('$value.toString().length >= ', '');
|
|
1792
1813
|
}
|
|
1793
1814
|
if (numField.validation.maxDigits != null) {
|
|
1794
|
-
maxDigits = (numField.validation.maxDigits.condition ||
|
|
1795
|
-
'').replace('$value.toString().length <= ', '');
|
|
1815
|
+
maxDigits = (numField.validation.maxDigits.condition || '').replace('$value.toString().length <= ', '');
|
|
1796
1816
|
}
|
|
1797
1817
|
}
|
|
1798
1818
|
controls.minValue = minValue;
|
|
@@ -1802,13 +1822,20 @@ class AjfFbNodeProperties {
|
|
|
1802
1822
|
validators.push(checkValueLimitsValidity);
|
|
1803
1823
|
validators.push(checkDigitsValidity);
|
|
1804
1824
|
}
|
|
1825
|
+
if (this.isRangeField(n.node)) {
|
|
1826
|
+
const rangeField = n.node;
|
|
1827
|
+
const { start, end, step } = rangeField;
|
|
1828
|
+
controls.start = start;
|
|
1829
|
+
controls.end = end;
|
|
1830
|
+
controls.step = step;
|
|
1831
|
+
validators.push(checkRangeValidity);
|
|
1832
|
+
}
|
|
1805
1833
|
if (this.isFieldWithChoices(n.node)) {
|
|
1806
1834
|
const fieldWithChoices = n.node;
|
|
1807
|
-
let triggerConditions = (fieldWithChoices.triggerConditions || []).map(
|
|
1835
|
+
let triggerConditions = (fieldWithChoices.triggerConditions || []).map(c => c.condition);
|
|
1808
1836
|
controls.choicesOriginRef = fieldWithChoices.choicesOriginRef;
|
|
1809
|
-
controls.choicesFilter =
|
|
1810
|
-
fieldWithChoices.choicesFilter.formula :
|
|
1811
|
-
null;
|
|
1837
|
+
controls.choicesFilter =
|
|
1838
|
+
fieldWithChoices.choicesFilter != null ? fieldWithChoices.choicesFilter.formula : null;
|
|
1812
1839
|
controls.forceExpanded = fieldWithChoices.forceExpanded;
|
|
1813
1840
|
controls.forceNarrow = fieldWithChoices.forceNarrow;
|
|
1814
1841
|
controls.triggerConditions = triggerConditions;
|
|
@@ -1895,27 +1922,27 @@ class AjfFbNodeProperties {
|
|
|
1895
1922
|
_initTriggerConditionEdit() {
|
|
1896
1923
|
this._editConditionDialogSub = Subscription.EMPTY;
|
|
1897
1924
|
this._cdr.markForCheck();
|
|
1898
|
-
this._editTriggerConditionSub =
|
|
1899
|
-
this.
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1925
|
+
this._editTriggerConditionSub = this._editTriggerConditionEvt
|
|
1926
|
+
.pipe(withLatestFrom(this._propertiesForm))
|
|
1927
|
+
.subscribe(([vcIdx, fg]) => {
|
|
1928
|
+
this._destroyConditionDialog();
|
|
1929
|
+
if (vcIdx < 0 || vcIdx >= this._triggerConditions.length || fg == null) {
|
|
1930
|
+
return;
|
|
1931
|
+
}
|
|
1932
|
+
this._editConditionDialog = this._dialog.open(AjfFbConditionEditorDialog);
|
|
1933
|
+
const cmp = this._editConditionDialog.componentInstance;
|
|
1934
|
+
cmp.condition = this._triggerConditions[vcIdx];
|
|
1935
|
+
this._editConditionDialogSub = this._editConditionDialog
|
|
1936
|
+
.afterClosed()
|
|
1937
|
+
.subscribe((cond) => {
|
|
1938
|
+
if (cond !== void 0) {
|
|
1939
|
+
this._triggerConditions[vcIdx] = cond;
|
|
1905
1940
|
}
|
|
1906
|
-
this.
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
this._editConditionDialogSub =
|
|
1910
|
-
this._editConditionDialog.afterClosed().subscribe((cond) => {
|
|
1911
|
-
if (cond !== void 0) {
|
|
1912
|
-
this._triggerConditions[vcIdx] = cond;
|
|
1913
|
-
}
|
|
1914
|
-
this._editConditionDialogSub.unsubscribe();
|
|
1915
|
-
this._editConditionDialogSub = Subscription.EMPTY;
|
|
1916
|
-
this._cdr.markForCheck();
|
|
1917
|
-
});
|
|
1941
|
+
this._editConditionDialogSub.unsubscribe();
|
|
1942
|
+
this._editConditionDialogSub = Subscription.EMPTY;
|
|
1943
|
+
this._cdr.markForCheck();
|
|
1918
1944
|
});
|
|
1945
|
+
});
|
|
1919
1946
|
}
|
|
1920
1947
|
_initRemoveWarningCondition() {
|
|
1921
1948
|
this._removeWarningConditionSub = this._removeWarningConditionEvt
|
|
@@ -1949,30 +1976,29 @@ class AjfFbNodeProperties {
|
|
|
1949
1976
|
});
|
|
1950
1977
|
}
|
|
1951
1978
|
_initWarningConditionEdit() {
|
|
1952
|
-
this._editWarningConditionSub =
|
|
1953
|
-
this.
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
|
|
1957
|
-
|
|
1958
|
-
|
|
1979
|
+
this._editWarningConditionSub = this._editWarningConditionEvt
|
|
1980
|
+
.pipe(withLatestFrom(this._propertiesForm))
|
|
1981
|
+
.subscribe(([vcIdx, fg]) => {
|
|
1982
|
+
this._destroyWarningConditionDialog();
|
|
1983
|
+
if (vcIdx < 0 || vcIdx >= this._warningConditions.length || fg == null) {
|
|
1984
|
+
return;
|
|
1985
|
+
}
|
|
1986
|
+
this._editWarningConditionDialog = this._dialog.open(AjfFbWarningConditionEditorDialog);
|
|
1987
|
+
const cmp = this._editWarningConditionDialog.componentInstance;
|
|
1988
|
+
const w = this._warningConditions[vcIdx];
|
|
1989
|
+
cmp.condition = w.condition;
|
|
1990
|
+
cmp.warningMessage = w.warningMessage;
|
|
1991
|
+
this._editWarningConditionDialogSub = this._editWarningConditionDialog
|
|
1992
|
+
.afterClosed()
|
|
1993
|
+
.subscribe((cond) => {
|
|
1994
|
+
if (cond !== void 0) {
|
|
1995
|
+
this._warningConditions[vcIdx] = cond;
|
|
1959
1996
|
}
|
|
1960
|
-
this.
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
const w = this._warningConditions[vcIdx];
|
|
1964
|
-
cmp.condition = w.condition;
|
|
1965
|
-
cmp.warningMessage = w.warningMessage;
|
|
1966
|
-
this._editWarningConditionDialogSub =
|
|
1967
|
-
this._editWarningConditionDialog.afterClosed().subscribe((cond) => {
|
|
1968
|
-
if (cond !== void 0) {
|
|
1969
|
-
this._warningConditions[vcIdx] = cond;
|
|
1970
|
-
}
|
|
1971
|
-
this._editWarningConditionDialogSub.unsubscribe();
|
|
1972
|
-
this._editWarningConditionDialogSub = Subscription.EMPTY;
|
|
1973
|
-
this._cdr.markForCheck();
|
|
1974
|
-
});
|
|
1997
|
+
this._editWarningConditionDialogSub.unsubscribe();
|
|
1998
|
+
this._editWarningConditionDialogSub = Subscription.EMPTY;
|
|
1999
|
+
this._cdr.markForCheck();
|
|
1975
2000
|
});
|
|
2001
|
+
});
|
|
1976
2002
|
}
|
|
1977
2003
|
_initRemoveValidationCondition() {
|
|
1978
2004
|
this._removeValidationConditionSub = this._removeValidationConditionEvt
|
|
@@ -2006,205 +2032,202 @@ class AjfFbNodeProperties {
|
|
|
2006
2032
|
});
|
|
2007
2033
|
}
|
|
2008
2034
|
_initValidationConditionEdit() {
|
|
2009
|
-
this._editValidationConditionSub =
|
|
2010
|
-
this.
|
|
2011
|
-
|
|
2012
|
-
|
|
2013
|
-
|
|
2014
|
-
|
|
2015
|
-
|
|
2035
|
+
this._editValidationConditionSub = this._editValidationConditionEvt
|
|
2036
|
+
.pipe(withLatestFrom(this._propertiesForm))
|
|
2037
|
+
.subscribe(([vcIdx, fg]) => {
|
|
2038
|
+
this._destroyValidationConditionDialog();
|
|
2039
|
+
if (vcIdx < 0 || vcIdx >= this._validationConditions.length || fg == null) {
|
|
2040
|
+
return;
|
|
2041
|
+
}
|
|
2042
|
+
this._editValidationConditionDialog = this._dialog.open(AjfFbValidationConditionEditorDialog);
|
|
2043
|
+
const cmp = this._editValidationConditionDialog.componentInstance;
|
|
2044
|
+
const v = this._validationConditions[vcIdx];
|
|
2045
|
+
cmp.condition = v.condition;
|
|
2046
|
+
cmp.errorMessage = v.errorMessage;
|
|
2047
|
+
this._editValidationConditionDialogSub = this._editValidationConditionDialog
|
|
2048
|
+
.afterClosed()
|
|
2049
|
+
.subscribe((cond) => {
|
|
2050
|
+
if (cond !== void 0) {
|
|
2051
|
+
this._validationConditions[vcIdx] = cond;
|
|
2016
2052
|
}
|
|
2017
|
-
this.
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
const v = this._validationConditions[vcIdx];
|
|
2021
|
-
cmp.condition = v.condition;
|
|
2022
|
-
cmp.errorMessage = v.errorMessage;
|
|
2023
|
-
this._editValidationConditionDialogSub =
|
|
2024
|
-
this._editValidationConditionDialog.afterClosed().subscribe((cond) => {
|
|
2025
|
-
if (cond !== void 0) {
|
|
2026
|
-
this._validationConditions[vcIdx] = cond;
|
|
2027
|
-
}
|
|
2028
|
-
this._editValidationConditionDialogSub.unsubscribe();
|
|
2029
|
-
this._editValidationConditionDialogSub = Subscription.EMPTY;
|
|
2030
|
-
this._cdr.markForCheck();
|
|
2031
|
-
});
|
|
2053
|
+
this._editValidationConditionDialogSub.unsubscribe();
|
|
2054
|
+
this._editValidationConditionDialogSub = Subscription.EMPTY;
|
|
2055
|
+
this._cdr.markForCheck();
|
|
2032
2056
|
});
|
|
2057
|
+
});
|
|
2033
2058
|
}
|
|
2034
2059
|
_initForceValueEdit() {
|
|
2035
|
-
this._editForceValueSub =
|
|
2036
|
-
this.
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2060
|
+
this._editForceValueSub = this._editForceValueEvt
|
|
2061
|
+
.pipe(withLatestFrom(this._propertiesForm))
|
|
2062
|
+
.subscribe(([_, formGroup]) => {
|
|
2063
|
+
this._destroyConditionDialog();
|
|
2064
|
+
if (formGroup == null) {
|
|
2065
|
+
return;
|
|
2066
|
+
}
|
|
2067
|
+
const fg = formGroup;
|
|
2068
|
+
const ctrl = fg.controls['forceValue'];
|
|
2069
|
+
this._editConditionDialog = this._dialog.open(AjfFbConditionEditorDialog);
|
|
2070
|
+
this._editConditionDialog.componentInstance.condition = ctrl.value;
|
|
2071
|
+
this._editConditionDialogSub = this._editConditionDialog
|
|
2072
|
+
.afterClosed()
|
|
2073
|
+
.subscribe((cond) => {
|
|
2074
|
+
if (cond !== void 0) {
|
|
2075
|
+
ctrl.setValue(cond);
|
|
2042
2076
|
}
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
this.
|
|
2046
|
-
this._editConditionDialog.componentInstance.condition = ctrl.value;
|
|
2047
|
-
this._editConditionDialogSub =
|
|
2048
|
-
this._editConditionDialog.afterClosed().subscribe((cond) => {
|
|
2049
|
-
if (cond !== void 0) {
|
|
2050
|
-
ctrl.setValue(cond);
|
|
2051
|
-
}
|
|
2052
|
-
this._editConditionDialogSub.unsubscribe();
|
|
2053
|
-
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2054
|
-
this._cdr.markForCheck();
|
|
2055
|
-
});
|
|
2077
|
+
this._editConditionDialogSub.unsubscribe();
|
|
2078
|
+
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2079
|
+
this._cdr.markForCheck();
|
|
2056
2080
|
});
|
|
2081
|
+
});
|
|
2057
2082
|
}
|
|
2058
2083
|
_initNextSlideConditionEdit() {
|
|
2059
|
-
this._editNextSlideConditionSub =
|
|
2060
|
-
this.
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2084
|
+
this._editNextSlideConditionSub = this._editNextSlideConditionEvt
|
|
2085
|
+
.pipe(withLatestFrom(this._propertiesForm))
|
|
2086
|
+
.subscribe(([_, formGroup]) => {
|
|
2087
|
+
this._destroyConditionDialog();
|
|
2088
|
+
if (formGroup == null) {
|
|
2089
|
+
return;
|
|
2090
|
+
}
|
|
2091
|
+
const fg = formGroup;
|
|
2092
|
+
const ctrl = fg.controls['nextSlideCondition'];
|
|
2093
|
+
this._editConditionDialog = this._dialog.open(AjfFbConditionEditorDialog);
|
|
2094
|
+
this._editConditionDialog.componentInstance.condition = ctrl.value;
|
|
2095
|
+
this._editConditionDialogSub = this._editConditionDialog
|
|
2096
|
+
.afterClosed()
|
|
2097
|
+
.subscribe((cond) => {
|
|
2098
|
+
if (cond !== void 0) {
|
|
2099
|
+
ctrl.setValue(cond);
|
|
2066
2100
|
}
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
this.
|
|
2070
|
-
this._editConditionDialog.componentInstance.condition = ctrl.value;
|
|
2071
|
-
this._editConditionDialogSub =
|
|
2072
|
-
this._editConditionDialog.afterClosed().subscribe((cond) => {
|
|
2073
|
-
if (cond !== void 0) {
|
|
2074
|
-
ctrl.setValue(cond);
|
|
2075
|
-
}
|
|
2076
|
-
this._editConditionDialogSub.unsubscribe();
|
|
2077
|
-
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2078
|
-
this._cdr.markForCheck();
|
|
2079
|
-
});
|
|
2101
|
+
this._editConditionDialogSub.unsubscribe();
|
|
2102
|
+
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2103
|
+
this._cdr.markForCheck();
|
|
2080
2104
|
});
|
|
2105
|
+
});
|
|
2081
2106
|
}
|
|
2082
2107
|
_initFormulaEdit() {
|
|
2083
2108
|
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2084
2109
|
this._cdr.markForCheck();
|
|
2085
|
-
this._editFormulaSub =
|
|
2086
|
-
this.
|
|
2087
|
-
|
|
2088
|
-
|
|
2089
|
-
|
|
2090
|
-
|
|
2091
|
-
|
|
2110
|
+
this._editFormulaSub = this._editFormulaEvt
|
|
2111
|
+
.pipe(withLatestFrom(this._propertiesForm))
|
|
2112
|
+
.subscribe(([_, formGroup]) => {
|
|
2113
|
+
this._destroyConditionDialog();
|
|
2114
|
+
if (formGroup == null) {
|
|
2115
|
+
return;
|
|
2116
|
+
}
|
|
2117
|
+
const fg = formGroup;
|
|
2118
|
+
const ctrl = fg.controls['formula'];
|
|
2119
|
+
this._editConditionDialog = this._dialog.open(AjfFbConditionEditorDialog);
|
|
2120
|
+
this._editConditionDialog.componentInstance.condition = ctrl.value;
|
|
2121
|
+
this._editConditionDialogSub = this._editConditionDialog
|
|
2122
|
+
.afterClosed()
|
|
2123
|
+
.subscribe((cond) => {
|
|
2124
|
+
if (cond !== void 0) {
|
|
2125
|
+
ctrl.setValue(cond);
|
|
2092
2126
|
}
|
|
2093
|
-
|
|
2094
|
-
|
|
2095
|
-
this.
|
|
2096
|
-
this._editConditionDialog.componentInstance.condition = ctrl.value;
|
|
2097
|
-
this._editConditionDialogSub =
|
|
2098
|
-
this._editConditionDialog.afterClosed().subscribe((cond) => {
|
|
2099
|
-
if (cond !== void 0) {
|
|
2100
|
-
ctrl.setValue(cond);
|
|
2101
|
-
}
|
|
2102
|
-
this._editConditionDialogSub.unsubscribe();
|
|
2103
|
-
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2104
|
-
this._cdr.markForCheck();
|
|
2105
|
-
});
|
|
2127
|
+
this._editConditionDialogSub.unsubscribe();
|
|
2128
|
+
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2129
|
+
this._cdr.markForCheck();
|
|
2106
2130
|
});
|
|
2131
|
+
});
|
|
2107
2132
|
}
|
|
2108
2133
|
_initFormulaRepsEdit() {
|
|
2109
|
-
this._editFormulaRepsSub =
|
|
2110
|
-
this.
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2134
|
+
this._editFormulaRepsSub = this._editFormulaRepsEvt
|
|
2135
|
+
.pipe(withLatestFrom(this._propertiesForm))
|
|
2136
|
+
.subscribe(([_, formGroup]) => {
|
|
2137
|
+
this._destroyConditionDialog();
|
|
2138
|
+
if (formGroup == null) {
|
|
2139
|
+
return;
|
|
2140
|
+
}
|
|
2141
|
+
const fg = formGroup;
|
|
2142
|
+
const ctrl = fg.controls['formulaReps'];
|
|
2143
|
+
this._editConditionDialog = this._dialog.open(AjfFbConditionEditorDialog);
|
|
2144
|
+
this._editConditionDialog.componentInstance.condition = ctrl.value;
|
|
2145
|
+
this._editConditionDialogSub = this._editConditionDialog
|
|
2146
|
+
.afterClosed()
|
|
2147
|
+
.subscribe((cond) => {
|
|
2148
|
+
if (cond !== void 0) {
|
|
2149
|
+
ctrl.setValue(cond);
|
|
2116
2150
|
}
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
this.
|
|
2120
|
-
this._editConditionDialog.componentInstance.condition = ctrl.value;
|
|
2121
|
-
this._editConditionDialogSub =
|
|
2122
|
-
this._editConditionDialog.afterClosed().subscribe((cond) => {
|
|
2123
|
-
if (cond !== void 0) {
|
|
2124
|
-
ctrl.setValue(cond);
|
|
2125
|
-
}
|
|
2126
|
-
this._editConditionDialogSub.unsubscribe();
|
|
2127
|
-
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2128
|
-
this._cdr.markForCheck();
|
|
2129
|
-
});
|
|
2151
|
+
this._editConditionDialogSub.unsubscribe();
|
|
2152
|
+
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2153
|
+
this._cdr.markForCheck();
|
|
2130
2154
|
});
|
|
2155
|
+
});
|
|
2131
2156
|
}
|
|
2132
2157
|
_initChoicesFilterEdit() {
|
|
2133
|
-
this._editChoicesFilterSub =
|
|
2134
|
-
this.
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2158
|
+
this._editChoicesFilterSub = this._editChoicesFilterEvt
|
|
2159
|
+
.pipe(withLatestFrom(this._propertiesForm))
|
|
2160
|
+
.subscribe(([_, formGroup]) => {
|
|
2161
|
+
this._destroyConditionDialog();
|
|
2162
|
+
if (formGroup == null) {
|
|
2163
|
+
return;
|
|
2164
|
+
}
|
|
2165
|
+
const fg = formGroup;
|
|
2166
|
+
const ctrl = fg.controls['choicesFilter'];
|
|
2167
|
+
this._editConditionDialog = this._dialog.open(AjfFbConditionEditorDialog);
|
|
2168
|
+
this._editConditionDialog.componentInstance.condition = ctrl.value;
|
|
2169
|
+
this._editConditionDialogSub = this._editConditionDialog
|
|
2170
|
+
.afterClosed()
|
|
2171
|
+
.subscribe((cond) => {
|
|
2172
|
+
if (cond !== void 0) {
|
|
2173
|
+
ctrl.setValue(cond);
|
|
2140
2174
|
}
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
this.
|
|
2144
|
-
this._editConditionDialog.componentInstance.condition = ctrl.value;
|
|
2145
|
-
this._editConditionDialogSub =
|
|
2146
|
-
this._editConditionDialog.afterClosed().subscribe((cond) => {
|
|
2147
|
-
if (cond !== void 0) {
|
|
2148
|
-
ctrl.setValue(cond);
|
|
2149
|
-
}
|
|
2150
|
-
this._editConditionDialogSub.unsubscribe();
|
|
2151
|
-
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2152
|
-
this._cdr.markForCheck();
|
|
2153
|
-
});
|
|
2175
|
+
this._editConditionDialogSub.unsubscribe();
|
|
2176
|
+
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2177
|
+
this._cdr.markForCheck();
|
|
2154
2178
|
});
|
|
2179
|
+
});
|
|
2155
2180
|
}
|
|
2156
2181
|
_initConditionalBranchEdit() {
|
|
2157
|
-
this._editConditionalBranchSub =
|
|
2158
|
-
this.
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
|
|
2162
|
-
|
|
2163
|
-
|
|
2182
|
+
this._editConditionalBranchSub = this._editConditionalBranchEvt
|
|
2183
|
+
.pipe(withLatestFrom(this._propertiesForm))
|
|
2184
|
+
.subscribe(([cbIdx, fg]) => {
|
|
2185
|
+
this._destroyConditionDialog();
|
|
2186
|
+
if (cbIdx < 0 || cbIdx >= this._conditionalBranches.length || fg == null) {
|
|
2187
|
+
return;
|
|
2188
|
+
}
|
|
2189
|
+
this._editConditionDialog = this._dialog.open(AjfFbConditionEditorDialog);
|
|
2190
|
+
this._editConditionDialog.componentInstance.condition = this._conditionalBranches[cbIdx];
|
|
2191
|
+
this._editConditionDialogSub = this._editConditionDialog
|
|
2192
|
+
.afterClosed()
|
|
2193
|
+
.subscribe((cond) => {
|
|
2194
|
+
if (cond !== void 0) {
|
|
2195
|
+
this._conditionalBranches[cbIdx] = cond;
|
|
2164
2196
|
}
|
|
2165
|
-
this.
|
|
2166
|
-
this.
|
|
2167
|
-
|
|
2168
|
-
this._editConditionDialogSub =
|
|
2169
|
-
this._editConditionDialog.afterClosed().subscribe((cond) => {
|
|
2170
|
-
if (cond !== void 0) {
|
|
2171
|
-
this._conditionalBranches[cbIdx] = cond;
|
|
2172
|
-
}
|
|
2173
|
-
this._editConditionDialogSub.unsubscribe();
|
|
2174
|
-
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2175
|
-
this._cdr.markForCheck();
|
|
2176
|
-
});
|
|
2197
|
+
this._editConditionDialogSub.unsubscribe();
|
|
2198
|
+
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2199
|
+
this._cdr.markForCheck();
|
|
2177
2200
|
});
|
|
2201
|
+
});
|
|
2178
2202
|
}
|
|
2179
2203
|
_initVisibilityEdit() {
|
|
2180
|
-
this._editVisibilitySub =
|
|
2181
|
-
this.
|
|
2182
|
-
|
|
2183
|
-
|
|
2184
|
-
|
|
2185
|
-
|
|
2186
|
-
|
|
2204
|
+
this._editVisibilitySub = this._editVisibilityEvt
|
|
2205
|
+
.pipe(withLatestFrom(this._propertiesForm))
|
|
2206
|
+
.subscribe(([_, formGroup]) => {
|
|
2207
|
+
this._destroyConditionDialog();
|
|
2208
|
+
if (formGroup == null) {
|
|
2209
|
+
return;
|
|
2210
|
+
}
|
|
2211
|
+
const fg = formGroup;
|
|
2212
|
+
const ctrl = fg.controls['visibility'];
|
|
2213
|
+
const condition = ctrl.value;
|
|
2214
|
+
this._editConditionDialog = this._dialog.open(AjfFbConditionEditorDialog);
|
|
2215
|
+
this._editConditionDialog.componentInstance.condition = condition;
|
|
2216
|
+
this._editConditionDialogSub = this._editConditionDialog
|
|
2217
|
+
.afterClosed()
|
|
2218
|
+
.subscribe((cond) => {
|
|
2219
|
+
if (cond !== void 0) {
|
|
2220
|
+
ctrl.setValue(cond);
|
|
2187
2221
|
}
|
|
2188
|
-
|
|
2189
|
-
|
|
2190
|
-
|
|
2191
|
-
this._editConditionDialog = this._dialog.open(AjfFbConditionEditorDialog);
|
|
2192
|
-
this._editConditionDialog.componentInstance.condition = condition;
|
|
2193
|
-
this._editConditionDialogSub =
|
|
2194
|
-
this._editConditionDialog.afterClosed().subscribe((cond) => {
|
|
2195
|
-
if (cond !== void 0) {
|
|
2196
|
-
ctrl.setValue(cond);
|
|
2197
|
-
}
|
|
2198
|
-
this._editConditionDialogSub.unsubscribe();
|
|
2199
|
-
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2200
|
-
this._cdr.markForCheck();
|
|
2201
|
-
});
|
|
2222
|
+
this._editConditionDialogSub.unsubscribe();
|
|
2223
|
+
this._editConditionDialogSub = Subscription.EMPTY;
|
|
2224
|
+
this._cdr.markForCheck();
|
|
2202
2225
|
});
|
|
2226
|
+
});
|
|
2203
2227
|
}
|
|
2204
2228
|
_handleTriggerCondtionsChange(fg) {
|
|
2205
2229
|
this._triggerConditionsSub = fg.valueChanges
|
|
2206
|
-
.pipe(distinctUntilChanged((v1, v2) => JSON.stringify(v1.triggerConditions) ===
|
|
2207
|
-
JSON.stringify(v2.triggerConditions)))
|
|
2230
|
+
.pipe(distinctUntilChanged((v1, v2) => JSON.stringify(v1.triggerConditions) === JSON.stringify(v2.triggerConditions)))
|
|
2208
2231
|
.subscribe((v) => {
|
|
2209
2232
|
this._triggerConditions = v.triggerConditions;
|
|
2210
2233
|
this._cdr.markForCheck();
|
|
@@ -2212,112 +2235,104 @@ class AjfFbNodeProperties {
|
|
|
2212
2235
|
}
|
|
2213
2236
|
_handleWarningCondtionsChange(fg) {
|
|
2214
2237
|
this._warningConditionsSub = fg.valueChanges
|
|
2215
|
-
.pipe(distinctUntilChanged((v1, v2) => JSON.stringify(v1.warningConditions) ===
|
|
2216
|
-
JSON.stringify(v2.warningConditions)))
|
|
2238
|
+
.pipe(distinctUntilChanged((v1, v2) => JSON.stringify(v1.warningConditions) === JSON.stringify(v2.warningConditions)))
|
|
2217
2239
|
.subscribe((v) => {
|
|
2218
2240
|
this._warningConditions = v.warningConditions;
|
|
2219
2241
|
this._cdr.markForCheck();
|
|
2220
2242
|
});
|
|
2221
2243
|
}
|
|
2222
2244
|
_handleValidationCondtionsChange(fg) {
|
|
2223
|
-
this._validationConditionsSub =
|
|
2224
|
-
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2228
|
-
|
|
2229
|
-
this._cdr.markForCheck();
|
|
2230
|
-
});
|
|
2245
|
+
this._validationConditionsSub = fg.valueChanges
|
|
2246
|
+
.pipe(distinctUntilChanged((v1, v2) => JSON.stringify(v1.validationConditions) === JSON.stringify(v2.validationConditions)))
|
|
2247
|
+
.subscribe((v) => {
|
|
2248
|
+
this._validationConditions = v.validationConditions;
|
|
2249
|
+
this._cdr.markForCheck();
|
|
2250
|
+
});
|
|
2231
2251
|
}
|
|
2232
2252
|
_handleForceValueChange(fg) {
|
|
2233
|
-
this._forceValueSub =
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2253
|
+
this._forceValueSub = fg.valueChanges
|
|
2254
|
+
.pipe(distinctUntilChanged((v1, v2) => v1.forceValue === v2.forceValue))
|
|
2255
|
+
.subscribe((v) => {
|
|
2256
|
+
this._curForceValue = v.forceValue;
|
|
2257
|
+
this._cdr.markForCheck();
|
|
2258
|
+
});
|
|
2239
2259
|
}
|
|
2240
2260
|
_handleNextSlideConditionChange(fg) {
|
|
2241
|
-
this._formulaSub =
|
|
2242
|
-
|
|
2243
|
-
|
|
2244
|
-
|
|
2245
|
-
|
|
2246
|
-
|
|
2247
|
-
|
|
2248
|
-
|
|
2249
|
-
|
|
2250
|
-
|
|
2251
|
-
|
|
2252
|
-
|
|
2253
|
-
this._cdr.markForCheck();
|
|
2254
|
-
});
|
|
2261
|
+
this._formulaSub = fg.valueChanges
|
|
2262
|
+
.pipe(distinctUntilChanged((v1, v2) => v1.nextSlideCondition === v2.nextSlideCondition))
|
|
2263
|
+
.subscribe((v) => {
|
|
2264
|
+
this._nextSlideCondition = v.nextSlideCondition;
|
|
2265
|
+
this._cdr.markForCheck();
|
|
2266
|
+
});
|
|
2267
|
+
this._formulaSub = fg.valueChanges
|
|
2268
|
+
.pipe(distinctUntilChanged((v1, v2) => v1.nextSlideCondition === v2.nextSlideCondition))
|
|
2269
|
+
.subscribe((v) => {
|
|
2270
|
+
this._nextSlideCondition = v.nextSlideCondition;
|
|
2271
|
+
this._cdr.markForCheck();
|
|
2272
|
+
});
|
|
2255
2273
|
}
|
|
2256
2274
|
_handleFormulaChange(fg) {
|
|
2257
|
-
this._formulaSub =
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
|
|
2275
|
+
this._formulaSub = fg.valueChanges
|
|
2276
|
+
.pipe(distinctUntilChanged((v1, v2) => v1.formula === v2.formula))
|
|
2277
|
+
.subscribe((v) => {
|
|
2278
|
+
this._curFormula = v.formula;
|
|
2279
|
+
this._cdr.markForCheck();
|
|
2280
|
+
});
|
|
2263
2281
|
}
|
|
2264
2282
|
_handleFormulaRepsChange(fg) {
|
|
2265
|
-
this._formulaRepsSub =
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
|
|
2269
|
-
|
|
2270
|
-
|
|
2283
|
+
this._formulaRepsSub = fg.valueChanges
|
|
2284
|
+
.pipe(distinctUntilChanged((v1, v2) => v1.formulaReps === v2.formulaReps))
|
|
2285
|
+
.subscribe((v) => {
|
|
2286
|
+
this._curFormulaReps = v.formulaReps;
|
|
2287
|
+
this._cdr.markForCheck();
|
|
2288
|
+
});
|
|
2271
2289
|
}
|
|
2272
2290
|
_handleChoicesFilterChange(fg) {
|
|
2273
|
-
this._choicesFilterSub =
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
|
|
2279
|
-
});
|
|
2291
|
+
this._choicesFilterSub = fg.valueChanges
|
|
2292
|
+
.pipe(distinctUntilChanged((v1, v2) => v1.choicesFilter === v2.choicesFilter))
|
|
2293
|
+
.subscribe((v) => {
|
|
2294
|
+
this._curChoicesFilter = v.choicesFilter;
|
|
2295
|
+
this._cdr.markForCheck();
|
|
2296
|
+
});
|
|
2280
2297
|
}
|
|
2281
2298
|
_handleConditionalBranchesChange(fg) {
|
|
2282
|
-
this._conditionalBranchesSub =
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2291
|
-
newCbs.push(alwaysCondition().condition);
|
|
2292
|
-
}
|
|
2293
|
-
this._conditionalBranches = this._conditionalBranches.concat(newCbs);
|
|
2294
|
-
}
|
|
2295
|
-
else if (curCbNum > cbNum) {
|
|
2296
|
-
this._conditionalBranches.splice(0, curCbNum - cbNum);
|
|
2299
|
+
this._conditionalBranchesSub = fg.valueChanges
|
|
2300
|
+
.pipe(distinctUntilChanged((v1, v2) => v1.conditionalBranchesNum === v2.conditionalBranchesNum))
|
|
2301
|
+
.subscribe((v) => {
|
|
2302
|
+
const cbNum = v.conditionalBranchesNum;
|
|
2303
|
+
const curCbNum = this._conditionalBranches.length;
|
|
2304
|
+
if (curCbNum < cbNum) {
|
|
2305
|
+
let newCbs = [];
|
|
2306
|
+
for (let i = curCbNum; i < cbNum; i++) {
|
|
2307
|
+
newCbs.push(alwaysCondition().condition);
|
|
2297
2308
|
}
|
|
2298
|
-
this.
|
|
2299
|
-
}
|
|
2309
|
+
this._conditionalBranches = this._conditionalBranches.concat(newCbs);
|
|
2310
|
+
}
|
|
2311
|
+
else if (curCbNum > cbNum) {
|
|
2312
|
+
this._conditionalBranches.splice(0, curCbNum - cbNum);
|
|
2313
|
+
}
|
|
2314
|
+
this._cdr.markForCheck();
|
|
2315
|
+
});
|
|
2300
2316
|
}
|
|
2301
2317
|
_handleVisibilityChange(fg) {
|
|
2302
|
-
this._visibilitySub =
|
|
2303
|
-
|
|
2304
|
-
|
|
2305
|
-
|
|
2306
|
-
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2310
|
-
|
|
2311
|
-
|
|
2312
|
-
|
|
2313
|
-
|
|
2314
|
-
|
|
2315
|
-
|
|
2316
|
-
|
|
2317
|
-
|
|
2318
|
-
|
|
2319
|
-
|
|
2320
|
-
});
|
|
2318
|
+
this._visibilitySub = fg.valueChanges
|
|
2319
|
+
.pipe(distinctUntilChanged((v1, v2) => v1.visibilityOpt === v2.visibilityOpt))
|
|
2320
|
+
.subscribe(v => {
|
|
2321
|
+
const visibilityOpt = v.visibilityOpt;
|
|
2322
|
+
let newCondition;
|
|
2323
|
+
switch (visibilityOpt) {
|
|
2324
|
+
case 'always':
|
|
2325
|
+
newCondition = alwaysCondition().condition;
|
|
2326
|
+
break;
|
|
2327
|
+
case 'never':
|
|
2328
|
+
newCondition = neverCondition().condition;
|
|
2329
|
+
break;
|
|
2330
|
+
default:
|
|
2331
|
+
newCondition = null;
|
|
2332
|
+
}
|
|
2333
|
+
this._curVisibility = newCondition;
|
|
2334
|
+
fg.controls['visibility'].setValue(newCondition);
|
|
2335
|
+
});
|
|
2321
2336
|
this._visibilitySub = fg.valueChanges
|
|
2322
2337
|
.pipe(filter(v => v.visibilityOpt === 'condition'), distinctUntilChanged((v1, v2) => v1.visibility === v2.visibility))
|
|
2323
2338
|
.subscribe(v => {
|
|
@@ -2335,11 +2350,11 @@ class AjfFbNodeProperties {
|
|
|
2335
2350
|
return 'condition';
|
|
2336
2351
|
}
|
|
2337
2352
|
}
|
|
2338
|
-
AjfFbNodeProperties.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
2339
|
-
AjfFbNodeProperties.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-next.15", type: AjfFbNodeProperties, selector: "ajf-fb-node-properties", ngImport: i0, template: "<div\n [style.display]=\"(enabled|async) ? 'none' : 'block'\"\n class=\"ajf-disabled-overlay\"\n></div>\n<div class=\"ajf-header\">\n <h3>{{'Properties'|transloco}}</h3>\n <mat-icon (click)=\"save()\">save</mat-icon>\n <mat-icon (click)=\"cancel()\">cancel</mat-icon>\n</div>\n<ng-container *ngIf=\"nodeEntry|async as ne\">\n <ng-container *ngIf=\"propertiesForm|async as pf\">\n <form [formGroup]=\"pf!\" novalidate>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"name\"\n [placeholder]=\"'Name' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"label\"\n [placeholder]=\"'Label' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Visibility'|transloco}}</mat-label>\n <mat-select\n formControlName=\"visibilityOpt\"\n [placeholder]=\"'Visible' | transloco\"\n >\n <mat-option value=\"always\">{{'Always'|transloco}}</mat-option>\n <mat-option value=\"never\">{{'Never'|transloco}}</mat-option>\n <mat-option value=\"condition\"\n >{{'Condition...'|transloco}}</mat-option\n >\n </mat-select>\n </mat-form-field>\n <button\n (click)=\"editVisibility()\"\n [disabled]=\"pf!.value.visibilityOpt != 'condition'\"\n mat-raised-button\n [matTooltip]=\"curVisibility || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curVisibility }}</span>\n </div>\n </button>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Branches'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"conditionalBranchesNum\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n <div *ngFor=\"let branch of conditionalBranches; let idx = index\">\n <button\n (click)=\"editConditionalBranch(idx)\"\n mat-raised-button\n [matTooltip]=\"branch\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ branch }}</span>\n </div>\n </button>\n </div>\n </div>\n <ng-template [ngIf]=\"isRepeatingContainerNode(ne)\">\n <div class=\"ajf-prop\">\n <div><label>{{'Repetitions'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editFormulaReps()\"\n mat-raised-button\n [matTooltip]=\"curFormulaReps || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curFormulaReps }}</span>\n </div>\n </button>\n </div>\n <div><label>{{'Min repetitions'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"minReps\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n <div><label>{{'Max repetitions'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"maxReps\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n </div>\n </ng-template>\n <ng-template [ngIf]=\"isField(ne)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Field size'|transloco}}</mat-label>\n <mat-select\n formControlName=\"size\"\n [placeholder]=\"'Size' | transloco\"\n >\n <mat-option\n *ngFor=\"let fieldSize of fieldSizes\"\n [value]=\"fieldSize.value\"\n >\n {{ fieldSize.label|transloco }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"hint\"\n [placeholder]=\"'Hint' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <textarea\n matInput\n formControlName=\"description\"\n [placeholder]=\"'Description' | transloco\"\n ></textarea>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"defaultValue\"\n [placeholder]=\"'Default value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Formula'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editFormula()\"\n mat-raised-button\n [matTooltip]=\"curFormula || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curFormula }}</span>\n </div>\n </button>\n </div>\n </div>\n <!-- <div class=\"ajf-prop\">\n <div><label>{{'Force value'|translco}}</label></div>\n <div>\n <button (click)=\"editForceValue()\" mat-raised-button [matTooltip]=\"curForceValue\">\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curForceValue }}</span>\n </div>\n </button>\n </div>\n </div> -->\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"notEmpty\"\n >{{'Not empty'|transloco}}</mat-checkbox\n >\n </div>\n <ng-template [ngIf]=\"isNumericField(ne!.node)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"minValue\"\n [placeholder]=\"'Min value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"maxValue\"\n [placeholder]=\"'Max value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"minDigits\"\n [placeholder]=\"'Min digits' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"maxDigits\"\n [placeholder]=\"'Max digits' | transloco\"\n />\n </mat-form-field>\n </div>\n </ng-template>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{ 'Validation' | transloco }}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addValidationCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"validationConditions == null || validationConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No conditions'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let validationCondition of validationConditions; let idx = index\"\n >\n <button\n (click)=\"editValidationCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"validationCondition.condition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ validationCondition.condition }}</span>\n </div>\n </button>\n <mat-icon\n class=\"ajf-pointer\"\n (click)=\"removeValidationCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"notEmptyWarning\"\n >{{'Not empty warning'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{'Warnings'|transloco}}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addWarningCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"warningConditions == null || warningConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No warnings'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let warningCondition of warningConditions; let idx = index\"\n >\n <button\n (click)=\"editWarningCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"warningCondition.condition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ warningCondition.condition }}</span>\n </div>\n </button>\n <mat-icon class=\"ajf-pointer\" (click)=\"removeWarningCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Go to next slide condition'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editNextSlideCondition()\"\n mat-raised-button\n [matTooltip]=\"nextSlideCondition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ nextSlideCondition }}</span>\n </div>\n </button>\n </div>\n </div>\n <ng-template [ngIf]=\"isFieldWithChoices(ne!.node)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Choices origins'|transloco}}</mat-label>\n <mat-select\n formControlName=\"choicesOriginRef\"\n [placeholder]=\"'Choices' | transloco\"\n >\n <mat-option\n *ngFor=\"let choicesOrigin of choicesOrigins\"\n [value]=\"choicesOrigin.name\"\n >\n {{ (choicesOrigin.label || choicesOrigin.name)|transloco }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Choices filter'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editChoicesFilter()\"\n mat-raised-button\n [matTooltip]=\"curChoicesFilter\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curChoicesFilter }}</span>\n </div>\n </button>\n </div>\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"forceExpanded\"\n >{{'Force expanded selection'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"forceNarrow\"\n >{{'Force narrow selection'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{'Trigger selection'|transloco}}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addTriggerCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"triggerConditions == null || triggerConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No trigger condition'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let triggerCondition of triggerConditions; let idx = index\"\n >\n <button\n (click)=\"editTriggerCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"triggerCondition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ triggerCondition }}</span>\n </div>\n </button>\n <mat-icon class=\"pointer\" (click)=\"removeTriggerCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n </ng-template>\n </ng-template>\n </form>\n </ng-container>\n</ng-container>\n", styles: ["ajf-fb-node-properties{display:block;padding:1em;position:relative}ajf-fb-node-properties mat-icon{cursor:pointer}ajf-fb-node-properties .ajf-header{display:flex;flex-direction:row;align-items:center;flex-wrap:nowrap}ajf-fb-node-properties .ajf-header>h3,ajf-fb-node-properties .ajf-header>label{flex:1 0 auto;margin-right:.5em}ajf-fb-node-properties .ajf-header>mat-icon{flex:0 0 auto;margin-left:.5em}ajf-fb-node-properties .ajf-disabled-overlay{position:absolute;top:0;right:0;bottom:0;left:0;opacity:.4;background-color:#fff}ajf-fb-node-properties .ajf-emph{font-style:italic}ajf-fb-node-properties [mat-raised-button]{margin:.5em 0}ajf-fb-node-properties [mat-raised-button].ajf-pointer{cursor:pointer}ajf-fb-node-properties [mat-raised-button] .ajf-icon-cont{display:flex;flex-direction:row;align-items:center}ajf-fb-node-properties [mat-raised-button] .ajf-icon-cont span{flex:1 1 auto;overflow:hidden;text-overflow:ellipsis;display:block;min-height:36px}ajf-fb-node-properties .ajf-validation-row{margin:.5em 0;display:flex;flex-direction:row;align-items:center}ajf-fb-node-properties .ajf-validation-row button{flex:1 1 auto}ajf-fb-node-properties .ajf-validation-row mat-icon{flex:0 0 auto}ajf-fb-node-properties .ajf-prop{margin:.5em 0}ajf-fb-node-properties mat-form-field,ajf-fb-node-properties mat-slider,ajf-fb-node-properties [mat-raised-button]{width:100%}\n"], components: [{ type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i5.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i9.MatSelect, selector: "mat-select", inputs: ["disabled", "disableRipple", "tabIndex"], exportAs: ["matSelect"] }, { type: i8$1.MatOption, selector: "mat-option", exportAs: ["matOption"] }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i9$1.MatSlider, selector: "mat-slider", inputs: ["disabled", "color", "tabIndex", "invert", "max", "min", "step", "thumbLabel", "tickInterval", "value", "displayWith", "valueText", "vertical"], outputs: ["change", "input", "valueChange"], exportAs: ["matSlider"] }, { type: i10.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex", "aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }], directives: [{ type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i3$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i3$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i6.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i3$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i3$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i3$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { type: i5.MatLabel, selector: "mat-label" }, { type: i6$2.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i8.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], pipes: { "async": i8.AsyncPipe, "transloco": i6$1.TranslocoPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
2340
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
2353
|
+
AjfFbNodeProperties.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbNodeProperties, deps: [{ token: i0.ChangeDetectorRef }, { token: AjfFormBuilderService }, { token: i2$1.MatDialog }, { token: i3$1.FormBuilder }], target: i0.ɵɵFactoryTarget.Component });
|
|
2354
|
+
AjfFbNodeProperties.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFbNodeProperties, selector: "ajf-fb-node-properties", ngImport: i0, template: "<div\n [style.display]=\"(enabled|async) ? 'none' : 'block'\"\n class=\"ajf-disabled-overlay\"\n></div>\n<div class=\"ajf-header\">\n <h3>{{'Properties'|transloco}}</h3>\n <mat-icon (click)=\"save()\">save</mat-icon>\n <mat-icon (click)=\"cancel()\">cancel</mat-icon>\n</div>\n<ng-container *ngIf=\"nodeEntry|async as ne\">\n <ng-container *ngIf=\"propertiesForm|async as pf\">\n <form [formGroup]=\"pf!\" novalidate>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"name\"\n [placeholder]=\"'Name' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"label\"\n [placeholder]=\"'Label' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Visibility'|transloco}}</mat-label>\n <mat-select\n formControlName=\"visibilityOpt\"\n [placeholder]=\"'Visible' | transloco\"\n >\n <mat-option value=\"always\">{{'Always'|transloco}}</mat-option>\n <mat-option value=\"never\">{{'Never'|transloco}}</mat-option>\n <mat-option value=\"condition\"\n >{{'Condition...'|transloco}}</mat-option\n >\n </mat-select>\n </mat-form-field>\n <button\n (click)=\"editVisibility()\"\n [disabled]=\"pf!.value.visibilityOpt != 'condition'\"\n mat-raised-button\n [matTooltip]=\"curVisibility || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curVisibility }}</span>\n </div>\n </button>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Branches'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"conditionalBranchesNum\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n <div *ngFor=\"let branch of conditionalBranches; let idx = index\">\n <button\n (click)=\"editConditionalBranch(idx)\"\n mat-raised-button\n [matTooltip]=\"branch\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ branch }}</span>\n </div>\n </button>\n </div>\n </div>\n <ng-template [ngIf]=\"isRepeatingContainerNode(ne)\">\n <div class=\"ajf-prop\">\n <div><label>{{'Repetitions'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editFormulaReps()\"\n mat-raised-button\n [matTooltip]=\"curFormulaReps || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curFormulaReps }}</span>\n </div>\n </button>\n </div>\n <div><label>{{'Min repetitions'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"minReps\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n <div><label>{{'Max repetitions'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"maxReps\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n </div>\n </ng-template>\n <ng-template [ngIf]=\"isField(ne)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Field size'|transloco}}</mat-label>\n <mat-select\n formControlName=\"size\"\n [placeholder]=\"'Size' | transloco\"\n >\n <mat-option\n *ngFor=\"let fieldSize of fieldSizes\"\n [value]=\"fieldSize.value\"\n >\n {{ fieldSize.label|transloco }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"hint\"\n [placeholder]=\"'Hint' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <textarea\n matInput\n formControlName=\"description\"\n [placeholder]=\"'Description' | transloco\"\n ></textarea>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"defaultValue\"\n [placeholder]=\"'Default value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Formula'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editFormula()\"\n mat-raised-button\n [matTooltip]=\"curFormula || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curFormula }}</span>\n </div>\n </button>\n </div>\n </div>\n <!-- <div class=\"ajf-prop\">\n <div><label>{{'Force value'|translco}}</label></div>\n <div>\n <button (click)=\"editForceValue()\" mat-raised-button [matTooltip]=\"curForceValue\">\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curForceValue }}</span>\n </div>\n </button>\n </div>\n </div> -->\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"notEmpty\"\n >{{'Not empty'|transloco}}</mat-checkbox\n >\n </div>\n <ng-template [ngIf]=\"isNumericField(ne!.node)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"minValue\"\n [placeholder]=\"'Min value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"maxValue\"\n [placeholder]=\"'Max value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"minDigits\"\n [placeholder]=\"'Min digits' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"maxDigits\"\n [placeholder]=\"'Max digits' | transloco\"\n />\n </mat-form-field>\n </div>\n </ng-template>\n <ng-template [ngIf]=\"isRangeField(ne!.node)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n type=\"number\"\n formControlName=\"start\"\n [placeholder]=\"'Start' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n type=\"number\"\n formControlName=\"end\"\n [placeholder]=\"'End' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n type=\"number\"\n formControlName=\"step\"\n [placeholder]=\"'Step' | transloco\"\n />\n </mat-form-field>\n </div>\n </ng-template>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{ 'Validation' | transloco }}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addValidationCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"validationConditions == null || validationConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No conditions'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let validationCondition of validationConditions; let idx = index\"\n >\n <button\n (click)=\"editValidationCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"validationCondition.condition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ validationCondition.condition }}</span>\n </div>\n </button>\n <mat-icon\n class=\"ajf-pointer\"\n (click)=\"removeValidationCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"notEmptyWarning\"\n >{{'Not empty warning'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{'Warnings'|transloco}}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addWarningCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"warningConditions == null || warningConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No warnings'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let warningCondition of warningConditions; let idx = index\"\n >\n <button\n (click)=\"editWarningCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"warningCondition.condition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ warningCondition.condition }}</span>\n </div>\n </button>\n <mat-icon class=\"ajf-pointer\" (click)=\"removeWarningCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Go to next slide condition'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editNextSlideCondition()\"\n mat-raised-button\n [matTooltip]=\"nextSlideCondition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ nextSlideCondition }}</span>\n </div>\n </button>\n </div>\n </div>\n <ng-template [ngIf]=\"isFieldWithChoices(ne!.node)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Choices origins'|transloco}}</mat-label>\n <mat-select\n formControlName=\"choicesOriginRef\"\n [placeholder]=\"'Choices' | transloco\"\n >\n <mat-option\n *ngFor=\"let choicesOrigin of choicesOrigins\"\n [value]=\"choicesOrigin.name\"\n >\n {{ (choicesOrigin.label || choicesOrigin.name)|transloco }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Choices filter'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editChoicesFilter()\"\n mat-raised-button\n [matTooltip]=\"curChoicesFilter\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curChoicesFilter }}</span>\n </div>\n </button>\n </div>\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"forceExpanded\"\n >{{'Force expanded selection'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"forceNarrow\"\n >{{'Force narrow selection'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{'Trigger selection'|transloco}}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addTriggerCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"triggerConditions == null || triggerConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No trigger condition'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let triggerCondition of triggerConditions; let idx = index\"\n >\n <button\n (click)=\"editTriggerCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"triggerCondition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ triggerCondition }}</span>\n </div>\n </button>\n <mat-icon class=\"pointer\" (click)=\"removeTriggerCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n </ng-template>\n </ng-template>\n </form>\n </ng-container>\n</ng-container>\n", styles: ["ajf-fb-node-properties{display:block;padding:1em;position:relative}ajf-fb-node-properties mat-icon{cursor:pointer}ajf-fb-node-properties .ajf-header{display:flex;flex-direction:row;align-items:center;flex-wrap:nowrap}ajf-fb-node-properties .ajf-header>h3,ajf-fb-node-properties .ajf-header>label{flex:1 0 auto;margin-right:.5em}ajf-fb-node-properties .ajf-header>mat-icon{flex:0 0 auto;margin-left:.5em}ajf-fb-node-properties .ajf-disabled-overlay{position:absolute;top:0;right:0;bottom:0;left:0;opacity:.4;background-color:#fff}ajf-fb-node-properties .ajf-emph{font-style:italic}ajf-fb-node-properties [mat-raised-button]{margin:.5em 0}ajf-fb-node-properties [mat-raised-button].ajf-pointer{cursor:pointer}ajf-fb-node-properties [mat-raised-button] .ajf-icon-cont{display:flex;flex-direction:row;align-items:center}ajf-fb-node-properties [mat-raised-button] .ajf-icon-cont span{flex:1 1 auto;overflow:hidden;text-overflow:ellipsis;display:block;min-height:36px}ajf-fb-node-properties .ajf-validation-row{margin:.5em 0;display:flex;flex-direction:row;align-items:center}ajf-fb-node-properties .ajf-validation-row button{flex:1 1 auto}ajf-fb-node-properties .ajf-validation-row mat-icon{flex:0 0 auto}ajf-fb-node-properties .ajf-prop{margin:.5em 0}ajf-fb-node-properties mat-form-field,ajf-fb-node-properties mat-slider,ajf-fb-node-properties [mat-raised-button]{width:100%}\n"], components: [{ type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i5.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i9.MatSelect, selector: "mat-select", inputs: ["disabled", "disableRipple", "tabIndex"], exportAs: ["matSelect"] }, { type: i8$1.MatOption, selector: "mat-option", exportAs: ["matOption"] }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i9$1.MatSlider, selector: "mat-slider", inputs: ["disabled", "color", "tabIndex", "invert", "max", "min", "step", "thumbLabel", "tickInterval", "value", "displayWith", "valueText", "vertical"], outputs: ["change", "input", "valueChange"], exportAs: ["matSlider"] }, { type: i10.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex", "aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }], directives: [{ type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i3$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i3$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i6.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i3$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i3$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i3$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { type: i5.MatLabel, selector: "mat-label" }, { type: i6$2.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i8.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i3$1.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }], pipes: { "async": i8.AsyncPipe, "transloco": i6$1.TranslocoPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
2355
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbNodeProperties, decorators: [{
|
|
2341
2356
|
type: Component,
|
|
2342
|
-
args: [{ selector: 'ajf-fb-node-properties', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div\n [style.display]=\"(enabled|async) ? 'none' : 'block'\"\n class=\"ajf-disabled-overlay\"\n></div>\n<div class=\"ajf-header\">\n <h3>{{'Properties'|transloco}}</h3>\n <mat-icon (click)=\"save()\">save</mat-icon>\n <mat-icon (click)=\"cancel()\">cancel</mat-icon>\n</div>\n<ng-container *ngIf=\"nodeEntry|async as ne\">\n <ng-container *ngIf=\"propertiesForm|async as pf\">\n <form [formGroup]=\"pf!\" novalidate>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"name\"\n [placeholder]=\"'Name' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"label\"\n [placeholder]=\"'Label' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Visibility'|transloco}}</mat-label>\n <mat-select\n formControlName=\"visibilityOpt\"\n [placeholder]=\"'Visible' | transloco\"\n >\n <mat-option value=\"always\">{{'Always'|transloco}}</mat-option>\n <mat-option value=\"never\">{{'Never'|transloco}}</mat-option>\n <mat-option value=\"condition\"\n >{{'Condition...'|transloco}}</mat-option\n >\n </mat-select>\n </mat-form-field>\n <button\n (click)=\"editVisibility()\"\n [disabled]=\"pf!.value.visibilityOpt != 'condition'\"\n mat-raised-button\n [matTooltip]=\"curVisibility || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curVisibility }}</span>\n </div>\n </button>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Branches'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"conditionalBranchesNum\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n <div *ngFor=\"let branch of conditionalBranches; let idx = index\">\n <button\n (click)=\"editConditionalBranch(idx)\"\n mat-raised-button\n [matTooltip]=\"branch\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ branch }}</span>\n </div>\n </button>\n </div>\n </div>\n <ng-template [ngIf]=\"isRepeatingContainerNode(ne)\">\n <div class=\"ajf-prop\">\n <div><label>{{'Repetitions'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editFormulaReps()\"\n mat-raised-button\n [matTooltip]=\"curFormulaReps || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curFormulaReps }}</span>\n </div>\n </button>\n </div>\n <div><label>{{'Min repetitions'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"minReps\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n <div><label>{{'Max repetitions'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"maxReps\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n </div>\n </ng-template>\n <ng-template [ngIf]=\"isField(ne)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Field size'|transloco}}</mat-label>\n <mat-select\n formControlName=\"size\"\n [placeholder]=\"'Size' | transloco\"\n >\n <mat-option\n *ngFor=\"let fieldSize of fieldSizes\"\n [value]=\"fieldSize.value\"\n >\n {{ fieldSize.label|transloco }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"hint\"\n [placeholder]=\"'Hint' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <textarea\n matInput\n formControlName=\"description\"\n [placeholder]=\"'Description' | transloco\"\n ></textarea>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"defaultValue\"\n [placeholder]=\"'Default value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Formula'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editFormula()\"\n mat-raised-button\n [matTooltip]=\"curFormula || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curFormula }}</span>\n </div>\n </button>\n </div>\n </div>\n <!-- <div class=\"ajf-prop\">\n <div><label>{{'Force value'|translco}}</label></div>\n <div>\n <button (click)=\"editForceValue()\" mat-raised-button [matTooltip]=\"curForceValue\">\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curForceValue }}</span>\n </div>\n </button>\n </div>\n </div> -->\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"notEmpty\"\n >{{'Not empty'|transloco}}</mat-checkbox\n >\n </div>\n <ng-template [ngIf]=\"isNumericField(ne!.node)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"minValue\"\n [placeholder]=\"'Min value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"maxValue\"\n [placeholder]=\"'Max value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"minDigits\"\n [placeholder]=\"'Min digits' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"maxDigits\"\n [placeholder]=\"'Max digits' | transloco\"\n />\n </mat-form-field>\n </div>\n </ng-template>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{ 'Validation' | transloco }}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addValidationCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"validationConditions == null || validationConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No conditions'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let validationCondition of validationConditions; let idx = index\"\n >\n <button\n (click)=\"editValidationCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"validationCondition.condition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ validationCondition.condition }}</span>\n </div>\n </button>\n <mat-icon\n class=\"ajf-pointer\"\n (click)=\"removeValidationCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"notEmptyWarning\"\n >{{'Not empty warning'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{'Warnings'|transloco}}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addWarningCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"warningConditions == null || warningConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No warnings'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let warningCondition of warningConditions; let idx = index\"\n >\n <button\n (click)=\"editWarningCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"warningCondition.condition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ warningCondition.condition }}</span>\n </div>\n </button>\n <mat-icon class=\"ajf-pointer\" (click)=\"removeWarningCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Go to next slide condition'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editNextSlideCondition()\"\n mat-raised-button\n [matTooltip]=\"nextSlideCondition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ nextSlideCondition }}</span>\n </div>\n </button>\n </div>\n </div>\n <ng-template [ngIf]=\"isFieldWithChoices(ne!.node)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Choices origins'|transloco}}</mat-label>\n <mat-select\n formControlName=\"choicesOriginRef\"\n [placeholder]=\"'Choices' | transloco\"\n >\n <mat-option\n *ngFor=\"let choicesOrigin of choicesOrigins\"\n [value]=\"choicesOrigin.name\"\n >\n {{ (choicesOrigin.label || choicesOrigin.name)|transloco }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Choices filter'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editChoicesFilter()\"\n mat-raised-button\n [matTooltip]=\"curChoicesFilter\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curChoicesFilter }}</span>\n </div>\n </button>\n </div>\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"forceExpanded\"\n >{{'Force expanded selection'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"forceNarrow\"\n >{{'Force narrow selection'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{'Trigger selection'|transloco}}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addTriggerCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"triggerConditions == null || triggerConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No trigger condition'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let triggerCondition of triggerConditions; let idx = index\"\n >\n <button\n (click)=\"editTriggerCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"triggerCondition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ triggerCondition }}</span>\n </div>\n </button>\n <mat-icon class=\"pointer\" (click)=\"removeTriggerCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n </ng-template>\n </ng-template>\n </form>\n </ng-container>\n</ng-container>\n", styles: ["ajf-fb-node-properties{display:block;padding:1em;position:relative}ajf-fb-node-properties mat-icon{cursor:pointer}ajf-fb-node-properties .ajf-header{display:flex;flex-direction:row;align-items:center;flex-wrap:nowrap}ajf-fb-node-properties .ajf-header>h3,ajf-fb-node-properties .ajf-header>label{flex:1 0 auto;margin-right:.5em}ajf-fb-node-properties .ajf-header>mat-icon{flex:0 0 auto;margin-left:.5em}ajf-fb-node-properties .ajf-disabled-overlay{position:absolute;top:0;right:0;bottom:0;left:0;opacity:.4;background-color:#fff}ajf-fb-node-properties .ajf-emph{font-style:italic}ajf-fb-node-properties [mat-raised-button]{margin:.5em 0}ajf-fb-node-properties [mat-raised-button].ajf-pointer{cursor:pointer}ajf-fb-node-properties [mat-raised-button] .ajf-icon-cont{display:flex;flex-direction:row;align-items:center}ajf-fb-node-properties [mat-raised-button] .ajf-icon-cont span{flex:1 1 auto;overflow:hidden;text-overflow:ellipsis;display:block;min-height:36px}ajf-fb-node-properties .ajf-validation-row{margin:.5em 0;display:flex;flex-direction:row;align-items:center}ajf-fb-node-properties .ajf-validation-row button{flex:1 1 auto}ajf-fb-node-properties .ajf-validation-row mat-icon{flex:0 0 auto}ajf-fb-node-properties .ajf-prop{margin:.5em 0}ajf-fb-node-properties mat-form-field,ajf-fb-node-properties mat-slider,ajf-fb-node-properties [mat-raised-button]{width:100%}\n"] }]
|
|
2357
|
+
args: [{ selector: 'ajf-fb-node-properties', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div\n [style.display]=\"(enabled|async) ? 'none' : 'block'\"\n class=\"ajf-disabled-overlay\"\n></div>\n<div class=\"ajf-header\">\n <h3>{{'Properties'|transloco}}</h3>\n <mat-icon (click)=\"save()\">save</mat-icon>\n <mat-icon (click)=\"cancel()\">cancel</mat-icon>\n</div>\n<ng-container *ngIf=\"nodeEntry|async as ne\">\n <ng-container *ngIf=\"propertiesForm|async as pf\">\n <form [formGroup]=\"pf!\" novalidate>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"name\"\n [placeholder]=\"'Name' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"label\"\n [placeholder]=\"'Label' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Visibility'|transloco}}</mat-label>\n <mat-select\n formControlName=\"visibilityOpt\"\n [placeholder]=\"'Visible' | transloco\"\n >\n <mat-option value=\"always\">{{'Always'|transloco}}</mat-option>\n <mat-option value=\"never\">{{'Never'|transloco}}</mat-option>\n <mat-option value=\"condition\"\n >{{'Condition...'|transloco}}</mat-option\n >\n </mat-select>\n </mat-form-field>\n <button\n (click)=\"editVisibility()\"\n [disabled]=\"pf!.value.visibilityOpt != 'condition'\"\n mat-raised-button\n [matTooltip]=\"curVisibility || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curVisibility }}</span>\n </div>\n </button>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Branches'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"conditionalBranchesNum\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n <div *ngFor=\"let branch of conditionalBranches; let idx = index\">\n <button\n (click)=\"editConditionalBranch(idx)\"\n mat-raised-button\n [matTooltip]=\"branch\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ branch }}</span>\n </div>\n </button>\n </div>\n </div>\n <ng-template [ngIf]=\"isRepeatingContainerNode(ne)\">\n <div class=\"ajf-prop\">\n <div><label>{{'Repetitions'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editFormulaReps()\"\n mat-raised-button\n [matTooltip]=\"curFormulaReps || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curFormulaReps }}</span>\n </div>\n </button>\n </div>\n <div><label>{{'Min repetitions'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"minReps\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n <div><label>{{'Max repetitions'|transloco}}</label></div>\n <div>\n <mat-slider\n formControlName=\"maxReps\"\n thumbLabel\n tickInterval=\"auto\"\n min=\"1\"\n max=\"5\"\n step=\"1\"\n ></mat-slider>\n </div>\n </div>\n </ng-template>\n <ng-template [ngIf]=\"isField(ne)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Field size'|transloco}}</mat-label>\n <mat-select\n formControlName=\"size\"\n [placeholder]=\"'Size' | transloco\"\n >\n <mat-option\n *ngFor=\"let fieldSize of fieldSizes\"\n [value]=\"fieldSize.value\"\n >\n {{ fieldSize.label|transloco }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"hint\"\n [placeholder]=\"'Hint' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <textarea\n matInput\n formControlName=\"description\"\n [placeholder]=\"'Description' | transloco\"\n ></textarea>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"defaultValue\"\n [placeholder]=\"'Default value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Formula'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editFormula()\"\n mat-raised-button\n [matTooltip]=\"curFormula || ''\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curFormula }}</span>\n </div>\n </button>\n </div>\n </div>\n <!-- <div class=\"ajf-prop\">\n <div><label>{{'Force value'|translco}}</label></div>\n <div>\n <button (click)=\"editForceValue()\" mat-raised-button [matTooltip]=\"curForceValue\">\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curForceValue }}</span>\n </div>\n </button>\n </div>\n </div> -->\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"notEmpty\"\n >{{'Not empty'|transloco}}</mat-checkbox\n >\n </div>\n <ng-template [ngIf]=\"isNumericField(ne!.node)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"minValue\"\n [placeholder]=\"'Min value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"maxValue\"\n [placeholder]=\"'Max value' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"minDigits\"\n [placeholder]=\"'Min digits' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n formControlName=\"maxDigits\"\n [placeholder]=\"'Max digits' | transloco\"\n />\n </mat-form-field>\n </div>\n </ng-template>\n <ng-template [ngIf]=\"isRangeField(ne!.node)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n type=\"number\"\n formControlName=\"start\"\n [placeholder]=\"'Start' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n type=\"number\"\n formControlName=\"end\"\n [placeholder]=\"'End' | transloco\"\n />\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <mat-form-field>\n <input\n matInput\n type=\"number\"\n formControlName=\"step\"\n [placeholder]=\"'Step' | transloco\"\n />\n </mat-form-field>\n </div>\n </ng-template>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{ 'Validation' | transloco }}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addValidationCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"validationConditions == null || validationConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No conditions'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let validationCondition of validationConditions; let idx = index\"\n >\n <button\n (click)=\"editValidationCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"validationCondition.condition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ validationCondition.condition }}</span>\n </div>\n </button>\n <mat-icon\n class=\"ajf-pointer\"\n (click)=\"removeValidationCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"notEmptyWarning\"\n >{{'Not empty warning'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{'Warnings'|transloco}}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addWarningCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"warningConditions == null || warningConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No warnings'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let warningCondition of warningConditions; let idx = index\"\n >\n <button\n (click)=\"editWarningCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"warningCondition.condition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ warningCondition.condition }}</span>\n </div>\n </button>\n <mat-icon class=\"ajf-pointer\" (click)=\"removeWarningCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Go to next slide condition'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editNextSlideCondition()\"\n mat-raised-button\n [matTooltip]=\"nextSlideCondition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ nextSlideCondition }}</span>\n </div>\n </button>\n </div>\n </div>\n <ng-template [ngIf]=\"isFieldWithChoices(ne!.node)\">\n <div class=\"ajf-prop\">\n <mat-form-field>\n <mat-label>{{'Choices origins'|transloco}}</mat-label>\n <mat-select\n formControlName=\"choicesOriginRef\"\n [placeholder]=\"'Choices' | transloco\"\n >\n <mat-option\n *ngFor=\"let choicesOrigin of choicesOrigins\"\n [value]=\"choicesOrigin.name\"\n >\n {{ (choicesOrigin.label || choicesOrigin.name)|transloco }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n </div>\n <div class=\"ajf-prop\">\n <div><label>{{'Choices filter'|transloco}}</label></div>\n <div>\n <button\n (click)=\"editChoicesFilter()\"\n mat-raised-button\n [matTooltip]=\"curChoicesFilter\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ curChoicesFilter }}</span>\n </div>\n </button>\n </div>\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"forceExpanded\"\n >{{'Force expanded selection'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <mat-checkbox formControlName=\"forceNarrow\"\n >{{'Force narrow selection'|transloco}}</mat-checkbox\n >\n </div>\n <div class=\"ajf-prop\">\n <div class=\"ajf-header\">\n <label>{{'Trigger selection'|transloco}}</label>\n <mat-icon class=\"ajf-pointer\" (click)=\"addTriggerCondition()\"\n >add_circle_outline</mat-icon\n >\n </div>\n <div\n *ngIf=\"triggerConditions == null || triggerConditions.length == 0\"\n class=\"ajf-validation-row ajf-emph\"\n >\n {{'No trigger condition'|transloco}}\n </div>\n <div\n class=\"ajf-validation-row\"\n *ngFor=\"let triggerCondition of triggerConditions; let idx = index\"\n >\n <button\n (click)=\"editTriggerCondition(idx)\"\n mat-raised-button\n [matTooltip]=\"triggerCondition\"\n >\n <div class=\"ajf-icon-cont\">\n <mat-icon>edit</mat-icon>\n <span>{{ triggerCondition }}</span>\n </div>\n </button>\n <mat-icon class=\"pointer\" (click)=\"removeTriggerCondition(idx)\"\n >remove_circle_outline</mat-icon\n >\n </div>\n </div>\n </ng-template>\n </ng-template>\n </form>\n </ng-container>\n</ng-container>\n", styles: ["ajf-fb-node-properties{display:block;padding:1em;position:relative}ajf-fb-node-properties mat-icon{cursor:pointer}ajf-fb-node-properties .ajf-header{display:flex;flex-direction:row;align-items:center;flex-wrap:nowrap}ajf-fb-node-properties .ajf-header>h3,ajf-fb-node-properties .ajf-header>label{flex:1 0 auto;margin-right:.5em}ajf-fb-node-properties .ajf-header>mat-icon{flex:0 0 auto;margin-left:.5em}ajf-fb-node-properties .ajf-disabled-overlay{position:absolute;top:0;right:0;bottom:0;left:0;opacity:.4;background-color:#fff}ajf-fb-node-properties .ajf-emph{font-style:italic}ajf-fb-node-properties [mat-raised-button]{margin:.5em 0}ajf-fb-node-properties [mat-raised-button].ajf-pointer{cursor:pointer}ajf-fb-node-properties [mat-raised-button] .ajf-icon-cont{display:flex;flex-direction:row;align-items:center}ajf-fb-node-properties [mat-raised-button] .ajf-icon-cont span{flex:1 1 auto;overflow:hidden;text-overflow:ellipsis;display:block;min-height:36px}ajf-fb-node-properties .ajf-validation-row{margin:.5em 0;display:flex;flex-direction:row;align-items:center}ajf-fb-node-properties .ajf-validation-row button{flex:1 1 auto}ajf-fb-node-properties .ajf-validation-row mat-icon{flex:0 0 auto}ajf-fb-node-properties .ajf-prop{margin:.5em 0}ajf-fb-node-properties mat-form-field,ajf-fb-node-properties mat-slider,ajf-fb-node-properties [mat-raised-button]{width:100%}\n"] }]
|
|
2343
2358
|
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: AjfFormBuilderService }, { type: i2$1.MatDialog }, { type: i3$1.FormBuilder }]; } });
|
|
2344
2359
|
|
|
2345
2360
|
/**
|
|
@@ -2539,7 +2554,9 @@ class AjfFbNodeEntry {
|
|
|
2539
2554
|
};
|
|
2540
2555
|
}
|
|
2541
2556
|
_updateBranchHeights() {
|
|
2542
|
-
if (this.nodeEntry == null ||
|
|
2557
|
+
if (this.nodeEntry == null ||
|
|
2558
|
+
!this.isNodeEntry ||
|
|
2559
|
+
this.branchLines == null ||
|
|
2543
2560
|
this.childEntries == null) {
|
|
2544
2561
|
return;
|
|
2545
2562
|
}
|
|
@@ -2556,9 +2573,9 @@ class AjfFbNodeEntry {
|
|
|
2556
2573
|
});
|
|
2557
2574
|
}
|
|
2558
2575
|
}
|
|
2559
|
-
AjfFbNodeEntry.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
2560
|
-
AjfFbNodeEntry.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-next.15", type: AjfFbNodeEntry, selector: "ajf-fb-node-entry", inputs: { isFirst: "isFirst", isExpanded: "isExpanded", nodeEntry: "nodeEntry", level: "level", isDraggable: "isDraggable", originOffset: "originOffset", firstBranchColor: "firstBranchColor" }, host: { listeners: { "window.resize": "onResize()" } }, viewQueries: [{ propertyName: "branchLines", predicate: AjfFbBranchLine, descendants: true }, { propertyName: "childEntries", predicate: AjfFbNodeEntry, descendants: true, read: ElementRef }], ngImport: i0, template: "<ng-container *ngIf=\"nodeEntry != null ; else rootEmpty\">\n <ng-template [ngIf]=\"isNodeEntry && !isLastNode()\">\n <ajf-fb-branch-line\n *ngFor=\"let childNodeEntry of realNodeEntry.children; let idx = index\"\n [offset]=\"idx\"\n [color]=\"branchColors[idx]\"\n ></ajf-fb-branch-line>\n </ng-template>\n\n <div\n class=\"mat-card-container\"\n [class.ajf-highlight]=\"(currentEditedNode|async) == nodeEntry\"\n >\n <div\n *ngIf=\"!isFirst\"\n class=\"ajf-origin-line\"\n [style.margin-left]=\"originLeftMargin\"\n [style.border-color]=\"firstBranchColor\"\n ></div>\n <ng-template [ngIf]=\"isNodeEntry\">\n <ng-container *ngIf=\"!isDraggable; else draggable\">\n <mat-card>\n <ng-container *ngTemplateOutlet=\"cardTitle\"></ng-container>\n <ng-container *ngTemplateOutlet=\"cardContent\"></ng-container>\n </mat-card>\n </ng-container>\n\n <ng-template #draggable>\n <mat-card cdkDrag [cdkDragData]=\"realNodeEntry\" class=\"ajf-draggable-box\">\n <ng-container\n *ngIf=\"isSlide(realNodeEntry.node); else fieldPanel\"\n >\n <ng-container *ngTemplateOutlet=\"slidePanel\"></ng-container>\n </ng-container>\n </mat-card>\n </ng-template>\n\n <ng-template #slidePanel>\n <mat-expansion-panel\n [expanded]=\"isExpanded\"\n (opened)=\"isExpanded = true\"\n (closed)=\"isExpanded = false\"\n class=\"mat-elevation-z\"\n >\n <mat-expansion-panel-header>\n <ng-container *ngTemplateOutlet=\"cardTitle\"></ng-container>\n </mat-expansion-panel-header>\n <ng-container *ngTemplateOutlet=\"cardContent\"></ng-container>\n </mat-expansion-panel>\n </ng-template>\n\n <ng-template #fieldPanel>\n <ng-container *ngTemplateOutlet=\"cardTitle\"></ng-container>\n <ng-container *ngTemplateOutlet=\"cardContent\"></ng-container>\n </ng-template>\n\n <ng-template #cardTitle>\n <div class=\"ajf-title-row\">\n <ajf-node-icon [node]=\"realNodeEntry.node\"></ajf-node-icon>\n <span\n class=\"ajf-title\"\n [innerHTML]=\"(realNodeEntry.node.label || realNodeEntry.node.name) | transloco\"\n ></span>\n <span\n *ngIf=\"realNodeEntry.node.visibility && realNodeEntry.node.visibility?.condition !== 'true'\"\n class=\"ajf-visibility-condition\"\n [innerHTML]=\"'Condition: (' + realNodeEntry.node.visibility?.condition + ')'\"\n >\n </span>\n <span class=\"ajf-actions\">\n <button\n [disabled]=\"(currentEditedNode|async) == nodeEntry\"\n (click)=\"edit($event)\"\n mat-icon-button\n >\n <mat-icon>edit</mat-icon>\n </button>\n <button\n [disabled]=\"(currentEditedNode|async) == null\"\n (click)=\"delete($event)\"\n mat-icon-button\n >\n <mat-icon>delete</mat-icon>\n </button>\n </span>\n </div>\n </ng-template>\n\n <ng-template #cardContent>\n <div *ngIf=\"hasContent\">\n <ajf-fb-node-entry\n cdkDropList\n class=\"ajf-fields-list\"\n *ngFor=\"let contentEntry of realNodeEntry.content; let isFirstChild = first; let idx = index\"\n [id]=\"assignId()\"\n [level]=\"level + 1\"\n [isFirst]=\"isFirstChild\"\n [firstBranchColor]=\"branchColors[idx]\"\n [nodeEntry]=\"contentEntry\"\n [cdkDropListEnterPredicate]=\"disableSlideDrop\"\n (cdkDropListDropped)=\"onDrop($event, true)\"\n [isExpanded]=\"isExpanded\"\n ></ajf-fb-node-entry>\n <mat-card\n class=\"ajf-empty\"\n *ngIf=\"realNodeEntry.content.length === 0\"\n cdkDropList\n [id]=\"assignId(true)\"\n [cdkDropListEnterPredicate]=\"disableSlideDrop\"\n (cdkDropListDropped)=\"onDrop($event, true)\"\n ><mat-card-title>Drop your fields here</mat-card-title></mat-card\n >\n </div>\n </ng-template>\n </ng-template>\n </div>\n\n <ng-template [ngIf]=\"isNodeEntry\">\n <ng-container\n *ngFor=\"let childNodeEntry of realNodeEntry.children; let idx = index\"\n >\n <ajf-fb-node-entry\n *ngIf=\"!isLastNode()\"\n [level]=\"level\"\n [originOffset]=\"idx\"\n [firstBranchColor]=\"branchColors[idx]\"\n [nodeEntry]=\"childNodeEntry\"\n [isExpanded]=\"isExpanded\"\n ></ajf-fb-node-entry>\n </ng-container>\n </ng-template>\n</ng-container>\n\n<ng-template #rootEmpty>\n <div class=\"mat-card-container\">\n <mat-card\n class=\"ajf-empty\"\n cdkDropList\n [cdkDropListEnterPredicate]=\"emptyAreaDropPredicate()\"\n (cdkDropListDropped)=\"onDrop($event)\"\n ><mat-card-title>Drop your slides here</mat-card-title>\n </mat-card>\n </div>\n</ng-template>\n", styles: ["ajf-fb-node-entry{display:block;position:relative}ajf-fb-node-entry .mat-card-container{position:relative}ajf-fb-node-entry .mat-card-container .ajf-origin-line{position:absolute;top:0;left:25px;width:25px;height:25px;border-bottom:2px solid;border-left:2px solid;border-bottom-left-radius:.5em}ajf-fb-node-entry .mat-card-container mat-card{margin-left:50px;padding:.5em 1em;margin-top:.2em;margin-bottom:.2em;background-color:#fff}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row{display:flex;flex:1 1 auto;flex-direction:row;align-items:center}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row>.ajf-title{flex:1 1 auto}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row>.ajf-visibility-condition{flex:1 1 auto;font-size:10px;color:#999}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row>.ajf-actions{flex:0 0 auto;white-space:nowrap}ajf-fb-node-entry .mat-card-container mat-card.ajf-empty{line-height:36px;border:2px dashed;box-shadow:none;box-sizing:border-box;text-align:center;color:#ccc}ajf-fb-node-entry .mat-card-container mat-card.ajf-draggable-box{padding:20px 10px;border-bottom:solid 1px #ccc;border-right:solid 1px #ccc;color:rgba(0,0,0,.87);box-sizing:border-box;cursor:move;background:#fff;font-size:14px}ajf-fb-node-entry .mat-card-container.ajf-highlight>mat-card{background-color:#fff9c4}ajf-fb-node-entry.ajf-fields-list{max-width:80%;min-height:60px;display:block;background:#fff;border-radius:4px;overflow:hidden}ajf-fb-node-entry .cdk-drag-placeholder{opacity:0;min-height:60px}ajf-fb-node-entry .ajf-fields-list.cdk-drop-list-dragging .ajf-draggable-box:not(.cdk-drag-placeholder),ajf-fb-node-entry .cdk-drag-animating{transition:transform 250ms cubic-bezier(0, 0, 0.2, 1)}\n"], components: [{ type: AjfFbBranchLine, selector: "ajf-fb-branch-line", inputs: ["offset", "color", "height"] }, { type: i3$3.MatCard, selector: "mat-card", exportAs: ["matCard"] }, { type: i4$2.MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["disabled", "expanded", "hideToggle", "togglePosition"], outputs: ["opened", "closed", "expandedChange", "afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { type: i4$2.MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["tabIndex", "expandedHeight", "collapsedHeight"] }, { type: i4$1.AjfNodeIcon, selector: "ajf-node-icon" }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: AjfFbNodeEntry, selector: "ajf-fb-node-entry", inputs: ["isFirst", "isExpanded", "nodeEntry", "level", "isDraggable", "originOffset", "firstBranchColor"] }], directives: [{ type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i8.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i14.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { type: i14.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { type: i3$3.MatCardTitle, selector: "mat-card-title, [mat-card-title], [matCardTitle]" }], pipes: { "async": i8.AsyncPipe, "transloco": i6$1.TranslocoPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
2561
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
2576
|
+
AjfFbNodeEntry.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbNodeEntry, deps: [{ token: AjfFormBuilderService }], target: i0.ɵɵFactoryTarget.Component });
|
|
2577
|
+
AjfFbNodeEntry.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFbNodeEntry, selector: "ajf-fb-node-entry", inputs: { isFirst: "isFirst", isExpanded: "isExpanded", nodeEntry: "nodeEntry", level: "level", isDraggable: "isDraggable", originOffset: "originOffset", firstBranchColor: "firstBranchColor" }, host: { listeners: { "window.resize": "onResize()" } }, viewQueries: [{ propertyName: "branchLines", predicate: AjfFbBranchLine, descendants: true }, { propertyName: "childEntries", predicate: AjfFbNodeEntry, descendants: true, read: ElementRef }], ngImport: i0, template: "<ng-container *ngIf=\"nodeEntry != null ; else rootEmpty\">\n <ng-template [ngIf]=\"isNodeEntry && !isLastNode()\">\n <ajf-fb-branch-line\n *ngFor=\"let childNodeEntry of realNodeEntry.children; let idx = index\"\n [offset]=\"idx\"\n [color]=\"branchColors[idx]\"\n ></ajf-fb-branch-line>\n </ng-template>\n\n <div\n class=\"mat-card-container\"\n [class.ajf-highlight]=\"(currentEditedNode|async) == nodeEntry\"\n >\n <div\n *ngIf=\"!isFirst\"\n class=\"ajf-origin-line\"\n [style.margin-left]=\"originLeftMargin\"\n [style.border-color]=\"firstBranchColor\"\n ></div>\n <ng-template [ngIf]=\"isNodeEntry\">\n <ng-container *ngIf=\"!isDraggable; else draggable\">\n <mat-card>\n <ng-container *ngTemplateOutlet=\"cardTitle\"></ng-container>\n <ng-container *ngTemplateOutlet=\"cardContent\"></ng-container>\n </mat-card>\n </ng-container>\n\n <ng-template #draggable>\n <mat-card cdkDrag [cdkDragData]=\"realNodeEntry\" class=\"ajf-draggable-box\">\n <ng-container\n *ngIf=\"isSlide(realNodeEntry.node); else fieldPanel\"\n >\n <ng-container *ngTemplateOutlet=\"slidePanel\"></ng-container>\n </ng-container>\n </mat-card>\n </ng-template>\n\n <ng-template #slidePanel>\n <mat-expansion-panel\n [expanded]=\"isExpanded\"\n (opened)=\"isExpanded = true\"\n (closed)=\"isExpanded = false\"\n class=\"mat-elevation-z\"\n >\n <mat-expansion-panel-header>\n <ng-container *ngTemplateOutlet=\"cardTitle\"></ng-container>\n </mat-expansion-panel-header>\n <ng-container *ngTemplateOutlet=\"cardContent\"></ng-container>\n </mat-expansion-panel>\n </ng-template>\n\n <ng-template #fieldPanel>\n <ng-container *ngTemplateOutlet=\"cardTitle\"></ng-container>\n <ng-container *ngTemplateOutlet=\"cardContent\"></ng-container>\n </ng-template>\n\n <ng-template #cardTitle>\n <div class=\"ajf-title-row\">\n <ajf-node-icon [node]=\"realNodeEntry.node\"></ajf-node-icon>\n <span\n class=\"ajf-title\"\n [innerHTML]=\"(realNodeEntry.node.label || realNodeEntry.node.name) | transloco\"\n ></span>\n <span\n *ngIf=\"realNodeEntry.node.visibility && realNodeEntry.node.visibility?.condition !== 'true'\"\n class=\"ajf-visibility-condition\"\n [innerHTML]=\"'Condition: (' + realNodeEntry.node.visibility?.condition + ')'\"\n >\n </span>\n <span class=\"ajf-actions\">\n <button\n [disabled]=\"(currentEditedNode|async) == nodeEntry\"\n (click)=\"edit($event)\"\n mat-icon-button\n >\n <mat-icon>edit</mat-icon>\n </button>\n <button\n [disabled]=\"(currentEditedNode|async) == null\"\n (click)=\"delete($event)\"\n mat-icon-button\n >\n <mat-icon>delete</mat-icon>\n </button>\n </span>\n </div>\n </ng-template>\n\n <ng-template #cardContent>\n <div *ngIf=\"hasContent\">\n <ajf-fb-node-entry\n cdkDropList\n class=\"ajf-fields-list\"\n *ngFor=\"let contentEntry of realNodeEntry.content; let isFirstChild = first; let idx = index\"\n [id]=\"assignId()\"\n [level]=\"level + 1\"\n [isFirst]=\"isFirstChild\"\n [firstBranchColor]=\"branchColors[idx]\"\n [nodeEntry]=\"contentEntry\"\n [cdkDropListEnterPredicate]=\"disableSlideDrop\"\n (cdkDropListDropped)=\"onDrop($event, true)\"\n [isExpanded]=\"isExpanded\"\n ></ajf-fb-node-entry>\n <mat-card\n class=\"ajf-empty\"\n *ngIf=\"realNodeEntry.content.length === 0\"\n cdkDropList\n [id]=\"assignId(true)\"\n [cdkDropListEnterPredicate]=\"disableSlideDrop\"\n (cdkDropListDropped)=\"onDrop($event, true)\"\n ><mat-card-title>Drop your fields here</mat-card-title></mat-card\n >\n </div>\n </ng-template>\n </ng-template>\n </div>\n\n <ng-template [ngIf]=\"isNodeEntry\">\n <ng-container\n *ngFor=\"let childNodeEntry of realNodeEntry.children; let idx = index\"\n >\n <ajf-fb-node-entry\n *ngIf=\"!isLastNode()\"\n [level]=\"level\"\n [originOffset]=\"idx\"\n [firstBranchColor]=\"branchColors[idx]\"\n [nodeEntry]=\"childNodeEntry\"\n [isExpanded]=\"isExpanded\"\n ></ajf-fb-node-entry>\n </ng-container>\n </ng-template>\n</ng-container>\n\n<ng-template #rootEmpty>\n <div class=\"mat-card-container\">\n <mat-card\n class=\"ajf-empty\"\n cdkDropList\n [cdkDropListEnterPredicate]=\"emptyAreaDropPredicate()\"\n (cdkDropListDropped)=\"onDrop($event)\"\n ><mat-card-title>Drop your slides here</mat-card-title>\n </mat-card>\n </div>\n</ng-template>\n", styles: ["ajf-fb-node-entry{display:block;position:relative}ajf-fb-node-entry .mat-card-container{position:relative}ajf-fb-node-entry .mat-card-container .ajf-origin-line{position:absolute;top:0;left:25px;width:25px;height:25px;border-bottom:2px solid;border-left:2px solid;border-bottom-left-radius:.5em}ajf-fb-node-entry .mat-card-container mat-card{margin-left:50px;padding:.5em 1em;margin-top:.2em;margin-bottom:.2em;background-color:#fff}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row{display:flex;flex:1 1 auto;flex-direction:row;align-items:center}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row>.ajf-title{flex:1 1 auto}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row>.ajf-visibility-condition{flex:1 1 auto;font-size:10px;color:#999}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row>.ajf-actions{flex:0 0 auto;white-space:nowrap}ajf-fb-node-entry .mat-card-container mat-card.ajf-empty{line-height:36px;border:2px dashed;box-shadow:none;box-sizing:border-box;text-align:center;color:#ccc}ajf-fb-node-entry .mat-card-container mat-card.ajf-draggable-box{padding:20px 10px;border-bottom:solid 1px #ccc;border-right:solid 1px #ccc;color:rgba(0,0,0,.87);box-sizing:border-box;cursor:move;background:#fff;font-size:14px}ajf-fb-node-entry .mat-card-container.ajf-highlight>mat-card{background-color:#fff9c4}ajf-fb-node-entry.ajf-fields-list{max-width:80%;min-height:60px;display:block;background:#fff;border-radius:4px;overflow:hidden}ajf-fb-node-entry .cdk-drag-placeholder{opacity:0;min-height:60px}ajf-fb-node-entry .ajf-fields-list.cdk-drop-list-dragging .ajf-draggable-box:not(.cdk-drag-placeholder),ajf-fb-node-entry .cdk-drag-animating{transition:transform 250ms cubic-bezier(0, 0, 0.2, 1)}\n"], components: [{ type: AjfFbBranchLine, selector: "ajf-fb-branch-line", inputs: ["offset", "color", "height"] }, { type: i3$3.MatCard, selector: "mat-card", exportAs: ["matCard"] }, { type: i4$2.MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["disabled", "expanded", "hideToggle", "togglePosition"], outputs: ["opened", "closed", "expandedChange", "afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { type: i4$2.MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["tabIndex", "expandedHeight", "collapsedHeight"] }, { type: i4$1.AjfNodeIcon, selector: "ajf-node-icon" }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: AjfFbNodeEntry, selector: "ajf-fb-node-entry", inputs: ["isFirst", "isExpanded", "nodeEntry", "level", "isDraggable", "originOffset", "firstBranchColor"] }], directives: [{ type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i8.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i14.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { type: i14.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { type: i3$3.MatCardTitle, selector: "mat-card-title, [mat-card-title], [matCardTitle]" }], pipes: { "async": i8.AsyncPipe, "transloco": i6$1.TranslocoPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
2578
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFbNodeEntry, decorators: [{
|
|
2562
2579
|
type: Component,
|
|
2563
2580
|
args: [{ selector: 'ajf-fb-node-entry', host: { '(window.resize)': 'onResize()' }, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container *ngIf=\"nodeEntry != null ; else rootEmpty\">\n <ng-template [ngIf]=\"isNodeEntry && !isLastNode()\">\n <ajf-fb-branch-line\n *ngFor=\"let childNodeEntry of realNodeEntry.children; let idx = index\"\n [offset]=\"idx\"\n [color]=\"branchColors[idx]\"\n ></ajf-fb-branch-line>\n </ng-template>\n\n <div\n class=\"mat-card-container\"\n [class.ajf-highlight]=\"(currentEditedNode|async) == nodeEntry\"\n >\n <div\n *ngIf=\"!isFirst\"\n class=\"ajf-origin-line\"\n [style.margin-left]=\"originLeftMargin\"\n [style.border-color]=\"firstBranchColor\"\n ></div>\n <ng-template [ngIf]=\"isNodeEntry\">\n <ng-container *ngIf=\"!isDraggable; else draggable\">\n <mat-card>\n <ng-container *ngTemplateOutlet=\"cardTitle\"></ng-container>\n <ng-container *ngTemplateOutlet=\"cardContent\"></ng-container>\n </mat-card>\n </ng-container>\n\n <ng-template #draggable>\n <mat-card cdkDrag [cdkDragData]=\"realNodeEntry\" class=\"ajf-draggable-box\">\n <ng-container\n *ngIf=\"isSlide(realNodeEntry.node); else fieldPanel\"\n >\n <ng-container *ngTemplateOutlet=\"slidePanel\"></ng-container>\n </ng-container>\n </mat-card>\n </ng-template>\n\n <ng-template #slidePanel>\n <mat-expansion-panel\n [expanded]=\"isExpanded\"\n (opened)=\"isExpanded = true\"\n (closed)=\"isExpanded = false\"\n class=\"mat-elevation-z\"\n >\n <mat-expansion-panel-header>\n <ng-container *ngTemplateOutlet=\"cardTitle\"></ng-container>\n </mat-expansion-panel-header>\n <ng-container *ngTemplateOutlet=\"cardContent\"></ng-container>\n </mat-expansion-panel>\n </ng-template>\n\n <ng-template #fieldPanel>\n <ng-container *ngTemplateOutlet=\"cardTitle\"></ng-container>\n <ng-container *ngTemplateOutlet=\"cardContent\"></ng-container>\n </ng-template>\n\n <ng-template #cardTitle>\n <div class=\"ajf-title-row\">\n <ajf-node-icon [node]=\"realNodeEntry.node\"></ajf-node-icon>\n <span\n class=\"ajf-title\"\n [innerHTML]=\"(realNodeEntry.node.label || realNodeEntry.node.name) | transloco\"\n ></span>\n <span\n *ngIf=\"realNodeEntry.node.visibility && realNodeEntry.node.visibility?.condition !== 'true'\"\n class=\"ajf-visibility-condition\"\n [innerHTML]=\"'Condition: (' + realNodeEntry.node.visibility?.condition + ')'\"\n >\n </span>\n <span class=\"ajf-actions\">\n <button\n [disabled]=\"(currentEditedNode|async) == nodeEntry\"\n (click)=\"edit($event)\"\n mat-icon-button\n >\n <mat-icon>edit</mat-icon>\n </button>\n <button\n [disabled]=\"(currentEditedNode|async) == null\"\n (click)=\"delete($event)\"\n mat-icon-button\n >\n <mat-icon>delete</mat-icon>\n </button>\n </span>\n </div>\n </ng-template>\n\n <ng-template #cardContent>\n <div *ngIf=\"hasContent\">\n <ajf-fb-node-entry\n cdkDropList\n class=\"ajf-fields-list\"\n *ngFor=\"let contentEntry of realNodeEntry.content; let isFirstChild = first; let idx = index\"\n [id]=\"assignId()\"\n [level]=\"level + 1\"\n [isFirst]=\"isFirstChild\"\n [firstBranchColor]=\"branchColors[idx]\"\n [nodeEntry]=\"contentEntry\"\n [cdkDropListEnterPredicate]=\"disableSlideDrop\"\n (cdkDropListDropped)=\"onDrop($event, true)\"\n [isExpanded]=\"isExpanded\"\n ></ajf-fb-node-entry>\n <mat-card\n class=\"ajf-empty\"\n *ngIf=\"realNodeEntry.content.length === 0\"\n cdkDropList\n [id]=\"assignId(true)\"\n [cdkDropListEnterPredicate]=\"disableSlideDrop\"\n (cdkDropListDropped)=\"onDrop($event, true)\"\n ><mat-card-title>Drop your fields here</mat-card-title></mat-card\n >\n </div>\n </ng-template>\n </ng-template>\n </div>\n\n <ng-template [ngIf]=\"isNodeEntry\">\n <ng-container\n *ngFor=\"let childNodeEntry of realNodeEntry.children; let idx = index\"\n >\n <ajf-fb-node-entry\n *ngIf=\"!isLastNode()\"\n [level]=\"level\"\n [originOffset]=\"idx\"\n [firstBranchColor]=\"branchColors[idx]\"\n [nodeEntry]=\"childNodeEntry\"\n [isExpanded]=\"isExpanded\"\n ></ajf-fb-node-entry>\n </ng-container>\n </ng-template>\n</ng-container>\n\n<ng-template #rootEmpty>\n <div class=\"mat-card-container\">\n <mat-card\n class=\"ajf-empty\"\n cdkDropList\n [cdkDropListEnterPredicate]=\"emptyAreaDropPredicate()\"\n (cdkDropListDropped)=\"onDrop($event)\"\n ><mat-card-title>Drop your slides here</mat-card-title>\n </mat-card>\n </div>\n</ng-template>\n", styles: ["ajf-fb-node-entry{display:block;position:relative}ajf-fb-node-entry .mat-card-container{position:relative}ajf-fb-node-entry .mat-card-container .ajf-origin-line{position:absolute;top:0;left:25px;width:25px;height:25px;border-bottom:2px solid;border-left:2px solid;border-bottom-left-radius:.5em}ajf-fb-node-entry .mat-card-container mat-card{margin-left:50px;padding:.5em 1em;margin-top:.2em;margin-bottom:.2em;background-color:#fff}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row{display:flex;flex:1 1 auto;flex-direction:row;align-items:center}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row>.ajf-title{flex:1 1 auto}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row>.ajf-visibility-condition{flex:1 1 auto;font-size:10px;color:#999}ajf-fb-node-entry .mat-card-container mat-card .ajf-title-row>.ajf-actions{flex:0 0 auto;white-space:nowrap}ajf-fb-node-entry .mat-card-container mat-card.ajf-empty{line-height:36px;border:2px dashed;box-shadow:none;box-sizing:border-box;text-align:center;color:#ccc}ajf-fb-node-entry .mat-card-container mat-card.ajf-draggable-box{padding:20px 10px;border-bottom:solid 1px #ccc;border-right:solid 1px #ccc;color:rgba(0,0,0,.87);box-sizing:border-box;cursor:move;background:#fff;font-size:14px}ajf-fb-node-entry .mat-card-container.ajf-highlight>mat-card{background-color:#fff9c4}ajf-fb-node-entry.ajf-fields-list{max-width:80%;min-height:60px;display:block;background:#fff;border-radius:4px;overflow:hidden}ajf-fb-node-entry .cdk-drag-placeholder{opacity:0;min-height:60px}ajf-fb-node-entry .ajf-fields-list.cdk-drop-list-dragging .ajf-draggable-box:not(.cdk-drag-placeholder),ajf-fb-node-entry .cdk-drag-animating{transition:transform 250ms cubic-bezier(0, 0, 0.2, 1)}\n"] }]
|
|
2564
2581
|
}], ctorParameters: function () { return [{ type: AjfFormBuilderService }]; }, propDecorators: { branchLines: [{
|
|
@@ -2601,28 +2618,28 @@ class AjfFormBuilder {
|
|
|
2601
2618
|
this._nodeTypes = _service.availableNodeTypes;
|
|
2602
2619
|
this._nodeEntriesTree = _service.nodeEntriesTree;
|
|
2603
2620
|
this._choicesOrigins = _service.choicesOrigins;
|
|
2604
|
-
this._editConditionSub =
|
|
2605
|
-
this.
|
|
2606
|
-
|
|
2607
|
-
|
|
2608
|
-
|
|
2609
|
-
|
|
2610
|
-
|
|
2611
|
-
|
|
2612
|
-
|
|
2613
|
-
|
|
2614
|
-
|
|
2615
|
-
this._editChoicesOriginSub =
|
|
2616
|
-
this.
|
|
2617
|
-
|
|
2618
|
-
|
|
2619
|
-
|
|
2620
|
-
|
|
2621
|
-
|
|
2622
|
-
|
|
2623
|
-
|
|
2624
|
-
|
|
2625
|
-
|
|
2621
|
+
this._editConditionSub = this._service.editedCondition.subscribe((condition) => {
|
|
2622
|
+
if (this._editConditionDialog != null) {
|
|
2623
|
+
this._editConditionDialog.close();
|
|
2624
|
+
this._editConditionDialog = null;
|
|
2625
|
+
}
|
|
2626
|
+
if (condition != null) {
|
|
2627
|
+
this._editConditionDialog = this._dialog.open(AjfFbConditionEditorDialog, {
|
|
2628
|
+
disableClose: true,
|
|
2629
|
+
});
|
|
2630
|
+
}
|
|
2631
|
+
});
|
|
2632
|
+
this._editChoicesOriginSub = this._service.editedChoicesOrigin.subscribe((choicesOrigin) => {
|
|
2633
|
+
if (this._editChoicesOriginDialog != null) {
|
|
2634
|
+
this._editChoicesOriginDialog.close();
|
|
2635
|
+
this._editChoicesOriginDialog = null;
|
|
2636
|
+
}
|
|
2637
|
+
if (choicesOrigin != null) {
|
|
2638
|
+
this._editChoicesOriginDialog = this._dialog.open(AjfFbChoicesOriginEditorDialog, {
|
|
2639
|
+
disableClose: true,
|
|
2640
|
+
});
|
|
2641
|
+
}
|
|
2642
|
+
});
|
|
2626
2643
|
this._beforeNodesUpdateSub = this._service.beforeNodesUpdate.subscribe(() => {
|
|
2627
2644
|
if (this.designerCont == null) {
|
|
2628
2645
|
return;
|
|
@@ -2702,7 +2719,11 @@ class AjfFormBuilder {
|
|
|
2702
2719
|
this._stringIdentifierDialog.close();
|
|
2703
2720
|
this._stringIdentifierDialog = null;
|
|
2704
2721
|
}
|
|
2705
|
-
this._stringIdentifierDialog = this._dialog.open(AjfFbStringIdentifierDialogComponent, {
|
|
2722
|
+
this._stringIdentifierDialog = this._dialog.open(AjfFbStringIdentifierDialogComponent, {
|
|
2723
|
+
disableClose: true,
|
|
2724
|
+
width: '60%',
|
|
2725
|
+
height: '60%',
|
|
2726
|
+
});
|
|
2706
2727
|
}
|
|
2707
2728
|
expandAll() {
|
|
2708
2729
|
this._globalExpanded = true;
|
|
@@ -2722,9 +2743,9 @@ class AjfFormBuilder {
|
|
|
2722
2743
|
this._service.setForm(this._form);
|
|
2723
2744
|
}
|
|
2724
2745
|
}
|
|
2725
|
-
AjfFormBuilder.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
2726
|
-
AjfFormBuilder.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-
|
|
2727
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
2746
|
+
AjfFormBuilder.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFormBuilder, deps: [{ token: AjfFormBuilderService }, { token: i2$1.MatDialog }], target: i0.ɵɵFactoryTarget.Component });
|
|
2747
|
+
AjfFormBuilder.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: AjfFormBuilder, selector: "ajf-form-builder", inputs: { form: "form" }, viewQueries: [{ propertyName: "designerCont", first: true, predicate: ["designer"], descendants: true, static: true }], ngImport: i0, template: "<mat-toolbar>\n <button mat-icon-button (click)=\"leftSidenav.toggle()\">\n <mat-icon>add_box</mat-icon>\n </button>\n <button mat-button [matMenuTriggerFor]=\"choicesMenu\">\n {{'Choices'|transloco}}\n </button>\n <button mat-button (click)=\"editStringIdentifier()\">\n {{'Identifier'|transloco}}\n </button>\n <button\n mat-icon-button\n aria-label=\"Collapsed\"\n matTooltip=\"Keep slides collapsed\"\n >\n <mat-icon>unfold_less</mat-icon>\n </button>\n <mat-slide-toggle\n color=\"primary\"\n (change)=\"expandToggle($event)\"\n ></mat-slide-toggle>\n <button\n mat-icon-button\n aria-label=\"Expanded\"\n matTooltip=\"Keep slides expanded\"\n >\n <mat-icon>unfold_more</mat-icon>\n </button>\n <mat-menu #choicesMenu>\n <button (click)=\"createChoicesOrigin()\" mat-menu-item>\n {{'New..'|transloco}}\n </button>\n <ng-container *ngIf=\"choicesOrigins|async as cos\">\n <button\n *ngFor=\"let choicesOrigin of cos\"\n (click)=\"editChoicesOrigin(choicesOrigin)\"\n mat-menu-item\n >\n {{ (choicesOrigin.label || choicesOrigin.name)| transloco }}\n </button>\n </ng-container>\n </mat-menu>\n <span class=\"ajf-spacer\"></span>\n <button mat-icon-button (click)=\"rightSidenav.toggle()\">\n <mat-icon>settings</mat-icon>\n </button>\n</mat-toolbar>\n<mat-drawer-container cdkDropListGroup>\n <mat-drawer #leftSidenav position=\"start\" mode=\"over\">\n <div\n #sourceDropList\n cdkDropList\n [cdkDropListConnectedTo]=\"(connectedDropLists|async)!\"\n [cdkDropListEnterPredicate]=\"disableDrop\"\n [cdkDropListData]=\"nodeTypes\"\n >\n <ajf-fb-node-type-entry\n *ngFor=\"let nodeType of nodeTypes\"\n cdkDrag\n [cdkDragData]=\"nodeType\"\n (cdkDragStarted)=\"leftSidenav.close()\"\n [nodeType]=\"nodeType\"\n ></ajf-fb-node-type-entry>\n </div>\n </mat-drawer>\n <mat-drawer #rightSidenav position=\"end\" mode=\"side\" [opened]=\"true\">\n <ajf-fb-node-properties></ajf-fb-node-properties>\n </mat-drawer>\n <div #designer class=\"ajf-designer\">\n <ajf-fb-node-entry\n id=\"slides-list\"\n cdkDropList\n (cdkDropListDropped)=\"onDrop($event)\"\n [cdkDropListEnterPredicate]=\"disableFieldDrop\"\n *ngFor=\"let nodeEntry of (nodeEntriesTree|async); let isFirst = first\"\n [isExpanded]=\"isGlobalExpanded\"\n [isFirst]=\"isFirst\"\n [nodeEntry]=\"nodeEntry\"\n ></ajf-fb-node-entry>\n </div>\n</mat-drawer-container>\n", styles: ["ajf-form-builder{display:flex;position:relative;min-height:300px;flex-direction:column;align-items:stretch}ajf-form-builder mat-toolbar mat-menu div[mat-menu-item]>button[mat-button]{flex:1 0 auto}ajf-form-builder mat-toolbar mat-menu div[mat-menu-item]>button[mat-icon-button]{flex:0 0 auto}ajf-form-builder mat-drawer-container{flex:1}ajf-form-builder mat-drawer-container mat-drawer{max-width:20%}ajf-form-builder mat-drawer-container .ajf-designer{padding:1em}ajf-form-builder mat-toolbar .ajf-spacer{flex:1 1 auto}\n"], components: [{ type: i3$4.MatToolbar, selector: "mat-toolbar", inputs: ["color"], exportAs: ["matToolbar"] }, { type: i2.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i6$4.MatSlideToggle, selector: "mat-slide-toggle", inputs: ["disabled", "disableRipple", "color", "tabIndex", "name", "id", "labelPosition", "aria-label", "aria-labelledby", "aria-describedby", "required", "checked"], outputs: ["change", "toggleChange"], exportAs: ["matSlideToggle"] }, { type: i7$1.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i7$1.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { type: i8$2.MatDrawerContainer, selector: "mat-drawer-container", inputs: ["autosize", "hasBackdrop"], outputs: ["backdropClick"], exportAs: ["matDrawerContainer"] }, { type: i8$2.MatDrawer, selector: "mat-drawer", inputs: ["position", "mode", "disableClose", "autoFocus", "opened"], outputs: ["openedChange", "opened", "openedStart", "closed", "closedStart", "positionChanged"], exportAs: ["matDrawer"] }, { type: AjfFbNodeTypeEntry, selector: "ajf-fb-node-type-entry", inputs: ["nodeType"] }, { type: AjfFbNodeProperties, selector: "ajf-fb-node-properties" }, { type: AjfFbNodeEntry, selector: "ajf-fb-node-entry", inputs: ["isFirst", "isExpanded", "nodeEntry", "level", "isDraggable", "originOffset", "firstBranchColor"] }], directives: [{ type: i7$1.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: i6$2.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i14.CdkDropListGroup, selector: "[cdkDropListGroup]", inputs: ["cdkDropListGroupDisabled"], exportAs: ["cdkDropListGroup"] }, { type: i14.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { type: i14.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }], pipes: { "transloco": i6$1.TranslocoPipe, "async": i8.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
2748
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFormBuilder, decorators: [{
|
|
2728
2749
|
type: Component,
|
|
2729
2750
|
args: [{ selector: 'ajf-form-builder', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<mat-toolbar>\n <button mat-icon-button (click)=\"leftSidenav.toggle()\">\n <mat-icon>add_box</mat-icon>\n </button>\n <button mat-button [matMenuTriggerFor]=\"choicesMenu\">\n {{'Choices'|transloco}}\n </button>\n <button mat-button (click)=\"editStringIdentifier()\">\n {{'Identifier'|transloco}}\n </button>\n <button\n mat-icon-button\n aria-label=\"Collapsed\"\n matTooltip=\"Keep slides collapsed\"\n >\n <mat-icon>unfold_less</mat-icon>\n </button>\n <mat-slide-toggle\n color=\"primary\"\n (change)=\"expandToggle($event)\"\n ></mat-slide-toggle>\n <button\n mat-icon-button\n aria-label=\"Expanded\"\n matTooltip=\"Keep slides expanded\"\n >\n <mat-icon>unfold_more</mat-icon>\n </button>\n <mat-menu #choicesMenu>\n <button (click)=\"createChoicesOrigin()\" mat-menu-item>\n {{'New..'|transloco}}\n </button>\n <ng-container *ngIf=\"choicesOrigins|async as cos\">\n <button\n *ngFor=\"let choicesOrigin of cos\"\n (click)=\"editChoicesOrigin(choicesOrigin)\"\n mat-menu-item\n >\n {{ (choicesOrigin.label || choicesOrigin.name)| transloco }}\n </button>\n </ng-container>\n </mat-menu>\n <span class=\"ajf-spacer\"></span>\n <button mat-icon-button (click)=\"rightSidenav.toggle()\">\n <mat-icon>settings</mat-icon>\n </button>\n</mat-toolbar>\n<mat-drawer-container cdkDropListGroup>\n <mat-drawer #leftSidenav position=\"start\" mode=\"over\">\n <div\n #sourceDropList\n cdkDropList\n [cdkDropListConnectedTo]=\"(connectedDropLists|async)!\"\n [cdkDropListEnterPredicate]=\"disableDrop\"\n [cdkDropListData]=\"nodeTypes\"\n >\n <ajf-fb-node-type-entry\n *ngFor=\"let nodeType of nodeTypes\"\n cdkDrag\n [cdkDragData]=\"nodeType\"\n (cdkDragStarted)=\"leftSidenav.close()\"\n [nodeType]=\"nodeType\"\n ></ajf-fb-node-type-entry>\n </div>\n </mat-drawer>\n <mat-drawer #rightSidenav position=\"end\" mode=\"side\" [opened]=\"true\">\n <ajf-fb-node-properties></ajf-fb-node-properties>\n </mat-drawer>\n <div #designer class=\"ajf-designer\">\n <ajf-fb-node-entry\n id=\"slides-list\"\n cdkDropList\n (cdkDropListDropped)=\"onDrop($event)\"\n [cdkDropListEnterPredicate]=\"disableFieldDrop\"\n *ngFor=\"let nodeEntry of (nodeEntriesTree|async); let isFirst = first\"\n [isExpanded]=\"isGlobalExpanded\"\n [isFirst]=\"isFirst\"\n [nodeEntry]=\"nodeEntry\"\n ></ajf-fb-node-entry>\n </div>\n</mat-drawer-container>\n", styles: ["ajf-form-builder{display:flex;position:relative;min-height:300px;flex-direction:column;align-items:stretch}ajf-form-builder mat-toolbar mat-menu div[mat-menu-item]>button[mat-button]{flex:1 0 auto}ajf-form-builder mat-toolbar mat-menu div[mat-menu-item]>button[mat-icon-button]{flex:0 0 auto}ajf-form-builder mat-drawer-container{flex:1}ajf-form-builder mat-drawer-container mat-drawer{max-width:20%}ajf-form-builder mat-drawer-container .ajf-designer{padding:1em}ajf-form-builder mat-toolbar .ajf-spacer{flex:1 1 auto}\n"] }]
|
|
2730
2751
|
}], ctorParameters: function () { return [{ type: AjfFormBuilderService }, { type: i2$1.MatDialog }]; }, propDecorators: { designerCont: [{
|
|
@@ -2757,8 +2778,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-next.15",
|
|
|
2757
2778
|
*/
|
|
2758
2779
|
class AjfFormBuilderModule {
|
|
2759
2780
|
}
|
|
2760
|
-
AjfFormBuilderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-
|
|
2761
|
-
AjfFormBuilderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.0.0-
|
|
2781
|
+
AjfFormBuilderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFormBuilderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
2782
|
+
AjfFormBuilderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFormBuilderModule, declarations: [AjfFbBranchLine,
|
|
2762
2783
|
AjfFbChoicesOriginEditor,
|
|
2763
2784
|
AjfFbChoicesOriginEditorDialog,
|
|
2764
2785
|
AjfFbConditionEditor,
|
|
@@ -2769,35 +2790,90 @@ AjfFormBuilderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", ve
|
|
|
2769
2790
|
AjfFbStringIdentifierDialogComponent,
|
|
2770
2791
|
AjfFbValidationConditionEditorDialog,
|
|
2771
2792
|
AjfFbWarningConditionEditorDialog,
|
|
2772
|
-
AjfFormBuilder], imports: [AjfMonacoEditorModule,
|
|
2773
|
-
|
|
2774
|
-
|
|
2775
|
-
|
|
2776
|
-
|
|
2777
|
-
|
|
2778
|
-
|
|
2779
|
-
|
|
2780
|
-
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2793
|
+
AjfFormBuilder], imports: [AjfMonacoEditorModule,
|
|
2794
|
+
AjfNodeIconModule,
|
|
2795
|
+
CommonModule,
|
|
2796
|
+
DragDropModule,
|
|
2797
|
+
FormsModule,
|
|
2798
|
+
MatAutocompleteModule,
|
|
2799
|
+
MatButtonModule,
|
|
2800
|
+
MatCardModule,
|
|
2801
|
+
MatCheckboxModule,
|
|
2802
|
+
MatChipsModule,
|
|
2803
|
+
MatDialogModule,
|
|
2804
|
+
MatFormFieldModule,
|
|
2805
|
+
MatIconModule,
|
|
2806
|
+
MatInputModule,
|
|
2807
|
+
MatListModule,
|
|
2808
|
+
MatMenuModule,
|
|
2809
|
+
MatSelectModule,
|
|
2810
|
+
MatSidenavModule,
|
|
2811
|
+
MatSliderModule,
|
|
2812
|
+
MatTableModule,
|
|
2813
|
+
MatToolbarModule,
|
|
2814
|
+
MatTooltipModule,
|
|
2815
|
+
ReactiveFormsModule,
|
|
2816
|
+
AjfTranslocoModule,
|
|
2817
|
+
MatExpansionModule,
|
|
2818
|
+
MatSlideToggleModule], exports: [AjfFormBuilder] });
|
|
2819
|
+
AjfFormBuilderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFormBuilderModule, providers: [AjfFormBuilderService], imports: [[
|
|
2820
|
+
AjfMonacoEditorModule,
|
|
2821
|
+
AjfNodeIconModule,
|
|
2822
|
+
CommonModule,
|
|
2823
|
+
DragDropModule,
|
|
2824
|
+
FormsModule,
|
|
2825
|
+
MatAutocompleteModule,
|
|
2826
|
+
MatButtonModule,
|
|
2827
|
+
MatCardModule,
|
|
2828
|
+
MatCheckboxModule,
|
|
2829
|
+
MatChipsModule,
|
|
2830
|
+
MatDialogModule,
|
|
2831
|
+
MatFormFieldModule,
|
|
2832
|
+
MatIconModule,
|
|
2833
|
+
MatInputModule,
|
|
2834
|
+
MatListModule,
|
|
2835
|
+
MatMenuModule,
|
|
2836
|
+
MatSelectModule,
|
|
2837
|
+
MatSidenavModule,
|
|
2838
|
+
MatSliderModule,
|
|
2839
|
+
MatTableModule,
|
|
2840
|
+
MatToolbarModule,
|
|
2841
|
+
MatTooltipModule,
|
|
2842
|
+
ReactiveFormsModule,
|
|
2843
|
+
AjfTranslocoModule,
|
|
2844
|
+
MatExpansionModule,
|
|
2845
|
+
MatSlideToggleModule,
|
|
2789
2846
|
]] });
|
|
2790
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-
|
|
2847
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: AjfFormBuilderModule, decorators: [{
|
|
2791
2848
|
type: NgModule,
|
|
2792
2849
|
args: [{
|
|
2793
2850
|
imports: [
|
|
2794
|
-
AjfMonacoEditorModule,
|
|
2795
|
-
|
|
2796
|
-
|
|
2797
|
-
|
|
2798
|
-
|
|
2799
|
-
|
|
2800
|
-
|
|
2851
|
+
AjfMonacoEditorModule,
|
|
2852
|
+
AjfNodeIconModule,
|
|
2853
|
+
CommonModule,
|
|
2854
|
+
DragDropModule,
|
|
2855
|
+
FormsModule,
|
|
2856
|
+
MatAutocompleteModule,
|
|
2857
|
+
MatButtonModule,
|
|
2858
|
+
MatCardModule,
|
|
2859
|
+
MatCheckboxModule,
|
|
2860
|
+
MatChipsModule,
|
|
2861
|
+
MatDialogModule,
|
|
2862
|
+
MatFormFieldModule,
|
|
2863
|
+
MatIconModule,
|
|
2864
|
+
MatInputModule,
|
|
2865
|
+
MatListModule,
|
|
2866
|
+
MatMenuModule,
|
|
2867
|
+
MatSelectModule,
|
|
2868
|
+
MatSidenavModule,
|
|
2869
|
+
MatSliderModule,
|
|
2870
|
+
MatTableModule,
|
|
2871
|
+
MatToolbarModule,
|
|
2872
|
+
MatTooltipModule,
|
|
2873
|
+
ReactiveFormsModule,
|
|
2874
|
+
AjfTranslocoModule,
|
|
2875
|
+
MatExpansionModule,
|
|
2876
|
+
MatSlideToggleModule,
|
|
2801
2877
|
],
|
|
2802
2878
|
declarations: [
|
|
2803
2879
|
AjfFbBranchLine,
|
|
@@ -2813,12 +2889,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-next.15",
|
|
|
2813
2889
|
AjfFbWarningConditionEditorDialog,
|
|
2814
2890
|
AjfFormBuilder,
|
|
2815
2891
|
],
|
|
2816
|
-
exports: [
|
|
2817
|
-
|
|
2818
|
-
],
|
|
2819
|
-
providers: [
|
|
2820
|
-
AjfFormBuilderService,
|
|
2821
|
-
],
|
|
2892
|
+
exports: [AjfFormBuilder],
|
|
2893
|
+
providers: [AjfFormBuilderService],
|
|
2822
2894
|
}]
|
|
2823
2895
|
}] });
|
|
2824
2896
|
|
|
@@ -2844,6 +2916,28 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-next.15",
|
|
|
2844
2916
|
*
|
|
2845
2917
|
*/
|
|
2846
2918
|
|
|
2919
|
+
/**
|
|
2920
|
+
* @license
|
|
2921
|
+
* Copyright (C) Gnucoop soc. coop.
|
|
2922
|
+
*
|
|
2923
|
+
* This file is part of the Advanced JSON forms (ajf).
|
|
2924
|
+
*
|
|
2925
|
+
* Advanced JSON forms (ajf) is free software: you can redistribute it and/or
|
|
2926
|
+
* modify it under the terms of the GNU Affero General Public License as
|
|
2927
|
+
* published by the Free Software Foundation, either version 3 of the License,
|
|
2928
|
+
* or (at your option) any later version.
|
|
2929
|
+
*
|
|
2930
|
+
* Advanced JSON forms (ajf) is distributed in the hope that it will be useful,
|
|
2931
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2932
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero
|
|
2933
|
+
* General Public License for more details.
|
|
2934
|
+
*
|
|
2935
|
+
* You should have received a copy of the GNU Affero General Public License
|
|
2936
|
+
* along with Advanced JSON forms (ajf).
|
|
2937
|
+
* If not, see http://www.gnu.org/licenses/.
|
|
2938
|
+
*
|
|
2939
|
+
*/
|
|
2940
|
+
|
|
2847
2941
|
/**
|
|
2848
2942
|
* Generated bundle index. Do not edit.
|
|
2849
2943
|
*/
|