Repository navigation
feat: add translation to "Functions" - #57
Conversation
✅ Deploy Preview for typst-docs-web ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
3w36zj6
left a comment
There was a problem hiding this comment.
LGTM, thanks! Just please apply the Biome suggestions.
@YDX-2147483647 @typst-community/jp Could you take a quick look to see if you have any concerns?
There was a problem hiding this comment.
Pull request overview
Adds a missing i18n key for the “Functions” section header and switches the GroupTemplate heading to use translations, ensuring the label is localized in all currently supported languages.
Changes:
- Add
"functions"toTranslationComponentKey. - Add
"functions"translations inen-US,ja-JP, andzh-Hans. - Replace the hardcoded “Function” heading in
GroupTemplatewith<Translation translationKey="functions" />.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/translation/index.tsx | Adds "functions" to the allowed translation keys so it can be used by components safely. |
| src/translation/en-US.tsx | Implements the "functions" translation string for English. |
| src/translation/ja-JP.tsx | Implements the "functions" translation string for Japanese. |
| src/translation/zh-Hans.tsx | Implements the "functions" translation string for Simplified Chinese. |
| src/components/templates/GroupTemplate.tsx | Uses the new translation key for the functions section heading instead of hardcoded English text. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
YDX-2147483647
left a comment
There was a problem hiding this comment.
Thanks for your contribution!
I've resolved the format error, and everything else looks fine.
The Functions heading doesn't have a tooltip. I find this a bit strange, but the upstream doesn't have it either (even in the latest typst/typst#8138). So no action is needed.
|
Dear @3w36zj6 and @YDX-2147483647 , Thank you for your review! Sincerely, with love to Typst, |
Hello,
I am a new contributor to the translation project of Typst document in Japanese.
I recently found a missing translation for the word "Function".
In this pull request, I added the translation support to the word "Function" in all supported languages.
If this missng translation is intentional, please discard this change.
I am thrilled to contribute to my favourite text compiler, Typst!
Sincerely,
Itsuki Kigoshi
Issue
Change
English (Code)
Japanese (Code)
Simplified Chinese (Code)
Preview
(Example in Japanese)