import { Button } from "@mui/material"

function ItemTitle({ name, idx, activeBtn, setActiveBtn }) {

    return (
        <Button
            className={`
                !py-2 !px-4 !shadow-none !rounded-[8px]
                ${activeBtn === idx ? '!bg-[#F17732] !text-[#FAFAFA]' : '!bg-[#F5F5F5] !text-[#3B3B3B]'}
            `}
            onClick={() => setActiveBtn(idx)}
            variant="contained"
            color="secondary"
        >
            {name}
        </Button>
    )
}

export default ItemTitle