UNPKG

@up-group/react-controls

Version:

We know that there are a ton of react UI library projects to choose from. Our hope with this one is to provide the next generation of react components that you can use to bootstrap your next project, or as a reference for building a UIKit. Read on to get

41 lines 1.99 kB
"use strict"; var __assign = (this && this.__assign) || Object.assign || function(t) { for (var s, i = 1, n = arguments.length; i < n; i++) { s = arguments[i]; for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p]; } return t; }; var __rest = (this && this.__rest) || function (s, e) { var t = {}; for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p]; if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) if (e.indexOf(p[i]) < 0) t[p[i]] = s[p[i]]; return t; }; Object.defineProperty(exports, "__esModule", { value: true }); var React = require("react"); var themedComponents_1 = require("../../../Common/theming/themedComponents"); var defaultProps = { color: '#000', textAlign: 'center', }; exports.style = (_a = ["\n text-align: ", ";\n color: ", ";\n display:'inline-block';\n"], _a.raw = ["\n text-align: ", ";\n color: ", ";\n display:'inline-block';\n"], themedComponents_1.css(_a, function (props) { return props.textAlign || defaultProps.textAlign; }, function (props) { return props.color || defaultProps.color; })); exports.SpanStyled = (_b = ["\n ", "\n"], _b.raw = ["\n ", "\n"], themedComponents_1.default.span(_b, exports.style)); var LigneStyled = function (props) { var dataFor = props.dataFor, className = props.className, children = props.children, others = __rest(props, ["dataFor", "className", "children"]); var tooltipProps = {}; if (dataFor) { tooltipProps = { "data-tip": "tooltip", "data-for": dataFor }; } return (React.createElement(exports.SpanStyled, __assign({ className: className }, tooltipProps, others), children)); }; exports.default = LigneStyled; var _a, _b; //# sourceMappingURL=styles.js.map