From 4ad0c3946a132f20742cc4de7f7dd31c79bb4653 Mon Sep 17 00:00:00 2001 From: "(quasar) nebula" Date: Thu, 11 Jan 2024 20:23:58 -0400 Subject: content, css: narrow image link/reveal interactivity wrapper --- src/content/dependencies/image.js | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'src/content/dependencies') diff --git a/src/content/dependencies/image.js b/src/content/dependencies/image.js index 9de58dce..5ea89a57 100644 --- a/src/content/dependencies/image.js +++ b/src/content/dependencies/image.js @@ -337,6 +337,18 @@ export default { ]); } + wrapped = + html.tag('div', {class: 'image-inner-area'}, + wrapped); + + if (willLink) { + wrapped = + html.tag('a', {class: 'image-link'}, + linkAttributes, + + wrapped); + } + wrapped = html.tag('div', {class: 'image-container'}, containerAttributes, @@ -344,8 +356,7 @@ export default { !originalSrc && {class: 'placeholder-image'}, - html.tag('div', {class: 'image-inner-area'}, - wrapped)); + wrapped); if (willReveal) { wrapped = @@ -367,17 +378,6 @@ export default { wrapped)); } - if (willLink) { - wrapped = - html.tag('a', {class: ['box', 'image-link']}, - linkAttributes, - - visibility === 'hidden' && - {class: 'js-hide'}, - - wrapped); - } - return wrapped; } }, -- cgit 1.3.0-6-gf8a5