Comments (2)
Hi @ryanfeeley.
TL;DR: Can't be fixed AFAIK, but options exist to work around the issue.
From what I can tell, the issue is cause by Firefox's insistence on rendering list item bullets using the -moz-bullet-font
instead of inheriting the font specified for the list item. Notice in the following screenshot that ::marker
pseudo-element within the ordered list inherits the font-family
value (sans-serif
) of its parent <li>
element:
Now, notice the font-family
of the ::marker
element within the unordered list:
Why is Firefox setting font-family
to -moz-bullet-font
instead of sans-serif
? Who knows. The good news is that we can "fix" the spacing issue by forcing the ::marker
element to inherit the font-family
value:
ul ::-moz-list-bullet {
font-family: inherit;
}
Unfortunately, this change causes Firefox to render the bullets at the wrong size and position:
The font-size
can be adjusted, but doing so reintroduces the height issue and new vertical alignment issues:
ul ::-moz-list-bullet {
font-family: inherit;
font-size: 1.5em;
}
No amount of tweaking to properties like line-height
or vertical-align
help, so "fixing" the font-family
value isn't really a great solution unless you're okay with the relatively small bullets in Firefox.
Another possible solution is to manually render a bullet for ::-moz-list-bullet
pseudo-elements using the content
property:
ul ::-moz-list-bullet {
content: '● ';
}
Unfortunately, this isn't a fix I can bake into the project because it isn't easy to override without knowing what's happening under the hood and it doesn't work well with nested lists.
I think this is worth filing a bug with Mozilla. I will add more to this thread if/when I know more.
Happy to answer any additional questions you may have. Until then, I will close the issue since there is nothing for me to do.
Thanks!
from vertical-rhythm-reset.
Firefox bug filed here: https://bugzilla.mozilla.org/show_bug.cgi?id=1750905
from vertical-rhythm-reset.
Related Issues (7)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vertical-rhythm-reset.