@pega/angular-sdk-overrides 0.25.1 → 0.25.3

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 (160) hide show
  1. package/lib/designSystemExtension/alert/alert.component.scss +3 -3
  2. package/lib/designSystemExtension/banner/banner.component.scss +12 -2
  3. package/lib/designSystemExtension/material-case-summary/material-case-summary.component.html +6 -3
  4. package/lib/designSystemExtension/material-case-summary/material-case-summary.component.scss +5 -34
  5. package/lib/designSystemExtension/material-details/material-details.component.scss +0 -5
  6. package/lib/designSystemExtension/material-details-fields/material-details-fields.component.html +2 -2
  7. package/lib/designSystemExtension/material-details-fields/material-details-fields.component.scss +4 -3
  8. package/lib/designSystemExtension/material-summary-item/material-summary-item.component.scss +2 -17
  9. package/lib/designSystemExtension/material-utility/material-utility.component.scss +1 -2
  10. package/lib/designSystemExtension/material-vertical-tabs/material-vertical-tabs.component.scss +1 -1
  11. package/lib/designSystemExtension/operator/operator.component.html +1 -1
  12. package/lib/designSystemExtension/operator/operator.component.scss +3 -10
  13. package/lib/designSystemExtension/operator/operator.component.ts +0 -1
  14. package/lib/designSystemExtension/pulse/pulse.component.scss +2 -2
  15. package/lib/designSystemExtension/rich-text-editor/rich-text-editor.component.scss +0 -1
  16. package/lib/designSystemExtension/wss-quick-create/wss-quick-create.component.scss +16 -8
  17. package/lib/field/auto-complete/auto-complete.component.html +0 -1
  18. package/lib/field/auto-complete/auto-complete.component.ts +35 -172
  19. package/lib/field/cancel-alert/cancel-alert.component.html +8 -12
  20. package/lib/field/cancel-alert/cancel-alert.component.scss +2 -3
  21. package/lib/field/cancel-alert/cancel-alert.component.ts +24 -36
  22. package/lib/field/check-box/check-box.component.html +0 -1
  23. package/lib/field/check-box/check-box.component.scss +0 -1
  24. package/lib/field/check-box/check-box.component.ts +19 -149
  25. package/lib/field/currency/currency.component.ts +36 -168
  26. package/lib/field/date/date.component.html +1 -1
  27. package/lib/field/date/date.component.ts +30 -150
  28. package/lib/field/date-time/date-time.component.ts +31 -149
  29. package/lib/field/decimal/decimal.component.ts +38 -163
  30. package/lib/field/dropdown/dropdown.component.ts +29 -151
  31. package/lib/field/email/email.component.ts +16 -155
  32. package/lib/field/field.base.ts +149 -0
  33. package/lib/field/group/group.component.ts +7 -4
  34. package/lib/field/integer/integer.component.ts +18 -157
  35. package/lib/field/location/location.component.ts +1 -1
  36. package/lib/field/multiselect/multiselect.component.ts +46 -148
  37. package/lib/field/multiselect/utils.ts +55 -47
  38. package/lib/field/object-reference/object-reference.component.html +17 -0
  39. package/lib/field/object-reference/object-reference.component.scss +0 -0
  40. package/lib/field/object-reference/object-reference.component.spec.ts +22 -0
  41. package/lib/field/object-reference/object-reference.component.ts +237 -0
  42. package/lib/field/percentage/percentage.component.ts +37 -154
  43. package/lib/field/phone/phone.component.ts +28 -142
  44. package/lib/field/radio-buttons/radio-buttons.component.scss +4 -2
  45. package/lib/field/radio-buttons/radio-buttons.component.ts +35 -161
  46. package/lib/field/rich-text/rich-text.component.ts +19 -90
  47. package/lib/field/scalar-list/scalar-list.component.ts +17 -72
  48. package/lib/field/selectable-card/selectable-card.component.html +54 -24
  49. package/lib/field/selectable-card/selectable-card.component.scss +11 -0
  50. package/lib/field/selectable-card/selectable-card.component.ts +16 -52
  51. package/lib/field/semantic-link/semantic-link.component.html +4 -8
  52. package/lib/field/semantic-link/semantic-link.component.scss +0 -13
  53. package/lib/field/semantic-link/semantic-link.component.ts +165 -5
  54. package/lib/field/text/text.component.scss +0 -1
  55. package/lib/field/text-area/text-area.component.ts +18 -152
  56. package/lib/field/text-input/text-input.component.ts +16 -155
  57. package/lib/field/time/time.component.ts +17 -151
  58. package/lib/field/url/url.component.ts +16 -154
  59. package/lib/field/user-reference/user-reference.component.scss +0 -1
  60. package/lib/field/user-reference/user-reference.component.ts +2 -3
  61. package/lib/infra/Containers/flow-container/flow-container.component.ts +5 -7
  62. package/lib/infra/Containers/modal-view-container/modal-view-container.component.ts +5 -10
  63. package/lib/infra/Containers/view-container/helper.ts +35 -2
  64. package/lib/infra/Containers/view-container/view-container.component.ts +1 -1
  65. package/lib/infra/action-buttons/action-buttons.component.html +13 -8
  66. package/lib/infra/action-buttons/action-buttons.component.scss +23 -0
  67. package/lib/infra/action-buttons/action-buttons.component.ts +1 -2
  68. package/lib/infra/assignment/assignment.component.ts +8 -6
  69. package/lib/infra/assignment-card/assignment-card.component.html +1 -2
  70. package/lib/infra/assignment-card/assignment-card.component.scss +0 -4
  71. package/lib/infra/assignment-card/assignment-card.component.ts +21 -4
  72. package/lib/infra/defer-load/defer-load.component.html +6 -2
  73. package/lib/infra/defer-load/defer-load.component.ts +16 -10
  74. package/lib/infra/multi-step/multi-step.component.scss +1 -21
  75. package/lib/infra/navbar/navbar.component.html +25 -28
  76. package/lib/infra/navbar/navbar.component.scss +16 -4
  77. package/lib/infra/navbar/navbar.component.ts +8 -3
  78. package/lib/infra/root-container/root-container.component.scss +0 -1
  79. package/lib/infra/root-container/root-container.component.ts +1 -2
  80. package/lib/infra/stages/stages.component.html +2 -2
  81. package/lib/infra/stages/stages.component.scss +7 -35
  82. package/lib/infra/stages/stages.component.ts +4 -2
  83. package/lib/infra/view/view.component.html +1 -1
  84. package/lib/infra/view/view.component.ts +0 -2
  85. package/lib/template/advanced-search/advanced-search.component.html +12 -0
  86. package/lib/template/advanced-search/advanced-search.component.scss +0 -0
  87. package/lib/template/advanced-search/advanced-search.component.spec.ts +0 -0
  88. package/lib/template/advanced-search/advanced-search.component.ts +112 -0
  89. package/lib/template/advanced-search/advanced-search.service.ts +27 -0
  90. package/lib/template/advanced-search/search-group/persist-utils.ts +56 -0
  91. package/lib/template/advanced-search/search-groups/search-groups.component.html +32 -0
  92. package/lib/template/advanced-search/search-groups/search-groups.component.scss +0 -0
  93. package/lib/template/advanced-search/search-groups/search-groups.component.spec.ts +0 -0
  94. package/lib/template/advanced-search/search-groups/search-groups.component.ts +294 -0
  95. package/lib/template/advanced-search/search-groups/utils.ts +29 -0
  96. package/lib/template/app-shell/app-shell.component.html +4 -1
  97. package/lib/template/app-shell/app-shell.component.scss +0 -3
  98. package/lib/template/app-shell/app-shell.component.ts +46 -7
  99. package/lib/template/case-summary/case-summary.component.scss +0 -2
  100. package/lib/template/case-view/case-view.component.html +3 -3
  101. package/lib/template/case-view/case-view.component.scss +18 -10
  102. package/lib/template/case-view/case-view.component.ts +1 -1
  103. package/lib/template/data-reference/data-reference-advanced-search.service.ts +16 -0
  104. package/lib/template/data-reference/data-reference.component.html +11 -8
  105. package/lib/template/data-reference/data-reference.component.ts +346 -112
  106. package/lib/template/data-reference/search-form/search-form.component.html +39 -0
  107. package/lib/template/data-reference/search-form/search-form.component.scss +11 -0
  108. package/lib/template/data-reference/search-form/search-form.component.spec.ts +0 -0
  109. package/lib/template/data-reference/search-form/search-form.component.ts +167 -0
  110. package/lib/template/data-reference/search-form/tabsData.ts +160 -0
  111. package/lib/template/data-reference/utils.ts +92 -0
  112. package/lib/template/default-form/default-form.component.ts +10 -2
  113. package/lib/template/default-page/default-page.component.html +34 -0
  114. package/lib/template/default-page/default-page.component.scss +31 -0
  115. package/lib/template/default-page/default-page.component.spec.ts +24 -0
  116. package/lib/template/default-page/default-page.component.ts +64 -0
  117. package/lib/template/field-group-list/field-group-list.component.scss +0 -1
  118. package/lib/template/inline-dashboard-page/inline-dashboard-page.component.ts +1 -1
  119. package/lib/template/list-view/list-view.component.html +9 -4
  120. package/lib/template/list-view/list-view.component.scss +21 -21
  121. package/lib/template/list-view/list-view.component.ts +154 -84
  122. package/lib/template/list-view/utils.ts +25 -2
  123. package/lib/template/object-page/object-page.component.html +1 -0
  124. package/lib/template/object-page/object-page.component.scss +0 -0
  125. package/lib/template/object-page/object-page.component.spec.ts +22 -0
  126. package/lib/template/object-page/object-page.component.ts +14 -0
  127. package/lib/template/one-column-tab/one-column-tab.component.scss +1 -1
  128. package/lib/template/repeating-structures/repeating-structures.component.ts +0 -1
  129. package/lib/template/self-service-case-view/self-service-case-view.component.html +80 -0
  130. package/lib/template/self-service-case-view/self-service-case-view.component.scss +124 -0
  131. package/lib/template/self-service-case-view/self-service-case-view.component.spec.ts +24 -0
  132. package/lib/template/self-service-case-view/self-service-case-view.component.ts +216 -0
  133. package/lib/template/simple-table/simple-table.component.ts +0 -1
  134. package/lib/template/simple-table-manual/helpers.ts +2 -2
  135. package/lib/template/simple-table-manual/simple-table-manual.component.html +4 -4
  136. package/lib/template/simple-table-manual/simple-table-manual.component.scss +4 -14
  137. package/lib/template/simple-table-manual/simple-table-manual.component.ts +8 -4
  138. package/lib/template/single-reference-readonly/single-reference-readonly.component.html +4 -1
  139. package/lib/template/single-reference-readonly/single-reference-readonly.component.scss +21 -0
  140. package/lib/template/single-reference-readonly/single-reference-readonly.component.ts +104 -3
  141. package/lib/template/utils.ts +42 -0
  142. package/lib/template/wss-nav-bar/wss-nav-bar.component.html +5 -4
  143. package/lib/template/wss-nav-bar/wss-nav-bar.component.scss +2 -8
  144. package/lib/template/wss-nav-bar/wss-nav-bar.component.ts +1 -8
  145. package/lib/widget/app-announcement/app-announcement.component.html +1 -2
  146. package/lib/widget/app-announcement/app-announcement.component.scss +2 -2
  147. package/lib/widget/attachment/Attachment.types.ts +92 -0
  148. package/lib/widget/attachment/AttachmentUtils.ts +287 -0
  149. package/lib/widget/attachment/attachment.component.html +3 -3
  150. package/lib/widget/attachment/attachment.component.scss +2 -5
  151. package/lib/widget/attachment/attachment.component.ts +255 -254
  152. package/lib/widget/feed-container/feed-container.component.scss +3 -9
  153. package/lib/widget/feed-container/feed-container.component.ts +2 -2
  154. package/lib/widget/file-utility/file-utility.component.html +3 -3
  155. package/lib/widget/file-utility/file-utility.component.scss +5 -16
  156. package/lib/widget/list-utility/list-utility.component.scss +3 -5
  157. package/lib/widget/todo/todo.component.html +8 -5
  158. package/lib/widget/todo/todo.component.scss +10 -11
  159. package/lib/widget/todo/todo.component.ts +6 -2
  160. package/package.json +1 -1
@@ -0,0 +1,124 @@
1
+ h1 {
2
+ font-size: 1.1rem;
3
+ line-height: 1.3rem;
4
+ }
5
+
6
+ ::ng-deep .mat-mdc-menu-panel {
7
+ overflow: unset;
8
+ max-width: unset;
9
+ }
10
+
11
+ .psdk-case-view-label {
12
+ font-size: 1rem;
13
+ display: block;
14
+ transform: translateY(0.2em) scale(0.75) perspective(100px) translateZ(0.001px);
15
+ -ms-transform: translateY(0.2em) scale(0.75);
16
+ width: 133.33333%;
17
+ border-radius: 0.6125rem;
18
+ }
19
+
20
+ .psdk-case-view {
21
+ box-sizing: border-box;
22
+ display: flex;
23
+ }
24
+
25
+ .ng-case-view-toolbar {
26
+ padding: 0.625rem 0.625rem;
27
+ }
28
+
29
+ .psdk-case-icon-div {
30
+ background-color: var(--mat-sys-on-primary-fixed);
31
+ border-radius: 1rem;
32
+ padding: 0.5rem 0.3rem 0.3rem 0.3rem;
33
+ }
34
+ .psdk-case-svg-icon {
35
+ width: 2rem;
36
+ padding: 0rem 0.3125rem;
37
+ filter: var(--app-white-color-filter);
38
+ }
39
+
40
+ .psdk-case-view-info-box {
41
+ display: flex;
42
+ flex-direction: row;
43
+ padding: 0rem 0.3125rem 0rem 0rem;
44
+ }
45
+
46
+ .psdk-case-view-info {
47
+ flex: 0 0 auto;
48
+ width: 25rem;
49
+ float: left;
50
+ // padding: 0rem 0.3125rem 0rem 0rem;
51
+ background-color: var(--mat-sys-surface-container);
52
+ height: 100%;
53
+ }
54
+
55
+ .psdk-case-view-main {
56
+ flex-grow: 2;
57
+ float: left;
58
+ padding: 0rem 0.3125rem;
59
+ height: 100%; /* Should be removed. Only for demonstration */
60
+ }
61
+
62
+ .psdk-case-view-summary {
63
+ padding-left: 0.75rem;
64
+ }
65
+
66
+ .psdk-case-view-heading {
67
+ display: block;
68
+ text-align: left;
69
+ padding-left: 0.5rem;
70
+ padding-bottom: 0;
71
+ padding-top: 5px;
72
+ }
73
+ .psdk-case-view-heading-id {
74
+ font-size: 0.9rem;
75
+ font-weight: normal;
76
+ }
77
+
78
+ .psdk-case-view-buttons {
79
+ display: flex;
80
+ justify-content: flex-start;
81
+ padding: 0.3125rem;
82
+ }
83
+
84
+ .psdk-case-view-utilities {
85
+ background-color: var(--mat-sys-surface-container);
86
+ width: 21.875rem;
87
+ float: left;
88
+ padding: 0rem 0.3125rem;
89
+ }
90
+
91
+ .psdk-case-view-divider {
92
+ border-bottom: 0.0625rem solid var(--mat-sys-outline-variant);
93
+ }
94
+
95
+ .psdk-status {
96
+ padding: 0.3125rem 0.3125rem;
97
+ background-color: var(--mat-sys-primary);
98
+ color: var(--mat-sys-surface-container);
99
+ width: fit-content;
100
+ margin: 0.625rem;
101
+ }
102
+
103
+ .psdk-case-view-toolbar {
104
+ background-color: var(--mat-sys-primary);
105
+ justify-content: center;
106
+ }
107
+
108
+ button {
109
+ margin: 0rem 0.3125rem;
110
+ }
111
+
112
+ .psdk-case-view-toolbar-row {
113
+ padding-left: 1rem;
114
+ white-space: normal;
115
+ height: auto;
116
+ }
117
+
118
+ .psdk-self-service-case-view-header {
119
+ display: flex;
120
+ justify-content: space-around;
121
+ align-items: center;
122
+ margin: 10px;
123
+ background-color: var(--mat-sys-primary);
124
+ }
@@ -0,0 +1,24 @@
1
+ import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
2
+
3
+ import { SelfServiceCaseViewComponent } from './self-service-case-view.component';
4
+
5
+ describe('SelfServiceCaseViewComponent', () => {
6
+ let component: SelfServiceCaseViewComponent;
7
+ let fixture: ComponentFixture<SelfServiceCaseViewComponent>;
8
+
9
+ beforeEach(waitForAsync(() => {
10
+ TestBed.configureTestingModule({
11
+ declarations: [SelfServiceCaseViewComponent]
12
+ }).compileComponents();
13
+ }));
14
+
15
+ beforeEach(() => {
16
+ fixture = TestBed.createComponent(SelfServiceCaseViewComponent);
17
+ component = fixture.componentInstance;
18
+ fixture.detectChanges();
19
+ });
20
+
21
+ it('should create', () => {
22
+ expect(component).toBeTruthy();
23
+ });
24
+ });
@@ -0,0 +1,216 @@
1
+ import { Component, OnInit, Input, forwardRef, OnDestroy } from '@angular/core';
2
+ import { CommonModule } from '@angular/common';
3
+ import { FormGroup } from '@angular/forms';
4
+ import { MatToolbarModule } from '@angular/material/toolbar';
5
+ import { MatButtonModule } from '@angular/material/button';
6
+ import { MatMenuModule } from '@angular/material/menu';
7
+ import { interval } from 'rxjs';
8
+ import { AngularPConnectData, AngularPConnectService } from '@pega/angular-sdk-components';
9
+ import { Utils } from '@pega/angular-sdk-components';
10
+ import { ComponentMapperComponent } from '@pega/angular-sdk-components';
11
+ import { prepareCaseSummaryData } from '@pega/angular-sdk-components';
12
+
13
+ interface SelfServiceCaseViewProps {
14
+ // If any, enter additional props that only exist on this component
15
+ icon: string;
16
+ subheader: string;
17
+ header: string;
18
+ showCaseLifecycle: any;
19
+ showSummaryRegion: any;
20
+ showUtilitiesRegion: any;
21
+ showCaseActions: any;
22
+ caseClass: any;
23
+ }
24
+
25
+ @Component({
26
+ selector: 'app-self-service-case-view',
27
+ templateUrl: './self-service-case-view.component.html',
28
+ styleUrls: ['./self-service-case-view.component.scss'],
29
+ providers: [Utils],
30
+ imports: [CommonModule, MatToolbarModule, MatButtonModule, MatMenuModule, forwardRef(() => ComponentMapperComponent)]
31
+ })
32
+ export class SelfServiceCaseViewComponent implements OnInit, OnDestroy {
33
+ @Input() pConn$: typeof PConnect;
34
+ @Input() formGroup$: FormGroup;
35
+
36
+ // Used with AngularPConnect
37
+ angularPConnectData: AngularPConnectData = {};
38
+ configProps$: SelfServiceCaseViewProps;
39
+
40
+ arChildren$: any[];
41
+
42
+ heading$ = '';
43
+ id$ = '';
44
+ status$ = '';
45
+
46
+ arAvailableActions$: any[] = [];
47
+ arAvailabeProcesses$: any[] = [];
48
+
49
+ caseSummaryPConn$: any;
50
+ currentCaseID = '';
51
+ editAction: boolean;
52
+ bHasNewAttachments = false;
53
+ localizedVal: any;
54
+ localeCategory = 'CaseView';
55
+ localeKey: any;
56
+ showCaseLifecycle: boolean;
57
+ showSummaryRegion: boolean;
58
+ showUtilitiesRegion: boolean;
59
+ showCaseActions: boolean;
60
+ utilityRegion: any;
61
+ primarySummaryFields: any;
62
+ secondarySummaryFields: any;
63
+
64
+ constructor(
65
+ private angularPConnect: AngularPConnectService,
66
+ private utils: Utils
67
+ ) {}
68
+
69
+ ngOnInit(): void {
70
+ // First thing in initialization is registering and subscribing to the AngularPConnect service
71
+ this.angularPConnectData = this.angularPConnect.registerAndSubscribeComponent(this, this.onStateChange);
72
+ this.checkAndUpdate();
73
+ this.localizedVal = PCore.getLocaleUtils().getLocaleValue;
74
+ }
75
+
76
+ ngOnDestroy(): void {
77
+ if (this.angularPConnectData.unsubscribeFn) {
78
+ this.angularPConnectData.unsubscribeFn();
79
+ }
80
+ }
81
+
82
+ // Callback passed when subscribing to store change
83
+ onStateChange() {
84
+ this.checkAndUpdate();
85
+ }
86
+
87
+ checkAndUpdate() {
88
+ // Should always check the bridge to see if the component should update itself (re-render)
89
+ const bUpdateSelf = this.angularPConnect.shouldComponentUpdate(this);
90
+
91
+ // ONLY call updateSelf when the component should update
92
+ // AND removing the "gate" that was put there since shouldComponentUpdate
93
+ // should be the real "gate"
94
+ if (bUpdateSelf) {
95
+ // generally, don't want to refresh everything when data changes in caseView, it is usually the
96
+ // case summary. But check if the case ID changes, this means a different case and we should
97
+ // update all.
98
+ if (this.hasCaseIDChanged()) {
99
+ this.fullUpdate();
100
+
101
+ // update okToInitFlowContainer, because case view was drawn, flow container will need to be init
102
+ // to match Nebula/Constellation
103
+ sessionStorage.setItem('okToInitFlowContainer', 'true');
104
+ } else {
105
+ this.updateHeaderAndSummary();
106
+ }
107
+ }
108
+ }
109
+
110
+ hasCaseIDChanged(): boolean {
111
+ if (this.currentCaseID !== this.pConn$.getDataObject().caseInfo.ID) {
112
+ this.currentCaseID = this.pConn$.getDataObject().caseInfo.ID;
113
+ return true;
114
+ }
115
+ return false;
116
+ }
117
+
118
+ updateHeaderAndSummary() {
119
+ this.configProps$ = this.pConn$.resolveConfigProps(this.pConn$.getConfigProps()) as SelfServiceCaseViewProps;
120
+ const hasNewAttachments = this.pConn$.getDataObject().caseInfo?.hasNewAttachments;
121
+
122
+ if (hasNewAttachments !== this.bHasNewAttachments) {
123
+ this.bHasNewAttachments = hasNewAttachments;
124
+ if (this.bHasNewAttachments) {
125
+ PCore.getPubSubUtils().publish(PCore.getEvents().getCaseEvent().CASE_ATTACHMENTS_UPDATED_FROM_CASEVIEW, true);
126
+ }
127
+ }
128
+
129
+ const kids = this.pConn$.getChildren() as any[];
130
+ for (const kid of kids) {
131
+ const meta = kid.getPConnect().getRawMetadata();
132
+ if (meta.type.toLowerCase() == 'region' && meta.name.toLowerCase() == 'summary') {
133
+ this.caseSummaryPConn$ = kid.getPConnect().getChildren()[0].getPConnect();
134
+ }
135
+ }
136
+
137
+ // have to put in a timeout, otherwise get an angular change event error
138
+ const timer = interval(100).subscribe(() => {
139
+ timer.unsubscribe();
140
+
141
+ this.heading$ = PCore.getLocaleUtils().getLocaleValue(this.configProps$.header, '', this.localeKey);
142
+ this.id$ = this.configProps$.subheader;
143
+ this.status$ = this.pConn$.getValue('.pyStatusWork');
144
+ });
145
+ }
146
+
147
+ fullUpdate() {
148
+ this.configProps$ = this.pConn$.resolveConfigProps(this.pConn$.getConfigProps()) as SelfServiceCaseViewProps;
149
+ this.localeKey = this.pConn$?.getCaseLocaleReference();
150
+ this.updateHeaderAndSummary();
151
+
152
+ this.arChildren$ = this.pConn$.getChildren() as any[];
153
+
154
+ const caseInfo = this.pConn$.getDataObject().caseInfo;
155
+ this.currentCaseID = caseInfo.ID;
156
+ this.arAvailableActions$ = caseInfo?.availableActions ? caseInfo.availableActions : [];
157
+ this.editAction = this.arAvailableActions$.find(action => action.ID === 'pyUpdateCaseDetails');
158
+ this.arAvailabeProcesses$ = caseInfo?.availableProcesses ? caseInfo.availableProcesses : [];
159
+
160
+ const { showCaseLifecycle = true, showSummaryRegion = true, showUtilitiesRegion = true, showCaseActions = true, caseClass } = this.configProps$;
161
+ this.showCaseLifecycle = this.utils.getBooleanValue(showCaseLifecycle);
162
+ this.showSummaryRegion = this.utils.getBooleanValue(showSummaryRegion);
163
+ this.showUtilitiesRegion = this.utils.getBooleanValue(showUtilitiesRegion);
164
+ this.showCaseActions = this.utils.getBooleanValue(showCaseActions);
165
+ const isObjectType: boolean = (PCore.getCaseUtils() as any).isObjectCaseType(caseClass);
166
+ this.utilityRegion = isObjectType ? this.filterUtilities(this.arChildren$[2]) : this.filterUtilities(this.arChildren$[4]);
167
+ if (this.showSummaryRegion) {
168
+ const { primarySummaryFields, secondarySummaryFields } = prepareCaseSummaryData(
169
+ this.arChildren$[0],
170
+ (config: any) => config?.availableInChannel?.selfService === true
171
+ );
172
+ this.primarySummaryFields = primarySummaryFields;
173
+ this.secondarySummaryFields = secondarySummaryFields;
174
+ }
175
+ }
176
+
177
+ filterUtilities(utils) {
178
+ let utilsMeta;
179
+ const pConnect = utils.getPConnect();
180
+ utilsMeta = pConnect.getRawMetadata?.();
181
+ if (!utilsMeta?.children?.length) return;
182
+ utilsMeta = {
183
+ ...utilsMeta,
184
+ children: utilsMeta.children.filter((child: any) => child.config?.availableInChannel?.selfService === true)
185
+ };
186
+ return utilsMeta.children?.length ? pConnect.createComponent(utilsMeta) : undefined;
187
+ }
188
+
189
+ isUtilitiesRegionNotEmpty() {
190
+ if (this.utilityRegion && this.utilityRegion.getPConnect()?.getChildren()?.length > 0) {
191
+ return this.utilityRegion
192
+ .getPConnect()
193
+ .getChildren()
194
+ .some((prop: { getPConnect: () => any }) => prop.getPConnect().getConfigProps().visibility !== false);
195
+ }
196
+ return false;
197
+ }
198
+
199
+ updateSelf() {
200
+ this.fullUpdate();
201
+ }
202
+
203
+ _menuActionClick(data) {
204
+ const actionsAPI = this.pConn$.getActionsApi();
205
+ const openLocalAction = actionsAPI.openLocalAction.bind(actionsAPI);
206
+
207
+ openLocalAction(data.ID, { ...data, containerName: 'modal', type: 'express' });
208
+ }
209
+
210
+ _menuProcessClick(data) {
211
+ const actionsAPI = this.pConn$.getActionsApi();
212
+ const openProcessAction = actionsAPI.openProcessAction.bind(actionsAPI);
213
+
214
+ openProcessAction(data.ID, { ...data });
215
+ }
216
+ }
@@ -79,7 +79,6 @@ export class SimpleTableComponent implements OnInit, OnDestroy {
79
79
  this.configProps$ = this.pConn$.resolveConfigProps(this.pConn$.getConfigProps()) as SimpleTableProps;
80
80
 
81
81
  if (this.configProps$.visibility != null) {
82
- // eslint-disable-next-line no-multi-assign
83
82
  this.bVisible$ = this.bVisible$ = this.utils.getBooleanValue(this.configProps$.visibility);
84
83
  }
85
84
 
@@ -238,7 +238,7 @@ export const buildFieldsForTable = (configFields, pConnect, showDeleteButton, op
238
238
 
239
239
  // get resolved field labels for primary fields raw config included in configFields
240
240
  const fieldsLabels = updateFieldLabels(fields, configFields, primaryFieldsViewIndex, pConnect, {
241
- columnsRawConfig: pConnect.getRawConfigProps()?.children.find(item => item?.name === 'Columns')?.children
241
+ columnsRawConfig: pConnect.getRawConfigProps()?.children?.find(item => item?.name === 'Columns')?.children
242
242
  });
243
243
 
244
244
  const fieldDefs = configFields?.map((field, index) => {
@@ -404,7 +404,7 @@ export const createPConnect = (contextName, referenceList, pageReference) => {
404
404
 
405
405
  // create PConnect object
406
406
  const config = { meta: {}, options };
407
- const { getPConnect } = PCore.createPConnect(config);
407
+ const { getPConnect } = PCore.createPConnect(config as any);
408
408
 
409
409
  return getPConnect();
410
410
  };
@@ -44,7 +44,7 @@
44
44
  <td mat-cell *matCellDef="let element; index as j">
45
45
  <div class="header-icon">
46
46
  <button mat-icon-button [matMenuTriggerFor]="utilityMenu">
47
- <img class="psdk-utility-card-actions-svg-icon" src="{{ settingsSvgIcon$ }}" />
47
+ <mat-icon>more_vert</mat-icon>
48
48
  </button>
49
49
  <mat-menu #utilityMenu="matMenu" overlapTrigger="false">
50
50
  <button mat-menu-item (click)="editRecord(element, j)">Edit</button>
@@ -58,7 +58,7 @@
58
58
  <tr mat-row *matRowDef="let row; columns: displayedColumns"></tr>
59
59
  <tr class="mat-row psdk-no-records" *matNoDataRow>
60
60
  <td id="no-records" class="mat-cell" [attr.colspan]="displayedColumns.length">
61
- {{ utils.getGenericFieldsLocalizedValue('CosmosFields.fields.lists', 'No records found.') }}
61
+ {{ utils.getGenericFieldsLocalizedValue('COSMOSFIELDS.lists', 'No records found.') }}
62
62
  </td>
63
63
  </tr>
64
64
  </table>
@@ -82,7 +82,7 @@
82
82
  <th mat-header-cell *matHeaderCellDef></th>
83
83
  <td mat-cell *matCellDef="let element; index as j">
84
84
  <button id="delete-button" mat-icon-button (click)="deleteRecord(j)">
85
- <img class="psdk-utility-card-action-svg-icon" src="{{ menuIconOverride$ }}" />
85
+ <mat-icon>delete</mat-icon>
86
86
  </button>
87
87
  </td>
88
88
  </ng-container>
@@ -90,7 +90,7 @@
90
90
  <tr mat-row *matRowDef="let row; columns: displayedColumns"></tr>
91
91
  <tr class="mat-row psdk-no-records" *matNoDataRow>
92
92
  <td id="no-records" class="mat-cell" [attr.colspan]="displayedColumns.length">
93
- {{ utils.getGenericFieldsLocalizedValue('CosmosFields.fields.lists', 'No records found.') }}
93
+ {{ utils.getGenericFieldsLocalizedValue('COSMOSFIELDS.lists', 'No records found.') }}
94
94
  </td>
95
95
  </tr>
96
96
  </table>
@@ -26,7 +26,7 @@ table {
26
26
  ::ng-deep th.mat-mdc-header-cell,
27
27
  td.mat-mdc-cell,
28
28
  td.mat-mdc-footer-cell {
29
- border-right: 1px solid var(--app-neutral-light-color);
29
+ border-right: 1px solid var(--mat-sys-outline-variant);
30
30
  padding: 8px !important;
31
31
  min-width: 10rem;
32
32
  }
@@ -76,13 +76,6 @@ td.mat-mdc-cell:last-child {
76
76
  padding-left: 0.625rem;
77
77
  }
78
78
 
79
- .psdk-icon-search {
80
- vertical-align: sub;
81
- padding: 0rem 0.125rem;
82
- min-width: unset;
83
- width: 1.1rem;
84
- }
85
-
86
79
  .psdk-outer-div-in-form {
87
80
  display: inline-grid;
88
81
  }
@@ -121,7 +114,7 @@ td.mat-mdc-cell:last-child {
121
114
  display: table;
122
115
  margin: auto;
123
116
  min-width: 100px;
124
- background-color: var(--app-form-color);
117
+ background-color: var(--mat-sys-surface-container);
125
118
  border: 1px solid var(--app-inverse-form-color);
126
119
  border-radius: 10px;
127
120
  padding: 20px;
@@ -137,7 +130,6 @@ td.mat-mdc-cell:last-child {
137
130
  align-items: center;
138
131
  height: 100%;
139
132
  width: 100%;
140
- background-color: var(--app-dialog-background-color);
141
133
  position: fixed;
142
134
  z-index: 999;
143
135
  top: 0px;
@@ -148,7 +140,6 @@ td.mat-mdc-cell:last-child {
148
140
  display: table;
149
141
  margin: auto;
150
142
  min-width: 150px;
151
- background-color: var(--app-form-color);
152
143
  border: 1px solid var(--app-inverse-form-color);
153
144
  border-radius: 10px;
154
145
  padding: 20px;
@@ -160,7 +151,6 @@ tr.mat-mdc-row {
160
151
  }
161
152
 
162
153
  tr.mat-mdc-header-row {
163
- background: var(--app-table-header-background-color);
164
154
  }
165
155
 
166
156
  .psdk-data-readonly {
@@ -171,13 +161,13 @@ tr.mat-mdc-header-row {
171
161
  .psdk-no-records {
172
162
  height: 56px;
173
163
  text-align: center;
174
- border: 1px solid var(--app-neutral-light-color);
164
+ border: 1px solid var(--mat-sys-outline-variant);
175
165
  border-top: none;
176
- background: var(--app-form-color);
177
166
  }
178
167
 
179
168
  .psdk-utility-card-action-svg-icon {
180
169
  width: 1.4rem;
170
+ filter: var(--app-primary-color-filter);
181
171
  }
182
172
 
183
173
  .label {
@@ -9,6 +9,7 @@ import { MatMenuModule } from '@angular/material/menu';
9
9
  import { MatOptionModule } from '@angular/material/core';
10
10
  import { MatSelectModule } from '@angular/material/select';
11
11
  import { MatSort, MatSortModule } from '@angular/material/sort';
12
+ import { MatIcon } from '@angular/material/icon';
12
13
  import { MatTableDataSource, MatTableModule } from '@angular/material/table';
13
14
  import isEqual from 'fast-deep-equal';
14
15
 
@@ -73,8 +74,10 @@ class Group {
73
74
  MatOptionModule,
74
75
  MatSelectModule,
75
76
  MatInputModule,
77
+ MatIcon,
76
78
  forwardRef(() => ComponentMapperComponent)
77
- ]
79
+ ],
80
+ providers: [DatapageService]
78
81
  })
79
82
  export class SimpleTableManualComponent implements OnInit, OnDestroy {
80
83
  @ViewChild(MatSort) sort: MatSort;
@@ -215,7 +218,6 @@ export class SimpleTableManualComponent implements OnInit, OnDestroy {
215
218
  this.configProps$ = this.pConn$.resolveConfigProps(this.pConn$.getConfigProps()) as SimpleTableManualProps;
216
219
 
217
220
  if (this.configProps$.visibility != null) {
218
- // eslint-disable-next-line no-multi-assign
219
221
  this.bVisible$ = this.bVisible$ = this.utils.getBooleanValue(this.configProps$.visibility);
220
222
  }
221
223
 
@@ -825,7 +827,7 @@ export class SimpleTableManualComponent implements OnInit, OnDestroy {
825
827
  const seen = {};
826
828
  return a.filter(item => {
827
829
  const k = key(item);
828
- // eslint-disable-next-line no-return-assign, no-prototype-builtins
830
+ // eslint-disable-next-line no-prototype-builtins
829
831
  return seen.hasOwnProperty(k) ? false : (seen[k] = true);
830
832
  });
831
833
  }
@@ -916,7 +918,7 @@ export class SimpleTableManualComponent implements OnInit, OnDestroy {
916
918
 
917
919
  // return the value that should be shown as the contents for the given row data
918
920
  // of the given row field
919
- getRowValue(inRowData: Object, inColKey: string): any {
921
+ getRowValue(inRowData: object, inColKey: string): any {
920
922
  // See what data (if any) we have to display
921
923
  const refKeys: string[] = inColKey.split('.');
922
924
  let valBuilder = inRowData;
@@ -959,6 +961,7 @@ export class SimpleTableManualComponent implements OnInit, OnDestroy {
959
961
  if (this.allowEditingInModal && this.defaultView) {
960
962
  this.pConn$
961
963
  .getActionsApi()
964
+ // @ts-expect-error
962
965
  .openEmbeddedDataModal(
963
966
  this.defaultView,
964
967
  this.pConn$ as any,
@@ -980,6 +983,7 @@ export class SimpleTableManualComponent implements OnInit, OnDestroy {
980
983
  if (data) {
981
984
  this.pConn$
982
985
  .getActionsApi()
986
+ // @ts-expect-error
983
987
  .openEmbeddedDataModal(
984
988
  this.bUseSeparateViewForEdit ? this.editView : this.defaultView,
985
989
  this.pConn$ as any,
@@ -1 +1,4 @@
1
- <component-mapper name="SemanticLink" [props]="{ pConn$ }"></component-mapper>
1
+ <div [ngClass]="displayMode ? 'psdk-grid-display' : 'psdk-grid-nondisplay'">
2
+ <div *ngIf="label" class="psdk-grid-label">{{ label }}</div>
3
+ <component-mapper name="SemanticLink" [props]="{ pConn$: newPconn, formGroup$ }"></component-mapper>
4
+ </div>
@@ -0,0 +1,21 @@
1
+ .psdk-grid-display {
2
+ display: grid;
3
+ grid-template-columns: repeat(2, minmax(0, 1fr));
4
+ column-gap: calc(2 * 0.5rem);
5
+ row-gap: calc(2 * 0.5rem);
6
+ align-items: center;
7
+ margin-top: 1rem;
8
+ }
9
+
10
+ .psdk-grid-nondisplay {
11
+ margin-top: 1rem;
12
+ }
13
+
14
+ .psdk-label {
15
+ color: var(--app-label-color);
16
+ margin: 8px 0px;
17
+ }
18
+
19
+ .psdk-value {
20
+ margin: 8px 0px;
21
+ }