diff --git a/src/App.vue b/src/App.vue index 37ad403..2473673 100644 --- a/src/App.vue +++ b/src/App.vue @@ -24,7 +24,7 @@ #app { padding: 16px 16px 50px; background: url("assets/bg.jpeg"); - height: 100vh; + min-height: 100vh; background-size: 100% 100%; } diff --git a/src/configs/routes.ts b/src/configs/routes.ts index de29705..900b5b9 100644 --- a/src/configs/routes.ts +++ b/src/configs/routes.ts @@ -1,6 +1,7 @@ import { RouteRecordRaw } from "vue-router"; import IndexPage from "../pages/IndexPage.vue"; import GamePage from "../pages/GamePage.vue"; +import ConfigPage from "../pages/ConfigPage.vue"; export default [ { @@ -11,4 +12,8 @@ export default [ path: "/game", component: GamePage, }, + { + path: "/config", + component: ConfigPage, + }, ] as RouteRecordRaw[]; diff --git a/src/pages/ConfigPage.vue b/src/pages/ConfigPage.vue new file mode 100644 index 0000000..115448f --- /dev/null +++ b/src/pages/ConfigPage.vue @@ -0,0 +1,75 @@ + + + diff --git a/src/pages/GamePage.vue b/src/pages/GamePage.vue index 573c78a..25e3adf 100644 --- a/src/pages/GamePage.vue +++ b/src/pages/GamePage.vue @@ -1,6 +1,6 @@ @@ -53,8 +53,10 @@ const { setGameConfig } = useGlobalStore(); const toGamePage = (config?: GameConfig) => { if (config) { setGameConfig(config); + router.push("/game"); + } else { + router.push("/config"); } - router.push("/game"); };