Skip to content

Bug fix: Turn off overflow-x scroll for HoverOverlay

Warren Gifford requested to merge og/fix-hover-overlay-overflow-x into main

Created by: oleggromov

What's wrong

As per the bug report in Slack, we've got a horizontal scroll in the code intel popover. This is due to positioning the close button with float: right.

Solution

The proper fix perhaps would be to renovate the popover's layout. However, since this is a quick bug fix, I am just applying the easiest possible solution.

We also add a story to capture this new behavior with a close button.

Before After
Screenshot 2022-06-22 at 19 58 30 Screenshot 2022-06-22 at 19 58 39

Test plan

  1. Open storybook yarn storybook
  2. Find WebHoverOverlay --> with close button
  3. Ensure there's no scroll

Then locally,

  1. Run sourcegraph sg start web-standalone
  2. Make sure on you mac scrollbars are always shown (Preferences -> General -> Show scroll bars = always)
  3. Open a file and hover over an identifier
  4. You should see no scroll

App preview:

Check out the client app preview documentation to learn more.

Merge request reports

Loading