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

Update docs_theme to boostrap V5.x #9404

Open
wants to merge 38 commits into
base: master
Choose a base branch
from

Conversation

mostafaei2002
Copy link

I am trying to update the docs_theme to bootstrap v5.x, There were some problems with the previous version.
The process shouldn't be very hard since the whole HTML structure is less than 250 lines. I don't know how much custom css, js is written for the current active version though.
If everything goes smoothly I should finish in a week or two.
Ideally I would love to use something other than mkdocs to generate the static HTML web pages. Bootstrap itself seems fine but mkdocs isn't that good. I like something like Astro much better.
Probably better to keep it quick and simple though and not overdo it.

@mostafaei2002 mostafaei2002 marked this pull request as draft May 12, 2024 18:45
@mostafaei2002
Copy link
Author

Some updates on my progress so far. I setup webpack for the project and the development environment. The navbar structure is almost completely updated. The side nav structure can be a bit improved and I haven't really touched the main content so far.
For the next step there is some discussion needed as most of the project will be finished and the only thing to work on will be the styles, To be more precise customizing the bootstrap variables and styles it is. And also setting up the dark mode which should be very easy with the tools bootstrap provides.

@mostafaei2002 mostafaei2002 marked this pull request as ready for review May 19, 2024 15:28
@mostafaei2002
Copy link
Author

I would love to have hear your opinions on the new theme. There are some problems specifically with the old django rest framework picture and the sponsers' picture on the dark mode but everything else looks quite good to me.
It's fully responsive as far as I've tested it and there is light & dark themes. To build the website use the following commands.

  1. npm install inside /docs_theme
  2. npm run build:watch inside /docs_theme
  3. mkdocs serve inside / directory (don't forget to install mkdocs from requirements.txt beforehand)

margin-bottom: 1rem;
}

// Temproary fix for mkdocs settings
Copy link
Contributor

@cclauss cclauss May 20, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix a typo discovered by codespell in pre-commit.

Suggested change
// Temproary fix for mkdocs settings
// Temporary fix for mkdocs settings

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To fix the other codespell errors, edit the last line of .pre-commit-config.yaml to change:

    exclude: locale|kickstarter-announcement.md|coreapi-0.1.1.js
# to
    exclude: locale|kickstarter-announcement.md|coreapi-0.1.1.js|docs_theme/package-lock.json

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, I fixed the problems. I would love to hear your opinions on the progress so far and suggestions for improvement.

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.

None yet

2 participants