particles

This commit is contained in:
incognitotgt 2024-04-16 07:44:10 -04:00
parent 82ca99aa5d
commit 3833559cec
No known key found for this signature in database
GPG key ID: D229D19A500C60B0

View file

@ -14,7 +14,7 @@ const particlesUrl = localStorage.getItem("particles") || "none";
export default function App() { export default function App() {
const [init, setInit] = useState(false); const [init, setInit] = useState(false);
const {background} = useTheme(); const { background } = useTheme();
// this should be run only once per application lifetime // this should be run only once per application lifetime
useEffect(() => { useEffect(() => {
initParticlesEngine(async (engine) => { initParticlesEngine(async (engine) => {
@ -37,14 +37,17 @@ export default function App() {
{window.location.origin === "https://nebulaproxy.io" && <Meta />} {window.location.origin === "https://nebulaproxy.io" && <Meta />}
{/* {window.location.origin === "http://localhost:8080" && <Meta />} */} {/* {window.location.origin === "http://localhost:8080" && <Meta />} */}
<Suspense fallback={<LoadSuspense />}> <Suspense fallback={<LoadSuspense />}>
<Routes /> <main className="absolute z-50 h-screen w-screen">
<div className="z-10 h-full w-full bg-primary"> <Routes />
</main>
<div className="-z-10 h-full w-full bg-primary">
{init && particlesUrl !== "none" && ( {init && particlesUrl !== "none" && (
<Particles <Particles
id="tsparticles" id="tsparticles"
url={particlesUrl} url={particlesUrl}
particlesLoaded={particlesLoaded} particlesLoaded={particlesLoaded}
class="bg-primary" class="bg-primary"
zIndex={-10}
/> />
)} )}
</div> </div>