« get me outta code hell

hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/page/homepage.js13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/page/homepage.js b/src/page/homepage.js
index c15c969a..7295ba09 100644
--- a/src/page/homepage.js
+++ b/src/page/homepage.js
@@ -91,11 +91,14 @@ export function writeTargetless({wikiData}) {
                           lazy: i > 0,
                         })),
 
-                      !empty(entry.actionLinks) &&
-                        html.tag('div', {class: 'grid-actions'},
-                          entry.actionLinks.map(action =>
-                            transformInline(action)
-                              .replace('<a', '<a class="box grid-item"'))),
+                      html.tag('div',
+                        {
+                          [html.onlyIfContent]: true,
+                          class: 'grid-actions',
+                        },
+                        entry.actionLinks?.map(action =>
+                          transformInline(action)
+                            .replace('<a', '<a class="box grid-item"'))),
                     ]),
                 ]))),
         ]),