@cloudscape-design/components 3.0.850 → 3.0.852
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/app-layout/visual-refresh-toolbar/contexts.d.ts +1 -0
- package/app-layout/visual-refresh-toolbar/contexts.d.ts.map +1 -1
- package/app-layout/visual-refresh-toolbar/contexts.js +1 -0
- package/app-layout/visual-refresh-toolbar/contexts.js.map +1 -1
- package/app-layout/visual-refresh-toolbar/index.d.ts.map +1 -1
- package/app-layout/visual-refresh-toolbar/index.js +2 -1
- package/app-layout/visual-refresh-toolbar/index.js.map +1 -1
- package/autosuggest/internal.js +2 -2
- package/autosuggest/internal.js.map +1 -1
- package/calendar/internal.js +1 -1
- package/calendar/internal.js.map +1 -1
- package/collection-preferences/content-display/content-display-option.d.ts +2 -3
- package/collection-preferences/content-display/content-display-option.d.ts.map +1 -1
- package/collection-preferences/content-display/content-display-option.js +2 -5
- package/collection-preferences/content-display/content-display-option.js.map +1 -1
- package/collection-preferences/content-display/index.d.ts.map +1 -1
- package/collection-preferences/content-display/index.js +7 -2
- package/collection-preferences/content-display/index.js.map +1 -1
- package/internal/components/dnd-container/index.d.ts +3 -27
- package/internal/components/dnd-container/index.d.ts.map +1 -1
- package/internal/components/dnd-container/index.js +68 -38
- package/internal/components/dnd-container/index.js.map +1 -1
- package/internal/components/dnd-container/interfaces.d.ts +31 -4
- package/internal/components/dnd-container/interfaces.d.ts.map +1 -1
- package/internal/components/dnd-container/interfaces.js.map +1 -1
- package/internal/components/dnd-container/use-drag-and-drop-reorder.d.ts +6 -4
- package/internal/components/dnd-container/use-drag-and-drop-reorder.d.ts.map +1 -1
- package/internal/components/dnd-container/use-drag-and-drop-reorder.js +8 -8
- package/internal/components/dnd-container/use-drag-and-drop-reorder.js.map +1 -1
- package/internal/components/dnd-container/use-live-announcements.d.ts +4 -3
- package/internal/components/dnd-container/use-live-announcements.d.ts.map +1 -1
- package/internal/components/dnd-container/use-live-announcements.js +9 -9
- package/internal/components/dnd-container/use-live-announcements.js.map +1 -1
- package/internal/components/drag-handle/index.d.ts +1 -2
- package/internal/components/drag-handle/index.d.ts.map +1 -1
- package/internal/components/drag-handle/index.js +9 -4
- package/internal/components/drag-handle/index.js.map +1 -1
- package/internal/components/drag-handle/styles.css.js +3 -2
- package/internal/components/drag-handle/styles.scoped.css +180 -3
- package/internal/components/drag-handle/styles.selectors.js +3 -2
- package/internal/environment.js +1 -1
- package/internal/environment.json +1 -1
- package/internal/manifest.json +1 -1
- package/internal/plugins/helpers/use-global-breadcrumbs.d.ts.map +1 -1
- package/internal/plugins/helpers/use-global-breadcrumbs.js +5 -4
- package/internal/plugins/helpers/use-global-breadcrumbs.js.map +1 -1
- package/package.json +1 -1
- package/internal/components/handle/index.d.ts +0 -3
- package/internal/components/handle/index.d.ts.map +0 -1
- package/internal/components/handle/index.js +0 -14
- package/internal/components/handle/index.js.map +0 -1
- package/internal/components/handle/styles.css.js +0 -7
- package/internal/components/handle/styles.scoped.css +0 -183
- package/internal/components/handle/styles.selectors.js +0 -8
|
@@ -2,16 +2,193 @@
|
|
|
2
2
|
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
3
3
|
SPDX-License-Identifier: Apache-2.0
|
|
4
4
|
*/
|
|
5
|
-
|
|
5
|
+
/*
|
|
6
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
7
|
+
SPDX-License-Identifier: Apache-2.0
|
|
8
|
+
*/
|
|
9
|
+
/*
|
|
10
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
11
|
+
SPDX-License-Identifier: Apache-2.0
|
|
12
|
+
*/
|
|
13
|
+
/*
|
|
14
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
15
|
+
SPDX-License-Identifier: Apache-2.0
|
|
16
|
+
*/
|
|
17
|
+
/*
|
|
18
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
19
|
+
SPDX-License-Identifier: Apache-2.0
|
|
20
|
+
*/
|
|
21
|
+
/*
|
|
22
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
23
|
+
SPDX-License-Identifier: Apache-2.0
|
|
24
|
+
*/
|
|
25
|
+
/*
|
|
26
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
27
|
+
SPDX-License-Identifier: Apache-2.0
|
|
28
|
+
*/
|
|
29
|
+
/*
|
|
30
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
31
|
+
SPDX-License-Identifier: Apache-2.0
|
|
32
|
+
*/
|
|
33
|
+
/*
|
|
34
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
35
|
+
SPDX-License-Identifier: Apache-2.0
|
|
36
|
+
*/
|
|
37
|
+
/*
|
|
38
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
39
|
+
SPDX-License-Identifier: Apache-2.0
|
|
40
|
+
*/
|
|
41
|
+
/*
|
|
42
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
43
|
+
SPDX-License-Identifier: Apache-2.0
|
|
44
|
+
*/
|
|
45
|
+
/*
|
|
46
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
47
|
+
SPDX-License-Identifier: Apache-2.0
|
|
48
|
+
*/
|
|
49
|
+
/*
|
|
50
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
51
|
+
SPDX-License-Identifier: Apache-2.0
|
|
52
|
+
*/
|
|
53
|
+
/*
|
|
54
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
55
|
+
SPDX-License-Identifier: Apache-2.0
|
|
56
|
+
*/
|
|
57
|
+
/*
|
|
58
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
59
|
+
SPDX-License-Identifier: Apache-2.0
|
|
60
|
+
*/
|
|
61
|
+
/*
|
|
62
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
63
|
+
SPDX-License-Identifier: Apache-2.0
|
|
64
|
+
*/
|
|
65
|
+
/*
|
|
66
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
67
|
+
SPDX-License-Identifier: Apache-2.0
|
|
68
|
+
*/
|
|
69
|
+
/*
|
|
70
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
71
|
+
SPDX-License-Identifier: Apache-2.0
|
|
72
|
+
*/
|
|
73
|
+
/*
|
|
74
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
75
|
+
SPDX-License-Identifier: Apache-2.0
|
|
76
|
+
*/
|
|
77
|
+
/*
|
|
78
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
79
|
+
SPDX-License-Identifier: Apache-2.0
|
|
80
|
+
*/
|
|
81
|
+
/*
|
|
82
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
83
|
+
SPDX-License-Identifier: Apache-2.0
|
|
84
|
+
*/
|
|
85
|
+
/*
|
|
86
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
87
|
+
SPDX-License-Identifier: Apache-2.0
|
|
88
|
+
*/
|
|
89
|
+
/*
|
|
90
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
91
|
+
SPDX-License-Identifier: Apache-2.0
|
|
92
|
+
*/
|
|
93
|
+
/*
|
|
94
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
95
|
+
SPDX-License-Identifier: Apache-2.0
|
|
96
|
+
*/
|
|
97
|
+
/*
|
|
98
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
99
|
+
SPDX-License-Identifier: Apache-2.0
|
|
100
|
+
*/
|
|
101
|
+
/*
|
|
102
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
103
|
+
SPDX-License-Identifier: Apache-2.0
|
|
104
|
+
*/
|
|
105
|
+
/*
|
|
106
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
107
|
+
SPDX-License-Identifier: Apache-2.0
|
|
108
|
+
*/
|
|
109
|
+
/*
|
|
110
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
111
|
+
SPDX-License-Identifier: Apache-2.0
|
|
112
|
+
*/
|
|
113
|
+
/* stylelint-disable @cloudscape-design/no-motion-outside-of-mixin, selector-combinator-disallowed-list, selector-pseudo-class-no-unknown, selector-class-pattern */
|
|
114
|
+
/* stylelint-enable @cloudscape-design/no-motion-outside-of-mixin, selector-combinator-disallowed-list, selector-pseudo-class-no-unknown, selector-class-pattern */
|
|
115
|
+
/*
|
|
116
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
117
|
+
SPDX-License-Identifier: Apache-2.0
|
|
118
|
+
*/
|
|
119
|
+
/*
|
|
120
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
121
|
+
SPDX-License-Identifier: Apache-2.0
|
|
122
|
+
*/
|
|
123
|
+
/*
|
|
124
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
125
|
+
SPDX-License-Identifier: Apache-2.0
|
|
126
|
+
*/
|
|
127
|
+
/*
|
|
128
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
129
|
+
SPDX-License-Identifier: Apache-2.0
|
|
130
|
+
*/
|
|
131
|
+
/*
|
|
132
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
133
|
+
SPDX-License-Identifier: Apache-2.0
|
|
134
|
+
*/
|
|
135
|
+
/*
|
|
136
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
137
|
+
SPDX-License-Identifier: Apache-2.0
|
|
138
|
+
*/
|
|
139
|
+
/*
|
|
140
|
+
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
141
|
+
SPDX-License-Identifier: Apache-2.0
|
|
142
|
+
*/
|
|
143
|
+
/* Style used for links in slots/components that are text heavy, to help links stand out among
|
|
144
|
+
surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F73#description */
|
|
145
|
+
.awsui_handle_sdha6_yy78y_145:not(#\9) {
|
|
146
|
+
-webkit-appearance: none;
|
|
147
|
+
appearance: none;
|
|
148
|
+
background: transparent;
|
|
149
|
+
border-block: none;
|
|
150
|
+
border-inline: none;
|
|
151
|
+
padding-block: 0;
|
|
152
|
+
padding-inline: var(--space-scaled-xxxs-27y4hv, 2px);
|
|
153
|
+
margin-block: 0;
|
|
154
|
+
margin-inline: var(--space-scaled-xxs-7597g1, 4px);
|
|
155
|
+
color: var(--color-text-interactive-default-tkx8fe, #424650);
|
|
6
156
|
cursor: grab;
|
|
7
157
|
/* stylelint-disable-next-line plugin/no-unsupported-browser-features */
|
|
8
158
|
touch-action: none;
|
|
9
159
|
}
|
|
160
|
+
.awsui_handle_sdha6_yy78y_145:not(#\9):hover {
|
|
161
|
+
color: var(--color-text-interactive-hover-f9gqs8, #0f141a);
|
|
162
|
+
}
|
|
163
|
+
body[data-awsui-focus-visible=true] .awsui_handle_sdha6_yy78y_145:not(#\9):focus:not(.awsui_hide-focus_sdha6_yy78y_162) {
|
|
164
|
+
position: relative;
|
|
165
|
+
}
|
|
166
|
+
body[data-awsui-focus-visible=true] .awsui_handle_sdha6_yy78y_145:not(#\9):focus:not(.awsui_hide-focus_sdha6_yy78y_162) {
|
|
167
|
+
outline: 2px dotted transparent;
|
|
168
|
+
outline-offset: calc(0px - 1px);
|
|
169
|
+
}
|
|
170
|
+
body[data-awsui-focus-visible=true] .awsui_handle_sdha6_yy78y_145:not(#\9):focus:not(.awsui_hide-focus_sdha6_yy78y_162)::before {
|
|
171
|
+
content: " ";
|
|
172
|
+
display: block;
|
|
173
|
+
position: absolute;
|
|
174
|
+
inset-inline-start: calc(-1 * 0px);
|
|
175
|
+
inset-block-start: calc(-1 * 0px);
|
|
176
|
+
inline-size: calc(100% + 0px + 0px);
|
|
177
|
+
block-size: calc(100% + 0px + 0px);
|
|
178
|
+
border-start-start-radius: var(--border-radius-control-default-focus-ring-u8zbsz, 4px);
|
|
179
|
+
border-start-end-radius: var(--border-radius-control-default-focus-ring-u8zbsz, 4px);
|
|
180
|
+
border-end-start-radius: var(--border-radius-control-default-focus-ring-u8zbsz, 4px);
|
|
181
|
+
border-end-end-radius: var(--border-radius-control-default-focus-ring-u8zbsz, 4px);
|
|
182
|
+
box-shadow: 0 0 0 2px var(--color-border-item-focused-nv6mhz, #006ce0);
|
|
183
|
+
}
|
|
184
|
+
body[data-awsui-focus-visible=true] .awsui_handle_sdha6_yy78y_145:not(#\9):focus.awsui_hide-focus_sdha6_yy78y_162 {
|
|
185
|
+
outline: none;
|
|
186
|
+
}
|
|
10
187
|
|
|
11
|
-
.
|
|
188
|
+
.awsui_handle_sdha6_yy78y_145:not(#\9):active {
|
|
12
189
|
cursor: grabbing;
|
|
13
190
|
}
|
|
14
191
|
|
|
15
|
-
.awsui_handle-
|
|
192
|
+
.awsui_handle-disabled_sdha6_yy78y_191:not(#\9) {
|
|
16
193
|
cursor: default;
|
|
17
194
|
}
|
|
@@ -2,7 +2,8 @@
|
|
|
2
2
|
// es-module interop with Babel and Typescript
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
module.exports.default = {
|
|
5
|
-
"handle": "
|
|
6
|
-
"
|
|
5
|
+
"handle": "awsui_handle_sdha6_yy78y_145",
|
|
6
|
+
"hide-focus": "awsui_hide-focus_sdha6_yy78y_162",
|
|
7
|
+
"handle-disabled": "awsui_handle-disabled_sdha6_yy78y_191"
|
|
7
8
|
};
|
|
8
9
|
|
package/internal/environment.js
CHANGED
package/internal/manifest.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"use-global-breadcrumbs.d.ts","sourceRoot":"","sources":["../../../../../src/internal/plugins/helpers/use-global-breadcrumbs.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"use-global-breadcrumbs.d.ts","sourceRoot":"","sources":["../../../../../src/internal/plugins/helpers/use-global-breadcrumbs.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,oBAAoB,EAAE,MAAM,sCAAsC,CAAC;AAoC5E,wBAAgB,uBAAuB,CAAC,CAAC,SAAS,oBAAoB,CAAC,IAAI,EAAE,KAAK,EAAE,oBAAoB,CAAC,CAAC,CAAC,WAQ1G;AAED,wBAAgB,uBAAuB,CAAC,OAAO,EAAE,OAAO,oCAavD"}
|
|
@@ -3,16 +3,17 @@ import { __rest } from "tslib";
|
|
|
3
3
|
// SPDX-License-Identifier: Apache-2.0
|
|
4
4
|
import { useContext, useEffect, useLayoutEffect, useRef, useState } from 'react';
|
|
5
5
|
import { useAppLayoutToolbarEnabled } from '../../../app-layout/utils/feature-flags';
|
|
6
|
-
import { BreadcrumbsSlotContext } from '../../../app-layout/visual-refresh-toolbar/contexts';
|
|
6
|
+
import { AppLayoutVisibilityContext, BreadcrumbsSlotContext, } from '../../../app-layout/visual-refresh-toolbar/contexts';
|
|
7
7
|
import { awsuiPluginsInternal } from '../api';
|
|
8
8
|
function useSetGlobalBreadcrumbsImplementation(_a) {
|
|
9
|
-
var _b;
|
|
9
|
+
var _b, _c;
|
|
10
10
|
var { __disableGlobalization } = _a, props = __rest(_a, ["__disableGlobalization"]);
|
|
11
11
|
const { isInToolbar } = (_b = useContext(BreadcrumbsSlotContext)) !== null && _b !== void 0 ? _b : {};
|
|
12
|
+
const isLayoutVisible = (_c = useContext(AppLayoutVisibilityContext)) !== null && _c !== void 0 ? _c : true;
|
|
12
13
|
const registrationRef = useRef();
|
|
13
14
|
const [registered, setRegistered] = useState(false);
|
|
14
15
|
useEffect(() => {
|
|
15
|
-
if (isInToolbar || __disableGlobalization) {
|
|
16
|
+
if (isInToolbar || __disableGlobalization || !isLayoutVisible) {
|
|
16
17
|
return;
|
|
17
18
|
}
|
|
18
19
|
const registration = awsuiPluginsInternal.breadcrumbs.registerBreadcrumbs(props, isRegistered => setRegistered(isRegistered !== null && isRegistered !== void 0 ? isRegistered : true));
|
|
@@ -22,7 +23,7 @@ function useSetGlobalBreadcrumbsImplementation(_a) {
|
|
|
22
23
|
};
|
|
23
24
|
// subsequent prop changes are handled by another effect
|
|
24
25
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
25
|
-
}, [isInToolbar, __disableGlobalization]);
|
|
26
|
+
}, [isInToolbar, __disableGlobalization, isLayoutVisible]);
|
|
26
27
|
useLayoutEffect(() => {
|
|
27
28
|
var _a;
|
|
28
29
|
(_a = registrationRef.current) === null || _a === void 0 ? void 0 : _a.update(props);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"use-global-breadcrumbs.js","sourceRoot":"","sources":["../../../../../src/internal/plugins/helpers/use-global-breadcrumbs.ts"],"names":[],"mappings":";AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAEjF,OAAO,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AACrF,OAAO,
|
|
1
|
+
{"version":3,"file":"use-global-breadcrumbs.js","sourceRoot":"","sources":["../../../../../src/internal/plugins/helpers/use-global-breadcrumbs.ts"],"names":[],"mappings":";AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAEjF,OAAO,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AACrF,OAAO,EACL,0BAA0B,EAC1B,sBAAsB,GACvB,MAAM,qDAAqD,CAAC;AAE7D,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAC;AAG9C,SAAS,qCAAqC,CAAC,EAGoB;;QAHpB,EAC7C,sBAAsB,OAE2C,EAD9D,KAAK,cAFqC,0BAG9C,CADS;IAER,MAAM,EAAE,WAAW,EAAE,GAAG,MAAA,UAAU,CAAC,sBAAsB,CAAC,mCAAI,EAAE,CAAC;IACjE,MAAM,eAAe,GAAG,MAAA,UAAU,CAAC,0BAA0B,CAAC,mCAAI,IAAI,CAAC;IACvE,MAAM,eAAe,GAAG,MAAM,EAA8D,CAAC;IAC7F,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IAEpD,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,WAAW,IAAI,sBAAsB,IAAI,CAAC,eAAe,EAAE;YAC7D,OAAO;SACR;QACD,MAAM,YAAY,GAAG,oBAAoB,CAAC,WAAW,CAAC,mBAAmB,CAAC,KAAK,EAAE,YAAY,CAAC,EAAE,CAC9F,aAAa,CAAC,YAAY,aAAZ,YAAY,cAAZ,YAAY,GAAI,IAAI,CAAC,CACpC,CAAC;QACF,eAAe,CAAC,OAAO,GAAG,YAAY,CAAC;QAEvC,OAAO,GAAG,EAAE;YACV,YAAY,CAAC,OAAO,EAAE,CAAC;QACzB,CAAC,CAAC;QACF,wDAAwD;QACxD,uDAAuD;IACzD,CAAC,EAAE,CAAC,WAAW,EAAE,sBAAsB,EAAE,eAAe,CAAC,CAAC,CAAC;IAE3D,eAAe,CAAC,GAAG,EAAE;;QACnB,MAAA,eAAe,CAAC,OAAO,0CAAE,MAAM,CAAC,KAAK,CAAC,CAAC;IACzC,CAAC,CAAC,CAAC;IAEH,OAAO,UAAU,CAAC;AACpB,CAAC;AAED,MAAM,UAAU,uBAAuB,CAAsC,KAA8B;IACzG,gEAAgE;IAChE,IAAI,CAAC,0BAA0B,EAAE,EAAE;QACjC,OAAO,KAAK,CAAC;KACd;IACD,iEAAiE;IACjE,sDAAsD;IACtD,OAAO,qCAAqC,CAAC,KAAK,CAAC,CAAC;AACtD,CAAC;AAED,MAAM,UAAU,uBAAuB,CAAC,OAAgB;IACtD,MAAM,CAAC,qBAAqB,EAAE,wBAAwB,CAAC,GAAG,QAAQ,CAAmC,IAAI,CAAC,CAAC;IAE3G,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,CAAC,OAAO,EAAE;YACZ,OAAO;SACR;QACD,OAAO,oBAAoB,CAAC,WAAW,CAAC,iBAAiB,CAAC,WAAW,CAAC,EAAE;YACtE,wBAAwB,CAAC,WAAW,CAAC,CAAC;QACxC,CAAC,CAAC,CAAC;IACL,CAAC,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC;IAEd,OAAO,qBAAqB,CAAC;AAC/B,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { useContext, useEffect, useLayoutEffect, useRef, useState } from 'react';\n\nimport { useAppLayoutToolbarEnabled } from '../../../app-layout/utils/feature-flags';\nimport {\n AppLayoutVisibilityContext,\n BreadcrumbsSlotContext,\n} from '../../../app-layout/visual-refresh-toolbar/contexts';\nimport { BreadcrumbGroupProps } from '../../../breadcrumb-group/interfaces';\nimport { awsuiPluginsInternal } from '../api';\nimport { BreadcrumbsGlobalRegistration } from '../controllers/breadcrumbs';\n\nfunction useSetGlobalBreadcrumbsImplementation({\n __disableGlobalization,\n ...props\n}: BreadcrumbGroupProps<any> & { __disableGlobalization?: boolean }) {\n const { isInToolbar } = useContext(BreadcrumbsSlotContext) ?? {};\n const isLayoutVisible = useContext(AppLayoutVisibilityContext) ?? true;\n const registrationRef = useRef<BreadcrumbsGlobalRegistration<BreadcrumbGroupProps> | null>();\n const [registered, setRegistered] = useState(false);\n\n useEffect(() => {\n if (isInToolbar || __disableGlobalization || !isLayoutVisible) {\n return;\n }\n const registration = awsuiPluginsInternal.breadcrumbs.registerBreadcrumbs(props, isRegistered =>\n setRegistered(isRegistered ?? true)\n );\n registrationRef.current = registration;\n\n return () => {\n registration.cleanup();\n };\n // subsequent prop changes are handled by another effect\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [isInToolbar, __disableGlobalization, isLayoutVisible]);\n\n useLayoutEffect(() => {\n registrationRef.current?.update(props);\n });\n\n return registered;\n}\n\nexport function useSetGlobalBreadcrumbs<T extends BreadcrumbGroupProps.Item>(props: BreadcrumbGroupProps<T>) {\n // avoid additional side effects when this feature is not active\n if (!useAppLayoutToolbarEnabled()) {\n return false;\n }\n // getGlobalFlag() value does not change without full page reload\n // eslint-disable-next-line react-hooks/rules-of-hooks\n return useSetGlobalBreadcrumbsImplementation(props);\n}\n\nexport function useGetGlobalBreadcrumbs(enabled: boolean) {\n const [discoveredBreadcrumbs, setDiscoveredBreadcrumbs] = useState<BreadcrumbGroupProps<any> | null>(null);\n\n useEffect(() => {\n if (!enabled) {\n return;\n }\n return awsuiPluginsInternal.breadcrumbs.registerAppLayout(breadcrumbs => {\n setDiscoveredBreadcrumbs(breadcrumbs);\n });\n }, [enabled]);\n\n return discoveredBreadcrumbs;\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/handle/index.tsx"],"names":[],"mappings":"AAEA,OAAc,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAK9C,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,KAAK,EAAE,cAAc,CAAC,cAAc,CAAC,eAgBnE"}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
-
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
-
import React from 'react';
|
|
4
|
-
import clsx from 'clsx';
|
|
5
|
-
import styles from './styles.css.js';
|
|
6
|
-
export default function Handle(props) {
|
|
7
|
-
// We need to use a div with button role instead of a button
|
|
8
|
-
// so that Safari will focus on it when clicking it.
|
|
9
|
-
// (See https://bugs.webkit.org/show_bug.cgi?id=22261)
|
|
10
|
-
// Otherwise, we can't reliably catch keyboard events coming from the handle
|
|
11
|
-
// when it is being dragged.
|
|
12
|
-
return (React.createElement("div", Object.assign({ role: "button", tabIndex: 0 }, props, { onPointerDown: props.onPointerDown, className: clsx(styles.handle, props.className) })));
|
|
13
|
-
}
|
|
14
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/internal/components/handle/index.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAyB,MAAM,OAAO,CAAC;AAC9C,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,MAAM,MAAM,iBAAiB,CAAC;AAErC,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,KAAqC;IAClE,4DAA4D;IAC5D,oDAAoD;IACpD,sDAAsD;IACtD,4EAA4E;IAC5E,4BAA4B;IAE5B,OAAO,CACL,2CACE,IAAI,EAAC,QAAQ,EACb,QAAQ,EAAE,CAAC,IACP,KAAK,IACT,aAAa,EAAE,KAAK,CAAC,aAAa,EAClC,SAAS,EAAE,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,SAAS,CAAC,IAC/C,CACH,CAAC;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { HTMLAttributes } from 'react';\nimport clsx from 'clsx';\n\nimport styles from './styles.css.js';\n\nexport default function Handle(props: HTMLAttributes<HTMLDivElement>) {\n // We need to use a div with button role instead of a button\n // so that Safari will focus on it when clicking it.\n // (See https://bugs.webkit.org/show_bug.cgi?id=22261)\n // Otherwise, we can't reliably catch keyboard events coming from the handle\n // when it is being dragged.\n\n return (\n <div\n role=\"button\"\n tabIndex={0}\n {...props}\n onPointerDown={props.onPointerDown}\n className={clsx(styles.handle, props.className)}\n />\n );\n}\n"]}
|
|
@@ -1,183 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
3
|
-
SPDX-License-Identifier: Apache-2.0
|
|
4
|
-
*/
|
|
5
|
-
/*
|
|
6
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
7
|
-
SPDX-License-Identifier: Apache-2.0
|
|
8
|
-
*/
|
|
9
|
-
/*
|
|
10
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
11
|
-
SPDX-License-Identifier: Apache-2.0
|
|
12
|
-
*/
|
|
13
|
-
/*
|
|
14
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
15
|
-
SPDX-License-Identifier: Apache-2.0
|
|
16
|
-
*/
|
|
17
|
-
/*
|
|
18
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
19
|
-
SPDX-License-Identifier: Apache-2.0
|
|
20
|
-
*/
|
|
21
|
-
/*
|
|
22
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
23
|
-
SPDX-License-Identifier: Apache-2.0
|
|
24
|
-
*/
|
|
25
|
-
/*
|
|
26
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
27
|
-
SPDX-License-Identifier: Apache-2.0
|
|
28
|
-
*/
|
|
29
|
-
/*
|
|
30
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
31
|
-
SPDX-License-Identifier: Apache-2.0
|
|
32
|
-
*/
|
|
33
|
-
/*
|
|
34
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
35
|
-
SPDX-License-Identifier: Apache-2.0
|
|
36
|
-
*/
|
|
37
|
-
/*
|
|
38
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
39
|
-
SPDX-License-Identifier: Apache-2.0
|
|
40
|
-
*/
|
|
41
|
-
/*
|
|
42
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
43
|
-
SPDX-License-Identifier: Apache-2.0
|
|
44
|
-
*/
|
|
45
|
-
/*
|
|
46
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
47
|
-
SPDX-License-Identifier: Apache-2.0
|
|
48
|
-
*/
|
|
49
|
-
/*
|
|
50
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
51
|
-
SPDX-License-Identifier: Apache-2.0
|
|
52
|
-
*/
|
|
53
|
-
/*
|
|
54
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
55
|
-
SPDX-License-Identifier: Apache-2.0
|
|
56
|
-
*/
|
|
57
|
-
/*
|
|
58
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
59
|
-
SPDX-License-Identifier: Apache-2.0
|
|
60
|
-
*/
|
|
61
|
-
/*
|
|
62
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
63
|
-
SPDX-License-Identifier: Apache-2.0
|
|
64
|
-
*/
|
|
65
|
-
/*
|
|
66
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
67
|
-
SPDX-License-Identifier: Apache-2.0
|
|
68
|
-
*/
|
|
69
|
-
/*
|
|
70
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
71
|
-
SPDX-License-Identifier: Apache-2.0
|
|
72
|
-
*/
|
|
73
|
-
/*
|
|
74
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
75
|
-
SPDX-License-Identifier: Apache-2.0
|
|
76
|
-
*/
|
|
77
|
-
/*
|
|
78
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
79
|
-
SPDX-License-Identifier: Apache-2.0
|
|
80
|
-
*/
|
|
81
|
-
/*
|
|
82
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
83
|
-
SPDX-License-Identifier: Apache-2.0
|
|
84
|
-
*/
|
|
85
|
-
/*
|
|
86
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
87
|
-
SPDX-License-Identifier: Apache-2.0
|
|
88
|
-
*/
|
|
89
|
-
/*
|
|
90
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
91
|
-
SPDX-License-Identifier: Apache-2.0
|
|
92
|
-
*/
|
|
93
|
-
/*
|
|
94
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
95
|
-
SPDX-License-Identifier: Apache-2.0
|
|
96
|
-
*/
|
|
97
|
-
/*
|
|
98
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
99
|
-
SPDX-License-Identifier: Apache-2.0
|
|
100
|
-
*/
|
|
101
|
-
/*
|
|
102
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
103
|
-
SPDX-License-Identifier: Apache-2.0
|
|
104
|
-
*/
|
|
105
|
-
/*
|
|
106
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
107
|
-
SPDX-License-Identifier: Apache-2.0
|
|
108
|
-
*/
|
|
109
|
-
/*
|
|
110
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
111
|
-
SPDX-License-Identifier: Apache-2.0
|
|
112
|
-
*/
|
|
113
|
-
/* stylelint-disable @cloudscape-design/no-motion-outside-of-mixin, selector-combinator-disallowed-list, selector-pseudo-class-no-unknown, selector-class-pattern */
|
|
114
|
-
/* stylelint-enable @cloudscape-design/no-motion-outside-of-mixin, selector-combinator-disallowed-list, selector-pseudo-class-no-unknown, selector-class-pattern */
|
|
115
|
-
/*
|
|
116
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
117
|
-
SPDX-License-Identifier: Apache-2.0
|
|
118
|
-
*/
|
|
119
|
-
/*
|
|
120
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
121
|
-
SPDX-License-Identifier: Apache-2.0
|
|
122
|
-
*/
|
|
123
|
-
/*
|
|
124
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
125
|
-
SPDX-License-Identifier: Apache-2.0
|
|
126
|
-
*/
|
|
127
|
-
/*
|
|
128
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
129
|
-
SPDX-License-Identifier: Apache-2.0
|
|
130
|
-
*/
|
|
131
|
-
/*
|
|
132
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
133
|
-
SPDX-License-Identifier: Apache-2.0
|
|
134
|
-
*/
|
|
135
|
-
/*
|
|
136
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
137
|
-
SPDX-License-Identifier: Apache-2.0
|
|
138
|
-
*/
|
|
139
|
-
/*
|
|
140
|
-
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
141
|
-
SPDX-License-Identifier: Apache-2.0
|
|
142
|
-
*/
|
|
143
|
-
/* Style used for links in slots/components that are text heavy, to help links stand out among
|
|
144
|
-
surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F73#description */
|
|
145
|
-
.awsui_handle_iykw5_1fwr7_145:not(#\9) {
|
|
146
|
-
-webkit-appearance: none;
|
|
147
|
-
appearance: none;
|
|
148
|
-
background: transparent;
|
|
149
|
-
border-block: none;
|
|
150
|
-
border-inline: none;
|
|
151
|
-
padding-block: 0;
|
|
152
|
-
padding-inline: var(--space-scaled-xxxs-27y4hv, 2px);
|
|
153
|
-
margin-block: 0;
|
|
154
|
-
margin-inline: var(--space-scaled-xxs-7597g1, 4px);
|
|
155
|
-
color: var(--color-text-interactive-default-tkx8fe, #424650);
|
|
156
|
-
}
|
|
157
|
-
.awsui_handle_iykw5_1fwr7_145:not(#\9):hover {
|
|
158
|
-
color: var(--color-text-interactive-hover-f9gqs8, #0f141a);
|
|
159
|
-
}
|
|
160
|
-
body[data-awsui-focus-visible=true] .awsui_handle_iykw5_1fwr7_145:not(#\9):focus:not(.awsui_hide-focus_iykw5_1fwr7_159) {
|
|
161
|
-
position: relative;
|
|
162
|
-
}
|
|
163
|
-
body[data-awsui-focus-visible=true] .awsui_handle_iykw5_1fwr7_145:not(#\9):focus:not(.awsui_hide-focus_iykw5_1fwr7_159) {
|
|
164
|
-
outline: 2px dotted transparent;
|
|
165
|
-
outline-offset: calc(0px - 1px);
|
|
166
|
-
}
|
|
167
|
-
body[data-awsui-focus-visible=true] .awsui_handle_iykw5_1fwr7_145:not(#\9):focus:not(.awsui_hide-focus_iykw5_1fwr7_159)::before {
|
|
168
|
-
content: " ";
|
|
169
|
-
display: block;
|
|
170
|
-
position: absolute;
|
|
171
|
-
inset-inline-start: calc(-1 * 0px);
|
|
172
|
-
inset-block-start: calc(-1 * 0px);
|
|
173
|
-
inline-size: calc(100% + 0px + 0px);
|
|
174
|
-
block-size: calc(100% + 0px + 0px);
|
|
175
|
-
border-start-start-radius: var(--border-radius-control-default-focus-ring-u8zbsz, 4px);
|
|
176
|
-
border-start-end-radius: var(--border-radius-control-default-focus-ring-u8zbsz, 4px);
|
|
177
|
-
border-end-start-radius: var(--border-radius-control-default-focus-ring-u8zbsz, 4px);
|
|
178
|
-
border-end-end-radius: var(--border-radius-control-default-focus-ring-u8zbsz, 4px);
|
|
179
|
-
box-shadow: 0 0 0 2px var(--color-border-item-focused-nv6mhz, #006ce0);
|
|
180
|
-
}
|
|
181
|
-
body[data-awsui-focus-visible=true] .awsui_handle_iykw5_1fwr7_145:not(#\9):focus.awsui_hide-focus_iykw5_1fwr7_159 {
|
|
182
|
-
outline: none;
|
|
183
|
-
}
|