thumbnail: Remove unused thumbnail sizes.

47683144ff switched the web client to prefer the 840x560 size, as the
mobile apps prefer; remove the now-unused 300x200 size.  No client was
using the generated `.jpg` formats, as all clients support `.webp`, so
remove the unused `.jpg` thumbnail as well.
This commit is contained in:
Alex Vandiver 2024-07-24 16:25:02 +00:00 committed by Tim Abbott
parent fccddf9f0d
commit e3a238fc89
1 changed files with 5 additions and 7 deletions

View File

@ -82,15 +82,13 @@ class StoredThumbnailFormat(BaseThumbnailFormat):
# options on this list are the ones which are written into # options on this list are the ones which are written into
# rendered_content. # rendered_content.
THUMBNAIL_OUTPUT_FORMATS = [ THUMBNAIL_OUTPUT_FORMATS = [
# For now, we generate relatively large default "thumbnails", so # We generate relatively large default "thumbnails", so that
# that clients that do not understand the thumbnailing protocol # clients that do not understand the thumbnailing protocol
# (e.g. mobile) get something which does not look pixelated. # (e.g. mobile) get something which does not look pixelated. This
# is also useful when the web client lightbox temporarily shows an
# upsized thumbnail while loading the full resolution image.
ThumbnailFormat("webp", 840, 560, animated=True), ThumbnailFormat("webp", 840, 560, animated=True),
ThumbnailFormat("webp", 840, 560, animated=False), ThumbnailFormat("webp", 840, 560, animated=False),
# 300x200 is the size preferred by the web client.
ThumbnailFormat("webp", 300, 200, animated=True),
ThumbnailFormat("webp", 300, 200, animated=False),
ThumbnailFormat("jpg", 300, 200, animated=False),
] ]