chore: remove or comment out some unused things

This commit is contained in:
Hakadao
2023-07-23 15:38:20 +08:00
parent d1cb2cc490
commit 3f48bb37ce
2 changed files with 16 additions and 18 deletions

View File

@@ -22,8 +22,6 @@ if (isFirefox) {
})
}
else {
// Firefox `browser.tabs.executeScript()` requires scripts return a primitive value
document.addEventListener('DOMContentLoaded', () => {
injectApp()
})

View File

@@ -45,22 +45,22 @@ onMounted(async () => {
keyword.value,
)
if (favoriteVideosWrap.value) {
favoriteVideosWrap.value.addEventListener('scroll', () => {
// When you scroll to the bottom, they will automatically
// add the next page of data to the history list
if (
favoriteVideosWrap.value.clientHeight
+ favoriteVideosWrap.value.scrollTop
>= favoriteVideosWrap.value.scrollHeight - 20
&& favoriteResources.length > 0
&& !isLoading.value
) {
if (activatedMediaId.value && !noMoreContent.value)
getFavoriteResources(activatedMediaId.value, currentPageNum.value++)
}
})
}
// if (favoriteVideosWrap.value) {
// favoriteVideosWrap.value.addEventListener('scroll', () => {
// // When you scroll to the bottom, they will automatically
// // add the next page of data to the history list
// if (
// favoriteVideosWrap.value.clientHeight
// + favoriteVideosWrap.value.scrollTop
// >= favoriteVideosWrap.value.scrollHeight - 20
// && favoriteResources.length > 0
// && !isLoading.value
// ) {
// if (activatedMediaId.value && !noMoreContent.value)
// getFavoriteResources(activatedMediaId.value, currentPageNum.value++)
// }
// })
// }
})
async function getFavoriteCategories() {