diff options
Diffstat (limited to 'src/content/dependencies/image.js')
-rw-r--r-- | src/content/dependencies/image.js | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/content/dependencies/image.js b/src/content/dependencies/image.js index bf47b14f..2ffa4c48 100644 --- a/src/content/dependencies/image.js +++ b/src/content/dependencies/image.js @@ -60,6 +60,12 @@ export default { mutable: false, }, + // Added to the <img>. + imgAttributes: { + type: 'attributes', + mutable: false, + }, + // Added to the <img> itself. alt: {type: 'string'}, @@ -141,6 +147,8 @@ export default { const imgAttributes = html.attributes([ {class: 'image'}, + slots.imgAttributes, + slots.alt && {alt: slots.alt}, dimensions && |