mirror of
https://github.com/johannesjo/super-productivity.git
synced 2026-07-24 00:17:23 +00:00
fix(focus-mode): never show mode selector during a running session
Mode switching mid-session was intentionally allowed for Flowtime, but users reported the selector popping up unexpectedly as confusing. Restrict isShowModeSelector to the Preparation state only.
This commit is contained in:
parent
ea3626cde8
commit
236b4b704a
2 changed files with 3 additions and 7 deletions
|
|
@ -697,8 +697,8 @@ describe('FocusModeMainComponent - notes panel (issue #5752)', () => {
|
|||
(mockStore.dispatch as jasmine.Spy).calls.reset();
|
||||
});
|
||||
|
||||
it('should show the mode selector while a focus session is in progress', () => {
|
||||
expect(component.isShowModeSelector()).toBe(true);
|
||||
it('should hide the mode selector while a focus session is in progress', () => {
|
||||
expect(component.isShowModeSelector()).toBe(false);
|
||||
});
|
||||
|
||||
it('should hide the mode selector while a Flowtime session is in progress', () => {
|
||||
|
|
|
|||
|
|
@ -168,11 +168,7 @@ export class FocusModeMainComponent {
|
|||
displayDuration = signal(25 * 60 * 1000); // Default 25 minutes
|
||||
isTaskSelectorOpen = signal(false);
|
||||
|
||||
isShowModeSelector = computed(
|
||||
() =>
|
||||
this._isPreparation() ||
|
||||
(this._isInProgress() && this.mode() !== FocusModeMode.Flowtime),
|
||||
);
|
||||
isShowModeSelector = computed(() => this._isPreparation());
|
||||
isShowPomodoroSettings = computed(
|
||||
() => this._isPreparation() && this.mode() === FocusModeMode.Pomodoro,
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue