We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4434828 commit 9539d0cCopy full SHA for 9539d0c
sphinxext/photofinish/__init__.py
@@ -209,6 +209,7 @@ def visit_image(
209
210
with Image.open(img_src_path) as im:
211
im_width, im_height = im.size
212
+ vi_snippet_data = get_vi_snippet_data(im)
213
214
# Set image ratio. Browsers need the aspect ratio of the image for
215
# non-janky lazyloading. We can either give it the aspect ratio
@@ -225,6 +226,11 @@ def visit_image(
225
226
]
227
228
for dest_ext in dest_exts:
229
+
230
+ if img_ext == ".png" and dest_ext != ".png":
231
+ if vi_snippet_data:
232
+ continue
233
234
srcset_srcs = []
235
width_min = app.config.width_min
236
width_max = 2 * app.config.max_viewport_width
0 commit comments