Working structure
This commit is contained in:
@@ -14,7 +14,7 @@ import {
|
||||
getVersions,
|
||||
toggleMod,
|
||||
installMod,
|
||||
} from "../services/LauncherService";
|
||||
} from "../services/SaturnApi";
|
||||
import { clsx, type ClassValue } from "clsx";
|
||||
import { twMerge } from "tailwind-merge";
|
||||
import { motion, AnimatePresence } from "framer-motion";
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
import React, { useEffect, useState } from "react";
|
||||
import { Play, Loader2 } from "lucide-react";
|
||||
import { launchGame } from "../services/LauncherService";
|
||||
// import { launchGame } from "../services/SaturnApi";
|
||||
import Bg from "@/assets/bg.png";
|
||||
import { listen } from "@tauri-apps/api/event";
|
||||
import { GameVersion } from "@/services/Types";
|
||||
import { launch } from "@/services/LauncherApi";
|
||||
|
||||
interface PlaySectionProps {
|
||||
version: GameVersion;
|
||||
@@ -43,7 +44,7 @@ const PlaySection: React.FC<PlaySectionProps> = ({ version }) => {
|
||||
<div className="absolute -inset-1 bg-linear-to-r from-blue-600 to-cyan-500 rounded-lg blur opacity-25 group-hover:opacity-50 transition duration-1000 group-hover:duration-200"></div>
|
||||
|
||||
<button
|
||||
onClick={() => launchGame(version.id)}
|
||||
onClick={() => launch()}
|
||||
disabled={isLaunching}
|
||||
className="relative btn-primary px-16 py-4 text-xl flex items-center gap-3 min-w-60 justify-center"
|
||||
>
|
||||
|
||||
@@ -7,7 +7,7 @@ import {
|
||||
Info,
|
||||
AlertTriangle,
|
||||
} from "lucide-react";
|
||||
import { getSettings, updateSettings } from "../services/LauncherService";
|
||||
import { getSettings, updateSettings } from "../services/SaturnApi";
|
||||
import { motion } from "framer-motion";
|
||||
import { LauncherSettings } from "@/services/Types";
|
||||
|
||||
@@ -118,8 +118,7 @@ const SettingsSection: React.FC = () => {
|
||||
<div className="relative w-full mt-2 h-6">
|
||||
{[1024, 4096, 8192, 12288, 16384].map((value) => {
|
||||
const percent =
|
||||
(((value - 1024) / (16384 - 1024)) * 100 - 50) * 0.97 +
|
||||
50;
|
||||
(((value - 1024) / (16384 - 1024)) * 100 - 50) * 0.97 + 50;
|
||||
|
||||
return (
|
||||
<span
|
||||
|
||||
Reference in New Issue
Block a user