Merge pull request #115 from MoltenCoffee/master

Localization for Dutch (Nederlands)
This commit is contained in:
Mike Cao 2020-09-08 02:51:58 -07:00 committed by GitHub
commit d1c9f78944
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 279 additions and 15 deletions

View File

@ -1,6 +1,7 @@
on:
release:
types: [published]
push:
branches:
- master
jobs:
@ -13,17 +14,29 @@ jobs:
uses: actions/checkout@v2
- name: Build PostgreSQL container image
run: docker build --build-arg DATABASE_TYPE=postgresql --tag docker.pkg.github.com/mikecao/umami/umami:postgresql-$(echo $GITHUB_SHA | head -c7) .
run: |
docker build --build-arg DATABASE_TYPE=postgresql \
--tag ghcr.io/$GITHUB_ACTOR/umami:postgresql-$(echo $GITHUB_SHA | head -c7) \
--tag ghcr.io/$GITHUB_ACTOR/umami:postgresql-latest \
.
- name: Build MySQL container image
run: docker build --build-arg DATABASE_TYPE=mysql --tag docker.pkg.github.com/mikecao/umami/umami:mysql-$(echo $GITHUB_SHA | head -c7) .
run: |
docker build --build-arg DATABASE_TYPE=mysql \
--tag ghcr.io/$GITHUB_ACTOR/umami:mysql-$(echo $GITHUB_SHA | head -c7) \
--tag ghcr.io/$GITHUB_ACTOR/umami:mysql-latest \
.
- name: Docker login
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: docker login -u mikecao -p $GITHUB_TOKEN docker.pkg.github.com
CR_PAT: ${{ secrets.CR_PAT }}
run: docker login -u $GITHUB_ACTOR -p $CR_PAT ghcr.io
- name: Push image to GitHub
run: |
docker push docker.pkg.github.com/mikecao/umami/umami:postgresql-$(echo $GITHUB_SHA | head -c7)
docker push docker.pkg.github.com/mikecao/umami/umami:mysql-$(echo $GITHUB_SHA | head -c7)
# Push each image individually, avoiding pushing to umami:latest
# as MySQL or PostgreSQL are required
docker push ghcr.io/$GITHUB_ACTOR/umami:postgresql-$(echo $GITHUB_SHA | head -c7)
docker push ghcr.io/$GITHUB_ACTOR/umami:postgresql-latest
docker push ghcr.io/$GITHUB_ACTOR/umami:mysql-$(echo $GITHUB_SHA | head -c7)
docker push ghcr.io/$GITHUB_ACTOR/umami:mysql-latest

View File

