FIX: Quoted images should be lightboxed (#21332)

An older change about optimising images caused the selector that adds lightboxing not to apply on quoted images. This fixes that. The selector is now not applicable as optimisation occurs in a separate place.

This change allows quoted images to be opened in a lightbox.
This commit is contained in:
Natalie Tay
2023-05-02 17:02:19 +08:00
committed by GitHub
parent 01dc461cc2
commit ccca2dbfe0
2 changed files with 3 additions and 3 deletions

View File

@ -209,7 +209,7 @@ class CookedPostProcessor
return if upload.animated?
if img.ancestors(".onebox, .onebox-body, .quote").blank? && !img.classes.include?("onebox")
if img.ancestors(".onebox, .onebox-body").blank? && !img.classes.include?("onebox")
add_lightbox!(img, original_width, original_height, upload, cropped: crop)
end