@valtimo-plugins/freemarker 5.0.1 → 7.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.
Files changed (47) hide show
  1. package/fesm2022/valtimo-plugins-freemarker.mjs +1076 -160
  2. package/fesm2022/valtimo-plugins-freemarker.mjs.map +1 -1
  3. package/lib/models/freemarker-template.d.ts +11 -7
  4. package/lib/plugins/mail-template/assets/mail-template-plugin-logo.d.ts +2 -2
  5. package/lib/plugins/mail-template/components/generate-mail-content/generate-mail-content.component.d.ts +1 -2
  6. package/lib/plugins/mail-template/components/generate-mail-file/generate-mail-file.component.d.ts +1 -2
  7. package/lib/plugins/mail-template/components/mail-template-add-edit-modal/mail-template-add-edit-modal.component.d.ts +1 -1
  8. package/lib/plugins/mail-template/components/mail-template-delete-modal/mail-template-delete-modal.component.d.ts +1 -1
  9. package/lib/plugins/mail-template/components/mail-template-editor/mail-template-editor.component.d.ts +6 -3
  10. package/lib/plugins/mail-template/components/mail-template-list/mail-template-list.component.d.ts +7 -4
  11. package/lib/plugins/mail-template/mail-template-plugin-module.d.ts +9 -12
  12. package/lib/plugins/text-template/assets/index.d.ts +1 -0
  13. package/lib/plugins/text-template/assets/text-template-plugin-logo.d.ts +2 -0
  14. package/lib/plugins/text-template/components/generate-text-file/generate-text-file.component.d.ts +32 -0
  15. package/lib/plugins/text-template/components/text-template-add-edit-modal/text-template-add-edit-modal.component.d.ts +29 -0
  16. package/lib/plugins/text-template/components/text-template-configuration/text-template-configuration.component.d.ts +25 -0
  17. package/lib/plugins/text-template/components/text-template-delete-modal/text-template-delete-modal.component.d.ts +11 -0
  18. package/lib/plugins/text-template/components/text-template-editor/text-template-editor.component.d.ts +52 -0
  19. package/lib/plugins/text-template/components/text-template-list/text-template-list.component.d.ts +35 -0
  20. package/lib/plugins/text-template/models/config.d.ts +12 -0
  21. package/lib/plugins/text-template/models/index.d.ts +1 -0
  22. package/lib/plugins/text-template/text-template-management-routing.module.d.ts +8 -0
  23. package/lib/plugins/text-template/text-template-plugin-module.d.ts +15 -0
  24. package/lib/plugins/text-template/text-template-plugin.specification.d.ts +3 -0
  25. package/lib/services/freemarker-template-management.service.d.ts +8 -5
  26. package/package.json +6 -9
  27. package/public_api.d.ts +9 -0
  28. package/esm2022/lib/models/freemarker-template.mjs +0 -17
  29. package/esm2022/lib/models/index.mjs +0 -17
  30. package/esm2022/lib/plugins/mail-template/assets/index.mjs +0 -17
  31. package/esm2022/lib/plugins/mail-template/assets/mail-template-plugin-logo.mjs +0 -18
  32. package/esm2022/lib/plugins/mail-template/components/generate-mail-content/generate-mail-content.component.mjs +0 -94
  33. package/esm2022/lib/plugins/mail-template/components/generate-mail-file/generate-mail-file.component.mjs +0 -94
  34. package/esm2022/lib/plugins/mail-template/components/mail-template-add-edit-modal/mail-template-add-edit-modal.component.mjs +0 -87
  35. package/esm2022/lib/plugins/mail-template/components/mail-template-configuration/mail-template-configuration.component.mjs +0 -77
  36. package/esm2022/lib/plugins/mail-template/components/mail-template-delete-modal/mail-template-delete-modal.component.mjs +0 -39
  37. package/esm2022/lib/plugins/mail-template/components/mail-template-editor/mail-template-editor.component.mjs +0 -168
  38. package/esm2022/lib/plugins/mail-template/components/mail-template-list/mail-template-list.component.mjs +0 -104
  39. package/esm2022/lib/plugins/mail-template/mail-template-management-routing.module.mjs +0 -48
  40. package/esm2022/lib/plugins/mail-template/mail-template-plugin-module.mjs +0 -158
  41. package/esm2022/lib/plugins/mail-template/mail-template-plugin.specification.mjs +0 -74
  42. package/esm2022/lib/plugins/mail-template/models/config.mjs +0 -17
  43. package/esm2022/lib/plugins/mail-template/models/index.mjs +0 -17
  44. package/esm2022/lib/services/freemarker-template-management.service.mjs +0 -68
  45. package/esm2022/lib/services/index.mjs +0 -17
  46. package/esm2022/public_api.mjs +0 -29
  47. package/esm2022/valtimo-plugins-freemarker.mjs +0 -5
@@ -1,24 +1,25 @@
1
1
  import * as i0 from '@angular/core';
2
- import { EventEmitter, Component, Input, Output, Injectable, ChangeDetectionStrategy, ViewChild, NgModule } from '@angular/core';
3
- import { BehaviorSubject, combineLatest, take, switchMap, of, map, tap, filter } from 'rxjs';
2
+ import { EventEmitter, Output, Input, Component, Injectable, ChangeDetectionStrategy, ViewChild, NgModule } from '@angular/core';
3
+ import { BehaviorSubject, combineLatest, take, map, switchMap, of, tap, filter, startWith } from 'rxjs';
4
4
  import * as i4 from '@angular/common';
5
5
  import { CommonModule } from '@angular/common';
6
6
  import * as i1 from '@valtimo/components';
7
- import { CARBON_CONSTANTS, ViewType, CarbonListComponent, FormModule, ParagraphModule, SelectModule, ConfirmationModalModule, CarbonListModule, EditorModule, InputModule, RenderInPageHeaderDirectiveModule } from '@valtimo/components';
7
+ import { ConfirmationModalModule, CARBON_CONSTANTS, ViewType, CarbonListModule, CarbonListComponent, ValtimoCdsOverflowButtonDirectiveModule, EditorModule, RenderInPageHeaderDirectiveModule, FormModule, ParagraphModule, SelectModule, InputModule as InputModule$1 } from '@valtimo/components';
8
8
  import * as i6 from '@valtimo/plugin';
9
9
  import { PluginTranslatePipeModule } from '@valtimo/plugin';
10
10
  import * as i2$1 from '@valtimo/document';
11
- import * as i1$1 from '@valtimo/config';
12
- import { ROLE_ADMIN, CASE_MANAGEMENT_TAB_TOKEN } from '@valtimo/config';
13
11
  import * as i2 from '@angular/common/http';
12
+ import { HttpHeaders } from '@angular/common/http';
13
+ import * as i3 from '@valtimo/shared';
14
+ import { InterceptorSkip, getCaseManagementRouteParams, ROLE_ADMIN, CASE_MANAGEMENT_TAB_TOKEN } from '@valtimo/shared';
14
15
  import * as i4$1 from 'carbon-components-angular';
15
- import { NotificationService, ButtonModule, DialogModule, DropdownModule, IconModule, InputModule as InputModule$1, LoadingModule, ModalModule, NotificationModule, TabsModule } from 'carbon-components-angular';
16
- import * as i2$2 from '@angular/router';
17
- import { RouterModule } from '@angular/router';
18
- import * as i1$2 from '@angular/forms';
19
- import { Validators, ReactiveFormsModule } from '@angular/forms';
16
+ import { ButtonModule, ModalModule, InputModule, TabsModule, DialogModule, NotificationService, DropdownModule, IconModule, LoadingModule, NotificationModule } from 'carbon-components-angular';
20
17
  import * as i5 from '@ngx-translate/core';
21
18
  import { TranslateModule } from '@ngx-translate/core';
19
+ import * as i1$1 from '@angular/forms';
20
+ import { Validators, ReactiveFormsModule } from '@angular/forms';
21
+ import * as i2$2 from '@angular/router';
22
+ import { RouterModule } from '@angular/router';
22
23
  import { AuthGuardService } from '@valtimo/security';
23
24
 
