-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathtool-tip.css
More file actions
39 lines (39 loc) · 836 Bytes
/
tool-tip.css
File metadata and controls
39 lines (39 loc) · 836 Bytes
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
.tool-tip{
background-color: #fff;
padding: 10px 16px;
border: 1px solid #dcdfe6;
display: inline-block;
cursor: pointer;
border-radius: 4px;
position: relative;
}
/* content-box */
.tool-tip::before{
content: attr(data-content);
max-width: 100%;
box-sizing: border-box;
position: absolute;
background-color: #303133;
color: #fff;
font-size: 12px;
border-radius: 4px;
padding: 10px;
left: 50%;
bottom:100%;
transform: translate(-50%,-10px);
display: none;
}
/* arrow-box */
.tool-tip::after{
display: none;
content: "";
border: 6px solid transparent;
border-top-color:#303133;
position: absolute;
left: 50%;
bottom:100%;
transform: translate(-50%,2px);
}
.tool-tip:hover::after,.tool-tip:hover::before{
display: block;
}