UNPKG

react-querybuilder

Version:

React Query Builder component for constructing queries and filters, with utilities for executing them in various database and evaluation contexts

6,009 lines 224 kB
import * as React from "react";
import { ChangeEvent, ComponentType, Context, ForwardRefExoticComponent, MouseEvent, ReactNode, Ref, RefAttributes } from "react";
import { EnhancedStore, Slice, StoreEnhancer, ThunkDispatch, Tuple, UnknownAction } from "@reduxjs/toolkit";
import { ReactReduxContextValue, TypedUseSelectorHook } from "react-redux";
import { JsonLogicAll, JsonLogicAnd, JsonLogicDoubleNegation, JsonLogicEqual, JsonLogicGreaterThan, JsonLogicGreaterThanOrEqual, JsonLogicInArray, JsonLogicInString, JsonLogicLessThan, JsonLogicLessThanOrEqual, JsonLogicNegation, JsonLogicNone, JsonLogicNotEqual, JsonLogicOr, JsonLogicSome, JsonLogicStrictEqual, JsonLogicStrictNotEqual, JsonLogicVar, ReservedOperations as JsonLogicReservedOperations, RulesLogic, RulesLogic as JsonLogicRulesLogic } from "json-logic-js";
import { Column, Operators, SQL, Table } from "drizzle-orm";
import { WhereOptions } from "sequelize";

//#region ../../node_modules/type-fest/source/primitive.d.ts
/**
Matches any [primitive value](https://developer.mozilla.org/en-US/docs/Glossary/Primitive).

@category Type
*/
type Primitive = null | undefined | string | number | boolean | symbol | bigint;
//#endregion
//#region ../../node_modules/type-fest/source/union-to-intersection.d.ts
/**
Convert a union type to an intersection type using [distributive conditional types](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-8.html#distributive-conditional-types).

Inspired by [this Stack Overflow answer](https://stackoverflow.com/a/50375286/2172153).

@example
```
import type {UnionToIntersection} from 'type-fest';

type Union = {the(): void} | {great(arg: string): void} | {escape: boolean};

type Intersection = UnionToIntersection<Union>;
//=> {the(): void; great(arg: string): void; escape: boolean};
```

@category Type
*/
type UnionToIntersection<Union> = (
// `extends unknown` is always going to be the case and is used to convert the
// `Union` into a [distributive conditional
// type](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-8.html#distributive-conditional-types).
Union extends unknown
// The union type is used as the only argument to a function since the union
// of function arguments is an intersection.
? (distributedUnion: Union) => void
// This won't happen.
: never
// Infer the `Intersection` type since TypeScript represents the positional
// arguments of unions of functions as an intersection of the union.
) extends ((mergedIntersection: infer Intersection) => void)
// The `& Union` is to ensure result of `UnionToIntersection<A | B>` is always assignable to `A | B`
? Intersection & Union : never;
//#endregion
//#region ../../node_modules/type-fest/source/keys-of-union.d.ts
/**
Create a union of all keys from a given type, even those exclusive to specific union members.

Unlike the native `keyof` keyword, which returns keys present in **all** union members, this type returns keys from **any** member.

@link https://stackoverflow.com/a/49402091

@example
```
import type {KeysOfUnion} from 'type-fest';

type A = {
	common: string;
	a: number;
};

type B = {
	common: string;
	b: string;
};

type C = {
	common: string;
	c: boolean;
};

type Union = A | B | C;

type CommonKeys = keyof Union;
//=> 'common'

type AllKeys = KeysOfUnion<Union>;
//=> 'common' | 'a' | 'b' | 'c'
```

@category Object
*/
type KeysOfUnion<ObjectType> =
// Hack to fix https://github.com/sindresorhus/type-fest/issues/1008
keyof UnionToIntersection<ObjectType extends unknown ? Record<keyof ObjectType, never> : never>;
//#endregion
//#region ../../node_modules/type-fest/source/is-any.d.ts
/**
Returns a boolean for whether the given type is `any`.

@link https://stackoverflow.com/a/49928360/1490091

Useful in type utilities, such as disallowing `any`s to be passed to a function.

@example
```
import type {IsAny} from 'type-fest';

const typedObject = {a: 1, b: 2} as const;
const anyObject: any = {a: 1, b: 2};

function get<O extends (IsAny<O> extends true ? {} : Record<string, number>), K extends keyof O = keyof O>(object: O, key: K) {
	return object[key];
}

const typedA = get(typedObject, 'a');
//=> 1

const anyA = get(anyObject, 'a');
//=> any
```

@category Type Guard
@category Utilities
*/
type IsAny<T$1> = 0 extends 1 & NoInfer<T$1> ? true : false;
//#endregion
//#region ../../node_modules/type-fest/source/is-optional-key-of.d.ts
/**
Returns a boolean for whether the given key is an optional key of type.

This is useful when writing utility types or schema validators that need to differentiate `optional` keys.

@example
```
import type {IsOptionalKeyOf} from 'type-fest';

type User = {
	name: string;
	surname: string;

	luckyNumber?: number;
};

type Admin = {
	name: string;
	surname?: string;
};

type T1 = IsOptionalKeyOf<User, 'luckyNumber'>;
//=> true

type T2 = IsOptionalKeyOf<User, 'name'>;
//=> false

type T3 = IsOptionalKeyOf<User, 'name' | 'luckyNumber'>;
//=> boolean

type T4 = IsOptionalKeyOf<User | Admin, 'name'>;
//=> false

type T5 = IsOptionalKeyOf<User | Admin, 'surname'>;
//=> boolean
```

@category Type Guard
@category Utilities
*/
type IsOptionalKeyOf<Type extends object, Key$1 extends keyof Type> = IsAny<Type | Key$1> extends true ? never : Key$1 extends keyof Type ? Type extends Record<Key$1, Type[Key$1]> ? false : true : false;
//#endregion
//#region ../../node_modules/type-fest/source/optional-keys-of.d.ts
/**
Extract all optional keys from the given type.

This is useful when you want to create a new type that contains different type values for the optional keys only.

@example
```
import type {OptionalKeysOf, Except} from 'type-fest';

type User = {
	name: string;
	surname: string;

	luckyNumber?: number;
};

const REMOVE_FIELD = Symbol('remove field symbol');
type UpdateOperation<Entity extends object> = Except<Partial<Entity>, OptionalKeysOf<Entity>> & {
	[Key in OptionalKeysOf<Entity>]?: Entity[Key] | typeof REMOVE_FIELD;
};

const update1: UpdateOperation<User> = {
	name: 'Alice',
};

const update2: UpdateOperation<User> = {
	name: 'Bob',
	luckyNumber: REMOVE_FIELD,
};
```

@category Utilities
*/
type OptionalKeysOf<Type extends object> = Type extends unknown // For distributing `Type`
? (keyof { [Key in keyof Type as IsOptionalKeyOf<Type, Key> extends false ? never : Key]: never }) & keyof Type // Intersect with `keyof Type` to ensure result of `OptionalKeysOf<Type>` is always assignable to `keyof Type`
: never;
//#endregion
//#region ../../node_modules/type-fest/source/required-keys-of.d.ts
/**
Extract all required keys from the given type.

This is useful when you want to create a new type that contains different type values for the required keys only or use the list of keys for validation purposes, etc...

@example
```
import type {RequiredKeysOf} from 'type-fest';

declare function createValidation<
	Entity extends object,
	Key extends RequiredKeysOf<Entity> = RequiredKeysOf<Entity>,
>(field: Key, validator: (value: Entity[Key]) => boolean): (entity: Entity) => boolean;

type User = {
	name: string;
	surname: string;
	luckyNumber?: number;
};

const validator1 = createValidation<User>('name', value => value.length < 25);
const validator2 = createValidation<User>('surname', value => value.length < 25);

// @ts-expect-error
const validator3 = createValidation<User>('luckyNumber', value => value > 0);
// Error: Argument of type '"luckyNumber"' is not assignable to parameter of type '"name" | "surname"'.
```

@category Utilities
*/
type RequiredKeysOf<Type extends object> = Type extends unknown // For distributing `Type`
? Exclude<keyof Type, OptionalKeysOf<Type>> : never;
//#endregion
//#region ../../node_modules/type-fest/source/is-never.d.ts
/**
Returns a boolean for whether the given type is `never`.

@link https://github.com/microsoft/TypeScript/issues/31751#issuecomment-498526919
@link https://stackoverflow.com/a/53984913/10292952
@link https://www.zhenghao.io/posts/ts-never

Useful in type utilities, such as checking if something does not occur.

@example
```
import type {IsNever, And} from 'type-fest';

type A = IsNever<never>;
//=> true

type B = IsNever<any>;
//=> false

type C = IsNever<unknown>;
//=> false

type D = IsNever<never[]>;
//=> false

type E = IsNever<object>;
//=> false

type F = IsNever<string>;
//=> false
```

@example
```
import type {IsNever} from 'type-fest';

type IsTrue<T> = T extends true ? true : false;

// When a distributive conditional is instantiated with `never`, the entire conditional results in `never`.
type A = IsTrue<never>;
//   ^? type A = never

// If you don't want that behaviour, you can explicitly add an `IsNever` check before the distributive conditional.
type IsTrueFixed<T> =
	IsNever<T> extends true ? false : T extends true ? true : false;

type B = IsTrueFixed<never>;
//   ^? type B = false
```

@category Type Guard
@category Utilities
*/
type IsNever<T$1> = [T$1] extends [never] ? true : false;
//#endregion
//#region ../../node_modules/type-fest/source/if.d.ts
/**
An if-else-like type that resolves depending on whether the given `boolean` type is `true` or `false`.

Use-cases:
- You can use this in combination with `Is*` types to create an if-else-like experience. For example, `If<IsAny<any>, 'is any', 'not any'>`.

Note:
- Returns a union of if branch and else branch if the given type is `boolean` or `any`. For example, `If<boolean, 'Y', 'N'>` will return `'Y' | 'N'`.
- Returns the else branch if the given type is `never`. For example, `If<never, 'Y', 'N'>` will return `'N'`.

@example
```
import type {If} from 'type-fest';

type A = If<true, 'yes', 'no'>;
//=> 'yes'

type B = If<false, 'yes', 'no'>;
//=> 'no'

type C = If<boolean, 'yes', 'no'>;
//=> 'yes' | 'no'

type D = If<any, 'yes', 'no'>;
//=> 'yes' | 'no'

type E = If<never, 'yes', 'no'>;
//=> 'no'
```

@example
```
import type {If, IsAny, IsNever} from 'type-fest';

type A = If<IsAny<unknown>, 'is any', 'not any'>;
//=> 'not any'

type B = If<IsNever<never>, 'is never', 'not never'>;
//=> 'is never'
```

@example
```
import type {If, IsEqual} from 'type-fest';

type IfEqual<T, U, IfBranch, ElseBranch> = If<IsEqual<T, U>, IfBranch, ElseBranch>;

type A = IfEqual<string, string, 'equal', 'not equal'>;
//=> 'equal'

type B = IfEqual<string, number, 'equal', 'not equal'>;
//=> 'not equal'
```

Note: Sometimes using the `If` type can make an implementation non–tail-recursive, which can impact performance. In such cases, it’s better to use a conditional directly. Refer to the following example:

@example
```
import type {If, IsEqual, StringRepeat} from 'type-fest';

type HundredZeroes = StringRepeat<'0', 100>;

// The following implementation is not tail recursive
type Includes<S extends string, Char extends string> =
	S extends `${infer First}${infer Rest}`
		? If<IsEqual<First, Char>,
			'found',
			Includes<Rest, Char>>
		: 'not found';

// Hence, instantiations with long strings will fail
// @ts-expect-error
type Fails = Includes<HundredZeroes, '1'>;
//           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Error: Type instantiation is excessively deep and possibly infinite.

// However, if we use a simple conditional instead of `If`, the implementation becomes tail-recursive
type IncludesWithoutIf<S extends string, Char extends string> =
	S extends `${infer First}${infer Rest}`
		? IsEqual<First, Char> extends true
			? 'found'
			: IncludesWithoutIf<Rest, Char>
		: 'not found';

// Now, instantiations with long strings will work
type Works = IncludesWithoutIf<HundredZeroes, '1'>;
//=> 'not found'
```

@category Type Guard
@category Utilities
*/
type If<Type extends boolean, IfBranch, ElseBranch> = IsNever<Type> extends true ? ElseBranch : Type extends true ? IfBranch : ElseBranch;
//#endregion
//#region ../../node_modules/type-fest/source/unknown-array.d.ts
/**
Represents an array with `unknown` value.

Use case: You want a type that all arrays can be assigned to, but you don't care about the value.

@example
```
import type {UnknownArray} from 'type-fest';

type IsArray<T> = T extends UnknownArray ? true : false;

type A = IsArray<['foo']>;
//=> true

type B = IsArray<readonly number[]>;
//=> true

type C = IsArray<string>;
//=> false
```

@category Type
@category Array
*/
type UnknownArray = readonly unknown[];
//#endregion
//#region ../../node_modules/type-fest/source/internal/type.d.ts
/**
Matches any primitive, `void`, `Date`, or `RegExp` value.
*/
type BuiltIns = Primitive | void | Date | RegExp;
/**
Test if the given function has multiple call signatures.

Needed to handle the case of a single call signature with properties.

Multiple call signatures cannot currently be supported due to a TypeScript limitation.
@see https://github.com/microsoft/TypeScript/issues/29732
*/
type HasMultipleCallSignatures<T$1 extends (...arguments_: any[]) => unknown> = T$1 extends {
  (...arguments_: infer A): unknown;
  (...arguments_: infer B): unknown;
} ? B extends A ? A extends B ? false : true : true : false;
/**
An if-else-like type that resolves depending on whether the given type is `any` or `never`.

@example
```
// When `T` is a NOT `any` or `never` (like `string`) => Returns `IfNotAnyOrNever` branch
type A = IfNotAnyOrNever<string, 'VALID', 'IS_ANY', 'IS_NEVER'>;
//=> 'VALID'

// When `T` is `any` => Returns `IfAny` branch
type B = IfNotAnyOrNever<any, 'VALID', 'IS_ANY', 'IS_NEVER'>;
//=> 'IS_ANY'

// When `T` is `never` => Returns `IfNever` branch
type C = IfNotAnyOrNever<never, 'VALID', 'IS_ANY', 'IS_NEVER'>;
//=> 'IS_NEVER'
```

Note: Wrapping a tail-recursive type with `IfNotAnyOrNever` makes the implementation non-tail-recursive. To fix this, move the recursion into a helper type. Refer to the following example:

@example
```ts
import type {StringRepeat} from 'type-fest';

type NineHundredNinetyNineSpaces = StringRepeat<' ', 999>;

// The following implementation is not tail recursive
type TrimLeft<S extends string> = IfNotAnyOrNever<S, S extends ` ${infer R}` ? TrimLeft<R> : S>;

// Hence, instantiations with long strings will fail
// @ts-expect-error
type T1 = TrimLeft<NineHundredNinetyNineSpaces>;
//        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Error: Type instantiation is excessively deep and possibly infinite.

// To fix this, move the recursion into a helper type
type TrimLeftOptimised<S extends string> = IfNotAnyOrNever<S, _TrimLeftOptimised<S>>;

type _TrimLeftOptimised<S extends string> = S extends ` ${infer R}` ? _TrimLeftOptimised<R> : S;

type T2 = TrimLeftOptimised<NineHundredNinetyNineSpaces>;
//=> ''
```
*/
type IfNotAnyOrNever<T$1, IfNotAnyOrNever$1, IfAny = any, IfNever = never> = If<IsAny<T$1>, IfAny, If<IsNever<T$1>, IfNever, IfNotAnyOrNever$1>>;
//#endregion
//#region ../../node_modules/type-fest/source/internal/array.d.ts
/**
Returns whether the given array `T` is readonly.
*/
type IsArrayReadonly<T$1 extends UnknownArray> = If<IsNever<T$1>, false, T$1 extends unknown[] ? false : true>;
//#endregion
//#region ../../node_modules/type-fest/source/simplify.d.ts
/**
Useful to flatten the type output to improve type hints shown in editors. And also to transform an interface into a type to aide with assignability.

@example
```
import type {Simplify} from 'type-fest';

type PositionProps = {
	top: number;
	left: number;
};

type SizeProps = {
	width: number;
	height: number;
};

// In your editor, hovering over `Props` will show a flattened object with all the properties.
type Props = Simplify<PositionProps & SizeProps>;
```

Sometimes it is desired to pass a value as a function argument that has a different type. At first inspection it may seem assignable, and then you discover it is not because the `value`'s type definition was defined as an interface. In the following example, `fn` requires an argument of type `Record<string, unknown>`. If the value is defined as a literal, then it is assignable. And if the `value` is defined as type using the `Simplify` utility the value is assignable.  But if the `value` is defined as an interface, it is not assignable because the interface is not sealed and elsewhere a non-string property could be added to the interface.

If the type definition must be an interface (perhaps it was defined in a third-party npm package), then the `value` can be defined as `const value: Simplify<SomeInterface> = ...`. Then `value` will be assignable to the `fn` argument.  Or the `value` can be cast as `Simplify<SomeInterface>` if you can't re-declare the `value`.

@example
```
import type {Simplify} from 'type-fest';

interface SomeInterface {
	foo: number;
	bar?: string;
	baz: number | undefined;
}

type SomeType = {
	foo: number;
	bar?: string;
	baz: number | undefined;
};

const literal = {foo: 123, bar: 'hello', baz: 456};
const someType: SomeType = literal;
const someInterface: SomeInterface = literal;

declare function fn(object: Record<string, unknown>): void;

fn(literal); // Good: literal object type is sealed
fn(someType); // Good: type is sealed
// @ts-expect-error
fn(someInterface); // Error: Index signature for type 'string' is missing in type 'someInterface'. Because `interface` can be re-opened
fn(someInterface as Simplify<SomeInterface>); // Good: transform an `interface` into a `type`
```

@link https://github.com/microsoft/TypeScript/issues/15300
@see {@link SimplifyDeep}
@category Object
*/
type Simplify<T$1> = { [KeyType in keyof T$1]: T$1[KeyType] } & {};
//#endregion
//#region ../../node_modules/type-fest/source/is-equal.d.ts
/**
Returns a boolean for whether the two given types are equal.

@link https://github.com/microsoft/TypeScript/issues/27024#issuecomment-421529650
@link https://stackoverflow.com/questions/68961864/how-does-the-equals-work-in-typescript/68963796#68963796

Use-cases:
- If you want to make a conditional branch based on the result of a comparison of two types.

@example
```
import type {IsEqual} from 'type-fest';

// This type returns a boolean for whether the given array includes the given item.
// `IsEqual` is used to compare the given array at position 0 and the given item and then return true if they are equal.
type Includes<Value extends readonly any[], Item> =
	Value extends readonly [Value[0], ...infer rest]
		? IsEqual<Value[0], Item> extends true
			? true
			: Includes<rest, Item>
		: false;
```

@category Type Guard
@category Utilities
*/
type IsEqual<A$1, B$1> = [A$1] extends [B$1] ? [B$1] extends [A$1] ? _IsEqual<A$1, B$1> : false : false;
// This version fails the `equalWrappedTupleIntersectionToBeNeverAndNeverExpanded` test in `test-d/is-equal.ts`.
type _IsEqual<A$1, B$1> = (<G>() => G extends A$1 & G | G ? 1 : 2) extends (<G>() => G extends B$1 & G | G ? 1 : 2) ? true : false;
//#endregion
//#region ../../node_modules/type-fest/source/omit-index-signature.d.ts
/**
Omit any index signatures from the given object type, leaving only explicitly defined properties.

This is the counterpart of `PickIndexSignature`.

Use-cases:
- Remove overly permissive signatures from third-party types.

This type was taken from this [StackOverflow answer](https://stackoverflow.com/a/68261113/420747).

It relies on the fact that an empty object (`{}`) is assignable to an object with just an index signature, like `Record<string, unknown>`, but not to an object with explicitly defined keys, like `Record<'foo' | 'bar', unknown>`.

(The actual value type, `unknown`, is irrelevant and could be any type. Only the key type matters.)

```
const indexed: Record<string, unknown> = {}; // Allowed

// @ts-expect-error
const keyed: Record<'foo', unknown> = {}; // Error
// => TS2739: Type '{}' is missing the following properties from type 'Record<"foo" | "bar", unknown>': foo, bar
```

Instead of causing a type error like the above, you can also use a [conditional type](https://www.typescriptlang.org/docs/handbook/2/conditional-types.html) to test whether a type is assignable to another:

```
type Indexed = {} extends Record<string, unknown>
	? '✅ `{}` is assignable to `Record<string, unknown>`'
	: '❌ `{}` is NOT assignable to `Record<string, unknown>`';
// => '✅ `{}` is assignable to `Record<string, unknown>`'

type Keyed = {} extends Record<'foo' | 'bar', unknown>
	? '✅ `{}` is assignable to `Record<\'foo\' | \'bar\', unknown>`'
	: '❌ `{}` is NOT assignable to `Record<\'foo\' | \'bar\', unknown>`';
// => "❌ `{}` is NOT assignable to `Record<'foo' | 'bar', unknown>`"
```

Using a [mapped type](https://www.typescriptlang.org/docs/handbook/2/mapped-types.html#further-exploration), you can then check for each `KeyType` of `ObjectType`...

```
type OmitIndexSignature<ObjectType> = {
	[KeyType in keyof ObjectType // Map each key of `ObjectType`...
	]: ObjectType[KeyType]; // ...to its original value, i.e. `OmitIndexSignature<Foo> == Foo`.
};
```

...whether an empty object (`{}`) would be assignable to an object with that `KeyType` (`Record<KeyType, unknown>`)...

```
type OmitIndexSignature<ObjectType> = {
	[KeyType in keyof ObjectType
	// Is `{}` assignable to `Record<KeyType, unknown>`?
	as {} extends Record<KeyType, unknown>
		? never // ✅ `{}` is assignable to `Record<KeyType, unknown>`
		: KeyType // ❌ `{}` is NOT assignable to `Record<KeyType, unknown>`
	]: ObjectType[KeyType];
};
```

If `{}` is assignable, it means that `KeyType` is an index signature and we want to remove it. If it is not assignable, `KeyType` is a "real" key and we want to keep it.

@example
```
import type {OmitIndexSignature} from 'type-fest';

type Example = {
	// These index signatures will be removed.
	[x: string]: any;
	[x: number]: any;
	[x: symbol]: any;
	[x: `head-${string}`]: string;
	[x: `${string}-tail`]: string;
	[x: `head-${string}-tail`]: string;
	[x: `${bigint}`]: string;
	[x: `embedded-${number}`]: string;

	// These explicitly defined keys will remain.
	foo: 'bar';
	qux?: 'baz';
};

type ExampleWithoutIndexSignatures = OmitIndexSignature<Example>;
// => { foo: 'bar'; qux?: 'baz' | undefined; }
```

@see {@link PickIndexSignature}
@category Object
*/
type OmitIndexSignature<ObjectType> = { [KeyType in keyof ObjectType as {} extends Record<KeyType, unknown> ? never : KeyType]: ObjectType[KeyType] };
//#endregion
//#region ../../node_modules/type-fest/source/pick-index-signature.d.ts
/**
Pick only index signatures from the given object type, leaving out all explicitly defined properties.

This is the counterpart of `OmitIndexSignature`.

@example
```
import type {PickIndexSignature} from 'type-fest';

declare const symbolKey: unique symbol;

type Example = {
	// These index signatures will remain.
	[x: string]: unknown;
	[x: number]: unknown;
	[x: symbol]: unknown;
	[x: `head-${string}`]: string;
	[x: `${string}-tail`]: string;
	[x: `head-${string}-tail`]: string;
	[x: `${bigint}`]: string;
	[x: `embedded-${number}`]: string;

	// These explicitly defined keys will be removed.
	['kebab-case-key']: string;
	[symbolKey]: string;
	foo: 'bar';
	qux?: 'baz';
};

type ExampleIndexSignature = PickIndexSignature<Example>;
// {
// 	[x: string]: unknown;
// 	[x: number]: unknown;
// 	[x: symbol]: unknown;
// 	[x: `head-${string}`]: string;
// 	[x: `${string}-tail`]: string;
// 	[x: `head-${string}-tail`]: string;
// 	[x: `${bigint}`]: string;
// 	[x: `embedded-${number}`]: string;
// }
```

@see {@link OmitIndexSignature}
@category Object
*/
type PickIndexSignature<ObjectType> = { [KeyType in keyof ObjectType as {} extends Record<KeyType, unknown> ? KeyType : never]: ObjectType[KeyType] };
//#endregion
//#region ../../node_modules/type-fest/source/merge.d.ts
// Merges two objects without worrying about index signatures.
type SimpleMerge<Destination, Source> = { [Key in keyof Destination as Key extends keyof Source ? never : Key]: Destination[Key] } & Source;

/**
Merge two types into a new type. Keys of the second type overrides keys of the first type.

@example
```
import type {Merge} from 'type-fest';

type Foo = {
	[x: string]: unknown;
	[x: number]: unknown;
	foo: string;
	bar: symbol;
};

type Bar = {
	[x: number]: number;
	[x: symbol]: unknown;
	bar: Date;
	baz: boolean;
};

export type FooBar = Merge<Foo, Bar>;
// => {
// 	[x: string]: unknown;
// 	[x: number]: number;
// 	[x: symbol]: unknown;
// 	foo: string;
// 	bar: Date;
// 	baz: boolean;
// }
```

@category Object
*/
type Merge<Destination, Source> = Simplify<SimpleMerge<PickIndexSignature<Destination>, PickIndexSignature<Source>> & SimpleMerge<OmitIndexSignature<Destination>, OmitIndexSignature<Source>>>;
//#endregion
//#region ../../node_modules/type-fest/source/internal/object.d.ts
/**
Works similar to the built-in `Pick` utility type, except for the following differences:
- Distributes over union types and allows picking keys from any member of the union type.
- Primitives types are returned as-is.
- Picks all keys if `Keys` is `any`.
- Doesn't pick `number` from a `string` index signature.

@example
```
type ImageUpload = {
	url: string;
	size: number;
	thumbnailUrl: string;
};

type VideoUpload = {
	url: string;
	duration: number;
	encodingFormat: string;
};

// Distributes over union types and allows picking keys from any member of the union type
type MediaDisplay = HomomorphicPick<ImageUpload | VideoUpload, "url" | "size" | "duration">;
//=> {url: string; size: number} | {url: string; duration: number}

// Primitive types are returned as-is
type Primitive = HomomorphicPick<string | number, 'toUpperCase' | 'toString'>;
//=> string | number

// Picks all keys if `Keys` is `any`
type Any = HomomorphicPick<{a: 1; b: 2} | {c: 3}, any>;
//=> {a: 1; b: 2} | {c: 3}

// Doesn't pick `number` from a `string` index signature
type IndexSignature = HomomorphicPick<{[k: string]: unknown}, number>;
//=> {}
*/
type HomomorphicPick<T$1, Keys extends KeysOfUnion<T$1>> = { [P in keyof T$1 as Extract<P, Keys>]: T$1[P] };
/**
Merges user specified options with default options.

@example
```
type PathsOptions = {maxRecursionDepth?: number; leavesOnly?: boolean};
type DefaultPathsOptions = {maxRecursionDepth: 10; leavesOnly: false};
type SpecifiedOptions = {leavesOnly: true};

type Result = ApplyDefaultOptions<PathsOptions, DefaultPathsOptions, SpecifiedOptions>;
//=> {maxRecursionDepth: 10; leavesOnly: true}
```

@example
```
// Complains if default values are not provided for optional options

type PathsOptions = {maxRecursionDepth?: number; leavesOnly?: boolean};
type DefaultPathsOptions = {maxRecursionDepth: 10};
type SpecifiedOptions = {};

type Result = ApplyDefaultOptions<PathsOptions, DefaultPathsOptions, SpecifiedOptions>;
//                                              ~~~~~~~~~~~~~~~~~~~
// Property 'leavesOnly' is missing in type 'DefaultPathsOptions' but required in type '{ maxRecursionDepth: number; leavesOnly: boolean; }'.
```

@example
```
// Complains if an option's default type does not conform to the expected type

type PathsOptions = {maxRecursionDepth?: number; leavesOnly?: boolean};
type DefaultPathsOptions = {maxRecursionDepth: 10; leavesOnly: 'no'};
type SpecifiedOptions = {};

type Result = ApplyDefaultOptions<PathsOptions, DefaultPathsOptions, SpecifiedOptions>;
//                                              ~~~~~~~~~~~~~~~~~~~
// Types of property 'leavesOnly' are incompatible. Type 'string' is not assignable to type 'boolean'.
```

@example
```
// Complains if an option's specified type does not conform to the expected type

type PathsOptions = {maxRecursionDepth?: number; leavesOnly?: boolean};
type DefaultPathsOptions = {maxRecursionDepth: 10; leavesOnly: false};
type SpecifiedOptions = {leavesOnly: 'yes'};

type Result = ApplyDefaultOptions<PathsOptions, DefaultPathsOptions, SpecifiedOptions>;
//                                                                   ~~~~~~~~~~~~~~~~
// Types of property 'leavesOnly' are incompatible. Type 'string' is not assignable to type 'boolean'.
```
*/
type ApplyDefaultOptions<Options extends object, Defaults extends Simplify<Omit<Required<Options>, RequiredKeysOf<Options>> & Partial<Record<RequiredKeysOf<Options>, never>>>, SpecifiedOptions extends Options> = If<IsAny<SpecifiedOptions>, Defaults, If<IsNever<SpecifiedOptions>, Defaults, Simplify<Merge<Defaults, { [Key in keyof SpecifiedOptions as Key extends OptionalKeysOf<Options> ? undefined extends SpecifiedOptions[Key] ? never : Key : Key]: SpecifiedOptions[Key] }> & Required<Options>>>>;
//#endregion
//#region ../../node_modules/type-fest/source/except.d.ts
/**
Filter out keys from an object.

Returns `never` if `Exclude` is strictly equal to `Key`.
Returns `never` if `Key` extends `Exclude`.
Returns `Key` otherwise.

@example
```
type Filtered = Filter<'foo', 'foo'>;
//=> never
```

@example
```
type Filtered = Filter<'bar', string>;
//=> never
```

@example
```
type Filtered = Filter<'bar', 'foo'>;
//=> 'bar'
```

@see {Except}
*/
type Filter<KeyType$1, ExcludeType> = IsEqual<KeyType$1, ExcludeType> extends true ? never : (KeyType$1 extends ExcludeType ? never : KeyType$1);
type ExceptOptions = {
  /**
  Disallow assigning non-specified properties.
  	Note that any omitted properties in the resulting type will be present in autocomplete as `undefined`.
  	@default false
  */
  requireExactProps?: boolean;
};
type DefaultExceptOptions = {
  requireExactProps: false;
};

