Skip to content

Inspector: scope stats and call tree to the selected timeline range #875

Description

@lukecotter

Summary

When a range is selected or zoomed on the Timeline, the Inspector's no-selection content — log overview, time-by-category, hot spots and the call tree — should recompute for just that window.

Today the Inspector is either empty or whole-log, so narrowing the timeline to a suspicious 3 seconds tells you nothing about what is inside it. Chrome DevTools' Performance panel behaves the way we want: its Summary and Bottom-Up tabs describe the selected range, falling back to the whole profile when nothing is selected.

Behaviour

  • Selecting or zooming to a range on the Timeline re-scopes the Inspector's default content to that window.
  • Clearing the range returns it to whole-log figures.
  • Figures must be labelled as range-scoped. A user glancing at "SOQL 12" needs to know instantly whether that is the transaction or the window — an unlabelled number here is worse than no number.
  • A selected frame still wins: an explicit selection shows that frame, not the range.

Constraints worth recording

  • It re-aggregates on every viewport change, so it needs debouncing and a stated perf budget. The renderer's own budget is 60fps on 500k+ line logs; the re-aggregation must not be what breaks it.
  • The call tree needs pruning to the range rather than rebuilding from scratch, for the same reason.
  • Depends on the Inspector's default/no-selection states landing first — the range view is a filtered version of exactly that content, so building it beforehand means building it twice.

Related

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions