File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -799,7 +799,7 @@ function buildChipCarousel() {
799799 photo . setAttribute ( "fetchpriority" , "low" ) ;
800800 photo . dataset . fallbackSrc = originalImageSrc ( stop . imagePath ) ;
801801 photo . src = thumbnailPhotoSrc ( stop ) ;
802- photo . addEventListener ( "error" , onChipPhotoError , { once : true } ) ;
802+ photo . addEventListener ( "error" , onChipPhotoError ) ;
803803 chip . appendChild ( photo ) ;
804804 }
805805
Original file line number Diff line number Diff line change @@ -344,6 +344,17 @@ def test_app_loads_chip_thumbnails_instead_of_full_size_strip_images():
344344 assert "onChipPhotoError" in script
345345
346346
347+ def test_chip_thumbnail_error_handler_stays_active_for_fallback_failure ():
348+ script = JS_PATH .read_text (encoding = "utf-8" )
349+
350+ build_chip_carousel = script [script .index ("function buildChipCarousel" ) : script .index ("function updateThemeNav" )]
351+
352+ assert 'photo.addEventListener("error", onChipPhotoError);' in build_chip_carousel
353+ assert 'photo.addEventListener("error", onChipPhotoError, { once: true });' not in build_chip_carousel
354+ assert 'img.removeAttribute("data-fallback-src");' in script
355+ assert "img.remove();" in script
356+
357+
347358def test_player_expand_and_minimize_use_bounded_crossfade_blur ():
348359 css = CSS_PATH .read_text (encoding = "utf-8" )
349360 script = JS_PATH .read_text (encoding = "utf-8" )
You can’t perform that action at this time.
0 commit comments