"use client";
function d(s, o, n, e) {
  const { month: h, defaultMonth: M, today: c = e.today(), numberOfMonths: f = 1 } = s;
  let t = h || M || c;
  const { differenceInCalendarMonths: i, addMonths: l, startOfMonth: r } = e;
  if (n && i(n, t) < f - 1) {
    const u = -1 * (f - 1);
    t = l(n, u);
  }
  return o && i(t, o) < 0 && (t = o), r(t);
}
export {
  d as getInitialMonth
};
