useRuleGroup()
useRuleGroup(
props
):object
Prepares all values and methods used by the RuleGroup component.
Parameters
Parameter | Type |
---|---|
props | RuleGroupProps <FullOption <string >, string > |
Returns
object
accessibleDescription
accessibleDescription:
string
actions
actions:
QueryActions
addGroup()
addGroup: (
_event
?,context
?) =>void
Parameters
Parameter | Type |
---|---|
_event ? | any |
context ? | any |
Returns
void
addRule()
addRule: (
_event
?,context
?) =>void
Parameters
Parameter | Type |
---|---|
_event ? | any |
context ? | any |
Returns
void
classNames
classNames:
object
classNames.addGroup
classNames.addGroup:
string
classNames.addRule
classNames.addRule:
string
classNames.body
classNames.body:
string
classNames.cloneGroup
classNames.cloneGroup:
string
classNames.combinators
classNames.combinators:
string
classNames.dragHandle
classNames.dragHandle:
string
classNames.header
classNames.header:
string
classNames.lockGroup
classNames.lockGroup:
string
classNames.notToggle
classNames.notToggle:
string
classNames.removeGroup
classNames.removeGroup:
string
classNames.shiftActions
classNames.shiftActions:
string
cloneGroup()
cloneGroup: (
_event
?,_context
?) =>void
Parameters
Parameter | Type |
---|---|
_event ? | any |
_context ? | any |
Returns
void
combinator
combinator:
string
context?
optional
context:any
disabled
disabled:
boolean
dragMonitorId
dragMonitorId:
string
|symbol
dragRef
dragRef:
Ref
<HTMLSpanElement
>
dropEffect?
optional
dropEffect:DropEffect
"move"
by default; "copy"
if the modifier key is pressed.
dropMonitorId
dropMonitorId:
string
|symbol
dropRef
dropRef:
Ref
<HTMLDivElement
>
id?
optional
id:string
isDragging
isDragging:
boolean
isOver
isOver:
boolean
not?
optional
not:boolean
Deprecated
Use the not
property of the ruleGroup
prop instead
onCombinatorChange()
onCombinatorChange: (
value
,_context
?) =>void
Parameters
Parameter | Type |
---|---|
value | any |
_context ? | any |
Returns
void
onGroupAdd()
onGroupAdd: (
group
,parentPath
,context
?) =>void
Parameters
Parameter | Type |
---|---|
group | RuleGroupTypeAny |
parentPath | Path |
context ? | any |
Returns
void
onIndependentCombinatorChange()
onIndependentCombinatorChange: (
value
,index
,_context
?) =>void
Parameters
Parameter | Type |
---|---|
value | any |
index | number |
_context ? | any |
Returns
void
onNotToggleChange()
onNotToggleChange: (
checked
,_context
?) =>void
Parameters
Parameter | Type |
---|---|
checked | boolean |
_context ? | any |
Returns
void
outerClassName
outerClassName:
string
parentDisabled
parentDisabled:
undefined
|boolean
path
path:
Path
pathsMemo
pathsMemo:
object
[]
previewRef
previewRef:
Ref
<HTMLDivElement
>
removeGroup()
removeGroup: (
_event
?,_context
?) =>void
Parameters
Parameter | Type |
---|---|
_event ? | any |
_context ? | any |
Returns
void
ruleGroup
ruleGroup:
RuleGroupType
<RuleType
<string
,string
,any
,string
>,string
> |object
rules?
optional
rules:RuleOrGroupArray
Deprecated
Use the rules
property of the ruleGroup
prop instead
schema
schema:
Schema
<FullOption
<string
>,string
>
shiftDownDisabled?
optional
shiftDownDisabled:boolean
shiftGroupDown()
shiftGroupDown: (
event
?,_context
?) =>void
Parameters
Parameter | Type |
---|---|
event ? | MouseEvent <Element , MouseEvent > |
_context ? | any |
Returns
void
shiftGroupUp()
shiftGroupUp: (
event
?,_context
?) =>void
Parameters
Parameter | Type |
---|---|
event ? | MouseEvent <Element , MouseEvent > |
_context ? | any |
Returns
void
shiftUpDisabled?
optional
shiftUpDisabled:boolean
toggleLockGroup()
toggleLockGroup: (
_event
?,_context
?) =>void
Parameters
Parameter | Type |
---|---|
_event ? | any |
_context ? | any |
Returns
void
translations
translations:
Translations
validationClassName
validationClassName:
string
validationResult
validationResult:
boolean
|ValidationResult
Defined in
packages/react-querybuilder/src/hooks/useRuleGroup.ts:19
API documentation is generated from the latest commit on the main
branch. It may be somewhat inconsistent with official releases of React Query Builder.