"use client";
import { jsx as e } from "react/jsx-runtime";
import { useContext as i, useMemo as a } from "react";
import { GanttContext as p } from "../../../Gantt/GanttContext.js";
import { BarsRowContext as m } from "./BarsRowContext.js";
import l from "./BarsItems/BarItems.js";
const v = ({
  barData: t,
  index: r,
  style: o,
  onBarDoubleClick: s
}) => {
  const { settings: n } = i(p), d = a(() => ({
    ...o,
    backgroundImage: `repeating-linear-gradient(to right, var(--d-border) 0px 1px, ${r % 2 === 0 ? "var(--d-background)" : "var(--d-secondary)"} 1px ${n.stepWidth}px`
  }), [r, n.stepWidth, o]);
  return /* @__PURE__ */ e(m.Provider, { value: { barData: t }, children: /* @__PURE__ */ e("div", { className: "gantt-bars-row-wrap", style: d, children: /* @__PURE__ */ e(
    l,
    {
      data: t.data,
      title: t.title,
      barKey: t.key,
      leftRender: t.leftRender,
      onBarDoubleClick: s
    }
  ) }) });
};
export {
  v as default
};
