Giter VIP home page Giter VIP logo

twister-html's Introduction

twister-html

HTML interface for Twister. To use it, clone this repo under ~/.twister/html like this:

git clone https://github.com/miguelfreitas/twister-html.git ~/.twister/html

Localisation

If you want a localised interface (currently available only for NL, IT, FR, DE and RU), use the experimental i18n branch:

git checkout i18n

If you want to translate it in your own language, check these instructions

Contribute

Feel free to fork and send pull requests! To make it easier for us to accept your patches, please follow the conventional GitHub workflow:

 # after forking, clone your repo
 rm -rf ~/.twister/html
 git clone [email protected]:yournickname/twister-html.git ~/.twister/html
 cd ~/.twister/html
 # CREATE A NEW BRANCH, specific to the fix you're implementing
 git checkout -b my-fix
 # ... make your changes ...
 # commit and push
 git commit -m "Fixing #1234 - bad foobarizer" && git push
 # Now open a pull request from branch my-fix to miguelfreitas:master on github.
 # Once the request is accepted, switch back to master and track upstream
 git remote add upstream https://github.com/miguelfreitas/twister-html.git # one-off setup
 git fetch upstream
 git checkout master
 git merge upstream/master # you should get a fast-forward message here
 git push

Translations

If you want to add your own translation, edit interface_localization.js like this:

  1. fork the repo, checkout i18n and create a new branch

     git clone [email protected]:yournickname/twister-html.git ~/.twister/html
     cd ~/.twister/html
     git checkout i18n
     git checkout -b Klingon
    
  2. add your language to the list of available choices. You should use your ISO code here, it should match what the browser reports. The Klingon ISO is "tlh", so:

     var knownLanguages = ["en","nl","it","fr","ru","tlh"];`
    

For multi-region languages, if you want to catch them all, use only the first half (e.g. to match it and it-ch, specify "it").

  1. add a new wordset block after existing ones

     if(preferredLanguage == "tlh"){
         polyglot.locale("tlh");
         wordset = {
             "Insults": "mu'qaD,
             ....
         }
     }
    
  2. stage all changes in file interface_localization.js

     git add interface_localization.js
    
  3. commit & push

     git commit -m "Klingon translation"
     git push   
    
  4. When opening the pull request on github, make sure you're pointing to miguelfreitas:i18n as the base, so we can merge it straight away in the right place. For any help, ping @toyg.

twister-html's People

Contributors

toyg avatar miguelfreitas avatar blocktester avatar dionyziz avatar basst85 avatar misjoinder avatar ishift avatar chrplace avatar ddorian1 avatar yourtion avatar

Watchers

 avatar

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.