Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
//#region src/hooks/useNumberInput/utils/padTrimValue.ts
const padTrimValue = (value, decimalSeparator = ".", decimalScale) => {
	if (decimalScale === void 0 || value === "" || value === void 0) return value;
	if (!value.match(/\d/g)) return "";
	const [int, decimals] = value.split(decimalSeparator);
	if (decimalScale === 0) return int;
	let newValue = decimals || "";
	if (newValue.length < decimalScale) while (newValue.length < decimalScale) newValue += "0";
	else newValue = newValue.slice(0, decimalScale);
	return `${int}${decimalSeparator}${newValue}`;
};
//#endregion
exports.padTrimValue = padTrimValue;
