UNPKG

maille

Version:

Component library for MithrilJS

50 lines (49 loc) 3.35 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", "shape-rendering": "geometricPrecision", "text-rendering": "geometricPrecision", "image-rendering": "optimizeQuality", "fill-rule": "evenodd", "clip-rule": "evenodd", "viewBox": "0 0 640 640" }; class CalendarTimes { 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="M43.252 76.477h118.005l-.13-2.031V21.508c0-11.835 12.296-21.52 27.367-21.52 15.06 0 27.39 9.72 27.39 21.52v52.938l-.142 2.031h200.98l-.142-2.031V21.508c0-11.835 12.295-21.52 27.366-21.52 15.06 0 27.39 9.72 27.39 21.52v52.938l-.141 2.031H596.76c5.362 0 9.732 4.37 9.732 9.733v101.352c0 5.362-4.37 9.732-9.732 9.732H43.253c-5.363 0-9.745-4.37-9.745-9.732V86.21c0-5.363 4.382-9.733 9.745-9.733zm324.832 245.2c11.008-11.173 28.913-11.232 39.98-.106 11.067 11.126 11.115 29.197.107 40.37l-48.308 49.005 48.367 49.04c10.913 11.09 10.76 29.067-.331 40.134-11.103 11.08-28.95 11.056-39.863-.047L320 451.376l-48.119 48.792c-11.008 11.185-28.913 11.232-39.98.106-11.067-11.114-11.115-29.197-.107-40.37l48.32-49.005-48.379-49.04c-10.901-11.09-10.76-29.056.331-40.134 11.103-11.08 28.961-11.044 39.863.047l48.036 48.71 48.118-48.805zM35.93 219.735h568.153a2.422 2.422 0 0 1 2.409 2.422V637.59a2.427 2.427 0 0 1-2.41 2.41H35.93c-1.322 0-2.42-1.088-2.42-2.41V222.157a2.425 2.425 0 0 1 2.42-2.422zm46.063 41.28H568.33c2.693 0 4.902 2.327 4.902 4.902v327.37c0 2.575-2.339 4.913-4.902 4.913H77.186c-2.575 0-4.902-2.208-4.902-4.913V270.724c0-5.35 4.359-9.709 9.71-9.709zm361.941-107.883c15.06 0 27.39-9.72 27.39-21.52V78.675l-.153-2.114h-54.45l-.153 2.114v52.937c0 11.835 12.295 21.52 27.366 21.52zm-255.44 0c15.06 0 27.39-9.72 27.39-21.52V78.675l-.153-2.114h-54.462l-.141 2.114v52.937c0 11.835 12.295 21.52 27.366 21.52z"/>')); } 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-times"; attrs.className = attrs.className ? (attrs.className + " " + additionalClasses) : additionalClasses; return attrs; } } exports.default = CalendarTimes;