misskey/src/client/app/desktop/views/widgets/timemachine.vue

30 lines
494 B
Vue
Raw Normal View History

2018-02-19 09:26:20 +00:00
<template>
<div class="mkw-timemachine">
<mk-calendar :design="props.design" @chosen="chosen"/>
</div>
</template>
<script lang="ts">
2018-02-24 15:18:09 +00:00
import define from '../../../common/define-widget';
2018-02-19 09:26:20 +00:00
export default define({
name: 'timemachine',
2018-02-21 06:30:03 +00:00
props: () => ({
2018-02-19 09:26:20 +00:00
design: 0
2018-02-21 06:30:03 +00:00
})
2018-02-19 09:26:20 +00:00
}).extend({
methods: {
chosen(date) {
this.$emit('chosen', date);
},
func() {
if (this.props.design == 5) {
this.props.design = 0;
} else {
this.props.design++;
}
2018-04-29 08:17:15 +00:00
this.save();
2018-02-19 09:26:20 +00:00
}
}
});
</script>