diff --git a/frontend/src/views/Feed.vue b/frontend/src/views/Feed.vue index 068ddc4..f398741 100644 --- a/frontend/src/views/Feed.vue +++ b/frontend/src/views/Feed.vue @@ -44,17 +44,12 @@ let categoryPromptTimer: number | null = null // - items 没这条 → 不渲染(孤儿) // - items 有 + Map 也有 → 渲染 // - items 有 + Map 没 → 不渲染(用户已 dismiss/确认/超时) -const articlesWithPrompts = computed(() => { - const r = items.value.filter((a) => (categoryPromptsByArticle.value.get(a.id)?.length ?? 0) > 0) - // eslint-disable-next-line no-console - console.log('[AWP] resultLen=', r.length, 'itemsLen=', items.value.length, 'mapSize=', categoryPromptsByArticle.value.size) - return r -}) +const articlesWithPrompts = computed(() => + items.value.filter((a) => (categoryPromptsByArticle.value.get(a.id)?.length ?? 0) > 0) +) // 移除某篇文章的所有提示条(8 秒超时 / 确认后 / 过滤变化) function clearPromptsForArticle(articleId: number) { - // eslint-disable-next-line no-console - console.log('[CLEAR_ONE]', articleId, 'stack:', new Error().stack?.split('\n').slice(2, 5).join(' | ')) if (categoryPromptsByArticle.value.has(articleId)) { const next = new Map(categoryPromptsByArticle.value) next.delete(articleId) @@ -64,8 +59,6 @@ function clearPromptsForArticle(articleId: number) { // 全清 function clearAllPrompts() { - // eslint-disable-next-line no-console - console.log('[CLEAR_ALL] size=', categoryPromptsByArticle.value.size, 'stack:', new Error().stack?.split('\n').slice(2, 5).join(' | ')) if (categoryPromptsByArticle.value.size > 0) { categoryPromptsByArticle.value = new Map() } @@ -693,58 +686,57 @@ onMounted(async () => { {{ a.is_read ? '已读' : '标为已读' }} + +
+ +
+ + ✓ 已将《{{ a.title_zh || a.title }}》标记为已读 + +
+ + + + + 全部已读 + + + 稍后再说 + + + +
- -
- -
- - ✓ 已将《{{ a.title_zh || a.title }}》标记为已读 - -
- - - - - 全部已读 - - - 稍后再说 - - - -