crystal-lang / crystal-website

crystal-lang.org website
61 stars 77 forks source link

Weird behavior with overflow y scrollbars on examples #759

Closed GeopJr closed 7 months ago

GeopJr commented 7 months ago

The y scrollbars are missing on both firefox and chromium by default due to margin-inline-start and calc (guessing) - even though they are supposed to be visible. This looks like a browser bug in both cases:

Firefox - toggling margin-inline-start fixes it:

Screencast from 2024-03-29 16-43-21.webm

Chromium - opening the inspector seems to fix it:

Screencast from 2024-03-29 16-46-28.webm

GNOME Web (webkit) - while it might not be 1:1 with Safari, no amount of style toggling makes the scrollbar appear

straight-shoota commented 7 months ago

This looks like a very weird condition for hidden scrollbars. But I can confirm the effect of disabling margin-inline-start on the parent element.

I suppose we can drop it from the style sheet, alongside the padding-inline-start to which it corresponds. They just implement a tiny visual polish for the link outline which reaches a bit outside the parent container.