Skip to content

Conversation

@MartijnCuppens
Copy link
Member

Fixes #26515.

Provides a way to easily add display headings with a sass map.

@dceluis
Copy link

dceluis commented May 19, 2018

Will this be possible with normal text utilities? #25832

$display3-weight: 300 !default;
$display4-weight: 300 !default;
$display-line-height: $headings-line-height !default;
$displays: (

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$displays: () !default;
$displays: map-merge($displays, ());

@andresgalante
Copy link
Collaborator

Hi @MartijnCuppens, this solution would gives more settings and it works.

My problem is that by having the definition for headings scattered into different files, instead of scoped to type.scss we would be making the codebase harder to contribute, code and maintain.

What do you think?

@MartijnCuppens
Copy link
Member Author

Hi @andresgalante,

Would you move the $displays sass map to the _type.scss? All bootstrap variables are defined in _variables.sccs, I think it's better to keep it there?

@andresgalante
Copy link
Collaborator

andresgalante commented Jun 15, 2018

Yes, you are right, all variables are define on variables and putting them within a map wouldn't make a difference than having them as variables outside the map. The map might be a bit harder to parse.

mdo
mdo previously requested changes Jul 7, 2018
Copy link
Member

@mdo mdo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You've removed several variables—that's a breaking change. You can likely rewrite the Sass map to include those variables rather than remove them outright.

@MartijnCuppens
Copy link
Member Author

I re-added the original display variables

@MartijnCuppens MartijnCuppens changed the title #26515: easily add display headings with sass maps Easily add display headings with sass maps Aug 4, 2018
@XhmikosR XhmikosR requested a review from mdo October 22, 2018 16:56
@MartijnCuppens
Copy link
Member Author

I'm not convinced anymore that this is a good idea (especially for v4). This technique is quite different from the way we handle things in other places, we're practically putting every property of the generated css in a sass map.

I'm considering closing this, unless someone has a good argument to merge this.

@XhmikosR
Copy link
Member

CC @andresgalante @mdo

@mdo
Copy link
Member

mdo commented Nov 3, 2018

Let's punt on it and reimagine the typography in v5 to do it right. v5 shouldn't be sweeping changes, but an easy-ish upgrade path. I feel like stuff like this can be tackled then. Feel free to close if you still agree! <3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants