@smartbit4all/ng-client 4.1.40 → 4.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (115) hide show
  1. package/esm2022/lib/smart-client/smart-component-api-client.mjs +1 -1
  2. package/esm2022/lib/smart-client/smart.component.mjs +1 -1
  3. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionBoolOperator.mjs +1 -1
  4. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionBuilderField.mjs +1 -1
  5. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionBuilderGroup.mjs +1 -1
  6. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionBuilderModel.mjs +1 -1
  7. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionData.mjs +1 -1
  8. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionDataType.mjs +1 -1
  9. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionField.mjs +1 -1
  10. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionFieldList.mjs +1 -1
  11. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionFieldWidgetType.mjs +1 -1
  12. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionList.mjs +1 -1
  13. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionOperandData.mjs +1 -1
  14. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionOperation.mjs +1 -1
  15. package/esm2022/lib/smart-filter/api/filter/model/filterExpressionOrderBy.mjs +1 -1
  16. package/esm2022/lib/smart-filter-editor/api/api/filter.service.mjs +1 -1
  17. package/esm2022/lib/smart-filter-editor/api/configuration.mjs +1 -1
  18. package/esm2022/lib/smart-filter-editor/api/encoder.mjs +1 -1
  19. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionBoolOperator.mjs +1 -1
  20. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionBuilderApiConfig.mjs +1 -1
  21. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionBuilderField.mjs +1 -1
  22. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionBuilderGroup.mjs +1 -1
  23. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionBuilderModel.mjs +1 -1
  24. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionBuilderUiModel.mjs +1 -1
  25. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionData.mjs +1 -1
  26. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionDataType.mjs +1 -1
  27. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionField.mjs +1 -1
  28. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionFieldEditor.mjs +1 -1
  29. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionFieldList.mjs +1 -1
  30. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionFieldWidgetType.mjs +1 -1
  31. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionList.mjs +1 -1
  32. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionOperandData.mjs +1 -1
  33. package/esm2022/lib/smart-filter-editor/api/model/filterExpressionOperation.mjs +1 -1
  34. package/esm2022/lib/smart-filter-editor/api/model/smartFilterType.mjs +1 -1
  35. package/esm2022/lib/smart-filter-editor/api/param.mjs +1 -1
  36. package/esm2022/lib/smart-filter-editor/api/variables.mjs +1 -1
  37. package/esm2022/lib/smart-filter-editor/smart-filter-editor-content/smart-filter-editor-content.component.mjs +3 -3
  38. package/esm2022/lib/smart-form/api/api/api.mjs +1 -1
  39. package/esm2022/lib/smart-form/api/api/default.service.mjs +1 -1
  40. package/esm2022/lib/smart-form/api/api.module.mjs +1 -1
  41. package/esm2022/lib/smart-form/api/configuration.mjs +1 -1
  42. package/esm2022/lib/smart-form/api/encoder.mjs +1 -1
  43. package/esm2022/lib/smart-form/api/index.mjs +1 -1
  44. package/esm2022/lib/smart-form/api/model/models.mjs +1 -1
  45. package/esm2022/lib/smart-form/api/model/propertyMapping.mjs +1 -1
  46. package/esm2022/lib/smart-form/api/model/selectionDefinition.mjs +1 -1
  47. package/esm2022/lib/smart-form/api/model/smartFormInputMode.mjs +1 -1
  48. package/esm2022/lib/smart-form/api/model/smartFormWidgetDirection.mjs +1 -1
  49. package/esm2022/lib/smart-form/api/model/smartFormWidgetType.mjs +1 -1
  50. package/esm2022/lib/smart-form/api/model/smartLayoutDefinition.mjs +1 -1
  51. package/esm2022/lib/smart-form/api/model/smartMatrixModel.mjs +1 -1
  52. package/esm2022/lib/smart-form/api/model/smartWidgetDefinition.mjs +1 -1
  53. package/esm2022/lib/smart-form/api/model/smartWidgetHint.mjs +1 -1
  54. package/esm2022/lib/smart-form/api/model/valueChangeMode.mjs +1 -1
  55. package/esm2022/lib/smart-form/api/param.mjs +1 -1
  56. package/esm2022/lib/smart-form/api/variables.mjs +1 -1
  57. package/esm2022/lib/smart-form/services/smartform.service.mjs +11 -6
  58. package/esm2022/lib/smart-form/smartform.form-model.mjs +1 -1
  59. package/esm2022/lib/smart-form/smartform.model.mjs +1 -1
  60. package/esm2022/lib/smart-grid/api/grid-api/api/api.mjs +1 -1
  61. package/esm2022/lib/smart-grid/api/grid-api/api/grid.service.mjs +1 -1
  62. package/esm2022/lib/smart-grid/api/grid-api/api.module.mjs +1 -1
  63. package/esm2022/lib/smart-grid/api/grid-api/configuration.mjs +1 -1
  64. package/esm2022/lib/smart-grid/api/grid-api/encoder.mjs +1 -1
  65. package/esm2022/lib/smart-grid/api/grid-api/index.mjs +1 -1
  66. package/esm2022/lib/smart-grid/api/grid-api/model/gridColumnContentType.mjs +1 -1
  67. package/esm2022/lib/smart-grid/api/grid-api/model/gridColumnMeta.mjs +1 -1
  68. package/esm2022/lib/smart-grid/api/grid-api/model/gridDataAccessConfig.mjs +1 -1
  69. package/esm2022/lib/smart-grid/api/grid-api/model/gridModel.mjs +1 -1
  70. package/esm2022/lib/smart-grid/api/grid-api/model/gridPage.mjs +1 -1
  71. package/esm2022/lib/smart-grid/api/grid-api/model/gridRow.mjs +1 -1
  72. package/esm2022/lib/smart-grid/api/grid-api/model/gridSelectionChange.mjs +1 -1
  73. package/esm2022/lib/smart-grid/api/grid-api/model/gridSelectionMode.mjs +1 -1
  74. package/esm2022/lib/smart-grid/api/grid-api/model/gridSelectionType.mjs +1 -1
  75. package/esm2022/lib/smart-grid/api/grid-api/model/gridServerModel.mjs +1 -1
  76. package/esm2022/lib/smart-grid/api/grid-api/model/gridUpdateData.mjs +1 -1
  77. package/esm2022/lib/smart-grid/api/grid-api/model/gridView.mjs +1 -1
  78. package/esm2022/lib/smart-grid/api/grid-api/model/gridViewDescriptor.mjs +1 -1
  79. package/esm2022/lib/smart-grid/api/grid-api/model/models.mjs +1 -1
  80. package/esm2022/lib/smart-grid/api/grid-api/param.mjs +1 -1
  81. package/esm2022/lib/smart-grid/api/grid-api/variables.mjs +1 -1
  82. package/esm2022/lib/smart-map/abstract-map.mjs +1 -1
  83. package/esm2022/lib/smart-map/api/api/geoMap.service.mjs +1 -1
  84. package/esm2022/lib/smart-map/api/model/geoMapDataSourceDescriptor.mjs +1 -1
  85. package/esm2022/lib/smart-map/api/model/geoMapDataSourceType.mjs +1 -1
  86. package/esm2022/lib/smart-map/impl/google-map.mjs +1 -1
  87. package/esm2022/lib/smart-map/impl/leaflet-map.mjs +1 -1
  88. package/esm2022/lib/smart-map/projects.mjs +1 -1
  89. package/esm2022/lib/smart-map/smart-map.component.mjs +1 -1
  90. package/esm2022/lib/smart-map/smart-map.module.mjs +1 -1
  91. package/esm2022/lib/smart-map/smart-map.types.mjs +1 -1
  92. package/esm2022/lib/smart-validation/named-validator.service.mjs +115 -0
  93. package/esm2022/lib/smart-validation/projects.mjs +4 -0
  94. package/esm2022/lib/smart-validation/smart-validation.module.mjs +24 -0
  95. package/esm2022/lib/smart-validation/smart-validation.types.mjs +4 -0
  96. package/esm2022/lib/view-context/api/model/componentConstraint.mjs +1 -1
  97. package/esm2022/lib/view-context/api/model/models.mjs +2 -1
  98. package/esm2022/lib/view-context/api/model/namedValidator.mjs +19 -0
  99. package/esm2022/projects.mjs +2 -1
  100. package/fesm2022/smartbit4all-ng-client.mjs +165 -8
  101. package/fesm2022/smartbit4all-ng-client.mjs.map +1 -1
  102. package/lib/smart-form/services/smartform.service.d.ts +4 -1
  103. package/lib/smart-form/smartform.form-model.d.ts +2 -2
  104. package/lib/smart-form/smartform.model.d.ts +11 -5
  105. package/lib/smart-validation/named-validator.service.d.ts +17 -0
  106. package/lib/smart-validation/projects.d.ts +3 -0
  107. package/lib/smart-validation/smart-validation.module.d.ts +8 -0
  108. package/lib/smart-validation/smart-validation.types.d.ts +12 -0
  109. package/lib/view-context/api/model/componentConstraint.d.ts +6 -0
  110. package/lib/view-context/api/model/models.d.ts +1 -0
  111. package/lib/view-context/api/model/namedValidator.d.ts +26 -0
  112. package/package.json +1 -1
  113. package/projects.d.ts +1 -0
  114. package/smartbit4all-ng-client-4.2.0.tgz +0 -0
  115. package/smartbit4all-ng-client-4.1.40.tgz +0 -0
