select
A native select, with label, hint, error and old() value handled.
Example
Laravel
<x-admin::select name="g_platform" label="Platform" placeholder="Choose…" :options="['sf' => 'Salesforce', 'mc' => 'Mailchimp']" />Props
| Prop | Required | Default | Options |
|---|---|---|---|
name | null | ||
label | null | ||
hint | null | ||
error | null | ||
id | null | ||
options | [] | ||
value | null | ||
placeholder | null | ||
optional | false | ||
required | false |
Other attributes, such as wire:model or data-*, pass through to the element.
Other stacks
React and Vue: import { Select } from "@admiral/ui-kit/react" (or /vue). See the React and Vue guide.
HTML, for any stack
<div class="adm-field">
<label class="adm-label" for="g_platform">Platform</label>
<select
name="g_platform" id="g_platform" class="adm-select"
>
<option value="">Choose…</option> <option value="sf" >Salesforce</option>
<option value="mc" >Mailchimp</option>
</select>
</div>