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.81 kB
JavaScript
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),a=["viewBox"],n=e.createElementVNode("mask",{id:"0eb4a0a0-0972-4bd1-b207-1234f36c2fa5"},[e.createElementVNode("circle",{cx:"256",cy:"256",r:"256",fill:"#fff"})],-1),r={mask:"url(#0eb4a0a0-0972-4bd1-b207-1234f36c2fa5)"},d={key:0},i=e.createElementVNode("path",{fill:"#eee",d:"M0 0h155.8l35 254.6-35 257.4H0z"},null,-1),m=e.createElementVNode("path",{fill:"#a2001d",d:"M155.8 0H512v345.1l-183 37.4-173.2-37.4z"},null,-1),u=e.createElementVNode("path",{fill:"#6da544",d:"M155.8 345.1H512V512H155.8z"},null,-1),_=e.createElementVNode("path",{fill:"#a2001d",d:"M50 .2 22.3 50l27.8 50.4L77.9 50zm55.8 0L78 50l27.7 50.4 28-50.4zM50 137.5l-27.7 49.6 27.8 50.5 27.7-50.5zm55.8 0L78 187.1l27.7 50.5 28-50.5zM50 274.7l-27.7 49.7 27.8 50.4 27.8-50.4zm55.8 0L78 324.4l27.7 50.4 28-50.4zM50 412l-27.7 49.6 27.8 50.5 27.7-50.5zm55.8 0L78 461.6l27.7 50.5 28-50.5z"},null,-1),f={fill:"none"},h=["r"],p=e.defineComponent({__name:"by",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),s=e.computed(()=>256+t.strokeWidth/2);return(k,g)=>(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}`},[n,e.createElementVNode("g",r,[t.flagName?(e.openBlock(),e.createElementBlock("title",d,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,a))}});exports.default=p;
//# sourceMappingURL=by-f2fc4f71.cjs.map