Skip to content

Commit adc7fc6

Browse files
committed
hide notice while focus
1 parent af2836f commit adc7fc6

1 file changed

Lines changed: 27 additions & 24 deletions

File tree

frontend/src/ts/components/test/modes-notice/TestModesNotice.tsx

Lines changed: 27 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import {
99
} from "../../../states/core";
1010
import { hotkeys } from "../../../states/hotkeys";
1111
import {
12+
getFocus,
1213
getLoadedChallenge,
1314
getPaceCaretWpm,
1415
isPaceRepeat,
@@ -29,30 +30,32 @@ import { PbNotice } from "./PbNotice";
2930

3031
export function TestModesNotice() {
3132
return (
32-
<div class="flex flex-wrap justify-center gap-x-4 text-base text-sub transition-opacity select-none">
33-
<Repeated />
34-
<ResultSaving />
35-
<QuickRestart />
36-
<LongText />
37-
<LoadedChallenge />
38-
<ZenMode />
39-
<Language />
40-
<Difficulty />
41-
<BlindMode />
42-
<LazyMode />
43-
<PaceCaretNotice />
44-
<AverageNotice />
45-
<PbNotice />
46-
<MinSpeed />
47-
<MinAcc />
48-
<MinBurst />
49-
<Funbox />
50-
<ConfidenceMode />
51-
<StopOnError />
52-
<Layout />
53-
<OppositeShift />
54-
<Tags />
55-
</div>
33+
<Show when={!getFocus()}>
34+
<div class="flex flex-wrap justify-center gap-x-4 text-base text-sub transition-opacity select-none">
35+
<Repeated />
36+
<ResultSaving />
37+
<QuickRestart />
38+
<LongText />
39+
<LoadedChallenge />
40+
<ZenMode />
41+
<Language />
42+
<Difficulty />
43+
<BlindMode />
44+
<LazyMode />
45+
<PaceCaretNotice />
46+
<AverageNotice />
47+
<PbNotice />
48+
<MinSpeed />
49+
<MinAcc />
50+
<MinBurst />
51+
<Funbox />
52+
<ConfidenceMode />
53+
<StopOnError />
54+
<Layout />
55+
<OppositeShift />
56+
<Tags />
57+
</div>
58+
</Show>
5659
);
5760
}
5861

0 commit comments

Comments
 (0)