diff --git a/frontend/src/PomodoroIntegration.test.ts b/frontend/src/PomodoroIntegration.test.ts index adcd846..9b2c33d 100644 --- a/frontend/src/PomodoroIntegration.test.ts +++ b/frontend/src/PomodoroIntegration.test.ts @@ -30,4 +30,15 @@ describe('pomodoro integration', () => { expect(panel).toContain('Date.now(), WRITER_ID') expect(panel).toContain('savePomodoroState(window.localStorage, STORAGE_KEY, state.value)') }) + + it('offers duration settings and keeps announcements honest about the running state', () => { + expect(panel).toContain("import AppSheet from './components/AppSheet.vue'") + expect(panel).toContain('@click="settingsOpen = true"') + expect(panel).toContain('已跳过休息,下一轮专注已开始') + expect(panel).toContain('专注完成,休息已开始') + expect(panel).toContain('休息完成,下一轮专注已开始') + expect(panel).toContain("v-if=\"state.status !== 'idle'\"") + expect(panel).toContain("setPomodoroDurations(state.value, minutes, state.value.breakMinutes") + expect(css).toContain('.pomodoro-settings__options button{min-height:44px') + }) }) diff --git a/frontend/src/PomodoroPanel.vue b/frontend/src/PomodoroPanel.vue index 0db3cbe..1002e38 100644 --- a/frontend/src/PomodoroPanel.vue +++ b/frontend/src/PomodoroPanel.vue @@ -1,6 +1,7 @@