UNPKG

vue-circle-flags

Version:

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

3 lines (2 loc) 1.82 kB
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=["viewBox"],s=e.createElementVNode("mask",{id:"b6d095bf-ab1b-4565-a36a-028e08428ebd"},[e.createElementVNode("circle",{cx:"256",cy:"256",r:"256",fill:"#fff"})],-1),d={mask:"url(#b6d095bf-ab1b-4565-a36a-028e08428ebd)"},i={key:0},n=e.createStaticVNode('<path fill="#d80027" d="M512 222.6V0H0l215.6 239.4z"></path><path fill="#6da544" d="M512 289.4V512H0l216.5-240z"></path><path fill="#333" d="m0 0 222.6 222.6H512v22.2l-10.9 11.8L512 267v22.4H222.6L0 512v-31.5l8-23-8-8.6V63l9.5-10.4-9.5-21z"></path><g fill="#ffda44"><path d="M512 244.8H213.2L0 31.7V63l192.8 193L0 449v31.5L213.2 267H512z"></path><path d="M62.2 310.6V289a38.8 38.8 0 0 0 38.8-38.8A27.5 27.5 0 0 0 73.5 223a18.7 18.7 0 0 0-18.7 18.7 12 12 0 0 0 12 12c3.7 0 6.8-3 6.8-6.8H95A28.2 28.2 0 0 1 66.8 275c-18.4 0-33.4-15-33.4-33.4 0-22.2 18-40.2 40-40.2a49 49 0 0 1 49 49c0 33.1-27 60.2-60.2 60.2z"></path></g>',4),h={fill:"none"},f=["r"],m=e.defineComponent({__name:"vu",props:{flagName:{},strokeColor:{default:"#000"},strokeWidth:{default:0}},setup(a){const t=a,o=e.computed(()=>512+2*t.strokeWidth),l=e.computed(()=>-t.strokeWidth),c=e.computed(()=>256+t.strokeWidth/2);return(p,u)=>(e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",class:"svg-circle-flags",viewBox:`${l.value} ${l.value} ${o.value} ${o.value}`},[s,e.createElementVNode("g",d,[t.flagName?(e.openBlock(),e.createElementBlock("title",i,e.toDisplayString(t.flagName),1)):e.createCommentVNode("",!0),n]),e.createElementVNode("g",h,[e.createElementVNode("circle",{cx:"256",cy:"256",r:c.value,fill:"none",style:e.normalizeStyle({stroke:t.strokeColor,strokeWidth:t.strokeWidth})},null,12,f)])],8,r))}});exports.default=m; //# sourceMappingURL=vu-a7ceadf4.cjs.map