@happeouikit/content-renderer 3.2.18 → 3.2.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.es.js CHANGED
@@ -5207,13 +5207,17 @@ const ni = ai(), ii = new RegExp(rt, "gi"), ui = new RegExp(
5207
5207
  return;
5208
5208
  const o = T.current.querySelectorAll("a") || [];
5209
5209
  o.length > 0 && o.forEach((f) => {
5210
- const { href: c } = f, h = new URL(c), { hostname: A } = h;
5211
- if (!(A !== a || h.pathname === "/"))
5210
+ try {
5211
+ const { href: c } = f, h = new URL(c), { hostname: A } = h;
5212
+ if (A !== a || h.pathname === "/")
5213
+ return;
5212
5214
  if (d === "") {
5213
5215
  const _ = `${h.pathname}${h.search}${h.hash}`;
5214
5216
  f.href = _;
5215
5217
  } else
5216
5218
  f.href = c.replace(a, d);
5219
+ } catch {
5220
+ }
5217
5221
  });
5218
5222
  });
5219
5223
  };