Skip to content

Commit

Permalink
Set language from browser settings
Browse files Browse the repository at this point in the history
  • Loading branch information
danniel committed Jul 3, 2023
1 parent 73e55f4 commit 68f0094
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion api/paul_api/paul_api/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@
LOCALE_PATHS = (os.path.join(BASE_DIR, "locale"),)

LANGUAGES = [
("ro", _("Romanian")),
("ro", _("Română")),
("en", _("English")),
]

Expand Down
7 changes: 4 additions & 3 deletions client/src/plugins/i18n.js
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ const messages = {
findOutMore: 'Find out more.',
firstAndLastNameLabel: 'Name and surname',
firstName: 'Name',
forgotPassword: 'Did your forgot your password?',
forgotPassword: 'Did you forget your password?',
forgotPasswordInsertEmail: 'Enter the e-mail address and you will receive a message with the instructions.',
forgotPasswordInstructionsConfirmation: 'You will receive an e-mail with a password reset link. If you dont find it, please check "spam" folder.',
forgotPasswordSendInstructions: 'Send the instructions',
Expand Down Expand Up @@ -625,8 +625,9 @@ const messages = {


const i18n = new VueI18n({
locale: 'ro',
fallbackLocale: 'en',
locale: navigator.language.split('-')[0],
// locale: process.env.LANGUAGE_CODE,
fallbackLocale: 'ro',
messages,
})

Expand Down

0 comments on commit 68f0094

Please sign in to comment.