UNPKG

@fe6/icon-img

Version:

Water Icon 的纯 HTML 图标

20 lines (19 loc) 4.97 kB
var IconsBytedMosaic=function(d){"use strict";var g={size:"1em",spin:!1,strokeWidth:4,strokeLinecap:"round",strokeLinejoin:"round",rtl:!1,theme:"outline",colors:{outline:{outStrokeColor:"#333",outFillColor:"transparent"},filled:{outStrokeColor:"#333",outFillColor:"#fff"},twoTone:{outStrokeColor:"#333",outFillColor:"#2f88ff"},multiColor:{outStrokeColor:"#333",outFillColor:"#2f88ff",innerStrokeColor:"#fff",innerFillColor:"#43ccf8"}},prefix:"cube"},k=function(){return"icon-"+((1+Math.random())*4294967296|0).toString(16).substring(1)},m=function(e,r,l){var o=r?.colors||[],t=[],i=r?.theme||l.theme;switch(i){case"outline":t.push(typeof o[0]=="string"?o[0]:l.colors.outline.outStrokeColor),t.push(typeof o[1]=="string"?o[1]:l.colors.outline.outFillColor),t.push(typeof o[0]=="string"?o[0]:l.colors.outline.outStrokeColor),t.push(typeof o[1]=="string"?o[1]:l.colors.outline.outFillColor);break;case"filled":t.push(typeof o[0]=="string"?o[0]:l.colors.filled.outStrokeColor),t.push(typeof o[0]=="string"?o[0]:l.colors.filled.outStrokeColor),t.push(typeof o[1]=="string"?o[1]:l.colors.filled.outFillColor),t.push(typeof o[1]=="string"?o[1]:l.colors.filled.outFillColor);break;case"twoTone":t.push(typeof o[0]=="string"?o[0]:l.colors.twoTone.outStrokeColor),t.push(typeof o[1]=="string"?o[1]:l.colors.twoTone.outFillColor),t.push(typeof o[0]=="string"?o[0]:l.colors.twoTone.outStrokeColor),t.push(typeof o[1]=="string"?o[1]:l.colors.twoTone.outFillColor);break;case"multiColor":t.push(typeof o[0]=="string"?o[0]:l.colors.multiColor.outStrokeColor),t.push(typeof o[1]=="string"?o[1]:l.colors.multiColor.outFillColor),t.push(typeof o[2]=="string"?o[2]:l.colors.multiColor.innerStrokeColor),t.push(typeof o[3]=="string"?o[3]:l.colors.multiColor.innerFillColor);break}return{size:r?.size||l.size,strokeWidth:r?.strokeWidth||l.strokeWidth,strokeLinecap:r?.strokeLinecap||l.strokeLinecap,strokeLinejoin:r?.strokeLinejoin||l.strokeLinejoin,colors:t,svg:r?.svg||"",id:e}},H="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",V="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_",y=function(e,r){for(var l="",o=0,t=e.length,i,s,a,n=r?V:H;o<t;){if(i=e.charCodeAt(o++)&255,o===t){l+=n.charAt(i>>2),l+=n.charAt((i&3)<<4),l+="==";break}if(s=e.charCodeAt(o++),o===t){l+=n.charAt(i>>2),l+=n.charAt((i&3)<<4|(s&240)>>4),l+=n.charAt((s&15)<<2),l+="=";break}a=e.charCodeAt(o++),l+=n.charAt(i>>2),l+=n.charAt((i&3)<<4|(s&240)>>4),l+=n.charAt((s&15)<<2|(a&192)>>6),l+=n.charAt(a&63)}return l},S=function(e){var r="",l,o,t=e.length;for(l=0;l<t;l++)o=e.charCodeAt(l),o>=1&&o<=127?r+=e.charAt(l):o>2047?(r+=String.fromCharCode(224|o>>12&15),r+=String.fromCharCode(128|o>>6&63),r+=String.fromCharCode(128|o>>0&63)):(r+=String.fromCharCode(192|o>>6&31),r+=String.fromCharCode(128|o>>0&63));return r},M=g,b=function(){return M},w=function(e,r,l){return function(o){var t=b(),i=["".concat(t.prefix,"-icon")];i.push("".concat(t.prefix,"-icon-").concat(e)),r&&t.rtl&&i.push("".concat(t.prefix,"-icon-rtl")),o!=null&&o.spin&&i.push("".concat(t.prefix,"-icon-spin"));var s=m(k(),o,t),a=l(s),n=y(S(a)),u="data:image/svg+xml;base64,".concat(n);return o!=null&&o.base64?u:'<span class="'.concat(i.join(" "),`"> <img class="`).concat(t.prefix,'-icon-img" src="').concat(u,`" /> </span>`)}},p=function(e){var r,l,o,t,i,s,a,n,u,v,h,f,C;return`<?xml version="1.0" encoding="UTF-8"?> <svg width="`.concat(e.size,'" height="').concat(e.size,`" viewBox="0 0 48 48" fill="none" xmlns="http://www.w3.org/2000/svg"> <rect width="48" height="48" fill="white" fill-opacity="0.01"/> <path d="M44 36H36V44H44V36Z" fill="`).concat((r=e.colors)===null||r===void 0?void 0:r[0],`"/> <path d="M28 36H20V44H28V36Z" fill="`).concat((l=e.colors)===null||l===void 0?void 0:l[0],`"/> <path d="M12 36H4V44H12V36Z" fill="`).concat((o=e.colors)===null||o===void 0?void 0:o[0],`"/> <path d="M44 20H36V28H44V20Z" fill="`).concat((t=e.colors)===null||t===void 0?void 0:t[0],`"/> <path d="M28 20H20V28H28V20Z" fill="`).concat((i=e.colors)===null||i===void 0?void 0:i[0],`"/> <path d="M12 20H4V28H12V20Z" fill="`).concat((s=e.colors)===null||s===void 0?void 0:s[0],`"/> <path d="M44 4H36V12H44V4Z" fill="`).concat((a=e.colors)===null||a===void 0?void 0:a[0],`"/> <path d="M28 4H20V12H28V4Z" fill="`).concat((n=e.colors)===null||n===void 0?void 0:n[0],`"/> <path d="M12 4H4V12H12V4Z" fill="`).concat((u=e.colors)===null||u===void 0?void 0:u[0],`"/> <path d="M20 12H12V20H20V12Z" fill="`).concat((v=e.colors)===null||v===void 0?void 0:v[0],`"/> <path d="M20 28H12V36H20V28Z" fill="`).concat((h=e.colors)===null||h===void 0?void 0:h[0],`"/> <path d="M36 12H28V20H36V12Z" fill="`).concat((f=e.colors)===null||f===void 0?void 0:f[0],`"/> <path d="M36 28H28V36H36V28Z" fill="`).concat((C=e.colors)===null||C===void 0?void 0:C[0],`"/> </svg>`)},F=w("byted-mosaic",!1,p);return d.default=F,d.getIconBytedMosaicSvgHtml=p,Object.defineProperty(d,"__esModule",{value:!0}),d}({});