Skip to content

Commit

Permalink
Update multiselect input field type
Browse files Browse the repository at this point in the history
  • Loading branch information
rasitozcan committed Jan 4, 2024
1 parent d7181ac commit 0fdf3a6
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions packages/picasso-query-builder/src/types/query-builder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export type RangeValue = {
interface BasicField
extends Omit<QueryBuilderField, 'inputType' | 'valueEditorType'> {
inputType?: 'text' | 'number' | null
valueEditorType?: 'text' | 'number' | 'select' | 'multiselect' | null
valueEditorType?: 'text' | 'number' | 'select' | null
hideOperator?: boolean
}
interface RangeField
Expand All @@ -34,6 +34,14 @@ interface BooleanField
extends Omit<QueryBuilderField, 'inputType' | 'valueEditorType' | 'values'> {
valueEditorType?: 'boolean'
}
interface MultiSelectField
extends Omit<QueryBuilderField, 'inputType' | 'valueEditorType'> {
valueEditorType?: 'multiselect'
/**
* Allow search input reset
*/
enableResetSearch?: boolean
}

interface AutoCompleteField
extends Omit<QueryBuilderField, 'inputType' | 'valueEditorType'> {
Expand All @@ -54,7 +62,12 @@ interface AutoCompleteField

export type BaseValueEditorProps = Omit<ValueEditorProps, 'schema'>
export type BaseVersatileSelectorProps = Omit<VersatileSelectorProps, 'schema'>
export type Field = BasicField | RangeField | AutoCompleteField | BooleanField
export type Field =
| BasicField
| RangeField
| AutoCompleteField
| BooleanField
| MultiSelectField
export type QueryBuilderErrors = {
[key: string]: ValidationResult | true
}
Expand Down

0 comments on commit 0fdf3a6

Please sign in to comment.