UNPKG

react-web-native-sketch

Version:

[TODO: We need an overview of how this can be used via npm vs as a local package]

49 lines 1.79 kB
"use strict"; var __extends = (this && this.__extends) || (function () { var extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; return function (d, b) { extendStatics(d, b); function __() { this.constructor = d; } d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); }; })(); Object.defineProperty(exports, "__esModule", { value: true }); var _a; var React = require("react"); var __1 = require("../.."); var theme_1 = require("../../utils/theme"); var styles = { root: { backgroundColor: '#eee' }, elevation: (_a = {}, _a[theme_1.web] = { boxShadow: '0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24)', transition: 'all 0.3s cubic-bezier(.25,.8,.25,1)', }, _a[theme_1.all] = { shadowColor: '#000000', shadowOffset: { width: 0, height: 2 }, shadowRadius: 4, shadowOpacity: 1.0 }, _a), }; var CPaper = /** @class */ (function (_super) { __extends(CPaper, _super); function CPaper() { return _super !== null && _super.apply(this, arguments) || this; } CPaper.prototype.render = function () { var _a = this.props, children = _a.children, classes = _a.classes, style = _a.style, name = _a.name; return (React.createElement(__1.View, { name: name, style: [classes.elevation, style] }, children)); }; return CPaper; }(React.PureComponent)); exports.Paper = __1.createStyles(styles, 'Paper')(CPaper); //# sourceMappingURL=Paper.js.map