@react-querybuilder/core 8.17.0 → 8.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (98) hide show
  1. package/dist/cjs/react-querybuilder_core.cjs.development.d.ts +57 -16
  2. package/dist/cjs/react-querybuilder_core.cjs.development.js +212 -206
  3. package/dist/cjs/react-querybuilder_core.cjs.development.js.map +1 -1
  4. package/dist/cjs/react-querybuilder_core.cjs.production.d.ts +57 -16
  5. package/dist/cjs/react-querybuilder_core.cjs.production.js +1 -1
  6. package/dist/cjs/react-querybuilder_core.cjs.production.js.map +1 -1
  7. package/dist/{convertQuery-BoMPXL7_.js → convertQuery-BJKNgecE.js} +2 -2
  8. package/dist/{convertQuery-BoMPXL7_.js.map → convertQuery-BJKNgecE.js.map} +1 -1
  9. package/dist/{convertQuery-CQwOrjQr.mjs → convertQuery-J1CaoDxe.mjs} +2 -2
  10. package/dist/{convertQuery-CQwOrjQr.mjs.map → convertQuery-J1CaoDxe.mjs.map} +1 -1
  11. package/dist/formatQuery.d.mts +5 -3
  12. package/dist/formatQuery.d.ts +5 -3
  13. package/dist/formatQuery.js +203 -203
  14. package/dist/formatQuery.js.map +1 -1
  15. package/dist/formatQuery.mjs +203 -203
  16. package/dist/formatQuery.mjs.map +1 -1
  17. package/dist/{import-CSHMjlid.d.ts → import-Qs1-kgv5.d.ts} +2 -2
  18. package/dist/{import-BQ5xaW6i.d.mts → import-ShTj5IdB.d.mts} +2 -2
  19. package/dist/{index-CREDWM32.d.ts → index-DlVg-QXo.d.mts} +32 -3
  20. package/dist/{index-CREDWM32.d.mts → index-DlVg-QXo.d.ts} +32 -3
  21. package/dist/{objectUtils-DxVaGCdg.js → objectUtils-DBJI82bl.js} +2 -2
  22. package/dist/objectUtils-DBJI82bl.js.map +1 -0
  23. package/dist/{objectUtils-D-w8MzpZ.mjs → objectUtils-ZvPkF6u6.mjs} +2 -2
  24. package/dist/objectUtils-ZvPkF6u6.mjs.map +1 -0
  25. package/dist/parseCEL.d.mts +7 -7
  26. package/dist/parseCEL.d.ts +7 -7
  27. package/dist/parseCEL.js +6 -6
  28. package/dist/parseCEL.js.map +1 -1
  29. package/dist/parseCEL.mjs +6 -6
  30. package/dist/parseCEL.mjs.map +1 -1
  31. package/dist/parseCypher.d.mts +1 -1
  32. package/dist/parseCypher.d.ts +1 -1
  33. package/dist/parseCypher.js.map +1 -1
  34. package/dist/parseCypher.mjs.map +1 -1
  35. package/dist/parseGremlin.d.mts +1 -1
  36. package/dist/parseGremlin.d.ts +1 -1
  37. package/dist/parseGremlin.js.map +1 -1
  38. package/dist/parseGremlin.mjs.map +1 -1
  39. package/dist/parseJSONata.d.mts +2 -2
  40. package/dist/parseJSONata.d.ts +2 -2
  41. package/dist/parseJSONata.js +2 -2
  42. package/dist/parseJSONata.js.map +1 -1
  43. package/dist/parseJSONata.mjs +2 -2
  44. package/dist/parseJSONata.mjs.map +1 -1
  45. package/dist/parseJsonLogic.d.mts +2 -2
  46. package/dist/parseJsonLogic.d.ts +2 -2
  47. package/dist/parseJsonLogic.js +11 -11
  48. package/dist/parseJsonLogic.js.map +1 -1
  49. package/dist/parseJsonLogic.mjs +11 -11
  50. package/dist/parseJsonLogic.mjs.map +1 -1
  51. package/dist/parseMongoDB.d.mts +2 -2
  52. package/dist/parseMongoDB.d.ts +2 -2
  53. package/dist/parseMongoDB.js +4 -4
  54. package/dist/parseMongoDB.js.map +1 -1
  55. package/dist/parseMongoDB.mjs +4 -4
  56. package/dist/parseMongoDB.mjs.map +1 -1
  57. package/dist/parseSPARQL.d.mts +1 -1
  58. package/dist/parseSPARQL.d.ts +1 -1
  59. package/dist/parseSPARQL.js.map +1 -1
  60. package/dist/parseSPARQL.mjs.map +1 -1
  61. package/dist/parseSQL.d.mts +2 -2
  62. package/dist/parseSQL.d.ts +2 -2
  63. package/dist/parseSQL.js +3 -3
  64. package/dist/parseSQL.js.map +1 -1
  65. package/dist/parseSQL.mjs +3 -3
  66. package/dist/parseSQL.mjs.map +1 -1
  67. package/dist/parseSpEL.d.mts +2 -2
  68. package/dist/parseSpEL.d.ts +2 -2
  69. package/dist/parseSpEL.js +3 -3
  70. package/dist/parseSpEL.js.map +1 -1
  71. package/dist/parseSpEL.mjs +3 -3
  72. package/dist/parseSpEL.mjs.map +1 -1
  73. package/dist/{prepareQueryObjects-BXf5aV-A.mjs → prepareQueryObjects-Cd_tt4oy.mjs} +3 -3
  74. package/dist/{prepareQueryObjects-BXf5aV-A.mjs.map → prepareQueryObjects-Cd_tt4oy.mjs.map} +1 -1
  75. package/dist/{prepareQueryObjects-gRQqiBPR.js → prepareQueryObjects-DaAXX792.js} +3 -3
  76. package/dist/{prepareQueryObjects-gRQqiBPR.js.map → prepareQueryObjects-DaAXX792.js.map} +1 -1
  77. package/dist/react-querybuilder_core.d.mts +57 -16
  78. package/dist/react-querybuilder_core.legacy-esm.d.ts +57 -16
  79. package/dist/react-querybuilder_core.legacy-esm.js +210 -204
  80. package/dist/react-querybuilder_core.legacy-esm.js.map +1 -1
  81. package/dist/react-querybuilder_core.mjs +212 -206
  82. package/dist/react-querybuilder_core.mjs.map +1 -1
  83. package/dist/react-querybuilder_core.production.d.mts +57 -16
  84. package/dist/react-querybuilder_core.production.mjs +1 -1
  85. package/dist/react-querybuilder_core.production.mjs.map +1 -1
  86. package/dist/transformQuery.d.mts +1 -1
  87. package/dist/transformQuery.d.ts +1 -1
  88. package/dist/transformQuery.js +1 -1
  89. package/dist/transformQuery.mjs +1 -1
  90. package/dist/{utils-ZlKseh1X.js → utils-BpaOtylk.js} +3 -3
  91. package/dist/utils-BpaOtylk.js.map +1 -0
  92. package/dist/{utils-01WaTGBL.mjs → utils-CJRGiPb-.mjs} +3 -3
  93. package/dist/utils-CJRGiPb-.mjs.map +1 -0
  94. package/package.json +12 -12
  95. package/dist/objectUtils-D-w8MzpZ.mjs.map +0 -1
  96. package/dist/objectUtils-DxVaGCdg.js.map +0 -1
  97. package/dist/utils-01WaTGBL.mjs.map +0 -1
  98. package/dist/utils-ZlKseh1X.js.map +0 -1
