import './balance-head.css'
import {useContext} from "react";
import {GlobalContext} from "../../context/GlobalContext.ts";

export default function BalanceHead() {
    const globalContext = useContext(GlobalContext);

    return (
        <div className="head-item balance-head">
            <span className="label">余额￥：</span>
            <span className="balance" onClick={() => {
                console.log('查看余额')
            }}>{globalContext.user.balance}</span>
        </div>
    )
}