@pega/angular-sdk-overrides 24.2.10 → 25.1.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/designSystemExtension/alert/alert.component.scss +3 -3
- package/lib/designSystemExtension/alert/alert.component.ts +0 -1
- package/lib/designSystemExtension/alert-banner/alert-banner.component.ts +0 -1
- package/lib/designSystemExtension/banner/banner.component.html +1 -1
- package/lib/designSystemExtension/banner/banner.component.scss +17 -3
- package/lib/designSystemExtension/banner/banner.component.ts +0 -1
- package/lib/designSystemExtension/case-create-stage/case-create-stage.component.ts +0 -1
- package/lib/designSystemExtension/field-group/field-group.component.ts +0 -1
- package/lib/designSystemExtension/material-case-summary/material-case-summary.component.html +6 -3
- package/lib/designSystemExtension/material-case-summary/material-case-summary.component.scss +5 -34
- package/lib/designSystemExtension/material-case-summary/material-case-summary.component.ts +0 -2
- package/lib/designSystemExtension/material-details/material-details.component.scss +0 -5
- package/lib/designSystemExtension/material-details/material-details.component.ts +0 -1
- package/lib/designSystemExtension/material-details-fields/material-details-fields.component.html +3 -3
- package/lib/designSystemExtension/material-details-fields/material-details-fields.component.scss +4 -3
- package/lib/designSystemExtension/material-details-fields/material-details-fields.component.ts +6 -1
- package/lib/designSystemExtension/material-summary-item/material-summary-item.component.scss +4 -17
- package/lib/designSystemExtension/material-summary-item/material-summary-item.component.ts +0 -1
- package/lib/designSystemExtension/material-summary-list/material-summary-list.component.ts +0 -1
- package/lib/designSystemExtension/material-utility/material-utility.component.scss +1 -2
- package/lib/designSystemExtension/material-vertical-tabs/material-vertical-tabs.component.scss +1 -1
- package/lib/designSystemExtension/material-vertical-tabs/material-vertical-tabs.component.ts +0 -1
- package/lib/designSystemExtension/operator/operator.component.html +2 -2
- package/lib/designSystemExtension/operator/operator.component.scss +13 -12
- package/lib/designSystemExtension/operator/operator.component.ts +4 -5
- package/lib/designSystemExtension/pulse/pulse.component.scss +2 -2
- package/lib/designSystemExtension/pulse/pulse.component.ts +0 -1
- package/lib/designSystemExtension/rich-text-editor/rich-text-editor.component.html +4 -17
- package/lib/designSystemExtension/rich-text-editor/rich-text-editor.component.scss +0 -1
- package/lib/designSystemExtension/rich-text-editor/rich-text-editor.component.ts +30 -1
- package/lib/designSystemExtension/wss-quick-create/wss-quick-create.component.scss +16 -9
- package/lib/designSystemExtension/wss-quick-create/wss-quick-create.component.ts +0 -1
- package/lib/field/auto-complete/auto-complete.component.html +0 -2
- package/lib/field/auto-complete/auto-complete.component.ts +48 -173
- package/lib/field/cancel-alert/cancel-alert.component.html +8 -12
- package/lib/field/cancel-alert/cancel-alert.component.scss +2 -3
- package/lib/field/cancel-alert/cancel-alert.component.ts +24 -37
- package/lib/field/check-box/check-box.component.html +17 -6
- package/lib/field/check-box/check-box.component.scss +0 -1
- package/lib/field/check-box/check-box.component.ts +25 -151
- package/lib/field/currency/currency.component.ts +54 -181
- package/lib/field/date/date.component.html +4 -3
- package/lib/field/date/date.component.ts +30 -151
- package/lib/field/date-time/date-time.component.html +2 -2
- package/lib/field/date-time/date-time.component.ts +47 -148
- package/lib/field/decimal/decimal.component.html +1 -0
- package/lib/field/decimal/decimal.component.ts +61 -164
- package/lib/field/dropdown/dropdown.component.html +1 -0
- package/lib/field/dropdown/dropdown.component.ts +43 -152
- package/lib/field/email/email.component.ts +28 -158
- package/lib/field/field.base.ts +149 -0
- package/lib/field/group/group.component.ts +7 -5
- package/lib/field/integer/integer.component.html +1 -1
- package/lib/field/integer/integer.component.ts +30 -160
- package/lib/field/list-view-action-buttons/list-view-action-buttons.component.html +1 -1
- package/lib/field/list-view-action-buttons/list-view-action-buttons.component.ts +3 -3
- package/lib/field/location/config-ext.json +8 -0
- package/lib/field/location/location.component.html +45 -0
- package/lib/field/location/location.component.scss +18 -0
- package/lib/field/location/location.component.spec.ts +22 -0
- package/lib/field/location/location.component.ts +280 -0
- package/lib/field/multiselect/multiselect.component.ts +47 -152
- package/lib/field/multiselect/utils.ts +55 -47
- package/lib/field/object-reference/object-reference.component.html +17 -0
- package/lib/field/object-reference/object-reference.component.scss +0 -0
- package/lib/field/object-reference/object-reference.component.spec.ts +22 -0
- package/lib/field/object-reference/object-reference.component.ts +237 -0
- package/lib/field/percentage/percentage.component.html +1 -1
- package/lib/field/percentage/percentage.component.ts +62 -170
- package/lib/field/phone/config-ext.json +1 -1
- package/lib/field/phone/phone.component.html +18 -17
- package/lib/field/phone/phone.component.scss +4 -0
- package/lib/field/phone/phone.component.ts +47 -156
- package/lib/field/radio-buttons/radio-buttons.component.html +17 -12
- package/lib/field/radio-buttons/radio-buttons.component.scss +4 -2
- package/lib/field/radio-buttons/radio-buttons.component.ts +37 -160
- package/lib/field/rich-text/rich-text.component.html +2 -0
- package/lib/field/rich-text/rich-text.component.scss +172 -0
- package/lib/field/rich-text/rich-text.component.ts +32 -93
- package/lib/field/scalar-list/scalar-list.component.ts +17 -73
- package/lib/field/selectable-card/selectable-card.component.html +70 -0
- package/lib/field/selectable-card/selectable-card.component.scss +11 -0
- package/lib/field/selectable-card/selectable-card.component.spec.ts +22 -0
- package/lib/field/selectable-card/selectable-card.component.ts +219 -0
- package/lib/field/semantic-link/semantic-link.component.html +4 -8
- package/lib/field/semantic-link/semantic-link.component.scss +0 -13
- package/lib/field/semantic-link/semantic-link.component.ts +165 -6
- package/lib/field/text/text.component.scss +0 -1
- package/lib/field/text/text.component.ts +6 -5
- package/lib/field/text-area/text-area.component.html +4 -2
- package/lib/field/text-area/text-area.component.ts +30 -155
- package/lib/field/text-content/text-content.component.ts +0 -1
- package/lib/field/text-input/text-input.component.html +1 -1
- package/lib/field/text-input/text-input.component.ts +28 -158
- package/lib/field/time/time.component.html +2 -2
- package/lib/field/time/time.component.ts +34 -154
- package/lib/field/url/url.component.html +1 -1
- package/lib/field/url/url.component.ts +28 -157
- package/lib/field/user-reference/user-reference.component.html +40 -38
- package/lib/field/user-reference/user-reference.component.scss +0 -1
- package/lib/field/user-reference/user-reference.component.ts +70 -9
- package/lib/infra/Containers/flow-container/flow-container.component.html +2 -2
- package/lib/infra/Containers/flow-container/flow-container.component.ts +24 -51
- package/lib/infra/Containers/flow-container/helpers.ts +2 -2
- package/lib/infra/Containers/hybrid-view-container/hybrid-view-container.component.ts +0 -1
- package/lib/infra/Containers/modal-view-container/modal-view-container.component.html +1 -11
- package/lib/infra/Containers/modal-view-container/modal-view-container.component.ts +5 -18
- package/lib/infra/Containers/view-container/helper.ts +35 -2
- package/lib/infra/Containers/view-container/view-container.component.ts +1 -2
- package/lib/infra/action-buttons/action-buttons.component.html +13 -8
- package/lib/infra/action-buttons/action-buttons.component.scss +23 -0
- package/lib/infra/action-buttons/action-buttons.component.ts +1 -3
- package/lib/infra/assignment/assignment.component.html +1 -1
- package/lib/infra/assignment/assignment.component.ts +100 -46
- package/lib/infra/assignment-card/assignment-card.component.html +2 -2
- package/lib/infra/assignment-card/assignment-card.component.scss +0 -4
- package/lib/infra/assignment-card/assignment-card.component.ts +21 -5
- package/lib/infra/dashboard-filter/dashboard-filter.component.ts +0 -1
- package/lib/infra/defer-load/defer-load.component.html +6 -2
- package/lib/infra/defer-load/defer-load.component.ts +25 -12
- package/lib/infra/error-boundary/error-boundary.component.ts +0 -1
- package/lib/infra/multi-step/multi-step.component.html +22 -38
- package/lib/infra/multi-step/multi-step.component.scss +14 -27
- package/lib/infra/multi-step/multi-step.component.ts +0 -1
- package/lib/infra/navbar/navbar.component.html +36 -41
- package/lib/infra/navbar/navbar.component.scss +22 -4
- package/lib/infra/navbar/navbar.component.ts +8 -6
- package/lib/infra/reference/reference.component.ts +82 -90
- package/lib/infra/region/region.component.ts +0 -1
- package/lib/infra/root-container/root-container.component.html +2 -15
- package/lib/infra/root-container/root-container.component.scss +0 -1
- package/lib/infra/root-container/root-container.component.ts +25 -32
- package/lib/infra/stages/stages.component.html +4 -3
- package/lib/infra/stages/stages.component.scss +12 -36
- package/lib/infra/stages/stages.component.ts +4 -3
- package/lib/infra/view/view.component.html +1 -1
- package/lib/infra/view/view.component.ts +3 -7
- package/lib/template/advanced-search/advanced-search.component.html +12 -0
- package/lib/template/advanced-search/advanced-search.component.scss +0 -0
- package/lib/template/advanced-search/advanced-search.component.spec.ts +0 -0
- package/lib/template/advanced-search/advanced-search.component.ts +112 -0
- package/lib/template/advanced-search/advanced-search.service.ts +27 -0
- package/lib/template/advanced-search/search-group/persist-utils.ts +56 -0
- package/lib/template/advanced-search/search-groups/search-groups.component.html +32 -0
- package/lib/template/advanced-search/search-groups/search-groups.component.scss +0 -0
- package/lib/template/advanced-search/search-groups/search-groups.component.spec.ts +0 -0
- package/lib/template/advanced-search/search-groups/search-groups.component.ts +294 -0
- package/lib/template/advanced-search/search-groups/utils.ts +29 -0
- package/lib/template/app-shell/app-shell.component.html +4 -1
- package/lib/template/app-shell/app-shell.component.scss +0 -3
- package/lib/template/app-shell/app-shell.component.ts +46 -8
- package/lib/template/banner-page/banner-page.component.ts +0 -1
- package/lib/template/base/form-template-base.ts +6 -0
- package/lib/template/case-summary/case-summary.component.scss +0 -2
- package/lib/template/case-summary/case-summary.component.ts +6 -22
- package/lib/template/case-view/case-view.component.html +4 -4
- package/lib/template/case-view/case-view.component.scss +18 -10
- package/lib/template/case-view/case-view.component.ts +1 -11
- package/lib/template/confirmation/confirmation.component.html +2 -2
- package/lib/template/confirmation/confirmation.component.ts +0 -1
- package/lib/template/data-reference/data-reference.component.html +11 -8
- package/lib/template/data-reference/data-reference.component.ts +346 -113
- package/lib/template/data-reference/search-form/search-form.component.html +39 -0
- package/lib/template/data-reference/search-form/search-form.component.scss +11 -0
- package/lib/template/data-reference/search-form/search-form.component.spec.ts +0 -0
- package/lib/template/data-reference/search-form/search-form.component.ts +167 -0
- package/lib/template/data-reference/search-form/tabsData.ts +160 -0
- package/lib/template/data-reference/utils.ts +92 -0
- package/lib/template/default-form/default-form.component.ts +45 -5
- package/lib/template/default-page/default-page.component.html +34 -0
- package/lib/template/default-page/default-page.component.scss +31 -0
- package/lib/template/default-page/default-page.component.spec.ts +24 -0
- package/lib/template/default-page/default-page.component.ts +64 -0
- package/lib/template/details/details.component.ts +0 -1
- package/lib/template/details-narrow-wide/details-narrow-wide.component.ts +0 -1
- package/lib/template/details-one-column/details-one-column.component.ts +0 -1
- package/lib/template/details-sub-tabs/details-sub-tabs.component.ts +0 -1
- package/lib/template/details-three-column/details-three-column.component.ts +0 -1
- package/lib/template/details-two-column/details-two-column.component.ts +0 -1
- package/lib/template/details-wide-narrow/details-wide-narrow.component.ts +0 -1
- package/lib/template/dynamic-tabs/dynamic-tabs.component.ts +0 -1
- package/lib/template/field-group-list/field-group-list.component.scss +0 -1
- package/lib/template/field-group-list/field-group-list.component.ts +0 -1
- package/lib/template/field-group-template/field-group-template.component.html +7 -7
- package/lib/template/field-group-template/field-group-template.component.scss +8 -0
- package/lib/template/field-group-template/field-group-template.component.ts +64 -55
- package/lib/template/field-value-list/field-value-list.component.html +2 -2
- package/lib/template/field-value-list/field-value-list.component.scss +4 -0
- package/lib/template/field-value-list/field-value-list.component.ts +0 -1
- package/lib/template/inline-dashboard/inline-dashboard.component.ts +0 -1
- package/lib/template/inline-dashboard-page/inline-dashboard-page.component.ts +1 -2
- package/lib/template/list-page/list-page.component.ts +0 -1
- package/lib/template/list-view/list-view.component.html +170 -160
- package/lib/template/list-view/list-view.component.scss +25 -21
- package/lib/template/list-view/list-view.component.ts +208 -122
- package/lib/template/list-view/listViewHelpers.ts +3 -9
- package/lib/template/list-view/utils.ts +27 -7
- package/lib/template/multi-reference-readonly/multi-reference-readonly.component.ts +0 -1
- package/lib/template/narrow-wide-form/narrow-wide-form.component.ts +0 -1
- package/lib/template/object-page/object-page.component.html +1 -0
- package/lib/template/object-page/object-page.component.scss +0 -0
- package/lib/template/object-page/object-page.component.spec.ts +22 -0
- package/lib/template/object-page/object-page.component.ts +14 -0
- package/lib/template/one-column/one-column.component.ts +0 -1
- package/lib/template/one-column-page/one-column-page.component.ts +0 -1
- package/lib/template/one-column-tab/one-column-tab.component.scss +1 -1
- package/lib/template/one-column-tab/one-column-tab.component.ts +0 -1
- package/lib/template/page/page.component.ts +0 -1
- package/lib/template/promoted-filters/promoted-filters.component.ts +0 -1
- package/lib/template/repeating-structures/repeating-structures.component.ts +0 -2
- package/lib/template/self-service-case-view/self-service-case-view.component.html +78 -0
- package/lib/template/self-service-case-view/self-service-case-view.component.scss +132 -0
- package/lib/template/self-service-case-view/self-service-case-view.component.spec.ts +24 -0
- package/lib/template/self-service-case-view/self-service-case-view.component.ts +207 -0
- package/lib/template/simple-table/simple-table.component.ts +0 -2
- package/lib/template/simple-table-manual/helpers.ts +126 -10
- package/lib/template/simple-table-manual/simple-table-manual.component.html +27 -8
- package/lib/template/simple-table-manual/simple-table-manual.component.scss +15 -17
- package/lib/template/simple-table-manual/simple-table-manual.component.ts +103 -45
- package/lib/template/simple-table-select/simple-table-select.component.ts +0 -1
- package/lib/template/single-reference-readonly/single-reference-readonly.component.html +4 -1
- package/lib/template/single-reference-readonly/single-reference-readonly.component.scss +21 -0
- package/lib/template/single-reference-readonly/single-reference-readonly.component.ts +104 -4
- package/lib/template/sub-tabs/sub-tabs.component.ts +0 -1
- package/lib/template/three-column/three-column.component.ts +0 -1
- package/lib/template/three-column-page/three-column-page.component.ts +0 -1
- package/lib/template/two-column/two-column.component.ts +0 -1
- package/lib/template/two-column-page/two-column-page.component.ts +0 -1
- package/lib/template/two-column-tab/two-column-tab.component.ts +0 -1
- package/lib/template/utils.ts +58 -0
- package/lib/template/wide-narrow-form/wide-narrow-form.component.ts +0 -1
- package/lib/template/wide-narrow-page/wide-narrow-page.component.ts +0 -1
- package/lib/template/wss-nav-bar/wss-nav-bar.component.html +6 -5
- package/lib/template/wss-nav-bar/wss-nav-bar.component.scss +8 -17
- package/lib/template/wss-nav-bar/wss-nav-bar.component.ts +1 -9
- package/lib/widget/app-announcement/app-announcement.component.html +1 -2
- package/lib/widget/app-announcement/app-announcement.component.scss +2 -2
- package/lib/widget/app-announcement/app-announcement.component.ts +0 -1
- package/lib/widget/attachment/Attachment.types.ts +92 -0
- package/lib/widget/attachment/AttachmentUtils.ts +287 -0
- package/lib/widget/attachment/attachment.component.html +3 -3
- package/lib/widget/attachment/attachment.component.scss +9 -12
- package/lib/widget/attachment/attachment.component.ts +267 -254
- package/lib/widget/case-history/case-history.component.ts +0 -1
- package/lib/widget/feed-container/feed-container.component.scss +3 -9
- package/lib/widget/feed-container/feed-container.component.ts +2 -5
- package/lib/widget/file-utility/file-utility.component.html +3 -3
- package/lib/widget/file-utility/file-utility.component.scss +6 -17
- package/lib/widget/file-utility/file-utility.component.ts +24 -9
- package/lib/widget/list-utility/list-utility.component.scss +4 -5
- package/lib/widget/list-utility/list-utility.component.ts +0 -1
- package/lib/widget/quick-create/quick-create.component.ts +41 -23
- package/lib/widget/todo/todo.component.html +12 -10
- package/lib/widget/todo/todo.component.scss +20 -10
- package/lib/widget/todo/todo.component.ts +11 -7
- package/lib/widget/utility/utility.component.ts +0 -1
- package/package.json +1 -1
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { Component,
|
|
1
|
+
import { Component, forwardRef } from '@angular/core';
|
|
2
2
|
import { CommonModule } from '@angular/common';
|
|
3
|
-
import {
|
|
3
|
+
import { ReactiveFormsModule } from '@angular/forms';
|
|
4
4
|
import { MatRadioModule } from '@angular/material/radio';
|
|
5
5
|
import { MatInputModule } from '@angular/material/input';
|
|
6
6
|
import { MatFormFieldModule } from '@angular/material/form-field';
|
|
7
|
-
|
|
8
|
-
import {
|
|
9
|
-
import { Utils } from '@pega/angular-sdk-components';
|
|
7
|
+
|
|
8
|
+
import { FieldBase } from '@pega/angular-sdk-components';
|
|
10
9
|
import { ComponentMapperComponent } from '@pega/angular-sdk-components';
|
|
11
|
-
import {
|
|
10
|
+
import { Utils } from '@pega/angular-sdk-components';
|
|
12
11
|
import { handleEvent } from '@pega/angular-sdk-components';
|
|
12
|
+
import { PConnFieldProps } from '@pega/angular-sdk-components';
|
|
13
13
|
|
|
14
14
|
interface IOption {
|
|
15
15
|
key: string;
|
|
@@ -20,6 +20,7 @@ interface RadioButtonsProps extends PConnFieldProps {
|
|
|
20
20
|
// If any, enter additional props that only exist on RadioButtons here
|
|
21
21
|
inline: boolean;
|
|
22
22
|
fieldMetadata?: any;
|
|
23
|
+
variant?: string;
|
|
23
24
|
}
|
|
24
25
|
|
|
25
26
|
@Component({
|
|
@@ -27,159 +28,60 @@ interface RadioButtonsProps extends PConnFieldProps {
|
|
|
27
28
|
templateUrl: './radio-buttons.component.html',
|
|
28
29
|
styleUrls: ['./radio-buttons.component.scss'],
|
|
29
30
|
providers: [Utils],
|
|
30
|
-
standalone: true,
|
|
31
31
|
imports: [CommonModule, ReactiveFormsModule, MatFormFieldModule, MatInputModule, MatRadioModule, forwardRef(() => ComponentMapperComponent)]
|
|
32
32
|
})
|
|
33
|
-
export class RadioButtonsComponent
|
|
34
|
-
@Input() pConn$: typeof PConnect;
|
|
35
|
-
@Input() formGroup$: FormGroup;
|
|
36
|
-
|
|
37
|
-
// Used with AngularPConnect
|
|
38
|
-
angularPConnectData: AngularPConnectData = {};
|
|
33
|
+
export class RadioButtonsComponent extends FieldBase {
|
|
39
34
|
configProps$: RadioButtonsProps;
|
|
40
35
|
|
|
41
|
-
label$ = '';
|
|
42
|
-
value$ = '';
|
|
43
|
-
bRequired$ = false;
|
|
44
|
-
bReadonly$ = false;
|
|
45
|
-
bDisabled$ = false;
|
|
46
|
-
bVisible$ = true;
|
|
47
36
|
bInline$ = false;
|
|
48
|
-
|
|
49
|
-
controlName$: string;
|
|
50
|
-
bHasForm$ = true;
|
|
37
|
+
|
|
51
38
|
options$: IOption[];
|
|
52
39
|
componentReference = '';
|
|
53
|
-
testId: string;
|
|
54
|
-
helperText: string;
|
|
55
|
-
placeholder: string;
|
|
56
|
-
|
|
57
|
-
fieldControl = new FormControl('', null);
|
|
58
40
|
fieldMetadata: any[];
|
|
59
41
|
localeContext = '';
|
|
60
42
|
localeClass = '';
|
|
61
43
|
localeName = '';
|
|
62
44
|
localePath = '';
|
|
63
45
|
localizedValue = '';
|
|
64
|
-
|
|
65
|
-
propName: string;
|
|
66
|
-
|
|
67
|
-
constructor(
|
|
68
|
-
private angularPConnect: AngularPConnectService,
|
|
69
|
-
private cdRef: ChangeDetectorRef,
|
|
70
|
-
private utils: Utils
|
|
71
|
-
) {}
|
|
72
|
-
|
|
73
|
-
ngOnInit(): void {
|
|
74
|
-
// First thing in initialization is registering and subscribing to the AngularPConnect service
|
|
75
|
-
this.angularPConnectData = this.angularPConnect.registerAndSubscribeComponent(this, this.onStateChange);
|
|
76
|
-
this.controlName$ = this.angularPConnect.getComponentID(this);
|
|
77
|
-
|
|
78
|
-
// Then, continue on with other initialization
|
|
79
|
-
|
|
80
|
-
// call updateSelf when initializing
|
|
81
|
-
// this.updateSelf();
|
|
82
|
-
this.checkAndUpdate();
|
|
83
|
-
|
|
84
|
-
if (this.formGroup$) {
|
|
85
|
-
// add control to formGroup
|
|
86
|
-
this.formGroup$.addControl(this.controlName$, this.fieldControl);
|
|
87
|
-
this.fieldControl.setValue(this.value$);
|
|
88
|
-
this.bHasForm$ = true;
|
|
89
|
-
} else {
|
|
90
|
-
this.bReadonly$ = true;
|
|
91
|
-
this.bHasForm$ = false;
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
ngOnDestroy(): void {
|
|
96
|
-
if (this.formGroup$) {
|
|
97
|
-
this.formGroup$.removeControl(this.controlName$);
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
if (this.angularPConnectData.unsubscribeFn) {
|
|
101
|
-
this.angularPConnectData.unsubscribeFn();
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
// Callback passed when subscribing to store change
|
|
106
|
-
onStateChange() {
|
|
107
|
-
this.checkAndUpdate();
|
|
108
|
-
}
|
|
46
|
+
variant?: string;
|
|
109
47
|
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
// ONLY call updateSelf when the component should update
|
|
116
|
-
if (bUpdateSelf) {
|
|
117
|
-
this.updateSelf();
|
|
118
|
-
}
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
// updateSelf
|
|
122
|
-
updateSelf(): void {
|
|
123
|
-
// moved this from ngOnInit() and call this from there instead...
|
|
48
|
+
/**
|
|
49
|
+
* Updates the component when there are changes in the state.
|
|
50
|
+
*/
|
|
51
|
+
override updateSelf(): void {
|
|
52
|
+
// Resolve config properties
|
|
124
53
|
this.configProps$ = this.pConn$.resolveConfigProps(this.pConn$.getConfigProps()) as RadioButtonsProps;
|
|
125
54
|
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
this.testId = this.configProps$.testId;
|
|
131
|
-
this.label$ = this.configProps$.label;
|
|
132
|
-
this.displayMode$ = this.configProps$.displayMode;
|
|
133
|
-
this.helperText = this.configProps$.helperText;
|
|
134
|
-
this.placeholder = this.configProps$.placeholder || '';
|
|
135
|
-
|
|
136
|
-
// timeout and detectChanges to avoid ExpressionChangedAfterItHasBeenCheckedError
|
|
137
|
-
setTimeout(() => {
|
|
138
|
-
if (this.configProps$.required != null) {
|
|
139
|
-
this.bRequired$ = this.utils.getBooleanValue(this.configProps$.required);
|
|
140
|
-
}
|
|
141
|
-
this.cdRef.detectChanges();
|
|
142
|
-
});
|
|
143
|
-
|
|
144
|
-
if (this.configProps$.visibility != null) {
|
|
145
|
-
this.bVisible$ = this.utils.getBooleanValue(this.configProps$.visibility);
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
if (this.configProps$.inline != null) {
|
|
149
|
-
this.bInline$ = this.utils.getBooleanValue(this.configProps$.inline);
|
|
150
|
-
}
|
|
55
|
+
// Update component common properties
|
|
56
|
+
this.updateComponentCommonProperties(this.configProps$);
|
|
151
57
|
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
58
|
+
// Extract and normalize the value property
|
|
59
|
+
const { value } = this.configProps$;
|
|
60
|
+
this.value$ = value;
|
|
155
61
|
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
if (this.bDisabled$) {
|
|
161
|
-
this.fieldControl.disable();
|
|
162
|
-
} else {
|
|
163
|
-
this.fieldControl.enable();
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
if (this.configProps$.readOnly != null) {
|
|
167
|
-
this.bReadonly$ = this.utils.getBooleanValue(this.configProps$.readOnly);
|
|
168
|
-
}
|
|
62
|
+
// Set component specific properties
|
|
63
|
+
this.updateRadioButtonsProperties(this.configProps$);
|
|
64
|
+
}
|
|
169
65
|
|
|
170
|
-
|
|
66
|
+
/**
|
|
67
|
+
* Updates radio buttons properties based on the provided config props.
|
|
68
|
+
* @param configProps Configuration properties.
|
|
69
|
+
*/
|
|
70
|
+
protected updateRadioButtonsProperties(configProps) {
|
|
71
|
+
const { inline, fieldMetadata, variant } = configProps;
|
|
171
72
|
|
|
172
|
-
this.
|
|
73
|
+
this.variant = variant;
|
|
74
|
+
this.bInline$ = this.utils.getBooleanValue(inline);
|
|
173
75
|
|
|
174
|
-
|
|
175
|
-
this.
|
|
76
|
+
// Get options from config props and data object
|
|
77
|
+
this.options$ = this.utils.getOptionList(configProps, this.pConn$.getDataObject());
|
|
176
78
|
|
|
79
|
+
// Extract metadata and locale information
|
|
177
80
|
const className = this.pConn$.getCaseInfo().getClassName();
|
|
178
81
|
const refName = this.propName?.slice(this.propName.lastIndexOf('.') + 1);
|
|
82
|
+
const metaData = Array.isArray(fieldMetadata) ? fieldMetadata.filter(field => field?.classID === className)[0] : fieldMetadata;
|
|
179
83
|
|
|
180
|
-
|
|
181
|
-
const metaData = Array.isArray(this.fieldMetadata) ? this.fieldMetadata.filter(field => field?.classID === className)[0] : this.fieldMetadata;
|
|
182
|
-
|
|
84
|
+
// Determine display name and locale context
|
|
183
85
|
let displayName = metaData?.datasource?.propertyForDisplayText;
|
|
184
86
|
displayName = displayName?.slice(displayName.lastIndexOf('.') + 1);
|
|
185
87
|
this.localeContext = metaData?.datasource?.tableType === 'DataPage' ? 'datapage' : 'associated';
|
|
@@ -187,20 +89,12 @@ export class RadioButtonsComponent implements OnInit, OnDestroy {
|
|
|
187
89
|
this.localeName = this.localeContext === 'datapage' ? metaData?.datasource?.name : refName;
|
|
188
90
|
this.localePath = this.localeContext === 'datapage' ? displayName : this.localeName;
|
|
189
91
|
|
|
92
|
+
// Get localized value
|
|
190
93
|
this.localizedValue = this.pConn$.getLocalizedValue(
|
|
191
94
|
this.value$,
|
|
192
95
|
this.localePath,
|
|
193
96
|
this.pConn$.getLocaleRuleNameFromKeys(this.localeClass, this.localeContext, this.localeName)
|
|
194
97
|
);
|
|
195
|
-
// trigger display of error message with field control
|
|
196
|
-
if (this.angularPConnectData.validateMessage != null && this.angularPConnectData.validateMessage != '') {
|
|
197
|
-
const timer = interval(100).subscribe(() => {
|
|
198
|
-
this.fieldControl.setErrors({ message: true });
|
|
199
|
-
this.fieldControl.markAsTouched();
|
|
200
|
-
|
|
201
|
-
timer.unsubscribe();
|
|
202
|
-
});
|
|
203
|
-
}
|
|
204
98
|
}
|
|
205
99
|
|
|
206
100
|
isSelected(buttonValue: string): boolean {
|
|
@@ -218,21 +112,4 @@ export class RadioButtonsComponent implements OnInit, OnDestroy {
|
|
|
218
112
|
this.pConn$.getLocaleRuleNameFromKeys(this.localeClass, this.localeContext, this.localeName)
|
|
219
113
|
);
|
|
220
114
|
}
|
|
221
|
-
|
|
222
|
-
getErrorMessage() {
|
|
223
|
-
let errMessage = '';
|
|
224
|
-
|
|
225
|
-
// look for validation messages for json, pre-defined or just an error pushed from workitem (400)
|
|
226
|
-
if (this.fieldControl.hasError('message')) {
|
|
227
|
-
errMessage = this.angularPConnectData.validateMessage ?? '';
|
|
228
|
-
return errMessage;
|
|
229
|
-
}
|
|
230
|
-
if (this.fieldControl.hasError('required')) {
|
|
231
|
-
errMessage = 'You must enter a value';
|
|
232
|
-
} else if (this.fieldControl.errors) {
|
|
233
|
-
errMessage = this.fieldControl.errors.toString();
|
|
234
|
-
}
|
|
235
|
-
|
|
236
|
-
return errMessage;
|
|
237
|
-
}
|
|
238
115
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
<div *ngIf="displayMode$; else noDisplayMode">
|
|
2
2
|
<component-mapper *ngIf="bVisible$ !== false" name="FieldValueList" [props]="{ label$, value$, displayMode$, isHtml$: true }"></component-mapper>
|
|
3
3
|
</div>
|
|
4
|
+
|
|
4
5
|
<ng-template #noDisplayMode>
|
|
5
6
|
<div *ngIf="!bReadonly$; else noEdit">
|
|
6
7
|
<div *ngIf="bVisible$">
|
|
@@ -13,6 +14,7 @@
|
|
|
13
14
|
</div>
|
|
14
15
|
</div>
|
|
15
16
|
</ng-template>
|
|
17
|
+
|
|
16
18
|
<ng-template #noEdit>
|
|
17
19
|
<div *ngIf="bVisible$ !== false">
|
|
18
20
|
<component-mapper name="RichTextEditor" [props]="{ label: label$, value: value$, readonly: true, testId }" [parent]="this"></component-mapper>
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
@use '@angular/material' as mat;
|
|
2
|
+
|
|
3
|
+
:host {
|
|
4
|
+
display: block;
|
|
5
|
+
background-color: var(--mat-sys-surface, #fff);
|
|
6
|
+
color: var(--mat-sys-on-surface, #000);
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
::ng-deep {
|
|
10
|
+
.tox-tinymce {
|
|
11
|
+
border: 1px solid var(--mat-sys-outline, #ccc) !important;
|
|
12
|
+
border-radius: 4px !important;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.tox-edit-area__iframe {
|
|
16
|
+
background-color: transparent !important;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.tox .tox-toolbar,
|
|
20
|
+
.tox .tox-toolbar__primary,
|
|
21
|
+
.tox .tox-editor-header {
|
|
22
|
+
background-color: var(--mat-sys-surface-container-high, #f0f0f0) !important;
|
|
23
|
+
border-bottom: 1px solid var(--mat-sys-outline-variant, #ccc) !important;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.tox .tox-tbtn {
|
|
27
|
+
color: var(--mat-sys-on-surface-variant, #555) !important;
|
|
28
|
+
background: transparent !important;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.tox .tox-tbtn svg {
|
|
32
|
+
fill: var(--mat-sys-on-surface-variant, #555) !important;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.tox .tox-tbtn:hover {
|
|
36
|
+
background: var(--mat-sys-hover-state-layer-opacity, rgba(0, 0, 0, 0.05)) !important;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.tox .tox-tbtn--enabled,
|
|
40
|
+
.tox .tox-tbtn--enabled:hover {
|
|
41
|
+
background: var(--mat-sys-secondary-container, #e8def8) !important;
|
|
42
|
+
color: var(--mat-sys-on-secondary-container, #1d192b) !important;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.tox .tox-tbtn--enabled svg {
|
|
46
|
+
fill: var(--mat-sys-on-secondary-container, #1d192b) !important;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.tox .tox-tbtn--select {
|
|
50
|
+
background-color: transparent !important;
|
|
51
|
+
margin: 2px 0;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.tox .tox-tbtn__select-label {
|
|
55
|
+
color: var(--mat-sys-on-surface, #000) !important;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.tox .tox-tbtn__select-chevron svg {
|
|
59
|
+
fill: var(--mat-sys-on-surface-variant, #555) !important;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.tox .tox-tbtn--select:hover {
|
|
63
|
+
background-color: var(--mat-sys-hover-state-layer-opacity, rgba(0, 0, 0, 0.05)) !important;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.tox .tox-statusbar {
|
|
67
|
+
background-color: var(--mat-sys-surface-container-high, #f0f0f0) !important;
|
|
68
|
+
border-top: 1px solid var(--mat-sys-outline-variant, #ccc) !important;
|
|
69
|
+
color: var(--mat-sys-on-surface-variant, #555) !important;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.tox .tox-dialog {
|
|
73
|
+
background-color: var(--mat-sys-surface-container, #fff) !important;
|
|
74
|
+
color: var(--mat-sys-on-surface, #000) !important;
|
|
75
|
+
border: 1px solid var(--mat-sys-outline-variant, #ccc) !important;
|
|
76
|
+
box-shadow: 0 4px 12px var(--mat-sys-shadow, rgba(0, 0, 0, 0.2)) !important;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.tox .tox-dialog__header {
|
|
80
|
+
background-color: var(--mat-sys-surface-container, #fff) !important;
|
|
81
|
+
color: var(--mat-sys-on-surface, #000) !important;
|
|
82
|
+
border-bottom: 1px solid var(--mat-sys-outline-variant, #ccc) !important;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.tox .tox-dialog__footer {
|
|
86
|
+
background-color: var(--mat-sys-surface-container, #fff) !important;
|
|
87
|
+
border-top: 1px solid var(--mat-sys-outline-variant, #ccc) !important;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.tox .tox-dialog-wrap__backdrop {
|
|
91
|
+
background-color: var(--mat-sys-scrim, rgba(0, 0, 0, 0.5)) !important;
|
|
92
|
+
opacity: 0.6;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.tox .tox-dialog__body input,
|
|
96
|
+
.tox .tox-dialog__body textarea,
|
|
97
|
+
.tox .tox-dialog__body select {
|
|
98
|
+
background-color: transparent !important;
|
|
99
|
+
color: var(--mat-sys-on-surface, #000) !important;
|
|
100
|
+
border: 1px solid var(--mat-sys-outline, #ccc) !important;
|
|
101
|
+
border-radius: 4px !important;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.tox .tox-label {
|
|
105
|
+
color: var(--mat-sys-on-surface-variant, #555) !important;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.tox .tox-button--icon--hover:hover {
|
|
109
|
+
background-color: var(--mat-sys-hover-state-layer-opacity) !important;
|
|
110
|
+
color: var(--mat-sys-on-surface) !important;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
.tox .tox-dialog__footer .tox-button {
|
|
114
|
+
background-color: var(--mat-sys-primary, #6200ee) !important;
|
|
115
|
+
color: var(--mat-sys-on-primary, #fff) !important;
|
|
116
|
+
border: none !important;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.tox .tox-dialog__footer .tox-button--secondary {
|
|
120
|
+
background-color: transparent !important;
|
|
121
|
+
color: var(--mat-sys-primary, #6200ee) !important;
|
|
122
|
+
border: 1px solid var(--mat-sys-outline, #ccc) !important;
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
::ng-deep {
|
|
127
|
+
.tox .tox-menu {
|
|
128
|
+
background-color: var(--mat-sys-surface-container, #2e334f) !important;
|
|
129
|
+
border: 1px solid var(--mat-sys-outline-variant, #404562) !important;
|
|
130
|
+
box-shadow: 0 4px 10px var(--mat-sys-shadow, rgba(0, 0, 0, 0.3)) !important;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.tox .tox-collection__item {
|
|
134
|
+
color: var(--mat-sys-on-surface, #dde1ff) !important;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.tox .tox-collection__item--active {
|
|
138
|
+
background-color: var(--mat-sys-secondary-container, #810081) !important;
|
|
139
|
+
color: var(--mat-sys-on-secondary-container, #ffd7f5) !important;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
.tox .tox-collection__item-icon svg {
|
|
143
|
+
fill: var(--mat-sys-on-surface, #dde1ff) !important;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
.tox .tox-collection__item-accessory {
|
|
147
|
+
color: var(--mat-sys-on-surface-variant, #c0c5e7) !important;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.tox .tox-swatches__picker-btn {
|
|
151
|
+
border-color: var(--mat-sys-outline-variant) !important;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
.tox .tox-listbox {
|
|
155
|
+
background-color: transparent !important;
|
|
156
|
+
border: 1px solid var(--mat-sys-outline, #8a8faf) !important;
|
|
157
|
+
color: var(--mat-sys-on-surface, #dde1ff) !important;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.tox .tox-listbox__select-chevron svg {
|
|
161
|
+
fill: var(--mat-sys-on-surface-variant, #c0c5e7) !important;
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
.tox .tox-listbox__select-label {
|
|
165
|
+
color: var(--mat-sys-on-surface, #dde1ff) !important;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
.tox .tox-listboxfield .tox-listbox--select {
|
|
169
|
+
background-color: transparent !important;
|
|
170
|
+
color: var(--mat-sys-on-surface, #dde1ff) !important;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { Component,
|
|
1
|
+
import { Component, forwardRef } from '@angular/core';
|
|
2
2
|
import { CommonModule } from '@angular/common';
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
import {
|
|
3
|
+
import { ReactiveFormsModule } from '@angular/forms';
|
|
4
|
+
|
|
5
|
+
import { FieldBase } from '@pega/angular-sdk-components';
|
|
6
6
|
import { ComponentMapperComponent } from '@pega/angular-sdk-components';
|
|
7
7
|
import { handleEvent } from '@pega/angular-sdk-components';
|
|
8
8
|
import { PConnFieldProps } from '@pega/angular-sdk-components';
|
|
@@ -15,109 +15,42 @@ interface RichTextProps extends PConnFieldProps {
|
|
|
15
15
|
selector: 'app-rich-text',
|
|
16
16
|
templateUrl: './rich-text.component.html',
|
|
17
17
|
styleUrls: ['./rich-text.component.scss'],
|
|
18
|
-
standalone: true,
|
|
19
18
|
imports: [CommonModule, ReactiveFormsModule, forwardRef(() => ComponentMapperComponent)]
|
|
20
19
|
})
|
|
21
|
-
export class RichTextComponent
|
|
22
|
-
@Input() pConn$: typeof PConnect;
|
|
23
|
-
@Input() formGroup$: FormGroup;
|
|
24
|
-
|
|
25
|
-
// Used with AngularPConnect
|
|
26
|
-
angularPConnectData: AngularPConnectData = {};
|
|
20
|
+
export class RichTextComponent extends FieldBase {
|
|
27
21
|
configProps$: RichTextProps;
|
|
28
22
|
|
|
29
|
-
label$ = '';
|
|
30
|
-
value$ = '';
|
|
31
|
-
bRequired$ = false;
|
|
32
|
-
bReadonly$ = false;
|
|
33
|
-
bDisabled$ = false;
|
|
34
|
-
bVisible$ = true;
|
|
35
|
-
displayMode$?: string = '';
|
|
36
|
-
controlName$: string;
|
|
37
|
-
testId: string;
|
|
38
|
-
helperText: string;
|
|
39
|
-
placeholder: any;
|
|
40
23
|
info: any;
|
|
41
24
|
error: boolean;
|
|
42
25
|
status: any;
|
|
43
|
-
actionsApi: Object;
|
|
44
|
-
propName: string;
|
|
45
|
-
|
|
46
|
-
constructor(
|
|
47
|
-
private angularPConnect: AngularPConnectService,
|
|
48
|
-
private utils: Utils
|
|
49
|
-
) {}
|
|
50
|
-
|
|
51
|
-
ngOnInit(): void {
|
|
52
|
-
// First thing in initialization is registering and subscribing to the AngularPConnect service
|
|
53
|
-
this.angularPConnectData = this.angularPConnect.registerAndSubscribeComponent(this, this.onStateChange);
|
|
54
|
-
|
|
55
|
-
// call updateSelf when initializing
|
|
56
|
-
this.checkAndUpdate();
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
ngOnDestroy(): void {
|
|
60
|
-
if (this.angularPConnectData.unsubscribeFn) {
|
|
61
|
-
this.angularPConnectData.unsubscribeFn();
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
// Callback passed when subscribing to store change
|
|
66
|
-
onStateChange() {
|
|
67
|
-
this.checkAndUpdate();
|
|
68
|
-
}
|
|
69
26
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
// ONLY call updateSelf when the component should update
|
|
76
|
-
if (bUpdateSelf) {
|
|
77
|
-
this.updateSelf();
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
// updateSelf
|
|
82
|
-
updateSelf(): void {
|
|
83
|
-
// moved this from ngOnInit() and call this from there instead...
|
|
27
|
+
/**
|
|
28
|
+
* Updates the component when there are changes in the state.
|
|
29
|
+
*/
|
|
30
|
+
override updateSelf(): void {
|
|
31
|
+
// Resolve config properties
|
|
84
32
|
this.configProps$ = this.pConn$.resolveConfigProps(this.pConn$.getConfigProps()) as RichTextProps;
|
|
85
|
-
const stateProps = this.pConn$.getStateProps();
|
|
86
|
-
this.status = stateProps?.status;
|
|
87
|
-
|
|
88
|
-
if (this.configProps$.value != undefined) {
|
|
89
|
-
this.value$ = this.configProps$.value;
|
|
90
|
-
}
|
|
91
33
|
|
|
92
|
-
|
|
93
|
-
this.
|
|
94
|
-
this.label$ = this.configProps$.label;
|
|
95
|
-
this.placeholder = this.configProps$.placeholder;
|
|
96
|
-
this.info = stateProps?.validatemessage || this.configProps$.helperText;
|
|
97
|
-
this.error = stateProps?.status === 'error';
|
|
34
|
+
// Update component common properties
|
|
35
|
+
this.updateComponentCommonProperties(this.configProps$);
|
|
98
36
|
|
|
99
|
-
|
|
100
|
-
|
|
37
|
+
// Extract and normalize the value property
|
|
38
|
+
const { value, helperText } = this.configProps$;
|
|
39
|
+
this.value$ = value;
|
|
101
40
|
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
41
|
+
const { status, validatemessage } = this.pConn$.getStateProps();
|
|
42
|
+
this.status = status;
|
|
43
|
+
this.info = validatemessage || helperText;
|
|
44
|
+
this.error = status === 'error';
|
|
45
|
+
}
|
|
105
46
|
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
47
|
+
fieldOnChange(editorValue: any) {
|
|
48
|
+
const oldVal = this.value$ ?? '';
|
|
49
|
+
const newVal = editorValue?.editor?.getBody()?.innerHTML ?? '';
|
|
109
50
|
|
|
110
|
-
|
|
111
|
-
this.bDisabled$ = this.utils.getBooleanValue(this.configProps$.disabled);
|
|
112
|
-
}
|
|
51
|
+
const isValueChanged = newVal.toString() !== oldVal.toString();
|
|
113
52
|
|
|
114
|
-
if (this.
|
|
115
|
-
this.bReadonly$ = this.utils.getBooleanValue(this.configProps$.readOnly);
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
fieldOnChange() {
|
|
120
|
-
if (this.status === 'error') {
|
|
53
|
+
if (isValueChanged || this.status === 'error') {
|
|
121
54
|
const property = this.propName;
|
|
122
55
|
this.pConn$.clearErrorMessages({
|
|
123
56
|
property,
|
|
@@ -128,6 +61,12 @@ export class RichTextComponent implements OnInit, OnDestroy {
|
|
|
128
61
|
}
|
|
129
62
|
|
|
130
63
|
fieldOnBlur(editorValue: any) {
|
|
131
|
-
|
|
64
|
+
const oldVal = this.value$ ?? '';
|
|
65
|
+
|
|
66
|
+
const isValueChanged = editorValue.toString() !== oldVal.toString();
|
|
67
|
+
|
|
68
|
+
if (isValueChanged) {
|
|
69
|
+
handleEvent(this.actionsApi, 'changeNblur', this.propName, editorValue);
|
|
70
|
+
}
|
|
132
71
|
}
|
|
133
72
|
}
|