|
@@ -2,6 +2,7 @@
|
|
|
import { reactive, onMounted } from "vue";
|
|
|
import { useRoute, useRouter } from "vue-router";
|
|
|
import { useI18n } from "vue-i18n";
|
|
|
+import Marquee from "../components/Marquee.vue";
|
|
|
|
|
|
const route = useRoute();
|
|
|
const router = useRouter();
|
|
@@ -23,7 +24,7 @@ function chooseLang(lang) {
|
|
|
console.log("選擇語言:", lang);
|
|
|
locale.value = lang; // i18n locale
|
|
|
localStorage.setItem("lang", lang);
|
|
|
- router.push("/step1");
|
|
|
+ // router.push("/step1");s
|
|
|
}
|
|
|
|
|
|
let langList = reactive([
|
|
@@ -49,11 +50,13 @@ let langList = reactive([
|
|
|
<template>
|
|
|
<div class="lang-content">
|
|
|
<div style="position: relative">
|
|
|
- <section>
|
|
|
+ <section class="postcard-title">
|
|
|
<h3>歡迎來到 AI 明信片</h3>
|
|
|
<p>請選擇您的語言</p>
|
|
|
</section>
|
|
|
- <button
|
|
|
+ <Marquee />
|
|
|
+ <div class="btn-content">
|
|
|
+ <button
|
|
|
v-for="(item, index) in langList"
|
|
|
:key="index"
|
|
|
@click="chooseLang(item.value)"
|
|
@@ -61,24 +64,29 @@ let langList = reactive([
|
|
|
>
|
|
|
{{ item.lang }}
|
|
|
</button>
|
|
|
+ </div>
|
|
|
+
|
|
|
</div>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<style lang="scss">
|
|
|
+
|
|
|
.lang-content {
|
|
|
width: 100%;
|
|
|
height: 100vh;
|
|
|
padding-top: 4rem;
|
|
|
display: flex;
|
|
|
flex-direction: column;
|
|
|
- justify-content: center;
|
|
|
- background-color: #231816;
|
|
|
+ justify-content: start;
|
|
|
+ // background-color: #231816;
|
|
|
background-size: cover;
|
|
|
background-position: center center;
|
|
|
+ background-image: url("@/assets/img/background.webp");
|
|
|
+ background-blend-mode: multiply;
|
|
|
|
|
|
section {
|
|
|
- margin: 2.5rem auto;
|
|
|
+ margin: 4rem auto;
|
|
|
color: white;
|
|
|
}
|
|
|
|
|
@@ -102,5 +110,12 @@ let langList = reactive([
|
|
|
.main-btn {
|
|
|
margin: 0 auto 2.5rem;
|
|
|
}
|
|
|
+
|
|
|
+ .btn-content{
|
|
|
+ position: absolute;
|
|
|
+ top: 70%;
|
|
|
+ left: 50%;
|
|
|
+ transform: translate(-50%, -50%);
|
|
|
+ }
|
|
|
}
|
|
|
</style>
|