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

fix(theme-common): allow details to not provide a summary #7267

Merged
merged 1 commit into from
Apr 29, 2022

Conversation

Josh-Cena
Copy link
Collaborator

Motivation

Right now, <details> without <summary> has a glitched UX:

Test

Not only does it show the unstyled triangle, the content is not expandable either, because there's no area that listens to the click event.

The actual fallback string is user-agent defined, but "Details" seems to be canonically used (in Chrome and Safari), so let's use it as well. It doesn't have to be localized.

Have you read the Contributing Guidelines on pull requests?

Yes

Test Plan

It now shows up as clickable & expandable.

@Josh-Cena Josh-Cena added the pr: polish This PR adds a very minor behavior improvement that users will enjoy. label Apr 29, 2022
@facebook-github-bot facebook-github-bot added the CLA Signed Signed Facebook CLA label Apr 29, 2022
@netlify
Copy link

netlify bot commented Apr 29, 2022

[V2]

Name Link
🔨 Latest commit 40609b3
🔍 Latest deploy log https://app.netlify.com/sites/docusaurus-2/deploys/626bf5732492ec00088c24dc
😎 Deploy Preview https://deploy-preview-7267--docusaurus-2.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@github-actions
Copy link

github-actions bot commented Apr 29, 2022

⚡️ Lighthouse report for the changes in this PR:

Category Score
🟠 Performance 57
🟢 Accessibility 100
🟠 Best practices 83
🟢 SEO 100
🟢 PWA 90

Lighthouse ran on https://deploy-preview-7267--docusaurus-2.netlify.app/

@github-actions
Copy link

github-actions bot commented Apr 29, 2022

Size Change: 0 B

Total Size: 803 kB

ℹ️ View Unchanged
Filename Size
website/.docusaurus/globalData.json 50.1 kB
website/build/assets/css/styles.********.css 107 kB
website/build/assets/js/main.********.js 607 kB
website/build/index.html 38.8 kB

compressed-size-action

@slorber slorber merged commit 41f5371 into main Apr 29, 2022
@slorber slorber deleted the jc/fix-details branch April 29, 2022 17:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Signed Facebook CLA pr: polish This PR adds a very minor behavior improvement that users will enjoy.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants