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

pagination color #31477

Closed
ghost opened this issue Aug 14, 2020 · 13 comments
Closed

pagination color #31477

ghost opened this issue Aug 14, 2020 · 13 comments

Comments

@ghost
Copy link

ghost commented Aug 14, 2020

Introduce different pagination color.Currently pagination only support primary color.

Like
'.pagination .pagination-primary'

@ghost ghost added the feature label Aug 14, 2020
@Deckluhm
Copy link
Contributor

I'm pretty sure .pagination-primary doesn't exist, .pagination is just using the primary color as his color.

The problem of creating color variants of each component is that it increases CSS bundle size (and therefore impacts performances).

@ghost
Copy link
Author

ghost commented Aug 14, 2020

pagination is most common and most useful features in all the blog type website.

Hope, we will see this class soon.
.pagination-colorName ( colorName are : -primary, secondary, success, info, warning etc. )

@SrilalS
Copy link

SrilalS commented Aug 15, 2020

i agree with @dev0mhm . adding this small feature wont effect CSS bundle size in a huge manner.

@MauricioHernanCabrera
Copy link
Contributor

I agree with @dev0mhm, if do you interesting I can to do this pull request

@ghost
Copy link
Author

ghost commented Aug 16, 2020

aye

@Deckluhm
Copy link
Contributor

adding this small feature wont effect CSS bundle size in a huge manner.

It's not but I don't know how the core team decides about adding (or not adding) that kind of things to library core.

It doesn't look like a popular demand/feature to me so I'm advocating a mixin (you can use to generate colored pagination yourself) without adding this to the core of the lib.

@MauricioHernanCabrera
Copy link
Contributor

I have create a pull request with mixin and class with theme colors, If interested, I can just add the mixin @Deckluhm

@axzx
Copy link

axzx commented Aug 17, 2020

Usually, the pagination should look the same throughout the site.
It would be better to be able to set the color you want in variables.

@mdo mdo added the css label Aug 17, 2020
@ffoodd
Copy link
Member

ffoodd commented Aug 18, 2020

Pagination colors are customizable through Sass variables, both in v4 and v5.

This has not been requested much, and as @axzx said I'm not sure it should be part of the core.

FWIW, customization might be easier soon whilst v5 moves to CSS custom properties. Using custom properties for pagination colors would make adding variant much easier.

@MauricioHernanCabrera
Copy link
Contributor

okasss

@MusicDev33
Copy link

I agree with @ffoodd, I think it's a good idea to change the color of pagination with CSS variables. I think this is generally a good direction for Bootstrap to keep going in, as it is getting to be rather large.

@ydmitry
Copy link
Contributor

ydmitry commented Sep 13, 2020

If will implement this #29853 with new versions of SCSS we could add new variants with additional colors without Bootstrap code change like:

@use '~bootstrap/scss-modular/pagination' with (
  $color: green
);

or

@include meta.load-css('~bootstrap/scss-modular/pagination', (
  color: green
));

@mdo
Copy link
Member

mdo commented Sep 17, 2020

Thanks, but for now we'll pass on adding color schemes for this. Would rather implement CSS vars for configuring the colors and direct folks to Sass variables for more.

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

No branches or pull requests

8 participants