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

Details component collapses when content is clicked in Edge, IE11 #911

Closed
36degrees opened this issue Jul 17, 2018 · 4 comments · Fixed by #912
Closed

Details component collapses when content is clicked in Edge, IE11 #911

36degrees opened this issue Jul 17, 2018 · 4 comments · Fixed by #912
Labels
🐛 bug Something isn't working the way it should (including incorrect wording in documentation)

Comments

@36degrees
Copy link
Contributor

From @andyjones1981 on July 15, 2018 8:46

The details component, when expanded, closes when the content is clicked on, rather than the link causing the close action.

This causes a problem when a user wants to select and copy the expanded text.

I am using this in a case tool which shows details of a message sent to an applicant, the case tool user might want to copy the update into another location but cannot do this.

On touch interfaces this does not occur and the text can be selected/copied without the panel closing.

I'll add that the Gov Elements version didn't close when text was selected.

Copied from original issue: alphagov/govuk-design-system-backlog#148

@36degrees
Copy link
Contributor Author

Hi Andy,

Thanks for flagging this – can you confirm that you're seeing this behaviour with the examples in the Design System, not just in your application? Can I also check what browser you're using? I've not been able to reproduce this in Chrome 67 (running on macOS High Sierra)

Thanks,

Ollie

@36degrees
Copy link
Contributor Author

From @andyjones1981 on July 16, 2018 19:20

@36degrees I just tested across IE11, Edge, FF and Chrome. Seems to be an issue isolated to IE11 and Edge only. I'll be honest I don't use chrome as my main browser, I use Edge. (Sorry should have x-tested first)

I can recreate in my service prototype as well as the example In the design system.

@36degrees
Copy link
Contributor Author

Great, thanks. I'm going to move this issue to alphagov/govuk-frontend so we can track it there.

@36degrees 36degrees changed the title Allow details content to be selected and copied when expanded Details component collapses when content is clicked in Edge, IE11 Jul 17, 2018
@36degrees 36degrees added the 🐛 bug Something isn't working the way it should (including incorrect wording in documentation) label Jul 17, 2018
36degrees added a commit that referenced this issue Jul 17, 2018
This fixes an issue where clicking the revealed content in browsers that do not support the native `details` element causes the details element to collapse. (Fixes #911)

It also fixes an issue in all browsers where clicking the revealed content ‘flips’ the aria-expanded attribute on the summary element and the aria-hidden attribute on the content element, causing them to get out of sync with the visible state of the component.
36degrees added a commit that referenced this issue Jul 17, 2018
This fixes an issue where clicking the revealed content in browsers that do not support the native `details` element causes the details element to collapse. (Fixes #911)

It also fixes an issue in all browsers where clicking the revealed content ‘flips’ the aria-expanded attribute on the summary element and the aria-hidden attribute on the content element, causing them to get out of sync with the visible state of the component.
@36degrees
Copy link
Contributor Author

@andyjones1981 a fix for this issue has been merged into master. We're hoping to get a bug fix release (v1.1.1) out today that will include it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working the way it should (including incorrect wording in documentation)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant