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

Removed .0 from doc version drop down #414

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

PaarthAgarwal
Copy link
Contributor

@PaarthAgarwal PaarthAgarwal commented Feb 7, 2023

Signed-off-by: PaarthAgarwal paarth.agarwal.mec20@itbhu.ac.in
Updates the config.toml file to display the version number without .0 in the drop-down.
Closes #219.

Signed-off-by: PaarthAgarwal <paarth.agarwal.mec20@itbhu.ac.in>
@PaarthAgarwal PaarthAgarwal requested review from a team as code owners February 7, 2023 14:20
@PaarthAgarwal
Copy link
Contributor Author

To change the version ion the docs page, we need to update docs/_index.md file for each version in the release branch (release-X.X.X) as well as the master branch

The versions are not hard coded and are taken from {{ $version := index (split .File.Path "/") 1 }}. Should I hardcode the version number instead of passing it like this?

config.toml Outdated Show resolved Hide resolved
Signed-off-by: PaarthAgarwal <paarth.agarwal.mec20@itbhu.ac.in>
@PaarthAgarwal PaarthAgarwal changed the title Replaced .0 with .x for doc version drop down Removed .0 from doc version drop down Feb 10, 2023
@Vad1mo Vad1mo self-requested a review February 10, 2023 12:10
@OrlinVasilev
Copy link
Member

I'm not sure if that's ok due to the fact we do versioning on the docs in branches, it breaks the links now
Details
check the preview first

@OrlinVasilev
Copy link
Member

image

@OrlinVasilev
Copy link
Member

https://deploy-preview-414--goharbor-io.netlify.app/ here is the address

@Vad1mo Vad1mo self-requested a review February 10, 2023 12:59
@PaarthAgarwal
Copy link
Contributor Author

I'm not sure if that's ok due to the fact we do versioning on the docs in branches, it breaks the links now Details check the preview first

That's true. It breaks the links indeed

Signed-off-by: PaarthAgarwal <paarth.agarwal.mec20@itbhu.ac.in>
Signed-off-by: PaarthAgarwal <paarth.agarwal.mec20@itbhu.ac.in>
@PaarthAgarwal
Copy link
Contributor Author

@OrlinVasilev @Vad1mo
I've updated the PR. Instead of modifying config.toml I've modified navbar.html and menu.html to display versions without the last ".0". Have a look
After the fix:
Screenshot from 2023-02-14 04-44-04

@Vad1mo
Copy link
Member

Vad1mo commented Feb 17, 2023

@OrlinVasilev can you take a look at it again to see if it works for you?

@OrlinVasilev
Copy link
Member

it works but it redirects to 2.7.0 again which is what we expect anyway!
Let me test a bit more ... thanks!

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.

Inaccruate link text related to harbor versions
3 participants