feat(viewer): hide view count in album header (user request) — counting/reporting unaffected
Co-Authored-By: Claude Code <noreply@anthropic.com>
This commit is contained in:
@@ -95,7 +95,7 @@ describe('activity page (Task 6)', () => {
|
||||
// 无 banner 资产 → 不渲染 img;viewCount 未知(null)→ 浏览项显示「—」而非 0(UI-02 §4.1)。
|
||||
// (参考稿:浏览项前置 ◉ Unicode 图标,属渲染内容的一部分。)
|
||||
expect(wrapper.find('img.banner').exists()).toBe(false);
|
||||
expect(wrapper.find('.view-count').text()).toBe('◉—');
|
||||
expect(wrapper.find('.view-count').exists()).toBe(false); // 已隐藏(2026-09-24)
|
||||
expect(document.title).toBe('2026 公司年会');
|
||||
});
|
||||
|
||||
|
||||
@@ -75,7 +75,8 @@ describe('album header info area (UI-02 V02)', () => {
|
||||
// pre-line:换行保留;文本插值(非 HTML 注入)。
|
||||
expect(wrapper.find('.description').text()).toBe('年度盛会\n多行介绍');
|
||||
// Intl.NumberFormat 分组 + 词条拼接(§4.1);参考稿:浏览项前置 ◉ Unicode 图标。
|
||||
expect(wrapper.find('.view-count').text()).toBe('◉1,286 次浏览');
|
||||
// 浏览次数已按用户要求隐藏(2026-09-24)——计数与上报不受影响,仅不展示。
|
||||
expect(wrapper.find('.view-count').exists()).toBe(false);
|
||||
expect(wrapper.find('.meta').text()).toContain('大宴会厅 · 上海市浦东新区世纪大道 100 号');
|
||||
// Asia/Shanghai(夹具时区):UTC 10-01 → 本地 10月1日。
|
||||
expect(wrapper.find('.meta').text()).toContain('10月1日');
|
||||
@@ -98,8 +99,8 @@ describe('album header info area (UI-02 V02)', () => {
|
||||
|
||||
expect(wrapper.find('img.banner').exists()).toBe(false);
|
||||
expect(wrapper.find('.description').exists()).toBe(false);
|
||||
expect(wrapper.findAll('.meta-item')).toHaveLength(2); // 浏览(—)+ 日期;地点整项省略
|
||||
expect(wrapper.find('.view-count').text()).toBe('◉—');
|
||||
expect(wrapper.findAll('.meta-item')).toHaveLength(1); // 浏览已隐藏,仅日期;地点整项省略
|
||||
expect(wrapper.find('.view-count').exists()).toBe(false); // 已隐藏(2026-09-24)
|
||||
expect(wrapper.find('.categories').exists()).toBe(false);
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user