import { Popover, Space, TableColumnsType } from "antd";
import { Student } from "../../../../../types/Item";
import { FaEye } from "react-icons/fa";
import { FaEllipsisVertical } from "react-icons/fa6";
import { RiDeleteBin6Fill } from "react-icons/ri";

export const useColumns = () => {
  const columns: TableColumnsType<Student> = [
    {
      title: "رقم الورقة",
      dataIndex: "id",
      key: "id",
      align: "center",
    },
    {
      title: "عرض الورقة",
      dataIndex: "first_name",
      key: "first_name",
      align: "center",
    },
    {
      title: "الحل",
      dataIndex: "sex",
      key: "sex",
      align: "center",
    },

    {
      title: (
        <div className="Add_table_button">
          {" "}
          <button>إضافة ورقة</button>{" "}
        </div>
      ),
      key: "actions",
      align: "center",
      render: (text, record, index) => {
        const handleDelete = (record: any) => {
          // console.log('Delete action for record:', record);
        };
        const className = index % 2 === 0 ? "even-row" : "odd-row";

        return (
          <div className={className}>
            <RiDeleteBin6Fill size={22} style={{ color: "#C11313" }} />
          </div>
        );
      },
    },
  ];

  return columns;
};
