name = Auth::user()->name; $this->email = Auth::user()->email; } /** * Update the profile information for the currently authenticated user. */ public function updateProfileInformation(): void { $user = Auth::user(); $validated = $this->validate([ 'name' => ['required', 'string', 'max:255'], 'email' => [ 'required', 'string', 'lowercase', 'email', 'max:255', Rule::unique(User::class)->ignore($user->id) ], ]); $user->fill($validated); if ($user->isDirty('email')) { $user->email_verified_at = null; } $user->save(); $this->dispatch('profile-updated', name: $user->name); } /** * Send an email verification notification to the current user. */ public function resendVerificationNotification(): void { $user = Auth::user(); if ($user->hasVerifiedEmail()) { $this->redirectIntended(default: route_with_country('dashboard', absolute: false)); return; } $user->sendEmailVerificationNotification(); Session::flash('status', 'verification-link-sent'); } }; ?>
@include('partials.settings-heading')
{{--
@if (auth()->user() instanceof \Illuminate\Contracts\Auth\MustVerifyEmail &&! auth()->user()->hasVerifiedEmail())
{{ __('Your email address is unverified.') }} {{ __('Click here to re-send the verification email.') }} @if (session('status') === 'verification-link-sent') {{ __('A new verification link has been sent to your email address.') }} @endif
@endif
--}}
{{ __('Save') }}
{{ __('Saved.') }}
{{ __('Spracheinstellungen') }} {{ __('Wähle deine Sprache aus...') }}
@php $languages = [ 'de' => ['name' => 'Deutsch', 'countries' => ['de-DE', 'de-AT', 'de-CH']], 'en' => ['name' => 'English', 'countries' => ['en-GB', 'en-US', 'en-AU', 'en-CA']], 'es' => ['name' => 'Español', 'countries' => ['es-ES', 'es-CL', 'es-CO']], ]; $currentLangCountry = session('lang_country', config('lang-country.fallback')); @endphp @foreach($languages as $langCode => $langData) @foreach($langData['countries'] as $langCountry) @php [$lang, $countryCode] = explode('-', $langCountry); $isActive = $currentLangCountry === $langCountry; @endphp {{ strtolower($countryCode) }} {{ $langData['name'] }} {{ strtoupper($countryCode) }} @endforeach @endforeach