Skip to content

Commit

Permalink
Update Timeline, disable new post update checker and hide reaction ba…
Browse files Browse the repository at this point in the history
…r on network timeline
  • Loading branch information
dansup committed Jun 29, 2021
1 parent 3ba31bd commit 1e3d3a6
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 10 deletions.
21 changes: 12 additions & 9 deletions resources/assets/js/components/Timeline.vue
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@

<status-card
:status="status"
:reaction-bar="reactionBar"
v-on:status-delete="deleteStatus"
v-on:comment-focus="commentFocus"
/>
Expand Down Expand Up @@ -707,7 +708,8 @@
discover_feed: [],
recentFeed: this.scope === 'home' ? true : false,
recentFeedMin: null,
recentFeedMax: null
recentFeedMax: null,
reactionBar: this.scope === 'network' ? false : true
}
},
Expand Down Expand Up @@ -831,7 +833,8 @@
this.fetchHashtagPosts();
}
// this.fetchStories();
this.rtw();
// this.rtw();
setTimeout(function() {
document.querySelectorAll('.timeline .card-body .comments .comment-body a').forEach(function(i, e) {
i.href = App.util.format.rewriteLinks(i);
Expand Down Expand Up @@ -902,20 +905,20 @@
if(self.ids.indexOf(d.id) == -1) {
self.feed.push(d);
self.ids.push(d.id);
vids.push({
sid: d.id,
pid: d.account.id
});
// vids.push({
// sid: d.id,
// pid: d.account.id
// });
}
});
this.min_id = Math.max(...this.ids).toString();
this.max_id = Math.min(...this.ids).toString();
this.page += 1;
$state.loaded();
this.loading = false;
axios.post('/api/status/view', {
'_v': vids,
});
// axios.post('/api/status/view', {
// '_v': vids,
// });
} else {
$state.complete();
}
Expand Down
7 changes: 6 additions & 1 deletion resources/assets/js/components/partials/StatusCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
</div>

<div class="card-body">
<div class="reactions my-1 pb-2">
<div v-if="reactionBar" class="reactions my-1 pb-2">
<h3 v-if="status.favourited" class="fas fa-heart text-danger pr-3 m-0 cursor-pointer" title="Like" v-on:click="likeStatus(status, $event);"></h3>
<h3 v-else class="far fa-heart pr-3 m-0 like-btn text-dark cursor-pointer" title="Like" v-on:click="likeStatus(status, $event);"></h3>
<h3 v-if="!status.comments_disabled" class="far fa-comment text-dark pr-3 m-0 cursor-pointer" title="Comment" v-on:click="commentFocus(status, $event)"></h3>
Expand Down Expand Up @@ -140,6 +140,11 @@
recommended: {
type: Boolean,
default: false
},
reactionBar: {
type: Boolean,
default: true
}
},
Expand Down

0 comments on commit 1e3d3a6

Please sign in to comment.