@cloudscape-design/components-themeable 3.0.514 → 3.0.515
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/internal/manifest.json +1 -1
- package/lib/internal/scss/app-layout/visual-refresh/mobile-toolbar.scss +5 -1
- package/lib/internal/scss/app-layout/visual-refresh/trigger-button.scss +4 -1
- package/lib/internal/scss/cards/styles.scss +7 -0
- package/lib/internal/scss/container/styles.scss +18 -0
- package/lib/internal/scss/wizard/styles.scss +22 -8
- package/lib/internal/template/app-layout/visual-refresh/mobile-toolbar.d.ts.map +1 -1
- package/lib/internal/template/app-layout/visual-refresh/mobile-toolbar.js +2 -1
- package/lib/internal/template/app-layout/visual-refresh/mobile-toolbar.js.map +1 -1
- package/lib/internal/template/app-layout/visual-refresh/styles.css.js +81 -80
- package/lib/internal/template/app-layout/visual-refresh/styles.scoped.css +177 -171
- package/lib/internal/template/app-layout/visual-refresh/styles.selectors.js +81 -80
- package/lib/internal/template/app-layout/visual-refresh/trigger-button.d.ts.map +1 -1
- package/lib/internal/template/app-layout/visual-refresh/trigger-button.js +2 -1
- package/lib/internal/template/app-layout/visual-refresh/trigger-button.js.map +1 -1
- package/lib/internal/template/cards/index.d.ts.map +1 -1
- package/lib/internal/template/cards/index.js +3 -2
- package/lib/internal/template/cards/index.js.map +1 -1
- package/lib/internal/template/cards/styles.css.js +40 -39
- package/lib/internal/template/cards/styles.scoped.css +52 -49
- package/lib/internal/template/cards/styles.selectors.js +40 -39
- package/lib/internal/template/container/internal.d.ts.map +1 -1
- package/lib/internal/template/container/internal.js +3 -2
- package/lib/internal/template/container/internal.js.map +1 -1
- package/lib/internal/template/container/styles.css.js +30 -29
- package/lib/internal/template/container/styles.scoped.css +65 -52
- package/lib/internal/template/container/styles.selectors.js +30 -29
- package/lib/internal/template/internal/environment.js +1 -1
- package/lib/internal/template/internal/environment.json +1 -1
- package/lib/internal/template/internal/utils/content-header-utils.d.ts +1 -0
- package/lib/internal/template/internal/utils/content-header-utils.d.ts.map +1 -1
- package/lib/internal/template/internal/utils/content-header-utils.js +2 -3
- package/lib/internal/template/internal/utils/content-header-utils.js.map +1 -1
- package/lib/internal/template/wizard/internal.d.ts.map +1 -1
- package/lib/internal/template/wizard/internal.js +3 -2
- package/lib/internal/template/wizard/internal.js.map +1 -1
- package/lib/internal/template/wizard/styles.css.js +32 -31
- package/lib/internal/template/wizard/styles.scoped.css +76 -65
- package/lib/internal/template/wizard/styles.selectors.js +32 -31
- package/lib/internal/template/wizard/wizard-form-header.d.ts.map +1 -1
- package/lib/internal/template/wizard/wizard-form-header.js +2 -1
- package/lib/internal/template/wizard/wizard-form-header.js.map +1 -1
- package/lib/internal/template/wizard/wizard-navigation.d.ts.map +1 -1
- package/lib/internal/template/wizard/wizard-navigation.js +3 -2
- package/lib/internal/template/wizard/wizard-navigation.js.map +1 -1
- package/package.json +1 -1
|
@@ -94,7 +94,7 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
94
94
|
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
95
95
|
SPDX-License-Identifier: Apache-2.0
|
|
96
96
|
*/
|
|
97
|
-
.
|
|
97
|
+
.awsui_root_14iqq_1r6ed_97:not(#\9) {
|
|
98
98
|
border-collapse: separate;
|
|
99
99
|
border-spacing: 0;
|
|
100
100
|
box-sizing: border-box;
|
|
@@ -131,23 +131,23 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
131
131
|
word-wrap: break-word;
|
|
132
132
|
position: relative;
|
|
133
133
|
}
|
|
134
|
-
.
|
|
134
|
+
.awsui_root_14iqq_1r6ed_97.awsui_fit-height_14iqq_1r6ed_133:not(#\9) {
|
|
135
135
|
display: flex;
|
|
136
136
|
flex-direction: column;
|
|
137
137
|
height: 100%;
|
|
138
138
|
}
|
|
139
|
-
.
|
|
139
|
+
.awsui_root_14iqq_1r6ed_97.awsui_fit-height_14iqq_1r6ed_133.awsui_with-side-media_14iqq_1r6ed_138:not(#\9) {
|
|
140
140
|
flex-direction: row;
|
|
141
141
|
}
|
|
142
|
-
.
|
|
142
|
+
.awsui_root_14iqq_1r6ed_97.awsui_variant-default_14iqq_1r6ed_141:not(#\9), .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141:not(#\9) {
|
|
143
143
|
background-color: var(--color-background-container-content-il2pe5, #ffffff);
|
|
144
144
|
border-radius: var(--border-radius-container-jm6teg, 0px);
|
|
145
145
|
box-sizing: border-box;
|
|
146
146
|
}
|
|
147
|
-
.
|
|
147
|
+
.awsui_root_14iqq_1r6ed_97.awsui_variant-default_14iqq_1r6ed_141.awsui_refresh_14iqq_1r6ed_146:not(#\9), .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141.awsui_refresh_14iqq_1r6ed_146:not(#\9) {
|
|
148
148
|
border: solid var(--border-divider-section-width-wl9k66, 1px) var(--color-border-divider-default-in8dkg, #eaeded);
|
|
149
149
|
}
|
|
150
|
-
.
|
|
150
|
+
.awsui_root_14iqq_1r6ed_97.awsui_variant-default_14iqq_1r6ed_141:not(#\9):not(.awsui_refresh_14iqq_1r6ed_146)::before, .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141:not(#\9):not(.awsui_refresh_14iqq_1r6ed_146)::before {
|
|
151
151
|
content: "";
|
|
152
152
|
position: absolute;
|
|
153
153
|
left: 0px;
|
|
@@ -162,7 +162,7 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
162
162
|
border-radius: var(--border-radius-container-jm6teg, 0px);
|
|
163
163
|
z-index: 1;
|
|
164
164
|
}
|
|
165
|
-
.
|
|
165
|
+
.awsui_root_14iqq_1r6ed_97.awsui_variant-default_14iqq_1r6ed_141:not(#\9):not(.awsui_refresh_14iqq_1r6ed_146)::after, .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141:not(#\9):not(.awsui_refresh_14iqq_1r6ed_146)::after {
|
|
166
166
|
content: "";
|
|
167
167
|
position: absolute;
|
|
168
168
|
left: 0px;
|
|
@@ -175,127 +175,127 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
175
175
|
border-radius: var(--border-radius-container-jm6teg, 0px);
|
|
176
176
|
box-shadow: var(--shadow-container-5104ec, 0 1px 1px 0 rgba(0, 28, 36, 0.3), 1px 1px 1px 0 rgba(0, 28, 36, 0.15), -1px 1px 1px 0 rgba(0, 28, 36, 0.15));
|
|
177
177
|
}
|
|
178
|
-
.
|
|
178
|
+
.awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141:not(#\9):not(:last-child), .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141:not(#\9):not(:last-child)::before, .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141:not(#\9):not(:last-child)::after {
|
|
179
179
|
border-bottom-right-radius: 0;
|
|
180
180
|
border-bottom-left-radius: 0;
|
|
181
181
|
border-bottom-width: 0;
|
|
182
182
|
}
|
|
183
|
-
.
|
|
183
|
+
.awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141 + .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141:not(#\9), .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141 + .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141:not(#\9)::before, .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141 + .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141:not(#\9)::after {
|
|
184
184
|
border-top-left-radius: 0;
|
|
185
185
|
border-top-right-radius: 0;
|
|
186
186
|
}
|
|
187
|
-
.
|
|
187
|
+
.awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141 + .awsui_root_14iqq_1r6ed_97.awsui_variant-stacked_14iqq_1r6ed_141:not(#\9):not(.awsui_refresh_14iqq_1r6ed_146)::before {
|
|
188
188
|
border-top: var(--border-divider-section-width-wl9k66, 1px) solid var(--color-border-divider-default-in8dkg, #eaeded);
|
|
189
189
|
}
|
|
190
|
-
.
|
|
190
|
+
.awsui_root_14iqq_1r6ed_97.awsui_sticky-enabled_14iqq_1r6ed_189:not(#\9):not(.awsui_refresh_14iqq_1r6ed_146)::before {
|
|
191
191
|
top: calc(-1 * var(--border-container-top-width-s1x6t0, 1px));
|
|
192
192
|
}
|
|
193
|
-
.
|
|
193
|
+
.awsui_root_14iqq_1r6ed_97.awsui_sticky-enabled_14iqq_1r6ed_189:not(#\9):not(.awsui_refresh_14iqq_1r6ed_146).awsui_variant-stacked_14iqq_1r6ed_141::before {
|
|
194
194
|
top: calc(-1 * var(--border-divider-section-width-wl9k66, 1px));
|
|
195
195
|
}
|
|
196
196
|
|
|
197
|
-
.awsui_with-side-
|
|
197
|
+
.awsui_with-side-media_14iqq_1r6ed_138:not(#\9) {
|
|
198
198
|
display: flex;
|
|
199
199
|
flex-direction: row;
|
|
200
200
|
}
|
|
201
201
|
|
|
202
|
-
.awsui_with-top-
|
|
202
|
+
.awsui_with-top-media_14iqq_1r6ed_201:not(#\9) {
|
|
203
203
|
display: flex;
|
|
204
204
|
flex-direction: column;
|
|
205
205
|
}
|
|
206
206
|
|
|
207
|
-
.awsui_content-
|
|
207
|
+
.awsui_content-wrapper_14iqq_1r6ed_206:not(#\9) {
|
|
208
208
|
display: flex;
|
|
209
209
|
flex-direction: column;
|
|
210
210
|
width: 100%;
|
|
211
211
|
}
|
|
212
|
-
.awsui_content-wrapper-fit-
|
|
212
|
+
.awsui_content-wrapper-fit-height_14iqq_1r6ed_211:not(#\9) {
|
|
213
213
|
height: 100%;
|
|
214
214
|
overflow: hidden;
|
|
215
215
|
}
|
|
216
216
|
|
|
217
|
-
.
|
|
217
|
+
.awsui_media_14iqq_1r6ed_216:not(#\9) {
|
|
218
218
|
overflow: hidden;
|
|
219
219
|
flex-shrink: 0;
|
|
220
220
|
}
|
|
221
|
-
.
|
|
222
|
-
.
|
|
223
|
-
.
|
|
221
|
+
.awsui_media_14iqq_1r6ed_216 img:not(#\9),
|
|
222
|
+
.awsui_media_14iqq_1r6ed_216 video:not(#\9),
|
|
223
|
+
.awsui_media_14iqq_1r6ed_216 picture:not(#\9) {
|
|
224
224
|
width: 100%;
|
|
225
225
|
height: 100%;
|
|
226
226
|
object-fit: cover;
|
|
227
227
|
object-position: center;
|
|
228
228
|
}
|
|
229
|
-
.
|
|
229
|
+
.awsui_media_14iqq_1r6ed_216 iframe:not(#\9) {
|
|
230
230
|
width: 100%;
|
|
231
231
|
height: 100%;
|
|
232
232
|
border: 0;
|
|
233
233
|
}
|
|
234
|
-
.awsui_media-
|
|
234
|
+
.awsui_media-top_14iqq_1r6ed_233:not(#\9) {
|
|
235
235
|
max-height: 66%;
|
|
236
236
|
border-top-left-radius: calc(var(--border-radius-container-jm6teg, 0px) - 1px);
|
|
237
237
|
border-top-right-radius: calc(var(--border-radius-container-jm6teg, 0px) - 1px);
|
|
238
238
|
}
|
|
239
|
-
.awsui_media-
|
|
239
|
+
.awsui_media-side_14iqq_1r6ed_238:not(#\9) {
|
|
240
240
|
max-width: 66%;
|
|
241
241
|
border-top-left-radius: calc(var(--border-radius-container-jm6teg, 0px) - 1px);
|
|
242
242
|
border-bottom-left-radius: calc(var(--border-radius-container-jm6teg, 0px) - 1px);
|
|
243
243
|
}
|
|
244
244
|
|
|
245
|
-
.
|
|
245
|
+
.awsui_header_14iqq_1r6ed_244:not(#\9) {
|
|
246
246
|
background-color: var(--color-background-container-header-ni4jv3, #fafafa);
|
|
247
247
|
border-top-left-radius: var(--border-radius-container-jm6teg, 0px);
|
|
248
248
|
border-top-right-radius: var(--border-radius-container-jm6teg, 0px);
|
|
249
249
|
}
|
|
250
|
-
.
|
|
250
|
+
.awsui_header_14iqq_1r6ed_244.awsui_header-with-media_14iqq_1r6ed_249:not(#\9) {
|
|
251
251
|
background: none;
|
|
252
252
|
}
|
|
253
|
-
.
|
|
253
|
+
.awsui_header_14iqq_1r6ed_244.awsui_header-with-media_14iqq_1r6ed_249:not(#\9):not(:empty) {
|
|
254
254
|
border-bottom: none;
|
|
255
255
|
}
|
|
256
|
-
.awsui_header-sticky-
|
|
256
|
+
.awsui_header-sticky-disabled_14iqq_1r6ed_255:not(#\9) {
|
|
257
257
|
position: relative;
|
|
258
258
|
z-index: 1;
|
|
259
259
|
}
|
|
260
|
-
.awsui_header-sticky-
|
|
260
|
+
.awsui_header-sticky-enabled_14iqq_1r6ed_259:not(#\9) {
|
|
261
261
|
top: 0;
|
|
262
262
|
/* stylelint-disable-next-line plugin/no-unsupported-browser-features */
|
|
263
263
|
position: sticky;
|
|
264
264
|
z-index: 800;
|
|
265
265
|
}
|
|
266
|
-
.awsui_header-
|
|
266
|
+
.awsui_header-stuck_14iqq_1r6ed_265:not(#\9) {
|
|
267
267
|
border-radius: 0;
|
|
268
268
|
}
|
|
269
|
-
.awsui_header-
|
|
269
|
+
.awsui_header-stuck_14iqq_1r6ed_265:not(#\9)::before {
|
|
270
270
|
border: 0;
|
|
271
271
|
}
|
|
272
|
-
.awsui_header-
|
|
272
|
+
.awsui_header-stuck_14iqq_1r6ed_265:not(#\9):not(.awsui_header-variant-cards_14iqq_1r6ed_271) {
|
|
273
273
|
box-shadow: var(--shadow-sticky-embedded-f9wivk, 0px 1px 4px -2px rgba(0, 28, 36, 0.5));
|
|
274
274
|
}
|
|
275
|
-
.awsui_header-dynamic-
|
|
275
|
+
.awsui_header-dynamic-height_14iqq_1r6ed_274.awsui_header-stuck_14iqq_1r6ed_265:not(#\9) {
|
|
276
276
|
margin-bottom: calc(var(--line-height-heading-xl-v9hsvt, 36px) - var(--line-height-heading-l-vog8w7, 22px));
|
|
277
277
|
}
|
|
278
|
-
.
|
|
278
|
+
.awsui_header_14iqq_1r6ed_244:not(#\9):not(:empty) {
|
|
279
279
|
border-bottom: var(--border-container-sticky-width-xo3q2l, 1px) solid var(--color-border-container-divider-gl15p9, #eaeded);
|
|
280
280
|
}
|
|
281
|
-
.
|
|
281
|
+
.awsui_header_14iqq_1r6ed_244.awsui_with-paddings_14iqq_1r6ed_280:not(#\9) {
|
|
282
282
|
padding: var(--space-container-header-top-bomjbu, 12px) var(--space-container-horizontal-oebwqe, 20px) var(--space-container-header-bottom-qqnwwz, 12px);
|
|
283
283
|
}
|
|
284
|
-
.
|
|
284
|
+
.awsui_header_14iqq_1r6ed_244.awsui_with-paddings_14iqq_1r6ed_280.awsui_header-variant-cards_14iqq_1r6ed_271:not(#\9) {
|
|
285
285
|
padding: var(--space-container-header-top-bomjbu, 12px) var(--space-container-horizontal-oebwqe, 20px);
|
|
286
286
|
}
|
|
287
|
-
.
|
|
287
|
+
.awsui_header_14iqq_1r6ed_244.awsui_with-hidden-content_14iqq_1r6ed_286:not(#\9) {
|
|
288
288
|
border-bottom-left-radius: var(--border-radius-container-jm6teg, 0px);
|
|
289
289
|
border-bottom-right-radius: var(--border-radius-container-jm6teg, 0px);
|
|
290
290
|
}
|
|
291
|
-
.awsui_header-variant-
|
|
291
|
+
.awsui_header-variant-cards_14iqq_1r6ed_271:not(#\9) {
|
|
292
292
|
border-radius: var(--border-radius-container-jm6teg, 0px);
|
|
293
293
|
box-sizing: border-box;
|
|
294
294
|
}
|
|
295
|
-
.awsui_header-variant-
|
|
295
|
+
.awsui_header-variant-cards_14iqq_1r6ed_271.awsui_refresh_14iqq_1r6ed_146:not(#\9) {
|
|
296
296
|
border: solid var(--border-divider-section-width-wl9k66, 1px) var(--color-border-divider-default-in8dkg, #eaeded);
|
|
297
297
|
}
|
|
298
|
-
.awsui_header-variant-
|
|
298
|
+
.awsui_header-variant-cards_14iqq_1r6ed_271:not(#\9):not(.awsui_refresh_14iqq_1r6ed_146)::before {
|
|
299
299
|
content: "";
|
|
300
300
|
position: absolute;
|
|
301
301
|
left: 0px;
|
|
@@ -310,7 +310,7 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
310
310
|
border-radius: var(--border-radius-container-jm6teg, 0px);
|
|
311
311
|
z-index: 1;
|
|
312
312
|
}
|
|
313
|
-
.awsui_header-variant-
|
|
313
|
+
.awsui_header-variant-cards_14iqq_1r6ed_271:not(#\9):not(.awsui_refresh_14iqq_1r6ed_146)::after {
|
|
314
314
|
content: "";
|
|
315
315
|
position: absolute;
|
|
316
316
|
left: 0px;
|
|
@@ -323,18 +323,27 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
323
323
|
border-radius: var(--border-radius-container-jm6teg, 0px);
|
|
324
324
|
box-shadow: var(--shadow-container-5104ec, 0 1px 1px 0 rgba(0, 28, 36, 0.3), 1px 1px 1px 0 rgba(0, 28, 36, 0.15), -1px 1px 1px 0 rgba(0, 28, 36, 0.15));
|
|
325
325
|
}
|
|
326
|
-
.awsui_header-variant-
|
|
326
|
+
.awsui_header-variant-cards_14iqq_1r6ed_271:not(#\9):not(.awsui_header-sticky-enabled_14iqq_1r6ed_259) {
|
|
327
327
|
position: relative;
|
|
328
328
|
}
|
|
329
|
-
.awsui_header-variant-
|
|
329
|
+
.awsui_header-variant-cards_14iqq_1r6ed_271.awsui_header-stuck_14iqq_1r6ed_265:not(#\9)::after, .awsui_header-variant-cards_14iqq_1r6ed_271.awsui_header-stuck_14iqq_1r6ed_265:not(#\9)::before {
|
|
330
330
|
border: 0;
|
|
331
331
|
border-top-left-radius: 0;
|
|
332
332
|
border-top-right-radius: 0;
|
|
333
333
|
}
|
|
334
|
-
.awsui_header-variant-full-
|
|
334
|
+
.awsui_header-variant-full-page_14iqq_1r6ed_333.awsui_header-stuck_14iqq_1r6ed_265:not(#\9) {
|
|
335
335
|
box-shadow: none;
|
|
336
336
|
}
|
|
337
|
-
.awsui_header-variant-full-
|
|
337
|
+
.awsui_header-variant-full-page_14iqq_1r6ed_333.awsui_header-stuck_14iqq_1r6ed_265:not(#\9)::before {
|
|
338
|
+
content: "";
|
|
339
|
+
position: absolute;
|
|
340
|
+
right: 0;
|
|
341
|
+
left: 0;
|
|
342
|
+
bottom: 0;
|
|
343
|
+
top: 0;
|
|
344
|
+
border-bottom: solid var(--border-divider-section-width-wl9k66, 1px) var(--color-border-divider-default-in8dkg, #eaeded);
|
|
345
|
+
}
|
|
346
|
+
.awsui_header-variant-full-page_14iqq_1r6ed_333.awsui_header-stuck_14iqq_1r6ed_265:not(#\9)::after {
|
|
338
347
|
content: "";
|
|
339
348
|
position: absolute;
|
|
340
349
|
right: 0;
|
|
@@ -344,35 +353,39 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
344
353
|
box-shadow: var(--shadow-sticky-hxu2pv, 0px 1px 4px -2px rgba(0, 28, 36, 0.5));
|
|
345
354
|
clip-path: polygon(-999% 100%, 999% 100%, 999% 999%, -999% 999%);
|
|
346
355
|
}
|
|
356
|
+
.awsui_header-variant-full-page_14iqq_1r6ed_333.awsui_header-stuck_14iqq_1r6ed_265:not(#\9):not(.awsui_remove-high-contrast-header_14iqq_1r6ed_355)::before {
|
|
357
|
+
content: "";
|
|
358
|
+
border-bottom: none;
|
|
359
|
+
}
|
|
347
360
|
|
|
348
361
|
/*
|
|
349
362
|
The dynamic height dark header needs a background that will cover
|
|
350
363
|
the default white background of the container component.
|
|
351
364
|
*/
|
|
352
|
-
.awsui_dark-
|
|
365
|
+
.awsui_dark-header_14iqq_1r6ed_364:not(#\9) {
|
|
353
366
|
background-color: var(--color-background-layout-main-td853a, #f2f3f3);
|
|
354
367
|
color: var(--color-text-body-default-ffdwgg, #16191f);
|
|
355
368
|
}
|
|
356
369
|
|
|
357
|
-
.
|
|
370
|
+
.awsui_content_14iqq_1r6ed_206:not(#\9) {
|
|
358
371
|
flex: 1;
|
|
359
372
|
}
|
|
360
|
-
.awsui_content-fit-
|
|
373
|
+
.awsui_content-fit-height_14iqq_1r6ed_372:not(#\9) {
|
|
361
374
|
overflow: auto;
|
|
362
375
|
}
|
|
363
|
-
.
|
|
376
|
+
.awsui_content_14iqq_1r6ed_206.awsui_with-paddings_14iqq_1r6ed_280:not(#\9) {
|
|
364
377
|
padding: var(--space-scaled-l-08jb88, 20px) var(--space-container-horizontal-oebwqe, 20px);
|
|
365
378
|
}
|
|
366
|
-
.
|
|
379
|
+
.awsui_header_14iqq_1r6ed_244 + .awsui_content_14iqq_1r6ed_206.awsui_with-paddings_14iqq_1r6ed_280:not(#\9) {
|
|
367
380
|
padding-top: var(--space-container-content-top-dkluz9, 16px);
|
|
368
381
|
}
|
|
369
|
-
.
|
|
382
|
+
.awsui_header_14iqq_1r6ed_244 + .awsui_content_14iqq_1r6ed_206.awsui_with-paddings_14iqq_1r6ed_280.awsui_content-with-media_14iqq_1r6ed_381:not(#\9) {
|
|
370
383
|
padding-top: 0;
|
|
371
384
|
}
|
|
372
385
|
|
|
373
|
-
.
|
|
386
|
+
.awsui_footer_14iqq_1r6ed_385.awsui_with-paddings_14iqq_1r6ed_280:not(#\9) {
|
|
374
387
|
padding: var(--space-scaled-s-9q8n2q, 12px) var(--space-container-horizontal-oebwqe, 20px);
|
|
375
388
|
}
|
|
376
|
-
.
|
|
389
|
+
.awsui_footer_14iqq_1r6ed_385.awsui_with-divider_14iqq_1r6ed_388:not(#\9) {
|
|
377
390
|
border-top: var(--border-divider-section-width-wl9k66, 1px) solid var(--color-border-divider-default-in8dkg, #eaeded);
|
|
378
391
|
}
|
|
@@ -2,34 +2,35 @@
|
|
|
2
2
|
// es-module interop with Babel and Typescript
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
module.exports.default = {
|
|
5
|
-
"root": "
|
|
6
|
-
"fit-height": "awsui_fit-
|
|
7
|
-
"with-side-media": "awsui_with-side-
|
|
8
|
-
"variant-default": "awsui_variant-
|
|
9
|
-
"variant-stacked": "awsui_variant-
|
|
10
|
-
"refresh": "
|
|
11
|
-
"sticky-enabled": "awsui_sticky-
|
|
12
|
-
"with-top-media": "awsui_with-top-
|
|
13
|
-
"content-wrapper": "awsui_content-
|
|
14
|
-
"content-wrapper-fit-height": "awsui_content-wrapper-fit-
|
|
15
|
-
"media": "
|
|
16
|
-
"media-top": "awsui_media-
|
|
17
|
-
"media-side": "awsui_media-
|
|
18
|
-
"header": "
|
|
19
|
-
"header-with-media": "awsui_header-with-
|
|
20
|
-
"header-sticky-disabled": "awsui_header-sticky-
|
|
21
|
-
"header-sticky-enabled": "awsui_header-sticky-
|
|
22
|
-
"header-stuck": "awsui_header-
|
|
23
|
-
"header-variant-cards": "awsui_header-variant-
|
|
24
|
-
"header-dynamic-height": "awsui_header-dynamic-
|
|
25
|
-
"with-paddings": "awsui_with-
|
|
26
|
-
"with-hidden-content": "awsui_with-hidden-
|
|
27
|
-
"header-variant-full-page": "awsui_header-variant-full-
|
|
28
|
-
"
|
|
29
|
-
"
|
|
30
|
-
"content
|
|
31
|
-
"content-
|
|
32
|
-
"
|
|
33
|
-
"
|
|
5
|
+
"root": "awsui_root_14iqq_1r6ed_97",
|
|
6
|
+
"fit-height": "awsui_fit-height_14iqq_1r6ed_133",
|
|
7
|
+
"with-side-media": "awsui_with-side-media_14iqq_1r6ed_138",
|
|
8
|
+
"variant-default": "awsui_variant-default_14iqq_1r6ed_141",
|
|
9
|
+
"variant-stacked": "awsui_variant-stacked_14iqq_1r6ed_141",
|
|
10
|
+
"refresh": "awsui_refresh_14iqq_1r6ed_146",
|
|
11
|
+
"sticky-enabled": "awsui_sticky-enabled_14iqq_1r6ed_189",
|
|
12
|
+
"with-top-media": "awsui_with-top-media_14iqq_1r6ed_201",
|
|
13
|
+
"content-wrapper": "awsui_content-wrapper_14iqq_1r6ed_206",
|
|
14
|
+
"content-wrapper-fit-height": "awsui_content-wrapper-fit-height_14iqq_1r6ed_211",
|
|
15
|
+
"media": "awsui_media_14iqq_1r6ed_216",
|
|
16
|
+
"media-top": "awsui_media-top_14iqq_1r6ed_233",
|
|
17
|
+
"media-side": "awsui_media-side_14iqq_1r6ed_238",
|
|
18
|
+
"header": "awsui_header_14iqq_1r6ed_244",
|
|
19
|
+
"header-with-media": "awsui_header-with-media_14iqq_1r6ed_249",
|
|
20
|
+
"header-sticky-disabled": "awsui_header-sticky-disabled_14iqq_1r6ed_255",
|
|
21
|
+
"header-sticky-enabled": "awsui_header-sticky-enabled_14iqq_1r6ed_259",
|
|
22
|
+
"header-stuck": "awsui_header-stuck_14iqq_1r6ed_265",
|
|
23
|
+
"header-variant-cards": "awsui_header-variant-cards_14iqq_1r6ed_271",
|
|
24
|
+
"header-dynamic-height": "awsui_header-dynamic-height_14iqq_1r6ed_274",
|
|
25
|
+
"with-paddings": "awsui_with-paddings_14iqq_1r6ed_280",
|
|
26
|
+
"with-hidden-content": "awsui_with-hidden-content_14iqq_1r6ed_286",
|
|
27
|
+
"header-variant-full-page": "awsui_header-variant-full-page_14iqq_1r6ed_333",
|
|
28
|
+
"remove-high-contrast-header": "awsui_remove-high-contrast-header_14iqq_1r6ed_355",
|
|
29
|
+
"dark-header": "awsui_dark-header_14iqq_1r6ed_364",
|
|
30
|
+
"content": "awsui_content_14iqq_1r6ed_206",
|
|
31
|
+
"content-fit-height": "awsui_content-fit-height_14iqq_1r6ed_372",
|
|
32
|
+
"content-with-media": "awsui_content-with-media_14iqq_1r6ed_381",
|
|
33
|
+
"footer": "awsui_footer_14iqq_1r6ed_385",
|
|
34
|
+
"with-divider": "awsui_with-divider_14iqq_1r6ed_388"
|
|
34
35
|
};
|
|
35
36
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"content-header-utils.d.ts","sourceRoot":"lib/default/","sources":["internal/utils/content-header-utils.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,sBAAsB,
|
|
1
|
+
{"version":3,"file":"content-header-utils.d.ts","sourceRoot":"lib/default/","sources":["internal/utils/content-header-utils.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,8BAA8B,SAA8C,CAAC;AAC1F,eAAO,MAAM,sBAAsB,QAAuE,CAAC"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
2
|
// SPDX-License-Identifier: Apache-2.0
|
|
3
3
|
import { getGlobalFlag } from './global-flags';
|
|
4
|
-
export const
|
|
5
|
-
|
|
6
|
-
: 'awsui-context-content-header';
|
|
4
|
+
export const shouldRemoveHighContrastHeader = !!getGlobalFlag('removeHighContrastHeader');
|
|
5
|
+
export const contentHeaderClassName = shouldRemoveHighContrastHeader ? '' : 'awsui-context-content-header';
|
|
7
6
|
//# sourceMappingURL=content-header-utils.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"content-header-utils.js","sourceRoot":"lib/default/","sources":["internal/utils/content-header-utils.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAE/C,MAAM,CAAC,MAAM,
|
|
1
|
+
{"version":3,"file":"content-header-utils.js","sourceRoot":"lib/default/","sources":["internal/utils/content-header-utils.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAE/C,MAAM,CAAC,MAAM,8BAA8B,GAAG,CAAC,CAAC,aAAa,CAAC,0BAA0B,CAAC,CAAC;AAC1F,MAAM,CAAC,MAAM,sBAAsB,GAAG,8BAA8B,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,8BAA8B,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { getGlobalFlag } from './global-flags';\n\nexport const shouldRemoveHighContrastHeader = !!getGlobalFlag('removeHighContrastHeader');\nexport const contentHeaderClassName = shouldRemoveHighContrastHeader ? '' : 'awsui-context-content-header';\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"internal.d.ts","sourceRoot":"lib/default/","sources":["wizard/internal.tsx"],"names":[],"mappings":";AAaA,OAAO,EAAE,0BAA0B,EAAE,MAAM,sCAAsC,CAAC;AAYlF,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"internal.d.ts","sourceRoot":"lib/default/","sources":["wizard/internal.tsx"],"names":[],"mappings":";AAaA,OAAO,EAAE,0BAA0B,EAAE,MAAM,sCAAsC,CAAC;AAYlF,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAM3C,KAAK,mBAAmB,GAAG,WAAW,GAAG,0BAA0B,CAAC;AAEpE,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,EACrC,KAAK,EACL,eAAe,EAAE,yBAAyB,EAC1C,gBAAgB,EAChB,iBAAyB,EACzB,WAAmB,EACnB,gBAAgB,EAChB,QAAQ,EACR,QAAQ,EACR,UAAU,EACV,iBAAiB,EACjB,GAAG,IAAI,EACR,EAAE,mBAAmB,eAyJrB"}
|
|
@@ -19,6 +19,7 @@ import WizardForm, { STEP_NAME_SELECTOR } from './wizard-form';
|
|
|
19
19
|
import WizardNavigation from './wizard-navigation';
|
|
20
20
|
import styles from './styles.css.js';
|
|
21
21
|
import { useFunnelChangeEvent } from './analytics';
|
|
22
|
+
import { shouldRemoveHighContrastHeader } from '../internal/utils/content-header-utils';
|
|
22
23
|
export default function InternalWizard(_a) {
|
|
23
24
|
var _b, _c, _d, _e, _f, _g, _h, _j;
|
|
24
25
|
var { steps, activeStepIndex: controlledActiveStepIndex, submitButtonText, isLoadingNextStep = false, allowSkipTo = false, secondaryActions, onCancel, onSubmit, onNavigate, __internalRootRef } = _a, rest = __rest(_a, ["steps", "activeStepIndex", "submitButtonText", "isLoadingNextStep", "allowSkipTo", "secondaryActions", "onCancel", "onSubmit", "onNavigate", "__internalRootRef"]);
|
|
@@ -81,9 +82,9 @@ export default function InternalWizard(_a) {
|
|
|
81
82
|
warnOnce('Wizard', `You have set \`allowSkipTo\` but you have not provided \`i18nStrings.skipToButtonLabel\`. The skip-to button will not be rendered.`);
|
|
82
83
|
}
|
|
83
84
|
return (React.createElement("div", Object.assign({}, baseProps, funnelProps, { ref: ref, className: clsx(styles.root, baseProps.className) }),
|
|
84
|
-
React.createElement("div", { className: clsx(styles.wizard, isVisualRefresh && styles.refresh, smallContainer && styles['small-container']) },
|
|
85
|
+
React.createElement("div", { className: clsx(styles.wizard, isVisualRefresh && styles.refresh, smallContainer && styles['small-container'], shouldRemoveHighContrastHeader && styles['remove-high-contrast-header']) },
|
|
85
86
|
React.createElement(WizardNavigation, { activeStepIndex: actualActiveStepIndex, farthestStepIndex: farthestStepIndex.current, allowSkipTo: allowSkipTo, hidden: smallContainer, i18nStrings: i18nStrings, isVisualRefresh: isVisualRefresh, isLoadingNextStep: isLoadingNextStep, onStepClick: onStepClick, onSkipToClick: onSkipToClick, steps: steps }),
|
|
86
|
-
React.createElement("div", { className: clsx(styles.form, isVisualRefresh && styles.refresh, smallContainer && styles['small-container']) },
|
|
87
|
+
React.createElement("div", { className: clsx(styles.form, isVisualRefresh && styles.refresh, smallContainer && styles['small-container'], shouldRemoveHighContrastHeader && styles['remove-high-contrast-header']) },
|
|
87
88
|
isVisualRefresh && React.createElement("div", { className: clsx(styles.background, contentHeaderClassName) }),
|
|
88
89
|
React.createElement(WizardForm, { steps: steps, isVisualRefresh: isVisualRefresh, showCollapsedSteps: smallContainer, i18nStrings: i18nStrings, submitButtonText: submitButtonText, activeStepIndex: actualActiveStepIndex, isPrimaryLoading: isLoadingNextStep, allowSkipTo: allowSkipTo, secondaryActions: secondaryActions, onCancelClick: onCancelClick, onPreviousClick: onPreviousClick, onSkipToClick: onSkipToClick, onPrimaryClick: onPrimaryClick })))));
|
|
89
90
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"intern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a,EAC5B,cAAc,EAAE,cAAc,GAC9B,CACE,CACF,CACF,CACP,CAAC;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { useRef } from 'react';\nimport clsx from 'clsx';\n\nimport { getBaseProps } from '../internal/base-component';\nimport { fireNonCancelableEvent } from '../internal/events';\nimport { warnOnce } from '@cloudscape-design/component-toolkit/internal';\n\nimport { useContainerBreakpoints } from '../internal/hooks/container-queries';\nimport { useControllable } from '../internal/hooks/use-controllable';\nimport { useMergeRefs } from '../internal/hooks/use-merge-refs';\nimport { useVisualRefresh } from '../internal/hooks/use-visual-mode';\nimport { InternalBaseComponentProps } from '../internal/hooks/use-base-component';\nimport { contentHeaderClassName } from '../internal/utils/content-header-utils';\n\nimport { useInternalI18n } from '../i18n/context';\n\nimport { FunnelMetrics } from '../internal/analytics';\nimport { useFunnel } from '../internal/analytics/hooks/use-funnel';\nimport { getNameFromSelector, getSubStepAllSelector } from '../internal/analytics/selectors';\n\nimport WizardForm, { STEP_NAME_SELECTOR } from './wizard-form';\nimport WizardNavigation from './wizard-navigation';\n\nimport { WizardProps } from './interfaces';\n\nimport styles from './styles.css.js';\nimport { useFunnelChangeEvent } from './analytics';\n\ntype InternalWizardProps = WizardProps & InternalBaseComponentProps;\n\nexport default function InternalWizard({\n steps,\n activeStepIndex: controlledActiveStepIndex,\n submitButtonText,\n isLoadingNextStep = false,\n allowSkipTo = false,\n secondaryActions,\n onCancel,\n onSubmit,\n onNavigate,\n __internalRootRef,\n ...rest\n}: InternalWizardProps) {\n const baseProps = getBaseProps(rest);\n\n const [breakpoint, breakpointsRef] = useContainerBreakpoints(['xs']);\n const ref = useMergeRefs(breakpointsRef, __internalRootRef);\n\n const smallContainer = breakpoint === 'default';\n\n const [activeStepIndex, setActiveStepIndex] = useControllable(controlledActiveStepIndex, onNavigate, 0, {\n componentName: 'Wizard',\n controlledProp: 'activeStepIndex',\n changeHandler: 'onNavigate',\n });\n const { funnelInteractionId, funnelSubmit, funnelCancel, funnelProps, funnelNextOrSubmitAttempt } = useFunnel();\n const actualActiveStepIndex = activeStepIndex ? Math.min(activeStepIndex, steps.length - 1) : 0;\n\n const farthestStepIndex = useRef<number>(actualActiveStepIndex);\n farthestStepIndex.current = Math.max(farthestStepIndex.current, actualActiveStepIndex);\n\n const isVisualRefresh = useVisualRefresh();\n const isLastStep = actualActiveStepIndex >= steps.length - 1;\n\n const navigationEvent = (requestedStepIndex: number, reason: WizardProps.NavigationReason) => {\n if (funnelInteractionId) {\n const stepName = getNameFromSelector(STEP_NAME_SELECTOR);\n\n FunnelMetrics.funnelStepNavigation({\n navigationType: reason,\n funnelInteractionId,\n stepNumber: actualActiveStepIndex + 1,\n stepName,\n stepNameSelector: STEP_NAME_SELECTOR,\n destinationStepNumber: requestedStepIndex + 1,\n subStepAllSelector: getSubStepAllSelector(),\n });\n }\n\n setActiveStepIndex(requestedStepIndex);\n fireNonCancelableEvent(onNavigate, { requestedStepIndex, reason });\n };\n const onStepClick = (stepIndex: number) => navigationEvent(stepIndex, 'step');\n const onSkipToClick = (stepIndex: number) => navigationEvent(stepIndex, 'skip');\n const onCancelClick = () => {\n funnelCancel();\n fireNonCancelableEvent(onCancel);\n };\n const onPreviousClick = () => navigationEvent(actualActiveStepIndex - 1, 'previous');\n const onPrimaryClick = () => {\n funnelNextOrSubmitAttempt();\n\n if (isLastStep) {\n funnelSubmit();\n fireNonCancelableEvent(onSubmit);\n } else {\n navigationEvent(actualActiveStepIndex + 1, 'next');\n }\n };\n\n useFunnelChangeEvent(funnelInteractionId, steps);\n\n const i18n = useInternalI18n('wizard');\n const skipToButtonLabel = i18n(\n 'i18nStrings.skipToButtonLabel',\n rest.i18nStrings?.skipToButtonLabel,\n format => task => format({ task__title: task.title })\n );\n\n const i18nStrings: WizardProps.I18nStrings = {\n ...rest.i18nStrings,\n skipToButtonLabel,\n stepNumberLabel: i18n(\n 'i18nStrings.stepNumberLabel',\n rest.i18nStrings?.stepNumberLabel,\n format => stepNumber => format({ stepNumber })\n ),\n collapsedStepsLabel: i18n(\n 'i18nStrings.collapsedStepsLabel',\n rest.i18nStrings?.collapsedStepsLabel,\n format => (stepNumber, stepsCount) => format({ stepNumber, stepsCount })\n ),\n navigationAriaLabel: i18n('i18nStrings.navigationAriaLabel', rest.i18nStrings?.navigationAriaLabel),\n cancelButton: i18n('i18nStrings.cancelButton', rest.i18nStrings?.cancelButton),\n previousButton: i18n('i18nStrings.previousButton', rest.i18nStrings?.previousButton),\n nextButton: i18n('i18nStrings.nextButton', rest.i18nStrings?.nextButton),\n optional: i18n('i18nStrings.optional', rest.i18nStrings?.optional),\n };\n\n if (activeStepIndex && activeStepIndex >= steps.length) {\n warnOnce(\n 'Wizard',\n `You have set \\`activeStepIndex\\` to ${activeStepIndex} but you have provided only ${\n steps.length\n } steps. Its value is ignored and the component uses ${steps.length - 1} instead.`\n );\n }\n\n if (allowSkipTo && !skipToButtonLabel) {\n warnOnce(\n 'Wizard',\n `You have set \\`allowSkipTo\\` but you have not provided \\`i18nStrings.skipToButtonLabel\\`. The skip-to button will not be rendered.`\n );\n }\n\n return (\n <div {...baseProps} {...funnelProps} ref={ref} className={clsx(styles.root, baseProps.className)}>\n <div\n className={clsx(styles.wizard, isVisualRefresh && styles.refresh, smallContainer && styles['small-container'])}\n >\n <WizardNavigation\n activeStepIndex={actualActiveStepIndex}\n farthestStepIndex={farthestStepIndex.current}\n allowSkipTo={allowSkipTo}\n hidden={smallContainer}\n i18nStrings={i18nStrings}\n isVisualRefresh={isVisualRefresh}\n isLoadingNextStep={isLoadingNextStep}\n onStepClick={onStepClick}\n onSkipToClick={onSkipToClick}\n steps={steps}\n />\n <div\n className={clsx(styles.form, isVisualRefresh && styles.refresh, smallContainer && styles['small-container'])}\n >\n {isVisualRefresh && <div className={clsx(styles.background, contentHeaderClassName)} />}\n <WizardForm\n steps={steps}\n isVisualRefresh={isVisualRefresh}\n showCollapsedSteps={smallContainer}\n i18nStrings={i18nStrings}\n submitButtonText={submitButtonText}\n activeStepIndex={actualActiveStepIndex}\n isPrimaryLoading={isLoadingNextStep}\n allowSkipTo={allowSkipTo}\n secondaryActions={secondaryActions}\n onCancelClick={onCancelClick}\n onPreviousClick={onPreviousClick}\n onSkipToClick={onSkipToClick}\n onPrimaryClick={onPrimaryClick}\n />\n </div>\n </div>\n </div>\n );\n}\n"]}
|
|
1
|
+
{"version":3,"file":"internal.js","sourceRoot":"lib/default/","sources":["wizard/internal.tsx"],"names":[],"mappings":";AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,EAAE,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AACtC,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,QAAQ,EAAE,MAAM,+CAA+C,CAAC;AAEzE,OAAO,EAAE,uBAAuB,EAAE,MAAM,qCAAqC,CAAC;AAC9E,OAAO,EAAE,eAAe,EAAE,MAAM,oCAAoC,CAAC;AACrE,OAAO,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AAErE,OAAO,EAAE,sBAAsB,EAAE,MAAM,wCAAwC,CAAC;AAEhF,OAAO,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAElD,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AACtD,OAAO,EAAE,SAAS,EAAE,MAAM,wCAAwC,CAAC;AACnE,OAAO,EAAE,mBAAmB,EAAE,qBAAqB,EAAE,MAAM,iCAAiC,CAAC;AAE7F,OAAO,UAAU,EAAE,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAC/D,OAAO,gBAAgB,MAAM,qBAAqB,CAAC;AAInD,OAAO,MAAM,MAAM,i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E;gBAEA,eAAe,IAAI,6BAAK,SAAS,EAAE,IAAI,CAAC,MAAM,CAAC,UAAU,EAAE,sBAAsB,CAAC,GAAI;gBACvF,oBAAC,UAAU,IACT,KAAK,EAAE,KAAK,EACZ,eAAe,EAAE,eAAe,EAChC,kBAAkB,EAAE,cAAc,EAClC,WAAW,EAAE,WAAW,EACxB,gBAAgB,EAAE,gBAAgB,EAClC,eAAe,EAAE,qBAAqB,EACtC,gBAAgB,EAAE,iBAAiB,EACnC,WAAW,EAAE,WAAW,EACxB,gBAAgB,EAAE,gBAAgB,EAClC,aAAa,EAAE,aAAa,EAC5B,eAAe,EAAE,eAAe,EAChC,aAAa,EAAE,aAAa,EAC5B,cAAc,EAAE,cAAc,GAC9B,CACE,CACF,CACF,CACP,CAAC;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { useRef } from 'react';\nimport clsx from 'clsx';\n\nimport { getBaseProps } from '../internal/base-component';\nimport { fireNonCancelableEvent } from '../internal/events';\nimport { warnOnce } from '@cloudscape-design/component-toolkit/internal';\n\nimport { useContainerBreakpoints } from '../internal/hooks/container-queries';\nimport { useControllable } from '../internal/hooks/use-controllable';\nimport { useMergeRefs } from '../internal/hooks/use-merge-refs';\nimport { useVisualRefresh } from '../internal/hooks/use-visual-mode';\nimport { InternalBaseComponentProps } from '../internal/hooks/use-base-component';\nimport { contentHeaderClassName } from '../internal/utils/content-header-utils';\n\nimport { useInternalI18n } from '../i18n/context';\n\nimport { FunnelMetrics } from '../internal/analytics';\nimport { useFunnel } from '../internal/analytics/hooks/use-funnel';\nimport { getNameFromSelector, getSubStepAllSelector } from '../internal/analytics/selectors';\n\nimport WizardForm, { STEP_NAME_SELECTOR } from './wizard-form';\nimport WizardNavigation from './wizard-navigation';\n\nimport { WizardProps } from './interfaces';\n\nimport styles from './styles.css.js';\nimport { useFunnelChangeEvent } from './analytics';\nimport { shouldRemoveHighContrastHeader } from '../internal/utils/content-header-utils';\n\ntype InternalWizardProps = WizardProps & InternalBaseComponentProps;\n\nexport default function InternalWizard({\n steps,\n activeStepIndex: controlledActiveStepIndex,\n submitButtonText,\n isLoadingNextStep = false,\n allowSkipTo = false,\n secondaryActions,\n onCancel,\n onSubmit,\n onNavigate,\n __internalRootRef,\n ...rest\n}: InternalWizardProps) {\n const baseProps = getBaseProps(rest);\n\n const [breakpoint, breakpointsRef] = useContainerBreakpoints(['xs']);\n const ref = useMergeRefs(breakpointsRef, __internalRootRef);\n\n const smallContainer = breakpoint === 'default';\n\n const [activeStepIndex, setActiveStepIndex] = useControllable(controlledActiveStepIndex, onNavigate, 0, {\n componentName: 'Wizard',\n controlledProp: 'activeStepIndex',\n changeHandler: 'onNavigate',\n });\n const { funnelInteractionId, funnelSubmit, funnelCancel, funnelProps, funnelNextOrSubmitAttempt } = useFunnel();\n const actualActiveStepIndex = activeStepIndex ? Math.min(activeStepIndex, steps.length - 1) : 0;\n\n const farthestStepIndex = useRef<number>(actualActiveStepIndex);\n farthestStepIndex.current = Math.max(farthestStepIndex.current, actualActiveStepIndex);\n\n const isVisualRefresh = useVisualRefresh();\n const isLastStep = actualActiveStepIndex >= steps.length - 1;\n\n const navigationEvent = (requestedStepIndex: number, reason: WizardProps.NavigationReason) => {\n if (funnelInteractionId) {\n const stepName = getNameFromSelector(STEP_NAME_SELECTOR);\n\n FunnelMetrics.funnelStepNavigation({\n navigationType: reason,\n funnelInteractionId,\n stepNumber: actualActiveStepIndex + 1,\n stepName,\n stepNameSelector: STEP_NAME_SELECTOR,\n destinationStepNumber: requestedStepIndex + 1,\n subStepAllSelector: getSubStepAllSelector(),\n });\n }\n\n setActiveStepIndex(requestedStepIndex);\n fireNonCancelableEvent(onNavigate, { requestedStepIndex, reason });\n };\n const onStepClick = (stepIndex: number) => navigationEvent(stepIndex, 'step');\n const onSkipToClick = (stepIndex: number) => navigationEvent(stepIndex, 'skip');\n const onCancelClick = () => {\n funnelCancel();\n fireNonCancelableEvent(onCancel);\n };\n const onPreviousClick = () => navigationEvent(actualActiveStepIndex - 1, 'previous');\n const onPrimaryClick = () => {\n funnelNextOrSubmitAttempt();\n\n if (isLastStep) {\n funnelSubmit();\n fireNonCancelableEvent(onSubmit);\n } else {\n navigationEvent(actualActiveStepIndex + 1, 'next');\n }\n };\n\n useFunnelChangeEvent(funnelInteractionId, steps);\n\n const i18n = useInternalI18n('wizard');\n const skipToButtonLabel = i18n(\n 'i18nStrings.skipToButtonLabel',\n rest.i18nStrings?.skipToButtonLabel,\n format => task => format({ task__title: task.title })\n );\n\n const i18nStrings: WizardProps.I18nStrings = {\n ...rest.i18nStrings,\n skipToButtonLabel,\n stepNumberLabel: i18n(\n 'i18nStrings.stepNumberLabel',\n rest.i18nStrings?.stepNumberLabel,\n format => stepNumber => format({ stepNumber })\n ),\n collapsedStepsLabel: i18n(\n 'i18nStrings.collapsedStepsLabel',\n rest.i18nStrings?.collapsedStepsLabel,\n format => (stepNumber, stepsCount) => format({ stepNumber, stepsCount })\n ),\n navigationAriaLabel: i18n('i18nStrings.navigationAriaLabel', rest.i18nStrings?.navigationAriaLabel),\n cancelButton: i18n('i18nStrings.cancelButton', rest.i18nStrings?.cancelButton),\n previousButton: i18n('i18nStrings.previousButton', rest.i18nStrings?.previousButton),\n nextButton: i18n('i18nStrings.nextButton', rest.i18nStrings?.nextButton),\n optional: i18n('i18nStrings.optional', rest.i18nStrings?.optional),\n };\n\n if (activeStepIndex && activeStepIndex >= steps.length) {\n warnOnce(\n 'Wizard',\n `You have set \\`activeStepIndex\\` to ${activeStepIndex} but you have provided only ${\n steps.length\n } steps. Its value is ignored and the component uses ${steps.length - 1} instead.`\n );\n }\n\n if (allowSkipTo && !skipToButtonLabel) {\n warnOnce(\n 'Wizard',\n `You have set \\`allowSkipTo\\` but you have not provided \\`i18nStrings.skipToButtonLabel\\`. The skip-to button will not be rendered.`\n );\n }\n\n return (\n <div {...baseProps} {...funnelProps} ref={ref} className={clsx(styles.root, baseProps.className)}>\n <div\n className={clsx(\n styles.wizard,\n isVisualRefresh && styles.refresh,\n smallContainer && styles['small-container'],\n shouldRemoveHighContrastHeader && styles['remove-high-contrast-header']\n )}\n >\n <WizardNavigation\n activeStepIndex={actualActiveStepIndex}\n farthestStepIndex={farthestStepIndex.current}\n allowSkipTo={allowSkipTo}\n hidden={smallContainer}\n i18nStrings={i18nStrings}\n isVisualRefresh={isVisualRefresh}\n isLoadingNextStep={isLoadingNextStep}\n onStepClick={onStepClick}\n onSkipToClick={onSkipToClick}\n steps={steps}\n />\n <div\n className={clsx(\n styles.form,\n isVisualRefresh && styles.refresh,\n smallContainer && styles['small-container'],\n shouldRemoveHighContrastHeader && styles['remove-high-contrast-header']\n )}\n >\n {isVisualRefresh && <div className={clsx(styles.background, contentHeaderClassName)} />}\n <WizardForm\n steps={steps}\n isVisualRefresh={isVisualRefresh}\n showCollapsedSteps={smallContainer}\n i18nStrings={i18nStrings}\n submitButtonText={submitButtonText}\n activeStepIndex={actualActiveStepIndex}\n isPrimaryLoading={isLoadingNextStep}\n allowSkipTo={allowSkipTo}\n secondaryActions={secondaryActions}\n onCancelClick={onCancelClick}\n onPreviousClick={onPreviousClick}\n onSkipToClick={onSkipToClick}\n onPrimaryClick={onPrimaryClick}\n />\n </div>\n </div>\n </div>\n );\n}\n"]}
|
|
@@ -1,36 +1,37 @@
|
|
|
1
1
|
|
|
2
2
|
import './styles.scoped.css';
|
|
3
3
|
export default {
|
|
4
|
-
"root": "
|
|
5
|
-
"wizard": "
|
|
6
|
-
"refresh": "
|
|
7
|
-
"small-container": "awsui_small-
|
|
8
|
-
"
|
|
9
|
-
"
|
|
10
|
-
"
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"
|
|
16
|
-
"form
|
|
17
|
-
"
|
|
18
|
-
"
|
|
19
|
-
"form-
|
|
20
|
-
"
|
|
21
|
-
"
|
|
22
|
-
"collapsed-steps
|
|
23
|
-
"
|
|
24
|
-
"form-header-component": "awsui_form-header-
|
|
25
|
-
"
|
|
26
|
-
"navigation-link
|
|
27
|
-
"navigation-link-
|
|
28
|
-
"navigation-link-
|
|
29
|
-
"navigation-link-
|
|
30
|
-
"
|
|
31
|
-
"
|
|
32
|
-
"
|
|
33
|
-
"
|
|
34
|
-
"
|
|
4
|
+
"root": "awsui_root_1xupv_1n2t9_94",
|
|
5
|
+
"wizard": "awsui_wizard_1xupv_1n2t9_129",
|
|
6
|
+
"refresh": "awsui_refresh_1xupv_1n2t9_129",
|
|
7
|
+
"small-container": "awsui_small-container_1xupv_1n2t9_136",
|
|
8
|
+
"remove-high-contrast-header": "awsui_remove-high-contrast-header_1xupv_1n2t9_140",
|
|
9
|
+
"navigation": "awsui_navigation_1xupv_1n2t9_148",
|
|
10
|
+
"number": "awsui_number_1xupv_1n2t9_212",
|
|
11
|
+
"circle": "awsui_circle_1xupv_1n2t9_228",
|
|
12
|
+
"title": "awsui_title_1xupv_1n2t9_236",
|
|
13
|
+
"active": "awsui_active_1xupv_1n2t9_264",
|
|
14
|
+
"disabled": "awsui_disabled_1xupv_1n2t9_275",
|
|
15
|
+
"enabled": "awsui_enabled_1xupv_1n2t9_285",
|
|
16
|
+
"form": "awsui_form_1xupv_1n2t9_326",
|
|
17
|
+
"form-header": "awsui_form-header_1xupv_1n2t9_331",
|
|
18
|
+
"background": "awsui_background_1xupv_1n2t9_341",
|
|
19
|
+
"form-header-content": "awsui_form-header-content_1xupv_1n2t9_353",
|
|
20
|
+
"form-component": "awsui_form-component_1xupv_1n2t9_361",
|
|
21
|
+
"hidden": "awsui_hidden_1xupv_1n2t9_375",
|
|
22
|
+
"collapsed-steps": "awsui_collapsed-steps_1xupv_1n2t9_379",
|
|
23
|
+
"collapsed-steps-hidden": "awsui_collapsed-steps-hidden_1xupv_1n2t9_384",
|
|
24
|
+
"form-header-component-wrapper": "awsui_form-header-component-wrapper_1xupv_1n2t9_388",
|
|
25
|
+
"form-header-component": "awsui_form-header-component_1xupv_1n2t9_388",
|
|
26
|
+
"navigation-link": "awsui_navigation-link_1xupv_1n2t9_401",
|
|
27
|
+
"navigation-link-item": "awsui_navigation-link-item_1xupv_1n2t9_402",
|
|
28
|
+
"navigation-link-label": "awsui_navigation-link-label_1xupv_1n2t9_403",
|
|
29
|
+
"navigation-link-active": "awsui_navigation-link-active_1xupv_1n2t9_407",
|
|
30
|
+
"navigation-link-disabled": "awsui_navigation-link-disabled_1xupv_1n2t9_412",
|
|
31
|
+
"cancel-button": "awsui_cancel-button_1xupv_1n2t9_416",
|
|
32
|
+
"previous-button": "awsui_previous-button_1xupv_1n2t9_417",
|
|
33
|
+
"primary-button": "awsui_primary-button_1xupv_1n2t9_418",
|
|
34
|
+
"skip-to-button": "awsui_skip-to-button_1xupv_1n2t9_419",
|
|
35
|
+
"action-buttons": "awsui_action-buttons_1xupv_1n2t9_423"
|
|
35
36
|
};
|
|
36
37
|
|