feat(webui): remove menubar Channel item; brand acts as channel selector only on dashboard; hover to open; commit text toned down
This commit is contained in:
parent
71cf7a927f
commit
9e95ccdca4
3 changed files with 7 additions and 7 deletions
|
|
@ -1,7 +1,7 @@
|
|||
html, body { height: 100%; }
|
||||
body { padding: 0; min-height: 100vh; }
|
||||
header.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 1000; padding: .6rem 1rem; border-bottom: 1px solid var(--muted-border-color); display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; background-color: var(--pico-background-color, #fff); }
|
||||
header.nav .brand { justify-self: start; }
|
||||
header.nav .brand { justify-self: start; cursor: pointer; }
|
||||
header.nav .commit { justify-self: center; font-size: .7rem; opacity: .55; }
|
||||
header.nav nav { justify-self: end; }
|
||||
main, article, .dash { margin-top: var(--headerH, 56px); margin-bottom: var(--footerH, 44px); }
|
||||
|
|
|
|||
|
|
@ -76,6 +76,12 @@ window.addEventListener('DOMContentLoaded', ()=>{
|
|||
if('scrollRestoration' in history){ history.scrollRestoration = 'manual'; }
|
||||
measureBars();
|
||||
loadChannels();
|
||||
// Open brand dropdown on hover (desktop) for the dashboard
|
||||
const brandDetails = document.getElementById('brand-chans');
|
||||
if(brandDetails){
|
||||
brandDetails.addEventListener('mouseenter', ()=>{ brandDetails.setAttribute('open',''); });
|
||||
brandDetails.addEventListener('mouseleave', ()=>{ brandDetails.removeAttribute('open'); });
|
||||
}
|
||||
if(document.getElementById('channel')){
|
||||
fetch('/api/channels').then(r=>r.json()).then(arr=>{ const sel=document.getElementById('channel'); arr.forEach(c=>{ const o=document.createElement('option'); o.value=c; o.textContent=c; sel.appendChild(o); }); }).catch(()=>{});
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue