I’m working in app multilanguage.
I need translate a column status and write this code (below) but I think it’s not the best way
Model User
const STATUSES = [
'active' => 'Active',
'deleted' => 'Deleted',
'suspended' => 'Suspended'
];
Blade template
<x-input.group for="email" label="{{ __('Status') }}" :error="$errors->first('editing.status')">
<x-input.select wire:model="editing.status" id="status">
@foreach(App\Models\User::STATUSES as $value => $label)
@php
$trans_value = __($label)
@endphp
<option value="{{ $value }}">{{ $trans_value }}</option>
@endforeach
</x-input.select>
</x-input.group>
Any cleaner alternative?