summaryrefslogtreecommitdiff
path: root/src/client/app/desktop/views/widgets/activity.vue
blob: 73c6d0ef647be3ffb07d8be0ff83b5c4c50fe45c (plain)
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
<template>
<mk-activity
	:design="props.design"
	:init-view="props.view"
	:user="$store.state.i"
	@view-changed="viewChanged"/>
</template>

<script lang="ts">
import define from '../../../common/define-widget';
export default define({
	name: 'activity',
	props: () => ({
		design: 0,
		view: 0
	})
}).extend({
	methods: {
		func() {
			if (this.props.design == 2) {
				this.props.design = 0;
			} else {
				this.props.design++;
			}
			this.save();
		},
		viewChanged(view) {
			this.props.view = view;
			this.save();
		}
	}
});
</script>