UNPKG

maille

Version:

Component library for MithrilJS

50 lines (49 loc) 3.16 kB
"use strict"; // THIS FILE WAS AUTO-GENERATED FOR PACKAGING, DO NOT MODIFY Object.defineProperty(exports, "__esModule", { value: true }); const types_1 = require("../../../types"); // tslint:disable-next-line const SVG_PROPS = { "xmlns": "http://www.w3.org/2000/svg", "width": "64", "height": "64", "viewBox": "0 0 640 640", "shape-rendering": "geometricPrecision", "text-rendering": "geometricPrecision", "image-rendering": "optimizeQuality", "fill-rule": "evenodd", "clip-rule": "evenodd" }; class DotsCircle { constructor() { this.defaults = { height: "1em", width: "1em", fill: "black", }; } view(vnode) { return m("svg", Object.assign({}, this.genAttrs(vnode)), // tslint:disable-next-line m.trust('<path d="M494.971 75.698c46.064 0 83.41 37.347 83.41 83.399 0 46.063-37.346 83.41-83.41 83.41-46.052 0-83.399-37.347-83.399-83.41 0-46.052 37.347-83.4 83.399-83.4zm75.58 195.77c-37.524 0-67.962 30.437-67.962 67.95 0 37.535 30.438 67.961 67.962 67.973 37.536 0 67.973-30.438 67.973-67.974 0-37.512-30.437-67.95-67.973-67.95zm-78.804 196.774c-26.21 0-47.47 21.26-47.47 47.469s21.26 47.469 47.47 47.469c26.209 0 47.469-21.26 47.469-47.47 0-26.208-21.26-47.468-47.47-47.468zm-181.55 76.808c-26.208 0-47.469 21.26-47.469 47.469 0 26.22 21.26 47.48 47.47 47.48 26.197 0 47.457-21.26 47.457-47.48 0-26.21-21.26-47.47-47.457-47.47zm-185.541-71.824c-24.568 0-44.481 19.914-44.481 44.481 0 24.555 19.913 44.48 44.48 44.48 24.556 0 44.47-19.924 44.47-44.48 0-24.567-19.914-44.48-44.47-44.48zM48.84 285.796c-26.162 0-47.375 21.212-47.375 47.362 0 26.15 21.213 47.363 47.375 47.363 26.15 0 47.362-21.213 47.362-47.363S74.99 285.795 48.84 285.795zm75.816-197.118c-33.095 0-59.942 26.847-59.942 59.942s26.847 59.93 59.942 59.93c33.094 0 59.93-26.835 59.93-59.93s-26.836-59.942-59.93-59.942zM310.54 0c-39.851 0-72.179 32.315-72.179 72.166 0 39.85 32.328 72.166 72.179 72.166 39.839 0 72.154-32.315 72.154-72.166C382.694 32.316 350.379 0 310.54 0z"/>')); } genAttrs(vnode) { const overrides = Object.values(types_1.GeneralIconAttrName) .reduce((acc, name) => { if (!name) { return acc; } if (vnode && vnode && vnode.attrs[name]) { acc[name] = vnode.attrs[name]; return acc; } if (name in this.defaults) { acc[name] = this.defaults[name]; } return acc; }, {}); const attrs = Object.assign({}, SVG_PROPS, overrides); if (!("style" in attrs) || !attrs.style) { attrs.style = {}; } if (attrs.style && typeof attrs.style !== "object") { throw new Error("attr.style must be an object for icons"); } attrs.style["vertical-align"] = "middle"; attrs.style["min-width"] = "1.25em"; const additionalClasses = "maille maille-uxwing-icon dots-circle"; attrs.className = attrs.className ? (attrs.className + " " + additionalClasses) : additionalClasses; return attrs; } } exports.default = DotsCircle;