React TreeList - columnChooser.search

Configures the column chooser's search functionality.

Selector: Search

jQuery
JavaScript
$(function(){
    $("#treeList").dxTreeList({
        // ...
        columnChooser: {
            // ...
            search: {
                editorOptions: { 
                    placeholder: 'Search column',
                    mode: 'text' 
                },
                enabled: true,
                timeout: 800      
            },
        },
    })
});
Angular
app.component.html
app.component.ts
app.module.ts
<dx-tree-list ... >
    <dxo-column-chooser ... >
        <dxo-search
            [editorOptions]="searchEditorOptions"
            [enabled]="true"
            [timeout]="800"
        ></dxo-search>
    </dxo-column-chooser>
</dx-tree-list>
import { Component } from '@angular/core'; 

@Component({ 
    selector: 'app-root', 
    templateUrl: './app.component.html', 
    styleUrls: ['./app.component.css'] 
}) 

export class AppComponent {
    searchEditorOptions;
    constructor() {
        this.searchEditorOptions = { 
            placeholder: 'Search column', 
            mode: 'text' 
        };
        // ...
    } 
    // ...
}
import { BrowserModule } from '@angular/platform-browser'; 
import { NgModule } from '@angular/core'; 
import { AppComponent } from './app.component'; 
import { DxTreeListModule } from 'devextreme-angular'; 

@NgModule({ 
    declarations: [ 
        AppComponent 
    ], 
    imports: [ 
        BrowserModule, 
        DxTreeListModule 
    ], 
    providers: [ ], 
    bootstrap: [AppComponent] 
}) 

export class AppModule { }  
Vue
App.vue (Options API)
App.vue (Composition API)
<template>
    <DxTreeList ... >
        <DxColumnChooser ... >
            <DxColumnChooserSearch
                :editor-options="searchEditorOptions"
                :enabled="true"
                :timeout="800"
            />
        </DxColumnChooser>
    </DxTreeList>
</template>

<script>
import 'devextreme/dist/css/dx.light.css';
import DxTreeList, {
    DxColumnChooser, 
    DxColumnChooserSearch,
    // ... 
} from 'devextreme-vue/tree-list';

export default {
    components: {
        DxTreeList, 
        DxColumnChooser, 
        DxColumnChooserSearch,
    },
    data() {
        return {
            searchEditorOptions: { 
                placeholder: 'Search column', 
                mode: 'text' 
            }
        };
    }
}
</script>
<template>
    <DxTreeList ... >
        <DxColumnChooser ... >
            <DxColumnChooserSearch
                :editor-options="searchEditorOptions"
                :enabled="true"
                :timeout="800"
            />
        </DxColumnChooser>
    </DxTreeList>
</template>

<script setup>
import 'devextreme/dist/css/dx.light.css';
import DxTreeList, {
    DxColumnChooser, 
    DxColumnChooserSearch,
    // ... 
} from 'devextreme-vue/tree-list';

const searchEditorOptions = { 
    placeholder: 'Search column', 
    mode: 'text' 
};

// ...
</script>
React
App.js
import React from 'react';  
import 'devextreme/dist/css/dx.light.css'; 

import TreeList, {
    ColumnChooser, 
    ColumnChooserSearch, 
    // ...
} from 'devextreme-react/data-grid';

const searchEditorOptions = { 
    placeholder: 'Search column', 
    mode: 'text' 
};

export default function App() { 
    return ( 
        <TreeList ... > 
            <ColumnChooser ... >
                <ColumnChooserSearch
                    editorOptions={searchEditorOptions}
                    enabled={true}
                    timeout={800}
                />
            </ColumnChooser>
        </TreeList>        
    ); 
} 

editorOptions

Configures the search box.

Type: any
Default Value: {}

See the TextBox Configuration topic for information about properties you can specify in this object.

