import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
import { AviLinkRegular } from "../../../AviLink";
import { Col, Row } from "antd";
import { Link } from "react-router-dom";
import { VoteBarFull } from "../../../VoteBar";
import { getLocalTimeData } from "../../../../Utils/Helpers";
import { useCachedUser } from "../../../../../../hooks/useCached";
export const WhitelistCard = (props) => {
    const timeData = getLocalTimeData(props.proposal);
    const proposerObj = useCachedUser({ username: props.proposal.proposer });
    let proposalType = "new member";
    const newMember = useCachedUser({ username: props.proposal.user });
    return (_jsx(Link, { to: `/dao/${props.daoOwner}/proposal/${props.proposal.id}`, children: _jsxs(Col, { className: "wl-card-wrapper", children: [_jsxs(Row, { className: "u-margin-bottom-large", justify: "space-between", children: [_jsxs("p", { className: "header-5", children: ["#", props.proposal.id] }), _jsxs("p", { className: "", children: ["#", proposalType] })] }), _jsx(Row, { className: "u-margin-bottom-large", children: _jsx(AviLinkRegular, { showVerified: true, wrapperClass: "avi", username: newMember.username, userObj: newMember }) }), _jsx(VoteBarFull, { proposal: props.proposal, timeData: timeData }), _jsxs(Row, { className: "u-margin-top-medium", align: "middle", justify: "space-between", children: [_jsx("p", { className: "", children: "proposal by" }), _jsx(AviLinkRegular, { showVerified: true, wrapperClass: "avi", username: proposerObj.username, userObj: proposerObj })] })] }) }));
};
//# sourceMappingURL=WhitelistCard.js.map