import { jsx as e } from "../../../../../external/.pnpm/preact@10.28.2/node_modules/preact/jsx-runtime/dist/jsxRuntime.module.js";
import { memo as p, forwardRef as h } from "../../../../../external/.pnpm/preact@10.28.2/node_modules/preact/compat/dist/compat.module.js";
import y from "./CalendarGridDate.js";
import _ from "./CalendarGridDayOfWeek.js";
/* empty css                  */
const f = h(({ cursorRootProps: t, onlyCellsWithin: i, prepare: d, getGridLabel: s, grid: r }, o) => /* @__PURE__ */ e("ol", { className: "adyen-pe-calendar", role: "none", ...t, children: r.map((a) => /* @__PURE__ */ e("li", { className: "adyen-pe-calendar__month", role: "none", children: [
  /* @__PURE__ */ e("div", { className: "adyen-pe-calendar__month-name", role: "none", "data-testid": "calendar-month-name", children: /* @__PURE__ */ e("time", { dateTime: a.datetime, "aria-hidden": "true", children: a.label }) }),
  /* @__PURE__ */ e(
    "table",
    {
      role: "grid",
      "aria-multiselectable": !0,
      "aria-label": s(a),
      className: "adyen-pe-calendar__grid",
      style: { "--adyen-pe-calendar-rowspan": r.rowspan },
      children: [
        /* @__PURE__ */ e("thead", { children: /* @__PURE__ */ e("tr", { className: "adyen-pe-calendar__row", children: r.weekdays.map((n, l) => /* @__PURE__ */ e(_, { grid: r, block: a, prepare: d, cell: l, ...n }, n.labels.long)) }) }),
        /* @__PURE__ */ e("tbody", { children: a.map((n, l) => /* @__PURE__ */ e("tr", { className: "adyen-pe-calendar__row", children: n.map((m, c) => /* @__PURE__ */ e(
          y,
          {
            ref: o,
            grid: r,
            block: a,
            prepare: d,
            cell: c,
            onlyCellsWithin: i,
            row: l,
            ...m
          },
          `${a.month}:${m.timestamp}`
        )) }, `${a.month}:${l}`)) })
      ]
    }
  )
] }, a.datetime)) })), G = p(f);
export {
  G as default
};
