mirror of
https://github.com/DerTyp7/dertyp7.github.io.git
synced 2025-10-29 21:02:09 +01:00
add logo tooltip
This commit is contained in:
@@ -6,6 +6,7 @@ function Logo() {
|
|||||||
<div className="logo">
|
<div className="logo">
|
||||||
<p>Janis</p>
|
<p>Janis</p>
|
||||||
<p>Meister</p>
|
<p>Meister</p>
|
||||||
|
<p className="tooltip">"DerTyp7"</p>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,15 +8,46 @@
|
|||||||
|
|
||||||
.logo {
|
.logo {
|
||||||
flex: 0.5;
|
flex: 0.5;
|
||||||
|
cursor: text;
|
||||||
|
|
||||||
p {
|
p {
|
||||||
font-size: 2rem;
|
font-size: 2rem;
|
||||||
line-height: 0.8;
|
line-height: 0.8;
|
||||||
|
|
||||||
|
&:nth-child(2) {
|
||||||
|
padding-left: 20px;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tooltip {
|
||||||
|
display: none;
|
||||||
|
background-color: var(--color-accent);
|
||||||
|
color: #000;
|
||||||
|
animation: moveFromTop 0.05s ease-in-out;
|
||||||
|
font-size: 1.5rem;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
p:nth-child(2) {
|
&:hover {
|
||||||
padding-left: 20px;
|
.tooltip {
|
||||||
font-weight: bold;
|
display: block;
|
||||||
|
position: absolute;
|
||||||
|
margin-top: 10px;
|
||||||
|
padding: 10px;
|
||||||
|
border-radius: 5px;
|
||||||
|
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
|
||||||
|
z-index: 1;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes moveFromTop {
|
||||||
|
0% {
|
||||||
|
transform: translateY(-30px);
|
||||||
|
}
|
||||||
|
100% {
|
||||||
|
transform: translateY(-10px);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user