vue-circle-flags
Version:
A vue component with a collection of 400+ circular SVG country flags. Wrapper of HatScripts/circle-flags
2 lines • 1.71 kB
JavaScript
let e=require("vue");var t=[`viewBox`],n=(0,e.createElementVNode)(`mask`,{id:`fdb68cf1-e404-4fef-bf55-a32f01a2e1c3`},[(0,e.createElementVNode)(`circle`,{cx:`256`,cy:`256`,r:`256`,fill:`#fff`})],-1),r={mask:`url(#fdb68cf1-e404-4fef-bf55-a32f01a2e1c3)`},i={key:0},a=(0,e.createElementVNode)(`path`,{fill:`#0052b4`,d:`M0 0h144.7l108.4 41.2L367.3 0H512v512H367.3l-110.2-41.4L144.7 512H0z`},null,-1),o=(0,e.createElementVNode)(`path`,{fill:`#ffda44`,d:`M144.7 0h222.6v512H144.7z`},null,-1),s=(0,e.createElementVNode)(`path`,{fill:`#d80027`,d:`m328.4 278.3 16.7 22.2v-89l-16.7 22.2h-50v-50l22.2-16.7h-89l22.2 16.7v50h-50l-16.7-22.2v89l16.7-22.2h50v50L211.6 345h89l-22.2-16.7v-50z`},null,-1),c=(0,e.createElementVNode)(`path`,{fill:`#eee`,d:`M323 244.9h-56v-55.7h-22V245h-55.7v22H245v55.7h22V267h55.7z`},null,-1),l={fill:`none`},u=[`r`],d=(0,e.defineComponent)({__name:`pt-30`,props:{flagName:{},strokeColor:{default:`#000`},strokeWidth:{default:0}},setup(d){let f=d,p=(0,e.computed)(()=>512+2*f.strokeWidth),m=(0,e.computed)(()=>-f.strokeWidth),h=(0,e.computed)(()=>256+f.strokeWidth/2);return(d,g)=>((0,e.openBlock)(),(0,e.createElementBlock)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,class:`svg-circle-flags`,viewBox:`${m.value} ${m.value} ${p.value} ${p.value}`},[n,(0,e.createElementVNode)(`g`,r,[f.flagName?((0,e.openBlock)(),(0,e.createElementBlock)(`title`,i,(0,e.toDisplayString)(f.flagName),1)):(0,e.createCommentVNode)(``,!0),a,o,s,c]),(0,e.createElementVNode)(`g`,l,[(0,e.createElementVNode)(`circle`,{cx:`256`,cy:`256`,r:h.value,fill:`none`,style:(0,e.normalizeStyle)({stroke:f.strokeColor,strokeWidth:f.strokeWidth})},null,12,u)])],8,t))}});exports.default=d;
//# sourceMappingURL=pt-30-DzNFM9Ff.cjs.map