amis/scss/components/_crud.scss

141 lines
2.6 KiB
SCSS
Raw Normal View History

2019-04-30 11:11:25 +08:00
.#{$ns}Crud {
2019-12-06 09:58:08 +08:00
position: relative;
&.is-loading > &-body {
// 弹框中blur 效果变成白班,先去掉。
// -webkit-filter: blur(5px);
// filter: blur(5px);
2019-12-06 09:58:08 +08:00
}
&-selection {
margin-bottom: $gap-base;
}
&-selectionLabel {
display: inline-block;
vertical-align: top;
margin-top: $gap-xs;
}
&-value {
cursor: pointer;
vertical-align: middle;
user-select: none;
line-height: $Form-input-lineHeight * $Form-input-fontSize - px2rem(2px);
display: inline-block;
font-size: $Form-selectValue-fontSize;
color: $Form-selectValue-color;
background: $Form-selectValue-bg;
border: px2rem(1px) solid $Form-selectValue-borderColor;
border-radius: 2px;
margin-right: $gap-xs;
margin-top: $gap-xs;
&:hover {
background-color: darken($Form-selectValue-bg, 5%);
2019-04-30 11:11:25 +08:00
}
2019-12-06 09:58:08 +08:00
&.is-disabled {
pointer-events: none;
opacity: $Button-onDisabled-opacity;
2019-04-30 11:11:25 +08:00
}
2019-12-06 09:58:08 +08:00
}
2019-04-30 11:11:25 +08:00
2019-12-06 09:58:08 +08:00
&-valueIcon {
cursor: pointer;
border-right: px2rem(1px) solid $Form-selectValue-borderColor;
padding: 1px 5px;
2019-04-30 11:11:25 +08:00
2019-12-06 09:58:08 +08:00
&:hover {
background-color: darken($Form-selectValue-bg, 5%);
2019-04-30 11:11:25 +08:00
}
2019-12-06 09:58:08 +08:00
}
&-valueLabel {
padding: 0 $gap-xs;
}
&-selectionClear {
display: inline-block;
cursor: pointer;
user-select: none;
margin-left: $gap-xs;
margin-top: $gap-xs;
vertical-align: middle;
}
&-toolbar-item {
margin-left: $Crud-toolbar-gap;
2020-04-29 20:00:01 +08:00
margin-top: $Crud-toolbar-gap;
2019-12-06 09:58:08 +08:00
line-height: $Crud-toolbar-lineHeight;
height: $Crud-toolbar-height;
vertical-align: middle;
2020-04-29 19:50:15 +08:00
display: inline-flex;
align-items: center;
2019-12-06 09:58:08 +08:00
&--left {
float: left;
2019-04-30 11:11:25 +08:00
}
2019-12-06 09:58:08 +08:00
&--right {
float: right;
2019-04-30 11:11:25 +08:00
}
2019-12-06 09:58:08 +08:00
}
2019-04-30 11:11:25 +08:00
2019-12-06 09:58:08 +08:00
&-actions {
> * + .#{$ns}Button,
> * + .#{$ns}ButtonGroup,
> * + .#{$ns}ButtonToolbar {
margin-left: $Crud-toolbar-gap;
2019-04-30 11:11:25 +08:00
}
2019-12-06 09:58:08 +08:00
}
2019-04-30 11:11:25 +08:00
2019-12-06 09:58:08 +08:00
&-statistics {
line-height: $Crud-toolbar-height;
vertical-align: middle;
}
2019-04-30 11:11:25 +08:00
2019-12-06 09:58:08 +08:00
&-pageSwitch {
.#{$ns}Select {
margin-left: $Crud-toolbar-gap;
2019-04-30 11:11:25 +08:00
}
2019-12-06 09:58:08 +08:00
}
2020-04-29 19:55:56 +08:00
&-pager {
align-self: flex-start;
}
2019-04-30 11:11:25 +08:00
}
@include media-breakpoint-up(sm) {
2019-12-06 09:58:08 +08:00
.#{$ns}Crud {
&-toolbar {
margin-left: -$Crud-toolbar-gap;
2020-04-29 20:00:01 +08:00
margin-top: -$Crud-toolbar-gap;
2019-12-06 09:58:08 +08:00
flex-basis: 0;
flex-grow: 1;
@include clearfix();
2019-04-30 11:11:25 +08:00
}
2019-12-06 09:58:08 +08:00
}
2019-04-30 11:11:25 +08:00
2019-12-06 09:58:08 +08:00
&-toolbar-item {
margin-left: $Crud-toolbar-gap;
line-height: $Crud-toolbar-lineHeight;
height: $Crud-toolbar-height;
vertical-align: middle;
2019-04-30 11:11:25 +08:00
2019-12-06 09:58:08 +08:00
&--left {
float: left;
}
2019-04-30 11:11:25 +08:00
2019-12-06 09:58:08 +08:00
&--right {
float: right;
2019-04-30 11:11:25 +08:00
}
2019-12-06 09:58:08 +08:00
}
2019-04-30 11:11:25 +08:00
2019-12-06 09:58:08 +08:00
&-actions {
> .#{$ns}Button + .#{$ns}Button {
margin-left: $Crud-toolbar-gap;
2019-04-30 11:11:25 +08:00
}
2019-12-06 09:58:08 +08:00
}
}