/* GENERATED FILE */
import  { useContext  } from "solid-js";
import { IconContext } from "../lib";

const renderPathFor = (weight: string, color: string) => {
  switch (weight) {
    case "bold":
      return (
        <>
          <circle cx="120" cy="48" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/>
  <circle cx="40" cy="120" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/>
  <circle cx="160" cy="208" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/>
  <circle cx="208" cy="72" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/>
  <line x1="184.84844" y1="65.68594" x2="143.15155" y2="54.31406" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/>
  <line x1="102.16099" y1="64.05511" x2="57.83902" y2="103.94489" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/>
  <line x1="59.35636" y1="134.19466" x2="140.64365" y2="193.80534" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/>
  <line x1="167.98938" y1="185.36342" x2="200.01089" y2="94.6358" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/>
        </>
      )
    case "duotone":
      return (
        <>
          <circle cx="120" cy="48" r="24" opacity="0.2"/>
  <circle cx="40" cy="120" r="24" opacity="0.2"/>
  <circle cx="160" cy="208" r="24" opacity="0.2"/>
  <circle cx="208" cy="72" r="24" opacity="0.2"/>
  <circle cx="120" cy="48" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <circle cx="40" cy="120" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <circle cx="160" cy="208" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <circle cx="208" cy="72" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <line x1="184.84844" y1="65.68594" x2="143.15155" y2="54.31406" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <line x1="102.16099" y1="64.05511" x2="57.83902" y2="103.94489" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <line x1="59.35636" y1="134.19466" x2="140.64365" y2="193.80534" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <line x1="167.98938" y1="185.36342" x2="200.01089" y2="94.6358" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
        </>
      )
    case "fill":
      return (
        <>
          <path d="M230.62744,49.37207a32.03673,32.03673,0,0,0-45.25488,0l-.00049.001a31.9114,31.9114,0,0,0-5.15478,6.75781l-28.24256-7.70215A31.978,31.978,0,0,0,97.37256,25.37207l-.00049.001a32.056,32.056,0,0,0-5.75415,37.4082L57.68018,93.3252a32.05378,32.05378,0,0,0-40.30762,4.04687l-.00049.001a32.00105,32.00105,0,0,0,42.88257,47.40039l70.03247,51.35791A32.00685,32.00685,0,1,0,177.855,181.44727l27.38355-77.58692c.91882.07861,1.84.124,2.76147.124a31.98463,31.98463,0,0,0,22.62744-54.61231Zm-67.866,126.7666a31.96846,31.96846,0,0,0-23.0166,7.0874l-70.032-51.35742a32.15784,32.15784,0,0,0-1.33081-26.6499L102.31982,74.6748a31.98394,31.98394,0,0,0,45.46289-10.80566l28.24256,7.70215a31.91307,31.91307,0,0,0,14.11951,26.98144Z"/>
        </>
      )
    case "light":
      return (
        <>
          <circle cx="120" cy="48" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/>
  <circle cx="40" cy="120" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/>
  <circle cx="160" cy="208" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/>
  <circle cx="208" cy="72" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/>
  <line x1="184.84844" y1="65.68594" x2="143.15155" y2="54.31406" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/>
  <line x1="102.16099" y1="64.05511" x2="57.83902" y2="103.94489" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/>
  <line x1="59.35636" y1="134.19466" x2="140.64365" y2="193.80534" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/>
  <line x1="167.98938" y1="185.36342" x2="200.01089" y2="94.6358" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/>
        </>
      )
    case "thin":
      return (
        <>
          <circle cx="120" cy="48" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/>
  <circle cx="40" cy="120" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/>
  <circle cx="160" cy="208" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/>
  <circle cx="208" cy="72" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/>
  <line x1="184.84844" y1="65.68594" x2="143.15155" y2="54.31406" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/>
  <line x1="102.16099" y1="64.05511" x2="57.83902" y2="103.94489" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/>
  <line x1="59.35636" y1="134.19466" x2="140.64365" y2="193.80534" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/>
  <line x1="167.98938" y1="185.36342" x2="200.01089" y2="94.6358" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/>
        </>
      )
    case "regular":
      return (
        <>
          <circle cx="120" cy="48" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <circle cx="40" cy="120" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <circle cx="160" cy="208" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <circle cx="208" cy="72" r="24" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <line x1="184.84844" y1="65.68594" x2="143.15155" y2="54.31406" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <line x1="102.16099" y1="64.05511" x2="57.83902" y2="103.94489" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <line x1="59.35636" y1="134.19466" x2="140.64365" y2="193.80534" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
  <line x1="167.98938" y1="185.36342" x2="200.01089" y2="94.6358" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
        </>
      )
    default:
      console.error(
        'Unsupported icon weight. Choose from "thin", "light", "regular", "bold", "fill", or "duotone".'
      );
      return null;
  }
};

const Polygon = (props: any, ref: any)  => {
  const { color, size, weight, mirrored, children, ...restProps } = props;
  const {
    color: contextColor,
    size: contextSize,
    weight: contextWeight,
    mirrored: contextMirrored,
    ...restContext
  } = useContext(IconContext);

  return (
    <svg
      ref={ref}
      xmlns="http://www.w3.org/2000/svg"
      width={size ?? contextSize}
      height={size ?? contextSize}
      fill={color ?? contextColor}
      viewBox="0 0 256 256"
      transform={mirrored || contextMirrored ? "scale(-1, 1)" : undefined}
      {...restContext}
      {...restProps}
    >
      {children}
      <rect width="256" height="256" fill="none"/>
      {renderPathFor(weight ?? contextWeight, color ?? contextColor)}
    </svg>
  );
};


export default Polygon;