Angular
NOTE
The nested component that configures the editorOptions property does not support event bindings and two-way property bindings.
Vue
NOTE
The nested component that configures the editorOptions property does not support event bindings and two-way property bindings.
jQuery
JavaScript
$(function(){
    $("#treeList").dxTreeList({
        // ...
        columnChooser: {
            // ...
            search: {
                editorOptions: { 
                    placeholder: 'Search column',
                    mode: 'text',
                    onValueChanged: (e) => {
                        // handle the value change here
                    }
                },
                // ...    
            },
        },
    })
});
Angular
app.component.html
app.component.ts
app.module.ts
<dx-tree-list ... >
    <dxo-column-chooser ... >
        <dxo-search
            [editorOptions]="searchEditorOptions"
            // ...
        ></dxo-search>
    </dxo-column-chooser>
</dx-tree-list>
import { Component } from '@angular/core'; 

@Component({ 
    selector: 'app-root', 
    templateUrl: './app.component.html', 
    styleUrls: ['./app.component.css'] 
}) 

export class AppComponent { 
    searchEditorOptions;
    constructor() {
        this.searchEditorOptions = { 
            placeholder: 'Search column', 
            mode: 'text',
            onValueChanged: (e) => {
                // handle the value change here
            } 
        };
        // ...
    } 
    // ...
}
import { BrowserModule } from '@angular/platform-browser'; 
import { NgModule } from '@angular/core'; 
import { AppComponent } from './app.component'; 
import { DxTreeListModule } from 'devextreme-angular'; 

@NgModule({ 
    declarations: [ 
        AppComponent 
    ], 
    imports: [ 
        BrowserModule, 
        DxTreeListModule 
    ], 
    providers: [ ], 
    bootstrap: [AppComponent] 
}) 

export class AppModule { }  
Vue
App.vue (Options API)
App.vue (Composition API)
<template>
    <DxTreeList ... >
        <DxColumnChooser ... >
            <DxColumnChooserSearch
                :editor-options="searchEditorOptions"
                // ...
            />
        </DxColumnChooser>
    </DxTreeList>
</template>

<script>
import 'devextreme/dist/css/dx.light.css';
import DxTreeList, {
    DxColumnChooser, 
    DxColumnChooserSearch,
    // ... 
} from 'devextreme-vue/tree-list';

export default {
    components: {
        DxTreeList
    },
    data() {
        return {
            searchEditorOptions: { 
                placeholder: 'Search column', 
                mode: 'text',
                onValueChanged: this.handleValueChange
            }
        };
    }
    methods: {
        handleValueChange(e) {
            // handle the value change here
        }
    }
}
</script>
<template>
    <DxTreeList ... >
        <DxColumnChooser ... >
            <DxColumnChooserSearch
                :editor-options="searchEditorOptions"
                // ...
            />
        </DxColumnChooser>
    </DxTreeList>
</template>

<script setup>
import 'devextreme/dist/css/dx.light.css';
import DxTreeList, {
    DxColumnChooser, 
    DxColumnChooserSearch,
    // ... 
} from 'devextreme-vue/tree-list';

const searchEditorOptions = { 
    placeholder: 'Search column', 
    mode: 'text',
    onValueChanged: (e) => {
        // handle the value change here
    }
};

// ...
</script>
React
App.js
import React from 'react';  
import 'devextreme/dist/css/dx.light.css'; 

import TreeList, {
    ColumnChooser, 
    ColumnChooserSearch, 
    // ...
} from 'devextreme-react/data-grid';

const searchEditorOptions = { 
    placeholder: 'Search column', 
    mode: 'text',
    onValueChanged: (e) => {
        // handle the value change here
    }
};

export default function App() { 
    return ( 
        <TreeList ... > 
            <ColumnChooser ... >
                <ColumnChooserSearch
                    editorOptions={searchEditorOptions}
                    // ...
                />
            </ColumnChooser>
        </TreeList>        
    ); 
} 

enabled

Specifies whether search is enabled in the column chooser.

Type:

Boolean

Default Value: false

timeout

Specifies a timeout, in milliseconds, during which a user may continue to modify the search value without starting the search operation.

Type:

Number

Default Value: 500