const require_rolldown_runtime = require('../../../../../../_virtual/rolldown_runtime.js');
const require_assertString$1 = require('./util/assertString.js');
const require_merge$1 = require('./util/merge.js');

//#region ../../node_modules/.pnpm/validator@13.12.0/node_modules/validator/lib/isCurrency.js
var require_isCurrency = /* @__PURE__ */ require_rolldown_runtime.__commonJS({ "../../node_modules/.pnpm/validator@13.12.0/node_modules/validator/lib/isCurrency.js": ((exports, module) => {
	Object.defineProperty(exports, "__esModule", { value: true });
	exports.default = isCurrency;
	var _merge = _interopRequireDefault(require_merge$1.require_merge());
	var _assertString = _interopRequireDefault(require_assertString$1.require_assertString());
	function _interopRequireDefault(obj) {
		return obj && obj.__esModule ? obj : { default: obj };
	}
	function currencyRegex(options) {
		var decimal_digits = "\\d{".concat(options.digits_after_decimal[0], "}");
		options.digits_after_decimal.forEach(function(digit, index) {
			if (index !== 0) decimal_digits = "".concat(decimal_digits, "|\\d{").concat(digit, "}");
		});
		var symbol = "(".concat(options.symbol.replace(/\W/, function(m) {
			return "\\".concat(m);
		}), ")").concat(options.require_symbol ? "" : "?"), negative = "-?", valid_whole_dollar_amounts = [
			"0",
			"[1-9]\\d*",
			"[1-9]\\d{0,2}(\\".concat(options.thousands_separator, "\\d{3})*")
		], whole_dollar_amount = "(".concat(valid_whole_dollar_amounts.join("|"), ")?"), decimal_amount = "(\\".concat(options.decimal_separator, "(").concat(decimal_digits, "))").concat(options.require_decimal ? "" : "?");
		var pattern = whole_dollar_amount + (options.allow_decimal || options.require_decimal ? decimal_amount : "");
		if (options.allow_negatives && !options.parens_for_negatives) {
			if (options.negative_sign_after_digits) pattern += negative;
			else if (options.negative_sign_before_digits) pattern = negative + pattern;
		}
		if (options.allow_negative_sign_placeholder) pattern = "( (?!\\-))?".concat(pattern);
		else if (options.allow_space_after_symbol) pattern = " ?".concat(pattern);
		else if (options.allow_space_after_digits) pattern += "( (?!$))?";
		if (options.symbol_after_digits) pattern += symbol;
		else pattern = symbol + pattern;
		if (options.allow_negatives) {
			if (options.parens_for_negatives) pattern = "(\\(".concat(pattern, "\\)|").concat(pattern, ")");
			else if (!(options.negative_sign_before_digits || options.negative_sign_after_digits)) pattern = negative + pattern;
		}
		return new RegExp("^(?!-? )(?=.*\\d)".concat(pattern, "$"));
	}
	var default_currency_options = {
		symbol: "$",
		require_symbol: false,
		allow_space_after_symbol: false,
		symbol_after_digits: false,
		allow_negatives: true,
		parens_for_negatives: false,
		negative_sign_before_digits: false,
		negative_sign_after_digits: false,
		allow_negative_sign_placeholder: false,
		thousands_separator: ",",
		decimal_separator: ".",
		allow_decimal: true,
		require_decimal: false,
		digits_after_decimal: [2],
		allow_space_after_digits: false
	};
	function isCurrency(str, options) {
		(0, _assertString.default)(str);
		options = (0, _merge.default)(options, default_currency_options);
		return currencyRegex(options).test(str);
	}
	module.exports = exports.default;
	module.exports.default = exports.default;
}) });

//#endregion
Object.defineProperty(exports, 'default', {
  enumerable: true,
  get: function () {
    return require_isCurrency();
  }
});