diff --git a/src/components/styled/GlobalStyle.styled.jsx b/src/components/styled/GlobalStyle.styled.jsx index 2a7075cb..8b211785 100644 --- a/src/components/styled/GlobalStyle.styled.jsx +++ b/src/components/styled/GlobalStyle.styled.jsx @@ -37,13 +37,18 @@ export const GlobalStyle = createGlobalStyle` padding: 0; } - .enlarged { - @media (min-width: 480px) { - max-width: none !important; - max-height: none !important; - } + .expanded-container { + display: inline-block; + } - @media (max-width: 480px) { + .enlarged { + display: block; + max-width: 100% !important; + max-height: 100% !important; + } + + @media (max-width: 480px) { + .enlarged { max-width: 100% !important; max-height: 100% !important; } diff --git a/src/components/views/Board.jsx b/src/components/views/Board.jsx index 8db8dc9e..61d97b49 100644 --- a/src/components/views/Board.jsx +++ b/src/components/views/Board.jsx @@ -485,24 +485,28 @@ const Board = () => { } ({commentMediaInfo?.type}) {commentMediaInfo?.type === "webpage" ? ( - - {thread.thumbnailUrl ? ( +
+ + {thread.thumbnailUrl ? ( + {commentMediaInfo.type} e.target.src = fallbackImgUrl} /> + ) : null} + +
+ ) : null} + {commentMediaInfo?.type === "image" ? ( +
+ {commentMediaInfo.type} e.target.src = fallbackImgUrl} /> - ) : null} - - ) : null} - {commentMediaInfo?.type === "image" ? ( - - {commentMediaInfo.type} e.target.src = fallbackImgUrl} /> - + +
) : null} {commentMediaInfo?.type === "video" ? ( @@ -717,24 +721,28 @@ const Board = () => { } ({replyMediaInfo?.type}) {replyMediaInfo?.type === "webpage" ? ( - - {reply.thumbnailUrl ? ( +
+ + {reply.thumbnailUrl ? ( + {replyMediaInfo.type} e.target.src = fallbackImgUrl} /> + ) : null} + +
+ ) : null} + {replyMediaInfo?.type === "image" ? ( +
+ {replyMediaInfo.type} e.target.src = fallbackImgUrl} /> - ) : null} - - ) : null} - {replyMediaInfo?.type === "image" ? ( - - {replyMediaInfo.type} e.target.src = fallbackImgUrl} /> - + +
) : null} {replyMediaInfo?.type === "video" ? ( @@ -848,6 +856,7 @@ const Board = () => {
{commentMediaInfo?.url ? ( commentMediaInfo.type === "webpage" ? ( +
{thread.thumbnailUrl ? ( { ) : null}
{commentMediaInfo?.type}
+
) : commentMediaInfo.type === "image" ? ( +
{commentMediaInfo.type} { onError={(e) => e.target.src = fallbackImgUrl} />
{commentMediaInfo?.type}
+
) : commentMediaInfo.type === "video" ? (
+ ) : null} + {commentMediaInfo?.type === "image" ? ( +
+ + {commentMediaInfo.type} e.target.src = fallbackImgUrl} /> - ) : null} - - ) : null} - {commentMediaInfo?.type === "image" ? ( - - {commentMediaInfo.type} e.target.src = fallbackImgUrl} /> - + +
) : null} {commentMediaInfo?.type === "video" ? ( @@ -663,24 +667,28 @@ const Thread = () => { } ({replyMediaInfo?.type}) {replyMediaInfo?.type === "webpage" ? ( - - {reply.thumbnailUrl ? ( +
+ + {reply.thumbnailUrl ? ( + thumbnail e.target.src = fallbackImgUrl} /> + ) : null} + +
+ ) : null} + {replyMediaInfo?.type === "image" ? ( +
+ thumbnail e.target.src = fallbackImgUrl} /> - ) : null} - - ) : null} - {replyMediaInfo?.type === "image" ? ( - - {replyMediaInfo.type} e.target.src = fallbackImgUrl} /> - + +
) : null} {replyMediaInfo?.type === "video" ? ( @@ -773,27 +781,31 @@ const Thread = () => { {commentMediaInfo?.url ? ( commentMediaInfo.type === "webpage" ? (
- - {comment.thumbnailUrl ? ( - {commentMediaInfo.type} e.target.src = fallbackImgUrl} /> - ) : null} -
{commentMediaInfo.type}
-
+
+ + {comment.thumbnailUrl ? ( + {commentMediaInfo.type} e.target.src = fallbackImgUrl} /> + ) : null} +
{commentMediaInfo.type}
+
+
) : commentMediaInfo.type === "image" ? (
- - {commentMediaInfo.type} e.target.src = fallbackImgUrl} /> -
{commentMediaInfo.type}
-
+
+ + {commentMediaInfo.type} e.target.src = fallbackImgUrl} /> +
{commentMediaInfo.type}
+
+
) : commentMediaInfo.type === "video" ? (
@@ -889,6 +901,7 @@ const Thread = () => {
{replyMediaInfo?.url ? ( replyMediaInfo.type === "webpage" ? ( +
{reply.thumbnailUrl ? ( { ) : null}
{replyMediaInfo.type}
+
) : replyMediaInfo.type === "image" ? ( +
{replyMediaInfo.type} { onError={(e) => e.target.src = fallbackImgUrl} />
{replyMediaInfo.type}
+
) : replyMediaInfo.type === "video" ? (