nuxeo-development-framework 0.0.17-bos → 0.0.18-bos

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.
@@ -90,7 +90,7 @@ import * as i3$6 from 'legacy-angular-formio';
90
90
  import { Components, FormBuilderComponent, registerCustomFormioComponent, FormioModule, FormioUtils } from 'legacy-angular-formio';
91
91
  import * as i1$9 from '@ng-bootstrap/ng-bootstrap';
92
92
  import { NgbDate, NgbDatepickerI18n, NgbCalendarIslamicUmalqura, NgbCalendar, NgbDateParserFormatter, NgbDatepickerModule } from '@ng-bootstrap/ng-bootstrap';
93
- import { Utils, Formio } from 'formiojs';
93
+ import { Formio, Utils } from 'formiojs';
94
94
  import _find from 'lodash/find';
95
95
  import _isEqual from 'lodash/isEqual';
96
96
  import * as i6$1 from '@swimlane/ngx-datatable';
@@ -11104,6 +11104,20 @@ const baseEditForm = (...extend) => {
11104
11104
  };
11105
11105
  };
11106
11106
 
11107
+ let formioEvaluatorPolicyApplied = false;
11108
+ function applyFormioEvaluatorPolicy() {
11109
+ if (formioEvaluatorPolicyApplied) {
11110
+ return;
11111
+ }
11112
+ if (isFormIOEvalDenied() && Formio.Evaluator) {
11113
+ Formio.Evaluator.noeval = true;
11114
+ }
11115
+ formioEvaluatorPolicyApplied = true;
11116
+ }
11117
+ function isFormIOEvalDenied() {
11118
+ return EnvManager.environment.denyFormIoUseEval === 'YES';
11119
+ }
11120
+
11107
11121
  class DynamicFormBuilderComponent {
11108
11122
  constructor() {
11109
11123
  this.form = {};
@@ -11169,6 +11183,7 @@ class DynamicFormBuilderComponent {
11169
11183
  this.deletedComponents = {};
11170
11184
  // tslint:disable-next-line:variable-name
11171
11185
  this._form = {};
11186
+ this.isFormIOEvalDenied = isFormIOEvalDenied();
11172
11187
  const numberEditForm = Components.components.number.editForm();
11173
11188
  const textEditForm = Components.components.textfield.editForm();
11174
11189
  textEditForm.components[0].components[1].components = textEditForm.components[0].components[1].components.filter((item) => !['persistent', 'protected', 'dbIndex', 'encrypted', 'calculateServer'].includes(item.key));
@@ -11239,11 +11254,11 @@ class DynamicFormBuilderComponent {
11239
11254
  }
11240
11255
  }
11241
11256
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.21", ngImport: i0, type: DynamicFormBuilderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
11242
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.21", type: DynamicFormBuilderComponent, isStandalone: false, selector: "app-dynamic-form-builder", inputs: { form: "form", builder: "builder", builderComponents: "builderComponents" }, outputs: { formUpdated: "formUpdated" }, viewQueries: [{ propertyName: "jsonElement", first: true, predicate: ["json"], descendants: true }, { propertyName: "FormBuilderComponent", first: true, predicate: FormBuilderComponent, descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"container-fluid\" dir=\"ltr\">\r\n <form-builder [form]=\"form\" [options]=\"builderOptions\" [rebuild]=\"refresher\" (change)=\"onChange($event)\"></form-builder>\r\n <!-- <button class=\"save-form\" (click)=\"save()\">SAVE</button> -->\r\n <div class=\"mx-2 save-form\">\r\n <cts-button\r\n [loading]=\"saving\"\r\n [theme]=\"'primary'\"\r\n [size]=\"'regular'\"\r\n (onClick)=\"save()\"\r\n \r\n >\r\n {{ \"BUTTONS.SAVE\" | translate }}\r\n </cts-button>\r\n </div>\r\n</div>\r\n", styles: [".formio-dialog{direction:ltr;text-align:left}.formio-dialog .card-title{border:0px!important}.builder{text-align:left}.builder div[ref=copyComponent],.builder div[ref=pasteComponent],.builder div[ref=editJson]{display:none;visibility:hidden}.builder .formarea{flex:0 0 75%}.builder .formarea .formio-component .formio-form .builder-component .form-group label{color:#646f85;font-size:13px}.builder .formarea .formio-component .formio-form .builder-component .form-group input{border:1px solid #ccc;border-radius:5px;background-color:#8f98aa1a;height:40px}.builder .formarea .formio-component .formio-form .builder-component .formio-component-vocabulary input{border:none;background:no-repeat;height:40px}.builder .formcomponents{flex:0 0 25%;max-width:25%}.builder .formcomponents .builder-sidebar .form-builder-panel .show .card-body{width:80%}.builder .formcomponents .builder-sidebar .form-builder-panel .show .card-body .formcomponent{width:100%;overflow:hidden;white-space:nowrap!important;text-overflow:ellipsis}.container-fluid .save-form{margin-top:15px;width:200px}\n"], dependencies: [{ kind: "component", type: ButtonComponent, selector: "cts-button", inputs: ["disabled", "loading", "size", "theme", "spinnerTheming"], outputs: ["onClick"] }, { kind: "directive", type: i2$1.Dir, selector: "[dir]", inputs: ["dir"], outputs: ["dirChange"], exportAs: ["dir"] }, { kind: "component", type: i3$6.FormBuilderComponent, selector: "form-builder", inputs: ["form", "options", "formbuilder", "noeval", "refresh", "rebuild"], outputs: ["change"] }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }], encapsulation: i0.ViewEncapsulation.None }); }
11257
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.21", type: DynamicFormBuilderComponent, isStandalone: false, selector: "app-dynamic-form-builder", inputs: { form: "form", builder: "builder", builderComponents: "builderComponents" }, outputs: { formUpdated: "formUpdated" }, viewQueries: [{ propertyName: "jsonElement", first: true, predicate: ["json"], descendants: true }, { propertyName: "FormBuilderComponent", first: true, predicate: FormBuilderComponent, descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"container-fluid\" dir=\"ltr\">\r\n <form-builder\r\n [form]=\"form\"\r\n [options]=\"builderOptions\"\r\n [rebuild]=\"refresher\"\r\n (change)=\"onChange($event)\"\r\n\t\t[noeval]=\"isFormIOEvalDenied\"\r\n ></form-builder>\r\n <!-- <button class=\"save-form\" (click)=\"save()\">SAVE</button> -->\r\n <div class=\"mx-2 save-form\">\r\n <cts-button\r\n [loading]=\"saving\"\r\n [theme]=\"'primary'\"\r\n [size]=\"'regular'\"\r\n (onClick)=\"save()\"\r\n >\r\n {{ \"BUTTONS.SAVE\" | translate }}\r\n </cts-button>\r\n </div>\r\n</div>\r\n", styles: [".formio-dialog{direction:ltr;text-align:left}.formio-dialog .card-title{border:0px!important}.builder{text-align:left}.builder div[ref=copyComponent],.builder div[ref=pasteComponent],.builder div[ref=editJson]{display:none;visibility:hidden}.builder .formarea{flex:0 0 75%}.builder .formarea .formio-component .formio-form .builder-component .form-group label{color:#646f85;font-size:13px}.builder .formarea .formio-component .formio-form .builder-component .form-group input{border:1px solid #ccc;border-radius:5px;background-color:#8f98aa1a;height:40px}.builder .formarea .formio-component .formio-form .builder-component .formio-component-vocabulary input{border:none;background:no-repeat;height:40px}.builder .formcomponents{flex:0 0 25%;max-width:25%}.builder .formcomponents .builder-sidebar .form-builder-panel .show .card-body{width:80%}.builder .formcomponents .builder-sidebar .form-builder-panel .show .card-body .formcomponent{width:100%;overflow:hidden;white-space:nowrap!important;text-overflow:ellipsis}.container-fluid .save-form{margin-top:15px;width:200px}\n"], dependencies: [{ kind: "component", type: ButtonComponent, selector: "cts-button", inputs: ["disabled", "loading", "size", "theme", "spinnerTheming"], outputs: ["onClick"] }, { kind: "directive", type: i2$1.Dir, selector: "[dir]", inputs: ["dir"], outputs: ["dirChange"], exportAs: ["dir"] }, { kind: "component", type: i3$6.FormBuilderComponent, selector: "form-builder", inputs: ["form", "options", "formbuilder", "noeval", "refresh", "rebuild"], outputs: ["change"] }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }], encapsulation: i0.ViewEncapsulation.None }); }
11243
11258
  }
