|
@@ -1,4 +1,5 @@
|
|
|
//@import '../theme/variables.scss';
|
|
//@import '../theme/variables.scss';
|
|
|
|
|
+@import "./animation.scss";
|
|
|
@import "./variables.scss";
|
|
@import "./variables.scss";
|
|
|
|
|
|
|
|
$module: #{$prefix}-modal;
|
|
$module: #{$prefix}-modal;
|
|
@@ -9,7 +10,7 @@ $module: #{$prefix}-modal;
|
|
|
// width: 600px;
|
|
// width: 600px;
|
|
|
margin: $spacing-modal-marginY $spacing-modal-marginX;
|
|
margin: $spacing-modal-marginY $spacing-modal-marginX;
|
|
|
color: $color-modal_main-text;
|
|
color: $color-modal_main-text;
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-mask {
|
|
&-mask {
|
|
|
position: fixed;
|
|
position: fixed;
|
|
|
top: $spacing-modal_mask-top;
|
|
top: $spacing-modal_mask-top;
|
|
@@ -20,18 +21,18 @@ $module: #{$prefix}-modal;
|
|
|
height: 100%;
|
|
height: 100%;
|
|
|
// filter: alpha(opacity=50);
|
|
// filter: alpha(opacity=50);
|
|
|
z-index: $z-modal-mask;
|
|
z-index: $z-modal-mask;
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-hidden {
|
|
&-hidden {
|
|
|
display: none;
|
|
display: none;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-icon-wrapper {
|
|
&-icon-wrapper {
|
|
|
display: inline-flex;
|
|
display: inline-flex;
|
|
|
margin-right: $spacing-modal_icon_wrapper-marginRight;
|
|
margin-right: $spacing-modal_icon_wrapper-marginRight;
|
|
|
width: $width-icon-extra-large;
|
|
width: $width-icon-extra-large;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-wrap {
|
|
&-wrap {
|
|
|
position: fixed;
|
|
position: fixed;
|
|
|
overflow: auto;
|
|
overflow: auto;
|
|
@@ -47,7 +48,7 @@ $module: #{$prefix}-modal;
|
|
|
align-items: center;
|
|
align-items: center;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-title {
|
|
&-title {
|
|
|
display: inline-flex;
|
|
display: inline-flex;
|
|
|
align-items: flex-start;
|
|
align-items: flex-start;
|
|
@@ -55,7 +56,7 @@ $module: #{$prefix}-modal;
|
|
|
width: $width-modal_title;
|
|
width: $width-modal_title;
|
|
|
margin: $spacing-modal_title-margin;
|
|
margin: $spacing-modal_title-margin;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-content {
|
|
&-content {
|
|
|
position: relative;
|
|
position: relative;
|
|
|
display: flex;
|
|
display: flex;
|
|
@@ -71,17 +72,17 @@ $module: #{$prefix}-modal;
|
|
|
overflow: hidden;
|
|
overflow: hidden;
|
|
|
@include shadow-elevated;
|
|
@include shadow-elevated;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-content-fullScreen {
|
|
&-content-fullScreen {
|
|
|
border-radius: $radius-modal_content_fullscreen;
|
|
border-radius: $radius-modal_content_fullscreen;
|
|
|
border: none;
|
|
border: none;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
// &-close {
|
|
// &-close {
|
|
|
// position: absolute;
|
|
// position: absolute;
|
|
|
// right: 15px;
|
|
// right: 15px;
|
|
|
// }
|
|
// }
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-header {
|
|
&-header {
|
|
|
display: flex;
|
|
display: flex;
|
|
|
align-items: flex-start;
|
|
align-items: flex-start;
|
|
@@ -93,24 +94,24 @@ $module: #{$prefix}-modal;
|
|
|
color: $color-modal_main-text;
|
|
color: $color-modal_main-text;
|
|
|
border-bottom: $width-modal_header-border solid $color-modal_header-border;
|
|
border-bottom: $width-modal_header-border solid $color-modal_header-border;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-body-wrapper {
|
|
&-body-wrapper {
|
|
|
display: flex;
|
|
display: flex;
|
|
|
align-items: flex-start;
|
|
align-items: flex-start;
|
|
|
margin: $spacing-modal_body_wrapper-marginY $spacing-modal_body_wrapper-marginX;
|
|
margin: $spacing-modal_body_wrapper-marginY $spacing-modal_body_wrapper-marginX;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-body {
|
|
&-body {
|
|
|
flex: 1 1 auto;
|
|
flex: 1 1 auto;
|
|
|
// padding: $spacing-loose;
|
|
// padding: $spacing-loose;
|
|
|
margin: $spacing-modal_body-margin;
|
|
margin: $spacing-modal_body-margin;
|
|
|
padding: $spacing-modal_body-padding;
|
|
padding: $spacing-modal_body-padding;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-withIcon {
|
|
&-withIcon {
|
|
|
margin-left: $spacing-modal_content_withicon-marginLeft;
|
|
margin-left: $spacing-modal_content_withicon-marginLeft;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-footer {
|
|
&-footer {
|
|
|
// padding: $spacing-loose;
|
|
// padding: $spacing-loose;
|
|
|
margin: $spacing-modal_footer-marginY $spacing-modal_footer-marginX;
|
|
margin: $spacing-modal_footer-marginY $spacing-modal_footer-marginX;
|
|
@@ -119,62 +120,62 @@ $module: #{$prefix}-modal;
|
|
|
border-radius: $radius-modal_footer;
|
|
border-radius: $radius-modal_footer;
|
|
|
border-top: $width-modal_footer-border solid $color-modal_footer-border;
|
|
border-top: $width-modal_footer-border solid $color-modal_footer-border;
|
|
|
background-color: $color-modal_footer-bg;
|
|
background-color: $color-modal_footer-bg;
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
.#{$prefix}-button {
|
|
.#{$prefix}-button {
|
|
|
margin-left: $spacing-modal_footer_button-marginLeft;
|
|
margin-left: $spacing-modal_footer_button-marginLeft;
|
|
|
margin-right: 0;
|
|
margin-right: 0;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-confirm {
|
|
&-confirm {
|
|
|
.#{$module}-header {
|
|
.#{$module}-header {
|
|
|
margin-bottom: $spacing-modal_confirm_header-marginBottom;
|
|
margin-bottom: $spacing-modal_confirm_header-marginBottom;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
// &-content-withIcon {
|
|
// &-content-withIcon {
|
|
|
// margin-left: 36px;
|
|
// margin-left: 36px;
|
|
|
// }
|
|
// }
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-icon-wrapper {
|
|
&-icon-wrapper {
|
|
|
display: inline-flex;
|
|
display: inline-flex;
|
|
|
margin-right: $spacing-modal_confirm_icon_wrapper-marginRight;
|
|
margin-right: $spacing-modal_confirm_icon_wrapper-marginRight;
|
|
|
width: $width-icon-extra-large;
|
|
width: $width-icon-extra-large;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-icon {
|
|
&-icon {
|
|
|
display: inline-flex;
|
|
display: inline-flex;
|
|
|
color: $color-modal_primary-icon;
|
|
color: $color-modal_primary-icon;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-info-icon {
|
|
&-info-icon {
|
|
|
color: $color-modal_info-icon;
|
|
color: $color-modal_info-icon;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-success-icon {
|
|
&-success-icon {
|
|
|
color: $color-modal_success-icon;
|
|
color: $color-modal_success-icon;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-error-icon {
|
|
&-error-icon {
|
|
|
color: $color-modal_danger-icon;
|
|
color: $color-modal_danger-icon;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-warning-icon {
|
|
&-warning-icon {
|
|
|
color: $color-modal_warning-icon;
|
|
color: $color-modal_warning-icon;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-small {
|
|
&-small {
|
|
|
width: $width-modal_small;
|
|
width: $width-modal_small;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-medium {
|
|
&-medium {
|
|
|
width: $width-modal_medium;
|
|
width: $width-modal_medium;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-large {
|
|
&-large {
|
|
|
width: $width-modal_large;
|
|
width: $width-modal_large;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
&-full-width {
|
|
&-full-width {
|
|
|
width: $width-modal_full_width;
|
|
width: $width-modal_full_width;
|
|
|
}
|
|
}
|
|
@@ -204,30 +205,33 @@ $module: #{$prefix}-modal;
|
|
|
display: none;
|
|
display: none;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-.#{$module}-content-animate-hide {
|
|
|
|
|
- animation: 90ms #{$module}-content-keyframe-hide ease forwards;
|
|
|
|
|
-}
|
|
|
|
|
|
|
+
|
|
|
|
|
|
|
|
.#{$module}-content-animate-show {
|
|
.#{$module}-content-animate-show {
|
|
|
- animation: 120ms #{$module}-content-keyframe-show cubic-bezier(0, 0, 0.26, 1.38) forwards;
|
|
|
|
|
|
|
+ animation: $animation_duration-modal_show #{$module}-content-keyframe-show $animation_function-modal_show $animation_delay-modal_show forwards;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-.#{$module}-mask-animate-hide {
|
|
|
|
|
- animation: 90ms #{$module}-mask-keyframe-hide ease forwards;
|
|
|
|
|
|
|
+.#{$module}-content-animate-hide {
|
|
|
|
|
+ animation: $animation_duration-modal_hide #{$module}-content-keyframe-hide $animation_function-modal_hide $animation_delay-modal_hide forwards;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
.#{$module}-mask-animate-show {
|
|
.#{$module}-mask-animate-show {
|
|
|
- animation: 90ms #{$module}-mask-keyframe-show ease forwards;
|
|
|
|
|
|
|
+ animation: $animation_duration-modal_mask_show #{$module}-mask-keyframe-show $animation_function-modal_mask_show $animation_delay-modal_mask_show forwards;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+.#{$module}-mask-animate-hide {
|
|
|
|
|
+ animation: $animation_duration-modal_mask_hide #{$module}-mask-keyframe-hide $animation_function-modal_mask_hide $animation_delay-modal_mask_hide forwards;
|
|
|
|
|
+}
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
|
|
|
@keyframes #{$module}-content-keyframe-show {
|
|
@keyframes #{$module}-content-keyframe-show {
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
0% {
|
|
0% {
|
|
|
- opacity: 0;
|
|
|
|
|
- transform: scale(0.7);
|
|
|
|
|
|
|
+ opacity: $animation_opacity-modal_content_open;
|
|
|
|
|
+ transform: scale($animation_transform_scale-modal_content-open);
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
100% {
|
|
100% {
|
|
|
opacity: 1;
|
|
opacity: 1;
|
|
|
transform: scale(1);
|
|
transform: scale(1);
|
|
@@ -235,38 +239,38 @@ $module: #{$prefix}-modal;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@keyframes #{$module}-content-keyframe-hide {
|
|
@keyframes #{$module}-content-keyframe-hide {
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
0% {
|
|
0% {
|
|
|
opacity: 1;
|
|
opacity: 1;
|
|
|
transform: scale(1);
|
|
transform: scale(1);
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
100% {
|
|
100% {
|
|
|
- opacity: 0;
|
|
|
|
|
- transform: scale(0.7);
|
|
|
|
|
|
|
+ opacity: $animation_opacity-modal_content-close;
|
|
|
|
|
+ transform: scale($animation_transform_scale-modal_content-close);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
@keyframes #{$module}-mask-keyframe-show {
|
|
@keyframes #{$module}-mask-keyframe-show {
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
0% {
|
|
0% {
|
|
|
- opacity: 0;
|
|
|
|
|
|
|
+ opacity: $animation_opacity-modal_mask-open;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
100% {
|
|
100% {
|
|
|
opacity: 1;
|
|
opacity: 1;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@keyframes #{$module}-mask-keyframe-hide {
|
|
@keyframes #{$module}-mask-keyframe-hide {
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
0% {
|
|
0% {
|
|
|
opacity: 1;
|
|
opacity: 1;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
100% {
|
|
100% {
|
|
|
- opacity: 0;
|
|
|
|
|
|
|
+ opacity: $animation_opacity-modal_mask-close;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|