@purpurds/breadcrumbs 4.4.0 → 4.5.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.
package/dist/LICENSE.txt CHANGED
@@ -1,5 +1,5 @@
1
1
  Name: @purpurds/icon
2
- Version: 4.3.0
2
+ Version: 4.4.0
3
3
  License: AGPL-3.0-only
4
4
  Private: false
5
5
 
@@ -1,10 +1,10 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),m=require("react");function M(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var w={exports:{}};/*!
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),m=require("react");function M(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var w={exports:{}};/*!
2
2
  Copyright (c) 2018 Jed Watson.
3
3
  Licensed under the MIT License (MIT), see
4
4
  http://jedwatson.github.io/classnames
5
- */(function(e){(function(){var u={}.hasOwnProperty;function s(){for(var r="",t=0;t<arguments.length;t++){var n=arguments[t];n&&(r=i(r,a.call(this,n)))}return r}function a(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return s.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var t="";for(var n in r)u.call(r,n)&&r[n]&&(t=i(t,this&&this[n]||n));return t}function i(r,t){return t?r?r+" "+t:r+t:r}e.exports?(s.default=s,e.exports=s):window.classNames=s})()})(w);var B=w.exports;const q=M(B),L={"purpur-icon":"_purpur-icon_8u1lq_1","purpur-icon--xxs":"_purpur-icon--xxs_8u1lq_4","purpur-icon--xs":"_purpur-icon--xs_8u1lq_8","purpur-icon--sm":"_purpur-icon--sm_8u1lq_12","purpur-icon--md":"_purpur-icon--md_8u1lq_16","purpur-icon--lg":"_purpur-icon--lg_8u1lq_20","purpur-icon--xl":"_purpur-icon--xl_8u1lq_24"},R={name:"home",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>',keywords:["home"],category:"buildings"},N=e=>o.jsx(D,{...e,svg:R});N.displayName="IconHome";const T=q.bind(L),j="purpur-icon",V="md",C=e=>e.filter(u=>Object.keys(u).length>=1).map(u=>`${u.name}="${u.value}"`).join(" "),H=({content:e="",title:u}={})=>{const s=[{name:"xmlns",value:"http://www.w3.org/2000/svg"},{name:"fill",value:"currentColor"},{name:"viewBox",value:"0 0 24 24"},u?{name:"role",value:"img"}:{name:"aria-hidden",value:"true"}],a=u?`<title>${u}</title>`:"";return`<svg ${C(s)}>${a}${e}</svg>`},P=e=>e.replace(/<(\/?)svg([^>]*)>/g,"").trim(),D=({["data-testid"]:e,svg:u,allyTitle:s,className:a="",size:i=V,...r})=>{const t=H({content:P(u.svg),title:s}),n=T(a,j,`${j}--${i}`);return o.jsx("span",{"aria-label":s,className:n,"data-testid":e,dangerouslySetInnerHTML:{__html:t},...r})};function Z(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var S={exports:{}};/*!
5
+ */(function(e){(function(){var u={}.hasOwnProperty;function s(){for(var r="",t=0;t<arguments.length;t++){var n=arguments[t];n&&(r=c(r,a.call(this,n)))}return r}function a(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return s.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var t="";for(var n in r)u.call(r,n)&&r[n]&&(t=c(t,this&&this[n]||n));return t}function c(r,t){return t?r?r+" "+t:r+t:r}e.exports?(s.default=s,e.exports=s):window.classNames=s})()})(w);var B=w.exports;const q=M(B),L={"purpur-icon":"_purpur-icon_8u1lq_1","purpur-icon--xxs":"_purpur-icon--xxs_8u1lq_4","purpur-icon--xs":"_purpur-icon--xs_8u1lq_8","purpur-icon--sm":"_purpur-icon--sm_8u1lq_12","purpur-icon--md":"_purpur-icon--md_8u1lq_16","purpur-icon--lg":"_purpur-icon--lg_8u1lq_20","purpur-icon--xl":"_purpur-icon--xl_8u1lq_24"},R={name:"home",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>',keywords:["home"],category:"buildings"},N=e=>i.jsx(D,{...e,svg:R});N.displayName="IconHome";const T=q.bind(L),j="purpur-icon",V="md",C=e=>e.filter(u=>Object.keys(u).length>=1).map(u=>`${u.name}="${u.value}"`).join(" "),H=({content:e="",title:u}={})=>{const s=[{name:"xmlns",value:"http://www.w3.org/2000/svg"},{name:"fill",value:"currentColor"},{name:"viewBox",value:"0 0 24 24"},u?{name:"role",value:"img"}:{name:"aria-hidden",value:"true"}],a=u?`<title>${u}</title>`:"";return`<svg ${C(s)}>${a}${e}</svg>`},P=e=>e.replace(/<(\/?)svg([^>]*)>/g,"").trim(),D=({["data-testid"]:e,svg:u,allyTitle:s,className:a="",size:c=V,...r})=>{const t=H({content:P(u.svg),title:s}),n=T(a,j,`${j}--${c}`);return i.jsx("span",{"aria-label":s,className:n,"data-testid":e,dangerouslySetInnerHTML:{__html:t},...r})};function Z(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var S={exports:{}};/*!
6
6
  Copyright (c) 2018 Jed Watson.
7
7
  Licensed under the MIT License (MIT), see
8
8
  http://jedwatson.github.io/classnames
9
- */(function(e){(function(){var u={}.hasOwnProperty;function s(){for(var r="",t=0;t<arguments.length;t++){var n=arguments[t];n&&(r=i(r,a(n)))}return r}function a(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return s.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var t="";for(var n in r)u.call(r,n)&&r[n]&&(t=i(t,n));return t}function i(r,t){return t?r?r+" "+t:r+t:r}e.exports?(s.default=s,e.exports=s):window.classNames=s})()})(S);var z=S.exports;const $=Z(z),p={"purpur-breadcrumbs":"_purpur-breadcrumbs_1oiut_1","purpur-breadcrumbs--default":"_purpur-breadcrumbs--default_1oiut_18","purpur-breadcrumbs--negative":"_purpur-breadcrumbs--negative_1oiut_32","purpur-breadcrumbs__list":"_purpur-breadcrumbs__list_1oiut_46","purpur-breadcrumbs__home":"_purpur-breadcrumbs__home_1oiut_54","purpur-breadcrumb-item":"_purpur-breadcrumb-item_1oiut_64","purpur-breadcrumb-item--current":"_purpur-breadcrumb-item--current_1oiut_67","purpur-breadcrumb-item--negative":"_purpur-breadcrumb-item--negative_1oiut_87","purpur-breadcrumb-item__separator":"_purpur-breadcrumb-item__separator_1oiut_90"},F=(e,u,s)=>({"@type":"ListItem",position:s,name:e,item:u}),U=e=>JSON.stringify({"@context":"https://schema.org","@type":"BreadcrumbList",itemListElement:e}),I={DEFAULT:"default",NEGATIVE:"negative"},k=Object.values(I),v="purpur-breadcrumbs",g="purpur-breadcrumb-item",O=({["data-testid"]:e,ariaLabel:u,children:s,className:a,meta:i=!0,variant:r="default"})=>{const t=$([a,p[v],p[`${v}--${r}`]]),n=m.Children.count(s),l=[],d=m.Children.map(s,(_,A)=>{const x=A+1,E=n===x,b=_.props.children,c=typeof b=="string"?null:b.props;let f=null,h=null;return typeof b=="string"?(f=b,h=_.props.href):c!=null&&c.children&&typeof(c==null?void 0:c.children)=="string"&&(f=c.children,h=c.href),f&&h&&l.push(F(f,h,x)),m.cloneElement(_,{current:E,variant:r,...x===1&&{children:o.jsxs(o.Fragment,{children:[o.jsx("span",{className:p[`${v}__home`],"aria-hidden":"true",children:o.jsx(N,{size:"xs"})}),_.props.children]})}})}),y=l.length===n?U(l):null;return o.jsxs("nav",{"data-testid":e,"aria-label":u||"Breadcrumb",className:t,children:[o.jsx("ol",{className:p[`${v}__list`],children:d}),i&&y?o.jsx("script",{type:"application/ld+json","data-testid":"breadcrumbs-meta",dangerouslySetInnerHTML:{__html:y}}):null]})},J=({href:e,["data-testid"]:u,children:s,current:a=!1,variant:i="default",onClick:r,...t})=>{const n=$([p[g],p[`${g}--${i}`]],{[p[`${g}--current`]]:a}),l=()=>{const d={href:e,"data-testid":u,"aria-current":a?"page":void 0,onClick:r};return e||typeof s=="string"?m.createElement("a",d,s):m.cloneElement(s,{...d,...s.props})};return o.jsxs("li",{...t,className:n,children:[l(),a?null:o.jsx("span",{"aria-hidden":!0,className:p[`${g}__separator`],children:"/"})]})};O.Item=J;exports.BREADCRUMB_VARIANT=I;exports.Breadcrumbs=O;exports.breadcrumbVariants=k;
9
+ */(function(e){(function(){var u={}.hasOwnProperty;function s(){for(var r="",t=0;t<arguments.length;t++){var n=arguments[t];n&&(r=c(r,a(n)))}return r}function a(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return s.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var t="";for(var n in r)u.call(r,n)&&r[n]&&(t=c(t,n));return t}function c(r,t){return t?r?r+" "+t:r+t:r}e.exports?(s.default=s,e.exports=s):window.classNames=s})()})(S);var z=S.exports;const $=Z(z),p={"purpur-breadcrumbs":"_purpur-breadcrumbs_11sb5_1","purpur-breadcrumbs--default":"_purpur-breadcrumbs--default_11sb5_18","purpur-breadcrumbs--negative":"_purpur-breadcrumbs--negative_11sb5_32","purpur-breadcrumbs__list":"_purpur-breadcrumbs__list_11sb5_46","purpur-breadcrumbs__home":"_purpur-breadcrumbs__home_11sb5_54","purpur-breadcrumb-item":"_purpur-breadcrumb-item_11sb5_64","purpur-breadcrumb-item--current":"_purpur-breadcrumb-item--current_11sb5_67","purpur-breadcrumb-item--negative":"_purpur-breadcrumb-item--negative_11sb5_87","purpur-breadcrumb-item__separator":"_purpur-breadcrumb-item__separator_11sb5_90"},F=(e,u,s)=>({"@type":"ListItem",position:s,name:e,item:u}),U=e=>JSON.stringify({"@context":"https://schema.org","@type":"BreadcrumbList",itemListElement:e}),I={DEFAULT:"default",NEGATIVE:"negative"},k=Object.values(I),v="purpur-breadcrumbs",g="purpur-breadcrumb-item",O=({["data-testid"]:e,ariaLabel:u,children:s,className:a,meta:c=!0,variant:r="default"})=>{const t=$([a,p[v],p[`${v}--${r}`]]),n=m.Children.count(s),l=[],d=m.Children.map(s,(_,A)=>{const x=A+1,E=n===x,b=_.props.children,o=typeof b=="string"?null:b.props;let f=null,h=null;return typeof b=="string"?(f=b,h=_.props.href):o!=null&&o.children&&typeof(o==null?void 0:o.children)=="string"&&(f=o.children,h=o.href),f&&h&&l.push(F(f,h,x)),m.cloneElement(_,{current:E,variant:r,...x===1&&{children:i.jsxs(i.Fragment,{children:[i.jsx("span",{className:p[`${v}__home`],"aria-hidden":"true",children:i.jsx(N,{size:"xs"})}),_.props.children]})}})}),y=l.length===n?U(l):null;return i.jsxs("nav",{"data-testid":e,"aria-label":u||"Breadcrumb",className:t,children:[i.jsx("ol",{className:p[`${v}__list`],children:d}),c&&y?i.jsx("script",{type:"application/ld+json","data-testid":"breadcrumbs-meta",dangerouslySetInnerHTML:{__html:y}}):null]})},J=({href:e,["data-testid"]:u,children:s,current:a=!1,variant:c="default",onClick:r,...t})=>{const n=$([p[g],p[`${g}--${c}`]],{[p[`${g}--current`]]:a}),l=()=>{const d={href:e,"data-testid":u,"aria-current":a?"page":void 0,onClick:r};return e||typeof s=="string"?m.createElement("a",d,s):m.cloneElement(s,{...d,...s.props})};return i.jsxs("li",{...t,className:n,children:[l(),a?null:i.jsx("span",{"aria-hidden":!0,className:p[`${g}__separator`],children:"/"})]})};O.Item=J;exports.BREADCRUMB_VARIANT=I;exports.Breadcrumbs=O;exports.breadcrumbVariants=k;
10
10
  //# sourceMappingURL=breadcrumbs.cjs.js.map
@@ -1,7 +1,7 @@
1
1
  import { jsx as p, jsxs as x, Fragment as M } from "react/jsx-runtime";
2
2
  import { Children as w, cloneElement as $, createElement as L } from "react";
3
- function q(t) {
4
- return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
3
+ function q(e) {
4
+ return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
5
5
  }
6
6
  var S = { exports: {} };
7
7
  /*!
@@ -9,13 +9,13 @@ var S = { exports: {} };
9
9
  Licensed under the MIT License (MIT), see
10
10
  http://jedwatson.github.io/classnames
11
11
  */
12
- (function(t) {
12
+ (function(e) {
13
13
  (function() {
14
- var s = {}.hasOwnProperty;
15
- function n() {
16
- for (var r = "", e = 0; e < arguments.length; e++) {
17
- var u = arguments[e];
18
- u && (r = i(r, a.call(this, u)));
14
+ var u = {}.hasOwnProperty;
15
+ function s() {
16
+ for (var r = "", t = 0; t < arguments.length; t++) {
17
+ var n = arguments[t];
18
+ n && (r = i(r, a.call(this, n)));
19
19
  }
20
20
  return r;
21
21
  }
@@ -25,18 +25,18 @@ var S = { exports: {} };
25
25
  if (typeof r != "object")
26
26
  return "";
27
27
  if (Array.isArray(r))
28
- return n.apply(this, r);
28
+ return s.apply(this, r);
29
29
  if (r.toString !== Object.prototype.toString && !r.toString.toString().includes("[native code]"))
30
30
  return r.toString();
31
- var e = "";
32
- for (var u in r)
33
- s.call(r, u) && r[u] && (e = i(e, this && this[u] || u));
34
- return e;
31
+ var t = "";
32
+ for (var n in r)
33
+ u.call(r, n) && r[n] && (t = i(t, this && this[n] || n));
34
+ return t;
35
35
  }
36
- function i(r, e) {
37
- return e ? r ? r + " " + e : r + e : r;
36
+ function i(r, t) {
37
+ return t ? r ? r + " " + t : r + t : r;
38
38
  }
39
- t.exports ? (n.default = n, t.exports = n) : window.classNames = n;
39
+ e.exports ? (s.default = s, e.exports = s) : window.classNames = s;
40
40
  })();
41
41
  })(S);
42
42
  var B = S.exports;
@@ -53,47 +53,47 @@ const H = /* @__PURE__ */ q(B), T = {
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
- }, j = (t) => /* @__PURE__ */ p(
56
+ }, j = (e) => /* @__PURE__ */ p(
57
57
  z,
58
58
  {
59
- ...t,
59
+ ...e,
60
60
  svg: P
61
61
  }
62
62
  );
63
63
  j.displayName = "IconHome";
64
- const V = H.bind(T), N = "purpur-icon", C = "md", D = (t) => t.filter((s) => Object.keys(s).length >= 1).map((s) => `${s.name}="${s.value}"`).join(" "), R = ({ content: t = "", title: s } = {}) => {
65
- const n = [
64
+ const V = H.bind(T), N = "purpur-icon", C = "md", D = (e) => e.filter((u) => Object.keys(u).length >= 1).map((u) => `${u.name}="${u.value}"`).join(" "), R = ({ content: e = "", title: u } = {}) => {
65
+ const s = [
66
66
  { name: "xmlns", value: "http://www.w3.org/2000/svg" },
67
67
  { name: "fill", value: "currentColor" },
68
68
  { name: "viewBox", value: "0 0 24 24" },
69
- s ? { name: "role", value: "img" } : { name: "aria-hidden", value: "true" }
70
- ], a = s ? `<title>${s}</title>` : "";
71
- return `<svg ${D(n)}>${a}${t}</svg>`;
72
- }, Z = (t) => t.replace(/<(\/?)svg([^>]*)>/g, "").trim(), z = ({
73
- ["data-testid"]: t,
74
- svg: s,
75
- allyTitle: n,
69
+ u ? { name: "role", value: "img" } : { name: "aria-hidden", value: "true" }
70
+ ], a = u ? `<title>${u}</title>` : "";
71
+ return `<svg ${D(s)}>${a}${e}</svg>`;
72
+ }, Z = (e) => e.replace(/<(\/?)svg([^>]*)>/g, "").trim(), z = ({
73
+ ["data-testid"]: e,
74
+ svg: u,
75
+ allyTitle: s,
76
76
  className: a = "",
77
77
  size: i = C,
78
78
  ...r
79
79
  }) => {
80
- const e = R({
81
- content: Z(s.svg),
82
- title: n
83
- }), u = V(a, N, `${N}--${i}`);
80
+ const t = R({
81
+ content: Z(u.svg),
82
+ title: s
83
+ }), n = V(a, N, `${N}--${i}`);
84
84
  return /* @__PURE__ */ p(
85
85
  "span",
86
86
  {
87
- "aria-label": n,
88
- className: u,
89
- "data-testid": t,
90
- dangerouslySetInnerHTML: { __html: e },
87
+ "aria-label": s,
88
+ className: n,
89
+ "data-testid": e,
90
+ dangerouslySetInnerHTML: { __html: t },
91
91
  ...r
92
92
  }
93
93
  );
94
94
  };
95
- function F(t) {
96
- return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
95
+ function F(e) {
96
+ return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
97
97
  }
98
98
  var I = { exports: {} };
99
99
  /*!
@@ -101,13 +101,13 @@ var I = { exports: {} };
101
101
  Licensed under the MIT License (MIT), see
102
102
  http://jedwatson.github.io/classnames
103
103
  */
104
- (function(t) {
104
+ (function(e) {
105
105
  (function() {
106
- var s = {}.hasOwnProperty;
107
- function n() {
108
- for (var r = "", e = 0; e < arguments.length; e++) {
109
- var u = arguments[e];
110
- u && (r = i(r, a(u)));
106
+ var u = {}.hasOwnProperty;
107
+ function s() {
108
+ for (var r = "", t = 0; t < arguments.length; t++) {
109
+ var n = arguments[t];
110
+ n && (r = i(r, a(n)));
111
111
  }
112
112
  return r;
113
113
  }
@@ -117,67 +117,67 @@ var I = { exports: {} };
117
117
  if (typeof r != "object")
118
118
  return "";
119
119
  if (Array.isArray(r))
120
- return n.apply(null, r);
120
+ return s.apply(null, r);
121
121
  if (r.toString !== Object.prototype.toString && !r.toString.toString().includes("[native code]"))
122
122
  return r.toString();
123
- var e = "";
124
- for (var u in r)
125
- s.call(r, u) && r[u] && (e = i(e, u));
126
- return e;
123
+ var t = "";
124
+ for (var n in r)
125
+ u.call(r, n) && r[n] && (t = i(t, n));
126
+ return t;
127
127
  }
128
- function i(r, e) {
129
- return e ? r ? r + " " + e : r + e : r;
128
+ function i(r, t) {
129
+ return t ? r ? r + " " + t : r + t : r;
130
130
  }
131
- t.exports ? (n.default = n, t.exports = n) : window.classNames = n;
131
+ e.exports ? (s.default = s, e.exports = s) : window.classNames = s;
132
132
  })();
133
133
  })(I);
134
134
  var k = I.exports;
135
- const O = /* @__PURE__ */ F(k), c = {
136
- "purpur-breadcrumbs": "_purpur-breadcrumbs_1oiut_1",
137
- "purpur-breadcrumbs--default": "_purpur-breadcrumbs--default_1oiut_18",
138
- "purpur-breadcrumbs--negative": "_purpur-breadcrumbs--negative_1oiut_32",
139
- "purpur-breadcrumbs__list": "_purpur-breadcrumbs__list_1oiut_46",
140
- "purpur-breadcrumbs__home": "_purpur-breadcrumbs__home_1oiut_54",
141
- "purpur-breadcrumb-item": "_purpur-breadcrumb-item_1oiut_64",
142
- "purpur-breadcrumb-item--current": "_purpur-breadcrumb-item--current_1oiut_67",
143
- "purpur-breadcrumb-item--negative": "_purpur-breadcrumb-item--negative_1oiut_87",
144
- "purpur-breadcrumb-item__separator": "_purpur-breadcrumb-item__separator_1oiut_90"
145
- }, U = (t, s, n) => ({
135
+ const O = /* @__PURE__ */ F(k), o = {
136
+ "purpur-breadcrumbs": "_purpur-breadcrumbs_11sb5_1",
137
+ "purpur-breadcrumbs--default": "_purpur-breadcrumbs--default_11sb5_18",
138
+ "purpur-breadcrumbs--negative": "_purpur-breadcrumbs--negative_11sb5_32",
139
+ "purpur-breadcrumbs__list": "_purpur-breadcrumbs__list_11sb5_46",
140
+ "purpur-breadcrumbs__home": "_purpur-breadcrumbs__home_11sb5_54",
141
+ "purpur-breadcrumb-item": "_purpur-breadcrumb-item_11sb5_64",
142
+ "purpur-breadcrumb-item--current": "_purpur-breadcrumb-item--current_11sb5_67",
143
+ "purpur-breadcrumb-item--negative": "_purpur-breadcrumb-item--negative_11sb5_87",
144
+ "purpur-breadcrumb-item__separator": "_purpur-breadcrumb-item__separator_11sb5_90"
145
+ }, U = (e, u, s) => ({
146
146
  "@type": "ListItem",
147
- position: n,
148
- name: t,
149
- item: s
150
- }), J = (t) => JSON.stringify({
147
+ position: s,
148
+ name: e,
149
+ item: u
150
+ }), J = (e) => JSON.stringify({
151
151
  "@context": "https://schema.org",
152
152
  "@type": "BreadcrumbList",
153
- itemListElement: t
153
+ itemListElement: e
154
154
  }), K = {
155
155
  DEFAULT: "default",
156
156
  NEGATIVE: "negative"
157
157
  }, rr = Object.values(K), h = "purpur-breadcrumbs", v = "purpur-breadcrumb-item", Q = ({
158
- ["data-testid"]: t,
159
- ariaLabel: s,
160
- children: n,
158
+ ["data-testid"]: e,
159
+ ariaLabel: u,
160
+ children: s,
161
161
  className: a,
162
162
  meta: i = !0,
163
163
  variant: r = "default"
164
164
  }) => {
165
- const e = O([a, c[h], c[`${h}--${r}`]]), u = w.count(n), l = [], m = w.map(n, (d, E) => {
166
- const y = E + 1, A = u === y, _ = d.props.children, o = typeof _ == "string" ? null : _.props;
167
- let f = null, b = null;
168
- return typeof _ == "string" ? (f = _, b = d.props.href) : o != null && o.children && typeof (o == null ? void 0 : o.children) == "string" && (f = o.children, b = o.href), f && b && l.push(U(f, b, y)), $(d, {
165
+ const t = O([a, o[h], o[`${h}--${r}`]]), n = w.count(s), l = [], m = w.map(s, (d, E) => {
166
+ const y = E + 1, A = n === y, _ = d.props.children, c = typeof _ == "string" ? null : _.props;
167
+ let b = null, f = null;
168
+ return typeof _ == "string" ? (b = _, f = d.props.href) : c != null && c.children && typeof (c == null ? void 0 : c.children) == "string" && (b = c.children, f = c.href), b && f && l.push(U(b, f, y)), $(d, {
169
169
  current: A,
170
170
  variant: r,
171
171
  ...y === 1 && {
172
172
  children: /* @__PURE__ */ x(M, { children: [
173
- /* @__PURE__ */ p("span", { className: c[`${h}__home`], "aria-hidden": "true", children: /* @__PURE__ */ p(j, { size: "xs" }) }),
173
+ /* @__PURE__ */ p("span", { className: o[`${h}__home`], "aria-hidden": "true", children: /* @__PURE__ */ p(j, { size: "xs" }) }),
174
174
  d.props.children
175
175
  ] })
176
176
  }
177
177
  });
178
- }), g = l.length === u ? J(l) : null;
179
- return /* @__PURE__ */ x("nav", { "data-testid": t, "aria-label": s || "Breadcrumb", className: e, children: [
180
- /* @__PURE__ */ p("ol", { className: c[`${h}__list`], children: m }),
178
+ }), g = l.length === n ? J(l) : null;
179
+ return /* @__PURE__ */ x("nav", { "data-testid": e, "aria-label": u || "Breadcrumb", className: t, children: [
180
+ /* @__PURE__ */ p("ol", { className: o[`${h}__list`], children: m }),
181
181
  i && g ? /* @__PURE__ */ p(
182
182
  "script",
183
183
  {
@@ -188,31 +188,31 @@ const O = /* @__PURE__ */ F(k), c = {
188
188
  ) : null
189
189
  ] });
190
190
  }, W = ({
191
- href: t,
192
- ["data-testid"]: s,
193
- children: n,
191
+ href: e,
192
+ ["data-testid"]: u,
193
+ children: s,
194
194
  current: a = !1,
195
195
  variant: i = "default",
196
196
  onClick: r,
197
- ...e
197
+ ...t
198
198
  }) => {
199
- const u = O([c[v], c[`${v}--${i}`]], {
200
- [c[`${v}--current`]]: a
199
+ const n = O([o[v], o[`${v}--${i}`]], {
200
+ [o[`${v}--current`]]: a
201
201
  });
202
- return /* @__PURE__ */ x("li", { ...e, className: u, children: [
202
+ return /* @__PURE__ */ x("li", { ...t, className: n, children: [
203
203
  (() => {
204
204
  const m = {
205
- href: t,
206
- "data-testid": s,
205
+ href: e,
206
+ "data-testid": u,
207
207
  "aria-current": a ? "page" : void 0,
208
208
  onClick: r
209
209
  };
210
- return t || typeof n == "string" ? L("a", m, n) : $(n, {
210
+ return e || typeof s == "string" ? L("a", m, s) : $(s, {
211
211
  ...m,
212
- ...n.props
212
+ ...s.props
213
213
  });
214
214
  })(),
215
- a ? null : /* @__PURE__ */ p("span", { "aria-hidden": !0, className: c[`${v}__separator`], children: "/" })
215
+ a ? null : /* @__PURE__ */ p("span", { "aria-hidden": !0, className: o[`${v}__separator`], children: "/" })
216
216
  ] });
217
217
  };
218
218
  Q.Item = W;