diff --git a/src/view/components/profiler/components/RenderedAt/RenderedAt.tsx b/src/view/components/profiler/components/RenderedAt/RenderedAt.tsx index d0a9fb99..0f26ad50 100644 --- a/src/view/components/profiler/components/RenderedAt/RenderedAt.tsx +++ b/src/view/components/profiler/components/RenderedAt/RenderedAt.tsx @@ -9,24 +9,18 @@ export function RenderedAt() { const data = useObserver(() => { const id = store.profiler.selectedNodeId.$; - return store.profiler.commits.$.filter(x => { - if (x.nodes.has(id)) { - const node = x.nodes.get(id)!; - const root = x.nodes.get(x.commitRootId)!; - return node.startTime >= root.startTime && node.endTime <= root.endTime; - } + return store.profiler.commits.$.filter(x => x.rendered.includes(id)).map( + commit => { + const node = commit.nodes.get(id)!; - return false; - }).map(commit => { - const node = commit.nodes.get(id)!; - - const selfDuration = commit.selfDurations.get(id) || 0; - return { - index: store.profiler.commits.$.findIndex(x => x === commit), - startTime: node.startTime, - selfDuration, - }; - }); + const selfDuration = commit.selfDurations.get(id) || 0; + return { + index: store.profiler.commits.$.findIndex(x => x === commit), + startTime: node.startTime, + selfDuration, + }; + }, + ); }); const commitIdx = useObserver(() => store.profiler.activeCommitIdx.$);