import { s as h, r as i, e as x } from "./replay-index-BExnbqCh.js";
import { d as j, i as b, j as d } from "./replay-index-BExnbqCh.js";
async function u(n, e) {
  const t = h(), l = await i(n), c = await i(e), o = l.replace(new RegExp(`^${t}+`), "").split(t).filter(Boolean), r = c.replace(new RegExp(`^${t}+`), "").split(t).filter(Boolean), m = Math.min(o.length, r.length);
  let s = 0;
  for (let a = 0; a < m && o[a] === r[a]; a++)
    s++;
  const p = o.slice(s).map(() => ".."), f = r.slice(s);
  return [...p, ...f].join(t);
}
async function w(n) {
  const e = await x(n);
  return e ? `.${e}` : "";
}
export {
  j as dirname,
  w as extname,
  b as isAbsolute,
  d as join,
  u as relative,
  i as resolve
};
