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.62 kB
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),n=["viewBox"],r=e.createElementVNode("mask",{id:"4d55ad06-9e28-4568-952e-7f37e3698f30"},[e.createElementVNode("circle",{cx:"256",cy:"256",r:"256",fill:"#fff"})],-1),d={mask:"url(#4d55ad06-9e28-4568-952e-7f37e3698f30)"},a={key:0},i=e.createElementVNode("path",{fill:"#eee",d:"M189.2 0H512v167l-347.5 24.6z"},null,-1),m=e.createElementVNode("path",{fill:"#6da544",d:"m163 320 349 25v167H189.2z"},null,-1),u=e.createElementVNode("path",{fill:"#d80027",d:"M0 0h189.2v167H512v178H189.2v167H0z"},null,-1),_=e.createElementVNode("path",{fill:"#eee",d:"M156.6 112.7 133 89l-15.7 15.8L101.5 89 78 112.7l15.8 15.7L78 144l23.6 23.6 15.8-15.7 15.7 15.7 23.6-23.6-15.7-15.7z"},null,-1),f={fill:"none"},h=["r"],v=e.defineComponent({__name:"om",props:{flagName:{},strokeColor:{default:"#000"},strokeWidth:{default:0}},setup(c){const t=c,o=e.computed(()=>512+2*t.strokeWidth),l=e.computed(()=>-t.strokeWidth),s=e.computed(()=>256+t.strokeWidth/2);return(p,k)=>(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}`},[r,e.createElementVNode("g",d,[t.flagName?(e.openBlock(),e.createElementBlock("title",a,e.toDisplayString(t.flagName),1)):e.createCommentVNode("",!0),i,m,u,_]),e.createElementVNode("g",f,[e.createElementVNode("circle",{cx:"256",cy:"256",r:s.value,fill:"none",style:e.normalizeStyle({stroke:t.strokeColor,strokeWidth:t.strokeWidth})},null,12,h)])],8,n))}});exports.default=v; //# sourceMappingURL=om-34f971df.cjs.map