Skip to the content

Hata旗

Load a native country or region flag, choose supported framing and keep each drawing’s source, author and licence.

Hata (旗) is Japanese for a flag. About the name

Contents

Reference · CV.4X3 flag SVG

svgconstant

The flag of Cape Verde (カーボベルデ), CV, drawn again by hand at 4:3 by flag-icons 7.5.0 (MIT), as an SVG string: viewBox 640 by 480, 1.3 KB. The drawing flag("CV", { shape: "4:3" }) uses, made for that shape by hand rather than cut from the flag. The /manifest entry's framings say how each frame was chosen.

Import it

import { svg } from "@johnmorrisdotca/hata/flags/cv.4x3";

Definition

const svg: string = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 640 480\"><defs><clipPath id=\"hata-cv-4x3-a\"><path fill-opacity=\".7\" d=\"M-123.4 0h682.6v512h-682.6z\"/></clipPath></defs><g fill-rule=\"evenodd\" clip-path=\"url(#hata-cv-4x3-a)\" transform=\"translate(115.7)scale(.94)\"><path fill=\"#fff\" d=\"M-123.4 233H723v206h-846.5z\"/><path fill=\"#081873\" d=\"M-122.8 0h846v256.6h-846zm.3 385.9h852.1V512h-852.1z\"/><path fill=\"#de3929\" d=\"M-122.5 302.6h846v39.6h-846z\"/><path fill=\"#ffce08\" d=\"m131 399.2 6.6 20.4H159l-17.4 12.7 6.6 20.5L131 440l-17.4 12.7 6.7-20.5-17.4-12.7h21.5M317 250.4l6.7 20.5H345l-17.4 12.6 6.6 20.5-17.4-12.7-17.4 12.7 6.6-20.5-17.4-12.6h21.6m-222 64.4 6.6 20.5h21.5L99 368.6l6.7 20.4-17.4-12.6L70.9 389l6.6-20.4-17.4-12.7h21.5M317 329.5l6.7 20.4H345l-17.4 12.7 6.6 20.4-17.4-12.6-17.4 12.7 6.6-20.5-17.4-12.7h21.6m-40.5-161.7 6.7 20.4H298l-17.4 12.7 6.6 20.5-17.4-12.7-17.4 12.7 6.7-20.5-17.5-12.7h21.6m-64.5-45.2 6.7 20.5h21.5l-17.4 12.6 6.6 20.5-17.4-12.6-17.4 12.6 6.7-20.5-17.4-12.6H192m-64.5 2.9 6.7 20.5h21.5l-17.4 12.6 6.7 20.5-17.5-12.7-17.4 12.7 6.7-20.5-17.4-12.6H121m-34.8 43.2 6.6 20.5h21.6l-17.5 12.6 6.7 20.5-17.4-12.7-17.4 12.7 6.6-20.5L58 271h21.5m119.2 149.4 6.7 20.5h21.5l-17.4 12.6 6.7 20.5-17.5-12.7-17.4 12.7 6.7-20.5-17.4-12.6H192m82.2-41.7 6.6 20.4h21.5L285 432.3l6.7 20.5-17.4-12.7-17.5 12.7 6.7-20.5-17.4-12.7h21.5\"/></g></svg>"

Examples

Example 1

import square from "@johnmorrisdotca/hata/flags/cv.4x3";

const host=document.createElement("div");
host.innerHTML = square;
console.log(host.querySelector("svg")?.getAttribute("viewBox"));

Example 2

import { svg } from "@johnmorrisdotca/hata/flags/cv.4x3";
console.log(svg.startsWith("<svg"),svg.length);
true 1359

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/hata 1.6.0.