jcicl 0.0.112 → 0.0.116

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,9 +1,17 @@
1
+ export interface CustomLogoProps {
2
+ logoSrc: string;
3
+ logoWidth: number;
4
+ logoHeight: number;
5
+ }
1
6
  export interface AppHeaderProps {
2
7
  loggedIn?: boolean;
3
8
  hamburgerMenu?: boolean;
4
9
  onLogin?: () => void;
10
+ onLogout?: () => void;
5
11
  onUserMenuClick?: () => void;
6
12
  onHamburgerMenuClick?: () => void;
13
+ logoProps: CustomLogoProps;
14
+ iconColor: string;
7
15
  }
8
16
  declare const AppHeader: React.FC<AppHeaderProps>;
9
17
  export default AppHeader;
@@ -1,76 +1,75 @@
1
1
  import { jsx as u, jsxs as b } from "react/jsx-runtime";
2
- import * as g from "react";
3
- import C, { useState as h, useLayoutEffect as z } from "react";
2
+ import * as w from "react";
3
+ import E, { useState as v, useLayoutEffect as M } from "react";
4
4
  import { n as f } from "../.chunks/emotion-styled.browser.esm.js";
5
5
  import { c as m } from "../.chunks/emotion-react.browser.esm.js";
6
- import { l as W } from "../.chunks/jocologo.js";
7
- import { I as k } from "../.chunks/Input.js";
8
- import { Button as x } from "../Button/Button.js";
9
- import I from "../Avatar/Avatar.js";
10
- import E from "../WithLabel/WithLabel.js";
11
- import { c as M } from "../.chunks/createSvgIcon.js";
12
- const S = C[typeof document < "u" && document.createElement !== void 0 ? "useLayoutEffect" : "useEffect"], y = (e) => {
13
- const l = g.useRef(e);
14
- return g.useEffect(() => {
15
- l.current = e;
16
- }), l;
6
+ import { I as y } from "../.chunks/Input.js";
7
+ import { Button as C } from "../Button/Button.js";
8
+ import O from "../Avatar/Avatar.js";
9
+ import I from "../WithLabel/WithLabel.js";
10
+ import { c as L } from "../.chunks/createSvgIcon.js";
11
+ const R = E[typeof document < "u" && document.createElement !== void 0 ? "useLayoutEffect" : "useEffect"], _ = (e) => {
12
+ const c = w.useRef(e);
13
+ return w.useEffect(() => {
14
+ c.current = e;
15
+ }), c;
17
16
  };
18
- function L() {
17
+ function A() {
19
18
  }
20
- function O(e, l, o = {}) {
21
- const r = R(o.polyfill), a = y(l);
22
- return S(() => {
23
- let t = !1;
24
- const i = e && "current" in e ? e.current : e;
25
- if (!i) return L;
26
- function s(n, c) {
27
- t || a.current(n, c);
19
+ function H(e, c, s = {}) {
20
+ const r = U(s.polyfill), a = _(c);
21
+ return R(() => {
22
+ let o = !1;
23
+ const l = e && "current" in e ? e.current : e;
24
+ if (!l) return A;
25
+ function n(i, t) {
26
+ o || a.current(i, t);
28
27
  }
29
- return r.subscribe(i, s), () => {
30
- t = !0, r.unsubscribe(i, s);
28
+ return r.subscribe(l, n), () => {
29
+ o = !0, r.unsubscribe(l, n);
31
30
  };
32
31
  }, [e, r, a]), r.observer;
33
32
  }
34
- function $(e) {
35
- let l = !1, o = [];
36
- const r = /* @__PURE__ */ new Map(), a = new (e || window.ResizeObserver)((t, i) => {
37
- o = o.concat(t);
38
- function s() {
39
- const n = /* @__PURE__ */ new Set();
40
- for (let c = 0; c < o.length; c++) {
41
- if (n.has(o[c].target)) continue;
42
- n.add(o[c].target);
43
- const p = r.get(o[c].target);
44
- p == null || p.forEach((d) => d(o[c], i));
33
+ function j(e) {
34
+ let c = !1, s = [];
35
+ const r = /* @__PURE__ */ new Map(), a = new (e || window.ResizeObserver)((o, l) => {
36
+ s = s.concat(o);
37
+ function n() {
38
+ const i = /* @__PURE__ */ new Set();
39
+ for (let t = 0; t < s.length; t++) {
40
+ if (i.has(s[t].target)) continue;
41
+ i.add(s[t].target);
42
+ const h = r.get(s[t].target);
43
+ h == null || h.forEach((d) => d(s[t], l));
45
44
  }
46
- o = [], l = !1;
45
+ s = [], c = !1;
47
46
  }
48
- l || window.requestAnimationFrame(s), l = !0;
47
+ c || window.requestAnimationFrame(n), c = !0;
49
48
  });
50
49
  return {
51
50
  observer: a,
52
- subscribe(t, i) {
53
- var s;
54
- a.observe(t);
55
- const n = (s = r.get(t)) !== null && s !== void 0 ? s : [];
56
- n.push(i), r.set(t, n);
51
+ subscribe(o, l) {
52
+ var n;
53
+ a.observe(o);
54
+ const i = (n = r.get(o)) !== null && n !== void 0 ? n : [];
55
+ i.push(l), r.set(o, i);
57
56
  },
58
- unsubscribe(t, i) {
59
- var s;
60
- const n = (s = r.get(t)) !== null && s !== void 0 ? s : [];
61
- if (n.length === 1) {
62
- a.unobserve(t), r.delete(t);
57
+ unsubscribe(o, l) {
58
+ var n;
59
+ const i = (n = r.get(o)) !== null && n !== void 0 ? n : [];
60
+ if (i.length === 1) {
61
+ a.unobserve(o), r.delete(o);
63
62
  return;
64
63
  }
65
- const c = n.indexOf(i);
66
- c !== -1 && n.splice(c, 1), r.set(t, n);
64
+ const t = i.indexOf(l);
65
+ t !== -1 && i.splice(t, 1), r.set(o, i);
67
66
  }
68
67
  };
69
68
  }
70
- let v;
71
- const R = (e) => v || (v = $(e)), _ = M(/* @__PURE__ */ u("path", {
69
+ let g;
70
+ const U = (e) => g || (g = j(e)), V = L(/* @__PURE__ */ u("path", {
72
71
  d: "M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"
73
- }), "Menu"), A = f("div")(() => ({
72
+ }), "Menu"), B = f("div")(() => ({
74
73
  ...m`
75
74
  display: flex;
76
75
  flex-direction: row;
@@ -80,34 +79,34 @@ const R = (e) => v || (v = $(e)), _ = M(/* @__PURE__ */ u("path", {
80
79
  justify-content: space-between;
81
80
  gap: 1.5rem;
82
81
  `
83
- })), j = f("img")({
84
- width: "36px"
85
- }), H = f("div")(() => ({
82
+ })), F = f("img")(({ width: e }) => ({
83
+ width: `${e}px`
84
+ })), q = f("div")(({ height: e }) => ({
86
85
  ...m`
87
86
  display: flex;
88
87
  gap: 1rem;
89
- height: 50px;
88
+ height: ${e}px;
90
89
  `
91
- })), U = f("div")(({ width: e, loggedIn: l }) => ({
90
+ })), P = f("div")(({ width: e, loggedIn: c }) => ({
92
91
  ...m`
93
92
  width: ${e}px;
94
93
  display: flex;
95
94
  justify-content: center;
96
95
  align-items: flex-end;
97
- flex-direction: ${l ? "column" : "column-reverse"};
96
+ flex-direction: ${c ? "column" : "column-reverse"};
98
97
  flex-shrink: 0;
99
98
  * {
100
99
  white-space: nowrap;
101
100
  }
102
101
  `
103
- })), w = f("div")(({ visible: e }) => ({
102
+ })), W = f("div")(({ visible: e }) => ({
104
103
  ...m`
105
104
  z-index: ${e ? 1 : 0};
106
105
  opacity: ${e ? 1 : 0};
107
106
  pointer-events: ${e ? "auto" : "none"};
108
107
  position: ${e ? "relative" : "absolute"};
109
108
  `
110
- })), V = f("div")(() => ({
109
+ })), D = f("div")(() => ({
111
110
  ...m`
112
111
  display: flex;
113
112
  width: 1360px;
@@ -116,33 +115,41 @@ const R = (e) => v || (v = $(e)), _ = M(/* @__PURE__ */ u("path", {
116
115
  width: 100%;
117
116
  }
118
117
  `
119
- })), T = ({ hamburgerMenu: e, onHamburgerMenuClick: l }) => {
120
- const [o, r] = h(!1), [a, t] = h(0), [i, s] = h(null), [n, c] = h(null);
121
- z(() => {
122
- i && i.clientWidth > a && t(i.clientWidth), n && n.clientWidth > a && t(n.clientWidth);
123
- }, [i, n]);
124
- const p = (d) => {
125
- d != null && d.clientWidth && d.clientWidth > a && t(d.clientWidth);
118
+ })), ee = ({
119
+ loggedIn: e,
120
+ logoProps: c,
121
+ iconColor: s,
122
+ hamburgerMenu: r,
123
+ onHamburgerMenuClick: a,
124
+ onUserMenuClick: o,
125
+ onLogin: l
126
+ }) => {
127
+ const [n, i] = v(0), [t, h] = v(null), [d, z] = v(null), { logoSrc: $, logoWidth: k, logoHeight: x } = c;
128
+ M(() => {
129
+ t && t.clientWidth > n && i(t.clientWidth), d && d.clientWidth > n && i(d.clientWidth);
130
+ }, [t, d]);
131
+ const S = (p) => {
132
+ p != null && p.clientWidth && p.clientWidth > n && i(p.clientWidth);
126
133
  };
127
- return O(i, () => p(i)), /* @__PURE__ */ b(A, { children: [
128
- /* @__PURE__ */ b(H, { children: [
129
- /* @__PURE__ */ u(j, { src: W, height: "50px" }),
130
- e && /* @__PURE__ */ u(x, { variant: "icon", onClick: l, children: /* @__PURE__ */ u(_, {}) })
134
+ return H(t, () => S(t)), /* @__PURE__ */ b(B, { children: [
135
+ /* @__PURE__ */ b(q, { height: x, children: [
136
+ /* @__PURE__ */ u(F, { src: $, height: `${x}px`, width: k }),
137
+ r && /* @__PURE__ */ u(C, { variant: "icon", onClick: a, color: s, children: /* @__PURE__ */ u(V, {}) })
131
138
  ] }),
132
- /* @__PURE__ */ u(V, { children: /* @__PURE__ */ u(k, { placeholder: "Search..." }) }),
133
- /* @__PURE__ */ b(U, { width: a, loggedIn: o, children: [
134
- /* @__PURE__ */ u(w, { visible: o, ref: s, children: /* @__PURE__ */ u(
135
- E,
139
+ /* @__PURE__ */ u(D, { children: /* @__PURE__ */ u(y, { placeholder: "Search..." }) }),
140
+ /* @__PURE__ */ b(P, { width: n, loggedIn: !!e, children: [
141
+ /* @__PURE__ */ u(W, { visible: !!e, ref: h, children: /* @__PURE__ */ u(
142
+ I,
136
143
  {
137
144
  id: "accountMenuContainer",
138
- component: /* @__PURE__ */ u(I, { onClick: () => r(!1) }),
145
+ component: /* @__PURE__ */ u(O, { onClick: o }),
139
146
  label: "Welcome, User"
140
147
  }
141
148
  ) }),
142
- /* @__PURE__ */ u(w, { visible: !o, ref: c, children: /* @__PURE__ */ u(x, { id: "loginButtonContainer", onClick: () => r(!0), children: "Log In" }) })
149
+ /* @__PURE__ */ u(W, { visible: !e, ref: z, children: /* @__PURE__ */ u(C, { id: "loginButtonContainer", onClick: l, children: "Log In" }) })
143
150
  ] })
144
151
  ] });
145
152
  };
146
153
  export {
147
- T as default
154
+ ee as default
148
155
  };
@@ -1 +1 @@
1
- export { default, type AppHeaderProps } from './AppHeader';
1
+ export { default, type AppHeaderProps, type CustomLogoProps } from './AppHeader';
@@ -1,7 +1,9 @@
1
1
  import { ButtonProps as MuiButtonProps } from '@mui/material/Button/Button';
2
- export interface ButtonProps extends Omit<MuiButtonProps, 'variant' | 'size'> {
2
+ export interface ButtonProps extends Omit<MuiButtonProps, 'variant' | 'size' | 'color'> {
3
3
  variant?: 1 | 2 | 'unstyled' | 'icon';
4
4
  size?: number;
5
+ color?: string;
6
+ highlightColor?: string;
5
7
  }
6
8
  export declare const Button: React.FC<ButtonProps & {
7
9
  children: React.ReactNode;
package/Button/Button.js CHANGED
@@ -1,34 +1,34 @@
1
- import { jsxs as F, jsx as s } from "react/jsx-runtime";
2
- import * as g from "react";
3
- import { g as U, a as _, s as l, r as H, c as i, f as A, u as q, b as h, P as t, d as J, e as b } from "../.chunks/DefaultPropsProvider.js";
1
+ import { jsxs as F, jsx as d } from "react/jsx-runtime";
2
+ import * as x from "react";
3
+ import { g as U, a as _, s as c, r as H, c as i, f as A, u as q, b as I, P as t, d as J, e as b } from "../.chunks/DefaultPropsProvider.js";
4
4
  import { m as K } from "../.chunks/memoTheme.js";
5
5
  import { c as Q } from "../.chunks/createSimplePaletteValueFilter.js";
6
6
  import { B as S } from "../.chunks/ButtonBase.js";
7
7
  import { c as X } from "../.chunks/emotion-react.browser.esm.js";
8
- import e from "../theme.js";
8
+ import s from "../theme.js";
9
9
  function Y(o) {
10
10
  return U("MuiButton", o);
11
11
  }
12
- const c = _("MuiButton", ["root", "text", "textInherit", "textPrimary", "textSecondary", "textSuccess", "textError", "textInfo", "textWarning", "outlined", "outlinedInherit", "outlinedPrimary", "outlinedSecondary", "outlinedSuccess", "outlinedError", "outlinedInfo", "outlinedWarning", "contained", "containedInherit", "containedPrimary", "containedSecondary", "containedSuccess", "containedError", "containedInfo", "containedWarning", "disableElevation", "focusVisible", "disabled", "colorInherit", "colorPrimary", "colorSecondary", "colorSuccess", "colorError", "colorInfo", "colorWarning", "textSizeSmall", "textSizeMedium", "textSizeLarge", "outlinedSizeSmall", "outlinedSizeMedium", "outlinedSizeLarge", "containedSizeSmall", "containedSizeMedium", "containedSizeLarge", "sizeMedium", "sizeSmall", "sizeLarge", "fullWidth", "startIcon", "endIcon", "icon", "iconSizeSmall", "iconSizeMedium", "iconSizeLarge"]), I = /* @__PURE__ */ g.createContext({});
13
- process.env.NODE_ENV !== "production" && (I.displayName = "ButtonGroupContext");
14
- const O = /* @__PURE__ */ g.createContext(void 0);
12
+ const u = _("MuiButton", ["root", "text", "textInherit", "textPrimary", "textSecondary", "textSuccess", "textError", "textInfo", "textWarning", "outlined", "outlinedInherit", "outlinedPrimary", "outlinedSecondary", "outlinedSuccess", "outlinedError", "outlinedInfo", "outlinedWarning", "contained", "containedInherit", "containedPrimary", "containedSecondary", "containedSuccess", "containedError", "containedInfo", "containedWarning", "disableElevation", "focusVisible", "disabled", "colorInherit", "colorPrimary", "colorSecondary", "colorSuccess", "colorError", "colorInfo", "colorWarning", "textSizeSmall", "textSizeMedium", "textSizeLarge", "outlinedSizeSmall", "outlinedSizeMedium", "outlinedSizeLarge", "containedSizeSmall", "containedSizeMedium", "containedSizeLarge", "sizeMedium", "sizeSmall", "sizeLarge", "fullWidth", "startIcon", "endIcon", "icon", "iconSizeSmall", "iconSizeMedium", "iconSizeLarge"]), h = /* @__PURE__ */ x.createContext({});
13
+ process.env.NODE_ENV !== "production" && (h.displayName = "ButtonGroupContext");
14
+ const O = /* @__PURE__ */ x.createContext(void 0);
15
15
  process.env.NODE_ENV !== "production" && (O.displayName = "ButtonGroupButtonContext");
16
16
  const Z = (o) => {
17
17
  const {
18
18
  color: n,
19
19
  disableElevation: a,
20
20
  fullWidth: r,
21
- size: d,
22
- variant: p,
23
- classes: u
21
+ size: e,
22
+ variant: l,
23
+ classes: p
24
24
  } = o, f = {
25
- root: ["root", p, `${p}${i(n)}`, `size${i(d)}`, `${p}Size${i(d)}`, `color${i(n)}`, a && "disableElevation", r && "fullWidth"],
25
+ root: ["root", l, `${l}${i(n)}`, `size${i(e)}`, `${l}Size${i(e)}`, `color${i(n)}`, a && "disableElevation", r && "fullWidth"],
26
26
  label: ["label"],
27
- startIcon: ["icon", "startIcon", `iconSize${i(d)}`],
28
- endIcon: ["icon", "endIcon", `iconSize${i(d)}`]
29
- }, y = J(f, Y, u);
27
+ startIcon: ["icon", "startIcon", `iconSize${i(e)}`],
28
+ endIcon: ["icon", "endIcon", `iconSize${i(e)}`]
29
+ }, y = J(f, Y, p);
30
30
  return {
31
- ...u,
31
+ ...p,
32
32
  // forward the focused, disabled, etc. classes to the ButtonBase
33
33
  ...y
34
34
  };
@@ -59,7 +59,7 @@ const Z = (o) => {
59
59
  fontSize: 22
60
60
  }
61
61
  }
62
- }], oo = l(S, {
62
+ }], oo = c(S, {
63
63
  shouldForwardProp: (o) => H(o) || o === "classes",
64
64
  name: "MuiButton",
65
65
  slot: "Root",
@@ -85,7 +85,7 @@ const Z = (o) => {
85
85
  "&:hover": {
86
86
  textDecoration: "none"
87
87
  },
88
- [`&.${c.disabled}`]: {
88
+ [`&.${u.disabled}`]: {
89
89
  color: (o.vars || o).palette.action.disabled
90
90
  },
91
91
  variants: [{
@@ -106,10 +106,10 @@ const Z = (o) => {
106
106
  "&:active": {
107
107
  boxShadow: (o.vars || o).shadows[8]
108
108
  },
109
- [`&.${c.focusVisible}`]: {
109
+ [`&.${u.focusVisible}`]: {
110
110
  boxShadow: (o.vars || o).shadows[6]
111
111
  },
112
- [`&.${c.disabled}`]: {
112
+ [`&.${u.disabled}`]: {
113
113
  color: (o.vars || o).palette.action.disabled,
114
114
  boxShadow: (o.vars || o).shadows[0],
115
115
  backgroundColor: (o.vars || o).palette.action.disabledBackground
@@ -125,7 +125,7 @@ const Z = (o) => {
125
125
  borderColor: "var(--variant-outlinedBorder, currentColor)",
126
126
  backgroundColor: "var(--variant-outlinedBg)",
127
127
  color: "var(--variant-outlinedColor)",
128
- [`&.${c.disabled}`]: {
128
+ [`&.${u.disabled}`]: {
129
129
  border: `1px solid ${(o.vars || o).palette.action.disabledBackground}`
130
130
  }
131
131
  }
@@ -236,13 +236,13 @@ const Z = (o) => {
236
236
  "&:hover": {
237
237
  boxShadow: "none"
238
238
  },
239
- [`&.${c.focusVisible}`]: {
239
+ [`&.${u.focusVisible}`]: {
240
240
  boxShadow: "none"
241
241
  },
242
242
  "&:active": {
243
243
  boxShadow: "none"
244
244
  },
245
- [`&.${c.disabled}`]: {
245
+ [`&.${u.disabled}`]: {
246
246
  boxShadow: "none"
247
247
  }
248
248
  }
@@ -255,7 +255,7 @@ const Z = (o) => {
255
255
  }
256
256
  }]
257
257
  };
258
- })), to = l("span", {
258
+ })), to = c("span", {
259
259
  name: "MuiButton",
260
260
  slot: "StartIcon",
261
261
  overridesResolver: (o, n) => {
@@ -276,7 +276,7 @@ const Z = (o) => {
276
276
  marginLeft: -2
277
277
  }
278
278
  }, ...R]
279
- }), ao = l("span", {
279
+ }), ao = c("span", {
280
280
  name: "MuiButton",
281
281
  slot: "EndIcon",
282
282
  overridesResolver: (o, n) => {
@@ -297,9 +297,9 @@ const Z = (o) => {
297
297
  marginRight: -2
298
298
  }
299
299
  }, ...R]
300
- }), k = /* @__PURE__ */ g.forwardRef(function(n, a) {
301
- const r = g.useContext(I), d = g.useContext(O), p = A(r, n), u = q({
302
- props: p,
300
+ }), k = /* @__PURE__ */ x.forwardRef(function(n, a) {
301
+ const r = x.useContext(h), e = x.useContext(O), l = A(r, n), p = q({
302
+ props: l,
303
303
  name: "MuiButton"
304
304
  }), {
305
305
  children: f,
@@ -317,8 +317,8 @@ const Z = (o) => {
317
317
  type: w,
318
318
  variant: V = "text",
319
319
  ...j
320
- } = u, x = {
321
- ...u,
320
+ } = p, g = {
321
+ ...p,
322
322
  color: y,
323
323
  component: B,
324
324
  disabled: z,
@@ -328,22 +328,22 @@ const Z = (o) => {
328
328
  size: M,
329
329
  type: w,
330
330
  variant: V
331
- }, v = Z(x), G = m && /* @__PURE__ */ s(to, {
331
+ }, v = Z(g), G = m && /* @__PURE__ */ d(to, {
332
332
  className: v.startIcon,
333
- ownerState: x,
333
+ ownerState: g,
334
334
  children: m
335
- }), L = C && /* @__PURE__ */ s(ao, {
335
+ }), L = C && /* @__PURE__ */ d(ao, {
336
336
  className: v.endIcon,
337
- ownerState: x,
337
+ ownerState: g,
338
338
  children: C
339
- }), D = d || "";
339
+ }), D = e || "";
340
340
  return /* @__PURE__ */ F(oo, {
341
- ownerState: x,
342
- className: h(r.className, v.root, N, D),
341
+ ownerState: g,
342
+ className: I(r.className, v.root, N, D),
343
343
  component: B,
344
344
  disabled: z,
345
345
  focusRipple: !$,
346
- focusVisibleClassName: h(v.focusVisible, P),
346
+ focusVisibleClassName: I(v.focusVisible, P),
347
347
  ref: a,
348
348
  type: w,
349
349
  ...j,
@@ -445,71 +445,75 @@ process.env.NODE_ENV !== "production" && (k.propTypes = {
445
445
  */
446
446
  variant: t.oneOfType([t.oneOf(["contained", "outlined", "text"]), t.string])
447
447
  });
448
- const E = l(k)`
448
+ const E = c(k)`
449
449
  text-transform: none;
450
450
  &:disabled {
451
451
  opacity: 0.5;
452
- color: ${e.colors.black};
452
+ color: ${s.colors.black};
453
453
  display: flex;
454
454
  justify-content: center;
455
455
  align-items: center;
456
456
  }
457
- `, no = l(E)`
458
- background-color: ${e.colors.green};
457
+ `, no = c(E)`
458
+ background-color: ${s.colors.green};
459
459
  border-radius: 0;
460
460
  height: 2.5rem;
461
461
  border: 2px solid transparent;
462
- color: ${e.colors.white};
462
+ color: ${s.colors.white};
463
463
  transition: 313ms all ease-in;
464
464
  border-radius: 32px;
465
465
  font-weight: 400;
466
466
  padding: 0.75rem 2rem;
467
467
  font-size: 1rem;
468
- box-shadow: ${e.boxShadow.gray63};
468
+ box-shadow: ${s.boxShadow.gray63};
469
469
  &:hover,
470
470
  :focus-visible {
471
- background-color: ${e.colors.darkGreen};
472
- box-shadow: ${e.boxShadow.black63};
471
+ background-color: ${s.colors.darkGreen};
472
+ box-shadow: ${s.boxShadow.black63};
473
473
  }
474
474
  &:disabled {
475
- background-color: ${e.colors.darkGreen};
475
+ background-color: ${s.colors.darkGreen};
476
476
  }
477
- `, ro = l(E)`
478
- color: ${e.colors.black};
479
- border: 3px solid ${e.colors.blue};
477
+ `, ro = c(E)`
478
+ color: ${s.colors.black};
479
+ border: 3px solid ${s.colors.blue};
480
480
  padding: 0.5rem 2rem;
481
- `, eo = l(S)`
481
+ `, eo = c(S)`
482
482
  border-radius: 8px;
483
- `, io = l(S)(({ size: o }) => ({
484
- ...X`
485
- display: flex;
486
- align-items: center;
487
- justify-content: center;
488
- background-color: transparent;
489
- transition: 313ms all ease-in-out;
483
+ `, io = c(S)(
484
+ ({ size: o, color: n, highlightColor: a }) => ({
485
+ ...X`
486
+ display: flex;
487
+ align-items: center;
488
+ justify-content: center;
489
+ background-color: transparent;
490
+ transition: 313ms all ease-in-out;
490
491
 
491
- &:hover,
492
- :focus-visible {
493
- svg {
494
- filter: drop-shadow(0 0 6px ${e.colors.dandelion}) drop-shadow(0 0 6px ${e.colors.dandelion})
495
- drop-shadow(0 0 6px ${e.colors.dandelion}) drop-shadow(0 0 6px ${e.colors.dandelion});
492
+ &:hover,
493
+ :focus-visible {
494
+ svg {
495
+ filter: drop-shadow(0 0 6px ${a}) drop-shadow(0 0 6px ${a})
496
+ drop-shadow(0 0 6px ${a}) drop-shadow(0 0 6px ${a});
497
+ }
496
498
  }
497
- }
498
499
 
499
- svg {
500
- transition: 313ms all ease-in-out;
501
- fill: ${e.colors.darkGreen};
502
- width: ${o}px;
503
- height: ${o}px;
504
- }
505
- `
506
- })), go = ({
500
+ svg {
501
+ transition: 313ms all ease-in-out;
502
+ fill: ${n};
503
+ width: ${o}px;
504
+ height: ${o}px;
505
+ }
506
+ `
507
+ })
508
+ ), xo = ({
507
509
  variant: o = 1,
508
510
  size: n = 50,
509
- children: a,
510
- ...r
511
- }) => o === "unstyled" ? /* @__PURE__ */ s(eo, { ...r, children: a }) : o === 2 ? /* @__PURE__ */ s(ro, { ...r, children: /* @__PURE__ */ s("span", { children: a }) }) : o === "icon" ? /* @__PURE__ */ s(io, { ...{ size: n }, ...r, children: a }) : /* @__PURE__ */ s(no, { ...r, children: /* @__PURE__ */ s("span", { children: a }) });
511
+ color: a = s.colors.darkGreen,
512
+ highlightColor: r = s.colors.dandelion,
513
+ children: e,
514
+ ...l
515
+ }) => o === "unstyled" ? /* @__PURE__ */ d(eo, { ...l, children: e }) : o === 2 ? /* @__PURE__ */ d(ro, { ...l, children: /* @__PURE__ */ d("span", { children: e }) }) : o === "icon" ? /* @__PURE__ */ d(io, { ...{ size: n, color: a, highlightColor: r }, ...l, children: e }) : /* @__PURE__ */ d(no, { ...l, children: /* @__PURE__ */ d("span", { children: e }) });
512
516
  export {
513
- go as Button,
514
- go as default
517
+ xo as Button,
518
+ xo as default
515
519
  };
package/Nav/Nav.d.ts CHANGED
@@ -1,3 +1,14 @@
1
+ export interface TemplateThemeProps {
2
+ backgroundPrimary: string;
3
+ backgroundSecondary: string;
4
+ backgroundTertiary: string;
5
+ borderPrimary: string;
6
+ iconPrimary: string;
7
+ highlightPrimary: string;
8
+ highlightSecondary: string;
9
+ highlightTertiary: string;
10
+ shadowPrimary: string;
11
+ }
1
12
  export interface NavItemProps {
2
13
  label?: string;
3
14
  icon?: React.ReactNode;
@@ -10,6 +21,7 @@ export interface NavProps {
10
21
  activeRoute?: string;
11
22
  navWidth?: string;
12
23
  isTablet?: boolean;
24
+ themeColors: Pick<TemplateThemeProps, 'highlightPrimary' | 'highlightTertiary' | 'iconPrimary'>;
13
25
  }
14
26
  export declare const Nav: React.FC<NavProps>;
15
27
  export default Nav;