@pega/cosmos-react-work 3.0.0-dev.12.0 → 3.0.0-dev.15.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 (41) hide show
  1. package/lib/components/SearchResults/SearchResult.d.ts +1 -1
  2. package/lib/components/SearchResults/SearchResult.d.ts.map +1 -1
  3. package/lib/components/SearchResults/SearchResult.js +9 -3
  4. package/lib/components/SearchResults/SearchResult.js.map +1 -1
  5. package/lib/components/SearchResults/SearchResults.d.ts.map +1 -1
  6. package/lib/components/SearchResults/SearchResults.js +51 -36
  7. package/lib/components/SearchResults/SearchResults.js.map +1 -1
  8. package/lib/components/SearchResults/SearchResults.styles.d.ts +3 -0
  9. package/lib/components/SearchResults/SearchResults.styles.d.ts.map +1 -1
  10. package/lib/components/SearchResults/SearchResults.styles.js +33 -17
  11. package/lib/components/SearchResults/SearchResults.styles.js.map +1 -1
  12. package/lib/components/SearchResults/SearchResults.types.d.ts +4 -0
  13. package/lib/components/SearchResults/SearchResults.types.d.ts.map +1 -1
  14. package/lib/components/SearchResults/SearchResults.types.js.map +1 -1
  15. package/lib/components/Stages/StageGlimpse.d.ts +10 -0
  16. package/lib/components/Stages/StageGlimpse.d.ts.map +1 -0
  17. package/lib/components/Stages/StageGlimpse.js +11 -0
  18. package/lib/components/Stages/StageGlimpse.js.map +1 -0
  19. package/lib/components/Stages/Stages.d.ts +1 -1
  20. package/lib/components/Stages/Stages.d.ts.map +1 -1
  21. package/lib/components/Stages/Stages.js +105 -112
  22. package/lib/components/Stages/Stages.js.map +1 -1
  23. package/lib/components/Stages/Stages.styles.d.ts +4 -7
  24. package/lib/components/Stages/Stages.styles.d.ts.map +1 -1
  25. package/lib/components/Stages/Stages.styles.js +169 -186
  26. package/lib/components/Stages/Stages.styles.js.map +1 -1
  27. package/lib/components/Stages/Stages.types.d.ts +19 -4
  28. package/lib/components/Stages/Stages.types.d.ts.map +1 -1
  29. package/lib/components/Stages/Stages.types.js.map +1 -1
  30. package/lib/components/Timeline/Timeline.styles.d.ts.map +1 -1
  31. package/lib/components/Timeline/Timeline.styles.js +1 -0
  32. package/lib/components/Timeline/Timeline.styles.js.map +1 -1
  33. package/package.json +5 -2
  34. package/lib/components/Stages/Steps.d.ts +0 -8
  35. package/lib/components/Stages/Steps.d.ts.map +0 -1
  36. package/lib/components/Stages/Steps.js +0 -12
  37. package/lib/components/Stages/Steps.js.map +0 -1
  38. package/lib/components/Stages/StepsContainer.d.ts +0 -8
  39. package/lib/components/Stages/StepsContainer.d.ts.map +0 -1
  40. package/lib/components/Stages/StepsContainer.js +0 -11
  41. package/lib/components/Stages/StepsContainer.js.map +0 -1
@@ -1,5 +1,6 @@
1
1
  import styled, { css } from 'styled-components';