@@ -26,7 +26,7 @@ import * as i3$3 from '@angular/material/expansion';
26
26
  import { MatExpansionModule } from '@angular/material/expansion';
27
27
  import { __decorate, __param } from 'tslib';
28
28
  import * as i10 from '@angular/forms';
29
- import { UntypedFormGroup, UntypedFormControl, Validators, NG_VALUE_ACCESSOR, FormsModule, ReactiveFormsModule } from '@angular/forms';
29
+ import { Validators, UntypedFormGroup, UntypedFormControl, NG_VALUE_ACCESSOR, FormsModule, ReactiveFormsModule } from '@angular/forms';
30
30
  import { ENTER, COMMA } from '@angular/cdk/keycodes';
31
31
  import { deepEqual } from 'fast-equals';
32
32
  import moment from 'moment';
@@ -2272,6 +2272,25 @@ var MessageType;
2272
2272
  MessageType["ERROR"] = "error";
2273
2273
  })(MessageType || (MessageType = {}));
2274
2274
 
2275
+ /**
2276
+ * View API
2277
+ * View API
2278
+ *
2279
+ * The version of the OpenAPI document: 1.0.0
2280
+ * Contact: info@it4all.hu
2281
+ *
2282
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
2283
+ * https://openapi-generator.tech
2284
+ * Do not edit the class manually.
2285
+ */
2286
+ var NamedValidatorOperationEnum;
2287
+ (function (NamedValidatorOperationEnum) {
2288
+ NamedValidatorOperationEnum["ADD"] = "ADD";
2289
+ NamedValidatorOperationEnum["REMOVE"] = "REMOVE";
2290
+ NamedValidatorOperationEnum["ALTER"] = "ALTER";
2291
+ })(NamedValidatorOperationEnum || (NamedValidatorOperationEnum = {}));
2292
+ ;
2293
+
2275
2294
  /**
2276
2295
  * View API
2277
2296
  * View API
@@ -4045,8 +4064,122 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImpo
4045
4064
  type: Optional
4046
4065
  }] }] });
4047
4066
 
4067
+ const EMPTY_PARAMS = {};
4068
+ const NAMED_VALIDATOR = new InjectionToken('Named validator factory');
4069
+
4070
+ const VALIDATOR_NAME_MAX = 'max';
4071
+ const VALIDATOR_NAME_MIN = 'min';
4072
+ const VALIDATOR_NAME_MAX_LEN = 'maxLength';
4073
+ const VALIDATOR_NAME_MIN_LEN = 'minLength';
4074
+ class NamedValidatorService {
4075
+ constructor(factories) {
4076
+ console.log(factories);
4077
+ this.factories = factories ? new Map(factories.map((it) => [it.name, it])) : new Map();
4078
+ }
4079
+ applyConstraint(w, c) {
4080
+ if (!w.validators) {
4081
+ w.validators = [];
4082
+ }
4083
+ this.applyBuiltInValidators(w, c);
4084
+ if (c.namedValidators) {
4085
+ this.applyNamedValidators(w, c.namedValidators);
4086
+ }
4087
+ }
4088
+ // TODO: this looks horrific, refactor!
4089
+ applyBuiltInValidators(w, c) {
4090
+ if (c.max) {
4091
+ w.validators = w.validators.filter((it) => it.name !== VALIDATOR_NAME_MAX);
4092
+ if (c.max > 0) {
4093
+ w.validators.push({
4094
+ name: VALIDATOR_NAME_MAX,
4095
+ validator: Validators.max(c.max),
4096
+ isCustom: false,
4097
+ errorMessage: '',
4098
+ });
4099
+ }
4100
+ }
4101
+ if (c.min) {
4102
+ w.validators = w.validators.filter((it) => it.name !== VALIDATOR_NAME_MIN);
4103
+ if (c.min > 0) {
4104
+ w.validators.push({
4105
+ name: VALIDATOR_NAME_MIN,
4106
+ validator: Validators.min(c.min),
4107
+ isCustom: false,
4108
+ errorMessage: '',
4109
+ });
4110
+ }
4111
+ }
4112
+ if (c.maxLength) {
4113
+ w.validators = w.validators.filter((it) => it.name !== VALIDATOR_NAME_MAX_LEN);
4114
+ if (c.maxLength > 0) {
4115
+ w.validators.push({
4116
+ name: VALIDATOR_NAME_MAX_LEN,
4117
+ validator: Validators.maxLength(c.maxLength),
4118
+ isCustom: false,
4119
+ errorMessage: '',
4120
+ });
4121
+ }
4122
+ }
4123
+ if (c.minLength) {
4124
+ w.validators = w.validators.filter((it) => it.name !== VALIDATOR_NAME_MIN_LEN);
4125
+ if (c.minLength > 0) {
4126
+ w.validators.push({
4127
+ name: VALIDATOR_NAME_MIN_LEN,
4128
+ validator: Validators.minLength(c.minLength),
4129
+ isCustom: false,
4130
+ errorMessage: '',
4131
+ });
4132
+ }
4133
+ }
4134
+ }
4135
+ applyNamedValidators(w, namedValidators) {
4136
+ for (const v of namedValidators) {
4137
+ this.applyNamedValidator(w, v);
4138
+ }
4139
+ }
4140
+ applyNamedValidator(w, namedValidator) {
4141
+ const validatorFactory = this.factories.get(namedValidator.name);
4142
+ if (!validatorFactory) {
4143
+ console.warn(`Custom validator named ${namedValidator.name} was requested, but isn't present!`);
4144
+ return;
4145
+ }
4146
+ switch (namedValidator.operation) {
4147
+ case NamedValidatorOperationEnum.ADD:
4148
+ w.validators = w.validators.filter((it) => it.name !== namedValidator.name);
4149
+ const validatorFn = validatorFactory.create(namedValidator.params);
4150
+ w.validators.push({
4151
+ name: namedValidator.name,
4152
+ isCustom: true,
4153
+ errorMessage: '',
4154
+ validator: validatorFn,
4155
+ });
4156
+ break;
4157
+ case NamedValidatorOperationEnum.ALTER:
4158
+ const smartValidator = w.validators.find((it) => it.name === namedValidator.name);
4159
+ if (smartValidator) {
4160
+ smartValidator.validator = validatorFactory.create(namedValidator.params);
4161
+ }
4162
+ break;
4163
+ case NamedValidatorOperationEnum.REMOVE:
4164
+ w.validators = w.validators.filter((it) => it.name !== namedValidator.name);
4165
+ break;
4166
+ }
4167
+ }
4168
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: NamedValidatorService, deps: [{ token: NAMED_VALIDATOR, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
4169
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: NamedValidatorService }); }
4170
+ }
4171
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: NamedValidatorService, decorators: [{
4172
+ type: Injectable
4173
+ }], ctorParameters: () => [{ type: Array, decorators: [{
4174
+ type: Inject,
4175
+ args: [NAMED_VALIDATOR]
4176
+ }, {
4177
+ type: Optional
4178
+ }] }] });
4179
+
4048
4180
  class SmartFormService {
4049
- constructor() {
4181
+ constructor(validatorProvider) {
4182
+ this.validatorProvider = validatorProvider;
4050
4183
  this.emptyKey = 'e#m%p@t*y';
4051
4184
  this.componentLibrary = ComponentLibrary;
4052
4185
  this.group = {};
@@ -4534,7 +4667,7 @@ class SmartFormService {
4534
4667
  }
4535
4668
  this.addEmptyItemToValueList(widget, emptyLabel);
4536
4669
  }
4537
- if (constraint.enabled === undefined) {
4670
+ if (constraint.enabled === undefined || constraint.enabled === null) {
4538
4671
  if (widget.isDisabled === undefined) {
4539
4672
  widget.isDisabled = false;
4540
4673
  }
@@ -4542,6 +4675,7 @@ class SmartFormService {
4542
4675
  else {
4543
4676
  widget.isDisabled = !constraint.enabled;
4544
4677
  }
4678
+ this.validatorProvider?.applyConstraint(widget, constraint);
4545
4679
  }
4546
4680
  });
4547
4681
  }
@@ -4689,12 +4823,14 @@ class SmartFormService {
4689
4823
  widget.label = await this.getTranslationOfKey(widget.originalLabel);
4690
4824
  }));
4691
4825
  }
4692
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: SmartFormService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
4826
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: SmartFormService, deps: [{ token: NamedValidatorService, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
4693
4827
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: SmartFormService }); }
4694
4828
  }
4695
4829
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: SmartFormService, decorators: [{
4696
4830
  type: Injectable
4697
- }] });
4831
+ }], ctorParameters: () => [{ type: NamedValidatorService, decorators: [{
4832
+ type: Optional
4833
+ }] }] });
4698
4834
 
4699
4835
  var SmartFormWidgetWidth;
4700
4836
  (function (SmartFormWidgetWidth) {
@@ -15482,11 +15618,11 @@ class SmartFilterEditorContentComponent {
15482
15618
  return widget;
15483
15619
  }
15484
15620
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: SmartFilterEditorContentComponent, deps: [{ token: SmartformLayoutDefinitionService }, { token: ComponentFactoryService }], target: i0.ɵɵFactoryTarget.Component }); }
15485
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: SmartFilterEditorContentComponent, selector: "smart-filter-expression-editor", inputs: { service: "service" }, viewQueries: [{ propertyName: "vcRef", first: true, predicate: ["form"], descendants: true, read: ViewContainerRef }, { propertyName: "simpleFilterVcRef", first: true, predicate: ["simpleFilterFromChild"], descendants: true, read: ViewContainerRef }], ngImport: i0, template: "<div class=\"smart-filter-editor-container\" *ngIf=\"service.model\">\r\n <h3 class=\"smart-filter-editor-title\">{{ service.model?.model?.label }}</h3>\r\n\r\n <div *ngIf=\"service.model?.type === type.SIMPLE; then simpleFilter; else complexFilter\"></div>\r\n\r\n <ng-template #simpleFilter>\r\n <div class=\"smart-filter-editor-expressionsContainer\">\r\n <ng-template #simpleFilterFromChild></ng-template>\r\n <!-- #simpleFilterFromChild [smartForm]=\"simpleFilterForm\"></smartform> -->\r\n </div>\r\n </ng-template>\r\n <ng-template #complexFilter>\r\n <div class=\"smart-filter-editor-uiActionsBar\" *ngIf=\"!service.model?.readOnly\">\r\n <smart-ui-action-toolbar [uiActionModels]=\"uiActionModels\"></smart-ui-action-toolbar>\r\n </div>\r\n <div\r\n *ngIf=\"\r\n service?.model?.model?.workplaceList?.filters?.length;\r\n then withParameters;\r\n else withoutParameters\r\n \"\r\n ></div>\r\n <ng-template #withoutParameters>\r\n <div class=\"smart-filter-editor-withoutParametersContainer\">\r\n <span class=\"mat-body\"> M\u00E9g nincs megadva param\u00E9ter </span>\r\n </div>\r\n </ng-template>\r\n <ng-template #withParameters>\r\n <div class=\"smart-filter-editor-withParametersContainer\">\r\n <div\r\n class=\"smart-filter-editor-expressionsContainer\"\r\n *ngIf=\"service?.model?.model?.workplaceList?.filters?.length\"\r\n >\r\n <app-expression-items\r\n [items]=\"(service.model?.model?.workplaceList)!.filters\"\r\n [service]=\"service\"\r\n ></app-expression-items>\r\n </div>\r\n <div class=\"smart-filter-editor-expressionEditorContainer\">\r\n <!-- <smartform #form [smartForm]=\"smartForm\"></smartform> -->\r\n <ng-template #form></ng-template>\r\n <div *ngIf=\"smartForm\">\r\n <button (click)=\"remove()\" mat-raised-button color=\"primary\">T\u00F6rl\u00E9s</button>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-template>\r\n </ng-template>\r\n</div>\r\n", styles: [".smart-filter-editor-container{display:flex;flex-direction:column;overflow:auto;position:relative}.targetGroupContentContainer h3{margin:0;font-weight:600}.smart-filter-editor-uiActionsBar{padding:1.5rem;border-radius:.25rem;background-color:var(--container-color);display:flex;flex-direction:row;gap:1rem}.smart-filter-editor-withoutParametersContainer{display:flex;flex-direction:column;background-color:var(--container-color)}.withoutParametersContainer .mat-body{font-weight:600;text-align:center}.smart-filter-editor-withParametersContainer{display:flex;flex-direction:column;background-color:var(--container-color)}.smart-filter-editor-expressionEditorContainer{display:flex;flex-direction:column;gap:.75rem}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: UiActionToolbarComponent, selector: "smart-ui-action-toolbar", inputs: ["uiActionModels", "uiActionDescriptorService", "id"] }, { kind: "component", type: i2$3.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: SmartFilterExpressionItemsComponent, selector: "app-expression-items", inputs: ["items", "service"] }] }); }
15621
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: SmartFilterEditorContentComponent, selector: "smart-filter-expression-editor", inputs: { service: "service" }, viewQueries: [{ propertyName: "vcRef", first: true, predicate: ["form"], descendants: true, read: ViewContainerRef }, { propertyName: "simpleFilterVcRef", first: true, predicate: ["simpleFilterFromChild"], descendants: true, read: ViewContainerRef }], ngImport: i0, template: "<div class=\"smart-filter-editor-container\" *ngIf=\"service.model\">\r\n <h3 class=\"smart-filter-editor-title\">{{ service.model.model?.label }}</h3>\r\n\r\n <div *ngIf=\"service.model?.type === type.SIMPLE; then simpleFilter; else complexFilter\"></div>\r\n\r\n <ng-template #simpleFilter>\r\n <div class=\"smart-filter-editor-expressionsContainer\">\r\n <ng-template #simpleFilterFromChild></ng-template>\r\n <!-- #simpleFilterFromChild [smartForm]=\"simpleFilterForm\"></smartform> -->\r\n </div>\r\n </ng-template>\r\n <ng-template #complexFilter>\r\n <div class=\"smart-filter-editor-uiActionsBar\" *ngIf=\"!service.model?.readOnly\">\r\n <smart-ui-action-toolbar [uiActionModels]=\"uiActionModels\"></smart-ui-action-toolbar>\r\n </div>\r\n <div\r\n *ngIf=\"\r\n service?.model?.model?.workplaceList?.filters?.length;\r\n then withParameters;\r\n else withoutParameters\r\n \"\r\n ></div>\r\n <ng-template #withoutParameters>\r\n <div class=\"smart-filter-editor-withoutParametersContainer\">\r\n <span class=\"mat-body\"> M\u00E9g nincs megadva param\u00E9ter </span>\r\n </div>\r\n </ng-template>\r\n <ng-template #withParameters>\r\n <div class=\"smart-filter-editor-withParametersContainer\">\r\n <div\r\n class=\"smart-filter-editor-expressionsContainer\"\r\n *ngIf=\"service?.model?.model?.workplaceList?.filters?.length\"\r\n >\r\n <app-expression-items\r\n [items]=\"(service.model.model?.workplaceList)!.filters\"\r\n [service]=\"service\"\r\n ></app-expression-items>\r\n </div>\r\n <div class=\"smart-filter-editor-expressionEditorContainer\">\r\n <!-- <smartform #form [smartForm]=\"smartForm\"></smartform> -->\r\n <ng-template #form></ng-template>\r\n <div *ngIf=\"smartForm\">\r\n <button (click)=\"remove()\" mat-raised-button color=\"primary\">T\u00F6rl\u00E9s</button>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-template>\r\n </ng-template>\r\n</div>\r\n", styles: [".smart-filter-editor-container{display:flex;flex-direction:column;overflow:auto;position:relative}.targetGroupContentContainer h3{margin:0;font-weight:600}.smart-filter-editor-uiActionsBar{padding:1.5rem;border-radius:.25rem;background-color:var(--container-color);display:flex;flex-direction:row;gap:1rem}.smart-filter-editor-withoutParametersContainer{display:flex;flex-direction:column;background-color:var(--container-color)}.withoutParametersContainer .mat-body{font-weight:600;text-align:center}.smart-filter-editor-withParametersContainer{display:flex;flex-direction:column;background-color:var(--container-color)}.smart-filter-editor-expressionEditorContainer{display:flex;flex-direction:column;gap:.75rem}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: UiActionToolbarComponent, selector: "smart-ui-action-toolbar", inputs: ["uiActionModels", "uiActionDescriptorService", "id"] }, { kind: "component", type: i2$3.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: SmartFilterExpressionItemsComponent, selector: "app-expression-items", inputs: ["items", "service"] }] }); }
15486
15622
  }
15487
15623
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: SmartFilterEditorContentComponent, decorators: [{
15488
15624
  type: Component,
15489
- args: [{ selector: 'smart-filter-expression-editor', template: "<div class=\"smart-filter-editor-container\" *ngIf=\"service.model\">\r\n <h3 class=\"smart-filter-editor-title\">{{ service.model?.model?.label }}</h3>\r\n\r\n <div *ngIf=\"service.model?.type === type.SIMPLE; then simpleFilter; else complexFilter\"></div>\r\n\r\n <ng-template #simpleFilter>\r\n <div class=\"smart-filter-editor-expressionsContainer\">\r\n <ng-template #simpleFilterFromChild></ng-template>\r\n <!-- #simpleFilterFromChild [smartForm]=\"simpleFilterForm\"></smartform> -->\r\n </div>\r\n </ng-template>\r\n <ng-template #complexFilter>\r\n <div class=\"smart-filter-editor-uiActionsBar\" *ngIf=\"!service.model?.readOnly\">\r\n <smart-ui-action-toolbar [uiActionModels]=\"uiActionModels\"></smart-ui-action-toolbar>\r\n </div>\r\n <div\r\n *ngIf=\"\r\n service?.model?.model?.workplaceList?.filters?.length;\r\n then withParameters;\r\n else withoutParameters\r\n \"\r\n ></div>\r\n <ng-template #withoutParameters>\r\n <div class=\"smart-filter-editor-withoutParametersContainer\">\r\n <span class=\"mat-body\"> M\u00E9g nincs megadva param\u00E9ter </span>\r\n </div>\r\n </ng-template>\r\n <ng-template #withParameters>\r\n <div class=\"smart-filter-editor-withParametersContainer\">\r\n <div\r\n class=\"smart-filter-editor-expressionsContainer\"\r\n *ngIf=\"service?.model?.model?.workplaceList?.filters?.length\"\r\n >\r\n <app-expression-items\r\n [items]=\"(service.model?.model?.workplaceList)!.filters\"\r\n [service]=\"service\"\r\n ></app-expression-items>\r\n </div>\r\n <div class=\"smart-filter-editor-expressionEditorContainer\">\r\n <!-- <smartform #form [smartForm]=\"smartForm\"></smartform> -->\r\n <ng-template #form></ng-template>\r\n <div *ngIf=\"smartForm\">\r\n <button (click)=\"remove()\" mat-raised-button color=\"primary\">T\u00F6rl\u00E9s</button>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-template>\r\n </ng-template>\r\n</div>\r\n", styles: [".smart-filter-editor-container{display:flex;flex-direction:column;overflow:auto;position:relative}.targetGroupContentContainer h3{margin:0;font-weight:600}.smart-filter-editor-uiActionsBar{padding:1.5rem;border-radius:.25rem;background-color:var(--container-color);display:flex;flex-direction:row;gap:1rem}.smart-filter-editor-withoutParametersContainer{display:flex;flex-direction:column;background-color:var(--container-color)}.withoutParametersContainer .mat-body{font-weight:600;text-align:center}.smart-filter-editor-withParametersContainer{display:flex;flex-direction:column;background-color:var(--container-color)}.smart-filter-editor-expressionEditorContainer{display:flex;flex-direction:column;gap:.75rem}\n"] }]
15625
+ args: [{ selector: 'smart-filter-expression-editor', template: "<div class=\"smart-filter-editor-container\" *ngIf=\"service.model\">\r\n <h3 class=\"smart-filter-editor-title\">{{ service.model.model?.label }}</h3>\r\n\r\n <div *ngIf=\"service.model?.type === type.SIMPLE; then simpleFilter; else complexFilter\"></div>\r\n\r\n <ng-template #simpleFilter>\r\n <div class=\"smart-filter-editor-expressionsContainer\">\r\n <ng-template #simpleFilterFromChild></ng-template>\r\n <!-- #simpleFilterFromChild [smartForm]=\"simpleFilterForm\"></smartform> -->\r\n </div>\r\n </ng-template>\r\n <ng-template #complexFilter>\r\n <div class=\"smart-filter-editor-uiActionsBar\" *ngIf=\"!service.model?.readOnly\">\r\n <smart-ui-action-toolbar [uiActionModels]=\"uiActionModels\"></smart-ui-action-toolbar>\r\n </div>\r\n <div\r\n *ngIf=\"\r\n service?.model?.model?.workplaceList?.filters?.length;\r\n then withParameters;\r\n else withoutParameters\r\n \"\r\n ></div>\r\n <ng-template #withoutParameters>\r\n <div class=\"smart-filter-editor-withoutParametersContainer\">\r\n <span class=\"mat-body\"> M\u00E9g nincs megadva param\u00E9ter </span>\r\n </div>\r\n </ng-template>\r\n <ng-template #withParameters>\r\n <div class=\"smart-filter-editor-withParametersContainer\">\r\n <div\r\n class=\"smart-filter-editor-expressionsContainer\"\r\n *ngIf=\"service?.model?.model?.workplaceList?.filters?.length\"\r\n >\r\n <app-expression-items\r\n [items]=\"(service.model.model?.workplaceList)!.filters\"\r\n [service]=\"service\"\r\n ></app-expression-items>\r\n </div>\r\n <div class=\"smart-filter-editor-expressionEditorContainer\">\r\n <!-- <smartform #form [smartForm]=\"smartForm\"></smartform> -->\r\n <ng-template #form></ng-template>\r\n <div *ngIf=\"smartForm\">\r\n <button (click)=\"remove()\" mat-raised-button color=\"primary\">T\u00F6rl\u00E9s</button>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-template>\r\n </ng-template>\r\n</div>\r\n", styles: [".smart-filter-editor-container{display:flex;flex-direction:column;overflow:auto;position:relative}.targetGroupContentContainer h3{margin:0;font-weight:600}.smart-filter-editor-uiActionsBar{padding:1.5rem;border-radius:.25rem;background-color:var(--container-color);display:flex;flex-direction:row;gap:1rem}.smart-filter-editor-withoutParametersContainer{display:flex;flex-direction:column;background-color:var(--container-color)}.withoutParametersContainer .mat-body{font-weight:600;text-align:center}.smart-filter-editor-withParametersContainer{display:flex;flex-direction:column;background-color:var(--container-color)}.smart-filter-editor-expressionEditorContainer{display:flex;flex-direction:column;gap:.75rem}\n"] }]
15490
15626
  }], ctorParameters: () => [{ type: SmartformLayoutDefinitionService }, { type: ComponentFactoryService }], propDecorators: { service: [{
15491
15627
  type: Input
15492
15628
  }], vcRef: [{
@@ -18560,6 +18696,27 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImpo
18560
18696
  }]
18561
18697
  }] });
18562
18698
 
18699
+ class SmartValidationModule {
18700
+ static forRoot(providers) {
18701
+ return {
18702
+ ngModule: SmartValidationModule,
18703
+ providers: [NamedValidatorService, ...providers],
18704
+ };
18705
+ }
18706
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: SmartValidationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
18707
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.11", ngImport: i0, type: SmartValidationModule }); }
18708
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: SmartValidationModule, providers: [NamedValidatorService] }); }
18709
+ }
18710
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: SmartValidationModule, decorators: [{
18711
+ type: NgModule,
18712
+ args: [{
18713
+ declarations: [],
18714
+ imports: [],
18715
+ providers: [NamedValidatorService],
18716
+ exports: [],
18717
+ }]
18718
+ }] });
18719
+
18563
18720
  /*
18564
18721
  * Public API Surface of smart-ng-client
18565
18722
  */
