-
Notifications
You must be signed in to change notification settings - Fork 105
/
MohamedAboSeada_bitter-skunk-14.html
102 lines (99 loc) · 1.85 KB
/
MohamedAboSeada_bitter-skunk-14.html
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
95
96
97
98
99
100
101
102
<div class="tooltip-container">
<div class="tooltip">
<p>This is a test</p>
<button>Got It</button>
<div class="line"></div>
</div>
<span class="text">Tooltip</span>
</div>
<style>
/* From Uiverse.io by MohamedAboSeada - Tags: simple, tooltip, animation, minimalist, hover, rounded, cube, modern */
.tooltip-container {
position: relative;
height: 50px;
display: flex;
background-color: darkgray;
border-radius: 5px;
box-shadow: 0 3px 0 rgb(0 0 0 / 80%);
width: 200px;
cursor: pointer;
align-items: center;
justify-content: center;
}
.tooltip {
position: absolute;
top: -110px;
left: 50%;
opacity: 0;
transition: 300ms ease;
background-color: #000;
color: #fff;
border-radius: 5px;
display: flex;
gap: 10px 0;
cursor: auto;
box-shadow: 0 0 10px rgb(0 0 0 / 50%);
font-style: oblique;
flex-direction: column;
padding: 10px;
width: 200px;
animation: opacity;
transform: translateX(-50%);
}
.tooltip button {
outline: none;
border: 1px solid #fff;
background-color: transparent;
color: #fff;
width: 70px;
height: 30px;
border-radius: 5px;
font-family: inherit;
font-size: 1rem;
align-self: flex-end;
cursor: pointer;
}
.line {
position: absolute;
width: 3px;
height: 25px;
background-color: #000;
top: 100%;
left: 50%;
display: flex;
align-items: flex-end;
justify-content: center;
transform: translateX(-50%);
}
.line::before {
content: "";
position: absolute;
bottom: -5px;
width: 10px;
height: 10px;
background-color: #000;
border-radius: 50%;
}
.tooltip-container:hover > .tooltip {
opacity: 1;
}
.tooltip-container:hover > .tooltip > .line {
animation: HeightUP 400ms ease;
}
@keyframes HeightUP {
0% {
height: 0;
}
100% {
height: 25px;
}
}
@keyframes opcaityUp {
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}
</style>