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 Feb 19, 2020
1 parent e53d44c commit a9444d1
Showing 1 changed file with 4 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,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 @@ -201,17 +201,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 a9444d1

Please sign in to comment.