Skip to content

Integrate new reference panel into existing `BlobPanel`

Warren Gifford requested to merge mrn/integrate-panel into main

Created by: mrnugget

This fixes #32307 (closed) by integrating the new reference panel into the existing BlobPanel as another BuiltinPanelView.

There's three interesting bits here:

  • I made the PanelViews dynamic so that they can match different tab IDs in the URL (#tab=<ID>), since the new reference panel needs to be backward compatible and react to #tab=def, #tab=references, #tab=implementations_$LANGUAGE, which are hardcoded into the extensions.
  • Depending on whether the feature flag coolCodeIntel is enabled, the new panel or the old def/ref/implementations panels are used. The def and ref panels are easily deactivated, but the implementations_$LANGUAGE panels come from extensions, so I had to dynamically filter them.
  • I had to essentially move the styling of the panels. They still look the same, but I had to move some styling and optionally disable a wrapper element so I can get the overflow: scroll working correctly for the two panes inside the new panel.

The rest is essentially cleanup and restructuring of the existing components and removal of those that we don't need anymore. I also thought about moving components but that would've made the diff unreadable. So I'll save that for a follow-up PR.

Test plan

  • Tested this locally by enabling/disabling the flag, checking whether the new panel reacts to all URLs, testing that dynamic matching works, etc. See video.

https://user-images.githubusercontent.com/1185253/157863497-65eecf67-5e4c-4a1e-88e6-7b2073eaaedb.mp4

Merge request reports

Loading