@@ -1,4 +1,4 @@
1
- const require_objectUtils = require("./objectUtils-DxVaGCdg.js");
1
+ const require_objectUtils = require("./objectUtils-DBJI82bl.js");
2
2
  //#region src/utils/convertQuery.ts
3
3
  const combinatorLevels = [
4
4
  "or",
@@ -91,4 +91,4 @@ Object.defineProperty(exports, "convertToIC", {
91
91
  }
92
92
  });
93
93
 
94
- //# sourceMappingURL=convertQuery-BoMPXL7_.js.map
94
+ //# sourceMappingURL=convertQuery-BJKNgecE.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"convertQuery-BoMPXL7_.js","names":["lc","isRuleGroupType","isRuleGroup","isRuleGroupTypeIC"],"sources":["../src/utils/convertQuery.ts"],"sourcesContent":["import type {\n RuleGroupArray,\n RuleGroupICArray,\n RuleGroupType,\n RuleGroupTypeAny,\n RuleGroupTypeIC,\n RuleType,\n ToRuleGroupType,\n ToRuleGroupTypeIC,\n} from '../types';\nimport { isRuleGroup, isRuleGroupType, isRuleGroupTypeIC } from './isRuleGroup';\nimport { lc } from './misc';\n\nconst combinatorLevels = ['or', 'xor', 'and'] as const;\n\nconst isSameString = (a: unknown, b: string) => lc(a) === b;\n\nconst generateRuleGroupICWithConsistentCombinators = (\n rg: RuleGroupTypeIC,\n baseCombinatorLevel: number = 0\n): RuleGroupTypeIC => {\n const baseCombinator = combinatorLevels[baseCombinatorLevel];\n\n // oxlint-disable-next-line typescript/no-explicit-any\n if (!rg.rules.includes(baseCombinator as any)) {\n // No instances of this combinator, so group based on the next\n // combinator level if at least two levels remain\n return baseCombinatorLevel < combinatorLevels.length - 2\n ? generateRuleGroupICWithConsistentCombinators(rg, baseCombinatorLevel + 1)\n : rg;\n }\n\n const newRules = [...rg.rules] as RuleGroupICArray;\n let cursor = 0;\n\n // Group all chains of combinators in the rule array that are not the base combinator\n while (cursor < newRules.length - 2) {\n if (isSameString(newRules[cursor + 1], baseCombinator)) {\n cursor += 2;\n continue;\n }\n\n let nextBaseCombinatorIndex = -1;\n for (let i = cursor + 2; i < newRules.length; i++) {\n if (typeof newRules[i] === 'string' && lc(newRules[i]) === baseCombinator) {\n nextBaseCombinatorIndex = i;\n break;\n }\n }\n\n if (nextBaseCombinatorIndex === -1) {\n // No more instances of this combinator, so group all remaining rules and exit the loop\n newRules.splice(\n cursor,\n newRules.length,\n generateRuleGroupICWithConsistentCombinators(\n // oxlint-disable-next-line typescript/no-explicit-any\n { rules: newRules.slice(cursor) as any },\n baseCombinatorLevel + 1\n )\n );\n break;\n } else {\n // Group all rules between the current cursor and the next instance of the base combinator\n newRules.splice(\n cursor,\n nextBaseCombinatorIndex - cursor,\n generateRuleGroupICWithConsistentCombinators(\n // oxlint-disable-next-line typescript/no-explicit-any\n { rules: newRules.slice(cursor, nextBaseCombinatorIndex) as any },\n baseCombinatorLevel + 1\n )\n );\n }\n }\n\n return { ...rg, rules: newRules };\n};\n\n/**\n * Converts a {@link RuleGroupTypeIC} to {@link RuleGroupType}.\n *\n * This function is idempotent: {@link RuleGroupType} queries will be\n * returned as-is.\n *\n * @group Query Tools\n */\nexport const convertFromIC = <RG extends RuleGroupTypeAny>(rg: RG): ToRuleGroupType<RG> => {\n if (isRuleGroupType(rg)) {\n return rg as ToRuleGroupType<RG>;\n }\n const processedRG = generateRuleGroupICWithConsistentCombinators(rg);\n const rules: RuleGroupArray = [];\n let combinator = 'and';\n for (const [idx, r] of processedRG.rules.entries()) {\n if (typeof r === 'string') {\n if (idx === 1) combinator = r;\n } else {\n rules.push(isRuleGroup(r) ? convertFromIC(r) : r);\n }\n }\n return { ...processedRG, combinator, rules } as ToRuleGroupType<RG>;\n};\n\n/**\n * Converts a {@link RuleGroupType} to {@link RuleGroupTypeIC}.\n *\n * This function is idempotent: {@link RuleGroupTypeIC} queries will be\n * returned as-is.\n *\n * @group Query Tools\n */\nexport const convertToIC = <RG extends RuleGroupTypeAny>(rg: RG): ToRuleGroupTypeIC<RG> => {\n if (isRuleGroupTypeIC(rg)) {\n return rg as ToRuleGroupTypeIC<RG>;\n }\n const { combinator, ...queryWithoutCombinator } = rg;\n const rules: (RuleGroupTypeIC | RuleType | string)[] = [];\n const { length } = rg.rules;\n for (let idx = 0; idx < length; idx++) {\n const r = rg.rules[idx];\n if (isRuleGroup(r)) {\n rules.push(convertToIC(r));\n } else {\n rules.push(r);\n }\n if (combinator && idx < length - 1) {\n rules.push(combinator);\n }\n }\n return { ...queryWithoutCombinator, rules } as ToRuleGroupTypeIC<RG>;\n};\n\n/**\n * Converts a {@link RuleGroupType} to {@link RuleGroupTypeIC}. For a more explicit\n * operation, use {@link convertToIC}.\n *\n * @group Query Tools\n */\nfunction convertQuery(query: RuleGroupType): RuleGroupTypeIC;\n/**\n * Converts a {@link RuleGroupTypeIC} to {@link RuleGroupType}. For a more explicit\n * operation, use {@link convertFromIC}.\n *\n * @group Query Tools\n */\nfunction convertQuery(query: RuleGroupTypeIC): RuleGroupType;\nfunction convertQuery(query: RuleGroupType | RuleGroupTypeIC): RuleGroupType | RuleGroupTypeIC {\n return isRuleGroupTypeIC(query) ? convertFromIC(query) : convertToIC(query);\n}\n\nexport { convertQuery };\n"],"mappings":";;AAaA,MAAM,mBAAmB;CAAC;CAAM;CAAO;AAAK;AAE5C,MAAM,gBAAgB,GAAY,MAAcA,oBAAAA,GAAG,CAAC,MAAM;AAE1D,MAAM,gDACJ,IACA,sBAA8B,MACV;CACpB,MAAM,iBAAiB,iBAAiB;CAGxC,IAAI,CAAC,GAAG,MAAM,SAAS,cAAqB,GAG1C,OAAO,sBAAsB,iBAAiB,SAAS,IACnD,6CAA6C,IAAI,sBAAsB,CAAC,IACxE;CAGN,MAAM,WAAW,CAAC,GAAG,GAAG,KAAK;CAC7B,IAAI,SAAS;CAGb,OAAO,SAAS,SAAS,SAAS,GAAG;EACnC,IAAI,aAAa,SAAS,SAAS,IAAI,cAAc,GAAG;GACtD,UAAU;GACV;EACF;EAEA,IAAI,0BAA0B;EAC9B,KAAK,IAAI,IAAI,SAAS,GAAG,IAAI,SAAS,QAAQ,KAC5C,IAAI,OAAO,SAAS,OAAO,YAAYA,oBAAAA,GAAG,SAAS,EAAE,MAAM,gBAAgB;GACzE,0BAA0B;GAC1B;EACF;EAGF,IAAI,4BAA4B,IAAI;GAElC,SAAS,OACP,QACA,SAAS,QACT,6CAEE,EAAE,OAAO,SAAS,MAAM,MAAM,EAAS,GACvC,sBAAsB,CACxB,CACF;GACA;EACF,OAEE,SAAS,OACP,QACA,0BAA0B,QAC1B,6CAEE,EAAE,OAAO,SAAS,MAAM,QAAQ,uBAAuB,EAAS,GAChE,sBAAsB,CACxB,CACF;CAEJ;CAEA,OAAO;EAAE,GAAG;EAAI,OAAO;CAAS;AAClC;;;;;;;;;AAUA,MAAa,iBAA8C,OAAgC;CACzF,IAAIC,oBAAAA,gBAAgB,EAAE,GACpB,OAAO;CAET,MAAM,cAAc,6CAA6C,EAAE;CACnE,MAAM,QAAwB,CAAC;CAC/B,IAAI,aAAa;CACjB,KAAK,MAAM,CAAC,KAAK,MAAM,YAAY,MAAM,QAAQ,GAC/C,IAAI,OAAO,MAAM;MACX,QAAQ,GAAG,aAAa;CAAA,OAE5B,MAAM,KAAKC,oBAAAA,YAAY,CAAC,IAAI,cAAc,CAAC,IAAI,CAAC;CAGpD,OAAO;EAAE,GAAG;EAAa;EAAY;CAAM;AAC7C;;;;;;;;;AAUA,MAAa,eAA4C,OAAkC;CACzF,IAAIC,oBAAAA,kBAAkB,EAAE,GACtB,OAAO;CAET,MAAM,EAAE,YAAY,GAAG,2BAA2B;CAClD,MAAM,QAAiD,CAAC;CACxD,MAAM,EAAE,WAAW,GAAG;CACtB,KAAK,IAAI,MAAM,GAAG,MAAM,QAAQ,OAAO;EACrC,MAAM,IAAI,GAAG,MAAM;EACnB,IAAID,oBAAAA,YAAY,CAAC,GACf,MAAM,KAAK,YAAY,CAAC,CAAC;OAEzB,MAAM,KAAK,CAAC;EAEd,IAAI,cAAc,MAAM,SAAS,GAC/B,MAAM,KAAK,UAAU;CAEzB;CACA,OAAO;EAAE,GAAG;EAAwB;CAAM;AAC5C"}
1
+ {"version":3,"file":"convertQuery-BJKNgecE.js","names":["lc","isRuleGroupType","isRuleGroup","isRuleGroupTypeIC"],"sources":["../src/utils/convertQuery.ts"],"sourcesContent":["import type {\n RuleGroupArray,\n RuleGroupICArray,\n RuleGroupType,\n RuleGroupTypeAny,\n RuleGroupTypeIC,\n RuleType,\n ToRuleGroupType,\n ToRuleGroupTypeIC,\n} from '../types';\nimport { isRuleGroup, isRuleGroupType, isRuleGroupTypeIC } from './isRuleGroup';\nimport { lc } from './misc';\n\nconst combinatorLevels = ['or', 'xor', 'and'] as const;\n\nconst isSameString = (a: unknown, b: string) => lc(a) === b;\n\nconst generateRuleGroupICWithConsistentCombinators = (\n rg: RuleGroupTypeIC,\n baseCombinatorLevel: number = 0\n): RuleGroupTypeIC => {\n const baseCombinator = combinatorLevels[baseCombinatorLevel];\n\n // oxlint-disable-next-line typescript/no-explicit-any\n if (!rg.rules.includes(baseCombinator as any)) {\n // No instances of this combinator, so group based on the next\n // combinator level if at least two levels remain\n return baseCombinatorLevel < combinatorLevels.length - 2\n ? generateRuleGroupICWithConsistentCombinators(rg, baseCombinatorLevel + 1)\n : rg;\n }\n\n const newRules = [...rg.rules] as RuleGroupICArray;\n let cursor = 0;\n\n // Group all chains of combinators in the rule array that are not the base combinator\n while (cursor < newRules.length - 2) {\n if (isSameString(newRules[cursor + 1], baseCombinator)) {\n cursor += 2;\n continue;\n }\n\n let nextBaseCombinatorIndex = -1;\n for (let i = cursor + 2; i < newRules.length; i++) {\n if (typeof newRules[i] === 'string' && lc(newRules[i]) === baseCombinator) {\n nextBaseCombinatorIndex = i;\n break;\n }\n }\n\n if (nextBaseCombinatorIndex === -1) {\n // No more instances of this combinator, so group all remaining rules and exit the loop\n newRules.splice(\n cursor,\n newRules.length,\n generateRuleGroupICWithConsistentCombinators(\n // oxlint-disable-next-line typescript/no-explicit-any\n { rules: newRules.slice(cursor) as any },\n baseCombinatorLevel + 1\n )\n );\n break;\n } else {\n // Group all rules between the current cursor and the next instance of the base combinator\n newRules.splice(\n cursor,\n nextBaseCombinatorIndex - cursor,\n generateRuleGroupICWithConsistentCombinators(\n // oxlint-disable-next-line typescript/no-explicit-any\n { rules: newRules.slice(cursor, nextBaseCombinatorIndex) as any },\n baseCombinatorLevel + 1\n )\n );\n }\n }\n\n return { ...rg, rules: newRules };\n};\n\n/**\n * Converts a {@link RuleGroupTypeIC} to {@link RuleGroupType}.\n *\n * This function is idempotent: {@link RuleGroupType} queries will be\n * returned as-is.\n *\n * @group Query Tools\n */\nexport const convertFromIC = <RG extends RuleGroupTypeAny>(rg: RG): ToRuleGroupType<RG> => {\n if (isRuleGroupType(rg)) {\n return rg as ToRuleGroupType<RG>;\n }\n const processedRG = generateRuleGroupICWithConsistentCombinators(rg);\n const rules: RuleGroupArray = [];\n let combinator = 'and';\n for (const [idx, r] of processedRG.rules.entries()) {\n if (typeof r === 'string') {\n if (idx === 1) combinator = r;\n } else {\n rules.push(isRuleGroup(r) ? convertFromIC(r) : r);\n }\n }\n return { ...processedRG, combinator, rules } as ToRuleGroupType<RG>;\n};\n\n/**\n * Converts a {@link RuleGroupType} to {@link RuleGroupTypeIC}.\n *\n * This function is idempotent: {@link RuleGroupTypeIC} queries will be\n * returned as-is.\n *\n * @group Query Tools\n */\nexport const convertToIC = <RG extends RuleGroupTypeAny>(rg: RG): ToRuleGroupTypeIC<RG> => {\n if (isRuleGroupTypeIC(rg)) {\n return rg as ToRuleGroupTypeIC<RG>;\n }\n const { combinator, ...queryWithoutCombinator } = rg;\n const rules: (RuleGroupTypeIC | RuleType | string)[] = [];\n const { length } = rg.rules;\n for (let idx = 0; idx < length; idx++) {\n const r = rg.rules[idx];\n if (isRuleGroup(r)) {\n rules.push(convertToIC(r));\n } else {\n rules.push(r);\n }\n if (combinator && idx < length - 1) {\n rules.push(combinator);\n }\n }\n return { ...queryWithoutCombinator, rules } as ToRuleGroupTypeIC<RG>;\n};\n\n/**\n * Converts a {@link RuleGroupType} to {@link RuleGroupTypeIC}. For a more explicit\n * operation, use {@link convertToIC}.\n *\n * @group Query Tools\n */\nfunction convertQuery(query: RuleGroupType): RuleGroupTypeIC;\n/**\n * Converts a {@link RuleGroupTypeIC} to {@link RuleGroupType}. For a more explicit\n * operation, use {@link convertFromIC}.\n *\n * @group Query Tools\n */\nfunction convertQuery(query: RuleGroupTypeIC): RuleGroupType;\nfunction convertQuery(query: RuleGroupType | RuleGroupTypeIC): RuleGroupType | RuleGroupTypeIC {\n return isRuleGroupTypeIC(query) ? convertFromIC(query) : convertToIC(query);\n}\n\nexport { convertQuery };\n"],"mappings":";;AAaA,MAAM,mBAAmB;CAAC;CAAM;CAAO;AAAK;AAE5C,MAAM,gBAAgB,GAAY,MAAcA,oBAAAA,GAAG,CAAC,MAAM;AAE1D,MAAM,gDACJ,IACA,sBAA8B,MACV;CACpB,MAAM,iBAAiB,iBAAiB;CAGxC,IAAI,CAAC,GAAG,MAAM,SAAS,cAAqB,GAG1C,OAAO,sBAAsB,iBAAiB,SAAS,IACnD,6CAA6C,IAAI,sBAAsB,CAAC,IACxE;CAGN,MAAM,WAAW,CAAC,GAAG,GAAG,KAAK;CAC7B,IAAI,SAAS;CAGb,OAAO,SAAS,SAAS,SAAS,GAAG;EACnC,IAAI,aAAa,SAAS,SAAS,IAAI,cAAc,GAAG;GACtD,UAAU;GACV;EACF;EAEA,IAAI,0BAA0B;EAC9B,KAAK,IAAI,IAAI,SAAS,GAAG,IAAI,SAAS,QAAQ,KAC5C,IAAI,OAAO,SAAS,OAAO,YAAYA,oBAAAA,GAAG,SAAS,EAAE,MAAM,gBAAgB;GACzE,0BAA0B;GAC1B;EACF;EAGF,IAAI,4BAA4B,IAAI;GAElC,SAAS,OACP,QACA,SAAS,QACT,6CAEE,EAAE,OAAO,SAAS,MAAM,MAAM,EAAS,GACvC,sBAAsB,CACxB,CACF;GACA;EACF,OAEE,SAAS,OACP,QACA,0BAA0B,QAC1B,6CAEE,EAAE,OAAO,SAAS,MAAM,QAAQ,uBAAuB,EAAS,GAChE,sBAAsB,CACxB,CACF;CAEJ;CAEA,OAAO;EAAE,GAAG;EAAI,OAAO;CAAS;AAClC;;;;;;;;;AAUA,MAAa,iBAA8C,OAAgC;CACzF,IAAIC,oBAAAA,gBAAgB,EAAE,GACpB,OAAO;CAET,MAAM,cAAc,6CAA6C,EAAE;CACnE,MAAM,QAAwB,CAAC;CAC/B,IAAI,aAAa;CACjB,KAAK,MAAM,CAAC,KAAK,MAAM,YAAY,MAAM,QAAQ,GAC/C,IAAI,OAAO,MAAM;MACX,QAAQ,GAAG,aAAa;CAAA,OAE5B,MAAM,KAAKC,oBAAAA,YAAY,CAAC,IAAI,cAAc,CAAC,IAAI,CAAC;CAGpD,OAAO;EAAE,GAAG;EAAa;EAAY;CAAM;AAC7C;;;;;;;;;AAUA,MAAa,eAA4C,OAAkC;CACzF,IAAIC,oBAAAA,kBAAkB,EAAE,GACtB,OAAO;CAET,MAAM,EAAE,YAAY,GAAG,2BAA2B;CAClD,MAAM,QAAiD,CAAC;CACxD,MAAM,EAAE,WAAW,GAAG;CACtB,KAAK,IAAI,MAAM,GAAG,MAAM,QAAQ,OAAO;EACrC,MAAM,IAAI,GAAG,MAAM;EACnB,IAAID,oBAAAA,YAAY,CAAC,GACf,MAAM,KAAK,YAAY,CAAC,CAAC;OAEzB,MAAM,KAAK,CAAC;EAEd,IAAI,cAAc,MAAM,SAAS,GAC/B,MAAM,KAAK,UAAU;CAEzB;CACA,OAAO;EAAE,GAAG;EAAwB;CAAM;AAC5C"}
@@ -1,4 +1,4 @@
1
- import { a as isRuleGroupTypeIC, i as isRuleGroupType, r as isRuleGroup, s as lc } from "./objectUtils-D-w8MzpZ.mjs";
1
+ import { a as isRuleGroupTypeIC, i as isRuleGroupType, r as isRuleGroup, s as lc } from "./objectUtils-ZvPkF6u6.mjs";
2
2
  //#region src/utils/convertQuery.ts
