UNPKG

vue-circle-flags

Version:

A vue component with a collection of 400+ circular SVG country flags. Wrapper of HatScripts/circle-flags

2 lines 2.19 kB
let e=require("vue");var t=[`viewBox`],n=(0,e.createElementVNode)(`mask`,{id:`922d2d78-76b8-4670-8027-ef9836a8cfa6`},[(0,e.createElementVNode)(`circle`,{cx:`256`,cy:`256`,r:`256`,fill:`#fff`})],-1),r={mask:`url(#922d2d78-76b8-4670-8027-ef9836a8cfa6)`},i={key:0},a=(0,e.createStaticVNode)(`<path fill="#ffda44" d="M0 0h512v512H0Z"></path><path fill="#d80027" d="m256 114-6 2-95 78c-4 3-4 9-1 13l102-33 102 33c3-4 3-10-1-13l-95-78-6-2z"></path><path fill="#eee" d="M278 231h-1zm-43 0z"></path><path fill="#6da544" d="m256 134-99 72 6 22 51-32 42 25 42-25 51 32 6-22z"></path><path fill="#333" d="m256 191-28 60-9-21-10 21-7-16-10 21-7-16-13 27 14 23h140l14-23-12-27-8 16-10-21-7 16-10-21-9 21zm-62 134zm124 0z"></path><path fill="#338af3" d="m183 290 11 32h124l11-32h-73z"></path><path fill="#eee" d="M256 129a4 4 0 0 0-2 1l-100 73a4 4 0 0 0-2 4l38 117a4 4 0 0 0 4 3h124a4 4 0 0 0 4-3l38-117a4 4 0 0 0-2-4l-100-73a4 4 0 0 0-2-1zm0 9 95 70-36 111H197l-36-111 95-70z"></path><rect width="9" height="142" x="252" y="170" fill="#ff9811" rx="4.5" ry="4.5"></rect><rect width="128" height="24" x="192" y="338" fill="#d80027" rx="12" ry="12"></rect><rect width="160" height="24" x="176" y="350" fill="#eee" rx="12" ry="12"></rect><path fill="#ffda44" d="m242 191 14-42 14 42-36-26h44z"></path>`,11),o={fill:`none`},s=[`r`],c=(0,e.defineComponent)({__name:`id-jt`,props:{flagName:{},strokeColor:{default:`#000`},strokeWidth:{default:0}},setup(c){let l=c,u=(0,e.computed)(()=>512+2*l.strokeWidth),d=(0,e.computed)(()=>-l.strokeWidth),f=(0,e.computed)(()=>256+l.strokeWidth/2);return(c,p)=>((0,e.openBlock)(),(0,e.createElementBlock)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,class:`svg-circle-flags`,viewBox:`${d.value} ${d.value} ${u.value} ${u.value}`},[n,(0,e.createElementVNode)(`g`,r,[l.flagName?((0,e.openBlock)(),(0,e.createElementBlock)(`title`,i,(0,e.toDisplayString)(l.flagName),1)):(0,e.createCommentVNode)(``,!0),a]),(0,e.createElementVNode)(`g`,o,[(0,e.createElementVNode)(`circle`,{cx:`256`,cy:`256`,r:f.value,fill:`none`,style:(0,e.normalizeStyle)({stroke:l.strokeColor,strokeWidth:l.strokeWidth})},null,12,s)])],8,t))}});exports.default=c; //# sourceMappingURL=id-jt-Cv10ccjA.cjs.map