fix(#4):完成分栏滚动&样式美化

This commit is contained in:
BTMuli
2023-03-10 15:21:52 +08:00
parent 1900c08058
commit 011d84082e

View File

@@ -14,12 +14,12 @@
</v-btn> </v-btn>
</template> </template>
</v-app-bar> </v-app-bar>
<!-- todo 样式优化目前左侧跟右侧滚动是同步的应该根据鼠标位置来判断是否滚动 --> <!-- todo 列表加载速度优化主要是天地万象的数据量太大了 -->
<v-row class="wrap-view"> <v-row class="wrap-view">
<!-- 左侧菜单 --> <!-- 左侧菜单 -->
<v-col cols="2" class="left-wrap"> <v-col class="left-wrap">
<div class="left-list">
<v-card <v-card
class="left-list"
v-for="series in seriesList" v-for="series in seriesList"
:key="series.order" :key="series.order"
@click="selectSeries(series.id)" @click="selectSeries(series.id)"
@@ -34,10 +34,9 @@
</v-list-item> </v-list-item>
</v-list> </v-list>
</v-card> </v-card>
</div>
</v-col> </v-col>
<!-- 右侧内容--> <!-- 右侧内容-->
<v-col cols="10" class="right-wrap"> <v-col cols="9" class="right-wrap">
<div class="right-list"> <div class="right-list">
<v-card <v-card
v-for="achievement in selectedSeries === -1 v-for="achievement in selectedSeries === -1
@@ -158,7 +157,7 @@ async function importJson() {
localData, localData,
remoteData remoteData
); );
await fs.writeTextFile(localPath, JSON.stringify(mergeUIAF, null, 4)); await fs.writeTextFile(localPath, JSON.stringify(mergeUIAF));
// 遍历 mergeUIAF对 mergeData 进行更新 // 遍历 mergeUIAF对 mergeData 进行更新
mergeUIAF.map(UIAF_Item => { mergeUIAF.map(UIAF_Item => {
// 更新成就 // 更新成就
@@ -190,11 +189,11 @@ async function importJson() {
// 写入数据 // 写入数据
await fs.writeTextFile( await fs.writeTextFile(
appStore.mergePath.achievements, appStore.mergePath.achievements,
JSON.stringify(mergeAchievementMap.getMap(), null, 4) JSON.stringify(mergeAchievementMap.getMap())
); );
await fs.writeTextFile( await fs.writeTextFile(
appStore.mergePath.achievementSeries, appStore.mergePath.achievementSeries,
JSON.stringify(mergeSeriesMap.getMap(), null, 4) JSON.stringify(mergeSeriesMap.getMap())
); );
// 刷新数据 // 刷新数据
await loadData(); await loadData();
@@ -223,28 +222,18 @@ async function exportJson() {
/*内容区域*/ /*内容区域*/
.wrap-view { .wrap-view {
overflow: auto; overflow: auto;
height: 100%; height: 840px;
border-bottom: 2px solid #e6e6e6;
} }
/*左侧系列*/ /*左侧系列*/
.left-wrap { .left-wrap {
display: flex; height: 100%;
overflow: auto; overflow: auto;
} }
.left-list {
display: flex;
flex: 1;
flex-direction: column;
height: 100%;
}
/*右侧成就*/ /*右侧成就*/
.right-wrap { .right-wrap {
display: flex; height: 100%;
overflow: auto; overflow: auto;
} }
.right-list {
display: flex;
flex: 1;
flex-direction: column;
height: 100%;
}
</style> </style>