diff options
| author | HJ <30-hj@users.noreply.git.pleroma.social> | 2024-05-22 12:15:57 +0000 |
|---|---|---|
| committer | HJ <30-hj@users.noreply.git.pleroma.social> | 2024-05-22 12:15:57 +0000 |
| commit | 3e99006e2ab06d2c8ade2eb20e12b1d2fbbcaac2 (patch) | |
| tree | ec9b7035c45a45f17f973162ba8a514003b39eb5 /src/components/quotes_timeline/quotes_timeline.js | |
| parent | e232ba0ec5542020f83ea685b8fb491b23def627 (diff) | |
| parent | 9d2572ffdb384ca4458cd96daf6c11e5d46dd03a (diff) | |
Merge branch 'quotes-count' into 'develop'
Display quotes count on posts and add quotes list page
See merge request pleroma/pleroma-fe!1885
Diffstat (limited to 'src/components/quotes_timeline/quotes_timeline.js')
| -rw-r--r-- | src/components/quotes_timeline/quotes_timeline.js | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/src/components/quotes_timeline/quotes_timeline.js b/src/components/quotes_timeline/quotes_timeline.js new file mode 100644 index 00000000..a5f42da5 --- /dev/null +++ b/src/components/quotes_timeline/quotes_timeline.js @@ -0,0 +1,26 @@ +import Timeline from '../timeline/timeline.vue' + +const QuotesTimeline = { + created () { + this.$store.commit('clearTimeline', { timeline: 'quotes' }) + this.$store.dispatch('startFetchingTimeline', { timeline: 'quotes', statusId: this.statusId }) + }, + components: { + Timeline + }, + computed: { + statusId () { return this.$route.params.id }, + timeline () { return this.$store.state.statuses.timelines.quotes } + }, + watch: { + statusId () { + this.$store.commit('clearTimeline', { timeline: 'quotes' }) + this.$store.dispatch('startFetchingTimeline', { timeline: 'quotes', statusId: this.statusId }) + } + }, + unmounted () { + this.$store.dispatch('stopFetchingTimeline', 'quotes') + } +} + +export default QuotesTimeline |
