1 | import _extends from 'babel-runtime/helpers/extends';
|
2 | import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties';
|
3 | import _classCallCheck from 'babel-runtime/helpers/classCallCheck';
|
4 | import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';
|
5 | import _inherits from 'babel-runtime/helpers/inherits';
|
6 |
|
7 | var _class, _temp;
|
8 |
|
9 | import React, { Component } from 'react';
|
10 | import PropTypes from 'prop-types';
|
11 | import classNames from 'classnames';
|
12 | import ConfigProvider from '../config-provider';
|
13 |
|
14 |
|
15 |
|
16 |
|
17 |
|
18 | var CardContent = (_temp = _class = function (_Component) {
|
19 | _inherits(CardContent, _Component);
|
20 |
|
21 | function CardContent() {
|
22 | _classCallCheck(this, CardContent);
|
23 |
|
24 | return _possibleConstructorReturn(this, _Component.apply(this, arguments));
|
25 | }
|
26 |
|
27 | CardContent.prototype.render = function render() {
|
28 | var _props = this.props,
|
29 | prefix = _props.prefix,
|
30 | className = _props.className,
|
31 | Component = _props.component,
|
32 | others = _objectWithoutProperties(_props, ['prefix', 'className', 'component']);
|
33 |
|
34 | return React.createElement(Component, _extends({}, others, {
|
35 | className: classNames(prefix + 'card-content-container', className)
|
36 | }));
|
37 | };
|
38 |
|
39 | return CardContent;
|
40 | }(Component), _class.propTypes = {
|
41 | prefix: PropTypes.string,
|
42 | |
43 |
|
44 |
|
45 | component: PropTypes.elementType,
|
46 | className: PropTypes.string
|
47 | }, _class.defaultProps = {
|
48 | prefix: 'next-',
|
49 | component: 'div'
|
50 | }, _temp);
|
51 | CardContent.displayName = 'CardContent';
|
52 |
|
53 |
|
54 | export default ConfigProvider.config(CardContent); |
\ | No newline at end of file |