-
Notifications
You must be signed in to change notification settings - Fork 94
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
fix: Use proper way of hiding the attachment input #5230
Conversation
/backport to stable28 |
<input ref="attachmentFileInput" | ||
tabindex="-1" | ||
<input v-show="false" | ||
ref="attachmentFileInput" | ||
data-text-el="attachment-file-input" | ||
type="file" | ||
accept="*/*" | ||
aria-hidden="true" |
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.
@ShGKme Also do we still need the aria-hidden then or is this already fine with just having display: none; through v-show
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.
No, display: none
(and visibility: hidden
) both make element completely hidden.
Let's say, be default element is visible for both monitor's and screen reader's users.
display: none
/visibility: hidden
- hides element completely for everythingaria-hidden="true"
- hides element only for screen readers (meaning, it is not important element, like decorative image)hidden-visually
- hides element only visually (meaning, this is only for screen reader or replaces some only visual element)
One specific case when aria-hidden="true"
and hidden-visually
used together - the prev and next slides in Viewer. They must be hidden, but for image/video pre-loading and because of a bug in FF we need then to not be display: none
.
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.
Thanks, that makes sense ❤️
Signed-off-by: Julius Härtl <[email protected]>
9179e7b
to
31ab596
Compare
Hide the input field properly to make it not focusable and hidden for assistive technologies.
as described in #5224 (comment)