From a4525790a28b937d7e556e4c4f287c764dcab4d4 Mon Sep 17 00:00:00 2001 From: Luke De Feo Date: Wed, 14 Dec 2022 08:41:23 -0800 Subject: [PATCH] Revert always root snapshot Summary: this assumption doesnt hold true for android as the snapshot is of the decor view and app bounds include the status bar / bottom bar Reviewed By: elboman Differential Revision: D42035810 fbshipit-source-id: 177b5d086487a940e0bdbe20c2a001c420a08d69 --- desktop/plugins/public/ui-debugger/index.tsx | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/desktop/plugins/public/ui-debugger/index.tsx b/desktop/plugins/public/ui-debugger/index.tsx index a418dd2c2..3598d1e08 100644 --- a/desktop/plugins/public/ui-debugger/index.tsx +++ b/desktop/plugins/public/ui-debugger/index.tsx @@ -130,12 +130,9 @@ export function plugin(client: PluginClient) { const seenNodes = new Set(); client.onMessage('subtreeUpdate', (event) => { liveClientData = produce(liveClientData, (draft) => { - // FIXME: remove node id from snapshot as is always - // for the entire screen. - const nodeId = rootId.get(); - if (event.snapshot && nodeId) { + if (event.snapshot) { draft.snapshotInfo = { - nodeId, + nodeId: event.rootId, base64Image: event.snapshot, }; }