import { jsx as n } from "react/jsx-runtime";
import { createRecipeContext as f, useRecipe as $, useChakraContext as m, useBreakpointValue as p } from "@chakra-ui/react";
import { e as b } from "./extract-style-props-CMyV-es-.es.js";
import { c as u } from "./index-N3Xxo-X9.es.js";
import { $ as x, a as P } from "./utils-CrjF8U_E.es.js";
import { $ as h } from "./useToolbar-NGUPId3z.es.js";
import { $ as C } from "./mergeProps-B-cqsBhL.es.js";
import { $ as z } from "./filterDOMProps-Cxz9cAAv.es.js";
import R, { forwardRef as T, createContext as y } from "react";
const v = /* @__PURE__ */ y({}), k = /* @__PURE__ */ T(function(o, e) {
  [o, e] = x(o, e, v);
  let { toolbarProps: a } = h(o, e), t = P({
    ...o,
    values: {
      orientation: o.orientation || "horizontal"
    },
    defaultClassName: "react-aria-Toolbar"
  }), r = z(o, {
    global: !0
  });
  return delete r.id, /* @__PURE__ */ R.createElement("div", {
    ...C(r, t, a),
    ref: e,
    slot: o.slot || void 0,
    "data-orientation": o.orientation || "horizontal"
  }, t.children);
}), { withContext: O } = /* @__PURE__ */ f({
  key: "nimbusToolbar"
}), V = /* @__PURE__ */ O(
  "div"
), N = ({
  ref: i,
  orientation: o = "horizontal",
  ...e
}) => {
  const a = $({ recipe: u }), [t, r] = a.splitVariantProps({
    orientation: o,
    ...e
  }), [c, s] = b(r), l = m().normalizeValue(o), d = p(l) ?? "horizontal";
  return /* @__PURE__ */ n(
    V,
    {
      orientation: o,
      ...t,
      ...c,
      asChild: !0,
      children: /* @__PURE__ */ n(
        k,
        {
          ref: i,
          orientation: d,
          ...s
        }
      )
    }
  );
};
export {
  N as T
};
//# sourceMappingURL=toolbar-CyTAGF7Q.es.js.map
