-
Notifications
You must be signed in to change notification settings - Fork 7.6k
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 "Languages" page #1691
Add "Languages" page #1691
Conversation
Deploy preview for reactjs ready! Built with commit 7c80589 |
Wouldn't it be better to redirect to the language based on the browser one? Just a thought |
Even if we added some sort of language detection/redirect, we'd still want to offer some mechanism for manually selecting a language (not to mention the contribution links) 😄 |
</ul> | ||
|
||
<p> | ||
Don't see your language above?{' '} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd point the link to here since that's where the actual instructions are.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cool. Thanks.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @bvaughn, there's a typo in variable naming 😃
Thanks. Fixed the typo~ |
src/pages/languages.js
Outdated
<div css={{marginTop: 10}}> | ||
<a | ||
css={{ | ||
fontSize: 12, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd make this bigger, maybe 14/16px?
Oh! Should probably include english in the list :) |
Psst ~ https://es.reactjs.org/ |
code: de | ||
is_completed: false | ||
- name: Spanish | ||
translated_name: Español |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
English goes here!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could ask the translations to do it (add english and remove their language from the list) but that’s a lot of redundant effort
is_completed: false | ||
- name: Japanese | ||
translated_name: 日本語 | ||
code: ja |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Technically Japanese and Brazillian Portuguese aren’t completely ready yet so I’d change these to false for now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the threshold? I don't think they need to be "completely ready".
I guess we can bucket things into three groups:
- Completed (95%+): Show language subdomain and "contribute" links
- Partly translated (25%-95%): Show language subdomain and "contribute" links
- In-progress (< 25%): Show "contribute" links
The question is what should those thresholds be?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The “100%” is for a “core” subset of pages defined by Dan (home page, tutorial, basics, apis). For example, some of the Spanish hooks docs aren’t done yet but it”s still 100% since it finished the core. Japanese and Portuguese are at around 70% on those (Jp doesn’t have the tutorial yet). Plus, there are final tasks like checking for consistency of terminology that need to be done before marking as complete (which I’m going through with Spanish right now)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a little more information than I had before, but I think it's still a bit vague to me. Is this written down somewhere in a more objective format, that we can refer to if we need to know which bucket a given subdomain falls into?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I picked some somewhat arbitrary % thresholds for now (specified via inline comments).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@gaearon what do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At first look, I think the proposed categories are maybe too fine grained.
I don't think it's necessary (or all that helpful) to distinguish between released, complete, and complete+. I also don't really want to have to move sites around between those categories each time we make significant changes to core pages.
Similarly, I'm not sure there's much value in distinguishing between "in-progress" and lesser translated states. I think it's worth showing all translations so that we direct potential contributors to them. I think it is important to indicate "this is not done yet" so we don't get people's hopes up for nothing– but I think the current 3 enums already do this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bvaughn It wouldn't be different sections for "complete"/"complete+" stuff and we don't have to add it in now. It's morel like... giving maintainers a gold star to encourage them to go beyond the core pages of translations.
In that case I'd rather have just "released" and "in progress", without an arbitrary cut-off point. That might be the best option.
But I also want @gaearon to weigh in.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems like you two agree on the number of sections on the page but @tesseralis wants to add extra “distinguishing” marks to some translations? I’d say it’s fine to leave it out of the MVP and add a bit later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fine by me. I added the extra steps to isreactreadyyet.com since it's easier to verify those :)
I'm going to go through and setup all of the Netlify pages and subdomains now. We don't have to link to them on reactjs.org yet, but I think it's good to have them accessible for people working on the translations, and I'd like to get them out of the way in a big batch. |
complete, partially translated, and needs contributors
@bvaughn while the pace of new languages has decressed a lot, what’s the plan for setting up subdomains for any new translations? Is there going to be s plan other than ‘ping Bryan at some point’? |
Okay. I've setup the Netlify integrations and and DNS records for the 3 new active subdomains (es, ja, and pt-br). When we should we merge this? |
I've documented this process internally so hopefully other React core members can help do at least the Netlify portion of the setup. Working to expand the list of people who can also do the DNS bit. For now though, I'll have to be involved. I've added a table (to the description of this PR) that tracks that domain status for each of the languages. I'll be gradually adding them all over the next few days. |
# Status enums indicate what percentage of "core" content has been translated: | ||
# 0: Incomplete (0–49%) | ||
# 1: Partially complete (50–94%) | ||
# 2: Complete (95–100%) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
any reason we're using enums instead of strings (incomplete
partial
complete
, etc.)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because I think the meaning of string labels is ambiguous ("incomplete" and "partial" are synonymous). So I choose a numeric value that at least indicates progression (1 is more complete than 0, 2 is more complete than 1).
My gut tells me that what we have in this PR is good enough for MVP, and I have a lot of other things to work on– so unless something small and important needs tweaking, I think I'm going to let this sit until we're ready to merge it and move on to other tasks~ 😄 |
I'm turning off Cloudflare SSL protection for now in favor of using Netlify and Let's Encrypt, because Netlify will handle the auto redirect from HTTP to HTTPS that way. There may be some short disruption where HTTPS doesn't work. |
Ok. All domains should be good to go with HTTPS redirects now |
css={{ | ||
fontSize: 12, | ||
}} | ||
href={`https://github.com/reactjs/${prefix}reactjs.org/`} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe it's better to link to the progress issue for each language since it has the actual instructions for contributing.
It's going to be issue #1 for all languages (since it's auto-generated) except for Spanish, Japanese, and Simplified Chinese, for which it's #4 by a lucky coincidence.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think linking to the main repo makes more sense. The progress issue seems more transient. I think the repos should rely on something more standard (like the readme or CONTRIBUTING.md
) for guidelines rather than a specific issue.
I think i'm going to leave this as-is.
@bvaughn I think we're ready to merge this. Only outstanding tasks are:
|
Yeah, I think we're ready too– but I've been holding off on the blog post PR /pull/1721 |
Add "Languages" header link and landing page.
You can see it here.
Generating language data
To generate the YAML data, I ran the following script on isreacttranslatedyet.com:
Netlify and Cloudflare setup