UNPKG

phosphor-solid

Version:

A clean and friendly icon family for Solid-js

85 lines (84 loc) 8.71 kB
/* GENERATED FILE */ import { useContext } from "solid-js"; import { IconContext } from "../lib"; const renderPathFor = (weight, color) => { switch (weight) { case "bold": return (<> <line x1="140" y1="48" x2="116" y2="48" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/> <line x1="116" y1="208" x2="140" y2="208" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/> <path d="M180,48h20a8.00011,8.00011,0,0,1,8,8.00012V76" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/> <line x1="208" y1="139.99963" x2="208" y2="115.99963" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/> <line x1="48" y1="115.99963" x2="48" y2="139.99963" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/> <path d="M76.00006,208.00006H56a8,8,0,0,1-8-7.99992v-20.0002" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/> <path d="M76,48H56a8.00011,8.00011,0,0,0-8,8.00012V76" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/> <line x1="208" y1="180" x2="208" y2="236" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/> <line x1="236" y1="208" x2="180" y2="208" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="24"/> </>); case "duotone": return (<> <line x1="140" y1="48" x2="116" y2="48" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <line x1="116" y1="208" x2="140" y2="208" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <path d="M180,48h20a8.00011,8.00011,0,0,1,8,8.00012V76" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <line x1="208" y1="139.99963" x2="208" y2="115.99963" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <line x1="48" y1="115.99963" x2="48" y2="139.99963" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <path d="M76.00006,208.00006H56a8,8,0,0,1-8-7.99992v-20.0002" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <path d="M76,48H56a8.00011,8.00011,0,0,0-8,8.00012V76" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <line x1="208" y1="180" x2="208" y2="236" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <line x1="236" y1="208" x2="180" y2="208" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> </>); case "fill": return (<> <path d="M148,48a7.99977,7.99977,0,0,1-8,8H116a8,8,0,0,1,0-16h24A7.99977,7.99977,0,0,1,148,48Zm-8,152H116a8,8,0,0,0,0,16h24a8,8,0,0,0,0-16ZM180,56h20V76a8,8,0,0,0,16,0V56a16.01833,16.01833,0,0,0-16-16H180a8,8,0,0,0,0,16Zm28,51.99951a7.99977,7.99977,0,0,0-8,8v24a8,8,0,0,0,16,0v-24A7.99977,7.99977,0,0,0,208,107.99951Zm-160,40a7.99977,7.99977,0,0,0,8-8v-24a8,8,0,1,0-16,0v24A7.99977,7.99977,0,0,0,48,147.99951ZM76,200H56V180a8,8,0,0,0-16,0v20a16.01833,16.01833,0,0,0,16,16H76a8,8,0,0,0,0-16ZM76,40H56A16.01833,16.01833,0,0,0,40,56V76a8,8,0,0,0,16,0V56H76a8,8,0,0,0,0-16ZM236,200H216V180a8,8,0,0,0-16,0v20H180a8,8,0,0,0,0,16h20v20a8,8,0,0,0,16,0V216h20a8,8,0,0,0,0-16Z"/> </>); case "light": return (<> <line x1="140" y1="48" x2="116" y2="48" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/> <line x1="116" y1="208" x2="140" y2="208" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/> <path d="M180,48h20a8.00011,8.00011,0,0,1,8,8.00012V76" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/> <line x1="208" y1="139.99963" x2="208" y2="115.99963" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/> <line x1="48" y1="115.99963" x2="48" y2="139.99963" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/> <path d="M76.00006,208.00006H56a8,8,0,0,1-8-7.99992v-20.0002" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/> <path d="M76,48H56a8.00011,8.00011,0,0,0-8,8.00012V76" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/> <line x1="208" y1="180" x2="208" y2="236" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/> <line x1="236" y1="208" x2="180" y2="208" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="12"/> </>); case "thin": return (<> <line x1="140" y1="48" x2="116" y2="48" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/> <line x1="116" y1="208" x2="140" y2="208" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/> <path d="M180,48h20a8.00011,8.00011,0,0,1,8,8.00012V76" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/> <line x1="208" y1="139.99963" x2="208" y2="115.99963" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/> <line x1="48" y1="115.99963" x2="48" y2="139.99963" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/> <path d="M76.00006,208.00006H56a8,8,0,0,1-8-7.99992v-20.0002" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/> <path d="M76,48H56a8.00011,8.00011,0,0,0-8,8.00012V76" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/> <line x1="208" y1="180" x2="208" y2="236" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/> <line x1="236" y1="208" x2="180" y2="208" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="8"/> </>); case "regular": return (<> <line x1="140" y1="48" x2="116" y2="48" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <line x1="116" y1="208" x2="140" y2="208" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <path d="M180,48h20a8.00011,8.00011,0,0,1,8,8.00012V76" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <line x1="208" y1="139.99963" x2="208" y2="115.99963" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <line x1="48" y1="115.99963" x2="48" y2="139.99963" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <path d="M76.00006,208.00006H56a8,8,0,0,1-8-7.99992v-20.0002" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <path d="M76,48H56a8.00011,8.00011,0,0,0-8,8.00012V76" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <line x1="208" y1="180" x2="208" y2="236" fill="none" stroke={color} stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/> <line x1="236" y1="208" x2="180" y2="208" 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 SelectionPlus = (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 SelectionPlus;