vue-circle-flags
Version:
A vue component with a collection of 400+ circular SVG country flags. Wrapper of HatScripts/circle-flags
2 lines • 1.82 kB
JavaScript
let e=require("vue");var t=[`viewBox`],n=(0,e.createElementVNode)(`mask`,{id:`69617fc2-b639-4840-a151-b6d867bbe6f8`},[(0,e.createElementVNode)(`circle`,{cx:`256`,cy:`256`,r:`256`,fill:`#fff`})],-1),r={mask:`url(#69617fc2-b639-4840-a151-b6d867bbe6f8)`},i={key:0},a=(0,e.createElementVNode)(`path`,{fill:`#ffda44`,d:`M0 0h512v385l-256 64L0 385z`},null,-1),o=(0,e.createElementVNode)(`path`,{fill:`#a2001d`,d:`m375 97 23-24v24h23l-23 23 23 23h-23v23l-23-23-24 23v-23h-22l22-23-22-23h22V73zm-238 0 23-24v24h24l-24 23 24 23h-24v23l-23-23-23 23v-23H91l23-23-23-23h23V73zm119-50 23-23v23h23l-23 23 23 24h-23v23l-23-23-23 23V94h-23l23-24-23-23h23V24Z`,class:`fil1`},null,-1),s=(0,e.createElementVNode)(`path`,{fill:`#a2001d`,d:`m218 103-35 35v28h-28l-35 35 29 29h20v38l17 17 32-32 11 11v121H0v127h512V385H282V264l11-11 32 32 17-17v-38h21l29-29-35-35-29 1v-29l-34-35-29 29v23l26 26-35 35-35-35 26-26v-23z`,class:`fil1`},null,-1),c={fill:`none`},l=[`r`],u=(0,e.defineComponent)({__name:`ru-cu`,props:{flagName:{},strokeColor:{default:`#000`},strokeWidth:{default:0}},setup(u){let d=u,f=(0,e.computed)(()=>512+2*d.strokeWidth),p=(0,e.computed)(()=>-d.strokeWidth),m=(0,e.computed)(()=>256+d.strokeWidth/2);return(u,h)=>((0,e.openBlock)(),(0,e.createElementBlock)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,class:`svg-circle-flags`,viewBox:`${p.value} ${p.value} ${f.value} ${f.value}`},[n,(0,e.createElementVNode)(`g`,r,[d.flagName?((0,e.openBlock)(),(0,e.createElementBlock)(`title`,i,(0,e.toDisplayString)(d.flagName),1)):(0,e.createCommentVNode)(``,!0),a,o,s]),(0,e.createElementVNode)(`g`,c,[(0,e.createElementVNode)(`circle`,{cx:`256`,cy:`256`,r:m.value,fill:`none`,style:(0,e.normalizeStyle)({stroke:d.strokeColor,strokeWidth:d.strokeWidth})},null,12,l)])],8,t))}});exports.default=u;
//# sourceMappingURL=ru-cu-feTYT-cP.cjs.map