1+ @import " ./../styles/index.scss" ;
2+
3+ .cptx-email-loading-container {
4+ border : solid 1px transparent ;
5+ border-radius : 4px ;
6+ display : flex ;
7+ flex-direction : column ;
8+ height : calc (100% - 8px );
9+ margin-bottom : 6px ;
10+ width : calc (100% - 2px );
11+
12+ .cptx-email-loading-info {
13+ align-items : center ;
14+ display : flex ;
15+ flex-direction : row ;
16+ height : 65px ;
17+ margin : 5px 17px 0 ;
18+ width : calc (100% - 32px );
19+
20+ .cptx-email-loading-info-letter {
21+ border-radius : 50% ;
22+ height : 36px ;
23+ margin-right : 10px ;
24+ width : 36px ;
25+ @extend .animated-background ;
26+ }
27+
28+ .cptx-email-loading-info-content {
29+ align-content : space-around ;
30+ display : flex ;
31+ flex-direction : column ;
32+ width : calc (100% - 46px );
33+
34+ .cptx-email-loading-text-line {
35+ & :nth-child (1 ){
36+ width : 35% ;
37+ }
38+
39+ & :nth-child (2 ){
40+ margin-top : 10px ;
41+ width : 50% ;
42+ }
43+ }
44+ }
45+ }
46+
47+ > hr {
48+ background-color : transparent ;
49+ border : 0 ;
50+ border-top : 1px solid rgba (0 , 0 , 0 , 0.1 );
51+ margin : 0 auto ;
52+ width : calc (100% - 20px );
53+ }
54+
55+ .cptx-email-loading-body {
56+ margin : 5px 17px 0 ;
57+ width : calc (100% - 32px );
58+
59+ .cptx-email-loading-text-line {
60+ & :nth-child (1 ){
61+ margin-top : 40px ;
62+ width : 40% ;
63+ }
64+
65+ & :nth-child (2 ){
66+ margin-top : 30px ;
67+ }
68+
69+ & :nth-child (3 ), & :nth-child (4 ){
70+ margin-top : 10px ;
71+ }
72+
73+ & :nth-child (4 ){
74+ width : 60% ;
75+ }
76+ }
77+ }
78+
79+ .cptx-email-loading-text-line {
80+ background-color : #cbd4dc ;
81+ border-radius : 2px ;
82+ height : 7px ;
83+ margin : 5px 0 ;
84+ width : 100% ;
85+ @extend .animated-background ;
86+ }
87+ }
88+
89+ @keyframes placeHolderShimmer {
90+ 0% {
91+ background-position : -468px 0
92+ }
93+ 100% {
94+ background-position : 468px 0
95+ }
96+ }
97+
98+ .animated-background {
99+ animation-duration : 1.25s ;
100+ animation-fill-mode : forwards ;
101+ animation-iteration-count : infinite ;
102+ animation-name : placeHolderShimmer;
103+ animation-timing-function : linear ;
104+ position : relative ;
105+ }
106+
107+ @mixin themable ($_THEME , $_BACKGROUND_COLOR_EMAIL , $_BORDER_COLOR_EMAIL , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT1 , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT2 , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT3 ){
108+ [data-theme ^= #{$_THEME } ],
109+ [data-theme ] [data-theme ^= #{$_THEME } ] {
110+ .cptx-email-loading-container {
111+ background-color : $_BACKGROUND_COLOR_EMAIL ;
112+ border-color : $_BORDER_COLOR_EMAIL ;
113+ }
114+
115+ .animated-background {
116+ background : linear-gradient (to right , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT1 8% , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT2 18% , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT3 33% );
117+ background-size : 800px 104px ;
118+ }
119+ }
120+ }
121+ @include themable ($_THEME_LIGHT , $_BACKGROUND_COLOR_EMAIL_LIGHT , $_BORDER_COLOR_EMAIL_LIGHT , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT1_LIGHT , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT2_LIGHT , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT3_LIGHT );
122+ @include themable ($_THEME_DARK , $_BACKGROUND_COLOR_EMAIL_DARK , $_BORDER_COLOR_EMAIL_DARK , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT1_DARK , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT2_DARK , $_BACKGROUND_COLOR_EMAIL_LOADING_GRADIENT3_DARK );
0 commit comments