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

Add language switcher and translations #617

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

melissawm
Copy link
Member

This is work in progress, as the Crowdin synchronization still needs to be set up before merging. However, you can test the switcher locally (which is why I added a copy of the website under the pt folder - this will be replaced by the actual translations once that work is finalized).

Addresses #582

Copy link

netlify bot commented Mar 11, 2025

Deploy Preview for scipy-org ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 2e9df36
🔍 Latest deploy log https://app.netlify.com/sites/scipy-org/deploys/67ec32ca8ecb3300083f9a9a
😎 Deploy Preview https://deploy-preview-617--scipy-org.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 100
Accessibility: 100
Best Practices: 100
SEO: 82
PWA: -
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Contributor

@tylerjereddy tylerjereddy left a comment

Choose a reason for hiding this comment

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

Melissa asked me to poke around on this branch a bit locally. After dealing with some issues installing Dart Sass (which is also needed on main it seems), the result for this branch of make html followed by make serve does indeed display the version switcher in top right locally:

image

For the most part using the switcher will swap languages and preserve the page you are navigated to when it does. One exception I noticed was that while on the "Installation" page, if you select a non-default tab like "package manager," it will always reset to the default/landing "project based" tab if you swap languages. That's pretty minor though.

Anyway, that's my initial check, hope it helps, let me know if you need anything else probed.

I don't have much to say about the infrastructure/Crowdin/auto-syncing--I'm not familiar with how that works.

alt = 'Avatar of Nick ODell'
{{< /image >}}
Nick ODell'''
link = 'https://github.com/nickodell'
Copy link
Contributor

Choose a reason for hiding this comment

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

I think Nick recently (last 1-2 days) accepted maintainer status.
I guess that would need to be updated on main and then propagated to the language-specific versions, or something like that?

Copy link
Member Author

Choose a reason for hiding this comment

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

That's right, we'll make sure to keep it up to date. The sync automation is still a bit wonky but we're working on it.

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.

2 participants