import { Wallet } from "@/api/user"; import { percentage } from "@/utils/methods"; import { ProgressBar } from "antd-mobile"; import { useTranslations } from "next-intl"; const Progress = (props: { percent: number }) => { const { percent } = props; return (
{percent.toFixed(2)}%
); }; export const WalletContent = (props: { percentage: number; type: string; difference: number; current: number; }) => { const { percentage, type, difference, current } = props; const t = useTranslations("ProfilePage"); return (
{type} R$ {current}
{t("modalBottomTips")} {difference.toFixed(2)}
); }; // 现金 export const BalanceContent = (props: { wallet: Wallet }) => { const { wallet } = props; const t = useTranslations("ProfilePage"); return ( <> ); }; export const BonusContent = (props: { wallet: Wallet; handleAcquire?: any }) => { const { wallet, handleAcquire } = props; const t = useTranslations("ProfilePage"); return (

{t("bonusArticle")}

  • {t("bonusDesc1")}
  • {t("bonusDesc2")}
  • {t("bonusDesc3")}
{handleAcquire && ( handleAcquire(2, wallet.is_point_transfer)} > {t("carteira")} )}
); }; export const FreeContent = (props: { wallet: Wallet; handleAcquire?: any }) => { const { wallet, handleAcquire } = props; const t = useTranslations("ProfilePage"); return (

{t("freeArticle")}

  • {t("freeDesc1")}
  • {t("freeDesc2")}
  • {t("freeDesc3")}{wallet?.free_transfer_ratio}:1
  • {t("freeDesc4", {n: wallet.free_transfer_max ?? 0})}
{handleAcquire && ( = (wallet?.free_transfer_min || 0)) ? "active" : ""}`} onClick={() => handleAcquire(3, wallet.is_free_transfer)} > {t("carteira")} )}

Valor minimo de transferência de {wallet?.free_transfer_min}

); }; export const ReplayContent = (props: { wallet: Wallet; handleAcquire?: any }) => { const { wallet, handleAcquire } = props; const t = useTranslations("ProfilePage"); return (

{t("replayArticle")}

  • {t("replayDesc1")}
  • {t("replayDesc2")}
  • {t("replayDesc3")} {wallet?.lose_transfer_ratio}:1
  • {t("replayDesc4", { n: wallet.lose_transfer_max ?? 0 })}
{handleAcquire && ( = (wallet?.lose_transfer_min || 0) ? "active" : ""}`} onClick={() => handleAcquire(4, wallet.is_lose_transfer)} > {t("carteira")} )}

Valor minimo de transferência de {wallet?.lose_transfer_min}

); }; // const WalletDescribeModal = () => { // const [tipsStatus, setTipsStatus] = useState("Bonus"); // const tipsRef = useRef(null); // const wallet: any = {}; // const t = useTranslations("ProfilePage"); // // return ( // // // {t("modalTitle")} // // } // > // {/*现金*/} // {tipsStatus === WalletEnum.Balance ? : null} // {/* 彩金*/} // {tipsStatus === WalletEnum.Bonus ? : null} // {/* 免费币 */} // {tipsStatus === WalletEnum.Free ? : null} // {/* 重玩币 */} // {tipsStatus === WalletEnum.Replay ? : null} // // ); // }; // export default WalletDescribeModal;