eBay / ebay-font

A small utility to efficiently load custom web fonts
MIT License
175 stars 19 forks source link

Do we need a "load only" option? #8

Closed ianmcburnie closed 7 years ago

ianmcburnie commented 7 years ago

I wonder whether we should clarify upfront that this module not only loads the font, but it applies it to the body too. Might there be a case where an app only wants to load the font, but not apply it to body? Perhaps only applying it to headings, for example?

Is it worth making that configurable?

The current guidance for Market Sans is that it is for font-size 16px and over. I'm trying to get clarification from design team if it's okay to set Market Sans as the default for all font sizes in our css.

senthilp commented 7 years ago

@ianmcburnie We will update the documentation to indicate that. And this module will always apply the fonts. I do not see a use case where we just load without applying. So I would not introduce a new flag, as that will result in over complication. We want to keep it as simple as possible.

Also i am assuming that Market Sans should be fine for all font sizes. But will wait for confirmation from design team.

Will keep the issue open to address the documentation.

ianmcburnie commented 7 years ago

Thanks Senthil. The feedback I am getting from design team is that Market Sans is recommended for 16px and over (see #6), but some teams are already using it for less than 16px (e.g. Homepage) without issue. There's no real definite answer or guidance from their side, and so given that I say we press ahead with our current direction of setting Market Sans as the default font-family on the body, which keeps things simple as you say.

Apps can opt out of Market Sans for 16px and under, if they wish, using our type ramp variables. Static sites can opt out using our typography classes.

RajaRamu commented 7 years ago

it make sense @ianmcburnie

senthilp commented 7 years ago

@ianmcburnie The documentation is updated to reflect how this module will be used. There is also a detailed blog post explaining it. Closing the issue now.