Don't display expand/collapse for no-data events (#7225)

This commit is contained in:
Jaco 2022-03-24 15:07:08 +01:00 committed by GitHub
parent dfa1beb232
commit b505ab1bc1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -19,10 +19,15 @@ function Event ({ className = '', value: { event } }: Props): React.ReactElement
summary={`${event.section}.${event.method}`}
summaryMeta={event.meta}
>
<EventDisplay
className='details'
value={event}
/>
{event.data.length
? (
<EventDisplay
className='details'
value={event}
/>
)
: null
}
</Expander>
);
}