|
@@ -1,13 +1,13 @@
|
|
|
"use client";
|
|
|
import { useWalletStore } from "@/stores/useWalletStore";
|
|
|
import { Mask } from "antd-mobile";
|
|
|
+import { motion } from "framer-motion";
|
|
|
import { useEffect, useState } from "react";
|
|
|
-
|
|
|
+import styles from "./style.module.scss";
|
|
|
const ActivityMask = () => {
|
|
|
const [visible, setVisible] = useState<boolean>(false);
|
|
|
|
|
|
const wallet = useWalletStore((state) => state.wallet);
|
|
|
- console.log(`🚀🚀🚀🚀🚀-> in ActivityMask.tsx on 10`, wallet);
|
|
|
useEffect(() => {
|
|
|
if (wallet?.notice?.lose_score > 0) {
|
|
|
setVisible(true);
|
|
@@ -22,31 +22,70 @@ const ActivityMask = () => {
|
|
|
{/*>*/}
|
|
|
{/* <span className={"iconfont icon-guanbi"}></span>*/}
|
|
|
{/*</div>*/}
|
|
|
- <div className={"absolute top-[20%] z-50"}>
|
|
|
- <div className={"h-[4.2rem] w-[100%]"}>
|
|
|
- <div
|
|
|
- className={"iconfont icon-guanbi absolute right-[30px]"}
|
|
|
- onClick={() => setVisible(false)}
|
|
|
- ></div>
|
|
|
- <img src={"/doings/activity.png"} className={"h-[4.1667rem] object-contain"} />
|
|
|
+ <div className={"absolute top-[18%] z-50 w-[100%]"} onClick={() => setVisible(false)}>
|
|
|
+ <div className={"relative flex h-[4.4653rem] w-[100%] justify-center"}>
|
|
|
+ <img
|
|
|
+ src={"/doings/activity.png"}
|
|
|
+ className={"h-[100%]" + " object-contain" + " absolute"}
|
|
|
+ />
|
|
|
+
|
|
|
+ <motion.div
|
|
|
+ className={"absolute -top-[13%] -z-10 flex h-[4.1667rem] items-center"}
|
|
|
+ animate={{
|
|
|
+ rotate: [0, 90, 180],
|
|
|
+ }}
|
|
|
+ transition={{
|
|
|
+ duration: 10,
|
|
|
+ ease: "linear",
|
|
|
+ repeat: Infinity,
|
|
|
+ }}
|
|
|
+ >
|
|
|
+ <img src="/img/light.png" alt="" />
|
|
|
+ </motion.div>
|
|
|
+
|
|
|
+ <motion.div
|
|
|
+ className={"absolute -top-[23%] -z-[9] flex h-[4.1667rem] items-center"}
|
|
|
+ animate={{
|
|
|
+ rotate: [0, 90, 180],
|
|
|
+ }}
|
|
|
+ transition={{
|
|
|
+ duration: 20,
|
|
|
+ ease: "linear",
|
|
|
+ repeat: Infinity,
|
|
|
+ }}
|
|
|
+ >
|
|
|
+ <img src="/img/light-1.png" alt="" />
|
|
|
+ </motion.div>
|
|
|
|
|
|
<div
|
|
|
className={
|
|
|
- "absolute -left-[8%] top-[28%] h-[2.0833rem] w-[56%]" +
|
|
|
- " translate-x-1/2" +
|
|
|
- " p-[0.0694rem] text-[#000]"
|
|
|
+ "absolute left-[50%] top-[28%] h-[2.8rem] w-[56%]" +
|
|
|
+ " -translate-x-1/2 p-[0.0694rem]"
|
|
|
}
|
|
|
>
|
|
|
- <div className={"text-center font-bold"}>Um presente</div>
|
|
|
- <div className={"mt-[0.0294rem] text-center"}>
|
|
|
- <span>Não tive sorte hoje,</span>
|
|
|
- <span>Continue com o bom trabalho</span>
|
|
|
+ <div className={"mt-[0.35rem] text-center font-[Arial]"}>
|
|
|
+ <div
|
|
|
+ className={styles.ActivityShadow}
|
|
|
+ // @ts-ignore
|
|
|
+ style={{ "--font-size": "0.2583rem" }}
|
|
|
+ data-text={"PRESENTE"}
|
|
|
+ >
|
|
|
+ PRESENTE
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div
|
|
|
+ className={`${styles.ActivityShadow} -mt-[0.1389rem]`}
|
|
|
+ // @ts-ignore
|
|
|
+ style={{ "--font-size": "0.4167rem" }}
|
|
|
+ data-text={`R$${wallet?.notice?.lose_score}`}
|
|
|
+ >
|
|
|
+ R${wallet?.notice?.lose_score}
|
|
|
+ </div>
|
|
|
</div>
|
|
|
- <div className={"mt-[0.4167rem] flex items-center justify-center"}>
|
|
|
- <span className={"mr-[0.0694rem]"}>presente: </span>
|
|
|
- <span className={"text-[0.2083rem] font-bold"}>
|
|
|
- {wallet?.notice?.lose_score}
|
|
|
- </span>
|
|
|
+
|
|
|
+ <div className={"absolute bottom-0 text-center text-[#663f23]"}>
|
|
|
+ <p>Não tive sorte hoje,</p>
|
|
|
+ <p>Continue com o bom trabalho</p>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|