Skip to content

Commit

Permalink
korede douda
Browse files Browse the repository at this point in the history
  • Loading branch information
tamaina committed Jul 17, 2023
1 parent 4881237 commit d82d038
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions packages/frontend/src/components/MkPagination.vue
Original file line number Diff line number Diff line change
Expand Up @@ -518,11 +518,20 @@ const prepend = (item: MisskeyEntity): void => {
if (
!isPausingUpdate.value && // タブがバックグラウンドの時/スクロール調整中はキューに追加する
queueSize.value === 0 && // キューに残っている場合はキューに追加する
active.value && // keepAliveで隠されている間はキューに追加する
!backed // 先頭に表示されていない時はキューに追加する
active.value // keepAliveで隠されている間はキューに追加する
) {
if (items.value.has(item.id)) return; // 既にタイムラインにある場合は何もしない
unshiftItems([item]);
if (!backed) {
// 先頭にいる場合は単に追加する
if (items.value.has(item.id)) return; // 既にタイムラインにある場合は何もしない
unshiftItems([item]);
} else if (!weakBacked) {
// ちょっと先頭にいる場合はスクロールを調整する
prependQueue(item);
executeQueue();
} else {
// 先頭にいない場合はキューに追加する
prependQueue(item);
}
} else {
prependQueue(item);
}
Expand Down

0 comments on commit d82d038

Please sign in to comment.