@@ -18568,5 +18725,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImpo
18568
18725
  * Generated bundle index. Do not edit.
18569
18726
  */
18570
18727
 
18571
- export { APIS$4 as APIS, AbstractMap, ApiModule$4 as ApiModule, ApiQueueService, BASE_PATH$6 as BASE_PATH, COLLECTION_FORMATS$6 as COLLECTION_FORMATS, COMPONENT_LIBRARY, CloseResult, ComparableDropdownDirective, ComparableMultiselectDirective, ComponentFactoryService, ComponentFactoryServiceModule, ComponentLibrary, ComponentType, ComponentWidgetType, Configuration$6 as Configuration, DIALOG_DISABLE_CLOSE, DataChangeKind, DefaultUiActionCode_CLOSE, ExpandableSectionButtonIconPosition, ExpandableSectionButtonType, ExpandableSectionComponent, FilterExpressionBoolOperator$1 as FilterExpressionBoolOperator, FilterExpressionBuilderGroupBuilderGroupKindEnum, FilterExpressionDataType, FilterExpressionFieldWidgetType, FilterExpressionOperation, FilterExpressionOrderByOrderEnum, GeoMapDataLoadingMode, GeoMapDataSourceType, GeoMapItemKind, GeoMapOperationMode, GeoMapSelectionMode, GeoMapTextType, GoogleMap, GridColumnContentType, GridDataAccessConfigKindEnum, GridSelectionMode, GridSelectionType, GridUiActionType, GridViewDescriptorKindEnum, HighlightPipe, IS_ASYNC_PARAM_NAME, IconPosition, ImageResourceKindEnum, LayoutDirection, LeafletMap, LinkTargetEnum, MAP_ENGINE, MapEngine, MessageOptionType, MessageTextType, MessageType, SelectionDefinitionTypeEnum, ServerRequestType, SessionAPIS, SessionErrorBehaviour, SessionService, SharedModule, SimplifiedTabGroupComponent, SmartActionType, SmartAuthService, SmartComponent, SmartComponentApiClient, SmartComponentLayoutComponent, SmartComponentLayoutModule, SmartComponentLayoutUtility, SmartDatePipe, SmartDateTimePipe, SmartDialog, SmartExpandableSectionModule, SmartExpandableSectionService, SmartFileUploaderComponent, SmartFilterComponent, SmartFilterEditorContentComponent, SmartFilterEditorModule, SmartFilterEditorService, SmartFilterExpressionItemComponent, SmartFilterExpressionItemsComponent, SmartFilterModule, SmartFilterParamComponent, SmartFilterParamsComponent, SmartFilterPosition, SmartFilterType, SmartFormInputMode, SmartFormTextFieldButtonIconPosition, SmartFormWidgetDirection, SmartFormWidgetType, SmartFormWidgetWidth, SmartGridButtonType, SmartGridComponent, SmartGridDataLayout, SmartGridModule, SmartGridService, SmartGridType, SmartIconComponent, SmartIconModule, SmartIconService, SmartLayoutDef, SmartLinkChannelVariableInPath, SmartLinkUuidVariableInPath, SmartMapComponent, SmartMapModule, SmartNavbarComponent, SmartNavbarModule, SmartNavbarService, SmartNavigationModule, SmartNavigationService, SmartNgClientModule, SmartNgClientService, SmartService, SmartSessionModule, SmartSessionService, SmartSessionTimerComponent, SmartSessionTimerService, SmartSubject, SmartTabGroupModule, SmartTabGroupService, SmartTable, SmartTableButtonType, SmartTableHeaderPropertyType, SmartTableInterfaceTypeEnum, SmartTableOptionButtonDirection, SmartTableOrder, SmartTableType, SmartTimePipe, SmartTooltipDirective, SmartTreeComponent, SmartTreeNodeButtonType, SmartUserSettinsIconPosition, SmartValidatorName, SmartViewContextErrorDialogButtonLabel, SmartViewContextErrorDialogMessage, SmartViewContextErrorDialogTitle, SmartViewContextModule, SmartViewContextService, SmartViewRedirect, SmartWidgetHintPosition, SmartWidgetHintPositionEnum, SmartWidgetSettings, SmartdialogModule, SmartdialogService, SmartfileuploaderComponent, SmartformComponent, SmartformLayoutDefinitionService, SmartformwidgetComponent, SmarttableComponent, SmarttableModule, SmarttableService, SmarttreeGenericService, SmarttreeModule, SmarttreeService, TabGroupComponent, ToggleLabelPosition, UiActionButtonType, UiActionConfirmDialogComponent, UiActionConfirmDialogService, UiActionDescriptorService, UiActionDialogButtonComponent, UiActionDialogType, UiActionFeedbackType, UiActionInputDialogComponent, UiActionInputDialogService, UiActionInputType, UiActionService, UiActionToolbarComponent, UiActionTooltipTooltipPositionEnum, ValueChangeMode, ViewEventHandlerViewEventTypeEnum, ViewService, ViewState, ViewType };
18728
+ export { APIS$4 as APIS, AbstractMap, ApiModule$4 as ApiModule, ApiQueueService, BASE_PATH$6 as BASE_PATH, COLLECTION_FORMATS$6 as COLLECTION_FORMATS, COMPONENT_LIBRARY, CloseResult, ComparableDropdownDirective, ComparableMultiselectDirective, ComponentFactoryService, ComponentFactoryServiceModule, ComponentLibrary, ComponentType, ComponentWidgetType, Configuration$6 as Configuration, DIALOG_DISABLE_CLOSE, DataChangeKind, DefaultUiActionCode_CLOSE, EMPTY_PARAMS, ExpandableSectionButtonIconPosition, ExpandableSectionButtonType, ExpandableSectionComponent, FilterExpressionBoolOperator$1 as FilterExpressionBoolOperator, FilterExpressionBuilderGroupBuilderGroupKindEnum, FilterExpressionDataType, FilterExpressionFieldWidgetType, FilterExpressionOperation, FilterExpressionOrderByOrderEnum, GeoMapDataLoadingMode, GeoMapDataSourceType, GeoMapItemKind, GeoMapOperationMode, GeoMapSelectionMode, GeoMapTextType, GoogleMap, GridColumnContentType, GridDataAccessConfigKindEnum, GridSelectionMode, GridSelectionType, GridUiActionType, GridViewDescriptorKindEnum, HighlightPipe, IS_ASYNC_PARAM_NAME, IconPosition, ImageResourceKindEnum, LayoutDirection, LeafletMap, LinkTargetEnum, MAP_ENGINE, MapEngine, MessageOptionType, MessageTextType, MessageType, NAMED_VALIDATOR, NamedValidatorOperationEnum, NamedValidatorService, SelectionDefinitionTypeEnum, ServerRequestType, SessionAPIS, SessionErrorBehaviour, SessionService, SharedModule, SimplifiedTabGroupComponent, SmartActionType, SmartAuthService, SmartComponent, SmartComponentApiClient, SmartComponentLayoutComponent, SmartComponentLayoutModule, SmartComponentLayoutUtility, SmartDatePipe, SmartDateTimePipe, SmartDialog, SmartExpandableSectionModule, SmartExpandableSectionService, SmartFileUploaderComponent, SmartFilterComponent, SmartFilterEditorContentComponent, SmartFilterEditorModule, SmartFilterEditorService, SmartFilterExpressionItemComponent, SmartFilterExpressionItemsComponent, SmartFilterModule, SmartFilterParamComponent, SmartFilterParamsComponent, SmartFilterPosition, SmartFilterType, SmartFormInputMode, SmartFormTextFieldButtonIconPosition, SmartFormWidgetDirection, SmartFormWidgetType, SmartFormWidgetWidth, SmartGridButtonType, SmartGridComponent, SmartGridDataLayout, SmartGridModule, SmartGridService, SmartGridType, SmartIconComponent, SmartIconModule, SmartIconService, SmartLayoutDef, SmartLinkChannelVariableInPath, SmartLinkUuidVariableInPath, SmartMapComponent, SmartMapModule, SmartNavbarComponent, SmartNavbarModule, SmartNavbarService, SmartNavigationModule, SmartNavigationService, SmartNgClientModule, SmartNgClientService, SmartService, SmartSessionModule, SmartSessionService, SmartSessionTimerComponent, SmartSessionTimerService, SmartSubject, SmartTabGroupModule, SmartTabGroupService, SmartTable, SmartTableButtonType, SmartTableHeaderPropertyType, SmartTableInterfaceTypeEnum, SmartTableOptionButtonDirection, SmartTableOrder, SmartTableType, SmartTimePipe, SmartTooltipDirective, SmartTreeComponent, SmartTreeNodeButtonType, SmartUserSettinsIconPosition, SmartValidationModule, SmartValidatorName, SmartViewContextErrorDialogButtonLabel, SmartViewContextErrorDialogMessage, SmartViewContextErrorDialogTitle, SmartViewContextModule, SmartViewContextService, SmartViewRedirect, SmartWidgetHintPosition, SmartWidgetHintPositionEnum, SmartWidgetSettings, SmartdialogModule, SmartdialogService, SmartfileuploaderComponent, SmartformComponent, SmartformLayoutDefinitionService, SmartformwidgetComponent, SmarttableComponent, SmarttableModule, SmarttableService, SmarttreeGenericService, SmarttreeModule, SmarttreeService, TabGroupComponent, ToggleLabelPosition, UiActionButtonType, UiActionConfirmDialogComponent, UiActionConfirmDialogService, UiActionDescriptorService, UiActionDialogButtonComponent, UiActionDialogType, UiActionFeedbackType, UiActionInputDialogComponent, UiActionInputDialogService, UiActionInputType, UiActionService, UiActionToolbarComponent, UiActionTooltipTooltipPositionEnum, ValueChangeMode, ViewEventHandlerViewEventTypeEnum, ViewService, ViewState, ViewType };
18572
18729
  //# sourceMappingURL=smartbit4all-ng-client.mjs.map