UNPKG

react-querybuilder

Version:

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

30 lines (29 loc) 1.35 kB
import type { ParserCommonOptions } from "../../types/import.mjs"; import type { DefaultRuleGroupType, DefaultRuleGroupTypeIC, Except } from "../../types/index.noReact.mjs"; /** * Options object for {@link parseCEL}. */ export interface ParseCELOptions extends ParserCommonOptions {} /** * Converts a CEL string expression into a query suitable for the * {@link index!QueryBuilder QueryBuilder} component's `query` or `defaultQuery` props * ({@link index!DefaultRuleGroupType DefaultRuleGroupType}). */ declare function parseCEL(cel: string): DefaultRuleGroupType; /** * Converts a CEL string expression into a query suitable for the * {@link index!QueryBuilder QueryBuilder} component's `query` or `defaultQuery` props * ({@link index!DefaultRuleGroupType DefaultRuleGroupType}). */ declare function parseCEL(cel: string, options: Except<ParseCELOptions, "independentCombinators"> & { independentCombinators?: false }): DefaultRuleGroupType; /** * Converts a CEL string expression into a query suitable for the * {@link index!QueryBuilder QueryBuilder} component's `query` or `defaultQuery` props * ({@link index!DefaultRuleGroupTypeIC DefaultRuleGroupTypeIC}). */ declare function parseCEL(cel: string, options: Except<ParseCELOptions, "independentCombinators"> & { independentCombinators: true }): DefaultRuleGroupTypeIC; export { parseCEL };