Comments (7)
You could create a custom template https://github.com/BlinkTagInc/transit-arrivals-widget#templatepath with the translations you need
Or I could update that template file to use https://github.com/mashpie/i18n-node to support various locales so you can generate multiple copies of the widget with different translations.
from transit-departures-widget.
from transit-departures-widget.
That is excellent.
Please make a PR and add views/widget/widget_pl.pug - I'll then do some updates to make the language a configuration option.
from transit-departures-widget.
from transit-departures-widget.
Great - I accepted it.
I refactored the template code to better support multiple languages and moved some text from JS into the template to make it easier to translate. So there are some English words now in the polish template that need translating - if you'd like to do another PR with these additional translations that would be great. https://github.com/BlinkTagInc/transit-arrivals-widget/blob/master/views/widget/content/content_pl.pug
I added documentation on the README about using languageCode
parameter.
Are you using this live on any site? Can I add your agency or agencies to the list on the README? (can you send a link to where this is being used)?
Also, if you are fluent in any other languages or work with anyone else who is, PRs for additional language translations are welcome.
from transit-departures-widget.
from transit-departures-widget.
Thanks for that.
I added support for 24-hour vs 12-hour times and also updated this to be an ES module.
Try out the latest version and let me know if you see any issues or have ideas for improvement.
from transit-departures-widget.
Related Issues (6)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from transit-departures-widget.