File tree Expand file tree Collapse file tree 3 files changed +30
-44
lines changed Expand file tree Collapse file tree 3 files changed +30
-44
lines changed Original file line number Diff line number Diff line change 1
- <script >
2
- export default {
3
- props: {
4
- visible: {
5
- type: Boolean ,
6
- default: false ,
7
- },
8
- },
9
- emits: [` close` ],
10
- methods: {
11
- onRedirect (url ) {
12
- window .open (url)
13
- },
1
+ <script setup>
2
+ const props = defineProps ({
3
+ visible: {
4
+ type: Boolean ,
5
+ default: false ,
14
6
},
7
+ })
8
+
9
+ defineEmits ([` close` ])
10
+
11
+ function onRedirect (url ) {
12
+ window .open (url)
15
13
}
16
14
</script >
17
15
18
16
<template >
19
17
<el-dialog
20
18
title =" 关于"
21
19
class =" about__dialog"
22
- :model-value =" visible"
20
+ :model-value =" props. visible"
23
21
width =" 30%"
24
22
center
25
23
@close =" $emit('close')"
Original file line number Diff line number Diff line change 1
- <script >
2
- export default {
3
- name: ` CssEditor` ,
4
- props: {
5
- showCssEditor: {
6
- type: Boolean ,
7
- default: false ,
8
- },
1
+ <script setup>
2
+ const props = defineProps ({
3
+ showCssEditor: {
4
+ type: Boolean ,
5
+ default: false ,
9
6
},
10
- }
7
+ })
11
8
</script >
12
9
13
10
<template >
14
11
<transition enter-active-class =" bounceInRight" >
15
- <el-col v-show =" showCssEditor" :span =" 8" class =" cssEditor-wrapper h-full" >
12
+ <el-col v-show =" props. showCssEditor" :span =" 8" class =" cssEditor-wrapper h-full" >
16
13
<textarea
17
14
id =" cssEditor"
18
15
type =" textarea"
Original file line number Diff line number Diff line change 1
- <script >
2
- import { mapState } from ' pinia '
1
+ <script setup >
2
+ import { onMounted , ref } from ' vue '
3
3
import { useStore } from ' @/stores'
4
4
5
- export default {
6
- name: ` RunLoading` ,
7
- data () {
8
- return {
9
- loading: true ,
10
- }
11
- },
12
- computed: {
13
- ... mapState (useStore, {
14
- nightMode : ({ nightMode }) => nightMode,
15
- }),
16
- },
17
- mounted () {
18
- setTimeout (() => {
19
- this .loading = false
20
- }, 100 )
21
- },
22
- }
5
+ const loading = ref (true )
6
+
7
+ const nightMode = useStore ().nightMode
8
+
9
+ onMounted (() => {
10
+ setTimeout (() => {
11
+ loading .value = false
12
+ }, 100 )
13
+ })
23
14
</script >
24
15
25
16
<template >
You can’t perform that action at this time.
0 commit comments