File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed
src/components/imageLightbox Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -30,10 +30,7 @@ type ValidDimensions = {
30
30
width : number ;
31
31
} ;
32
32
33
- const getValidDimensions = (
34
- width ?: number ,
35
- height ?: number
36
- ) : ValidDimensions | null => {
33
+ const getValidDimensions = ( width ?: number , height ?: number ) : ValidDimensions | null => {
37
34
if (
38
35
width != null &&
39
36
height != null &&
@@ -62,7 +59,9 @@ export function ImageLightbox({
62
59
// Check if we should use Next.js Image or regular img
63
60
// Use Next.js Image for internal images with valid dimensions
64
61
// Use regular img for external images or when dimensions are invalid/missing
65
- const validDimensions = ! isExternalImage ( src ) ? getValidDimensions ( width , height ) : null ;
62
+ const validDimensions = ! isExternalImage ( src )
63
+ ? getValidDimensions ( width , height )
64
+ : null ;
66
65
67
66
const handleClick = ( e : React . MouseEvent ) => {
68
67
// If Ctrl/Cmd+click, open image in new tab
You can’t perform that action at this time.
0 commit comments