diff --git a/ui/shared/nft/NftHtmlFullscreen.tsx b/ui/shared/nft/NftHtmlFullscreen.tsx
index 0e28fab523..80f9bcddfe 100644
--- a/ui/shared/nft/NftHtmlFullscreen.tsx
+++ b/ui/shared/nft/NftHtmlFullscreen.tsx
@@ -9,7 +9,7 @@ interface Props {
onClose: () => void;
}
-const NftHtmlWithFullscreen = ({ src, isOpen, onClose }: Props) => {
+const NftHtmlFullscreen = ({ src, isOpen, onClose }: Props) => {
return (
{
);
};
-export default NftHtmlWithFullscreen;
+export default NftHtmlFullscreen;
diff --git a/ui/shared/nft/NftHtmlWithFullscreen.tsx b/ui/shared/nft/NftHtmlWithFullscreen.tsx
deleted file mode 100644
index eca068fae0..0000000000
--- a/ui/shared/nft/NftHtmlWithFullscreen.tsx
+++ /dev/null
@@ -1,33 +0,0 @@
-import { chakra, useDisclosure } from '@chakra-ui/react';
-import React from 'react';
-
-import NftHtml from './NftHtml';
-import NftMediaFullscreenModal from './NftMediaFullscreenModal';
-
-interface Props {
- src: string;
- onLoad: () => void;
- onError: () => void;
-}
-
-const NftHtmlWithFullscreen = ({ src, onLoad, onError }: Props) => {
- const { isOpen, onOpen, onClose } = useDisclosure();
-
- return (
- <>
-
-
-
-
- >
- );
-};
-
-export default NftHtmlWithFullscreen;
diff --git a/ui/shared/nft/NftImageFullscreen.tsx b/ui/shared/nft/NftImageFullscreen.tsx
index 04fad72270..9d35c313d4 100644
--- a/ui/shared/nft/NftImageFullscreen.tsx
+++ b/ui/shared/nft/NftImageFullscreen.tsx
@@ -11,12 +11,29 @@ interface Props {
onClose: () => void;
}
-const NftImageWithFullscreen = ({ src, isOpen, onClose }: Props) => {
+const NftImageFullscreen = ({ src, isOpen, onClose }: Props) => {
+ const imgRef = React.useRef(null);
+ const [ hasDimentions, setHasDimentions ] = React.useState(true);
+
+ const checkWidth = React.useCallback(() => {
+ if (imgRef.current?.getBoundingClientRect().width === 0) {
+ setHasDimentions(false);
+ }
+ }, [ ]);
+
return (
-
+
);
};
-export default NftImageWithFullscreen;
+export default NftImageFullscreen;
diff --git a/ui/shared/nft/NftImageWithFullscreen.tsx b/ui/shared/nft/NftImageWithFullscreen.tsx
deleted file mode 100644
index 374ffbda92..0000000000
--- a/ui/shared/nft/NftImageWithFullscreen.tsx
+++ /dev/null
@@ -1,29 +0,0 @@
-import {
- Image,
- useDisclosure,
-} from '@chakra-ui/react';
-import React from 'react';
-
-import NftImage from './NftImage';
-import NftMediaFullscreenModal from './NftMediaFullscreenModal';
-
-interface Props {
- src: string;
- onLoad: () => void;
- onError: () => void;
-}
-
-const NftImageWithFullscreen = ({ src, onLoad, onError }: Props) => {
- const { isOpen, onOpen, onClose } = useDisclosure();
-
- return (
- <>
-
-
-
-
- >
- );
-};
-
-export default NftImageWithFullscreen;
diff --git a/ui/shared/nft/NftVideoFullscreen.tsx b/ui/shared/nft/NftVideoFullscreen.tsx
index dc1685c26b..07fa250b1e 100644
--- a/ui/shared/nft/NftVideoFullscreen.tsx
+++ b/ui/shared/nft/NftVideoFullscreen.tsx
@@ -10,7 +10,7 @@ interface Props {
onClose: () => void;
}
-const NftVideoWithFullscreen = ({ src, isOpen, onClose }: Props) => {
+const NftVideoFullscreen = ({ src, isOpen, onClose }: Props) => {
return (
{
);
};
-export default NftVideoWithFullscreen;
+export default NftVideoFullscreen;
diff --git a/ui/shared/nft/NftVideoWithFullscreen.tsx b/ui/shared/nft/NftVideoWithFullscreen.tsx
deleted file mode 100644
index ed676379e7..0000000000
--- a/ui/shared/nft/NftVideoWithFullscreen.tsx
+++ /dev/null
@@ -1,37 +0,0 @@
-import {
- chakra,
- useDisclosure,
-} from '@chakra-ui/react';
-import React from 'react';
-
-import NftMediaFullscreenModal from './NftMediaFullscreenModal';
-import NftVideo from './NftVideo';
-import { videoPlayProps } from './utils';
-
-interface Props {
- src: string;
- onLoad: () => void;
- onError: () => void;
-}
-
-const NftVideoWithFullscreen = ({ src, onLoad, onError }: Props) => {
- const { isOpen, onOpen, onClose } = useDisclosure();
-
- return (
- <>
-
-
-
-
- >
- );
-};
-
-export default NftVideoWithFullscreen;
diff --git a/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_mobile_recent-keywords-suggest-mobile-1.png b/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_mobile_recent-keywords-suggest-mobile-1.png
index bc7a68e250..a7c2b5af44 100644
Binary files a/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_mobile_recent-keywords-suggest-mobile-1.png and b/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_mobile_recent-keywords-suggest-mobile-1.png differ