@pega/angular-sdk-overrides 0.25.3 → 0.25.5

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 (26) hide show
  1. package/lib/designSystemExtension/wss-quick-create/wss-quick-create.component.scss +0 -1
  2. package/lib/field/date/date.component.html +1 -1
  3. package/lib/field/date-time/date-time.component.html +1 -1
  4. package/lib/field/date-time/date-time.component.ts +5 -1
  5. package/lib/field/location/location.component.html +2 -2
  6. package/lib/field/location/location.component.ts +20 -125
  7. package/lib/field/phone/phone.component.scss +0 -5
  8. package/lib/infra/Containers/flow-container/flow-container.component.html +1 -1
  9. package/lib/infra/Containers/flow-container/flow-container.component.ts +1 -1
  10. package/lib/infra/multi-step/multi-step.component.html +22 -38
  11. package/lib/infra/multi-step/multi-step.component.scss +13 -6
  12. package/lib/infra/navbar/navbar.component.html +11 -13
  13. package/lib/infra/navbar/navbar.component.scss +6 -0
  14. package/lib/infra/reference/reference.component.ts +5 -0
  15. package/lib/infra/view/view.component.ts +3 -4
  16. package/lib/template/list-view/list-view.component.html +170 -167
  17. package/lib/template/list-view/list-view.component.scss +7 -3
  18. package/lib/template/list-view/list-view.component.ts +53 -31
  19. package/lib/template/self-service-case-view/self-service-case-view.component.html +21 -25
  20. package/lib/template/self-service-case-view/self-service-case-view.component.scss +2 -1
  21. package/lib/widget/attachment/attachment.component.scss +7 -9
  22. package/lib/widget/attachment/attachment.component.ts +4 -3
  23. package/lib/widget/file-utility/file-utility.component.scss +1 -1
  24. package/lib/widget/quick-create/quick-create.component.ts +41 -22
  25. package/lib/widget/todo/todo.component.scss +2 -0
  26. package/package.json +1 -1
@@ -5,7 +5,7 @@
5
5
  }
6
6
 
7
7
  .psdk-modal-file-selector {
8
- border: 1px dashed var(--app-neutral-dark-color);
8
+ border: 1px dashed var(--mat-sys-neutral-variant20);
9
9
  width: 100%;
10
10
  padding: 0.3rem;
11
11
  text-align: center;
@@ -22,7 +22,7 @@
22
22
  }
23
23
 
24
24
  .psdk-modal-file-selector-error {
25
- border: 1px dashed var(--app-error-light-color);
25
+ border: 1px dashed var(--mat-sys-error);
26
26
  width: 100%;
27
27
  padding: 0.3rem;
28
28
  text-align: center;
@@ -45,14 +45,14 @@
45
45
  }
46
46
 
47
47
  .psdk-attachment-list {
48
- border: 1px solid var(--app-neutral-color);
48
+ border: 1px solid var(--mat-sys-secondary);
49
49
  }
50
50
 
51
51
  ::ng-deep .mat-mdc-form-field-infix {
52
52
  width: auto;
53
53
  }
54
54
  .psdk-modal-file-selector {
55
- border: 1px dashed var(--app-neutral-dark-color);
55
+ border: 1px dashed var(--mat-sys-neutral-variant20);
56
56
  padding: 0.5rem;
57
57
  text-align: center;
58
58
  position: relative;
@@ -68,7 +68,7 @@
68
68
  }
69
69
 
70
70
  .psdk-modal-file-selector-error {
71
- border: 1px dashed var(--app-error-light-color);
71
+ border: 1px dashed var(--mat-sys-error);
72
72
  padding: 0.5rem;
73
73
  text-align: center;
74
74
  position: relative;
@@ -90,7 +90,7 @@
90
90
  }
91
91
 
92
92
  .psdk-attachment-list {
93
- border: 1px solid var(--app-neutral-color);
93
+ border: 1px solid var(--mat-sys-secondary);
94
94
  }
95
95
 