24
25
  /*
@@ -104,12 +105,12 @@ class MailTemplateConfigurationComponent {
104
105
  }
105
106
  injectCaseTab() {
106
107
  }
107
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplateConfigurationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
108
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: MailTemplateConfigurationComponent, selector: "valtimo-mail-template-configuration", inputs: { save$: "save$", disabled$: "disabled$", pluginId: "pluginId", prefillConfiguration$: "prefillConfiguration$" }, outputs: { valid: "valid", configuration: "configuration" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<v-form\n (valueChange)=\"formValueChange($event)\"\n *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null\n } as obs\"\n>\n <v-input\n name=\"configurationTitle\"\n [title]=\"'configurationTitle' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [disabled]=\"obs.disabled\"\n [defaultValue]=\"obs.prefill?.configurationTitle\"\n [required]=\"true\"\n [tooltip]=\"'configurationTitleTooltip' | pluginTranslate: pluginId | async\"\n [widthPx]=\"350\"\n placeholder=\"Mail Template Plugin\"\n >\n </v-input>\n</v-form>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1.FormComponent, selector: "v-form", inputs: ["className"], outputs: ["valueChange"] }, { kind: "component", type: i1.InputComponent, selector: "v-input", inputs: ["name", "type", "title", "titleTranslationKey", "defaultValue", "widthPx", "fullWidth", "margin", "smallMargin", "disabled", "step", "min", "maxLength", "tooltip", "required", "hideNumberSpinBox", "smallLabel", "rows", "clear$", "carbonTheme", "placeholder", "dataTestId"], outputs: ["valueChange"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "pipe", type: i6.PluginTranslatePipe, name: "pluginTranslate" }] }); }
108
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplateConfigurationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
109
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: MailTemplateConfigurationComponent, isStandalone: false, selector: "valtimo-mail-template-configuration", inputs: { save$: "save$", disabled$: "disabled$", pluginId: "pluginId", prefillConfiguration$: "prefillConfiguration$" }, outputs: { valid: "valid", configuration: "configuration" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<v-form\n (valueChange)=\"formValueChange($event)\"\n *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null\n } as obs\"\n>\n <v-input\n name=\"configurationTitle\"\n [title]=\"'configurationTitle' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [disabled]=\"obs.disabled\"\n [defaultValue]=\"obs.prefill?.configurationTitle\"\n [required]=\"true\"\n [tooltip]=\"'configurationTitleTooltip' | pluginTranslate: pluginId | async\"\n [widthPx]=\"350\"\n placeholder=\"Mail Template Plugin\"\n >\n </v-input>\n</v-form>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1.FormComponent, selector: "v-form", inputs: ["className"], outputs: ["valueChange"] }, { kind: "component", type: i1.InputComponent, selector: "v-input", inputs: ["name", "type", "title", "titleTranslationKey", "defaultValue", "widthPx", "fullWidth", "margin", "smallMargin", "disabled", "step", "min", "maxLength", "tooltip", "required", "hideNumberSpinBox", "smallLabel", "rows", "clear$", "carbonTheme", "placeholder", "dataTestId", "trim"], outputs: ["valueChange"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "pipe", type: i6.PluginTranslatePipe, name: "pluginTranslate" }] }); }
109
110
  }
110
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplateConfigurationComponent, decorators: [{
111
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplateConfigurationComponent, decorators: [{
111
112
  type: Component,
112
- args: [{ selector: 'valtimo-mail-template-configuration', template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<v-form\n (valueChange)=\"formValueChange($event)\"\n *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null\n } as obs\"\n>\n <v-input\n name=\"configurationTitle\"\n [title]=\"'configurationTitle' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [disabled]=\"obs.disabled\"\n [defaultValue]=\"obs.prefill?.configurationTitle\"\n [required]=\"true\"\n [tooltip]=\"'configurationTitleTooltip' | pluginTranslate: pluginId | async\"\n [widthPx]=\"350\"\n placeholder=\"Mail Template Plugin\"\n >\n </v-input>\n</v-form>\n" }]
113
+ args: [{ standalone: false, selector: 'valtimo-mail-template-configuration', template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<v-form\n (valueChange)=\"formValueChange($event)\"\n *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null\n } as obs\"\n>\n <v-input\n name=\"configurationTitle\"\n [title]=\"'configurationTitle' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [disabled]=\"obs.disabled\"\n [defaultValue]=\"obs.prefill?.configurationTitle\"\n [required]=\"true\"\n [tooltip]=\"'configurationTitleTooltip' | pluginTranslate: pluginId | async\"\n [widthPx]=\"350\"\n placeholder=\"Mail Template Plugin\"\n >\n </v-input>\n</v-form>\n" }]
113
114
  }], ctorParameters: () => [], propDecorators: { save$: [{
114
115
  type: Input
115
116
  }], disabled$: [{
@@ -145,12 +146,16 @@ class FreemarkerTemplateManagementService {
145
146
  this.http = http;
146
147
  this.valtimoEndpointUri = `${this.configService.config.valtimoApi.endpointUri}management/`;
147
148
  }
148
- getAllMailTemplates(caseDefinitionName) {
149
- return this.getTemplates(caseDefinitionName, 'mail', undefined, 0, 10000);
149
+ getAllMailTemplates(caseDefinitionKey, caseDefinitionVersionTag) {
150
+ return this.getTemplates(caseDefinitionKey, caseDefinitionVersionTag, 'mail', undefined, 0, 10000);
150
151
  }
151
- getTemplates(caseDefinitionName, templateType, templateKey, page, pageSize) {
152
+ getAllTextTemplates(caseDefinitionKey, caseDefinitionVersionTag) {
153
+ return this.getTemplates(caseDefinitionKey, caseDefinitionVersionTag, 'text', undefined, 0, 10000);
154
+ }
155
+ getTemplates(caseDefinitionKey, caseDefinitionVersionTag, templateType, templateKey, page, pageSize) {
152
156
  const params = {
153
- caseDefinitionName,
157
+ caseDefinitionKey,
158
+ caseDefinitionVersionTag,
154
159
  templateType,
155
160
  templateKey,
156
161
  page,
@@ -163,11 +168,14 @@ class FreemarkerTemplateManagementService {
163
168
  });
164
169
  return this.http.get(`${this.valtimoEndpointUri}v1/template`, { params });
165
170
  }
166
- getMailTemplate(caseDefinitionName, key) {
167
- return this.getTemplate(caseDefinitionName, 'mail', key);
171
+ getMailTemplate(caseDefinitionKey, caseDefinitionVersionTag, key) {
172
+ return this.getTemplate(caseDefinitionKey, caseDefinitionVersionTag, 'mail', key);
173
+ }
174
+ getTextTemplate(caseDefinitionKey, caseDefinitionVersionTag, key) {
175
+ return this.getTemplate(caseDefinitionKey, caseDefinitionVersionTag, 'text', key);
168
176
  }
169
- getTemplate(caseDefinitionName, templateType, key) {
170
- return this.http.get(`${this.valtimoEndpointUri}v1/case-definition/${caseDefinitionName}/template-type/${templateType}/template/${key}`);
177
+ getTemplate(caseDefinitionKey, caseDefinitionVersionTag, templateType, key) {
178
+ return this.http.get(`${this.valtimoEndpointUri}v1/case-definition/${caseDefinitionKey}/version/${caseDefinitionVersionTag}/template-type/${templateType}/template/${key}`);
171
179
  }
172
180
  addTemplate(template) {
173
181
  return this.http.post(`${this.valtimoEndpointUri}v1/template`, template);
@@ -178,15 +186,22 @@ class FreemarkerTemplateManagementService {
178
186
  updateTemplate(template) {
179
187
  return this.http.put(`${this.valtimoEndpointUri}v1/template`, template);
180
188
  }
181
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: FreemarkerTemplateManagementService, deps: [{ token: i1$1.ConfigService }, { token: i2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
182
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: FreemarkerTemplateManagementService, providedIn: 'root' }); }
189
+ isFinal(caseDefinitionKey, caseDefinitionVersionTag) {
190
+ return this.http
191
+ .get(`${this.valtimoEndpointUri}v1/case-definition/${caseDefinitionKey}/version/${caseDefinitionVersionTag}`, {
192
+ headers: new HttpHeaders().set(InterceptorSkip, '403'),
193
+ })
194
+ .pipe(map(caseDefinition => caseDefinition.final));
195
+ }
196
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: FreemarkerTemplateManagementService, deps: [{ token: i3.ConfigService }, { token: i2.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
197
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: FreemarkerTemplateManagementService, providedIn: 'root' }); }
183
198
  }
184
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: FreemarkerTemplateManagementService, decorators: [{
199
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: FreemarkerTemplateManagementService, decorators: [{
185
200
  type: Injectable,
186
201
  args: [{
187
202
  providedIn: 'root',
188
203
  }]
189
- }], ctorParameters: () => [{ type: i1$1.ConfigService }, { type: i2.HttpClient }] });
204
+ }], ctorParameters: () => [{ type: i3.ConfigService }, { type: i2.HttpClient }] });
190
205
 
191
206
  /*
192
207
  * Copyright 2015-2024 Ritense BV, the Netherlands.
@@ -269,12 +284,12 @@ class GenerateMailContentComponent {
269
284
  });
270
285
  });
271
286
  }
272
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: GenerateMailContentComponent, deps: [{ token: i1.ModalService }, { token: i2$1.DocumentService }, { token: FreemarkerTemplateManagementService }], target: i0.ɵɵFactoryTarget.Component }); }
273
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: GenerateMailContentComponent, selector: "valtimo-generate-mail-content-configuration", inputs: { save$: "save$", disabled$: "disabled$", pluginId: "pluginId", prefillConfiguration$: "prefillConfiguration$" }, outputs: { valid: "valid", configuration: "configuration" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null,\n mailTemplateItems: mailTemplateItems$ | async,\n loading: loading$ | async,\n } as obs\"\n>\n <ng-container *ngIf=\"obs.loading === false; else loading\">\n <v-paragraph [margin]=\"true\" [italic]=\"true\">\n {{ 'generateMailContentDescription' | pluginTranslate: pluginId | async }}\n </v-paragraph>\n <v-form (valueChange)=\"formValueChange($event)\">\n <v-select\n [items]=\"obs.mailTemplateItems\"\n [margin]=\"true\"\n [widthInPx]=\"350\"\n name=\"mailTemplateKey\"\n [title]=\"'mailTemplateKey' | pluginTranslate: pluginId | async\"\n [disabled]=\"obs.disabled\"\n [defaultSelectionId]=\"obs.prefill?.mailTemplateKey\"\n [required]=\"true\"\n [loading]=\"!obs.mailTemplateItems\"\n [tooltip]=\"'mailTemplateKeyTooltip' | pluginTranslate: pluginId | async\"\n ></v-select>\n <v-input\n name=\"processVariableName\"\n [title]=\"'processVariableName' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [defaultValue]=\"obs.prefill?.processVariableName || 'content'\"\n [disabled]=\"obs.disabled\"\n [tooltip]=\"'processVariableNameTooltip' | pluginTranslate: pluginId | async\"\n ></v-input>\n </v-form>\n </ng-container>\n</ng-container>\n\n<ng-template #loading>\n <div class=\"loading-container\">\n <cds-loading></cds-loading>\n </div>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1.FormComponent, selector: "v-form", inputs: ["className"], outputs: ["valueChange"] }, { kind: "component", type: i1.ParagraphComponent, selector: "v-paragraph", inputs: ["center", "fullWidth", "margin", "italic", "loading", "dataTestId"] }, { kind: "component", type: i1.SelectComponent, selector: "v-select", inputs: ["items", "defaultSelection", "defaultSelectionId", "defaultSelectionIds", "disabled", "dropUp", "multiple", "margin", "widthInPx", "notFoundText", "clearAllText", "clearText", "name", "title", "titleTranslationKey", "clearSelectionSubject$", "tooltip", "required", "loading", "loadingText", "placeholder", "smallMargin", "carbonTheme", "appendInline", "dataTestId"], outputs: ["selectedChange"] }, { kind: "component", type: i1.InputComponent, selector: "v-input", inputs: ["name", "type", "title", "titleTranslationKey", "defaultValue", "widthPx", "fullWidth", "margin", "smallMargin", "disabled", "step", "min", "maxLength", "tooltip", "required", "hideNumberSpinBox", "smallLabel", "rows", "clear$", "carbonTheme", "placeholder", "dataTestId"], outputs: ["valueChange"] }, { kind: "component", type: i4$1.Loading, selector: "cds-loading, ibm-loading", inputs: ["title", "isActive", "size", "overlay"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "pipe", type: i6.PluginTranslatePipe, name: "pluginTranslate" }] }); }
287
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: GenerateMailContentComponent, deps: [{ token: i1.ModalService }, { token: i2$1.DocumentService }, { token: FreemarkerTemplateManagementService }], target: i0.ɵɵFactoryTarget.Component }); }
288
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: GenerateMailContentComponent, isStandalone: false, selector: "valtimo-generate-mail-content-configuration", inputs: { save$: "save$", disabled$: "disabled$", pluginId: "pluginId", prefillConfiguration$: "prefillConfiguration$" }, outputs: { valid: "valid", configuration: "configuration" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null,\n mailTemplateItems: mailTemplateItems$ | async,\n loading: loading$ | async,\n } as obs\"\n>\n <ng-container *ngIf=\"obs.loading === false; else loading\">\n <v-paragraph [margin]=\"true\" [italic]=\"true\">\n {{ 'generateMailContentDescription' | pluginTranslate: pluginId | async }}\n </v-paragraph>\n <v-form (valueChange)=\"formValueChange($event)\">\n <v-select\n [items]=\"obs.mailTemplateItems\"\n [margin]=\"true\"\n [widthInPx]=\"350\"\n name=\"mailTemplateKey\"\n [title]=\"'mailTemplateKey' | pluginTranslate: pluginId | async\"\n [disabled]=\"obs.disabled\"\n [defaultSelectionId]=\"obs.prefill?.mailTemplateKey\"\n [required]=\"true\"\n [loading]=\"!obs.mailTemplateItems\"\n [tooltip]=\"'mailTemplateKeyTooltip' | pluginTranslate: pluginId | async\"\n ></v-select>\n <v-input\n name=\"processVariableName\"\n [title]=\"'processVariableName' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [defaultValue]=\"obs.prefill?.processVariableName || 'content'\"\n [disabled]=\"obs.disabled\"\n [tooltip]=\"'processVariableNameTooltip' | pluginTranslate: pluginId | async\"\n ></v-input>\n </v-form>\n </ng-container>\n</ng-container>\n\n<ng-template #loading>\n <div class=\"loading-container\">\n <cds-loading></cds-loading>\n </div>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1.FormComponent, selector: "v-form", inputs: ["className"], outputs: ["valueChange"] }, { kind: "component", type: i1.ParagraphComponent, selector: "v-paragraph", inputs: ["center", "fullWidth", "margin", "italic", "loading", "dataTestId"] }, { kind: "component", type: i1.SelectComponent, selector: "v-select", inputs: ["items", "defaultSelection", "defaultSelectionId", "defaultSelectionIds", "disabled", "dropUp", "multiple", "margin", "widthInPx", "notFoundText", "clearAllText", "clearText", "name", "title", "titleTranslationKey", "clearSelectionSubject$", "tooltip", "required", "loading", "loadingText", "placeholder", "smallMargin", "carbonTheme", "appendInline", "dataTestId"], outputs: ["selectedChange"] }, { kind: "component", type: i1.InputComponent, selector: "v-input", inputs: ["name", "type", "title", "titleTranslationKey", "defaultValue", "widthPx", "fullWidth", "margin", "smallMargin", "disabled", "step", "min", "maxLength", "tooltip", "required", "hideNumberSpinBox", "smallLabel", "rows", "clear$", "carbonTheme", "placeholder", "dataTestId", "trim"], outputs: ["valueChange"] }, { kind: "component", type: i4$1.Loading, selector: "cds-loading, ibm-loading", inputs: ["title", "isActive", "size", "overlay"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "pipe", type: i6.PluginTranslatePipe, name: "pluginTranslate" }] }); }
274
289
  }
275
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: GenerateMailContentComponent, decorators: [{
290
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: GenerateMailContentComponent, decorators: [{
276
291
  type: Component,
277
- args: [{ selector: 'valtimo-generate-mail-content-configuration', template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null,\n mailTemplateItems: mailTemplateItems$ | async,\n loading: loading$ | async,\n } as obs\"\n>\n <ng-container *ngIf=\"obs.loading === false; else loading\">\n <v-paragraph [margin]=\"true\" [italic]=\"true\">\n {{ 'generateMailContentDescription' | pluginTranslate: pluginId | async }}\n </v-paragraph>\n <v-form (valueChange)=\"formValueChange($event)\">\n <v-select\n [items]=\"obs.mailTemplateItems\"\n [margin]=\"true\"\n [widthInPx]=\"350\"\n name=\"mailTemplateKey\"\n [title]=\"'mailTemplateKey' | pluginTranslate: pluginId | async\"\n [disabled]=\"obs.disabled\"\n [defaultSelectionId]=\"obs.prefill?.mailTemplateKey\"\n [required]=\"true\"\n [loading]=\"!obs.mailTemplateItems\"\n [tooltip]=\"'mailTemplateKeyTooltip' | pluginTranslate: pluginId | async\"\n ></v-select>\n <v-input\n name=\"processVariableName\"\n [title]=\"'processVariableName' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [defaultValue]=\"obs.prefill?.processVariableName || 'content'\"\n [disabled]=\"obs.disabled\"\n [tooltip]=\"'processVariableNameTooltip' | pluginTranslate: pluginId | async\"\n ></v-input>\n </v-form>\n </ng-container>\n</ng-container>\n\n<ng-template #loading>\n <div class=\"loading-container\">\n <cds-loading></cds-loading>\n </div>\n</ng-template>\n" }]
292
+ args: [{ standalone: false, selector: 'valtimo-generate-mail-content-configuration', template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null,\n mailTemplateItems: mailTemplateItems$ | async,\n loading: loading$ | async,\n } as obs\"\n>\n <ng-container *ngIf=\"obs.loading === false; else loading\">\n <v-paragraph [margin]=\"true\" [italic]=\"true\">\n {{ 'generateMailContentDescription' | pluginTranslate: pluginId | async }}\n </v-paragraph>\n <v-form (valueChange)=\"formValueChange($event)\">\n <v-select\n [items]=\"obs.mailTemplateItems\"\n [margin]=\"true\"\n [widthInPx]=\"350\"\n name=\"mailTemplateKey\"\n [title]=\"'mailTemplateKey' | pluginTranslate: pluginId | async\"\n [disabled]=\"obs.disabled\"\n [defaultSelectionId]=\"obs.prefill?.mailTemplateKey\"\n [required]=\"true\"\n [loading]=\"!obs.mailTemplateItems\"\n [tooltip]=\"'mailTemplateKeyTooltip' | pluginTranslate: pluginId | async\"\n ></v-select>\n <v-input\n name=\"processVariableName\"\n [title]=\"'processVariableName' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [defaultValue]=\"obs.prefill?.processVariableName || 'content'\"\n [disabled]=\"obs.disabled\"\n [tooltip]=\"'processVariableNameTooltip' | pluginTranslate: pluginId | async\"\n ></v-input>\n </v-form>\n </ng-container>\n</ng-container>\n\n<ng-template #loading>\n <div class=\"loading-container\">\n <cds-loading></cds-loading>\n </div>\n</ng-template>\n" }]
278
293
  }], ctorParameters: () => [{ type: i1.ModalService }, { type: i2$1.DocumentService }, { type: FreemarkerTemplateManagementService }], propDecorators: { save$: [{
279
294
  type: Input
280
295
  }], disabled$: [{
@@ -354,12 +369,12 @@ class GenerateMailFileComponent {
354
369
  });
355
370
  });
356
371
  }
357
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: GenerateMailFileComponent, deps: [{ token: i1.ModalService }, { token: i2$1.DocumentService }, { token: FreemarkerTemplateManagementService }], target: i0.ɵɵFactoryTarget.Component }); }
358
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: GenerateMailFileComponent, selector: "valtimo-generate-mail-file-configuration", inputs: { save$: "save$", disabled$: "disabled$", pluginId: "pluginId", prefillConfiguration$: "prefillConfiguration$" }, outputs: { valid: "valid", configuration: "configuration" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null,\n mailTemplateItems: mailTemplateItems$ | async,\n loading: loading$ | async,\n } as obs\"\n>\n <ng-container *ngIf=\"obs.loading === false; else loading\">\n <v-paragraph [margin]=\"true\" [italic]=\"true\">\n {{ 'generateMailFileDescription' | pluginTranslate: pluginId | async }}\n </v-paragraph>\n <v-form (valueChange)=\"formValueChange($event)\">\n <v-select\n [items]=\"obs.mailTemplateItems\"\n [margin]=\"true\"\n [widthInPx]=\"350\"\n name=\"mailTemplateKey\"\n [title]=\"'mailTemplateKey' | pluginTranslate: pluginId | async\"\n [disabled]=\"obs.disabled\"\n [defaultSelectionId]=\"obs.prefill?.mailTemplateKey\"\n [required]=\"true\"\n [loading]=\"!obs.mailTemplateItems\"\n [tooltip]=\"'mailTemplateKeyTooltip' | pluginTranslate: pluginId | async\"\n ></v-select>\n <v-input\n name=\"processVariableName\"\n [title]=\"'processVariableName' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [defaultValue]=\"obs.prefill?.processVariableName || 'contentId'\"\n [disabled]=\"obs.disabled\"\n [tooltip]=\"'processVariableNameTooltip' | pluginTranslate: pluginId | async\"\n ></v-input>\n </v-form>\n </ng-container>\n</ng-container>\n\n<ng-template #loading>\n <div class=\"loading-container\">\n <cds-loading></cds-loading>\n </div>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1.FormComponent, selector: "v-form", inputs: ["className"], outputs: ["valueChange"] }, { kind: "component", type: i1.ParagraphComponent, selector: "v-paragraph", inputs: ["center", "fullWidth", "margin", "italic", "loading", "dataTestId"] }, { kind: "component", type: i1.SelectComponent, selector: "v-select", inputs: ["items", "defaultSelection", "defaultSelectionId", "defaultSelectionIds", "disabled", "dropUp", "multiple", "margin", "widthInPx", "notFoundText", "clearAllText", "clearText", "name", "title", "titleTranslationKey", "clearSelectionSubject$", "tooltip", "required", "loading", "loadingText", "placeholder", "smallMargin", "carbonTheme", "appendInline", "dataTestId"], outputs: ["selectedChange"] }, { kind: "component", type: i1.InputComponent, selector: "v-input", inputs: ["name", "type", "title", "titleTranslationKey", "defaultValue", "widthPx", "fullWidth", "margin", "smallMargin", "disabled", "step", "min", "maxLength", "tooltip", "required", "hideNumberSpinBox", "smallLabel", "rows", "clear$", "carbonTheme", "placeholder", "dataTestId"], outputs: ["valueChange"] }, { kind: "component", type: i4$1.Loading, selector: "cds-loading, ibm-loading", inputs: ["title", "isActive", "size", "overlay"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "pipe", type: i6.PluginTranslatePipe, name: "pluginTranslate" }] }); }
372
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: GenerateMailFileComponent, deps: [{ token: i1.ModalService }, { token: i2$1.DocumentService }, { token: FreemarkerTemplateManagementService }], target: i0.ɵɵFactoryTarget.Component }); }
373
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: GenerateMailFileComponent, isStandalone: false, selector: "valtimo-generate-mail-file-configuration", inputs: { save$: "save$", disabled$: "disabled$", pluginId: "pluginId", prefillConfiguration$: "prefillConfiguration$" }, outputs: { valid: "valid", configuration: "configuration" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null,\n mailTemplateItems: mailTemplateItems$ | async,\n loading: loading$ | async,\n } as obs\"\n>\n <ng-container *ngIf=\"obs.loading === false; else loading\">\n <v-paragraph [margin]=\"true\" [italic]=\"true\">\n {{ 'generateMailFileDescription' | pluginTranslate: pluginId | async }}\n </v-paragraph>\n <v-form (valueChange)=\"formValueChange($event)\">\n <v-select\n [items]=\"obs.mailTemplateItems\"\n [margin]=\"true\"\n [widthInPx]=\"350\"\n name=\"mailTemplateKey\"\n [title]=\"'mailTemplateKey' | pluginTranslate: pluginId | async\"\n [disabled]=\"obs.disabled\"\n [defaultSelectionId]=\"obs.prefill?.mailTemplateKey\"\n [required]=\"true\"\n [loading]=\"!obs.mailTemplateItems\"\n [tooltip]=\"'mailTemplateKeyTooltip' | pluginTranslate: pluginId | async\"\n ></v-select>\n <v-input\n name=\"processVariableName\"\n [title]=\"'processVariableName' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [defaultValue]=\"obs.prefill?.processVariableName || 'contentId'\"\n [disabled]=\"obs.disabled\"\n [tooltip]=\"'processVariableNameTooltip' | pluginTranslate: pluginId | async\"\n ></v-input>\n </v-form>\n </ng-container>\n</ng-container>\n\n<ng-template #loading>\n <div class=\"loading-container\">\n <cds-loading></cds-loading>\n </div>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1.FormComponent, selector: "v-form", inputs: ["className"], outputs: ["valueChange"] }, { kind: "component", type: i1.ParagraphComponent, selector: "v-paragraph", inputs: ["center", "fullWidth", "margin", "italic", "loading", "dataTestId"] }, { kind: "component", type: i1.SelectComponent, selector: "v-select", inputs: ["items", "defaultSelection", "defaultSelectionId", "defaultSelectionIds", "disabled", "dropUp", "multiple", "margin", "widthInPx", "notFoundText", "clearAllText", "clearText", "name", "title", "titleTranslationKey", "clearSelectionSubject$", "tooltip", "required", "loading", "loadingText", "placeholder", "smallMargin", "carbonTheme", "appendInline", "dataTestId"], outputs: ["selectedChange"] }, { kind: "component", type: i1.InputComponent, selector: "v-input", inputs: ["name", "type", "title", "titleTranslationKey", "defaultValue", "widthPx", "fullWidth", "margin", "smallMargin", "disabled", "step", "min", "maxLength", "tooltip", "required", "hideNumberSpinBox", "smallLabel", "rows", "clear$", "carbonTheme", "placeholder", "dataTestId", "trim"], outputs: ["valueChange"] }, { kind: "component", type: i4$1.Loading, selector: "cds-loading, ibm-loading", inputs: ["title", "isActive", "size", "overlay"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "pipe", type: i6.PluginTranslatePipe, name: "pluginTranslate" }] }); }
359
374
  }
360
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: GenerateMailFileComponent, decorators: [{
375
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: GenerateMailFileComponent, decorators: [{
361
376
  type: Component,
362
- args: [{ selector: 'valtimo-generate-mail-file-configuration', template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null,\n mailTemplateItems: mailTemplateItems$ | async,\n loading: loading$ | async,\n } as obs\"\n>\n <ng-container *ngIf=\"obs.loading === false; else loading\">\n <v-paragraph [margin]=\"true\" [italic]=\"true\">\n {{ 'generateMailFileDescription' | pluginTranslate: pluginId | async }}\n </v-paragraph>\n <v-form (valueChange)=\"formValueChange($event)\">\n <v-select\n [items]=\"obs.mailTemplateItems\"\n [margin]=\"true\"\n [widthInPx]=\"350\"\n name=\"mailTemplateKey\"\n [title]=\"'mailTemplateKey' | pluginTranslate: pluginId | async\"\n [disabled]=\"obs.disabled\"\n [defaultSelectionId]=\"obs.prefill?.mailTemplateKey\"\n [required]=\"true\"\n [loading]=\"!obs.mailTemplateItems\"\n [tooltip]=\"'mailTemplateKeyTooltip' | pluginTranslate: pluginId | async\"\n ></v-select>\n <v-input\n name=\"processVariableName\"\n [title]=\"'processVariableName' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [defaultValue]=\"obs.prefill?.processVariableName || 'contentId'\"\n [disabled]=\"obs.disabled\"\n [tooltip]=\"'processVariableNameTooltip' | pluginTranslate: pluginId | async\"\n ></v-input>\n </v-form>\n </ng-container>\n</ng-container>\n\n<ng-template #loading>\n <div class=\"loading-container\">\n <cds-loading></cds-loading>\n </div>\n</ng-template>\n" }]
377
+ args: [{ standalone: false, selector: 'valtimo-generate-mail-file-configuration', template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null,\n mailTemplateItems: mailTemplateItems$ | async,\n loading: loading$ | async,\n } as obs\"\n>\n <ng-container *ngIf=\"obs.loading === false; else loading\">\n <v-paragraph [margin]=\"true\" [italic]=\"true\">\n {{ 'generateMailFileDescription' | pluginTranslate: pluginId | async }}\n </v-paragraph>\n <v-form (valueChange)=\"formValueChange($event)\">\n <v-select\n [items]=\"obs.mailTemplateItems\"\n [margin]=\"true\"\n [widthInPx]=\"350\"\n name=\"mailTemplateKey\"\n [title]=\"'mailTemplateKey' | pluginTranslate: pluginId | async\"\n [disabled]=\"obs.disabled\"\n [defaultSelectionId]=\"obs.prefill?.mailTemplateKey\"\n [required]=\"true\"\n [loading]=\"!obs.mailTemplateItems\"\n [tooltip]=\"'mailTemplateKeyTooltip' | pluginTranslate: pluginId | async\"\n ></v-select>\n <v-input\n name=\"processVariableName\"\n [title]=\"'processVariableName' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [defaultValue]=\"obs.prefill?.processVariableName || 'contentId'\"\n [disabled]=\"obs.disabled\"\n [tooltip]=\"'processVariableNameTooltip' | pluginTranslate: pluginId | async\"\n ></v-input>\n </v-form>\n </ng-container>\n</ng-container>\n\n<ng-template #loading>\n <div class=\"loading-container\">\n <cds-loading></cds-loading>\n </div>\n</ng-template>\n" }]
363
378
  }], ctorParameters: () => [{ type: i1.ModalService }, { type: i2$1.DocumentService }, { type: FreemarkerTemplateManagementService }], propDecorators: { save$: [{
364
379
  type: Input
365
380
  }], disabled$: [{
@@ -374,6 +389,44 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImpo
374
389
  type: Output
375
390
  }] } });
376
391
 
392
+ /*
393
+ * Copyright 2015-2023 Ritense BV, the Netherlands.
394
+ *
395
+ * Licensed under EUPL, Version 1.2 (the "License");
396
+ * you may not use this file except in compliance with the License.
397
+ * You may obtain a copy of the License at
398
+ *
399
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
400
+ *
401
+ * Unless required by applicable law or agreed to in writing, software
402
+ * distributed under the License is distributed on an "AS IS" basis,
403
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
404
+ * See the License for the specific language governing permissions and
405
+ * limitations under the License.
406
+ */
407
+ class MailTemplateDeleteModalComponent {
408
+ constructor() {
409
+ this.deleteEvent = new EventEmitter();
410
+ }
411
+ onDelete(templates) {
412
+ this.deleteEvent.emit(templates);
413
+ }
414
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplateDeleteModalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
415
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: MailTemplateDeleteModalComponent, isStandalone: true, selector: "valtimo-mail-template-delete-modal", inputs: { deleteRowKeys: "deleteRowKeys", showDeleteModal$: "showDeleteModal$" }, outputs: { deleteEvent: "deleteEvent" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-confirmation-modal\n confirmButtonTextTranslationKey=\"interface.delete\"\n confirmButtonType=\"danger\"\n contentTranslationKey=\"template.deleteModalContent\"\n [outputOnConfirm]=\"deleteRowKeys\"\n [showModalSubject$]=\"showDeleteModal$\"\n titleTranslationKey=\"interface.delete\"\n (confirmEvent)=\"onDelete($event)\"\n></valtimo-confirmation-modal>\n", dependencies: [{ kind: "ngmodule", type: ConfirmationModalModule }, { kind: "component", type: i1.ConfirmationModalComponent, selector: "valtimo-confirmation-modal", inputs: ["titleTranslationKey", "title", "content", "contentTranslationKey", "confirmButtonText", "confirmButtonTextTranslationKey", "confirmButtonType", "showOptionalButton", "optionalButtonText", "optionalButtonTextTranslationKey", "optionalButtonType", "cancelButtonText", "cancelButtonTextTranslationKey", "cancelButtonType", "showModalSubject$", "outputOnConfirm", "outputOnOptional", "spacerAfterCancelButton"], outputs: ["confirmEvent", "optionalEvent", "cancelEvent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
416
+ }
417
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplateDeleteModalComponent, decorators: [{
418
+ type: Component,
419
+ args: [{ standalone: true, selector: 'valtimo-mail-template-delete-modal', changeDetection: ChangeDetectionStrategy.OnPush, imports: [
420
+ ConfirmationModalModule
421
+ ], template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-confirmation-modal\n confirmButtonTextTranslationKey=\"interface.delete\"\n confirmButtonType=\"danger\"\n contentTranslationKey=\"template.deleteModalContent\"\n [outputOnConfirm]=\"deleteRowKeys\"\n [showModalSubject$]=\"showDeleteModal$\"\n titleTranslationKey=\"interface.delete\"\n (confirmEvent)=\"onDelete($event)\"\n></valtimo-confirmation-modal>\n" }]
422
+ }], propDecorators: { deleteRowKeys: [{
423
+ type: Input
424
+ }], showDeleteModal$: [{
425
+ type: Input
426
+ }], deleteEvent: [{
427
+ type: Output
428
+ }] } });
429
+
377
430
  /*
378
431
  * Copyright 2015-2023 Ritense BV, the Netherlands.
379
432
  *
@@ -436,13 +489,20 @@ class MailTemplateAddEditModalComponent {
436
489
  }
437
490
  }, CARBON_CONSTANTS.modalAnimationMs);
438
491
  }
439
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplateAddEditModalComponent, deps: [{ token: i1$2.FormBuilder }, { token: i1.KeyGeneratorService }], target: i0.ɵɵFactoryTarget.Component }); }
440
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: MailTemplateAddEditModalComponent, selector: "valtimo-mail-template-add-edit-modal", inputs: { open: "open", type: "type", defaultKeyValue: "defaultKeyValue" }, outputs: { closeEvent: "closeEvent" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal\n *ngIf=\"{\n isAdd: type === 'add'\n } as vars\"\n [open]=\"open\"\n showFooter=\"true\"\n [title]=\"vars.title\"\n valtimoCdsModal\n>\n <cds-modal-header [showCloseButton]=\"true\" (closeSelect)=\"onCancel()\">\n <h3 cdsModalHeaderHeading>\n {{\n vars.isAdd\n ? 'Add'\n : 'Edit'\n }}\n </h3>\n </cds-modal-header>\n\n <section cdsModalContent>\n <form [formGroup]=\"form\">\n <cds-label [invalid]=\"key.dirty && key.invalid\">\n {{ 'Key' }}\n\n <input\n formControlName=\"key\"\n cdsText\n placeholder=\"{{ 'key' }}\"\n [attr.modal-primary-focus]=\"true\"\n [invalid]=\"key.dirty && key.invalid\"\n />\n </cds-label>\n </form>\n </section>\n\n <cds-modal-footer>\n <button cdsButton=\"ghost\" (click)=\"onCancel()\">\n {{ 'interface.cancel' | translate }}\n </button>\n\n <button [disabled]=\"this.form.invalid\" (click)=\"onConfirm()\" cdsButton=\"primary\">\n {{ vars.isAdd ? ('interface.create' | translate) : ('interface.save' | translate) }}\n </button>\n </cds-modal-footer>\n</cds-modal>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i4$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "component", type: i4$1.Label, selector: "cds-label, ibm-label", inputs: ["labelInputID", "disabled", "skeleton", "helperText", "invalidText", "invalid", "warn", "warnText", "ariaLabel"] }, { kind: "directive", type: i4$1.TextInput, selector: "[cdsText], [ibmText]", inputs: ["theme", "size", "invalid", "warn", "skeleton"] }, { kind: "component", type: i4$1.Modal, selector: "cds-modal, ibm-modal", inputs: ["size", "theme", "ariaLabel", "open", "trigger", "hasScrollingContent"], outputs: ["overlaySelected", "close"] }, { kind: "component", type: i4$1.ModalHeader, selector: "cds-modal-header, ibm-modal-header", inputs: ["theme", "closeLabel", "showCloseButton"], outputs: ["closeSelect"] }, { kind: "component", type: i4$1.ModalFooter, selector: "cds-modal-footer, ibm-modal-footer" }, { kind: "directive", type: i4$1.ModalContent, selector: "[cdsModalContent], [ibmModalContent]", inputs: ["hasForm"] }, { kind: "directive", type: i4$1.ModalHeaderHeading, selector: "[cdsModalHeaderHeading], [ibmModalHeaderHeading]" }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
492
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplateAddEditModalComponent, deps: [{ token: i1$1.FormBuilder }, { token: i1.KeyGeneratorService }], target: i0.ɵɵFactoryTarget.Component }); }
493
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: MailTemplateAddEditModalComponent, isStandalone: true, selector: "valtimo-mail-template-add-edit-modal", inputs: { open: "open", type: "type", defaultKeyValue: "defaultKeyValue" }, outputs: { closeEvent: "closeEvent" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal\n *ngIf=\"{\n isAdd: type === 'add'\n } as vars\"\n [open]=\"open\"\n showFooter=\"true\"\n [title]=\"vars.title\"\n valtimoCdsModal\n>\n <cds-modal-header [showCloseButton]=\"true\" (closeSelect)=\"onCancel()\">\n <h3 cdsModalHeaderHeading>\n {{\n vars.isAdd\n ? 'Add'\n : 'Edit'\n }}\n </h3>\n </cds-modal-header>\n\n <section cdsModalContent>\n <form [formGroup]=\"form\">\n <cds-label [invalid]=\"key.dirty && key.invalid\">\n {{ 'Key' }}\n\n <input\n formControlName=\"key\"\n cdsText\n placeholder=\"{{ 'key' }}\"\n [attr.modal-primary-focus]=\"true\"\n [invalid]=\"key.dirty && key.invalid\"\n />\n </cds-label>\n </form>\n </section>\n\n <cds-modal-footer>\n <button cdsButton=\"ghost\" (click)=\"onCancel()\">\n {{ 'interface.cancel' | translate }}\n </button>\n\n <button [disabled]=\"this.form.invalid\" (click)=\"onConfirm()\" cdsButton=\"primary\">\n {{ vars.isAdd ? ('interface.create' | translate) : ('interface.save' | translate) }}\n </button>\n </cds-modal-footer>\n</cds-modal>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i4$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: ModalModule }, { kind: "component", type: i4$1.Modal, selector: "cds-modal, ibm-modal", inputs: ["size", "theme", "ariaLabel", "open", "trigger", "hasScrollingContent"], outputs: ["overlaySelected", "close"] }, { kind: "component", type: i4$1.ModalHeader, selector: "cds-modal-header, ibm-modal-header", inputs: ["theme", "closeLabel", "showCloseButton"], outputs: ["closeSelect"] }, { kind: "component", type: i4$1.ModalFooter, selector: "cds-modal-footer, ibm-modal-footer" }, { kind: "directive", type: i4$1.ModalContent, selector: "[cdsModalContent], [ibmModalContent]", inputs: ["hasForm"] }, { kind: "directive", type: i4$1.ModalHeaderHeading, selector: "[cdsModalHeaderHeading], [ibmModalHeaderHeading]" }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$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]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "ngmodule", type: InputModule }, { kind: "component", type: i4$1.Label, selector: "cds-label, ibm-label", inputs: ["labelInputID", "disabled", "skeleton", "helperText", "invalidText", "invalid", "warn", "warnText", "ariaLabel"] }, { kind: "directive", type: i4$1.TextInput, selector: "[cdsText], [ibmText]", inputs: ["theme", "size", "invalid", "warn", "skeleton"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
441
494
  }
442
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplateAddEditModalComponent, decorators: [{
495
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplateAddEditModalComponent, decorators: [{
443
496
  type: Component,
444
- args: [{ selector: 'valtimo-mail-template-add-edit-modal', changeDetection: ChangeDetectionStrategy.OnPush, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal\n *ngIf=\"{\n isAdd: type === 'add'\n } as vars\"\n [open]=\"open\"\n showFooter=\"true\"\n [title]=\"vars.title\"\n valtimoCdsModal\n>\n <cds-modal-header [showCloseButton]=\"true\" (closeSelect)=\"onCancel()\">\n <h3 cdsModalHeaderHeading>\n {{\n vars.isAdd\n ? 'Add'\n : 'Edit'\n }}\n </h3>\n </cds-modal-header>\n\n <section cdsModalContent>\n <form [formGroup]=\"form\">\n <cds-label [invalid]=\"key.dirty && key.invalid\">\n {{ 'Key' }}\n\n <input\n formControlName=\"key\"\n cdsText\n placeholder=\"{{ 'key' }}\"\n [attr.modal-primary-focus]=\"true\"\n [invalid]=\"key.dirty && key.invalid\"\n />\n </cds-label>\n </form>\n </section>\n\n <cds-modal-footer>\n <button cdsButton=\"ghost\" (click)=\"onCancel()\">\n {{ 'interface.cancel' | translate }}\n </button>\n\n <button [disabled]=\"this.form.invalid\" (click)=\"onConfirm()\" cdsButton=\"primary\">\n {{ vars.isAdd ? ('interface.create' | translate) : ('interface.save' | translate) }}\n </button>\n </cds-modal-footer>\n</cds-modal>\n" }]
445
- }], ctorParameters: () => [{ type: i1$2.FormBuilder }, { type: i1.KeyGeneratorService }], propDecorators: { open: [{
497
+ args: [{ standalone: true, selector: 'valtimo-mail-template-add-edit-modal', changeDetection: ChangeDetectionStrategy.OnPush, imports: [
498
+ CommonModule,
499
+ ButtonModule,
500
+ TranslateModule,
501
+ ModalModule,
502
+ ReactiveFormsModule,
503
+ InputModule
504
+ ], template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal\n *ngIf=\"{\n isAdd: type === 'add'\n } as vars\"\n [open]=\"open\"\n showFooter=\"true\"\n [title]=\"vars.title\"\n valtimoCdsModal\n>\n <cds-modal-header [showCloseButton]=\"true\" (closeSelect)=\"onCancel()\">\n <h3 cdsModalHeaderHeading>\n {{\n vars.isAdd\n ? 'Add'\n : 'Edit'\n }}\n </h3>\n </cds-modal-header>\n\n <section cdsModalContent>\n <form [formGroup]=\"form\">\n <cds-label [invalid]=\"key.dirty && key.invalid\">\n {{ 'Key' }}\n\n <input\n formControlName=\"key\"\n cdsText\n placeholder=\"{{ 'key' }}\"\n [attr.modal-primary-focus]=\"true\"\n [invalid]=\"key.dirty && key.invalid\"\n />\n </cds-label>\n </form>\n </section>\n\n <cds-modal-footer>\n <button cdsButton=\"ghost\" (click)=\"onCancel()\">\n {{ 'interface.cancel' | translate }}\n </button>\n\n <button [disabled]=\"this.form.invalid\" (click)=\"onConfirm()\" cdsButton=\"primary\">\n {{ vars.isAdd ? ('interface.create' | translate) : ('interface.save' | translate) }}\n </button>\n </cds-modal-footer>\n</cds-modal>\n" }]
505
+ }], ctorParameters: () => [{ type: i1$1.FormBuilder }, { type: i1.KeyGeneratorService }], propDecorators: { open: [{
446
506
  type: Input
447
507
  }], type: [{
448
508
  type: Input
@@ -452,42 +512,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImpo
452
512
  type: Output
453
513
  }] } });
454
514
 
455
- /*
456
- * Copyright 2015-2023 Ritense BV, the Netherlands.
457
- *
458
- * Licensed under EUPL, Version 1.2 (the "License");
459
- * you may not use this file except in compliance with the License.
460
- * You may obtain a copy of the License at
461
- *
462
- * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
463
- *
464
- * Unless required by applicable law or agreed to in writing, software
465
- * distributed under the License is distributed on an "AS IS" basis,
466
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
467
- * See the License for the specific language governing permissions and
468
- * limitations under the License.
469
- */
470
- class MailTemplateDeleteModalComponent {
471
- constructor() {
472
- this.deleteEvent = new EventEmitter();
473
- }
474
- onDelete(templates) {
475
- this.deleteEvent.emit(templates);
476
- }
477
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplateDeleteModalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
478
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: MailTemplateDeleteModalComponent, selector: "valtimo-mail-template-delete-modal", inputs: { deleteRowKeys: "deleteRowKeys", showDeleteModal$: "showDeleteModal$" }, outputs: { deleteEvent: "deleteEvent" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-confirmation-modal\n confirmButtonTextTranslationKey=\"interface.delete\"\n confirmButtonType=\"danger\"\n contentTranslationKey=\"template.deleteModalContent\"\n [outputOnConfirm]=\"deleteRowKeys\"\n [showModalSubject$]=\"showDeleteModal$\"\n titleTranslationKey=\"interface.delete\"\n (confirmEvent)=\"onDelete($event)\"\n></valtimo-confirmation-modal>\n", dependencies: [{ kind: "component", type: i1.ConfirmationModalComponent, selector: "valtimo-confirmation-modal", inputs: ["titleTranslationKey", "title", "content", "contentTranslationKey", "confirmButtonText", "confirmButtonTextTranslationKey", "confirmButtonType", "showOptionalButton", "optionalButtonText", "optionalButtonTextTranslationKey", "optionalButtonType", "cancelButtonText", "cancelButtonTextTranslationKey", "cancelButtonType", "showModalSubject$", "outputOnConfirm", "outputOnOptional", "spacerAfterCancelButton"], outputs: ["confirmEvent", "optionalEvent", "cancelEvent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
479
- }
480
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplateDeleteModalComponent, decorators: [{
481
- type: Component,
482
- args: [{ selector: 'valtimo-mail-template-delete-modal', changeDetection: ChangeDetectionStrategy.OnPush, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-confirmation-modal\n confirmButtonTextTranslationKey=\"interface.delete\"\n confirmButtonType=\"danger\"\n contentTranslationKey=\"template.deleteModalContent\"\n [outputOnConfirm]=\"deleteRowKeys\"\n [showModalSubject$]=\"showDeleteModal$\"\n titleTranslationKey=\"interface.delete\"\n (confirmEvent)=\"onDelete($event)\"\n></valtimo-confirmation-modal>\n" }]
483
- }], propDecorators: { deleteRowKeys: [{
484
- type: Input
485
- }], showDeleteModal$: [{
486
- type: Input
487
- }], deleteEvent: [{
488
- type: Output
489
- }] } });
490
-
491
515
  /*
492
516
  * Copyright 2015-2024 Ritense BV, the Netherlands.
493
517
  *
@@ -504,23 +528,23 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImpo
504
528
  * limitations under the License.
505
529
  */
506
530
  class MailTemplateListComponent {
507
- constructor(templateService, router, route) {
531
+ constructor(templateService, router, route, environmentService) {
508
532
  this.templateService = templateService;
509
533
  this.router = router;
510
534
  this.route = route;
535
+ this.environmentService = environmentService;
511
536
  this.fields = [
512
537
  {
513
538
  viewType: ViewType.TEXT,
514
539
  key: 'key',
515
540
  label: 'Key',
516
541
  },
517
- {
518
- viewType: ViewType.BOOLEAN,
519
- key: 'readOnly',
520
- label: 'Read only',
521
- },
522
542
  ];
523
- this._caseDefinitionName$ = this.route.params.pipe(map(params => params?.name), filter(caseDefinitionName => !!caseDefinitionName));
543
+ this._caseDefinitionId$ = getCaseManagementRouteParams(this.route).pipe(filter((params) => !!params?.caseDefinitionKey));
544
+ this.readOnly$ = this._caseDefinitionId$.pipe(switchMap(caseDefinitionId => combineLatest([
545
+ this.environmentService.canUpdateGlobalConfiguration(),
546
+ this.templateService.isFinal(caseDefinitionId.caseDefinitionKey, caseDefinitionId.caseDefinitionVersionTag)
547
+ ]).pipe(map(([canUpdateGlobal, isFinalCase]) => !canUpdateGlobal || isFinalCase), startWith(true))));
524
548
  this.templates$ = new BehaviorSubject(null);
525
549
  this.showAddModal$ = new BehaviorSubject(false);
526
550
  this.showDeleteModal$ = new BehaviorSubject(false);
@@ -538,9 +562,13 @@ class MailTemplateListComponent {
538
562
  this.showAddModal$.next(false);
539
563
  return;
540
564
  }
541
- this._caseDefinitionName$.pipe(take(1), switchMap(caseDefinitionName => this.templateService.addTemplate({ caseDefinitionName, type: 'mail', ...data }))).subscribe(template => {
565
+ this._caseDefinitionId$.pipe(take(1), switchMap(caseDefinitionId => this.templateService.addTemplate({
566
+ caseDefinitionKey: caseDefinitionId.caseDefinitionKey,
567
+ caseDefinitionVersionTag: caseDefinitionId.caseDefinitionVersionTag,
568
+ type: 'mail', ...data
569
+ }))).subscribe(template => {
542
570
  this.showAddModal$.next(false);
543
- this.gotoMailTemplateEditor(template.caseDefinitionName, template.key);
571
+ this.gotoMailTemplateEditor(template.caseDefinitionKey, template.caseDefinitionVersionTag, template.key);
544
572
  });
545
573
  }
546
574
  showDeleteModal() {
@@ -549,19 +577,24 @@ class MailTemplateListComponent {
549
577
  }
550
578
  onDelete(templates) {
551
579
  this.loading$.next(true);
552
- this._caseDefinitionName$.pipe(take(1), switchMap(caseDefinitionName => this.templateService.deleteTemplates({ caseDefinitionName, type: 'mail', templates }))).subscribe(_ => {
580
+ this._caseDefinitionId$.pipe(take(1), switchMap(caseDefinitionId => this.templateService.deleteTemplates({
581
+ caseDefinitionKey: caseDefinitionId.caseDefinitionKey,
582
+ caseDefinitionVersionTag: caseDefinitionId.caseDefinitionVersionTag,
583
+ type: 'mail',
584
+ templates
585
+ }))).subscribe(_ => {
553
586
  this.reloadTemplateList();
554
587
  });
555
588
  }
556
589
  onRowClick(template) {
557
- this._caseDefinitionName$.pipe(take(1)).subscribe(caseDefinitionName => this.gotoMailTemplateEditor(caseDefinitionName, template.key));
590
+ this._caseDefinitionId$.pipe(take(1)).subscribe(caseDefinitionId => this.gotoMailTemplateEditor(caseDefinitionId.caseDefinitionKey, caseDefinitionId.caseDefinitionVersionTag, template.key));
558
591
  }
559
- gotoMailTemplateEditor(caseDefinitionName, key) {
560
- this.router.navigate([`/dossier-management/dossier/${caseDefinitionName}/mail-template/${key}`]);
592
+ gotoMailTemplateEditor(caseDefinitionKey, caseDefinitionVersionTag, key) {
593
+ this.router.navigate([`/case-management/case/${caseDefinitionKey}/version/${caseDefinitionVersionTag}/mail-template/${key}`]);
561
594
  }
562
595
  reloadTemplateList() {
563
596
  this.loading$.next(true);
564
- this._caseDefinitionName$.pipe(switchMap(caseDefinitionName => this.templateService.getAllMailTemplates(caseDefinitionName)), map(templatePage => templatePage.content), take(1)).subscribe(templateListItems => {
597
+ this._caseDefinitionId$.pipe(switchMap((caseDefinitionId) => this.templateService.getAllMailTemplates(caseDefinitionId.caseDefinitionKey, caseDefinitionId.caseDefinitionVersionTag)), map(templatePage => templatePage.content), take(1)).subscribe(templateListItems => {
565
598
  this.templates$.next(templateListItems);
566
599
  this.loading$.next(false);
567
600
  });
@@ -569,13 +602,20 @@ class MailTemplateListComponent {
569
602
  setSelectedTemplateKeys() {
570
603
  this.selectedRowKeys$.next(this.carbonList.selectedItems.map((template) => template.key));
571
604
  }
572
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplateListComponent, deps: [{ token: FreemarkerTemplateManagementService }, { token: i2$2.Router }, { token: i2$2.ActivatedRoute }], target: i0.ɵɵFactoryTarget.Component }); }
573
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: MailTemplateListComponent, selector: "ng-component", viewQueries: [{ propertyName: "carbonList", first: true, predicate: CarbonListComponent, descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-carbon-list\n [header]=\"false\"\n [items]=\"templates$ | async\"\n [fields]=\"fields\"\n [loading]=\"loading$ | async\"\n [showSelectionColumn]=\"true\"\n (rowClicked)=\"onRowClick($event)\"\n>\n <ng-container header> {{ 'Title' }} </ng-container>\n\n <div carbonToolbarContent>\n <ng-container [ngTemplateOutlet]=\"addTemplateButton\"></ng-container>\n </div>\n\n <ng-container carbonToolbarActions>\n <button cdsButton=\"primary\" (click)=\"showDeleteModal()\">\n {{ 'interface.delete' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"trash-can\" size=\"16\"></svg>\n </button>\n </ng-container>\n\n <valtimo-no-results\n [action]=\"addTemplateButton\"\n description=\"{{ 'Come back later.' }}\"\n title=\"{{ 'No templates found' }}\"\n ></valtimo-no-results>\n</valtimo-carbon-list>\n\n<valtimo-mail-template-add-edit-modal\n [open]=\"showAddModal$ | async\"\n (closeEvent)=\"onAdd($event)\"\n></valtimo-mail-template-add-edit-modal>\n\n<ng-container *ngIf=\"{selectedRowKeys: selectedRowKeys$ | async} as obs\">\n <valtimo-mail-template-delete-modal\n [deleteRowKeys]=\"obs.selectedRowKeys\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-mail-template-delete-modal>\n</ng-container>\n\n<ng-template #addTemplateButton>\n <button cdsButton=\"primary\" (click)=\"openAddModal()\">\n {{ 'Add' }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"add\" size=\"16\"></svg>\n </button>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i1.CarbonListComponent, selector: "valtimo-carbon-list", inputs: ["items", "fields", "tableTranslations", "paginatorConfig", "pagination", "loading", "actions", "actionItems", "header", "hideColumnHeader", "initialSortState", "sortState", "isSearchable", "enableSingleSelection", "lastColumnTemplate", "paginationIdentifier", "showSelectionColumn", "striped", "hideToolbar", "lockedTooltipTranslationKey", "movingRowsEnabled", "dragAndDrop", "dragAndDropDisabled"], outputs: ["rowClicked", "paginationClicked", "paginationSet", "search", "sortChanged", "moveRow", "itemsReordered"] }, { kind: "component", type: i1.CarbonNoResultsComponent, selector: "valtimo-no-results", inputs: ["action", "description", "illustration", "title", "smallPadding", "collapseVertically", "alwaysRenderVertically"] }, { kind: "directive", type: i4$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "directive", type: i4$1.IconDirective, selector: "[cdsIcon], [ibmIcon]", inputs: ["ibmIcon", "cdsIcon", "size", "title", "ariaLabel", "ariaLabelledBy", "ariaHidden", "isFocusable"] }, { kind: "component", type: MailTemplateAddEditModalComponent, selector: "valtimo-mail-template-add-edit-modal", inputs: ["open", "type", "defaultKeyValue"], outputs: ["closeEvent"] }, { kind: "component", type: MailTemplateDeleteModalComponent, selector: "valtimo-mail-template-delete-modal", inputs: ["deleteRowKeys", "showDeleteModal$"], outputs: ["deleteEvent"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
605
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplateListComponent, deps: [{ token: FreemarkerTemplateManagementService }, { token: i2$2.Router }, { token: i2$2.ActivatedRoute }, { token: i3.EnvironmentService }], target: i0.ɵɵFactoryTarget.Component }); }
606
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: MailTemplateListComponent, isStandalone: true, selector: "ng-component", viewQueries: [{ propertyName: "carbonList", first: true, predicate: CarbonListComponent, descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-carbon-list\n [header]=\"false\"\n [items]=\"templates$ | async\"\n [fields]=\"fields\"\n [loading]=\"loading$ | async\"\n [showSelectionColumn]=\"!(readOnly$ | async)\"\n (rowClicked)=\"onRowClick($event)\"\n>\n <ng-container header> {{ 'Title' }}</ng-container>\n\n <div carbonToolbarContent>\n <ng-container [ngTemplateOutlet]=\"addTemplateButton\"></ng-container>\n </div>\n\n <ng-container carbonToolbarActions>\n <button cdsButton=\"primary\" (click)=\"showDeleteModal()\">\n {{ 'interface.delete' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"trash-can\" size=\"16\"></svg>\n </button>\n </ng-container>\n\n <valtimo-no-results\n [action]=\"addTemplateButton\"\n description=\"{{ 'Come back later.' }}\"\n title=\"{{ 'No templates found' }}\"\n ></valtimo-no-results>\n</valtimo-carbon-list>\n\n<valtimo-mail-template-add-edit-modal\n [open]=\"showAddModal$ | async\"\n (closeEvent)=\"onAdd($event)\"\n></valtimo-mail-template-add-edit-modal>\n\n<ng-container *ngIf=\"{selectedRowKeys: selectedRowKeys$ | async} as obs\">\n <valtimo-mail-template-delete-modal\n [deleteRowKeys]=\"obs.selectedRowKeys\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-mail-template-delete-modal>\n</ng-container>\n\n<ng-template #addTemplateButton>\n <button cdsButton=\"primary\"\n [disabled]=\"readOnly$ | async\"\n (click)=\"openAddModal()\">\n {{ 'Add' }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"add\" size=\"16\"></svg>\n </button>\n</ng-template>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "ngmodule", type: CarbonListModule }, { kind: "component", type: i1.CarbonListComponent, selector: "valtimo-carbon-list", inputs: ["items", "fields", "tableTranslations", "paginatorConfig", "pagination", "loading", "actions", "actionItems", "header", "hideColumnHeader", "initialSortState", "sortState", "isSearchable", "enableSingleSelection", "lastColumnTemplate", "paginationIdentifier", "showSelectionColumn", "striped", "hideToolbar", "lockedTooltipTranslationKey", "movingRowsEnabled", "dragAndDrop", "dragAndDropDisabled"], outputs: ["rowClicked", "paginationClicked", "paginationSet", "search", "sortChanged", "moveRow", "itemsReordered"] }, { kind: "component", type: i1.CarbonNoResultsComponent, selector: "valtimo-no-results", inputs: ["action", "description", "illustration", "title", "smallPadding", "collapseVertically", "alwaysRenderVertically"] }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i4$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }, { kind: "component", type: MailTemplateDeleteModalComponent, selector: "valtimo-mail-template-delete-modal", inputs: ["deleteRowKeys", "showDeleteModal$"], outputs: ["deleteEvent"] }, { kind: "component", type: MailTemplateAddEditModalComponent, selector: "valtimo-mail-template-add-edit-modal", inputs: ["open", "type", "defaultKeyValue"], outputs: ["closeEvent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
574
607
  }
575
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplateListComponent, decorators: [{
608
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplateListComponent, decorators: [{
576
609
  type: Component,
577
- args: [{ changeDetection: ChangeDetectionStrategy.OnPush, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-carbon-list\n [header]=\"false\"\n [items]=\"templates$ | async\"\n [fields]=\"fields\"\n [loading]=\"loading$ | async\"\n [showSelectionColumn]=\"true\"\n (rowClicked)=\"onRowClick($event)\"\n>\n <ng-container header> {{ 'Title' }} </ng-container>\n\n <div carbonToolbarContent>\n <ng-container [ngTemplateOutlet]=\"addTemplateButton\"></ng-container>\n </div>\n\n <ng-container carbonToolbarActions>\n <button cdsButton=\"primary\" (click)=\"showDeleteModal()\">\n {{ 'interface.delete' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"trash-can\" size=\"16\"></svg>\n </button>\n </ng-container>\n\n <valtimo-no-results\n [action]=\"addTemplateButton\"\n description=\"{{ 'Come back later.' }}\"\n title=\"{{ 'No templates found' }}\"\n ></valtimo-no-results>\n</valtimo-carbon-list>\n\n<valtimo-mail-template-add-edit-modal\n [open]=\"showAddModal$ | async\"\n (closeEvent)=\"onAdd($event)\"\n></valtimo-mail-template-add-edit-modal>\n\n<ng-container *ngIf=\"{selectedRowKeys: selectedRowKeys$ | async} as obs\">\n <valtimo-mail-template-delete-modal\n [deleteRowKeys]=\"obs.selectedRowKeys\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-mail-template-delete-modal>\n</ng-container>\n\n<ng-template #addTemplateButton>\n <button cdsButton=\"primary\" (click)=\"openAddModal()\">\n {{ 'Add' }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"add\" size=\"16\"></svg>\n </button>\n</ng-template>\n" }]
578
- }], ctorParameters: () => [{ type: FreemarkerTemplateManagementService }, { type: i2$2.Router }, { type: i2$2.ActivatedRoute }], propDecorators: { carbonList: [{
610
+ args: [{ standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [
611
+ CommonModule,
612
+ CarbonListModule,
613
+ ButtonModule,
614
+ TranslateModule,
615
+ MailTemplateDeleteModalComponent,
616
+ MailTemplateAddEditModalComponent
617
+ ], template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-carbon-list\n [header]=\"false\"\n [items]=\"templates$ | async\"\n [fields]=\"fields\"\n [loading]=\"loading$ | async\"\n [showSelectionColumn]=\"!(readOnly$ | async)\"\n (rowClicked)=\"onRowClick($event)\"\n>\n <ng-container header> {{ 'Title' }}</ng-container>\n\n <div carbonToolbarContent>\n <ng-container [ngTemplateOutlet]=\"addTemplateButton\"></ng-container>\n </div>\n\n <ng-container carbonToolbarActions>\n <button cdsButton=\"primary\" (click)=\"showDeleteModal()\">\n {{ 'interface.delete' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"trash-can\" size=\"16\"></svg>\n </button>\n </ng-container>\n\n <valtimo-no-results\n [action]=\"addTemplateButton\"\n description=\"{{ 'Come back later.' }}\"\n title=\"{{ 'No templates found' }}\"\n ></valtimo-no-results>\n</valtimo-carbon-list>\n\n<valtimo-mail-template-add-edit-modal\n [open]=\"showAddModal$ | async\"\n (closeEvent)=\"onAdd($event)\"\n></valtimo-mail-template-add-edit-modal>\n\n<ng-container *ngIf=\"{selectedRowKeys: selectedRowKeys$ | async} as obs\">\n <valtimo-mail-template-delete-modal\n [deleteRowKeys]=\"obs.selectedRowKeys\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-mail-template-delete-modal>\n</ng-container>\n\n<ng-template #addTemplateButton>\n <button cdsButton=\"primary\"\n [disabled]=\"readOnly$ | async\"\n (click)=\"openAddModal()\">\n {{ 'Add' }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"add\" size=\"16\"></svg>\n </button>\n</ng-template>\n" }]
618
+ }], ctorParameters: () => [{ type: FreemarkerTemplateManagementService }, { type: i2$2.Router }, { type: i2$2.ActivatedRoute }, { type: i3.EnvironmentService }], propDecorators: { carbonList: [{
579
619
  type: ViewChild,
580
620
  args: [CarbonListComponent]
581
621
  }] } });
@@ -596,7 +636,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImpo
596
636
  * limitations under the License.
597
637
  */
598
638
  class MailTemplateEditorComponent {
599
- constructor(templateService, route, pageTitleService, router, notificationService, translateService, breadcrumbService) {
639
+ constructor(templateService, route, pageTitleService, router, notificationService, translateService, breadcrumbService, environmentService) {
600
640
  this.templateService = templateService;
601
641
  this.route = route;
602
642
  this.pageTitleService = pageTitleService;
@@ -604,6 +644,7 @@ class MailTemplateEditorComponent {
604
644
  this.notificationService = notificationService;
605
645
  this.translateService = translateService;
606
646
  this.breadcrumbService = breadcrumbService;
647
+ this.environmentService = environmentService;
607
648
  this.model$ = new BehaviorSubject(null);
608
649
  this.template$ = new BehaviorSubject(null);
609
650
  this.saveDisabled$ = new BehaviorSubject(true);
@@ -611,8 +652,12 @@ class MailTemplateEditorComponent {
611
652
  this.moreDisabled$ = new BehaviorSubject(true);
612
653
  this.showDeleteModal$ = new BehaviorSubject(false);
613
654
  this.updatedModelValue$ = new BehaviorSubject('');
614
- this._caseDefinitionName$ = this.route.params.pipe(map(params => params?.name), filter(caseDefinitionName => !!caseDefinitionName));
615
- this.templateKey$ = this.route.params.pipe(map(params => params?.key), filter(templateKey => !!templateKey));
655
+ this._caseDefinitionId$ = getCaseManagementRouteParams(this.route).pipe(filter((params) => !!params?.caseDefinitionKey));
656
+ this.templateKey$ = combineLatest([this.route.params, this.route.parent.params]).pipe(map(([params, parentParams]) => params?.templateKey || parentParams?.templateKey), filter(templateKey => !!templateKey));
657
+ this.readOnly$ = this._caseDefinitionId$.pipe(switchMap(caseDefinitionId => combineLatest([
658
+ this.environmentService.canUpdateGlobalConfiguration(),
659
+ this.templateService.isFinal(caseDefinitionId.caseDefinitionKey, caseDefinitionId.caseDefinitionVersionTag)
660
+ ]).pipe(map(([canUpdateGlobal, isFinalCase]) => !canUpdateGlobal || isFinalCase), startWith(true))));
616
661
  }
617
662
  ngOnInit() {
618
663
  this.loadTemplate();
@@ -623,6 +668,7 @@ class MailTemplateEditorComponent {
623
668
  ngOnDestroy() {
624
669
  this.pageTitleService.enableReset();
625
670
  this.breadcrumbService.clearThirdBreadcrumb();
671
+ this.breadcrumbService.clearFourthBreadcrumb();
626
672
  }
627
673
  onValid(valid) {
628
674
  this.saveDisabled$.next(valid === false);
@@ -634,9 +680,10 @@ class MailTemplateEditorComponent {
634
680
  this.disableEditor();
635
681
  this.disableSave();
636
682
  this.disableMore();
637
- combineLatest([this.updatedModelValue$, this._caseDefinitionName$, this.templateKey$]).pipe(switchMap(([updatedModelValue, caseDefinitionName, templateKey]) => this.templateService.updateTemplate({
683
+ combineLatest([this.updatedModelValue$, this._caseDefinitionId$, this.templateKey$]).pipe(switchMap(([updatedModelValue, caseDefinitionId, templateKey]) => this.templateService.updateTemplate({
638
684
  key: templateKey,
639
- caseDefinitionName,
685
+ caseDefinitionKey: caseDefinitionId.caseDefinitionKey,
686
+ caseDefinitionVersionTag: caseDefinitionId.caseDefinitionVersionTag,
640
687
  type: 'mail',
641
688
  content: updatedModelValue,
642
689
  })), take(1)).subscribe({
@@ -659,15 +706,20 @@ class MailTemplateEditorComponent {
659
706
  this.disableEditor();
660
707
  this.disableSave();
661
708
  this.disableMore();
662
- this._caseDefinitionName$.pipe(take(1)).subscribe(caseDefinitionName => this.templateService.deleteTemplates({ caseDefinitionName, type: 'mail', templates }).pipe(take(1)).subscribe(_ => this.router.navigate([`/dossier-management/dossier/${caseDefinitionName}`])));
709
+ this._caseDefinitionId$.pipe(take(1)).subscribe(caseDefinitionId => this.templateService.deleteTemplates({
710
+ caseDefinitionKey: caseDefinitionId.caseDefinitionKey,
711
+ caseDefinitionVersionTag: caseDefinitionId.caseDefinitionVersionTag,
712
+ type: 'mail',
713
+ templates
714
+ }).pipe(take(1)).subscribe(_ => this.router.navigate([`/case-management/case/${caseDefinitionId.caseDefinitionKey}/version/${caseDefinitionId.caseDefinitionVersionTag}/mail-template`])));
663
715
  }
664
716
  showDeleteModal() {
665
717
  this.showDeleteModal$.next(true);
666
718
  }
667
719
  loadTemplate() {
668
- combineLatest([this._caseDefinitionName$, this.templateKey$]).pipe(tap(([_, key]) => {
720
+ combineLatest([this._caseDefinitionId$, this.templateKey$]).pipe(tap(([_, key]) => {
669
721
  this.pageTitleService.setCustomPageTitle(`Mail template: ${key}`, true);
670
- }), switchMap(([caseDefinitionName, key]) => this.templateService.getMailTemplate(caseDefinitionName, key)), take(1)).subscribe(result => {
722
+ }), switchMap(([caseDefinitionId, key]) => this.templateService.getMailTemplate(caseDefinitionId.caseDefinitionKey, caseDefinitionId.caseDefinitionVersionTag, key)), take(1)).subscribe(result => {
671
723
  this.enableMore();
672
724
  this.enableSave();
673
725
  this.enableEditor();
@@ -706,15 +758,23 @@ class MailTemplateEditorComponent {
706
758
  }
707
759
  refreshViewer(html) {
708
760
  setTimeout(() => {
709
- document.getElementById('html-viewer-iframe').srcdoc = html;
710
- });
761
+ const htmlViewer = document.getElementById('html-viewer-iframe');
762
+ if (htmlViewer) {
763
+ htmlViewer.srcdoc = html;
764
+ }
765
+ }, 100);
711
766
  }
712
767
  initBreadcrumb() {
713
- this._caseDefinitionName$.subscribe(caseDefinitionName => {
768
+ this._caseDefinitionId$.subscribe(caseDefinitionId => {
714
769
  this.breadcrumbService.setThirdBreadcrumb({
715
- route: [`/dossier-management/dossier/${caseDefinitionName}`],
716
- content: caseDefinitionName,
717
- href: `/dossier-management/dossier/${caseDefinitionName}`,
770
+ route: [`/case-management/case/${caseDefinitionId.caseDefinitionKey}/version/${caseDefinitionId.caseDefinitionVersionTag}`],
771
+ content: `${caseDefinitionId.caseDefinitionKey}:${caseDefinitionId.caseDefinitionVersionTag}`,
772
+ href: `/case-management/case/${caseDefinitionId.caseDefinitionKey}/version/${caseDefinitionId.caseDefinitionVersionTag}`,
773
+ });
774
+ this.breadcrumbService.setFourthBreadcrumb({
775
+ route: [`/case-management/case/${caseDefinitionId.caseDefinitionKey}/version/${caseDefinitionId.caseDefinitionVersionTag}/mail-template`],
776
+ content: 'Mail template',
777
+ href: `/case-management/case/${caseDefinitionId.caseDefinitionKey}/version/${caseDefinitionId.caseDefinitionVersionTag}/mail-template`,
718
778
  });
719
779
  });
720
780
  }
@@ -729,13 +789,24 @@ class MailTemplateEditorComponent {
729
789
  title: this.translateService.instant('Saved successfully'),
730
790
  });
731
791
  }
732
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplateEditorComponent, deps: [{ token: FreemarkerTemplateManagementService }, { token: i2$2.ActivatedRoute }, { token: i1.PageTitleService }, { token: i2$2.Router }, { token: i4$1.NotificationService }, { token: i5.TranslateService }, { token: i1.BreadcrumbService }], target: i0.ɵɵFactoryTarget.Component }); }
733
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: MailTemplateEditorComponent, selector: "ng-component", providers: [NotificationService], ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"{\n model: model$ | async,\n updatedModelValue: updatedModelValue$ | async,\n template: template$ | async,\n } as obs\">\n\n <div class=\"template-explanation\">\n Mail templates use <a target=\"_blank\" href=\"https://www.w3schools.com/html/html_intro.asp\">HTML</a> for the mail\n layout. <a target=\"_blank\" href=\"https://freemarker.apache.org/docs/dgui_quickstart_basics.html\">FreeMarker</a>\n can be used to create placeholders inside the HTML. The data-model for FreeMarker is based upon <a\n target=\"_blank\" href=\"https://docs.valtimo.nl/reference/modules/value-resolver\">Valtimo value-resolvers</a>\n with a slightly different notation. For example: $&#123;doc.firstName&#125;. Retrieves\n the `firstName` from the case.\n </div>\n\n <cds-tabs type=\"contained\">\n <cds-tab [active]=\"true\" [heading]=\"'Editor'\">\n <valtimo-editor\n [model]=\"obs.model\"\n [disabled]=\"(editorDisabled$ | async) || obs.template.readOnly\"\n (validEvent)=\"onValid($event)\"\n (valueChangeEvent)=\"onValueChange($event)\"\n [fitPage]=\"true\"\n [fitPageExtraSpace]=\"80\"\n ></valtimo-editor>\n </cds-tab>\n <cds-tab [heading]=\"'Viewer'\" (selected)=\"onSelectedTabViewer()\">\n <iframe title=\"HTML Viewer\" id=\"html-viewer-iframe\">\n </iframe>\n </cds-tab>\n </cds-tabs>\n</ng-container>\n\n<ng-container renderInPageHeader>\n <ng-template>\n <div *ngIf=\"{\n model: model$ | async,\n moreDisabled: moreDisabled$ | async,\n template: template$ | async,\n } as obs\"\n class=\"buttons-container\"\n >\n <cds-overflow-menu class=\"overflow-button\">\n <cds-overflow-menu-option\n [disabled]=\"obs.moreDisabled || obs.template.readOnly\"\n type=\"danger\"\n (selected)=\"showDeleteModal()\"\n >{{ 'interface.delete' | translate }}\n </cds-overflow-menu-option\n >\n </cds-overflow-menu>\n\n <button\n [disabled]=\"(saveDisabled$ | async) || obs.template.readOnly\"\n cdsButton=\"primary\"\n size=\"md\"\n (click)=\"updateTemplate()\"\n >\n {{ 'interface.save' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"save\" size=\"16\"></svg>\n </button>\n </div>\n </ng-template>\n</ng-container>\n\n<ng-container *ngIf=\"{templateKey: templateKey$ | async} as obs\">\n <valtimo-mail-template-delete-modal\n [deleteRowKeys]=\"[obs.templateKey]\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-mail-template-delete-modal>\n</ng-container>\n", styles: ["::ng-deep .cds--tab-content{background:var(--cds-layer)!important}::ng-deep #html-viewer-iframe{width:100%;height:calc(100vh - 219px)}.loading-container{display:flex;width:100%;justify-content:center}.overflow-button{margin-right:16px}.buttons-container{display:flex;flex-direction:row}.template-explanation{margin-top:16px;margin-bottom:24px}\n/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1.EditorComponent, selector: "valtimo-editor", inputs: ["editorOptions", "model", "disabled", "formatOnLoad", "widthPx", "heightPx", "heightStyle", "jsonSchema", "fitPage", "fitPageExtraSpace"], outputs: ["validEvent", "valueChangeEvent"] }, { kind: "directive", type: i4$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "component", type: i4$1.OverflowMenu, selector: "cds-overflow-menu, ibm-overflow-menu", inputs: ["buttonLabel", "flip", "placement", "open", "customTrigger", "offset", "wrapperClass", "triggerClass"], outputs: ["openChange"] }, { kind: "component", type: i4$1.OverflowMenuOption, selector: "cds-overflow-menu-option, ibm-overflow-menu-option", inputs: ["divider", "type", "disabled", "href", "target", "innerClass"], outputs: ["selected"] }, { kind: "directive", type: i4$1.IconDirective, selector: "[cdsIcon], [ibmIcon]", inputs: ["ibmIcon", "cdsIcon", "size", "title", "ariaLabel", "ariaLabelledBy", "ariaHidden", "isFocusable"] }, { kind: "directive", type: i1.RenderInPageHeaderDirective, selector: "[renderInPageHeader]", inputs: ["fullWidth"] }, { kind: "component", type: i4$1.Tabs, selector: "cds-tabs, ibm-tabs", inputs: ["position", "cacheActive", "followFocus", "isNavigation", "ariaLabel", "ariaLabelledby", "type", "theme", "skeleton"] }, { kind: "component", type: i4$1.Tab, selector: "cds-tab, ibm-tab", inputs: ["heading", "title", "context", "active", "disabled", "tabIndex", "id", "cacheActive", "tabContent", "templateContext"], outputs: ["selected"] }, { kind: "component", type: MailTemplateDeleteModalComponent, selector: "valtimo-mail-template-delete-modal", inputs: ["deleteRowKeys", "showDeleteModal$"], outputs: ["deleteEvent"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
792
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplateEditorComponent, deps: [{ token: FreemarkerTemplateManagementService }, { token: i2$2.ActivatedRoute }, { token: i1.PageTitleService }, { token: i2$2.Router }, { token: i4$1.NotificationService }, { token: i5.TranslateService }, { token: i1.BreadcrumbService }, { token: i3.EnvironmentService }], target: i0.ɵɵFactoryTarget.Component }); }
793
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: MailTemplateEditorComponent, isStandalone: true, selector: "ng-component", providers: [NotificationService], ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"{\n model: model$ | async,\n updatedModelValue: updatedModelValue$ | async,\n template: template$ | async,\n } as obs\">\n\n <div class=\"template-explanation\">\n Mail templates use <a target=\"_blank\" href=\"https://www.w3schools.com/html/html_intro.asp\">HTML</a> for the mail\n layout. <a target=\"_blank\" href=\"https://freemarker.apache.org/docs/dgui_quickstart_basics.html\">FreeMarker</a>\n can be used to create placeholders inside the HTML. The data-model for FreeMarker is based upon <a\n target=\"_blank\" href=\"https://docs.valtimo.nl/reference/modules/value-resolver\">Valtimo value-resolvers</a>\n with a slightly different notation. For example: $&#123;doc.firstName&#125;. Retrieves\n the `firstName` from the case.\n </div>\n\n <cds-tabs type=\"contained\">\n <cds-tab [active]=\"true\" [heading]=\"'Editor'\">\n <valtimo-editor\n [model]=\"obs.model\"\n [disabled]=\"(editorDisabled$ | async) || (readOnly$ | async)\"\n (validEvent)=\"onValid($event)\"\n (valueChangeEvent)=\"onValueChange($event)\"\n [fitPage]=\"true\"\n [fitPageExtraSpace]=\"80\"\n ></valtimo-editor>\n </cds-tab>\n <cds-tab [heading]=\"'Viewer'\" (selected)=\"onSelectedTabViewer()\">\n <iframe title=\"HTML Viewer\" id=\"html-viewer-iframe\">\n </iframe>\n </cds-tab>\n </cds-tabs>\n</ng-container>\n\n<ng-container renderInPageHeader>\n <ng-template>\n <div *ngIf=\"{\n model: model$ | async,\n moreDisabled: moreDisabled$ | async,\n template: template$ | async,\n } as obs\"\n class=\"buttons-container\"\n >\n <cds-overflow-menu class=\"overflow-button\">\n <cds-overflow-menu-option\n [disabled]=\"obs.moreDisabled || (readOnly$ | async)\"\n type=\"danger\"\n (selected)=\"showDeleteModal()\"\n >{{ 'interface.delete' | translate }}\n </cds-overflow-menu-option\n >\n </cds-overflow-menu>\n\n <button\n [disabled]=\"(saveDisabled$ | async) || (readOnly$ | async)\"\n cdsButton=\"primary\"\n size=\"md\"\n (click)=\"updateTemplate()\"\n >\n {{ 'interface.save' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"save\" size=\"16\"></svg>\n </button>\n </div>\n </ng-template>\n</ng-container>\n\n<ng-container *ngIf=\"{templateKey: templateKey$ | async} as obs\">\n <valtimo-mail-template-delete-modal\n [deleteRowKeys]=\"[obs.templateKey]\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-mail-template-delete-modal>\n</ng-container>\n", styles: ["::ng-deep .cds--tab-content{background:var(--cds-layer)!important}::ng-deep #html-viewer-iframe{width:100%;height:calc(100vh - 219px)}.loading-container{display:flex;width:100%;justify-content:center}.overflow-button{margin-right:16px}.buttons-container{display:flex;flex-direction:row}.template-explanation{margin-top:16px;margin-bottom:24px}\n/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: TabsModule }, { kind: "component", type: i4$1.Tabs, selector: "cds-tabs, ibm-tabs", inputs: ["position", "cacheActive", "followFocus", "isNavigation", "ariaLabel", "ariaLabelledby", "type", "theme", "skeleton"] }, { kind: "component", type: i4$1.Tab, selector: "cds-tab, ibm-tab", inputs: ["heading", "title", "context", "active", "disabled", "tabIndex", "id", "cacheActive", "tabContent", "templateContext"], outputs: ["selected"] }, { kind: "ngmodule", type: DialogModule }, { kind: "component", type: i4$1.OverflowMenu, selector: "cds-overflow-menu, ibm-overflow-menu", inputs: ["buttonLabel", "description", "flip", "placement", "open", "customTrigger", "offset", "wrapperClass", "triggerClass"], outputs: ["openChange"] }, { kind: "component", type: i4$1.OverflowMenuOption, selector: "cds-overflow-menu-option, ibm-overflow-menu-option", inputs: ["divider", "type", "disabled", "href", "target", "innerClass"], outputs: ["selected"] }, { kind: "ngmodule", type: ValtimoCdsOverflowButtonDirectiveModule }, { kind: "component", type: MailTemplateDeleteModalComponent, selector: "valtimo-mail-template-delete-modal", inputs: ["deleteRowKeys", "showDeleteModal$"], outputs: ["deleteEvent"] }, { kind: "ngmodule", type: CarbonListModule }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i4$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: EditorModule }, { kind: "component", type: i1.EditorComponent, selector: "valtimo-editor", inputs: ["editorOptions", "model", "disabled", "formatOnLoad", "widthPx", "heightPx", "heightStyle", "jsonSchema", "fitPage", "fitPageExtraSpace"], outputs: ["validEvent", "valueChangeEvent"] }, { kind: "ngmodule", type: RenderInPageHeaderDirectiveModule }, { kind: "directive", type: i1.RenderInPageHeaderDirective, selector: "[renderInPageHeader]", inputs: ["fullWidth"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
734
794
  }
735
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplateEditorComponent, decorators: [{
795
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplateEditorComponent, decorators: [{
736
796
  type: Component,
737
- args: [{ changeDetection: ChangeDetectionStrategy.OnPush, providers: [NotificationService], template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"{\n model: model$ | async,\n updatedModelValue: updatedModelValue$ | async,\n template: template$ | async,\n } as obs\">\n\n <div class=\"template-explanation\">\n Mail templates use <a target=\"_blank\" href=\"https://www.w3schools.com/html/html_intro.asp\">HTML</a> for the mail\n layout. <a target=\"_blank\" href=\"https://freemarker.apache.org/docs/dgui_quickstart_basics.html\">FreeMarker</a>\n can be used to create placeholders inside the HTML. The data-model for FreeMarker is based upon <a\n target=\"_blank\" href=\"https://docs.valtimo.nl/reference/modules/value-resolver\">Valtimo value-resolvers</a>\n with a slightly different notation. For example: $&#123;doc.firstName&#125;. Retrieves\n the `firstName` from the case.\n </div>\n\n <cds-tabs type=\"contained\">\n <cds-tab [active]=\"true\" [heading]=\"'Editor'\">\n <valtimo-editor\n [model]=\"obs.model\"\n [disabled]=\"(editorDisabled$ | async) || obs.template.readOnly\"\n (validEvent)=\"onValid($event)\"\n (valueChangeEvent)=\"onValueChange($event)\"\n [fitPage]=\"true\"\n [fitPageExtraSpace]=\"80\"\n ></valtimo-editor>\n </cds-tab>\n <cds-tab [heading]=\"'Viewer'\" (selected)=\"onSelectedTabViewer()\">\n <iframe title=\"HTML Viewer\" id=\"html-viewer-iframe\">\n </iframe>\n </cds-tab>\n </cds-tabs>\n</ng-container>\n\n<ng-container renderInPageHeader>\n <ng-template>\n <div *ngIf=\"{\n model: model$ | async,\n moreDisabled: moreDisabled$ | async,\n template: template$ | async,\n } as obs\"\n class=\"buttons-container\"\n >\n <cds-overflow-menu class=\"overflow-button\">\n <cds-overflow-menu-option\n [disabled]=\"obs.moreDisabled || obs.template.readOnly\"\n type=\"danger\"\n (selected)=\"showDeleteModal()\"\n >{{ 'interface.delete' | translate }}\n </cds-overflow-menu-option\n >\n </cds-overflow-menu>\n\n <button\n [disabled]=\"(saveDisabled$ | async) || obs.template.readOnly\"\n cdsButton=\"primary\"\n size=\"md\"\n (click)=\"updateTemplate()\"\n >\n {{ 'interface.save' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"save\" size=\"16\"></svg>\n </button>\n </div>\n </ng-template>\n</ng-container>\n\n<ng-container *ngIf=\"{templateKey: templateKey$ | async} as obs\">\n <valtimo-mail-template-delete-modal\n [deleteRowKeys]=\"[obs.templateKey]\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-mail-template-delete-modal>\n</ng-container>\n", styles: ["::ng-deep .cds--tab-content{background:var(--cds-layer)!important}::ng-deep #html-viewer-iframe{width:100%;height:calc(100vh - 219px)}.loading-container{display:flex;width:100%;justify-content:center}.overflow-button{margin-right:16px}.buttons-container{display:flex;flex-direction:row}.template-explanation{margin-top:16px;margin-bottom:24px}\n/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
738
- }], ctorParameters: () => [{ type: FreemarkerTemplateManagementService }, { type: i2$2.ActivatedRoute }, { type: i1.PageTitleService }, { type: i2$2.Router }, { type: i4$1.NotificationService }, { type: i5.TranslateService }, { type: i1.BreadcrumbService }] });
797
+ args: [{ standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, providers: [NotificationService], imports: [
798
+ CommonModule,
799
+ TranslateModule,
800
+ TabsModule,
801
+ DialogModule,
802
+ ValtimoCdsOverflowButtonDirectiveModule,
803
+ MailTemplateDeleteModalComponent,
804
+ CarbonListModule,
805
+ ButtonModule,
806
+ EditorModule,
807
+ RenderInPageHeaderDirectiveModule,
808
+ ], template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"{\n model: model$ | async,\n updatedModelValue: updatedModelValue$ | async,\n template: template$ | async,\n } as obs\">\n\n <div class=\"template-explanation\">\n Mail templates use <a target=\"_blank\" href=\"https://www.w3schools.com/html/html_intro.asp\">HTML</a> for the mail\n layout. <a target=\"_blank\" href=\"https://freemarker.apache.org/docs/dgui_quickstart_basics.html\">FreeMarker</a>\n can be used to create placeholders inside the HTML. The data-model for FreeMarker is based upon <a\n target=\"_blank\" href=\"https://docs.valtimo.nl/reference/modules/value-resolver\">Valtimo value-resolvers</a>\n with a slightly different notation. For example: $&#123;doc.firstName&#125;. Retrieves\n the `firstName` from the case.\n </div>\n\n <cds-tabs type=\"contained\">\n <cds-tab [active]=\"true\" [heading]=\"'Editor'\">\n <valtimo-editor\n [model]=\"obs.model\"\n [disabled]=\"(editorDisabled$ | async) || (readOnly$ | async)\"\n (validEvent)=\"onValid($event)\"\n (valueChangeEvent)=\"onValueChange($event)\"\n [fitPage]=\"true\"\n [fitPageExtraSpace]=\"80\"\n ></valtimo-editor>\n </cds-tab>\n <cds-tab [heading]=\"'Viewer'\" (selected)=\"onSelectedTabViewer()\">\n <iframe title=\"HTML Viewer\" id=\"html-viewer-iframe\">\n </iframe>\n </cds-tab>\n </cds-tabs>\n</ng-container>\n\n<ng-container renderInPageHeader>\n <ng-template>\n <div *ngIf=\"{\n model: model$ | async,\n moreDisabled: moreDisabled$ | async,\n template: template$ | async,\n } as obs\"\n class=\"buttons-container\"\n >\n <cds-overflow-menu class=\"overflow-button\">\n <cds-overflow-menu-option\n [disabled]=\"obs.moreDisabled || (readOnly$ | async)\"\n type=\"danger\"\n (selected)=\"showDeleteModal()\"\n >{{ 'interface.delete' | translate }}\n </cds-overflow-menu-option\n >\n </cds-overflow-menu>\n\n <button\n [disabled]=\"(saveDisabled$ | async) || (readOnly$ | async)\"\n cdsButton=\"primary\"\n size=\"md\"\n (click)=\"updateTemplate()\"\n >\n {{ 'interface.save' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"save\" size=\"16\"></svg>\n </button>\n </div>\n </ng-template>\n</ng-container>\n\n<ng-container *ngIf=\"{templateKey: templateKey$ | async} as obs\">\n <valtimo-mail-template-delete-modal\n [deleteRowKeys]=\"[obs.templateKey]\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-mail-template-delete-modal>\n</ng-container>\n", styles: ["::ng-deep .cds--tab-content{background:var(--cds-layer)!important}::ng-deep #html-viewer-iframe{width:100%;height:calc(100vh - 219px)}.loading-container{display:flex;width:100%;justify-content:center}.overflow-button{margin-right:16px}.buttons-container{display:flex;flex-direction:row}.template-explanation{margin-top:16px;margin-bottom:24px}\n/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
809
+ }], ctorParameters: () => [{ type: FreemarkerTemplateManagementService }, { type: i2$2.ActivatedRoute }, { type: i1.PageTitleService }, { type: i2$2.Router }, { type: i4$1.NotificationService }, { type: i5.TranslateService }, { type: i1.BreadcrumbService }, { type: i3.EnvironmentService }] });
739
810
 
740
811
  /*
741
812
  * Copyright 2015-2023 Ritense BV, the Netherlands.
@@ -752,9 +823,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImpo
752
823
  * See the License for the specific language governing permissions and
753
824
  * limitations under the License.
754
825
  */
755
- const routes = [
826
+ const routes$1 = [
756
827
  {
757
- path: 'dossier-management/dossier/:name/mail-template/:key',
828
+ path: 'case-management/case/:caseDefinitionKey/version/:caseDefinitionVersionTag/mail-template/:templateKey',
758
829
  component: MailTemplateEditorComponent,
759
830
  canActivate: [AuthGuardService],
760
831
  data: {
@@ -764,15 +835,15 @@ const routes = [
764
835
  },
765
836
  },
766
837
  ];
767
- class TemplateManagementRoutingModule {
768
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TemplateManagementRoutingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
769
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.12", ngImport: i0, type: TemplateManagementRoutingModule, imports: [CommonModule, i2$2.RouterModule], exports: [RouterModule] }); }
770
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TemplateManagementRoutingModule, imports: [CommonModule, RouterModule.forChild(routes), RouterModule] }); }
771
- }
772
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TemplateManagementRoutingModule, decorators: [{
838
+ let TemplateManagementRoutingModule$1 = class TemplateManagementRoutingModule {
839
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TemplateManagementRoutingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
840
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.14", ngImport: i0, type: TemplateManagementRoutingModule, imports: [CommonModule, i2$2.RouterModule], exports: [RouterModule] }); }
841
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TemplateManagementRoutingModule, imports: [CommonModule, RouterModule.forChild(routes$1), RouterModule] }); }
842
+ };
843
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TemplateManagementRoutingModule$1, decorators: [{
773
844
  type: NgModule,
774
845
  args: [{
775
- imports: [CommonModule, RouterModule.forChild(routes)],
846
+ imports: [CommonModule, RouterModule.forChild(routes$1)],
776
847
  exports: [RouterModule],
777
848
  }]
778
849
  }] });
@@ -793,16 +864,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImpo
793
864
  * limitations under the License.
794
865
  */
795
866
  class MailTemplatePluginModule {
796
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplatePluginModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
797
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.12", ngImport: i0, type: MailTemplatePluginModule, declarations: [MailTemplateConfigurationComponent,
867
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplatePluginModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
868
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.14", ngImport: i0, type: MailTemplatePluginModule, declarations: [MailTemplateConfigurationComponent,
798
869
  GenerateMailFileComponent,
799
- GenerateMailContentComponent,
800
- MailTemplateAddEditModalComponent,
801
- MailTemplateEditorComponent,
802
- MailTemplateDeleteModalComponent,
803
- MailTemplateListComponent], imports: [CommonModule,
870
+ GenerateMailContentComponent], imports: [CommonModule,
804
871
  PluginTranslatePipeModule,
805
- TemplateManagementRoutingModule,
872
+ TemplateManagementRoutingModule$1,
806
873
  FormModule,
807
874
  ParagraphModule,
808
875
  SelectModule,
@@ -811,35 +878,33 @@ class MailTemplatePluginModule {
811
878
  ReactiveFormsModule,
812
879
  CarbonListModule,
813
880
  EditorModule,
814
- InputModule,
881
+ InputModule$1,
815
882
  ButtonModule,
816
883
  DialogModule,
817
884
  DropdownModule,
818
885
  IconModule,
819
- InputModule$1,
886
+ InputModule,
820
887
  LoadingModule,
821
888
  ModalModule,
822
889
  NotificationModule,
823
890
  RenderInPageHeaderDirectiveModule,
824
- TabsModule], exports: [MailTemplateConfigurationComponent,
891
+ TabsModule,
892
+ ValtimoCdsOverflowButtonDirectiveModule,
893
+ MailTemplateDeleteModalComponent], exports: [MailTemplateConfigurationComponent,
825
894
  GenerateMailFileComponent,
826
- GenerateMailContentComponent,
827
- MailTemplateAddEditModalComponent,
828
- MailTemplateEditorComponent,
829
- MailTemplateDeleteModalComponent,
830
- MailTemplateListComponent] }); }
831
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplatePluginModule, providers: [
895
+ GenerateMailContentComponent] }); }
896
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplatePluginModule, providers: [
832
897
  {
833
898
  provide: CASE_MANAGEMENT_TAB_TOKEN,
834
899
  useValue: {
835
- translationKey: 'Mail templates',
900
+ translationKey: 'mail-template',
836
901
  component: MailTemplateListComponent,
837
902
  },
838
903
  multi: true,
839
904
  }
840
905
  ], imports: [CommonModule,
841
906
  PluginTranslatePipeModule,
842
- TemplateManagementRoutingModule,
907
+ TemplateManagementRoutingModule$1,
843
908
  FormModule,
844
909
  ParagraphModule,
845
910
  SelectModule,
@@ -848,34 +913,32 @@ class MailTemplatePluginModule {
848
913
  ReactiveFormsModule,
849
914
  CarbonListModule,
850
915
  EditorModule,
851
- InputModule,
916
+ InputModule$1,
852
917
  ButtonModule,
853
918
  DialogModule,
854
919
  DropdownModule,
855
920
  IconModule,
856
- InputModule$1,
921
+ InputModule,
857
922
  LoadingModule,
858
923
  ModalModule,
859
924
  NotificationModule,
860
925
  RenderInPageHeaderDirectiveModule,
861
- TabsModule] }); }
926
+ TabsModule,
927
+ ValtimoCdsOverflowButtonDirectiveModule,
928
+ MailTemplateDeleteModalComponent] }); }
862
929
  }
863
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: MailTemplatePluginModule, decorators: [{
930
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MailTemplatePluginModule, decorators: [{
864
931
  type: NgModule,
865
932
  args: [{
866
933
  declarations: [
867
934
  MailTemplateConfigurationComponent,
868
935
  GenerateMailFileComponent,
869
936
  GenerateMailContentComponent,
870
- MailTemplateAddEditModalComponent,
871
- MailTemplateEditorComponent,
872
- MailTemplateDeleteModalComponent,
873
- MailTemplateListComponent,
874
937
  ],
875
938
  imports: [
876
939
  CommonModule,
877
940
  PluginTranslatePipeModule,
878
- TemplateManagementRoutingModule,
941
+ TemplateManagementRoutingModule$1,
879
942
  FormModule,
880
943
  ParagraphModule,
881
944
  SelectModule,
@@ -884,32 +947,30 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImpo
884
947
  ReactiveFormsModule,
885
948
  CarbonListModule,
886
949
  EditorModule,
887
- InputModule,
950
+ InputModule$1,
888
951
  ButtonModule,
889
952
  DialogModule,
890
953
  DropdownModule,
891
954
  IconModule,
892
- InputModule$1,
955
+ InputModule,
893
956
  LoadingModule,
894
957
  ModalModule,
895
958
  NotificationModule,
896
959
  RenderInPageHeaderDirectiveModule,
897
960
  TabsModule,
961
+ ValtimoCdsOverflowButtonDirectiveModule,
962
+ MailTemplateDeleteModalComponent,
898
963
  ],
899
964
  exports: [
900
965
  MailTemplateConfigurationComponent,
901
966
  GenerateMailFileComponent,
902
967
  GenerateMailContentComponent,
903
- MailTemplateAddEditModalComponent,
904
- MailTemplateEditorComponent,
905
- MailTemplateDeleteModalComponent,
906
- MailTemplateListComponent,
907
968
  ],
908
969
  providers: [
909
970
  {
910
971
  provide: CASE_MANAGEMENT_TAB_TOKEN,
911
972
  useValue: {
912
- translationKey: 'Mail templates',
973
+ translationKey: 'mail-template',
913
974
  component: MailTemplateListComponent,
914
975
  },
915
976
  multi: true,
@@ -933,7 +994,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImpo
933
994
  * See the License for the specific language governing permissions and
934
995
  * limitations under the License.
935
996
  */
936
- const FREEMARKER_PLUGIN_LOGO_BASE64 = 'data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPHN2ZyBpZD0ic3ZnMiIgdmlld0JveD0iMCAwIDQwMCAyMDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPHBhdGggZD0iTSAzNDAuMzM3IDEzNS4zMjQgTCAzNTAuNTU1IDE1MC44MTUgTCAzODQuNiA5OS4xNzYgTCAzNTAuNTU1IDQ3LjUzNSBMIDM0MC4zMzcgNjMuMDI4IEwgMzY0LjE4MSA5OS4xNzYgTCAzNDAuMzM3IDEzNS4zMjQgWiIgc3R5bGU9ImZpbGw6IHJnYigwLCA4MCwgMTc4KTsiLz4KICA8cGF0aCBkPSJNIDU1LjQwNiA2My4wMjggTCA0NS4xODggNDcuNTM1IEwgMTEuMTQzIDk5LjE3NiBMIDQ1LjE4OCAxNTAuODE1IEwgNTUuNDA2IDEzNS4zMjQgTCAzMS41NjMgOTkuMTc2IEwgNTUuNDA2IDYzLjAyOCBaIiBzdHlsZT0iZmlsbDogcmdiKDAsIDgwLCAxNzgpOyIvPgogIDxwYXRoIGQ9Ik0gOTIuNzIxIDQ3LjUzNSBMIDExMy4zNzYgNDcuNTM1IEwgMTA5LjczMiA2OC4xOTEgTCAxMzAuMzg5IDY4LjE5MSBMIDEzNC4wMzIgNDcuNTM1IEwgMTU0LjY4OSA0Ny41MzUgTCAxNTEuMDQ1IDY4LjE5MSBMIDE3MS43MDEgNjguMTkxIEwgMTY4LjA0OSA4OC44NDggTCAxNDcuMzkzIDg4Ljg0OCBMIDE0My43NTYgMTA5LjUwNCBMIDE2NC40MTIgMTA5LjUwNCBMIDE2MC43NjcgMTMwLjE2IEwgMTQwLjExMSAxMzAuMTYgTCAxMzYuNDgyIDE1MC44MTUgTCAxMTUuODI2IDE1MC44MTUgTCAxMTkuNDYzIDEzMC4xNiBMIDk4LjgwNiAxMzAuMTYgTCA5NS4yMjkgMTUwLjgxNSBMIDc0LjUxMyAxNTAuODE1IEwgNzguMTUgMTMwLjE2IEwgNTcuNDk0IDEzMC4xNiBMIDYxLjEzOCAxMDkuNTA0IEwgODEuNzk1IDEwOS41MDQgTCA4NS40MzIgODguODk5IEwgNjQuNzc1IDg4Ljg5OSBMIDY4LjQyIDY4LjE5MSBMIDg5LjA3NiA2OC4xOTEgTCA5Mi43MjEgNDcuNTM1IFogTSAxMDIuNDUxIDEwOS41MDQgTCAxMjMuMTA3IDEwOS41MDQgTCAxMjYuNzUyIDg4Ljg0OCBMIDEwNi4wOTUgODguODQ4IEwgMTAyLjQ1MSAxMDkuNTA0IFoiIHN0eWxlPSJmaWxsOiByZ2IoMCwgODAsIDE3OCk7Ii8+CiAgPGcgdHJhbnNmb3JtPSJtYXRyaXgoMi4wMjgxNjQsIDAsIDAsIDIuMDI4MTY0LCAxNzkuMDc4MTg2LCAyNi4zMjE2NjcpIiBzdHlsZT0iIj4KICAgIDxwYXRoIGQ9Ik0gNjYuMDk3IDExLjUyOCBMIDkuMTk3IDExLjUyOCBDIDQuMTI2IDExLjUyOCAwIDE1LjY1NCAwIDIwLjcyNSBMIDAgNTMuNDQ3IEMgMCA1OC41MTggNC4xMjYgNjIuNjQ0IDkuMTk3IDYyLjY0NCBMIDY2LjA5NyA2Mi42NDQgQyA3MS4xNjggNjIuNjQ0IDc1LjI5NCA1OC41MTggNzUuMjk0IDUzLjQ0NyBMIDc1LjI5NCAyMC43MjYgQyA3NS4yOTUgMTUuNjU0IDcxLjE2OSAxMS41MjggNjYuMDk3IDExLjUyOCBaIE0gNjEuNjAzIDE3LjUyOCBMIDM3LjY0NyAzMi45NjIgTCAxMy42OTEgMTcuNTI4IEwgNjEuNjAzIDE3LjUyOCBaIE0gNjYuMDk3IDU2LjY0NSBMIDkuMTk3IDU2LjY0NSBDIDcuNDM0IDU2LjY0NSA2IDU1LjIxIDYgNTMuNDQ4IEwgNiAyMC44OTYgTCAzNS43OTYgNDAuMDU2IEMgMzUuODM2IDQwLjA4MSAzNS44NzkgNDAuMDk4IDM1LjkyIDQwLjEyMSBDIDM1Ljk2MyA0MC4xNDUgMzYuMDA3IDQwLjE2OCAzNi4wNTEgNDAuMTkgQyAzNi4yODIgNDAuMzA5IDM2LjUyIDQwLjQwNSAzNi43NjMgNDAuNDY4IEMgMzYuNzg4IDQwLjQ3NSAzNi44MTMgNDAuNDc4IDM2LjgzOCA0MC40ODQgQyAzNy4xMDUgNDAuNTQ3IDM3LjM3NSA0MC41ODYgMzcuNjQ1IDQwLjU4NiBDIDM3LjY0NiA0MC41ODYgMzcuNjQ3IDQwLjU4NiAzNy42NDcgNDAuNTg2IEMgMzcuNjQ5IDQwLjU4NiAzNy42NSA0MC41ODYgMzcuNjUxIDQwLjU4NiBDIDM3LjkyMSA0MC41ODYgMzguMTkxIDQwLjU0OCAzOC40NTggNDAuNDg0IEMgMzguNDgzIDQwLjQ3OCAzOC41MDggNDAuNDc1IDM4LjUzMyA0MC40NjggQyAzOC43NzYgNDAuNDA1IDM5LjAxMyA0MC4zMDkgMzkuMjQ1IDQwLjE5IEMgMzkuMjg5IDQwLjE2OCAzOS4zMzMgNDAuMTQ1IDM5LjM3NiA0MC4xMjEgQyAzOS40MTcgNDAuMDk4IDM5LjQ2IDQwLjA4MSAzOS41IDQwLjA1NiBMIDY5LjI5NiAyMC44OTYgTCA2OS4yOTYgNTMuNDQ3IEMgNjkuMjk1IDU1LjIxIDY3Ljg2IDU2LjY0NSA2Ni4wOTcgNTYuNjQ1IFoiLz4KICA8L2c+Cjwvc3ZnPg==';
997
+ const MAIL_TEMPLATE_PLUGIN_LOGO_BASE64 = 'data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPHN2ZyBpZD0ic3ZnMiIgdmlld0JveD0iMCAwIDQwMCAyMDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPHBhdGggZD0iTSAzNDAuMzM3IDEzNS4zMjQgTCAzNTAuNTU1IDE1MC44MTUgTCAzODQuNiA5OS4xNzYgTCAzNTAuNTU1IDQ3LjUzNSBMIDM0MC4zMzcgNjMuMDI4IEwgMzY0LjE4MSA5OS4xNzYgTCAzNDAuMzM3IDEzNS4zMjQgWiIgc3R5bGU9ImZpbGw6IHJnYigwLCA4MCwgMTc4KTsiLz4KICA8cGF0aCBkPSJNIDU1LjQwNiA2My4wMjggTCA0NS4xODggNDcuNTM1IEwgMTEuMTQzIDk5LjE3NiBMIDQ1LjE4OCAxNTAuODE1IEwgNTUuNDA2IDEzNS4zMjQgTCAzMS41NjMgOTkuMTc2IEwgNTUuNDA2IDYzLjAyOCBaIiBzdHlsZT0iZmlsbDogcmdiKDAsIDgwLCAxNzgpOyIvPgogIDxwYXRoIGQ9Ik0gOTIuNzIxIDQ3LjUzNSBMIDExMy4zNzYgNDcuNTM1IEwgMTA5LjczMiA2OC4xOTEgTCAxMzAuMzg5IDY4LjE5MSBMIDEzNC4wMzIgNDcuNTM1IEwgMTU0LjY4OSA0Ny41MzUgTCAxNTEuMDQ1IDY4LjE5MSBMIDE3MS43MDEgNjguMTkxIEwgMTY4LjA0OSA4OC44NDggTCAxNDcuMzkzIDg4Ljg0OCBMIDE0My43NTYgMTA5LjUwNCBMIDE2NC40MTIgMTA5LjUwNCBMIDE2MC43NjcgMTMwLjE2IEwgMTQwLjExMSAxMzAuMTYgTCAxMzYuNDgyIDE1MC44MTUgTCAxMTUuODI2IDE1MC44MTUgTCAxMTkuNDYzIDEzMC4xNiBMIDk4LjgwNiAxMzAuMTYgTCA5NS4yMjkgMTUwLjgxNSBMIDc0LjUxMyAxNTAuODE1IEwgNzguMTUgMTMwLjE2IEwgNTcuNDk0IDEzMC4xNiBMIDYxLjEzOCAxMDkuNTA0IEwgODEuNzk1IDEwOS41MDQgTCA4NS40MzIgODguODk5IEwgNjQuNzc1IDg4Ljg5OSBMIDY4LjQyIDY4LjE5MSBMIDg5LjA3NiA2OC4xOTEgTCA5Mi43MjEgNDcuNTM1IFogTSAxMDIuNDUxIDEwOS41MDQgTCAxMjMuMTA3IDEwOS41MDQgTCAxMjYuNzUyIDg4Ljg0OCBMIDEwNi4wOTUgODguODQ4IEwgMTAyLjQ1MSAxMDkuNTA0IFoiIHN0eWxlPSJmaWxsOiByZ2IoMCwgODAsIDE3OCk7Ii8+CiAgPGcgdHJhbnNmb3JtPSJtYXRyaXgoMi4wMjgxNjQsIDAsIDAsIDIuMDI4MTY0LCAxNzkuMDc4MTg2LCAyNi4zMjE2NjcpIiBzdHlsZT0iIj4KICAgIDxwYXRoIGQ9Ik0gNjYuMDk3IDExLjUyOCBMIDkuMTk3IDExLjUyOCBDIDQuMTI2IDExLjUyOCAwIDE1LjY1NCAwIDIwLjcyNSBMIDAgNTMuNDQ3IEMgMCA1OC41MTggNC4xMjYgNjIuNjQ0IDkuMTk3IDYyLjY0NCBMIDY2LjA5NyA2Mi42NDQgQyA3MS4xNjggNjIuNjQ0IDc1LjI5NCA1OC41MTggNzUuMjk0IDUzLjQ0NyBMIDc1LjI5NCAyMC43MjYgQyA3NS4yOTUgMTUuNjU0IDcxLjE2OSAxMS41MjggNjYuMDk3IDExLjUyOCBaIE0gNjEuNjAzIDE3LjUyOCBMIDM3LjY0NyAzMi45NjIgTCAxMy42OTEgMTcuNTI4IEwgNjEuNjAzIDE3LjUyOCBaIE0gNjYuMDk3IDU2LjY0NSBMIDkuMTk3IDU2LjY0NSBDIDcuNDM0IDU2LjY0NSA2IDU1LjIxIDYgNTMuNDQ4IEwgNiAyMC44OTYgTCAzNS43OTYgNDAuMDU2IEMgMzUuODM2IDQwLjA4MSAzNS44NzkgNDAuMDk4IDM1LjkyIDQwLjEyMSBDIDM1Ljk2MyA0MC4xNDUgMzYuMDA3IDQwLjE2OCAzNi4wNTEgNDAuMTkgQyAzNi4yODIgNDAuMzA5IDM2LjUyIDQwLjQwNSAzNi43NjMgNDAuNDY4IEMgMzYuNzg4IDQwLjQ3NSAzNi44MTMgNDAuNDc4IDM2LjgzOCA0MC40ODQgQyAzNy4xMDUgNDAuNTQ3IDM3LjM3NSA0MC41ODYgMzcuNjQ1IDQwLjU4NiBDIDM3LjY0NiA0MC41ODYgMzcuNjQ3IDQwLjU4NiAzNy42NDcgNDAuNTg2IEMgMzcuNjQ5IDQwLjU4NiAzNy42NSA0MC41ODYgMzcuNjUxIDQwLjU4NiBDIDM3LjkyMSA0MC41ODYgMzguMTkxIDQwLjU0OCAzOC40NTggNDAuNDg0IEMgMzguNDgzIDQwLjQ3OCAzOC41MDggNDAuNDc1IDM4LjUzMyA0MC40NjggQyAzOC43NzYgNDAuNDA1IDM5LjAxMyA0MC4zMDkgMzkuMjQ1IDQwLjE5IEMgMzkuMjg5IDQwLjE2OCAzOS4zMzMgNDAuMTQ1IDM5LjM3NiA0MC4xMjEgQyAzOS40MTcgNDAuMDk4IDM5LjQ2IDQwLjA4MSAzOS41IDQwLjA1NiBMIDY5LjI5NiAyMC44OTYgTCA2OS4yOTYgNTMuNDQ3IEMgNjkuMjk1IDU1LjIxIDY3Ljg2IDU2LjY0NSA2Ni4wOTcgNTYuNjQ1IFoiLz4KICA8L2c+Cjwvc3ZnPg==';
937
998
 
938
999
  /*
939
1000
  * Copyright 2015-2022 Ritense BV, the Netherlands.
@@ -969,7 +1030,7 @@ const FREEMARKER_PLUGIN_LOGO_BASE64 = 'data:image/svg+xml;base64,PD94bWwgdmVyc2l
969
1030
  const mailTemplatePluginSpecification = {
970
1031
  pluginId: 'mail-template',
971
1032
  pluginConfigurationComponent: MailTemplateConfigurationComponent,
972
- pluginLogoBase64: FREEMARKER_PLUGIN_LOGO_BASE64,
1033
+ pluginLogoBase64: MAIL_TEMPLATE_PLUGIN_LOGO_BASE64,
973
1034
  functionConfigurationComponents: {
974
1035
  'generate-mail-file': GenerateMailFileComponent,
975
1036
  'generate-mail-content': GenerateMailContentComponent,
@@ -1020,6 +1081,861 @@ const mailTemplatePluginSpecification = {
1020
1081
  },
1021
1082
  };
1022
1083
 
1084
+ /*
1085
+ * Copyright 2015-2022 Ritense BV, the Netherlands.
1086
+ *
1087
+ * Licensed under EUPL, Version 1.2 (the "License");
1088
+ * you may not use this file except in compliance with the License.
1089
+ * You may obtain a copy of the License at
1090
+ *
1091
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1092
+ *
1093
+ * Unless required by applicable law or agreed to in writing, software
1094
+ * distributed under the License is distributed on an "AS IS" basis,
1095
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1096
+ * See the License for the specific language governing permissions and
1097
+ * limitations under the License.
1098
+ */
1099
+
1100
+ /*
1101
+ * Copyright 2015-2022 Ritense BV, the Netherlands.
1102
+ *
1103
+ * Licensed under EUPL, Version 1.2 (the "License");
1104
+ * you may not use this file except in compliance with the License.
1105
+ * You may obtain a copy of the License at
1106
+ *
1107
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1108
+ *
1109
+ * Unless required by applicable law or agreed to in writing, software
1110
+ * distributed under the License is distributed on an "AS IS" basis,
1111
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1112
+ * See the License for the specific language governing permissions and
1113
+ * limitations under the License.
1114
+ */
1115
+
1116
+ /*
1117
+ * Copyright 2015-2022 Ritense BV, the Netherlands.
1118
+ *
1119
+ * Licensed under EUPL, Version 1.2 (the "License");
1120
+ * you may not use this file except in compliance with the License.
1121
+ * You may obtain a copy of the License at
1122
+ *
1123
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1124
+ *
1125
+ * Unless required by applicable law or agreed to in writing, software
1126
+ * distributed under the License is distributed on an "AS IS" basis,
1127
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1128
+ * See the License for the specific language governing permissions and
1129
+ * limitations under the License.
1130
+ */
1131
+ class TextTemplateConfigurationComponent {
1132
+ constructor() {
1133
+ this.valid = new EventEmitter();
1134
+ this.configuration = new EventEmitter();
1135
+ this.formValue$ = new BehaviorSubject(null);
1136
+ this.valid$ = new BehaviorSubject(false);
1137
+ }
1138
+ ngOnInit() {
1139
+ this.openSaveSubscription();
1140
+ }
1141
+ ngOnDestroy() {
1142
+ this.saveSubscription?.unsubscribe();
1143
+ }
1144
+ formValueChange(formValue) {
1145
+ this.formValue$.next(formValue);
1146
+ this.handleValid(formValue);
1147
+ }
1148
+ handleValid(formValue) {
1149
+ const valid = !!(formValue.configurationTitle);
1150
+ this.valid$.next(valid);
1151
+ this.valid.emit(valid);
1152
+ }
1153
+ openSaveSubscription() {
1154
+ this.saveSubscription = this.save$?.subscribe(_ => {
1155
+ combineLatest([this.formValue$, this.valid$])
1156
+ .pipe(take(1))
1157
+ .subscribe(([formValue, valid]) => {
1158
+ if (valid) {
1159
+ this.configuration.emit(formValue);
1160
+ this.injectCaseTab();
1161
+ }
1162
+ });
1163
+ });
1164
+ }
1165
+ injectCaseTab() {
1166
+ }
1167
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplateConfigurationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1168
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: TextTemplateConfigurationComponent, isStandalone: false, selector: "valtimo-text-template-configuration", inputs: { save$: "save$", disabled$: "disabled$", pluginId: "pluginId", prefillConfiguration$: "prefillConfiguration$" }, outputs: { valid: "valid", configuration: "configuration" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<v-form\n (valueChange)=\"formValueChange($event)\"\n *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null\n } as obs\"\n>\n <v-input\n name=\"configurationTitle\"\n [title]=\"'configurationTitle' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [disabled]=\"obs.disabled\"\n [defaultValue]=\"obs.prefill?.configurationTitle\"\n [required]=\"true\"\n [tooltip]=\"'configurationTitleTooltip' | pluginTranslate: pluginId | async\"\n [widthPx]=\"350\"\n placeholder=\"Text Template Plugin\"\n >\n </v-input>\n</v-form>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1.FormComponent, selector: "v-form", inputs: ["className"], outputs: ["valueChange"] }, { kind: "component", type: i1.InputComponent, selector: "v-input", inputs: ["name", "type", "title", "titleTranslationKey", "defaultValue", "widthPx", "fullWidth", "margin", "smallMargin", "disabled", "step", "min", "maxLength", "tooltip", "required", "hideNumberSpinBox", "smallLabel", "rows", "clear$", "carbonTheme", "placeholder", "dataTestId", "trim"], outputs: ["valueChange"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "pipe", type: i6.PluginTranslatePipe, name: "pluginTranslate" }] }); }
1169
+ }
1170
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplateConfigurationComponent, decorators: [{
1171
+ type: Component,
1172
+ args: [{ standalone: false, selector: 'valtimo-text-template-configuration', template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<v-form\n (valueChange)=\"formValueChange($event)\"\n *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null\n } as obs\"\n>\n <v-input\n name=\"configurationTitle\"\n [title]=\"'configurationTitle' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [disabled]=\"obs.disabled\"\n [defaultValue]=\"obs.prefill?.configurationTitle\"\n [required]=\"true\"\n [tooltip]=\"'configurationTitleTooltip' | pluginTranslate: pluginId | async\"\n [widthPx]=\"350\"\n placeholder=\"Text Template Plugin\"\n >\n </v-input>\n</v-form>\n" }]
1173
+ }], ctorParameters: () => [], propDecorators: { save$: [{
1174
+ type: Input
1175
+ }], disabled$: [{
1176
+ type: Input
1177
+ }], pluginId: [{
1178
+ type: Input
1179
+ }], prefillConfiguration$: [{
1180
+ type: Input
1181
+ }], valid: [{
1182
+ type: Output
1183
+ }], configuration: [{
1184
+ type: Output
1185
+ }] } });
1186
+
1187
+ /*
1188
+ * Copyright 2015-2023 Ritense BV, the Netherlands.
1189
+ *
1190
+ * Licensed under EUPL, Version 1.2 (the "License");
1191
+ * you may not use this file except in compliance with the License.
1192
+ * You may obtain a copy of the License at
1193
+ *
1194
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1195
+ *
1196
+ * Unless required by applicable law or agreed to in writing, software
1197
+ * distributed under the License is distributed on an "AS IS" basis,
1198
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1199
+ * See the License for the specific language governing permissions and
1200
+ * limitations under the License.
1201
+ */
1202
+ class TextTemplateDeleteModalComponent {
1203
+ constructor() {
1204
+ this.deleteEvent = new EventEmitter();
1205
+ }
1206
+ onDelete(templates) {
1207
+ this.deleteEvent.emit(templates);
1208
+ }
1209
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplateDeleteModalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1210
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: TextTemplateDeleteModalComponent, isStandalone: true, selector: "valtimo-text-template-delete-modal", inputs: { deleteRowKeys: "deleteRowKeys", showDeleteModal$: "showDeleteModal$" }, outputs: { deleteEvent: "deleteEvent" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-confirmation-modal\n confirmButtonTextTranslationKey=\"interface.delete\"\n confirmButtonType=\"danger\"\n contentTranslationKey=\"template.deleteModalContent\"\n [outputOnConfirm]=\"deleteRowKeys\"\n [showModalSubject$]=\"showDeleteModal$\"\n titleTranslationKey=\"interface.delete\"\n (confirmEvent)=\"onDelete($event)\"\n></valtimo-confirmation-modal>\n", dependencies: [{ kind: "ngmodule", type: ConfirmationModalModule }, { kind: "component", type: i1.ConfirmationModalComponent, selector: "valtimo-confirmation-modal", inputs: ["titleTranslationKey", "title", "content", "contentTranslationKey", "confirmButtonText", "confirmButtonTextTranslationKey", "confirmButtonType", "showOptionalButton", "optionalButtonText", "optionalButtonTextTranslationKey", "optionalButtonType", "cancelButtonText", "cancelButtonTextTranslationKey", "cancelButtonType", "showModalSubject$", "outputOnConfirm", "outputOnOptional", "spacerAfterCancelButton"], outputs: ["confirmEvent", "optionalEvent", "cancelEvent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
1211
+ }
1212
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplateDeleteModalComponent, decorators: [{
1213
+ type: Component,
1214
+ args: [{ standalone: true, selector: 'valtimo-text-template-delete-modal', changeDetection: ChangeDetectionStrategy.OnPush, imports: [
1215
+ ConfirmationModalModule
1216
+ ], template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-confirmation-modal\n confirmButtonTextTranslationKey=\"interface.delete\"\n confirmButtonType=\"danger\"\n contentTranslationKey=\"template.deleteModalContent\"\n [outputOnConfirm]=\"deleteRowKeys\"\n [showModalSubject$]=\"showDeleteModal$\"\n titleTranslationKey=\"interface.delete\"\n (confirmEvent)=\"onDelete($event)\"\n></valtimo-confirmation-modal>\n" }]
1217
+ }], propDecorators: { deleteRowKeys: [{
1218
+ type: Input
1219
+ }], showDeleteModal$: [{
1220
+ type: Input
1221
+ }], deleteEvent: [{
1222
+ type: Output
1223
+ }] } });
1224
+
1225
+ /*
1226
+ * Copyright 2015-2023 Ritense BV, the Netherlands.
1227
+ *
1228
+ * Licensed under EUPL, Version 1.2 (the "License");
1229
+ * you may not use this file except in compliance with the License.
1230
+ * You may obtain a copy of the License at
1231
+ *
1232
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1233
+ *
1234
+ * Unless required by applicable law or agreed to in writing, software
1235
+ * distributed under the License is distributed on an "AS IS" basis,
1236
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1237
+ * See the License for the specific language governing permissions and
1238
+ * limitations under the License.
1239
+ */
1240
+ class TextTemplateAddEditModalComponent {
1241
+ set defaultKeyValue(value) {
1242
+ this._defaultKeyValue = value;
1243
+ this.setDefaultKeyValue(value);
1244
+ }
1245
+ get key() {
1246
+ const key = this.form?.get('key');
1247
+ if (!key?.value) {
1248
+ return key;
1249
+ }
1250
+ key.setValue(this.keyGeneratorService.getUniqueKey(key.value, []));
1251
+ return key;
1252
+ }
1253
+ constructor(fb, keyGeneratorService) {
1254
+ this.fb = fb;
1255
+ this.keyGeneratorService = keyGeneratorService;
1256
+ this.open = false;
1257
+ this.type = 'add';
1258
+ this.closeEvent = new EventEmitter();
1259
+ this.form = this.fb.group({
1260
+ key: this.fb.control('', Validators.required),
1261
+ });
1262
+ }
1263
+ ngOnInit() {
1264
+ }
1265
+ onCancel() {
1266
+ this.closeEvent.emit(null);
1267
+ this.resetForm();
1268
+ }
1269
+ onConfirm() {
1270
+ if (!this.key) {
1271
+ return;
1272
+ }
1273
+ this.closeEvent.emit({ key: this.key.value });
1274
+ this.resetForm();
1275
+ }
1276
+ setDefaultKeyValue(value) {
1277
+ this.key.setValue(value);
1278
+ }
1279
+ resetForm() {
1280
+ setTimeout(() => {
1281
+ this.form.reset();
1282
+ if (this.type === 'edit') {
1283
+ this.setDefaultKeyValue(this._defaultKeyValue);
1284
+ }
1285
+ }, CARBON_CONSTANTS.modalAnimationMs);
1286
+ }
1287
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplateAddEditModalComponent, deps: [{ token: i1$1.FormBuilder }, { token: i1.KeyGeneratorService }], target: i0.ɵɵFactoryTarget.Component }); }
1288
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: TextTemplateAddEditModalComponent, isStandalone: true, selector: "valtimo-text-template-add-edit-modal", inputs: { open: "open", type: "type", defaultKeyValue: "defaultKeyValue" }, outputs: { closeEvent: "closeEvent" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal\n *ngIf=\"{\n isAdd: type === 'add'\n } as vars\"\n [open]=\"open\"\n showFooter=\"true\"\n [title]=\"vars.title\"\n valtimoCdsModal\n>\n <cds-modal-header [showCloseButton]=\"true\" (closeSelect)=\"onCancel()\">\n <h3 cdsModalHeaderHeading>\n {{\n vars.isAdd\n ? 'Add'\n : 'Edit'\n }}\n </h3>\n </cds-modal-header>\n\n <section cdsModalContent>\n <form [formGroup]=\"form\">\n <cds-label [invalid]=\"key.dirty && key.invalid\">\n {{ 'Key' }}\n\n <input\n formControlName=\"key\"\n cdsText\n placeholder=\"{{ 'key' }}\"\n [attr.modal-primary-focus]=\"true\"\n [invalid]=\"key.dirty && key.invalid\"\n />\n </cds-label>\n </form>\n </section>\n\n <cds-modal-footer>\n <button cdsButton=\"ghost\" (click)=\"onCancel()\">\n {{ 'interface.cancel' | translate }}\n </button>\n\n <button [disabled]=\"this.form.invalid\" (click)=\"onConfirm()\" cdsButton=\"primary\">\n {{ vars.isAdd ? ('interface.create' | translate) : ('interface.save' | translate) }}\n </button>\n </cds-modal-footer>\n</cds-modal>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i4$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: ModalModule }, { kind: "component", type: i4$1.Modal, selector: "cds-modal, ibm-modal", inputs: ["size", "theme", "ariaLabel", "open", "trigger", "hasScrollingContent"], outputs: ["overlaySelected", "close"] }, { kind: "component", type: i4$1.ModalHeader, selector: "cds-modal-header, ibm-modal-header", inputs: ["theme", "closeLabel", "showCloseButton"], outputs: ["closeSelect"] }, { kind: "component", type: i4$1.ModalFooter, selector: "cds-modal-footer, ibm-modal-footer" }, { kind: "directive", type: i4$1.ModalContent, selector: "[cdsModalContent], [ibmModalContent]", inputs: ["hasForm"] }, { kind: "directive", type: i4$1.ModalHeaderHeading, selector: "[cdsModalHeaderHeading], [ibmModalHeaderHeading]" }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$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]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "ngmodule", type: InputModule }, { kind: "component", type: i4$1.Label, selector: "cds-label, ibm-label", inputs: ["labelInputID", "disabled", "skeleton", "helperText", "invalidText", "invalid", "warn", "warnText", "ariaLabel"] }, { kind: "directive", type: i4$1.TextInput, selector: "[cdsText], [ibmText]", inputs: ["theme", "size", "invalid", "warn", "skeleton"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
1289
+ }
1290
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplateAddEditModalComponent, decorators: [{
1291
+ type: Component,
1292
+ args: [{ standalone: true, selector: 'valtimo-text-template-add-edit-modal', changeDetection: ChangeDetectionStrategy.OnPush, imports: [
1293
+ CommonModule,
1294
+ ButtonModule,
1295
+ TranslateModule,
1296
+ ModalModule,
1297
+ ReactiveFormsModule,
1298
+ InputModule
1299
+ ], template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<cds-modal\n *ngIf=\"{\n isAdd: type === 'add'\n } as vars\"\n [open]=\"open\"\n showFooter=\"true\"\n [title]=\"vars.title\"\n valtimoCdsModal\n>\n <cds-modal-header [showCloseButton]=\"true\" (closeSelect)=\"onCancel()\">\n <h3 cdsModalHeaderHeading>\n {{\n vars.isAdd\n ? 'Add'\n : 'Edit'\n }}\n </h3>\n </cds-modal-header>\n\n <section cdsModalContent>\n <form [formGroup]=\"form\">\n <cds-label [invalid]=\"key.dirty && key.invalid\">\n {{ 'Key' }}\n\n <input\n formControlName=\"key\"\n cdsText\n placeholder=\"{{ 'key' }}\"\n [attr.modal-primary-focus]=\"true\"\n [invalid]=\"key.dirty && key.invalid\"\n />\n </cds-label>\n </form>\n </section>\n\n <cds-modal-footer>\n <button cdsButton=\"ghost\" (click)=\"onCancel()\">\n {{ 'interface.cancel' | translate }}\n </button>\n\n <button [disabled]=\"this.form.invalid\" (click)=\"onConfirm()\" cdsButton=\"primary\">\n {{ vars.isAdd ? ('interface.create' | translate) : ('interface.save' | translate) }}\n </button>\n </cds-modal-footer>\n</cds-modal>\n" }]
1300
+ }], ctorParameters: () => [{ type: i1$1.FormBuilder }, { type: i1.KeyGeneratorService }], propDecorators: { open: [{
1301
+ type: Input
1302
+ }], type: [{
1303
+ type: Input
1304
+ }], defaultKeyValue: [{
1305
+ type: Input
1306
+ }], closeEvent: [{
1307
+ type: Output
1308
+ }] } });
1309
+
1310
+ /*
1311
+ * Copyright 2015-2024 Ritense BV, the Netherlands.
1312
+ *
1313
+ * Licensed under EUPL, Version 1.2 (the "License");
1314
+ * you may not use this file except in compliance with the License.
1315
+ * You may obtain a copy of the License at
1316
+ *
1317
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1318
+ *
1319
+ * Unless required by applicable law or agreed to in writing, software
1320
+ * distributed under the License is distributed on an "AS IS" basis,
1321
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1322
+ * See the License for the specific language governing permissions and
1323
+ * limitations under the License.
1324
+ */
1325
+ class TextTemplateListComponent {
1326
+ constructor(templateService, router, route, environmentService) {
1327
+ this.templateService = templateService;
1328
+ this.router = router;
1329
+ this.route = route;
1330
+ this.environmentService = environmentService;
1331
+ this.fields = [
1332
+ {
1333
+ viewType: ViewType.TEXT,
1334
+ key: 'key',
1335
+ label: 'Key',
1336
+ },
1337
+ {
1338
+ viewType: ViewType.BOOLEAN,
1339
+ key: 'readOnly',
1340
+ label: 'Read only',
1341
+ },
1342
+ ];
1343
+ this._caseDefinitionId$ = getCaseManagementRouteParams(this.route).pipe(filter((params) => !!params?.caseDefinitionKey));
1344
+ this.readOnly$ = this._caseDefinitionId$.pipe(switchMap(caseDefinitionId => combineLatest([
1345
+ this.environmentService.canUpdateGlobalConfiguration(),
1346
+ this.templateService.isFinal(caseDefinitionId.caseDefinitionKey, caseDefinitionId.caseDefinitionVersionTag)
1347
+ ]).pipe(map(([canUpdateGlobal, isFinalCase]) => !canUpdateGlobal || isFinalCase), startWith(true))));
1348
+ this.templates$ = new BehaviorSubject(null);
1349
+ this.showAddModal$ = new BehaviorSubject(false);
1350
+ this.showDeleteModal$ = new BehaviorSubject(false);
1351
+ this.selectedRowKeys$ = new BehaviorSubject([]);
1352
+ this.loading$ = new BehaviorSubject(true);
1353
+ }
1354
+ ngOnInit() {
1355
+ this.reloadTemplateList();
1356
+ }
1357
+ openAddModal() {
1358
+ this.showAddModal$.next(true);
1359
+ }
1360
+ onAdd(data) {
1361
+ if (!data) {
1362
+ this.showAddModal$.next(false);
1363
+ return;
1364
+ }
1365
+ this._caseDefinitionId$.pipe(take(1), switchMap(caseDefinitionId => this.templateService.addTemplate({
1366
+ caseDefinitionKey: caseDefinitionId.caseDefinitionKey,
1367
+ caseDefinitionVersionTag: caseDefinitionId.caseDefinitionVersionTag,
1368
+ type: 'text', ...data
1369
+ }))).subscribe(template => {
1370
+ this.showAddModal$.next(false);
1371
+ this.gotoTextTemplateEditor(template.caseDefinitionKey, template.caseDefinitionVersionTag, template.key);
1372
+ });
1373
+ }
1374
+ showDeleteModal() {
1375
+ this.setSelectedTemplateKeys();
1376
+ this.showDeleteModal$.next(true);
1377
+ }
1378
+ onDelete(templates) {
1379
+ this.loading$.next(true);
1380
+ this._caseDefinitionId$.pipe(take(1), switchMap(caseDefinitionId => this.templateService.deleteTemplates({
1381
+ caseDefinitionKey: caseDefinitionId.caseDefinitionKey,
1382
+ caseDefinitionVersionTag: caseDefinitionId.caseDefinitionVersionTag,
1383
+ type: 'text',
1384
+ templates
1385
+ }))).subscribe(_ => {
1386
+ this.reloadTemplateList();
1387
+ });
1388
+ }
1389
+ onRowClick(template) {
1390
+ this._caseDefinitionId$.pipe(take(1)).subscribe(caseDefinitionId => this.gotoTextTemplateEditor(caseDefinitionId.caseDefinitionKey, caseDefinitionId.caseDefinitionVersionTag, template.key));
1391
+ }
1392
+ gotoTextTemplateEditor(caseDefinitionKey, caseDefinitionVersionTag, key) {
1393
+ this.router.navigate([`/case-management/case/${caseDefinitionKey}/version/${caseDefinitionVersionTag}/text-template/${key}`]);
1394
+ }
1395
+ reloadTemplateList() {
1396
+ this.loading$.next(true);
1397
+ this._caseDefinitionId$.pipe(switchMap(caseDefinitionId => this.templateService.getAllTextTemplates(caseDefinitionId.caseDefinitionKey, caseDefinitionId.caseDefinitionVersionTag)), map(templatePage => templatePage.content), take(1)).subscribe(templateListItems => {
1398
+ this.templates$.next(templateListItems);
1399
+ this.loading$.next(false);
1400
+ });
1401
+ }
1402
+ setSelectedTemplateKeys() {
1403
+ this.selectedRowKeys$.next(this.carbonList.selectedItems.map((template) => template.key));
1404
+ }
1405
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplateListComponent, deps: [{ token: FreemarkerTemplateManagementService }, { token: i2$2.Router }, { token: i2$2.ActivatedRoute }, { token: i3.EnvironmentService }], target: i0.ɵɵFactoryTarget.Component }); }
1406
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: TextTemplateListComponent, isStandalone: true, selector: "ng-component", viewQueries: [{ propertyName: "carbonList", first: true, predicate: CarbonListComponent, descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-carbon-list\n [header]=\"false\"\n [items]=\"templates$ | async\"\n [fields]=\"fields\"\n [loading]=\"loading$ | async\"\n [showSelectionColumn]=\"!(readOnly$ | async)\"\n (rowClicked)=\"onRowClick($event)\"\n>\n <ng-container header> {{ 'Title' }}</ng-container>\n\n <div carbonToolbarContent>\n <ng-container [ngTemplateOutlet]=\"addTemplateButton\"></ng-container>\n </div>\n\n <ng-container carbonToolbarActions>\n <button cdsButton=\"primary\" (click)=\"showDeleteModal()\">\n {{ 'interface.delete' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"trash-can\" size=\"16\"></svg>\n </button>\n </ng-container>\n\n <valtimo-no-results\n [action]=\"addTemplateButton\"\n description=\"{{ 'Come back later.' }}\"\n title=\"{{ 'No templates found' }}\"\n ></valtimo-no-results>\n</valtimo-carbon-list>\n\n<valtimo-text-template-add-edit-modal\n [open]=\"showAddModal$ | async\"\n (closeEvent)=\"onAdd($event)\"\n></valtimo-text-template-add-edit-modal>\n\n<ng-container *ngIf=\"{selectedRowKeys: selectedRowKeys$ | async} as obs\">\n <valtimo-text-template-delete-modal\n [deleteRowKeys]=\"obs.selectedRowKeys\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-text-template-delete-modal>\n</ng-container>\n\n<ng-template #addTemplateButton>\n <button cdsButton=\"primary\"\n [disabled]=\"readOnly$ | async\"\n (click)=\"openAddModal()\">\n {{ 'Add' }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"add\" size=\"16\"></svg>\n </button>\n</ng-template>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "ngmodule", type: CarbonListModule }, { kind: "component", type: i1.CarbonListComponent, selector: "valtimo-carbon-list", inputs: ["items", "fields", "tableTranslations", "paginatorConfig", "pagination", "loading", "actions", "actionItems", "header", "hideColumnHeader", "initialSortState", "sortState", "isSearchable", "enableSingleSelection", "lastColumnTemplate", "paginationIdentifier", "showSelectionColumn", "striped", "hideToolbar", "lockedTooltipTranslationKey", "movingRowsEnabled", "dragAndDrop", "dragAndDropDisabled"], outputs: ["rowClicked", "paginationClicked", "paginationSet", "search", "sortChanged", "moveRow", "itemsReordered"] }, { kind: "component", type: i1.CarbonNoResultsComponent, selector: "valtimo-no-results", inputs: ["action", "description", "illustration", "title", "smallPadding", "collapseVertically", "alwaysRenderVertically"] }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i4$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }, { kind: "component", type: TextTemplateDeleteModalComponent, selector: "valtimo-text-template-delete-modal", inputs: ["deleteRowKeys", "showDeleteModal$"], outputs: ["deleteEvent"] }, { kind: "component", type: TextTemplateAddEditModalComponent, selector: "valtimo-text-template-add-edit-modal", inputs: ["open", "type", "defaultKeyValue"], outputs: ["closeEvent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
1407
+ }
1408
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplateListComponent, decorators: [{
1409
+ type: Component,
1410
+ args: [{ standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [
1411
+ CommonModule,
1412
+ CarbonListModule,
1413
+ ButtonModule,
1414
+ TranslateModule,
1415
+ TextTemplateDeleteModalComponent,
1416
+ TextTemplateAddEditModalComponent
1417
+ ], template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<valtimo-carbon-list\n [header]=\"false\"\n [items]=\"templates$ | async\"\n [fields]=\"fields\"\n [loading]=\"loading$ | async\"\n [showSelectionColumn]=\"!(readOnly$ | async)\"\n (rowClicked)=\"onRowClick($event)\"\n>\n <ng-container header> {{ 'Title' }}</ng-container>\n\n <div carbonToolbarContent>\n <ng-container [ngTemplateOutlet]=\"addTemplateButton\"></ng-container>\n </div>\n\n <ng-container carbonToolbarActions>\n <button cdsButton=\"primary\" (click)=\"showDeleteModal()\">\n {{ 'interface.delete' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"trash-can\" size=\"16\"></svg>\n </button>\n </ng-container>\n\n <valtimo-no-results\n [action]=\"addTemplateButton\"\n description=\"{{ 'Come back later.' }}\"\n title=\"{{ 'No templates found' }}\"\n ></valtimo-no-results>\n</valtimo-carbon-list>\n\n<valtimo-text-template-add-edit-modal\n [open]=\"showAddModal$ | async\"\n (closeEvent)=\"onAdd($event)\"\n></valtimo-text-template-add-edit-modal>\n\n<ng-container *ngIf=\"{selectedRowKeys: selectedRowKeys$ | async} as obs\">\n <valtimo-text-template-delete-modal\n [deleteRowKeys]=\"obs.selectedRowKeys\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-text-template-delete-modal>\n</ng-container>\n\n<ng-template #addTemplateButton>\n <button cdsButton=\"primary\"\n [disabled]=\"readOnly$ | async\"\n (click)=\"openAddModal()\">\n {{ 'Add' }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"add\" size=\"16\"></svg>\n </button>\n</ng-template>\n" }]
1418
+ }], ctorParameters: () => [{ type: FreemarkerTemplateManagementService }, { type: i2$2.Router }, { type: i2$2.ActivatedRoute }, { type: i3.EnvironmentService }], propDecorators: { carbonList: [{
1419
+ type: ViewChild,
1420
+ args: [CarbonListComponent]
1421
+ }] } });
1422
+
1423
+ /*
1424
+ * Copyright 2015-2023 Ritense BV, the Netherlands.
1425
+ *
1426
+ * Licensed under EUPL, Version 1.2 (the "License");
1427
+ * you may not use this file except in compliance with the License.
1428
+ * You may obtain a copy of the License at
1429
+ *
1430
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1431
+ *
1432
+ * Unless required by applicable law or agreed to in writing, software
1433
+ * distributed under the License is distributed on an "AS IS" basis,
1434
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1435
+ * See the License for the specific language governing permissions and
1436
+ * limitations under the License.
1437
+ */
1438
+ class TextTemplateEditorComponent {
1439
+ constructor(templateService, route, pageTitleService, router, notificationService, translateService, breadcrumbService, environmentService) {
1440
+ this.templateService = templateService;
1441
+ this.route = route;
1442
+ this.pageTitleService = pageTitleService;
1443
+ this.router = router;
1444
+ this.notificationService = notificationService;
1445
+ this.translateService = translateService;
1446
+ this.breadcrumbService = breadcrumbService;
1447
+ this.environmentService = environmentService;
1448
+ this.model$ = new BehaviorSubject(null);
1449
+ this.template$ = new BehaviorSubject(null);
1450
+ this.saveDisabled$ = new BehaviorSubject(true);
1451
+ this.editorDisabled$ = new BehaviorSubject(false);
1452
+ this.moreDisabled$ = new BehaviorSubject(true);
1453
+ this.showDeleteModal$ = new BehaviorSubject(false);
1454
+ this.updatedModelValue$ = new BehaviorSubject('');
1455
+ this.canUpdateGlobalConfiguration$ = this.environmentService.canUpdateGlobalConfiguration();
1456
+ this._caseDefinitionId$ = getCaseManagementRouteParams(this.route).pipe(filter((params) => !!params?.caseDefinitionKey));
1457
+ this.templateKey$ = combineLatest([this.route.params, this.route.parent.params]).pipe(map(([params, parentParams]) => params?.templateKey || parentParams?.templateKey), filter(templateKey => !!templateKey));
1458
+ this.readOnly$ = this._caseDefinitionId$.pipe(switchMap(caseDefinitionId => combineLatest([
1459
+ this.environmentService.canUpdateGlobalConfiguration(),
1460
+ this.templateService.isFinal(caseDefinitionId.caseDefinitionKey, caseDefinitionId.caseDefinitionVersionTag)
1461
+ ]).pipe(map(([canUpdateGlobal, isFinalCase]) => !canUpdateGlobal || isFinalCase), startWith(true))));
1462
+ }
1463
+ ngOnInit() {
1464
+ this.loadTemplate();
1465
+ }
1466
+ ngAfterViewInit() {
1467
+ this.initBreadcrumb();
1468
+ }
1469
+ ngOnDestroy() {
1470
+ this.pageTitleService.enableReset();
1471
+ this.breadcrumbService.clearThirdBreadcrumb();
1472
+ this.breadcrumbService.clearFourthBreadcrumb();
1473
+ }
1474
+ onValid(valid) {
1475
+ this.saveDisabled$.next(valid === false);
1476
+ }
1477
+ onValueChange(value) {
1478
+ this.updatedModelValue$.next(value);
1479
+ }
1480
+ updateTemplate() {
1481
+ this.disableEditor();
1482
+ this.disableSave();
1483
+ this.disableMore();
1484
+ combineLatest([this.updatedModelValue$, this._caseDefinitionId$, this.templateKey$]).pipe(switchMap(([updatedModelValue, caseDefinitionId, templateKey]) => this.templateService.updateTemplate({
1485
+ key: templateKey,
1486
+ caseDefinitionKey: caseDefinitionId.caseDefinitionKey,
1487
+ caseDefinitionVersionTag: caseDefinitionId.caseDefinitionVersionTag,
1488
+ type: 'text',
1489
+ content: updatedModelValue,
1490
+ })), take(1)).subscribe({
1491
+ next: result => {
1492
+ this.enableMore();
1493
+ this.enableSave();
1494
+ this.enableEditor();
1495
+ this.showSuccessMessage(result.key);
1496
+ this.setModel(result.content);
1497
+ this.template$.next(result);
1498
+ },
1499
+ error: () => {
1500
+ this.enableMore();
1501
+ this.enableSave();
1502
+ this.enableEditor();
1503
+ },
1504
+ });
1505
+ }
1506
+ onDelete(templates) {
1507
+ this.disableEditor();
1508
+ this.disableSave();
1509
+ this.disableMore();
1510
+ this._caseDefinitionId$.pipe(take(1)).subscribe(caseDefinitionId => this.templateService.deleteTemplates({
1511
+ caseDefinitionKey: caseDefinitionId.caseDefinitionKey,
1512
+ caseDefinitionVersionTag: caseDefinitionId.caseDefinitionVersionTag,
1513
+ type: 'text',
1514
+ templates
1515
+ }).pipe(take(1)).subscribe(_ => this.router.navigate([`/case-management/case/${caseDefinitionId.caseDefinitionKey}/version/${caseDefinitionId.caseDefinitionVersionTag}/text-template`])));
1516
+ }
1517
+ showDeleteModal() {
1518
+ this.showDeleteModal$.next(true);
1519
+ }
1520
+ loadTemplate() {
1521
+ combineLatest([this._caseDefinitionId$, this.templateKey$]).pipe(tap(([_, key]) => {
1522
+ this.pageTitleService.setCustomPageTitle(`Text template: ${key}`, true);
1523
+ }), switchMap(([caseDefinitionId, key]) => this.templateService.getTextTemplate(caseDefinitionId.caseDefinitionKey, caseDefinitionId.caseDefinitionVersionTag, key)), take(1)).subscribe(result => {
1524
+ this.enableMore();
1525
+ this.enableSave();
1526
+ this.enableEditor();
1527
+ this.setModel(result.content);
1528
+ this.template$.next(result);
1529
+ });
1530
+ }
1531
+ setModel(content) {
1532
+ this.model$.next({
1533
+ value: content,
1534
+ language: 'freemarker2',
1535
+ });
1536
+ this.updatedModelValue$.next(content);
1537
+ }
1538
+ disableMore() {
1539
+ this.moreDisabled$.next(true);
1540
+ }
1541
+ enableMore() {
1542
+ this.moreDisabled$.next(false);
1543
+ }
1544
+ disableSave() {
1545
+ this.saveDisabled$.next(true);
1546
+ }
1547
+ enableSave() {
1548
+ this.saveDisabled$.next(false);
1549
+ }
1550
+ disableEditor() {
1551
+ this.editorDisabled$.next(true);
1552
+ }
1553
+ enableEditor() {
1554
+ this.editorDisabled$.next(false);
1555
+ }
1556
+ initBreadcrumb() {
1557
+ this._caseDefinitionId$.subscribe(caseDefinitionId => {
1558
+ this.breadcrumbService.setThirdBreadcrumb({
1559
+ route: [`/case-management/case/${caseDefinitionId.caseDefinitionKey}/version/${caseDefinitionId.caseDefinitionVersionTag}`],
1560
+ content: `${caseDefinitionId.caseDefinitionKey}:${caseDefinitionId.caseDefinitionVersionTag}`,
1561
+ href: `/case-management/case/${caseDefinitionId.caseDefinitionKey}/version/${caseDefinitionId.caseDefinitionVersionTag}`,
1562
+ });
1563
+ this.breadcrumbService.setFourthBreadcrumb({
1564
+ route: [`/case-management/case/${caseDefinitionId.caseDefinitionKey}/version/${caseDefinitionId.caseDefinitionVersionTag}/text-template`],
1565
+ content: 'Text template',
1566
+ href: `/case-management/case/${caseDefinitionId.caseDefinitionKey}/version/${caseDefinitionId.caseDefinitionVersionTag}/text-template`,
1567
+ });
1568
+ });
1569
+ }
1570
+ showSuccessMessage(key) {
1571
+ this.notificationService.showToast({
1572
+ caption: this.translateService.instant(`${key} was saved successfully`, {
1573
+ key,
1574
+ }),
1575
+ type: 'success',
1576
+ duration: 4000,
1577
+ showClose: true,
1578
+ title: this.translateService.instant('Saved successfully'),
1579
+ });
1580
+ }
1581
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplateEditorComponent, deps: [{ token: FreemarkerTemplateManagementService }, { token: i2$2.ActivatedRoute }, { token: i1.PageTitleService }, { token: i2$2.Router }, { token: i4$1.NotificationService }, { token: i5.TranslateService }, { token: i1.BreadcrumbService }, { token: i3.EnvironmentService }], target: i0.ɵɵFactoryTarget.Component }); }
1582
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: TextTemplateEditorComponent, isStandalone: true, selector: "ng-component", providers: [NotificationService], ngImport: i0, template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"{\n model: model$ | async,\n updatedModelValue: updatedModelValue$ | async,\n template: template$ | async,\n } as obs\">\n\n <div class=\"template-explanation\">\n Text Templates use <a target=\"_blank\" href=\"https://freemarker.apache.org/docs/dgui_quickstart_basics.html\">FreeMarker</a>\n to create placeholders inside the text. The data-model for FreeMarker is based upon nested <a\n target=\"_blank\" href=\"https://docs.valtimo.nl/reference/modules/value-resolver\">Valtimo value-resolvers</a>\n with a slightly different notation. For example: $&#123;doc.firstName&#125;. Retrieves\n the `firstName` from the case.\n\n Text Templates can be used as value resolvers. For example: $&#123;template.my-text-template&#125; or\n `template:my-text-template`.\n </div>\n\n <valtimo-editor\n [model]=\"obs.model\"\n [disabled]=\"(editorDisabled$ | async) || (readOnly$ | async)\"\n (validEvent)=\"onValid($event)\"\n (valueChangeEvent)=\"onValueChange($event)\"\n [fitPage]=\"true\"\n [fitPageExtraSpace]=\"80\"\n ></valtimo-editor>\n</ng-container>\n\n<ng-container renderInPageHeader>\n <ng-template>\n <div *ngIf=\"{\n model: model$ | async,\n moreDisabled: moreDisabled$ | async,\n template: template$ | async,\n } as obs\"\n class=\"buttons-container\"\n >\n <cds-overflow-menu class=\"overflow-button\">\n <cds-overflow-menu-option\n [disabled]=\"obs.moreDisabled || (readOnly$ | async)\"\n type=\"danger\"\n (selected)=\"showDeleteModal()\"\n >{{ 'interface.delete' | translate }}\n </cds-overflow-menu-option\n >\n </cds-overflow-menu>\n\n <button\n [disabled]=\"(saveDisabled$ | async) || (readOnly$ | async)\"\n cdsButton=\"primary\"\n size=\"md\"\n (click)=\"updateTemplate()\"\n >\n {{ 'interface.save' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"save\" size=\"16\"></svg>\n </button>\n </div>\n </ng-template>\n</ng-container>\n\n<ng-container *ngIf=\"{templateKey: templateKey$ | async} as obs\">\n <valtimo-text-template-delete-modal\n [deleteRowKeys]=\"[obs.templateKey]\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-text-template-delete-modal>\n</ng-container>\n", styles: [".loading-container{display:flex;width:100%;justify-content:center}.overflow-button{margin-right:16px}.buttons-container{display:flex;flex-direction:row}.template-explanation{margin-top:16px;margin-bottom:24px}\n/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: TabsModule }, { kind: "ngmodule", type: DialogModule }, { kind: "component", type: i4$1.OverflowMenu, selector: "cds-overflow-menu, ibm-overflow-menu", inputs: ["buttonLabel", "description", "flip", "placement", "open", "customTrigger", "offset", "wrapperClass", "triggerClass"], outputs: ["openChange"] }, { kind: "component", type: i4$1.OverflowMenuOption, selector: "cds-overflow-menu-option, ibm-overflow-menu-option", inputs: ["divider", "type", "disabled", "href", "target", "innerClass"], outputs: ["selected"] }, { kind: "ngmodule", type: ValtimoCdsOverflowButtonDirectiveModule }, { kind: "component", type: TextTemplateDeleteModalComponent, selector: "valtimo-text-template-delete-modal", inputs: ["deleteRowKeys", "showDeleteModal$"], outputs: ["deleteEvent"] }, { kind: "ngmodule", type: CarbonListModule }, { kind: "ngmodule", type: ButtonModule }, { kind: "directive", type: i4$1.Button, selector: "[cdsButton], [ibmButton]", inputs: ["ibmButton", "cdsButton", "size", "skeleton", "iconOnly", "isExpressive"] }, { kind: "ngmodule", type: EditorModule }, { kind: "component", type: i1.EditorComponent, selector: "valtimo-editor", inputs: ["editorOptions", "model", "disabled", "formatOnLoad", "widthPx", "heightPx", "heightStyle", "jsonSchema", "fitPage", "fitPageExtraSpace"], outputs: ["validEvent", "valueChangeEvent"] }, { kind: "ngmodule", type: RenderInPageHeaderDirectiveModule }, { kind: "directive", type: i1.RenderInPageHeaderDirective, selector: "[renderInPageHeader]", inputs: ["fullWidth"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
1583
+ }
1584
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplateEditorComponent, decorators: [{
1585
+ type: Component,
1586
+ args: [{ standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, providers: [NotificationService], imports: [
1587
+ CommonModule,
1588
+ TranslateModule,
1589
+ TabsModule,
1590
+ DialogModule,
1591
+ ValtimoCdsOverflowButtonDirectiveModule,
1592
+ TextTemplateDeleteModalComponent,
1593
+ CarbonListModule,
1594
+ ButtonModule,
1595
+ EditorModule,
1596
+ RenderInPageHeaderDirectiveModule,
1597
+ ], template: "<!--\n ~ Copyright 2015-2023 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container\n *ngIf=\"{\n model: model$ | async,\n updatedModelValue: updatedModelValue$ | async,\n template: template$ | async,\n } as obs\">\n\n <div class=\"template-explanation\">\n Text Templates use <a target=\"_blank\" href=\"https://freemarker.apache.org/docs/dgui_quickstart_basics.html\">FreeMarker</a>\n to create placeholders inside the text. The data-model for FreeMarker is based upon nested <a\n target=\"_blank\" href=\"https://docs.valtimo.nl/reference/modules/value-resolver\">Valtimo value-resolvers</a>\n with a slightly different notation. For example: $&#123;doc.firstName&#125;. Retrieves\n the `firstName` from the case.\n\n Text Templates can be used as value resolvers. For example: $&#123;template.my-text-template&#125; or\n `template:my-text-template`.\n </div>\n\n <valtimo-editor\n [model]=\"obs.model\"\n [disabled]=\"(editorDisabled$ | async) || (readOnly$ | async)\"\n (validEvent)=\"onValid($event)\"\n (valueChangeEvent)=\"onValueChange($event)\"\n [fitPage]=\"true\"\n [fitPageExtraSpace]=\"80\"\n ></valtimo-editor>\n</ng-container>\n\n<ng-container renderInPageHeader>\n <ng-template>\n <div *ngIf=\"{\n model: model$ | async,\n moreDisabled: moreDisabled$ | async,\n template: template$ | async,\n } as obs\"\n class=\"buttons-container\"\n >\n <cds-overflow-menu class=\"overflow-button\">\n <cds-overflow-menu-option\n [disabled]=\"obs.moreDisabled || (readOnly$ | async)\"\n type=\"danger\"\n (selected)=\"showDeleteModal()\"\n >{{ 'interface.delete' | translate }}\n </cds-overflow-menu-option\n >\n </cds-overflow-menu>\n\n <button\n [disabled]=\"(saveDisabled$ | async) || (readOnly$ | async)\"\n cdsButton=\"primary\"\n size=\"md\"\n (click)=\"updateTemplate()\"\n >\n {{ 'interface.save' | translate }}\n\n <svg class=\"cds--btn__icon\" cdsIcon=\"save\" size=\"16\"></svg>\n </button>\n </div>\n </ng-template>\n</ng-container>\n\n<ng-container *ngIf=\"{templateKey: templateKey$ | async} as obs\">\n <valtimo-text-template-delete-modal\n [deleteRowKeys]=\"[obs.templateKey]\"\n [showDeleteModal$]=\"showDeleteModal$\"\n (deleteEvent)=\"onDelete($event)\"\n >\n </valtimo-text-template-delete-modal>\n</ng-container>\n", styles: [".loading-container{display:flex;width:100%;justify-content:center}.overflow-button{margin-right:16px}.buttons-container{display:flex;flex-direction:row}.template-explanation{margin-top:16px;margin-bottom:24px}\n/*!\n * Copyright 2015-2023 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
1598
+ }], ctorParameters: () => [{ type: FreemarkerTemplateManagementService }, { type: i2$2.ActivatedRoute }, { type: i1.PageTitleService }, { type: i2$2.Router }, { type: i4$1.NotificationService }, { type: i5.TranslateService }, { type: i1.BreadcrumbService }, { type: i3.EnvironmentService }] });
1599
+
1600
+ /*
1601
+ * Copyright 2015-2023 Ritense BV, the Netherlands.
1602
+ *
1603
+ * Licensed under EUPL, Version 1.2 (the "License");
1604
+ * you may not use this file except in compliance with the License.
1605
+ * You may obtain a copy of the License at
1606
+ *
1607
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1608
+ *
1609
+ * Unless required by applicable law or agreed to in writing, software
1610
+ * distributed under the License is distributed on an "AS IS" basis,
1611
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1612
+ * See the License for the specific language governing permissions and
1613
+ * limitations under the License.
1614
+ */
1615
+ const routes = [
1616
+ {
1617
+ path: 'case-management/case/:caseDefinitionKey/version/:caseDefinitionVersionTag/text-template/:templateKey',
1618
+ component: TextTemplateEditorComponent,
1619
+ canActivate: [AuthGuardService],
1620
+ data: {
1621
+ title: 'Text Template Editor',
1622
+ templates: [ROLE_ADMIN],
1623
+ customPageTitle: true,
1624
+ },
1625
+ },
1626
+ ];
1627
+ class TemplateManagementRoutingModule {
1628
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TemplateManagementRoutingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
1629
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.14", ngImport: i0, type: TemplateManagementRoutingModule, imports: [CommonModule, i2$2.RouterModule], exports: [RouterModule] }); }
1630
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TemplateManagementRoutingModule, imports: [CommonModule, RouterModule.forChild(routes), RouterModule] }); }
1631
+ }
1632
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TemplateManagementRoutingModule, decorators: [{
1633
+ type: NgModule,
1634
+ args: [{
1635
+ imports: [CommonModule, RouterModule.forChild(routes)],
1636
+ exports: [RouterModule],
1637
+ }]
1638
+ }] });
1639
+
1640
+ /*
1641
+ * Copyright 2015-2022 Ritense BV, the Netherlands.
1642
+ *
1643
+ * Licensed under EUPL, Version 1.2 (the "License");
1644
+ * you may not use this file except in compliance with the License.
1645
+ * You may obtain a copy of the License at
1646
+ *
1647
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1648
+ *
1649
+ * Unless required by applicable law or agreed to in writing, software
1650
+ * distributed under the License is distributed on an "AS IS" basis,
1651
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1652
+ * See the License for the specific language governing permissions and
1653
+ * limitations under the License.
1654
+ */
1655
+ class GenerateTextFileComponent {
1656
+ constructor(modalService, documentService, templateService) {
1657
+ this.modalService = modalService;
1658
+ this.documentService = documentService;
1659
+ this.templateService = templateService;
1660
+ this.valid = new EventEmitter();
1661
+ this.configuration = new EventEmitter();
1662
+ this.formValue$ = new BehaviorSubject(null);
1663
+ this.valid$ = new BehaviorSubject(false);
1664
+ this.loading$ = new BehaviorSubject(true);
1665
+ this.textTemplateItems$ = this.modalService.modalData$.pipe(switchMap(params => this.documentService.findProcessDocumentDefinitionsByProcessDefinitionKey(params?.processDefinitionKey)), switchMap(processDocumentDefinitions => combineLatest([
1666
+ of({ content: [] }),
1667
+ ...processDocumentDefinitions.map(processDocumentDefinition => this.templateService.getAllTextTemplates(processDocumentDefinition.id.documentDefinitionId.name)),
1668
+ ])), map(results => {
1669
+ return results
1670
+ .flatMap(result => result.content)
1671
+ .map(template => ({
1672
+ id: template.key,
1673
+ text: template.key,
1674
+ }));
1675
+ }), tap(() => {
1676
+ this.loading$.next(false);
1677
+ }));
1678
+ }
1679
+ ngOnInit() {
1680
+ this.openSaveSubscription();
1681
+ }
1682
+ ngOnDestroy() {
1683
+ this.saveSubscription?.unsubscribe();
1684
+ }
1685
+ formValueChange(formValue) {
1686
+ this.formValue$.next(formValue);
1687
+ this.handleValid(formValue);
1688
+ }
1689
+ handleValid(formValue) {
1690
+ const valid = !!(formValue.textTemplateKey && formValue.processVariableName);
1691
+ this.valid$.next(valid);
1692
+ this.valid.emit(valid);
1693
+ }
1694
+ openSaveSubscription() {
1695
+ this.saveSubscription = this.save$?.subscribe(save => {
1696
+ combineLatest([this.formValue$, this.valid$])
1697
+ .pipe(take(1))
1698
+ .subscribe(([formValue, valid]) => {
1699
+ if (valid) {
1700
+ this.configuration.emit(formValue);
1701
+ }
1702
+ });
1703
+ });
1704
+ }
1705
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: GenerateTextFileComponent, deps: [{ token: i1.ModalService }, { token: i2$1.DocumentService }, { token: FreemarkerTemplateManagementService }], target: i0.ɵɵFactoryTarget.Component }); }
1706
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: GenerateTextFileComponent, isStandalone: false, selector: "valtimo-generate-text-file-configuration", inputs: { save$: "save$", disabled$: "disabled$", pluginId: "pluginId", prefillConfiguration$: "prefillConfiguration$" }, outputs: { valid: "valid", configuration: "configuration" }, ngImport: i0, template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null,\n textTemplateItems: textTemplateItems$ | async,\n loading: loading$ | async,\n } as obs\"\n>\n <ng-container *ngIf=\"obs.loading === false; else loading\">\n <v-paragraph [margin]=\"true\" [italic]=\"true\">\n {{ 'generateTextFileDescription' | pluginTranslate: pluginId | async }}\n </v-paragraph>\n <v-form (valueChange)=\"formValueChange($event)\">\n <v-select\n [items]=\"obs.textTemplateItems\"\n [margin]=\"true\"\n [widthInPx]=\"350\"\n name=\"textTemplateKey\"\n [title]=\"'textTemplateKey' | pluginTranslate: pluginId | async\"\n [disabled]=\"obs.disabled\"\n [defaultSelectionId]=\"obs.prefill?.textTemplateKey\"\n [required]=\"true\"\n [loading]=\"!obs.textTemplateItems\"\n [tooltip]=\"'textTemplateKeyTooltip' | pluginTranslate: pluginId | async\"\n ></v-select>\n <v-input\n name=\"processVariableName\"\n [title]=\"'processVariableName' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [defaultValue]=\"obs.prefill?.processVariableName || 'contentId'\"\n [disabled]=\"obs.disabled\"\n [tooltip]=\"'processVariableNameTooltip' | pluginTranslate: pluginId | async\"\n ></v-input>\n </v-form>\n </ng-container>\n</ng-container>\n\n<ng-template #loading>\n <div class=\"loading-container\">\n <cds-loading></cds-loading>\n </div>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1.FormComponent, selector: "v-form", inputs: ["className"], outputs: ["valueChange"] }, { kind: "component", type: i1.ParagraphComponent, selector: "v-paragraph", inputs: ["center", "fullWidth", "margin", "italic", "loading", "dataTestId"] }, { kind: "component", type: i1.SelectComponent, selector: "v-select", inputs: ["items", "defaultSelection", "defaultSelectionId", "defaultSelectionIds", "disabled", "dropUp", "multiple", "margin", "widthInPx", "notFoundText", "clearAllText", "clearText", "name", "title", "titleTranslationKey", "clearSelectionSubject$", "tooltip", "required", "loading", "loadingText", "placeholder", "smallMargin", "carbonTheme", "appendInline", "dataTestId"], outputs: ["selectedChange"] }, { kind: "component", type: i1.InputComponent, selector: "v-input", inputs: ["name", "type", "title", "titleTranslationKey", "defaultValue", "widthPx", "fullWidth", "margin", "smallMargin", "disabled", "step", "min", "maxLength", "tooltip", "required", "hideNumberSpinBox", "smallLabel", "rows", "clear$", "carbonTheme", "placeholder", "dataTestId", "trim"], outputs: ["valueChange"] }, { kind: "component", type: i4$1.Loading, selector: "cds-loading, ibm-loading", inputs: ["title", "isActive", "size", "overlay"] }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }, { kind: "pipe", type: i6.PluginTranslatePipe, name: "pluginTranslate" }] }); }
1707
+ }
1708
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: GenerateTextFileComponent, decorators: [{
1709
+ type: Component,
1710
+ args: [{ standalone: false, selector: 'valtimo-generate-text-file-configuration', template: "<!--\n ~ Copyright 2015-2022 Ritense BV, the Netherlands.\n ~\n ~ Licensed under EUPL, Version 1.2 (the \"License\");\n ~ you may not use this file except in compliance with the License.\n ~ You may obtain a copy of the License at\n ~\n ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n ~\n ~ Unless required by applicable law or agreed to in writing, software\n ~ distributed under the License is distributed on an \"AS IS\" basis,\n ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n ~ See the License for the specific language governing permissions and\n ~ limitations under the License.\n -->\n\n<ng-container *ngIf=\"{\n disabled: disabled$ | async,\n prefill: prefillConfiguration$ ? (prefillConfiguration$ | async) : null,\n textTemplateItems: textTemplateItems$ | async,\n loading: loading$ | async,\n } as obs\"\n>\n <ng-container *ngIf=\"obs.loading === false; else loading\">\n <v-paragraph [margin]=\"true\" [italic]=\"true\">\n {{ 'generateTextFileDescription' | pluginTranslate: pluginId | async }}\n </v-paragraph>\n <v-form (valueChange)=\"formValueChange($event)\">\n <v-select\n [items]=\"obs.textTemplateItems\"\n [margin]=\"true\"\n [widthInPx]=\"350\"\n name=\"textTemplateKey\"\n [title]=\"'textTemplateKey' | pluginTranslate: pluginId | async\"\n [disabled]=\"obs.disabled\"\n [defaultSelectionId]=\"obs.prefill?.textTemplateKey\"\n [required]=\"true\"\n [loading]=\"!obs.textTemplateItems\"\n [tooltip]=\"'textTemplateKeyTooltip' | pluginTranslate: pluginId | async\"\n ></v-select>\n <v-input\n name=\"processVariableName\"\n [title]=\"'processVariableName' | pluginTranslate: pluginId | async\"\n [margin]=\"true\"\n [defaultValue]=\"obs.prefill?.processVariableName || 'contentId'\"\n [disabled]=\"obs.disabled\"\n [tooltip]=\"'processVariableNameTooltip' | pluginTranslate: pluginId | async\"\n ></v-input>\n </v-form>\n </ng-container>\n</ng-container>\n\n<ng-template #loading>\n <div class=\"loading-container\">\n <cds-loading></cds-loading>\n </div>\n</ng-template>\n" }]
1711
+ }], ctorParameters: () => [{ type: i1.ModalService }, { type: i2$1.DocumentService }, { type: FreemarkerTemplateManagementService }], propDecorators: { save$: [{
1712
+ type: Input
1713
+ }], disabled$: [{
1714
+ type: Input
1715
+ }], pluginId: [{
1716
+ type: Input
1717
+ }], prefillConfiguration$: [{
1718
+ type: Input
1719
+ }], valid: [{
1720
+ type: Output
1721
+ }], configuration: [{
1722
+ type: Output
1723
+ }] } });
1724
+
1725
+ /*
1726
+ * Copyright 2015-2022 Ritense BV, the Netherlands.
1727
+ *
1728
+ * Licensed under EUPL, Version 1.2 (the "License");
1729
+ * you may not use this file except in compliance with the License.
1730
+ * You may obtain a copy of the License at
1731
+ *
1732
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1733
+ *
1734
+ * Unless required by applicable law or agreed to in writing, software
1735
+ * distributed under the License is distributed on an "AS IS" basis,
1736
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1737
+ * See the License for the specific language governing permissions and
1738
+ * limitations under the License.
1739
+ */
1740
+ class TextTemplatePluginModule {
1741
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplatePluginModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
1742
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.14", ngImport: i0, type: TextTemplatePluginModule, declarations: [GenerateTextFileComponent,
1743
+ TextTemplateConfigurationComponent], imports: [CommonModule,
1744
+ PluginTranslatePipeModule,
1745
+ TemplateManagementRoutingModule,
1746
+ FormModule,
1747
+ ParagraphModule,
1748
+ SelectModule,
1749
+ ConfirmationModalModule,
1750
+ TranslateModule,
1751
+ ReactiveFormsModule,
1752
+ CarbonListModule,
1753
+ EditorModule,
1754
+ InputModule$1,
1755
+ ButtonModule,
1756
+ DialogModule,
1757
+ DropdownModule,
1758
+ IconModule,
1759
+ InputModule,
1760
+ LoadingModule,
1761
+ ModalModule,
1762
+ NotificationModule,
1763
+ RenderInPageHeaderDirectiveModule,
1764
+ TabsModule], exports: [GenerateTextFileComponent] }); }
1765
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplatePluginModule, providers: [
1766
+ {
1767
+ provide: CASE_MANAGEMENT_TAB_TOKEN,
1768
+ useValue: {
1769
+ translationKey: 'text-template',
1770
+ component: TextTemplateListComponent,
1771
+ },
1772
+ multi: true,
1773
+ }
1774
+ ], imports: [CommonModule,
1775
+ PluginTranslatePipeModule,
1776
+ TemplateManagementRoutingModule,
1777
+ FormModule,
1778
+ ParagraphModule,
1779
+ SelectModule,
1780
+ ConfirmationModalModule,
1781
+ TranslateModule,
1782
+ ReactiveFormsModule,
1783
+ CarbonListModule,
1784
+ EditorModule,
1785
+ InputModule$1,
1786
+ ButtonModule,
1787
+ DialogModule,
1788
+ DropdownModule,
1789
+ IconModule,
1790
+ InputModule,
1791
+ LoadingModule,
1792
+ ModalModule,
1793
+ NotificationModule,
1794
+ RenderInPageHeaderDirectiveModule,
1795
+ TabsModule] }); }
1796
+ }
1797
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TextTemplatePluginModule, decorators: [{
1798
+ type: NgModule,
1799
+ args: [{
1800
+ declarations: [
1801
+ GenerateTextFileComponent,
1802
+ TextTemplateConfigurationComponent,
1803
+ ],
1804
+ imports: [
1805
+ CommonModule,
1806
+ PluginTranslatePipeModule,
1807
+ TemplateManagementRoutingModule,
1808
+ FormModule,
1809
+ ParagraphModule,
1810
+ SelectModule,
1811
+ ConfirmationModalModule,
1812
+ TranslateModule,
1813
+ ReactiveFormsModule,
1814
+ CarbonListModule,
1815
+ EditorModule,
1816
+ InputModule$1,
1817
+ ButtonModule,
1818
+ DialogModule,
1819
+ DropdownModule,
1820
+ IconModule,
1821
+ InputModule,
1822
+ LoadingModule,
1823
+ ModalModule,
1824
+ NotificationModule,
1825
+ RenderInPageHeaderDirectiveModule,
1826
+ TabsModule,
1827
+ ],
1828
+ exports: [
1829
+ GenerateTextFileComponent,
1830
+ ],
1831
+ providers: [
1832
+ {
1833
+ provide: CASE_MANAGEMENT_TAB_TOKEN,
1834
+ useValue: {
1835
+ translationKey: 'text-template',
1836
+ component: TextTemplateListComponent,
1837
+ },
1838
+ multi: true,
1839
+ }
1840
+ ]
1841
+ }]
1842
+ }] });
1843
+
1844
+ /*
1845
+ * Copyright 2015-2022 Ritense BV, the Netherlands.
1846
+ *
1847
+ * Licensed under EUPL, Version 1.2 (the "License");
1848
+ * you may not use this file except in compliance with the License.
1849
+ * You may obtain a copy of the License at
1850
+ *
1851
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1852
+ *
1853
+ * Unless required by applicable law or agreed to in writing, software
1854
+ * distributed under the License is distributed on an "AS IS" basis,
1855
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1856
+ * See the License for the specific language governing permissions and
1857
+ * limitations under the License.
1858
+ */
1859
+ const TEXT_TEMPLATE_PLUGIN_LOGO_BASE64 = 'data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPHN2ZyBpZD0ic3ZnMiIgdmlld0JveD0iMCAwIDQwMCAyMDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPHBhdGggZD0iTSAzMjcuMTE2IDE0NS44OTggTCAzNDAuMzA0IDE2NS44OTIgTCAzODQuMjQxIDk5LjI0NiBMIDM0MC4zMDQgMzIuNjAxIEwgMzI3LjExNiA1Mi41OTUgTCAzNTcuODg4IDk5LjI0NiBMIDMyNy4xMTYgMTQ1Ljg5OCBaIiBzdHlsZT0iZmlsbDogcmdiKDAsIDgwLCAxNzgpOyIgdHJhbnNmb3JtPSJtYXRyaXgoMSwgMCwgMCwgMSwgLTUuNjg0MzQxODg2MDgwODAyZS0xNCwgMCkiLz4KICA8cGF0aCBkPSJNIDY0LjcwMyA1Mi41OTUgTCA1MS41MTggMzIuNjAxIEwgNy41OCA5OS4yNDYgTCA1MS41MTggMTY1Ljg5MiBMIDY0LjcwMyAxNDUuODk4IEwgMzMuOTMzIDk5LjI0NiBMIDY0LjcwMyA1Mi41OTUgWiIgc3R5bGU9ImZpbGw6IHJnYigwLCA4MCwgMTc4KTsiIHRyYW5zZm9ybT0ibWF0cml4KDEsIDAsIDAsIDEsIC01LjY4NDM0MTg4NjA4MDgwMmUtMTQsIDApIi8+CiAgPHBhdGggZD0iTSAxMTIuODYgMzIuNjAxIEwgMTM5LjUxOCAzMi42MDEgTCAxMzQuODE1IDU5LjI2IEwgMTYxLjQ3NCA1OS4yNiBMIDE2Ni4xNzYgMzIuNjAxIEwgMTkyLjgzNCAzMi42MDEgTCAxODguMTMgNTkuMjYgTCAyMTQuNzg4IDU5LjI2IEwgMjEwLjA3NyA4NS45MTcgTCAxODMuNDE4IDg1LjkxNyBMIDE3OC43MjMgMTEyLjU3NSBMIDIwNS4zODIgMTEyLjU3NSBMIDIwMC42NzggMTM5LjIzMyBMIDE3NC4wMjEgMTM5LjIzMyBMIDE2OS4zMzYgMTY1Ljg5MiBMIDE0Mi42NzkgMTY1Ljg5MiBMIDE0Ny4zNzMgMTM5LjIzMyBMIDEyMC43MTUgMTM5LjIzMyBMIDExNi4wOTcgMTY1Ljg5MiBMIDg5LjM2MiAxNjUuODkyIEwgOTQuMDU2IDEzOS4yMzMgTCA2Ny4zOTggMTM5LjIzMyBMIDcyLjEwMiAxMTIuNTc1IEwgOTguNzYgMTEyLjU3NSBMIDEwMy40NTQgODUuOTg1IEwgNzYuNzk2IDg1Ljk4NSBMIDgxLjQ5OCA1OS4yNiBMIDEwOC4xNTcgNTkuMjYgTCAxMTIuODYgMzIuNjAxIFogTSAxMjUuNDE3IDExMi41NzUgTCAxNTIuMDc2IDExMi41NzUgTCAxNTYuNzc5IDg1LjkxNyBMIDEzMC4xMjEgODUuOTE3IEwgMTI1LjQxNyAxMTIuNTc1IFoiIHN0eWxlPSJmaWxsOiByZ2IoMCwgODAsIDE3OCk7IiB0cmFuc2Zvcm09Im1hdHJpeCgxLCAwLCAwLCAxLCAtNS42ODQzNDE4ODYwODA4MDJlLTE0LCAwKSIvPgogIDxnIHRyYW5zZm9ybT0ibWF0cml4KDAuMjQ2MjE5MDA5MTYwOTk1NDgsIDAsIDAsIDAuMjQ2MjE5MDA5MTYwOTk1NDgsIDIwNC4yOTI0MTk0MzM1OTM3LCAzMi4xNjgzNjkyOTMyMTI4OSkiIHN0eWxlPSIiPgogICAgPHBhdGggZD0iTTQ4Ni4yMDEsMTk2LjEyNGgtMTMuMTY2VjEzMi41OWMwLTAuMzk2LTAuMDYyLTAuNzk1LTAuMTE1LTEuMTk2Yy0wLjAyMS0yLjUyMy0wLjgyNS01LTIuNTUyLTYuOTYzTDM2NC42NTcsMy42NzcmIzEwOyYjOTsmIzk7Yy0wLjAzMy0wLjAzMS0wLjA2NC0wLjA0Mi0wLjA4NS0wLjA3NWMtMC42My0wLjcwNC0xLjM2NC0xLjI5LTIuMTQzLTEuNzk2Yy0wLjIyOS0wLjE1NC0wLjQ2MS0wLjI4My0wLjcwMi0wLjQxOCYjMTA7JiM5OyYjOTtjLTAuNjcyLTAuMzY2LTEuMzg3LTAuNjcxLTIuMTIxLTAuODkyYy0wLjItMC4wNTUtMC4zNzktMC4xMzQtMC41NzctMC4xODhDMzU4LjIzLDAuMTE4LDM1Ny40MDEsMCwzNTYuNTYyLDBIOTYuNzU3JiMxMDsmIzk7JiM5O0M4NC44OTQsMCw3NS4yNTYsOS42NDksNzUuMjU2LDIxLjUwMnYxNzQuNjE2SDYyLjA5Yy0xNi45NjgsMC0zMC43MjksMTMuNzUzLTMwLjcyOSwzMC43M3YxNTkuODEyJiMxMDsmIzk7JiM5O2MwLDE2Ljk2MSwxMy43NjEsMzAuNzMxLDMwLjcyOSwzMC43MzFoMTMuMTY2VjUyNi43OWMwLDExLjg1NCw5LjYzOCwyMS41MDEsMjEuNTAxLDIxLjUwMWgzNTQuNzc2JiMxMDsmIzk7JiM5O2MxMS44NTMsMCwyMS41MDEtOS42NDcsMjEuNTAxLTIxLjUwMVY0MTcuMzkyaDEzLjE2NmMxNi45NjYsMCwzMC43MjktMTMuNzY0LDMwLjcyOS0zMC43MzFWMjI2Ljg1NCYjMTA7JiM5OyYjOTtDNTE2LjkzLDIwOS44NzIsNTAzLjE2NywxOTYuMTI0LDQ4Ni4yMDEsMTk2LjEyNHogTTk2Ljc1NywyMS41MDJoMjQ5LjA1NHYxMTAuMDA2YzAsNS45NDMsNC44MTcsMTAuNzUxLDEwLjc1MSwxMC43NTFoOTQuOTcyJiMxMDsmIzk7JiM5O3Y1My44NjRIOTYuNzU3VjIxLjUwMnogTTIwMi44MTQsMjI1LjA0Mmg0MS42OGwxNC4wNjMsMjkuM2M0Ljc1Niw5Ljc1Niw4LjMzNiwxNy42MjIsMTIuMTQ3LDI2LjY3NmgwLjQ4JiMxMDsmIzk7JiM5O2MzLjc5OC0xMC4yNDIsNi45LTE3LjM5MiwxMC45NS0yNi42NzZsMTMuNTg3LTI5LjNoNDEuNDQ5bC00NS4yNjEsNzguMzYzbDQ3LjYzOCw4Mi4xODVoLTQxLjkyN2wtMTQuNTI1LTI5LjA2JiMxMDsmIzk7JiM5O2MtNS45NTYtMTEuMTk3LTkuNzcxLTE5LjUyOC0xNC4yOTktMjguODI1aC0wLjQ3OGMtMy4zMzQsOS4yOTctNy4zODEsMTcuNjI4LTEyLjM4MSwyOC44MjVsLTEzLjMzNiwyOS4wNmgtNDEuNDU1bDQ2LjQ1NS04MS4yMjQmIzEwOyYjOTsmIzk7TDIwMi44MTQsMjI1LjA0MnogTTY2LjA4LDI1NS41MzJ2LTMwLjQ4OWgxMjMuMzgydjMwLjQ4OWgtNDMuODI4djEzMC4wNDloLTM2LjQzNFYyNTUuNTMySDY2LjA4eiBNNDUxLjUzNCw1MjAuOTYySDk2Ljc1N3YtMTAzLjU3JiMxMDsmIzk7JiM5O2gzNTQuNzc2VjUyMC45NjJ6IE00NzEuNzY0LDI1NS41MzJoLTQzLjgzMXYxMzAuMDQ5aC0zNi40NDJWMjU1LjUzMmgtNDMuMTE5di0zMC40ODloMTIzLjM5M1YyNTUuNTMyeiIvPgogIDwvZz4KPC9zdmc+';
1860
+
1861
+ /*
1862
+ * Copyright 2015-2022 Ritense BV, the Netherlands.
1863
+ *
1864
+ * Licensed under EUPL, Version 1.2 (the "License");
1865
+ * you may not use this file except in compliance with the License.
1866
+ * You may obtain a copy of the License at
1867
+ *
1868
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1869
+ *
1870
+ * Unless required by applicable law or agreed to in writing, software
1871
+ * distributed under the License is distributed on an "AS IS" basis,
1872
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1873
+ * See the License for the specific language governing permissions and
1874
+ * limitations under the License.
1875
+ */
1876
+
1877
+ /*
1878
+ * Copyright 2015-2022 Ritense BV, the Netherlands.
1879
+ *
1880
+ * Licensed under EUPL, Version 1.2 (the "License");
1881
+ * you may not use this file except in compliance with the License.
1882
+ * You may obtain a copy of the License at
1883
+ *
1884
+ * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
1885
+ *
1886
+ * Unless required by applicable law or agreed to in writing, software
1887
+ * distributed under the License is distributed on an "AS IS" basis,
1888
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1889
+ * See the License for the specific language governing permissions and
1890
+ * limitations under the License.
1891
+ */
1892
+ const textTemplatePluginSpecification = {
1893
+ pluginId: 'text-template',
1894
+ pluginConfigurationComponent: TextTemplateConfigurationComponent,
1895
+ pluginLogoBase64: TEXT_TEMPLATE_PLUGIN_LOGO_BASE64,
1896
+ functionConfigurationComponents: {
1897
+ 'generate-text-file': GenerateTextFileComponent,
1898
+ },
1899
+ pluginTranslations: {
1900
+ nl: {
1901
+ title: 'Text sjablonen',
1902
+ 'generate-text-file': 'Genereer Textbestand',
1903
+ description: 'Maak Text sjablonen met Freemarker.',
1904
+ configurationTitle: 'Configuratienaam',
1905
+ configurationTitleTooltip: 'De naam van de huidige plug-in configuratie. Onder deze naam kan de configuratie worden gevonden in de rest van de applicatie.',
1906
+ generateTextFileDescription: 'Deze actie genereert de inhoud van een text-template en slaat het resultaat op in een tijdelijk bestand. Het ID van het bestand wordt opgeslagen in een Proces Variabele.',
1907
+ textTemplateKey: 'Text sjabloon',
1908
+ textTemplateKeyTooltip: 'Op bases van deze sjabloon wordt de text-template gegenereerd',
1909
+ processVariableName: 'Procesvariabelenaam',
1910
+ processVariableNameTooltip: 'Het resultaat wordt opgeslagen in een procesvariabele met deze naam',
1911
+ },
1912
+ en: {
1913
+ title: 'Text Templates',
1914
+ 'generate-text-file': 'Generate Text File',
1915
+ description: 'Create text-template templates with Freemarker.',
1916
+ configurationTitle: 'Configuration Name',
1917
+ configurationTitleTooltip: 'The name of the current plug-in configuration. The configuration can be found under this name in the rest of the application.',
1918
+ generateTextFileDescription: 'This action generates the content of an text-template and saves the result in a temporary file. The file ID is stored in a Process Variable.',
1919
+ textTemplateKey: 'Text Template',
1920
+ textTemplateKeyTooltip: 'The text-template will be generated based on this template.',
1921
+ processVariableName: 'Process Variable Name',
1922
+ processVariableNameTooltip: 'The result will be stored in a process variable with this name.',
1923
+ },
1924
+ de: {
1925
+ title: 'Text-Vorlagen',
1926
+ 'generate-text-file': 'Text-Datei generieren',
1927
+ description: 'Erstellen Sie Text-Vorlagen mit Freemarker.',
1928
+ configurationTitle: 'Konfigurationsname',
1929
+ configurationTitleTooltip: 'Der Name der aktuellen Plug-in-Konfiguration. Unter diesem Namen kann die Konfiguration im Rest der Anwendung gefunden werden.',
1930
+ generateTextFileDescription: 'Diese Aktion generiert den Inhalt einer Text und speichert das Ergebnis in einer temporären Datei. Die Datei-ID wird in einer Prozessvariablen gespeichert.',
1931
+ textTemplateKey: 'Text-Vorlage',
1932
+ textTemplateKeyTooltip: 'Die Text wird basierend auf dieser Vorlage generiert.',
1933
+ processVariableName: 'Prozessvariablenname',
1934
+ processVariableNameTooltip: 'Das Ergebnis wird in einer Prozessvariablen mit diesem Namen gespeichert.',
1935
+ },
1936
+ },
1937
+ };
1938
+
1023
1939
  /*
1024
1940
  * Copyright 2015-2022 Ritense BV, the Netherlands.
1025
1941
  *
@@ -1043,5 +1959,5 @@ const mailTemplatePluginSpecification = {
1043
1959
  * Generated bundle index. Do not edit.
1044
1960
  */
1045
1961
 
1046
- export { GenerateMailContentComponent, GenerateMailFileComponent, MailTemplateAddEditModalComponent, MailTemplateConfigurationComponent, MailTemplateDeleteModalComponent, MailTemplateEditorComponent, MailTemplateListComponent, MailTemplatePluginModule, mailTemplatePluginSpecification };
1962
+ export { GenerateMailContentComponent, GenerateMailFileComponent, GenerateTextFileComponent, MailTemplateAddEditModalComponent, MailTemplateConfigurationComponent, MailTemplateDeleteModalComponent, MailTemplateEditorComponent, MailTemplateListComponent, MailTemplatePluginModule, TextTemplateAddEditModalComponent, TextTemplateConfigurationComponent, TextTemplateDeleteModalComponent, TextTemplateEditorComponent, TextTemplateListComponent, TextTemplatePluginModule, mailTemplatePluginSpecification, textTemplatePluginSpecification };
1047
1963
  //# sourceMappingURL=valtimo-plugins-freemarker.mjs.map