mirror of
https://github.com/snapotter-hq/SnapOtter.git
synced 2026-08-03 07:46:42 +02:00
fix: prevent image collapse in beautify preview when frame or watermark is active
The image element used flex: 1 1 0 (basis 0) inside the inline-flex preview wrapper, causing it to collapse to zero height whenever a device frame or watermark overlay was present. Changed to flex: 0 1 auto so the image uses its intrinsic height and can shrink if needed. Added regression e2e tests verifying every preset keeps the image visible, and that adding a watermark does not collapse the image regardless of whether a frame is active.
This commit is contained in:
@@ -285,7 +285,7 @@ export function ImageViewer({
|
||||
imageWrapperChildren
|
||||
? {
|
||||
display: "block",
|
||||
flex: "1 1 0",
|
||||
flex: "0 1 auto",
|
||||
minHeight: 0,
|
||||
maxWidth: "100%",
|
||||
objectFit: "contain" as const,
|
||||
|
||||
Reference in New Issue
Block a user