@ -60,13 +60,13 @@ The `HASH_SALT` is used to generate unique values for your installation.
### Build the application
```
```bash
npm run build
```
### Start the application
```
```bash
npm start
```
@ -78,15 +78,26 @@ or change the [port](https://nextjs.org/docs/api-reference/cli#production) to se
To build the umami container and start up a Postgres database, run:
```
```bash
docker-compose up
```
Alternatively, to pull just the Umami Docker image with PostgreSQL support:
```bash
docker pull ghcr.io/mikecao/umami:postgresql-latest
```
Or with MySQL support:
```bash
docker pull ghcr.io/mikecao/umami:mysql-latest
```
## Getting updates
To get the latest features, simply do a pull, install any new dependencies, and rebuild:
```
```bash
git pull
npm install
npm run build

View File

@ -2,7 +2,7 @@
version: '3'
services:
umami:
build: .
image: ghcr.io/mikecao/umami:postgresql-latest
ports:
- "3000:3000"
environment:

236
lang/nl-NL.json Normal file
View File

@ -0,0 +1,236 @@
{
"active-users.message": {
"defaultMessage": "{x} actieve {x, plural, one {bezoeker} other {bezoekers}}"
},
"button.add-account": {
"defaultMessage": "Account toevoegen"
},
"button.add-website": {
"defaultMessage": "Website toevoegen"
},
"button.back": {
"defaultMessage": "Terug"
},
"button.cancel": {
"defaultMessage": "Annuleren"
},
"button.change-password": {
"defaultMessage": "Wachtwoord wijzigen"
},
"button.copy-to-clipboard": {
"defaultMessage": "Kopiëer naar klembord"
},
"button.delete": {
"defaultMessage": "Verwijderen"
},
"button.edit": {
"defaultMessage": "Bewerken"
},
"button.login": {
"defaultMessage": "Inloggen"
},
"button.more": {
"defaultMessage": "Toon meer"
},
"button.save": {
"defaultMessage": "Opslaan"
},
"button.view-details": {
"defaultMessage": "Meer details"
},
"footer.powered-by": {
"defaultMessage": "mogelijk gemaakt door"
},
"header.nav.dashboard": {
"defaultMessage": "Dashboard"
},
"header.nav.settings": {
"defaultMessage": "Instellingen"
},
"label.adminsitrator": {
"defaultMessage": "Administrator"
},
"label.confirm-password": {
"defaultMessage": "Wachtwoord bevestigen"
},
"label.current-password": {
"defaultMessage": "Huidig wachtwoord"
},
"label.domain": {
"defaultMessage": "Domein"
},
"label.enable-share-url": {
"defaultMessage": "Sta delen via openbare URL toe"
},
"label.invalid": {
"defaultMessage": "Ongeldig"
},
"label.invalid-domain": {
"defaultMessage": "Ongeldig domein"
},
"label.last-days": {
"defaultMessage": "Laatste {x} dagen"
},
"label.last-hours": {
"defaultMessage": "Laatste {x} uur"
},
"label.logged-in-as": {
"defaultMessage": "Ingelogd als {username}"
},
"label.logout": {
"defaultMessage": "Uitloggen"
},
"label.name": {
"defaultMessage": "Naam"
},
"label.new-password": {
"defaultMessage": "Nieuw wachtwoord"
},
"label.password": {
"defaultMessage": "Wachtwoord"
},
"label.passwords-dont-match": {
"defaultMessage": "Wachtwoorden komen niet overeen"
},
"label.required": {
"defaultMessage": "Verplicht"
},
"label.this-month": {
"defaultMessage": "Deze maand"
},
"label.this-week": {
"defaultMessage": "Deze week"
},
"label.this-year": {
"defaultMessage": "Dit jaar"
},
"label.today": {
"defaultMessage": "Vandaag"
},
"label.username": {
"defaultMessage": "Gebruikersnaam"
},
"message.confirm-delete": {
"defaultMessage": "Weet je zeker dat je {target} wilt verwijderen?"
},
"message.copied": {
"defaultMessage": "Gekopiëerd!"
},
"message.delete-warning": {
"defaultMessage": "Alle verwante gegezens zullen ook verwijderd worden."
},
"message.failure": {
"defaultMessage": "Er is iets misgegaan."
},
"message.incorrect-username-password": {
"defaultMessage": "Incorrecte gebruikersnaam/wachtwoord."
},
"message.save-success": {
"defaultMessage": "Opslaan succesvol."
},
"message.share-url": {
"defaultMessage": "Met deze URL kan {target} openbaar gedeeld worden."
},
"message.track-stats": {
"defaultMessage": "Om statistieken voor {target} bij te houden, plaats je de volgende code in het {head} gedeelte van je website."
},
"message.type-delete": {
"defaultMessage": "Type {delete} in onderstaande veld om dit te bevestigen."
},
"metrics.actions": {
"defaultMessage": "Acties"
},
"metrics.average-visit-time": {
"defaultMessage": "Gemiddelde bezoektijd"
},
"metrics.bounce-rate": {
"defaultMessage": "Bouncepercentage"
},
"metrics.browsers": {
"defaultMessage": "Browsers"
},
"metrics.countries": {
"defaultMessage": "Landen"
},
"metrics.devices": {
"defaultMessage": "Apparaten"
},
"metrics.events": {
"defaultMessage": "Gebeurtenissen"
},
"metrics.filter.combined": {
"defaultMessage": "Gecombineerd"
},
"metrics.filter.domain-only": {
"defaultMessage": "Alleen domein"
},
"metrics.filter.raw": {
"defaultMessage": "Ruw"
},
"metrics.operating-system": {
"defaultMessage": "Besturingssystem"
},
"metrics.page-views": {
"defaultMessage": "Paginaweergaven"
},
"metrics.pages": {
"defaultMessage": "Pagina's"
},
"metrics.referrers": {
"defaultMessage": "Verwijzers"
},
"metrics.unique-visitors": {
"defaultMessage": "Unieke bezoekers"
},
"metrics.views": {
"defaultMessage": "Weergaven"
},
"metrics.visitors": {
"defaultMessage": "Bezoekers"
},
"placeholder.message.go-to-settings": {
"defaultMessage": "Naar instellingen"
},
"placeholder.message.no-websites-configured": {
"defaultMessage": "Je hebt geen websites ingesteld."
},
"settings.accounts": {
"defaultMessage": "Accounts"
},
"settings.profile": {
"defaultMessage": "Profiel"
},
"settings.websites": {
"defaultMessage": "Websites"
},
"title.add-account": {
"defaultMessage": "Account toevoegen"
},
"title.add-website": {
"defaultMessage": "Website toevoegen"
},
"title.delete-account": {
"defaultMessage": "Account verwijderen"
},
"title.delete-website": {
"defaultMessage": "Website verwijderen"
},
"title.edit-account": {
"defaultMessage": "Account bewerken"
},
"title.edit-website": {
"defaultMessage": "Website bewerken"
},
"title.share-url": {
"defaultMessage": "URL delen"
},
"title.tracking-code": {
"defaultMessage": "Tracking code"
},
"tooltip.get-share-url": {
"defaultMessage": "Openbare URL"
},
"tooltip.get-tracking-code": {
"defaultMessage": "Tracking code"
}
}

View File

@ -1,20 +1,24 @@
import enMessages from 'lang-compiled/en.json';
import nlMessages from 'lang-compiled/nl-NL.json';
import zhCNMessages from 'lang-compiled/zh-CN.json';
import { format } from 'date-fns';
import { enUS, zhCN } from 'date-fns/locale';
import { enUS, nl, zhCN } from 'date-fns/locale';
export const messages = {
en: enMessages,
'nl-NL': nlMessages,
'zh-CN': zhCNMessages,
};
export const dateLocales = {
en: enUS,
'nl-NL': nl,
'zh-CN': zhCN,
};
export const menuOptions = [
{ label: 'English', value: 'en', display: 'EN' },
{ label: 'Nederlands', value: 'nl-NL', display: 'NL' },
{ label: '中文 (Chinese Simplified)', value: 'zh-CN', display: '中文' },
];