import { textLockup as s, events as D } from "@universityofmaryland/web-elements-library/atomic";
import { parseDateFromElement as r, createEventDetails as S } from "@universityofmaryland/web-utilities-library/date";
import { Attributes as c, Register as p, Lifecycle as f, Slots as n } from "@universityofmaryland/web-model-library";
const v = "umd-element-events-date", g = c.handler.common.resize(
  (e) => e.events?.size()
), h = (e) => {
  const t = c.isTheme.dark({ element: e }), o = n.headline.default({ element: e }), i = e.querySelector(
    `[slot="${n.name.DATE_START_ISO}"]`
  ), m = e.querySelector(
    `[slot="${n.name.DATE_END_ISO}"]`
  ), a = r({
    element: i
  }), l = r({ element: m });
  if (!a)
    return s.date({
      headline: o,
      isThemeDark: t
    });
  const d = S({
    startDate: a,
    endDate: l
  }), u = D.sign({
    ...d,
    isThemeDark: t
  });
  return s.date({
    headline: o,
    dateSign: u,
    isThemeDark: t
  });
}, E = p.webComponent({
  tagName: v,
  createComponent: h,
  attributes: [g],
  afterConnect: f.hooks.loadOnConnect
});
var b = E;
export {
  b as e
};
//# sourceMappingURL=event-lockup-DYOdwoC5.js.map
