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

Use Docsy Theme #338

Merged
merged 42 commits into from
Nov 4, 2023
Merged

Use Docsy Theme #338

merged 42 commits into from
Nov 4, 2023

Conversation

ajschmidt8
Copy link
Member

@ajschmidt8 ajschmidt8 commented Nov 2, 2023

Closes #334.

This PR updates our website to use the Docsy theme for Hugo.

Our site was previously using Bulma as its CSS framework, but Docsy uses Bootstrap.

To avoid having two CSS frameworks included in our site, I've migrated our HTML and CSS from Bulma to Bootstrap.

As a result, this PR touches pretty much all of the files in the repository.

Fortunately, Bootstrap is very configurable and a lot of its class names overlap with Bulma's. Therefore, I was able to configure Bootstrap with Bulma's font sizes, grid settings, etc. to make the transition a little bit easier.

There were a lot of CSS class names that needed to be changed.

The HTML changes consisted mostly of just adding an extra adding a row class to our section elements and wrapping the section contents in a <div class="col"></div>.

The exception here is the navigation bar, which had to be completely rewritten for Bootstrap.

Finally, I've added some draft content to the docs/ directory and configured our Netlify preview environment to build drafts so they can be easily showcased.

There is still more work to do for the documentation page styles, but this PR is a great starting point. I will add my thoughts on follow up tasks as a comment.

horizontal padding is handled by Bootstraps grid
@ajschmidt8
Copy link
Member Author

ajschmidt8 commented Nov 2, 2023

The preview environment for this PR is here: https://deploy-preview-338--rapids-ai.netlify.app/.

The preview site should look mostly indistinguishable from our production site, https://rapids.ai/.

Here is how the documentation pages look in a preview environment so far (ugly, indeed): https://deploy-preview-338--rapids-ai.netlify.app/docs/.

Here's how a default Docsy doc page looks for reference: https://www.docsy.dev/docs/.

Potential Follow-up tasks:

  • Phase 1
    • Fix documentation page styles:
      • Add appropriate margin/padding to top of page to account for fixed navbar
        • Alternatively, make navbar static on doc pages
      • Remove slant from footer on doc pages? or just adjust padding/margin
      • Remove HTML element styles that prevent basic markdown from being styled correctly
        • This will require adjusting additional styles to the landing pages to prevent styles from changing
    • Use Bootstrap utility API to generate utility classes for custom RAPIDS colors:
      • e.g. has-text-rapids-purple-primary, has-text-rapids-purple-secondary2, has-border-rapids-teal
    • remove remaining @extends from scss (can be done after custom color utility classes are generated)
    • enable taxonomies (for upcoming announcement/notices pages)
  • Phase 2
    • Adjust mobile menu styles to ensure menu is vertically scrollable on small screens
    • Use Hugo's built-in image-processing functionality to resize our adopter/contributor images to a reasonable size
      • Alternatively, we can just resize the source images instead of processing them with Hugo
    • Add some code quality tools to the repo/devcontainer, like StyleLint, HTML formatters, etc.
    • Investigate adding purgecss to our PostCSS config to remove unused CSS styles from our final stylesheet

@ajschmidt8 ajschmidt8 marked this pull request as ready for review November 4, 2023 15:41
@ajschmidt8 ajschmidt8 requested a review from a team as a code owner November 4, 2023 15:41
@ajschmidt8
Copy link
Member Author

Allan and I reviewed this collectively yesterday and he gave a verbal approval to merge.

therefore I will admin merge this PR.

@ajschmidt8 ajschmidt8 merged commit dc16c35 into rapidsai:main Nov 4, 2023
3 checks passed
@ajschmidt8 ajschmidt8 deleted the docsy branch November 4, 2023 15:43
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.

Incorporate Hugo Docsy Theme
1 participant