@aseguragonzalez/ui 1.1.0 → 1.2.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 +1 @@
1
- const e=require("./Breadcrumb.module.css.cjs");let t=require("react"),n=require("react/jsx-runtime");var r=(0,t.forwardRef)(({items:t,"aria-label":r=`Breadcrumb`,className:i},a)=>(0,n.jsx)(`nav`,{ref:a,"aria-label":r,className:[e.default.nav,i??``].filter(Boolean).join(` `),children:(0,n.jsx)(`ol`,{className:e.default.list,children:t.map((r,i)=>{let a=i===t.length-1;return(0,n.jsx)(`li`,{className:e.default.item,children:a?(0,n.jsx)(`span`,{className:e.default.current,"aria-current":`page`,children:r.label}):r.href?(0,n.jsx)(`a`,{href:r.href,className:e.default.link,children:r.label}):(0,n.jsx)(`span`,{className:e.default.link,children:r.label})},`${r.label}-${i}`)})})}));r.displayName=`Breadcrumb`,exports.Breadcrumb=r;
1
+ const e=require("./Breadcrumb.module.css.cjs"),t=require("../shared/ItemLink.cjs");let n=require("react"),r=require("react/jsx-runtime");var i=(0,n.forwardRef)(({items:n,"aria-label":i=`Breadcrumb`,linkComponent:a,className:o},s)=>(0,r.jsx)(`nav`,{ref:s,"aria-label":i,className:[e.default.nav,o??``].filter(Boolean).join(` `),children:(0,r.jsx)(`ol`,{className:e.default.list,children:n.map((i,o)=>{let s=o===n.length-1;return(0,r.jsx)(`li`,{className:e.default.item,children:s?(0,r.jsx)(`span`,{className:e.default.current,"aria-current":`page`,children:i.label}):i.href?(0,r.jsx)(t.ItemLink,{linkComponent:a,href:i.href,className:e.default.link,children:i.label}):(0,r.jsx)(`span`,{className:e.default.link,children:i.label})},`${i.label}-${o}`)})})}));i.displayName=`Breadcrumb`,exports.Breadcrumb=i;
@@ -1,3 +1,4 @@
1
+ import type { LinkComponent } from '../shared/LinkComponent';
1
2
  export interface BreadcrumbItem {
2
3
  label: string;
3
4
  href?: string;
@@ -5,6 +6,11 @@ export interface BreadcrumbItem {
5
6
  export interface BreadcrumbProps {
6
7
  items: BreadcrumbItem[];
7
8
  'aria-label'?: string;
9
+ /**
10
+ * Component rendered for ancestor items with an `href` instead of a plain `<a>`, such as an adapter over the
11
+ * router's link, so navigation happens without a full page load. Defaults to `<a>`.
12
+ */
13
+ linkComponent?: LinkComponent;
8
14
  className?: string;
9
15
  }
10
16
  declare const Breadcrumb: import("react").ForwardRefExoticComponent<BreadcrumbProps & import("react").RefAttributes<HTMLElement>>;
@@ -1,33 +1,35 @@
1
1
  import e from "./Breadcrumb.module.css.js";
2
- import { forwardRef as t } from "react";
3
- import { jsx as n } from "react/jsx-runtime";
2
+ import { ItemLink as t } from "../shared/ItemLink.js";
3
+ import { forwardRef as n } from "react";
4
+ import { jsx as r } from "react/jsx-runtime";
4
5
  //#region src/components/Breadcrumb/Breadcrumb.tsx
5
- var r = t(({ items: t, "aria-label": r = "Breadcrumb", className: i }, a) => /* @__PURE__ */ n("nav", {
6
- ref: a,
7
- "aria-label": r,
8
- className: [e.nav, i ?? ""].filter(Boolean).join(" "),
9
- children: /* @__PURE__ */ n("ol", {
6
+ var i = n(({ items: n, "aria-label": i = "Breadcrumb", linkComponent: a, className: o }, s) => /* @__PURE__ */ r("nav", {
7
+ ref: s,
8
+ "aria-label": i,
9
+ className: [e.nav, o ?? ""].filter(Boolean).join(" "),
10
+ children: /* @__PURE__ */ r("ol", {
10
11
  className: e.list,
11
- children: t.map((r, i) => {
12
- let a = i === t.length - 1;
13
- return /* @__PURE__ */ n("li", {
12
+ children: n.map((i, o) => {
13
+ let s = o === n.length - 1;
14
+ return /* @__PURE__ */ r("li", {
14
15
  className: e.item,
15
- children: a ? /* @__PURE__ */ n("span", {
16
+ children: s ? /* @__PURE__ */ r("span", {
16
17
  className: e.current,
17
18
  "aria-current": "page",
18
- children: r.label
19
- }) : r.href ? /* @__PURE__ */ n("a", {
20
- href: r.href,
19
+ children: i.label
20
+ }) : i.href ? /* @__PURE__ */ r(t, {
21
+ linkComponent: a,
22
+ href: i.href,
21
23
  className: e.link,
22
- children: r.label
23
- }) : /* @__PURE__ */ n("span", {
24
+ children: i.label
25
+ }) : /* @__PURE__ */ r("span", {
24
26
  className: e.link,
25
- children: r.label
27
+ children: i.label
26
28
  })
27
- }, `${r.label}-${i}`);
29
+ }, `${i.label}-${o}`);
28
30
  })
29
31
  })
30
32
  }));
31
- r.displayName = "Breadcrumb";
33
+ i.displayName = "Breadcrumb";
32
34
  //#endregion
33
- export { r as Breadcrumb };
35
+ export { i as Breadcrumb };
@@ -1 +1 @@
1
- const e=require("./Navbar.module.css.cjs");let t=require("react"),n=require("react/jsx-runtime");var r=()=>(0,n.jsx)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 20 20`,fill:`currentColor`,"aria-hidden":`true`,children:(0,n.jsx)(`path`,{fillRule:`evenodd`,d:`M2 4.75A.75.75 0 0 1 2.75 4h14.5a.75.75 0 0 1 0 1.5H2.75A.75.75 0 0 1 2 4.75ZM2 10a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75A.75.75 0 0 1 2 10Zm0 5.25a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75a.75.75 0 0 1-.75-.75Z`,clipRule:`evenodd`})}),i=()=>(0,n.jsx)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 20 20`,fill:`currentColor`,"aria-hidden":`true`,children:(0,n.jsx)(`path`,{d:`M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z`})}),a=(0,t.forwardRef)(({brand:a,items:o=[],actions:s,sticky:c=!1,"aria-label":l=`Main navigation`,defaultMobileOpen:u=!1,isMobileOpen:d,onMobileOpenChange:f,className:p},m)=>{let[h,g]=(0,t.useState)(u),_=d??h,v=(0,t.useId)(),y=()=>{let e=!_;d===void 0&&g(e),f?.(e)},b=()=>{d===void 0&&g(!1),f?.(!1)},x=[e.default.navbar,c?e.default.sticky:``,p??``].filter(Boolean).join(` `);return(0,n.jsxs)(`header`,{ref:m,className:x,children:[(0,n.jsxs)(`div`,{className:e.default.inner,children:[a&&(0,n.jsx)(`div`,{className:e.default.brand,children:a}),o.length>0&&(0,n.jsx)(`nav`,{className:e.default.nav,"aria-label":l,children:(0,n.jsx)(`ul`,{className:e.default.navList,children:o.map(t=>(0,n.jsx)(`li`,{className:e.default.navItem,children:(0,n.jsx)(`a`,{href:t.href,onClick:t.onClick,className:[e.default.navLink,t.isActive?e.default.navLinkActive:``].filter(Boolean).join(` `),"aria-current":t.isActive?`page`:void 0,children:t.label})},t.key))})}),s&&(0,n.jsx)(`div`,{className:e.default.actions,children:s}),(0,n.jsx)(`button`,{type:`button`,className:e.default.menuButton,onClick:y,"aria-expanded":_,"aria-controls":v,"aria-label":_?`Close menu`:`Open menu`,children:_?(0,n.jsx)(i,{}):(0,n.jsx)(r,{})})]}),(0,n.jsx)(`div`,{id:v,className:[e.default.mobileMenu,_?e.default.mobileMenuOpen:``].filter(Boolean).join(` `),children:(0,n.jsx)(`nav`,{"aria-label":`${l} — menu`,children:(0,n.jsx)(`ul`,{className:e.default.mobileNavList,children:o.map(t=>(0,n.jsx)(`li`,{className:e.default.mobileNavItem,children:(0,n.jsx)(`a`,{href:t.href,onClick:()=>{t.onClick?.(),b()},className:[e.default.mobileNavLink,t.isActive?e.default.mobileNavLinkActive:``].filter(Boolean).join(` `),"aria-current":t.isActive?`page`:void 0,children:t.label})},t.key))})})})]})});a.displayName=`Navbar`,exports.Navbar=a;
1
+ const e=require("../shared/ItemLink.cjs"),t=require("./Navbar.module.css.cjs");let n=require("react"),r=require("react/jsx-runtime");var i=()=>(0,r.jsx)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 20 20`,fill:`currentColor`,"aria-hidden":`true`,children:(0,r.jsx)(`path`,{fillRule:`evenodd`,d:`M2 4.75A.75.75 0 0 1 2.75 4h14.5a.75.75 0 0 1 0 1.5H2.75A.75.75 0 0 1 2 4.75ZM2 10a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75A.75.75 0 0 1 2 10Zm0 5.25a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75a.75.75 0 0 1-.75-.75Z`,clipRule:`evenodd`})}),a=()=>(0,r.jsx)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 20 20`,fill:`currentColor`,"aria-hidden":`true`,children:(0,r.jsx)(`path`,{d:`M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z`})}),o=(0,n.forwardRef)(({brand:o,items:s=[],actions:c,sticky:l=!1,"aria-label":u=`Main navigation`,linkComponent:d,defaultMobileOpen:f=!1,isMobileOpen:p,onMobileOpenChange:m,className:h},g)=>{let[_,v]=(0,n.useState)(f),y=p??_,b=(0,n.useId)(),x=()=>{let e=!y;p===void 0&&v(e),m?.(e)},S=()=>{p===void 0&&v(!1),m?.(!1)},C=[t.default.navbar,l?t.default.sticky:``,h??``].filter(Boolean).join(` `);return(0,r.jsxs)(`header`,{ref:g,className:C,children:[(0,r.jsxs)(`div`,{className:t.default.inner,children:[o&&(0,r.jsx)(`div`,{className:t.default.brand,children:o}),s.length>0&&(0,r.jsx)(`nav`,{className:t.default.nav,"aria-label":u,children:(0,r.jsx)(`ul`,{className:t.default.navList,children:s.map(n=>(0,r.jsx)(`li`,{className:t.default.navItem,children:(0,r.jsx)(e.ItemLink,{linkComponent:d,href:n.href,onClick:n.onClick,className:[t.default.navLink,n.isActive?t.default.navLinkActive:``].filter(Boolean).join(` `),"aria-current":n.isActive?`page`:void 0,children:n.label})},n.key))})}),c&&(0,r.jsx)(`div`,{className:t.default.actions,children:c}),(0,r.jsx)(`button`,{type:`button`,className:t.default.menuButton,onClick:x,"aria-expanded":y,"aria-controls":b,"aria-label":y?`Close menu`:`Open menu`,children:y?(0,r.jsx)(a,{}):(0,r.jsx)(i,{})})]}),(0,r.jsx)(`div`,{id:b,className:[t.default.mobileMenu,y?t.default.mobileMenuOpen:``].filter(Boolean).join(` `),children:(0,r.jsx)(`nav`,{"aria-label":`${u} — menu`,children:(0,r.jsx)(`ul`,{className:t.default.mobileNavList,children:s.map(n=>(0,r.jsx)(`li`,{className:t.default.mobileNavItem,children:(0,r.jsx)(e.ItemLink,{linkComponent:d,href:n.href,onClick:()=>{n.onClick?.(),S()},className:[t.default.mobileNavLink,n.isActive?t.default.mobileNavLinkActive:``].filter(Boolean).join(` `),"aria-current":n.isActive?`page`:void 0,children:n.label})},n.key))})})})]})});o.displayName=`Navbar`,exports.Navbar=o;
@@ -1,3 +1,4 @@
1
+ import type { LinkComponent } from '../shared/LinkComponent';
1
2
  export interface NavItem {
2
3
  key: string;
3
4
  label: string;
@@ -11,6 +12,11 @@ export interface NavbarProps {
11
12
  actions?: React.ReactNode;
12
13
  sticky?: boolean;
13
14
  'aria-label'?: string;
15
+ /**
16
+ * Component rendered for items with an `href` instead of a plain `<a>`, such as an adapter over the
17
+ * router's link, so navigation happens without a full page load. Defaults to `<a>`.
18
+ */
19
+ linkComponent?: LinkComponent;
14
20
  defaultMobileOpen?: boolean;
15
21
  isMobileOpen?: boolean;
16
22
  onMobileOpenChange?: (open: boolean) => void;
@@ -1,101 +1,104 @@
1
- import e from "./Navbar.module.css.js";
2
- import { forwardRef as t, useId as n, useState as r } from "react";
3
- import { jsx as i, jsxs as a } from "react/jsx-runtime";
1
+ import { ItemLink as e } from "../shared/ItemLink.js";
2
+ import t from "./Navbar.module.css.js";
3
+ import { forwardRef as n, useId as r, useState as i } from "react";
4
+ import { jsx as a, jsxs as o } from "react/jsx-runtime";
4
5
  //#region src/components/Navbar/Navbar.tsx
5
- var o = () => /* @__PURE__ */ i("svg", {
6
+ var s = () => /* @__PURE__ */ a("svg", {
6
7
  width: "20",
7
8
  height: "20",
8
9
  viewBox: "0 0 20 20",
9
10
  fill: "currentColor",
10
11
  "aria-hidden": "true",
11
- children: /* @__PURE__ */ i("path", {
12
+ children: /* @__PURE__ */ a("path", {
12
13
  fillRule: "evenodd",
13
14
  d: "M2 4.75A.75.75 0 0 1 2.75 4h14.5a.75.75 0 0 1 0 1.5H2.75A.75.75 0 0 1 2 4.75ZM2 10a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75A.75.75 0 0 1 2 10Zm0 5.25a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75a.75.75 0 0 1-.75-.75Z",
14
15
  clipRule: "evenodd"
15
16
  })
16
- }), s = () => /* @__PURE__ */ i("svg", {
17
+ }), c = () => /* @__PURE__ */ a("svg", {
17
18
  width: "20",
18
19
  height: "20",
19
20
  viewBox: "0 0 20 20",
20
21
  fill: "currentColor",
21
22
  "aria-hidden": "true",
22
- children: /* @__PURE__ */ i("path", { d: "M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z" })
23
- }), c = t(({ brand: t, items: c = [], actions: l, sticky: u = !1, "aria-label": d = "Main navigation", defaultMobileOpen: f = !1, isMobileOpen: p, onMobileOpenChange: m, className: h }, g) => {
24
- let [_, v] = r(f), y = p ?? _, b = n(), x = () => {
25
- let e = !y;
26
- p === void 0 && v(e), m?.(e);
27
- }, S = () => {
28
- p === void 0 && v(!1), m?.(!1);
29
- }, C = [
30
- e.navbar,
31
- u ? e.sticky : "",
32
- h ?? ""
23
+ children: /* @__PURE__ */ a("path", { d: "M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z" })
24
+ }), l = n(({ brand: n, items: l = [], actions: u, sticky: d = !1, "aria-label": f = "Main navigation", linkComponent: p, defaultMobileOpen: m = !1, isMobileOpen: h, onMobileOpenChange: g, className: _ }, v) => {
25
+ let [y, b] = i(m), x = h ?? y, S = r(), C = () => {
26
+ let e = !x;
27
+ h === void 0 && b(e), g?.(e);
28
+ }, w = () => {
29
+ h === void 0 && b(!1), g?.(!1);
30
+ }, T = [
31
+ t.navbar,
32
+ d ? t.sticky : "",
33
+ _ ?? ""
33
34
  ].filter(Boolean).join(" ");
34
- return /* @__PURE__ */ a("header", {
35
- ref: g,
36
- className: C,
37
- children: [/* @__PURE__ */ a("div", {
38
- className: e.inner,
35
+ return /* @__PURE__ */ o("header", {
36
+ ref: v,
37
+ className: T,
38
+ children: [/* @__PURE__ */ o("div", {
39
+ className: t.inner,
39
40
  children: [
40
- t && /* @__PURE__ */ i("div", {
41
- className: e.brand,
42
- children: t
41
+ n && /* @__PURE__ */ a("div", {
42
+ className: t.brand,
43
+ children: n
43
44
  }),
44
- c.length > 0 && /* @__PURE__ */ i("nav", {
45
- className: e.nav,
46
- "aria-label": d,
47
- children: /* @__PURE__ */ i("ul", {
48
- className: e.navList,
49
- children: c.map((t) => /* @__PURE__ */ i("li", {
50
- className: e.navItem,
51
- children: /* @__PURE__ */ i("a", {
52
- href: t.href,
53
- onClick: t.onClick,
54
- className: [e.navLink, t.isActive ? e.navLinkActive : ""].filter(Boolean).join(" "),
55
- "aria-current": t.isActive ? "page" : void 0,
56
- children: t.label
45
+ l.length > 0 && /* @__PURE__ */ a("nav", {
46
+ className: t.nav,
47
+ "aria-label": f,
48
+ children: /* @__PURE__ */ a("ul", {
49
+ className: t.navList,
50
+ children: l.map((n) => /* @__PURE__ */ a("li", {
51
+ className: t.navItem,
52
+ children: /* @__PURE__ */ a(e, {
53
+ linkComponent: p,
54
+ href: n.href,
55
+ onClick: n.onClick,
56
+ className: [t.navLink, n.isActive ? t.navLinkActive : ""].filter(Boolean).join(" "),
57
+ "aria-current": n.isActive ? "page" : void 0,
58
+ children: n.label
57
59
  })
58
- }, t.key))
60
+ }, n.key))
59
61
  })
60
62
  }),
61
- l && /* @__PURE__ */ i("div", {
62
- className: e.actions,
63
- children: l
63
+ u && /* @__PURE__ */ a("div", {
64
+ className: t.actions,
65
+ children: u
64
66
  }),
65
- /* @__PURE__ */ i("button", {
67
+ /* @__PURE__ */ a("button", {
66
68
  type: "button",
67
- className: e.menuButton,
68
- onClick: x,
69
- "aria-expanded": y,
70
- "aria-controls": b,
71
- "aria-label": y ? "Close menu" : "Open menu",
72
- children: i(y ? s : o, {})
69
+ className: t.menuButton,
70
+ onClick: C,
71
+ "aria-expanded": x,
72
+ "aria-controls": S,
73
+ "aria-label": x ? "Close menu" : "Open menu",
74
+ children: a(x ? c : s, {})
73
75
  })
74
76
  ]
75
- }), /* @__PURE__ */ i("div", {
76
- id: b,
77
- className: [e.mobileMenu, y ? e.mobileMenuOpen : ""].filter(Boolean).join(" "),
78
- children: /* @__PURE__ */ i("nav", {
79
- "aria-label": `${d} — menu`,
80
- children: /* @__PURE__ */ i("ul", {
81
- className: e.mobileNavList,
82
- children: c.map((t) => /* @__PURE__ */ i("li", {
83
- className: e.mobileNavItem,
84
- children: /* @__PURE__ */ i("a", {
85
- href: t.href,
77
+ }), /* @__PURE__ */ a("div", {
78
+ id: S,
79
+ className: [t.mobileMenu, x ? t.mobileMenuOpen : ""].filter(Boolean).join(" "),
80
+ children: /* @__PURE__ */ a("nav", {
81
+ "aria-label": `${f} — menu`,
82
+ children: /* @__PURE__ */ a("ul", {
83
+ className: t.mobileNavList,
84
+ children: l.map((n) => /* @__PURE__ */ a("li", {
85
+ className: t.mobileNavItem,
86
+ children: /* @__PURE__ */ a(e, {
87
+ linkComponent: p,
88
+ href: n.href,
86
89
  onClick: () => {
87
- t.onClick?.(), S();
90
+ n.onClick?.(), w();
88
91
  },
89
- className: [e.mobileNavLink, t.isActive ? e.mobileNavLinkActive : ""].filter(Boolean).join(" "),
90
- "aria-current": t.isActive ? "page" : void 0,
91
- children: t.label
92
+ className: [t.mobileNavLink, n.isActive ? t.mobileNavLinkActive : ""].filter(Boolean).join(" "),
93
+ "aria-current": n.isActive ? "page" : void 0,
94
+ children: n.label
92
95
  })
93
- }, t.key))
96
+ }, n.key))
94
97
  })
95
98
  })
96
99
  })]
97
100
  });
98
101
  });
99
- c.displayName = "Navbar";
102
+ l.displayName = "Navbar";
100
103
  //#endregion
101
- export { c as Navbar };
104
+ export { l as Navbar };
@@ -1 +1 @@
1
- const e=require("./Sidebar.module.css.cjs");let t=require("react"),n=require("react/jsx-runtime"),r=require("react-dom");var i=`a[href], button:not([disabled]), input:not([disabled]), [tabindex]:not([tabindex="-1"])`,a=()=>(0,n.jsx)(`svg`,{width:`16`,height:`16`,viewBox:`0 0 16 16`,fill:`none`,"aria-hidden":`true`,children:(0,n.jsx)(`path`,{d:`M10 4L6 8L10 12`,stroke:`currentColor`,strokeWidth:`1.5`,strokeLinecap:`round`,strokeLinejoin:`round`})}),o=()=>(0,n.jsx)(`svg`,{width:`16`,height:`16`,viewBox:`0 0 16 16`,fill:`none`,"aria-hidden":`true`,children:(0,n.jsx)(`path`,{d:`M6 4L10 8L6 12`,stroke:`currentColor`,strokeWidth:`1.5`,strokeLinecap:`round`,strokeLinejoin:`round`})}),s=()=>(0,n.jsx)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 20 20`,fill:`currentColor`,"aria-hidden":`true`,children:(0,n.jsx)(`path`,{d:`M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z`})}),c=(0,t.forwardRef)(({items:c,logo:l,header:u,footer:d,"aria-label":f=`Sidebar navigation`,defaultCollapsed:p=!1,isCollapsed:m,onCollapsedChange:h,defaultMobileOpen:g=!1,isMobileOpen:_,onMobileOpenChange:v,className:y},b)=>{let[x,S]=(0,t.useState)(p),C=m??x,[w,T]=(0,t.useState)(g),E=_??w,[D]=(0,t.useState)(()=>typeof document<`u`),O=(0,t.useRef)(null),k=(0,t.useRef)(null);(0,t.useEffect)(()=>{if(window.matchMedia?.(`(max-width: 767px)`)?.matches??!1)return E?(k.current=document.activeElement,document.body.style.overflow=`hidden`,(O.current?.querySelector(i))?.focus()):(document.body.style.overflow=``,k.current?.focus(),k.current=null),()=>{document.body.style.overflow=``}},[E]);let A=(0,t.useCallback)(()=>{let e=!C;m===void 0&&S(e),h?.(e)},[C,m,h]),j=(0,t.useCallback)(()=>{_===void 0&&T(!1),v?.(!1)},[_,v]),M=(0,t.useCallback)(e=>{e.key===`Escape`&&j()},[j]),N=[e.default.sidebar,C?e.default.collapsed:``,E?e.default.mobileOpen:``,y??``].filter(Boolean).join(` `);return(0,n.jsxs)(`aside`,{ref:b,className:N,children:[D&&E&&(0,r.createPortal)((0,n.jsx)(`div`,{className:e.default.backdrop,onClick:j,"aria-hidden":`true`}),document.body),(0,n.jsxs)(`div`,{ref:O,className:e.default.panel,onKeyDown:M,tabIndex:-1,children:[(l||u)&&(0,n.jsxs)(`div`,{className:e.default.panelTop,children:[(0,n.jsxs)(`div`,{className:e.default.logoRow,children:[l&&(0,n.jsx)(`div`,{className:e.default.logoSlot,children:l}),u&&(0,n.jsx)(`div`,{className:e.default.headerContent,children:u})]}),(0,n.jsx)(`button`,{type:`button`,className:e.default.mobileCloseButton,onClick:j,"aria-label":`Close sidebar`,children:(0,n.jsx)(s,{})})]}),!l&&!u&&(0,n.jsx)(`div`,{className:e.default.mobileCloseRow,children:(0,n.jsx)(`button`,{type:`button`,className:e.default.mobileCloseButton,onClick:j,"aria-label":`Close sidebar`,children:(0,n.jsx)(s,{})})}),(0,n.jsx)(`nav`,{"aria-label":f,className:e.default.nav,children:(0,n.jsx)(`ul`,{className:e.default.navList,tabIndex:0,children:c.map(t=>(0,n.jsx)(`li`,{className:e.default.navItem,children:(0,n.jsxs)(`a`,{href:t.href,onClick:t.onClick,className:[e.default.navLink,t.isActive?e.default.navLinkActive:``].filter(Boolean).join(` `),"aria-current":t.isActive?`page`:void 0,"aria-label":t.icon&&C?t.label:void 0,title:t.icon&&C?t.label:void 0,children:[t.icon&&(0,n.jsx)(`span`,{className:e.default.navLinkIcon,"aria-hidden":`true`,children:t.icon}),(0,n.jsx)(`span`,{className:e.default.navLinkLabel,children:t.label})]})},t.key))})}),d&&(0,n.jsx)(`div`,{className:e.default.footer,children:d}),(0,n.jsx)(`button`,{type:`button`,className:e.default.collapseButton,onClick:A,"aria-label":C?`Expand sidebar`:`Collapse sidebar`,"aria-expanded":!C,children:C?(0,n.jsx)(o,{}):(0,n.jsx)(a,{})})]})]})});c.displayName=`Sidebar`,exports.Sidebar=c;
1
+ const e=require("../shared/ItemLink.cjs"),t=require("./Sidebar.module.css.cjs");let n=require("react"),r=require("react/jsx-runtime"),i=require("react-dom");var a=`a[href], button:not([disabled]), input:not([disabled]), [tabindex]:not([tabindex="-1"])`,o=()=>(0,r.jsx)(`svg`,{width:`16`,height:`16`,viewBox:`0 0 16 16`,fill:`none`,"aria-hidden":`true`,children:(0,r.jsx)(`path`,{d:`M10 4L6 8L10 12`,stroke:`currentColor`,strokeWidth:`1.5`,strokeLinecap:`round`,strokeLinejoin:`round`})}),s=()=>(0,r.jsx)(`svg`,{width:`16`,height:`16`,viewBox:`0 0 16 16`,fill:`none`,"aria-hidden":`true`,children:(0,r.jsx)(`path`,{d:`M6 4L10 8L6 12`,stroke:`currentColor`,strokeWidth:`1.5`,strokeLinecap:`round`,strokeLinejoin:`round`})}),c=()=>(0,r.jsx)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 20 20`,fill:`currentColor`,"aria-hidden":`true`,children:(0,r.jsx)(`path`,{d:`M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z`})}),l=(0,n.forwardRef)(({items:l,logo:u,header:d,footer:f,"aria-label":p=`Sidebar navigation`,linkComponent:m,defaultCollapsed:h=!1,isCollapsed:g,onCollapsedChange:_,defaultMobileOpen:v=!1,isMobileOpen:y,onMobileOpenChange:b,className:x},S)=>{let[C,w]=(0,n.useState)(h),T=g??C,[E,D]=(0,n.useState)(v),O=y??E,[k]=(0,n.useState)(()=>typeof document<`u`),A=(0,n.useRef)(null),j=(0,n.useRef)(null);(0,n.useEffect)(()=>{if(window.matchMedia?.(`(max-width: 767px)`)?.matches??!1)return O?(j.current=document.activeElement,document.body.style.overflow=`hidden`,(A.current?.querySelector(a))?.focus()):(document.body.style.overflow=``,j.current?.focus(),j.current=null),()=>{document.body.style.overflow=``}},[O]);let M=(0,n.useCallback)(()=>{let e=!T;g===void 0&&w(e),_?.(e)},[T,g,_]),N=(0,n.useCallback)(()=>{y===void 0&&D(!1),b?.(!1)},[y,b]),P=(0,n.useCallback)(e=>{e.key===`Escape`&&N()},[N]),F=[t.default.sidebar,T?t.default.collapsed:``,O?t.default.mobileOpen:``,x??``].filter(Boolean).join(` `);return(0,r.jsxs)(`aside`,{ref:S,className:F,children:[k&&O&&(0,i.createPortal)((0,r.jsx)(`div`,{className:t.default.backdrop,onClick:N,"aria-hidden":`true`}),document.body),(0,r.jsxs)(`div`,{ref:A,className:t.default.panel,onKeyDown:P,tabIndex:-1,children:[(u||d)&&(0,r.jsxs)(`div`,{className:t.default.panelTop,children:[(0,r.jsxs)(`div`,{className:t.default.logoRow,children:[u&&(0,r.jsx)(`div`,{className:t.default.logoSlot,children:u}),d&&(0,r.jsx)(`div`,{className:t.default.headerContent,children:d})]}),(0,r.jsx)(`button`,{type:`button`,className:t.default.mobileCloseButton,onClick:N,"aria-label":`Close sidebar`,children:(0,r.jsx)(c,{})})]}),!u&&!d&&(0,r.jsx)(`div`,{className:t.default.mobileCloseRow,children:(0,r.jsx)(`button`,{type:`button`,className:t.default.mobileCloseButton,onClick:N,"aria-label":`Close sidebar`,children:(0,r.jsx)(c,{})})}),(0,r.jsx)(`nav`,{"aria-label":p,className:t.default.nav,children:(0,r.jsx)(`ul`,{className:t.default.navList,tabIndex:0,children:l.map(n=>(0,r.jsx)(`li`,{className:t.default.navItem,children:(0,r.jsxs)(e.ItemLink,{linkComponent:m,href:n.href,onClick:()=>{n.onClick?.(),O&&N()},className:[t.default.navLink,n.isActive?t.default.navLinkActive:``].filter(Boolean).join(` `),"aria-current":n.isActive?`page`:void 0,"aria-label":n.icon&&T?n.label:void 0,title:n.icon&&T?n.label:void 0,children:[n.icon&&(0,r.jsx)(`span`,{className:t.default.navLinkIcon,"aria-hidden":`true`,children:n.icon}),(0,r.jsx)(`span`,{className:t.default.navLinkLabel,children:n.label})]})},n.key))})}),f&&(0,r.jsx)(`div`,{className:t.default.footer,children:f}),(0,r.jsx)(`button`,{type:`button`,className:t.default.collapseButton,onClick:M,"aria-label":T?`Expand sidebar`:`Collapse sidebar`,"aria-expanded":!T,children:T?(0,r.jsx)(s,{}):(0,r.jsx)(o,{})})]})]})});l.displayName=`Sidebar`,exports.Sidebar=l;
@@ -1,3 +1,4 @@
1
+ import type { LinkComponent } from '../shared/LinkComponent';
1
2
  export interface SidebarItem {
2
3
  key: string;
3
4
  label: string;
@@ -15,6 +16,11 @@ export interface SidebarProps {
15
16
  /** Pinned to the bottom of the panel, above the collapse button. */
16
17
  footer?: React.ReactNode;
17
18
  'aria-label'?: string;
19
+ /**
20
+ * Component rendered for items with an `href` instead of a plain `<a>`, such as an adapter over the
21
+ * router's link, so navigation happens without a full page load. Defaults to `<a>`.
22
+ */
23
+ linkComponent?: LinkComponent;
18
24
  /** Desktop collapse — uncontrolled default */
19
25
  defaultCollapsed?: boolean;
20
26
  /** Desktop collapse — controlled */
@@ -1,150 +1,154 @@
1
- import e from "./Sidebar.module.css.js";
2
- import { forwardRef as t, useCallback as n, useEffect as r, useRef as i, useState as a } from "react";
3
- import { jsx as o, jsxs as s } from "react/jsx-runtime";
4
- import { createPortal as c } from "react-dom";
1
+ import { ItemLink as e } from "../shared/ItemLink.js";
2
+ import t from "./Sidebar.module.css.js";
3
+ import { forwardRef as n, useCallback as r, useEffect as i, useRef as a, useState as o } from "react";
4
+ import { jsx as s, jsxs as c } from "react/jsx-runtime";
5
+ import { createPortal as l } from "react-dom";
5
6
  //#region src/components/Sidebar/Sidebar.tsx
6
- var l = "a[href], button:not([disabled]), input:not([disabled]), [tabindex]:not([tabindex=\"-1\"])", u = () => /* @__PURE__ */ o("svg", {
7
+ var u = "a[href], button:not([disabled]), input:not([disabled]), [tabindex]:not([tabindex=\"-1\"])", d = () => /* @__PURE__ */ s("svg", {
7
8
  width: "16",
8
9
  height: "16",
9
10
  viewBox: "0 0 16 16",
10
11
  fill: "none",
11
12
  "aria-hidden": "true",
12
- children: /* @__PURE__ */ o("path", {
13
+ children: /* @__PURE__ */ s("path", {
13
14
  d: "M10 4L6 8L10 12",
14
15
  stroke: "currentColor",
15
16
  strokeWidth: "1.5",
16
17
  strokeLinecap: "round",
17
18
  strokeLinejoin: "round"
18
19
  })
19
- }), d = () => /* @__PURE__ */ o("svg", {
20
+ }), f = () => /* @__PURE__ */ s("svg", {
20
21
  width: "16",
21
22
  height: "16",
22
23
  viewBox: "0 0 16 16",
23
24
  fill: "none",
24
25
  "aria-hidden": "true",
25
- children: /* @__PURE__ */ o("path", {
26
+ children: /* @__PURE__ */ s("path", {
26
27
  d: "M6 4L10 8L6 12",
27
28
  stroke: "currentColor",
28
29
  strokeWidth: "1.5",
29
30
  strokeLinecap: "round",
30
31
  strokeLinejoin: "round"
31
32
  })
32
- }), f = () => /* @__PURE__ */ o("svg", {
33
+ }), p = () => /* @__PURE__ */ s("svg", {
33
34
  width: "20",
34
35
  height: "20",
35
36
  viewBox: "0 0 20 20",
36
37
  fill: "currentColor",
37
38
  "aria-hidden": "true",
38
- children: /* @__PURE__ */ o("path", { d: "M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z" })
39
- }), p = t(({ items: t, logo: p, header: m, footer: h, "aria-label": g = "Sidebar navigation", defaultCollapsed: _ = !1, isCollapsed: v, onCollapsedChange: y, defaultMobileOpen: b = !1, isMobileOpen: x, onMobileOpenChange: S, className: C }, w) => {
40
- let [T, E] = a(_), D = v ?? T, [O, k] = a(b), A = x ?? O, [j] = a(() => typeof document < "u"), M = i(null), N = i(null);
41
- r(() => {
42
- if (window.matchMedia?.("(max-width: 767px)")?.matches ?? !1) return A ? (N.current = document.activeElement, document.body.style.overflow = "hidden", (M.current?.querySelector(l))?.focus()) : (document.body.style.overflow = "", N.current?.focus(), N.current = null), () => {
39
+ children: /* @__PURE__ */ s("path", { d: "M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z" })
40
+ }), m = n(({ items: n, logo: m, header: h, footer: g, "aria-label": _ = "Sidebar navigation", linkComponent: v, defaultCollapsed: y = !1, isCollapsed: b, onCollapsedChange: x, defaultMobileOpen: S = !1, isMobileOpen: C, onMobileOpenChange: w, className: T }, E) => {
41
+ let [D, O] = o(y), k = b ?? D, [A, j] = o(S), M = C ?? A, [N] = o(() => typeof document < "u"), P = a(null), F = a(null);
42
+ i(() => {
43
+ if (window.matchMedia?.("(max-width: 767px)")?.matches ?? !1) return M ? (F.current = document.activeElement, document.body.style.overflow = "hidden", (P.current?.querySelector(u))?.focus()) : (document.body.style.overflow = "", F.current?.focus(), F.current = null), () => {
43
44
  document.body.style.overflow = "";
44
45
  };
45
- }, [A]);
46
- let P = n(() => {
47
- let e = !D;
48
- v === void 0 && E(e), y?.(e);
46
+ }, [M]);
47
+ let I = r(() => {
48
+ let e = !k;
49
+ b === void 0 && O(e), x?.(e);
49
50
  }, [
50
- D,
51
- v,
52
- y
53
- ]), F = n(() => {
54
- x === void 0 && k(!1), S?.(!1);
55
- }, [x, S]), I = n((e) => {
56
- e.key === "Escape" && F();
57
- }, [F]), L = [
58
- e.sidebar,
59
- D ? e.collapsed : "",
60
- A ? e.mobileOpen : "",
61
- C ?? ""
51
+ k,
52
+ b,
53
+ x
54
+ ]), L = r(() => {
55
+ C === void 0 && j(!1), w?.(!1);
56
+ }, [C, w]), R = r((e) => {
57
+ e.key === "Escape" && L();
58
+ }, [L]), z = [
59
+ t.sidebar,
60
+ k ? t.collapsed : "",
61
+ M ? t.mobileOpen : "",
62
+ T ?? ""
62
63
  ].filter(Boolean).join(" ");
63
- return /* @__PURE__ */ s("aside", {
64
- ref: w,
65
- className: L,
66
- children: [j && A && c(/* @__PURE__ */ o("div", {
67
- className: e.backdrop,
68
- onClick: F,
64
+ return /* @__PURE__ */ c("aside", {
65
+ ref: E,
66
+ className: z,
67
+ children: [N && M && l(/* @__PURE__ */ s("div", {
68
+ className: t.backdrop,
69
+ onClick: L,
69
70
  "aria-hidden": "true"
70
- }), document.body), /* @__PURE__ */ s("div", {
71
- ref: M,
72
- className: e.panel,
73
- onKeyDown: I,
71
+ }), document.body), /* @__PURE__ */ c("div", {
72
+ ref: P,
73
+ className: t.panel,
74
+ onKeyDown: R,
74
75
  tabIndex: -1,
75
76
  children: [
76
- (p || m) && /* @__PURE__ */ s("div", {
77
- className: e.panelTop,
78
- children: [/* @__PURE__ */ s("div", {
79
- className: e.logoRow,
80
- children: [p && /* @__PURE__ */ o("div", {
81
- className: e.logoSlot,
82
- children: p
83
- }), m && /* @__PURE__ */ o("div", {
84
- className: e.headerContent,
77
+ (m || h) && /* @__PURE__ */ c("div", {
78
+ className: t.panelTop,
79
+ children: [/* @__PURE__ */ c("div", {
80
+ className: t.logoRow,
81
+ children: [m && /* @__PURE__ */ s("div", {
82
+ className: t.logoSlot,
85
83
  children: m
84
+ }), h && /* @__PURE__ */ s("div", {
85
+ className: t.headerContent,
86
+ children: h
86
87
  })]
87
- }), /* @__PURE__ */ o("button", {
88
+ }), /* @__PURE__ */ s("button", {
88
89
  type: "button",
89
- className: e.mobileCloseButton,
90
- onClick: F,
90
+ className: t.mobileCloseButton,
91
+ onClick: L,
91
92
  "aria-label": "Close sidebar",
92
- children: /* @__PURE__ */ o(f, {})
93
+ children: /* @__PURE__ */ s(p, {})
93
94
  })]
94
95
  }),
95
- !p && !m && /* @__PURE__ */ o("div", {
96
- className: e.mobileCloseRow,
97
- children: /* @__PURE__ */ o("button", {
96
+ !m && !h && /* @__PURE__ */ s("div", {
97
+ className: t.mobileCloseRow,
98
+ children: /* @__PURE__ */ s("button", {
98
99
  type: "button",
99
- className: e.mobileCloseButton,
100
- onClick: F,
100
+ className: t.mobileCloseButton,
101
+ onClick: L,
101
102
  "aria-label": "Close sidebar",
102
- children: /* @__PURE__ */ o(f, {})
103
+ children: /* @__PURE__ */ s(p, {})
103
104
  })
104
105
  }),
105
- /* @__PURE__ */ o("nav", {
106
- "aria-label": g,
107
- className: e.nav,
108
- children: /* @__PURE__ */ o("ul", {
109
- className: e.navList,
106
+ /* @__PURE__ */ s("nav", {
107
+ "aria-label": _,
108
+ className: t.nav,
109
+ children: /* @__PURE__ */ s("ul", {
110
+ className: t.navList,
110
111
  tabIndex: 0,
111
- children: t.map((t) => /* @__PURE__ */ o("li", {
112
- className: e.navItem,
113
- children: /* @__PURE__ */ s("a", {
114
- href: t.href,
115
- onClick: t.onClick,
116
- className: [e.navLink, t.isActive ? e.navLinkActive : ""].filter(Boolean).join(" "),
117
- "aria-current": t.isActive ? "page" : void 0,
118
- "aria-label": t.icon && D ? t.label : void 0,
119
- title: t.icon && D ? t.label : void 0,
120
- children: [t.icon && /* @__PURE__ */ o("span", {
121
- className: e.navLinkIcon,
112
+ children: n.map((n) => /* @__PURE__ */ s("li", {
113
+ className: t.navItem,
114
+ children: /* @__PURE__ */ c(e, {
115
+ linkComponent: v,
116
+ href: n.href,
117
+ onClick: () => {
118
+ n.onClick?.(), M && L();
119
+ },
120
+ className: [t.navLink, n.isActive ? t.navLinkActive : ""].filter(Boolean).join(" "),
121
+ "aria-current": n.isActive ? "page" : void 0,
122
+ "aria-label": n.icon && k ? n.label : void 0,
123
+ title: n.icon && k ? n.label : void 0,
124
+ children: [n.icon && /* @__PURE__ */ s("span", {
125
+ className: t.navLinkIcon,
122
126
  "aria-hidden": "true",
123
- children: t.icon
124
- }), /* @__PURE__ */ o("span", {
125
- className: e.navLinkLabel,
126
- children: t.label
127
+ children: n.icon
128
+ }), /* @__PURE__ */ s("span", {
129
+ className: t.navLinkLabel,
130
+ children: n.label
127
131
  })]
128
132
  })
129
- }, t.key))
133
+ }, n.key))
130
134
  })
131
135
  }),
132
- h && /* @__PURE__ */ o("div", {
133
- className: e.footer,
134
- children: h
136
+ g && /* @__PURE__ */ s("div", {
137
+ className: t.footer,
138
+ children: g
135
139
  }),
136
- /* @__PURE__ */ o("button", {
140
+ /* @__PURE__ */ s("button", {
137
141
  type: "button",
138
- className: e.collapseButton,
139
- onClick: P,
140
- "aria-label": D ? "Expand sidebar" : "Collapse sidebar",
141
- "aria-expanded": !D,
142
- children: o(D ? d : u, {})
142
+ className: t.collapseButton,
143
+ onClick: I,
144
+ "aria-label": k ? "Expand sidebar" : "Collapse sidebar",
145
+ "aria-expanded": !k,
146
+ children: s(k ? f : d, {})
143
147
  })
144
148
  ]
145
149
  })]
146
150
  });
147
151
  });
148
- p.displayName = "Sidebar";
152
+ m.displayName = "Sidebar";
149
153
  //#endregion
150
- export { p as Sidebar };
154
+ export { m as Sidebar };
@@ -0,0 +1 @@
1
+ let e=require("react/jsx-runtime");function t({linkComponent:t,href:n,...r}){return t&&n?(0,e.jsx)(t,{href:n,...r}):(0,e.jsx)(`a`,{href:n,...r})}exports.ItemLink=t;
@@ -0,0 +1,7 @@
1
+ import type { LinkComponent, LinkComponentProps } from './LinkComponent';
2
+ export interface ItemLinkProps extends Omit<LinkComponentProps, 'href'> {
3
+ href?: string;
4
+ linkComponent?: LinkComponent;
5
+ }
6
+ /** Renders a navigation item's link through `linkComponent` when it has an `href`, otherwise as a plain `<a>`. */
7
+ export declare function ItemLink({ linkComponent: Link, href, ...rest }: ItemLinkProps): import("react").JSX.Element;
@@ -0,0 +1,10 @@
1
+ import { jsx as e } from "react/jsx-runtime";
2
+ //#region src/components/shared/ItemLink.tsx
3
+ function t({ linkComponent: t, href: n, ...r }) {
4
+ return e(t && n ? t : "a", {
5
+ href: n,
6
+ ...r
7
+ });
8
+ }
9
+ //#endregion
10
+ export { t as ItemLink };
@@ -0,0 +1,16 @@
1
+ import type { AriaAttributes, ComponentType, MouseEventHandler, ReactNode } from 'react';
2
+ /** Props a navigation component passes to a consumer-supplied link component. */
3
+ export interface LinkComponentProps {
4
+ href: string;
5
+ className?: string;
6
+ children?: ReactNode;
7
+ onClick?: MouseEventHandler<HTMLAnchorElement>;
8
+ 'aria-current'?: AriaAttributes['aria-current'];
9
+ 'aria-label'?: string;
10
+ title?: string;
11
+ }
12
+ /**
13
+ * A link component, typically a thin adapter over the router's own (`<Link to={href} … />`), that a
14
+ * navigation component renders for items with an `href` instead of a plain `<a>`.
15
+ */
16
+ export type LinkComponent = ComponentType<LinkComponentProps>;
package/dist/index.d.ts CHANGED
@@ -101,6 +101,7 @@ export { Navbar } from './components/Navbar/Navbar';
101
101
  export type { NavbarProps, NavItem } from './components/Navbar/Navbar';
102
102
  export { Sidebar } from './components/Sidebar/Sidebar';
103
103
  export type { SidebarProps, SidebarItem } from './components/Sidebar/Sidebar';
104
+ export type { LinkComponent, LinkComponentProps } from './components/shared/LinkComponent';
104
105
  export { DataTable } from './components/DataTable/DataTable';
105
106
  export type { DataTableProps, TableColumn, SortDirection } from './components/DataTable/DataTable';
106
107
  export { BarChart } from './components/BarChart/BarChart';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aseguragonzalez/ui",
3
- "version": "1.1.0",
3
+ "version": "1.2.0",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "description": "Accessible, themeable design system for React SPAs",