Fix accordion transition on chrome

This commit is contained in:
Antoine Bartuccio 2025-06-11 00:20:46 +02:00
parent 36d4a02a45
commit 96f91138dd
Signed by: klmp200
GPG Key ID: E7245548C53F904B

View File

@ -57,4 +57,17 @@ details[open].accordion>.accordion-content {
// will create a strange behavior where the transition
// continues without being shown, creating inconsistenties
transition: all 300ms ease-out;
}
// For some reason, it's still not enough for chrome
// We repeat duplicate the transition again but only for chrome
// And since everything with ::details-content crashes firefox
// we put this at the end so it doesn't break the previous code
details.accordion::details-content {
opacity: 0;
}
details[open].accordion::details-content {
opacity: 1;
transition: all 300ms ease-out;
}