diff options
-rw-r--r-- | src/content/dependencies/image.js | 3 | ||||
-rw-r--r-- | tap-snapshots/test/snapshot/image.js.test.cjs | 24 |
2 files changed, 14 insertions, 13 deletions
diff --git a/src/content/dependencies/image.js b/src/content/dependencies/image.js index 1960fb0a..822a8996 100644 --- a/src/content/dependencies/image.js +++ b/src/content/dependencies/image.js @@ -148,7 +148,8 @@ export default { wrapped = html.tag('div', {class: 'image-container'}, - wrapped); + html.tag('div', {class: 'image-inner-area'}, + wrapped)); if (willReveal) { wrapped = diff --git a/tap-snapshots/test/snapshot/image.js.test.cjs b/tap-snapshots/test/snapshot/image.js.test.cjs index 5561c02a..f1512930 100644 --- a/tap-snapshots/test/snapshot/image.js.test.cjs +++ b/tap-snapshots/test/snapshot/image.js.test.cjs @@ -7,7 +7,7 @@ 'use strict' exports[`test/snapshot/image.js TAP image (snapshot) > content warnings via tags 1`] = ` <div class="reveal"> - <div class="image-container"><img src="media/album-art/beyond-canon/cover.png"></div> + <div class="image-container"><div class="image-inner-area"><img src="media/album-art/beyond-canon/cover.png"></div></div> <span class="reveal-text-container"> <span class="reveal-text"> cw: too cool for school @@ -19,42 +19,42 @@ exports[`test/snapshot/image.js TAP image (snapshot) > content warnings via tags ` exports[`test/snapshot/image.js TAP image (snapshot) > id with link 1`] = ` -<a id="banana" class="box image-link" href="foobar"><div class="image-container"><img src="foobar"></div></a> +<a id="banana" class="box image-link" href="foobar"><div class="image-container"><div class="image-inner-area"><img src="foobar"></div></div></a> ` exports[`test/snapshot/image.js TAP image (snapshot) > id with square 1`] = ` -<div class="square"><div class="square-content"><div class="image-container"><img id="banana" src="foobar"></div></div></div> +<div class="square"><div class="square-content"><div class="image-container"><div class="image-inner-area"><img id="banana" src="foobar"></div></div></div></div> ` exports[`test/snapshot/image.js TAP image (snapshot) > id without link 1`] = ` -<div class="image-container"><img id="banana" src="foobar"></div> +<div class="image-container"><div class="image-inner-area"><img id="banana" src="foobar"></div></div> ` exports[`test/snapshot/image.js TAP image (snapshot) > lazy with square 1`] = ` -<noscript><div class="square"><div class="square-content"><div class="image-container"><img src="foobar"></div></div></div></noscript> -<div class="square js-hide"><div class="square-content"><div class="image-container"><img class="lazy" data-original="foobar"></div></div></div> +<noscript><div class="square"><div class="square-content"><div class="image-container"><div class="image-inner-area"><img src="foobar"></div></div></div></div></noscript> +<div class="square js-hide"><div class="square-content"><div class="image-container"><div class="image-inner-area"><img class="lazy" data-original="foobar"></div></div></div></div> ` exports[`test/snapshot/image.js TAP image (snapshot) > link with file size 1`] = ` -<a class="box image-link" href="media/album-art/pingas/cover.png"><div class="image-container"><img data-original-size="1000000" src="media/album-art/pingas/cover.png"></div></a> +<a class="box image-link" href="media/album-art/pingas/cover.png"><div class="image-container"><div class="image-inner-area"><img data-original-size="1000000" src="media/album-art/pingas/cover.png"></div></div></a> ` exports[`test/snapshot/image.js TAP image (snapshot) > source missing 1`] = ` -<div class="image-container"><div class="image-text-area">Example of missing source message.</div></div> +<div class="image-container"><div class="image-inner-area"><div class="image-text-area">Example of missing source message.</div></div></div> ` exports[`test/snapshot/image.js TAP image (snapshot) > source via path 1`] = ` -<div class="image-container"><img src="media/album-art/beyond-canon/cover.png"></div> +<div class="image-container"><div class="image-inner-area"><img src="media/album-art/beyond-canon/cover.png"></div></div> ` exports[`test/snapshot/image.js TAP image (snapshot) > source via src 1`] = ` -<div class="image-container"><img src="https://example.com/bananas.gif"></div> +<div class="image-container"><div class="image-inner-area"><img src="https://example.com/bananas.gif"></div></div> ` exports[`test/snapshot/image.js TAP image (snapshot) > square 1`] = ` -<div class="square"><div class="square-content"><div class="image-container"><img src="foobar"></div></div></div> +<div class="square"><div class="square-content"><div class="image-container"><div class="image-inner-area"><img src="foobar"></div></div></div></div> ` exports[`test/snapshot/image.js TAP image (snapshot) > width & height 1`] = ` -<div class="image-container"><img width="600" height="400" src="foobar"></div> +<div class="image-container"><div class="image-inner-area"><img width="600" height="400" src="foobar"></div></div> ` |