mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-25 04:46:40 +07:00
fixed image load on PhotoSwipe
This commit is contained in:
parent
60acf8f14d
commit
acacc42ccf
3 changed files with 7 additions and 15 deletions
|
@ -1,9 +1,4 @@
|
|||
import React, {
|
||||
CSSProperties,
|
||||
FC,
|
||||
useMemo,
|
||||
useReducer,
|
||||
} from 'react';
|
||||
import React, { CSSProperties, FC, useMemo, useReducer } from 'react';
|
||||
|
||||
import classNames from 'classnames';
|
||||
|
||||
|
@ -24,7 +19,7 @@ const ImageLoadingWrapper: FC<ImageLoadingWrapperProps> = ({
|
|||
color,
|
||||
...props
|
||||
}) => {
|
||||
const [loading, onLoad] = useReducer((v) => false, true);
|
||||
const [loading, onLoad] = useReducer(() => false, true);
|
||||
|
||||
const style = useMemo<CSSProperties>(
|
||||
() => ({
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue