"use client";
let react_jsx_runtime = require("react/jsx-runtime");
//#region packages/@mantine/core/src/components/Input/InputClearSection/InputClearSection.tsx
const clearSectionOffset = {
	xs: 7,
	sm: 8,
	md: 10,
	lg: 12,
	xl: 15
};
function InputClearSection({ __clearable, __clearSection, rightSection, __defaultRightSection, size = "sm", __clearSectionMode = "both" }) {
	const clearSection = __clearable && __clearSection;
	if (__clearSectionMode === "rightSection") return rightSection === null ? null : rightSection || __defaultRightSection;
	if (__clearSectionMode === "clear") return rightSection === null ? null : clearSection || __defaultRightSection;
	if (clearSection && (rightSection || __defaultRightSection)) return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
		"data-combined-clear-section": true,
		style: {
			display: "flex",
			gap: 2,
			alignItems: "center",
			paddingInlineEnd: clearSectionOffset[size]
		},
		children: [clearSection, rightSection || __defaultRightSection]
	});
	return rightSection === null ? null : rightSection || clearSection || __defaultRightSection;
}
//#endregion
exports.InputClearSection = InputClearSection;

//# sourceMappingURL=InputClearSection.cjs.map