biomejs / biome

A toolchain for web projects, aimed to provide functionalities to maintain them. Biome offers formatter and linter, usable via CLI and LSP.
https://biomejs.dev
Apache License 2.0
14.3k stars 443 forks source link

☂️ Translate the website in Japanese 🇯🇵 #880

Closed ematipico closed 9 months ago

ematipico commented 10 months ago

Coordination issue for translating the website in Japanese.

Upon more studying, I think we can push the changes directly to main.

Our documentation uses Starlight, and that's how we can enable i18n: https://starlight.astro.build/guides/i18n/

My advice is to take charge of one page at the time.

I leave the task/coordination/help in the capable hands of @nissy-dev @unvalley and @TaKO8Ki !

kevinwolfcr commented 9 months ago

@ematipico any plans to translate to Spanish? I could help on that.

TaKO8Ki commented 9 months ago

@chansuke I've assigned you :)

ematipico commented 9 months ago

@ematipico any plans to translate to Spanish? I could help on that.

You can open a GitHub discussion, and start the conversation there, so we can understand what that means for the project. Let's keep this issue only for coordinating among translators

unvalley commented 9 months ago

Anyone interested in introducing textlint? It helps us to providing polished translation. We can discuss specific textlint rules or plugins on the PR will be created for.

yossydev commented 9 months ago

@unvalley

Anyone interested in introducing textlint? It helps us to providing polished translation. We can discuss specific textlint rules or plugins on the PR will be created for.

I'm insanely interested!

Yuiki commented 9 months ago

@nissy-dev We have a task labeled Translate Starlight's UI on our list. However, since Startlight already offers Japanese default UI strings, I think we don't need to translate those. What do you think?

Naoto-Ida commented 9 months ago

Anything unassigned that I can pick up? It seems like I was late to the party, with the list being full of assignees. Would be happy to give back for all the awesomeness this tool offers!

ematipico commented 9 months ago

Actually, here's something interesting that we should implement. At the moment our lint rule pages are generated from source: for example the documentation of this page https://biomejs.dev/linter/rules/no-debugger/ is generated from

https://github.com/biomejs/biome/blob/01309e8c837bf1147ac8a29cb185065bd331f3fc/crates/biome_js_analyze/src/analyzers/suspicious/no_debugger.rs#L12-L28

Ideally, we could come up with a long-term solution, where people can add new translations (e.g. Japanese, Spanish, etc.). This means that we have to come up with some, here's an example:


declare_rule! {
    /// Disallow the use of `debugger`
    ///
    /// ```md,jp
    ///  <TRANSLATED CONTENT HERE> 
    /// ```
    /// ## Examples
    ///
    /// ### Invalid
    ///
    /// ```js,expect_diagnostic
    /// debugger;
    /// ```
    ///
    /// ### Valid
    ///
    /// ```js
    /// const test = { debugger: 1 };
    /// test.debugger;
    ///```
    pub(crate) NoDebugger {
        version: "1.0.0",
        name: "noDebugger",
        recommended: true,
        fix_kind: FixKind::Unsafe,
    }
}

Then, we will have to update https://github.com/biomejs/biome/blob/main/xtask/lintdoc/src/main.rs to:

nissy-dev commented 9 months ago

@Yuiki

We have a task labeled Translate Starlight's UI on our list. However, since Startlight already offers Japanese default UI strings, I think we don't need to translate those. What do you think?

Thank you for pointing out! I removed the task.

nissy-dev commented 9 months ago

@Naoto-Ida

Anything unassigned that I can pick up? It seems like I was late to the party, with the list being full of assignees. Would be happy to give back for all the awesomeness this tool offers!

Thanks! We have two options.

If you would like to contribute, please let me know what you would like to do.

nissy-dev commented 9 months ago

@ematipico Thanks for comments on translating lint rules!

In this issue, we have excluded automatically generated docs from the scope due to our maintainer's burden. There are several reasons.

I think we can discuss whether to translate automatically generated documents in another issue after the this issue is over.

yossydev commented 9 months ago

@nissy-dev @unvalley Thanks for your time! Regarding textlint, am I correct in assuming that you have specific rules in place and that you will issue a PR when it is ready to be configured? :eyes:.

nissy-dev commented 9 months ago

@yossydev Thank you for your interest in introducing textlint rules!

I would like you to select rules that are considered useful for translation and introduce textlint (and if possible, configure CI, etc.). When doing this, we recommend checking the settings of several OSS translation projects.

yossydev commented 9 months ago

@nissy-dev Yes sir! Thank you! I will set up the necessary rules and CIs and send out a PR!

yossydev commented 9 months ago

