completionId: cgen-b9903d445a5d49e1a36980988f8ac2e3
cgen-b9903d445a5d49e1a36980988f8ac2e3
This commit is contained in:
parent
da13686b96
commit
3b7a8b3e3e
1 changed files with 4 additions and 3 deletions
|
|
@ -20,11 +20,12 @@ import {
|
|||
import { useNavigate } from "react-router-dom";
|
||||
import { useEffect, useState, useRef } from "react";
|
||||
import LoadingScreen from "@/components/LoadingScreen";
|
||||
import { aethexToast } from "@/lib/aethex-toast";
|
||||
import { useArmToast } from "@/hooks/use-arm-toast";
|
||||
|
||||
export default function Corp() {
|
||||
const navigate = useNavigate();
|
||||
const { theme } = useArmTheme();
|
||||
const armToast = useArmToast();
|
||||
const [isLoading, setIsLoading] = useState(true);
|
||||
const toastShownRef = useRef(false);
|
||||
|
||||
|
|
@ -32,13 +33,13 @@ export default function Corp() {
|
|||
const timer = setTimeout(() => {
|
||||
setIsLoading(false);
|
||||
if (!toastShownRef.current) {
|
||||
aethexToast.system("Corp systems engaged");
|
||||
armToast.system("Corp systems engaged");
|
||||
toastShownRef.current = true;
|
||||
}
|
||||
}, 900);
|
||||
|
||||
return () => clearTimeout(timer);
|
||||
}, []);
|
||||
}, [armToast]);
|
||||
|
||||
if (isLoading) {
|
||||
return (
|
||||
|
|
|
|||
Loading…
Reference in a new issue