repod/src/App.vue

42 lines
911 B
Vue
Raw Normal View History

2023-06-22 18:10:30 +00:00
<template>
2023-06-24 15:18:27 +00:00
<NcContent app-name="repod">
2023-12-23 23:24:46 +00:00
<GPodder v-if="!gpodder" />
<Subscriptions v-if="gpodder" />
<router-view v-if="gpodder" :key="$route.path" />
2023-08-30 17:59:20 +00:00
<Bar />
2023-06-24 15:18:27 +00:00
</NcContent>
2023-06-22 18:10:30 +00:00
</template>
<script lang="ts">
import 'toastify-js/src/toastify.css'
2024-08-09 20:21:07 +00:00
import { mapActions, mapState } from 'pinia'
2023-08-24 21:59:55 +00:00
import Bar from './components/Player/Bar.vue'
2023-07-04 15:43:58 +00:00
import GPodder from './views/GPodder.vue'
import { NcContent } from '@nextcloud/vue'
2023-08-28 19:18:14 +00:00
import Subscriptions from './components/Sidebar/Subscriptions.vue'
2023-12-23 23:24:46 +00:00
import { loadState } from '@nextcloud/initial-state'
import { usePlayer } from './store/player.ts'
2023-06-22 18:10:30 +00:00
export default {
name: 'App',
components: {
2023-08-24 21:59:55 +00:00
Bar,
2023-07-04 15:43:58 +00:00
GPodder,
2023-06-24 22:34:02 +00:00
NcContent,
2023-08-28 19:18:14 +00:00
Subscriptions,
2023-06-22 18:10:30 +00:00
},
2023-12-23 23:24:46 +00:00
computed: {
2024-08-09 20:21:07 +00:00
...mapState(usePlayer, ['paused']),
2023-12-23 23:24:46 +00:00
gpodder() {
return loadState('repod', 'gpodder', false)
},
},
mounted() {
this.init()
},
methods: {
...mapActions(usePlayer, ['init']),
},
2023-06-22 18:10:30 +00:00
}
</script>