Skip to content

Enable theme translation - #246

Merged
hugovk merged 10 commits into
python:mainfrom
StanFromIreland:localize-theme
Sep 7, 2025
Merged

Enable theme translation#246
hugovk merged 10 commits into
python:mainfrom
StanFromIreland:localize-theme

Conversation

@StanFromIreland

@StanFromIrelandStanFromIreland commented Aug 7, 2025

Copy link
Copy Markdown
Member

Adds Polish to start. Based on @rffontenelle 's pr. This does not allow for translation of the Copy button for some reason, but I think that can be left for another time.

Result:

image

📚 Documentation preview 📚: https://python-docs-theme-previews--246.org.readthedocs.build/

🇵🇱 Polish preview 🇵🇱

@StanFromIreland
StanFromIreland marked this pull request as ready for review August 7, 2025 15:12
@StanFromIreland
StanFromIreland marked this pull request as draft August 7, 2025 15:13
@StanFromIreland
StanFromIreland marked this pull request as ready for review August 7, 2025 17:19
@StanFromIrelandStanFromIreland changed the title Localize themeEnable theme translationAug 7, 2025
@rffontenellerffontenelle mentioned this pull request Aug 7, 2025
@rffontenelle

Copy link
Copy Markdown
Contributor

Thanks for fixing what was missing with the solution!

@rffontenellerffontenelle mentioned this pull request Aug 8, 2025

@m-aciekm-aciek left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Translation improvement suggestions, otherwise looks good to me 👍

Comment threadpython_docs_theme/locales/pl_PL/LC_MESSAGES/messages.po Outdated
Comment threadpython_docs_theme/locales/pl_PL/LC_MESSAGES/messages.po Outdated
Comment threadpython_docs_theme/locales/pl_PL/LC_MESSAGES/messages.po Outdated
Comment threadpython_docs_theme/locales/pl_PL/LC_MESSAGES/messages.po Outdated
Comment threadpython_docs_theme/locales/pl_PL/LC_MESSAGES/messages.po Outdated

@m-aciekm-aciek left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggestion for better portability

Comment threadpython_docs_theme/__init__.py Outdated
Co-authored-by: Maciej Olko <maciej.olko@gmail.com>
yeager added a commit to yeager/python-docs-theme that referenced this pull request Aug 29, 2025
@yeageryeager mentioned this pull request Aug 29, 2025

@hugovkhugovk left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks about right, but I'd appreciate a PR approval from a translator as well.

And we can always iterate and fix as needed after an initial release.

Comment threadbabel_runner.py Outdated
Comment threadbabel_runner.py
Comment threadpython_docs_theme/__init__.py Outdated
Comment threadpython_docs_theme/locales/pl_PL/LC_MESSAGES/messages.mo Outdated
@StanFromIreland

Copy link
Copy Markdown
MemberAuthor

Looks about right, but I'd appreciate a PR approval from a translator as well.

Maciek has already reviewed translation, see above.

Comment threadpython_docs_theme/locales/pl_PL/LC_MESSAGES/messages.po
@hugovk

Copy link
Copy Markdown
Member

Looks about right, but I'd appreciate a PR approval from a translator as well.

Maciek has already reviewed translation, see above.

Yes, but not approved.

@StanFromIreland

Copy link
Copy Markdown
MemberAuthor

In hopes of getting this in faster, I can just delete it?

Fun fact, translations of the Python docs are actually not reviewed for most languages.

@StanFromIreland

Copy link
Copy Markdown
MemberAuthor

Preview! (built with -D language='pl')

@m-aciekm-aciek left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good! Thanks

Comment thread.gitignore
Comment threadbabel_runner.py
Comment thread.gitignore
Comment threadpython_docs_theme/locales/pl_PL/LC_MESSAGES/messages.mo Outdated
@StanFromIreland

Copy link
Copy Markdown
MemberAuthor

It is no longer a follow up, it is now included in this PR!

Verified manually that the artefact has the compiled files.

@rffontenelle

Copy link
Copy Markdown
Contributor

Sweet! Was setup-python really necessary, considering that python is already included in the GH runner image?

@StanFromIreland

Copy link
Copy Markdown
MemberAuthor

It is used in all other workflows in this repository when Python is needed.

@hugovkhugovk left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks!

@hugovk
hugovk merged commit 4f43ade into python:mainSep 7, 2025
12 checks passed
@StanFromIreland
StanFromIreland deleted the localize-theme branch September 7, 2025 17:26
Sign up for freeto 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.

5 participants

@StanFromIreland@rffontenelle@hugovk@AA-Turner@m-aciek