UNPKG

phosphor-solid

Version:

A clean and friendly icon family for Solid-js

291 lines (208 loc) 15.1 kB
import { useContext } from 'solid-js'; import { IconContext } from '../lib/index.esm.js'; import { template, setAttribute, spread, insert } from 'solid-js/web'; import { objectWithoutPropertiesLoose as _objectWithoutPropertiesLoose } from '../_virtual/_rollupPluginBabelHelpers.js'; const _tmpl$ = template(`<svg><path d="M175.98828,128.009a239.296,239.296,0,0,1-17.934,91.1974" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="24"></path></svg>`, 4, true), _tmpl$2 = template(`<svg><path d="M163.76327,96.006a48.00042,48.00042,0,0,0-83.775,32.003,143.35055,143.35055,0,0,1-17.98007,69.73221" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="24"></path></svg>`, 4, true), _tmpl$3 = template(`<svg><path d="M95.98767,37.47183A96.06707,96.06707,0,0,1,223.98828,128.009a288.94528,288.94528,0,0,1-7.13641,63.99948" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="24"></path></svg>`, 4, true), _tmpl$4 = template(`<svg><path d="M23.28359,168.00907a95.64559,95.64559,0,0,0,8.70469-40A95.76081,95.76081,0,0,1,63.988,56.45385" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="24"></path></svg>`, 4, true), _tmpl$5 = template(`<svg><path d="M110.567,208.009q-3.04226,6.62844-6.56532,12.97841" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="24"></path></svg>`, 4, true), _tmpl$6 = template(`<svg><path d="M127.97656,128.00842a192.34737,192.34737,0,0,1-6.0489,48.00023" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="24"></path></svg>`, 4, true), _tmpl$7 = template(`<svg><path d="M175.97656,128.009a239.296,239.296,0,0,1-17.934,91.1974" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$8 = template(`<svg><path d="M163.75156,96.006a48.00043,48.00043,0,0,0-83.775,32.003,143.35055,143.35055,0,0,1-17.98007,69.73221" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$9 = template(`<svg><path d="M95.976,37.47183A96.06707,96.06707,0,0,1,223.97656,128.009a288.94528,288.94528,0,0,1-7.13641,63.99948" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$10 = template(`<svg><path d="M23.27187,168.00907a95.64559,95.64559,0,0,0,8.70469-40A95.76081,95.76081,0,0,1,63.97631,56.45385" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$11 = template(`<svg><path d="M110.55525,208.009q-3.04226,6.62844-6.56531,12.97841" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$12 = template(`<svg><path d="M127.96484,128.00842a192.34737,192.34737,0,0,1-6.0489,48.00023" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$13 = template(`<svg><g><path d="M175.98242,120.0094a8.00039,8.00039,0,0,0-8,8,230.70455,230.70455,0,0,1-17.333,88.15527,8.00032,8.00032,0,1,0,14.79883,6.084,246.6394,246.6394,0,0,0,18.53418-94.23926A8.00039,8.00039,0,0,0,175.98242,120.0094Z"></path><path d="M127.98242,88.0094a40.06442,40.06442,0,0,1,29.81445,13.333,8.00032,8.00032,0,1,0,11.92188-10.67188A56.00093,56.00093,0,0,0,71.98242,128.0094,136.088,136.088,0,0,1,55.00586,193.861a7.99993,7.99993,0,1,0,13.99219,7.75977A152.12935,152.12935,0,0,0,87.98242,128.0094,40.04583,40.04583,0,0,1,127.98242,88.0094Z"></path><path d="M69.31738,62.41467A7.99966,7.99966,0,1,0,58.64746,50.4928a104.15766,104.15766,0,0,0-34.665,77.5166,87.28655,87.28655,0,0,1-7.97558,36.66308,7.9997,7.9997,0,1,0,14.541,6.67383,103.15936,103.15936,0,0,0,9.43457-43.33691A88.1429,88.1429,0,0,1,69.31738,62.41467Z"></path><path d="M127.98242,24.0094a103.7636,103.7636,0,0,0-34.667,5.91992,8.00025,8.00025,0,0,0,5.332,15.08594,88.06652,88.06652,0,0,1,117.335,82.99414,281.58357,281.58357,0,0,1-6.93847,62.22851,8.00013,8.00013,0,1,0,15.60351,3.541,297.64323,297.64323,0,0,0,7.335-65.76953A104.11791,104.11791,0,0,0,127.98242,24.0094Z"></path><path d="M113.89844,200.73889a8.00188,8.00188,0,0,0-10.60742,3.93359c-1.92676,4.19727-4.044,8.38086-6.291,12.43555a7.99945,7.99945,0,1,0,13.99219,7.75781c2.44336-4.40625,4.74511-8.95507,6.83984-13.51953A7.999,7.999,0,0,0,113.89844,200.73889Z"></path><path d="M127.9707,120.00842a8.00039,8.00039,0,0,0-8,8,184.6862,184.6862,0,0,1-5.79687,46.00586,8.00008,8.00008,0,1,0,15.49512,3.98828,200.70138,200.70138,0,0,0,6.30175-49.99414A8.00039,8.00039,0,0,0,127.9707,120.00842Z"></path></g></svg>`, 16, true), _tmpl$14 = template(`<svg><path d="M175.99414,128.009a239.296,239.296,0,0,1-17.934,91.1974" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="12"></path></svg>`, 4, true), _tmpl$15 = template(`<svg><path d="M163.76913,96.006a48.00042,48.00042,0,0,0-83.775,32.003,143.35045,143.35045,0,0,1-17.98008,69.73221" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="12"></path></svg>`, 4, true), _tmpl$16 = template(`<svg><path d="M95.99353,37.47183A96.06707,96.06707,0,0,1,223.99414,128.009a288.94528,288.94528,0,0,1-7.13641,63.99948" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="12"></path></svg>`, 4, true), _tmpl$17 = template(`<svg><path d="M23.28945,168.00907a95.64559,95.64559,0,0,0,8.70469-40A95.76081,95.76081,0,0,1,63.99389,56.45385" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="12"></path></svg>`, 4, true), _tmpl$18 = template(`<svg><path d="M110.57283,208.009q-3.04225,6.62844-6.56532,12.97841" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="12"></path></svg>`, 4, true), _tmpl$19 = template(`<svg><path d="M127.98242,128.00842a192.34737,192.34737,0,0,1-6.0489,48.00023" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="12"></path></svg>`, 4, true), _tmpl$20 = template(`<svg><path d="M176,128.009a239.296,239.296,0,0,1-17.934,91.1974" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="8"></path></svg>`, 4, true), _tmpl$21 = template(`<svg><path d="M163.775,96.006A48.00042,48.00042,0,0,0,80,128.009a143.35045,143.35045,0,0,1-17.98008,69.73221" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="8"></path></svg>`, 4, true), _tmpl$22 = template(`<svg><path d="M95.99938,37.47183A96.06708,96.06708,0,0,1,224,128.009a288.94528,288.94528,0,0,1-7.13641,63.99948" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="8"></path></svg>`, 4, true), _tmpl$23 = template(`<svg><path d="M23.29531,168.00907A95.64559,95.64559,0,0,0,32,128.009,95.76081,95.76081,0,0,1,63.99975,56.45385" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="8"></path></svg>`, 4, true), _tmpl$24 = template(`<svg><path d="M110.57869,208.009q-3.04225,6.62844-6.56532,12.97841" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="8"></path></svg>`, 4, true), _tmpl$25 = template(`<svg><path d="M127.98828,128.00842a192.34737,192.34737,0,0,1-6.0489,48.00023" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="8"></path></svg>`, 4, true), _tmpl$26 = template(`<svg><path d="M176.00586,128.009a239.296,239.296,0,0,1-17.934,91.1974" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$27 = template(`<svg><path d="M163.78085,96.006a48.00042,48.00042,0,0,0-83.775,32.003,143.35045,143.35045,0,0,1-17.98008,69.73221" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$28 = template(`<svg><path d="M96.00524,37.47183A96.06708,96.06708,0,0,1,224.00586,128.009a288.94587,288.94587,0,0,1-7.13641,63.99948" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$29 = template(`<svg><path d="M23.30117,168.00907a95.64559,95.64559,0,0,0,8.70469-40A95.76078,95.76078,0,0,1,64.00561,56.45385" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$30 = template(`<svg><path d="M110.58455,208.009q-3.04225,6.62844-6.56532,12.97841" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$31 = template(`<svg><path d="M127.99414,128.00842a192.34737,192.34737,0,0,1-6.0489,48.00023" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"></path></svg>`, 4, true), _tmpl$32 = template(`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256"><rect width="256" height="256" fill="none"></rect></svg>`, 4); var renderPathFor = function renderPathFor(weight, color) { switch (weight) { case "bold": return [function () { var _el$ = _tmpl$.cloneNode(true); setAttribute(_el$, "stroke", color); return _el$; }(), function () { var _el$2 = _tmpl$2.cloneNode(true); setAttribute(_el$2, "stroke", color); return _el$2; }(), function () { var _el$3 = _tmpl$3.cloneNode(true); setAttribute(_el$3, "stroke", color); return _el$3; }(), function () { var _el$4 = _tmpl$4.cloneNode(true); setAttribute(_el$4, "stroke", color); return _el$4; }(), function () { var _el$5 = _tmpl$5.cloneNode(true); setAttribute(_el$5, "stroke", color); return _el$5; }(), function () { var _el$6 = _tmpl$6.cloneNode(true); setAttribute(_el$6, "stroke", color); return _el$6; }()]; case "duotone": return [function () { var _el$7 = _tmpl$7.cloneNode(true); setAttribute(_el$7, "stroke", color); return _el$7; }(), function () { var _el$8 = _tmpl$8.cloneNode(true); setAttribute(_el$8, "stroke", color); return _el$8; }(), function () { var _el$9 = _tmpl$9.cloneNode(true); setAttribute(_el$9, "stroke", color); return _el$9; }(), function () { var _el$10 = _tmpl$10.cloneNode(true); setAttribute(_el$10, "stroke", color); return _el$10; }(), function () { var _el$11 = _tmpl$11.cloneNode(true); setAttribute(_el$11, "stroke", color); return _el$11; }(), function () { var _el$12 = _tmpl$12.cloneNode(true); setAttribute(_el$12, "stroke", color); return _el$12; }()]; case "fill": return _tmpl$13.cloneNode(true); case "light": return [function () { var _el$14 = _tmpl$14.cloneNode(true); setAttribute(_el$14, "stroke", color); return _el$14; }(), function () { var _el$15 = _tmpl$15.cloneNode(true); setAttribute(_el$15, "stroke", color); return _el$15; }(), function () { var _el$16 = _tmpl$16.cloneNode(true); setAttribute(_el$16, "stroke", color); return _el$16; }(), function () { var _el$17 = _tmpl$17.cloneNode(true); setAttribute(_el$17, "stroke", color); return _el$17; }(), function () { var _el$18 = _tmpl$18.cloneNode(true); setAttribute(_el$18, "stroke", color); return _el$18; }(), function () { var _el$19 = _tmpl$19.cloneNode(true); setAttribute(_el$19, "stroke", color); return _el$19; }()]; case "thin": return [function () { var _el$20 = _tmpl$20.cloneNode(true); setAttribute(_el$20, "stroke", color); return _el$20; }(), function () { var _el$21 = _tmpl$21.cloneNode(true); setAttribute(_el$21, "stroke", color); return _el$21; }(), function () { var _el$22 = _tmpl$22.cloneNode(true); setAttribute(_el$22, "stroke", color); return _el$22; }(), function () { var _el$23 = _tmpl$23.cloneNode(true); setAttribute(_el$23, "stroke", color); return _el$23; }(), function () { var _el$24 = _tmpl$24.cloneNode(true); setAttribute(_el$24, "stroke", color); return _el$24; }(), function () { var _el$25 = _tmpl$25.cloneNode(true); setAttribute(_el$25, "stroke", color); return _el$25; }()]; case "regular": return [function () { var _el$26 = _tmpl$26.cloneNode(true); setAttribute(_el$26, "stroke", color); return _el$26; }(), function () { var _el$27 = _tmpl$27.cloneNode(true); setAttribute(_el$27, "stroke", color); return _el$27; }(), function () { var _el$28 = _tmpl$28.cloneNode(true); setAttribute(_el$28, "stroke", color); return _el$28; }(), function () { var _el$29 = _tmpl$29.cloneNode(true); setAttribute(_el$29, "stroke", color); return _el$29; }(), function () { var _el$30 = _tmpl$30.cloneNode(true); setAttribute(_el$30, "stroke", color); return _el$30; }(), function () { var _el$31 = _tmpl$31.cloneNode(true); setAttribute(_el$31, "stroke", color); return _el$31; }()]; default: console.error('Unsupported icon weight. Choose from "thin", "light", "regular", "bold", "fill", or "duotone".'); return null; } }; var FingerprintSimple = function FingerprintSimple(props, ref) { var color = props.color, size = props.size, weight = props.weight, mirrored = props.mirrored, children = props.children, restProps = _objectWithoutPropertiesLoose(props, ["color", "size", "weight", "mirrored", "children"]); var _useContext = useContext(IconContext), contextColor = _useContext.color, contextSize = _useContext.size, contextWeight = _useContext.weight, contextMirrored = _useContext.mirrored, restContext = _objectWithoutPropertiesLoose(_useContext, ["color", "size", "weight", "mirrored"]); return function () { var _el$32 = _tmpl$32.cloneNode(true), _el$33 = _el$32.firstChild; var _ref$ = ref; typeof _ref$ === "function" ? _ref$(_el$32) : ref = _el$32; setAttribute(_el$32, "width", size != null ? size : contextSize); setAttribute(_el$32, "height", size != null ? size : contextSize); setAttribute(_el$32, "fill", color != null ? color : contextColor); setAttribute(_el$32, "transform", mirrored || contextMirrored ? "scale(-1, 1)" : undefined); spread(_el$32, restContext, true, true); spread(_el$32, restProps, true, true); insert(_el$32, children, _el$33); insert(_el$32, function () { return renderPathFor(weight != null ? weight : contextWeight, color != null ? color : contextColor); }, null); return _el$32; }(); }; export default FingerprintSimple; //# sourceMappingURL=FingerprintSimple.esm.js.map