UNPKG

tuya-panel-kit

Version:

a functional component library for developing tuya device panels!

53 lines (36 loc) 3.54 kB
Object.defineProperty(exports, "__esModule", { value: true }); exports.StyledImage = exports.StyledIconFont = exports.StyledTitle = exports.StyledNotificationContainer = exports.StyledNotificationContent = exports.StyledNotification = undefined; var _templateObject = _taggedTemplateLiteral(['\n align-self: stretch;\n align-items: center;\n justify-content: space-between;\n'], ['\n align-self: stretch;\n align-items: center;\n justify-content: space-between;\n']), _templateObject2 = _taggedTemplateLiteral(['\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n margin: ', ';\n border-radius: 22;\n background-color: ', ';\n'], ['\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n margin: ', ';\n border-radius: 22;\n background-color: ', ';\n']), _templateObject3 = _taggedTemplateLiteral(['\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n margin: ', ';\n min-height: 10;\n background-color: ', ';\n'], ['\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n margin: ', ';\n min-height: 10;\n background-color: ', ';\n']), _templateObject4 = _taggedTemplateLiteral(['\n min-width: ', 'px;\n max-width: ', 'px;\n font-size: 14;\n color: ', ';\n margin: ', ';\n'], ['\n min-width: ', 'px;\n max-width: ', 'px;\n font-size: 14;\n color: ', ';\n margin: ', ';\n']), _templateObject5 = _taggedTemplateLiteral(['\n position: absolute;\n top: ', 'px;\n'], ['\n position: absolute;\n top: ', 'px;\n']), _templateObject6 = _taggedTemplateLiteral(['\n position: absolute;\n top: ', 'px;\n height: ', 'px;\n width: ', 'px;\n'], ['\n position: absolute;\n top: ', 'px;\n height: ', 'px;\n width: ', 'px;\n']); var _reactNative = require('react-native'); var _native = require('styled-components/native'); var _native2 = _interopRequireDefault(_native); var _utils = require('../../utils'); var _TYText = require('../TYText'); var _TYText2 = _interopRequireDefault(_TYText); var _iconfont = require('../iconfont'); var _iconfont2 = _interopRequireDefault(_iconfont); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _taggedTemplateLiteral(strings, raw) { return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); } var viewWidth = _utils.RatioUtils.viewWidth, cx = _utils.RatioUtils.convertX; var StyledNotification = exports.StyledNotification = (0, _native2.default)(_reactNative.TouchableOpacity)(_templateObject); var StyledNotificationContent = exports.StyledNotificationContent = (0, _native2.default)(_reactNative.View)(_templateObject2, 12 + 'px 0px ' + 2 + 'px 0px', function (props) { return props.background; }); var StyledNotificationContainer = exports.StyledNotificationContainer = (0, _native2.default)(_reactNative.View)(_templateObject3, '10px ' + cx(16) + 'px', function (props) { return props.background; }); var StyledTitle = exports.StyledTitle = (0, _native2.default)(_TYText2.default)(_templateObject4, cx(44), viewWidth - 142, function (props) { return props.color; }, '0px ' + cx(30) + 'px 0px ' + cx(32) + 'px'); var StyledIconFont = exports.StyledIconFont = (0, _native2.default)(_iconfont2.default)(_templateObject5, function (props) { return props.enableClose ? cx(2) : 0; }); var StyledImage = exports.StyledImage = (0, _native2.default)(_reactNative.Image)(_templateObject6, cx(2), cx(21), cx(24));