"use client";
const require_create_split_props = require("../../utils/create-split-props.cjs");
const require_factory = require("../factory.cjs");
const require_use_qr_code_context = require("./use-qr-code-context.cjs");
const require_use_qr_code = require("./use-qr-code.cjs");
let react = require("react");
let _zag_js_react = require("@zag-js/react");
let react_jsx_runtime = require("react/jsx-runtime");
//#region src/components/qr-code/qr-code-root.tsx
var splitRootProps = require_create_split_props.createSplitProps();
var QrCodeRoot = (0, react.forwardRef)((props, ref) => {
	const [qrcodeProps, localProps] = splitRootProps(props, [
		"defaultValue",
		"encoding",
		"id",
		"ids",
		"onValueChange",
		"pixelSize",
		"value"
	]);
	const qrCode = require_use_qr_code.useQrCode(qrcodeProps);
	const mergedProps = (0, _zag_js_react.mergeProps)(qrCode.getRootProps(), localProps);
	return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_use_qr_code_context.QrCodeProvider, {
		value: qrCode,
		children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_factory.ark.div, {
			...mergedProps,
			ref
		})
	});
});
QrCodeRoot.displayName = "QrcodeRoot";
//#endregion
exports.QrCodeRoot = QrCodeRoot;
