Skip to content

Commit

Permalink
fix: complex debug values not showing in collapsed state
Browse files Browse the repository at this point in the history
  • Loading branch information
eps1lon committed Mar 9, 2020
1 parent c831387 commit 13a9992
Showing 1 changed file with 4 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import EditableValue from './EditableValue';
import ExpandCollapseToggle from './ExpandCollapseToggle';
import {InspectedElementContext} from './InspectedElementContext';
import KeyValue from './KeyValue';
import {serializeHooksForCopy} from '../utils';
import {getMetaValueLabel, serializeHooksForCopy} from '../utils';
import styles from './HooksTree.css';
import useContextMenu from '../../ContextMenu/useContextMenu';
import {meta} from '../../../hydration';
Expand Down Expand Up @@ -202,17 +202,11 @@ function HookView({canEditHooks, hook, id, inspectPath, path}: HookViewProps) {
className={name !== '' ? styles.Name : styles.NameAnonymous}>
{name || 'Anonymous'}
</span>
<span className={styles.Value} onClick={toggleIsOpen}>
{getMetaValueLabel(value)}
</span>
</div>
<div className={styles.Children} hidden={!isOpen}>
<KeyValue
depth={1}
alphaSort={false}
inspectPath={inspectPath}
name="DebugValue"
path={path.concat(['value'])}
pathRoot="hooks"
value={value}
/>
{subHooksView}
</div>
</div>
Expand Down

0 comments on commit 13a9992

Please sign in to comment.