Giter Site home page Giter Site logo

Comments (13)

jedfonner avatar jedfonner commented on August 16, 2024 3

I submitted a Feature Suggestion: Include user's language in body of outgoing slash command request. Please add your vote to this to encourage Mattermost to take it into consideration.

from mattermostonfire.

jedfonner avatar jedfonner commented on August 16, 2024 2

Great idea. I'm a little stumped on how to get the user's locale from the request. AFAIK Mattermost does not send it in the initial request to create the poll. So I'm not sure I can make the i18n dynamic.

I will work on moving the text into a separate json map using ICU Message syntax. Best case we can figure out how to dynamically pull the right text. Worst case I can add instructions to define the locale as an environment variable.

from mattermostonfire.

jedfonner avatar jedfonner commented on August 16, 2024 2

I've created a branch with basic support for specifying a language as an environment config.

However now I need help with the actual translations. Anyone available to help translate in German, French, etc before I merge it into master?

from mattermostonfire.

jedfonner avatar jedfonner commented on August 16, 2024 2

@DarckCrystale and elpatron68 - you guys rock! Thanks so much. I just merged your PRs into my initial PR and merged all of it to master.

from mattermostonfire.

elpatron68 avatar elpatron68 commented on August 16, 2024 1

The easiest way is to edit https://github.com/jedfonner/MattermostOnFire/blob/i18next/functions/translations.json and provide it as Gist (https://gist.github.com/) or at Pastebin.

Otherwise, you could clone this repository, checkout the i18next branch, make your changes, commit them and create a pull request.

from mattermostonfire.

LucileDT avatar LucileDT commented on August 16, 2024

As a French, I can say we have some French people who would be happy to have the poll tool in French too! So I think that it would be better if the project was prepared to support multiple languages and then set up something like https://crowdin.com to allow non tech people to translate it in their own language (Crowdin is used for Open Broadcaster Software, I have an account on it and it's pretty easy to use, easier than make a ton of pull requests).

from mattermostonfire.

DarckCrystale avatar DarckCrystale commented on August 16, 2024

@jedfonner did you contact the Mattermost dev team to ask them?

from mattermostonfire.

elpatron68 avatar elpatron68 commented on August 16, 2024

Thanks! I will translate to german.

from mattermostonfire.

DarckCrystale avatar DarckCrystale commented on August 16, 2024

I can translate to French if needed and if "how to do" is explained :)

from mattermostonfire.

DarckCrystale avatar DarckCrystale commented on August 16, 2024

Thanks!

from mattermostonfire.

DarckCrystale avatar DarckCrystale commented on August 16, 2024

Done for me and pull request submitted :)

from mattermostonfire.

elpatron68 avatar elpatron68 commented on August 16, 2024

Just one last question: Updating a running installation to support i18n is the same way than deploying a fresh one?

from mattermostonfire.

jedfonner avatar jedfonner commented on August 16, 2024

@elpatron68 Pretty much. Update your local working directory to the latest code, then set your mattermost.language environment variable as explained in the new Readme section, and then run firebase deploy (luckily it's all JavaScript so nothing to build locally!)

from mattermostonfire.

Related Issues (5)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.