import { jsx as r } from "react/jsx-runtime";
import { Link as f, NavLink as k } from "react-router-dom";
function u({
  routerLinkComponent: n,
  to: o,
  external: t = !1,
  children: i,
  ...e
}) {
  return t ? (
    // @ts-expect-error
    /* @__PURE__ */ r("a", { href: o, ...e, children: i })
  ) : (
    // @ts-ignore
    /* @__PURE__ */ r(n, { to: o, ...e, children: i })
  );
}
function p({ ...n }) {
  return /* @__PURE__ */ r(u, { routerLinkComponent: f, ...n });
}
function m({ className: n = "", ...o }) {
  const t = o.external && typeof n == "function" ? n({}) : n;
  return /* @__PURE__ */ r(u, { routerLinkComponent: k, className: t, ...o });
}
export {
  p as Link,
  m as NavLink
};
