phosphor-solid
Version:
A clean and friendly icon family for Solid-js
55 lines (54 loc) • 5.37 kB
JSX
/* GENERATED FILE */
import { useContext } from "solid-js";
import { IconContext } from "../lib";
const renderPathFor = (weight, color) => {
switch (weight) {
case "bold":
return (<>
<circle cx="127.88745" cy="44" r="28" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/>
<path d="M153.91044,134.715,188.657,161.74012a12,12,0,1,0,16.97056-16.97057l-39.598-50.91169A19.93738,19.93738,0,0,0,151.88746,88h-48a19.93739,19.93739,0,0,0-14.14213,5.85786l-39.598,50.91169A12,12,0,1,0,67.1179,161.74012L101.86446,134.715,74.13088,222.3089a12,12,0,0,0,21.75139,10.14284l32.0052-50.37108h0l32.0052,50.37108A12,12,0,0,0,181.644,222.3089Z" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/>
</>);
case "duotone":
return (<>
<circle cx="127.88745" cy="44" r="28" opacity="0.2"/>
<path d="M153.91044,134.715,188.657,161.74012a12,12,0,1,0,16.97056-16.97057l-39.598-50.91169A19.93738,19.93738,0,0,0,151.88746,88h-48a19.93739,19.93739,0,0,0-14.14213,5.85786l-39.598,50.91169A12,12,0,1,0,67.1179,161.74012L101.86446,134.715,74.13088,222.3089a12,12,0,0,0,21.75139,10.14284l32.0052-50.37108h0l32.0052,50.37108A12,12,0,0,0,181.644,222.3089Z" opacity="0.2"/>
<circle cx="127.88745" cy="44" r="28" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
<path d="M153.91044,134.715,188.657,161.74012a12,12,0,1,0,16.97056-16.97057l-39.598-50.91169A19.93738,19.93738,0,0,0,151.88746,88h-48a19.93739,19.93739,0,0,0-14.14213,5.85786l-39.598,50.91169A12,12,0,1,0,67.1179,161.74012L101.86446,134.715,74.13088,222.3089a12,12,0,0,0,21.75139,10.14284l32.0052-50.37108h0l32.0052,50.37108A12,12,0,0,0,181.644,222.3089Z" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
</>);
case "fill":
return (<>
<g>
<circle cx="127.88745" cy="44" r="36"/>
<path d="M211.67456,139.51367,172.34448,88.94629a7.93269,7.93269,0,0,0-.65723-.74512A27.81868,27.81868,0,0,0,151.88745,80h-48a27.81872,27.81872,0,0,0-19.79981,8.20117,7.93259,7.93259,0,0,0-.65722.74512L44.09936,139.51416A20.00055,20.00055,0,0,0,72.37378,167.7876l14.09961-10.96729-19.832,62.64014a20.00009,20.00009,0,0,0,36.23731,16.897l25.00879-39.35937,25.00879,39.35937a20.00007,20.00007,0,0,0,36.2373-16.897l-19.832-62.64014,14.09961,10.96729a20.00035,20.00035,0,0,0,28.27344-28.27393Z"/>
</g>
</>);
case "light":
return (<>
<circle cx="127.88745" cy="44" r="28" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/>
<path d="M153.91044,134.715,188.657,161.74012a12,12,0,1,0,16.97056-16.97057l-39.598-50.91169A19.93738,19.93738,0,0,0,151.88746,88h-48a19.93739,19.93739,0,0,0-14.14213,5.85786l-39.598,50.91169A12,12,0,1,0,67.1179,161.74012L101.86446,134.715,74.13088,222.3089a12,12,0,0,0,21.75139,10.14284l32.0052-50.37108h0l32.0052,50.37108A12,12,0,0,0,181.644,222.3089Z" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/>
</>);
case "thin":
return (<>
<circle cx="127.88745" cy="44" r="28" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/>
<path d="M153.91044,134.715,188.657,161.74012a12,12,0,1,0,16.97056-16.97057l-39.598-50.91169A19.93738,19.93738,0,0,0,151.88746,88h-48a19.93739,19.93739,0,0,0-14.14213,5.85786l-39.598,50.91169A12,12,0,1,0,67.1179,161.74012L101.86446,134.715,74.13088,222.3089a12,12,0,0,0,21.75139,10.14284l32.0052-50.37108h0l32.0052,50.37108A12,12,0,0,0,181.644,222.3089Z" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/>
</>);
case "regular":
return (<>
<circle cx="127.88745" cy="44" r="28" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
<path d="M153.91044,134.715,188.657,161.74012a12,12,0,1,0,16.97056-16.97057l-39.598-50.91169A19.93738,19.93738,0,0,0,151.88746,88h-48a19.93739,19.93739,0,0,0-14.14213,5.85786l-39.598,50.91169A12,12,0,1,0,67.1179,161.74012L101.86446,134.715,74.13088,222.3089a12,12,0,0,0,21.75139,10.14284l32.0052-50.37108h0l32.0052,50.37108A12,12,0,0,0,181.644,222.3089Z" 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 Pedestrian = (props, ref) => {
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 Pedestrian;