Merge pull request 'Add styles for spoiler message functionality' (#53) from BordedDev/snek:feat/spoilers into main
Reviewed-on: #53 Reviewed-by: retoor <retoor@noreply@molodetz.nl>
This commit is contained in:
commit
19c88d786e
@ -221,6 +221,55 @@ footer {
|
|||||||
hyphens: auto;
|
hyphens: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.message-content .spoiler {
|
||||||
|
background-color: rgba(255, 255, 255, 0.1);
|
||||||
|
/*color: transparent;*/
|
||||||
|
cursor: pointer;
|
||||||
|
border-radius: 0.5rem;
|
||||||
|
padding: 0.5rem;
|
||||||
|
position: relative;
|
||||||
|
height: 2.5rem;
|
||||||
|
overflow: hidden;
|
||||||
|
max-width: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.message-content .spoiler * {
|
||||||
|
opacity: 0;
|
||||||
|
pointer-events: none;
|
||||||
|
visibility: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
.spoiler:hover, .spoiler:focus, .spoiler:focus-within, .spoiler:active {
|
||||||
|
/*color: #e6e6e6;*/
|
||||||
|
/*transition: color 0.3s ease-in;*/
|
||||||
|
height: unset;
|
||||||
|
overflow: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes delay-pointer-events {
|
||||||
|
0% {
|
||||||
|
visibility: hidden;
|
||||||
|
}
|
||||||
|
50% {
|
||||||
|
visibility: hidden;
|
||||||
|
}
|
||||||
|
100% {
|
||||||
|
visibility: visible;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.spoiler:hover * {
|
||||||
|
animation: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.spoiler:hover *, .spoiler:focus *, .spoiler:focus-within *, .spoiler:active * {
|
||||||
|
opacity: 1;
|
||||||
|
transition: opacity 0.3s ease-in;
|
||||||
|
pointer-events: auto;
|
||||||
|
visibility: visible;
|
||||||
|
animation: delay-pointer-events 0.2s linear;
|
||||||
|
}
|
||||||
|
|
||||||
.message-content {
|
.message-content {
|
||||||
max-width: 100%;
|
max-width: 100%;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user