import { jsxs as s, jsx as t } from "react/jsx-runtime";
import { Icon as m } from "../icon/index.js";
import '../../assets/index10.css';const f = "_file_1ik2m_1", n = {
  file: f,
  delete: "_delete_1ik2m_52"
}, _ = ({
  deleteAccessibleLabel: d,
  name: a,
  onClick: e,
  onDelete: i,
  ref: o,
  url: l
}) => /* @__PURE__ */ s("div", { className: n.file, ref: o, "data-component": "file", children: [
  /* @__PURE__ */ s("a", { href: l, onClick: (r) => {
    r.stopPropagation(), (e || !l) && (r.preventDefault(), e == null || e());
  }, title: a, children: [
    /* @__PURE__ */ t(m, { name: "document", size: "small", variant: "primary" }),
    a
  ] }),
  i && /* @__PURE__ */ t("a", { "aria-label": d ?? `Delete ${a}`, className: n.delete, onClick: () => i(), tabIndex: 0, children: /* @__PURE__ */ t(m, { name: "trash", size: "small", variant: "danger" }) })
] });
export {
  _ as File
};
//# sourceMappingURL=index.js.map
