1 | import _extends from "@babel/runtime/helpers/extends";
|
2 | import React from 'react';
|
3 | import PropTypes from 'prop-types';
|
4 |
|
5 | var JSONArrow = function JSONArrow(_ref) {
|
6 | var styling = _ref.styling,
|
7 | arrowStyle = _ref.arrowStyle,
|
8 | expanded = _ref.expanded,
|
9 | nodeType = _ref.nodeType,
|
10 | onClick = _ref.onClick;
|
11 | return React.createElement("div", _extends({}, styling('arrowContainer', arrowStyle), {
|
12 | onClick: onClick
|
13 | }), React.createElement("div", styling(['arrow', 'arrowSign'], nodeType, expanded, arrowStyle), "\u25B6", arrowStyle === 'double' && React.createElement("div", styling(['arrowSign', 'arrowSignInner']), "\u25B6")));
|
14 | };
|
15 |
|
16 | JSONArrow.propTypes = {
|
17 | styling: PropTypes.func.isRequired,
|
18 | arrowStyle: PropTypes.oneOf(['single', 'double']),
|
19 | expanded: PropTypes.bool.isRequired,
|
20 | nodeType: PropTypes.string.isRequired,
|
21 | onClick: PropTypes.func.isRequired
|
22 | };
|
23 | JSONArrow.defaultProps = {
|
24 | arrowStyle: 'single'
|
25 | };
|
26 | export default JSONArrow; |
\ | No newline at end of file |