/**
Create a type from an object type without certain keys.

We recommend setting the `requireExactProps` option to `true`.

This type is a stricter version of [`Omit`](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-5.html#the-omit-helper-type). The `Omit` type does not restrict the omitted keys to be keys present on the given type, while `Except` does. The benefits of a stricter type are avoiding typos and allowing the compiler to pick up on rename refactors automatically.

This type was proposed to the TypeScript team, which declined it, saying they prefer that libraries implement stricter versions of the built-in types ([microsoft/TypeScript#30825](https://github.com/microsoft/TypeScript/issues/30825#issuecomment-523668235)).

@example
```
import type {Except} from 'type-fest';

type Foo = {
	a: number;
	b: string;
};

type FooWithoutA = Except<Foo, 'a'>;
//=> {b: string}

// @ts-expect-error
const fooWithoutA: FooWithoutA = {a: 1, b: '2'};
//=> errors: 'a' does not exist in type '{ b: string; }'

type FooWithoutB = Except<Foo, 'b', {requireExactProps: true}>;
//=> {a: number} & Partial<Record<"b", never>>

// @ts-expect-error
const fooWithoutB: FooWithoutB = {a: 1, b: '2'};
//=> errors at 'b': Type 'string' is not assignable to type 'undefined'.

// The `Omit` utility type doesn't work when omitting specific keys from objects containing index signatures.

// Consider the following example:

type UserData = {
	[metadata: string]: string;
	email: string;
	name: string;
	role: 'admin' | 'user';
};

// `Omit` clearly doesn't behave as expected in this case:
type PostPayload = Omit<UserData, 'email'>;
//=> { [x: string]: string; [x: number]: string; }

// In situations like this, `Except` works better.
// It simply removes the `email` key while preserving all the other keys.
type PostPayloadFixed = Except<UserData, 'email'>;
//=> { [x: string]: string; name: string; role: 'admin' | 'user'; }
```

@category Object
*/
type Except<ObjectType, KeysType extends keyof ObjectType, Options extends ExceptOptions = {}> = _Except<ObjectType, KeysType, ApplyDefaultOptions<ExceptOptions, DefaultExceptOptions, Options>>;
type _Except<ObjectType, KeysType extends keyof ObjectType, Options extends Required<ExceptOptions>> = { [KeyType in keyof ObjectType as Filter<KeyType, KeysType>]: ObjectType[KeyType] } & (Options['requireExactProps'] extends true ? Partial<Record<KeysType, never>> : {});
//#endregion
//#region ../../node_modules/type-fest/source/require-at-least-one.d.ts
/**
Create a type that requires at least one of the given keys. The remaining keys are kept as is.

@example
```
import type {RequireAtLeastOne} from 'type-fest';

type Responder = {
	text?: () => string;
	json?: () => string;
	secure?: boolean;
};

const responder: RequireAtLeastOne<Responder, 'text' | 'json'> = {
	json: () => '{"message": "ok"}',
	secure: true,
};
```

@category Object
*/
type RequireAtLeastOne<ObjectType, KeysType extends keyof ObjectType = keyof ObjectType> = IfNotAnyOrNever<ObjectType, If<IsNever<KeysType>, never, _RequireAtLeastOne<ObjectType, If<IsAny<KeysType>, keyof ObjectType, KeysType>>>>;
type _RequireAtLeastOne<ObjectType, KeysType extends keyof ObjectType> = {
  // For each `Key` in `KeysType` make a mapped type:
[Key in KeysType]-?: Required<Pick<ObjectType, Key>> &
// 1. Make `Key`'s type required
// 2. Make all other keys in `KeysType` optional
Partial<Pick<ObjectType, Exclude<KeysType, Key>>> }[KeysType] &
// 3. Add the remaining keys not in `KeysType`
Except<ObjectType, KeysType>;
//#endregion
//#region ../../node_modules/type-fest/source/required-deep.d.ts
/**
Create a type from another type with all keys and nested keys set to required.

Use-cases:
- Creating optional configuration interfaces where the underlying implementation still requires all options to be fully specified.
- Modeling the resulting type after a deep merge with a set of defaults.

@example
```
import type {RequiredDeep} from 'type-fest';

type Settings = {
	textEditor?: {
		fontSize?: number;
		fontColor?: string;
		fontWeight?: number | undefined;
	};
	autocomplete?: boolean;
	autosave?: boolean | undefined;
};

type RequiredSettings = RequiredDeep<Settings>;
//=> {
// 	textEditor: {
// 		fontSize: number;
// 		fontColor: string;
// 		fontWeight: number | undefined;
// 	};
// 	autocomplete: boolean;
// 	autosave: boolean | undefined;
// }
```

Note that types containing overloaded functions are not made deeply required due to a [TypeScript limitation](https://github.com/microsoft/TypeScript/issues/29732).

@category Utilities
@category Object
@category Array
@category Set
@category Map
*/
type RequiredDeep<T$1> = T$1 extends BuiltIns ? T$1 : T$1 extends Map<infer KeyType, infer ValueType> ? Map<RequiredDeep<KeyType>, RequiredDeep<ValueType>> : T$1 extends Set<infer ItemType> ? Set<RequiredDeep<ItemType>> : T$1 extends ReadonlyMap<infer KeyType, infer ValueType> ? ReadonlyMap<RequiredDeep<KeyType>, RequiredDeep<ValueType>> : T$1 extends ReadonlySet<infer ItemType> ? ReadonlySet<RequiredDeep<ItemType>> : T$1 extends WeakMap<infer KeyType, infer ValueType> ? WeakMap<RequiredDeep<KeyType>, RequiredDeep<ValueType>> : T$1 extends WeakSet<infer ItemType> ? WeakSet<RequiredDeep<ItemType>> : T$1 extends Promise<infer ValueType> ? Promise<RequiredDeep<ValueType>> : T$1 extends ((...arguments_: any[]) => unknown) ? IsNever<keyof T$1> extends true ? T$1 : HasMultipleCallSignatures<T$1> extends true ? T$1 : ((...arguments_: Parameters<T$1>) => ReturnType<T$1>) & RequiredObjectDeep<T$1> : T$1 extends object ? RequiredObjectDeep<T$1> : unknown;
type RequiredObjectDeep<ObjectType extends object> = { [KeyType in keyof ObjectType]-?: RequiredDeep<ObjectType[KeyType]> };
//#endregion
//#region ../../node_modules/type-fest/source/set-optional.d.ts
/**
Create a type that makes the given keys optional. The remaining keys are kept as is. The sister of the `SetRequired` type.

Use-case: You want to define a single model where the only thing that changes is whether or not some of the keys are optional.

@example
```
import type {SetOptional} from 'type-fest';

type Foo = {
	a: number;
	b?: string;
	c: boolean;
};

type SomeOptional = SetOptional<Foo, 'b' | 'c'>;
// type SomeOptional = {
// 	a: number;
// 	b?: string; // Was already optional and still is.
// 	c?: boolean; // Is now optional.
// }
```

@category Object
*/
type SetOptional<BaseType, Keys extends keyof BaseType> = (BaseType extends ((...arguments_: never) => any) ? (...arguments_: Parameters<BaseType>) => ReturnType<BaseType> : unknown) & _SetOptional<BaseType, Keys>;
type _SetOptional<BaseType, Keys extends keyof BaseType> = BaseType extends unknown // To distribute `BaseType` when it's a union type.
? Simplify<
// Pick just the keys that are readonly from the base type.
Except<BaseType, Keys> &
// Pick the keys that should be mutable from the base type and make them mutable.
Partial<HomomorphicPick<BaseType, Keys>>> : never;
//#endregion
//#region ../../node_modules/type-fest/source/set-required.d.ts
/**
Create a type that makes the given keys required. The remaining keys are kept as is. The sister of the `SetOptional` type.

Use-case: You want to define a single model where the only thing that changes is whether or not some of the keys are required.

@example
```
import type {SetRequired} from 'type-fest';

type Foo = {
	a?: number;
	b: string;
	c?: boolean;
};

type SomeRequired = SetRequired<Foo, 'b' | 'c'>;
// type SomeRequired = {
// 	a?: number;
// 	b: string; // Was already required and still is.
// 	c: boolean; // Is now required.
// }

// Set specific indices in an array to be required.
type ArrayExample = SetRequired<[number?, number?, number?], 0 | 1>;
//=> [number, number, number?]
```

@category Object
*/
type SetRequired<BaseType, Keys extends keyof BaseType> = (BaseType extends ((...arguments_: never) => any) ? (...arguments_: Parameters<BaseType>) => ReturnType<BaseType> : unknown) & _SetRequired<BaseType, Keys>;
type _SetRequired<BaseType, Keys extends keyof BaseType> = BaseType extends UnknownArray ? SetArrayRequired<BaseType, Keys> extends infer ResultantArray ? If<IsArrayReadonly<BaseType>, Readonly<ResultantArray>, ResultantArray> : never : Simplify<
// Pick just the keys that are optional from the base type.
Except<BaseType, Keys> &
// Pick the keys that should be required from the base type and make them required.
Required<HomomorphicPick<BaseType, Keys>>>;

