@gf-ui/components
Version:
48 lines (43 loc) • 2.48 kB
JavaScript
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
import { I as Icons } from './index2.js';
const svgData = {"name":"svg","type":"element","value":"","attributes":{"class":"icon","viewBox":"0 0 1024 1024","version":"1.1","xmlns":"http://www.w3.org/2000/svg"},"children":[{"name":"path","type":"element","value":"","attributes":{"fill":"currentColor","d":"M491.925333 532.074667V853.333333H170.666667V532.074667h321.258666zM597.333333 789.333333v64h-64v-64h64z m256-85.333333v149.333333h-128v-64h64v-85.333333h64z m-425.408-107.925333H234.666667V789.333333h193.258666v-193.258666zM661.333333 597.333333v128h64v64h-128v-192h64z m-277.333333 42.666667v106.666667h-106.666667v-106.666667h106.666667z m405.333333 0v64h-64v-64h64z m64-106.666667v106.666667h-64v-42.666667h-64v-64h128z m-256 0v64h-64v-64h64zM491.925333 170.666667v321.258666H170.666667V170.666667h321.258666zM853.333333 170.666667v321.258666H532.074667V170.666667H853.333333z m-425.408 64H234.666667v193.258666h193.258666V234.666667zM789.333333 234.666667h-193.258666v193.258666H789.333333V234.666667z m-405.333333 42.666666v106.666667h-106.666667v-106.666667h106.666667z m362.666667 0v106.666667h-106.666667v-106.666667h106.666667z"},"children":[]}],"_name":"qRcode","_isColor":false};
const GfIconqRcode = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
constructor() {
super();
this.__registerHost();
this.size = 30;
this.styles = {};
this.color = "#606266";
this.rotate = 0;
this.spin = false;
this.opacity = 1;
}
render() {
const { size, styles, color, rotate, spin, opacity } = this;
const hostStyles = { width: size + 'px', height: size + 'px' };
return (h(Host, { style: hostStyles }, h(Icons, Object.assign({}, { svgData, size, styles, color, rotate, spin, opacity }))));
}
}, [0, "gf-icon-q-rcode", {
"size": [8],
"styles": [16],
"color": [1],
"rotate": [2],
"spin": [4],
"opacity": [8]
}]);
function defineCustomElement$1() {
if (typeof customElements === "undefined") {
return;
}
const components = ["gf-icon-q-rcode"];
components.forEach(tagName => { switch (tagName) {
case "gf-icon-q-rcode":
if (!customElements.get(tagName)) {
customElements.define(tagName, GfIconqRcode);
}
break;
} });
}
const GfIconQRcode = GfIconqRcode;
const defineCustomElement = defineCustomElement$1;
export { GfIconQRcode, defineCustomElement };