Skip to content
This repository was archived by the owner on Jun 1, 2023. It is now read-only.

Only show scrollbars when needed #132

Merged
merged 4 commits into from
Jul 27, 2020

Conversation

andrewchang-bird
Copy link
Contributor

Changes overflow: scroll to overflow: auto so that scroll bars only appear if the content is scrollable. This primarily affects macOS users who opt to always show scroll bars for accessibility reasons (and users on platforms that don't auto-hide scroll bars).

Currently, the docs look like this (notice the scroll bars for non-scrollable content in the nav and code blocks):

Old

This change hides scroll bars for non-scrollable content, which seems like the expected behavior:

New non-scrollable

Content that is actually scrollable still shows scroll bars:

New scrollable

Changes `overflow: scroll` to `overflow: auto` so that scroll bars only
appear if the content is scrollable. This primarily affects macOS users
who opt to always show scroll bars for accessibility reasons (and users
on platforms that don't auto-hide scroll bars).
@mattt mattt merged commit 6fe449c into SwiftDocOrg:master Jul 27, 2020
@mattt
Copy link
Contributor

mattt commented Jul 27, 2020

Hey, @andrewchang-bird! Thank you for taking the time to write this up and submit a patch. I just merged it, and look forward to cutting a new release on Friday that includes this fix.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants