add counter to tabbar
This commit is contained in:
@@ -6,11 +6,12 @@
|
||||
class="flex justify-around sm:justify-between sm:gap-8 sm:px-4 sm:flex-row sm:bg-white sm:max-w-prose mx-auto"
|
||||
>
|
||||
<TabMenuItem
|
||||
v-for="{ route, label, icon } in tabs"
|
||||
v-for="{ route, label, icon, unreadCount } in tabs"
|
||||
:key="route"
|
||||
:label
|
||||
:icon
|
||||
:to="{ name: route }"
|
||||
:unreadCount
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
@@ -22,6 +23,7 @@ type Tab = {
|
||||
route: (typeof ROUTE_NAMES)[keyof typeof ROUTE_NAMES]
|
||||
label: string
|
||||
icon: string
|
||||
unreadCount?: number
|
||||
}
|
||||
const tabs: Tab[] = [
|
||||
{ route: ROUTE_NAMES.CREATE, label: 'Создать QR-код', icon: 'plus' },
|
||||
|
||||
Reference in New Issue
Block a user