-
Notifications
You must be signed in to change notification settings - Fork 0
/
app.vue
140 lines (127 loc) · 2.97 KB
/
app.vue
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
<script setup lang="ts">
import { useStyle } from './composables/useStyle'
const siteConfig = useSiteConfig()
const { theme, themeOverrides } = useStyle()
function _console() {
// 控制台输出
const styleTitle1 = 'font-size: 20px;font-weight: 600;color: rgb(244,167,89);'
const styleTitle2 = 'font-size:12px;color: rgb(244,167,89);'
const styleContent = 'color: rgb(30,152,255);'
const title1 = `${siteConfig.name} 主页\n`
const title2 = `${siteConfig.description}`
const content = `\n\n 版本:v1.0.0 \n\n 主页:${siteConfig.authorLink} \n\n 作者:${siteConfig.author} \n\n`
console.info(`%c${title1} %c${title2} %c${content}`, styleTitle1, styleTitle2, styleContent)
}
useHead({
title: siteConfig.name,
link: [
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' },
],
meta: [
{ name: 'description', content: siteConfig.description },
{ name: 'keywords', content: siteConfig.keywords },
{ name: 'author', content: siteConfig.author },
{ name: 'copyright', content: `Copyright © 2024 - ${new Date().getFullYear()}` },
{ name: 'theme-color', content: 'white' },
],
})
useSeoMeta({
title: siteConfig.name,
description: siteConfig.description,
ogTitle: siteConfig.title,
ogDescription: siteConfig.description,
ogImage: siteConfig.logo,
ogUrl: siteConfig.url,
})
onMounted(() => {
_console()
})
</script>
<template>
<n-config-provider :theme="theme" :theme-overrides="themeOverrides" inline-theme-disabled>
<n-global-style />
<NuxtLayout>
<NuxtPage />
</NuxtLayout>
</n-config-provider>
</template>
<style>
.page-enter-active,
.page-leave-active {
transition: all 0.5s ease-in-out;
overflow: hidden;
}
.page-enter-from,
.page-leave-to {
opacity: 0;
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
</style>
<style lang="scss" scoped>
.load-box {
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
width: 100vw;
margin: 0;
background: #000;
animation: fadeIn 0.5s ease-in-out forwards;
-webkit-animation: fadeIn 0.5s ease-in-out forwards;
}
.loader {
position: relative;
display: flex;
align-items: center;
justify-content: center;
width: 100%;
max-width: 6rem;
margin-top: 3rem;
margin-bottom: 3rem;
}
.loader:before,
.loader:after {
content: '';
position: absolute;
border-radius: 50%;
animation: pulsOut 1.8s ease-in-out infinite;
filter: drop-shadow(0 0 1rem rgba(255, 255, 255, 0.75));
}
.loader:before {
width: 100%;
padding-bottom: 100%;
box-shadow: inset 0 0 0 1rem #fff;
animation-name: pulsIn;
}
.loader:after {
width: calc(100% - 2rem);
padding-bottom: calc(100% - 2rem);
box-shadow: 0 0 0 0 #fff;
}
@keyframes pulsIn {
0% {
box-shadow: inset 0 0 0 1rem #fff;
opacity: 1;
}
50%,
100% {
box-shadow: inset 0 0 0 0 #fff;
opacity: 0;
}
}
@keyframes pulsOut {
0%,
50% {
box-shadow: 0 0 0 0 #fff;
opacity: 0;
}
100% {
box-shadow: 0 0 0 1rem #fff;
opacity: 1;
}
}
</style>