fix: align numeric habit progress to row end
ci / docker (push) Successful in 5m26s

This commit is contained in:
2026-09-08 11:03:03 +08:00
parent 8fa0418fa2
commit 42b0e37d96
3 changed files with 11 additions and 3 deletions
+6
View File
@@ -114,6 +114,12 @@ describe('task and habit row decoration', () => {
expect(toggleBlock).not.toContain('await loadHabits()')
})
it('places numeric habit progress at the far right instead of under the title', () => {
expect(mvpPanel.match(/<small v-if="habitProgressText\(h\)" class="habit-progress">/g)?.length).toBe(2)
expect(mvpPanel).not.toContain('<span><span class="habit-name">{{ h.name }}</span><small')
expect(css).toContain('.habit-progress{margin-left:auto;')
})
it('can hide completed habits in both Today and full habit views', () => {
expect(mvpPanel).toContain('const hideCompletedHabits = ref(false)')
expect(mvpPanel).toContain('const visibleTodayHabits = computed')