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

Prevent Preflight from affecting list semantics #13815

Merged
merged 5 commits into from
Jun 14, 2024

Conversation

benface
Copy link
Contributor

@benface benface commented Jun 9, 2024

The comment should be self-explanatory. I learned this trick thanks to Sara Soueidan's talk at CSS Day. 🙃

@thecrypticace
Copy link
Contributor

Looks like using list-style: "" works too given that the semantics are lost when the type is set to none and since it's set to "" they stay around. Interestingly some screen readers don't seem to care if none is used but some other ones do so this seems like a good change. 👍

@thecrypticace thecrypticace merged commit 332347e into tailwindlabs:next Jun 14, 2024
1 check passed
@benface benface deleted the patch-1 branch June 15, 2024 15:34
@sntran
Copy link

sntran commented Jun 22, 2024

How would we go about re-adding it? For example, we want the <ul> to have bullet on desktop but not on tablet, while wanting to keep its sematics, i.e., can't do md:list-none

@benface
Copy link
Contributor Author

benface commented Jun 22, 2024

Huh, good point @sntran. I guess you can do md:list-[''] or customize your theme to have { listStyleType: { none: "''" } }. But I wonder if that should be changed in the default theme @thecrypticace?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants