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.68 kB
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),s=["viewBox"],r=e.createElementVNode("mask",{id:"f7c322d8-56af-4b07-a988-a86c99255022"},[e.createElementVNode("circle",{cx:"256",cy:"256",r:"256",fill:"#fff"})],-1),a={mask:"url(#f7c322d8-56af-4b07-a988-a86c99255022)"},i={key:0},d=e.createElementVNode("path",{fill:"#eee",d:"M0 0h171l85 32 85-32h171v171l-32 85 32 85v171H341l-85-32-85 32H0V341l32-85-32-85Z"},null,-1),m=e.createElementVNode("path",{fill:"#d80027",d:"M171 0h170v512H171z"},null,-1),h=e.createElementVNode("path",{fill:"#0052b4",d:"M512 171v170H0V171z"},null,-1),u=e.createElementVNode("path",{fill:"#eee",d:"m236 247 52-37h-64l52 37-20-61zm-45 79 52-37h-64l52 37-20-61zm90 0 52-37h-64l52 37-20-61zm74-47 52-37h-64l52 37-20-61zm-238 0 52-37h-64l52 37-20-61z"},null,-1),_={fill:"none"},f=["r"],p=e.defineComponent({__name:"an",props:{flagName:{},strokeColor:{default:"#000"},strokeWidth:{default:0}},setup(c){const t=c,l=e.computed(()=>512+2*t.strokeWidth),o=e.computed(()=>-t.strokeWidth),n=e.computed(()=>256+t.strokeWidth/2);return(v,k)=>(e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",class:"svg-circle-flags",viewBox:`${o.value} ${o.value} ${l.value} ${l.value}`},[r,e.createElementVNode("g",a,[t.flagName?(e.openBlock(),e.createElementBlock("title",i,e.toDisplayString(t.flagName),1)):e.createCommentVNode("",!0),d,m,h,u]),e.createElementVNode("g",_,[e.createElementVNode("circle",{cx:"256",cy:"256",r:n.value,fill:"none",style:e.normalizeStyle({stroke:t.strokeColor,strokeWidth:t.strokeWidth})},null,12,f)])],8,s))}});exports.default=p; //# sourceMappingURL=an-404fefc7.cjs.map