"use client";
const require_use_props = require("../../../core/MantineProvider/use-props/use-props.cjs");
const require_factory = require("../../../core/factory/factory.cjs");
const require_Box = require("../../../core/Box/Box.cjs");
const require_Splitter_context = require("../Splitter.context.cjs");
const require_Splitter_module = require("../Splitter.module.cjs");
let react_jsx_runtime = require("react/jsx-runtime");
//#region packages/@mantine/core/src/components/Splitter/SplitterPane/SplitterPane.tsx
const SplitterPane = require_factory.factory((_props) => {
	const props = require_use_props.useProps("SplitterPane", null, _props);
	const { className, classNames, style, styles, vars, children, defaultSize, min, max, collapsible, collapseThreshold, __index, mod, ...others } = props;
	const ctx = require_Splitter_context.useSplitterContext();
	const size = ctx.sizes[__index];
	const isCollapsed = ctx.collapsed[__index];
	const sizeStyle = { flexBasis: `${size}%` };
	return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_Box.Box, {
		...ctx.getStyles("pane", {
			className,
			classNames,
			style: [sizeStyle, style],
			styles,
			props
		}),
		mod: [{ collapsed: isCollapsed || void 0 }, mod],
		...others,
		children
	});
});
SplitterPane.classes = require_Splitter_module.default;
SplitterPane.displayName = "@mantine/core/SplitterPane";
//#endregion
exports.SplitterPane = SplitterPane;

//# sourceMappingURL=SplitterPane.cjs.map