const require_chunk = require('./chunk-U64pC571.js');
let numeric_quantity = require("numeric-quantity");

//#region src/utils/misc.ts
/**
* Converts a value to lowercase if it's a string, otherwise returns the value as is.
*/
// istanbul ignore next
const lc = (v) => typeof v === "string" ? v.toLowerCase() : v;
/**
* Regex matching numeric strings. Passes for positive/negative integers, decimals,
* and E notation, with optional surrounding whitespace.
*/
const numericRegex = new RegExp(numeric_quantity.numericRegex.source.replace(/^\^/, String.raw`^\s*`).replace(/\$$/, String.raw`\s*$`));
/**
* Determines if a variable is a plain old JavaScript object, aka POJO.
*/
const isPojo = (obj) => obj === null || typeof obj !== "object" ? false : Object.getPrototypeOf(obj) === Object.prototype;
/**
* Simple helper to determine whether a value is null, undefined, or an empty string.
*/
const nullOrUndefinedOrEmpty = (value) => value === null || value === void 0 || value === "";

//#endregion
//#region src/utils/isRuleGroup.ts
/**
* Determines if an object is a {@link RuleGroupType} or {@link RuleGroupTypeIC}.
*/
const isRuleGroup = (rg) => isPojo(rg) && Array.isArray(rg.rules);
/**
* Determines if an object is a {@link RuleGroupType}.
*/
const isRuleGroupType = (rg) => isRuleGroup(rg) && typeof rg.combinator === "string";
/**
* Determines if an object is a {@link RuleGroupTypeIC}.
*/
const isRuleGroupTypeIC = (rg) => isRuleGroup(rg) && rg.combinator === void 0;

//#endregion
Object.defineProperty(exports, 'isPojo', {
  enumerable: true,
  get: function () {
    return isPojo;
  }
});
Object.defineProperty(exports, 'isRuleGroup', {
  enumerable: true,
  get: function () {
    return isRuleGroup;
  }
});
Object.defineProperty(exports, 'isRuleGroupType', {
  enumerable: true,
  get: function () {
    return isRuleGroupType;
  }
});
Object.defineProperty(exports, 'isRuleGroupTypeIC', {
  enumerable: true,
  get: function () {
    return isRuleGroupTypeIC;
  }
});
Object.defineProperty(exports, 'lc', {
  enumerable: true,
  get: function () {
    return lc;
  }
});
Object.defineProperty(exports, 'nullOrUndefinedOrEmpty', {
  enumerable: true,
  get: function () {
    return nullOrUndefinedOrEmpty;
  }
});
Object.defineProperty(exports, 'numericRegex', {
  enumerable: true,
  get: function () {
    return numericRegex;
  }
});
//# sourceMappingURL=isRuleGroup-Cjk1Q2mj.js.map