@nissy-dev The link to Biome Blog, currently on the top page (https://biomejs.dev/ja), is now https://biomejs.dev/ja/blog. It just doesn't seem to exist yet, so I'm getting a 404 error. Should I modify it so that it transitions once to https://biomejs.dev/blog?

nissy-dev commented 9 months ago

@yossydev Hmm, I don't think this redirect is wrong.This problem seems to be resolved by placing blog/index.mdx in ja docs.

And then, I think the problem is that the 404 feedback is not enough. The 404 page was probably not working properly because it was deployed to vercel, and the translation was also interrupted. see: #954

However, since we replaced vercel with netlify just yesterday, the 404 page seems to be working properly. Therefore, it would be ideal to fix as follows.

Gumichocopengin8 commented 9 months ago

Made a PR #1010 to follow up with #954.

Gumichocopengin8 commented 9 months ago

I found a routing bug. I'm pretty sure it worked fine on Vercel, so the bug is introduced after switching to Netlify. Here's the fix #1011

yossydev commented 9 months ago

@yossydev Hmm, I don't think this redirect is wrong.This problem seems to be resolved by placing blog/index.mdx in ja docs.

And then, I think the problem is that the 404 feedback is not enough. The 404 page was probably not working properly because it was deployed to vercel, and the translation was also interrupted. see: #954

However, since we replaced vercel with netlify just yesterday, the 404 page seems to be working properly. Therefore, it would be ideal to fix as follows.

  • add blog/index.mdx in ja docs
  • translate 404.md

@nissy-dev I see! Thank you! May I tackle the problem over there myself? :eyes:

"add blog/index.mdx in ja docs" ← Regarding this, should the content remain in English?? For example, there is a blog article called Biome formatter wins the Prettier challenge, but is it okay if the title is still in English on the ja/blog page?

nissy-dev commented 9 months ago

@yossydev When I just checked, the blog directory moved and blog/index.mdx itself was removed... If it's easy to fix, I think you can change it to https://biomejs.dev/blog, but I don't think many people access the footer of the top page, so it's okay to just leave it as 404.

Gumichocopengin8 commented 9 months ago
image

Don't we wanna add other sponsors or README sponsor info is outdated?

ematipico commented 9 months ago
image

Don't we wanna add other sponsors or README sponsor info is outdated?

Only gold and platinum sponsors are featured on our website

nissy-dev commented 9 months ago

These are the remaining tasks that I have in mind

First, the translation task in https://github.com/biomejs/biome/issues/880#issuecomment-1826477936.

And tasks related to documents that have been recently updated.

I plan to close this issue as soon as I finish translating two assigned documents. Tasks related to recent updates will be created as separate issues when this issue is closed, but if someone want to start them from now, there is no problem in starting them.

Spice-Z commented 9 months ago

@nissy-dev Sorry to late ! I just created the PR for guides/integrate-in-editor.mdx.

1025

chansuke commented 9 months ago

@nissy-dev Hi, thank you for the work! Can I update formatter/index.mdx?

Update translation for formatter/index.mdx

nissy-dev commented 9 months ago

@chansuke Yes! I assigned you.

yossydev commented 9 months ago

@nissy-dev Good evening!

Translate formatter option philosophy page

Can I do this myself?

zhoujian-official commented 9 months ago

Hello, is there anyone translating blogs to Japanese? I'm trying to translate blogs to Chinese but don't know where to put it. Anyone show me an example of the Japanese blog translation please.

ematipico commented 9 months ago

@nissy-dev @zhoujian-official

I think we should not translate our blog posts. Instead, we should let the community translate the blog posts in their platforms (for example, what Sosuke Suzuki did for Prettier's blog post https://zenn.dev/sosukesuzuki/articles/e1e47e2a760e9d ) and we could promote these translations in our channels:

Here's some context about why we should do it this way: https://discord.com/channels/1132231889290285117/1138807473726300270/1181247964136615958

zhoujian-official commented 9 months ago

Sounds reasonable.

Here is my Chinese translation of the blogs:

Biome v1 : https://juejin.cn/post/7308539123538624549 Announcing Biome : https://juejin.cn/post/7308539123538608165 Biome formatter wins the Prettier challenge : https://juejin.cn/post/7308643782375768118

ematipico commented 9 months ago

That's great @zhoujian-official ! Feel free to create a PR to add those links , maybe with this markdown at the very end of the page:

## Translations

- [<TITLE IN YOUR LANGUAGE>](LINK)
nissy-dev commented 9 months ago

@ematipico

I think we should not translate our blog posts. Instead, we should let the community translate the blog posts in their platforms

Totally, I agree with your opinions! I removed the task related to blog translation from https://github.com/biomejs/biome/issues/880#issuecomment-1837311752

nissy-dev commented 9 months ago

@yossydev

Translate formatter option philosophy page Can I do this myself?

Yes, but I recommend starting after the PR has been merged.

nissy-dev commented 9 months ago

@Naturalclar Hi! How's the translation going? If you don't have time, you can also assign it to someone else.

Naturalclar commented 9 months ago

@nissy-dev sorry for the late response! :pray: I'll send a PR by end of tomorrow.

unvalley commented 9 months ago

We recently added the Formatter Option Philosophy. This is interesting part to know about biome's direction. Anyone interested in this translation?

nissy-dev commented 9 months ago

I have already assigned it to @yossydev ref: https://github.com/biomejs/biome/issues/880#issuecomment-1837311752, https://github.com/biomejs/biome/issues/880#issuecomment-1838721470

unvalley commented 9 months ago

Ah, sorry I missed that.

nissy-dev commented 9 months ago

All the originally planned translations have been completed, so I would like to close this issue. Thank you very much to everyone who helped with the translation!

ematipico commented 9 months ago

One last thing to do, I think, would be to translate the README.md :)

nissy-dev commented 9 months ago

I created the new issue https://github.com/biomejs/biome/issues/1125