2019-05-06 12:04:39 +08:00
|
|
|
@import '../../style/themes/index';
|
2018-12-07 20:02:01 +08:00
|
|
|
@import '../../style/mixins/index';
|
2015-07-27 20:53:08 +08:00
|
|
|
|
2018-12-07 20:02:01 +08:00
|
|
|
@alert-prefix-cls: ~'@{ant-prefix}-alert';
|
2015-07-27 20:53:08 +08:00
|
|
|
|
2015-08-20 16:55:42 +08:00
|
|
|
.@{alert-prefix-cls} {
|
2020-12-22 11:08:12 +08:00
|
|
|
.reset-component();
|
2019-04-15 10:52:00 +08:00
|
|
|
|
2015-07-27 20:53:08 +08:00
|
|
|
position: relative;
|
2020-11-30 11:04:56 +08:00
|
|
|
display: flex;
|
2020-11-30 13:07:38 +08:00
|
|
|
align-items: center;
|
2022-11-04 10:43:29 +08:00
|
|
|
padding: @alert-padding-vertical @alert-padding-horizontal;
|
2019-09-21 09:48:46 +08:00
|
|
|
word-wrap: break-word;
|
2015-07-27 20:53:08 +08:00
|
|
|
border-radius: @border-radius-base;
|
|
|
|
|
2020-11-30 11:04:56 +08:00
|
|
|
&-content {
|
|
|
|
flex: 1;
|
|
|
|
min-width: 0;
|
2018-12-05 10:38:42 +08:00
|
|
|
}
|
|
|
|
|
2015-07-27 20:53:08 +08:00
|
|
|
&-icon {
|
2020-12-06 20:45:49 +08:00
|
|
|
margin-right: @margin-xs;
|
2015-07-27 20:53:08 +08:00
|
|
|
}
|
|
|
|
|
2015-07-29 10:27:31 +08:00
|
|
|
&-description {
|
2019-02-15 10:48:07 +08:00
|
|
|
display: none;
|
2016-08-28 17:16:43 +08:00
|
|
|
font-size: @font-size-base;
|
2020-04-28 11:16:01 +08:00
|
|
|
line-height: @font-size-base + 8px;
|
2015-07-27 20:53:08 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
&-success {
|
2018-09-13 17:56:54 +08:00
|
|
|
background-color: @alert-success-bg-color;
|
2019-02-15 10:48:07 +08:00
|
|
|
border: @border-width-base @border-style-base @alert-success-border-color;
|
2015-11-29 16:55:43 +08:00
|
|
|
.@{alert-prefix-cls}-icon {
|
2018-09-13 17:56:54 +08:00
|
|
|
color: @alert-success-icon-color;
|
2015-07-27 20:53:08 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&-info {
|
2018-09-13 17:56:54 +08:00
|
|
|
background-color: @alert-info-bg-color;
|
2019-02-15 10:48:07 +08:00
|
|
|
border: @border-width-base @border-style-base @alert-info-border-color;
|
2015-11-29 16:55:43 +08:00
|
|
|
.@{alert-prefix-cls}-icon {
|
2018-09-13 17:56:54 +08:00
|
|
|
color: @alert-info-icon-color;
|
2015-07-27 20:53:08 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-03-28 14:38:25 +08:00
|
|
|
&-warning {
|
2018-09-13 17:56:54 +08:00
|
|
|
background-color: @alert-warning-bg-color;
|
2019-02-15 10:48:07 +08:00
|
|
|
border: @border-width-base @border-style-base @alert-warning-border-color;
|
2015-11-29 16:55:43 +08:00
|
|
|
.@{alert-prefix-cls}-icon {
|
2018-09-13 17:56:54 +08:00
|
|
|
color: @alert-warning-icon-color;
|
2015-07-27 20:53:08 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&-error {
|
2018-09-13 17:56:54 +08:00
|
|
|
background-color: @alert-error-bg-color;
|
2019-02-15 10:48:07 +08:00
|
|
|
border: @border-width-base @border-style-base @alert-error-border-color;
|
2019-12-11 14:15:45 +08:00
|
|
|
|
2015-11-29 16:55:43 +08:00
|
|
|
.@{alert-prefix-cls}-icon {
|
2018-09-13 17:56:54 +08:00
|
|
|
color: @alert-error-icon-color;
|
2015-07-27 20:53:08 +08:00
|
|
|
}
|
2019-12-11 14:15:45 +08:00
|
|
|
|
2019-12-18 12:25:43 +08:00
|
|
|
.@{alert-prefix-cls}-description > pre {
|
|
|
|
margin: 0;
|
|
|
|
padding: 0;
|
2019-12-11 14:15:45 +08:00
|
|
|
}
|
2015-07-27 20:53:08 +08:00
|
|
|
}
|
|
|
|
|
2020-11-30 11:04:56 +08:00
|
|
|
&-action {
|
|
|
|
margin-left: @margin-xs;
|
|
|
|
}
|
|
|
|
|
2015-11-29 16:55:43 +08:00
|
|
|
&-close-icon {
|
2020-11-30 11:04:56 +08:00
|
|
|
margin-left: @margin-xs;
|
2020-02-10 19:52:12 +08:00
|
|
|
padding: 0;
|
2015-07-29 15:22:47 +08:00
|
|
|
overflow: hidden;
|
2019-02-15 10:48:07 +08:00
|
|
|
font-size: @font-size-sm;
|
2020-04-28 11:16:01 +08:00
|
|
|
line-height: @font-size-sm;
|
2019-09-10 09:12:23 +08:00
|
|
|
background-color: transparent;
|
2019-09-16 20:38:20 +08:00
|
|
|
border: none;
|
2019-10-28 15:25:22 +08:00
|
|
|
outline: none;
|
2015-11-29 16:55:43 +08:00
|
|
|
cursor: pointer;
|
2015-07-29 15:22:47 +08:00
|
|
|
|
2018-08-24 18:36:08 +08:00
|
|
|
.@{iconfont-css-prefix}-close {
|
2018-07-04 16:40:41 +08:00
|
|
|
color: @alert-close-color;
|
2018-12-07 20:02:01 +08:00
|
|
|
transition: color 0.3s;
|
2021-10-13 15:38:59 +08:00
|
|
|
|
2015-11-29 16:55:43 +08:00
|
|
|
&:hover {
|
2018-12-21 16:56:48 +08:00
|
|
|
color: @alert-close-hover-color;
|
2015-07-29 15:22:47 +08:00
|
|
|
}
|
|
|
|
}
|
2015-07-27 20:53:08 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
&-close-text {
|
2019-07-30 17:29:52 +08:00
|
|
|
color: @alert-close-color;
|
|
|
|
transition: color 0.3s;
|
2021-10-13 15:38:59 +08:00
|
|
|
|
2019-07-30 17:29:52 +08:00
|
|
|
&:hover {
|
|
|
|
color: @alert-close-hover-color;
|
|
|
|
}
|
2015-07-27 20:53:08 +08:00
|
|
|
}
|
|
|
|
|
2015-07-29 17:22:36 +08:00
|
|
|
&-with-description {
|
2020-11-30 13:07:38 +08:00
|
|
|
align-items: flex-start;
|
2020-04-28 11:16:01 +08:00
|
|
|
padding: @alert-with-description-padding;
|
2015-11-29 16:55:43 +08:00
|
|
|
}
|
2015-07-27 20:53:08 +08:00
|
|
|
|
2015-11-29 18:42:57 +08:00
|
|
|
&-with-description&-no-icon {
|
2020-03-29 10:39:46 +08:00
|
|
|
padding: @alert-with-description-no-icon-padding-vertical 15px;
|
2015-11-29 18:42:57 +08:00
|
|
|
}
|
|
|
|
|
2015-11-29 16:55:43 +08:00
|
|
|
&-with-description &-icon {
|
2020-11-30 11:04:56 +08:00
|
|
|
margin-right: @alert-with-description-padding-vertical;
|
2020-04-28 11:16:01 +08:00
|
|
|
font-size: @alert-with-description-icon-size;
|
2015-11-29 16:55:43 +08:00
|
|
|
}
|
2021-10-13 15:38:59 +08:00
|
|
|
|
2015-11-29 16:55:43 +08:00
|
|
|
&-with-description &-message {
|
|
|
|
display: block;
|
2016-08-28 17:16:43 +08:00
|
|
|
margin-bottom: 4px;
|
2019-02-15 10:48:07 +08:00
|
|
|
color: @alert-message-color;
|
|
|
|
font-size: @font-size-lg;
|
2015-11-29 16:55:43 +08:00
|
|
|
}
|
2015-07-29 15:22:47 +08:00
|
|
|
|
2019-07-23 05:34:33 +08:00
|
|
|
&-message {
|
|
|
|
color: @alert-message-color;
|
|
|
|
}
|
|
|
|
|
2015-11-29 16:55:43 +08:00
|
|
|
&-with-description &-description {
|
|
|
|
display: block;
|
2015-07-27 20:53:08 +08:00
|
|
|
}
|
2015-08-20 13:06:47 +08:00
|
|
|
|
2020-08-11 17:04:42 +08:00
|
|
|
&&-motion-leave {
|
|
|
|
overflow: hidden;
|
|
|
|
opacity: 1;
|
|
|
|
transition: max-height 0.3s @ease-in-out-circ, opacity 0.3s @ease-in-out-circ,
|
|
|
|
padding-top 0.3s @ease-in-out-circ, padding-bottom 0.3s @ease-in-out-circ,
|
|
|
|
margin-bottom 0.3s @ease-in-out-circ;
|
|
|
|
}
|
|
|
|
|
|
|
|
&&-motion-leave-active {
|
2020-07-10 17:26:39 +08:00
|
|
|
max-height: 0;
|
2020-08-11 17:04:42 +08:00
|
|
|
margin-bottom: 0 !important;
|
2015-08-20 13:06:47 +08:00
|
|
|
padding-top: 0;
|
|
|
|
padding-bottom: 0;
|
2020-08-11 17:04:42 +08:00
|
|
|
opacity: 0;
|
2016-06-28 22:13:11 +08:00
|
|
|
}
|
2016-08-03 14:54:10 +08:00
|
|
|
|
|
|
|
&-banner {
|
|
|
|
margin-bottom: 0;
|
2019-02-15 10:48:07 +08:00
|
|
|
border: 0;
|
|
|
|
border-radius: 0;
|
2016-08-03 14:54:10 +08:00
|
|
|
}
|
2016-06-28 22:13:11 +08:00
|
|
|
}
|
|
|
|
|
2020-04-23 17:58:36 +08:00
|
|
|
@import './rtl';
|