canonical / vanilla-framework

From community websites to web applications, this CSS framework will help you achieve a consistent look and feel.
https://vanillaframework.io
GNU Lesser General Public License v3.0
845 stars 167 forks source link

Extract monospace text styling to a %placeholder #3417

Open bartaz opened 4 years ago

bartaz commented 4 years ago

Currently only <code> <pre> etc elements provide built-in monospace font styling, but they also come with other styles, like background, etc.

There is no easy way of creating other elements that will use monospace font but different style.

We should extract any necessary styles (font, line-height, etc) to some %vf-text-monospace placeholder, so it can be reused in places that need to use monospace font without inheriting base <code> styling.

bartaz commented 2 months ago

Triaging: effort low, impact low/medium.

Needs decision. Do we want to allow monospace text outside of code elements?

syncronize-issues-to-jira[bot] commented 2 months ago

Thank you for reporting us your feedback!

The internal ticket has been created: https://warthogs.atlassian.net/browse/WD-15163.

This message was autogenerated

apollo13 commented 1 month ago

I'd support having a mixin or a simple css class setting the relevant font properties. My usecase would be showing git revisions in a table and without monospace they do not align nicely.

bartaz commented 1 month ago

I'd support having a mixin or a simple css class setting the relevant font properties. My usecase would be showing git revisions in a table and without monospace they do not align nicely.

Why can't you just wrap them in <code>?

apollo13 commented 1 month ago

Fair enough, it doesn't look to bad in this case. Thanks!

bartaz commented 1 month ago

Unless there is some high impact use case for this we will consider it for the new architecture only.