Skip to content
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

data-turbo-stream links should not set aria-busy #681

Merged
merged 1 commit into from
Aug 16, 2022
Merged

data-turbo-stream links should not set aria-busy #681

merged 1 commit into from
Aug 16, 2022

Conversation

kevinmcconnell
Copy link
Collaborator

Normally when following a link Turbo sets [aria-busy="true"] on the
document element. When the visit is complete, that attribute is removed.

However, when using [data-turbo-stream] to request a stream response
to a link, there is no visit to complete. That presented as a bug where
aria-busy was set at the start of the operation, but never cleared.

To solve this, we avoid setting the aria-busy attribute for links that
have a data-turbo-stream attribute.

Normally when following a link Turbo sets `[aria-busy="true"]` on the
document element. When the visit is complete, that attribute is removed.

However, when using `[data-turbo-stream]` to request a stream response
to a link, there is no visit to complete. That presented as a bug where
`aria-busy` was set at the start of the operation, but never cleared.

To solve this, we avoid setting the `aria-busy` attribute for links that
have a `data-turbo-stream` attribute.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants