feat:init
This commit is contained in:
1 parent
53d0eeac6b
commit
ae0c050010
494 files changed
+17701
-2318
No files matched your search
+15
-20
@@ -1,29 +1,24 @@
|
||||
import { getBackgroundImage, getStaticImage } from "@/lib/utils";
|
||||
import { Image } from "@/components";
|
||||
import { useNavigate } from "react-router-dom";
|
||||
import { BackgroundImage, Image } from "@/components";
|
||||
import { getStaticImage } from "@/utils";
|
||||
|
||||
export default function Home() {
|
||||
const Home = () => {
|
||||
const navigate = useNavigate();
|
||||
|
||||
const handleStartExperiment = () => {
|
||||
console.log("点击开启实验");
|
||||
navigate("/menu");
|
||||
};
|
||||
|
||||
return (
|
||||
<BackgroundImage
|
||||
src={getStaticImage("home/进入页.png")}
|
||||
className="h-full w-full relative"
|
||||
backgroundSize="cover"
|
||||
backgroundPosition="center"
|
||||
<div
|
||||
className="w-full h-full bg-cover bg-center bg-no-repeat"
|
||||
style={{ backgroundImage: getBackgroundImage("home/首页底图") }}
|
||||
>
|
||||
<Image
|
||||
src={getStaticImage("components/按钮-进入.png")}
|
||||
alt="进入"
|
||||
onClick={() => {
|
||||
navigate("/menu");
|
||||
}}
|
||||
className="absolute bottom-38 left-1/2 -translate-1/2"
|
||||
button
|
||||
className="absolute bottom-10 left-1/2 transform -translate-x-1/2 -translate-y-1/2"
|
||||
onClick={handleStartExperiment}
|
||||
src={getStaticImage("home/首页-进入")}
|
||||
/>
|
||||
</BackgroundImage>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
export default Home;
|
||||
Reference in new issue
Block a user