File tree Expand file tree Collapse file tree 1 file changed +76
-71
lines changed Expand file tree Collapse file tree 1 file changed +76
-71
lines changed Original file line number Diff line number Diff line change 4
4
<image class =" logo" src =" https://cdn.uviewui.com/uview/common/logo.png" mode =" widthFix" ></image >
5
5
<view class =" nav-info" >
6
6
<view class =" nav-title__text" >
7
- {{$t('common.title')}}
7
+ < text class = " nav-info__title__text " >uView {{version}}</ text >
8
8
</view >
9
9
<view class =" nav-slogan" >
10
- {{$t('common.intro')}}
10
+ {{$t('common.intro')}}
11
11
</view >
12
12
</view >
13
13
</view >
21
21
</template >
22
22
23
23
<script >
24
- export default {
25
- props: {
26
- desc: String ,
27
- title: String ,
28
- },
29
- computed: {
30
- lang () {
31
- return this .$i18n .locale == ' zh' ? ' zh' : ' en' ;
32
- }
33
- },
34
- methods: {
35
- switchLang () {
36
- this .$i18n .locale = this .$i18n .locale == ' en' ? ' zh' : ' en' ;
37
- this .vuex_tabbar [0 ].text = this .$t (' nav.components' )
38
- this .vuex_tabbar [1 ].text = this .$t (' nav.js' )
39
- this .vuex_tabbar [2 ].text = this .$t (' nav.template' )
40
- uni .setNavigationBarTitle ({
41
- title: this .$t (this .title )
42
- });
43
- }
24
+ export default {
25
+ props: {
26
+ desc: String ,
27
+ title: String ,
28
+ },
29
+ computed: {
30
+ lang () {
31
+ return this .$i18n .locale == ' zh' ? ' zh' : ' en' ;
32
+ }
33
+ },
34
+ data () {
35
+ return {
36
+ version: uni .$u .config .v
37
+ }
38
+ },
39
+ methods: {
40
+ switchLang () {
41
+ this .$i18n .locale = this .$i18n .locale == ' en' ? ' zh' : ' en' ;
42
+ this .vuex_tabbar [0 ].text = this .$t (' nav.components' )
43
+ this .vuex_tabbar [1 ].text = this .$t (' nav.js' )
44
+ this .vuex_tabbar [2 ].text = this .$t (' nav.template' )
45
+ uni .setNavigationBarTitle ({
46
+ title: this .$t (this .title )
47
+ });
44
48
}
45
49
}
50
+ }
46
51
</script >
47
52
48
53
<style lang="scss" scoped>
49
- .nav-wrap {
50
- padding : 15px ;
51
- position : relative ;
52
- }
53
-
54
- .lang {
55
- position : absolute ;
56
- top : 15px ;
57
- right : 15px ;
58
- }
59
-
60
- .nav-title {
61
- /* #ifndef APP-NVUE */
62
- display : flex ;
63
- /* #endif */
64
- flex-direction : row ;
65
- align-items : center ;
66
- }
67
-
68
- .nav-info {
69
- margin-left : 15px ;
70
- }
71
-
72
- .nav-title__text {
73
- /* #ifndef APP-NVUE */
74
- display : flex ;
75
- /* #endif */
76
- color : $u-main-color ;
77
- font-size : 25px ;
78
- font-weight : bold ;
79
- }
80
-
81
- .logo {
82
- width : 70px ;
83
- /* #ifndef APP-NVUE */
84
- height : auto ;
85
- /* #endif */
86
- }
87
-
88
- .nav-slogan {
89
- color : $u-tips-color ;
90
- font-size : 14px ;
91
- }
92
-
93
- .nav-desc {
94
- margin-top : 10px ;
95
- font-size : 14px ;
96
- color : $u-content-color ;
97
- }
54
+ .nav-wrap {
55
+ padding : 15px ;
56
+ position : relative ;
57
+ }
58
+
59
+ .lang {
60
+ position : absolute ;
61
+ top : 15px ;
62
+ right : 15px ;
63
+ }
64
+
65
+ .nav-title {
66
+ /* #ifndef APP-NVUE */
67
+ display : flex ;
68
+ /* #endif */
69
+ flex-direction : row ;
70
+ align-items : center ;
71
+ }
72
+
73
+ .nav-info {
74
+ margin-left : 15px ;
75
+ }
76
+
77
+ .nav-title__text {
78
+ /* #ifndef APP-NVUE */
79
+ display : flex ;
80
+ /* #endif */
81
+ color : $u-main-color ;
82
+ font-size : 25px ;
83
+ font-weight : bold ;
84
+ }
85
+
86
+ .logo {
87
+ width : 70px ;
88
+ /* #ifndef APP-NVUE */
89
+ height : auto ;
90
+ /* #endif */
91
+ }
92
+
93
+ .nav-slogan {
94
+ color : $u-tips-color ;
95
+ font-size : 14px ;
96
+ }
97
+
98
+ .nav-desc {
99
+ margin-top : 10px ;
100
+ font-size : 14px ;
101
+ color : $u-content-color ;
102
+ }
98
103
</style >
You can’t perform that action at this time.
0 commit comments