mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-25 12:56:41 +07:00
loading node
This commit is contained in:
parent
da9ac62584
commit
a0272f5baa
4 changed files with 28 additions and 5 deletions
|
@ -12,9 +12,11 @@ interface IProps {
|
|||
}
|
||||
|
||||
const NodeImageBlock: FC<IProps> = ({ node, is_loading }) => {
|
||||
const images = useMemo(() => node.files.filter(({ type }) => type === UPLOAD_TYPES.IMAGE), [
|
||||
node,
|
||||
]);
|
||||
const images = useMemo(
|
||||
() =>
|
||||
(node && node.files && node.files.filter(({ type }) => type === UPLOAD_TYPES.IMAGE)) || [],
|
||||
[node]
|
||||
);
|
||||
|
||||
return (
|
||||
<div className={classNames(styles.wrap, { is_loading })}>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue