@@ -118,16 +118,16 @@ describe('approved cream solid button system', () => {
|
||||
})
|
||||
|
||||
describe('mobile navigation styles', () => {
|
||||
it('uses five direct mobile destinations and keeps Settings in the sidebar', () => {
|
||||
it('renames the bottom More tab to a direct Settings tab', () => {
|
||||
expect(app).not.toContain('aria-controls="mobile-more-menu"')
|
||||
expect(app).not.toContain('<Ellipsis/><span>更多</span>')
|
||||
expect(app).toContain("<StickyNote/><span>备忘录</span>")
|
||||
expect(app).toContain("<CalendarDays/><span>日历</span>")
|
||||
expect(app).not.toContain("@click=\"switchView('settings')\"><Settings/><span>设置</span>")
|
||||
expect(app).toContain("<Settings/><span>设置</span>")
|
||||
expect(app).toContain("@click=\"switchView('settings')\"")
|
||||
expect(app).toContain('<span>设置</span>')
|
||||
})
|
||||
|
||||
it('marks only exact mobile destinations active and exposes aria-current only there', () => {
|
||||
for (const view of ['today', 'habits', 'countdowns', 'memos', 'calendar']) {
|
||||
for (const view of ['today', 'habits', 'countdowns', 'settings']) {
|
||||
expect(app).toContain(`:class="{active:activeView==='${view}'}" :aria-current="activeView==='${view}' ? 'page' : undefined"`)
|
||||
}
|
||||
expect(app).not.toContain("activeView==='tasks'||activeView==='upcoming'||activeView==='trash'||activeView==='settings'")
|
||||
|
||||
Reference in New Issue
Block a user