@cloudscape-design/components-themeable 3.0.1210 → 3.0.1212
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/internal/components/dropdown/styles.scss +3 -2
- package/lib/internal/scss/internal/generated/custom-css-properties/index.scss +140 -139
- package/lib/internal/template/alert/interfaces.d.ts +2 -0
- package/lib/internal/template/alert/interfaces.d.ts.map +1 -1
- package/lib/internal/template/alert/interfaces.js.map +1 -1
- package/lib/internal/template/alert/styles.css.js +27 -27
- package/lib/internal/template/alert/styles.scoped.css +50 -50
- package/lib/internal/template/alert/styles.selectors.js +27 -27
- package/lib/internal/template/annotation-context/annotation/styles.css.js +13 -13
- package/lib/internal/template/annotation-context/annotation/styles.scoped.css +21 -21
- package/lib/internal/template/annotation-context/annotation/styles.selectors.js +13 -13
- package/lib/internal/template/app-layout/notifications/styles.css.js +3 -3
- package/lib/internal/template/app-layout/notifications/styles.scoped.css +7 -7
- package/lib/internal/template/app-layout/notifications/styles.selectors.js +3 -3
- package/lib/internal/template/app-layout/visual-refresh/styles.css.js +86 -86
- package/lib/internal/template/app-layout/visual-refresh/styles.scoped.css +258 -258
- package/lib/internal/template/app-layout/visual-refresh/styles.selectors.js +86 -86
- package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/styles.css.js +30 -30
- package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/styles.scoped.css +87 -87
- package/lib/internal/template/app-layout/visual-refresh-toolbar/drawer/styles.selectors.js +30 -30
- package/lib/internal/template/app-layout/visual-refresh-toolbar/navigation/styles.css.js +4 -4
- package/lib/internal/template/app-layout/visual-refresh-toolbar/navigation/styles.scoped.css +7 -7
- package/lib/internal/template/app-layout/visual-refresh-toolbar/navigation/styles.selectors.js +4 -4
- package/lib/internal/template/app-layout/visual-refresh-toolbar/skeleton/styles.css.js +27 -27
- package/lib/internal/template/app-layout/visual-refresh-toolbar/skeleton/styles.scoped.css +54 -54
- package/lib/internal/template/app-layout/visual-refresh-toolbar/skeleton/styles.selectors.js +27 -27
- package/lib/internal/template/attribute-editor/styles.css.js +15 -15
- package/lib/internal/template/attribute-editor/styles.scoped.css +28 -28
- package/lib/internal/template/attribute-editor/styles.selectors.js +15 -15
- package/lib/internal/template/autosuggest/interfaces.d.ts +2 -0
- package/lib/internal/template/autosuggest/interfaces.d.ts.map +1 -1
- package/lib/internal/template/autosuggest/interfaces.js.map +1 -1
- package/lib/internal/template/badge/interfaces.d.ts +2 -0
- package/lib/internal/template/badge/interfaces.d.ts.map +1 -1
- package/lib/internal/template/badge/interfaces.js.map +1 -1
- package/lib/internal/template/breadcrumb-group/item/styles.css.js +7 -7
- package/lib/internal/template/breadcrumb-group/item/styles.scoped.css +28 -28
- package/lib/internal/template/breadcrumb-group/item/styles.selectors.js +7 -7
- package/lib/internal/template/button/interfaces.d.ts +2 -0
- package/lib/internal/template/button/interfaces.d.ts.map +1 -1
- package/lib/internal/template/button/interfaces.js.map +1 -1
- package/lib/internal/template/button/styles.css.js +22 -22
- package/lib/internal/template/button/styles.scoped.css +256 -256
- package/lib/internal/template/button/styles.selectors.js +22 -22
- package/lib/internal/template/button-dropdown/category-elements/expandable-category-element.js +1 -1
- package/lib/internal/template/button-dropdown/category-elements/expandable-category-element.js.map +1 -1
- package/lib/internal/template/button-dropdown/internal.d.ts.map +1 -1
- package/lib/internal/template/button-dropdown/internal.js +1 -1
- package/lib/internal/template/button-dropdown/internal.js.map +1 -1
- package/lib/internal/template/button-dropdown/item-element/styles.css.js +21 -21
- package/lib/internal/template/button-dropdown/item-element/styles.scoped.css +37 -37
- package/lib/internal/template/button-dropdown/item-element/styles.selectors.js +21 -21
- package/lib/internal/template/button-group/interfaces.d.ts +2 -0
- package/lib/internal/template/button-group/interfaces.d.ts.map +1 -1
- package/lib/internal/template/button-group/interfaces.js.map +1 -1
- package/lib/internal/template/checkbox/interfaces.d.ts +2 -0
- package/lib/internal/template/checkbox/interfaces.d.ts.map +1 -1
- package/lib/internal/template/checkbox/interfaces.js.map +1 -1
- package/lib/internal/template/checkbox/styles.css.js +3 -3
- package/lib/internal/template/checkbox/styles.scoped.css +11 -11
- package/lib/internal/template/checkbox/styles.selectors.js +3 -3
- package/lib/internal/template/column-layout/flexible-column-layout/index.js +2 -2
- package/lib/internal/template/column-layout/flexible-column-layout/index.js.map +1 -1
- package/lib/internal/template/column-layout/grid-column-layout.js +1 -1
- package/lib/internal/template/column-layout/grid-column-layout.js.map +1 -1
- package/lib/internal/template/container/interfaces.d.ts +2 -0
- package/lib/internal/template/container/interfaces.d.ts.map +1 -1
- package/lib/internal/template/container/interfaces.js.map +1 -1
- package/lib/internal/template/content-layout/styles.css.js +14 -14
- package/lib/internal/template/content-layout/styles.scoped.css +27 -27
- package/lib/internal/template/content-layout/styles.selectors.js +14 -14
- package/lib/internal/template/date-picker/index.d.ts.map +1 -1
- package/lib/internal/template/date-picker/index.js +1 -1
- package/lib/internal/template/date-picker/index.js.map +1 -1
- package/lib/internal/template/date-range-picker/index.d.ts.map +1 -1
- package/lib/internal/template/date-range-picker/index.js +1 -1
- package/lib/internal/template/date-range-picker/index.js.map +1 -1
- package/lib/internal/template/flashbar/interfaces.d.ts +2 -0
- package/lib/internal/template/flashbar/interfaces.d.ts.map +1 -1
- package/lib/internal/template/flashbar/interfaces.js.map +1 -1
- package/lib/internal/template/flashbar/styles.css.js +50 -50
- package/lib/internal/template/flashbar/styles.scoped.css +187 -187
- package/lib/internal/template/flashbar/styles.selectors.js +50 -50
- package/lib/internal/template/grid/internal.d.ts.map +1 -1
- package/lib/internal/template/grid/internal.js +2 -2
- package/lib/internal/template/grid/internal.js.map +1 -1
- package/lib/internal/template/help-panel/styles.css.js +6 -6
- package/lib/internal/template/help-panel/styles.scoped.css +73 -73
- package/lib/internal/template/help-panel/styles.selectors.js +6 -6
- package/lib/internal/template/input/interfaces.d.ts +2 -0
- package/lib/internal/template/input/interfaces.d.ts.map +1 -1
- package/lib/internal/template/input/interfaces.js.map +1 -1
- package/lib/internal/template/input/styles.css.js +13 -13
- package/lib/internal/template/input/styles.scoped.css +74 -74
- package/lib/internal/template/input/styles.selectors.js +13 -13
- package/lib/internal/template/internal/base-component/styles.scoped.css +1 -1
- package/lib/internal/template/internal/components/autosuggest-input/index.d.ts.map +1 -1
- package/lib/internal/template/internal/components/autosuggest-input/index.js +2 -1
- package/lib/internal/template/internal/components/autosuggest-input/index.js.map +1 -1
- package/lib/internal/template/internal/components/drag-handle-wrapper/styles.css.js +30 -30
- package/lib/internal/template/internal/components/drag-handle-wrapper/styles.scoped.css +58 -58
- package/lib/internal/template/internal/components/drag-handle-wrapper/styles.selectors.js +30 -30
- package/lib/internal/template/internal/components/dropdown/dropdown-fit-handler.d.ts +9 -9
- package/lib/internal/template/internal/components/dropdown/dropdown-fit-handler.d.ts.map +1 -1
- package/lib/internal/template/internal/components/dropdown/dropdown-fit-handler.js +22 -23
- package/lib/internal/template/internal/components/dropdown/dropdown-fit-handler.js.map +1 -1
- package/lib/internal/template/internal/components/dropdown/dropdown-position.d.ts.map +1 -1
- package/lib/internal/template/internal/components/dropdown/dropdown-position.js +4 -1
- package/lib/internal/template/internal/components/dropdown/dropdown-position.js.map +1 -1
- package/lib/internal/template/internal/components/dropdown/index.d.ts +1 -1
- package/lib/internal/template/internal/components/dropdown/index.d.ts.map +1 -1
- package/lib/internal/template/internal/components/dropdown/index.js +54 -30
- package/lib/internal/template/internal/components/dropdown/index.js.map +1 -1
- package/lib/internal/template/internal/components/dropdown/interfaces.d.ts +33 -18
- package/lib/internal/template/internal/components/dropdown/interfaces.d.ts.map +1 -1
- package/lib/internal/template/internal/components/dropdown/interfaces.js.map +1 -1
- package/lib/internal/template/internal/components/dropdown/styles.css.js +20 -20
- package/lib/internal/template/internal/components/dropdown/styles.scoped.css +39 -38
- package/lib/internal/template/internal/components/dropdown/styles.selectors.js +20 -20
- package/lib/internal/template/internal/components/radio-button/interfaces.d.ts +2 -0
- package/lib/internal/template/internal/components/radio-button/interfaces.d.ts.map +1 -1
- package/lib/internal/template/internal/components/radio-button/interfaces.js.map +1 -1
- package/lib/internal/template/internal/components/radio-button/styles.css.js +7 -7
- package/lib/internal/template/internal/components/radio-button/styles.scoped.css +18 -18
- package/lib/internal/template/internal/components/radio-button/styles.selectors.js +7 -7
- package/lib/internal/template/internal/components/token-list/styles.css.js +10 -10
- package/lib/internal/template/internal/components/token-list/styles.scoped.css +25 -25
- package/lib/internal/template/internal/components/token-list/styles.selectors.js +10 -10
- package/lib/internal/template/internal/environment.js +2 -2
- package/lib/internal/template/internal/environment.json +2 -2
- package/lib/internal/template/internal/generated/custom-css-properties/index.d.ts +1 -0
- package/lib/internal/template/internal/generated/custom-css-properties/index.d.ts.map +1 -1
- package/lib/internal/template/internal/generated/custom-css-properties/index.js +139 -138
- package/lib/internal/template/internal/generated/custom-css-properties/index.js.map +1 -1
- package/lib/internal/template/internal/hooks/use-base-component/styles-check.d.ts +1 -2
- package/lib/internal/template/internal/hooks/use-base-component/styles-check.d.ts.map +1 -1
- package/lib/internal/template/internal/hooks/use-base-component/styles-check.js +27 -7
- package/lib/internal/template/internal/hooks/use-base-component/styles-check.js.map +1 -1
- package/lib/internal/template/internal/utils/flatten-children.d.ts +3 -0
- package/lib/internal/template/internal/utils/flatten-children.d.ts.map +1 -0
- package/lib/internal/template/internal/utils/flatten-children.js +17 -0
- package/lib/internal/template/internal/utils/flatten-children.js.map +1 -0
- package/lib/internal/template/link/interfaces.d.ts +2 -0
- package/lib/internal/template/link/interfaces.d.ts.map +1 -1
- package/lib/internal/template/link/interfaces.js.map +1 -1
- package/lib/internal/template/link/styles.css.js +20 -20
- package/lib/internal/template/link/styles.scoped.css +103 -103
- package/lib/internal/template/link/styles.selectors.js +20 -20
- package/lib/internal/template/multiselect/internal.d.ts.map +1 -1
- package/lib/internal/template/multiselect/internal.js +2 -1
- package/lib/internal/template/multiselect/internal.js.map +1 -1
- package/lib/internal/template/multiselect/use-multiselect.d.ts +1 -1
- package/lib/internal/template/progress-bar/interfaces.d.ts +2 -0
- package/lib/internal/template/progress-bar/interfaces.d.ts.map +1 -1
- package/lib/internal/template/progress-bar/interfaces.js.map +1 -1
- package/lib/internal/template/progress-bar/styles.css.js +18 -18
- package/lib/internal/template/progress-bar/styles.scoped.css +48 -48
- package/lib/internal/template/progress-bar/styles.selectors.js +18 -18
- package/lib/internal/template/prompt-input/interfaces.d.ts +2 -0
- package/lib/internal/template/prompt-input/interfaces.d.ts.map +1 -1
- package/lib/internal/template/prompt-input/interfaces.js.map +1 -1
- package/lib/internal/template/prompt-input/styles.css.js +17 -17
- package/lib/internal/template/prompt-input/styles.scoped.css +79 -79
- package/lib/internal/template/prompt-input/styles.selectors.js +17 -17
- package/lib/internal/template/radio-group/interfaces.d.ts +2 -0
- package/lib/internal/template/radio-group/interfaces.d.ts.map +1 -1
- package/lib/internal/template/radio-group/interfaces.js.map +1 -1
- package/lib/internal/template/segmented-control/interfaces.d.ts +2 -0
- package/lib/internal/template/segmented-control/interfaces.d.ts.map +1 -1
- package/lib/internal/template/segmented-control/interfaces.js.map +1 -1
- package/lib/internal/template/segmented-control/styles.css.js +16 -16
- package/lib/internal/template/segmented-control/styles.scoped.css +46 -46
- package/lib/internal/template/segmented-control/styles.selectors.js +16 -16
- package/lib/internal/template/select/internal.d.ts.map +1 -1
- package/lib/internal/template/select/internal.js +2 -1
- package/lib/internal/template/select/internal.js.map +1 -1
- package/lib/internal/template/select/utils/use-select.d.ts +1 -1
- package/lib/internal/template/select/utils/use-select.d.ts.map +1 -1
- package/lib/internal/template/select/utils/use-select.js +1 -1
- package/lib/internal/template/select/utils/use-select.js.map +1 -1
- package/lib/internal/template/slider/interfaces.d.ts +2 -0
- package/lib/internal/template/slider/interfaces.d.ts.map +1 -1
- package/lib/internal/template/slider/interfaces.js.map +1 -1
- package/lib/internal/template/slider/styles.css.js +26 -26
- package/lib/internal/template/slider/styles.scoped.css +165 -165
- package/lib/internal/template/slider/styles.selectors.js +26 -26
- package/lib/internal/template/space-between/internal.d.ts.map +1 -1
- package/lib/internal/template/space-between/internal.js +4 -3
- package/lib/internal/template/space-between/internal.js.map +1 -1
- package/lib/internal/template/spinner/styles.css.js +13 -13
- package/lib/internal/template/spinner/styles.scoped.css +39 -39
- package/lib/internal/template/spinner/styles.selectors.js +13 -13
- package/lib/internal/template/tabs/interfaces.d.ts +2 -0
- package/lib/internal/template/tabs/interfaces.d.ts.map +1 -1
- package/lib/internal/template/tabs/interfaces.js.map +1 -1
- package/lib/internal/template/tabs/styles.css.js +30 -30
- package/lib/internal/template/tabs/styles.scoped.css +76 -76
- package/lib/internal/template/tabs/styles.selectors.js +30 -30
- package/lib/internal/template/tag-editor/styles.css.js +3 -3
- package/lib/internal/template/tag-editor/styles.scoped.css +13 -13
- package/lib/internal/template/tag-editor/styles.selectors.js +3 -3
- package/lib/internal/template/text-content/styles.css.js +1 -1
- package/lib/internal/template/text-content/styles.scoped.css +66 -66
- package/lib/internal/template/text-content/styles.selectors.js +1 -1
- package/lib/internal/template/text-filter/interfaces.d.ts +2 -0
- package/lib/internal/template/text-filter/interfaces.d.ts.map +1 -1
- package/lib/internal/template/text-filter/interfaces.js.map +1 -1
- package/lib/internal/template/textarea/interfaces.d.ts +2 -0
- package/lib/internal/template/textarea/interfaces.d.ts.map +1 -1
- package/lib/internal/template/textarea/interfaces.js.map +1 -1
- package/lib/internal/template/textarea/styles.css.js +5 -5
- package/lib/internal/template/textarea/styles.scoped.css +45 -45
- package/lib/internal/template/textarea/styles.selectors.js +5 -5
- package/lib/internal/template/toggle/interfaces.d.ts +2 -0
- package/lib/internal/template/toggle/interfaces.d.ts.map +1 -1
- package/lib/internal/template/toggle/interfaces.js.map +1 -1
- package/lib/internal/template/toggle/styles.css.js +10 -10
- package/lib/internal/template/toggle/styles.scoped.css +23 -23
- package/lib/internal/template/toggle/styles.selectors.js +10 -10
- package/package.json +1 -1
|
@@ -150,27 +150,27 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
150
150
|
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
151
151
|
SPDX-License-Identifier: Apache-2.0
|
|
152
152
|
*/
|
|
153
|
-
@keyframes awsui_drag-handle-
|
|
153
|
+
@keyframes awsui_drag-handle-entry_155yk_ea0dq_1 {
|
|
154
154
|
from {
|
|
155
|
-
transform: translate(var(--awsui-drag-handle-animation-inline-offset-
|
|
155
|
+
transform: translate(var(--awsui-drag-handle-animation-inline-offset-c5ek4l), var(--awsui-drag-handle-animation-block-offset-c5ek4l));
|
|
156
156
|
}
|
|
157
157
|
to {
|
|
158
158
|
transform: translate(0, 0);
|
|
159
159
|
}
|
|
160
160
|
}
|
|
161
|
-
@keyframes awsui_drag-handle-
|
|
161
|
+
@keyframes awsui_drag-handle-exit_155yk_ea0dq_1 {
|
|
162
162
|
from {
|
|
163
163
|
transform: translate(0, 0);
|
|
164
164
|
}
|
|
165
165
|
to {
|
|
166
|
-
transform: translate(var(--awsui-drag-handle-animation-inline-offset-
|
|
166
|
+
transform: translate(var(--awsui-drag-handle-animation-inline-offset-c5ek4l), var(--awsui-drag-handle-animation-block-offset-c5ek4l));
|
|
167
167
|
}
|
|
168
168
|
}
|
|
169
|
-
.awsui_direction-button-
|
|
170
|
-
--awsui-drag-handle-animation-inline-offset-
|
|
171
|
-
--awsui-drag-handle-animation-block-offset-
|
|
169
|
+
.awsui_direction-button-wrapper_155yk_ea0dq_169:not(#\9) {
|
|
170
|
+
--awsui-drag-handle-animation-inline-offset-c5ek4l: 0;
|
|
171
|
+
--awsui-drag-handle-animation-block-offset-c5ek4l: 0;
|
|
172
172
|
}
|
|
173
|
-
@keyframes awsui_awsui-motion-fade-
|
|
173
|
+
@keyframes awsui_awsui-motion-fade-in_155yk_ea0dq_1 {
|
|
174
174
|
from {
|
|
175
175
|
opacity: 0.2;
|
|
176
176
|
}
|
|
@@ -178,7 +178,7 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
178
178
|
opacity: 1;
|
|
179
179
|
}
|
|
180
180
|
}
|
|
181
|
-
@keyframes awsui_awsui-motion-fade-out-
|
|
181
|
+
@keyframes awsui_awsui-motion-fade-out-0_155yk_ea0dq_1 {
|
|
182
182
|
from {
|
|
183
183
|
opacity: 1;
|
|
184
184
|
}
|
|
@@ -186,81 +186,81 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
186
186
|
opacity: 0;
|
|
187
187
|
}
|
|
188
188
|
}
|
|
189
|
-
.awsui_direction-button-wrapper-motion-
|
|
189
|
+
.awsui_direction-button-wrapper-motion-enter_155yk_ea0dq_189:not(#\9), .awsui_direction-button-wrapper-motion-entering_155yk_ea0dq_189:not(#\9), .awsui_direction-button-wrapper-motion-exit_155yk_ea0dq_189:not(#\9), .awsui_direction-button-wrapper-motion-exiting_155yk_ea0dq_189:not(#\9) {
|
|
190
190
|
pointer-events: none;
|
|
191
191
|
}
|
|
192
|
-
.awsui_direction-button-wrapper-motion-
|
|
193
|
-
animation: awsui_drag-handle-
|
|
192
|
+
.awsui_direction-button-wrapper-motion-entering_155yk_ea0dq_189:not(#\9) {
|
|
193
|
+
animation: awsui_drag-handle-entry_155yk_ea0dq_1 var(--motion-duration-complex-hv88cf, 270ms) var(--motion-easing-responsive-dxkfpl, ease-out), awsui_awsui-motion-fade-in_155yk_ea0dq_1 var(--motion-duration-complex-hv88cf, 270ms) var(--motion-easing-responsive-dxkfpl, ease-out);
|
|
194
194
|
}
|
|
195
195
|
@media (prefers-reduced-motion: reduce) {
|
|
196
|
-
.awsui_direction-button-wrapper-motion-
|
|
196
|
+
.awsui_direction-button-wrapper-motion-entering_155yk_ea0dq_189:not(#\9) {
|
|
197
197
|
animation: none;
|
|
198
198
|
transition: none;
|
|
199
199
|
}
|
|
200
200
|
}
|
|
201
|
-
.awsui-motion-disabled .awsui_direction-button-wrapper-motion-
|
|
201
|
+
.awsui-motion-disabled .awsui_direction-button-wrapper-motion-entering_155yk_ea0dq_189:not(#\9), .awsui-mode-entering .awsui_direction-button-wrapper-motion-entering_155yk_ea0dq_189:not(#\9) {
|
|
202
202
|
animation: none;
|
|
203
203
|
transition: none;
|
|
204
204
|
}
|
|
205
|
-
.awsui_direction-button-wrapper-motion-
|
|
206
|
-
animation: awsui_drag-handle-
|
|
205
|
+
.awsui_direction-button-wrapper-motion-exiting_155yk_ea0dq_189:not(#\9) {
|
|
206
|
+
animation: awsui_drag-handle-exit_155yk_ea0dq_1 var(--motion-duration-complex-hv88cf, 270ms) var(--motion-easing-responsive-dxkfpl, ease-out) forwards, awsui_awsui-motion-fade-out-0_155yk_ea0dq_1 var(--motion-duration-complex-hv88cf, 270ms) var(--motion-easing-responsive-dxkfpl, ease-out) forwards;
|
|
207
207
|
}
|
|
208
208
|
@media (prefers-reduced-motion: reduce) {
|
|
209
|
-
.awsui_direction-button-wrapper-motion-
|
|
209
|
+
.awsui_direction-button-wrapper-motion-exiting_155yk_ea0dq_189:not(#\9) {
|
|
210
210
|
animation: none;
|
|
211
211
|
transition: none;
|
|
212
212
|
}
|
|
213
213
|
}
|
|
214
|
-
.awsui-motion-disabled .awsui_direction-button-wrapper-motion-
|
|
214
|
+
.awsui-motion-disabled .awsui_direction-button-wrapper-motion-exiting_155yk_ea0dq_189:not(#\9), .awsui-mode-entering .awsui_direction-button-wrapper-motion-exiting_155yk_ea0dq_189:not(#\9) {
|
|
215
215
|
animation: none;
|
|
216
216
|
transition: none;
|
|
217
217
|
}
|
|
218
218
|
@media (prefers-reduced-motion: reduce) {
|
|
219
|
-
.awsui_direction-button-
|
|
219
|
+
.awsui_direction-button-wrapper_155yk_ea0dq_169:not(#\9) {
|
|
220
220
|
animation: none;
|
|
221
221
|
transition: none;
|
|
222
222
|
}
|
|
223
223
|
}
|
|
224
|
-
.awsui-motion-disabled .awsui_direction-button-
|
|
224
|
+
.awsui-motion-disabled .awsui_direction-button-wrapper_155yk_ea0dq_169:not(#\9), .awsui-mode-entering .awsui_direction-button-wrapper_155yk_ea0dq_169:not(#\9) {
|
|
225
225
|
animation: none;
|
|
226
226
|
transition: none;
|
|
227
227
|
}
|
|
228
228
|
|
|
229
|
-
.awsui_direction-button-wrapper-block-
|
|
230
|
-
--awsui-drag-handle-animation-block-offset-
|
|
229
|
+
.awsui_direction-button-wrapper-block-start_155yk_ea0dq_229:not(#\9) {
|
|
230
|
+
--awsui-drag-handle-animation-block-offset-c5ek4l: 20px;
|
|
231
231
|
}
|
|
232
232
|
|
|
233
|
-
.awsui_direction-button-wrapper-block-
|
|
234
|
-
--awsui-drag-handle-animation-block-offset-
|
|
233
|
+
.awsui_direction-button-wrapper-block-end_155yk_ea0dq_233:not(#\9) {
|
|
234
|
+
--awsui-drag-handle-animation-block-offset-c5ek4l: -20px;
|
|
235
235
|
}
|
|
236
236
|
|
|
237
|
-
.awsui_direction-button-wrapper-inline-
|
|
237
|
+
.awsui_direction-button-wrapper-inline-start_155yk_ea0dq_237:not(#\9) {
|
|
238
238
|
/* stylelint-disable-next-line plugin/no-unsupported-browser-features */
|
|
239
239
|
/* stylelint-disable-next-line plugin/no-unsupported-browser-features */
|
|
240
240
|
}
|
|
241
|
-
.awsui_direction-button-wrapper-inline-
|
|
242
|
-
--awsui-drag-handle-animation-inline-offset-
|
|
241
|
+
.awsui_direction-button-wrapper-inline-start_155yk_ea0dq_237:not(#\9):dir(ltr) {
|
|
242
|
+
--awsui-drag-handle-animation-inline-offset-c5ek4l: 20px;
|
|
243
243
|
}
|
|
244
|
-
.awsui_direction-button-wrapper-inline-
|
|
245
|
-
--awsui-drag-handle-animation-inline-offset-
|
|
244
|
+
.awsui_direction-button-wrapper-inline-start_155yk_ea0dq_237:not(#\9):dir(rtl) {
|
|
245
|
+
--awsui-drag-handle-animation-inline-offset-c5ek4l: -20px;
|
|
246
246
|
}
|
|
247
247
|
|
|
248
|
-
.awsui_direction-button-wrapper-inline-
|
|
248
|
+
.awsui_direction-button-wrapper-inline-end_155yk_ea0dq_248:not(#\9) {
|
|
249
249
|
/* stylelint-disable-next-line plugin/no-unsupported-browser-features */
|
|
250
250
|
/* stylelint-disable-next-line plugin/no-unsupported-browser-features */
|
|
251
251
|
}
|
|
252
|
-
.awsui_direction-button-wrapper-inline-
|
|
253
|
-
--awsui-drag-handle-animation-inline-offset-
|
|
252
|
+
.awsui_direction-button-wrapper-inline-end_155yk_ea0dq_248:not(#\9):dir(ltr) {
|
|
253
|
+
--awsui-drag-handle-animation-inline-offset-c5ek4l: -20px;
|
|
254
254
|
}
|
|
255
|
-
.awsui_direction-button-wrapper-inline-
|
|
256
|
-
--awsui-drag-handle-animation-inline-offset-
|
|
255
|
+
.awsui_direction-button-wrapper-inline-end_155yk_ea0dq_248:not(#\9):dir(rtl) {
|
|
256
|
+
--awsui-drag-handle-animation-inline-offset-c5ek4l: 20px;
|
|
257
257
|
}
|
|
258
258
|
|
|
259
|
-
.
|
|
259
|
+
.awsui_contents_155yk_ea0dq_259:not(#\9) {
|
|
260
260
|
display: contents;
|
|
261
261
|
}
|
|
262
262
|
|
|
263
|
-
.awsui_portal-
|
|
263
|
+
.awsui_portal-overlay_155yk_ea0dq_263:not(#\9) {
|
|
264
264
|
position: absolute;
|
|
265
265
|
inset-block-start: 0;
|
|
266
266
|
inset-inline-start: 0;
|
|
@@ -268,20 +268,20 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
268
268
|
z-index: 7000;
|
|
269
269
|
}
|
|
270
270
|
|
|
271
|
-
.awsui_portal-overlay-
|
|
271
|
+
.awsui_portal-overlay-disabled_155yk_ea0dq_271:not(#\9) {
|
|
272
272
|
display: none;
|
|
273
273
|
}
|
|
274
274
|
|
|
275
|
-
.awsui_portal-overlay-
|
|
275
|
+
.awsui_portal-overlay-contents_155yk_ea0dq_275:not(#\9) {
|
|
276
276
|
pointer-events: auto;
|
|
277
277
|
}
|
|
278
278
|
|
|
279
|
-
.awsui_drag-
|
|
279
|
+
.awsui_drag-handle_155yk_ea0dq_279:not(#\9) {
|
|
280
280
|
position: relative;
|
|
281
281
|
display: inline-flex;
|
|
282
282
|
}
|
|
283
283
|
|
|
284
|
-
.awsui_direction-button-
|
|
284
|
+
.awsui_direction-button-wrapper_155yk_ea0dq_169:not(#\9) {
|
|
285
285
|
position: absolute;
|
|
286
286
|
block-size: var(--space-static-xl-pek4x1, 24px);
|
|
287
287
|
inline-size: var(--space-static-xl-pek4x1, 24px);
|
|
@@ -289,67 +289,67 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
289
289
|
padding-inline: var(--space-static-xxs-0cgyf1, 4px);
|
|
290
290
|
}
|
|
291
291
|
|
|
292
|
-
.awsui_direction-button-wrapper-
|
|
292
|
+
.awsui_direction-button-wrapper-hidden_155yk_ea0dq_292:not(#\9) {
|
|
293
293
|
display: none;
|
|
294
294
|
}
|
|
295
295
|
|
|
296
|
-
.awsui_direction-button-wrapper-block-
|
|
296
|
+
.awsui_direction-button-wrapper-block-start_155yk_ea0dq_229:not(#\9) {
|
|
297
297
|
inset-block-start: calc(-1 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
298
298
|
inset-inline-start: calc(50% - (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)) / 2);
|
|
299
299
|
}
|
|
300
300
|
|
|
301
|
-
.awsui_direction-button-wrapper-block-
|
|
301
|
+
.awsui_direction-button-wrapper-block-end_155yk_ea0dq_233:not(#\9) {
|
|
302
302
|
inset-block-end: calc(-1 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
303
303
|
inset-inline-start: calc(50% - (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)) / 2);
|
|
304
304
|
}
|
|
305
305
|
|
|
306
|
-
.awsui_direction-button-wrapper-inline-
|
|
306
|
+
.awsui_direction-button-wrapper-inline-start_155yk_ea0dq_237:not(#\9) {
|
|
307
307
|
inset-inline-start: calc(-1 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
308
308
|
inset-block-start: calc(50% - (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)) / 2);
|
|
309
309
|
}
|
|
310
310
|
|
|
311
|
-
.awsui_direction-button-wrapper-inline-
|
|
311
|
+
.awsui_direction-button-wrapper-inline-end_155yk_ea0dq_248:not(#\9) {
|
|
312
312
|
inset-inline-end: calc(-1 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
313
313
|
inset-block-start: calc(50% - (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)) / 2);
|
|
314
314
|
}
|
|
315
315
|
|
|
316
|
-
.awsui_direction-button-wrapper-
|
|
316
|
+
.awsui_direction-button-wrapper-forced_155yk_ea0dq_316:not(#\9) {
|
|
317
317
|
inset-inline-start: calc(50% - (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)) / 2);
|
|
318
318
|
}
|
|
319
319
|
|
|
320
|
-
.awsui_direction-button-wrapper-forced-top-
|
|
320
|
+
.awsui_direction-button-wrapper-forced-top-0_155yk_ea0dq_320:not(#\9) {
|
|
321
321
|
inset-block-start: calc(-1 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
322
322
|
}
|
|
323
323
|
|
|
324
|
-
.awsui_direction-button-wrapper-forced-top-
|
|
324
|
+
.awsui_direction-button-wrapper-forced-top-1_155yk_ea0dq_324:not(#\9) {
|
|
325
325
|
inset-block-start: calc(-2 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
326
326
|
}
|
|
327
327
|
|
|
328
|
-
.awsui_direction-button-wrapper-forced-top-
|
|
328
|
+
.awsui_direction-button-wrapper-forced-top-2_155yk_ea0dq_328:not(#\9) {
|
|
329
329
|
inset-block-start: calc(-3 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
330
330
|
}
|
|
331
331
|
|
|
332
|
-
.awsui_direction-button-wrapper-forced-top-
|
|
332
|
+
.awsui_direction-button-wrapper-forced-top-3_155yk_ea0dq_332:not(#\9) {
|
|
333
333
|
inset-block-start: calc(-4 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
334
334
|
}
|
|
335
335
|
|
|
336
|
-
.awsui_direction-button-wrapper-forced-bottom-
|
|
336
|
+
.awsui_direction-button-wrapper-forced-bottom-0_155yk_ea0dq_336:not(#\9) {
|
|
337
337
|
inset-block-start: calc(1 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
338
338
|
}
|
|
339
339
|
|
|
340
|
-
.awsui_direction-button-wrapper-forced-bottom-
|
|
340
|
+
.awsui_direction-button-wrapper-forced-bottom-1_155yk_ea0dq_340:not(#\9) {
|
|
341
341
|
inset-block-start: calc(2 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
342
342
|
}
|
|
343
343
|
|
|
344
|
-
.awsui_direction-button-wrapper-forced-bottom-
|
|
344
|
+
.awsui_direction-button-wrapper-forced-bottom-2_155yk_ea0dq_344:not(#\9) {
|
|
345
345
|
inset-block-start: calc(3 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
346
346
|
}
|
|
347
347
|
|
|
348
|
-
.awsui_direction-button-wrapper-forced-bottom-
|
|
348
|
+
.awsui_direction-button-wrapper-forced-bottom-3_155yk_ea0dq_348:not(#\9) {
|
|
349
349
|
inset-block-start: calc(4 * (var(--space-static-xl-pek4x1, 24px) + 2 * var(--space-static-xxs-0cgyf1, 4px)));
|
|
350
350
|
}
|
|
351
351
|
|
|
352
|
-
.awsui_direction-
|
|
352
|
+
.awsui_direction-button_155yk_ea0dq_169:not(#\9) {
|
|
353
353
|
position: absolute;
|
|
354
354
|
border-width: 0;
|
|
355
355
|
cursor: pointer;
|
|
@@ -368,14 +368,14 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
368
368
|
color: var(--color-text-direction-button-default-dkices, #ffffff);
|
|
369
369
|
box-shadow: var(--shadow-dropdown-skxpuu, 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));
|
|
370
370
|
}
|
|
371
|
-
.awsui_direction-
|
|
371
|
+
.awsui_direction-button_155yk_ea0dq_169:not(#\9):not(.awsui_direction-button-disabled_155yk_ea0dq_371):hover {
|
|
372
372
|
background-color: var(--color-background-direction-button-hover-v5bxfc, #414750);
|
|
373
373
|
}
|
|
374
|
-
.awsui_direction-
|
|
374
|
+
.awsui_direction-button_155yk_ea0dq_169:not(#\9):not(.awsui_direction-button-disabled_155yk_ea0dq_371):active {
|
|
375
375
|
background-color: var(--color-background-direction-button-active-wn6s2j, #2a2e33);
|
|
376
376
|
}
|
|
377
377
|
|
|
378
|
-
.awsui_direction-button-
|
|
378
|
+
.awsui_direction-button-disabled_155yk_ea0dq_371:not(#\9) {
|
|
379
379
|
cursor: default;
|
|
380
380
|
background-color: var(--color-background-direction-button-disabled-rcznmi, #eaeded);
|
|
381
381
|
color: var(--color-text-direction-button-disabled-596cgx, #aab7b8);
|
|
@@ -2,35 +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
|
-
"direction-button-wrapper": "awsui_direction-button-
|
|
6
|
-
"direction-button-wrapper-motion-enter": "awsui_direction-button-wrapper-motion-
|
|
7
|
-
"direction-button-wrapper-motion-entering": "awsui_direction-button-wrapper-motion-
|
|
8
|
-
"direction-button-wrapper-motion-exit": "awsui_direction-button-wrapper-motion-
|
|
9
|
-
"direction-button-wrapper-motion-exiting": "awsui_direction-button-wrapper-motion-
|
|
10
|
-
"drag-handle-entry": "awsui_drag-handle-
|
|
11
|
-
"awsui-motion-fade-in": "awsui_awsui-motion-fade-
|
|
12
|
-
"drag-handle-exit": "awsui_drag-handle-
|
|
13
|
-
"awsui-motion-fade-out-0": "awsui_awsui-motion-fade-out-
|
|
14
|
-
"direction-button-wrapper-block-start": "awsui_direction-button-wrapper-block-
|
|
15
|
-
"direction-button-wrapper-block-end": "awsui_direction-button-wrapper-block-
|
|
16
|
-
"direction-button-wrapper-inline-start": "awsui_direction-button-wrapper-inline-
|
|
17
|
-
"direction-button-wrapper-inline-end": "awsui_direction-button-wrapper-inline-
|
|
18
|
-
"contents": "
|
|
19
|
-
"portal-overlay": "awsui_portal-
|
|
20
|
-
"portal-overlay-disabled": "awsui_portal-overlay-
|
|
21
|
-
"portal-overlay-contents": "awsui_portal-overlay-
|
|
22
|
-
"drag-handle": "awsui_drag-
|
|
23
|
-
"direction-button-wrapper-hidden": "awsui_direction-button-wrapper-
|
|
24
|
-
"direction-button-wrapper-forced": "awsui_direction-button-wrapper-
|
|
25
|
-
"direction-button-wrapper-forced-top-0": "awsui_direction-button-wrapper-forced-top-
|
|
26
|
-
"direction-button-wrapper-forced-top-1": "awsui_direction-button-wrapper-forced-top-
|
|
27
|
-
"direction-button-wrapper-forced-top-2": "awsui_direction-button-wrapper-forced-top-
|
|
28
|
-
"direction-button-wrapper-forced-top-3": "awsui_direction-button-wrapper-forced-top-
|
|
29
|
-
"direction-button-wrapper-forced-bottom-0": "awsui_direction-button-wrapper-forced-bottom-
|
|
30
|
-
"direction-button-wrapper-forced-bottom-1": "awsui_direction-button-wrapper-forced-bottom-
|
|
31
|
-
"direction-button-wrapper-forced-bottom-2": "awsui_direction-button-wrapper-forced-bottom-
|
|
32
|
-
"direction-button-wrapper-forced-bottom-3": "awsui_direction-button-wrapper-forced-bottom-
|
|
33
|
-
"direction-button": "awsui_direction-
|
|
34
|
-
"direction-button-disabled": "awsui_direction-button-
|
|
5
|
+
"direction-button-wrapper": "awsui_direction-button-wrapper_155yk_ea0dq_169",
|
|
6
|
+
"direction-button-wrapper-motion-enter": "awsui_direction-button-wrapper-motion-enter_155yk_ea0dq_189",
|
|
7
|
+
"direction-button-wrapper-motion-entering": "awsui_direction-button-wrapper-motion-entering_155yk_ea0dq_189",
|
|
8
|
+
"direction-button-wrapper-motion-exit": "awsui_direction-button-wrapper-motion-exit_155yk_ea0dq_189",
|
|
9
|
+
"direction-button-wrapper-motion-exiting": "awsui_direction-button-wrapper-motion-exiting_155yk_ea0dq_189",
|
|
10
|
+
"drag-handle-entry": "awsui_drag-handle-entry_155yk_ea0dq_1",
|
|
11
|
+
"awsui-motion-fade-in": "awsui_awsui-motion-fade-in_155yk_ea0dq_1",
|
|
12
|
+
"drag-handle-exit": "awsui_drag-handle-exit_155yk_ea0dq_1",
|
|
13
|
+
"awsui-motion-fade-out-0": "awsui_awsui-motion-fade-out-0_155yk_ea0dq_1",
|
|
14
|
+
"direction-button-wrapper-block-start": "awsui_direction-button-wrapper-block-start_155yk_ea0dq_229",
|
|
15
|
+
"direction-button-wrapper-block-end": "awsui_direction-button-wrapper-block-end_155yk_ea0dq_233",
|
|
16
|
+
"direction-button-wrapper-inline-start": "awsui_direction-button-wrapper-inline-start_155yk_ea0dq_237",
|
|
17
|
+
"direction-button-wrapper-inline-end": "awsui_direction-button-wrapper-inline-end_155yk_ea0dq_248",
|
|
18
|
+
"contents": "awsui_contents_155yk_ea0dq_259",
|
|
19
|
+
"portal-overlay": "awsui_portal-overlay_155yk_ea0dq_263",
|
|
20
|
+
"portal-overlay-disabled": "awsui_portal-overlay-disabled_155yk_ea0dq_271",
|
|
21
|
+
"portal-overlay-contents": "awsui_portal-overlay-contents_155yk_ea0dq_275",
|
|
22
|
+
"drag-handle": "awsui_drag-handle_155yk_ea0dq_279",
|
|
23
|
+
"direction-button-wrapper-hidden": "awsui_direction-button-wrapper-hidden_155yk_ea0dq_292",
|
|
24
|
+
"direction-button-wrapper-forced": "awsui_direction-button-wrapper-forced_155yk_ea0dq_316",
|
|
25
|
+
"direction-button-wrapper-forced-top-0": "awsui_direction-button-wrapper-forced-top-0_155yk_ea0dq_320",
|
|
26
|
+
"direction-button-wrapper-forced-top-1": "awsui_direction-button-wrapper-forced-top-1_155yk_ea0dq_324",
|
|
27
|
+
"direction-button-wrapper-forced-top-2": "awsui_direction-button-wrapper-forced-top-2_155yk_ea0dq_328",
|
|
28
|
+
"direction-button-wrapper-forced-top-3": "awsui_direction-button-wrapper-forced-top-3_155yk_ea0dq_332",
|
|
29
|
+
"direction-button-wrapper-forced-bottom-0": "awsui_direction-button-wrapper-forced-bottom-0_155yk_ea0dq_336",
|
|
30
|
+
"direction-button-wrapper-forced-bottom-1": "awsui_direction-button-wrapper-forced-bottom-1_155yk_ea0dq_340",
|
|
31
|
+
"direction-button-wrapper-forced-bottom-2": "awsui_direction-button-wrapper-forced-bottom-2_155yk_ea0dq_344",
|
|
32
|
+
"direction-button-wrapper-forced-bottom-3": "awsui_direction-button-wrapper-forced-bottom-3_155yk_ea0dq_348",
|
|
33
|
+
"direction-button": "awsui_direction-button_155yk_ea0dq_169",
|
|
34
|
+
"direction-button-disabled": "awsui_direction-button-disabled_155yk_ea0dq_371"
|
|
35
35
|
};
|
|
36
36
|
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { BoundingBox } from '../../utils/scrollable-containers';
|
|
2
2
|
import { LogicalDOMRect } from './dropdown-position';
|
|
3
|
+
import { DropdownWidthConstraint } from './interfaces';
|
|
3
4
|
export interface DropdownPosition {
|
|
4
5
|
blockSize: string;
|
|
5
6
|
inlineSize: string;
|
|
@@ -11,26 +12,25 @@ export interface InteriorDropdownPosition extends DropdownPosition {
|
|
|
11
12
|
insetBlockEnd: string;
|
|
12
13
|
insetBlockStart: string;
|
|
13
14
|
}
|
|
14
|
-
export declare const
|
|
15
|
-
export declare const hasEnoughSpaceToStretchBeyondTriggerWidth: ({ triggerElement, dropdownElement, desiredMinWidth, expandToViewport, stretchWidth, stretchHeight, isMobile, }: {
|
|
15
|
+
export declare const hasEnoughSpaceForFlexibleWidth: ({ triggerElement, dropdownElement, minWidthConstraint, maxWidthConstraint, expandToViewport, stretchHeight, isMobile, }: {
|
|
16
16
|
triggerElement: HTMLElement;
|
|
17
17
|
dropdownElement: HTMLElement;
|
|
18
|
-
|
|
18
|
+
minWidthConstraint?: DropdownWidthConstraint;
|
|
19
|
+
maxWidthConstraint?: DropdownWidthConstraint;
|
|
19
20
|
expandToViewport: boolean;
|
|
20
|
-
stretchWidth: boolean;
|
|
21
21
|
stretchHeight: boolean;
|
|
22
22
|
isMobile: boolean;
|
|
23
23
|
}) => boolean;
|
|
24
|
-
export declare const getDropdownPosition: ({ triggerElement, dropdownElement, overflowParents, minWidth:
|
|
24
|
+
export declare const getDropdownPosition: ({ triggerElement, dropdownElement, overflowParents, minWidth: minWidthConstraint, maxWidth: maxWidthConstraint, preferCenter, matchTriggerWidth, stretchHeight, isMobile, }: {
|
|
25
25
|
triggerElement: HTMLElement;
|
|
26
26
|
dropdownElement: HTMLElement;
|
|
27
27
|
overflowParents: ReadonlyArray<BoundingBox>;
|
|
28
|
-
minWidth?:
|
|
28
|
+
minWidth?: DropdownWidthConstraint;
|
|
29
|
+
maxWidth?: DropdownWidthConstraint;
|
|
29
30
|
preferCenter?: boolean;
|
|
30
|
-
|
|
31
|
+
matchTriggerWidth?: boolean;
|
|
31
32
|
stretchHeight?: boolean;
|
|
32
33
|
isMobile?: boolean;
|
|
33
|
-
stretchBeyondTriggerWidth?: boolean;
|
|
34
34
|
}) => DropdownPosition;
|
|
35
|
-
export declare const calculatePosition: (dropdownElement: HTMLDivElement, triggerElement: HTMLDivElement, verticalContainerElement: HTMLDivElement, interior: boolean, expandToViewport: boolean, preferCenter: boolean,
|
|
35
|
+
export declare const calculatePosition: (dropdownElement: HTMLDivElement, triggerElement: HTMLDivElement, verticalContainerElement: HTMLDivElement, interior: boolean, expandToViewport: boolean, preferCenter: boolean, matchTriggerWidth: boolean, stretchHeight: boolean, isMobile: boolean, minWidth?: DropdownWidthConstraint, maxWidth?: DropdownWidthConstraint) => [DropdownPosition, LogicalDOMRect];
|
|
36
36
|
//# sourceMappingURL=dropdown-fit-handler.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dropdown-fit-handler.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/dropdown/dropdown-fit-handler.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"dropdown-fit-handler.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/dropdown/dropdown-fit-handler.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAmD,MAAM,mCAAmC,CAAC;AACjH,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AACrD,OAAO,EAAE,uBAAuB,EAAE,MAAM,cAAc,CAAC;AAcvD,MAAM,WAAW,gBAAgB;IAC/B,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,OAAO,CAAC;IACxB,eAAe,EAAE,OAAO,CAAC;IACzB,gBAAgB,EAAE,MAAM,CAAC;CAC1B;AACD,MAAM,WAAW,wBAAyB,SAAQ,gBAAgB;IAChE,aAAa,EAAE,MAAM,CAAC;IACtB,eAAe,EAAE,MAAM,CAAC;CACzB;AAkKD,eAAO,MAAM,8BAA8B,GAAI,yHAQ5C;IACD,cAAc,EAAE,WAAW,CAAC;IAC5B,eAAe,EAAE,WAAW,CAAC;IAC7B,kBAAkB,CAAC,EAAE,uBAAuB,CAAC;IAC7C,kBAAkB,CAAC,EAAE,uBAAuB,CAAC;IAC7C,gBAAgB,EAAE,OAAO,CAAC;IAC1B,aAAa,EAAE,OAAO,CAAC;IACvB,QAAQ,EAAE,OAAO,CAAC;CACnB,YAoBA,CAAC;AAEF,eAAO,MAAM,mBAAmB,GAAI,6KAUjC;IACD,cAAc,EAAE,WAAW,CAAC;IAC5B,eAAe,EAAE,WAAW,CAAC;IAC7B,eAAe,EAAE,aAAa,CAAC,WAAW,CAAC,CAAC;IAC5C,QAAQ,CAAC,EAAE,uBAAuB,CAAC;IACnC,QAAQ,CAAC,EAAE,uBAAuB,CAAC;IACnC,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,KAAG,gBA0DH,CAAC;AAkDF,eAAO,MAAM,iBAAiB,GAC5B,iBAAiB,cAAc,EAC/B,gBAAgB,cAAc,EAC9B,0BAA0B,cAAc,EACxC,UAAU,OAAO,EACjB,kBAAkB,OAAO,EACzB,cAAc,OAAO,EACrB,mBAAmB,OAAO,EAC1B,eAAe,OAAO,EACtB,UAAU,OAAO,EACjB,WAAW,uBAAuB,EAClC,WAAW,uBAAuB,KACjC,CAAC,gBAAgB,EAAE,cAAc,CAkCnC,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 { getLogicalBoundingClientRect } from '@cloudscape-design/component-toolkit/internal';
|
|
4
|
-
import { getBreakpointValue } from '../../breakpoints';
|
|
5
4
|
import { getOverflowParentDimensions, getOverflowParents } from '../../utils/scrollable-containers';
|
|
6
5
|
import styles from './styles.css.js';
|
|
7
6
|
const AVAILABLE_SPACE_RESERVE_DEFAULT = 50;
|
|
@@ -19,9 +18,6 @@ const getClosestParentDimensions = (element) => {
|
|
|
19
18
|
});
|
|
20
19
|
return parents.shift();
|
|
21
20
|
};
|
|
22
|
-
// By default, most dropdowns should expand their content as necessary, but to a maximum of 465px (the XXS breakpoint).
|
|
23
|
-
// This value was determined by UX but may be subject to change in the future, depending on the feedback.
|
|
24
|
-
export const defaultMaxDropdownWidth = getBreakpointValue('xxs');
|
|
25
21
|
const getAvailableSpace = ({ trigger, overflowParents, stretchWidth = false, stretchHeight = false, isMobile, }) => {
|
|
26
22
|
const availableSpaceReserveVertical = stretchHeight
|
|
27
23
|
? 0
|
|
@@ -88,20 +84,24 @@ const getInteriorAvailableSpace = ({ trigger, overflowParents, isMobile, }) => {
|
|
|
88
84
|
inlineEnd: Number.MAX_VALUE,
|
|
89
85
|
});
|
|
90
86
|
};
|
|
91
|
-
const
|
|
92
|
-
|
|
87
|
+
const resolveWidthConstraint = (constraint, triggerWidth, fallback) => {
|
|
88
|
+
if (constraint === 'trigger') {
|
|
89
|
+
return triggerWidth;
|
|
90
|
+
}
|
|
91
|
+
if (typeof constraint === 'number') {
|
|
92
|
+
return constraint;
|
|
93
|
+
}
|
|
94
|
+
return fallback;
|
|
95
|
+
};
|
|
96
|
+
const getWidths = ({ triggerElement, dropdownElement, minWidthConstraint, maxWidthConstraint, }) => {
|
|
93
97
|
const { inlineSize: triggerInlineSize } = getLogicalBoundingClientRect(triggerElement);
|
|
94
|
-
// Minimum width is determined by either an explicit number (desiredMinWidth) or the trigger width
|
|
95
|
-
const minWidth = desiredMinWidth ? Math.min(triggerInlineSize, desiredMinWidth) : triggerInlineSize;
|
|
96
|
-
// If stretchBeyondTriggerWidth is true, the maximum width is the XS breakpoint (465px) or the trigger width (if bigger).
|
|
97
|
-
const maxWidth = stretchBeyondTriggerWidth ? Math.max(defaultMaxDropdownWidth, triggerInlineSize) : Number.MAX_VALUE;
|
|
98
|
-
// Determine the actual dropdown width, the size that it "wants" to be
|
|
99
98
|
const { inlineSize: requiredWidth } = getLogicalBoundingClientRect(dropdownElement);
|
|
100
|
-
|
|
99
|
+
const minWidth = resolveWidthConstraint(minWidthConstraint, triggerInlineSize, 0);
|
|
100
|
+
const maxWidth = resolveWidthConstraint(maxWidthConstraint, triggerInlineSize, Number.MAX_VALUE);
|
|
101
101
|
const idealWidth = Math.min(Math.max(requiredWidth, minWidth), maxWidth);
|
|
102
102
|
return { idealWidth, minWidth, triggerInlineSize };
|
|
103
103
|
};
|
|
104
|
-
export const
|
|
104
|
+
export const hasEnoughSpaceForFlexibleWidth = ({ triggerElement, dropdownElement, minWidthConstraint, maxWidthConstraint, expandToViewport, stretchHeight, isMobile, }) => {
|
|
105
105
|
const overflowParents = getOverflowParentDimensions({
|
|
106
106
|
element: dropdownElement,
|
|
107
107
|
excludeClosestParent: false,
|
|
@@ -111,32 +111,31 @@ export const hasEnoughSpaceToStretchBeyondTriggerWidth = ({ triggerElement, drop
|
|
|
111
111
|
const { idealWidth } = getWidths({
|
|
112
112
|
triggerElement: triggerElement,
|
|
113
113
|
dropdownElement,
|
|
114
|
-
|
|
115
|
-
|
|
114
|
+
minWidthConstraint,
|
|
115
|
+
maxWidthConstraint,
|
|
116
116
|
});
|
|
117
117
|
const availableSpace = getAvailableSpace({
|
|
118
118
|
trigger: triggerElement,
|
|
119
119
|
overflowParents,
|
|
120
|
-
stretchWidth,
|
|
121
120
|
stretchHeight,
|
|
122
121
|
isMobile,
|
|
123
122
|
});
|
|
124
123
|
return idealWidth <= availableSpace.inlineStart || idealWidth <= availableSpace.inlineEnd;
|
|
125
124
|
};
|
|
126
|
-
export const getDropdownPosition = ({ triggerElement, dropdownElement, overflowParents, minWidth:
|
|
125
|
+
export const getDropdownPosition = ({ triggerElement, dropdownElement, overflowParents, minWidth: minWidthConstraint, maxWidth: maxWidthConstraint, preferCenter = false, matchTriggerWidth = false, stretchHeight = false, isMobile = false, }) => {
|
|
127
126
|
// Determine the space available around the dropdown that it can grow in
|
|
128
127
|
const availableSpace = getAvailableSpace({
|
|
129
128
|
trigger: triggerElement,
|
|
130
129
|
overflowParents,
|
|
131
|
-
stretchWidth,
|
|
130
|
+
stretchWidth: matchTriggerWidth,
|
|
132
131
|
stretchHeight,
|
|
133
132
|
isMobile,
|
|
134
133
|
});
|
|
135
134
|
const { idealWidth, minWidth, triggerInlineSize } = getWidths({
|
|
136
135
|
triggerElement,
|
|
137
136
|
dropdownElement,
|
|
138
|
-
|
|
139
|
-
|
|
137
|
+
minWidthConstraint,
|
|
138
|
+
maxWidthConstraint,
|
|
140
139
|
});
|
|
141
140
|
let dropInlineStart;
|
|
142
141
|
let insetInlineStart = null;
|
|
@@ -209,7 +208,7 @@ const getInteriorDropdownPosition = (trigger, dropdown, overflowParents, isMobil
|
|
|
209
208
|
insetInlineStart: `${insetInlineStart}px`,
|
|
210
209
|
};
|
|
211
210
|
};
|
|
212
|
-
export const calculatePosition = (dropdownElement, triggerElement, verticalContainerElement, interior, expandToViewport, preferCenter,
|
|
211
|
+
export const calculatePosition = (dropdownElement, triggerElement, verticalContainerElement, interior, expandToViewport, preferCenter, matchTriggerWidth, stretchHeight, isMobile, minWidth, maxWidth) => {
|
|
213
212
|
// cleaning previously assigned values,
|
|
214
213
|
// so that they are not reused in case of screen resize and similar events
|
|
215
214
|
verticalContainerElement.style.maxBlockSize = '';
|
|
@@ -233,11 +232,11 @@ export const calculatePosition = (dropdownElement, triggerElement, verticalConta
|
|
|
233
232
|
dropdownElement,
|
|
234
233
|
overflowParents,
|
|
235
234
|
minWidth,
|
|
235
|
+
maxWidth,
|
|
236
236
|
preferCenter,
|
|
237
|
-
|
|
237
|
+
matchTriggerWidth,
|
|
238
238
|
stretchHeight,
|
|
239
239
|
isMobile,
|
|
240
|
-
stretchBeyondTriggerWidth,
|
|
241
240
|
});
|
|
242
241
|
const triggerBox = getLogicalBoundingClientRect(triggerElement);
|
|
243
242
|
return [position, triggerBox];
|