diff --git a/package.json b/package.json index cd694136..c66dd0d4 100644 --- a/package.json +++ b/package.json @@ -47,7 +47,6 @@ "redux": "^1.0.0 || 1.0.0-rc" }, "dependencies": { - "lodash.assign": "^3.2.0", "react-mixin": "^1.7.0", "react-redux": "^0.2.2", "redux": "^1.0.0-rc" diff --git a/src/react/DebugPanel.js b/src/react/DebugPanel.js index c87fff6c..c81a91f9 100644 --- a/src/react/DebugPanel.js +++ b/src/react/DebugPanel.js @@ -13,9 +13,9 @@ export function getDefaultStyle(props) { position: 'fixed', zIndex: 999, fontSize: 17, - overflow: 'auto', + overflow: 'hidden', opacity: 0.92, - background: 'black', + background: '#181d20', color: 'white', left: left ? 0 : undefined, right: right ? 0 : undefined, @@ -23,7 +23,9 @@ export function getDefaultStyle(props) { bottom: bottom ? 0 : undefined, maxHeight: (bottom && top) ? '100%' : '20%', maxWidth: (left && right) ? '100%' : '20%', - wordWrap: 'break-word' + minWidth: 260, + wordWrap: 'break-word', + boxSizing: 'border-box' }; } diff --git a/src/react/JSONTree/JSONArrayNode.js b/src/react/JSONTree/JSONArrayNode.js index 1b1e305c..e7075453 100644 --- a/src/react/JSONTree/JSONArrayNode.js +++ b/src/react/JSONTree/JSONArrayNode.js @@ -3,7 +3,6 @@ import reactMixin from 'react-mixin'; import { ExpandedStateHandlerMixin } from './mixins'; import JSONArrow from './JSONArrow'; import grabNode from './grab-node'; -import assign from 'lodash.assign'; const styles = { base: { @@ -90,8 +89,14 @@ export default class JSONArrayNode extends React.Component { listStyle: 'none', display: (this.state.expanded) ? 'block' : 'none' }; - let containerStyle = assign({}, styles.base, styles.parentNode); - let spanStyle = assign({}, styles.span, this.state.expanded ? styles.spanExpanded : {}); + let containerStyle = {...styles.base, ...styles.parentNode}; + let spanStyle = { ...styles.span }; + if (this.state.expanded) { + spanStyle = { + ...spanStyle, + ...styles.spanExpanded + }; + } return (
- ⇧ -
- } - - {!collapsed && -