mirror of
https://github.com/linux-odyssey/linux-odyssey.git
synced 2026-11-08 11:30:12 +08:00
add header to login and register page, modified header class but not fit for all circumstances
This commit is contained in:
1 parent
ad29137b86
commit
8c4a9ea871
7 files changed
+40
-22
No files matched your search
@@ -8,24 +8,24 @@ defineProps({
|
|||||||
},
|
},
|
||||||
headerComponent: {
|
headerComponent: {
|
||||||
type: Object,
|
type: Object,
|
||||||
required: true,
|
required: false,
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
<div
|
<div
|
||||||
id="header"
|
id="header"
|
||||||
class="w-full h-[6vh] px-5 flex flex-row items-center justify-between bg-bg-secondary"
|
class="w-full top-0 px-5 fixed flex flex-row bg-bg-secondary justify-between items-center"
|
||||||
>
|
>
|
||||||
<div class="flex flex-row items-center gap-3">
|
<div class="flex flex-row items-center gap-3">
|
||||||
<img src="../img/icon_totem.svg" class="h-8 justify-self-start" />
|
<img src="../../img/icon_totem.svg" class="h-8 justify-self-start" />
|
||||||
<button
|
<RouterLink
|
||||||
id="GameTitle"
|
to="/"
|
||||||
class="text-text-primary inline-block font-bold whitespace-nowrap pt-1"
|
class="text-text-primary inline-block font-bold whitespace-nowrap pt-1"
|
||||||
style="font-size: 2vh"
|
style="font-size: 2vh"
|
||||||
>
|
>
|
||||||
Linux Odyssey
|
Linux Odyssey
|
||||||
</button>
|
</RouterLink>
|
||||||
<p
|
<p
|
||||||
id="QuestTitle"
|
id="QuestTitle"
|
||||||
class="text-text inline-block font-bold whitespace-nowrap"
|
class="text-text inline-block font-bold whitespace-nowrap"
|
||||||
@@ -34,7 +34,7 @@ defineProps({
|
|||||||
{{ title }}
|
{{ title }}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="h-full w-full flex gap-3 items-center justify-end">
|
<div class="w-full flex gap-3 items-center justify-end">
|
||||||
<component :is="headerComponent" />
|
<component :is="headerComponent" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
<script setup>
|
<script setup>
|
||||||
|
import { bugReportUrl } from '../../config'
|
||||||
|
|
||||||
const scrollToSection = (sectionId) => {
|
const scrollToSection = (sectionId) => {
|
||||||
const section = document.getElementById(sectionId)
|
const section = document.getElementById(sectionId)
|
||||||
if (section) {
|
if (section) {
|
||||||
|
|||||||
@@ -46,7 +46,7 @@ onMounted(async () => {
|
|||||||
|
|
||||||
<template>
|
<template>
|
||||||
<!-- game header -->
|
<!-- game header -->
|
||||||
<div class="h-[6vh] w-full">
|
<div class="w-full h-[5vh]">
|
||||||
<HeaderPart
|
<HeaderPart
|
||||||
:title="sessionStore.quest?.title"
|
:title="sessionStore.quest?.title"
|
||||||
:headerComponent="GameHeaderComponents"
|
:headerComponent="GameHeaderComponents"
|
||||||
@@ -59,7 +59,7 @@ onMounted(async () => {
|
|||||||
:value="sessionStore.session.status"
|
:value="sessionStore.session.status"
|
||||||
/>
|
/>
|
||||||
<!-- main -->
|
<!-- main -->
|
||||||
<div id="main" class="h-[94vh] w-full flex p-3 space-x-3">
|
<div id="main" class="h-[95vh] w-full flex p-3 space-x-3">
|
||||||
<!-- Topic and Command List -->
|
<!-- Topic and Command List -->
|
||||||
<div class="bg-bg-secondary h-full w-1/4 rounded-lg">
|
<div class="bg-bg-secondary h-full w-1/4 rounded-lg">
|
||||||
<section id="quest" class="h-full p-3 overflow-auto">
|
<section id="quest" class="h-full p-3 overflow-auto">
|
||||||
|
|||||||
@@ -11,9 +11,9 @@ import { facebookUrl, githubUrl } from '../config'
|
|||||||
<DynamicBackground class="w-full h-full" />
|
<DynamicBackground class="w-full h-full" />
|
||||||
<div class="h-screen w-screen absolute top-0 left-0">
|
<div class="h-screen w-screen absolute top-0 left-0">
|
||||||
<!-- game header -->
|
<!-- game header -->
|
||||||
<HeaderPart :headerComponent="LandingHeaderComponents" />
|
<HeaderPart :headerComponent="LandingHeaderComponents" class="z-50" />
|
||||||
<!-- main content -->
|
<!-- main content -->
|
||||||
<main class="w-full h-[94vh] overflow-y-auto">
|
<main class="w-full h-full overflow-y-auto">
|
||||||
<div class="w-full flex flex-col items-center">
|
<div class="w-full flex flex-col items-center">
|
||||||
<div
|
<div
|
||||||
class="flex flex-col md:flex-row mt-10 justify-around gap-5 items-center my-10"
|
class="flex flex-col md:flex-row mt-10 justify-around gap-5 items-center my-10"
|
||||||
@@ -26,7 +26,6 @@ import { facebookUrl, githubUrl } from '../config'
|
|||||||
Odyssey
|
Odyssey
|
||||||
</h1>
|
</h1>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- intro -->
|
<!-- intro -->
|
||||||
<div class="w-full md:w-2/3 px-5">
|
<div class="w-full md:w-2/3 px-5">
|
||||||
<section
|
<section
|
||||||
@@ -158,6 +157,7 @@ import { facebookUrl, githubUrl } from '../config'
|
|||||||
class="text-text-primary text-3xl font-extrabold font-mono sm:col-span-3 gap-6"
|
class="text-text-primary text-3xl font-extrabold font-mono sm:col-span-3 gap-6"
|
||||||
>
|
>
|
||||||
玩家感想
|
玩家感想
|
||||||
|
<!--可以做成翻頁卡牌一次一個-->
|
||||||
</h1>
|
</h1>
|
||||||
<h1 class="text-xl text-center">"很好玩很像益智遊戲"</h1>
|
<h1 class="text-xl text-center">"很好玩很像益智遊戲"</h1>
|
||||||
<h1 class="text-xl text-center">
|
<h1 class="text-xl text-center">
|
||||||
@@ -195,7 +195,9 @@ import { facebookUrl, githubUrl } from '../config'
|
|||||||
<h1 class="text-text-primary font-extrabold font-mono text-3xl">
|
<h1 class="text-text-primary font-extrabold font-mono text-3xl">
|
||||||
聯絡我們
|
聯絡我們
|
||||||
</h1>
|
</h1>
|
||||||
<div class="flex flex-row items-center justify-around mt-5 gap-5">
|
<div
|
||||||
|
class="flex flex-row items-center justify-around mt-5 gap-5 mb-5"
|
||||||
|
>
|
||||||
<ContactButton
|
<ContactButton
|
||||||
:url="facebookUrl"
|
:url="facebookUrl"
|
||||||
:icons="['fab', 'facebook']"
|
:icons="['fab', 'facebook']"
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import AuthForm from '../components/AuthForm.vue'
|
import AuthForm from '../components/AuthForm.vue'
|
||||||
import Background from '../components/DynamicBackground.vue'
|
import DynamicBackground from '../components/DynamicBackground.vue'
|
||||||
|
import HeaderPart from '../components/header/HeaderPart.vue'
|
||||||
|
|
||||||
import {
|
import {
|
||||||
TooManyRequestsError,
|
TooManyRequestsError,
|
||||||
@@ -45,10 +46,11 @@ const handleLogin = async ({
|
|||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div class="w-screen h-screen">
|
<div class="w-screen h-screen">
|
||||||
<Background class="w-full h-full" />
|
<DynamicBackground class="w-full h-full" />
|
||||||
<div
|
<div
|
||||||
class="w-screen h-screen absolute top-0 left-0 flex flex-wrap justify-center content-center"
|
class="w-screen h-screen absolute top-0 left-0 flex flex-wrap justify-center content-center"
|
||||||
>
|
>
|
||||||
|
<HeaderPart />
|
||||||
<div class="w-fit">
|
<div class="w-fit">
|
||||||
<AuthForm @onSubmit="handleLogin" type="login" />
|
<AuthForm @onSubmit="handleLogin" type="login" />
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -5,10 +5,21 @@ import GameHeaderComponents from '../components/header/GameHeaderComponents.vue'
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div class="h-[6vh] w-full">
|
<div class="w-fit h-[5vh]">
|
||||||
<HeaderPart :title="關卡地圖" :headerComponent="GameHeaderComponents" />
|
<HeaderPart
|
||||||
|
:title="關卡地圖"
|
||||||
|
:headerComponent="GameHeaderComponents"
|
||||||
|
class="z-50"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex flex-col justify-center items-center w-full h-[94vh]">
|
<!-- <p
|
||||||
|
class="text-text-primary absolute z-1 font-bold inline-block tracking-widest"
|
||||||
|
style="left: 1.2%; top: 1.5%; height: 100%; font-size: 2vh"
|
||||||
|
>
|
||||||
|
Quest Map
|
||||||
|
Unix編年史
|
||||||
|
</p> -->
|
||||||
|
<div class="flex flex-col justify-center items-center w-full h-[95vh]">
|
||||||
<QuestMap />
|
<QuestMap />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -3,8 +3,8 @@ import validator from 'validator'
|
|||||||
import { isValidUsername } from '@linux-odyssey/utils'
|
import { isValidUsername } from '@linux-odyssey/utils'
|
||||||
import { passwordPolicy } from '@linux-odyssey/constants'
|
import { passwordPolicy } from '@linux-odyssey/constants'
|
||||||
import AuthForm from '../components/AuthForm.vue'
|
import AuthForm from '../components/AuthForm.vue'
|
||||||
import Background from '../components/DynamicBackground.vue'
|
import DynamicBackground from '../components/DynamicBackground.vue'
|
||||||
|
import HeaderPart from '../components/header/HeaderPart.vue'
|
||||||
import { checkUsername, register } from '../utils/auth'
|
import { checkUsername, register } from '../utils/auth'
|
||||||
import {
|
import {
|
||||||
UnauthorizedError,
|
UnauthorizedError,
|
||||||
@@ -89,11 +89,12 @@ async function check({
|
|||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div class="w-screen h-screen">
|
<div class="w-screen h-screen">
|
||||||
<Background class="w-full h-full" />
|
<DynamicBackground class="w-full h-full" />
|
||||||
<div
|
<div
|
||||||
class="h-screen w-screen absolute top-0 left-0 flex flex-wrap justify-center content-center"
|
class="h-screen w-screen absolute top-0 left-0 flex flex-wrap justify-center content-center"
|
||||||
>
|
>
|
||||||
<div class="w-fit">
|
<HeaderPart />
|
||||||
|
<div class="w-fit h-[91vh]">
|
||||||
<AuthForm
|
<AuthForm
|
||||||
@onSubmit="handleRegister"
|
@onSubmit="handleRegister"
|
||||||
@onChange="check"
|
@onChange="check"
|
||||||
|
|||||||
Reference in new issue
Block a user