import React from "react";
import { CaretLeft } from "@/assets/svgs";

import { NavLink } from "react-router-dom";

const BackButton = ({ text, link }) => {
  return (
    <div>
      <NavLink
        className="flex items-center gap-3 text-[#262626]"
        to={link ? link : -1}
      >
        <CaretLeft />
        {text && text}
      </NavLink>
    </div>
  );
};

export default BackButton;
