Allow exploring all events in table view

Summary: This lets you debug when events go off screen

Reviewed By: lblasa

Differential Revision: D48395787

fbshipit-source-id: 51a6eb74fa0f61c34f25e86a6ee40bf5969379ee
This commit is contained in:
Luke De Feo
2023-08-21 04:24:16 -07:00
committed by Facebook GitHub Bot
parent 1bffe8bc6b
commit 22d1bc2552
5 changed files with 30 additions and 33 deletions

View File

@@ -20,17 +20,17 @@ import {FrameworkEvent, Id} from '../ClientTypes';
import {plugin} from '../index';
import {Button, Tooltip} from 'antd';
export function FrameworkEventsTable({treeId}: {treeId?: Id}) {
export function FrameworkEventsTable({nodeId}: {nodeId: Id}) {
const instance = usePlugin(plugin);
const managerRef = useRef<DataTableManager<FrameworkEvent> | null>(null);
useEffect(() => {
if (treeId != null) {
if (nodeId != null) {
managerRef.current?.resetFilters();
managerRef.current?.addColumnFilter('treeId', treeId as string);
managerRef.current?.addColumnFilter('nodeId', nodeId as string);
}
}, [treeId]);
}, [nodeId]);
return (
<Layout.Container grow>