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

question about future of theme-colors #23126

Closed
wojtask9 opened this issue Jul 20, 2017 · 3 comments
Closed

question about future of theme-colors #23126

wojtask9 opened this issue Jul 20, 2017 · 3 comments
Labels

Comments

@wojtask9
Copy link
Contributor

wojtask9 commented Jul 20, 2017

bootstrap v4.beta1 is around the corner so I would ask what is the future of theme-colors?

Currently all themeable components iterate over theme-colors map.
It is possible that in future (v4 lifetime) there will be for example separate maps for components (example alert-theme, table-theme, buttons-theme, etc)?

And what about "color-levels"? Currently they are hardcoded.
@include alert-variant(theme-color-level($color, -10), theme-color-level($color, -9), theme-color-level($color, 6));
Is there a chance that after beta1 things will be more customizable?

@mdo
Copy link
Member

mdo commented Jul 20, 2017

Goal is for every color to have their own Sass map for 100 to 900 levels. We'll likely have variables for all those, too. There are currently no plans to provide different maps unique to each component.

What else are you thinking about for easier customization?

@wojtask9
Copy link
Contributor Author

Maybe something misunderstood about color-levels.
For example how to make alerts border darker than default?
Currently there isn't any way to achieve this (see https://github.com/twbs/bootstrap/blob/v4-dev/scss/_alert.scss#L46) without modify sources.
Another example are buttons.
How to make border color other than background-color (https://github.com/twbs/bootstrap/blob/v4-dev/scss/_buttons.scss#L55).

Currently when we updating bsv4 sources we replace lines mentioned above using simple regexp to something similar:

@include alert-variant(theme-color-level($color, $alert-bg-color-lvl), theme-color-level($color, $alert-border-color-lvl), theme-color-level($color, $alert-color-lvl));

It's not ideal solution but works.

@mdo
Copy link
Member

mdo commented Oct 1, 2017

Closing for #23418.

@mdo mdo closed this as completed Oct 1, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants