"use client";
const require_render_strategy = require("../../utils/render-strategy.cjs");
const require_split_presence_props = require("../presence/split-presence-props.cjs");
const require_use_presence = require("../presence/use-presence.cjs");
const require_use_presence_context = require("../presence/use-presence-context.cjs");
const require_use_tour_context = require("./use-tour-context.cjs");
let _zag_js_react = require("@zag-js/react");
let react_jsx_runtime = require("react/jsx-runtime");
//#region src/components/tour/tour-root.tsx
var TourRoot = (props) => {
	const [presenceProps, { children, tour }] = require_split_presence_props.splitPresenceProps(props);
	const [renderStrategyProps] = require_render_strategy.splitRenderStrategyProps(presenceProps);
	return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_use_tour_context.TourProvider, {
		value: tour,
		children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_render_strategy.RenderStrategyPropsProvider, {
			value: renderStrategyProps,
			children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_use_presence_context.PresenceProvider, {
				value: require_use_presence.usePresence((0, _zag_js_react.mergeProps)({ present: tour.open }, presenceProps)),
				children
			})
		})
	});
};
//#endregion
exports.TourRoot = TourRoot;
