const a = (t, r, o) => {
  let e = t.indexOf(r);
  if (e === -1)
    return t;
  const n = r.length;
  let l = 0, u = "";
  do
    u += t.substr(l, e - l) + r + o, l = e + n, e = t.indexOf(r, l);
  while (e !== -1);
  return u += t.substr(l), u;
}, d = (t, r, o, e) => {
  let n = 0, l = "";
  do {
    const u = t[e - 1] === "\r";
    l += t.substr(n, (u ? e - 1 : e) - n) + r + (u ? `\r
` : `
`) + o, n = e + 1, e = t.indexOf(`
`, n);
  } while (e !== -1);
  return l += t.substr(n), l;
};
var c = {
  stringReplaceAll: a,
  stringEncaseCRLFWithFirstIndex: d
};
export {
  c as default
};
//# sourceMappingURL=util.js.map
