UNPKG

@dialpad/dialtone-icons

Version:

Dialtone icon library

68 lines (67 loc) 2.66 kB
import { I as t } from "../constants-DeVuDy8J.js"; import { openBlock as i, createElementBlock as r, normalizeClass as d, createElementVNode as c } from "vue"; import { _ as n } from "../_plugin-vue_export-helper-CHgC5LLL.js"; const o = { name: "DtIconFlag", props: { /** * The size of the icon. * @values 100, 200, 300, 400, 500, 600, 700, 800 */ size: { type: String, default: "500", validator: (e) => Object.keys(t).includes(e) }, /** * The label of the icon as read out by a screenreader. Leave this unset if your icon is purely presentational */ ariaLabel: { type: String, default: void 0 } }, /** * @TODO: Remove this emit once the icons migration is complete, * they will no longer need this event. * */ emits: ["loaded"], computed: { iconSizeClass() { return t[this.size]; }, ariaHidden() { return this.ariaLabel ? "false" : "true"; }, dataQA() { return this.$attrs["data-qa"] ?? "dt-icon"; } }, created() { this.$emit("loaded"); } }, s = ["aria-label", "data-qa", "aria-hidden"], _ = /* @__PURE__ */ c("path", { fill: "currentColor", "fill-rule": "evenodd", d: "M2.252.786C2.63.635 3.194.5 4 .5c.847 0 1.548.28 2.158.525l.028.01C6.82 1.29 7.36 1.5 8 1.5c.694 0 1.13-.115 1.377-.214a1.341 1.341 0 0 0 .28-.15.5.5 0 0 1 .843.364v6a.5.5 0 0 1-.146.354L10 7.5l.354.354h-.002v.002l-.003.002-.005.005-.014.013c-.01.009-.022.02-.037.031a1.271 1.271 0 0 1-.117.087c-.1.066-.24.145-.428.22C9.37 8.365 8.806 8.5 8 8.5c-.847 0-1.548-.28-2.158-.525l-.028-.01C5.18 7.71 4.64 7.5 4 7.5c-.694 0-1.13.115-1.377.214a1.688 1.688 0 0 0-.123.055V11a.5.5 0 0 1-1 0V1.5a.5.5 0 0 1 .146-.354L2 1.5l-.354-.354h.002v-.002l.003-.002.005-.005.014-.013c.01-.009.022-.02.037-.031.029-.025.068-.054.117-.087a2.33 2.33 0 0 1 .428-.22Zm.248.983v4.93c.364-.113.854-.199 1.5-.199.847 0 1.548.28 2.158.525l.028.01C6.82 7.29 7.36 7.5 8 7.5c.694 0 1.13-.115 1.377-.214a2.79 2.79 0 0 0 .123-.055v-4.93c-.364.113-.854.199-1.5.199-.847 0-1.548-.28-2.158-.525l-.028-.01C5.18 1.71 4.64 1.5 4 1.5c-.694 0-1.13.115-1.377.214a1.688 1.688 0 0 0-.123.055Z", "clip-rule": "evenodd" }, null, -1), m = [ _ ]; function u(e, f, l, h, p, a) { return i(), r("svg", { "aria-label": l.ariaLabel, class: d([a.iconSizeClass, "d-icon d-icon--flag"]), "data-qa": a.dataQA, "aria-hidden": a.ariaHidden, role: "img", "data-name": "Flag", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 12 12" }, m, 10, s); } const b = /* @__PURE__ */ n(o, [["render", u]]); export { b as default }; //# sourceMappingURL=flag.js.map