Compare commits
3 Commits
e76affaea1
...
d72d2731d9
Author | SHA1 | Date | |
---|---|---|---|
d72d2731d9 | |||
f3ac7cc684 | |||
b1b3de295c |
19
bun.lock
19
bun.lock
@@ -12,16 +12,13 @@
|
|||||||
"@tailwindcss/typography": "0.5.16",
|
"@tailwindcss/typography": "0.5.16",
|
||||||
"@tailwindcss/vite": "^4.1.11",
|
"@tailwindcss/vite": "^4.1.11",
|
||||||
"@tauri-apps/api": "2.6.0",
|
"@tauri-apps/api": "2.6.0",
|
||||||
"@tauri-apps/plugin-dialog": "2.3.0",
|
"@tauri-apps/plugin-dialog": "2.3.1",
|
||||||
"@tauri-apps/plugin-fs": "2.4.0",
|
"@tauri-apps/plugin-fs": "2.4.1",
|
||||||
"@tauri-apps/plugin-shell": "2.3.0",
|
"@tauri-apps/plugin-shell": "2.3.0",
|
||||||
"@tauri-apps/plugin-sql": "2.3.0",
|
|
||||||
"animejs": "^4.0.2",
|
"animejs": "^4.0.2",
|
||||||
"buffer": "^6.0.3",
|
"buffer": "^6.0.3",
|
||||||
"crypto-js": "^4.2.0",
|
"crypto-js": "^4.2.0",
|
||||||
"lucide-svelte": "0.525.0",
|
"lucide-svelte": "0.525.0",
|
||||||
"osu-classes": "3.1.0",
|
|
||||||
"osu-parsers": "4.1.7",
|
|
||||||
"semver": "^7.7.2",
|
"semver": "^7.7.2",
|
||||||
"svelte-confetti": "^2.0.0",
|
"svelte-confetti": "^2.0.0",
|
||||||
"tw-animate-css": "^1.3.0",
|
"tw-animate-css": "^1.3.0",
|
||||||
@@ -296,14 +293,12 @@
|
|||||||
|
|
||||||
"@tauri-apps/cli-win32-x64-msvc": ["@tauri-apps/cli-win32-x64-msvc@2.6.1", "", { "os": "win32", "cpu": "x64" }, "sha512-fBsjPqIIHaaQt7tnjIGmPHu5p/BNBVD4JfOhO3QqIVBzAb+W2bDyIQPdoDMI943soLr/+N10xeTiPu+3L74+dQ=="],
|
"@tauri-apps/cli-win32-x64-msvc": ["@tauri-apps/cli-win32-x64-msvc@2.6.1", "", { "os": "win32", "cpu": "x64" }, "sha512-fBsjPqIIHaaQt7tnjIGmPHu5p/BNBVD4JfOhO3QqIVBzAb+W2bDyIQPdoDMI943soLr/+N10xeTiPu+3L74+dQ=="],
|
||||||
|
|
||||||
"@tauri-apps/plugin-dialog": ["@tauri-apps/plugin-dialog@2.3.0", "", { "dependencies": { "@tauri-apps/api": "^2.6.0" } }, "sha512-ylSBvYYShpGlKKh732ZuaHyJ5Ie1JR71QCXewCtsRLqGdc8Is4xWdz6t43rzXyvkItM9syNPMvFVcvjgEy+/GA=="],
|
"@tauri-apps/plugin-dialog": ["@tauri-apps/plugin-dialog@2.3.1", "", { "dependencies": { "@tauri-apps/api": "^2.6.0" } }, "sha512-B7jvyhycV8SI/WHzPjciwtYfdFM6/9EXuMjRgYWZwn8GPDmHxpT80aJdb/eDVN+NgoAFDh9bu4QPonYahoYnZQ=="],
|
||||||
|
|
||||||
"@tauri-apps/plugin-fs": ["@tauri-apps/plugin-fs@2.4.0", "", { "dependencies": { "@tauri-apps/api": "^2.6.0" } }, "sha512-Sp8AdDcbyXyk6LD6Pmdx44SH3LPeNAvxR2TFfq/8CwqzfO1yOyV+RzT8fov0NNN7d9nvW7O7MtMAptJ42YXA5g=="],
|
"@tauri-apps/plugin-fs": ["@tauri-apps/plugin-fs@2.4.1", "", { "dependencies": { "@tauri-apps/api": "^2.6.0" } }, "sha512-vJlKZVGF3UAFGoIEVT6Oq5L4HGDCD78WmA4uhzitToqYiBKWAvZR61M6zAyQzHqLs0ADemkE4RSy/5sCmZm6ZQ=="],
|
||||||
|
|
||||||
"@tauri-apps/plugin-shell": ["@tauri-apps/plugin-shell@2.3.0", "", { "dependencies": { "@tauri-apps/api": "^2.6.0" } }, "sha512-6GIRxO2z64uxPX4CCTuhQzefvCC0ew7HjdBhMALiGw74vFBDY95VWueAHOHgNOMV4UOUAFupyidN9YulTe5xlA=="],
|
"@tauri-apps/plugin-shell": ["@tauri-apps/plugin-shell@2.3.0", "", { "dependencies": { "@tauri-apps/api": "^2.6.0" } }, "sha512-6GIRxO2z64uxPX4CCTuhQzefvCC0ew7HjdBhMALiGw74vFBDY95VWueAHOHgNOMV4UOUAFupyidN9YulTe5xlA=="],
|
||||||
|
|
||||||
"@tauri-apps/plugin-sql": ["@tauri-apps/plugin-sql@2.3.0", "", { "dependencies": { "@tauri-apps/api": "^2.6.0" } }, "sha512-JYwIocfsLaDWa41LMiZWuzts7yCJR+EpZPRmgpO7Gd7XiAS9S67dKz306j/k/d9XntB0YopMRBol2OIWMschuA=="],
|
|
||||||
|
|
||||||
"@types/bun": ["@types/bun@1.2.18", "", { "dependencies": { "bun-types": "1.2.18" } }, "sha512-Xf6RaWVheyemaThV0kUfaAUvCNokFr+bH8Jxp+tTZfx7dAPA8z9ePnP9S9+Vspzuxxx9JRAXhnyccRj3GyCMdQ=="],
|
"@types/bun": ["@types/bun@1.2.18", "", { "dependencies": { "bun-types": "1.2.18" } }, "sha512-Xf6RaWVheyemaThV0kUfaAUvCNokFr+bH8Jxp+tTZfx7dAPA8z9ePnP9S9+Vspzuxxx9JRAXhnyccRj3GyCMdQ=="],
|
||||||
|
|
||||||
"@types/cookie": ["@types/cookie@0.6.0", "", {}, "sha512-4Kh9a6B2bQciAhf7FSuMRRkUWecJgJu9nPnx3yzpsfXX/c50REIqpHY4C82bXP90qrLtXtkDxTZosYO3UpOwlA=="],
|
"@types/cookie": ["@types/cookie@0.6.0", "", {}, "sha512-4Kh9a6B2bQciAhf7FSuMRRkUWecJgJu9nPnx3yzpsfXX/c50REIqpHY4C82bXP90qrLtXtkDxTZosYO3UpOwlA=="],
|
||||||
@@ -562,8 +557,6 @@
|
|||||||
|
|
||||||
"lucide-svelte": ["lucide-svelte@0.525.0", "", { "peerDependencies": { "svelte": "^3 || ^4 || ^5.0.0-next.42" } }, "sha512-kfuN6JcCqTfCz2B76aXnyGLAzEBRSYw5GaUspM5RNHQZS5aI5yaKu06fbaofOk8cDvUtY0AUm/zAix7aUX6Q3A=="],
|
"lucide-svelte": ["lucide-svelte@0.525.0", "", { "peerDependencies": { "svelte": "^3 || ^4 || ^5.0.0-next.42" } }, "sha512-kfuN6JcCqTfCz2B76aXnyGLAzEBRSYw5GaUspM5RNHQZS5aI5yaKu06fbaofOk8cDvUtY0AUm/zAix7aUX6Q3A=="],
|
||||||
|
|
||||||
"lzma-js-simple-v2": ["lzma-js-simple-v2@1.2.3", "", { "dependencies": { "@types/node": "^20.12.7" } }, "sha512-6kgy86Q3YLolV6dOwCqdQXg3V07e3XJJ6wqfrN8/s65mvCfqkr+jMJkfiSZNvk+u2ig+G8rLdtaoW/g1oJiwow=="],
|
|
||||||
|
|
||||||
"magic-string": ["magic-string@0.30.17", "", { "dependencies": { "@jridgewell/sourcemap-codec": "^1.5.0" } }, "sha512-sNPKHvyjVf7gyjwS4xGTaW/mCnF8wnjtifKBEhxfZ7E/S8tQ0rssrwGNn6q8JH/ohItJfSQp9mBtQYuTlH5QnA=="],
|
"magic-string": ["magic-string@0.30.17", "", { "dependencies": { "@jridgewell/sourcemap-codec": "^1.5.0" } }, "sha512-sNPKHvyjVf7gyjwS4xGTaW/mCnF8wnjtifKBEhxfZ7E/S8tQ0rssrwGNn6q8JH/ohItJfSQp9mBtQYuTlH5QnA=="],
|
||||||
|
|
||||||
"merge2": ["merge2@1.4.1", "", {}, "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg=="],
|
"merge2": ["merge2@1.4.1", "", {}, "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg=="],
|
||||||
@@ -598,10 +591,6 @@
|
|||||||
|
|
||||||
"optionator": ["optionator@0.9.4", "", { "dependencies": { "deep-is": "^0.1.3", "fast-levenshtein": "^2.0.6", "levn": "^0.4.1", "prelude-ls": "^1.2.1", "type-check": "^0.4.0", "word-wrap": "^1.2.5" } }, "sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g=="],
|
"optionator": ["optionator@0.9.4", "", { "dependencies": { "deep-is": "^0.1.3", "fast-levenshtein": "^2.0.6", "levn": "^0.4.1", "prelude-ls": "^1.2.1", "type-check": "^0.4.0", "word-wrap": "^1.2.5" } }, "sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g=="],
|
||||||
|
|
||||||
"osu-classes": ["osu-classes@3.1.0", "", {}, "sha512-kz38FWMGnz5lr6ofovUrNaDAcs1gNpwlDc1qHjW86ILQZXG44w/+NflV7EyFomkI05XCADGfltE4FVoPwrkrmg=="],
|
|
||||||
|
|
||||||
"osu-parsers": ["osu-parsers@4.1.7", "", { "dependencies": { "lzma-js-simple-v2": "^1.2.3" }, "peerDependencies": { "osu-classes": "^3.1.0" } }, "sha512-b8aYJy9vK0Yk8zVbxVN+HSChGnXufSxePb3gABG8s5YGCY+31CKJTUHDAVRST0kX4lyeI4Z3iRxsCRftHFHEug=="],
|
|
||||||
|
|
||||||
"p-limit": ["p-limit@3.1.0", "", { "dependencies": { "yocto-queue": "^0.1.0" } }, "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ=="],
|
"p-limit": ["p-limit@3.1.0", "", { "dependencies": { "yocto-queue": "^0.1.0" } }, "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ=="],
|
||||||
|
|
||||||
"p-locate": ["p-locate@5.0.0", "", { "dependencies": { "p-limit": "^3.0.2" } }, "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw=="],
|
"p-locate": ["p-locate@5.0.0", "", { "dependencies": { "p-limit": "^3.0.2" } }, "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw=="],
|
||||||
|
@@ -21,21 +21,17 @@
|
|||||||
"@better-fetch/fetch": "^1.1.18",
|
"@better-fetch/fetch": "^1.1.18",
|
||||||
"@fontsource/sora": "^5.2.6",
|
"@fontsource/sora": "^5.2.6",
|
||||||
"@fontsource/space-mono": "^5.2.8",
|
"@fontsource/space-mono": "^5.2.8",
|
||||||
"@iarna/toml": "2.2.5",
|
|
||||||
"@number-flow/svelte": "^0.3.9",
|
"@number-flow/svelte": "^0.3.9",
|
||||||
"@tailwindcss/typography": "0.5.16",
|
"@tailwindcss/typography": "0.5.16",
|
||||||
"@tailwindcss/vite": "^4.1.11",
|
"@tailwindcss/vite": "^4.1.11",
|
||||||
"@tauri-apps/api": "2.6.0",
|
"@tauri-apps/api": "2.6.0",
|
||||||
"@tauri-apps/plugin-dialog": "2.3.0",
|
"@tauri-apps/plugin-dialog": "2.3.1",
|
||||||
"@tauri-apps/plugin-fs": "2.4.0",
|
"@tauri-apps/plugin-fs": "2.4.1",
|
||||||
"@tauri-apps/plugin-shell": "2.3.0",
|
"@tauri-apps/plugin-shell": "2.3.0",
|
||||||
"@tauri-apps/plugin-sql": "2.3.0",
|
|
||||||
"animejs": "^4.0.2",
|
"animejs": "^4.0.2",
|
||||||
"buffer": "^6.0.3",
|
"buffer": "^6.0.3",
|
||||||
"crypto-js": "^4.2.0",
|
"crypto-js": "^4.2.0",
|
||||||
"lucide-svelte": "0.525.0",
|
"lucide-svelte": "0.525.0",
|
||||||
"osu-classes": "3.1.0",
|
|
||||||
"osu-parsers": "4.1.7",
|
|
||||||
"semver": "^7.7.2",
|
"semver": "^7.7.2",
|
||||||
"tw-animate-css": "^1.3.0",
|
"tw-animate-css": "^1.3.0",
|
||||||
"svelte-confetti": "^2.0.0"
|
"svelte-confetti": "^2.0.0"
|
||||||
@@ -43,6 +39,7 @@
|
|||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@eslint/compat": "^1.2.5",
|
"@eslint/compat": "^1.2.5",
|
||||||
"@eslint/js": "^9.18.0",
|
"@eslint/js": "^9.18.0",
|
||||||
|
"@iarna/toml": "2.2.5",
|
||||||
"@lucide/svelte": "^0.525.0",
|
"@lucide/svelte": "^0.525.0",
|
||||||
"@sveltejs/adapter-static": "3.0.8",
|
"@sveltejs/adapter-static": "3.0.8",
|
||||||
"@sveltejs/kit": "2.22.2",
|
"@sveltejs/kit": "2.22.2",
|
||||||
|
1069
src-tauri/Cargo.lock
generated
1069
src-tauri/Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "ezpplauncher"
|
name = "ezpplauncher"
|
||||||
version = "3.0.2"
|
version = "3.0.3"
|
||||||
description = "EZPPLauncher redefined."
|
description = "EZPPLauncher redefined."
|
||||||
authors = ["HorizonCode"]
|
authors = ["HorizonCode"]
|
||||||
edition = "2024"
|
edition = "2024"
|
||||||
@@ -15,20 +15,19 @@ name = "ezpplauncher_lib"
|
|||||||
crate-type = ["staticlib", "cdylib", "rlib"]
|
crate-type = ["staticlib", "cdylib", "rlib"]
|
||||||
|
|
||||||
[build-dependencies]
|
[build-dependencies]
|
||||||
tauri-build = { version = "2.3.0", features = [] }
|
tauri-build = { version = "2.3.1", features = [] }
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
tauri = { version = "2.6.2", features = [] }
|
tauri = { version = "2.7.0", features = [] }
|
||||||
tauri-plugin-shell = "2.3.0"
|
tauri-plugin-shell = "2.3.0"
|
||||||
serde = { version = "1.0.219", features = ["derive"] }
|
serde = { version = "1.0.219", features = ["derive"] }
|
||||||
serde_json = "1.0.140"
|
serde_json = "1.0.141"
|
||||||
serde_repr = "0.1.20"
|
serde_repr = "0.1.20"
|
||||||
tauri-plugin-sql = "2.3.0"
|
tauri-plugin-dialog = "2.3.1"
|
||||||
tauri-plugin-dialog = "2.3.0"
|
tauri-plugin-fs = "2.4.1"
|
||||||
tauri-plugin-fs = "2.4.0"
|
|
||||||
hardware-id = "0.3.0"
|
hardware-id = "0.3.0"
|
||||||
tauri-plugin-cors-fetch = "4.1.0"
|
tauri-plugin-cors-fetch = "4.1.0"
|
||||||
sysinfo = "0.35.2"
|
sysinfo = "0.36.1"
|
||||||
reqwest = { version = "0.12.22", features = ["json", "stream"] }
|
reqwest = { version = "0.12.22", features = ["json", "stream"] }
|
||||||
md5 = "0.8.0"
|
md5 = "0.8.0"
|
||||||
tokio = { version = "1.46.1", features = ["full"] }
|
tokio = { version = "1.46.1", features = ["full"] }
|
||||||
@@ -40,9 +39,9 @@ once_cell = "1.21.3"
|
|||||||
[target.'cfg(windows)'.dependencies]
|
[target.'cfg(windows)'.dependencies]
|
||||||
winreg = "0.55.0"
|
winreg = "0.55.0"
|
||||||
winapi = { version = "0.3", features = ["winuser", "wincrypt", "memoryapi", "winbase", "dpapi"] }
|
winapi = { version = "0.3", features = ["winuser", "wincrypt", "memoryapi", "winbase", "dpapi"] }
|
||||||
base64 = "0.21"
|
base64 = "0.22.1"
|
||||||
widestring = "1.0"
|
widestring = "1.0"
|
||||||
|
|
||||||
[target.'cfg(not(any(target_os = "android", target_os = "ios")))'.dependencies]
|
[target.'cfg(not(any(target_os = "android", target_os = "ios")))'.dependencies]
|
||||||
tauri-plugin-single-instance = "2.3.0"
|
tauri-plugin-single-instance = "2.3.2"
|
||||||
|
|
||||||
|
@@ -67,7 +67,6 @@ pub fn run() {
|
|||||||
.plugin(tauri_plugin_dialog::init())
|
.plugin(tauri_plugin_dialog::init())
|
||||||
.plugin(tauri_plugin_shell::init())
|
.plugin(tauri_plugin_shell::init())
|
||||||
.plugin(tauri_plugin_cors_fetch::init())
|
.plugin(tauri_plugin_cors_fetch::init())
|
||||||
.plugin(tauri_plugin_sql::Builder::default().build())
|
|
||||||
.build(tauri::generate_context!())
|
.build(tauri::generate_context!())
|
||||||
.expect("error while building tauri application");
|
.expect("error while building tauri application");
|
||||||
|
|
||||||
|
@@ -1,150 +0,0 @@
|
|||||||
<script lang="ts">
|
|
||||||
import ezppLogo from '../../../../assets/logo.png';
|
|
||||||
import { osudirect } from '@/api/osudirect';
|
|
||||||
import { gameSounds } from '@/utils';
|
|
||||||
import { BeatmapDecoder } from 'osu-parsers';
|
|
||||||
import { onMount } from 'svelte';
|
|
||||||
|
|
||||||
type logoProps = {
|
|
||||||
beatmapId: number;
|
|
||||||
extended: boolean;
|
|
||||||
onclick: () => void;
|
|
||||||
};
|
|
||||||
|
|
||||||
let { beatmapId, extended, onclick }: logoProps = $props();
|
|
||||||
|
|
||||||
let hovered = $state(false);
|
|
||||||
let bpm = $state(150); // 1000 * 60 / bpm
|
|
||||||
let lastTimeout: number | undefined = undefined;
|
|
||||||
|
|
||||||
onMount(async () => {
|
|
||||||
gameSounds.preload();
|
|
||||||
|
|
||||||
const beatmapData = await osudirect.osu(beatmapId);
|
|
||||||
if (beatmapData) {
|
|
||||||
const decoder = new BeatmapDecoder();
|
|
||||||
const beatmap = decoder.decodeFromString(beatmapData);
|
|
||||||
console.log(beatmap);
|
|
||||||
|
|
||||||
const audio = new Audio(`https://osu.direct/api/media/audio/${beatmapId}`);
|
|
||||||
audio.volume = 0.3;
|
|
||||||
|
|
||||||
// Function to play the heartbeat sound
|
|
||||||
const playHeartbeat = () => {
|
|
||||||
gameSounds.play('menuHeartbeat', {
|
|
||||||
volume: hovered ? 1 : 0.3,
|
|
||||||
});
|
|
||||||
};
|
|
||||||
|
|
||||||
// Function to synchronize the heartbeat with the song
|
|
||||||
const syncHeartbeat = () => {
|
|
||||||
const currentTime = audio.currentTime * 1000 - 25; // Convert to milliseconds
|
|
||||||
const timingPoint = beatmap.controlPoints.timingPointAt(currentTime);
|
|
||||||
const timingPointTime = timingPoint.startTime;
|
|
||||||
console.log(currentTime, timingPointTime);
|
|
||||||
if (timingPoint && bpm !== timingPoint.bpm) {
|
|
||||||
bpm = timingPoint.bpm;
|
|
||||||
|
|
||||||
if (lastTimeout) window.clearTimeout(lastTimeout);
|
|
||||||
|
|
||||||
const interval = (1000 * 60) / bpm; // Interval in milliseconds
|
|
||||||
const nextBeat = currentTime % interval; // Invert: time since last beat
|
|
||||||
|
|
||||||
// Schedule the next heartbeat at the correct time
|
|
||||||
lastTimeout = window.setTimeout(() => {
|
|
||||||
playHeartbeat();
|
|
||||||
// Clear any previous interval
|
|
||||||
if (lastTimeout) {
|
|
||||||
window.clearInterval(lastTimeout);
|
|
||||||
lastTimeout = undefined;
|
|
||||||
}
|
|
||||||
if (!lastTimeout) lastTimeout = window.setInterval(playHeartbeat, interval);
|
|
||||||
}, nextBeat);
|
|
||||||
}
|
|
||||||
// Continue syncing
|
|
||||||
requestAnimationFrame(syncHeartbeat);
|
|
||||||
};
|
|
||||||
|
|
||||||
// Wait for audio to be ready before starting playback and syncing
|
|
||||||
audio.addEventListener('canplay', async () => {
|
|
||||||
audio.addEventListener('play', syncHeartbeat);
|
|
||||||
audio.addEventListener('ended', async () => await audio.play());
|
|
||||||
await audio.play();
|
|
||||||
syncHeartbeat();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<div
|
|
||||||
class="w-screen {extended
|
|
||||||
? hovered
|
|
||||||
? '-translate-y-1 scale-100'
|
|
||||||
: '-translate-y-1 scale-90'
|
|
||||||
: hovered
|
|
||||||
? 'translate-y-5 scale-150'
|
|
||||||
: 'translate-y-5 scale-125'} transition-transform select-none"
|
|
||||||
>
|
|
||||||
<!-- svelte-ignore a11y_click_events_have_key_events -->
|
|
||||||
<!-- svelte-ignore a11y_no_static_element_interactions -->
|
|
||||||
<div
|
|
||||||
class="logo-animation relative w-44 h-44 mx-auto cursor-pointer"
|
|
||||||
onmouseenter={() => (hovered = true)}
|
|
||||||
onmouseleave={() => (hovered = false)}
|
|
||||||
onclick={() => {
|
|
||||||
if (extended) {
|
|
||||||
gameSounds.play('menuBack');
|
|
||||||
} else {
|
|
||||||
gameSounds.play('menuHit');
|
|
||||||
}
|
|
||||||
onclick();
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<img
|
|
||||||
class="absolute pulse-logo"
|
|
||||||
style="animation-duration: {(1000 * 60) / bpm}ms;"
|
|
||||||
src={ezppLogo}
|
|
||||||
alt="logo-pulse"
|
|
||||||
/>
|
|
||||||
<img
|
|
||||||
class="absolute main-logo"
|
|
||||||
style="animation-duration: {(1000 * 60) / bpm}ms;"
|
|
||||||
src={ezppLogo}
|
|
||||||
alt="logo"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<style lang="scss">
|
|
||||||
.logo-animation {
|
|
||||||
.pulse-logo {
|
|
||||||
animation: 0.5s 0.2s infinite forwards beat-pulse;
|
|
||||||
}
|
|
||||||
.main-logo {
|
|
||||||
animation: 0.5s infinite forwards beat;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes beat {
|
|
||||||
0%,
|
|
||||||
100% {
|
|
||||||
scale: 1;
|
|
||||||
}
|
|
||||||
90% {
|
|
||||||
scale: 1.08;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@keyframes beat-pulse {
|
|
||||||
0%,
|
|
||||||
10% {
|
|
||||||
scale: 0.5;
|
|
||||||
opacity: 0.5;
|
|
||||||
filter: blur(0px);
|
|
||||||
}
|
|
||||||
100% {
|
|
||||||
scale: 1.4;
|
|
||||||
opacity: 0;
|
|
||||||
filter: blur(2px);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</style>
|
|
Reference in New Issue
Block a user