diff --git a/DESIGN.md b/DESIGN.md index efa8b2d..6e51c4f 100644 --- a/DESIGN.md +++ b/DESIGN.md @@ -5,7 +5,7 @@ - Pokopia Wiki 是一个面向 Pokopia 游戏资料的社区 Wiki。 - 所有人都可以浏览 Wiki 内容。 - 已注册并完成邮箱验证的用户可以创建、编辑、删除 Wiki 内容。 -- 前台以 Pokemon、栖息地、物品、材料单、每日 CheckList、Life 为主要浏览入口。 +- 前台以 Pokemon、栖息地、物品、材料单、每日 CheckList、Life、Dish、Events、Actions、Dream Island、Clothes 为主要浏览入口。 - 管理入口用于维护全局配置、语言、列表排序和每日 CheckList。 ## 技术栈 @@ -404,6 +404,18 @@ API 暴露边界: - 非作者不能编辑或删除其他用户的 Life Post。 - 非作者不能删除其他用户的 Life Comment。 +## 开发中入口 + +以下前台公开入口当前仅展示“正在开发中”占位页,不提供数据模型、后端 API、编辑表单、管理入口或排序能力: + +- Dish +- Events +- Actions:游戏内快捷动作,例如挥手、跳舞等。 +- Dream Island +- Clothes + +这些开发中入口在主导航和占位页中显示状态 Badge,便于用户识别当前功能状态。 + ## 前端交互与 UI - UI 风格以 `DesignGuidelines.html` 为准。 diff --git a/frontend/src/App.vue b/frontend/src/App.vue index e291db6..4ed9241 100644 --- a/frontend/src/App.vue +++ b/frontend/src/App.vue @@ -3,7 +3,20 @@ import { computed, onMounted, onUnmounted, ref } from 'vue'; import { useI18n } from 'vue-i18n'; import { useRouter } from 'vue-router'; import AppShell from './components/AppShell.vue'; -import { iconAdmin, iconChecklist, iconHabitat, iconItem, iconLife, iconPokemon, iconRecipe } from './icons'; +import { + iconAction, + iconAdmin, + iconChecklist, + iconClothes, + iconDish, + iconDreamIsland, + iconEvent, + iconHabitat, + iconItem, + iconLife, + iconPokemon, + iconRecipe +} from './icons'; import { getCurrentLocale, onLocaleChange, setCurrentLocale } from './i18n'; import { api, getAuthToken, onAuthTokenChange, setAuthToken, type AuthUser, type Language } from './services/api'; @@ -18,11 +31,20 @@ const languages = ref([ let removeAuthListener: (() => void) | null = null; let removeLocaleListener: (() => void) | null = null; +function inDevBadge() { + return { label: t('common.inDev'), tone: 'info' as const }; +} + const navItems = computed(() => [ { label: t('nav.pokemon'), to: '/pokemon', icon: iconPokemon }, { label: t('nav.habitats'), to: '/habitats', icon: iconHabitat }, { label: t('nav.items'), to: '/items', icon: iconItem }, { label: t('nav.recipes'), to: '/recipes', icon: iconRecipe }, + { label: t('nav.dish'), to: '/dish', icon: iconDish, badge: inDevBadge() }, + { label: t('nav.events'), to: '/events', icon: iconEvent, badge: inDevBadge() }, + { label: t('nav.actions'), to: '/actions', icon: iconAction, badge: inDevBadge() }, + { label: t('nav.dreamIsland'), to: '/dream-island', icon: iconDreamIsland, badge: inDevBadge() }, + { label: t('nav.clothes'), to: '/clothes', icon: iconClothes, badge: inDevBadge() }, { label: t('nav.checklist'), to: '/checklist', icon: iconChecklist }, { label: t('nav.life'), to: '/life', icon: iconLife }, { label: t('nav.admin'), to: '/admin', icon: iconAdmin } diff --git a/frontend/src/components/AppShell.vue b/frontend/src/components/AppShell.vue index 84bfe49..7adf79c 100644 --- a/frontend/src/components/AppShell.vue +++ b/frontend/src/components/AppShell.vue @@ -6,12 +6,21 @@ import { useRoute } from 'vue-router'; import { iconClose, iconLogin, iconLogout, iconMenu, iconRegister, iconTranslate, type AppIcon } from '../icons'; import type { AuthUser, Language } from '../services/api'; import PokeBallMark from './PokeBallMark.vue'; +import StatusBadge from './StatusBadge.vue'; defineProps<{ currentUser: AuthUser | null; languages: Language[]; locale: string; - navItems: Array<{ label: string; to: string; icon?: AppIcon }>; + navItems: Array<{ + label: string; + to: string; + icon?: AppIcon; + badge?: { + label: string; + tone?: 'info' | 'success' | 'warning' | 'danger' | 'neutral'; + }; + }>; }>(); const emit = defineEmits<{ @@ -132,7 +141,14 @@ onBeforeUnmount(() => { @click="closeSidebar" >