UNPKG

@makeen.io/material-ui-kit

Version:
53 lines (19 loc) 2.16 kB
import _extends from "@babel/runtime/helpers/extends";import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";function _templateObject2() {var data = _taggedTemplateLiteral(["\n ", "\n "]);_templateObject2 = function _templateObject2() {return data;};return data;}function _templateObject() {var data = _taggedTemplateLiteral(["\n ", "\n"]);_templateObject = function _templateObject() {return data;};return data;}import React from "react"; import MaterialTab from "@material-ui/core/Tab"; import styled, { css } from "styled-components"; export default styled(function (_ref) {var label = _ref.label,rest = _objectWithoutProperties(_ref, ["label"]);return /*#__PURE__*/React.createElement(MaterialTab, _extends({ classes: { wrapper: "xp-wrapper", selected: "xp-selected" }, label: label }, rest));})(_templateObject(), function (props) { var customStyle = "";var palette = props.palette; var themePalette = props.theme.palette; if (palette) { customStyle = customStyle.concat("\n text-transform: none;\n font-size: 13px;\n font-weight: normal;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.23;\n letter-spacing: normal;\n min-width: 80px;\n min-height: 30px;\n font-weight: bold;\n padding: 1.2em 3.5em;\n\n border: 2px solid ".concat( themePalette[palette].tabs.border, ";\n\n &:first-child {\n border-top-left-radius: 5px;\n border-bottom-left-radius: 5px;\n border-right: none;\n }\n\n &:last-child {\n border-top-right-radius: 5px;\n border-bottom-right-radius: 5px;\n border-left: none;\n }\n\n &:hover {\n color: ").concat( themePalette[palette].tabs.contrastText, "\n }\n &.xp-selected {\n color: ").concat( themePalette[palette].tabs.contrastText, ";\n background-color: ").concat( themePalette[palette].tabs.main, ";\n }\n &.xp-wrapper {\n\n }")); } return css(_templateObject2(), customStyle); }); //# sourceMappingURL=index.js.map