(function (global) {
  const app = (global.EpicrisisApp = global.EpicrisisApp || {});

  function init() {
    if (!document.body.classList.contains("epicrisis-page")) return;
    app.utils.localizeMachineDates();
    app.scrollTop.init();
    app.selection.hidratarDraftPdfInicial();
    app.selection.inicializarSeleccionPDF();
    app.draft.instalarPersistenciaDraft();
    app.soat.initForm();
    app.qxAgent.ejecutarAgenteHallazgosQx();
  }

  document.addEventListener("DOMContentLoaded", init);
})(globalThis);