11244
11259
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.21", ngImport: i0, type: DynamicFormBuilderComponent, decorators: [{
11245
11260
  type: Component,
11246
- args: [{ selector: 'app-dynamic-form-builder', encapsulation: ViewEncapsulation.None, standalone: false, template: "<div class=\"container-fluid\" dir=\"ltr\">\r\n <form-builder [form]=\"form\" [options]=\"builderOptions\" [rebuild]=\"refresher\" (change)=\"onChange($event)\"></form-builder>\r\n <!-- <button class=\"save-form\" (click)=\"save()\">SAVE</button> -->\r\n <div class=\"mx-2 save-form\">\r\n <cts-button\r\n [loading]=\"saving\"\r\n [theme]=\"'primary'\"\r\n [size]=\"'regular'\"\r\n (onClick)=\"save()\"\r\n \r\n >\r\n {{ \"BUTTONS.SAVE\" | translate }}\r\n </cts-button>\r\n </div>\r\n</div>\r\n", styles: [".formio-dialog{direction:ltr;text-align:left}.formio-dialog .card-title{border:0px!important}.builder{text-align:left}.builder div[ref=copyComponent],.builder div[ref=pasteComponent],.builder div[ref=editJson]{display:none;visibility:hidden}.builder .formarea{flex:0 0 75%}.builder .formarea .formio-component .formio-form .builder-component .form-group label{color:#646f85;font-size:13px}.builder .formarea .formio-component .formio-form .builder-component .form-group input{border:1px solid #ccc;border-radius:5px;background-color:#8f98aa1a;height:40px}.builder .formarea .formio-component .formio-form .builder-component .formio-component-vocabulary input{border:none;background:no-repeat;height:40px}.builder .formcomponents{flex:0 0 25%;max-width:25%}.builder .formcomponents .builder-sidebar .form-builder-panel .show .card-body{width:80%}.builder .formcomponents .builder-sidebar .form-builder-panel .show .card-body .formcomponent{width:100%;overflow:hidden;white-space:nowrap!important;text-overflow:ellipsis}.container-fluid .save-form{margin-top:15px;width:200px}\n"] }]
11261
+ args: [{ selector: 'app-dynamic-form-builder', encapsulation: ViewEncapsulation.None, standalone: false, template: "<div class=\"container-fluid\" dir=\"ltr\">\r\n <form-builder\r\n [form]=\"form\"\r\n [options]=\"builderOptions\"\r\n [rebuild]=\"refresher\"\r\n (change)=\"onChange($event)\"\r\n\t\t[noeval]=\"isFormIOEvalDenied\"\r\n ></form-builder>\r\n <!-- <button class=\"save-form\" (click)=\"save()\">SAVE</button> -->\r\n <div class=\"mx-2 save-form\">\r\n <cts-button\r\n [loading]=\"saving\"\r\n [theme]=\"'primary'\"\r\n [size]=\"'regular'\"\r\n (onClick)=\"save()\"\r\n >\r\n {{ \"BUTTONS.SAVE\" | translate }}\r\n </cts-button>\r\n </div>\r\n</div>\r\n", styles: [".formio-dialog{direction:ltr;text-align:left}.formio-dialog .card-title{border:0px!important}.builder{text-align:left}.builder div[ref=copyComponent],.builder div[ref=pasteComponent],.builder div[ref=editJson]{display:none;visibility:hidden}.builder .formarea{flex:0 0 75%}.builder .formarea .formio-component .formio-form .builder-component .form-group label{color:#646f85;font-size:13px}.builder .formarea .formio-component .formio-form .builder-component .form-group input{border:1px solid #ccc;border-radius:5px;background-color:#8f98aa1a;height:40px}.builder .formarea .formio-component .formio-form .builder-component .formio-component-vocabulary input{border:none;background:no-repeat;height:40px}.builder .formcomponents{flex:0 0 25%;max-width:25%}.builder .formcomponents .builder-sidebar .form-builder-panel .show .card-body{width:80%}.builder .formcomponents .builder-sidebar .form-builder-panel .show .card-body .formcomponent{width:100%;overflow:hidden;white-space:nowrap!important;text-overflow:ellipsis}.container-fluid .save-form{margin-top:15px;width:200px}\n"] }]
11247
11262
  }], ctorParameters: () => [], propDecorators: { jsonElement: [{
11248
11263
  type: ViewChild,
11249
11264
  args: ['json']