37 Commits

Author SHA1 Message Date
softsimon
b6052563c3 Merge pull request #792 from mempool/i18n/add-macedonian
Add new locale: Macedonian (mk)
2021-09-17 13:54:03 +04:00
wiz
d63e4f878a Add new locale: Macedonian (mk) 2021-09-17 15:03:52 +09:00
wiz
0e508e6b0f Add new locale: Romanian (ro) 2021-09-17 15:02:15 +09:00
wiz
7082eea4be Enable 'ca' locale for Catalan 2021-08-08 01:05:42 +09:00
wiz
2799ebaf90 Update nginx configuration for cache settings and new locales
* Consolidates add_header statements into single top-level section
* Updates locales to match frontend/src/app/app.constants.ts
* Re-orders locales to match locale selector for easier checking
2021-07-19 18:36:13 +09:00
wiz
1818d16ead Enable i18n locale for Russian (ru) 2021-06-13 15:05:21 -05:00
wiz
4518d1ead3 Disable caching of electrs endpoints in production/nginx.conf 2021-05-06 21:20:13 +09:00
wiz
109c652dd0 Enable i18n for Polish language 2021-04-26 05:43:47 +09:00
softsimon
7c74440c00 Adding Hebrew language 2021-02-25 17:16:22 +07:00
wiz
99eedf106f Improve production high availability using structured failover and cache 2021-02-23 13:33:52 +09:00
wiz
9c1cd1cf4d Update nginx and mempool backend configuration for active failover HA 2021-02-22 20:22:38 +09:00
wiz
f9d71aca39 Update nginx.conf for signet, services, and disable SSR for now 2021-02-21 03:39:19 +09:00
wiz
da2f9aa80d Fix production nginx.conf and backend config to always use unique ports 2021-01-31 01:16:32 +09:00
wiz
c13d128d9c Configure production backends and nginx for high availability electrs 2021-01-30 23:01:01 +09:00
softsimon
02c4ad2688 Adding Italian language. Updating nginx conf with some missing languages. 2021-01-27 20:24:32 +07:00
softsimon
6e5404f2a3 Adding hungarian language. 2021-01-24 04:19:50 +07:00
wiz
b170df0dfc Enable 'ka' locale for Georgian 2020-12-07 00:20:05 +09:00
wiz
384b541a3d Enable 'ar' locale for Arabic 2020-12-04 04:11:14 +09:00
wiz
e4b5305936 Enable locale 'vi' for Vietnamese 2020-12-03 10:16:02 +09:00
wiz
ee49b911cb Change nginx.conf Tor HS port from 81 to 80 to fix i18n bug 2020-12-03 09:56:29 +09:00
wiz
2b8ef7a13a Exempt localhost from nginx rate limits for Tor and AU usage 2020-12-03 09:47:39 +09:00
wiz
1898dba1fc Update list of supported locales 2020-12-02 21:33:53 +09:00
wiz
46ad261d84 Implement i18n support in frontend using Angular + Transifex + NGINX
This PR adds basic i18n support into the mempool frontend, together with
a smooth workflow for developers and translators to collaborate:

* Using the existing @angular/localize module, developers add i18n
metadata to any frontend strings their new features or changes modify

* Using the new npm script `i18n-extract-from-source`, developers
extract the i18n data from source code into `src/locale/messages.xlf`

* After pushing the updated `src/locale/messages.xlf` to GitHub, the
Transifex service will update its database from the new source data

* Using the Transifex website UI, translators can work together to
translate all the mempool frontend strings into their native languages

* Using the new npm script `i18n-pull-from-transifex`, developers can
pull in completed translations from Transifex, and commit them into git.

This flow requires an API key from Transifex, which can be obtained at
https://www.transifex.com/user/settings/api/ to be used with the python
script installed by `pip install transifex-client` - after preparing
these, run the npm script which will ask you for the API key the first
time. When downloading is complete, you can test building the frontend,
and if successful, commit the new strings files into git.

This PR implements a new locale selector in the footer of the homepage
dashboard, and includes WIP translations for the following languages:

* Czech (cs)
* German (de)
* Japanese (ja)
* Norwegian (nn)
* Spanish (es)
* Swedish (sv)
* Ukrainian (uk)
* Persian (fa)
* Portugese (pt)
* Turkish (tr)
* Dutch (nl)
* French (fr)
* Chinese (zh)
* Slovenian (sl)
* Korean (ko)
* Polish (pl)

The user-agent's `Accept-Language` header is used to automatically
detect their preferred language, which can be manually overriden by the
pull-down selector, which saves their preference to a cookie, which is
used by nginx to serve the correct HTML bundle to the user.

Remaining tasks include adding i18n metadata for strings in the Bisq and
Liquid frontend code, mouseover hover tooltip strings, hard-coded og
metadata inside HTML templates, and many other places. This will be done
in a separate PR.

When upgrading to add i18n support, mempool instance operators must take
care to install the new nginx.conf and nginx-mempool.conf files, and
tweak for their specific site configuration.

Fixes #81
2020-12-02 04:19:33 +09:00
wiz
2ccd218c00 Fix nginx.conf reverse proxy cache URL path for sponsor images 2020-11-16 00:43:10 +09:00
wiz
22cece394c Enable nginx reverse proxy cache for sponsor profile images + misc tweaks 2020-11-06 14:09:04 +09:00
wiz
3eac6b8996 Don't rate limit /api/v1/donations URL prefix for sponsor photos 2020-10-19 20:56:46 +09:00
wiz
615abe0c60 Route /api and /<network/api URLs to HTML for API documentation 2020-10-18 13:11:02 +09:00
wiz
539eb60afb Update production nginx.conf and mempool-config.json for Bisq Markets API 2020-09-23 19:39:46 +09:00
wiz
b58726f153 Update production nginx.conf with performance tuning and rate limiting 2020-09-10 14:39:04 +09:00
wiz
52d7d7f564 Add bisq websocket proxy in production nginx.conf 2020-07-26 00:03:30 +09:00
wiz
0e3de8b75f Add production 4th instance for bisq backend 2020-07-24 21:53:57 +09:00
wiz
b113c5e10c Add proxy_pass with rewrite for /bisq/api into nginx.conf 2020-07-18 21:07:36 +09:00
wiz
e25ca3cbc5 Rename API endpoints in frontend and nginx.conf to match blockstream 2020-07-06 00:15:16 +09:00
wiz
adb392b9d1 Add HTTP Link: header for canonical URL reference to mempool.space 2020-07-05 16:34:26 +09:00
wiz
f718231c33 Fix HTTP content-security-policy header typo 2020-07-04 18:00:41 +09:00
wiz
5f2a0a1dda Add HTTP security headers to production nginx.conf 2020-07-04 17:57:26 +09:00
wiz
2e3ff685f8 Update misc files used for mempool.space production website 2020-05-25 18:42:00 +09:00