You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/ui-tray/src/Tray/README.md
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -25,9 +25,6 @@ The Tray is an actionable container that is triggered by click and does not need
25
25
renderCloseButton() {
26
26
return (
27
27
<Flex>
28
-
<Flex.Item shouldGrow shouldShrink>
29
-
<Heading>Hello</Heading>
30
-
</Flex.Item>
31
28
<Flex.Item>
32
29
<CloseButton
33
30
placement="end"
@@ -36,6 +33,9 @@ The Tray is an actionable container that is triggered by click and does not need
36
33
onClick={this.hideTray}
37
34
/>
38
35
</Flex.Item>
36
+
<Flex.Item shouldGrow shouldShrink>
37
+
<Heading>Hello</Heading>
38
+
</Flex.Item>
39
39
</Flex>
40
40
)
41
41
}
@@ -86,9 +86,6 @@ The Tray is an actionable container that is triggered by click and does not need
86
86
87
87
constrenderCloseButton= () => (
88
88
<Flex>
89
-
<Flex.Item shouldGrow shouldShrink>
90
-
<Heading>Hello</Heading>
91
-
</Flex.Item>
92
89
<Flex.Item>
93
90
<CloseButton
94
91
placement="end"
@@ -97,6 +94,9 @@ The Tray is an actionable container that is triggered by click and does not need
97
94
onClick={hideTray}
98
95
/>
99
96
</Flex.Item>
97
+
<Flex.Item shouldGrow shouldShrink>
98
+
<Heading>Hello</Heading>
99
+
</Flex.Item>
100
100
</Flex>
101
101
)
102
102
@@ -159,7 +159,7 @@ type: embed
159
159
<Figure.Item>Keyboard focus must be set in the tray when it appears; usually on the first interactive element</Figure.Item>
160
160
<Figure.Item>Trays must contain keyboard focus until they’re closed. This is to ensure that keyboard or screen reader users won't mistakenly interact with background content that is meant to be hidden or inaccessible</Figure.Item>
161
161
<Figure.Item>When a user closes a tray, focus must return to a logical place within the page. This is usually the element that triggered opening the tray</Figure.Item>
162
-
<Figure.Item>We recommend that trays begin with a heading (typically H2)</Figure.Item>
162
+
<Figure.Item>We recommend that trays begin with a heading (typically H2). However, when configuring the component, the button to close the Tray should precede the heading. This ensures screen readers announce the Tray's content in a logical order.</Figure.Item>
0 commit comments