vue-circle-flags
Version:
A vue component with a collection of 400+ circular SVG country flags. Wrapper of HatScripts/circle-flags
1 lines • 5.54 kB
Source Map (JSON)
{"version":3,"file":"dm-Bv_cnBCd.cjs","names":[],"sources":["../src/components/flags/dm.vue","../src/components/flags/dm.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=\"4f42b6f4-1a06-412c-ab42-9721248ae0e3\">\r\n <circle cx=\"256\" cy=\"256\" r=\"256\" fill=\"#fff\" />\r\n </mask>\r\n <g mask=\"url(#4f42b6f4-1a06-412c-ab42-9721248ae0e3)\">\r\n <title v-if=\"props.flagName\">{{ props.flagName }}</title>\r\n <path\r\n fill=\"#496e2d\"\r\n d=\"M0 0h208l48 32 48-32h208v208l-32 48 32 48v208H304l-48-32-48 32H0V304l32-48-32-48Z\"\r\n />\r\n <path fill=\"#333\" d=\"M512 240v32l-256 32L0 272v-32l256-32z\" />\r\n <path fill=\"#ffda44\" d=\"M512 208v32H0v-32z\" />\r\n <path fill=\"#333\" d=\"M240 0h32l32 256-32 256h-32l-32-256Z\" />\r\n <path fill=\"#ffda44\" d=\"M208 0h32v512h-32z\" />\r\n <path fill=\"#eee\" d=\"M272 0h32v512h-32z\" />\r\n <path fill=\"#eee\" d=\"M512 272v32H0v-32z\" />\r\n <circle cx=\"256\" cy=\"256\" r=\"122.4\" fill=\"#d80027\" />\r\n <path\r\n fill=\"#496e2d\"\r\n d=\"M284 270c-9-19-21-37-21-37v-13a14 14 0 0 0-27-2 11 11 0 0 0-4 21 16 16 0 0 1 9-9 14 14 0 0 0 2 2h2s-7 19-7 29c0 27 19 36 19 36l-10 9h19v-18l9 9s17-11 9-27zm-28-114 4 13h14l-11 8 4 12-11-8-11 8 4-12-11-8h14Zm-59 19 11 8 11-8-4 13 11 8h-14l-4 12-4-12h-14l11-8zm-36 50h13l4-13 4 13h14l-11 8 4 13-11-8-11 8 5-13zm0 62 11-8-5-13 11 8 11-8-4 13 11 8h-14l-4 13-4-13Zm36 50 4-13-11-8h14l4-12 4 12h13l-10 8 4 13-11-8zm59 19-4-13h-14l11-8-4-12 11 8 11-8-4 12 11 9h-14Zm59-19-11-8-11 8 4-13-10-8h13l4-12 4 12h14l-11 8zm36-50h-13l-4 13-4-13h-14l11-8-4-13 11 8 11-8-5 13zm0-62-11 8 5 13-11-8-11 8 4-13-11-8h14l4-13 4 13zm-36-50-4 13 11 8h-14l-4 12-4-12h-14l11-8-4-13 11 8z\"\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=\"4f42b6f4-1a06-412c-ab42-9721248ae0e3\">\r\n <circle cx=\"256\" cy=\"256\" r=\"256\" fill=\"#fff\" />\r\n </mask>\r\n <g mask=\"url(#4f42b6f4-1a06-412c-ab42-9721248ae0e3)\">\r\n <title v-if=\"props.flagName\">{{ props.flagName }}</title>\r\n <path\r\n fill=\"#496e2d\"\r\n d=\"M0 0h208l48 32 48-32h208v208l-32 48 32 48v208H304l-48-32-48 32H0V304l32-48-32-48Z\"\r\n />\r\n <path fill=\"#333\" d=\"M512 240v32l-256 32L0 272v-32l256-32z\" />\r\n <path fill=\"#ffda44\" d=\"M512 208v32H0v-32z\" />\r\n <path fill=\"#333\" d=\"M240 0h32l32 256-32 256h-32l-32-256Z\" />\r\n <path fill=\"#ffda44\" d=\"M208 0h32v512h-32z\" />\r\n <path fill=\"#eee\" d=\"M272 0h32v512h-32z\" />\r\n <path fill=\"#eee\" d=\"M512 272v32H0v-32z\" />\r\n <circle cx=\"256\" cy=\"256\" r=\"122.4\" fill=\"#d80027\" />\r\n <path\r\n fill=\"#496e2d\"\r\n d=\"M284 270c-9-19-21-37-21-37v-13a14 14 0 0 0-27-2 11 11 0 0 0-4 21 16 16 0 0 1 9-9 14 14 0 0 0 2 2h2s-7 19-7 29c0 27 19 36 19 36l-10 9h19v-18l9 9s17-11 9-27zm-28-114 4 13h14l-11 8 4 12-11-8-11 8 4-12-11-8h14Zm-59 19 11 8 11-8-4 13 11 8h-14l-4 12-4-12h-14l11-8zm-36 50h13l4-13 4 13h14l-11 8 4 13-11-8-11 8 5-13zm0 62 11-8-5-13 11 8 11-8-4 13 11 8h-14l-4 13-4-13Zm36 50 4-13-11-8h14l4-12 4 12h13l-10 8 4 13-11-8zm59 19-4-13h-14l11-8-4-12 11 8 11-8-4 12 11 9h-14Zm59-19-11-8-11 8 4-13-10-8h13l4-12 4 12h14l-11 8zm36-50h-13l-4 13-4-13h-14l11-8-4-13 11 8 11-8-5 13zm0-62-11 8 5 13-11-8-11 8 4-13-11-8h14l4-13 4 13zm-36-50-4 13 11 8h-14l-4 12-4-12h-14l11-8-4-13 11 8z\"\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":"0mDAqDQ,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"}