forked from DebaucheryLibrarian/traxxx
Not parsing HTML with jsdom when using http module directly to save memory. Added loading ellipsis to release grid pages.
This commit is contained in:
@@ -64,7 +64,10 @@
|
||||
:fetch-releases="fetchReleases"
|
||||
/>
|
||||
|
||||
<Releases :releases="releases" />
|
||||
<Releases
|
||||
:releases="releases"
|
||||
:done="done"
|
||||
/>
|
||||
|
||||
<Pagination
|
||||
:items-total="totalCount"
|
||||
@@ -93,6 +96,8 @@ import Campaign from '../campaigns/campaign.vue';
|
||||
const converter = new Converter();
|
||||
|
||||
async function fetchReleases(scroll = true) {
|
||||
this.done = false;
|
||||
|
||||
const { tag, releases, totalCount } = await this.$store.dispatch('fetchTagBySlug', {
|
||||
tagSlug: this.$route.params.tagSlug,
|
||||
pageNumber: Number(this.$route.params.pageNumber),
|
||||
@@ -107,6 +112,8 @@ async function fetchReleases(scroll = true) {
|
||||
this.hasMedia = this.tag.poster || this.tag.photos.length > 0;
|
||||
this.description = this.tag.description && converter.makeHtml(escapeHtml(this.tag.description));
|
||||
|
||||
this.done = true;
|
||||
|
||||
if (this.hasMedia) {
|
||||
this.showBannerCampaign = true;
|
||||
}
|
||||
@@ -146,6 +153,7 @@ export default {
|
||||
tag: null,
|
||||
description: null,
|
||||
releases: null,
|
||||
done: false,
|
||||
totalCount: 0,
|
||||
limit: 20,
|
||||
pageTitle: null,
|
||||
|
||||
Reference in New Issue
Block a user