2
- import { calculateFontSize, defaultThemeProp, StyledIcon, StyledText, useDirection } from '@pega/cosmos-react-core';
2
+ import { rgba as polishedRgba } from 'polished';
3
+ import { calculateFontSize, CardContent, DateTimeDisplay, defaultThemeProp, Popover, StyledIcon, tryCatch, useDirection } from '@pega/cosmos-react-core';
3
4
  export const StyledStages = styled.div(props => {
4
5
  return css `
5
6
  background-color: ${props.theme.base.palette['primary-background']};
@@ -20,195 +21,189 @@ export const StyledInnerStage = styled.span(props => {
20
21
  `}
21
22
  `;
22
23
  });
23
- export const StyledStage = styled.button(({ theme: { base: { spacing, palette, 'hit-area': hitArea, shadow, transparency, 'border-radius': borderRadius } } }) => {
24
- const activeColor = palette.interactive;
25
- const baseBorderColor = palette['border-line'];
24
+ export const StyledStage = styled.button(({ theme: { base: { spacing, palette, 'hit-area': hitArea, transparency, 'border-radius': borderRadius } } }) => {
26
25
  const thinBorderWidth = '0.0625rem';
27
26
  const thickBorderWidth = '0.125rem';
28
- const baseTransparency = transparency['transparent-2'];
29
- const { rtl, start, end } = useDirection();
27
+ const { rtl } = useDirection();
28
+ const borderShadow = tryCatch(() => polishedRgba(palette['border-line'], 1));
30
29
  return css `
31
- /* stylelint-disable no-descending-specificity */
32
- background-color: inherit;
33
- color: ${palette['foreground-color']};
34
- outline: none;
35
- border-color: transparent;
36
- border-width: ${thinBorderWidth} 0;
37
- border-style: solid;
38
- position: relative;
39
- height: calc(4 * ${spacing});
40
- min-width: calc(5.25 * ${spacing});
41
- padding-inline-start: calc(2 * ${spacing});
42
- padding-inline-end: ${spacing};
43
-
44
- @media (pointer: coarse) {
45
- height: ${hitArea['finger-min']};
46
- padding-inline-start: calc(2.25 * ${spacing});
47
- }
48
-
49
- ${StyledIcon} {
50
- margin-inline-end: 0.25rem;
51
- color: ${palette.success};
30
+ /* stylelint-disable no-descending-specificity */
31
+ background-color: inherit;
32
+ color: ${palette['foreground-color']};
33
+ outline: none;
34
+ border-color: transparent;
35
+ border-width: ${thinBorderWidth} 0;
36
+ border-style: solid;
37
+ position: relative;
38
+ height: calc(4 * ${spacing});
39
+ min-width: calc(5.25 * ${spacing});
40
+ padding-inline-start: calc(2 * ${spacing});
41
+ padding-inline-end: ${spacing};
52
42
 
53
- &:last-child {
54
- margin-inline-end: 0;
43
+ @media (pointer: coarse) {
44
+ height: ${hitArea['finger-min']};
45
+ padding-inline-start: calc(2.25 * ${spacing});
55
46
  }
56
- }
57
47
 
58
- ${StyledInnerStage} {
59
- opacity: ${baseTransparency};
60
- }
61
-
62
- &:first-child {
63
- border-top-${start}-radius: ${borderRadius};
64
- border-bottom-${start}-radius: ${borderRadius};
65
- border-inline-start-width: ${thinBorderWidth};
66
- padding-inline-start: calc(${spacing});
67
- }
48
+ ${StyledIcon} {
49
+ color: ${palette.success};
68
50
 
69
- &:last-child {
70
- border-top-${end}-radius: ${borderRadius};
71
- border-bottom-${end}-radius: ${borderRadius};
72
- border-inline-end-width: ${thinBorderWidth};
73
- padding-inline-end: calc(${spacing});
74
- min-width: calc(6.25 * ${spacing});
75
- }
76
-
77
- &:not(:first-child)::before {
78
- content: '';
79
- position: absolute;
80
- display: block;
81
- width: calc(2.25 * ${spacing});
82
- height: calc(2.25 * ${spacing});
83
- left: calc(-1.125 * ${spacing});
84
- right: calc(-1.125 * ${spacing});
85
- background-color: transparent;
86
- border-style: solid;
87
- border-color: ${baseBorderColor};
88
- border-inline-end-width: ${thinBorderWidth};
89
- border-inline-start-width: 0;
90
- border-top-width: ${rtl ? 0 : thinBorderWidth};
91
- border-bottom-width: ${rtl ? thinBorderWidth : 0};
92
- transform: rotateZ(45deg) skew(15deg, 15deg);
51
+ & ~ ${StyledInnerStage} {
52
+ margin-inline-start: 0.25rem;
53
+ }
54
+ }
93
55
 
94
- @media (pointer: coarse) {
95
- width: calc(2.875 * ${spacing});
96
- height: calc(2.875 * ${spacing});
97
- left: calc(-1.375 * ${spacing});
98
- right: calc(-1.375 * ${spacing});
99
- transform: rotateZ(45deg) skew(20deg, 20deg);
56
+ ${StyledInnerStage} {
57
+ opacity: ${transparency['transparent-2']};
100
58
  }
101
- }
102
59
 
103
- &:hover,
104
- &:hover::before {
105
- border-color: ${baseBorderColor};
106
- }
60
+ &:first-of-type {
61
+ border-start-start-radius: ${borderRadius};
62
+ border-end-start-radius: ${borderRadius};
63
+ border-inline-start-width: ${thinBorderWidth};
64
+ padding-inline-start: ${spacing};
107
65
 
108
- &:hover {
109
- ${StyledInnerStage} {
110
- opacity: 1;
66
+ &:active {
67
+ padding-inline-start: ${spacing};
68
+ }
69
+
70
+ &:focus {
71
+ border-inline-start-width: ${thickBorderWidth};
72
+ padding-inline-start: calc(${spacing} - ${thickBorderWidth} + ${thinBorderWidth});
73
+ }
111
74
  }
112
- }
113
75
 
114
- &:focus,
115
- &:active,
116
- &:focus::before,
117
- &:active::before,
118
- &:focus + &::before,
119
- &:active + &::before {
120
- border-color: ${activeColor};
121
- }
76
+ &:last-of-type {
77
+ border-start-end-radius: ${borderRadius};
78
+ border-end-end-radius: ${borderRadius};
79
+ border-inline-end-width: ${thinBorderWidth};
80
+ padding-inline-end: ${spacing};
81
+ min-width: calc(6.25 * ${spacing});
122
82
 
123
- &:focus {
124
- border-width: ${thickBorderWidth} 0;
125
- }
83
+ &:active {
84
+ border-inline-end-width: ${thinBorderWidth};
85
+ padding-inline-end: ${spacing};
86
+ }
126
87
 
127
- &:focus::before,
128
- &:focus + &::before {
129
- border-inline-end-width: ${thickBorderWidth};
130
- border-top-width: ${rtl ? 0 : thickBorderWidth};
131
- border-bottom-width: ${rtl ? thickBorderWidth : 0};
132
- }
88
+ &:focus {
89
+ border-inline-end-width: ${thickBorderWidth};
90
+ padding-inline-end: calc(${spacing} - ${thinBorderWidth});
91
+ }
92
+ }
133
93
 
134
- &:first-child:focus {
135
- border-inline-start-width: ${thickBorderWidth};
136
- padding-inline-start: calc(${spacing} - ${thickBorderWidth} + ${thinBorderWidth});
137
- }
94
+ &:not(:first-of-type)::before,
95
+ &:not(:last-of-type)::after {
96
+ content: '';
97
+ position: absolute;
98
+ display: block;
99
+ width: calc(2.25 * ${spacing});
100
+ height: calc(2.25 * ${spacing});
101
+ background-color: transparent;
102
+ border-style: solid;
103
+ border-color: ${palette['border-line']};
104
+ border-inline-end-width: ${thinBorderWidth};
105
+ border-inline-start-width: 0;
106
+ border-top-width: ${rtl ? 0 : thinBorderWidth};
107
+ border-bottom-width: ${rtl ? thinBorderWidth : 0};
108
+ transform: rotateZ(45deg) skew(15deg, 15deg);
138
109
 
139
- &:last-child:focus {
140
- border-inline-end-width: ${thickBorderWidth};
141
- padding-inline-end: calc(${spacing} - ${thinBorderWidth});
142
- }
110
+ @media (pointer: coarse) {
111
+ width: calc(2.875 * ${spacing});
112
+ height: calc(2.875 * ${spacing});
113
+ transform: rotateZ(45deg) skew(20deg, 20deg);
114
+ }
115
+ }
143
116
 
144
- &:active {
145
- border-width: ${thinBorderWidth} 0;
117
+ &:not(:first-of-type)::before {
118
+ inset-inline-start: calc(-1.125 * ${spacing});
146
119
 
147
- ${StyledInnerStage} {
148
- opacity: ${transparency['transparent-3']};
120
+ @media (pointer: coarse) {
121
+ inset-inline-start: calc(-1.375 * ${spacing});
122
+ }
149
123
  }
150
- }
151
124
 
152
- &:active::before,
153
- &:active + &::before {
154
- border-inline-end-width: ${thinBorderWidth};
155
- border-top-width: ${rtl ? 0 : thinBorderWidth};
156
- border-bottom-width: ${rtl ? thinBorderWidth : 0};
157
- }
125
+ &:not(:last-of-type)::after {
126
+ inset-inline-end: calc(-1.125 * ${spacing});
127
+ z-index: 1;
158
128
 
159
- &:first-child:active {
160
- border-inline-start-width: ${thinBorderWidth};
161
- padding-inline-start: calc(${spacing});
162
- }
129
+ @media (pointer: coarse) {
130
+ inset-inline-end: calc(-1.375 * ${spacing});
131
+ }
132
+ }
163
133
 
164
- &:last-child:active {
165
- border-inline-end-width: ${thinBorderWidth};
166
- padding-inline-end: calc(${spacing});
167
- }
134
+ &:hover,
135
+ &:hover::before,
136
+ &:hover::after {
137
+ border-color: ${palette['border-line']};
138
+ }
168
139
 
169
- &[aria-current] {
170
- z-index: 2;
140
+ &:focus,
141
+ &:active,
142
+ &:focus::before,
143
+ &:active::before,
144
+ &:focus::after,
145
+ &:active::after {
146
+ border-color: ${palette.interactive};
147
+ }
171
148
 
172
- ${StyledInnerStage} {
173
- font-weight: bold;
174
- opacity: 1;
149
+ &:focus {
150
+ border-width: ${thickBorderWidth} 0;
175
151
  }
176
152
 
177
- &:hover {
178
- ${StyledInnerStage} {
179
- opacity: ${baseTransparency};
180
- }
153
+ &:focus::before,
154
+ &:focus::after {
155
+ z-index: 1;
156
+ border-inline-end-width: ${thickBorderWidth};
157
+ border-top-width: ${rtl ? 0 : thickBorderWidth};
158
+ border-bottom-width: ${rtl ? thickBorderWidth : 0};
159
+ }
160
+
161
+ &:focus::before {
162
+ pointer-events: none;
181
163
  }
164
+
182
165
  &:active {
166
+ border-width: ${thinBorderWidth} 0;
167
+
183
168
  ${StyledInnerStage} {
184
169
  opacity: ${transparency['transparent-3']};
185
170
  }
186
171
  }
187
- }
188
172
 
189
- &[aria-current] + &::before {
190
- box-shadow: ${shadow.low};
191
- }
173
+ &:active::before,
174
+ &:active::after {
175
+ border-inline-end-width: ${thinBorderWidth};
176
+ border-top-width: ${rtl ? 0 : thinBorderWidth};
177
+ border-bottom-width: ${rtl ? thinBorderWidth : 0};
178
+ }
192
179
 
193
- &[aria-current] + &:focus::before {
194
- box-shadow: none;
195
- }
196
- `;
180
+ &[aria-current] {
181
+ ${StyledInnerStage} {
182
+ font-weight: bold;
183
+ opacity: 1;
184
+ }
185
+
186
+ &:hover {
187
+ ${StyledInnerStage} {
188
+ opacity: ${transparency['transparent-2']};
189
+ }
190
+ }
191
+ }
192
+
193
+ &[aria-current]::after {
194
+ filter: drop-shadow(0.0625rem -0.0625rem 0.125rem ${borderShadow});
195
+ }
196
+ `;
197
197
  });
198
198
  StyledStage.defaultProps = defaultThemeProp;
199
- export const StyledStagePopover = styled.div(({ theme }) => {
200
- return css `
201
- padding: calc(2 * ${theme.base.spacing});
202
- white-space: pre-line;
203
- width: 18rem;
204
- `;
205
- });
199
+ export const StyledStagePopover = styled(Popover) `
200
+ width: 36ch;
201
+ `;
206
202
  StyledStagePopover.defaultProps = defaultThemeProp;
207
203
  export const StyledStepsContainer = styled.ol(({ theme }) => {
208
204
  return css `
209
205
  list-style-type: none;
210
- margin-top: calc(1.5 * ${theme.base.spacing});
211
- margin-bottom: calc(2.5 * ${theme.base.spacing});
206
+ margin: calc(1.5 * ${theme.base.spacing}) 0;
212
207
 
213
208
  &:empty {
214
209
  margin-bottom: 0;
@@ -216,11 +211,9 @@ export const StyledStepsContainer = styled.ol(({ theme }) => {
216
211
  `;
217
212
  });
218
213
  StyledStepsContainer.defaultProps = defaultThemeProp;
219
- export const StyledStep = styled.li(({ complete, theme }) => {
220
- const iconColor = complete ? theme.base.palette.success : theme.base.palette['foreground-color'];
221
- const iconWidth = complete ? '1.125rem' : '0.3rem';
222
- const iconMargin = complete ? 0 : '0.3rem';
223
- const textOpacity = complete ? theme.base.transparency['transparent-3'] : 1;
214
+ export const StyledStep = styled.li(({ completed, theme }) => {
215
+ const iconColor = encodeURIComponent(completed ? theme.base.palette.success : theme.base.palette['foreground-color']);
216
+ const textOpacity = completed ? theme.base.transparency['transparent-2'] : 1;
224
217
  return css `
225
218
  border-radius: 0;
226
219
  margin-bottom: calc(${theme.base.spacing});
@@ -230,46 +223,36 @@ export const StyledStep = styled.li(({ complete, theme }) => {
230
223
  margin-bottom: 0;
231
224
  }
232
225
 
233
- ${StyledIcon} {
234
- margin-inline-end: calc(${theme.base.spacing});
235
- color: ${iconColor};
236
- width: ${iconWidth};
237
- margin-inline-start: ${iconMargin};
226
+ /* stylelint-disable no-duplicate-selectors */
227
+ &::before {
228
+ content: '\u00b7';
229
+ font-weight: 800;
230
+ width: 1rem;
231
+ text-align: center;
232
+ flex-shrink: 0;
238
233
  }
239
234
 
240
- ${StyledText} {
235
+ ${completed &&
236
+ css `
237
+ &::before {
238
+ /* cSpell:disable-next-line */
239
+ content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 25 25' fill='${iconColor}'%3E%3Cpath d='M3.5328125,10.8960938 C3.5328125,10.8960938 10.0460938,17.3617188 10.0460938,17.3617188 C10.0460938,17.3617188 22.4984375,4 22.4984375,4 C22.4984375,4 23.9828125,5.484375 23.9828125,5.484375 C23.9828125,5.484375 10.09375,20.2351562 10.09375,20.2351562 C10.09375,20.2351562 2,12.3804687 2,12.3804687 C2,12.3804687 3.5328125,10.8960937 3.5328125,10.8960937 L3.5328125,10.8960938 Z'/%3E%3C/svg%3E");
240
+ margin-block-start: calc(0.25 * ${theme.base.spacing});
241
+ }
242
+ `}
243
+ /* stylelint-enable no-duplicate-selectors */
244
+
245
+ div {
241
246
  opacity: ${textOpacity};
242
247
  }
243
248
  `;
244
249
  });
245
250
  StyledStep.defaultProps = defaultThemeProp;
246
- export const StyledSteps = styled.div `
247
- background-color: ${props => props.theme.components.card.background};
248
- position: relative;
251
+ export const StyledPopoverContent = styled(CardContent) `
252
+ min-height: 6rem;
249
253
  `;
250
- StyledSteps.defaultProps = defaultThemeProp;
251
- export const StyledInnerStep = styled.span(({ complete, theme }) => {
252
- const textOpacity = complete ? theme.base.transparency['transparent-2'] : 1;
253
- return css `
254
- display: flex;
255
- width: 100%;
256
- text-align: start;
257
- overflow: hidden;
258
- white-space: nowrap;
259
- text-overflow: ellipsis;
260
-
261
- ${StyledIcon} {
262
- color: ${theme.base.palette.success};
263
- margin-inline-end: ${theme.base.spacing};
264
- }
265
-
266
- ${StyledText} {
267
- opacity: ${textOpacity};
268
- }
269
- `;
270
- });
271
- StyledInnerStep.defaultProps = defaultThemeProp;
272
- export const StyledDateTimeDisplay = styled.span(({ theme }) => {
254
+ StyledPopoverContent.defaultProps = defaultThemeProp;
255
+ export const StyledDateTimeDisplay = styled(DateTimeDisplay)(({ theme }) => {
273
256
  const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);
274
257
  return css `
275
258
  font-size: ${fontSize.xs};
@@ -1 +1 @@
1
- {"version":3,"file":"Stages.styles.js","sourceRoot":"","sources":["../../../src/components/Stages/Stages.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,EACL,iBAAiB,EACjB,gBAAgB,EAChB,UAAU,EACV,UAAU,EACV,YAAY,EACb,MAAM,yBAAyB,CAAC;AAEjC,MAAM,CAAC,MAAM,YAAY,GAAG,MAAM,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE;IAC7C,OAAO,GAAG,CAAA;wBACY,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,oBAAoB,CAAC;qBACjD,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,eAAe,CAAC;;GAEnD,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,YAAY,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAE7C,MAAM,CAAC,MAAM,gBAAgB,GAAG,MAAM,CAAC,IAAI,CAAyB,KAAK,CAAC,EAAE;IAC1E,OAAO,GAAG,CAAA;;;;MAIN,KAAK,CAAC,QAAQ;QAChB,GAAG,CA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C;AAEF,WAAW,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAE5C,MAAM,CAAC,MAAM,eAAe,GAAG,MAAM,CAAC,IAAI,CAAwB,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,EAAE,EAAE;IACxF,MAAM,WAAW,GAAG,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,CAAC,YAAY,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IAC5E,OAAO,GAAG,CAAA;;;;;;;;MAQN,UAAU;eACD,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO;2BACd,KAAK,CAAC,IAAI,CAAC,OAAO;;;MAGvC,UAAU;iBACC,WAAW;;GAEzB,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,eAAe,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAEhD,MAAM,CAAC,MAAM,qBAAqB,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IAC7D,MAAM,QAAQ,GAAG,iBAAiB,CAAC,KAAK,CAAC,IAAI,CAAC,WAAW,CAAC,EAAE,KAAK,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC;IACtF,OAAO,GAAG,CAAA;iBACK,QAAQ,CAAC,EAAE;eACb,KAAK,CAAC,IAAI,CAAC,YAAY,CAAC,eAAe,CAAC;GACpD,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,qBAAqB,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\n\nimport {\n calculateFontSize,\n defaultThemeProp,\n StyledIcon,\n StyledText,\n useDirection\n} from '@pega/cosmos-react-core';\n\nexport const StyledStages = styled.div(props => {\n return css`\n background-color: ${props.theme.base.palette['primary-background']};\n border-radius: ${props.theme.base['border-radius']};\n width: 100%;\n `;\n});\n\nStyledStages.defaultProps = defaultThemeProp;\n\nexport const StyledInnerStage = styled.span<{ ellipsis?: boolean }>(props => {\n return css`\n display: inline-block;\n text-align: center;\n white-space: nowrap;\n ${props.ellipsis &&\n css`\n overflow: hidden;\n text-overflow: ellipsis;\n `}\n `;\n});\n\nexport const StyledStage = styled.button(\n ({\n theme: {\n base: {\n spacing,\n palette,\n 'hit-area': hitArea,\n shadow,\n transparency,\n 'border-radius': borderRadius\n }\n }\n }) => {\n const activeColor = palette.interactive;\n const baseBorderColor = palette['border-line'];\n const thinBorderWidth = '0.0625rem';\n const thickBorderWidth = '0.125rem';\n const baseTransparency = transparency['transparent-2'];\n const { rtl, start, end } = useDirection();\n\n return css`\n /* stylelint-disable no-descending-specificity */\n background-color: inherit;\n color: ${palette['foreground-color']};\n outline: none;\n border-color: transparent;\n border-width: ${thinBorderWidth} 0;\n border-style: solid;\n position: relative;\n height: calc(4 * ${spacing});\n min-width: calc(5.25 * ${spacing});\n padding-inline-start: calc(2 * ${spacing});\n padding-inline-end: ${spacing};\n\n @media (pointer: coarse) {\n height: ${hitArea['finger-min']};\n padding-inline-start: calc(2.25 * ${spacing});\n }\n\n ${StyledIcon} {\n margin-inline-end: 0.25rem;\n color: ${palette.success};\n\n &:last-child {\n margin-inline-end: 0;\n }\n }\n\n ${StyledInnerStage} {\n opacity: ${baseTransparency};\n }\n\n &:first-child {\n border-top-${start}-radius: ${borderRadius};\n border-bottom-${start}-radius: ${borderRadius};\n border-inline-start-width: ${thinBorderWidth};\n padding-inline-start: calc(${spacing});\n }\n\n &:last-child {\n border-top-${end}-radius: ${borderRadius};\n border-bottom-${end}-radius: ${borderRadius};\n border-inline-end-width: ${thinBorderWidth};\n padding-inline-end: calc(${spacing});\n min-width: calc(6.25 * ${spacing});\n }\n\n &:not(:first-child)::before {\n content: '';\n position: absolute;\n display: block;\n width: calc(2.25 * ${spacing});\n height: calc(2.25 * ${spacing});\n left: calc(-1.125 * ${spacing});\n right: calc(-1.125 * ${spacing});\n background-color: transparent;\n border-style: solid;\n border-color: ${baseBorderColor};\n border-inline-end-width: ${thinBorderWidth};\n border-inline-start-width: 0;\n border-top-width: ${rtl ? 0 : thinBorderWidth};\n border-bottom-width: ${rtl ? thinBorderWidth : 0};\n transform: rotateZ(45deg) skew(15deg, 15deg);\n\n @media (pointer: coarse) {\n width: calc(2.875 * ${spacing});\n height: calc(2.875 * ${spacing});\n left: calc(-1.375 * ${spacing});\n right: calc(-1.375 * ${spacing});\n transform: rotateZ(45deg) skew(20deg, 20deg);\n }\n }\n\n &:hover,\n &:hover::before {\n border-color: ${baseBorderColor};\n }\n\n &:hover {\n ${StyledInnerStage} {\n opacity: 1;\n }\n }\n\n &:focus,\n &:active,\n &:focus::before,\n &:active::before,\n &:focus + &::before,\n &:active + &::before {\n border-color: ${activeColor};\n }\n\n &:focus {\n border-width: ${thickBorderWidth} 0;\n }\n\n &:focus::before,\n &:focus + &::before {\n border-inline-end-width: ${thickBorderWidth};\n border-top-width: ${rtl ? 0 : thickBorderWidth};\n border-bottom-width: ${rtl ? thickBorderWidth : 0};\n }\n\n &:first-child:focus {\n border-inline-start-width: ${thickBorderWidth};\n padding-inline-start: calc(${spacing} - ${thickBorderWidth} + ${thinBorderWidth});\n }\n\n &:last-child:focus {\n border-inline-end-width: ${thickBorderWidth};\n padding-inline-end: calc(${spacing} - ${thinBorderWidth});\n }\n\n &:active {\n border-width: ${thinBorderWidth} 0;\n\n ${StyledInnerStage} {\n opacity: ${transparency['transparent-3']};\n }\n }\n\n &:active::before,\n &:active + &::before {\n border-inline-end-width: ${thinBorderWidth};\n border-top-width: ${rtl ? 0 : thinBorderWidth};\n border-bottom-width: ${rtl ? thinBorderWidth : 0};\n }\n\n &:first-child:active {\n border-inline-start-width: ${thinBorderWidth};\n padding-inline-start: calc(${spacing});\n }\n\n &:last-child:active {\n border-inline-end-width: ${thinBorderWidth};\n padding-inline-end: calc(${spacing});\n }\n\n &[aria-current] {\n z-index: 2;\n\n ${StyledInnerStage} {\n font-weight: bold;\n opacity: 1;\n }\n\n &:hover {\n ${StyledInnerStage} {\n opacity: ${baseTransparency};\n }\n }\n &:active {\n ${StyledInnerStage} {\n opacity: ${transparency['transparent-3']};\n }\n }\n }\n\n &[aria-current] + &::before {\n box-shadow: ${shadow.low};\n }\n\n &[aria-current] + &:focus::before {\n box-shadow: none;\n }\n `;\n }\n);\n\nStyledStage.defaultProps = defaultThemeProp;\n\nexport const StyledStagePopover = styled.div(({ theme }) => {\n return css`\n padding: calc(2 * ${theme.base.spacing});\n white-space: pre-line;\n width: 18rem;\n `;\n});\n\nStyledStagePopover.defaultProps = defaultThemeProp;\n\nexport const StyledStepsContainer = styled.ol(({ theme }) => {\n return css`\n list-style-type: none;\n margin-top: calc(1.5 * ${theme.base.spacing});\n margin-bottom: calc(2.5 * ${theme.base.spacing});\n\n &:empty {\n margin-bottom: 0;\n }\n `;\n});\n\nStyledStepsContainer.defaultProps = defaultThemeProp;\n\nexport const StyledStep = styled.li<{ complete: boolean }>(({ complete, theme }) => {\n const iconColor = complete ? theme.base.palette.success : theme.base.palette['foreground-color'];\n const iconWidth = complete ? '1.125rem' : '0.3rem';\n const iconMargin = complete ? 0 : '0.3rem';\n const textOpacity = complete ? theme.base.transparency['transparent-3'] : 1;\n\n return css`\n border-radius: 0;\n margin-bottom: calc(${theme.base.spacing});\n color: ${theme.base.palette['foreground-color']};\n\n &:last-child {\n margin-bottom: 0;\n }\n\n ${StyledIcon} {\n margin-inline-end: calc(${theme.base.spacing});\n color: ${iconColor};\n width: ${iconWidth};\n margin-inline-start: ${iconMargin};\n }\n\n ${StyledText} {\n opacity: ${textOpacity};\n }\n `;\n});\n\nStyledStep.defaultProps = defaultThemeProp;\n\nexport const StyledSteps = styled.div`\n background-color: ${props => props.theme.components.card.background};\n position: relative;\n`;\n\nStyledSteps.defaultProps = defaultThemeProp;\n\nexport const StyledInnerStep = styled.span<{ complete: boolean }>(({ complete, theme }) => {\n const textOpacity = complete ? theme.base.transparency['transparent-2'] : 1;\n return css`\n display: flex;\n width: 100%;\n text-align: start;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n\n ${StyledIcon} {\n color: ${theme.base.palette.success};\n margin-inline-end: ${theme.base.spacing};\n }\n\n ${StyledText} {\n opacity: ${textOpacity};\n }\n `;\n});\n\nStyledInnerStep.defaultProps = defaultThemeProp;\n\nexport const StyledDateTimeDisplay = styled.span(({ theme }) => {\n const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);\n return css`\n font-size: ${fontSize.xs};\n opacity: ${theme.base.transparency['transparent-2']};\n `;\n});\n\nStyledDateTimeDisplay.defaultProps = defaultThemeProp;\n"]}
1
+ {"version":3,"file":"Stages.styles.js","sourceRoot":"","sources":["../../../src/components/Stages/Stages.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,IAAI,IAAI,YAAY,EAAE,MAAM,UAAU,CAAC;AAEhD,OAAO,EACL,iBAAiB,EACjB,WAAW,EACX,eAAe,EACf,gBAAgB,EAChB,OAAO,EACP,UAAU,EACV,QAAQ,EACR,YAAY,EACb,MAAM,yBAAyB,CAAC;AAEjC,MAAM,CAAC,MAAM,YAAY,GAAG,MAAM,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE;IAC7C,OAAO,GAAG,CAAA;wBACY,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,oBAAoB,CAAC;qBACjD,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,eAAe,CAAC;;GAEnD,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,YAAY,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAE7C,MAAM,CAAC,MAAM,gBAAgB,GAAG,MAAM,CAAC,IAAI,CAAyB,KAAK,CAAC,EAAE;IAC1E,OAAO,GAAG,CAAA;;;;MAIN,KAAK,CAAC,QAAQ;QAChB,GAAG,CAAA;;;KAGF;GACF,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,WAAW,GAAG,MAA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AC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,kBAAkB,CAAC,CAChF,CAAC;IACF,MAAM,WAAW,GAAG,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,CAAC,YAAY,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IAE7E,OAAO,GAAG,CAAA;;0BAEc,KAAK,CAAC,IAAI,CAAC,OAAO;aAC/B,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,kBAAkB,CAAC;;;;;;;;;;;;;;;MAe7C,SAAS;QACX,GAAG,CAAA;;;+GAGwG,SAAS;0CAC9E,KAAK,CAAC,IAAI,CAAC,OAAO;;KAEvD;;;;iBAIY,WAAW;;GAEzB,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,UAAU,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAE3C,MAAM,CAAC,MAAM,oBAAoB,GAAG,MAAM,CAAC,WAAW,CAAC,CAAA;;CAEtD,CAAC;AAEF,oBAAoB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAErD,MAAM,CAAC,MAAM,qBAAqB,GAAG,MAAM,CAAC,eAAe,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IACzE,MAAM,QAAQ,GAAG,iBAAiB,CAAC,KAAK,CAAC,IAAI,CAAC,WAAW,CAAC,EAAE,KAAK,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC;IACtF,OAAO,GAAG,CAAA;iBACK,QAAQ,CAAC,EAAE;eACb,KAAK,CAAC,IAAI,CAAC,YAAY,CAAC,eAAe,CAAC;GACpD,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,qBAAqB,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\nimport { rgba as polishedRgba } from 'polished';\n\nimport {\n calculateFontSize,\n CardContent,\n DateTimeDisplay,\n defaultThemeProp,\n Popover,\n StyledIcon,\n tryCatch,\n useDirection\n} from '@pega/cosmos-react-core';\n\nexport const StyledStages = styled.div(props => {\n return css`\n background-color: ${props.theme.base.palette['primary-background']};\n border-radius: ${props.theme.base['border-radius']};\n width: 100%;\n `;\n});\n\nStyledStages.defaultProps = defaultThemeProp;\n\nexport const StyledInnerStage = styled.span<{ ellipsis?: boolean }>(props => {\n return css`\n display: inline-block;\n text-align: center;\n white-space: nowrap;\n ${props.ellipsis &&\n css`\n overflow: hidden;\n text-overflow: ellipsis;\n `}\n `;\n});\n\nexport const StyledStage = styled.button(\n ({\n theme: {\n base: { spacing, palette, 'hit-area': hitArea, transparency, 'border-radius': borderRadius }\n }\n }) => {\n const thinBorderWidth = '0.0625rem';\n const thickBorderWidth = '0.125rem';\n const { rtl } = useDirection();\n const borderShadow = tryCatch(() => polishedRgba(palette['border-line'], 1));\n\n return css`\n /* stylelint-disable no-descending-specificity */\n background-color: inherit;\n color: ${palette['foreground-color']};\n outline: none;\n border-color: transparent;\n border-width: ${thinBorderWidth} 0;\n border-style: solid;\n position: relative;\n height: calc(4 * ${spacing});\n min-width: calc(5.25 * ${spacing});\n padding-inline-start: calc(2 * ${spacing});\n padding-inline-end: ${spacing};\n\n @media (pointer: coarse) {\n height: ${hitArea['finger-min']};\n padding-inline-start: calc(2.25 * ${spacing});\n }\n\n ${StyledIcon} {\n color: ${palette.success};\n\n & ~ ${StyledInnerStage} {\n margin-inline-start: 0.25rem;\n }\n }\n\n ${StyledInnerStage} {\n opacity: ${transparency['transparent-2']};\n }\n\n &:first-of-type {\n border-start-start-radius: ${borderRadius};\n border-end-start-radius: ${borderRadius};\n border-inline-start-width: ${thinBorderWidth};\n padding-inline-start: ${spacing};\n\n &:active {\n padding-inline-start: ${spacing};\n }\n\n &:focus {\n border-inline-start-width: ${thickBorderWidth};\n padding-inline-start: calc(${spacing} - ${thickBorderWidth} + ${thinBorderWidth});\n }\n }\n\n &:last-of-type {\n border-start-end-radius: ${borderRadius};\n border-end-end-radius: ${borderRadius};\n border-inline-end-width: ${thinBorderWidth};\n padding-inline-end: ${spacing};\n min-width: calc(6.25 * ${spacing});\n\n &:active {\n border-inline-end-width: ${thinBorderWidth};\n padding-inline-end: ${spacing};\n }\n\n &:focus {\n border-inline-end-width: ${thickBorderWidth};\n padding-inline-end: calc(${spacing} - ${thinBorderWidth});\n }\n }\n\n &:not(:first-of-type)::before,\n &:not(:last-of-type)::after {\n content: '';\n position: absolute;\n display: block;\n width: calc(2.25 * ${spacing});\n height: calc(2.25 * ${spacing});\n background-color: transparent;\n border-style: solid;\n border-color: ${palette['border-line']};\n border-inline-end-width: ${thinBorderWidth};\n border-inline-start-width: 0;\n border-top-width: ${rtl ? 0 : thinBorderWidth};\n border-bottom-width: ${rtl ? thinBorderWidth : 0};\n transform: rotateZ(45deg) skew(15deg, 15deg);\n\n @media (pointer: coarse) {\n width: calc(2.875 * ${spacing});\n height: calc(2.875 * ${spacing});\n transform: rotateZ(45deg) skew(20deg, 20deg);\n }\n }\n\n &:not(:first-of-type)::before {\n inset-inline-start: calc(-1.125 * ${spacing});\n\n @media (pointer: coarse) {\n inset-inline-start: calc(-1.375 * ${spacing});\n }\n }\n\n &:not(:last-of-type)::after {\n inset-inline-end: calc(-1.125 * ${spacing});\n z-index: 1;\n\n @media (pointer: coarse) {\n inset-inline-end: calc(-1.375 * ${spacing});\n }\n }\n\n &:hover,\n &:hover::before,\n &:hover::after {\n border-color: ${palette['border-line']};\n }\n\n &:focus,\n &:active,\n &:focus::before,\n &:active::before,\n &:focus::after,\n &:active::after {\n border-color: ${palette.interactive};\n }\n\n &:focus {\n border-width: ${thickBorderWidth} 0;\n }\n\n &:focus::before,\n &:focus::after {\n z-index: 1;\n border-inline-end-width: ${thickBorderWidth};\n border-top-width: ${rtl ? 0 : thickBorderWidth};\n border-bottom-width: ${rtl ? thickBorderWidth : 0};\n }\n\n &:focus::before {\n pointer-events: none;\n }\n\n &:active {\n border-width: ${thinBorderWidth} 0;\n\n ${StyledInnerStage} {\n opacity: ${transparency['transparent-3']};\n }\n }\n\n &:active::before,\n &:active::after {\n border-inline-end-width: ${thinBorderWidth};\n border-top-width: ${rtl ? 0 : thinBorderWidth};\n border-bottom-width: ${rtl ? thinBorderWidth : 0};\n }\n\n &[aria-current] {\n ${StyledInnerStage} {\n font-weight: bold;\n opacity: 1;\n }\n\n &:hover {\n ${StyledInnerStage} {\n opacity: ${transparency['transparent-2']};\n }\n }\n }\n\n &[aria-current]::after {\n filter: drop-shadow(0.0625rem -0.0625rem 0.125rem ${borderShadow});\n }\n `;\n }\n);\n\nStyledStage.defaultProps = defaultThemeProp;\n\nexport const StyledStagePopover = styled(Popover)`\n width: 36ch;\n`;\n\nStyledStagePopover.defaultProps = defaultThemeProp;\n\nexport const StyledStepsContainer = styled.ol(({ theme }) => {\n return css`\n list-style-type: none;\n margin: calc(1.5 * ${theme.base.spacing}) 0;\n\n &:empty {\n margin-bottom: 0;\n }\n `;\n});\n\nStyledStepsContainer.defaultProps = defaultThemeProp;\n\nexport const StyledStep = styled.li<{ completed: boolean }>(({ completed, theme }) => {\n const iconColor = encodeURIComponent(\n completed ? theme.base.palette.success : theme.base.palette['foreground-color']\n );\n const textOpacity = completed ? theme.base.transparency['transparent-2'] : 1;\n\n return css`\n border-radius: 0;\n margin-bottom: calc(${theme.base.spacing});\n color: ${theme.base.palette['foreground-color']};\n\n &:last-child {\n margin-bottom: 0;\n }\n\n /* stylelint-disable no-duplicate-selectors */\n &::before {\n content: '\\u00b7';\n font-weight: 800;\n width: 1rem;\n text-align: center;\n flex-shrink: 0;\n }\n\n ${completed &&\n css`\n &::before {\n /* cSpell:disable-next-line */\n content: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 25 25' fill='${iconColor}'%3E%3Cpath d='M3.5328125,10.8960938 C3.5328125,10.8960938 10.0460938,17.3617188 10.0460938,17.3617188 C10.0460938,17.3617188 22.4984375,4 22.4984375,4 C22.4984375,4 23.9828125,5.484375 23.9828125,5.484375 C23.9828125,5.484375 10.09375,20.2351562 10.09375,20.2351562 C10.09375,20.2351562 2,12.3804687 2,12.3804687 C2,12.3804687 3.5328125,10.8960937 3.5328125,10.8960937 L3.5328125,10.8960938 Z'/%3E%3C/svg%3E\");\n margin-block-start: calc(0.25 * ${theme.base.spacing});\n }\n `}\n /* stylelint-enable no-duplicate-selectors */\n\n div {\n opacity: ${textOpacity};\n }\n `;\n});\n\nStyledStep.defaultProps = defaultThemeProp;\n\nexport const StyledPopoverContent = styled(CardContent)`\n min-height: 6rem;\n`;\n\nStyledPopoverContent.defaultProps = defaultThemeProp;\n\nexport const StyledDateTimeDisplay = styled(DateTimeDisplay)(({ theme }) => {\n const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);\n return css`\n font-size: ${fontSize.xs};\n opacity: ${theme.base.transparency['transparent-2']};\n `;\n});\n\nStyledDateTimeDisplay.defaultProps = defaultThemeProp;\n"]}
@@ -1,16 +1,23 @@
1
- import { ReactNode } from 'react';
1
+ import { ReactNode, Ref } from 'react';
2
2
  import { BaseProps, NoChildrenProp } from '@pega/cosmos-react-core';
3
3
  export interface StepProps {
4
+ /** Step name - either text or link. */
4
5
  name: ReactNode;
5
- complete: boolean;
6
+ /** Flag determining whether step has been completed. */
7
+ completed: boolean;
8
+ /** Unique step identifier. */
6
9
  id: string;
7
10
  }
8
11
  export interface StageProps {
12
+ /** Stage name. */
9
13
  name: string;
14
+ /** Unique identifier. */
10
15
  id: string;
16
+ /** Date of completion. Accepts date object, ISO string or timestamp. */
11
17
  date?: Date | string | number;
12
- required: boolean;
13
- complete: boolean;
18
+ /** Flag determining whether the stage is completed. */
19
+ completed: boolean;
20
+ /** Steps data defined in this stage. The stage is treated as not loaded if undefined. */
14
21
  steps?: StepProps[];
15
22
  }
16
23
  export interface StagesProps extends BaseProps, NoChildrenProp {
@@ -18,6 +25,14 @@ export interface StagesProps extends BaseProps, NoChildrenProp {
18
25
  stages: StageProps[];
19
26
  /** Current stage id. */
20
27
  current: string;
28
+ /** Case title (label) */
21
29
  caseTitle?: string;
30
+ /**
31
+ * Callback invoked when stage details are requested to show.
32
+ * @param stages stages' ids requested to load details for.
33
+ */
34
+ onLoadStage?: (stages: StageProps['id'][]) => void;
35
+ /** Ref to the stages container. */
36
+ ref?: Ref<HTMLDivElement>;
22
37
  }
23
38
  //# sourceMappingURL=Stages.types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Stages.types.d.ts","sourceRoot":"","sources":["../../../src/components/Stages/Stages.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAElC,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAEpE,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,SAAS,CAAC;IAChB,QAAQ,EAAE,OAAO,CAAC;IAClB,EAAE,EAAE,MAAM,CAAC;CACZ;AAED,MAAM,WAAW,UAAU;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,CAAC,EAAE,IAAI,GAAG,MAAM,GAAG,MAAM,CAAC;IAC9B,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;IAClB,KAAK,CAAC,EAAE,SAAS,EAAE,CAAC;CACrB;AAED,MAAM,WAAW,WAAY,SAAQ,SAAS,EAAE,cAAc;IAC5D,6DAA6D;IAC7D,MAAM,EAAE,UAAU,EAAE,CAAC;IACrB,wBAAwB;IACxB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB"}
1
+ {"version":3,"file":"Stages.types.d.ts","sourceRoot":"","sources":["../../../src/components/Stages/Stages.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAEvC,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAEpE,MAAM,WAAW,SAAS;IACxB,uCAAuC;IACvC,IAAI,EAAE,SAAS,CAAC;IAChB,wDAAwD;IACxD,SAAS,EAAE,OAAO,CAAC;IACnB,8BAA8B;IAC9B,EAAE,EAAE,MAAM,CAAC;CACZ;AAED,MAAM,WAAW,UAAU;IACzB,kBAAkB;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,yBAAyB;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,wEAAwE;IACxE,IAAI,CAAC,EAAE,IAAI,GAAG,MAAM,GAAG,MAAM,CAAC;IAC9B,uDAAuD;IACvD,SAAS,EAAE,OAAO,CAAC;IACnB,yFAAyF;IACzF,KAAK,CAAC,EAAE,SAAS,EAAE,CAAC;CACrB;AAED,MAAM,WAAW,WAAY,SAAQ,SAAS,EAAE,cAAc;IAC5D,6DAA6D;IAC7D,MAAM,EAAE,UAAU,EAAE,CAAC;IACrB,wBAAwB;IACxB,OAAO,EAAE,MAAM,CAAC;IAChB,yBAAyB;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,WAAW,CAAC,EAAE,CAAC,MAAM,EAAE,UAAU,CAAC,IAAI,CAAC,EAAE,KAAK,IAAI,CAAC;IACnD,mCAAmC;IACnC,GAAG,CAAC,EAAE,GAAG,CAAC,cAAc,CAAC,CAAC;CAC3B"}
@@ -1 +1 @@
1
- {"version":3,"file":"Stages.types.js","sourceRoot":"","sources":["../../../src/components/Stages/Stages.types.ts"],"names":[],"mappings":"","sourcesContent":["import { ReactNode } from 'react';\n\nimport { BaseProps, NoChildrenProp } from '@pega/cosmos-react-core';\n\nexport interface StepProps {\n name: ReactNode;\n complete: boolean;\n id: string;\n}\n\nexport interface StageProps {\n name: string;\n id: string;\n date?: Date | string | number;\n required: boolean;\n complete: boolean;\n steps?: StepProps[];\n}\n\nexport interface StagesProps extends BaseProps, NoChildrenProp {\n /** List of objects describing each stage and their state. */\n stages: StageProps[];\n /** Current stage id. */\n current: string;\n caseTitle?: string;\n}\n"]}
1
+ {"version":3,"file":"Stages.types.js","sourceRoot":"","sources":["../../../src/components/Stages/Stages.types.ts"],"names":[],"mappings":"","sourcesContent":["import { ReactNode, Ref } from 'react';\n\nimport { BaseProps, NoChildrenProp } from '@pega/cosmos-react-core';\n\nexport interface StepProps {\n /** Step name - either text or link. */\n name: ReactNode;\n /** Flag determining whether step has been completed. */\n completed: boolean;\n /** Unique step identifier. */\n id: string;\n}\n\nexport interface StageProps {\n /** Stage name. */\n name: string;\n /** Unique identifier. */\n id: string;\n /** Date of completion. Accepts date object, ISO string or timestamp. */\n date?: Date | string | number;\n /** Flag determining whether the stage is completed. */\n completed: boolean;\n /** Steps data defined in this stage. The stage is treated as not loaded if undefined. */\n steps?: StepProps[];\n}\n\nexport interface StagesProps extends BaseProps, NoChildrenProp {\n /** List of objects describing each stage and their state. */\n stages: StageProps[];\n /** Current stage id. */\n current: string;\n /** Case title (label) */\n caseTitle?: string;\n /**\n * Callback invoked when stage details are requested to show.\n * @param stages stages' ids requested to load details for.\n */\n onLoadStage?: (stages: StageProps['id'][]) => void;\n /** Ref to the stages container. */\n ref?: Ref<HTMLDivElement>;\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"Timeline.styles.d.ts","sourceRoot":"","sources":["../../../src/components/Timeline/Timeline.styles.ts"],"names":[],"mappings":"AAiBA,eAAO,MAAM,UAAU,mOASrB,CAAC;AAIH,eAAO,MAAM,iBAAiB,0OAU5B,CAAC;AAIH,eAAO,MAAM,kBAAkB;eAA+B,OAAO;SAOnE,CAAC;AAIH,eAAO,MAAM,gBAAgB,mOAM5B,CAAC;AAIF,eAAO,MAAM,kBAAkB,mOAU7B,CAAC;AAIH,UAAU,wBAAwB;IAChC,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;IACjB,YAAY,EAAE,OAAO,CAAC;IACtB,YAAY,EAAE,OAAO,CAAC;IACtB,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,eAAO,MAAM,mBAAmB,8HA4D/B,CAAC;AAIF,eAAO,MAAM,mBAAmB,2GA+B9B,CAAC;AAIH,eAAO,MAAM,UAAU,8OAetB,CAAC;AAIF,eAAO,MAAM,iBAAiB,wGAQ5B,CAAC;AAIH,eAAO,MAAM,UAAU,8OAKrB,CAAC;AAIH,eAAO,MAAM,iBAAiB,wGAO7B,CAAC"}
1
+ {"version":3,"file":"Timeline.styles.d.ts","sourceRoot":"","sources":["../../../src/components/Timeline/Timeline.styles.ts"],"names":[],"mappings":"AAiBA,eAAO,MAAM,UAAU,mOASrB,CAAC;AAIH,eAAO,MAAM,iBAAiB,0OAU5B,CAAC;AAIH,eAAO,MAAM,kBAAkB;eAA+B,OAAO;SAOnE,CAAC;AAIH,eAAO,MAAM,gBAAgB,mOAM5B,CAAC;AAIF,eAAO,MAAM,kBAAkB,mOAU7B,CAAC;AAIH,UAAU,wBAAwB;IAChC,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;IACjB,YAAY,EAAE,OAAO,CAAC;IACtB,YAAY,EAAE,OAAO,CAAC;IACtB,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,eAAO,MAAM,mBAAmB,8HA6D/B,CAAC;AAIF,eAAO,MAAM,mBAAmB,2GA+B9B,CAAC;AAIH,eAAO,MAAM,UAAU,8OAetB,CAAC;AAIF,eAAO,MAAM,iBAAiB,wGAQ5B,CAAC;AAIH,eAAO,MAAM,UAAU,8OAKrB,CAAC;AAIH,eAAO,MAAM,iBAAiB,wGAO7B,CAAC"}
@@ -58,6 +58,7 @@ export const StyledBulletWrapper = styled.td(({ theme, hasPrev, hasNext, isPrevF
58
58
  position: relative;
59
59
  text-align: center;
60
60
  padding-top: calc(2.25 * ${theme.base.spacing} + 0.0625rem);
61
+ min-width: 2rem;
61
62
 
62
63
  ${hasPrev &&
63
64
  css `
@@ -1 +1 @@
1
- {"version":3,"file":"Timeline.styles.js","sourceRoot":"","sources":["../../../src/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A;;;;IAItC,cAAc;;;CAGjB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\n\nimport {\n Button,\n calculateFontSize,\n Card,\n CardContent,\n DateTimeDisplay,\n defaultThemeProp,\n Flex,\n FontSize,\n Grid,\n StyledBackdrop,\n StyledIcon,\n useDirection\n} from '@pega/cosmos-react-core';\n\nexport const StyledCard = styled(Card)(({ theme }) => {\n return css`\n border-top: 0.0625rem solid ${theme.base.colors.slate.light};\n padding: ${theme.base.spacing} 0;\n &:not(& &) {\n border-radius: 0;\n background-color: transparent;\n }\n `;\n});\n\nStyledCard.defaultProps = defaultThemeProp;\n\nexport const StyledCardContent = styled(CardContent)(({ theme }) => {\n return css`\n &:not(${StyledCard} ${StyledCard} > &) {\n padding: ${theme.base.spacing} 0;\n padding-inline-start: ${theme.base['hit-area']['mouse-min']};\n @media (pointer: coarse) {\n padding-inline-start: ${theme.base['hit-area']['finger-min']};\n }\n }\n `;\n});\n\nStyledCardContent.defaultProps = defaultThemeProp;\n\nexport const StyledToggleButton = styled(Button)<{ collapsed: boolean }>(({ theme, collapsed }) => {\n return css`\n transition: transform calc(2 * ${theme.base.animation.speed})\n ${theme.base.animation.timing.ease};\n transform: ${collapsed ? 'rotate(-90deg)' : 'rotate(0)'};\n color: ${theme.components.button.color};\n `;\n});\n\nStyledToggleButton.defaultProps = defaultThemeProp;\n\nexport const StyledCardHeader = styled(Grid)`\n padding: 0;\n min-height: 2rem;\n ${StyledToggleButton} {\n align-self: start;\n }\n`;\n\nStyledCardHeader.defaultProps = defaultThemeProp;\n\nexport const StyledTimelineIcon = styled(Flex)(({ theme }) => {\n return css`\n border-radius: 50%;\n color: ${theme.base.palette.light};\n background: ${theme.base.palette.info};\n & > ${StyledIcon} {\n height: 1em;\n width: 1em;\n }\n `;\n});\n\nStyledTimelineIcon.defaultProps = defaultThemeProp;\n\ninterface StyledBulletWrapperProps {\n hasPrev: boolean;\n hasNext: boolean;\n isPrevFuture: boolean;\n isNextFuture: boolean;\n hasIcon: boolean;\n}\n\nexport const StyledBulletWrapper = styled.td<StyledBulletWrapperProps>(\n ({ theme, hasPrev, hasNext, isPrevFuture, isNextFuture, hasIcon }) => {\n const { rtl } = useDirection();\n return css`\n position: relative;\n text-align: center;\n padding-top: calc(2.25 * ${theme.base.spacing} + 0.0625rem);\n\n ${hasPrev &&\n css`\n &::before {\n content: '';\n display: block;\n position: absolute;\n top: 0;\n inset-inline-start: 50%;\n transform: translateX(${rtl ? '50%' : '-50%'});\n width: 0.0625rem;\n height: calc(2.25 * ${theme.base.spacing} + 0.75rem);\n border-inline-start: 0.0625rem ${isPrevFuture ? 'dashed' : 'solid'}\n ${theme.base.palette.info};\n }\n `}\n\n ${hasNext &&\n css`\n &::after {\n content: '';\n display: block;\n position: absolute;\n top: calc(2.25 * ${theme.base.spacing} + 0.75rem);\n inset-inline-start: 50%;\n transform: translateX(${rtl ? '50%' : '-50%'});\n width: 0.0625rem;\n height: calc(100% - 2.25 * ${theme.base.spacing} - 0.75rem);\n border-inline-start: 0.0625rem ${isNextFuture ? 'dashed' : 'solid'}\n ${theme.base.palette.info};\n }\n `}\n\n & > ${StyledTimelineIcon} {\n position: relative;\n margin: 0;\n z-index: 1;\n width: ${hasIcon ? '1.5rem' : '0.5rem'};\n height: ${hasIcon ? '1.5rem' : '0.5rem'};\n }\n\n @media (min-width: ${theme.base.breakpoints.sm}) {\n padding-top: calc(${theme.base.spacing} + 0.0625rem);\n &::before {\n height: calc(${theme.base.spacing} + 0.75rem);\n }\n &::after {\n top: calc(${theme.base.spacing} + 0.75rem);\n height: calc(100% - ${theme.base.spacing} - 0.75rem);\n }\n }\n `;\n }\n);\n\nStyledBulletWrapper.defaultProps = defaultThemeProp;\n\nexport const StyledTimelineTable = styled.table(({ theme }) => {\n return css`\n tr {\n td {\n border-inline-start: ${theme.base.spacing} solid transparent;\n border-inline-end: ${theme.base.spacing} solid transparent;\n vertical-align: top;\n }\n td:first-child {\n border-inline-start: none;\n }\n\n td:last-child {\n border-inline-end: none;\n }\n }\n border-collapse: collapse;\n width: 100%;\n @media (min-width: ${theme.base.breakpoints.sm}) {\n column-gap: ${theme.base.spacing};\n tr {\n td {\n border-inline-start: calc(0.5 * ${theme.base.spacing}) solid transparent;\n border-inline-end: calc(0.5 * ${theme.base.spacing}) solid transparent;\n }\n }\n ${StyledCard} {\n padding: calc(0.5 * ${theme.base.spacing}) 0;\n }\n }\n `;\n});\n\nStyledTimelineTable.defaultProps = defaultThemeProp;\n\nexport const StyledDate = styled(DateTimeDisplay)(\n ({\n theme: {\n base: { 'font-size': fontSize, 'font-scale': fontScale, spacing },\n components: { text }\n }\n }) => {\n const fontSizes = calculateFontSize(fontSize, fontScale);\n return css`\n display: block;\n padding: calc(3 * ${spacing}) 0 calc(1.25 * ${spacing});\n font-size: ${fontSizes[text.h2['font-size'] as FontSize]};\n font-weight: ${text.h2['font-weight']};\n `;\n }\n);\n\nStyledDate.defaultProps = defaultThemeProp;\n\nexport const StyledTimeWrapper = styled.td(({ theme }) => {\n return css`\n @media (min-width: ${theme.base.breakpoints.sm}) {\n text-align: end;\n line-height: ${theme.base['hit-area']['mouse-min']};\n padding-top: calc(0.5 * ${theme.base.spacing} + 0.0625rem);\n }\n `;\n});\n\nStyledTimeWrapper.defaultProps = defaultThemeProp;\n\nexport const StyledTime = styled(DateTimeDisplay)(({ theme }) => {\n return css`\n opacity: ${theme.base.transparency['transparent-2']};\n white-space: nowrap;\n `;\n});\n\nStyledTime.defaultProps = defaultThemeProp;\n\nexport const StyledLoadingCell = styled.td`\n position: relative;\n height: 2.8rem;\n\n ${StyledBackdrop} {\n background: transparent;\n }\n`;\n"]}
1
+ {"version":3,"file":"Timeline.styles.js","sourceRoot":"","sources":["../../../src/components/Timeline/Timeline.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,EACL,MAAM,EACN,iBAAiB,EACjB,IAAI,EACJ,WAAW,EACX,eAAe,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E,OAAO,EAAE,EACjE,UAAU,EAAE,EAAE,IAAI,EAAE,EACrB,EACF,EAAE,EAAE;IACH,MAAM,SAAS,GAAG,iBAAiB,CAAC,QAAQ,EAAE,SAAS,CAAC,CAAC;IACzD,OAAO,GAAG,CAAA;;0BAEY,OAAO,mBAAmB,OAAO;mBACxC,SAAS,CAAC,IAAI,CAAC,EAAE,CAAC,WAAW,CAAa,CAAC;qBACzC,IAAI,CAAC,EAAE,CAAC,aAAa,CAAC;KACtC,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,UAAU,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAE3C,MAAM,CAAC,MAAM,iBAAiB,GAAG,MAAM,CAAC,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IACvD,OAAO,GAAG,CAAA;yBACa,KAAK,CAAC,IAAI,CAAC,WAAW,CAAC,EAAE;;qBAE7B,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,WAAW,CAAC;gCACxB,KAAK,CAAC,IAAI,CAAC,OAAO;;GAE/C,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,iBAAiB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAElD,MAAM,CAAC,MAAM,UAAU,GAAG,MAAM,CAAC,eAAe,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IAC9D,OAAO,GAAG,CAAA;eACG,KAAK,CAAC,IAAI,CAAC,YAAY,CAAC,eAAe,CAAC;;GAEpD,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,UAAU,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAE3C,MAAM,CAAC,MAAM,iBAAiB,GAAG,MAAM,CAAC,EAAE,CAAA;;;;IAItC,cAAc;;;CAGjB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\n\nimport {\n Button,\n calculateFontSize,\n Card,\n CardContent,\n DateTimeDisplay,\n defaultThemeProp,\n Flex,\n FontSize,\n Grid,\n StyledBackdrop,\n StyledIcon,\n useDirection\n} from '@pega/cosmos-react-core';\n\nexport const StyledCard = styled(Card)(({ theme }) => {\n return css`\n border-top: 0.0625rem solid ${theme.base.colors.slate.light};\n padding: ${theme.base.spacing} 0;\n &:not(& &) {\n border-radius: 0;\n background-color: transparent;\n }\n `;\n});\n\nStyledCard.defaultProps = defaultThemeProp;\n\nexport const StyledCardContent = styled(CardContent)(({ theme }) => {\n return css`\n &:not(${StyledCard} ${StyledCard} > &) {\n padding: ${theme.base.spacing} 0;\n padding-inline-start: ${theme.base['hit-area']['mouse-min']};\n @media (pointer: coarse) {\n padding-inline-start: ${theme.base['hit-area']['finger-min']};\n }\n }\n `;\n});\n\nStyledCardContent.defaultProps = defaultThemeProp;\n\nexport const StyledToggleButton = styled(Button)<{ collapsed: boolean }>(({ theme, collapsed }) => {\n return css`\n transition: transform calc(2 * ${theme.base.animation.speed})\n ${theme.base.animation.timing.ease};\n transform: ${collapsed ? 'rotate(-90deg)' : 'rotate(0)'};\n color: ${theme.components.button.color};\n `;\n});\n\nStyledToggleButton.defaultProps = defaultThemeProp;\n\nexport const StyledCardHeader = styled(Grid)`\n padding: 0;\n min-height: 2rem;\n ${StyledToggleButton} {\n align-self: start;\n }\n`;\n\nStyledCardHeader.defaultProps = defaultThemeProp;\n\nexport const StyledTimelineIcon = styled(Flex)(({ theme }) => {\n return css`\n border-radius: 50%;\n color: ${theme.base.palette.light};\n background: ${theme.base.palette.info};\n & > ${StyledIcon} {\n height: 1em;\n width: 1em;\n }\n `;\n});\n\nStyledTimelineIcon.defaultProps = defaultThemeProp;\n\ninterface StyledBulletWrapperProps {\n hasPrev: boolean;\n hasNext: boolean;\n isPrevFuture: boolean;\n isNextFuture: boolean;\n hasIcon: boolean;\n}\n\nexport const StyledBulletWrapper = styled.td<StyledBulletWrapperProps>(\n ({ theme, hasPrev, hasNext, isPrevFuture, isNextFuture, hasIcon }) => {\n const { rtl } = useDirection();\n return css`\n position: relative;\n text-align: center;\n padding-top: calc(2.25 * ${theme.base.spacing} + 0.0625rem);\n min-width: 2rem;\n\n ${hasPrev &&\n css`\n &::before {\n content: '';\n display: block;\n position: absolute;\n top: 0;\n inset-inline-start: 50%;\n transform: translateX(${rtl ? '50%' : '-50%'});\n width: 0.0625rem;\n height: calc(2.25 * ${theme.base.spacing} + 0.75rem);\n border-inline-start: 0.0625rem ${isPrevFuture ? 'dashed' : 'solid'}\n ${theme.base.palette.info};\n }\n `}\n\n ${hasNext &&\n css`\n &::after {\n content: '';\n display: block;\n position: absolute;\n top: calc(2.25 * ${theme.base.spacing} + 0.75rem);\n inset-inline-start: 50%;\n transform: translateX(${rtl ? '50%' : '-50%'});\n width: 0.0625rem;\n height: calc(100% - 2.25 * ${theme.base.spacing} - 0.75rem);\n border-inline-start: 0.0625rem ${isNextFuture ? 'dashed' : 'solid'}\n ${theme.base.palette.info};\n }\n `}\n\n & > ${StyledTimelineIcon} {\n position: relative;\n margin: 0;\n z-index: 1;\n width: ${hasIcon ? '1.5rem' : '0.5rem'};\n height: ${hasIcon ? '1.5rem' : '0.5rem'};\n }\n\n @media (min-width: ${theme.base.breakpoints.sm}) {\n padding-top: calc(${theme.base.spacing} + 0.0625rem);\n &::before {\n height: calc(${theme.base.spacing} + 0.75rem);\n }\n &::after {\n top: calc(${theme.base.spacing} + 0.75rem);\n height: calc(100% - ${theme.base.spacing} - 0.75rem);\n }\n }\n `;\n }\n);\n\nStyledBulletWrapper.defaultProps = defaultThemeProp;\n\nexport const StyledTimelineTable = styled.table(({ theme }) => {\n return css`\n tr {\n td {\n border-inline-start: ${theme.base.spacing} solid transparent;\n border-inline-end: ${theme.base.spacing} solid transparent;\n vertical-align: top;\n }\n td:first-child {\n border-inline-start: none;\n }\n\n td:last-child {\n border-inline-end: none;\n }\n }\n border-collapse: collapse;\n width: 100%;\n @media (min-width: ${theme.base.breakpoints.sm}) {\n column-gap: ${theme.base.spacing};\n tr {\n td {\n border-inline-start: calc(0.5 * ${theme.base.spacing}) solid transparent;\n border-inline-end: calc(0.5 * ${theme.base.spacing}) solid transparent;\n }\n }\n ${StyledCard} {\n padding: calc(0.5 * ${theme.base.spacing}) 0;\n }\n }\n `;\n});\n\nStyledTimelineTable.defaultProps = defaultThemeProp;\n\nexport const StyledDate = styled(DateTimeDisplay)(\n ({\n theme: {\n base: { 'font-size': fontSize, 'font-scale': fontScale, spacing },\n components: { text }\n }\n }) => {\n const fontSizes = calculateFontSize(fontSize, fontScale);\n return css`\n display: block;\n padding: calc(3 * ${spacing}) 0 calc(1.25 * ${spacing});\n font-size: ${fontSizes[text.h2['font-size'] as FontSize]};\n font-weight: ${text.h2['font-weight']};\n `;\n }\n);\n\nStyledDate.defaultProps = defaultThemeProp;\n\nexport const StyledTimeWrapper = styled.td(({ theme }) => {\n return css`\n @media (min-width: ${theme.base.breakpoints.sm}) {\n text-align: end;\n line-height: ${theme.base['hit-area']['mouse-min']};\n padding-top: calc(0.5 * ${theme.base.spacing} + 0.0625rem);\n }\n `;\n});\n\nStyledTimeWrapper.defaultProps = defaultThemeProp;\n\nexport const StyledTime = styled(DateTimeDisplay)(({ theme }) => {\n return css`\n opacity: ${theme.base.transparency['transparent-2']};\n white-space: nowrap;\n `;\n});\n\nStyledTime.defaultProps = defaultThemeProp;\n\nexport const StyledLoadingCell = styled.td`\n position: relative;\n height: 2.8rem;\n\n ${StyledBackdrop} {\n background: transparent;\n }\n`;\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pega/cosmos-react-work",
3
- "version": "3.0.0-dev.12.0",
3
+ "version": "3.0.0-dev.15.0",
4
4
  "author": "Pegasystems",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "repository": {
@@ -20,7 +20,7 @@
20
20
  "build": "tsc -b"
21
21
  },
22
22
  "dependencies": {
23
- "@pega/cosmos-react-core": "3.0.0-dev.12.0",
23
+ "@pega/cosmos-react-core": "3.0.0-dev.15.0",
24
24
  "@types/react": "^16.14.24 || ^17.0.38",
25
25
  "@types/react-dom": "^16.9.14 || ^17.0.11",
26
26
  "@types/styled-components": "^5.1.7",
@@ -38,6 +38,9 @@
38
38
  "@storybook/react": "^6.4.19",
39
39
  "@storybook/testing-react": "^1.2.4",
40
40
  "@storybook/theming": "^6.4.19",
41
+ "@testing-library/jest-dom": "^5.16.2",
42
+ "@testing-library/react": "^12.1.3",
43
+ "@testing-library/user-event": "^13.5.0",
41
44
  "enzyme": "^3.11.0",
42
45
  "typescript": "~4.6.2"
43
46
  }