96
96
  ::ng-deep .mat-mdc-form-field-infix {
@@ -126,7 +126,6 @@
126
126
 
127
127
  .psdk-attachment-card-svg-icon {
128
128
  width: 2.5rem;
129
- filter: var(--app-white-color-filter);
130
129
  }
131
130
 
132
131
  .psdk-utility-button {
@@ -134,7 +133,6 @@
134
133
  border: none;
135
134
  margin-right: 0.5rem;
136
135
  cursor: pointer;
137
- filter: var(--app-white-color-filter);
138
136
  }
139
137
 
140
138
  .psdk-utility-card-action-svg-icon {
@@ -151,7 +149,7 @@
151
149
  }
152
150
 
153
151
  .file-div-error {
154
- border: 1px dashed var(--app-error-light-color);
152
+ border: 1px dashed var(--mat-sys-error);
155
153
  width: 100%;
156
154
  padding: 0.5rem;
157
155
  text-align: center;
@@ -132,11 +132,12 @@ export class AttachmentComponent implements OnInit, OnDestroy {
132
132
  updateSelf() {
133
133
  const configProps: AttachmentProps = this.pConn$.resolveConfigProps(this.pConn$.getConfigProps()) as AttachmentProps;
134
134
  const stateProps = this.pConn$.getStateProps();
135
- const { value, label, required, visibility, disabled, readOnly, extensions, displayMode, isTableFormatter, allowMultiple, editMode } =
136
- configProps;
135
+ const { value, label, required, disabled, readOnly, extensions, displayMode, isTableFormatter, allowMultiple, editMode } = configProps;
137
136
 
138
137
  this.bRequired$ = this.utils.getBooleanValue(required);
139
- this.bVisible$ = this.utils.getBooleanValue(visibility);
138
+ if (configProps.visibility != null) {
139
+ this.bVisible$ = this.utils.getBooleanValue(configProps.visibility);
140
+ }
140
141
  this.bDisabled$ = this.utils.getBooleanValue(disabled);
141
142
  this.bReadonly$ = this.utils.getBooleanValue(readOnly);
142
143
  this.allowMultiple$ = this.utils.getBooleanValue(allowMultiple);
@@ -24,7 +24,7 @@
24
24
  }
25
25
 
26
26
  .psdk-modal-file-selector {
27
- border: 1px dashed var(--app-neutral-dark-color);
27
+ border: 1px dashed var(--mat-sys-neutral-variant20);
28
28
  width: 100%;
29
29
  padding: 0.3rem;
30
30
  text-align: center;
@@ -40,38 +40,57 @@ export class QuickCreateComponent implements OnInit, OnChanges {
40
40
 
41
41
  initComponent() {
42
42
  this.configProps$ = this.pConn$.resolveConfigProps(this.pConn$.getConfigProps()) as QuickCreateProps;
43
-
44
43
  this.heading$ = this.configProps$.heading;
45
44
  this.showCaseIcons$ = this.configProps$.showCaseIcons;
46
45
  this.classFilter$ = this.configProps$.classFilter;
47
-
46
+ const cases: any = [];
47
+ const defaultCases: any = [];
48
48
  const envInfo = PCore.getEnvironmentInfo();
49
- if (
50
- this.classFilter$ &&
51
- envInfo.environmentInfoObject &&
52
- envInfo.environmentInfoObject.pyCaseTypeList &&
53
- envInfo.environmentInfoObject.pyCaseTypeList.length > 0
54
- ) {
55
- this.classFilter$.forEach(item => {
56
- let icon = this.utils.getImageSrc('polaris-solid', this.utils.getSDKStaticContentUrl());
57
- let label = '';
58
- (envInfo.environmentInfoObject as any).pyCaseTypeList.forEach(casetype => {
59
- if (casetype.pyWorkTypeImplementationClassName === item) {
60
- icon = casetype.pxIcon && this.utils.getImageSrc(casetype?.pxIcon, this.utils.getSDKStaticContentUrl());
61
- label = casetype.pyWorkTypeName ?? '';
62
- }
63
- });
64
- if (label !== '') {
65
- this.cases$.push({
66
- label,
49
+ if (envInfo?.environmentInfoObject?.pyCaseTypeList) {
50
+ envInfo.environmentInfoObject.pyCaseTypeList.forEach((casetype: any) => {
51
+ if (casetype.pyWorkTypeName && casetype.pyWorkTypeImplementationClassName) {
52
+ defaultCases.push({
53
+ classname: casetype.pyWorkTypeImplementationClassName,
54
+ onClick: () => {
55
+ this.createCase(casetype.pyWorkTypeImplementationClassName);
56
+ },
57
+ ...(this.showCaseIcons$ && { icon: this.utils.getImageSrc(casetype?.pxIcon, this.utils.getSDKStaticContentUrl()) }),
58
+ label: casetype.pyWorkTypeName
59
+ });
60
+ }
61
+ });
62
+ } else {
63
+ const pConnectInAppContext = PCore.createPConnect({
64
+ options: { context: PCore.getConstants().APP.APP }
65
+ }).getPConnect();
66
+ const pyPortalInAppContext = pConnectInAppContext.getValue('pyPortal') as any;
67
+ pyPortalInAppContext?.pyCaseTypesAvailableToCreate?.forEach(casetype => {
68
+ if (casetype.pyClassName && casetype.pyLabel) {
69
+ defaultCases.push({
70
+ classname: casetype.pyClassName,
67
71
  onClick: () => {
68
- this.createCase(item);
72
+ this.createCase(casetype.pyClassName);
69
73
  },
70
- ...(this.showCaseIcons$ && { icon })
74
+ ...(this.showCaseIcons$ && { icon: this.utils.getImageSrc(casetype?.pxIcon, this.utils.getSDKStaticContentUrl()) }),
75
+ label: casetype.pyLabel
71
76
  });
72
77
  }
73
78
  });
74
79
  }
80
+
81
+ /* If classFilter is not empty - filter from the list of defaultCases */
82
+ if (this.classFilter$?.length > 0) {
83
+ this.classFilter$.forEach(item => {
84
+ defaultCases.forEach(casetype => {
85
+ if (casetype.classname === item) {
86
+ cases.push(casetype);
87
+ }
88
+ });
89
+ });
90
+ this.cases$ = cases;
91
+ } else {
92
+ this.cases$ = defaultCases;
93
+ }
75
94
  }
76
95
 
77
96
  ngOnInit() {
@@ -13,6 +13,8 @@
13
13
  padding: 1rem;
14
14
  background-color: var(--mat-sys-surface-container);
15
15
  border-radius: 0.6125rem;
16
+ border-left: 6px solid;
17
+ border-left-color: var(--mat-sys-primary);
16
18
  }
17
19
 
18
20
  .psdk-todo-header {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pega/angular-sdk-overrides",
3
- "version": "0.25.3",
3
+ "version": "0.25.5",
4
4
  "description": "Angular SDK - Code for overriding components",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"