Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix the broken "Show source" toggle for Ruby 3.4 docs #2466

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

StalemateInc
Copy link

Should fix #2417.

With Ruby 3.4 the documentation is generated using a different theme, which impacted the layout of the page and the classes for HTML elements. Without the change the "Source" toggle from the original doc is copied over into the the final document without doing anything, whereas the expected header "Show source" link is missing and as the result the source code cannot be viewed.

This PR updates Docs::Rdoc::CleanHtmlFilter to add a link for methods with the source and remove the superfluous "Source" toggle from the original documentation.

Manually tested on documentation from Ruby 3.3 and 3.4.

Before Screenshot 2025-03-26 at 22 21 04
After Screenshot 2025-03-26 at 22 22 57

@StalemateInc StalemateInc requested a review from a team as a code owner March 26, 2025 19:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Ruby3.4 Show Source toggle does not work
1 participant