thatfiredev / NotDog

The Shazam of animals. 🐶 | Sample app to demonstrate ML Kit Image Labeling
https://not-dog-io.firebaseapp.com/
MIT License
10 stars 17 forks source link

Translate to your language #8

Open thatfiredev opened 5 years ago

thatfiredev commented 5 years ago

REOPENED FOR HACKTOBERFEST 2019 ✨

~The app is currently in english only.~ I believe the app would be able to reach a wider audience if we had more languages, so EVERYONE IS WELCOME TO ADD THEIR LANGUAGE :tada: .

How to add your language

First of all, make sure you read our Contributing Guidelines and follow the steps described there to create a new branch. The modifications that you should make:

  1. Create a new directory under app/src/main/res/ named values-{code}. Here code is the two-letter ISO 639-1 language code. For example, english is en, french is fr, spanish is es. See the full list here.
  2. Copy the strings.xml file from the app/src/main/res/values directory to the directory you've recently created.
  3. Edit the copied file and replace all english text between tags with the translated version.

That's it! Commit your changes, push and send a pull request!

Example

Translating the app to portuguese:

Existing values/string.xml file:

<resources>
    <string name="app_name">Not Dog</string>
    <string name="dog">Dog</string>
    <string name="action_settings">Settings</string>
    <string name="permission_explanation">We cant see the dog if you dont allow us to use the camera</string>
</resources>

Created values-pt/string.xml file:

<resources>
    <string name="app_name">Não é um cão</string>
    <string name="dog">Cão</string>
    <string name="action_settings">Definições</string>
    <string name="permission_explanation">Não temos como ver o cão se você não der permissão para aceder a câmera.</string>
</resources>

Languages that we already have:

henriklagergren commented 5 years ago

Added swedish translation #22

davidfranquet commented 5 years ago

Added Catalan translation #33

thatfiredev commented 5 years ago

Hacktoberfest is over and now we have 20 languages on the app! :tada: THANK YOU for all of the awesome contributors!

I'm closing this issue, but translations are still welcome.

davidfranquet commented 5 years ago

Welcome!