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.78 kB
JavaScript
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),s=["viewBox"],n=e.createElementVNode("mask",{id:"9efe0c19-7ac3-43cc-8127-4b12347e78f0"},[e.createElementVNode("circle",{cx:"256",cy:"256",r:"256",fill:"#fff"})],-1),r={mask:"url(#9efe0c19-7ac3-43cc-8127-4b12347e78f0)"},i={key:0},d=e.createElementVNode("path",{fill:"#ffda44",d:"M0 0h256l51.7 254.7L256 512H0z"},null,-1),m=e.createElementVNode("path",{fill:"#eee",d:"M256 0h256v512H256z"},null,-1),f=e.createElementVNode("path",{fill:"#acabb1",d:"m354 222.8 48.1 63.6A33.4 33.4 0 1 0 420 273l-75-99.2-17.7 13.4-26.7 20.2 26.9 35.5 26.6-20.1zm69.3 73.1a11.1 11.1 0 1 1 13.4 17.8 11.1 11.1 0 0 1-13.4-17.8z"},null,-1),u=e.createElementVNode("path",{fill:"#ffda44",d:"m436.6 242.9 26.8-35.5-26.6-20.2-17.8-13.4-75 99.2a33.4 33.4 0 1 0 17.8 13.4l48-63.6 26.8 20zm-93.8 68.6a11.1 11.1 0 1 1-17.8-13.4 11.1 11.1 0 0 1 17.8 13.4z"},null,-1),_={fill:"none"},h=["r"],p=e.defineComponent({__name:"va",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),a=e.computed(()=>256+t.strokeWidth/2);return(k,v)=>(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}`},[n,e.createElementVNode("g",r,[t.flagName?(e.openBlock(),e.createElementBlock("title",i,e.toDisplayString(t.flagName),1)):e.createCommentVNode("",!0),d,m,f,u]),e.createElementVNode("g",_,[e.createElementVNode("circle",{cx:"256",cy:"256",r:a.value,fill:"none",style:e.normalizeStyle({stroke:t.strokeColor,strokeWidth:t.strokeWidth})},null,12,h)])],8,s))}});exports.default=p;
//# sourceMappingURL=va-eaa09f6b.cjs.map