« get me outta code hell

content: misc content syntax cleanup, mostly attribute merging - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/content/dependencies/linkExternalAsIcon.js
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2023-12-29 22:59:20 -0400
committer(quasar) nebula <qznebula@protonmail.com>2023-12-30 16:26:36 -0400
commitf400a43640e7106d181d55365a9617c3d12e5891 (patch)
tree91c7911c2f5e91d4a230f807814930761991d23a /src/content/dependencies/linkExternalAsIcon.js
parent25c434a514152fdd02e5405e4de418cd62614c6a (diff)
content: misc content syntax cleanup, mostly attribute merging
Diffstat (limited to 'src/content/dependencies/linkExternalAsIcon.js')
-rw-r--r--src/content/dependencies/linkExternalAsIcon.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/content/dependencies/linkExternalAsIcon.js b/src/content/dependencies/linkExternalAsIcon.js
index 357c835..3eb355a 100644
--- a/src/content/dependencies/linkExternalAsIcon.js
+++ b/src/content/dependencies/linkExternalAsIcon.js
@@ -25,8 +25,12 @@ export default {
     const compactText = format('compact');
     const iconId = format('icon-id');
 
-    return html.tag('a',
-      {href: data.url, class: ['icon', slots.withText && 'has-text']},
+    return html.tag('a', {class: 'icon'},
+      {href: data.url},
+
+      slots.withText &&
+        {class: 'has-text'},
+
       [
         html.tag('svg', [
           !slots.withText &&