mirror of
https://github.com/zclzone/vue-naive-admin.git
synced 2025-05-01 14:49:00 +08:00
fix: 路由标签较多,屏幕较窄情况下没有左右滚动条
This commit is contained in:
parent
4eb15744a6
commit
6f38034c14
@ -8,23 +8,26 @@
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<n-tabs
|
||||
:value="tabStore.activeTab"
|
||||
:closable="tabStore.tabs.length > 1"
|
||||
:style="`--selected-bg: ${appStore.isDark ? '#1b2429' : '#eaf0f1'}`"
|
||||
type="card"
|
||||
@close="(path) => tabStore.removeTab(path)"
|
||||
>
|
||||
<n-tab
|
||||
v-for="item in tabStore.tabs"
|
||||
:key="item.path"
|
||||
:name="item.path"
|
||||
@click="handleItemClick(item.path)"
|
||||
@contextmenu.prevent="handleContextMenu($event, item)"
|
||||
<n-scrollbar x-scrollable>
|
||||
<n-tabs
|
||||
:value="tabStore.activeTab"
|
||||
:closable="tabStore.tabs.length > 1"
|
||||
class="py-10"
|
||||
:style="`--selected-bg: ${appStore.isDark ? '#1b2429' : '#eaf0f1'}`"
|
||||
type="card"
|
||||
@close="(path) => tabStore.removeTab(path)"
|
||||
>
|
||||
{{ item.title }}
|
||||
</n-tab>
|
||||
</n-tabs>
|
||||
<n-tab
|
||||
v-for="item in tabStore.tabs"
|
||||
:key="item.path"
|
||||
:name="item.path"
|
||||
@click="handleItemClick(item.path)"
|
||||
@contextmenu.prevent="handleContextMenu($event, item)"
|
||||
>
|
||||
{{ item.title }}
|
||||
</n-tab>
|
||||
</n-tabs>
|
||||
</n-scrollbar>
|
||||
|
||||
<ContextMenu
|
||||
v-if="contextMenuOption.show"
|
||||
|
Loading…
x
Reference in New Issue
Block a user