main ← Grubba27:feat/theme-translations-with-picker
opened 12:46AM - 13 Mar 24 UTC
## Why this change?
In the current Discourse theme admin UI, admins are limi…ted to editing the label in their own language only. This PR changes that.
<details><summary>Changes</summary>
- Add `ComboBox` in `admin-customize-theme-show.js` with `availableLocales` based on `admin-site-text-index.js`
- Add `locale` property to request
- Add check in update_translations method to check `locale` property
</details>
### TODO:
- [x] Tests ( would love some input on that, what would be a good test for the changes that I've made, examples )
- [x] fetching translations for the selected language; without it, the Admin might get lost. I thought of adding a get method [here](https://github.com/Grubba27/discourse/blob/aa30541a11b71ab0dc0f1c995ba9767f1a6e3ff9/config/routes.rb#L232-L234) to get translations -> ` get "translations/:key" => "themes#translations"`)
## Demo
https://github.com/discourse/discourse/assets/70247653/6849fdfb-761b-4d26-9986-23880e49a472