"use client";
import { rem } from "../../core/utils/units-converters/rem.mjs";
import { getSize } from "../../core/utils/get-size/get-size.mjs";
import { createVarsResolver } from "../../core/styles-api/create-vars-resolver/create-vars-resolver.mjs";
import { getThemeColor } from "../../core/MantineProvider/color-functions/get-theme-color/get-theme-color.mjs";
import { useProps } from "../../core/MantineProvider/use-props/use-props.mjs";
import { useStyles } from "../../core/styles-api/use-styles/use-styles.mjs";
import { factory } from "../../core/factory/factory.mjs";
import { Box } from "../../core/Box/Box.mjs";
import { UnstyledButton } from "../UnstyledButton/UnstyledButton.mjs";
import Burger_module_default from "./Burger.module.mjs";
import { jsx, jsxs } from "react/jsx-runtime";
//#region packages/@mantine/core/src/components/Burger/Burger.tsx
const varsResolver = createVarsResolver((theme, { color, size, lineSize, transitionDuration, transitionTimingFunction }) => ({ root: {
	"--burger-color": color ? getThemeColor(color, theme) : void 0,
	"--burger-size": getSize(size, "burger-size"),
	"--burger-line-size": lineSize ? rem(lineSize) : void 0,
	"--burger-transition-duration": transitionDuration === void 0 ? void 0 : `${transitionDuration}ms`,
	"--burger-transition-timing-function": transitionTimingFunction
} }));
const Burger = factory((_props) => {
	const props = useProps("Burger", null, _props);
	const { classNames, className, style, styles, unstyled, vars, opened, children, transitionDuration, transitionTimingFunction, lineSize, attributes, ...others } = props;
	const getStyles = useStyles({
		name: "Burger",
		classes: Burger_module_default,
		props,
		className,
		style,
		classNames,
		styles,
		unstyled,
		attributes,
		vars,
		varsResolver
	});
	return /* @__PURE__ */ jsxs(UnstyledButton, {
		...getStyles("root"),
		...others,
		children: [/* @__PURE__ */ jsx(Box, {
			mod: ["reduce-motion", { opened }],
			...getStyles("burger")
		}), children]
	});
});
Burger.classes = Burger_module_default;
Burger.varsResolver = varsResolver;
Burger.displayName = "@mantine/core/Burger";
//#endregion
export { Burger };

//# sourceMappingURL=Burger.mjs.map