3
3
  const combinatorLevels = [
4
4
  "or",
@@ -80,4 +80,4 @@ const convertToIC = (rg) => {
80
80
  //#endregion
81
81
  export { convertToIC as n, convertFromIC as t };
82
82
 
83
- //# sourceMappingURL=convertQuery-CQwOrjQr.mjs.map
83
+ //# sourceMappingURL=convertQuery-J1CaoDxe.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"convertQuery-CQwOrjQr.mjs","names":[],"sources":["../src/utils/convertQuery.ts"],"sourcesContent":["import type {\n RuleGroupArray,\n RuleGroupICArray,\n RuleGroupType,\n RuleGroupTypeAny,\n RuleGroupTypeIC,\n RuleType,\n ToRuleGroupType,\n ToRuleGroupTypeIC,\n} from '../types';\nimport { isRuleGroup, isRuleGroupType, isRuleGroupTypeIC } from './isRuleGroup';\nimport { lc } from './misc';\n\nconst combinatorLevels = ['or', 'xor', 'and'] as const;\n\nconst isSameString = (a: unknown, b: string) => lc(a) === b;\n\nconst generateRuleGroupICWithConsistentCombinators = (\n rg: RuleGroupTypeIC,\n baseCombinatorLevel: number = 0\n): RuleGroupTypeIC => {\n const baseCombinator = combinatorLevels[baseCombinatorLevel];\n\n // oxlint-disable-next-line typescript/no-explicit-any\n if (!rg.rules.includes(baseCombinator as any)) {\n // No instances of this combinator, so group based on the next\n // combinator level if at least two levels remain\n return baseCombinatorLevel < combinatorLevels.length - 2\n ? generateRuleGroupICWithConsistentCombinators(rg, baseCombinatorLevel + 1)\n : rg;\n }\n\n const newRules = [...rg.rules] as RuleGroupICArray;\n let cursor = 0;\n\n // Group all chains of combinators in the rule array that are not the base combinator\n while (cursor < newRules.length - 2) {\n if (isSameString(newRules[cursor + 1], baseCombinator)) {\n cursor += 2;\n continue;\n }\n\n let nextBaseCombinatorIndex = -1;\n for (let i = cursor + 2; i < newRules.length; i++) {\n if (typeof newRules[i] === 'string' && lc(newRules[i]) === baseCombinator) {\n nextBaseCombinatorIndex = i;\n break;\n }\n }\n\n if (nextBaseCombinatorIndex === -1) {\n // No more instances of this combinator, so group all remaining rules and exit the loop\n newRules.splice(\n cursor,\n newRules.length,\n generateRuleGroupICWithConsistentCombinators(\n // oxlint-disable-next-line typescript/no-explicit-any\n { rules: newRules.slice(cursor) as any },\n baseCombinatorLevel + 1\n )\n );\n break;\n } else {\n // Group all rules between the current cursor and the next instance of the base combinator\n newRules.splice(\n cursor,\n nextBaseCombinatorIndex - cursor,\n generateRuleGroupICWithConsistentCombinators(\n // oxlint-disable-next-line typescript/no-explicit-any\n { rules: newRules.slice(cursor, nextBaseCombinatorIndex) as any },\n baseCombinatorLevel + 1\n )\n );\n }\n }\n\n return { ...rg, rules: newRules };\n};\n\n/**\n * Converts a {@link RuleGroupTypeIC} to {@link RuleGroupType}.\n *\n * This function is idempotent: {@link RuleGroupType} queries will be\n * returned as-is.\n *\n * @group Query Tools\n */\nexport const convertFromIC = <RG extends RuleGroupTypeAny>(rg: RG): ToRuleGroupType<RG> => {\n if (isRuleGroupType(rg)) {\n return rg as ToRuleGroupType<RG>;\n }\n const processedRG = generateRuleGroupICWithConsistentCombinators(rg);\n const rules: RuleGroupArray = [];\n let combinator = 'and';\n for (const [idx, r] of processedRG.rules.entries()) {\n if (typeof r === 'string') {\n if (idx === 1) combinator = r;\n } else {\n rules.push(isRuleGroup(r) ? convertFromIC(r) : r);\n }\n }\n return { ...processedRG, combinator, rules } as ToRuleGroupType<RG>;\n};\n\n/**\n * Converts a {@link RuleGroupType} to {@link RuleGroupTypeIC}.\n *\n * This function is idempotent: {@link RuleGroupTypeIC} queries will be\n * returned as-is.\n *\n * @group Query Tools\n */\nexport const convertToIC = <RG extends RuleGroupTypeAny>(rg: RG): ToRuleGroupTypeIC<RG> => {\n if (isRuleGroupTypeIC(rg)) {\n return rg as ToRuleGroupTypeIC<RG>;\n }\n const { combinator, ...queryWithoutCombinator } = rg;\n const rules: (RuleGroupTypeIC | RuleType | string)[] = [];\n const { length } = rg.rules;\n for (let idx = 0; idx < length; idx++) {\n const r = rg.rules[idx];\n if (isRuleGroup(r)) {\n rules.push(convertToIC(r));\n } else {\n rules.push(r);\n }\n if (combinator && idx < length - 1) {\n rules.push(combinator);\n }\n }\n return { ...queryWithoutCombinator, rules } as ToRuleGroupTypeIC<RG>;\n};\n\n/**\n * Converts a {@link RuleGroupType} to {@link RuleGroupTypeIC}. For a more explicit\n * operation, use {@link convertToIC}.\n *\n * @group Query Tools\n */\nfunction convertQuery(query: RuleGroupType): RuleGroupTypeIC;\n/**\n * Converts a {@link RuleGroupTypeIC} to {@link RuleGroupType}. For a more explicit\n * operation, use {@link convertFromIC}.\n *\n * @group Query Tools\n */\nfunction convertQuery(query: RuleGroupTypeIC): RuleGroupType;\nfunction convertQuery(query: RuleGroupType | RuleGroupTypeIC): RuleGroupType | RuleGroupTypeIC {\n return isRuleGroupTypeIC(query) ? convertFromIC(query) : convertToIC(query);\n}\n\nexport { convertQuery };\n"],"mappings":";;AAaA,MAAM,mBAAmB;CAAC;CAAM;CAAO;AAAK;AAE5C,MAAM,gBAAgB,GAAY,MAAc,GAAG,CAAC,MAAM;AAE1D,MAAM,gDACJ,IACA,sBAA8B,MACV;CACpB,MAAM,iBAAiB,iBAAiB;CAGxC,IAAI,CAAC,GAAG,MAAM,SAAS,cAAqB,GAG1C,OAAO,sBAAsB,iBAAiB,SAAS,IACnD,6CAA6C,IAAI,sBAAsB,CAAC,IACxE;CAGN,MAAM,WAAW,CAAC,GAAG,GAAG,KAAK;CAC7B,IAAI,SAAS;CAGb,OAAO,SAAS,SAAS,SAAS,GAAG;EACnC,IAAI,aAAa,SAAS,SAAS,IAAI,cAAc,GAAG;GACtD,UAAU;GACV;EACF;EAEA,IAAI,0BAA0B;EAC9B,KAAK,IAAI,IAAI,SAAS,GAAG,IAAI,SAAS,QAAQ,KAC5C,IAAI,OAAO,SAAS,OAAO,YAAY,GAAG,SAAS,EAAE,MAAM,gBAAgB;GACzE,0BAA0B;GAC1B;EACF;EAGF,IAAI,4BAA4B,IAAI;GAElC,SAAS,OACP,QACA,SAAS,QACT,6CAEE,EAAE,OAAO,SAAS,MAAM,MAAM,EAAS,GACvC,sBAAsB,CACxB,CACF;GACA;EACF,OAEE,SAAS,OACP,QACA,0BAA0B,QAC1B,6CAEE,EAAE,OAAO,SAAS,MAAM,QAAQ,uBAAuB,EAAS,GAChE,sBAAsB,CACxB,CACF;CAEJ;CAEA,OAAO;EAAE,GAAG;EAAI,OAAO;CAAS;AAClC;;;;;;;;;AAUA,MAAa,iBAA8C,OAAgC;CACzF,IAAI,gBAAgB,EAAE,GACpB,OAAO;CAET,MAAM,cAAc,6CAA6C,EAAE;CACnE,MAAM,QAAwB,CAAC;CAC/B,IAAI,aAAa;CACjB,KAAK,MAAM,CAAC,KAAK,MAAM,YAAY,MAAM,QAAQ,GAC/C,IAAI,OAAO,MAAM;MACX,QAAQ,GAAG,aAAa;CAAA,OAE5B,MAAM,KAAK,YAAY,CAAC,IAAI,cAAc,CAAC,IAAI,CAAC;CAGpD,OAAO;EAAE,GAAG;EAAa;EAAY;CAAM;AAC7C;;;;;;;;;AAUA,MAAa,eAA4C,OAAkC;CACzF,IAAI,kBAAkB,EAAE,GACtB,OAAO;CAET,MAAM,EAAE,YAAY,GAAG,2BAA2B;CAClD,MAAM,QAAiD,CAAC;CACxD,MAAM,EAAE,WAAW,GAAG;CACtB,KAAK,IAAI,MAAM,GAAG,MAAM,QAAQ,OAAO;EACrC,MAAM,IAAI,GAAG,MAAM;EACnB,IAAI,YAAY,CAAC,GACf,MAAM,KAAK,YAAY,CAAC,CAAC;OAEzB,MAAM,KAAK,CAAC;EAEd,IAAI,cAAc,MAAM,SAAS,GAC/B,MAAM,KAAK,UAAU;CAEzB;CACA,OAAO;EAAE,GAAG;EAAwB;CAAM;AAC5C"}
1
+ {"version":3,"file":"convertQuery-J1CaoDxe.mjs","names":[],"sources":["../src/utils/convertQuery.ts"],"sourcesContent":["import type {\n RuleGroupArray,\n RuleGroupICArray,\n RuleGroupType,\n RuleGroupTypeAny,\n RuleGroupTypeIC,\n RuleType,\n ToRuleGroupType,\n ToRuleGroupTypeIC,\n} from '../types';\nimport { isRuleGroup, isRuleGroupType, isRuleGroupTypeIC } from './isRuleGroup';\nimport { lc } from './misc';\n\nconst combinatorLevels = ['or', 'xor', 'and'] as const;\n\nconst isSameString = (a: unknown, b: string) => lc(a) === b;\n\nconst generateRuleGroupICWithConsistentCombinators = (\n rg: RuleGroupTypeIC,\n baseCombinatorLevel: number = 0\n): RuleGroupTypeIC => {\n const baseCombinator = combinatorLevels[baseCombinatorLevel];\n\n // oxlint-disable-next-line typescript/no-explicit-any\n if (!rg.rules.includes(baseCombinator as any)) {\n // No instances of this combinator, so group based on the next\n // combinator level if at least two levels remain\n return baseCombinatorLevel < combinatorLevels.length - 2\n ? generateRuleGroupICWithConsistentCombinators(rg, baseCombinatorLevel + 1)\n : rg;\n }\n\n const newRules = [...rg.rules] as RuleGroupICArray;\n let cursor = 0;\n\n // Group all chains of combinators in the rule array that are not the base combinator\n while (cursor < newRules.length - 2) {\n if (isSameString(newRules[cursor + 1], baseCombinator)) {\n cursor += 2;\n continue;\n }\n\n let nextBaseCombinatorIndex = -1;\n for (let i = cursor + 2; i < newRules.length; i++) {\n if (typeof newRules[i] === 'string' && lc(newRules[i]) === baseCombinator) {\n nextBaseCombinatorIndex = i;\n break;\n }\n }\n\n if (nextBaseCombinatorIndex === -1) {\n // No more instances of this combinator, so group all remaining rules and exit the loop\n newRules.splice(\n cursor,\n newRules.length,\n generateRuleGroupICWithConsistentCombinators(\n // oxlint-disable-next-line typescript/no-explicit-any\n { rules: newRules.slice(cursor) as any },\n baseCombinatorLevel + 1\n )\n );\n break;\n } else {\n // Group all rules between the current cursor and the next instance of the base combinator\n newRules.splice(\n cursor,\n nextBaseCombinatorIndex - cursor,\n generateRuleGroupICWithConsistentCombinators(\n // oxlint-disable-next-line typescript/no-explicit-any\n { rules: newRules.slice(cursor, nextBaseCombinatorIndex) as any },\n baseCombinatorLevel + 1\n )\n );\n }\n }\n\n return { ...rg, rules: newRules };\n};\n\n/**\n * Converts a {@link RuleGroupTypeIC} to {@link RuleGroupType}.\n *\n * This function is idempotent: {@link RuleGroupType} queries will be\n * returned as-is.\n *\n * @group Query Tools\n */\nexport const convertFromIC = <RG extends RuleGroupTypeAny>(rg: RG): ToRuleGroupType<RG> => {\n if (isRuleGroupType(rg)) {\n return rg as ToRuleGroupType<RG>;\n }\n const processedRG = generateRuleGroupICWithConsistentCombinators(rg);\n const rules: RuleGroupArray = [];\n let combinator = 'and';\n for (const [idx, r] of processedRG.rules.entries()) {\n if (typeof r === 'string') {\n if (idx === 1) combinator = r;\n } else {\n rules.push(isRuleGroup(r) ? convertFromIC(r) : r);\n }\n }\n return { ...processedRG, combinator, rules } as ToRuleGroupType<RG>;\n};\n\n/**\n * Converts a {@link RuleGroupType} to {@link RuleGroupTypeIC}.\n *\n * This function is idempotent: {@link RuleGroupTypeIC} queries will be\n * returned as-is.\n *\n * @group Query Tools\n */\nexport const convertToIC = <RG extends RuleGroupTypeAny>(rg: RG): ToRuleGroupTypeIC<RG> => {\n if (isRuleGroupTypeIC(rg)) {\n return rg as ToRuleGroupTypeIC<RG>;\n }\n const { combinator, ...queryWithoutCombinator } = rg;\n const rules: (RuleGroupTypeIC | RuleType | string)[] = [];\n const { length } = rg.rules;\n for (let idx = 0; idx < length; idx++) {\n const r = rg.rules[idx];\n if (isRuleGroup(r)) {\n rules.push(convertToIC(r));\n } else {\n rules.push(r);\n }\n if (combinator && idx < length - 1) {\n rules.push(combinator);\n }\n }\n return { ...queryWithoutCombinator, rules } as ToRuleGroupTypeIC<RG>;\n};\n\n/**\n * Converts a {@link RuleGroupType} to {@link RuleGroupTypeIC}. For a more explicit\n * operation, use {@link convertToIC}.\n *\n * @group Query Tools\n */\nfunction convertQuery(query: RuleGroupType): RuleGroupTypeIC;\n/**\n * Converts a {@link RuleGroupTypeIC} to {@link RuleGroupType}. For a more explicit\n * operation, use {@link convertFromIC}.\n *\n * @group Query Tools\n */\nfunction convertQuery(query: RuleGroupTypeIC): RuleGroupType;\nfunction convertQuery(query: RuleGroupType | RuleGroupTypeIC): RuleGroupType | RuleGroupTypeIC {\n return isRuleGroupTypeIC(query) ? convertFromIC(query) : convertToIC(query);\n}\n\nexport { convertQuery };\n"],"mappings":";;AAaA,MAAM,mBAAmB;CAAC;CAAM;CAAO;AAAK;AAE5C,MAAM,gBAAgB,GAAY,MAAc,GAAG,CAAC,MAAM;AAE1D,MAAM,gDACJ,IACA,sBAA8B,MACV;CACpB,MAAM,iBAAiB,iBAAiB;CAGxC,IAAI,CAAC,GAAG,MAAM,SAAS,cAAqB,GAG1C,OAAO,sBAAsB,iBAAiB,SAAS,IACnD,6CAA6C,IAAI,sBAAsB,CAAC,IACxE;CAGN,MAAM,WAAW,CAAC,GAAG,GAAG,KAAK;CAC7B,IAAI,SAAS;CAGb,OAAO,SAAS,SAAS,SAAS,GAAG;EACnC,IAAI,aAAa,SAAS,SAAS,IAAI,cAAc,GAAG;GACtD,UAAU;GACV;EACF;EAEA,IAAI,0BAA0B;EAC9B,KAAK,IAAI,IAAI,SAAS,GAAG,IAAI,SAAS,QAAQ,KAC5C,IAAI,OAAO,SAAS,OAAO,YAAY,GAAG,SAAS,EAAE,MAAM,gBAAgB;GACzE,0BAA0B;GAC1B;EACF;EAGF,IAAI,4BAA4B,IAAI;GAElC,SAAS,OACP,QACA,SAAS,QACT,6CAEE,EAAE,OAAO,SAAS,MAAM,MAAM,EAAS,GACvC,sBAAsB,CACxB,CACF;GACA;EACF,OAEE,SAAS,OACP,QACA,0BAA0B,QAC1B,6CAEE,EAAE,OAAO,SAAS,MAAM,QAAQ,uBAAuB,EAAS,GAChE,sBAAsB,CACxB,CACF;CAEJ;CAEA,OAAO;EAAE,GAAG;EAAI,OAAO;CAAS;AAClC;;;;;;;;;AAUA,MAAa,iBAA8C,OAAgC;CACzF,IAAI,gBAAgB,EAAE,GACpB,OAAO;CAET,MAAM,cAAc,6CAA6C,EAAE;CACnE,MAAM,QAAwB,CAAC;CAC/B,IAAI,aAAa;CACjB,KAAK,MAAM,CAAC,KAAK,MAAM,YAAY,MAAM,QAAQ,GAC/C,IAAI,OAAO,MAAM;MACX,QAAQ,GAAG,aAAa;CAAA,OAE5B,MAAM,KAAK,YAAY,CAAC,IAAI,cAAc,CAAC,IAAI,CAAC;CAGpD,OAAO;EAAE,GAAG;EAAa;EAAY;CAAM;AAC7C;;;;;;;;;AAUA,MAAa,eAA4C,OAAkC;CACzF,IAAI,kBAAkB,EAAE,GACtB,OAAO;CAET,MAAM,EAAE,YAAY,GAAG,2BAA2B;CAClD,MAAM,QAAiD,CAAC;CACxD,MAAM,EAAE,WAAW,GAAG;CACtB,KAAK,IAAI,MAAM,GAAG,MAAM,QAAQ,OAAO;EACrC,MAAM,IAAI,GAAG,MAAM;EACnB,IAAI,YAAY,CAAC,GACf,MAAM,KAAK,YAAY,CAAC,CAAC;OAEzB,MAAM,KAAK,CAAC;EAEd,IAAI,cAAc,MAAM,SAAS,GAC/B,MAAM,KAAK,UAAU;CAEzB;CACA,OAAO;EAAE,GAAG;EAAwB;CAAM;AAC5C"}
@@ -1,4 +1,4 @@
1
- import { A as SetRequired, O as RuleType, S as RuleGroupTypeAny, _ as ValueProcessorLegacy, a as ExportOperatorMap, c as NLTranslationKey, d as ParameterizedSQL, f as RQBJsonLogic, g as ValueProcessorByRule, h as SQLPreset, i as ExportObjectFormats, l as NLTranslations, m as RuleProcessor, n as DiagnosticsResult, o as FormatQueryOptions, p as RuleGroupProcessor, r as ExportFormat, s as GroupVariantCondition, t as ConstituentWordOrder, u as ParameterizedNamedSQL, v as ValueProcessorOptions } from "./index-CREDWM32.mjs";
1
+ import { A as SetRequired, O as RuleType, S as RuleGroupTypeAny, _ as ValueProcessorLegacy, a as ExportOperatorMap, c as NLTranslationKey, d as ParameterizedSQL, f as RQBJsonLogic, g as ValueProcessorByRule, h as SQLPreset, i as ExportObjectFormats, l as NLTranslations, m as RuleProcessor, n as DiagnosticsResult, o as FormatQueryOptions, p as RuleGroupProcessor, r as ExportFormat, s as GroupVariantCondition, t as ConstituentWordOrder, u as ParameterizedNamedSQL, v as ValueProcessorOptions } from "./index-DlVg-QXo.mjs";
2
2
  import { Column, Operators, SQL, Table } from "drizzle-orm";
3
3
  import { WhereOptions } from "sequelize";
4
4
  import { eq } from "@tanstack/db";
@@ -644,7 +644,7 @@ declare const numerifyValues: (rg: RuleGroupTypeAny, options: SetRequired<Format
644
644
  *
645
645
  * @group Export
646
646
  */
647
- declare const isValidValue: (value: any) => boolean;
647
+ declare const isValidValue: (value: unknown) => boolean;
648
648
  /**
649
649
  * Determines whether {@link formatQuery} should render the given value as a number.
650
650
  * As long as `parseNumbers` is `true`, `number` and `bigint` values will return `true` and
@@ -652,7 +652,7 @@ declare const isValidValue: (value: any) => boolean;
652
652
  *
653
653
  * @group Export
654
654
  */
655
- declare const shouldRenderAsNumber: (value: any, parseNumbers?: boolean) => boolean;
655
+ declare const shouldRenderAsNumber: (value: unknown, parseNumbers?: boolean) => boolean;
656
656
  /**
657
657
  * Used by {@link formatQuery} to determine whether the given value processor is a
658
658
  * "legacy" value processor by counting the number of arguments. Legacy value
@@ -761,6 +761,8 @@ declare const bigIntJsonParseReviver: (_key: string, value: unknown) => unknown;
761
761
  /**
762
762
  * Default value processor used by {@link formatQuery} for "sql" format.
763
763
  *
764
+ * @deprecated Prefer {@link defaultValueProcessorByRule}.
765
+ *
764
766
  * @group Export
765
767
  */
766
768
  declare const defaultValueProcessor: ValueProcessorLegacy;
@@ -1,4 +1,4 @@
1
- import { A as SetRequired, O as RuleType, S as RuleGroupTypeAny, _ as ValueProcessorLegacy, a as ExportOperatorMap, c as NLTranslationKey, d as ParameterizedSQL, f as RQBJsonLogic, g as ValueProcessorByRule, h as SQLPreset, i as ExportObjectFormats, l as NLTranslations, m as RuleProcessor, n as DiagnosticsResult, o as FormatQueryOptions, p as RuleGroupProcessor, r as ExportFormat, s as GroupVariantCondition, t as ConstituentWordOrder, u as ParameterizedNamedSQL, v as ValueProcessorOptions } from "./index-CREDWM32.js";
1
+ import { A as SetRequired, O as RuleType, S as RuleGroupTypeAny, _ as ValueProcessorLegacy, a as ExportOperatorMap, c as NLTranslationKey, d as ParameterizedSQL, f as RQBJsonLogic, g as ValueProcessorByRule, h as SQLPreset, i as ExportObjectFormats, l as NLTranslations, m as RuleProcessor, n as DiagnosticsResult, o as FormatQueryOptions, p as RuleGroupProcessor, r as ExportFormat, s as GroupVariantCondition, t as ConstituentWordOrder, u as ParameterizedNamedSQL, v as ValueProcessorOptions } from "./index-DlVg-QXo.js";
2
2
  import { Column, Operators, SQL, Table } from "drizzle-orm";
3
3
  import { WhereOptions } from "sequelize";
4
4
  import { eq } from "@tanstack/db";
@@ -644,7 +644,7 @@ declare const numerifyValues: (rg: RuleGroupTypeAny, options: SetRequired<Format
644
644
  *
645
645
  * @group Export
646
646
  */
647
- declare const isValidValue: (value: any) => boolean;
647
+ declare const isValidValue: (value: unknown) => boolean;
648
648
  /**
649
649
  * Determines whether {@link formatQuery} should render the given value as a number.
650
650
  * As long as `parseNumbers` is `true`, `number` and `bigint` values will return `true` and
@@ -652,7 +652,7 @@ declare const isValidValue: (value: any) => boolean;
652
652
  *
653
653
  * @group Export
654
654
  */
655
- declare const shouldRenderAsNumber: (value: any, parseNumbers?: boolean) => boolean;
655
+ declare const shouldRenderAsNumber: (value: unknown, parseNumbers?: boolean) => boolean;
656
656
  /**
657
657
  * Used by {@link formatQuery} to determine whether the given value processor is a
658
658
  * "legacy" value processor by counting the number of arguments. Legacy value
@@ -761,6 +761,8 @@ declare const bigIntJsonParseReviver: (_key: string, value: unknown) => unknown;
761
761
  /**
762
762
  * Default value processor used by {@link formatQuery} for "sql" format.
763
763
  *
764
+ * @deprecated Prefer {@link defaultValueProcessorByRule}.
765
+ *
764
766
  * @group Export
765
767
  */
766
768
  declare const defaultValueProcessor: ValueProcessorLegacy;