1 | import _extends from 'babel-runtime/helpers/extends';
|
2 | import _classCallCheck from 'babel-runtime/helpers/classCallCheck';
|
3 | import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';
|
4 | import _inherits from 'babel-runtime/helpers/inherits';
|
5 |
|
6 | var _class, _temp;
|
7 |
|
8 | import React, { Component } from 'react';
|
9 | import PropTypes from 'prop-types';
|
10 | import CheckableItem from './checkable-item';
|
11 |
|
12 |
|
13 |
|
14 |
|
15 |
|
16 |
|
17 | var RadioItem = (_temp = _class = function (_Component) {
|
18 | _inherits(RadioItem, _Component);
|
19 |
|
20 | function RadioItem() {
|
21 | _classCallCheck(this, RadioItem);
|
22 |
|
23 | return _possibleConstructorReturn(this, _Component.apply(this, arguments));
|
24 | }
|
25 |
|
26 | RadioItem.prototype.render = function render() {
|
27 | return React.createElement(CheckableItem, _extends({
|
28 | role: 'menuitemradio',
|
29 | checkType: 'radio'
|
30 | }, this.props));
|
31 | };
|
32 |
|
33 | return RadioItem;
|
34 | }(Component), _class.menuChildType = 'item', _class.propTypes = {
|
35 | |
36 |
|
37 |
|
38 | checked: PropTypes.bool,
|
39 | |
40 |
|
41 |
|
42 | disabled: PropTypes.bool,
|
43 | |
44 |
|
45 |
|
46 |
|
47 |
|
48 | onChange: PropTypes.func,
|
49 | |
50 |
|
51 |
|
52 | helper: PropTypes.node,
|
53 | |
54 |
|
55 |
|
56 | children: PropTypes.node
|
57 | }, _class.defaultProps = {
|
58 | checked: false,
|
59 | disabled: false,
|
60 | onChange: function onChange() {}
|
61 | }, _temp);
|
62 | RadioItem.displayName = 'RadioItem';
|
63 | export { RadioItem as default }; |
\ | No newline at end of file |