QueryBuilderDndContextProps
Defined in: packages/dnd/src/types.ts:81
QueryBuilderDndContext props.
Extends
Pick
<QueryBuilderDndProps
,"canDrop"
|"copyModeModifierKey"
|"groupModeModifierKey"
>
Properties
baseControls
baseControls:
Pick
<Required
<SetNonNullable
<Partial
<{actionElement
:ComponentType
<ActionProps
>;addGroupAction
:null
|ComponentType
<ActionWithRulesAndAddersProps
>;addRuleAction
:null
|ComponentType
<ActionWithRulesAndAddersProps
>;cloneGroupAction
:null
|ComponentType
<ActionWithRulesProps
>;cloneRuleAction
:null
|ComponentType
<ActionProps
>;combinatorSelector
:null
|ComponentType
<CombinatorSelectorProps
>;dragHandle
:null
|ForwardRefExoticComponent
<DragHandleProps
&RefAttributes
<HTMLElement
>>;fieldSelector
:null
|ComponentType
<FieldSelectorProps
<{[key
:string
]:unknown
;className?
: Classname | undefined;comparator?
:string
| (f
: ...,operator
: ...) => ...;defaultOperator?
:string
;defaultValue?
:any
;disabled?
:boolean
;id?
:string
;inputType?
: InputType | null | undefined;label
:string
;name
:string
;operators?
: FlexibleOptionList<{ [x: string]: unknown; value?: string | undefined; label: string; disabled?: boolean | undefined; name: string; }> | undefined;placeholder?
:string
;validator?
:RuleValidator
;value
:string
;valueEditorType?
: ValueEditorType | ((operator: string) => ValueEditorType) | undefined;values?
: FlexibleOptionList<{ [x: string]: unknown; value?: string | undefined; label: string; disabled?: boolean | undefined; name: string; }> | undefined;valueSources?
: ValueSources | ((operator: string) => ValueSources) | undefined; }>>;inlineCombinator
:null
|ComponentType
<InlineCombinatorProps
>;lockGroupAction
:null
|ComponentType
<ActionWithRulesProps
>;lockRuleAction
:null
|ComponentType
<ActionWithRulesProps
>;notToggle
:null
|ComponentType
<NotToggleProps
>;operatorSelector
:null
|ComponentType
<OperatorSelectorProps
>;removeGroupAction
:null
|ComponentType
<ActionWithRulesProps
>;removeRuleAction
:null
|ComponentType
<ActionProps
>;rule
:ComponentType
<RuleProps
<string
,string
>>;ruleGroup
:ComponentType
<RuleGroupProps
<{[key
:string
]:unknown
;className?
:Classname
;comparator?
:string
| (f
: { [x: string]: unknown; label: string; disabled?: boolean | undefined; name: string; value: string; id?: string | undefined; operators?: FlexibleOptionList<{ [x: string]: unknown; value?: string | undefined; label: string; disabled?: boolean | undefined; name: string; }> | undefined; ... 9 more ...; className?: Clas...,operator
:string
) =>boolean
;defaultOperator?
:string
;defaultValue?
:any
;disabled?
:boolean
;id?
:string
;inputType?
:null
|InputType
;label
:string
;name
:string
;operators?
:FlexibleOptionList
<{[key
: ...]: ...;disabled?
: ...;label
: ...;name
: ...;value?
: ...; }>;placeholder?
:string
;validator?
:RuleValidator
;value
:string
;valueEditorType?
:ValueEditorType
| (operator
:string
) =>ValueEditorType
;values?
:FlexibleOptionList
<{[key
: ...]: ...;disabled?
: ...;label
: ...;name
: ...;value?
: ...; }>;valueSources?
:ValueSources
| (operator
:string
) =>ValueSources
; },string
>>;ruleGroupBodyElements
:ComponentType
<RuleGroupProps
<{[key
:string
]:unknown
;disabled?
:boolean
;label
:string
;name
:string
;value
:string
; },string
> &UseRuleGroup
>;ruleGroupHeaderElements
:ComponentType
<RuleGroupProps
<{[key
:string
]:unknown
;disabled?
:boolean
;label
:string
;name
:string
;value
:string
; },string
> &UseRuleGroup
>;shiftActions
:null
|ComponentType
<ShiftActionsProps
>;valueEditor
:null
|ComponentType
<ValueEditorProps
<{[key
:string
]:unknown
;className?
: Classname | undefined;comparator?
:string
| (f
: ...,operator
: ...) => ...;defaultOperator?
:string
;defaultValue?
:any
;disabled?
:boolean
;id?
:string
;inputType?
: InputType | null | undefined;label
:string
;name
:string
;operators?
: FlexibleOptionList<{ [x: string]: unknown; value?: string | undefined; label: string; disabled?: boolean | undefined; name: string; }> | undefined;placeholder?
:string
;validator?
:RuleValidator
;value
:string
;valueEditorType?
: ValueEditorType | ((operator: string) => ValueEditorType) | undefined;values?
: FlexibleOptionList<{ [x: string]: unknown; value?: string | undefined; label: string; disabled?: boolean | undefined; name: string; }> | undefined;valueSources?
: ValueSources | ((operator: string) => ValueSources) | undefined; },string
>>;valueSelector
:ComponentType
<ValueSelectorProps
<{[key
:string
]:unknown
;disabled?
:boolean
;label
:string
;name
:string
;value
:string
; }>>;valueSourceSelector
:null
|ComponentType
<ValueSourceSelectorProps
>; }>,"rule"
|"ruleGroup"
|"inlineCombinator"
|"shiftActions"
|"actionElement"
|"addGroupAction"
|"addRuleAction"
|"cloneGroupAction"
|"cloneRuleAction"
|"combinatorSelector"
|"dragHandle"
|"fieldSelector"
|"lockGroupAction"
|"lockRuleAction"
|"notToggle"
|"operatorSelector"
|"removeGroupAction"
|"removeRuleAction"
|"ruleGroupBodyElements"
|"ruleGroupHeaderElements"
|"valueEditor"
|"valueSelector"
|"valueSourceSelector"
>>,"rule"
|"ruleGroup"
|"combinatorSelector"
>
Defined in: packages/dnd/src/types.ts:85
canDrop()?
optional
canDrop: (params
:CustomCanDropParams
) =>boolean
Defined in: packages/dnd/src/types.ts:59
Parameters
Parameter | Type |
---|---|
params | CustomCanDropParams |
Returns
boolean
Inherited from
Pick.canDrop
copyModeModifierKey?
optional
copyModeModifierKey:string
Defined in: packages/dnd/src/types.ts:66
Key code for the modifier key that puts a drag-and-drop action in "copy" mode. Can be combined with "group" modifier key.
Default
"alt"
Inherited from
Pick.copyModeModifierKey
groupModeModifierKey?
optional
groupModeModifierKey:string
Defined in: packages/dnd/src/types.ts:73
Key code for the modifier key that puts a drag-and-drop action in "group" mode. Can be combined with "copy" modifier key.
Default
"ctrl"
Inherited from
Pick.groupModeModifierKey
useDrag()?
optional
useDrag: <DragObject
,DropResult
,CollectedProps
>(specArg
:FactoryOrInstance
<DragSourceHookSpec
<DragObject
,DropResult
,CollectedProps
>>,deps?
:unknown
[]) => [CollectedProps
,ConnectDragSource
,ConnectDragPreview
]
Defined in: packages/dnd/src/types.ts:83
useDragSource hook
Type Parameters
Type Parameter | Default type |
---|---|
DragObject | unknown |
DropResult | unknown |
CollectedProps | unknown |
Parameters
Parameter | Type | Description |
---|---|---|
specArg | FactoryOrInstance <DragSourceHookSpec <DragObject , DropResult , CollectedProps >> | - |
deps? | unknown [] | The memoization deps array to use when evaluating spec changes |
Returns
[CollectedProps
, ConnectDragSource
, ConnectDragPreview
]
useDrop()?
optional
useDrop: <DragObject
,DropResult
,CollectedProps
>(specArg
:FactoryOrInstance
<DropTargetHookSpec
<DragObject
,DropResult
,CollectedProps
>>,deps?
:unknown
[]) => [CollectedProps
,ConnectDropTarget
]
Defined in: packages/dnd/src/types.ts:84
useDropTarget Hook
Type Parameters
Type Parameter | Default type |
---|---|
DragObject | unknown |
DropResult | unknown |
CollectedProps | unknown |
Parameters
Parameter | Type | Description |
---|---|---|
specArg | FactoryOrInstance <DropTargetHookSpec <DragObject , DropResult , CollectedProps >> | - |
deps? | unknown [] | The memoization deps array to use when evaluating spec changes |
Returns
[CollectedProps
, ConnectDropTarget
]
API documentation is generated from the latest commit on the main
branch. It may be somewhat inconsistent with official releases of React Query Builder.