-
Notifications
You must be signed in to change notification settings - Fork 127
/
Copy pathApp.vue
78 lines (73 loc) · 1.54 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
<template>
<a-config-provider :locale="currentLanguage">
<div id="app">
<full-loading :show="fullLoading" :text="loadingText" />
<app-layout />
</div>
</a-config-provider>
</template>
<script lang="ts">
import { computed, defineComponent } from 'vue'
import AppLayout from '@/layout/AppLayout.vue'
import { Locales } from '@/i18n/index'
import { useStore } from 'vuex'
import { StateType } from '@/@types'
const App = defineComponent({
setup() {
const store = useStore<StateType>()
const fullLoading = computed(() => store.state.app.fullLoading)
const loadingText = computed(() => store.state.app.loadingText)
const currentLanguage = computed(() => Locales[store.state.app.language])
return {
currentLanguage,
loadingText,
fullLoading,
Locales
}
},
components: {
AppLayout
}
})
export default App
</script>
<style lang="less" scoped>
.target {
display: block;
width: 100px;
color: green;
font-weight: bold;
size: 18px;
}
.kk {
display: flex;
flex-flow: row nowrap;
align-items: center;
}
.area {
display: flex;
flex-flow: column nowrap;
align-items: center;
justify-content: center;
width: 100%;
height: 200px;
line-height: 40px;
}
#app {
font-family: Avenir, Helvetica, Arial, sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
text-align: center;
color: #2c3e50;
}
#nav {
padding: 30px;
a {
font-weight: bold;
color: #2c3e50;
&.router-link-exact-active {
color: #42b983;
}
}
}
</style>