# Coveo SimpleFilter Component (CoveoSimpleFilter)

## Index

### Methods

- closeContainer
- debugInfo
- deselectValue
- disable
- enable
- getBindings
- getSelectedCaptions
- getValueCaption
- getValueContainer
- openContainer
- resetSimpleFilter
- selectValue
- toggleContainer
- toggleValue
- get

### Properties

- bind
- componentOptionsModel
- componentStateModel
- disabled
- logger
- queryController
- queryStateModel
- root
- searchInterface
- ID

### Accessors

- usageAnalytics

### Component Options

- enableClearButton
- field
- maximumNumberOfValues
- sortCriteria
- title
- valueCaption
- values

### Constructors

- constructor

## Methods

### closeContainer

- closeContainer(): void

- - Defined in ui/SimpleFilter/SimpleFilter.ts :323

  #### Returns void

### debugInfo

- debugInfo(): any

- Inherited from BaseComponent.debugInfo

  - Defined in ui/Base/BaseComponent.ts :41

  #### Returns any

### deselectValue

- deselectValue(value: string): void

- - Defined in ui/SimpleFilter/SimpleFilter.ts :274

  #### Parameters

  - ##### value: string

  #### Returns void

### disable

- disable(): void

- Inherited from BaseComponent.disable

  - Defined in ui/Base/BaseComponent.ts :52

  #### Returns void

### enable

- enable(): void

- Inherited from BaseComponent.enable

  - Defined in ui/Base/BaseComponent.ts :61

  #### Returns void

### getBindings

- getBindings(): IComponentBindings

- Inherited from Component.getBindings

  - Defined in ui/Base/Component.ts :328

  #### Returns IComponentBindings

### getSelectedCaptions

- getSelectedCaptions(): string[]

- - Defined in ui/SimpleFilter/SimpleFilter.ts :245

  #### Returns string[]

  An array containing the selected captions.

### getValueCaption

- getValueCaption(value: string): string

- - Defined in ui/SimpleFilter/SimpleFilter.ts :230

  #### Parameters

  - ##### value: string

  #### Returns string

  The value caption, if available; the original value otherwise.

### getValueContainer

- getValueContainer(): Dom

- - Defined in ui/SimpleFilter/SimpleFilter.ts :221

  #### Returns Dom

  The `SimpleFilter` valueContainer.

### openContainer

- openContainer(): void

- - Defined in ui/SimpleFilter/SimpleFilter.ts :310

  #### Returns void

### resetSimpleFilter

- resetSimpleFilter(): void

- - Defined in ui/SimpleFilter/SimpleFilter.ts :299

  #### Returns void

### selectValue

- selectValue(value: string, triggerQuery?: boolean): void

- - Defined in ui/SimpleFilter/SimpleFilter.ts :261

  #### Parameters

  - ##### value: string

  - ##### Default value triggerQuery: boolean = true

  #### Returns void

### toggleContainer

- toggleContainer(): void

- - Defined in ui/SimpleFilter/SimpleFilter.ts :252

  #### Returns void

### toggleValue

- toggleValue(value: string): void

- - Defined in ui/SimpleFilter/SimpleFilter.ts :287

  #### Parameters

  - ##### value: string

  #### Returns void

### Static get

- get(element: HTMLElement, componentClass?: any, noThrow?: boolean): BaseComponent

- Inherited from Component.get

  - Defined in ui/Base/Component.ts :410

  #### Parameters

  - ##### element: HTMLElement

  - ##### Optional componentClass: any

  - ##### Optional noThrow: boolean

  #### Returns BaseComponent

## Properties

### bind

bind: ComponentEvents

Inherited from Component.bind

- Defined in ui/Base/Component.ts :270

### componentOptionsModel

componentOptionsModel: ComponentOptionsModel

Inherited from Component.componentOptionsModel

- Defined in ui/Base/Component.ts :294

### componentStateModel

componentStateModel: ComponentStateModel

Inherited from Component.componentStateModel

- Defined in ui/Base/Component.ts :282

### disabled

disabled: boolean

Inherited from BaseComponent.disabled

- Defined in ui/Base/BaseComponent.ts :23

### logger

logger: Logger

Inherited from BaseComponent.logger

- Defined in ui/Base/BaseComponent.ts :18

### queryController

queryController: QueryController

Inherited from Component.queryController

- Defined in ui/Base/Component.ts :286

### queryStateModel

queryStateModel: QueryStateModel

Inherited from Component.queryStateModel

- Defined in ui/Base/Component.ts :278

### root

root: HTMLElement

Inherited from Component.root

- Defined in ui/Base/Component.ts :274

### searchInterface

searchInterface: SearchInterface

Inherited from Component.searchInterface

- Defined in ui/Base/Component.ts :290

### Static ID

ID: string

Inherited from BaseComponent.ID

- Defined in ui/Base/BaseComponent.ts :28

## Accessors

### usageAnalytics

usageAnalytics:

Inherited from Component.usageAnalytics

- Defined in ui/Base/Component.ts :343

## Component Options

### enableClearButton

enableClearButton: boolean

- Defined in ui/SimpleFilter/SimpleFilter.ts :173

Markup configuration example(s) :

    data-enable-clear-button='true'
    data-enable-clear-button='false'

### field

field: IFieldOption

- Defined in ui/SimpleFilter/SimpleFilter.ts :85

Markup configuration example(s) :

    data-field='@foo'

### maximumNumberOfValues

maximumNumberOfValues: number

- Defined in ui/SimpleFilter/SimpleFilter.ts :70

Markup configuration example(s) :

    data-maximum-number-of-values='10'

### sortCriteria

sortCriteria: "occurrences" | "score" | "alphaascending" | "alphadescending" | "computedfieldascending" | "computedfielddescending" | "chisquare" | "nosort"

- Defined in ui/SimpleFilter/SimpleFilter.ts :154

### title

title: string

- Defined in ui/SimpleFilter/SimpleFilter.ts :92

Markup configuration example(s) :

    data-title='foo'

### valueCaption

valueCaption: any

- Defined in ui/SimpleFilter/SimpleFilter.ts :129

### values

values: string[]

- Defined in ui/SimpleFilter/SimpleFilter.ts :78

## Constructors

### constructor

- new SimpleFilter(element: HTMLElement, options: ISimpleFilterOptions, bindings?: IComponentBindings): SimpleFilter

- Overwrites Component.constructor

  - Defined in ui/SimpleFilter/SimpleFilter.ts :186

  #### Parameters

  - ##### element: HTMLElement

  - ##### options: ISimpleFilterOptions

  - ##### Optional bindings: IComponentBindings

  #### Returns SimpleFilter