UNPKG

maille

Version:

Component library for MithrilJS

50 lines (49 loc) 3.83 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", "viewBox": "0 0 3763 3763", "shape-rendering": "geometricPrecision", "text-rendering": "geometricPrecision", "image-rendering": "optimizeQuality", "fill-rule": "evenodd", "clip-rule": "evenodd" }; class CalendarOutline { 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('<defs><style>.fil0{fill:none}</style></defs><g id="Layer_x0020_1"><path class="fil0" d="M1544 470h658m952 0h323c103 0 188 84 188 188v2820c0 103-84 188-188 188H286c-103 0-188-84-188-188V658c0-103 84-188 188-188h345M98 1486h3567"/><path d="M2499 145c0-80 79-145 177-145s177 65 177 145v635c0 80-79 145-177 145s-177-65-177-145V145zm-475 3034c-10 0-19-44-19-98s8-98 19-98h483c10 0 19 44 19 98s-8 98-19 98h-483zM485 2055c-10 0-19-44-19-98s8-98 19-98h483c10 0 19 44 19 98s-8 98-19 98H485zm770 0c-10 0-19-44-19-98s8-98 19-98h483c10 0 19 44 19 98s-8 98-19 98h-483zm770 0c-10 0-19-44-19-98s8-98 19-98h483c10 0 19 44 19 98s-8 98-19 98h-483zm770 0c-10 0-19-44-19-98s8-98 19-98h483c10 0 19 44 19 98s-8 98-19 98h-483zM486 2617c-10 0-19-44-19-98s8-98 19-98h483c10 0 19 44 19 98s-8 98-19 98H486zm770 0c-10 0-19-44-19-98s8-98 19-98h483c10 0 19 44 19 98s-8 98-19 98h-483zm770 0c-10 0-19-44-19-98s8-98 19-98h483c10 0 19 44 19 98s-8 98-19 98h-483zm770 0c-10 0-19-44-19-98s8-98 19-98h483c10 0 19 44 19 98s-8 98-19 98h-483zM487 3179c-10 0-19-44-19-98s8-98 19-98h483c10 0 19 44 19 98s-8 98-19 98H487zm770 0c-10 0-19-44-19-98s8-98 19-98h483c10 0 19 44 19 98s-8 98-19 98h-483zM909 145c0-80 79-145 177-145s177 65 177 145v635c0 80-79 145-177 145s-177-65-177-145V145zM198 1388h3371V657c0-25-10-47-26-63s-39-26-63-26h-323c-54 0-98-44-98-98s44-98 98-98h323c79 0 150 32 202 84s84 123 84 202v2820c0 79-32 150-84 202s-123 84-202 84H289c-79 0-150-32-202-84S3 3557 3 3478V658c0-79 32-150 84-202s123-84 202-84h345c54 0 98 44 98 98s-44 98-98 98H289c-25 0-47 10-63 26s-26 39-26 63v731zm3371 196H198v1893c0 25 10 47 26 63s39 26 63 26h3191c25 0 47-10 63-26s26-39 26-63V1584zM1546 568c-54 0-98-44-98-98s44-98 98-98h658c54 0 98 44 98 98s-44 98-98 98h-658z" fill-rule="nonzero"/><path class="fil0" d="M485 1957h484M1255 1957h483M2025 1957h483M2794 1957h484M485 2519h484M1255 2519h483M2025 2519h483M2794 2519h484M485 3081h484M1255 3081h483M2025 3081h483"/></g>')); } 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 calendar-outline"; attrs.className = attrs.className ? (attrs.className + " " + additionalClasses) : additionalClasses; return attrs; } } exports.default = CalendarOutline;