reflex-dev / reflex

🕸️ Web apps in pure Python 🐍
https://reflex.dev
Apache License 2.0
19.02k stars 1.07k forks source link

Translate Documentation to Spanish #1968

Closed statick88 closed 9 months ago

statick88 commented 11 months ago

Translate documentation to Spanish Hello, my name is Diego Saavedra, I am a professor at the University of the Armed Forces ESPE in Ecuador.

I am looking for projects as an example for my students, I like this project to translate Documentation to Spanish in work teams, I don't know if someone else has already started it, if the answer is "No", I would like to know if I can start the translation of the documentation to Spanish.

Greetings,

Sincerely Diego Saavedra

picklelo commented 10 months ago

I don't think anyone has started - would welcome your contribution to translating! Are you thinking of just the README or the entire docs? We're working on moving the main website docs into this repo so it should be easier to contribute to in the future.

bryan-trz commented 10 months ago

Hi, I'm also fluent in both English and Spanish. I would love to help with this!

picklelo commented 10 months ago

@statick88 @bryan-trz a good place to start would be with the README if one of you wants to take that on!

In a couple of weeks we will have our main website docs also in the repo as markdown files, then it should be possible to work on translations for the main website.

bryan-trz commented 10 months ago

@picklelo Can I be assigned to this? I'll start on it in the meantime.

picklelo commented 9 months ago

This was added in #2028

hasansezertasan commented 7 months ago

In a couple of weeks we will have our main website docs also in the repo as markdown files, then it should be possible to work on translations for the main website.

I'm so excited for this. I'm actively contributing to the FastAPI repository for Turkish translations and, I'd like to do the same for Reflex documentations too.

picklelo commented 7 months ago

@hasansezertasan We've migrated all our docs to Markdown now, they are located here: https://github.com/reflex-dev/reflex-web/tree/main/docs

We're using a mix of Markdown / Reflex in the code for interactive docs. Soon we will move the docs from the reflex-web repo to this repo.

hasansezertasan commented 7 months ago

@hasansezertasan We've migrated all our docs to Markdown now, they are located here: https://github.com/reflex-dev/reflex-web/tree/main/docs

We're using a mix of Markdown / Reflex in the code for interactive docs. Soon we will move the docs from the reflex-web repo to this repo.

Oh, I see now. What do you think about the translation progress?

picklelo commented 7 months ago

@hasansezertasan My only concern with manual translations is how will we maintain it as we update our docs over time? How have you seen this handled in other projects?

hasansezertasan commented 7 months ago

@hasansezertasan My only concern with manual translations is how will we maintain it as we update our docs over time? How have you seen this handled in other projects?

I thought about this often while translating the FastAPI Documentation, and there is even a discussion on it (tiangolo/fastapi#10872), but there is no clear solution there. Expired (outdated) translations need to be detected and reported.

This page at FastAPI documentation doesn't have a Turkish translation at the moment: General - How To - Recipes - FastAPI, that's why you see "The current page still doesn't have a translation for this language." message. It can tell if there is a translation page or not.

I think it also should tell or highlight if the translation is up to date or not.

How do we detect it? I can think of only one solution.

A script that tracks the modification dates of the original markdown files and keeps a log for that (in JSON maybe).

And we can use that log to let people know if the current translation is up to date or not.

Consider this directory as documentation tree:

- docs
  - index.md  # Original File - Modified today
  - index.tr.md  # Turkish Translation - Modified yesterday
  - track.json

This is the example for track.json

{
    "index_tr_md": {
        "outdated": true
    }
}

This is the example for index.md:

# This is the index!

This is the example for index.tr.md

{% if index_tr_md.outdated %}
Bu sayfa güncel değil.
{% endif %}

# Bu giriş sayfasıdır.

"Bu sayfa güncel değil." means "This page is not up to date".

What I'm talking about is a rough example.

picklelo commented 7 months ago

@hasansezertasan Thanks for the response - that makes sense, it should be easy to track which files are out of date based on the git commits. Then when deploying our website we can generate a JSON similar to what you mentioned to say on the docs.

We're happy to start accepting translations with this method. We will add some guides on how to actually update the docs - we will need to do some modifications to start showing the translations on the actual website. In the next month we will be moving all the docs to this repo, so that may be a good time to restructure everything.

hasansezertasan commented 7 months ago

@hasansezertasan Thanks for the response - that makes sense, it should be easy to track which files are out of date based on the git commits. Then when deploying our website we can generate a JSON similar to what you mentioned to say on the docs.

I'm happy if I did any help 😇.

We're happy to start accepting translations with this method. We will add some guides on how to actually update the docs - we will need to do some modifications to start showing the translations on the actual website. In the next month we will be moving all the docs to this repo, so that may be a good time to restructure everything.

The method I just proposed (maybe an improved version of it)? I'm super happy now 🚀! Excited to see the workflow and the guides!

hasansezertasan commented 5 months ago

We will add some guides on how to actually update the docs - we will need to do some modifications to start showing the translations on the actual website. In the next month we will be moving all the docs to this repo, so that may be a good time to restructure everything.

Hi @picklelo, is there any progress on it?

picklelo commented 5 months ago

@hasansezertasan We've converted all our docs to markdown files in the reflex-web repo: https://github.com/reflex-dev/reflex-web/tree/main/docs

We could try to start implementing your solution on that repo!

hasansezertasan commented 3 months ago

@hasansezertasan We've converted all our docs to markdown files in the reflex-web repo: https://github.com/reflex-dev/reflex-web/tree/main/docs

Great news!

We could try to start implementing your solution on that repo!

How do we proceed? 🚀 🚀 🚀