UNPKG

bs-spectacle

Version:
131 lines (126 loc) 3.13 kB
// Generated by BUCKLESCRIPT VERSION 2.2.2, PLEASE EDIT WITH CARE 'use strict'; var ReasonReact = require("reason-react/src/ReasonReact.js"); var Types$BsSpectacle = require("./Types.js"); function extendProps(italic, bold, caps, margin, padding, textColor, textSize, textAlign, textFont, bgColor, bgImage, bgSize, bgPosition, bgRepeat, bgDarken, overflow, height, moreProps) { var tmp = { }; var tmp$1 = Types$BsSpectacle.to_js_boolean(italic); if (tmp$1) { tmp.italic = tmp$1[0]; } var tmp$2 = Types$BsSpectacle.to_js_boolean(bold); if (tmp$2) { tmp.bold = tmp$2[0]; } var tmp$3 = Types$BsSpectacle.to_js_boolean(caps); if (tmp$3) { tmp.caps = tmp$3[0]; } if (margin) { tmp.margin = margin[0]; } if (padding) { tmp.padding = padding[0]; } if (textColor) { tmp.textColor = textColor[0]; } if (textSize) { tmp.textSize = textSize[0]; } if (textAlign) { tmp.textAlign = textAlign[0]; } if (textFont) { tmp.textFont = textFont[0]; } if (bgColor) { tmp.bgColor = bgColor[0]; } if (bgImage) { tmp.bgImage = bgImage[0]; } if (bgSize) { tmp.bgSize = bgSize[0]; } if (bgPosition) { tmp.bgPosition = bgPosition[0]; } if (bgRepeat) { tmp.bgRepeat = bgRepeat[0]; } if (bgDarken) { tmp.bgDarken = bgDarken[0]; } if (overflow) { tmp.overflow = overflow[0]; } if (height) { tmp.height = height[0]; } return Object.assign({ }, tmp, moreProps); } function MakeBaseComponent(BaseComponent) { var make = function (italic, bold, caps, margin, padding, textColor, textSize, textAlign, textFont, bgColor, bgImage, bgSize, bgPosition, bgRepeat, bgDarken, overflow, height, children) { var tmp = { }; var tmp$1 = Types$BsSpectacle.to_js_boolean(italic); if (tmp$1) { tmp.italic = tmp$1[0]; } var tmp$2 = Types$BsSpectacle.to_js_boolean(bold); if (tmp$2) { tmp.bold = tmp$2[0]; } var tmp$3 = Types$BsSpectacle.to_js_boolean(caps); if (tmp$3) { tmp.caps = tmp$3[0]; } if (margin) { tmp.margin = margin[0]; } if (padding) { tmp.padding = padding[0]; } if (textColor) { tmp.textColor = textColor[0]; } if (textSize) { tmp.textSize = textSize[0]; } if (textAlign) { tmp.textAlign = textAlign[0]; } if (textFont) { tmp.textFont = textFont[0]; } if (bgColor) { tmp.bgColor = bgColor[0]; } if (bgImage) { tmp.bgImage = bgImage[0]; } if (bgSize) { tmp.bgSize = bgSize[0]; } if (bgPosition) { tmp.bgPosition = bgPosition[0]; } if (bgRepeat) { tmp.bgRepeat = bgRepeat[0]; } if (bgDarken) { tmp.bgDarken = bgDarken[0]; } if (overflow) { tmp.overflow = overflow[0]; } if (height) { tmp.height = height[0]; } return ReasonReact.wrapJsForReason(BaseComponent[/* reactClass */0], tmp, children); }; return /* module */[/* make */make]; } exports.extendProps = extendProps; exports.MakeBaseComponent = MakeBaseComponent; /* ReasonReact Not a pure module */