From 2989fc9bd78021e01c57122c58e940dd9f610730 Mon Sep 17 00:00:00 2001 From: Hayden Date: Sat, 23 Jan 2021 19:10:20 -0900 Subject: [PATCH] added UI language selection --- dev/dev-notes.md | 18 +------ docs/docs/roadmap.md | 2 +- frontend/src/App.vue | 1 + .../src/components/Settings/General/index.vue | 50 +++++++++++++++++++ .../Settings/Theme/ColorPickerDialog.vue | 47 +++-------------- frontend/src/i18n.js | 34 +++++++------ frontend/src/main.js | 5 +- frontend/src/pages/SettingsPage.vue | 5 +- frontend/src/store/modules/language.js | 44 ++++++++++++++++ frontend/src/store/store.js | 12 +++-- 10 files changed, 137 insertions(+), 81 deletions(-) create mode 100644 frontend/src/components/Settings/General/index.vue create mode 100644 frontend/src/store/modules/language.js diff --git a/dev/dev-notes.md b/dev/dev-notes.md index f5d3ad44f..2062d6be5 100644 --- a/dev/dev-notes.md +++ b/dev/dev-notes.md @@ -16,15 +16,7 @@ Don't forget to [join the Discord](https://discord.gg/R6QDyJgbD2)! # Todo's -Documentation -- [ ] V0.1.0 Release Notes -- [ ] Nextcloud Migration How To -- [ ] New Docker Setup with Sqlite -- [ ] Update Env Variables -- [ ] New Roadmap / Milestones - Frontend -- [x] Prep / Cook / Total Time Indicator + Editor - [ ] No Meal Today Page instead of Null - [ ] Recipe Print Page - [ ] Recipe Editor Data Validation Client Side @@ -32,12 +24,7 @@ Frontend - [ ] Advanced Search Page, draft started - [ ] Filter by Category - [ ] Filter by Tags -- [ ] Search Bar redesign - - [x] Initial - - [ ] Results redesign -- [x] Replace Backups card with something like Home Assistant -- [x] Replace import card with something like Home Assistant - - [x] Select which imports to do +- [ ] Search Bar Results Redesign Backend - [ ] Database Import @@ -46,11 +33,10 @@ Backend - [ ] Meal Plans - [x] Settings - [x] Themes -- [x] Remove Print / Debug Code +- [ ] Remove Print / Debug Code - [ ] Support how to sections and how to steps - [ ] Recipe request by category/tags - SQL - [ ] Setup Database Migrations diff --git a/docs/docs/roadmap.md b/docs/docs/roadmap.md index 85d079eba..f752f9bbe 100644 --- a/docs/docs/roadmap.md +++ b/docs/docs/roadmap.md @@ -38,7 +38,7 @@ Feature placement is not set in stone. This is much more of a guideline than any - [ ] Additional Backup / Import Features - [ ] Import Recipes Force/Rebase options - [x] Upload .zip file -- [ ] Improved Color Picker +- [x] Improved Color Picker - [x] Meal Plan redesign ### Backend - [ ] PostgreSQL Support diff --git a/frontend/src/App.vue b/frontend/src/App.vue index 98c56b8ca..630fa1cce 100644 --- a/frontend/src/App.vue +++ b/frontend/src/App.vue @@ -58,6 +58,7 @@ export default { mounted() { this.$store.dispatch("initTheme") this.$store.dispatch("requestRecentRecipes") + this.$store.dispatch("initLang") this.darkModeSystemCheck() this.darkModeAddEventListener() }, diff --git a/frontend/src/components/Settings/General/index.vue b/frontend/src/components/Settings/General/index.vue new file mode 100644 index 000000000..3e3ac3cef --- /dev/null +++ b/frontend/src/components/Settings/General/index.vue @@ -0,0 +1,50 @@ + + + + + \ No newline at end of file diff --git a/frontend/src/components/Settings/Theme/ColorPickerDialog.vue b/frontend/src/components/Settings/Theme/ColorPickerDialog.vue index 4bb01301e..3504e9e49 100644 --- a/frontend/src/components/Settings/Theme/ColorPickerDialog.vue +++ b/frontend/src/components/Settings/Theme/ColorPickerDialog.vue @@ -1,44 +1,9 @@