### File

`packages/components/eui-select/eui-select-control.directive.ts`

### Description

Control value accessor for single-select dropdowns with EUI styling. Extends Angular's SelectControlValueAccessor to handle placeholder behavior and readonly state synchronization.

### Applied automatically

Example :

    <select euiSelect [formControl]="myControl">
      <option euiOption [ngValue]="item" *ngFor="let item of items">{{item.label}}</option>
    </select>

### Notes

- Automatically applied when using euiSelect with form directives
- Handles object values via ngValue
- Manages placeholder styling and selection state

### Extends

`SelectControlValueAccessor`

### Implements

`ControlValueAccessor` `OnChanges` `DoCheck`

### Metadata

Providers | `)`
Selector | `select:not([multiple])[formControlName][euiSelect],select:not([multiple])[formControl][euiSelect],select:not([multiple])[ngModel][euiSelect]`

### Index

###### Methods

- registerOnChange
- setDisabledState
- writeValue

###### Inputs

- placeholder

### Constructor

`constructor()`

### Inputs

placeholder
Type : `string`

### Methods

registerOnChange
`registerOnChange(fn: (value: any) => void)`

Parameters :

Name | Type | Optional
fn | `function` | No

Returns : `void`

setDisabledState
`setDisabledState(isDisabled: boolean)`

Parameters :

Name | Type | Optional
isDisabled | `boolean` | No

Returns : `void`

writeValue
`writeValue(value: any)`

Sets the "value" property on the select element.

Parameters :

Name | Type | Optional
value | `any` | No

Returns : `void`

# results matching ""

# No results matching ""