Skip to content

Commit 85181e3

Browse files
committed
SOMETHING CHANGED WHEN REBASING NOW IT DOESNT WORK AGAIN, code is pretty much the same and I don't know how to go back
1 parent 0bd4dc0 commit 85181e3

2 files changed

Lines changed: 4 additions & 6 deletions

File tree

src/components/Instructions.tsx

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ export default function BreathingInstructions({
133133
window.clearTimeout(animationTimeoutRef.current);
134134
}
135135
};
136-
}, [animationSet.waitSet, showIntro, exerciseType, animationProvider.changeAnimation]);
136+
}, [animationSet.waitSet, showIntro, exerciseType, animationProvider, animationProvider.changeAnimation]);
137137

138138
useEffect(() => {
139139
return () => {
@@ -145,7 +145,7 @@ export default function BreathingInstructions({
145145
if (!showIntro && !animationSet.exerciseSet && !isPaused) {
146146
setAnimationSet((prev) => ({ ...prev, exerciseSet: true }));
147147
}
148-
}, [showIntro, animationSet.exerciseSet]);
148+
}, [showIntro, isPaused, animationSet.exerciseSet]);
149149

150150
const handlePauseToggle = () => {
151151
if (!isPaused) {
@@ -269,9 +269,7 @@ const handlePauseToggle = () => {
269269
transition={{ duration: 1.5, delay: 0.3 }}
270270
className="text-lg md:text-xl text-[#ffffff] text-center max-w-md mx-auto"
271271
>
272-
{t(
273-
`instructions.${exerciseType}.${exercise.instructions[currentInstruction].key}`
274-
)}
272+
{t(`instructions.${exerciseType}.${exercise.instructions[currentInstruction].key}`)}
275273
</motion.p>
276274

277275
<motion.div

src/components/WelcomePage.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ const WelcomePage = () => {
1010

1111
useEffect(() => {
1212
animationProvider.changeAnimation("main");
13-
}, []);
13+
}, [animationProvider]);
1414

1515
const toggleInfo = () => {
1616
setIsInfoVisible(!isInfoVisible);

0 commit comments

Comments
 (0)