diff --git a/package-lock.json b/package-lock.json
index 13b1b84..fc72c2b 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -19,7 +19,6 @@
"svelte": "^4.2.7",
"svelte-check": "^3.6.0",
"svelte-highlight": "^7.6.0",
- "svelte-parallax": "^0.6.0",
"typescript": "^5.0.0",
"vite": "^5.0.3"
}
@@ -898,12 +897,6 @@
"node": ">=8.0"
}
},
- "node_modules/focus-options-polyfill": {
- "version": "1.6.0",
- "resolved": "https://registry.npmjs.org/focus-options-polyfill/-/focus-options-polyfill-1.6.0.tgz",
- "integrity": "sha512-uyrAmLZrPnUItQY5wTdg31TO9GGZRGsh/jmohUg9oLmLi/sw5y7LlTV/mwyd6rvbxIOGwmRiv6LcTS8w7Bk9NQ==",
- "dev": true
- },
"node_modules/fs-constants": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz",
@@ -1801,15 +1794,6 @@
"resolved": "https://registry.npmjs.org/svelte-media-queries/-/svelte-media-queries-1.6.2.tgz",
"integrity": "sha512-SMz6od/vIeZEGlc4P0HKJK4G0fZotuwFhCSpBQaPqh75h6sL6sNf+4+IjbegFKXbP7b+SOfyzVOIMXTr8jynkA=="
},
- "node_modules/svelte-parallax": {
- "version": "0.6.0",
- "resolved": "https://registry.npmjs.org/svelte-parallax/-/svelte-parallax-0.6.0.tgz",
- "integrity": "sha512-W2dGPNmK274AmL8Ibzr96luh24jr3u2MfAmAJTpnhAZwxkRws5MKgCxfxBBPvpRUc2GpGGIGanhTYXoHV6DcBw==",
- "dev": true,
- "dependencies": {
- "focus-options-polyfill": "^1.6.0"
- }
- },
"node_modules/svelte/node_modules/@ampproject/remapping": {
"version": "2.2.1",
"resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.2.1.tgz",
diff --git a/package.json b/package.json
index bffde61..85b0370 100644
--- a/package.json
+++ b/package.json
@@ -18,7 +18,6 @@
"svelte": "^4.2.7",
"svelte-check": "^3.6.0",
"svelte-highlight": "^7.6.0",
- "svelte-parallax": "^0.6.0",
"typescript": "^5.0.0",
"vite": "^5.0.3"
},
diff --git a/src/routes/zhen/Comps/TopAnimatedBackground.svelte b/src/routes/zhen/Comps/TopAnimatedBackground.svelte
index 34218e2..9ccc3d9 100644
--- a/src/routes/zhen/Comps/TopAnimatedBackground.svelte
+++ b/src/routes/zhen/Comps/TopAnimatedBackground.svelte
@@ -4,8 +4,6 @@
import TopNameTextPlate from "./TopNameTextPlate.svelte";
//import { throttle } from "./../Utils/Throttle";
- import { Parallax, ParallaxLayer, StickyLayer } from "svelte-parallax";
-
// Params
let mouseMoveScale: number = 0.25;
let targetTextLenght: number = 100;
@@ -54,32 +52,24 @@
windowRef.addEventListener("resize", updateDimensions);
const RevertToOrigin = () => {
- if (
- navigator.userAgent.search(/gecko/i) > 0 &&
- StartPageAnimated !== null
- ) {
- StartPageAnimated.classList.add("FirefoxSmoothTranition");
+ if(navigator.userAgent.search(/gecko/i)>0 && StartPageAnimated !== null){
+ StartPageAnimated.classList.add('FirefoxSmoothTranition');
}
- updateAnimation(new Vector2(windowWidth / 2, windowHeight / 2));
+ updateAnimation(new Vector2(windowWidth/2, windowHeight/2));
};
- document.documentElement.addEventListener("mouseleave", RevertToOrigin);
+ document.documentElement.addEventListener('mouseleave', RevertToOrigin)
const RemoveFirefoxSmoothTranition = () => {
- if (
- navigator.userAgent.search(/gecko/i) > 0 &&
- StartPageAnimated !== null
- ) {
- StartPageAnimated.classList.remove("FirefoxSmoothTranition");
+ if(navigator.userAgent.search(/gecko/i)>0 && StartPageAnimated !== null){
+ StartPageAnimated.classList.remove('FirefoxSmoothTranition');
}
};
- document.documentElement.addEventListener(
- "mouseenter",
- RemoveFirefoxSmoothTranition,
- );
+ document.documentElement.addEventListener('mouseenter', RemoveFirefoxSmoothTranition)
return () => {
windowRef.removeEventListener("resize", updateDimensions);
};
+
});
const programmingLanguages: string[] = [
@@ -91,52 +81,27 @@
"JAVASCRIPT",
"TYPESCRIPT",
"HTML",
- "CSS",
+ "CSS"
];
function getRandomInt(max: number) {
return Math.floor(Math.random() * max);
}
- function GrabRandomString() {
+ function GrabRandomString(){
let outString: string = "";
while (outString.length < targetTextLenght) {
- outString +=
- programmingLanguages[
- getRandomInt(programmingLanguages.length)
- ] + " ";
+ outString += programmingLanguages[getRandomInt(programmingLanguages.length)] + " ";
}
return outString; // At about target size
}
+