import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
import Button from "../../button";
import { InfoIcon } from "../../icon";
export const LeverageView = ({ maxLeverage, predFundingRate, countdown, onShowLeverageInfo })=>{
    return /*#__PURE__*/ _jsxs("div", {
        id: "orderly-leverage",
        className: "orderly-flex orderly-justify-between orderly-items-center orderly-text-3xs",
        children: [
            /*#__PURE__*/ _jsxs("div", {
                className: "orderly-text-4xs orderly-text-base-contrast-36 orderly-flex orderly-items-center",
                children: [
                    /*#__PURE__*/ _jsxs("button", {
                        className: "orderly-flex orderly-items-center orderly-gap-1",
                        onClick: ()=>onShowLeverageInfo?.(),
                        children: [
                            /*#__PURE__*/ _jsx(InfoIcon, {
                                size: 14
                            }),
                            /*#__PURE__*/ _jsx("span", {
                                children: "Max leverage"
                            })
                        ]
                    }),
                    /*#__PURE__*/ _jsx(Button, {
                        variant: "text",
                        size: "small",
                        className: "orderly-px-1 orderly-min-w-[24px] orderly-text-4xs orderly-text-link",
                        children: `${maxLeverage}x`
                    })
                ]
            }),
            /*#__PURE__*/ _jsxs("div", {
                className: "orderly-flex orderly-flex-col orderly-items-end orderly-text-4xs orderly-text-base-contrast-36",
                children: [
                    /*#__PURE__*/ _jsx("div", {
                        children: "Pred. funding rate"
                    }),
                    /*#__PURE__*/ _jsxs("div", {
                        className: "orderly-flex orderly-gap-1",
                        children: [
                            /*#__PURE__*/ _jsx("span", {
                                className: "orderly-text-warning",
                                children: `${predFundingRate}%`
                            }),
                            /*#__PURE__*/ _jsx("span", {
                                children: "in"
                            }),
                            /*#__PURE__*/ _jsx("span", {
                                children: countdown
                            })
                        ]
                    })
                ]
            })
        ]
    });
};

//# sourceMappingURL=leverage.js.map