Dodavanje base šablona, sidebara, topbara i dashboard stranice

This commit is contained in:
2026-06-01 01:11:05 +02:00
parent 56accffb37
commit 3b9e0c081a
7 changed files with 326 additions and 2 deletions
+18
View File
@@ -0,0 +1,18 @@
{{define "topbar"}}
<header class="topbar">
<span class="topbar-naslov">{{.NaslovStranice}}</span>
<!-- dugme za promenu teme -->
<div style="display:flex;align-items:center;gap:8px;">
<a href="/tema/tamna" style="width:20px;height:20px;border-radius:50%;background:#1a1d2e;border:2px solid {{if eq .Tema "tamna"}}#fff{{else}}transparent{{end}};display:inline-block;" title="Tamna"></a>
<a href="/tema/svetla" style="width:20px;height:20px;border-radius:50%;background:#f8fafc;border:2px solid {{if eq .Tema "svetla"}}#1a1d2e{{else}}#cbd5e1{{end}};display:inline-block;" title="Svetla"></a>
<a href="/tema/zelena" style="width:20px;height:20px;border-radius:50%;background:#0f2818;border:2px solid {{if eq .Tema "zelena"}}#fff{{else}}transparent{{end}};display:inline-block;" title="Zelena"></a>
<a href="/tema/ljubicasta" style="width:20px;height:20px;border-radius:50%;background:#1e1535;border:2px solid {{if eq .Tema "ljubicasta"}}#fff{{else}}transparent{{end}};display:inline-block;" title="Ljubičasta"></a>
</div>
<!-- korisnik -->
<div style="width:32px;height:32px;border-radius:50%;background:var(--sb-aktivan);display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:500;color:#fff;flex-shrink:0;">
{{if .Korisnik}}{{slice .Korisnik 0 2}}{{else}}NT{{end}}
</div>
</header>
{{end}}