complete main page aside? use anti-moe instead unmoe

This commit is contained in:
KUN1007 2023-05-26 20:34:01 +08:00
parent 38be23e3fc
commit c547f88735
11 changed files with 36 additions and 16 deletions

View file

@ -8,11 +8,12 @@
"kungal",
"kungalgame",
"kungalgamer",
"Licence",
"loli",
"moemoepoint",
"Pinia",
"sina",
"unmoe",
"anti-moe",
"weixin"
],
"i18n-ally.localesPaths": ["src/language"]

View file

@ -1,7 +1,7 @@
<!-- 设置面板组件展示整个论坛的设置面板 -->
<script setup lang="ts">
// vue
import { ref, watch, onMounted } from 'vue'
import { watch } from 'vue'
//
import { Icon } from '@iconify/vue'
//
@ -13,7 +13,6 @@ import { useSettingsPanelStore } from '@/store/modules/settings'
import { storeToRefs } from 'pinia'
// i18n
import { useI18n } from 'vue-i18n'
/*
* 网站的语言设置
*/

View file

@ -1,8 +1,5 @@
<script setup lang="ts">
import { useSettingsPanelStore } from '@/store/modules/settings'
import { storeToRefs } from 'pinia'
const settingsStore = useSettingsPanelStore()
</script>
<template>

View file

@ -1,6 +1,10 @@
export default {
header: {
name: 'KUNGalgame',
allTopic: 'All TOPIC',
createTopic: 'CREATE TOPIC',
technology: 'TECHNOLOGY',
aboutUs: 'ABOUT US',
},
mainPage: {
asideActive: {

View file

@ -1,9 +1,20 @@
export default {
header: {
name: '鲲Galgame',
allTopic: '所有帖子',
createTopic: '发布帖子',
technology: '技术交流',
aboutUs: '关于我们',
},
mainPage: {
asideActive: {
fold: '折叠左侧区域',
update: '更新日志',
balance: '收支公示',
rank: '排行榜单',
regulations: '执行条例',
contacts: '加入我们',
antiMoe: '不萌记录',
hot: `今日热门话题`,
new: `今日最新话题`,
},

View file

@ -197,9 +197,9 @@ export const constantRoutes: RouteRecordRaw[] = [
},
// KUNGalgame 不萌萌页
{
name: 'Unmoe',
path: '/unmoe',
component: () => import('@/views/unmoe/Unmoe.vue'),
name: 'AntiMoe',
path: '/anti-moe',
component: () => import('@/views/anti-moe/AntiMoe.vue'),
meta: {
title: '不萌萌',
transition: 'animate__backInUp',

View file

@ -4,7 +4,7 @@ import MainPageArticle from './article/MainPageArticle.vue'
// store
import { useSettingsPanelStore } from '@/store/modules/settings'
import { storeToRefs } from 'pinia'
import { computed, watch } from 'vue'
import { computed } from 'vue'
// 使 store
const settingsStore = useSettingsPanelStore()
const { showMainPageWidth } = storeToRefs(settingsStore)

View file

@ -17,13 +17,21 @@ const asideBarStatus = (): boolean => {
}
const isActive = ref<boolean>(asideBarStatus())
const asideWidth = isActive.value ? '40px' : '240px'
const asideWidth = ref('240px')
const handleFold = () => {
isActive.value = !isActive.value
}
watch(isActive, () => {
localStorage.setItem('KUNGalgame-main-page-aside', isActive.value.toString())
})
watch(
isActive,
() => {
localStorage.setItem(
'KUNGalgame-main-page-aside',
isActive.value.toString()
)
asideWidth.value = isActive.value ? '240px' : '40px'
},
{ immediate: true }
)
</script>
<template>

View file

@ -14,7 +14,7 @@ const asideItem: aside[] = [
{ index: 3, name: '排行榜单', router: '/rank' },
{ index: 4, name: '执行条例', router: '/regulations' },
{ index: 5, name: '加入我们', router: '/contacts' },
{ index: 6, name: '不萌记录', router: '/unmoe' },
{ index: 6, name: '不萌记录', router: '/anti-moe' },
]
export default asideItem

View file

@ -12,7 +12,7 @@ const asideBarItem: asideBar[] = [
{ index: 2, name: '执行条例', router: '/regulations' },
{ index: 3, name: '更新日志', router: '/update-log' },
{ index: 4, name: '收支公示', router: '/balance' },
{ index: 5, name: '不萌记录', router: '/unmoe' },
{ index: 5, name: '不萌记录', router: '/anti-moe' },
{ index: 6, name: '加入我们', router: '/contacts' },
{ index: 7, name: '感谢名单', router: '/thanks-list' },
{ index: 8, name: '返回主页', router: '/' },