ruby / rdoc

RDoc produces HTML and online documentation for Ruby projects.
https://ruby.github.io/rdoc/
Other
844 stars 440 forks source link

Fix sidebar scroll again and add missing footer back #1154

Closed st0012 closed 3 months ago

st0012 commented 3 months ago
  1. In #1152 I only added footer to index.html but forgot about other pages. So I added it back to them in this PR.
  2. I standardized sidebar nav's structure to be:

    <nav id="navigation" role="navigation">
      <div id="project-navigation">
        <%= render '_sidebar_navigation.rhtml' %>
        <%= render '_sidebar_search.rhtml' %>
      </div>
      <!-- if the page originally has it -->
      <%= render '_sidebar_table_of_contents.rhtml' %>
    
      <!-- sidebar content for the page -->
    
      <%= render '_footer.rhtml' %>
    </nav>

    And removed unnecessary divs like #project-metadata or #class-metadata as they were never referenced

  3. I changed nav's default overflow setting to auto so we don't need to make individual elements to be scrollable.

Demo

https://github.com/user-attachments/assets/e0a12a60-36d8-40ef-a01e-1fcde8fb995f