-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[MOO-809]: Implement a11y for pluggable widgets #21
base: main
Are you sure you want to change the base?
Conversation
23d72ce
to
3109960
Compare
3109960
to
3d406f4
Compare
return visible ? ( | ||
<View style={style.container}> | ||
<Pressable | ||
style={[style.header.container, icon === "left" && { flexDirection: "row-reverse" }]} | ||
onPress={collapsible ? () => onPressGroupHeader(group, index) : null} | ||
accessible={isAccessible} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure if this is the right place to configure if the element is accessible or not, as if the accordion element is open by default then the children will be accessible still.
(group.headerRenderMode === "text" ? group.headerText.value : undefined) | ||
} | ||
accessibilityHint={group.screenReaderHint?.value} | ||
accessibilityState={{ expanded: isExpanded }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can use accessibilityElementsHidden
and importantForAccessibility
properties to disable all the children if the parent is disabled
@@ -41,11 +48,12 @@ export function GroupIcon({ iconCollapsed, iconExpanded, isExpanded, style }: Gr | |||
}, [isExpanded, animatedValue]); | |||
|
|||
return customIconsConfigured ? ( | |||
<View style={iconStyles}> | |||
<View accessible={accessible} style={iconStyles}> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it would be nice if there is a caption for the icon
Checklist
[XX-000]: description
)? ✅Feature specific
This PR contains
What is the purpose of this PR?
Implement a11y for pluggable widgets.