@achs/webkit
Version:
Conjunto de componentes de UI con el estilo del Sistema de Diseño ACHS (Asociación Chilena de Seguridad), para reutilizar de forma transversal en las aplicaciones web de ACHS. Construido con **React 19**, **TypeScript** y **Vite**, con soporte para las
33 lines (32 loc) • 1.35 kB
JavaScript
import { jsx as e, jsxs as h } from "react/jsx-runtime";
import { forwardRef as p } from "react";
import a from "./Breadcrumbs.module.scss.mjs";
import '../../../assets/node_modules/.pnpm/bootstrap-icons@1.13.1/node_modules/bootstrap-icons/font/bootstrap-icons.css';/* empty css */
const b = p(({
items: l,
color: c = "primary",
separatorIcon: o = "bi-chevron-right",
className: n,
...d
}, t) => /* @__PURE__ */ e(
"nav",
{
ref: t,
"aria-label": "Breadcrumb",
"data-color": c,
className: `${a.breadcrumbs} ${n ?? ""}`.trim(),
...d,
children: /* @__PURE__ */ e("ol", { className: a.list, children: l.map((r, i) => {
const s = i === l.length - 1, m = !s && (r.href !== void 0 || r.onClick !== void 0);
return /* @__PURE__ */ h("li", { className: a.item, children: [
m ? /* @__PURE__ */ e("a", { className: a.link, href: r.href, onClick: r.onClick, children: r.label }) : /* @__PURE__ */ e("span", { className: a.current, "aria-current": s ? "page" : void 0, children: r.label }),
!s && /* @__PURE__ */ e("i", { className: `bi ${o} ${a.separator}`, "aria-hidden": "true" })
] }, i);
}) })
}
));
b.displayName = "Breadcrumbs";
export {
b as Breadcrumbs,
b as default
};