mirror of https://github.com/MarceauKa/shaark.git
🚧 Locale settings
This commit is contained in:
parent
ad4d061f4a
commit
6a0ed6885a
|
@ -19,6 +19,10 @@ class StoreSettingsRequest extends FormRequest
|
||||||
'min:2',
|
'min:2',
|
||||||
'max:100',
|
'max:100',
|
||||||
],
|
],
|
||||||
|
'locale' => [
|
||||||
|
'required',
|
||||||
|
'in:fr,en',
|
||||||
|
],
|
||||||
'is_private' => [
|
'is_private' => [
|
||||||
'nullable',
|
'nullable',
|
||||||
'in:on,off',
|
'in:on,off',
|
||||||
|
|
|
@ -23,6 +23,8 @@ class AppServiceProvider extends ServiceProvider
|
||||||
|
|
||||||
public function boot()
|
public function boot()
|
||||||
{
|
{
|
||||||
|
$this->app->setLocale(app('shaarli')->getLocale());
|
||||||
|
|
||||||
View::composer('layouts.partials.scripts', function (\Illuminate\View\View $view) {
|
View::composer('layouts.partials.scripts', function (\Illuminate\View\View $view) {
|
||||||
$locale = config('app.locale');
|
$locale = config('app.locale');
|
||||||
|
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
return [
|
return [
|
||||||
'name' => env('APP_NAME'),
|
'name' => env('APP_NAME'),
|
||||||
|
'locale' => env('APP_LOCALE'),
|
||||||
'is_private' => false,
|
'is_private' => false,
|
||||||
'is_dark' => false,
|
'is_dark' => false,
|
||||||
];
|
];
|
||||||
|
|
|
@ -25,6 +25,7 @@ but built with [Laravel](https://github.com/laravel/laravel) and [Vue.js](https:
|
||||||
- [x] Original Shaarli import
|
- [x] Original Shaarli import
|
||||||
- [x] RSS feed
|
- [x] RSS feed
|
||||||
- [x] Export
|
- [x] Export
|
||||||
|
- [x] Dark mode
|
||||||
- [x] i18n (english and french)
|
- [x] i18n (english and french)
|
||||||
|
|
||||||
## Screenshots
|
## Screenshots
|
||||||
|
|
|
@ -1 +0,0 @@
|
||||||
{"is_private":false,"name":"Shaarli","is_dark":false}
|
|
Loading…
Reference in New Issue