Open grvsachdeva opened 5 years ago
Updating Translation wikis/notes:
https://publiclab.org/wiki/translation - Updated. @jywarren I have replaced the video here as the old video was not available anymore. The current video is more like an introduction to Transifex so if you want I can record a video of translation activity with Public Lab as an example? or, check out https://www.youtube.com/user/TransifexInc/feed and suggest a video which seems relevant.
The second page is https://publiclab.org/notes/liz/10-26-2016/how-to-join-public-lab-s-transifex-project a note written by @ebarry. I have some improvements in mind for that. Can I edit that note?
Thanks!
hi @gauravano i have made you a co-author of that note, please edit as you see fit! Thanks!
Thanks, @ebarry !!
Hey @publiclab/community-reps, I have did some changes to Language dropdown and also added new languages, check it out :point_down:
What do you think about this design? If you like it, I will update the feature. Thanks!
i like it, and look forward to a future moment when we make the language option more visible :)
I am thinking of an enhancement -- Suppose a user browses a website from China then using their location we can show this language menu to them in the notice or somewhere at top of the website? What do you think @jywarren @ebarry?
Also, I have updated https://publiclab.org/notes/liz/10-26-2016/how-to-join-public-lab-s-transifex-project note with the latest screenshots.
@ebarry there are some more research notes tagged translation
. I will go through all of them and so want to ask can I update wherever necessary? you don't have to go through the trouble of making me co-author at all of them as I already have admin privileges so can edit those notes, but just want to ask a would that be fine with you? Thanks!!
Are the dropdown changes in a feature, and do they need to be added to the live site? Cool!
One thing if you haven't already, is to clearly show people how to enable the "see translation prompts everywhere" setting -- which, ok it was a while ago -- i think was driven from a profile tag? We could advertise this and get some language growth going, then consider switching it from an opt-in to an opt-out to see it really grow?
Are the dropdown changes in a feature, and do they need to be added to the live site? Cool!
yes! Here's the gist - https://gist.github.com/gauravano/1124fff46ae156537e6fb712bff9e980
@jywarren yes, currently profile tag enables the translation prompts. Yes, I am thinking of writing a note. What do you think? For making it easy to enable translation prompts, we can add a button on the profile page or somewhere else?
Thanks!
So, with the right profile tag, should I be seeing the prompts on every page?
On Thu, May 30, 2019 at 5:16 PM Jeffrey Warren jeff@unterbahn.com wrote:
Footer updated! Wow!
On Thu, May 30, 2019 at 5:15 PM Jeffrey Warren jeff@unterbahn.com wrote:
sure, yeah! Also, the "people" grid feature on this page could be used to prompt people to add that profile tag to themselves:
[people:PROFILETAGNAME]
https://publiclab.org/wiki/education#Education+group
On Thu, May 30, 2019 at 5:02 PM Gaurav Sachdeva notifications@github.com wrote:
Are the dropdown changes in a feature, and do they need to be added to the live site? Cool!
yes! Here's the gist - https://gist.github.com/gauravano/1124fff46ae156537e6fb712bff9e980
@jywarren https://github.com/jywarren yes, currently profile tag enables the translation prompts. Yes, I am thinking of writing a note. What do you think? For making it easy to enable translation prompts, we can add a button on the profile page or somewhere else?
Thanks!
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/publiclab/plots2/issues/5737?email_source=notifications&email_token=AAAF6J56C3G4BOK3F4DH5HDPYA6FLA5CNFSM4HN3CFMKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWTQJKQ#issuecomment-497484970, or mute the thread https://github.com/notifications/unsubscribe-auth/AAAF6J5INAMAFBZUP5AFH4TPYA6FLANCNFSM4HN3CFMA .
Footer updated! Wow!
On Thu, May 30, 2019 at 5:15 PM Jeffrey Warren jeff@unterbahn.com wrote:
sure, yeah! Also, the "people" grid feature on this page could be used to prompt people to add that profile tag to themselves:
[people:PROFILETAGNAME]
https://publiclab.org/wiki/education#Education+group
On Thu, May 30, 2019 at 5:02 PM Gaurav Sachdeva notifications@github.com wrote:
Are the dropdown changes in a feature, and do they need to be added to the live site? Cool!
yes! Here's the gist - https://gist.github.com/gauravano/1124fff46ae156537e6fb712bff9e980
@jywarren https://github.com/jywarren yes, currently profile tag enables the translation prompts. Yes, I am thinking of writing a note. What do you think? For making it easy to enable translation prompts, we can add a button on the profile page or somewhere else?
Thanks!
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/publiclab/plots2/issues/5737?email_source=notifications&email_token=AAAF6J56C3G4BOK3F4DH5HDPYA6FLA5CNFSM4HN3CFMKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWTQJKQ#issuecomment-497484970, or mute the thread https://github.com/notifications/unsubscribe-auth/AAAF6J5INAMAFBZUP5AFH4TPYA6FLANCNFSM4HN3CFMA .
sure, yeah! Also, the "people" grid feature on this page could be used to prompt people to add that profile tag to themselves:
[people:PROFILETAGNAME]
https://publiclab.org/wiki/education#Education+group
On Thu, May 30, 2019 at 5:02 PM Gaurav Sachdeva notifications@github.com wrote:
Are the dropdown changes in a feature, and do they need to be added to the live site? Cool!
yes! Here's the gist - https://gist.github.com/gauravano/1124fff46ae156537e6fb712bff9e980
@jywarren https://github.com/jywarren yes, currently profile tag enables the translation prompts. Yes, I am thinking of writing a note. What do you think? For making it easy to enable translation prompts, we can add a button on the profile page or somewhere else?
Thanks!
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/publiclab/plots2/issues/5737?email_source=notifications&email_token=AAAF6J56C3G4BOK3F4DH5HDPYA6FLA5CNFSM4HN3CFMKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWTQJKQ#issuecomment-497484970, or mute the thread https://github.com/notifications/unsubscribe-auth/AAAF6J5INAMAFBZUP5AFH4TPYA6FLANCNFSM4HN3CFMA .
So, with the right profile tag, should I be seeing the prompts on every page?
Only on pages where I replaced default t
helper with custom translation
helper like this https://github.com/publiclab/plots2/blob/master/app/views/dashboard/dashboard.html.erb#L47 . I will document it and some more things today.
sure, yeah! Also, the "people" grid feature on this page could be used to prompt people to add that profile tag to themselves:
@jywarren you added such button here - https://publiclab.org/wiki/translation a month ago. Should we add it to more pages?
LOL omg i totally did. So, no problem.
Ah ok re: t vs. translation -- are we going to roll this out across all templates on a schedule? Thanks, sorry i was out of sync with you and even myself :-P
On Fri, May 31, 2019 at 4:49 AM Gaurav Sachdeva notifications@github.com wrote:
So, with the right profile tag, should I be seeing the prompts on every page?
Only on pages where I replaced default t helper with custom translation helper like this https://github.com/publiclab/plots2/blob/master/app/views/dashboard/dashboard.html.erb#L47 . I will document it and some more things today.
sure, yeah! Also, the "people" grid feature on this page could be used to prompt people to add that profile tag to themselves:
@jywarren https://github.com/jywarren you added such button here - https://publiclab.org/wiki/translation a month ago. Should we add it to more pages?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/publiclab/plots2/issues/5737?email_source=notifications&email_token=AAAF6JYVHDYGKAGYRBFP4VTPYDQ75A5CNFSM4HN3CFMKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWUT4IQ#issuecomment-497630754, or mute the thread https://github.com/notifications/unsubscribe-auth/AAAF6JZERM5OIGHZ6ZXMKPDPYDQ75ANCNFSM4HN3CFMA .
We need to change t
to raw translation
in views. We can do it wherever we want. Currently, they are on /blog, /dashboard and /subscriptions. I can add them everywhere. What do you think about that?
Thanks!
Yes, let's do the t
to translation
conversion now, I'm pretty happy with how this is working, and people can turn it on and off via profile tags anyways! Thanks, this is AWESOME Gaurav!
I am thinking of an enhancement -- Suppose a user browses a website from China then using their location we can show this language menu to them in the notice or somewhere at top of the website? What do you think @jywarren @ebarry?
I think this sounds good but i think we can detect the languages settings of the user's browser, rather than guessing based on location. That way if someone doesn't speak one of the primary languages of a country their browser settings will still try to show them the site in that language.
Sure, headers are always helpful (and resourceful :sweat_smile: ). I will start on this enhancement after updating the notes/wikis related to translation. @jywarren @ebarry so can I go ahead and update the research notes- https://publiclab.org/tag/translation using my admin privileges?
Yes please go ahead! You can add yourself as co-author too!
On Mon, Jun 3, 2019, 7:23 PM Gaurav Sachdeva notifications@github.com wrote:
Sure, headers are always helpful. I will start on this enhancement after updating the notes/wikis related to translation. @jywarren https://github.com/jywarren @ebarry https://github.com/ebarry so can I go ahead and update the research notes using my admin privileges?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/publiclab/plots2/issues/5737?email_source=notifications&email_token=AAAF6J7VKIXMQXSWX7TABFLPYWRV7A5CNFSM4HN3CFMKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODW26XTI#issuecomment-498461645, or mute the thread https://github.com/notifications/unsubscribe-auth/AAAF6JYNEYDRWN5TWJVYIB3PYWRV7ANCNFSM4HN3CFMA .
Thanks, @jywarren for confirming! Also, don't you think what I am currently doing is somewhat similar to @steviepubliclab's note - https://publiclab.org/notes/stevie/05-24-2019/idea-to-distribute-tasks-for-a-reserach-area-review. But, I think, it'll cover only wikis but if that covers research notes too, then co-authors would be added or the reviewers need to be given admin privileges :thinking:.
Will update in 2 days and then throw final documentation for pushing and pulling translations and helper methods.
Huh yes it is related! Ok, awesome.
On Tue, Jun 4, 2019, 6:56 PM Gaurav Sachdeva notifications@github.com wrote:
Thanks, @jywarren https://github.com/jywarren for confirming! Also, don't you think what I am currently doing is somewhat similar to @steviepubliclab https://github.com/steviepubliclab's note - https://publiclab.org/notes/stevie/05-24-2019/idea-to-distribute-tasks-for-a-reserach-area-review. But, I think, it'll cover only wikis but if that covers research notes too, then co-authors would be added or the reviewers need to be given admin privileges 🤔.
Will update in 2 days and then throw final documentation for pushing and pulling translations and helper methods.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/publiclab/plots2/issues/5737?email_source=notifications&email_token=AAAF6J46SLBKE2XAJK3MGVDPY3XH3A5CNFSM4HN3CFMKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODW6DEKY#issuecomment-498872875, or mute the thread https://github.com/notifications/unsubscribe-auth/AAAF6JZVPCWKWSSLPPJEESLPY3XH3ANCNFSM4HN3CFMA .
Ok just confirming that any t(...)
can be replaced with a new, special translations(...)
method in Ruby, as in this comment by @gauravano?
If so, @publiclab/gci I think this would make a lot of really nice GCI tasks!
Finding instances of the old t() method is a little harder than I thought, as the GitHub search doesn't work, so I think a "grep" based search in Linux would work but it's not as easy to do:
grep -r "t(" app/views
It should return lines like this one!
I am having success in Visual Basic Code by searching for \st\(
- space t (
Ok just confirming that any t(...) can be replaced with a new, special translations(...) method in Ruby, as in this comment by @gauravano?
Hi @jywarren @nstjean, yeah, t(..)
can be replaced by translation(...)
. The code for translation is in helpers/application_helper.rb
.
NOTE: After replacing, testing that view is necessary as it may not work for complex blocks like div, span, etc.
And, if corner cases need to be handled, then one can change the helper definition.
All the instances can be found from RubyMine too or any editor as @nstjean also mentioned an example. I will say, create a list of files here as a checklist and then create issues so as to have no confusion or duplicate issues.
Thanks!
Hi, I'm thinking we should create fall-back text in this prompt as well, and finish documentation (I've started here: https://github.com/publiclab/plots2/blob/master/README.md#internationalization)
For new strings, we could, if there is no text yet available, offer this syntax:
translate('dashboard.post_content', { fallback: "Post some content" }
We are currently passing :fallback
into the t()
helper. What does that do? I don't see it documented here: https://guides.rubyonrails.org/i18n.html#adding-translations
Here's the list of remaining tasks of Translation project:
cc @jywarren