naive-ui/styles/Pagination.scss

149 lines
4.1 KiB
SCSS
Raw Normal View History

2019-06-25 15:48:04 +08:00
@import './mixins/mixins.scss';
@import './themes/vars.scss';
2019-06-25 15:48:04 +08:00
2019-10-15 17:55:02 +08:00
@include themes-mixin {
@include b(pagination) {
@include once {
2019-10-16 23:43:07 +08:00
display: flex;
2019-10-15 17:55:02 +08:00
vertical-align: middle;
@include b(select) {
width: 120px;
}
2019-10-15 17:55:02 +08:00
@include m(transition-disabled) {
@include b(pagination-item) {
@include not-m(backward) {
@include not-m(forward) {
transition: none;
path {
transition: none;
}
}
}
}
}
}
2019-10-15 17:55:02 +08:00
@include b(pagination-quick-jumper) {
@include once {
white-space: nowrap;
display: flex;
width: 110px;
line-height: 28px;
transition: color .3s $--n-ease-in-out-cubic-bezier;
2019-10-15 17:55:02 +08:00
@include b(input) {
margin: 0 8px;
input {
padding-left: 6px;
padding-right: 10px;
}
}
2019-06-25 15:48:04 +08:00
}
2019-10-15 17:55:02 +08:00
color: map-get($--pagination-item-text-color, "default");
2019-06-25 15:48:04 +08:00
}
2019-10-15 17:55:02 +08:00
@include b(pagination-item) {
@include once {
position: relative;
cursor: pointer;
user-select: none;
min-width:28px;
height:28px;
padding-left: 4px;
padding-right: 4px;
box-sizing: border-box;
opacity: 1;
transition: color .3s $--n-ease-in-out-cubic-bezier, box-shadow .3s $--n-ease-in-out-cubic-bezier, background-color .3s $--n-ease-in-out-cubic-bezier, opacity .3s $--n-ease-in-out-cubic-bezier;
2019-10-15 17:55:02 +08:00
display: flex;
align-items: center;
justify-content: center;
border-radius:6px;
line-height: 28px;
path {
transition: fill .3s $--n-ease-in-out-cubic-bezier;
2019-10-15 17:55:02 +08:00
}
&:not(:last-child) {
margin-right: 10px;
}
2019-10-17 22:16:30 +08:00
@include e(more-icon, arrow-icon) {
position: relative;
width: 16px;
2019-10-15 17:55:02 +08:00
height: 16px;
2019-10-17 22:16:30 +08:00
@include b(base-icon) {
position: absolute;
left: 0;
right: 0;
top: 0;
bottom: 0;
}
2019-10-15 17:55:02 +08:00
}
2019-06-25 15:48:04 +08:00
}
2019-10-15 17:55:02 +08:00
color: map-get($--pagination-item-text-color, 'default');
@include e(more-icon, arrow-icon) {
path {
fill: map-get($--pagination-item-text-color, 'default');
}
}
2019-10-15 17:55:02 +08:00
@include m(active) {
2019-10-15 17:55:02 +08:00
background: map-get($--pagination-item-background-color, 'active');
color: map-get($--pagination-item-text-color, 'active');
box-shadow: inset 0 0 0 1px map-get($--pagination-item-border-color, 'active');
}
@include m(backward, forward) {
2019-10-15 17:55:02 +08:00
box-shadow: inset 0 0 0 1px map-get($--pagination-item-border-color, 'default');
path {
fill: map-get($--pagination-item-text-color, 'default');
}
2019-06-25 15:48:04 +08:00
}
@include m(fast-backward, fast-forward) {
2019-10-15 17:55:02 +08:00
@include once {
@include e(more-icon) {
display: block;
}
@include e(arrow-icon) {
display: none;
2019-06-25 15:48:04 +08:00
}
}
path {
2019-10-15 17:55:02 +08:00
fill: map-get($--pagination-item-text-color, 'default');
}
}
@include m(disabled) {
@include once {
cursor: not-allowed;
}
opacity: $--pagination-disabled-opacity;
}
@include not-m(disabled) {
&:hover {
color: map-get($--pagination-item-text-color, 'hover');
@include m(fast-backward, fast-forward) {
@include once {
@include e(more-icon) {
display: none;
}
}
@include e(arrow-icon) {
@include once {
display: block;
}
path {
fill: map-get($--pagination-item-text-color, 'default');
}
}
path {
fill: map-get($--pagination-item-text-color, 'default');
}
}
}
2019-06-25 15:48:04 +08:00
}
}
2019-10-15 17:55:02 +08:00
@include m(disabled) {
@include once {
cursor: not-allowed;
}
@include b(pagination-quick-jumper) {
color: map-get($--pagination-text-color, "disabled");
}
}
2019-06-25 15:48:04 +08:00
}
2019-10-15 17:55:02 +08:00
}