@purpurds/breadcrumbs 5.6.0 → 5.8.0

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.
@@ -1,6 +1,6 @@
1
- import { jsx as o, jsxs as x, Fragment as L } from "react/jsx-runtime";
2
- import { Children as w, cloneElement as N, createElement as E } from "react";
3
- function H(e) {
1
+ import { jsx as o, jsxs as x, Fragment as M } from "react/jsx-runtime";
2
+ import { Children as w, cloneElement as N, createElement as H } from "react";
3
+ function B(e) {
4
4
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
5
5
  }
6
6
  var S = { exports: {} };
@@ -39,8 +39,8 @@ var S = { exports: {} };
39
39
  e.exports ? (n.default = n, e.exports = n) : window.classNames = n;
40
40
  })();
41
41
  })(S);
42
- var B = S.exports;
43
- const P = /* @__PURE__ */ H(B), A = {
42
+ var E = S.exports;
43
+ const P = /* @__PURE__ */ B(E), z = {
44
44
  "purpur-icon": "_purpur-icon_8u1lq_1",
45
45
  "purpur-icon--xxs": "_purpur-icon--xxs_8u1lq_4",
46
46
  "purpur-icon--xs": "_purpur-icon--xs_8u1lq_8",
@@ -48,20 +48,20 @@ const P = /* @__PURE__ */ H(B), A = {
48
48
  "purpur-icon--md": "_purpur-icon--md_8u1lq_16",
49
49
  "purpur-icon--lg": "_purpur-icon--lg_8u1lq_20",
50
50
  "purpur-icon--xl": "_purpur-icon--xl_8u1lq_24"
51
- }, Z = {
51
+ }, A = {
52
52
  name: "home",
53
53
  svg: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M11.38 1.848a.9.9 0 0 1 1.24 0l8.69 8.276c1.242 1.183.405 3.276-1.31 3.276h-.6v8.1a.9.9 0 0 1-.9.9h-13a.9.9 0 0 1-.9-.9v-8.1H4c-1.715 0-2.552-2.093-1.31-3.276l8.69-8.276ZM12 3.743l-8.069 7.685c-.026.024-.03.04-.032.049a.11.11 0 0 0 .008.06.11.11 0 0 0 .036.049c.007.005.021.014.057.014h1.5a.9.9 0 0 1 .9.9v8.1h11.2v-8.1a.9.9 0 0 1 .9-.9H20c.036 0 .05-.009.057-.014a.111.111 0 0 0 .036-.049.111.111 0 0 0 .008-.06c-.002-.008-.006-.025-.032-.05L12 3.744ZM10.6 14a.9.9 0 0 1 .9-.9H15a.9.9 0 0 1 .9.9v4a.9.9 0 0 1-.9.9h-3.5a.9.9 0 0 1-.9-.9v-4Zm1.8.9v2.2h1.7v-2.2h-1.7Z" clip-rule="evenodd"/></svg>',
54
54
  keywords: ["home"],
55
55
  category: "buildings"
56
56
  }, j = (e) => /* @__PURE__ */ o(
57
- F,
57
+ V,
58
58
  {
59
59
  ...e,
60
- svg: Z
60
+ svg: A
61
61
  }
62
62
  );
63
63
  j.displayName = "IconHome";
64
- const z = P.bind(A), $ = "purpur-icon", C = "md", T = (e) => e.filter((u) => Object.keys(u).length >= 1).map((u) => `${u.name}="${u.value}"`).join(" "), k = ({ content: e = "", title: u } = {}) => {
64
+ const C = P.bind(z), $ = "purpur-icon", Z = "md", T = (e) => e.filter((u) => Object.keys(u).length >= 1).map((u) => `${u.name}="${u.value}"`).join(" "), k = ({ content: e = "", title: u } = {}) => {
65
65
  const n = [
66
66
  { name: "xmlns", value: "http://www.w3.org/2000/svg" },
67
67
  { name: "fill", value: "currentColor" },
@@ -69,18 +69,18 @@ const z = P.bind(A), $ = "purpur-icon", C = "md", T = (e) => e.filter((u) => Obj
69
69
  u ? { name: "role", value: "img" } : { name: "aria-hidden", value: "true" }
70
70
  ], a = u ? `<title>${u}</title>` : "";
71
71
  return `<svg ${T(n)}>${a}${e}</svg>`;
72
- }, D = (e) => e.replace(/<(\/?)svg([^>]*)>/g, "").trim(), F = ({
72
+ }, F = (e) => e.replace(/<(\/?)svg([^>]*)>/g, "").trim(), V = ({
73
73
  ["data-testid"]: e,
74
74
  svg: u,
75
75
  allyTitle: n,
76
76
  className: a = "",
77
- size: i = C,
77
+ size: i = Z,
78
78
  ...r
79
79
  }) => {
80
80
  const t = k({
81
- content: D(u.svg),
81
+ content: F(u.svg),
82
82
  title: n
83
- }), s = z(a, $, `${$}--${i}`);
83
+ }), s = C(a, $, `${$}--${i}`);
84
84
  return /* @__PURE__ */ o(
85
85
  "span",
86
86
  {
@@ -92,10 +92,10 @@ const z = P.bind(A), $ = "purpur-icon", C = "md", T = (e) => e.filter((u) => Obj
92
92
  }
93
93
  );
94
94
  };
95
- function V(e) {
95
+ function D(e) {
96
96
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
97
97
  }
98
- var I = { exports: {} };
98
+ var O = { exports: {} };
99
99
  /*!
100
100
  Copyright (c) 2018 Jed Watson.
101
101
  Licensed under the MIT License (MIT), see
@@ -130,9 +130,9 @@ var I = { exports: {} };
130
130
  }
131
131
  e.exports ? (n.default = n, e.exports = n) : window.classNames = n;
132
132
  })();
133
- })(I);
134
- var J = I.exports;
135
- const O = /* @__PURE__ */ V(J), c = {
133
+ })(O);
134
+ var J = O.exports;
135
+ const I = /* @__PURE__ */ D(J), c = {
136
136
  "purpur-breadcrumbs": "_purpur-breadcrumbs_3f81v_1",
137
137
  "purpur-breadcrumbs--default": "_purpur-breadcrumbs--default_3f81v_21",
138
138
  "purpur-breadcrumbs--negative": "_purpur-breadcrumbs--negative_3f81v_35",
@@ -142,7 +142,7 @@ const O = /* @__PURE__ */ V(J), c = {
142
142
  "purpur-breadcrumb-item--current": "_purpur-breadcrumb-item--current_3f81v_70",
143
143
  "purpur-breadcrumb-item--negative": "_purpur-breadcrumb-item--negative_3f81v_92",
144
144
  "purpur-breadcrumb-item__separator": "_purpur-breadcrumb-item__separator_3f81v_95"
145
- }, R = (e, u, n) => ({
145
+ }, W = (e, u, n) => ({
146
146
  "@type": "ListItem",
147
147
  position: n,
148
148
  name: e,
@@ -159,18 +159,18 @@ const O = /* @__PURE__ */ V(J), c = {
159
159
  meta: i = !0,
160
160
  negative: r = !1
161
161
  }) => {
162
- const t = O([
162
+ const t = I([
163
163
  a,
164
164
  c[b],
165
165
  c[`${b}--${r ? "negative" : "default"}`]
166
- ]), s = w.count(n), l = [], m = w.map(n, (d, M) => {
167
- const y = M + 1, q = s === y, _ = d.props.children, p = typeof _ == "string" ? null : _.props;
166
+ ]), s = w.count(n), l = [], m = w.map(n, (d, q) => {
167
+ const y = q + 1, L = s === y, _ = d.props.children, p = typeof _ == "string" ? null : _.props;
168
168
  let f = null, v = null;
169
- return typeof _ == "string" ? (f = _, v = d.props.href) : p != null && p.children && typeof (p == null ? void 0 : p.children) == "string" && (f = p.children, v = p.href), f && v && l.push(R(f, v, y)), N(d, {
170
- current: q,
169
+ return typeof _ == "string" ? (f = _, v = d.props.href) : p != null && p.children && typeof (p == null ? void 0 : p.children) == "string" && (f = p.children, v = p.href), f && v && l.push(W(f, v, y)), N(d, {
170
+ current: L,
171
171
  negative: r,
172
172
  ...y === 1 && {
173
- children: /* @__PURE__ */ x(L, { children: [
173
+ children: /* @__PURE__ */ x(M, { children: [
174
174
  /* @__PURE__ */ o("span", { className: c[`${b}__home`], "aria-hidden": "true", children: /* @__PURE__ */ o(j, { size: "xs" }) }),
175
175
  d.props.children
176
176
  ] })
@@ -188,7 +188,7 @@ const O = /* @__PURE__ */ V(J), c = {
188
188
  }
189
189
  ) : null
190
190
  ] });
191
- }, U = ({
191
+ }, R = ({
192
192
  href: e,
193
193
  ["data-testid"]: u,
194
194
  children: n,
@@ -197,7 +197,7 @@ const O = /* @__PURE__ */ V(J), c = {
197
197
  onClick: r,
198
198
  ...t
199
199
  }) => {
200
- const s = O(
200
+ const s = I(
201
201
  [c[h], c[`${h}--${i ? "negative" : "default"}`]],
202
202
  {
203
203
  [c[`${h}--current`]]: a
@@ -211,7 +211,7 @@ const O = /* @__PURE__ */ V(J), c = {
211
211
  "aria-current": a ? "page" : void 0,
212
212
  onClick: r
213
213
  };
214
- return e || typeof n == "string" ? E("a", m, n) : N(n, {
214
+ return e || typeof n == "string" ? H("a", m, n) : N(n, {
215
215
  ...m,
216
216
  ...n.props
217
217
  });
@@ -219,7 +219,7 @@ const O = /* @__PURE__ */ V(J), c = {
219
219
  a ? null : /* @__PURE__ */ o("span", { "aria-hidden": !0, className: c[`${h}__separator`], children: "/" })
220
220
  ] });
221
221
  };
222
- Q.Item = U;
222
+ Q.Item = R;
223
223
  export {
224
224
  Q as Breadcrumbs
225
225
  };