Sidebar logo links to the start page

This commit is contained in:
Daniel Redetzke
2026-10-04 02:31:36 +03:00
parent 3a93ec35ee
commit 3e9b9c8a1a
2 changed files with 4 additions and 2 deletions
+3 -2
View File
@@ -63,7 +63,8 @@
}
// brand is the logo lockup: mark, wordmark and the katakana reading.
const brand = (size) => h('div', { class: 'brand' }, logo(size),
// With href it is a link (the sidebar's goes to the start page).
const brand = (size, href) => h(href ? 'a' : 'div', href ? { class: 'brand', href } : { class: 'brand' }, logo(size),
h('div', null, h('div', { class: 'wm' }, APP), h('div', { class: 'kana', lang: 'ja' }, 'ゴーストワイヤー')));
// Icons are constant markup from ICONS, never data.
@@ -356,7 +357,7 @@
peerCount = h('span', { class: 'count' });
navLinks = {};
const nav = h('nav', { class: 'side', 'aria-label': 'Main' },
brand(34),
brand(34, '#/'),
srvBox,
NAV.map(([href, ic, label]) => (navLinks[href] = h('a', { class: 'nav', href }, icon(ic), label, ic === 'peers' ? peerCount : null))),
h('div', { class: 'foot' },