Skip to content

Commit b0e8c89

Browse files
committed
aria label based on the state
1 parent 1c27ee5 commit b0e8c89

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

packages/compass-data-modeling/src/components/diagram-editor-toolbar.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,11 @@ export const DiagramEditorToolbar: React.FunctionComponent<{
7373
<Tooltip
7474
trigger={
7575
<IconButton
76-
aria-label="Add Relationship"
76+
aria-label={
77+
!isInRelationshipDrawingMode
78+
? 'Add Relationship'
79+
: 'Exit Relationship Drawing Mode'
80+
}
7781
onClick={onRelationshipDrawingToggle}
7882
active={isInRelationshipDrawingMode}
7983
aria-pressed={isInRelationshipDrawingMode}

0 commit comments

Comments
 (0)