ant-design/style/components/spin.less
2015-10-31 02:00:03 +08:00

86 lines
1.5 KiB
Plaintext

@import "../mixins/index";
@spin-prefix-cls: ant-spin;
// root of component
// ------------------------------
.@{spin-prefix-cls} {
color: @primary-color;
display: inline-block;
font-size: 1em;
text-align: center;
&-nested-loading {
position: relative;
}
&-nested-loading & {
position: absolute;
top: 50%;
left: 50%;
margin-top: -0.75em;
margin-left: -2.5em;
z-index: 4;
}
&-container {
transition: all 0.5s ease;
}
&-nested-loading > &-container {
opacity: 0.7;
filter: blur(1px);
filter: progid:DXImageTransform.Microsoft.Blur(PixelRadius=1, MakeShadow=false); /* IE6~IE9 */
}
// dots
// ------------------------------
&-dot {
.animation(antSpinPulse 1s infinite ease-in-out);
.square(1em);
border-radius: 50%;
display: inline-block;
background-color: @primary-color;
}
&-dot-second {
.animation-delay(200ms);
margin-left: 1em;
}
&-dot-third {
.animation-delay(400ms);
margin-left: 1em;
}
// Sizes
// ------------------------------
&-default {
font-size: @spin-dot-size;
}
// small
&-small {
font-size: @spin-dot-size-sm;
}
// large
&-large {
font-size: @spin-dot-size-lg;
}
}
// pulse
@keyframes antSpinPulse {
0%, 80%, 100% { opacity: 0; }
40% { opacity: 1; }
}
@media all and (-ms-high-contrast: none), (-ms-high-contrast: active) {
/* IE10+*/
.ant-spin-nested-loading > .ant-spin-container {
background: #fff;
opacity: 0.5;
}
}