-
Notifications
You must be signed in to change notification settings - Fork 318
/
Copy path_index.less
94 lines (79 loc) · 1.64 KB
/
_index.less
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
@import "../../base.less";
@import "./_var.less";
@import "../../mixins/_index.less";
.@{prefix}-toast {
position: fixed;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
min-width: 104px;
max-width: 188px;
border-radius: @radius-small;
color: @toast-text-color;
background: rgba(0, 0, 0, 60%);
text-align: center;
padding: calc(@spacer * 2.5);
z-index: @toast-z-index;
&:not(&--text)&--column {
border-radius: calc(@radius-small * 2);
}
.@{prefix}-icon {
color: inherit;
font-size: 48px;
}
&__text {
font-size: @toast-font-size-base;
white-space: pre-wrap;
word-break: break-word;
line-height: 22px;
margin-top: @spacer-1;
min-width: 82px;
}
&--text {
width: fit-content;
padding-top: 14px;
padding-bottom: 14px;
.@{prefix}-toast__text {
margin-top: 0;
min-width: auto;
}
}
/** 有无icon判断 */
&--icononly {
padding-top: @spacer-1;
padding-bottom: @spacer-1;
min-width: 88px;
min-height: 88px !important; // stylelint-disable-line
flex-direction: initial;
}
&--middle {
left: 50%;
top: 50%;
transform: translate3d(-50%, -50%, 0);
}
&--top {
left: 50%;
top: @spacer-1;
transform: translateX(-50%);
}
&--bottom {
left: 50%;
bottom: @spacer-1;
transform: translateX(-50%);
}
&--row {
flex-direction: row;
padding: 14px 24px;
.@{prefix}-icon {
color: inherit;
font-size: 24px;
}
.@{prefix}-toast__text {
margin-top: 0;
margin-left: @spacer;
min-width: auto;
line-height: 24px;
}
}
}