import * as l from "react";
import { devUseWarning as i } from "../_util/warning.mjs";
import p from "./Base/index.mjs";
var c = globalThis && globalThis.__rest || function(r, n) {
  var t = {};
  for (var e in r)
    Object.prototype.hasOwnProperty.call(r, e) && n.indexOf(e) < 0 && (t[e] = r[e]);
  if (r != null && typeof Object.getOwnPropertySymbols == "function")
    for (var o = 0, e = Object.getOwnPropertySymbols(r); o < e.length; o++)
      n.indexOf(e[o]) < 0 && Object.prototype.propertyIsEnumerable.call(r, e[o]) && (t[e[o]] = r[e[o]]);
  return t;
};
const f = /* @__PURE__ */ l.forwardRef((r, n) => {
  var {
    ellipsis: t,
    rel: e
  } = r, o = c(r, ["ellipsis", "rel"]);
  if (process.env.NODE_ENV !== "production") {
    const a = i("Typography.Link");
    process.env.NODE_ENV !== "production" && a(typeof t != "object", "usage", "`ellipsis` only supports boolean value.");
  }
  const s = Object.assign(Object.assign({}, o), {
    rel: e === void 0 && o.target === "_blank" ? "noopener noreferrer" : e
  });
  return delete s.navigate, /* @__PURE__ */ l.createElement(p, Object.assign({}, s, {
    ref: n,
    ellipsis: !!t,
    component: "a"
  }));
}), O = f;
export {
  O as default
};
