vue-circle-flags
Version:
A vue component with a collection of 400+ circular SVG country flags. Wrapper of HatScripts/circle-flags
1 lines • 5.57 kB
Source Map (JSON)
{"version":3,"file":"pm-DyFi4gyw.cjs","names":[],"sources":["../src/components/flags/pm.vue","../src/components/flags/pm.vue"],"sourcesContent":["<template>\r\n <svg\r\n xmlns=\"http://www.w3.org/2000/svg\"\r\n class=\"svg-circle-flags\"\r\n :viewBox=\"`${viewBoxOrigin} ${viewBoxOrigin} ${svgSize} ${svgSize}`\"\r\n >\r\n <mask id=\"d0417b1c-0e5a-4d93-894d-4f70edf8252b\">\r\n <circle cx=\"256\" cy=\"256\" r=\"256\" fill=\"#fff\" />\r\n </mask>\r\n <g mask=\"url(#d0417b1c-0e5a-4d93-894d-4f70edf8252b)\">\r\n <title v-if=\"props.flagName\">{{ props.flagName }}</title>\r\n <path fill=\"#338af3\" d=\"M160 0h352v512H160l-32-256z\" />\r\n <path fill=\"#eee\" d=\"m0 160 80-32 80 32v192l-80 32-80-32z\" />\r\n <rect width=\"160\" height=\"160\" fill=\"#d80027\" ry=\"0\" />\r\n <path fill=\"#6da544\" d=\"M160 21V0h-20L0 139v21h20z\" />\r\n <path fill=\"#6da544\" d=\"M0 21V0h20l140 139v21h-20z\" />\r\n <path fill=\"#eee\" d=\"M0 64h160v32H0z\" />\r\n <path fill=\"#eee\" d=\"M64 0h32v160H64z\" />\r\n <path fill=\"#d80027\" d=\"M0 512h160V352H0z\" />\r\n <path\r\n fill=\"#ffda44\"\r\n d=\"M340 146v158h-40c-24 0-24-32-24-32h-96v32h20l147 32 145-32v-24h-80s0 24-24 24h-32V146z\"\r\n />\r\n <path\r\n fill=\"#ffda44\"\r\n d=\"M356 138v32c-31-11-61 8-80-32 33 23 51-10 80 0zm-72 46s-24 24-16 72h-72s32-56 88-72zm16 104h95c-31-48 0-104 0-104h-95s-40 56 0 104zm101-24a96 96 0 0 1 4-64h63s-16 32-1 64zm-101 40h192s-8 0-16 24-16 48-56 48H276c-39 0-52-50-76-72z\"\r\n />\r\n <rect\r\n width=\"96\"\r\n height=\"32\"\r\n x=\"32\"\r\n y=\"384\"\r\n fill=\"#ffda44\"\r\n rx=\"16\"\r\n ry=\"16\"\r\n />\r\n <rect\r\n width=\"96\"\r\n height=\"32\"\r\n x=\"32\"\r\n y=\"448\"\r\n fill=\"#ffda44\"\r\n rx=\"16\"\r\n ry=\"16\"\r\n />\r\n </g>\r\n <g fill=\"none\">\r\n <circle\r\n cx=\"256\"\r\n cy=\"256\"\r\n :r=\"circleStroke\"\r\n fill=\"none\"\r\n :style=\"{ stroke: props.strokeColor, strokeWidth: props.strokeWidth }\"\r\n />\r\n </g>\r\n </svg>\r\n</template>\r\n<script setup lang=\"ts\">\r\n import { computed } from 'vue';\r\n\r\n const props = withDefaults(\r\n defineProps<{\r\n flagName: string | undefined;\r\n strokeColor?: string;\r\n strokeWidth?: number;\r\n }>(),\r\n {\r\n strokeColor: '#000',\r\n strokeWidth: 0\r\n }\r\n );\r\n\r\n const svgSize = computed(() => 512 + 2 * props.strokeWidth),\r\n viewBoxOrigin = computed(() => -props.strokeWidth),\r\n circleStroke = computed(() => 256 + props.strokeWidth / 2);\r\n</script>\r\n","<template>\r\n <svg\r\n xmlns=\"http://www.w3.org/2000/svg\"\r\n class=\"svg-circle-flags\"\r\n :viewBox=\"`${viewBoxOrigin} ${viewBoxOrigin} ${svgSize} ${svgSize}`\"\r\n >\r\n <mask id=\"d0417b1c-0e5a-4d93-894d-4f70edf8252b\">\r\n <circle cx=\"256\" cy=\"256\" r=\"256\" fill=\"#fff\" />\r\n </mask>\r\n <g mask=\"url(#d0417b1c-0e5a-4d93-894d-4f70edf8252b)\">\r\n <title v-if=\"props.flagName\">{{ props.flagName }}</title>\r\n <path fill=\"#338af3\" d=\"M160 0h352v512H160l-32-256z\" />\r\n <path fill=\"#eee\" d=\"m0 160 80-32 80 32v192l-80 32-80-32z\" />\r\n <rect width=\"160\" height=\"160\" fill=\"#d80027\" ry=\"0\" />\r\n <path fill=\"#6da544\" d=\"M160 21V0h-20L0 139v21h20z\" />\r\n <path fill=\"#6da544\" d=\"M0 21V0h20l140 139v21h-20z\" />\r\n <path fill=\"#eee\" d=\"M0 64h160v32H0z\" />\r\n <path fill=\"#eee\" d=\"M64 0h32v160H64z\" />\r\n <path fill=\"#d80027\" d=\"M0 512h160V352H0z\" />\r\n <path\r\n fill=\"#ffda44\"\r\n d=\"M340 146v158h-40c-24 0-24-32-24-32h-96v32h20l147 32 145-32v-24h-80s0 24-24 24h-32V146z\"\r\n />\r\n <path\r\n fill=\"#ffda44\"\r\n d=\"M356 138v32c-31-11-61 8-80-32 33 23 51-10 80 0zm-72 46s-24 24-16 72h-72s32-56 88-72zm16 104h95c-31-48 0-104 0-104h-95s-40 56 0 104zm101-24a96 96 0 0 1 4-64h63s-16 32-1 64zm-101 40h192s-8 0-16 24-16 48-56 48H276c-39 0-52-50-76-72z\"\r\n />\r\n <rect\r\n width=\"96\"\r\n height=\"32\"\r\n x=\"32\"\r\n y=\"384\"\r\n fill=\"#ffda44\"\r\n rx=\"16\"\r\n ry=\"16\"\r\n />\r\n <rect\r\n width=\"96\"\r\n height=\"32\"\r\n x=\"32\"\r\n y=\"448\"\r\n fill=\"#ffda44\"\r\n rx=\"16\"\r\n ry=\"16\"\r\n />\r\n </g>\r\n <g fill=\"none\">\r\n <circle\r\n cx=\"256\"\r\n cy=\"256\"\r\n :r=\"circleStroke\"\r\n fill=\"none\"\r\n :style=\"{ stroke: props.strokeColor, strokeWidth: props.strokeWidth }\"\r\n />\r\n </g>\r\n </svg>\r\n</template>\r\n<script setup lang=\"ts\">\r\n import { computed } from 'vue';\r\n\r\n const props = withDefaults(\r\n defineProps<{\r\n flagName: string | undefined;\r\n strokeColor?: string;\r\n strokeWidth?: number;\r\n }>(),\r\n {\r\n strokeColor: '#000',\r\n strokeWidth: 0\r\n }\r\n );\r\n\r\n const svgSize = computed(() => 512 + 2 * props.strokeWidth),\r\n viewBoxOrigin = computed(() => -props.strokeWidth),\r\n circleStroke = computed(() => 256 + props.strokeWidth / 2);\r\n</script>\r\n"],"mappings":"45CAwEQ,GAAA,EAAA,EAAA,cAAyB,IAAM,EAAI,EAAM,WAAW,EACxD,GAAA,EAAA,EAAA,cAA+B,CAAC,EAAM,WAAW,EACjD,GAAA,EAAA,EAAA,cAA8B,IAAM,EAAM,YAAc,CAAC"}