import t from "./Calendar.js";
import { RANGE_TO as a, RANGE_FROM as O, SELECT_NONE as i, SELECT_MANY as E, SELECT_ONE as u, CONTROLS_NONE as n, CONTROLS_MINIMAL as c, CONTROLS_ALL as m } from "../constants.js";
import s, { untilNow as L, sinceNow as f, UNBOUNDED_SLICE as _ } from "../timeslice/index.js";
import { struct as l } from "../../../../../utils/struct/main.js";
import { isNumber as v, isFunction as d } from "../../../../../utils/value/is.js";
import { ALREADY_RESOLVED_PROMISE as p } from "../../../../../utils/async/constants.js";
import { enumerable as N } from "../../../../../utils/struct/property.js";
const b = Object.defineProperties(((e) => {
  const { grid: r, kill: o } = new t();
  return v(e) ? r.config({ blocks: e }) : d(e) ? p.then(() => {
    r.config.watch = e;
  }) : r.config(e), l({
    grid: N(r),
    kill: N(o)
  });
}), {
  controls: {
    value: l({
      ALL: { value: m },
      MINIMAL: { value: c },
      NONE: { value: n }
    })
  },
  highlight: {
    value: l({
      ONE: { value: u },
      MANY: { value: E },
      NONE: { value: i }
    })
  },
  slice: {
    value: Object.defineProperties(s.bind(null), {
      FROM: { value: O },
      TO: { value: a },
      UNBOUNDED: { value: _ },
      SINCE_NOW: { get: f },
      UNTIL_NOW: { get: L }
    })
  }
});
export {
  b as default
};
