Skip to content

Commit 8da0785

Browse files
satya07sbSatyapriya Bai
and
Satyapriya Bai
authored
[accessibility-3739618]:[Screen Reader - Azure Cosmos DB- Data Explorer - Graphs]: Screen Reader announces both expanded and collapsed information simultaneously for expand/collapse button in bottom notification region under 'Data Explorer' pane. (#2048)
Co-authored-by: Satyapriya Bai <[email protected]>
1 parent 4ac4103 commit 8da0785

File tree

2 files changed

+18
-18
lines changed

2 files changed

+18
-18
lines changed

src/Explorer/Menus/NotificationConsole/NotificationConsoleComponent.tsx

+6-6
Original file line numberDiff line numberDiff line change
@@ -109,15 +109,15 @@ export class NotificationConsoleComponent extends React.Component<
109109
<div className="statusBar">
110110
<span className="dataTypeIcons">
111111
<span className="notificationConsoleHeaderIconWithData">
112-
<img src={LoadingIcon} alt="in progress items" />
112+
<img src={LoadingIcon} alt="In progress items" />
113113
<span className="numInProgress">{numInProgress}</span>
114114
</span>
115115
<span className="notificationConsoleHeaderIconWithData">
116-
<img src={ErrorBlackIcon} alt="error items" />
116+
<img src={ErrorBlackIcon} alt="Error items" />
117117
<span className="numErroredItems">{numErroredItems}</span>
118118
</span>
119119
<span className="notificationConsoleHeaderIconWithData">
120-
<img src={infoBubbleIcon} alt="info items" />
120+
<img src={infoBubbleIcon} alt="Info items" />
121121
<span className="numInfoItems">{numInfoItems}</span>
122122
</span>
123123
</span>
@@ -134,12 +134,12 @@ export class NotificationConsoleComponent extends React.Component<
134134
data-test="NotificationConsole/ExpandCollapseButton"
135135
role="button"
136136
tabIndex={0}
137-
aria-label={"console button" + (this.props.isConsoleExpanded ? " expanded" : " collapsed")}
138-
aria-expanded={!this.props.isConsoleExpanded}
137+
aria-label="Console"
138+
aria-expanded={this.props.isConsoleExpanded}
139139
>
140140
<img
141141
src={this.props.isConsoleExpanded ? ChevronDownIcon : ChevronUpIcon}
142-
alt={this.props.isConsoleExpanded ? "ChevronDownIcon" : "ChevronUpIcon"}
142+
alt={this.props.isConsoleExpanded ? "Collapse icon" : "Expand icon"}
143143
/>
144144
</div>
145145
</div>

src/Explorer/Menus/NotificationConsole/__snapshots__/NotificationConsoleComponent.test.tsx.snap

+12-12
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ exports[`NotificationConsoleComponent renders the console 1`] = `
2121
className="notificationConsoleHeaderIconWithData"
2222
>
2323
<img
24-
alt="in progress items"
24+
alt="In progress items"
2525
src={{}}
2626
/>
2727
<span
@@ -34,7 +34,7 @@ exports[`NotificationConsoleComponent renders the console 1`] = `
3434
className="notificationConsoleHeaderIconWithData"
3535
>
3636
<img
37-
alt="error items"
37+
alt="Error items"
3838
src={{}}
3939
/>
4040
<span
@@ -47,7 +47,7 @@ exports[`NotificationConsoleComponent renders the console 1`] = `
4747
className="notificationConsoleHeaderIconWithData"
4848
>
4949
<img
50-
alt="info items"
50+
alt="Info items"
5151
src={{}}
5252
/>
5353
<span
@@ -71,15 +71,15 @@ exports[`NotificationConsoleComponent renders the console 1`] = `
7171
</span>
7272
</div>
7373
<div
74-
aria-expanded={true}
75-
aria-label="console button collapsed"
74+
aria-expanded={false}
75+
aria-label="Console"
7676
className="expandCollapseButton"
7777
data-test="NotificationConsole/ExpandCollapseButton"
7878
role="button"
7979
tabIndex={0}
8080
>
8181
<img
82-
alt="ChevronUpIcon"
82+
alt="Expand icon"
8383
src=""
8484
/>
8585
</div>
@@ -192,7 +192,7 @@ exports[`NotificationConsoleComponent renders the console 2`] = `
192192
className="notificationConsoleHeaderIconWithData"
193193
>
194194
<img
195-
alt="in progress items"
195+
alt="In progress items"
196196
src={{}}
197197
/>
198198
<span
@@ -205,7 +205,7 @@ exports[`NotificationConsoleComponent renders the console 2`] = `
205205
className="notificationConsoleHeaderIconWithData"
206206
>
207207
<img
208-
alt="error items"
208+
alt="Error items"
209209
src={{}}
210210
/>
211211
<span
@@ -218,7 +218,7 @@ exports[`NotificationConsoleComponent renders the console 2`] = `
218218
className="notificationConsoleHeaderIconWithData"
219219
>
220220
<img
221-
alt="info items"
221+
alt="Info items"
222222
src={{}}
223223
/>
224224
<span
@@ -244,15 +244,15 @@ exports[`NotificationConsoleComponent renders the console 2`] = `
244244
</span>
245245
</div>
246246
<div
247-
aria-expanded={true}
248-
aria-label="console button collapsed"
247+
aria-expanded={false}
248+
aria-label="Console"
249249
className="expandCollapseButton"
250250
data-test="NotificationConsole/ExpandCollapseButton"
251251
role="button"
252252
tabIndex={0}
253253
>
254254
<img
255-
alt="ChevronUpIcon"
255+
alt="Expand icon"
256256
src=""
257257
/>
258258
</div>

0 commit comments

Comments
 (0)