merge: hub notification badge slot
This commit is contained in:
commit
86386b08b1
1 changed files with 11 additions and 0 deletions
|
|
@ -31,6 +31,8 @@ interface Module {
|
||||||
glow: string
|
glow: string
|
||||||
envKey?: string
|
envKey?: string
|
||||||
status?: string
|
status?: string
|
||||||
|
/** Unread count for the corner badge. Wire to real data via #32. */
|
||||||
|
unread?: number
|
||||||
}
|
}
|
||||||
|
|
||||||
// Lower (root/red) → upper (crown/violet)
|
// Lower (root/red) → upper (crown/violet)
|
||||||
|
|
@ -113,6 +115,15 @@ function notImplemented() {
|
||||||
<p class="text-sm font-semibold text-foreground drop-shadow">{{ m.label }}</p>
|
<p class="text-sm font-semibold text-foreground drop-shadow">{{ m.label }}</p>
|
||||||
<p v-if="m.status" class="text-[9px] font-light text-muted-foreground">{{ m.status }}</p>
|
<p v-if="m.status" class="text-[9px] font-light text-muted-foreground">{{ m.status }}</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Notification badge — wired to data once #32 lands. Hidden when unread is falsy/0. -->
|
||||||
|
<span
|
||||||
|
v-if="m.unread"
|
||||||
|
class="absolute top-1.5 right-1.5 min-w-[18px] h-[18px] px-1 rounded-full bg-red-500 text-white text-[10px] font-semibold flex items-center justify-center shadow ring-1 ring-background/60"
|
||||||
|
:aria-label="`${m.unread} unread`"
|
||||||
|
>
|
||||||
|
{{ m.unread > 99 ? '99+' : m.unread }}
|
||||||
|
</span>
|
||||||
</component>
|
</component>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue