"use client";
import { createSplitProps } from "../../utils/create-split-props.js";
import { CollapsibleContent } from "../collapsible/collapsible-content.js";
import { useTreeViewContext } from "./use-tree-view-context.js";
import { useTreeViewNodePropsContext } from "./use-tree-view-node-props-context.js";
import { forwardRef } from "react";
import { mergeProps } from "@zag-js/react";
import { jsx } from "react/jsx-runtime";
//#region src/components/tree-view/tree-view-branch-content.tsx
var splitVisibilityProps = createSplitProps();
var TreeViewBranchContent = forwardRef((props, ref) => {
	const treeView = useTreeViewContext();
	const nodeProps = useTreeViewNodePropsContext();
	const [, branchContentProps] = splitVisibilityProps(treeView.getBranchContentProps(nodeProps), ["hidden", "data-state"]);
	return /* @__PURE__ */ jsx(CollapsibleContent, {
		ref,
		...mergeProps(branchContentProps, props)
	});
});
TreeViewBranchContent.displayName = "TreeViewBranchContent";
//#endregion
export { TreeViewBranchContent };
