mirror of
https://github.com/Einundzwanzig-Podcast/einundzwanzig-portal.git
synced 2025-12-11 06:46:47 +00:00
Livewire UI installed
This commit is contained in:
49
resources/views/vendor/wireui/components/native-select.blade.php
vendored
Normal file
49
resources/views/vendor/wireui/components/native-select.blade.php
vendored
Normal file
@@ -0,0 +1,49 @@
|
||||
<div class="@if($disabled) opacity-60 @endif">
|
||||
@if ($label)
|
||||
<x-dynamic-component
|
||||
:component="WireUi::component('label')"
|
||||
class="mb-1"
|
||||
:label="$label"
|
||||
:has-error="$errors->has($name)"
|
||||
:for="$id"
|
||||
/>
|
||||
@endif
|
||||
|
||||
<select {{ $attributes->class([
|
||||
$defaultClasses(),
|
||||
$errorClasses() => $errors->has($name),
|
||||
$colorClasses() => !$errors->has($name),
|
||||
]) }}>
|
||||
@if ($options->isNotEmpty())
|
||||
@if ($placeholder)
|
||||
<option value="">{{ $placeholder }}</option>
|
||||
@endif
|
||||
|
||||
@forelse ($options as $key => $option)
|
||||
<option value="{{ $getOptionValue($key, $option) }}"
|
||||
@if(data_get($option, 'disabled', false)) disabled @endif>
|
||||
{{ $getOptionLabel($option) }}
|
||||
</option>
|
||||
@empty
|
||||
@unless ($hideEmptyMessage)
|
||||
<option disabled>
|
||||
{{ $emptyMessage ?? __('wireui::messages.empty_options') }}
|
||||
</option>
|
||||
@endunless
|
||||
@endforelse
|
||||
@else {{ $slot }} @endif
|
||||
</select>
|
||||
|
||||
@if ($hint)
|
||||
<label @if ($id) for="{{ $id }}" @endif class="mt-2 text-sm text-secondary-500 dark:text-secondary-400">
|
||||
{{ $hint }}
|
||||
</label>
|
||||
@endif
|
||||
|
||||
@if ($name)
|
||||
<x-dynamic-component
|
||||
:component="WireUi::component('error')"
|
||||
:name="$name"
|
||||
/>
|
||||
@endif
|
||||
</div>
|
||||
Reference in New Issue
Block a user