/**
Remove the optional modifier from the specified keys in an array.
*/
type SetArrayRequired<TArray extends UnknownArray, Keys, Counter extends any[] = [], Accumulator extends UnknownArray = []> = TArray extends unknown // For distributing `TArray` when it's a union
? keyof TArray & `${number}` extends never
// Exit if `TArray` is empty (e.g., []), or
// `TArray` contains no non-rest elements preceding the rest element (e.g., `[...string[]]` or `[...string[], string]`).
? [...Accumulator, ...TArray] : TArray extends readonly [(infer First)?, ...infer Rest] ? '0' extends OptionalKeysOf<TArray> // If the first element of `TArray` is optional
? `${Counter['length']}` extends `${Keys & (string | number)}` // If the current index needs to be required
? SetArrayRequired<Rest, Keys, [...Counter, any], [...Accumulator, First]>
// If the current element is optional, but it doesn't need to be required,
// then we can exit early, since no further elements can now be made required.
: [...Accumulator, ...TArray] : SetArrayRequired<Rest, Keys, [...Counter, any], [...Accumulator, TArray[0]]> : never // Should never happen, since `[(infer F)?, ...infer R]` is a top-type for arrays.
: never; // Should never happen
//#endregion
//#region ../../node_modules/type-fest/source/set-non-nullable.d.ts
/**
Create a type that makes the given keys non-nullable, where the remaining keys are kept as is.

If no keys are given, all keys will be made non-nullable.

Use-case: You want to define a single model where the only thing that changes is whether or not some or all of the keys are non-nullable.

@example
```
import type {SetNonNullable} from 'type-fest';

type Foo = {
	a: number | null;
	b: string | undefined;
	c?: boolean | null;
};

type SomeNonNullable = SetNonNullable<Foo, 'b' | 'c'>;
// type SomeNonNullable = {
// 	a: number | null;
// 	b: string; // Can no longer be undefined.
// 	c?: boolean; // Can no longer be null, but is still optional.
// }

type AllNonNullable = SetNonNullable<Foo>;
// type AllNonNullable = {
// 	a: number; // Can no longer be null.
// 	b: string; // Can no longer be undefined.
// 	c?: boolean; // Can no longer be null, but is still optional.
// }
```

@category Object
*/
type SetNonNullable<BaseType, Keys extends keyof BaseType = keyof BaseType> = { [Key in keyof BaseType]: Key extends Keys ? NonNullable<BaseType[Key]> : BaseType[Key] };
//#endregion
//#region ../core/src/types/options.d.ts
type RequireAtLeastOne$1<ObjectType, KeysType extends keyof ObjectType> = { [Key in KeysType]-?: Required<Pick<ObjectType, Key>> & Partial<Pick<ObjectType, Exclude<KeysType, Key>>> }[KeysType] & Except<ObjectType, KeysType>;
type StringUnionToFlexibleOptionArray<Op extends string> = Array<Op extends unknown ? FlexibleOption<Op> : never>;
type StringUnionToFullOptionArray<Op extends string> = Array<Op extends unknown ? FullOption<Op> : never>;
/**
* Extracts the {@link Option} type from a {@link FlexibleOptionList}.
*
* @group Option Lists
*/
type GetOptionType<OL extends FlexibleOptionList<FullOption>> = OL extends FlexibleOptionList<infer Opt> ? Opt : never;
/**
* Extracts the type of the identifying property from a {@link Option},
* {@link ValueOption}, or {@link FullOption}.
*
* @group Option Lists
*/
type GetOptionIdentifierType<Opt$1 extends BaseOption> = Opt$1 extends Option<infer NameType> | ValueOption<infer NameType> ? NameType : string;
/**
* Adds an `unknown` index property to an interface.
*/
type WithUnknownIndex<T$1> = T$1 & {
  [key: string]: unknown;
};
/**
* Do not use this type directly; use {@link Option}, {@link ValueOption},
* or {@link FullOption} instead. For specific option types, you can use
* {@link FullField}, {@link FullOperator}, or {@link FullCombinator},
* all of which extend {@link FullOption}.
*
* @group Option Lists
*/
interface BaseOption<N extends string = string> {
  name?: N;
  value?: N;
  label: string;
  disabled?: boolean;
}
/**
* A generic option. Used directly in {@link OptionList} or
* as the child element of an {@link OptionGroup}.
*
* @group Option Lists
*/
type Option<N extends string = string> = Simplify<WithUnknownIndex<SetRequired<BaseOption<N>, "name">>>;
/**
* Like {@link Option} but requiring `value` instead of `name`.
*
* @group Option Lists
*/
type ValueOption<N extends string = string> = Simplify<WithUnknownIndex<SetRequired<BaseOption<N>, "value">>>;
/**
* A generic {@link Option} with either a `name` or `value` as its primary identifier.
* {@link OptionList}-type props on the {@link react-querybuilder!QueryBuilder QueryBuilder} component accept this type,
* but corresponding props passed down to subcomponents will always be augmented
* to {@link FullOption} first.
*
* @group Option Lists
*/
type FlexibleOption<N extends string = string> = Simplify<WithUnknownIndex<RequireAtLeastOne$1<BaseOption<N>, "name" | "value">>>;
/**
* Utility type to turn an {@link Option}, {@link ValueOption}, or {@link BaseOption}
* into a {@link FlexibleOption}.
*
* @group Option Lists
*/
type ToFlexibleOption<Opt$1 extends BaseOption | string> = WithUnknownIndex<RequireAtLeastOne$1<Opt$1 extends string ? FlexibleOption<Opt$1> : Opt$1, "name" | "value">>;
/**
* A generic {@link Option} requiring both `name` _and_ `value` properties.
* Props that extend {@link OptionList} accept {@link BaseOption}, but
* corresponding props sent to subcomponents will always be augmented to this
* type first to ensure both `name` and `value` are available.
*
* NOTE: Do not extend from this type directly. Use {@link BaseFullOption}
* (optionally wrapped in {@link WithUnknownIndex}) instead, otherwise
* the `unknown` index property will cause issues. See {@link Option} and
* {@link ValueOption} for examples.
*
* @group Option Lists
*/
type FullOption<N extends string = string> = Simplify<WithUnknownIndex<SetRequired<BaseOption<N>, "name" | "value">>>;
/**
* This type is identical to {@link FullOption} but without the `unknown` index
* property. Extend from this type instead of {@link FullOption} directly.
*
* @group Option Lists
*/
type BaseFullOption<N extends string = string> = Simplify<SetRequired<BaseOption<N>, "name" | "value">>;
/**
* Utility type to turn an {@link Option}, {@link ValueOption} or
* {@link BaseOption} into a {@link FullOption}.
*
* @group Option Lists
*/
type ToFullOption<Opt$1 extends BaseOption> = Opt$1 extends BaseFullOption ? Opt$1 : Opt$1 extends BaseOption<infer IdentifierType> ? WithUnknownIndex<Opt$1 & FullOption<IdentifierType>> : never;
/**
* @deprecated Renamed to {@link Option}.
*
* @group Option Lists
*/
type NameLabelPair<N extends string = string> = Option<N>;
/**
* A group of {@link Option}s, usually within an {@link OptionList}.
*
* @group Option Lists
*/
interface OptionGroup<Opt$1 extends BaseOption = FlexibleOption> {
  label: string;
  options: WithUnknownIndex<Opt$1>[];
}
/**
* A group of {@link BaseOption}s, usually within a {@link FlexibleOptionList}.
*
* @group Option Lists
*/
type FlexibleOptionGroup<Opt$1 extends BaseOption | string = BaseOption> = {
  label: string;
  options: (Opt$1 extends BaseFullOption ? Opt$1 : ToFlexibleOption<Opt$1>)[];
};
/**
* Either an array of {@link Option}s or an array of {@link OptionGroup}s.
*
* @group Option Lists
*/
type OptionList<Opt$1 extends Option = Option> = Opt$1[] | OptionGroup<Opt$1>[];
/**
* An array of options or option groups, like {@link OptionList} but the option type
* may use either `name` or `value` as the primary identifier.
*
* @group Option Lists
*/
type FlexibleOptionList<Opt$1 extends BaseOption> = ToFlexibleOption<Opt$1>[] | FlexibleOptionGroup<ToFlexibleOption<Opt$1>>[];
/**
* An array of options or option groups, like {@link OptionList} but the option type
* may use either `name` or `value` as the primary identifier.
*
* @group Option Lists
*/
type FlexibleOptionListProp<Opt$1 extends BaseOption> = (ToFlexibleOption<Opt$1> | GetOptionIdentifierType<Opt$1>)[] | FlexibleOptionGroup<ToFlexibleOption<Opt$1> | GetOptionIdentifierType<Opt$1>>[];
/**
* An array of options or option groups, like {@link OptionList}, but using
* {@link FullOption} instead of {@link Option}. This means that every member is
* guaranteed to have both `name` and `value`.
*
* @group Option Lists
*/
type FullOptionList<Opt$1 extends BaseOption> = Opt$1 extends BaseFullOption ? Opt$1[] | OptionGroup<Opt$1>[] : ToFullOption<Opt$1>[] | OptionGroup<ToFullOption<Opt$1>>[];
/**
* Map of option identifiers to their respective {@link Option}.
*
* @group Option Lists
*/
type BaseOptionMap<V$1 extends BaseOption = BaseOption, K$1 extends string = GetOptionIdentifierType<V$1>> = { [k in K$1]?: ToFlexibleOption<V$1> };
/**
* Map of option identifiers to their respective {@link FullOption}.
*
* @group Option Lists
*/
type FullOptionMap<V$1 extends BaseFullOption, K$1 extends string = GetOptionIdentifierType<V$1>> = { [k in K$1]?: V$1 };
/**
* Map of option identifiers to their respective {@link FullOption}.
* Must include all possible strings from the identifier type.
*
* @group Option Lists
*/
type FullOptionRecord<V$1 extends BaseFullOption, K$1 extends string = GetOptionIdentifierType<V$1>> = Record<K$1, V$1>;
//#endregion
//#region ../core/src/types/ruleGroups.d.ts
/**
* Properties common to both rules and groups.
*/
interface CommonRuleAndGroupProperties {
  path?: Path;
  id?: string;
  disabled?: boolean;
  /**
  * Whether this rule or group is muted. When muted, the rule or group
  * is excluded from query export formats (SQL, JSON, MongoDB, etc.).
  * For groups, muting recursively mutes all children.
  */
  muted?: boolean;
}
/**
* The main rule type. The `field`, `operator`, and `value` properties
* can be narrowed with generics.
*/
interface RuleType<F extends string = string, O extends string = string, V$1 = any, C extends string = string> extends CommonRuleAndGroupProperties {
  field: F;
  operator: O;
  value: V$1;
  valueSource?: ValueSource;
  match?: MatchConfig;
  /**
  * Only used when adding a rule to a query that uses independent combinators.
  */
  combinatorPreceding?: C;
}
/**
* The main rule group type. This type is used for query definitions as well as
* all sub-groups of queries.
*/
interface RuleGroupType<R$1 extends RuleType = RuleType, C extends string = string> extends CommonRuleAndGroupProperties {
  combinator: C;
  rules: RuleGroupArray<RuleGroupType<R$1, C>, R$1>;
  not?: boolean;
}
/**
* The type of the `rules` array in a {@link RuleGroupType}.
*/
type RuleGroupArray<RG extends RuleGroupType = RuleGroupType, R$1 extends RuleType = RuleType> = (R$1 | RG)[];
/**
* All updateable properties of rules and groups (everything except
* `id`, `path`, and `rules`).
*/
type UpdateableProperties = Exclude<keyof (RuleType & RuleGroupType), "id" | "path" | "rules">;
/**
* The type of the `rules` array in a {@link DefaultRuleGroupType}.
*/
type DefaultRuleGroupArray<F extends string = string> = RuleGroupArray<DefaultRuleGroupType, DefaultRuleType<F>>;
/**
* {@link RuleGroupType} with the `combinator` property limited to
* {@link DefaultCombinatorNameExtended} and `rules` limited to {@link DefaultRuleType}.
*/
type DefaultRuleGroupType<F extends string = string> = RuleGroupType<DefaultRuleType<F>, DefaultCombinatorNameExtended> & {
  rules: DefaultRuleGroupArray<F>;
};
/**
* {@link RuleType} with the `operator` property limited to {@link DefaultOperatorName}.
*/
type DefaultRuleType<F extends string = string> = RuleType<F, DefaultOperatorName>;
/**
* Default allowed values for the `combinator` property.
*
* @group Option Lists
*/
type DefaultCombinatorName = "and" | "or";
/**
* Default allowed values for the `combinator` property, plus `"xor"`.
*
* @group Option Lists
*/
type DefaultCombinatorNameExtended = DefaultCombinatorName | "xor";
/**
* Default values for the `operator` property.
*
* @group Option Lists
*/
type DefaultOperatorName = "=" | "!=" | "<" | ">" | "<=" | ">=" | "contains" | "beginsWith" | "endsWith" | "doesNotContain" | "doesNotBeginWith" | "doesNotEndWith" | "null" | "notNull" | "in" | "notIn" | "between" | "notBetween";
/**
* A {@link FullCombinator} definition with a {@link DefaultCombinatorName} `name` property.
*
* @group Option Lists
*/
type DefaultCombinator = FullCombinator<DefaultCombinatorName>;
/**
* A {@link FullCombinator} definition with a {@link DefaultCombinatorNameExtended} `name` property.
*
* @group Option Lists
*/
type DefaultCombinatorExtended = FullCombinator<DefaultCombinatorNameExtended>;
/**
* An {@link FullOperator} definition with a {@link DefaultOperatorName} `name` property.
*
* @group Option Lists
*/
type DefaultOperator = FullOperator<DefaultOperatorName>;
//#endregion
//#region ../core/src/types/ruleGroupsIC.utils.d.ts
type MAXIMUM_ALLOWED_BOUNDARY = 80;
type MappedTuple<Tuple$1 extends Array<unknown>, Result extends Array<unknown> = [], Count extends ReadonlyArray<number> = []> = Count["length"] extends MAXIMUM_ALLOWED_BOUNDARY ? Result : Tuple$1 extends [] ? [] : Result extends [] ? MappedTuple<Tuple$1, Tuple$1, [...Count, 1]> : MappedTuple<Tuple$1, Result | [...Result, ...Tuple$1], [...Count, 1]>;
//#endregion
//#region ../core/src/types/ruleGroupsIC.d.ts
/**
* The main rule group interface when using independent combinators. This type is used
* for query definitions as well as all sub-groups of queries.
*/
interface RuleGroupTypeIC<R$1 extends RuleType = RuleType, C extends string = string> extends Except<RuleGroupType<R$1, C>, "combinator" | "rules"> {
  combinator?: undefined;
  rules: RuleGroupICArray<RuleGroupTypeIC<R$1, C>, R$1, C>;
  /**
  * Only used when adding a rule to a query that uses independent combinators
  */
  combinatorPreceding?: C;
}
/**
* Shorthand for "either {@link RuleGroupType} or {@link RuleGroupTypeIC}".
*/
type RuleGroupTypeAny<R$1 extends RuleType = RuleType, C extends string = string> = RuleGroupType<R$1, C> | RuleGroupTypeIC<R$1, C>;
/**
* The type of the `rules` array in a {@link RuleGroupTypeIC}.
*/
type RuleGroupICArray<RG extends RuleGroupTypeIC = RuleGroupTypeIC, R$1 extends RuleType = RuleType, C extends string = string> = [R$1 | RG] | [R$1 | RG, ...MappedTuple<[C, R$1 | RG]>] | ((R$1 | RG)[] & {
  length: 0;
});
/**
* Shorthand for "either {@link RuleGroupArray} or {@link RuleGroupICArray}".
*/
type RuleOrGroupArray = RuleGroupArray | RuleGroupICArray;
/**
* The type of the `rules` array in a {@link DefaultRuleGroupTypeIC}.
*/
type DefaultRuleGroupICArray<F extends string = string> = RuleGroupICArray<DefaultRuleGroupTypeIC<F>, DefaultRuleType<F>, DefaultCombinatorName>;
/**
* Shorthand for "either {@link DefaultRuleGroupArray} or {@link DefaultRuleGroupICArray}".
*/
type DefaultRuleOrGroupArray<F extends string = string> = DefaultRuleGroupArray<F> | DefaultRuleGroupICArray<F>;
/**
* {@link RuleGroupTypeIC} with combinators limited to
* {@link DefaultCombinatorName} and rules limited to {@link DefaultRuleType}.
*/
interface DefaultRuleGroupTypeIC<F extends string = string> extends RuleGroupTypeIC<DefaultRuleType<F>> {
  rules: DefaultRuleGroupICArray<F>;
}
/**
* Shorthand for "either {@link DefaultRuleGroupType} or {@link DefaultRuleGroupTypeIC}".
*/
type DefaultRuleGroupTypeAny<F extends string = string> = DefaultRuleGroupType<F> | DefaultRuleGroupTypeIC<F>;
/**
* Determines if a type extending {@link RuleGroupTypeAny} is actually
* {@link RuleGroupType} or {@link RuleGroupTypeIC}.
*/
type GetRuleGroupType<RG> = RG extends {
  combinator: string;
} ? RuleGroupType : RuleGroupTypeIC;
/**
* Determines the {@link RuleType} of a given {@link RuleGroupType}
* or {@link RuleGroupTypeIC}. If the field and operator name types of
* the rule type extend the identifier types of the provided Field and
* Operator types, the given rule type is returned as is. Otherwise,
* the rule type has its field and operator types narrowed to the
* identifier types of the provided Field and Operator types.
*/
type GetRuleTypeFromGroupWithFieldAndOperator<RG extends RuleGroupTypeAny, F extends BaseOption, O extends BaseOption> = RG extends RuleGroupType<infer RT> | RuleGroupTypeIC<infer RT> ? RT extends RuleType<infer RuleFieldName, infer RuleOperatorName, infer RuleValueName, infer RuleCombinatorName> ? RuleFieldName extends GetOptionIdentifierType<F> ? RuleOperatorName extends GetOptionIdentifierType<O> ? RuleType<RuleFieldName, RuleOperatorName, RuleValueName, RuleCombinatorName> : RuleType<RuleFieldName, GetOptionIdentifierType<O>, RuleValueName, RuleCombinatorName> : RuleOperatorName extends GetOptionIdentifierType<O> ? RuleType<GetOptionIdentifierType<F>, RuleOperatorName, RuleValueName, RuleCombinatorName> : RuleType<GetOptionIdentifierType<F>, GetOptionIdentifierType<O>, RuleValueName, RuleCombinatorName> : never : never;
/**
* Converts a narrowed rule group type to its most generic form.
*/
type GenericizeRuleGroupType<RG> = RG extends RuleGroupType ? RuleGroupType : RuleGroupTypeIC;
//#endregion
//#region ../core/src/types/validation.d.ts
/**
* Object with a `valid` boolean value and optional `reasons`.
*/
interface ValidationResult {
  valid: boolean;
  reasons?: any[];
}
/**
* Map of rule/group `id` to its respective {@link ValidationResult}.
*/
type ValidationMap = Record<string, boolean | ValidationResult>;
/**
* Function that validates a query.
*/
type QueryValidator = (query: RuleGroupTypeAny) => boolean | ValidationMap;
/**
* Function that validates a rule.
*/
type RuleValidator = (rule: RuleType) => boolean | ValidationResult;
//#endregion
//#region ../core/src/types/basic.d.ts
/**
* @see https://react-querybuilder.js.org/docs/tips/path
*/
type Path = number[];
/**
* String of classnames, array of classname strings, or object where the
* keys are classnames and those with truthy values will be included.
* Suitable for passing to the `clsx` package.
*/
type Classname = string | string[] | Record<string, any>;
/**
* A source for the `value` property of a rule.
*/
type ValueSource = "value" | "field";
/**
* Type of {@link react-querybuilder!ValueEditor ValueEditor} that will be displayed.
*/
type ValueEditorType = "text" | "select" | "checkbox" | "radio" | "textarea" | "switch" | "multiselect" | null;
/**
* A valid array of potential value sources.
*
* @see {@link ValueSource}
*/
type ValueSources = ["value"] | ["value", "field"] | ["field", "value"] | ["field"];
type ValueSourceFlexibleOptions = ToFlexibleOptionArrays<ValueSources>;
type ValueSourceFullOptions = ToOptionArrays<ValueSources>;
type ToOptionArrays<Sources extends readonly string[]> = Sources extends unknown ? { [K in keyof Sources]: {
  name: Sources[K];
  value: Sources[K];
  label: string;
} } : never;
type ToFlexibleOptionArrays<Sources extends readonly string[]> = Sources extends unknown ? { [K in keyof Sources]: FlexibleOption<Sources[K]> } : never;
type WithOptionalClassName<T$1> = T$1 & {
  className?: Classname;
};
/**
* HTML5 input types
*/
type InputType = "button" | "checkbox" | "color" | "date" | "datetime-local" | "email" | "file" | "hidden" | "image" | "month" | "number" | "password" | "radio" | "range" | "reset" | "search" | "submit" | "tel" | "text" | "time" | "url" | "week" | "bigint" | (string & {});
/**
* Quantification mode describing how many elements of the value array must pass
* the filter for the rule itself to pass.
*
* For "atLeast", "atMost", and "exactly", the threshold value will be converted to
* a percentage if the number is less than 1. Non-numeric values and numbers less
* than 0 will be ignored.
*/
interface MatchConfig {
  mode: MatchMode;
  threshold?: number | null | undefined;
}
type MatchMode = "all" | "some" | "none" | "atLeast" | "atMost" | "exactly";
type MatchModeOptions = StringUnionToFullOptionArray<MatchMode>;
type ActionElementEventHandler = (event?: any, context?: any) => void;
type ValueChangeEventHandler = (value?: any, context?: any) => void;
/**
* Base for all Field types/interfaces.
*/
interface BaseFullField<FieldName extends string = string, OperatorName$1 extends string = string, ValueName extends string = string, OperatorObj extends FullOption = FullOption<OperatorName$1>, ValueObj extends FullOption = FullOption<ValueName>> extends WithOptionalClassName<BaseFullOption<FieldName>> {
  id?: string;
  operators?: FlexibleOptionList<OperatorObj> | OperatorName$1[] | FlexibleOption<OperatorName$1>[] | (OperatorName$1 | FlexibleOption<OperatorName$1>)[];
  valueEditorType?: ValueEditorType | ((operator: OperatorName$1) => ValueEditorType);
  valueSources?: ValueSources | ValueSourceFlexibleOptions | ((operator: OperatorName$1) => ValueSources | ValueSourceFlexibleOptions);
  inputType?: InputType | null;
  values?: FlexibleOptionList<ValueObj>;
  matchModes?: boolean | MatchMode[] | FlexibleOption<MatchMode>[];
  /** Properties of items in the value. */
  subproperties?: FlexibleOptionList<FullField>;
  defaultOperator?: OperatorName$1;
  defaultValue?: any;
  placeholder?: string;
  validator?: RuleValidator;
  comparator?: string | ((f: FullField, operator: string) => boolean);
}
/**
* Full field definition used in the `fields` prop of {@link react-querybuilder!QueryBuilder QueryBuilder}.
* This type requires both `name` and `value`, but the `fields` prop itself
* can use a {@link FlexibleOption} where only one of `name` or `value` is
* required (along with `label`), or {@link Field} where only `name` and
* `label` are required.
*
* The `name`/`value`, `operators`, and `values` properties of this interface
* can be narrowed with generics.
*
* @group Option Lists
*/
type FullField<FieldName extends string = string, OperatorName$1 extends string = string, ValueName extends string = string, OperatorObj extends FullOption = FullOption<OperatorName$1>, ValueObj extends FullOption = FullOption<ValueName>> = Simplify<FullOption<FieldName> & BaseFullField<FieldName, OperatorName$1, ValueName, OperatorObj, ValueObj>>;
/**
* Field definition used in the `fields` prop of {@link react-querybuilder!QueryBuilder QueryBuilder}.
* This type is an extension of {@link FullField} where only `name` and
* `label` are required.
*
* The `name`/`value`, `operators`, and `values` properties of this interface
* can be narrowed with generics.
*
* @group Option Lists
*/
type Field<FieldName extends string = string, OperatorName$1 extends string = string, ValueName extends string = string, OperatorObj extends FullOption = FullOption<OperatorName$1>> = WithUnknownIndex<{
  value?: FieldName;
} & Pick<BaseFullField<FieldName, OperatorName$1, ValueName, OperatorObj>, Exclude<keyof BaseFullField, "value">>>;
/**
* Field definition used in the `fields` prop of {@link react-querybuilder!QueryBuilder QueryBuilder}.
* This type is an extension of {@link FullField} where only `value` and
* `label` are required.
*
* The `name`/`value`, `operators`, and `values` properties of this interface
* can be narrowed with generics.
*
* @group Option Lists
*/
type FieldByValue<FieldName extends string = string, OperatorName$1 extends string = string, ValueName extends string = string, OperatorObj extends FullOption = FullOption<OperatorName$1>> = WithUnknownIndex<{
  name?: FieldName;
} & Pick<BaseFullField<FieldName, OperatorName$1, ValueName, OperatorObj>, Exclude<keyof BaseFullField, "name">>>;
/**
* Utility type to make one or more properties required.
*/
type WithRequired<T$1, K$1 extends keyof T$1> = T$1 & { [P in K$1]-?: T$1[P] };
/**
* Utility type to make all properties non-nullable.
*/
type RemoveNullability<T$1 extends Record<string, unknown>> = { [k in keyof T$1]: NonNullable<T$1[k]> };
/**
* Allowed values of the {@link FullOperator} property `arity`. A value of `"unary"` or
* a number less than two will cause the default {@link react-querybuilder!ValueEditor ValueEditor} to render `null`.
*/
type Arity = number | "unary" | "binary" | "ternary";
/**
* Full operator definition used in the `operators`/`getOperators` props of
* {@link react-querybuilder!QueryBuilder QueryBuilder}. This type requires both `name` and `value`, but the
* `operators`/`getOperators` props themselves can use a {@link FlexibleOption}
* where only one of `name` or `value` is required, or {@link FullOperator} where
* only `name` is required.
*
* The `name`/`value` properties of this interface can be narrowed with generics.
*
* @group Option Lists
*/
interface FullOperator<N extends string = string> extends WithOptionalClassName<FullOption<N>> {
  arity?: Arity;
}
/**
* Operator definition used in the `operators`/`getOperators` props of
* {@link react-querybuilder!QueryBuilder QueryBuilder}. This type is an extension of {@link FullOperator}
* where only `name` and `label` are required.
*
* The `name`/`value` properties of this interface can be narrowed with generics.
*
* @group Option Lists
*/
type Operator<N extends string = string> = WithUnknownIndex<SetOptional<BaseFullOption<N>, "value"> & WithOptionalClassName<{
  arity?: Arity;
}>>;
/**
* Operator definition used in the `operators`/`getOperators` props of
* {@link react-querybuilder!QueryBuilder QueryBuilder}. This type is an extension of {@link FullOperator}
* where only `value` and `label` are required.
*
* The `name`/`value` properties of this interface can be narrowed with generics.
*
* @group Option Lists
*/
type OperatorByValue<N extends string = string> = WithUnknownIndex<SetOptional<BaseFullOption<N>, "name"> & WithOptionalClassName<{
  arity?: Arity;
}>>;
/**
* Full combinator definition used in the `combinators` prop of {@link react-querybuilder!QueryBuilder QueryBuilder}.
* This type requires both `name` and `value`, but the `combinators` prop itself
* can use a {@link FlexibleOption} where only one of `name` or `value` is required,
* or {@link Combinator} where only `name` is required.
*
* The `name`/`value` properties of this interface can be narrowed with generics.
*
* @group Option Lists
*/
type FullCombinator<N extends string = string> = WithOptionalClassName<FullOption<N>>;
/**
* Combinator definition used in the `combinators` prop of {@link react-querybuilder!QueryBuilder QueryBuilder}.
* This type is an extension of {@link FullCombinator} where only `name` and
* `label` are required.
*
* The `name`/`value` properties of this interface can be narrowed with generics.
*
* @group Option Lists
*/
type Combinator<N extends string = string> = WithUnknownIndex<WithOptionalClassName<SetOptional<BaseFullOption<N>, "value">>>;
/**
* Combinator definition used in the `combinators` prop of {@link react-querybuilder!QueryBuilder QueryBuilder}.
* This type is an extension of {@link FullCombinator} where only `value` and
* `label` are required.
*
* The `name`/`value` properties of this interface can be narrowed with generics.
*
* @group Option Lists
*/
type CombinatorByValue<N extends string = string> = WithUnknownIndex<WithOptionalClassName<SetOptional<BaseFullOption<N>, "name">>>;
type ParseNumberMethodName = "enhanced" | "native" | "strict";
/**
* Parsing algorithms used by {@link parseNumber}.
*/
type ParseNumberMethod = boolean | ParseNumberMethodName;
type ParseNumbersModerationLevel = "-limited" | "";
/**
* Options for the `parseNumbers` prop of {@link react-querybuilder!QueryBuilder QueryBuilder}.
*/
type ParseNumbersPropConfig = boolean | `${ParseNumberMethodName}${ParseNumbersModerationLevel}`;
/**
* Signature of `accessibleDescriptionGenerator` prop, used by {@link react-querybuilder!QueryBuilder QueryBuilder} to generate
* accessible descriptions for each {@link react-querybuilder!RuleGroup RuleGroup}.
*/
type AccessibleDescriptionGenerator = (props: {
  path: Path;
  qbId: string;
}) => string;
//#endregion
//#region ../core/src/types/dnd.d.ts
type DndDropTargetType = "rule" | "ruleGroup" | "inlineCombinator";
type DraggedItem = (RuleType & {
  path: Path;
  qbId: string;
}) | (RuleGroupTypeAny & {
  path: Path;
  qbId: string;
});
type DropEffect = "move" | "copy";
interface DropResult {
  path: Path;
  type: DndDropTargetType;
  dropEffect?: DropEffect;
  groupItems?: boolean;
  qbId: string;
  getQuery: () => RuleGroupTypeAny;
  dispatchQuery: (query: RuleGroupTypeAny) => void;
}
interface DragCollection {
  isDragging: boolean;
  dragMonitorId: string | symbol;
}
interface DropCollection {
  dropNotAllowed: boolean;
  isOver: boolean;
  dropMonitorId: string | symbol;
  dropEffect?: DropEffect;
  groupItems?: boolean;
}
//#endregion
//#region ../core/src/types/export.d.ts
/**
* Available export formats for {@link formatQuery}.
*
* @group Export
*/
type ExportFormat = "json" | "sql" | "json_without_ids" | "parameterized" | "parameterized_named" | "mongodb" | "mongodb_query" | "cel" | "jsonlogic" | "spel" | "elasticsearch" | "jsonata" | "natural_language" | "ldap" | "drizzle" | "prisma" | "sequelize";
/**
* Export formats for {@link formatQuery} that produce objects instead of strings.
*
* @group Export
*/
type ExportObjectFormats = "parameterized" | "parameterized_named" | "jsonlogic" | "elasticsearch" | "jsonata" | "mongodb_query";
/**
* Available presets for the "sql" export format.
*
* @group Export
*/
type SQLPreset = "ansi" | "sqlite" | "postgresql" | "mysql" | "mssql" | "oracle";
/**
* A map of operators to strings to be used in the output of {@link formatQuery}. If the
* result can differ based on the `valueSource`, the key should map to an array where the
* second element represents the string to be used when `valueSource` is "field". The first
* element will be used in all other cases.
*
* @group Export
*/
type ExportOperatorMap = Partial<Record<Lowercase<DefaultOperatorName> | DefaultOperatorName, string | [string, string]>>;
/**
* Options object shape for {@link formatQuery}.
*
* @group Export
*/
interface FormatQueryOptions {
  /**
  * The {@link ExportFormat}.
  */
  format?: ExportFormat;
  /**
  * This function will be used to process the `operator` from each rule
  * for query language formats. If not defined, the appropriate
  * `defaultOperatorProcessor*` for the format will be used.
  */
  operatorProcessor?: RuleProcessor;
  /**
  * This function will be used to process the `value` from each rule
  * for query language formats. If not defined, the appropriate
  * `defaultValueProcessor*` for the format will be used.
  */
  valueProcessor?: ValueProcessorLegacy | ValueProcessorByRule;
  /**
  * This function will be used to process each rule. If not defined, the appropriate
  * `defaultRuleProcessor*` for the given format will be used.
  */
  ruleProcessor?: RuleProcessor;
  /**
  * This function will be used to process each rule group. If not defined, the appropriate
  * `defaultRuleGroupProcessor*` for the format will be used.
  *
  * If this function is defined, it will override the `format` option. This also allows
  * `formatQuery` to produce completely custom output formats.
  */
  ruleGroupProcessor?: RuleGroupProcessor;
  /**
  * In the "sql", "parameterized", "parameterized_named", and "jsonata" export
  * formats, field names will be bracketed by this string. If an array of strings
  * is passed, field names will be preceded by the first element and
  * succeeded by the second element.
  *
  * Tip: Use `fieldIdentifierSeparator` to bracket identifiers individually within field names.
  *
  * @default '' // the empty string
  *
  * @example
  * formatQuery(query, { format: 'sql', quoteFieldNamesWith: '"' })
  * // `"First name" = 'Steve'`
  *
  * @example
  * formatQuery(query, { format: 'sql', quoteFieldNamesWith: ['[', ']'] })
  * // "[First name] = 'Steve'"
  */
  quoteFieldNamesWith?: string | [string, string];
  /**
  * When used in conjunction with the `quoteFieldNamesWith` option, field names will
  * be split by this string, each part being individually processed as per the rules
  * of the `quoteFieldNamesWith` configuration. The parts will then be re-joined
  * by the same string.
  *
  * A common value for this option is `'.'`.
  *
  * A value of `''` (the empty string) will disable splitting/rejoining.
  *
  * @default ''
  *
  * @example
  * formatQuery(query, {
  *   format: 'sql',
  *   quoteFieldNamesWith: ['[', ']'],
  *   fieldIdentifierSeparator: '.',
  * })
  * // "[dbo].[Musicians].[First name] = 'Steve'"
  */
  fieldIdentifierSeparator?: string;
  /**
  * Character to use for quoting string values in the SQL format.
  * @default `'`
  */
  quoteValuesWith?: string;
  /**
  * Validator function for the entire query. Can be the same function passed
  * as `validator` prop to {@link react-querybuilder!QueryBuilder QueryBuilder}.
  */
  validator?: QueryValidator;
  /**
  * This can be the same {@link FullField} array passed to {@link react-querybuilder!QueryBuilder QueryBuilder}, but
  * really all you need to provide is the `name` and `validator` for each field.
  *
  * The full field object from this array, where the field's identifying property
  * matches the rule's `field`, will be passed to the rule processor.
  */
  fields?: FlexibleOptionList<FullField>;
  /**
  * This can be the same `getOperators` function passed to {@link react-querybuilder!QueryBuilder QueryBuilder}.
  *
  * The full operator object from this array, where the operator's identifying property
  * matches the rule's `operator`, will be passed to the rule processor.
  */
  getOperators?(field: string, misc: {
    fieldData: FullField;
  }): FlexibleOptionList<FullOperator> | null;
  /**
  * This string will be inserted in place of invalid groups for non-JSON formats.
  * Defaults to `'(1 = 1)'` for "sql"/"parameterized"/"parameterized_named" and
  * `'$and:[{$expr:true}]'` for "mongodb".
  */
  fallbackExpression?: string;
  /**
  * This string will be placed in front of named parameters (aka bind variables)
  * when using the "parameterized_named" export format.
  *
  * @default ":"
  */
  paramPrefix?: string;
  /**
  * Maintains the parameter prefix in the `params` object keys when using the
  * "parameterized_named" export format. Recommended when using SQLite.
  *
  * @default false
  *
  * @example
  * console.log(formatQuery(query, {
  *   format: "parameterized_named",
  *   paramPrefix: "$",
  *   paramsKeepPrefix: true
  * }).params)
  * // { $firstName: "Stev" }
  * // Default (`paramsKeepPrefix` is `false`):
  * // { firstName: "Stev" }
  */
  paramsKeepPrefix?: boolean;
  /**
  * Renders parameter placeholders as a series of sequential numbers
  * instead of '?' like the default. This option will respect the
  * `paramPrefix` option like the 'parameterized_named' format.
  *
  * @default false
  */
  numberedParams?: boolean;
  /**
  * Preserves the order of values for "between" and "notBetween" rules, even if a larger
  * value comes before a smaller value (which will always evaluate to false).
  */
  preserveValueOrder?: boolean;
  /**
  * Renders values as either `number`-types or unquoted strings, as
  * appropriate and when possible. Each `string`-type value is evaluated
  * against {@link numericRegex} to determine if it can be represented as a
  * plain numeric value. If so, `parseFloat` is used to convert it to a number.
  */
  parseNumbers?: ParseNumbersPropConfig;
  /**
  * Any rules where the field is equal to this value will be ignored.
  *
  * @default '~'
  */
  placeholderFieldName?: string;
  /**
  * Any rules where the operator is equal to this value will be ignored.
  *
  * @default '~'
  */
  placeholderOperatorName?: string;
  /**
  * Any rules where the value is equal to this value will be ignored.
  *
  * @default '~'
  */
  placeholderValueName?: string;
  /**
  * Operator to use when concatenating wildcard characters and field names in "sql" format.
  * The ANSI standard is `||`, while SQL Server uses `+`. MySQL does not implement a concatenation
  * operator by default, and therefore requires use of the `CONCAT` function.
  *
  * If `concatOperator` is set to `"CONCAT"` (case-insensitive), the `CONCAT` function will be
  * used. Note that Oracle SQL does not support more than two values in the `CONCAT` function,
  * so this option should not be used in that context. The default setting (`"||"`) is already
  * compatible with Oracle SQL.
  *
  * @default '||'
  */
  concatOperator?: "||" | "+" | "CONCAT" | (string & {});
  /**
  * Option presets to maximize compatibility with various SQL dialects.
  */
  preset?: SQLPreset;
  /**
  * Map of operators to their translations for the "natural_language" format. If the
  * result can differ based on the `valueSource`, the key should map to an array where the
  * second element represents the string to be used when `valueSource` is "field". The first
  * element will be used in all other cases.
  */
  operatorMap?: ExportOperatorMap;
  /**
  * [Constituent word order](https://en.wikipedia.org/wiki/Word_order#Constituent_word_orders)
  * for the "natural_language" format. Can be abbreviated like "SVO" or spelled out like
  * "subject-verb-object".
  *
  * - Subject = field
  * - Verb = operator
  * - Object = value
  */
  wordOrder?: ConstituentWordOrderString | Lowercase<ConstituentWordOrderString> | ({} & string);
  /**
  * Translatable strings used by the "natural_language" format.
  */
  translations?: Partial<Record<NLTranslationKey, string>>;
  context?: Record<string, any>;
}
/**
* Options object for {@link ValueProcessorByRule} functions.
*
* @group Export
*/
interface ValueProcessorOptions extends FormatQueryOptions {
  valueProcessor?: ValueProcessorByRule;
  escapeQuotes?: boolean;
  /**
  * The full field object, if `fields` was provided in the
  * {@link formatQuery} options parameter.
  */
  fieldData?: FullField;
  /**
  * Included for the "parameterized_named" format only. Keys of this object represent
  * field names and values represent the current list of parameter names for that
  * field based on the query rules processed up to that point. Use this list to
  * ensure that parameter names generated by the custom rule processor are unique.
  */
  fieldParamNames?: Record<string, string[]>;
  /**
  * Included for the "parameterized_named" format only. Call this function with a
  * field name to get a unique parameter name, as yet unused during query processing.
  */
  getNextNamedParam?: (field: string) => string;
  /**
  * Additional prefix and suffix characters to wrap the value in. Useful for augmenting
  * the default value processor results with special syntax (e.g., for dates or function
  * calls).
  */
  wrapValueWith?: [string, string];
  /**
  * Parse numbers in the rule value.
  *
  * @default false
  */
  parseNumbers?: boolean;
}
/**
* Options object curated by {@link formatQuery} and passed to a {@link RuleGroupProcessor}.
*
* @group Export
*/
interface FormatQueryFinalOptions extends Required<Except<FormatQueryOptions, "context" | "valueProcessor" | "validator" | "placeholderValueName" | "ruleGroupProcessor" | "parseNumbers">> {
  fields: FullOptionList<FullField>;
  getParseNumberBoolean: (inputType?: InputType | null) => boolean | undefined;
  parseNumbers?: ParseNumbersPropConfig | undefined;
  placeholderValueName?: string | undefined;
  valueProcessor: ValueProcessorByRule;
  validator?: QueryValidator;
  validateRule: FormatQueryValidateRule;
  validationMap: ValidationMap;
  context?: Record<string, unknown>;
}
/**
* Function that produces a processed value for a given {@link RuleType}.
*
* @group Export
*/
type ValueProcessorByRule = (rule: RuleType, options?: ValueProcessorOptions) => string;
/**
* Function that produces a processed value for a given `field`, `operator`, `value`,
* and `valueSource`.
*
* @group Export
*/
type ValueProcessorLegacy = (field: string, operator: string, value: any, valueSource?: ValueSource) => string;
/**
* @group Export
*/
type ValueProcessor = ValueProcessorLegacy;
/**
* Function to produce a result that {@link formatQuery} uses when processing a
* {@link RuleType} object.
*
* See the default rule processor for each format to know what type to return.
* | Format                   | Default rule processor                    |
* | ------------------------ | ----------------------------------------- |
* | `sql`                    | {@link defaultRuleProcessorSQL}           |
* | `parameterized`          | {@link defaultRuleProcessorParameterized} |
* | `parameterized_named`    | {@link defaultRuleProcessorParameterized} |
* | `mongodb` _(deprecated)_ | {@link defaultRuleProcessorMongoDB}       |
* | `mongodb_query`          | {@link defaultRuleProcessorMongoDBQuery}  |
* | `cel`                    | {@link defaultRuleProcessorCEL}           |
* | `spel`                   | {@link defaultRuleProcessorSpEL}          |
* | `jsonlogic`              | {@link defaultRuleProcessorJsonLogic}     |
* | `elasticsearch`          | {@link defaultRuleProcessorElasticSearch} |
* | `jsonata`                | {@link defaultRuleProcessorJSONata}       |
*
* @group Export
*/
type RuleProcessor = (rule: RuleType, options?: ValueProcessorOptions, meta?: {
  processedParams?: Record<string, any> | any[];
  context?: Record<string, any>;
}) => any;
/**
* Function to produce a result that {@link formatQuery} uses when processing a
* {@link RuleGroupType} or {@link RuleGroupTypeIC} object.
*
* See the default rule group processor for each format to know what type to return.
* | Format                   | Default rule group processor                   |
* | ------------------------ | ---------------------------------------------- |
* | `sql`                    | {@link defaultRuleGroupProcessorSQL}           |
* | `parameterized`          | {@link defaultRuleGroupProcessorParameterized} |
* | `parameterized_named`    | {@link defaultRuleGroupProcessorParameterized} |
* | `mongodb` _(deprecated)_ | {@link defaultRuleGroupProcessorMongoDB}       |
* | `mongodb_query`          | {@link defaultRuleGroupProcessorMongoDBQuery}  |
* | `cel`                    | {@link defaultRuleGroupProcessorCEL}           |
* | `spel`                   | {@link defaultRuleGroupProcessorSpEL}          |
* | `jsonlogic`              | {@link defaultRuleGroupProcessorJsonLogic}     |
* | `elasticsearch`          | {@link defaultRuleGroupProcessorElasticSearch} |
* | `jsonata`                | {@link defaultRuleGroupProcessorJSONata}       |
*
* @group Export
*/
type RuleGroupProcessor<TResult = unknown> = (ruleGroup: RuleGroupTypeAny, options: FormatQueryFinalOptions, meta?: {
  processedParams?: Record<string, any> | any[];
  context?: Record<string, any>;
}) => TResult;
/**
* Rule validator for {@link formatQuery}.
*
* @group Export
*/
type FormatQueryValidateRule = (rule: RuleType) => readonly [boolean | ValidationResult | undefined, RuleValidator | undefined];
/**
* Object produced by {@link formatQuery} for the `"parameterized"` format.
*
* @group Export
*/
interface ParameterizedSQL {
  /** The SQL `WHERE` clause fragment with `?` placeholders for each value. */
  sql: string;
  /**
  * Parameter values in the same order their respective placeholders
  * appear in the `sql` string.
  */
  params: any[];
}
/**
* Object produced by {@link formatQuery} for the `"parameterized_named"` format.
*
* @group Export
*/
interface ParameterizedNamedSQL {
  /** The SQL `WHERE` clause fragment with bind variable placeholders for each value. */
  sql: string;
  /**
  * Map of bind variable names from the `sql` string to the associated values.
  */
  params: Record<string, any>;
}
/**
* @group Export
*/
interface RQBJsonLogicStartsWith {
  startsWith: [RQBJsonLogic, RQBJsonLogic, ...RQBJsonLogic[]];
}
/**
* @group Export
*/
interface RQBJsonLogicEndsWith {
  endsWith: [RQBJsonLogic, RQBJsonLogic, ...RQBJsonLogic[]];
}
/**
* @group Export
*/
interface RQBJsonLogicVar {
  var: string;
}
/**
* JsonLogic rule object with additional operators generated by {@link formatQuery}
* and accepted by {@link parseJsonLogic!parseJsonLogic}.
*
* @group Export
*/
type RQBJsonLogic = RulesLogic<RQBJsonLogicStartsWith | RQBJsonLogicEndsWith>;
/**
* Constituent word order (as array) for the "natural_language" format.
*
* - S (subject) = field
* - V (verb) = operator
* - O (object) = value
*
* @group Export
*/
type ConstituentWordOrder = ["S", "V", "O"] | ["S", "O", "V"] | ["O", "S", "V"] | ["O", "V", "S"] | ["V", "S", "O"] | ["V", "O", "S"];
/**
* Constituent word order (as string) for the "natural_language" format.
*
* - S (subject) = field
* - V (verb) = operator
* - O (object) = value
*
* @group Export
*/
type ConstituentWordOrderString = "SVO" | "SOV" | "OSV" | "OVS" | "VSO" | "VOS";
type RepeatStrings<S extends string[], Depth extends number[] = []> = Depth["length"] extends 2 ? "" : "" | `_${S[number]}${RepeatStrings<S, [...Depth, 1]>}`;
type ZeroOrMoreGroupVariants = RepeatStrings<["xor", "not"]>;
/**
* Rule group condition identifier for the "natural_language" format.
*
* @group Export
*/
type GroupVariantCondition = "not" | "xor";
/**
* Keys for the `translations` config object used by the "natural_language" format.
*
* @group Export
*/
type NLTranslationKey = "and" | "or" | "true" | "false" | `groupPrefix${ZeroOrMoreGroupVariants}` | `groupSuffix${ZeroOrMoreGroupVariants}`;
/**
* `translations` config object for "natural_language" format.
*
* @group Export
*/
type NLTranslations = Partial<Record<NLTranslationKey, string>>;
//#endregion
//#region ../core/src/types/queryBuilder.d.ts
/**
* Base interface for all rule subcomponents.
*
* @group Props
*/
interface CommonRuleSubComponentProps {
  rule: RuleType;
}
/**
* Classnames applied to each component.
*
* @group Props
*/
interface Classnames {
  /**
  * Classnames applied to the root `<div>` element.
  */
  queryBuilder: Classname;
  /**
  * Classnames applied to the `<div>` containing the RuleGroup.
  */
  ruleGroup: Classname;
  /**
  * Classnames applied to the `<div>` containing the RuleGroup header controls.
  */
  header: Classname;
  /**
  * Classnames applied to the `<div>` containing the RuleGroup child rules/groups.
  */
  body: Classname;
  /**
  * Classnames applied to the `<select>` control for combinators.
  */
  combinators: Classname;
  /**
  * Classnames applied to the `<button>` to add a Rule.
  */
  addRule: Classname;
  /**
  * Classnames applied to the `<button>` to add a RuleGroup.
  */
  addGroup: Classname;
  /**
  * Classnames applied to the `<button>` to clone a Rule.
  */
  cloneRule: Classname;
  /**
  * Classnames applied to the `<button>` to clone a RuleGroup.
  */
  cloneGroup: Classname;
  /**
  * Classnames applied to the `<button>` to remove a RuleGroup.
  */
  removeGroup: Classname;
  /**
  * Classnames applied to the `<div>` containing the Rule.
  */
  rule: Classname;
  /**
  * Classnames applied to the `<select>` control for fields.
  */
  fields: Classname;
  /**
  * Classnames applied to the `<select>` control for match modes.
  */
  matchMode: Classname;
  /**
  * Classnames applied to the `<input>` for match thresholds.
  */
  matchThreshold: Classname;
  /**
  * Classnames applied to the `<select>` control for operators.
  */
  operators: Classname;
  /**
  * Classnames applied to the `<input>` for the rule value.
  */
  value: Classname;
  /**
  * Classnames applied to the `<button>` to remove a Rule.
  */
  removeRule: Classname;
  /**
  * Classnames applied to the `<label>` on the "not" toggle.
  */
  notToggle: Classname;
  /**
  * Classnames applied to the `<span>` handle for dragging rules/groups.
  */
  shiftActions: Classname;
  /**
  * Classnames applied to the `<span>` handle for dragging rules/groups.
  */
  dragHandle: Classname;
  /**
  * Classnames applied to the `<button>` to lock/disable a Rule.
  */
  lockRule: Classname;
  /**
  * Classnames applied to the `<button>` to lock/disable a RuleGroup.
  */
  lockGroup: Classname;
  /**
  * Classnames applied to the `<button>` to mute a Rule.
  */
  muteRule: Classname;
  /**
  * Classnames applied to the `<button>` to mute a RuleGroup.
  */
  muteGroup: Classname;
  /**
  * Classnames applied to the `<select>` control for value sources.
  */
  valueSource: Classname;
  /**
  * Classnames applied to all action elements.
  */
  actionElement: Classname;
  /**
  * Classnames applied to all select elements.
  */
  valueSelector: Classname;
  /**
  * Classname(s) applied to inline combinator elements.
  */
  betweenRules: Classname;
  /**
  * Classname(s) applied to valid rules and groups.
  */
  valid: Classname;
  /**
  * Classname(s) applied to invalid rules and groups.
  */
  invalid: Classname;
  /**
  * Classname(s) applied to rules and groups while being dragged.
  */
  dndDragging: Classname;
  /**
  * Classname(s) applied to rules and groups hovered over by a dragged element.
  */
  dndOver: Classname;
  /**
  * Classname(s) applied to rules and groups hovered over by a dragged element
  * when the drop effect is "copy" (modifier key is pressed).
  */
  dndCopy: Classname;
  /**
  * Classname(s) applied to rules and groups hovered over by a dragged element
  * when the Ctrl key is pressed, indicating the items will form a new group.
  */
  dndGroup: Classname;
  /**
  * Classname(s) applied to rules and groups that cannot accept a drop from
  * the dragged element hovering over it.
  */
  dndDropNotAllowed: Classname;
  /**
  * Classname(s) applied to disabled elements.
  */
  disabled: Classname;
  /**
  * Classname(s) applied to muted elements.
  */
  muted: Classname;
  /**
  * Classname(s) applied to each element in a series of value editors.
  */
  valueListItem: Classname;
  /**
  * Not applied, but see CSS styles.
  */
  branches: Classname;
  /**
  * Classname(s) applied to rules that render a subquery.
  */
  hasSubQuery: Classname;
  /**
  * Classname(s) applied to async components in their "loading" state.
  */
  loading: Classname;
}
/**
* Placeholder strings for option lists.
*
* @group Props
*/
interface Placeholder {
  /**
  * Value for the placeholder field option if autoSelectField is false,
  * or the placeholder operator option if autoSelectOperator is false.
  */
  placeholderName?: string;
  /**
  * Label for the placeholder field option if autoSelectField is false,
  * or the placeholder operator option if autoSelectOperator is false.
  */
  placeholderLabel?: string;
  /**
  * Label for the placeholder field optgroup if autoSelectField is false,
  * or the placeholder operator optgroup if autoSelectOperator is false.
  */
  placeholderGroupLabel?: string;
}
/**
* A translation for a component with `title` only.
*
* @group Props
*/
interface BaseTranslation {
  title?: string;
}
/**
* A translation for a component with `title` and `label`.
*
* @group Props
*/
interface BaseTranslationWithLabel<LabelType = string> extends BaseTranslation {
  label?: LabelType;
}
/**
* A translation for a component with `title` and a placeholder.
*
* @group Props
*/
interface BaseTranslationWithPlaceholders extends BaseTranslation, Placeholder {}
/**
* The shape of the `translations` prop.
*
* @group Props
*/
interface BaseTranslations<LabelType = string> {
  fields: BaseTranslationWithPlaceholders;
  operators: BaseTranslationWithPlaceholders;
  values: BaseTranslationWithPlaceholders;
  matchMode: BaseTranslation;
  matchThreshold: BaseTranslation;
  value: BaseTranslation;
  removeRule: BaseTranslationWithLabel<LabelType>;
  removeGroup: BaseTranslationWithLabel<LabelType>;
  addRule: BaseTranslationWithLabel<LabelType>;
  addGroup: BaseTranslationWithLabel<LabelType>;
  combinators: BaseTranslation;
  notToggle: BaseTranslationWithLabel<LabelType>;
  cloneRule: BaseTranslationWithLabel<LabelType>;
  cloneRuleGroup: BaseTranslationWithLabel<LabelType>;
  shiftActionUp: BaseTranslationWithLabel<LabelType>;
  shiftActionDown: BaseTranslationWithLabel<LabelType>;
  dragHandle: BaseTranslationWithLabel<LabelType>;
  lockRule: BaseTranslationWithLabel<LabelType>;
  lockGroup: BaseTranslationWithLabel<LabelType>;
  lockRuleDisabled: BaseTranslationWithLabel<LabelType>;
  lockGroupDisabled: BaseTranslationWithLabel<LabelType>;
  muteRule: BaseTranslationWithLabel<LabelType>;
  muteGroup: BaseTranslationWithLabel<LabelType>;
  unmuteRule: BaseTranslationWithLabel<LabelType>;
  unmuteGroup: BaseTranslationWithLabel<LabelType>;
  valueSourceSelector: BaseTranslation;
}
/**
* The full `translations` interface with all properties required.
*
* @group Props
*/
type BaseTranslationsFull<LabelType = string> = RequiredDeep<BaseTranslations<LabelType>>;
/**
* Functions included in the `actions` prop passed to every subcomponent.
*
* @group Props
*/
interface QueryActions {
  onGroupAdd(group: RuleGroupTypeAny, parentPath: Path, context?: any): void;
  onGroupRemove(path: Path): void;
  onPropChange(prop: Exclude<keyof RuleType | keyof RuleGroupType, "id" | "path">, value: any, path: Path, context?: any): void;
  onRuleAdd(rule: RuleType, parentPath: Path, context?: any): void;
  onRuleRemove(path: Path): void;
  moveRule(oldPath: Path, newPath: Path | "up" | "down", clone?: boolean, context?: any): void;
  groupRule(sourcePath: Path, targetPath: Path, clone?: boolean, context?: any): void;
}
interface QueryBuilderFlags {
  /**
  * Set to `false` to avoid calling the `onQueryChange` callback
  * when the component mounts.
  *
  * @default true
  */
  enableMountQueryChange?: boolean;
  /**
  * Enables drag-and-drop features.
  *
  * @default false
  */
  enableDragAndDrop?: boolean;
  /**
  * Enables debug logging for query builders (and React DnD when applicable).
  *
  * @default false
  */
  debugMode?: boolean;
  /**
  * Show group combinator selectors in the body of the group, between each child rule/group,
  * instead of in the group header.
  *
  * @default false
  */
  showCombinatorsBetweenRules?: boolean;
  /**
  * Show the "not" (aka inversion) toggle for rule groups.
  *
  * @default false
  */
  showNotToggle?: boolean;
  /**
  * Show the "Shift up"/"Shift down" actions.
  *
  * @default false
  */
  showShiftActions?: boolean;
  /**
  * Show the "Clone rule" and "Clone group" buttons.
  *
  * @default false
  */
  showCloneButtons?: boolean;
  /**
  * Show the "Lock rule" and "Lock group" buttons.
  *
  * @default false
  */
  showLockButtons?: boolean;
  /**
  * Show the "Mute rule" and "Mute group" buttons.
  *
  * @default false
  */
  showMuteButtons?: boolean;
  /**
  * Reset the `operator` and `value` when the `field` changes.
  *
  * @default true
  */
  resetOnFieldChange?: boolean;
  /**
  * Reset the `value` when the `operator` changes.
  *
  * @default false
  */
  resetOnOperatorChange?: boolean;
  /**
  * Select the first field in the array automatically.
  *
  * @default true
  */
  autoSelectField?: boolean;
  /**
  * Select the first operator in the array automatically.
  *
  * @default true
  */
  autoSelectOperator?: boolean;
  /**
  * Select the first value in the array automatically. Only applicable when the value editor renders a select list.
  *
  * @default false
  */
  autoSelectValue?: boolean;
  /**
  * Adds a new default rule automatically to each new group.
  *
  * @default false
  */
  addRuleToNewGroups?: boolean;
  /**
  * Store list-type values as native arrays instead of comma-separated strings.
  *
  * @default false
  */
  listsAsArrays?: boolean;
  /**
  * Prevent _any_ assignment of standard classes to elements. This includes conditional
  * and event-based classes for validation, drag-and-drop, etc.
  *
  * @default false
  */
  suppressStandardClassnames?: boolean;
}
//#endregion
//#region ../core/src/defaults.d.ts
/**
* @group Defaults
*/
declare const defaultPlaceholderName = "~";
/**
* @group Defaults
*/
declare const defaultPlaceholderLabel = "------";
/**
* Default `name` for placeholder option in the `fields` array.
*
* @group Defaults
*/
declare const defaultPlaceholderFieldName: typeof defaultPlaceholderName;
/**
* Default `label` for placeholder option in the `fields` array.
*
* @group Defaults
*/
declare const defaultPlaceholderFieldLabel: typeof defaultPlaceholderLabel;
/**
* Default `label` for placeholder option group in the `fields` array.
*
* @group Defaults
*/
declare const defaultPlaceholderFieldGroupLabel: typeof defaultPlaceholderLabel;
/**
* Default `name` for placeholder option in the `operators` array.
*
* @group Defaults
*/
declare const defaultPlaceholderOperatorName: typeof defaultPlaceholderName;
/**
* Default `label` for placeholder option in the `operators` array.
*
* @group Defaults
*/
declare const defaultPlaceholderOperatorLabel: typeof defaultPlaceholderLabel;
/**
* Default `label` for placeholder option group in the `operators` array.
*
* @group Defaults
*/
declare const defaultPlaceholderOperatorGroupLabel: typeof defaultPlaceholderLabel;
/**
* Default `name` for placeholder option in the `values` array.
*
* @group Defaults
*/
declare const defaultPlaceholderValueName: typeof defaultPlaceholderName;
/**
* Default `label` for placeholder option in the `values` array.
*
* @group Defaults
*/
declare const defaultPlaceholderValueLabel: typeof defaultPlaceholderLabel;
/**
* Default `label` for placeholder option group in the `values` array.
*
* @group Defaults
*/
declare const defaultPlaceholderValueGroupLabel: typeof defaultPlaceholderLabel;
/**
* Default configuration of translatable strings.
*
* @group Defaults
*/
declare const defaultTranslations: BaseTranslationsFull;
/**
* Default character used to `.join` and `.split` arrays.
*
* @group Defaults
*/
declare const defaultJoinChar = ",";
type DefaultOperators = StringUnionToFullOptionArray<DefaultOperatorName>;
declare const defaultOperatorLabelMap: Record<DefaultOperatorName, string>;
declare const defaultCombinatorLabelMap: Record<DefaultCombinatorNameExtended, string>;
/**
* Default operator list.
*
* @group Defaults
*/
declare const defaultOperators: DefaultOperators;
/**
* Map of default operators to their respective opposite/negating operators.
*
* @group Defaults
*/
declare const defaultOperatorNegationMap: Record<DefaultOperatorName, DefaultOperatorName>;
type DefaultCombinators = StringUnionToFullOptionArray<DefaultCombinatorName>;
/**
* Default combinator list.
*
* @group Defaults
*/
declare const defaultCombinators: DefaultCombinators;
type DefaultCombinatorsExtended = StringUnionToFullOptionArray<DefaultCombinatorNameExtended>;
/**
* Default combinator list, with `XOR` added.
*
* @group Defaults
*/
declare const defaultCombinatorsExtended: DefaultCombinatorsExtended;
type DefaultMatchModes = StringUnionToFullOptionArray<MatchMode>;
/**
* Default match modes.
*
* @group Defaults
*/
declare const defaultMatchModes: DefaultMatchModes;
/**
* Standard classnames applied to each component.
*
* @group Defaults
*/
declare const standardClassnames: {
  readonly queryBuilder: "queryBuilder";
  readonly ruleGroup: "ruleGroup";
  readonly header: "ruleGroup-header";
  readonly body: "ruleGroup-body";
  readonly combinators: "ruleGroup-combinators";
  readonly addRule: "ruleGroup-addRule";
  readonly addGroup: "ruleGroup-addGroup";
  readonly cloneRule: "rule-cloneRule";
  readonly cloneGroup: "ruleGroup-cloneGroup";
  readonly removeGroup: "ruleGroup-remove";
  readonly notToggle: "ruleGroup-notToggle";
  readonly rule: "rule";
  readonly fields: "rule-fields";
  readonly matchMode: "rule-matchMode";
  readonly matchThreshold: "rule-matchThreshold";
  readonly operators: "rule-operators";
  readonly value: "rule-value";
  readonly removeRule: "rule-remove";
  readonly betweenRules: "betweenRules";
  readonly valid: "queryBuilder-valid";
  readonly invalid: "queryBuilder-invalid";
  readonly shiftActions: "shiftActions";
  readonly dndDragging: "dndDragging";
  readonly dndOver: "dndOver";
  readonly dndCopy: "dndCopy";
  readonly dndGroup: "dndGroup";
  readonly dndDropNotAllowed: "dndDropNotAllowed";
  readonly dragHandle: "queryBuilder-dragHandle";
  readonly disabled: "queryBuilder-disabled";
  readonly muted: "queryBuilder-muted";
  readonly lockRule: "rule-lock";
  readonly lockGroup: "ruleGroup-lock";
  readonly muteRule: "rule-mute";
  readonly muteGroup: "ruleGroup-mute";
  readonly valueSource: "rule-valueSource";
  readonly valueListItem: "rule-value-list-item";
  readonly branches: "queryBuilder-branches";
  readonly justified: "queryBuilder-justified";
  readonly hasSubQuery: "rule-hasSubQuery";
  readonly loading: "queryBuilder-loading";
};
/**
* Default classnames for each component.
*
* @group Defaults
*/
declare const defaultControlClassnames: Classnames;
/**
* Default reason codes for a group being invalid.
*
* @group Defaults
*/
declare const groupInvalidReasons: {
  readonly empty: "empty";
  readonly invalidCombinator: "invalid combinator";
  readonly invalidIndependentCombinators: "invalid independent combinators";
};
/**
* Component identifiers for testing.
*
* @group Defaults
*/
declare const TestID: {
  readonly rule: "rule";
  readonly ruleGroup: "rule-group";
  readonly inlineCombinator: "inline-combinator";
  readonly addGroup: "add-group";
  readonly removeGroup: "remove-group";
  readonly cloneGroup: "clone-group";
  readonly cloneRule: "clone-rule";
  readonly addRule: "add-rule";
  readonly removeRule: "remove-rule";
  readonly combinators: "combinators";
  readonly fields: "fields";
  readonly operators: "operators";
  readonly valueEditor: "value-editor";
  readonly notToggle: "not-toggle";
  readonly shiftActions: "shift-actions";
  readonly dragHandle: "drag-handle";
  readonly lockRule: "lock-rule";
  readonly lockGroup: "lock-group";
  readonly muteRule: "mute-rule";
  readonly muteGroup: "mute-group";
  readonly valueSourceSelector: "value-source-selector";
  readonly matchModeEditor: "match-mode-editor";
};
declare const LogType: {
  readonly parentPathDisabled: "action aborted: parent path disabled";
  readonly pathDisabled: "action aborted: path is disabled";
  readonly queryUpdate: "query updated";
  readonly onAddRuleFalse: "onAddRule callback returned false";
  readonly onAddGroupFalse: "onAddGroup callback returned false";
  readonly onGroupRuleFalse: "onGroupRule callback returned false";
  readonly onGroupGroupFalse: "onGroupGroup callback returned false";
  readonly onMoveRuleFalse: "onMoveRule callback returned false";
  readonly onMoveGroupFalse: "onMoveGroup callback returned false";
  readonly onRemoveFalse: "onRemove callback returned false";
  readonly add: "rule or group added";
  readonly remove: "rule or group removed";
  readonly update: "rule or group updated";
  readonly move: "rule or group moved";
  readonly group: "rule or group grouped with another";
};
/**
* The {@link Path} of the root group.
*
* @group Defaults
*/
declare const rootPath: Path;
/**
* Default values for all `boolean`
* {@link react-querybuilder!QueryBuilder QueryBuilder} options.
*
* @group Defaults
*/
declare const queryBuilderFlagDefaults: Required<QueryBuilderFlags>;
//#endregion
//#region ../core/src/utils/arrayUtils.d.ts
/**
* Splits a string by a given character (see {@link defaultJoinChar}). Escaped characters
* (characters preceded by a backslash) will not apply to the split, and the backslash will
* be removed in the array element. Inverse of {@link joinWith}.
*
* @example
* splitBy('this\\,\\,that,,the other,,,\\,')
* // or
* splitBy('this\\,\\,that,,the other,,,\\,', ',')
* // would return
* ['this,,that', '', 'the other', '', '', ',']
*/
declare const splitBy: (str?: string, splitChar?: string) => string[];
/**
* Joins an array of strings using the given character (see {@link defaultJoinChar}). When
* the given character appears in an array element, a backslash will be added just before it
* to distinguish it from the join character. Effectively the inverse of {@link splitBy}.
*
* TIP: The join character can actually be a string of any length. Only the first character
* will be searched for in the array elements and preceded by a backslash.
*
* @example
* joinWith(['this,,that', '', 'the other', '', '', ','], ', ')
* // would return
* 'this\\,\\,that, , the other, , , \\,'
*/
declare const joinWith: (strArr: any[], joinChar?: string) => string;
/**
* Trims the value if it is a string. Otherwise returns the value as is.
*/
declare const trimIfString: (val: any) => any;
/**
* Splits a string by comma then trims each element. Arrays are returned as is except
* any string elements are trimmed.
*/
declare const toArray: (v: any, {
  retainEmptyStrings
}?: {
  retainEmptyStrings?: boolean;
}) => any[];
/**
* Determines if an array is free of `null`/`undefined`.
*/
declare const nullFreeArray: <T$1>(arr: T$1[]) => arr is Exclude<T$1, null>[];
//#endregion
//#region ../core/src/utils/clsx.d.ts
type ClassDictionary = Record<string, any>;
type ClassValue = ClassArray | ClassDictionary | string | number | bigint | null | boolean | undefined;
type ClassArray = ClassValue[];
/**
* Vendored/adapted version of the `clsx` package.
*
* **NOTE:** Prefer the official package from npm outside the context of React Query Builder.
*/
declare function clsx(...args: ClassValue[]): string;
//#endregion
//#region ../core/src/utils/convertQuery.d.ts
/**
* Converts a {@link RuleGroupTypeIC} to {@link RuleGroupType}.
*
* This function is idempotent: {@link RuleGroupType} queries will be
* returned as-is.
*
* @group Query Tools
*/
declare const convertFromIC: <RG extends RuleGroupType = RuleGroupType>(rg: RuleGroupTypeAny) => RG;
/**
* Converts a {@link RuleGroupType} to {@link RuleGroupTypeIC}.
*
* This function is idempotent: {@link RuleGroupTypeIC} queries will be
* returned as-is.
*
* @group Query Tools
*/
declare const convertToIC: <RGIC extends RuleGroupTypeIC = RuleGroupTypeIC>(rg: RuleGroupTypeAny) => RGIC;
/**
* Converts a {@link RuleGroupType} to {@link RuleGroupTypeIC}. For a more explicit
* operation, use {@link convertToIC}.
*
* @group Query Tools
*/
declare function convertQuery(query: RuleGroupType): RuleGroupTypeIC;
/**
* Converts a {@link RuleGroupTypeIC} to {@link RuleGroupType}. For a more explicit
* operation, use {@link convertFromIC}.
*
* @group Query Tools
*/
declare function convertQuery(query: RuleGroupTypeIC): RuleGroupType;
//#endregion
//#region ../core/src/utils/defaultValidator.d.ts
/**
* This is an example validation function you can pass to {@link react-querybuilder!QueryBuilder QueryBuilder} in the
* `validator` prop. It assumes that you want to validate groups, and has a no-op
* for validating rules which you can replace with your own implementation.
*/
declare const defaultValidator: QueryValidator;
//#endregion
//#region ../core/src/utils/filterFieldsByComparator.d.ts
/**
* For a given {@link FullField}, returns the `fields` list filtered for
* other fields that match by `comparator`. Only fields *other than the
* one in question* will ever be included, even if `comparator` is `null`
* or `undefined`. If `comparator` is a string, fields with the same value
* for that property will be included. If `comparator` is a function, each
* field will be passed to the function along with the `operator` and fields
* for which the function returns `true` will be included.
*
* @group Option Lists
*/
declare const filterFieldsByComparator: (field: FullField, fields: OptionList<FullField>, operator: string) => FullField[] | {
  options: WithUnknownIndex<FullField>[];
  label: string;
}[];
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorCEL.d.ts
/**
* Default rule processor used by {@link formatQuery} for "cel" format.
*
* @group Export
*/
declare const defaultRuleProcessorCEL: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorMongoDB.d.ts
/**
* Default rule processor used by {@link formatQuery} for "mongodb" format.
*
* Note that the "mongodb" format is deprecated in favor of the "mongodb_query" format.
*
* @group Export
*/
declare const defaultRuleProcessorMongoDB: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorSpEL.d.ts
/**
* Default rule processor used by {@link formatQuery} for "spel" format.
*
* @group Export
*/
declare const defaultRuleProcessorSpEL: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultValueProcessorByRule.d.ts
/**
* Default value processor used by {@link formatQuery} for "sql" format.
*
* @group Export
*/
declare const defaultValueProcessorByRule: ValueProcessorByRule;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorCEL.d.ts
/**
* Rule group processor used by {@link formatQuery} for "cel" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorCEL: RuleGroupProcessor<string>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorDrizzle.d.ts
/**
* Default rule group processor used by {@link formatQuery} for the "drizzle" format. The returned
* function can be assigned to the `where` property in the Drizzle relational queries API.
*
* @example
* const where = formatQuery(query, 'drizzle');
* const results = db.query.users.findMany({ where });
*
* @returns Function that takes a Drizzle table config and an object of Drizzle operators.
*
* @group Export
*/
declare const defaultRuleGroupProcessorDrizzle: RuleGroupProcessor<(columns: Record<string, Column> | Table, drizzleOperators: Operators) => SQL | undefined>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorElasticSearch.d.ts
/**
* Rule group processor used by {@link formatQuery} for "elasticsearch" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorElasticSearch: RuleGroupProcessor<Record<string, unknown>>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorJSONata.d.ts
/**
* Rule group processor used by {@link formatQuery} for "jsonata" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorJSONata: RuleGroupProcessor<string>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorJsonLogic.d.ts
/**
* Rule group processor used by {@link formatQuery} for "jsonlogic" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorJsonLogic: RuleGroupProcessor<RQBJsonLogic>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorLDAP.d.ts
/**
* Rule group processor used by {@link formatQuery} for "ldap" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorLDAP: RuleGroupProcessor<string>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorMongoDB.d.ts
/**
* Rule group processor used by {@link formatQuery} for "mongodb" format.
*
* Note that the "mongodb" format is deprecated in favor of the "mongodb_query" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorMongoDB: RuleGroupProcessor<string>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorMongoDBQuery.d.ts
/**
* Default fallback object used by {@link formatQuery} for "mongodb_query" format.
*
* @group Export
*/
declare const mongoDbFallback: {
  readonly $and: readonly [{
    readonly $expr: true;
  }];
};
/**
* Rule group processor used by {@link formatQuery} for "mongodb_query" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorMongoDBQuery: RuleGroupProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorNL.d.ts
/**
* Rule group processor used by {@link formatQuery} for "natural_language" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorNL: RuleGroupProcessor<string>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorParameterized.d.ts
/**
* Rule group processor used by {@link formatQuery} for "parameterized" and
* "parameterized_named" formats.
*
* @group Export
*/
declare const defaultRuleGroupProcessorParameterized: RuleGroupProcessor<ParameterizedSQL | ParameterizedNamedSQL>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorPrisma.d.ts
/**
* Default fallback object used by {@link formatQuery} for "prisma" format.
*
* @group Export
*/
declare const prismaFallback: {};
/**
* Rule group processor used by {@link formatQuery} for "prisma" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorPrisma: RuleGroupProcessor<Record<string, unknown> | undefined>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorSequelize.d.ts
/**
* Rule group processor used by {@link formatQuery} for "sequelize" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorSequelize: RuleGroupProcessor<WhereOptions | undefined>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorSpEL.d.ts
/**
* Default rule processor used by {@link formatQuery} for "spel" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorSpEL: RuleGroupProcessor<string>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleGroupProcessorSQL.d.ts
/**
* Default rule processor used by {@link formatQuery} for "sql" format.
*
* @group Export
*/
declare const defaultRuleGroupProcessorSQL: RuleGroupProcessor<string>;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorDrizzle.d.ts
/**
* Default rule processor used by {@link formatQuery} for the "drizzle" format.
*
* @group Export
*/
declare const defaultRuleProcessorDrizzle: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorElasticSearch.d.ts
/**
* Default rule processor used by {@link formatQuery} for "elasticsearch" format.
*
* @group Export
*/
declare const defaultRuleProcessorElasticSearch: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorJSONata.d.ts
/**
* Default rule processor used by {@link formatQuery} for "jsonata" format.
*
* @group Export
*/
declare const defaultRuleProcessorJSONata: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorJsonLogic.d.ts
/**
* Default rule processor used by {@link formatQuery} for "jsonlogic" format.
*
* @group Export
*/
declare const defaultRuleProcessorJsonLogic: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorLDAP.d.ts
/**
* Default rule processor used by {@link formatQuery} for "ldap" format.
*
* @group Export
*/
declare const defaultRuleProcessorLDAP: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorMongoDBQuery.d.ts
/**
* Default rule processor used by {@link formatQuery} for "mongodb_query" format.
*
* @group Export
*/
declare const defaultRuleProcessorMongoDBQuery: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorNL.d.ts
/**
* Default operator map used by {@link formatQuery} for "natural_language" format.
*
* @group Export
*/
declare const defaultExportOperatorMap: ExportOperatorMap;
/**
* Default operator processor used by {@link formatQuery} for "natural_language" format.
*
* @group Export
*/
declare const defaultOperatorProcessorNL: RuleProcessor;
/**
* Default rule processor used by {@link formatQuery} for "natural_language" format.
*
* @group Export
*/
declare const defaultRuleProcessorNL: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorParameterized.d.ts
/**
* Default rule processor used by {@link formatQuery} for "parameterized" and
* "parameterized_named" formats.
*
* @group Export
*/
declare const defaultRuleProcessorParameterized: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorPrisma.d.ts
/**
* Default rule processor used by {@link formatQuery} for "prisma" format.
*
* @group Export
*/
declare const defaultRuleProcessorPrisma: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorSequelize.d.ts
/**
* Default rule processor used by {@link formatQuery} for the "sequelize" format.
*
* @group Export
*/
declare const defaultRuleProcessorSequelize: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultRuleProcessorSQL.d.ts
/**
* Default operator processor used by {@link formatQuery} for "sql" and "parameterized*" formats.
*
* @group Export
*/
declare const defaultOperatorProcessorSQL: RuleProcessor;
/**
* Default rule processor used by {@link formatQuery} for "sql" format.
*
* @group Export
*/
declare const defaultRuleProcessorSQL: RuleProcessor;
//#endregion
//#region ../core/src/utils/formatQuery/defaultValueProcessorNL.d.ts
/**
* Default value processor used by {@link formatQuery} for "natural_language" format.
*
* @group Export
*/
declare const defaultValueProcessorNL: ValueProcessorByRule;
//#endregion
//#region ../core/src/utils/formatQuery/formatQuery.d.ts
/**
* A collection of option presets for {@link formatQuery}, specifically for SQL-based formats.
*
* @group Export
*/
declare const sqlDialectPresets: Record<SQLPreset, FormatQueryOptions>;
/**
* A collection of option presets for {@link formatQuery}.
*
* @group Export
*/
declare const formatQueryOptionPresets: Record<string, FormatQueryOptions>;
/**
* Generates a formatted (indented two spaces) JSON string from a query object.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny): string;
/**
* Generates a result based on the provided rule group processor.
*
* @group Export
*/
declare function formatQuery<TResult = unknown>(ruleGroup: RuleGroupTypeAny, options: FormatQueryOptions & {
  ruleGroupProcessor: RuleGroupProcessor<TResult>;
}): TResult;
/**
* Generates a {@link index!ParameterizedSQL ParameterizedSQL} object from a query object.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: "parameterized" | (FormatQueryOptions & {
  format: "parameterized";
})): ParameterizedSQL;
/**
* Generates a {@link index!ParameterizedNamedSQL ParameterizedNamedSQL} object from a query object.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: "parameterized_named" | (FormatQueryOptions & {
  format: "parameterized_named";
})): ParameterizedNamedSQL;
/**
* Generates a {@link index!RQBJsonLogic JsonLogic} object from a query object.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: "jsonlogic" | (FormatQueryOptions & {
  format: "jsonlogic";
})): RQBJsonLogic;
/**
* Generates an ElasticSearch query object from an RQB query object.
*
* NOTE: Support for the ElasticSearch format is experimental.
* You may have better results exporting "sql" format then using
* [ElasticSearch SQL](https://www.elastic.co/guide/en/elasticsearch/reference/current/xpack-sql.html).
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: "elasticsearch" | (FormatQueryOptions & {
  format: "elasticsearch";
})): Record<string, any>;
/**
* Generates a MongoDB query object from an RQB query object.
*
* This is equivalent to the "mongodb" format, but returns a JSON object
* instead of a string.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: "mongodb_query" | (FormatQueryOptions & {
  format: "mongodb_query";
})): Record<string, any>;
/**
* Generates a JSON.stringify'd MongoDB query object from an RQB query object.
*
* This is equivalent to the "mongodb_query" format, but returns a string
* instead of a JSON object.
*
* @deprecated Use the "mongodb_query" format for greater flexibility.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: "mongodb" | (FormatQueryOptions & {
  format: "mongodb";
})): string;
/**
* Generates a Prisma ORM query object from an RQB query object.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: "prisma" | (FormatQueryOptions & {
  format: "prisma";
})): Record<string, any>;
/**
* Generates a Drizzle ORM query function from an RQB query object. The function can
* be assigned to the `where` property in the Drizzle relational queries API.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: "drizzle" | (FormatQueryOptions & {
  format: "drizzle";
})): ReturnType<typeof defaultRuleGroupProcessorDrizzle>;
/**
* Generates a Sequelize query object from an RQB query object. The object can
* be assigned to the `where` property in the Sequelize query functions.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: "sequelize" | (FormatQueryOptions & {
  format: "sequelize";
})): ReturnType<typeof defaultRuleGroupProcessorSequelize>;
/**
* Generates a JSONata query string from an RQB query object.
*
* NOTE: Either `parseNumbers: "strict-limited"` or `parseNumbers: true`
* are recommended for this format.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: "jsonata" | (FormatQueryOptions & {
  format: "jsonata";
})): string;
/**
* Generates an LDAP query string from an RQB query object.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: "ldap" | (FormatQueryOptions & {
  format: "ldap";
})): string;
/**
* Generates a formatted (indented two spaces) JSON string from a query object.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: FormatQueryOptions): string;
/**
* Generates a query string in the requested format.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: Exclude<ExportFormat, ExportObjectFormats>): string;
/**
* Generates a query string in the requested format.
*
* @group Export
*/
declare function formatQuery(ruleGroup: RuleGroupTypeAny, options: FormatQueryOptions & {
  format: Exclude<ExportFormat, ExportObjectFormats>;
}): string;
//#endregion
//#region ../core/src/utils/formatQuery/utils.d.ts
/**
* Maps a {@link DefaultOperatorName} to a SQL operator.
*
* @group Export
*/
declare const mapSQLOperator: (rqbOperator: string) => string;
/**
* Maps a (lowercase) {@link DefaultOperatorName} to a MongoDB operator.
*
* @group Export
*/
declare const mongoOperators: {
  "=": string;
  "!=": string;
  "<": string;
  "<=": string;
  ">": string;
  ">=": string;
  in: string;
  notin: string;
  notIn: string;
};
/**
* Maps a (lowercase) {@link DefaultOperatorName} to a Prisma ORM operator.
*
* @group Export
*/
declare const prismaOperators: {
  "=": string;
  "!=": string;
  "<": string;
  "<=": string;
  ">": string;
  ">=": string;
  in: string;
  notin: string;
};
/**
* Maps a {@link DefaultCombinatorName} to a CEL combinator.
*
* @group Export
*/
declare const celCombinatorMap: {
  and: "&&";
  or: "||";
};
/**
* Register these operators with `jsonLogic` before applying the result
* of `formatQuery(query, 'jsonlogic')`.
*
* @example
* ```
* for (const [op, func] of Object.entries(jsonLogicAdditionalOperators)) {
*   jsonLogic.add_operation(op, func);
* }
* jsonLogic.apply({ "startsWith": [{ "var": "firstName" }, "Stev"] }, data);
* ```
*
* @group Export
*/
declare const jsonLogicAdditionalOperators: Record<"startsWith" | "endsWith", (a: string, b: string) => boolean>;
/**
* Converts all `string`-type `value` properties of a query object into `number` where appropriate.
*
* Used by {@link formatQuery} for the `json*` formats when `parseNumbers` is `true`.
*
* @group Export
*/
declare const numerifyValues: (rg: RuleGroupTypeAny, options: SetRequired<FormatQueryOptions, "fields">) => RuleGroupTypeAny;
/**
* Determines whether a value is _anything_ except an empty `string` or `NaN`.
*
* @group Export
*/
declare const isValidValue: (value: any) => boolean;
/**
* Determines whether {@link formatQuery} should render the given value as a number.
* As long as `parseNumbers` is `true`, `number` and `bigint` values will return `true` and
* `string` values will return `true` if they test positive against {@link numericRegex}.
*
* @group Export
*/
declare const shouldRenderAsNumber: (value: any, parseNumbers?: boolean) => boolean;
/**
* Used by {@link formatQuery} to determine whether the given value processor is a
* "legacy" value processor by counting the number of arguments. Legacy value
* processors take 3 arguments (not counting any arguments with default values), while
* rule-based value processors take no more than 2 arguments.
*
* @group Export
*/
declare const isValueProcessorLegacy: (valueProcessor: ValueProcessorLegacy | ValueProcessorByRule) => valueProcessor is ValueProcessorLegacy;
/**
* Converts the `quoteFieldNamesWith` option into an array of two strings.
* If the option is a string, the array elements are both that string.
*
* @default
* ['', '']
*
* @group Export
*/
declare const getQuoteFieldNamesWithArray: (quoteFieldNamesWith?: null | string | [string, string]) => [string, string];
/**
* Given a field name and relevant {@link ValueProcessorOptions}, returns the field name
* wrapped in the configured quote character(s).
*
* @group Export
*/
declare const getQuotedFieldName: (fieldName: string, {
  quoteFieldNamesWith,
  fieldIdentifierSeparator
}: ValueProcessorOptions) => string;
/**
* Given a [Constituent word order](https://en.wikipedia.org/wiki/Word_order#Constituent_word_orders)
* like "svo" or "sov", returns a permutation of `["S", "V", "O"]` based on the first occurrence of
* each letter in the input string (case insensitive). This widens the valid input from abbreviations
* like "svo" to more expressive strings like "subject-verb-object" or "sub ver obj". Any missing
* letters are appended in the default order "SVO" (e.g., "object" would yield `["O", "S", "V"]`).
*
* @group Export
*/
declare const normalizeConstituentWordOrder: (input: string) => ConstituentWordOrder;
/**
* Default translations used by {@link formatQuery} for "natural_language" format.
*
* @group Export
*/
declare const defaultNLTranslations: NLTranslations;
/**
* Used by {@link formatQuery} to get a translation based on certain conditions
* for the "natural_language" format.
*
* @group Export
*/
declare const getNLTranslataion: (key: NLTranslationKey, translations: NLTranslations, conditions?: GroupVariantCondition[]) => string;
type ProcessedMatchMode = {
  mode: "all";
  threshold?: number | null | undefined;
} | {
  mode: "none";
  threshold?: number | null | undefined;
} | {
  mode: "some";
  threshold?: number | null | undefined;
} | {
  mode: "atleast";
  threshold: number;
} | {
  mode: "atmost";
  threshold: number;
} | {
  mode: "exactly";
  threshold: number;
};
/**
* Transforms
* - `match: { mode: "atLeast", threshold: 1 }` to `match: { mode: "some" }`
* - `match: { mode: "atMost", threshold: 0 }` to `match: { mode: "none" }`.
*
* Returns:
* - Processed `{ mode, threshold }` object for valid subqueries
* - `null` if match mode is not applicable for the rule
* - `false` if match mode is valid, but either
*   1. `threshold` is required and invalid, or
*   2. `value` is not a valid rule group.
*/
declare const processMatchMode: (rule: RuleType) => null | false | ProcessedMatchMode;
/**
* "Replacer" method for JSON.stringify's second argument. Converts `bigint` values to
* objects with a `$bigint` property having a value of a string representation of
* the actual `bigint`-type value.
*
* Inverse of {@link bigIntJsonParseReviver}.
*
* @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/BigInt#use_within_json
*/
declare const bigIntJsonStringifyReplacer: (_key: string, value: unknown) => unknown;
/**
* "Reviver" method for JSON.parse's second argument. Converts objects having a single
* `$bigint: string` property to an actual `bigint` value.
*
* Inverse of {@link bigIntJsonStringifyReplacer}.
*
* @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/BigInt#use_within_json
*/
declare const bigIntJsonParseReviver: (_key: string, value: unknown) => unknown;
//#endregion
//#region ../core/src/utils/formatQuery/index.d.ts
/**
* Default value processor used by {@link formatQuery} for "sql" format.
*
* @group Export
*/
declare const defaultValueProcessor: ValueProcessorLegacy;
/**
* @deprecated Prefer {@link defaultRuleProcessorMongoDB}.
*
* @group Export
*/
declare const defaultMongoDBValueProcessor: ValueProcessorLegacy;
/**
* @deprecated Prefer {@link defaultRuleProcessorCEL}.
*
* @group Export
*/
declare const defaultCELValueProcessor: ValueProcessorLegacy;
/**
* @deprecated Prefer {@link defaultRuleProcessorSpEL}.
*
* @group Export
*/
declare const defaultSpELValueProcessor: ValueProcessorLegacy;
/**
* @deprecated Renamed to {@link defaultRuleProcessorCEL}.
*
* @group Export
*/
declare const defaultValueProcessorCELByRule: RuleProcessor;
/**
* @deprecated Renamed to {@link defaultRuleProcessorMongoDB}.
*
* @group Export
*/
declare const defaultValueProcessorMongoDBByRule: RuleProcessor;
/**
* @deprecated Renamed to {@link defaultRuleProcessorSpEL}.
*
* @group Export
*/
declare const defaultValueProcessorSpELByRule: RuleProcessor;
//#endregion
//#region ../core/src/utils/generateAccessibleDescription.d.ts
declare const generateAccessibleDescription: AccessibleDescriptionGenerator;
//#endregion
//#region ../core/src/utils/generateID.d.ts
type UUID = `${string}-${string}-${string}-${string}-${string}`;
/**
* Default `id` generator. Generates a valid v4 UUID. Uses `crypto.randomUUID()`
* when available, otherwise uses an alternate method based on `getRandomValues`.
* The returned string is guaranteed to match this regex:
* ```
* /^[0-9A-F]{8}-[0-9A-F]{4}-4[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i
* ```
* @returns Valid v4 UUID
*/
declare let generateID: () => UUID;
//#endregion
//#region ../core/src/utils/getMatchModesUtil.d.ts
/**
* Utility function to get the match modes array for the given
* field. If the field definition does not define a `matchModes`
* property, the `getMatchModes` prop is used. Returns
* `FullOption<MatchMode>[]` of all match modes by default.
*/
declare const getMatchModesUtil: <F extends FullField>(fieldData: F, getMatchModes?: (field: GetOptionIdentifierType<F>, misc: {
  fieldData: F;
}) => boolean | MatchMode[] | FlexibleOption<MatchMode>[]) => MatchModeOptions;
//#endregion
//#region ../core/src/utils/getParseNumberMethod.d.ts
declare const getParseNumberMethod: ({
  parseNumbers,
  inputType
}: {
  parseNumbers?: ParseNumbersPropConfig;
  inputType?: InputType | null;
}) => ParseNumberMethod;
//#endregion
//#region ../core/src/utils/getValidationClassNames.d.ts
/**
* Gets the standard classname for valid or invalid components
* based on the given validation result.
*/
declare const getValidationClassNames: (validationResult: boolean | ValidationResult) => "" | (typeof standardClassnames)["valid"] | (typeof standardClassnames)["invalid"];
//#endregion
//#region ../core/src/utils/getValueSourcesUtil.d.ts
/**
* Utility function to get the value sources array for the given
* field and operator. If the field definition does not define a
* `valueSources` property, the `getValueSources` prop is used.
* Returns `[FullOption<"value">]` by default.
*/
declare const getValueSourcesUtil: <F extends FullField, O extends string>(fieldData: F, operator: string, getValueSources?: (field: GetOptionIdentifierType<F>, operator: O, misc: {
  fieldData: F;
}) => ValueSources | ValueSourceFlexibleOptions) => ValueSourceFullOptions;
//#endregion
//#region ../core/src/utils/isRuleGroup.d.ts
/**
* Determines if an object is a {@link RuleType} (only checks for a `field` property).
*/
declare const isRuleType: (s: unknown) => s is RuleType;
/**
* Determines if an object is a {@link RuleGroupType} or {@link RuleGroupTypeIC}.
*/
declare const isRuleGroup: (rg: unknown) => rg is RuleGroupTypeAny;
/**
* Determines if an object is a {@link RuleGroupType}.
*/
declare const isRuleGroupType: (rg: unknown) => rg is RuleGroupType;
/**
* Determines if an object is a {@link RuleGroupTypeIC}.
*/
declare const isRuleGroupTypeIC: (rg: unknown) => rg is RuleGroupTypeIC;
//#endregion
//#region ../core/src/utils/isRuleOrGroupValid.d.ts
/**
* Determines if an object is useful as a validation result.
*/
declare const isValidationResult: (vr?: ValidationResult) => vr is ValidationResult;
/**
* Determines if a rule or group is valid based on a validation result (if defined)
* or a validator function. Returns `true` if neither are defined and the `muted`
* property is not `true`.
*/
declare const isRuleOrGroupValid: (rg: RuleType | RuleGroupTypeAny, validationResult?: boolean | ValidationResult, validator?: RuleValidator) => boolean;
//#endregion
//#region ../core/src/utils/mergeAnyTranslations.d.ts
/**
* Merges any number of partial translations into a single definition.
*/
declare const mergeAnyTranslations: (base: Record<string, Record<string, unknown>>, ...otherTranslations: (Record<string, Record<string, unknown>> | undefined)[]) => Record<string, Record<string, unknown>>;
declare const mergeAnyTranslation: (el: string, keyPropContextMap: Record<string, [unknown, unknown]>, defaults?: Record<string, Record<string, unknown>>) => Record<string, Record<string, unknown>> | undefined;
//#endregion
//#region ../core/src/utils/mergeClassnames.d.ts
type MergeClassnamesParams = (Partial<Classnames> | undefined)[];
/**
* Merges a list of partial {@link Classnames} definitions into a single definition.
*/
declare const mergeClassnames: (...args: MergeClassnamesParams) => Classnames;
//#endregion
//#region ../core/src/utils/misc.d.ts
/**
* Converts a value to lowercase if it's a string, otherwise returns the value as is.
*/
declare const lc: <T$1>(v: T$1) => T$1;
/**
* Regex matching numeric strings. Passes for positive/negative integers, decimals,
* and E notation, with optional surrounding whitespace.
*/
declare const numericRegex: RegExp;
/**
* Determines if a variable is a plain old JavaScript object, aka POJO.
*/
declare const isPojo: (obj: any) => obj is Record<string, any>;
/**
* Simple helper to determine whether a value is null, undefined, or an empty string.
*/
declare const nullOrUndefinedOrEmpty: (value: unknown) => value is null | undefined | "";
//#endregion
//#region ../core/src/utils/objectUtils.d.ts
/**
* Original looked like this (not sure why template string is used):
* ```
* type ObjectKeys<T extends object> = `${Exclude<keyof T, symbol>}`;
* ```
*/
type ObjectKeys<T$1 extends object> = Exclude<keyof T$1, symbol>;
/**
* A strongly-typed version of `Object.keys()`.
*
* [Original source](https://github.com/sindresorhus/ts-extras/blob/44f57392c5f027268330771996c4fdf9260b22d6/source/object-keys.ts)
*/
declare const objectKeys: <Type extends object>(value: Type) => Array<ObjectKeys<Type>>;
/**
* A strongly-typed version of `Object.entries()`.
*
* [Original source](https://github.com/sindresorhus/ts-extras/blob/44f57392c5f027268330771996c4fdf9260b22d6/source/object-entries.ts)
*/
declare const objectEntries: <Type extends Record<PropertyKey, unknown>>(value: Type) => Array<[ObjectKeys<Type>, Type[ObjectKeys<Type>]]>;
//#endregion
//#region ../core/src/utils/optGroupUtils.d.ts
/**
* Converts an {@link Option} or {@link ValueOption} (i.e., {@link BaseOption})
* into a {@link FullOption}. Full options are left unchanged.
*
* @group Option Lists
*/
declare function toFullOption<Opt$1 extends BaseOption>(opt: Opt$1 | string, baseProperties?: Record<string, unknown>, labelMap?: Record<string, unknown>): ToFullOption<Opt$1>;
/**
* Converts an {@link OptionList} or {@link FlexibleOptionList} into a {@link FullOptionList}.
* Lists of full options are left unchanged.
*
* @group Option Lists
*/
declare function toFullOptionList<Opt$1 extends BaseOption>(optList: unknown[], baseProperties?: Record<string, unknown>, labelMap?: Record<string, unknown>): FullOptionList<Opt$1>;
/**
* Converts a {@link FlexibleOptionList} into a {@link FullOptionList}.
* Lists of full options are left unchanged.
*
* @group Option Lists
*/
declare function toFullOptionMap<OptMap extends BaseOptionMap>(optMap: OptMap, baseProperties?: Record<string, unknown>): OptMap extends BaseOptionMap<infer V, infer K> ? Partial<Record<K, ToFullOption<V>>> : never;
/**
* @deprecated Renamed to {@link uniqByIdentifier}.
*
* @group Option Lists
*/
declare const uniqByName: <T$1 extends {
  name: string;
  value?: string;
} | {
  name?: string;
  value: string;
}>(originalArray: T$1[]) => T$1[];
/**
* Generates a new array of objects with duplicates removed based
* on the identifying property (`value` or `name`)
*
* @group Option Lists
*/
declare const uniqByIdentifier: <T$1 extends RequireAtLeastOne<{
  name: string;
  value: string;
}, "name" | "value">>(originalArray: T$1[]) => T$1[];
/**
* Determines if an {@link OptionList} is an {@link OptionGroup} array.
*
* @group Option Lists
*/
declare const isOptionGroupArray: (arr: any) => arr is OptionGroup<BaseOption>[];
/**
* Determines if an array is a flat array of {@link FlexibleOption}.
*
* @group Option Lists
*/
declare const isFlexibleOptionArray: (arr: any) => arr is FlexibleOption[];
/**
* Determines if an array is a flat array of {@link FullOption}.
*
* @group Option Lists
*/
declare const isFullOptionArray: (arr: any) => arr is FullOption[];
/**
* Determines if a {@link FlexibleOptionList} is a {@link FlexibleOptionGroup} array.
*
* @group Option Lists
*/
declare const isFlexibleOptionGroupArray: (arr: any, {
  allowEmpty
}?: {
  allowEmpty?: boolean;
}) => arr is FlexibleOptionGroup[];
/**
* Determines if a {@link FlexibleOptionList} is a {@link OptionGroup} array of {@link FullOption}.
*
* @group Option Lists
*/
declare const isFullOptionGroupArray: (arr: any, {
  allowEmpty
}?: {
  allowEmpty?: boolean;
}) => arr is OptionGroup<FullOption>[];
/**
* Gets the option from an {@link OptionList} with the given `name`. Handles
* {@link Option} arrays as well as {@link OptionGroup} arrays.
*
* @group Option Lists
*/
declare function getOption<OptType extends FullOption>(arr: FullOptionList<OptType>, name: string): OptType | undefined;
declare function getOption<OptType extends ValueOption>(arr: FlexibleOptionList<OptType>, name: string): OptType | undefined;
declare function getOption<OptType extends Option>(arr: FlexibleOptionList<OptType>, name: string): OptType | undefined;
/**
* Gets the first option from an {@link OptionList}.
*
* @group Option Lists
*/
declare function getFirstOption<Opt$1 extends FullOption>(arr?: OptionGroup<Opt$1>[] | Opt$1[]): GetOptionIdentifierType<Opt$1> | null;
declare function getFirstOption<Opt$1 extends ValueOption>(arr?: OptionGroup<Opt$1>[] | Opt$1[]): GetOptionIdentifierType<Opt$1> | null;
declare function getFirstOption<Opt$1 extends Option>(arr?: OptionGroup<Opt$1>[] | Opt$1[]): GetOptionIdentifierType<Opt$1> | null;
/**
* Flattens {@link FlexibleOptionGroup} arrays into {@link BaseOption} arrays.
* If the array is already flat, it is returned as is.
*
* @group Option Lists
*/
declare const toFlatOptionArray: <T$1 extends FullOption, OL extends FullOptionList<T$1>>(arr: OL) => T$1[];
/**
* Generates a new {@link OptionGroup} array with duplicates
* removed based on the identifying property (`value` or `name`).
*
* @group Option Lists
*/
declare const uniqOptGroups: <T$1 extends BaseOption>(originalArray: FlexibleOptionGroup<T$1>[]) => OptionGroup<ToFullOption<T$1>>[];
/**
* Generates a new {@link Option} or {@link OptionGroup} array with duplicates
* removed based on the identifier property (`value` or `name`).
*
* @group Option Lists
*/
declare const uniqOptList: <T$1 extends BaseOption>(originalArray: FlexibleOptionList<T$1>) => WithUnknownIndex<BaseOption & FullOption>[] | OptionGroup<ToFullOption<T$1>>[];
interface PreparedOptionList<O extends FullOption> {
  defaultOption: FullOption;
  optionList: FullOptionList<O>;
  optionsMap: Partial<FullOptionRecord<FullOption>>;
}
interface PrepareOptionListParams<O extends FullOption> {
  placeholder?: Placeholder;
  optionList?: FlexibleOptionListProp<O> | BaseOptionMap<O>;
  baseOption?: Record<string, unknown>;
  labelMap?: Record<string, string>;
  autoSelectOption?: boolean;
}
declare const prepareOptionList: <O extends FullOption>(props: PrepareOptionListParams<O>) => PreparedOptionList<O>;
//#endregion
//#region ../core/src/utils/parseNumber.d.ts
/**
* Options object for {@link parseNumber}.
*/
interface ParseNumberOptions {
  parseNumbers?: ParseNumberMethod;
  /**
  * Generates a `bigint` value if the string represents a valid integer
  * outside the safe boundaries of the `number` type.
  */
  bigIntOnOverflow?: boolean;
}
/**
* Converts a string to a number. Uses native `parseFloat` if `parseNumbers` is "native",
* otherwise uses [`numeric-quantity`](https://jakeboone02.github.io/numeric-quantity/).
* If that returns `NaN`, the string is returned unchanged. Numeric values are returned
* as-is regardless of the `parseNumbers` option.
*/
declare const parseNumber: (val: any, {
  parseNumbers,
  bigIntOnOverflow
}?: ParseNumberOptions) => any;
//#endregion
//#region ../core/src/utils/pathUtils.d.ts
/**
* Return type for {@link findPath}.
*/
type FindPathReturnType = RuleGroupTypeAny | RuleType | null;
/**
* Returns the {@link RuleType} or {@link RuleGroupType}/{@link RuleGroupTypeIC}
* at the given path within a query.
*/
declare const findPath: (path: Path, query: RuleGroupTypeAny) => FindPathReturnType;
/**
* Returns the {@link RuleType} or {@link RuleGroupType}/{@link RuleGroupTypeIC}
* with the given `id` within a query.
*/
declare const findID: (id: string, query: RuleGroupTypeAny) => FindPathReturnType;
/**
* Returns the {@link Path} of the {@link RuleType} or {@link RuleGroupType}/{@link RuleGroupTypeIC}
* with the given `id` within a query.
*/
declare const getPathOfID: (id: string, query: RuleGroupTypeAny) => Path | null;
/**
* Truncates the last element of an array and returns the result as a new array.
*/
declare const getParentPath: (path: Path) => Path;
/**
* Determines if two paths (each `Path`) are equivalent.
*/
declare const pathsAreEqual: (path1: Path, path2: Path) => boolean;
/**
* Determines if the first path is an ancestor of the second path. The first path must
* be shorter and exactly match the second path up through the length of the first path.
*/
declare const isAncestor: (maybeAncestor: Path, path: Path) => boolean;
/**
* Finds the deepest/longest path that two paths have in common.
*/
declare const getCommonAncestorPath: (path1: Path, path2: Path) => Path;
/**
* Determines if the rule or group at the specified path is either disabled itself
* or disabled by an ancestor group.
*/
declare const pathIsDisabled: (path: Path, query: RuleGroupTypeAny) => boolean;
//#endregion
//#region ../core/src/utils/preferProp.d.ts
/**
* For given default, prop, and context values, return the first provided of prop,
* context, and default, in that order.
*/
declare const preferProp: (def: boolean, prop?: boolean, context?: boolean, doNotFinalize?: boolean) => boolean;
/**
* For given default, prop, and context values, return the first provided of prop,
* context, and default, in that order.
*/
declare const preferAnyProp: (def?: any, prop?: any, context?: any) => any;
/**
* For a given set of defaults, props, and context values, return the first provided of prop,
* context, and default—in that order—for each property in the defaults object.
*/
declare const preferFlagProps: (props?: QueryBuilderFlags, contextVals?: QueryBuilderFlags, finalize?: boolean) => QueryBuilderFlags;
//#endregion
//#region ../core/src/utils/prepareQueryObjects.d.ts
/**
* Options for {@link prepareRule}/{@link prepareRuleGroup}.
*/
interface PreparerOptions {
  idGenerator?: () => string;
}
/**
* Ensures that a rule is valid by adding an `id` property if it does not already exist.
*/
declare const prepareRule: (rule: RuleType, {
  idGenerator
}?: PreparerOptions) => RuleType;
/**
* Ensures that a rule group is valid by recursively adding an `id` property to the group itself
* and all its rules and subgroups where one does not already exist.
*/
declare const prepareRuleGroup: <RG extends RuleGroupTypeAny>(queryObject: RG, {
  idGenerator
}?: PreparerOptions) => RG;
/**
* Ensures that a rule or group is valid. See {@link prepareRule} and {@link prepareRuleGroup}.
*/
declare const prepareRuleOrGroup: <RG extends RuleGroupTypeAny>(rg: RG | RuleType, {
  idGenerator
}?: PreparerOptions) => RuleGroupType | RuleGroupTypeIC | RuleType;
//#endregion
//#region ../core/src/utils/queryTools.d.ts
/**
* Options for {@link add}.
*
* @group Query Tools
*/
interface AddOptions {
  /**
  * If the query extends `RuleGroupTypeIC` (i.e. the query has independent
  * combinators), then the first combinator in this list will be inserted
  * before the new rule/group if the parent group is not empty. This option
  * is overridden by `combinatorPreceding`.
  */
  combinators?: OptionList;
  /**
  * If the query extends `RuleGroupTypeIC` (i.e. the query has independent
  * combinators), then this combinator will be inserted before the new rule/group
  * if the parent group is not empty. This option will supersede `combinators`.
  */
  combinatorPreceding?: string;
  /**
  * ID generator.
  */
  idGenerator?: () => string;
}
/**
* Adds a rule or group to a query.
* @returns The new query with the rule or group added.
*
* @group Query Tools
*/
declare const add: <RG extends RuleGroupTypeAny>(query: RG, ruleOrGroup: RG | RuleType, parentPathOrID: Path | string, {
  combinators,
  combinatorPreceding,
  idGenerator
}?: AddOptions) => RG;
/**
* Options for {@link update}.
*
* @group Query Tools
*/
interface UpdateOptions {
  /**
  * When updating the `field` of a rule, the rule's `operator`, `value`, and `valueSource`
  * will be reset to their respective defaults. Defaults to `true`.
  */
  resetOnFieldChange?: boolean;
  /**
  * When updating the `operator` of a rule, the rule's `value` and `valueSource`
  * will be reset to their respective defaults. Defaults to `false`.
  */
  resetOnOperatorChange?: boolean;
  /**
  * Determines the default operator name for a given field.
  */
  getRuleDefaultOperator?: (field: string) => string;
  /**
  * Determines the valid value sources for a given field and operator.
  */
  getValueSources?: (field: string, operator: string) => ValueSources | ValueSourceFlexibleOptions;
  /**
  * Gets the default value for a given rule, in case the value needs to be reset.
  */
  getRuleDefaultValue?: (rule: RuleType) => any;
  /**
  * Determines the valid match modes for a given field.
  */
  getMatchModes?: (field: string) => MatchModeOptions;
}
/**
* Updates a property of a rule or group within a query.
* @returns The new query with the rule or group property updated.
*
* @group Query Tools
*/
declare const update: <RG extends RuleGroupTypeAny>(query: RG, prop: UpdateableProperties, value: any, pathOrID: Path | string, {
  resetOnFieldChange,
  resetOnOperatorChange,
  getRuleDefaultOperator,
  getValueSources,
  getRuleDefaultValue,
  getMatchModes
}?: UpdateOptions) => RG;
/**
* Removes a rule or group from a query.
* @returns The new query with the rule or group removed.
*
* @group Query Tools
*/
declare const remove: <RG extends RuleGroupTypeAny>(query: RG, pathOrID: Path | string) => RG;
/**
* Options for {@link move}.
*
* @group Query Tools
*/
interface MoveOptions {
  /**
  * When `true`, the source rule/group will not be removed from its original path.
  */
  clone?: boolean;
  /**
  * If the query extends `RuleGroupTypeIC` (i.e. the query is using independent
  * combinators), then the first combinator in this list will be inserted before
  * the rule/group if necessary.
  */
  combinators?: OptionList;
  /**
  * ID generator.
  */
  idGenerator?: () => string;
}
/**
* Moves a rule or group from one path to another. In the options parameter, pass
* `{ clone: true }` to copy instead of move.
* @returns The new query with the rule or group moved or cloned.
*
* @group Query Tools
*/
declare const move: <RG extends RuleGroupTypeAny>(query: RG, oldPathOrID: Path | string, newPath: Path | "up" | "down", {
  clone,
  combinators,
  idGenerator
}?: MoveOptions) => RG;
/**
* Options for {@link insert}.
*
* @group Query Tools
*/
interface InsertOptions {
  /**
  * If the query extends `RuleGroupTypeIC` (i.e. the query has independent
  * combinators), then the first combinator in this list will be inserted
  * before the new rule/group if the parent group is not empty. This option
  * is overridden by `combinatorPreceding`.
  */
  combinators?: OptionList;
  /**
  * If the query extends `RuleGroupTypeIC` (i.e. the query has independent
  * combinators), then this combinator will be inserted before the new rule/group
  * if the parent group is not empty and the new rule/group is not the first in the
  * group (`path.at(-1) > 0`). This option will supersede `combinators`.
  */
  combinatorPreceding?: string;
  /**
  * If the query extends `RuleGroupTypeIC` (i.e. the query has independent
  * combinators), then this combinator will be inserted after the new rule/group
  * if the parent group is not empty and the new rule/group is the first in the
  * group (`path.at(-1) === 0`). This option will supersede `combinators`.
  */
  combinatorSucceeding?: string;
  /**
  * ID generator.
  *
  * @default generateID
  */
  idGenerator?: () => string;
  /**
  * When `true`, the new rule/group will replace the rule/group at `path`.
  */
  replace?: boolean;
}
/**
* Inserts a rule or group into a query.
* @returns The new query with the rule or group inserted.
*
* @group Query Tools
*/
declare const insert: <RG extends RuleGroupTypeAny>(query: RG, ruleOrGroup: RG | RuleType, path: number[], {
  combinators,
  combinatorPreceding,
  combinatorSucceeding,
  idGenerator,
  replace
}?: InsertOptions) => RG;
/**
* Options for {@link group}.
*
* @group Query Tools
*/
interface GroupOptions {
  /**
  * When `true`, the source rule/group will not be removed from its original path.
  */
  clone?: boolean;
  /**
  * If the query extends `RuleGroupTypeIC` (i.e. the query is using independent
  * combinators), then the first combinator in this list will be inserted between
  * the two rules/groups.
  */
  combinators?: OptionList;
  /**
  * ID generator.
  */
  idGenerator?: () => string;
}
/**
* Creates a new group at a target path with its `rules` array containing the current
* objects at the target path and the source path. In the options parameter, pass
* `{ clone: true }` to copy the source rule/group instead of move.
*
* @returns The new query with the rules or groups grouped.
*
* @group Query Tools
*/
declare const group: <RG extends RuleGroupTypeAny>(query: RG, sourcePathOrID: Path | string, targetPathOrID: Path | string, {
  clone,
  combinators,
  idGenerator
}?: GroupOptions) => RG;
//#endregion
//#region ../core/src/utils/regenerateIDs.d.ts
/**
* Options object for {@link regenerateID}/{@link regenerateIDs}.
*/
interface RegenerateIdOptions {
  idGenerator?: () => string;
}
/**
* Generates a new `id` property for a rule.
*/
declare const regenerateID: <R$1 extends RuleType>(rule: R$1, {
  idGenerator
}?: RegenerateIdOptions) => SetRequired<R$1, "id">;
/**
* Recursively generates new `id` properties for a rule group and all its rules and subgroups.
*/
declare const regenerateIDs: <RG>(subject: RG, {
  idGenerator
}?: RegenerateIdOptions) => RG & {
  id: string;
};
//#endregion
//#region ../core/src/utils/transformQuery.d.ts
/**
* Options object for {@link index!transformQuery transformQuery}.
*/
interface TransformQueryOptions<RG extends RuleGroupTypeAny = RuleGroupType> {
  /**
  * When a rule is encountered in the hierarchy, it will be replaced
  * with the result of this function.
  *
  * @defaultValue `r => r`
  */
  ruleProcessor?: (rule: RuleType) => any;
  /**
  * When a group is encountered in the hierarchy (including the root group, the
  * query itself), it will be replaced with the result of this function.
  *
  * @defaultValue `rg => rg`
  */
  ruleGroupProcessor?: (ruleGroup: RG) => Record<string, any>;
  /**
  * For each rule and group in the query, any properties matching a key
  * in this object will be renamed to the corresponding value. To retain both
  * the new _and_ the original properties, set `deleteRemappedProperties`
  * to `false`.
  *
  * If a key has a value of `false`, the corresponding property will be removed
  * without being copied to a new property name. (Warning: `{ rules: false }`
  * will prevent recursion and only return the processed root group.)
  *
  * @defaultValue `{}`
  *
  * @example
  * ```
  *   transformQuery(
  *     { combinator: 'and', not: true, rules: [] },
  *     { propertyMap: { combinator: 'AndOr', not: false } }
  *   )
  *   // Returns: { AndOr: 'and', rules: [] }
  * ```
  */
  propertyMap?: Record<string, string | false>;
  /**
  * Any combinator values (including independent combinators) will be translated
  * from the key in this object to the value.
  *
  * @defaultValue `{}`
  *
  * @example
  * ```
  *   transformQuery(
  *     { combinator: 'and', rules: [] },
  *     { combinatorMap: { and: '&&', or: '||' } }
  *   )
  *   // Returns: { combinator: '&&', rules: [] }
  * ```
  */
  combinatorMap?: Record<string, string>;
  /**
  * Any operator values will be translated from the key in this object to the value.
  *
  * @defaultValue `{}`
  *
  * @example
  * ```
  *   transformQuery(
  *     { combinator: 'and', rules: [{ field: 'name', operator: '=', value: 'Steve Vai' }] },
  *     { operatorMap: { '=': 'is' } }
  *   )
  *   // Returns:
  *   // {
  *   //   combinator: 'and',
  *   //   rules: [{ field: 'name', operator: 'is', value: 'Steve Vai' }]
  *   // }
  * ```
  */
  operatorMap?: Record<string, string>;
  /**
  * Prevents the `path` property (see {@link index!Path Path}) from being added to each
  * rule and group in the hierarchy.
  *
  * @defaultValue `false`
  */
  omitPath?: boolean;
  /**
  * Original properties remapped according to the `propertyMap` option will be removed.
  *
  * @defaultValue `true`
  *
  * @example
  * ```
  *   transformQuery(
  *     { combinator: 'and', rules: [] },
  *     { propertyMap: { combinator: 'AndOr' }, deleteRemappedProperties: false }
  *   )
  *   // Returns: { combinator: 'and', AndOr: 'and', rules: [] }
  * ```
  */
  deleteRemappedProperties?: boolean;
}
/**
* Recursively process a query heirarchy using this versatile utility function.
*
* [Documentation](https://react-querybuilder.js.org/docs/utils/misc#transformquery)
*/
declare function transformQuery(query: RuleGroupType, options?: TransformQueryOptions): any;
/**
* Recursively process a query heirarchy with independent combinators using this
* versatile utility function.
*
* [Documentation](https://react-querybuilder.js.org/docs/utils/misc#transformquery)
*/
declare function transformQuery(query: RuleGroupTypeIC, options?: TransformQueryOptions<RuleGroupTypeIC>): any;
//#endregion
//#region src/components/RuleGroup.d.ts
/**
* Default component to display {@link RuleGroupType} and {@link RuleGroupTypeIC}
* objects. This is actually a small wrapper around {@link RuleGroupHeaderComponents}
* and {@link RuleGroupBodyComponents}.
*
* @group Components
*/
declare const RuleGroup: React.MemoExoticComponent<(props: RuleGroupProps) => React.JSX.Element>;
/**
* Renders a `React.Fragment` containing an array of form controls for managing
* a {@link RuleGroupType} or {@link RuleGroupTypeIC}.
*
* @group Components
*/
declare const RuleGroupHeaderComponents: React.MemoExoticComponent<(rg: UseRuleGroup) => React.JSX.Element>;
/**
* Renders a `React.Fragment` containing an array of either (1) {@link Rule} and
* {@link RuleGroup}, or (2) {@link Rule}, {@link RuleGroup}, and {@link InlineCombinator}.
*
* @group Components
*/
declare const RuleGroupBodyComponents: React.MemoExoticComponent<(rg: UseRuleGroup) => React.JSX.Element>;
interface UseRuleGroup extends RuleGroupProps {
  addGroup: ActionElementEventHandler;
  addRule: ActionElementEventHandler;
  accessibleDescription: string;
  muted?: boolean;
  classNames: Pick<{ [k in keyof Classnames]: string }, "header" | "shiftActions" | "dragHandle" | "combinators" | "notToggle" | "addRule" | "addGroup" | "cloneGroup" | "lockGroup" | "muteGroup" | "removeGroup" | "body">;
  cloneGroup: ActionElementEventHandler;
  onCombinatorChange: ValueChangeEventHandler;
  onGroupAdd: (group: RuleGroupTypeAny, parentPath: Path, context?: any) => void;
  onIndependentCombinatorChange: (value: any, index: number, context?: any) => void;
  onNotToggleChange: (checked: boolean, context?: any) => void;
  outerClassName: string;
  pathsMemo: {
    path: Path;
    disabled: boolean;
  }[];
  removeGroup: ActionElementEventHandler;
  ruleGroup: RuleGroupType | RuleGroupTypeIC;
  shiftGroupDown: (event?: MouseEvent, context?: any) => void;
  shiftGroupUp: (event?: MouseEvent, context?: any) => void;
  toggleLockGroup: ActionElementEventHandler;
  toggleMuteGroup: ActionElementEventHandler;
  validationClassName: string;
  validationResult: boolean | ValidationResult;
}
/**
* Prepares all values and methods used by the {@link RuleGroup} component.
*
* @group Hooks
*/
declare const useRuleGroup: (props: RuleGroupProps) => UseRuleGroup;
//#endregion
//#region src/types/props.d.ts
/**
* Base interface for all subcomponents.
*
* @group Props
*/
interface CommonSubComponentProps<F extends FullOption = FullField, O extends string = string> {
  /**
  * CSS classNames to be applied.
  *
  * This is `string` and not {@link Classname} because the {@link Rule}
  * and {@link RuleGroup} components run `clsx()` to produce the `className`
  * that gets passed to each subcomponent.
  */
  className?: string;
  /**
  * Path to this subcomponent's rule/group within the query.
  */
  path: Path;
  /**
  * The level of the current group. Always equal to `path.length`.
  */
  level: number;
  /**
  * The title/tooltip for this control.
  */
  title?: string;
  /**
  * Disables the control.
  */
  disabled?: boolean;
  /**
  * Container for custom props that are passed to all components.
  */
  context?: any;
  /**
  * Validation result of the parent rule/group.
  */
  validation?: boolean | ValidationResult;
  /**
  * Test ID for this component.
  */
  testID?: string;
  /**
  * All subcomponents receive the configuration schema as a prop.
  */
  schema: Schema<F, O>;
}
/**
* Base interface for selectors and editors.
*
* @group Props
*/
interface SelectorOrEditorProps<F extends FullOption = FullField, O extends string = string> extends CommonSubComponentProps<F, O> {
  value?: string;
  handleOnChange(value: any): void;
}
/**
* Base interface for selector components.
*/
interface BaseSelectorProps<OptType extends Option> extends SelectorOrEditorProps<ToFullOption<OptType>> {
  options: FullOptionList<OptType>;
}
/**
* Props for all `value` selector components.
*
* @group Props
*/
interface ValueSelectorProps<OptType extends Option = FullOption> extends BaseSelectorProps<OptType> {
  multiple?: boolean;
  listsAsArrays?: boolean;
}
/**
* Props for `combinatorSelector` components.
*
* @group Props
*/
interface CombinatorSelectorProps extends BaseSelectorProps<FullOption> {
  options: FullOptionList<FullCombinator>;
  rules: RuleOrGroupArray;
  ruleGroup: RuleGroupTypeAny;
}
/**
* Props for `fieldSelector` components.
*
* @group Props
*/
interface FieldSelectorProps<F extends FullField = FullField> extends BaseSelectorProps<F>, CommonRuleSubComponentProps {
  operator?: F extends FullField<string, infer OperatorName> ? OperatorName : string;
}
/**
* Props for `matchModeEditor` components.
*
* @group Props
*/
interface MatchModeEditorProps extends BaseSelectorProps<FullOption>, CommonRuleSubComponentProps {
  match: MatchConfig;
  selectorComponent?: ComponentType<ValueSelectorProps>;
  numericEditorComponent?: ComponentType<ValueEditorProps>;
  classNames: {
    matchMode: string;
    matchThreshold: string;
  };
  options: FullOptionList<FullOption<MatchMode>>;
  field: string;
  fieldData: FullField;
}
/**
* Props for `operatorSelector` components.
*
* @group Props
*/
interface OperatorSelectorProps extends BaseSelectorProps<FullOption>, CommonRuleSubComponentProps {
  options: FullOptionList<FullOperator>;
  field: string;
  fieldData: FullField;
}
/**
* Props for `valueSourceSelector` components.
*
* @group Props
*/
interface ValueSourceSelectorProps extends BaseSelectorProps<FullOption>, CommonRuleSubComponentProps {
  options: FullOptionList<FullOption<ValueSource>>;
  field: string;
  fieldData: FullField;
}
/**
* Utility type representing props for selector components
* that could potentially be any of the standard selector types.
*
* @group Props
*/
type VersatileSelectorProps = ValueSelectorProps & Partial<FieldSelectorProps> & Partial<OperatorSelectorProps> & Partial<CombinatorSelectorProps>;
/**
* A translation for a component with `title` and `label`.
*
* @group Props
*/
interface TranslationWithLabel extends BaseTranslationWithLabel<ReactNode> {}
/**
* A translation for a component with `title` only.
*
* @group Props
*/
interface Translation extends BaseTranslation {}
/**
* A translation for a component with `title` and a placeholder.
*
* @group Props
*/
interface TranslationWithPlaceholders extends BaseTranslationWithPlaceholders {}
/**
* The shape of the `translations` prop.
*
* @group Props
*/
interface Translations extends BaseTranslations<ReactNode> {}
/**
* The full `translations` interface with all properties required.
*
* @group Props
*/
type TranslationsFull = { [K in keyof Translations]: { [T in keyof Translations[K]]-?: Translations[K][T] } };
/**
* Props passed to every action component (rendered as `<button>` by default).
*
* @group Props
*/
interface ActionProps extends CommonSubComponentProps {
  /** Visible text. */
  label?: ReactNode;
  /**
  * Triggers the action, e.g. the addition of a new rule or group. The second parameter
  * will be forwarded to the `onAddRule` or `onAddGroup` callback if appropriate.
  */
  handleOnClick(e?: MouseEvent, context?: any): void;
  /**
  * Translation which overrides the regular `label`/`title` props when
  * the element is disabled.
  */
  disabledTranslation?: TranslationWithLabel;
  /**
  * The {@link RuleType} or {@link RuleGroupType}/{@link RuleGroupTypeIC}
  * associated with this element.
  */
  ruleOrGroup: RuleGroupTypeAny | RuleType;
  /**
  * Rules in this group (if the action element is for a group).
  */
  rules?: RuleOrGroupArray;
}
/**
* Props passed to every group action component.
*
* @deprecated Use {@link ActionProps} instead.
* @group Props
*/
interface ActionWithRulesProps extends ActionProps {}
/**
* Props passed to every action component that adds a rule or group.
*
* @deprecated Use {@link ActionProps} instead.
* @group Props
*/
interface ActionWithRulesAndAddersProps extends ActionProps {}
/**
* Props for `notToggle` components.
*
* @group Props
*/
interface NotToggleProps extends CommonSubComponentProps {
  checked?: boolean;
  handleOnChange(checked: boolean): void;
  label?: ReactNode;
  ruleGroup: RuleGroupTypeAny;
}
/**
* Props passed to `shiftActions` components.
*
* @group Props
*/
interface ShiftActionsProps extends CommonSubComponentProps {
  /**
  * Visible text for "shift up"/"shift down" elements.
  */
  labels?: {
    shiftUp?: ReactNode;
    shiftDown?: ReactNode;
  };
  /**
  * Tooltips for "shift up"/"shift down" elements.
  */
  titles?: {
    shiftUp?: string;
    shiftDown?: string;
  };
  /**
  * The {@link RuleType} or {@link RuleGroupType}/{@link RuleGroupTypeIC}
  * associated with this element.
  */
  ruleOrGroup: RuleGroupTypeAny | RuleType;
  /**
  * Method to shift the rule/group up one place.
  */
  shiftUp?: () => void;
  /**
  * Method to shift the rule/group down one place.
  */
  shiftDown?: () => void;
  /**
  * Whether shifting the rule/group up is disallowed.
  */
  shiftUpDisabled?: boolean;
  /**
  * Whether shifting the rule/group down is disallowed.
  */
  shiftDownDisabled?: boolean;
}
/**
* Props for `dragHandle` components.
*
* @group Props
*/
interface DragHandleProps extends CommonSubComponentProps {
  label?: ReactNode;
  ruleOrGroup: RuleGroupTypeAny | RuleType;
}
/**
* Props passed to `inlineCombinator` components.
*
* @group Props
*/
interface InlineCombinatorProps extends CombinatorSelectorProps {
  component: ComponentType<CombinatorSelectorProps>;
}
/**
* Props passed to `valueEditor` components.
*
* @group Props
*/
interface ValueEditorProps<F extends FullField = FullField, O extends string = string> extends SelectorOrEditorProps<F, O>, CommonRuleSubComponentProps {
  field: GetOptionIdentifierType<F>;
  operator: O;
  value?: any;
  valueSource: ValueSource;
  /** The entire {@link FullField} object. */
  fieldData: F;
  type?: ValueEditorType;
  inputType?: InputType | null;
  values?: any[];
  listsAsArrays?: boolean;
  parseNumbers?: ParseNumbersPropConfig;
  separator?: ReactNode;
  selectorComponent?: ComponentType<ValueSelectorProps>;
  /**
  * Only pass `true` if the {@link useValueEditor} hook has already run
  * in a parent/ancestor component. See usage in the compatibility packages.
  */
  skipHook?: boolean;
  schema: Schema<F, O>;
}
/**
* All subcomponents.
*
* @group Props
*/
type Controls<F extends FullField, O extends string> = Required<SetNonNullable<ControlElementsProp<F, O>, keyof ControlElementsProp<F, O>>>;
/**
* Subcomponents.
*
* @group Props
*/
type ControlElementsProp<F extends FullField, O extends string> = Partial<{
  /**
  * Default component for all button-type controls.
  *
  * @default ActionElement
  */
  actionElement: ComponentType<ActionProps>;
  /**
  * Adds a sub-group to the current group.
  *
  * @default ActionElement
  */
  addGroupAction: ComponentType<ActionProps> | null;
  /**
  * Adds a rule to the current group.
  *
  * @default ActionElement
  */
  addRuleAction: ComponentType<ActionProps> | null;
  /**
  * Clones the current group.
  *
  * @default ActionElement
  */
  cloneGroupAction: ComponentType<ActionProps> | null;
  /**
  * Clones the current rule.
  *
  * @default ActionElement
  */
  cloneRuleAction: ComponentType<ActionProps> | null;
  /**
  * Selects the `combinator` property for the current group, or the current independent combinator value.
  *
  * @default ValueSelector
  */
  combinatorSelector: ComponentType<CombinatorSelectorProps> | null;
  /**
  * Provides a draggable handle for reordering rules and groups.
  *
  * @default DragHandle
  */
  dragHandle: ForwardRefExoticComponent<DragHandleProps & RefAttributes<HTMLElement>> | null;
  /**
  * Selects the `field` property for the current rule.
  *
  * @default ValueSelector
  */
  fieldSelector: ComponentType<FieldSelectorProps<F>> | null;
  /**
  * A small wrapper around the `combinatorSelector` component.
  *
  * @default InlineCombinator
  */
  inlineCombinator: ComponentType<InlineCombinatorProps> | null;
  /**
  * Locks the current group (sets the `disabled` property to `true`).
  *
  * @default ActionElement
  */
  lockGroupAction: ComponentType<ActionProps> | null;
  /**
  * Locks the current rule (sets the `disabled` property to `true`).
  *
  * @default ActionElement
  */
  lockRuleAction: ComponentType<ActionProps> | null;
  /**
  * Mutes the current group (sets the `muted` property to `true`).
  *
  * @default ActionElement
  */
  muteGroupAction: ComponentType<ActionProps> | null;
  /**
  * Mutes the current rule (sets the `muted` property to `true`).
  *
  * @default ActionElement
  */
  muteRuleAction: ComponentType<ActionProps> | null;
  /**
  * Selects the `match` property for the current rule.
  *
  * @default MatchModeEditor
  */
  matchModeEditor: ComponentType<MatchModeEditorProps> | null;
  /**
  * Toggles the `not` property of the current group between `true` and `false`.
  *
  * @default NotToggle
  */
  notToggle: ComponentType<NotToggleProps> | null;
  /**
  * Selects the `operator` property for the current rule.
  *
  * @default ValueSelector
  */
  operatorSelector: ComponentType<OperatorSelectorProps> | null;
  /**
  * Removes the current group from its parent group's `rules` array.
  *
  * @default ActionElement
  */
  removeGroupAction: ComponentType<ActionProps> | null;
  /**
  * Removes the current rule from its parent group's `rules` array.
  *
  * @default ActionElement
  */
  removeRuleAction: ComponentType<ActionProps> | null;
  /**
  * Rule layout component.
  *
  * @default Rule
  */
  rule: ComponentType<RuleProps>;
  /**
  * Rule group layout component.
  *
  * @default RuleGroup
  */
  ruleGroup: ComponentType<RuleGroupProps<F, O>>;
  /**
  * Rule group body components.
  *
  * @default RuleGroupBodyComponents
  */
  ruleGroupBodyElements: ComponentType<RuleGroupProps & UseRuleGroup>;
  /**
  * Rule group header components.
  *
  * @default RuleGroupHeaderComponents
  */
  ruleGroupHeaderElements: ComponentType<RuleGroupProps & UseRuleGroup>;
  /**
  * Shifts the current rule/group up or down in the query hierarchy.
  *
  * @default ShiftActions
  */
  shiftActions: ComponentType<ShiftActionsProps> | null;
  /**
  * Updates the `value` property for the current rule.
  *
  * @default ValueEditor
  */
  valueEditor: ComponentType<ValueEditorProps<F, O>> | null;
  /**
  * Default component for all value selector controls.
  *
  * @default ValueSelector
  */
  valueSelector: ComponentType<ValueSelectorProps>;
  /**
  * Selects the `valueSource` property for the current rule.
  *
  * @default ValueSelector
  */
  valueSourceSelector: ComponentType<ValueSourceSelectorProps> | null;
}>;
/**
* Configuration options passed in the `schema` prop from
* {@link QueryBuilder} to each subcomponent.
*
* @group Props
*/
interface Schema<F extends FullField, O extends string> {
  qbId: string;
  fields: FullOptionList<F>;
  fieldMap: Partial<Record<GetOptionIdentifierType<F>, F>>;
  classNames: Classnames;
  combinators: FullOptionList<FullCombinator>;
  controls: Controls<F, O>;
  createRule(): RuleType;
  createRuleGroup(ic?: boolean): RuleGroupTypeAny;
  dispatchQuery(query: RuleGroupTypeAny): void;
  getQuery(): RuleGroupTypeAny;
  getOperators(field: string, meta: {
    fieldData: F;
  }): FullOptionList<FullOperator>;
  getValueEditorType(field: string, operator: string, meta: {
    fieldData: F;
  }): ValueEditorType;
  getValueEditorSeparator(field: string, operator: string, meta: {
    fieldData: F;
  }): ReactNode;
  getValueSources(field: string, operator: string, meta: {
    fieldData: F;
  }): ValueSourceFullOptions;
  getInputType(field: string, operator: string, meta: {
    fieldData: F;
  }): InputType | null;
  getValues(field: string, operator: string, meta: {
    fieldData: F;
  }): FullOptionList<Option>;
  getMatchModes(field: string, misc: {
    fieldData: F;
  }): MatchModeOptions;
  getSubQueryBuilderProps(field: GetOptionIdentifierType<F>, misc: {
    fieldData: F;
  }): QueryBuilderProps<RuleGroupTypeAny, FullOption, FullOption, FullOption>;
  getRuleClassname(rule: RuleType, misc: {
    fieldData: F;
  }): Classname;
  getRuleGroupClassname(ruleGroup: RuleGroupTypeAny): Classname;
  accessibleDescriptionGenerator: AccessibleDescriptionGenerator;
  showCombinatorsBetweenRules: boolean;
  showNotToggle: boolean;
  showShiftActions: boolean;
  showCloneButtons: boolean;
  showLockButtons: boolean;
  showMuteButtons: boolean;
  autoSelectField: boolean;
  autoSelectOperator: boolean;
  autoSelectValue: boolean;
  addRuleToNewGroups: boolean;
  enableDragAndDrop: boolean;
  validationMap: ValidationMap;
  independentCombinators: boolean;
  listsAsArrays: boolean;
  parseNumbers: ParseNumbersPropConfig;
  disabledPaths: Path[];
  suppressStandardClassnames: boolean;
  maxLevels: number;
}
/**
* Common props between {@link Rule} and {@link RuleGroup}.
*/
interface CommonRuleAndGroupProps<F extends FullField = FullField, O extends string = string> {
  id?: string;
  path: Path;
  parentDisabled?: boolean;
  parentMuted?: boolean;
  translations: Translations;
  schema: Schema<F, O>;
  actions: QueryActions;
  disabled?: boolean;
  shiftUpDisabled?: boolean;
  shiftDownDisabled?: boolean;
  context?: any;
}
/**
* Return type of {@link @react-querybuilder/dnd!useRuleGroupDnD} hook.
*/
interface UseRuleGroupDnD {
  isDragging: boolean;
  dragMonitorId: string | symbol;
  isOver: boolean;
  dropMonitorId: string | symbol;
  previewRef: Ref<HTMLDivElement>;
  dragRef: Ref<HTMLSpanElement>;
  dropRef: Ref<HTMLDivElement>;
  /** `"move"` by default; `"copy"` if the modifier key is pressed. */
  dropEffect?: DropEffect;
  /** True if the dragged and hovered items should form a new group. */
  groupItems?: boolean;
  dropNotAllowed?: boolean;
}
/**
* {@link RuleGroup} props.
*
* @group Props
*/
interface RuleGroupProps<F extends FullOption = FullOption, O extends string = string> extends CommonRuleAndGroupProps<F, O>, Partial<UseRuleGroupDnD> {
  ruleGroup: RuleGroupTypeAny<RuleType<GetOptionIdentifierType<F>, O>>;
  /**
  * @deprecated Use the `combinator` property of the `ruleGroup` prop instead
  */
  combinator?: string;
  /**
  * @deprecated Use the `rules` property of the `ruleGroup` prop instead
  */
  rules?: RuleOrGroupArray;
  /**
  * @deprecated Use the `not` property of the `ruleGroup` prop instead
  */
  not?: boolean;
}
/**
* Return type of {@link @react-querybuilder/dnd!useRuleDnD} hook.
*/
interface UseRuleDnD {
  isDragging: boolean;
  dragMonitorId: string | symbol;
  isOver: boolean;
  dropMonitorId: string | symbol;
  dragRef: Ref<HTMLSpanElement>;
  dndRef: Ref<HTMLDivElement>;
  /** `"move"` by default; `"copy"` if the modifier key is pressed. */
  dropEffect?: DropEffect;
  /** True if the dragged and hovered items should form a new group. */
  groupItems?: boolean;
  dropNotAllowed?: boolean;
}
/**
* {@link Rule} props.
*
* @group Props
*/
interface RuleProps<F extends string = string, O extends string = string> extends CommonRuleAndGroupProps<FullOption<F>, O>, Partial<UseRuleDnD> {
  rule: RuleType<F, O>;
  /**
  * @deprecated Use the `field` property of the `rule` prop instead
  */
  field?: string;
  /**
  * @deprecated Use the `operator` property of the `rule` prop instead
  */
  operator?: string;
  /**
  * @deprecated Use the `value` property of the `rule` prop instead
  */
  value?: any;
  /**
  * @deprecated Use the `valueSource` property of the `rule` prop instead
  */
  valueSource?: ValueSource;
}
/**
* Props passed down through context from a {@link QueryBuilderContextProvider}.
*
* @group Props
*/
interface QueryBuilderContextProps<F extends FullField = FullField, O extends string = string> extends QueryBuilderFlags {
  /**
  * Defines replacement components.
  */
  controlElements?: ControlElementsProp<F, O>;
  /**
  * This can be used to assign specific CSS classes to various controls
  * that are rendered by {@link QueryBuilder}.
  */
  controlClassnames?: Partial<Classnames>;
  /**
  * This can be used to override translatable texts applied to the various
  * controls that are rendered by {@link QueryBuilder}.
  */
  translations?: Partial<Translations>;
}
/**
* @group Props
*/
interface QueryBuilderContextProviderProps extends QueryBuilderContextProps {
  children?: ReactNode;
}
/**
* @group Components
*/
type QueryBuilderContextProvider<ExtraProps extends object = Record<string, any>> = ComponentType<QueryBuilderContextProviderProps & ExtraProps>;
/**
* Props for {@link QueryBuilder}.
*
* Notes:
* - Only one of `query` or `defaultQuery` should be provided. If `query` is present,
* then `defaultQuery` should be undefined and vice versa.
* - If rendered initially with a `query` prop, then `query` must be defined in every
* subsequent render or warnings will be logged (in non-production modes only).
*
* @typeParam RG - The type of the query object, inferred from either the `query` or `defaultQuery` prop.
* Must extend {@link RuleGroupType} or {@link RuleGroupTypeIC}.
* @typeParam F - The field type (see {@link Field}).
* @typeParam O - The operator type (see {@link Operator}).
* @typeParam C - The combinator type (see {@link Combinator}).
*
* @group Props
*/
type QueryBuilderProps<RG extends RuleGroupTypeAny, F extends FullField, O extends FullOperator, C extends FullCombinator> = RG extends RuleGroupType<infer R> | RuleGroupTypeIC<infer R> ? QueryBuilderContextProps<F, GetOptionIdentifierType<O>> & {
  /**
  * Initial query object for uncontrolled components.
  */
  defaultQuery?: RG;
  /**
  * Query object for controlled components.
  */
  query?: RG;
  /**
  * List of valid {@link FullField}s.
  *
  * @default []
  */
  fields?: FlexibleOptionListProp<F> | BaseOptionMap<F>;
  /**
  * List of valid {@link FullOperator}s.
  *
  * @see {@link DefaultOperatorName}
  *
  * @default
  * [
  *   { name: '=', label: '=' },
  *   { name: '!=', label: '!=' },
  *   { name: '<', label: '<' },
  *   { name: '>', label: '>' },
  *   { name: '<=', label: '<=' },
  *   { name: '>=', label: '>=' },
  *   { name: 'contains', label: 'contains' },
  *   { name: 'beginsWith', label: 'begins with' },
  *   { name: 'endsWith', label: 'ends with' },
  *   { name: 'doesNotContain', label: 'does not contain' },
  *   { name: 'doesNotBeginWith', label: 'does not begin with' },
  *   { name: 'doesNotEndWith', label: 'does not end with' },
  *   { name: 'null', label: 'is null' },
  *   { name: 'notNull', label: 'is not null' },
  *   { name: 'in', label: 'in' },
  *   { name: 'notIn', label: 'not in' },
  *   { name: 'between', label: 'between' },
  *   { name: 'notBetween', label: 'not between' },
  * ]
  */
  operators?: FlexibleOptionListProp<O>;
  /**
  * List of valid {@link FullCombinator}s.
  *
  * @see {@link DefaultCombinatorName}
  *
  * @default
  * [
  *   {name: 'and', label: 'AND'},
  *   {name: 'or', label: 'OR'},
  * ]
  */
  combinators?: FlexibleOptionListProp<C>;
  /**
  * Default properties applied to all objects in the `fields` prop. Properties on
  * individual field definitions will override these.
  */
  baseField?: Record<string, unknown>;
  /**
  * Default properties applied to all objects in the `operators` prop. Properties on
  * individual operator definitions will override these.
  */
  baseOperator?: Record<string, unknown>;
  /**
  * Default properties applied to all objects in the `combinators` prop. Properties on
  * individual combinator definitions will override these.
  */
  baseCombinator?: Record<string, unknown>;
  /**
  * The default `field` value for new rules. This can be the field `name`
  * itself or a function that returns a valid {@link FullField} `name` given
  * the `fields` list.
  */
  getDefaultField?: GetOptionIdentifierType<F> | ((fieldsData: FullOptionList<F>) => string);
  /**
  * The default `operator` value for new rules. This can be the operator
  * `name` or a function that returns a valid {@link FullOperator} `name` for
  * a given field name.
  */
  getDefaultOperator?: GetOptionIdentifierType<O> | ((field: GetOptionIdentifierType<F>, misc: {
    fieldData: F;
  }) => string);
  /**
  * Returns the default `value` for new rules.
  */
  getDefaultValue?(rule: R, misc: {
    fieldData: F;
  }): any;
  /**
  * This function should return the list of allowed {@link FullOperator}s
  * for the given {@link FullField} `name`. If `null` is returned, the
  * {@link DefaultOperator}s are used.
  */
  getOperators?(field: GetOptionIdentifierType<F>, misc: {
    fieldData: F;
  }): FlexibleOptionListProp<FullOperator> | null;
  /**
  * This function should return the type of {@link ValueEditor} (see
  * {@link ValueEditorType}) for the given field `name` and operator `name`.
  */
  getValueEditorType?(field: GetOptionIdentifierType<F>, operator: GetOptionIdentifierType<O>, misc: {
    fieldData: F;
  }): ValueEditorType;
  /**
  * This function should return the separator element for a given field
  * `name` and operator `name`. The element can be any valid React element,
  * including a bare string (e.g., "and" or "to") or an HTML element like
  * `<span />`. It will be placed in between value editors when multiple
  * editors are rendered, such as when the `operator` is `"between"`.
  */
  getValueEditorSeparator?(field: GetOptionIdentifierType<F>, operator: GetOptionIdentifierType<O>, misc: {
    fieldData: F;
  }): ReactNode;
  /**
  * This function should return the list of valid {@link ValueSources}
  * for a given field `name` and operator `name`. The return value must
  * be an array that includes at least one valid {@link ValueSource}
  * (i.e. `["value"]`, `["field"]`, `["value", "field"]`, or
  * `["field", "value"]`).
  */
  getValueSources?(field: GetOptionIdentifierType<F>, operator: GetOptionIdentifierType<O>, misc: {
    fieldData: F;
  }): ValueSources | ValueSourceFlexibleOptions;
  /**
  * This function should return the `type` of `<input />`
  * for the given field `name` and operator `name` (only applicable when
  * `getValueEditorType` returns `"text"` or a falsy value). If no
  * function is provided, `"text"` is used as the default.
  */
  getInputType?(field: GetOptionIdentifierType<F>, operator: GetOptionIdentifierType<O>, misc: {
    fieldData: F;
  }): InputType | null;
  /**
  * This function should return the list of allowed values for the
  * given field `name` and operator `name` (only applicable when
  * `getValueEditorType` returns `"select"` or `"radio"`). If no
  * function is provided, an empty array is used as the default.
  */
  getValues?(field: GetOptionIdentifierType<F>, operator: GetOptionIdentifierType<O>, misc: {
    fieldData: F;
  }): FlexibleOptionListProp<Option>;
  /**
  * This function should return the list of valid {@link MatchMode}s or
  * {@link MatchConfig}s for a given field `name`. The return value must
  * be an array that includes at least one valid {@link MatchMode}, or `true`
  * to indicate that all match modes are allowed. Any other return value
  * will be ignored (no match modes will be allowed).
  */
  getMatchModes?(field: GetOptionIdentifierType<F>, misc: {
    fieldData: F;
  }): boolean | MatchMode[] | FlexibleOption<MatchMode>[];
  /**
  * This function should return any props that a subquery (see {@link MatchMode})
  * should override from the props provided to this query builder. Note that certain
  * props like `query`, `onQueryChange`, and `enableDragAndDrop` will be ignored.
  */
  getSubQueryBuilderProps?(field: GetOptionIdentifierType<F>, misc: {
    fieldData: F;
  }): QueryBuilderProps<GenericizeRuleGroupType<RG>, FullOption, FullOption, FullOption>;
  /**
  * The return value of this function will be used to apply classnames to the
  * outer `<div>` of the given {@link Rule}.
  */
  getRuleClassname?(rule: R, misc: {
    fieldData: F;
  }): Classname;
  /**
  * The return value of this function will be used to apply classnames to the
  * outer `<div>` of the given {@link RuleGroup}.
  */
  getRuleGroupClassname?(ruleGroup: RG): Classname;
  /**
  * This callback is invoked before a new rule is added. The function should either manipulate
  * the rule and return the new object, return `true` to allow the addition to proceed as normal,
  * or return `false` to cancel the addition of the rule.
  */
  onAddRule?(rule: R, parentPath: Path, query: RG, context?: any): RuleType | boolean;
  /**
  * This callback is invoked before a new group is added. The function should either manipulate
  * the group and return the new object, return `true` to allow the addition to proceed as normal,
  * or return `false` to cancel the addition of the group.
  */
  onAddGroup?(ruleGroup: RG, parentPath: Path, query: RG, context?: any): RG | boolean;
  /**
  * This callback is invoked before a rule is moved or shifted. The function should return
  * `true` to allow the move/shift to proceed as normal, `false` to cancel the move/shift, or
  * a new query object (presumably based on `query` or `nextQuery`) which will become the new
  * query state.
  */
  onMoveRule?(rule: R, fromPath: Path, toPath: Path | "up" | "down", query: RG, nextQuery: RG, options: MoveOptions, context?: any): RG | boolean;
  /**
  * This callback is invoked before a group is moved or shifted. The function should return
  * `true` to allow the move/shift to proceed as normal, `false` to cancel the move/shift, or
  * a new query object (presumably based on `query` or `nextQuery`) which will become the new
  * query state.
  */
  onMoveGroup?(ruleGroup: RG, fromPath: Path, toPath: Path | "up" | "down", query: RG, nextQuery: RG, options: MoveOptions, context?: any): RG | boolean;
  /**
  * This callback is invoked before a rule is grouped with another object. The function should
  * return `true` to allow the grouping to proceed as normal, `false` to cancel the grouping,
  * or a new query object (presumably based on `query` or `nextQuery`) which will become the new
  * query state.
  */
  onGroupRule?(rule: R, fromPath: Path, toPath: Path, query: RG, nextQuery: RG, options: GroupOptions, context?: any): RG | boolean;
  /**
  * This callback is invoked before a group is grouped with another object. The function should
  * return `true` to allow the grouping to proceed as normal, `false` to cancel the grouping,
  * or a new query object (presumably based on `query` or `nextQuery`) which will become the new
  * query state.
  */
  onGroupGroup?(ruleGroup: RG, fromPath: Path, toPath: Path, query: RG, nextQuery: RG, options: GroupOptions, context?: any): RG | boolean;
  /**
  * This callback is invoked before a rule or group is removed. The function should return
  * `true` if the rule or group should be removed or `false` if it should not be removed.
  */
  onRemove?(ruleOrGroup: R | RG, path: Path, query: RG, context?: any): boolean;
  /**
  * This callback is invoked anytime the query state is updated.
  */
  onQueryChange?(query: RG): void;
  /**
  * Each log object will be passed to this function when `debugMode` is `true`.
  *
  * @default console.log
  */
  onLog?(obj: any): void;
  /**
  * @deprecated As of v7, this prop is ignored. To enable independent combinators, use
  * {@link RuleGroupTypeIC} for the `query` or `defaultQuery` prop. The query builder
  * will detect the query type and behave accordingly.
  */
  independentCombinators?: boolean;
  /**
  * Disables the entire query builder if true, or the rules and groups at
  * the specified paths (as well as all child rules/groups and subcomponents)
  * if an array of paths is provided. If the root path is specified (`disabled={[[]]}`),
  * no changes to the query are allowed.
  *
  * @default false
  */
  disabled?: boolean | Path[];
  /**
  * Store values as numbers whenever possible.
  *
  * _**TIP: Try `"strict-limited"` first.**_
  *
  * Options include `true`, `false`, `"enhanced"`, `"native"`, and `"strict"`. The `string` options
  * can be suffixed with `"-limited"`.
  *
  * - `false` avoids numeric parsing
  * - `true` or `"strict"` parses values using `numeric-quantity`, bailing out (returning the original
  *   string) when trailing invalid characters are present
  * - `"enhanced"` is the same as `true`/`"strict"`, but ignores trailing invalid characters (CAUTION:
  *   this can lead to information loss)
  * - `"native"` parses values using `parseFloat`, returning `NaN` when parsing fails
  *
  * When the value is `true` or a string without the "-limited" suffix, the default {@link ValueEditor}
  * will attempt to parse *all* inputs as numbers. **CAUTION: This can lead to unexpected behavior.**
  *
  * When the value is a string with the "-limited" suffix, the default {@link ValueEditor} will
  * only attempt to parse inputs as numbers when the `inputType` is `"number"`.
  *
  * @default false
  */
  parseNumbers?: ParseNumbersPropConfig;
  /**
  * Query validation function.
  */
  validator?: QueryValidator;
  /**
  * `id` generator function. Should always produce a unique/random value.
  *
  * @default crypto.randomUUID
  */
  idGenerator?: () => string;
  /**
  * Generator function for the `title` attribute applied to the outermost `<div>` of each
  * rule group. As this is intended to help with accessibility, the text output from this
  * function should be meaningful, descriptive, and unique within the page.
  */
  accessibleDescriptionGenerator?: AccessibleDescriptionGenerator;
  /**
  * Maximum number of levels deep the query is allowed to go. The minimum is 1; values
  * less than 1 will be ignored.
  */
  maxLevels?: number;
  /**
  * Container for custom props that are passed to all components.
  */
  context?: any;
} : never;
//#endregion
//#region src/components/ActionElement.d.ts
/**
* Default `<button>` component used by {@link QueryBuilder}.
*
* @group Components
*/
declare const ActionElement: (props: ActionProps) => React.JSX.Element;
//#endregion
//#region src/components/DragHandle.d.ts
/**
* Default drag handle component used by {@link QueryBuilder} when `enableDragAndDrop` is `true`.
*
* @group Components
*/
declare const DragHandle: React.ForwardRefExoticComponent<DragHandleProps & React.RefAttributes<HTMLSpanElement>>;
//#endregion
//#region src/components/InlineCombinator.d.ts
/**
* Default `inlineCombinator` component used by {@link QueryBuilder}. A small `<div>`
* wrapper around the `combinatorSelector` component, used when either
* `showCombinatorsBetweenRules` or `independentCombinators` are `true`.
*
* @group Components
*/
declare const InlineCombinator: (allProps: InlineCombinatorProps) => React.JSX.Element;
//#endregion
//#region src/components/MatchModeEditor.d.ts
/**
* Default `matchModeEditor` component used by {@link QueryBuilder}.
*
* @group Components
*/
declare const MatchModeEditor: (props: MatchModeEditorProps) => React.JSX.Element | null;
interface UseMatchModeEditor {
  thresholdNum: number;
  thresholdRule: RuleType;
  thresholdSchema: Schema<FullField, string>;
  handleChangeMode: (mode: MatchMode) => void;
  handleChangeThreshold: (threshold: number) => void;
}
declare const useMatchModeEditor: (props: MatchModeEditorProps) => UseMatchModeEditor;
//#endregion
//#region src/components/NotToggle.d.ts
/**
* Default `notToggle` (aka inversion) component used by {@link QueryBuilder}.
*
* @group Components
*/
declare const NotToggle: (props: NotToggleProps) => React.JSX.Element;
//#endregion
//#region src/hooks/useControlledOrUncontrolled.d.ts
interface UseControlledOrUncontrolledParams {
  defaultQuery?: RuleGroupTypeAny;
  queryProp?: RuleGroupTypeAny;
}
/**
* Logs a warning when the component changes from controlled to uncontrolled,
* vice versa, or both `query` and `defaultQuery` are provided.
*
* @group Hooks
*/
declare const useControlledOrUncontrolled: (params: UseControlledOrUncontrolledParams) => void;
//#endregion
//#region src/hooks/useDeprecatedProps.d.ts
/**
* Logs an error to the console if any of the following are true:
* - `QueryBuilder` is rendered with an `independentCombinators` prop
* - `RuleGroup` is rendered with `combinator` or `rules` props (deprecated in favor of `ruleGroup`)
* - `Rule` is rendered with `field`, `operator`, or `value` props (deprecated in favor of `rule`)
*
* @group Hooks
*/
declare function useDeprecatedProps(type: "independentCombinators", logWarning: boolean, otherParams: "invalid" | "unnecessary"): void;
declare function useDeprecatedProps(type: "rule" | "ruleGroup", logWarning: boolean): void;
//#endregion
//#region src/hooks/useFields.d.ts
interface UseFields<F extends FullField> {
  defaultField: FullField;
  fields: FullOptionList<F>;
  fieldMap: Partial<FullOptionRecord<FullField>>;
}
declare const useFields: <F extends FullField>(props: {
  translations: TranslationsFull;
} & Pick<QueryBuilderProps<RuleGroupTypeAny, F, FullOperator, FullCombinator>, "fields" | "baseField" | "autoSelectField">) => UseFields<F>;
//#endregion
//#region src/hooks/useMergedContext.d.ts
type UseMergedContextParams<F extends FullField = FullField, O extends string = string, Finalize extends boolean | undefined = undefined> = QueryBuilderContextProps<F, O> & {
  initialQuery?: RuleGroupTypeAny;
  qbId?: string;
  /**
  * When true, props and context are merged with defaults to ensure all properties
  * are defined. Action elements and value selectors are merged with their respective
  * bulk override components. Only needs to be true when run from `QueryBuilder`.
  */
  finalize?: Finalize;
};
interface UseMergedContext<F extends FullField = FullField, O extends string = string, Finalize extends boolean | undefined = undefined> extends QueryBuilderContextProps<F, O>, QueryBuilderFlags {
  enableDragAndDrop: Finalize extends true ? boolean : boolean | undefined;
  initialQuery?: RuleGroupTypeAny;
  qbId?: string;
  controlElements: Finalize extends true ? Controls<F, O> : Partial<Controls<F, O>>;
  controlClassnames: Classnames;
  translations: Finalize extends true ? TranslationsFull : Partial<Translations>;
}
/**
* Merges inherited context values with props, giving precedence to props.
*
* @group Hooks
*/
declare const useMergedContext: <F extends FullField = FullField, O extends string = string, Finalize extends boolean | undefined = undefined>({
  finalize,
  ...props
}: UseMergedContextParams<F, O, Finalize>) => UseMergedContext<F, O, Finalize>;
//#endregion
//#region src/hooks/useOptionListProp.d.ts
interface UseOptionListProp<O extends FullOption> extends PreparedOptionList<O> {}
interface UseOptionListPropParams<O extends FullOption> extends PrepareOptionListParams<O> {}
/**
* @group Hooks
* @deprecated Memoize the result of `prepareOptionList` instead.
*/
declare const useOptionListProp: <O extends FullOption>(props: UseOptionListPropParams<O>) => UseOptionListProp<O>;
//#endregion
//#region src/hooks/usePathsMemo.d.ts
interface PathInfo {
  path: Path;
  disabled: boolean;
}
declare const usePathsMemo: ({
  disabled,
  path,
  nestedArray,
  disabledPaths
}: {
  disabled: boolean;
  path: Path;
  nestedArray: unknown[];
  disabledPaths: Path[];
}) => PathInfo[];
//#endregion
//#region src/hooks/usePreferProp.d.ts
/**
* For given default, prop, and context values, return the first provided of prop,
* context, and default, in that order.
*
* @group Hooks
*/
declare const usePreferProp: (def: boolean, prop?: boolean, context?: boolean, doNotFinalize?: boolean) => boolean;
/**
* For given default, prop, and context values, return the first provided of prop,
* context, and default, in that order.
*
* @group Hooks
*/
declare const usePreferAnyProp: (def?: any, prop?: any, context?: any) => any;
//#endregion
//#region src/hooks/usePrevious.d.ts
/**
* Returns the prop value from the last render.
*
* Adapted from https://usehooks.com/usePrevious/.
*
* @group Hooks
*/
declare const usePrevious: <T$1>(value: T$1) => T$1 | null;
//#endregion
//#region src/hooks/useReactDndWarning.d.ts
/**
* Logs a warning if drag-and-drop is enabled but the required dependencies
* (`react-dnd` and either `react-dnd-html5-backend` or `react-dnd-touch-backend`)
* were not detected.
*
* @group Hooks
*/
declare const useReactDndWarning: (enableDragAndDrop: boolean, dndRefs: boolean) => void;
//#endregion
//#region src/hooks/useSelectElementChangeHandler.d.ts
interface UseSelectElementChangeHandlerParams {
  onChange: (v: string | string[]) => void;
  multiple?: boolean;
}
/**
* Returns a memoized change handler for HTML `<select>` elements.
*
* @group Hooks
*/
declare const useSelectElementChangeHandler: (params: UseSelectElementChangeHandlerParams) => ((e: ChangeEvent<HTMLSelectElement>) => void);
//#endregion
//#region src/hooks/useStopEventPropagation.d.ts
interface RQBMouseEventHandler {
  (event?: MouseEvent, context?: any): void;
}
/**
* Wraps an event handler function in another function that calls
* `event.preventDefault()` and `event.stopPropagation()` first. The
* returned function accepts and forwards a second `context` argument.
*
* @group Hooks
*/
declare const useStopEventPropagation: (method: RQBMouseEventHandler) => RQBMouseEventHandler;
//#endregion
//#region src/components/Rule.d.ts
/**
* Default component to display {@link RuleType} objects. This is
* actually a small wrapper around {@link RuleComponents}.
*
* @group Components
*/
declare const Rule: React.MemoExoticComponent<(r: RuleProps) => React.JSX.Element>;
interface RuleComponentsProps extends UseRule {
  subQuery?: UseRuleGroup;
  groupComponentsWrapper?: React.ComponentType<{
    children: React.ReactNode;
    className: string;
  }>;
}
/**
* Renders a `React.Fragment` containing an array of form controls for managing a {@link RuleType}.
*
* @group Components
*/
declare const RuleComponents: React.MemoExoticComponent<(r: RuleComponentsProps) => React.JSX.Element>;
/**
* @group Components
*/
declare const RuleWithSubQueryGroupComponentsWrapper: (props: React.PropsWithChildren) => React.JSX.Element;
/**
* @group Components
*/
declare const RuleComponentsWithSubQuery: React.MemoExoticComponent<(r: RuleComponentsProps) => React.JSX.Element>;
interface UseRule extends RuleProps {
  classNames: {
    shiftActions: string;
    dragHandle: string;
    fields: string;
    matchMode: string;
    matchThreshold: string;
    operators: string;
    valueSource: string;
    value: string;
    cloneRule: string;
    lockRule: string;
    muteRule: string;
    removeRule: string;
  };
  muted?: boolean;
  parentMuted?: boolean;
  cloneRule: ActionElementEventHandler;
  fieldData: FullField<string, string, string, FullOption, FullOption>;
  generateOnChangeHandler: (prop: Exclude<keyof RuleType, "id" | "path">) => ValueChangeEventHandler;
  onChangeValueSource: ValueChangeEventHandler;
  onChangeField: ValueChangeEventHandler;
  onChangeMatchMode: ValueChangeEventHandler;
  onChangeOperator: ValueChangeEventHandler;
  onChangeValue: ValueChangeEventHandler;
  hideValueControls: boolean;
  inputType: InputType | null;
  matchModes: MatchModeOptions;
  operators: OptionList<FullOperator>;
  outerClassName: string;
  removeRule: ActionElementEventHandler;
  shiftRuleUp: (event?: MouseEvent, _context?: any) => void;
  shiftRuleDown: (event?: MouseEvent, _context?: any) => void;
  subproperties: UseFields<FullField>;
  subQueryBuilderProps: Record<string, unknown>;
  toggleLockRule: ActionElementEventHandler;
  toggleMuteRule: ActionElementEventHandler;
  validationResult: boolean | ValidationResult;
  valueEditorSeparator: React.ReactNode;
  valueEditorType: ValueEditorType;
  values: FlexibleOptionList<Option>;
  valueSourceOptions: ValueSourceFullOptions;
  valueSources: ValueSources;
}
/**
* Prepares all values and methods used by the {@link Rule} component.
*
* @group Hooks
*/
declare const useRule: (props: RuleProps) => UseRule;
//#endregion
//#region src/components/ShiftActions.d.ts
/**
* Default "shift up"/"shift down" buttons used by {@link QueryBuilder}.
*
* @group Components
*/
declare const ShiftActions: (props: ShiftActionsProps) => React.JSX.Element;
//#endregion
//#region src/components/ValueEditor.d.ts
/**
* Default `valueEditor` component used by {@link QueryBuilder}.
*
* @group Components
*/
declare const ValueEditor: <F extends FullField>(allProps: ValueEditorProps<F>) => React.JSX.Element | null;
interface UseValueEditor {
  /**
  * Array of values for when the main value represents a list, e.g. when operator
  * is "between" or "in".
  */
  valueAsArray: any[];
  /**
  * An update handler for a series of value editors, e.g. when operator is "between".
  * Calling this function will update a single element of the value array and leave
  * the rest of the array as is.
  *
  * @param {string} val The new value for the editor
  * @param {number} idx The index of the editor (and the array element to update)
  */
  multiValueHandler: (val: unknown, idx: number) => void;
  /**
  * An update handler for bigint editors, e.g. when `inputType` is "bigint" and
  * `parseNumbersMethod` is truthy.
  */
  bigIntValueHandler: (val: unknown) => void;
  /**
  * Evaluated `parseNumber` method based on `parseNumbers` prop. This property ends up
  * being the same as the `parseNumbers` prop minus the "-limited" suffix, unless
  * the "-limited" suffix is present and the `inputType` is not "number", in which case
  * it's set to `false`.
  */
  parseNumberMethod: ParseNumberMethod;
  /**
  * Class for items in a value editor series (e.g. "between" value editors).
  */
  valueListItemClassName: string;
  /**
  * Coerced `inputType` based on `inputType` and `operator`.
  */
  inputTypeCoerced: InputType;
}
/**
* This hook is primarily concerned with multi-value editors like date range
* pickers, editors for 'in' and 'between' operators, etc.
*
* @returns The value as an array (`valueAsArray`), a change handler for
* series of editors (`multiValueHandler`), a processed version of the
* `parseNumbers` prop (`parseNumberMethod`), and the classname(s) to be applied
* to each editor in editor series (`valueListItemClassName`).
*
* **NOTE:** The following logic only applies if `skipHook` is not `true`. To avoid
* automatically updating the `value`, pass `{ skipHook: true }`.
*
* If the `value` is an array of non-zero length, the `operator` is _not_ one of
* the known multi-value operators ("between", "notBetween", "in", "notIn"), and
* the `type` is not "multiselect", then the `value` will be set to the first
* element of the array (i.e., `value[0]`).
*
* The same thing will happen if `inputType` is "number" and `value` is a string
* containing a comma, since `<input type="number">` doesn't handle commas.
*
* @example
* // Consider the following rule:
* `{ field: "f1", operator: "in", value: ["twelve","fourteen"] }`
* // If `operator` changes to "=", the value will be reset to "twelve".
*
* @example
* // Consider the following rule:
* `{ field: "f1", operator: "between", value: "12,14" }`
* // If `operator` changes to "=", the value will be reset to "12".
*
* @group Hooks
*/
declare const useValueEditor: <F extends FullField = FullField, O extends string = string>(props: ValueEditorProps<F, O>) => UseValueEditor;
//#endregion
//#region src/components/ValueSelector.d.ts
/**
* Default `<select>` component used by {@link QueryBuilder}.
*
* @group Components
*/
declare const ValueSelector: <Opt$1 extends FullOption = FullOption>(props: ValueSelectorProps<Opt$1>) => React.JSX.Element;
type UseValueSelectorParams = Pick<ValueSelectorProps, "handleOnChange" | "listsAsArrays" | "multiple" | "value">;
/**
* Transforms a value into an array when appropriate and provides a memoized change handler.
*
* @group Hooks
*/
declare const useValueSelector: (props: UseValueSelectorParams) => {
  /**
  * Memoized change handler for value selectors
  */
  onChange: (v: string | string[]) => void;
  /**
  * The value as provided or, if appropriate, as an array
  */
  val: string | any[] | undefined;
};
//#endregion
//#region src/defaults.d.ts
/**
* Default components used by {@link QueryBuilder}.
*
* @group Defaults
*/
declare const defaultControlElements: {
  actionElement: typeof ActionElement;
  addGroupAction: typeof ActionElement;
  addRuleAction: typeof ActionElement;
  cloneGroupAction: typeof ActionElement;
  cloneRuleAction: typeof ActionElement;
  combinatorSelector: typeof ValueSelector;
  dragHandle: typeof DragHandle;
  fieldSelector: typeof ValueSelector;
  inlineCombinator: typeof InlineCombinator;
  lockGroupAction: typeof ActionElement;
  lockRuleAction: typeof ActionElement;
  matchModeEditor: typeof MatchModeEditor;
  muteGroupAction: typeof ActionElement;
  muteRuleAction: typeof ActionElement;
  notToggle: typeof NotToggle;
  operatorSelector: typeof ValueSelector;
  removeGroupAction: typeof ActionElement;
  removeRuleAction: typeof ActionElement;
  rule: typeof Rule;
  ruleGroup: typeof RuleGroup;
  ruleGroupBodyElements: typeof RuleGroupBodyComponents;
  ruleGroupHeaderElements: typeof RuleGroupHeaderComponents;
  shiftActions: typeof ShiftActions;
  valueEditor: typeof ValueEditor;
  valueSelector: typeof ValueSelector;
  valueSourceSelector: typeof ValueSelector;
};
//#endregion
//#region src/messages.d.ts
declare const messages: {
  readonly errorInvalidIndependentCombinatorsProp: "QueryBuilder was rendered with a truthy independentCombinators prop. This prop is deprecated and unnecessary. Furthermore, the initial query/defaultQuery prop was of type RuleGroupType instead of type RuleGroupIC. More info: https://react-querybuilder.js.org/docs/components/querybuilder#independent-combinators";
  readonly errorUnnecessaryIndependentCombinatorsProp: "QueryBuilder was rendered with the deprecated and unnecessary independentCombinators prop. To use independent combinators, make sure the query/defaultQuery prop is of type RuleGroupIC when the component mounts. More info: https://react-querybuilder.js.org/docs/components/querybuilder#independent-combinators";
  readonly errorDeprecatedRuleGroupProps: "A custom RuleGroup component has rendered a standard RuleGroup component with deprecated props. The combinator, not, and rules props should not be used. Instead, the full group object should be passed as the ruleGroup prop.";
  readonly errorDeprecatedRuleProps: "A custom RuleGroup component has rendered a standard Rule component with deprecated props. The field, operator, value, and valueSource props should not be used. Instead, the full rule object should be passed as the rule prop.";
  readonly errorBothQueryDefaultQuery: "QueryBuilder was rendered with both query and defaultQuery props. QueryBuilder must be either controlled or uncontrolled (specify either the query prop, or the defaultQuery prop, but not both). Decide between using a controlled or uncontrolled query builder and remove one of these props. More info: https://reactjs.org/link/controlled-components";
  readonly errorUncontrolledToControlled: "QueryBuilder is changing from an uncontrolled component to be controlled. This is likely caused by the query changing from undefined to a defined value, which should not happen. Decide between using a controlled or uncontrolled query builder for the lifetime of the component. More info: https://reactjs.org/link/controlled-components";
  readonly errorControlledToUncontrolled: "QueryBuilder is changing from a controlled component to be uncontrolled. This is likely caused by the query changing from defined to undefined, which should not happen. Decide between using a controlled or uncontrolled query builder for the lifetime of the component. More info: https://reactjs.org/link/controlled-components";
  readonly errorEnabledDndWithoutReactDnD: "QueryBuilder was rendered with the enableDragAndDrop prop set to true, but either react-dnd was not detected or one of react-dnd-html5-backend or react-dnd-touch-backend was not detected. To enable drag-and-drop functionality, install react-dnd and one of the backend packages and wrap QueryBuilder in QueryBuilderDnD from @react-querybuilder/dnd.";
  readonly errorDeprecatedDebugImport: "Importing from react-querybuilder/debug is deprecated. To enable Redux DevTools for React Query Builder's internal store, set globalThis.__RQB_DEVTOOLS__ = true.";
};
//#endregion
//#region src/utils/getCompatContextProvider.d.ts
type GetCompatContextProviderProps = QueryBuilderContextProps;
/**
* Generates a context provider for a compatibility package.
*/
declare const getCompatContextProvider: <F extends FullField, O extends string>(gccpProps: QueryBuilderContextProps<F, O>) => QueryBuilderContextProvider;
//#endregion
//#region src/utils/mergeTranslations.d.ts
/**
* Merges any number of partial {@link Translations} into a single definition.
*/
declare const mergeTranslations: (base: Partial<Translations>, ...otherTranslations: (Partial<Translations> | undefined)[]) => Partial<Translations>;
declare const mergeTranslation: (el: keyof Translations, keyPropContextMap: Record<string, [ReactNode, ReactNode]>, finalize?: boolean) => Record<string, Record<string, string>> | undefined;
//#endregion
//#region src/utils/toOptions.d.ts
/**
* Generates an array of `<option>` or `<optgroup>` elements
* from a given {@link OptionList}.
*
* @group Option Lists
*/
declare const toOptions: (arr?: OptionList) => React.JSX.Element[] | null;
//#endregion
//#region src/components/QueryBuilder.useQueryBuilderSetup.d.ts
type UseQueryBuilderSetup<RG extends RuleGroupTypeAny, F extends FullField, O extends FullOperator, C extends FullCombinator> = {
  qbId: string;
  rqbContext: UseMergedContext<F, GetOptionIdentifierType<O>, true>;
  fields: FullOptionList<F>;
  fieldMap: FullOptionMap<FullField<string, string, string, FullOption, FullOption>, GetOptionIdentifierType<F>>;
  combinators: WithUnknownIndex<BaseOption & FullOption>[] | OptionGroup<WithUnknownIndex<BaseOption & FullOption>>[];
  getRuleDefaultValue: <RT$1 extends RuleType = GetRuleTypeFromGroupWithFieldAndOperator<RG, F, O>>(r: RT$1) => any;
  createRule: () => GetRuleTypeFromGroupWithFieldAndOperator<RG, F, O>;
  createRuleGroup: (independentCombinators?: boolean) => RG;
} & RemoveNullability<{
  getInputTypeMain: QueryBuilderProps<RG, F, O, C>["getInputType"];
  getRuleDefaultOperator: QueryBuilderProps<RG, F, O, C>["getDefaultOperator"];
  getValueEditorTypeMain: QueryBuilderProps<RG, F, O, C>["getValueEditorType"];
}> & {
  getValueSourcesMain: (field: GetOptionIdentifierType<F>, operator: GetOptionIdentifierType<O>, misc: {
    fieldData: F;
  }) => ValueSourceFullOptions;
  getSubQueryBuilderPropsMain: (field: GetOptionIdentifierType<F>, misc: {
    fieldData: F;
  }) => Record<string, unknown>;
  getMatchModesMain: (field: GetOptionIdentifierType<F>, misc?: {
    fieldData: F;
  }) => MatchModeOptions;
  getOperatorsMain: (...p: Parameters<NonNullable<QueryBuilderProps<RG, F, O, C>["getOperators"]>>) => FullOptionList<O>;
  getValuesMain: (...p: Parameters<NonNullable<QueryBuilderProps<RG, F, O, C>["getValues"]>>) => FullOptionList<Option>;
};
/**
* Massages the props as necessary and prepares the basic update/generate methods
* for use by the {@link QueryBuilder} component.
*
* @group Hooks
*/
declare const useQueryBuilderSetup: <RG extends RuleGroupTypeAny, F extends FullField, O extends FullOperator, C extends FullCombinator>(props: QueryBuilderProps<RG, F, O, C>) => UseQueryBuilderSetup<RG, F, O, C>;
//#endregion
//#region src/components/QueryBuilder.useQueryBuilderSchema.d.ts
type UseQueryBuilderSchema<RG extends RuleGroupTypeAny, F extends FullField, O extends FullOperator, C extends FullCombinator> = Pick<UseQueryBuilderSetup<RG, F, O, C>, "rqbContext"> & {
  actions: QueryActions;
  rootGroup: RuleGroupTypeAny<GetRuleTypeFromGroupWithFieldAndOperator<RG, F, O>>;
  rootGroupDisabled: boolean;
  queryDisabled: boolean;
  schema: Schema<F, GetOptionIdentifierType<O>>;
  translations: TranslationsFull;
  wrapperClassName: string;
  dndEnabledAttr: string;
  inlineCombinatorsAttr: string;
  combinatorPropObject: Pick<RuleGroupProps, "combinator">;
};
/**
* For given {@link QueryBuilderProps} and setup values from {@link useQueryBuilderSetup},
* prepares and returns all values required to render a query builder.
*
* @group Hooks
*/
declare function useQueryBuilderSchema<RG extends RuleGroupTypeAny, F extends FullField, O extends FullOperator, C extends FullCombinator>(props: QueryBuilderProps<RG, F, O, C>, setup: UseQueryBuilderSetup<RG, F, O, C>): UseQueryBuilderSchema<RG, F, O, C>;
//#endregion
//#region src/components/QueryBuilder.useQueryBuilder.d.ts
/**
* Calls {@link useQueryBuilderSetup} to massage the props and prepare basic
* update/generate methods, then passes the result to {@link useQueryBuilderSchema}
* to prepare and return all values required to render {@link QueryBuilder}.
*
* @group Hooks
*/
declare const useQueryBuilder: <RG extends RuleGroupTypeAny, F extends FullField, O extends FullOperator, C extends FullCombinator>(props: QueryBuilderProps<RG, F, O, C>) => UseQueryBuilderSchema<RG, F, O, C>;
//#endregion
//#region src/components/QueryBuilderContext.d.ts
interface QueryBuilderContextType extends QueryBuilderContextProps<any, any> {
  initialQuery?: RuleGroupTypeAny;
  qbId?: string;
}
/**
* Context provider for {@link QueryBuilder}. Any descendant query builders
* will inherit the props from a context provider.
*/
declare const QueryBuilderContext: Context<QueryBuilderContextType>;
//#endregion
//#region src/components/QueryBuilder.d.ts
/**
* The query builder component for React.
*
* See https://react-querybuilder.js.org/ for demos and documentation.
*
* @group Components
*/
declare const QueryBuilder: <RG extends RuleGroupTypeAny, F extends FullField, O extends FullOperator, C extends FullCombinator>(props: QueryBuilderProps<RG, F, O, C>) => React.JSX.Element;
//#endregion
//#region src/components/QueryBuilderStateProvider.d.ts
/**
* Context provider for the `{@link QueryBuilder}` state store.
*
* @group Components
*/
declare const QueryBuilderStateProvider: (props: {
  children: React.ReactNode;
}) => React.JSX.Element;
//#endregion
//#region src/redux/queriesSlice.d.ts
type QueriesSliceState = Record<string, RuleGroupTypeAny>;
//#endregion
//#region src/redux/warningsSlice.d.ts
type ValuesAsKeys<T$1> = T$1 extends Record<infer _K, infer V> ? [V] extends [string] ? { [Key in V]: boolean } : never : never;
type WarningsSliceState = ValuesAsKeys<typeof messages>;
//#endregion
//#region src/redux/types.d.ts
interface RqbState {
  queries: QueriesSliceState;
  warnings: WarningsSliceState;
}
type RqbStore = EnhancedStore<RqbState, UnknownAction, Tuple<[StoreEnhancer<{
  dispatch: ThunkDispatch<RqbState, undefined, UnknownAction>;
}>, StoreEnhancer]>> & {
  addSlice: (slice: Slice) => void;
};
//#endregion
//#region src/redux/getRqbStore.d.ts
declare global {
  var __RQB_DEVTOOLS__: boolean | undefined;
}
/**
* Gets the singleton React Query Builder store instance.
* DevTools are enabled if either:
* - globalThis.__RQB_DEVTOOLS__ is truthy
* - window.__RQB_DEVTOOLS__ is truthy
*/
declare function getRqbStore(devTools?: boolean): RqbStore;
/**
* Injects a slice into the React Query Builder store. Useful for extensions
* that need to integrate their own state management.
*/
declare const injectSlice: (slice: Slice) => void;
//#endregion
//#region src/redux/hooks.d.ts
/**
* A Redux `useSelector` hook for RQB's internal store. See also {@link getQuerySelectorById}.
*
* **TIP:** Prefer {@link useQueryBuilderQuery} if you only need to access the query object
* for the nearest ancestor {@link QueryBuilder} component.
*
* @group Hooks
*/
declare const useQueryBuilderSelector: TypedUseSelectorHook<RqbState>;
/**
* Retrieves the full, latest query object for the nearest ancestor {@link QueryBuilder}
* component.
*
* The optional parameter should only be used when retrieving a query object from a different
* {@link QueryBuilder} than the nearest ancestor. It can be a full props object as passed
* to a custom component or any object matching the interface `{ schema: { qbId: string } }`.
*
* Must follow React's [Rules of Hooks](https://react.dev/warnings/invalid-hook-call-warning).
*
* @group Hooks
*/
declare const useQueryBuilderQuery: (props?: {
  schema: {
    qbId: string;
  };
}) => RuleGroupTypeAny;
//#endregion
//#region src/redux/QueryBuilderStateContext.d.ts
declare const QueryBuilderStateContext: React.Context<ReactReduxContextValue<RqbState> | null>;
//#endregion
//#region src/redux/selectors.d.ts
/**
* Given a `qbId` (passed to every component as part of the `schema` prop), returns
* a Redux selector for use with {@link useQueryBuilderSelector}.
*
* Note that {@link useQueryBuilderQuery} is a more concise way of accessing the
* query for the nearest ancestor {@link QueryBuilder} component.
*/
declare const getQuerySelectorById: (qbId: string) => (state: RqbState) => RuleGroupTypeAny;
//#endregion
//#region src/redux/store.d.ts
declare const queryBuilderStore: RqbStore;
//#endregion
export { UseFields as $, RQBJsonLogic as $a, defaultPlaceholderOperatorGroupLabel as $i, mergeClassnames as $n, GetRuleGroupType as $o, defaultRuleProcessorJSONata as $r, regenerateIDs as $t, useValueEditor as A, BaseTranslation as Aa, splitBy as Ai, PreparedOptionList as An, MatchModeOptions as Ao, jsonLogicAdditionalOperators as Ar, GetOptionIdentifierType as As, Schema as At, useSelectElementChangeHandler as B, ConstituentWordOrder as Ba, defaultCombinators as Bi, toFullOption as Bn, ValueSourceFlexibleOptions as Bo, sqlDialectPresets as Br, ValueOption as Bs, ValueEditorProps as Bt, messages as C, JsonLogicOr as Ca, defaultValidator as Ci, getPathOfID as Cn, FieldByValue as Co, celCombinatorMap as Cr, FlexibleOptionGroup as Cs, OperatorSelectorProps as Ct, useValueSelector as D, JsonLogicStrictEqual as Da, clsx as Di, ParseNumberOptions as Dn, InputType as Do, getQuotedFieldName as Dr, FullOptionList as Ds, QueryBuilderProps as Dt, ValueSelector as E, JsonLogicSome as Ea, convertToIC as Ei, pathsAreEqual as En, FullOperator as Eo, getQuoteFieldNamesWithArray as Er, FullOption as Es, QueryBuilderContextProviderProps as Et, RuleWithSubQueryGroupComponentsWrapper as F, Classnames as Fa, DefaultMatchModes as Fi, isFullOptionArray as Fn, Path as Fo, prismaOperators as Fr, OptionList as Fs, TranslationWithPlaceholders as Ft, PathInfo as G, FormatQueryFinalOptions as Ga, defaultOperatorLabelMap as Gi, uniqOptGroups as Gn, RuleValidator as Go, defaultRuleProcessorPrisma as Gr, RuleGroupBodyComponents as Gt, usePrevious as H, ExportFormat as Ha, defaultControlClassnames as Hi, toFullOptionMap as Hn, ValueSources as Ho, defaultOperatorProcessorSQL as Hr, ValueSourceSelectorProps as Ht, UseRule as I, CommonRuleSubComponentProps as Ia, DefaultOperators as Ii, isFullOptionGroupArray as In, RemoveNullability as Io, processMatchMode as Ir, StringUnionToFlexibleOptionArray as Is, Translations as It, UseOptionListPropParams as J, GroupVariantCondition as Ja, defaultPlaceholderFieldGroupLabel as Ji, objectKeys as Jn, DefaultRuleGroupICArray as Jo, defaultOperatorProcessorNL as Jr, useRuleGroup as Jt, usePathsMemo as K, FormatQueryOptions as Ka, defaultOperatorNegationMap as Ki, uniqOptList as Kn, ValidationMap as Ko, defaultRuleProcessorParameterized as Kr, RuleGroupHeaderComponents as Kt, useRule as L, Placeholder as La, LogType as Li, isOptionGroupArray as Ln, ValueChangeEventHandler as Lo, shouldRenderAsNumber as Lr, StringUnionToFullOptionArray as Ls, TranslationsFull as Lt, Rule as M, BaseTranslationWithPlaceholders as Ma, trimIfString as Mi, getOption as Mn, OperatorByValue as Mo, mongoOperators as Mr, NameLabelPair as Ms, ShiftActionsProps as Mt, RuleComponents as N, BaseTranslations as Na, DefaultCombinators as Ni, isFlexibleOptionArray as Nn, ParseNumberMethod as No, normalizeConstituentWordOrder as Nr, Option as Ns, Translation as Nt, UseValueEditor as O, JsonLogicStrictNotEqual as Oa, joinWith as Oi, parseNumber as On, MatchConfig as Oo, isValidValue as Or, FullOptionMap as Os, RuleGroupProps as Ot, RuleComponentsWithSubQuery as P, BaseTranslationsFull as Pa, DefaultCombinatorsExtended as Pi, isFlexibleOptionGroupArray as Pn, ParseNumbersPropConfig as Po, numerifyValues as Pr, OptionGroup as Ps, TranslationWithLabel as Pt, useMergedContext as Q, ParameterizedSQL as Qa, defaultPlaceholderName as Qi, numericRegex as Qn, GenericizeRuleGroupType as Qo, defaultRuleProcessorJsonLogic as Qr, regenerateID as Qt, useStopEventPropagation as R, QueryActions as Ra, TestID as Ri, prepareOptionList as Rn, ValueEditorType as Ro, formatQuery as Rr, ToFlexibleOption as Rs, UseRuleDnD as Rt, getCompatContextProvider as S, JsonLogicNotEqual as Sa, filterFieldsByComparator as Si, getParentPath as Sn, Field as So, bigIntJsonStringifyReplacer as Sr, FlexibleOption as Ss, NotToggleProps as St, UseValueSelectorParams as T, JsonLogicRulesLogic as Ta, convertQuery as Ti, pathIsDisabled as Tn, FullField as To, getNLTranslataion as Tr, FlexibleOptionListProp as Ts, QueryBuilderContextProvider as Tt, usePreferAnyProp as U, ExportObjectFormats as Ua, defaultJoinChar as Ui, uniqByIdentifier as Un, WithRequired as Uo, defaultRuleProcessorSQL as Ur, VersatileSelectorProps as Ut, useReactDndWarning as V, ConstituentWordOrderString as Va, defaultCombinatorsExtended as Vi, toFullOptionList as Vn, ValueSourceFullOptions as Vo, defaultValueProcessorNL as Vr, WithUnknownIndex as Vs, ValueSelectorProps as Vt, usePreferProp as W, ExportOperatorMap as Wa, defaultMatchModes as Wi, uniqByName as Wn, QueryValidator as Wo, defaultRuleProcessorSequelize as Wr, RuleGroup as Wt, UseMergedContext as X, NLTranslations as Xa, defaultPlaceholderFieldName as Xi, lc as Xn, DefaultRuleGroupTypeIC as Xo, defaultRuleProcessorMongoDBQuery as Xr, transformQuery as Xt, useOptionListProp as Y, NLTranslationKey as Ya, defaultPlaceholderFieldLabel as Yi, isPojo as Yn, DefaultRuleGroupTypeAny as Yo, defaultRuleProcessorNL as Yr, TransformQueryOptions as Yt, UseMergedContextParams as Z, ParameterizedNamedSQL as Za, defaultPlaceholderLabel as Zi, nullOrUndefinedOrEmpty as Zn, DefaultRuleOrGroupArray as Zo, defaultRuleProcessorLDAP as Zr, RegenerateIdOptions as Zt, useQueryBuilderSetup as _, JsonLogicInString as _a, defaultRuleGroupProcessorCEL as _i, preferProp as _n, ActionElementEventHandler as _o, defaultValueProcessor as _r, RuleType as _s, Controls as _t, useQueryBuilderSelector as a, defaultTranslations as aa, defaultRuleGroupProcessorPrisma as ai, add as an, SQLPreset as ao, isRuleGroupType as ar, CommonRuleAndGroupProperties as as, MatchModeEditor as at, mergeTranslations as b, JsonLogicNegation as ba, defaultRuleProcessorMongoDB as bi, findPath as bn, Combinator as bo, defaultValueProcessorSpELByRule as br, BaseOption as bs, InlineCombinatorProps as bt, RqbState as c, rootPath as ca, defaultRuleGroupProcessorNL as ci, move as cn, ValueProcessorLegacy as co, getValueSourcesUtil as cr, DefaultCombinatorName as cs, InlineCombinator as ct, QueryBuilder as d, JsonLogicAnd as da, defaultRuleGroupProcessorMongoDB as di, PreparerOptions as dn, DragCollection as do, getMatchModesUtil as dr, DefaultOperatorName as ds, ActionProps as dt, defaultPlaceholderOperatorLabel as ea, defaultRuleProcessorElasticSearch as ei, AddOptions as en, RQBJsonLogicEndsWith as eo, mergeAnyTranslation as er, GetRuleTypeFromGroupWithFieldAndOperator as es, useFields as et, QueryBuilderContext as f, JsonLogicDoubleNegation as fa, defaultRuleGroupProcessorLDAP as fi, prepareRule as fn, DraggedItem as fo, generateID as fr, DefaultRuleGroupArray as fs, ActionWithRulesAndAddersProps as ft, UseQueryBuilderSetup as g, JsonLogicInArray as ga, defaultRuleGroupProcessorDrizzle as gi, preferFlagProps as gn, AccessibleDescriptionGenerator as go, defaultSpELValueProcessor as gr, RuleGroupType as gs, ControlElementsProp as gt, useQueryBuilderSchema as h, JsonLogicGreaterThanOrEqual as ha, defaultRuleGroupProcessorElasticSearch as hi, preferAnyProp as hn, DropResult as ho, defaultMongoDBValueProcessor as hr, RuleGroupArray as hs, CommonSubComponentProps as ht, useQueryBuilderQuery as i, defaultPlaceholderValueName as ia, defaultRuleGroupProcessorSequelize as ii, UpdateOptions as in, RuleProcessor as io, isRuleGroup as ir, RuleOrGroupArray as is, NotToggle as it, ShiftActions as j, BaseTranslationWithLabel as ja, toArray as ji, getFirstOption as jn, Operator as jo, mapSQLOperator as jr, GetOptionType as js, SelectorOrEditorProps as jt, ValueEditor as k, JsonLogicVar as ka, nullFreeArray as ki, PrepareOptionListParams as kn, MatchMode as ko, isValueProcessorLegacy as kr, FullOptionRecord as ks, RuleProps as kt, RqbStore as l, standardClassnames as la, defaultRuleGroupProcessorMongoDBQuery as li, remove as ln, ValueProcessorOptions as lo, getValidationClassNames as lr, DefaultCombinatorNameExtended as ls, DragHandle as lt, UseQueryBuilderSchema as m, JsonLogicGreaterThan as ma, defaultRuleGroupProcessorJSONata as mi, prepareRuleOrGroup as mn, DropEffect as mo, defaultCELValueProcessor as mr, DefaultRuleType as ms, CombinatorSelectorProps as mt, getQuerySelectorById as n, defaultPlaceholderValueGroupLabel as na, defaultRuleGroupProcessorSQL as ni, InsertOptions as nn, RQBJsonLogicVar as no, isRuleOrGroupValid as nr, RuleGroupTypeAny as ns, UseControlledOrUncontrolledParams as nt, getRqbStore as o, groupInvalidReasons as oa, prismaFallback as oi, group as on, ValueProcessor as oo, isRuleGroupTypeIC as or, DefaultCombinator as os, UseMatchModeEditor as ot, useQueryBuilder as p, JsonLogicEqual as pa, defaultRuleGroupProcessorJsonLogic as pi, prepareRuleGroup as pn, DropCollection as po, generateAccessibleDescription as pr, DefaultRuleGroupType as ps, ActionWithRulesProps as pt, UseOptionListProp as q, FormatQueryValidateRule as qa, defaultOperators as qi, objectEntries as qn, ValidationResult as qo, defaultExportOperatorMap as qr, UseRuleGroup as qt, QueryBuilderStateContext as r, defaultPlaceholderValueLabel as ra, defaultRuleGroupProcessorSpEL as ri, MoveOptions as rn, RuleGroupProcessor as ro, isValidationResult as rr, RuleGroupTypeIC as rs, useControlledOrUncontrolled as rt, injectSlice as s, queryBuilderFlagDefaults as sa, defaultRuleGroupProcessorParameterized as si, insert as sn, ValueProcessorByRule as so, isRuleType as sr, DefaultCombinatorExtended as ss, useMatchModeEditor as st, queryBuilderStore as t, defaultPlaceholderOperatorName as ta, defaultRuleProcessorDrizzle as ti, GroupOptions as tn, RQBJsonLogicStartsWith as to, mergeAnyTranslations as tr, RuleGroupICArray as ts, useDeprecatedProps as tt, QueryBuilderStateProvider as u, JsonLogicAll as ua, mongoDbFallback as ui, update as un, DndDropTargetType as uo, getParseNumberMethod as ur, DefaultOperator as us, ActionElement as ut, toOptions as v, JsonLogicLessThan as va, defaultValueProcessorByRule as vi, FindPathReturnType as vn, Arity as vo, defaultValueProcessorCELByRule as vr, UpdateableProperties as vs, DragHandleProps as vt, defaultControlElements as w, JsonLogicReservedOperations as wa, convertFromIC as wi, isAncestor as wn, FullCombinator as wo, defaultNLTranslations as wr, FlexibleOptionList as ws, QueryBuilderContextProps as wt, GetCompatContextProviderProps as x, JsonLogicNone as xa, defaultRuleProcessorCEL as xi, getCommonAncestorPath as xn, CombinatorByValue as xo, bigIntJsonParseReviver as xr, BaseOptionMap as xs, MatchModeEditorProps as xt, mergeTranslation as y, JsonLogicLessThanOrEqual as ya, defaultRuleProcessorSpEL as yi, findID as yn, Classname as yo, defaultValueProcessorMongoDBByRule as yr, BaseFullOption as ys, FieldSelectorProps as yt, UseSelectElementChangeHandlerParams as z, QueryBuilderFlags as za, defaultCombinatorLabelMap as zi, toFlatOptionArray as zn, ValueSource as zo, formatQueryOptionPresets as zr, ToFullOption as zs, UseRuleGroupDnD as zt };
//# sourceMappingURL=index-CJ_xNf4H.d.ts.map