import { __esmMin } from "../../_virtual/_rolldown/runtime.js";
//#region src/utils/string-coerce.ts
/** Trim non-empty strings; otherwise undefined. */
function normalizeOptionalString(value) {
	if (typeof value !== "string") return;
	const trimmed = value.trim();
	return trimmed.length > 0 ? trimmed : void 0;
}
function normalizeLowercaseStringOrEmpty(value) {
	if (typeof value !== "string") return "";
	return value.trim().toLowerCase();
}
/** Lowercase trimmed string, or undefined when empty/missing. */
function normalizeOptionalLowercaseString(value) {
	if (typeof value !== "string") return;
	const trimmed = value.trim().toLowerCase();
	return trimmed.length > 0 ? trimmed : void 0;
}
var init_string_coerce = __esmMin((() => {}));
//#endregion
init_string_coerce();
export { init_string_coerce, normalizeLowercaseStringOrEmpty, normalizeOptionalLowercaseString, normalizeOptionalString };

//# sourceMappingURL=string-coerce.js.map