mirror of
https://github.com/cheeaun/phanpy.git
synced 2025-03-14 12:18:30 +03:00
Potential fix for weird carousel bug on Firefox
This commit is contained in:
parent
222786f202
commit
66746eb579
2 changed files with 16 additions and 0 deletions
|
@ -1121,6 +1121,11 @@ a[href^='http'][rel*='nofollow']:visited:not(:has(div)) {
|
|||
flex-grow: 1;
|
||||
background-color: var(--backdrop-solid-color);
|
||||
animation: appear 0.3s var(--timing-function) both;
|
||||
transition: width 0.3s var(--timing-function);
|
||||
|
||||
&:only-child {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
.media-modal-container.loading {
|
||||
display: flex;
|
||||
|
|
|
@ -142,6 +142,17 @@ function StatusPage(params) {
|
|||
}
|
||||
}, [showMediaOnly, closeLink, snapStates.prevLocation]);
|
||||
|
||||
useEffect(() => {
|
||||
let timer = setTimeout(() => {
|
||||
// carouselRef.current?.focus?.();
|
||||
const $carousel = document.querySelector('.carousel');
|
||||
if ($carousel) {
|
||||
$carousel.focus();
|
||||
}
|
||||
}, 100);
|
||||
return () => clearTimeout(timer);
|
||||
}, [showMediaOnly]);
|
||||
|
||||
return (
|
||||
<div class="deck-backdrop">
|
||||
{showMedia ? (
|
||||
|
|
Loading…
Add table
Reference in a new issue