// src/utils/delay.ts
function delay(ms, { signal } = {}) {
  return new Promise((resolve, reject) => {
    const timeout = setTimeout(resolve, ms);
    if (signal) {
      signal.addEventListener("abort", () => {
        clearTimeout(timeout);
        reject(new DOMException("Aborted", "AbortError"));
      });
    }
  });
}

export {
  delay
};
//# sourceMappingURL=chunk-54MSCPN2.js.map
