mirror of
https://github.com/react/react-native-devtools-frontend.git
synced 2026-10-13 01:54:52 +08:00
This is a reland of f353e8cc4c.
The scroll events logic was flakey; swapping to a polling system which should be
more robust.
Original change's description:
> Fix ElementsBreadcrumbs mutation bugs.
>
> This CL fixes two bugs in the breadcrumbs that were causing too much
> mutation:
>
> 1) Re-creating `NodeText` elements on each render.
> 2) Destroying the scroll buttons and then re-rendering them on every
> scroll.
>
> The first is fixed by using `<devtools-node-text>` and deferring all
> other rendering and instantiation concerns to Lit-Html/the browser. The
> second is fixed by hiding and showing the buttons with CSS. We use the
> new `withNoMutations` unit test helper to ensure we don't mutate and to
> avoid mutations being inadvertently introduced again.
>
> Bug: 1129881
> Change-Id: I17fb517e2eca4761705d604ac34e6404a40b28f8
> Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2421691
> Commit-Queue: Jack Franklin <jacktfranklin@chromium.org>
> Reviewed-by: Paul Lewis <aerotwist@chromium.org>
Bug: 1129881
Change-Id: I9a2c8cb49c5e60868622a103668d99a9f759053d
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2421700
Auto-Submit: Jack Franklin <jacktfranklin@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
Commit-Queue: Jack Franklin <jacktfranklin@chromium.org>