feat(growth): same-day 1-day baselines for new videos

Let 1-day view growth use a zero baseline for videos published today, and the first successful sample for older videos ingested today, without mixing those into 7/30-day rankings.
This commit is contained in:
kairee committed 2026-11-02 20:44:17 +08:00
1 parent 8e7ead1669
commit c5b7185675
21 files changed
+411 -59

No files matched your search

+1 -1
View File
@@ -69,7 +69,7 @@ export async function renderHome(root) {
const growthEmptyTitle = growth.reason
|| `近 ${growthDays} 日增长暂不可用`;
const growthEmptyHint = growthDays <= 1
? "当前快照不足,完成至少 2 天快照后即可显示播放增量。"
? "当日发布按 0 起算;更早发布的新入库需要当天至少两次采样。"
: `需要至少 ${growthDays + 1} 天快照才能计算近 ${growthDays} 日增长。`;
const updatedLabel = formatClock(overview.updated_at);
const dataDateLabel = formatDataDate(overview.data_date);