@caseparts-org/caseblocks 0.0.12 → 0.0.16

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.
Files changed (55) hide show
  1. package/dist/assets/Account.css +1 -1
  2. package/dist/assets/Avatar.css +1 -1
  3. package/dist/assets/Button.css +1 -1
  4. package/dist/assets/Cart.css +1 -0
  5. package/dist/assets/HamburgerMenu.css +1 -0
  6. package/dist/assets/Icon.css +1 -1
  7. package/dist/assets/MainNav.css +1 -1
  8. package/dist/assets/Root.css +1 -1
  9. package/dist/assets/SearchBox.css +1 -1
  10. package/dist/assets/Tooltip.css +1 -0
  11. package/dist/atoms/Button/Button.d.ts +1 -1
  12. package/dist/atoms/Button/Button.js +35 -33
  13. package/dist/atoms/Button/Button.stories.d.ts +1 -1
  14. package/dist/atoms/Button/Button.stories.js +13 -16
  15. package/dist/atoms/Flex/Flex.stories.d.ts +1 -1
  16. package/dist/atoms/Grid/Grid.stories.d.ts +1 -1
  17. package/dist/atoms/Icon/Icon.js +17 -17
  18. package/dist/atoms/Icon/Icon.stories.d.ts +1 -1
  19. package/dist/atoms/Input/Input.stories.d.ts +1 -1
  20. package/dist/atoms/Link/Link.stories.d.ts +1 -1
  21. package/dist/atoms/Separator/Separator.stories.d.ts +1 -1
  22. package/dist/atoms/Text/Text.stories.d.ts +1 -1
  23. package/dist/molecules/Account/Account.d.ts +3 -0
  24. package/dist/molecules/Account/Account.js +56 -33
  25. package/dist/molecules/Account/Account.stories.d.ts +1 -1
  26. package/dist/molecules/Account/Account.stories.js +12 -5
  27. package/dist/molecules/Avatar/Avatar.d.ts +2 -1
  28. package/dist/molecules/Avatar/Avatar.js +26 -24
  29. package/dist/molecules/Avatar/Avatar.stories.d.ts +1 -1
  30. package/dist/molecules/Avatar/Avatar.stories.js +4 -1
  31. package/dist/molecules/Cart/Cart.d.ts +7 -0
  32. package/dist/molecules/Cart/Cart.js +23 -0
  33. package/dist/molecules/Cart/Cart.stories.d.ts +14 -0
  34. package/dist/molecules/Cart/Cart.stories.js +24 -0
  35. package/dist/molecules/Chip/Chip.stories.d.ts +1 -1
  36. package/dist/molecules/HamburgerMenu/HamburgerMenu.d.ts +7 -0
  37. package/dist/molecules/HamburgerMenu/HamburgerMenu.js +62 -0
  38. package/dist/molecules/Logo/Logo.js +13 -44
  39. package/dist/molecules/Logo/Logo.stories.d.ts +1 -1
  40. package/dist/molecules/SearchBox/SearchBox.js +16 -16
  41. package/dist/molecules/SearchBox/SearchBox.stories.d.ts +1 -1
  42. package/dist/molecules/ToggleView/ToggleView.stories.d.ts +1 -1
  43. package/dist/molecules/Tooltip/Tooltip.d.ts +11 -0
  44. package/dist/molecules/Tooltip/Tooltip.js +734 -0
  45. package/dist/molecules/Tooltip/Tooltip.stories.d.ts +46 -0
  46. package/dist/molecules/Tooltip/Tooltip.stories.js +142 -0
  47. package/dist/organisms/ChipSelector/ChipSelector.stories.d.ts +1 -1
  48. package/dist/organisms/MainNav/MainNav.d.ts +19 -1
  49. package/dist/organisms/MainNav/MainNav.js +117 -95
  50. package/dist/organisms/MainNav/MainNav.stories.d.ts +3 -2
  51. package/dist/organisms/MainNav/MainNav.stories.js +134 -11
  52. package/dist/organisms/SpinZoomViewer/SpinZoomViewer.stories.d.ts +1 -1
  53. package/dist/styles/tokens.css +53 -0
  54. package/package.json +14 -16
  55. package/dist/assets/Logo.css +0 -1
@@ -1 +1 @@
1
- ._button_j66cf_1{box-sizing:border-box;cursor:pointer;width:var(--spacing-2-5);height:var(--spacing-2-5);padding:var(--spacing-0-5);border-width:0;border-radius:0px var(--spacing-0-125) var(--spacing-0-125) 0px;display:flex;flex-direction:row;align-items:center;justify-content:center;background-color:inherit;color:var(--icons-icon-search)}._text_j66cf_16{flex:1;position:relative;border:none;outline:none;font-family:var(--font-family-body);font-weight:var(--font-weight-light);font-size:var(--font-size-sm);line-height:var(--line-height-sm);background:transparent;color:var(--text-text-search-bar)}._text_j66cf_16::placeholder{font-style:italic}._input_j66cf_31{flex:1;padding:0px 0px 0px var(--spacing-0-25)}._inputSearch_j66cf_35{flex:1;border-radius:var(--spacing-0-125)}._searchfield_j66cf_39{flex:1;height:var(--spacing-2-5);border-radius:var(--spacing-2-5);overflow:hidden;background-color:var(--surface-surface-search-bar)}._searchBox_j66cf_46{flex:1;width:100%;min-width:250px;max-width:392px;height:var(--spacing-2-5);position:relative;border-radius:var(--spacing-2-5);overflow:hidden;text-align:left;background-color:var(--surface-surface-search-bar)}
1
+ ._button_8serw_1{box-sizing:border-box;cursor:pointer;width:var(--spacing-2-5);height:var(--spacing-2-5);padding:var(--spacing-0-5);border-width:0;border-radius:0px var(--spacing-0-125) var(--spacing-0-125) 0px;display:flex;flex-direction:row;align-items:center;justify-content:center;background-color:inherit;color:var(--icons-icon-search)}._text_8serw_16{flex:1;position:relative;border:none;border-radius:40px;outline:none;font-family:var(--font-family-body);font-weight:var(--font-weight-light);font-size:var(--font-size-sm);line-height:var(--line-height-sm);background:var(--surface-surface-searchBar, #f6f6f6);color:var(--text-text-search-bar)}._text_8serw_16::placeholder{font-style:italic}._input_8serw_32{flex:1;padding:0px 0px 0px var(--spacing-0-25)}._inputSearch_8serw_36{flex:1;border-radius:var(--spacing-0-125)}._searchfield_8serw_40{flex:1;height:var(--spacing-2-5);border-radius:var(--spacing-2-5);overflow:hidden;background-color:var(--surface-surface-search-bar)}._searchBox_8serw_47{flex:1;width:100%;min-width:250px;height:var(--spacing-2-5);position:relative;border-radius:var(--spacing-2-5);overflow:hidden;text-align:left;background-color:var(--surface-surface-search-bar)}
@@ -0,0 +1 @@
1
+ ._tooltip_mtsuw_1{box-shadow:8px 8px 12px #00000026;background-color:var(--color-neutrals-neutral-1)}._content_mtsuw_5{padding:var(--spacing-1)}.popup-content{margin:auto;background:#fff;width:50%;padding:5px;border:1px solid #d7d7d7}[role=tooltip].popup-content{width:200px;box-shadow:0 0 3px #00000029;border-radius:5px}.popup-overlay{background:#00000080}[data-popup=tooltip].popup-overlay{background:transparent}.popup-arrow{-webkit-filter:drop-shadow(0 -3px 3px rgba(0,0,0,.16));filter:drop-shadow(0 -3px 3px rgba(0,0,0,.16));color:#fff;stroke-width:2px;stroke:#d7d7d7;stroke-dasharray:30px;stroke-dashoffset:-54px;left:0;right:0;top:0;bottom:0}
@@ -1,6 +1,6 @@
1
1
  import { HideAtProps } from '../HideAt';
2
2
  export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement>, HideAtProps {
3
- size: "xs" | "sm" | "md" | "lg" | "xl";
3
+ size: "xxs" | "xs" | "sm" | "md" | "lg" | "xl";
4
4
  variant: "primary" | "secondary" | "cta-primary" | "tertiary" | "destructive";
5
5
  disabled?: boolean;
6
6
  }
@@ -1,45 +1,47 @@
1
- import { jsx as r } from "react/jsx-runtime";
2
- import { t as n } from "../../Text.module-smM1g1J4.js";
3
- import { c as i } from "../../clsx-OuTLNxxd.js";
4
- import { getHideAtStyles as c } from "../HideAt.js";
5
- import '../../assets/Button.css';const m = "_button_1co79_1", t = {
1
+ import { jsx as b } from "react/jsx-runtime";
2
+ import { t } from "../../Text.module-smM1g1J4.js";
3
+ import { c as r } from "../../clsx-OuTLNxxd.js";
4
+ import { getHideAtStyles as z } from "../HideAt.js";
5
+ import '../../assets/Button.css';const m = "_button_17viz_1", o = {
6
6
  button: m,
7
- "button-primary": "_button-primary_1co79_36",
8
- "button-secondary": "_button-secondary_1co79_50",
9
- "button-cta-primary": "_button-cta-primary_1co79_72",
10
- "button-tertiary": "_button-tertiary_1co79_86",
11
- "button-destructive": "_button-destructive_1co79_104",
12
- "button-size-xs": "_button-size-xs_1co79_122",
13
- "button-size-sm": "_button-size-sm_1co79_126",
14
- "button-size-md": "_button-size-md_1co79_130",
15
- "button-size-lg": "_button-size-lg_1co79_134",
16
- "button-size-xl": "_button-size-xl_1co79_138"
7
+ "button-primary": "_button-primary_17viz_36",
8
+ "button-secondary": "_button-secondary_17viz_50",
9
+ "button-cta-primary": "_button-cta-primary_17viz_72",
10
+ "button-tertiary": "_button-tertiary_17viz_86",
11
+ "button-destructive": "_button-destructive_17viz_104",
12
+ "button-size-xxs": "_button-size-xxs_17viz_122",
13
+ "button-size-xs": "_button-size-xs_17viz_128",
14
+ "button-size-sm": "_button-size-sm_17viz_135",
15
+ "button-size-md": "_button-size-md_17viz_142",
16
+ "button-size-lg": "_button-size-lg_17viz_149",
17
+ "button-size-xl": "_button-size-xl_17viz_156"
17
18
  };
18
- function l({
19
- children: _,
20
- size: o,
21
- variant: u,
19
+ function y({
20
+ children: n,
21
+ size: i,
22
+ variant: _,
22
23
  hideAt: s,
23
- className: e,
24
- ...b
24
+ className: u,
25
+ ...e
25
26
  }) {
26
- return /* @__PURE__ */ r(
27
+ return /* @__PURE__ */ b(
27
28
  "button",
28
29
  {
29
- className: i(
30
- t.button,
31
- t[`button-${u}`],
32
- t[`button-size-${o}`],
33
- n.text,
34
- n[`text-${o}`],
35
- c(s),
36
- e
30
+ className: r(
31
+ o.button,
32
+ o[`button-${_}`],
33
+ o[`button-size-${i}`],
34
+ t.text,
35
+ t[`text-${i}`],
36
+ t["text-semibold"],
37
+ z(s),
38
+ u
37
39
  ),
38
- ...b,
39
- children: _
40
+ ...e,
41
+ children: n
40
42
  }
41
43
  );
42
44
  }
43
45
  export {
44
- l as Button
46
+ y as Button
45
47
  };
@@ -1,4 +1,4 @@
1
- import { StoryObj } from '@storybook/react';
1
+ import { StoryObj } from '@storybook/react-vite';
2
2
  import { Button } from './Button';
3
3
  declare const meta: {
4
4
  title: string;
@@ -1,8 +1,8 @@
1
- import { jsx as r, jsxs as s } from "react/jsx-runtime";
2
- import { Button as e } from "./Button.js";
3
- const c = {
1
+ import { jsx as t, jsxs as s } from "react/jsx-runtime";
2
+ import { Button as r } from "./Button.js";
3
+ const n = {
4
4
  title: "Case Parts/Atoms/Button",
5
- component: e,
5
+ component: r,
6
6
  parameters: {
7
7
  // Optional parameter to center the component in the Canvas. More info: https://storybook.js.org/docs/configure/story-layout
8
8
  layout: "centered"
@@ -11,8 +11,8 @@ const c = {
11
11
  tags: ["autodocs"]
12
12
  }, l = {
13
13
  args: {
14
- children: "Button Text",
15
- size: "sm",
14
+ children: "Text",
15
+ size: "md",
16
16
  variant: "primary"
17
17
  }
18
18
  }, a = [
@@ -22,19 +22,16 @@ const c = {
22
22
  "cta-primary",
23
23
  "destructive"
24
24
  ], p = {
25
- render: () => /* @__PURE__ */ r("div", { style: { display: "flex", flexDirection: "column", gap: "10px" }, children: a.map((t) => /* @__PURE__ */ s(e, { variant: t, size: "md", children: [
26
- t.charAt(0).toUpperCase() + t.slice(1),
27
- " Button"
28
- ] }, t)) })
29
- }, o = ["xs", "sm", "md", "lg", "xl"], m = {
30
- render: () => /* @__PURE__ */ r("div", { style: { display: "flex", flexDirection: "column", gap: "10px" }, children: o.map((t) => /* @__PURE__ */ s(e, { size: t, variant: "primary", children: [
31
- t.charAt(0).toUpperCase() + t.slice(1),
32
- " Button"
33
- ] }, t)) })
25
+ render: () => /* @__PURE__ */ t("div", { style: { display: "flex", flexDirection: "column", gap: "10px" }, children: a.map((e) => /* @__PURE__ */ t(r, { variant: e, size: "md", children: e.charAt(0).toUpperCase() + e.slice(1) }, e)) })
26
+ }, o = ["xxs", "xs", "sm", "md", "lg", "xl"], m = {
27
+ render: () => /* @__PURE__ */ t("div", { style: { display: "flex", flexDirection: "column", gap: "10px" }, children: o.map((e) => /* @__PURE__ */ s(r, { size: e, variant: "primary", children: [
28
+ e.charAt(0).toUpperCase() + e.slice(1).toUpperCase(),
29
+ " Btn"
30
+ ] }, e)) })
34
31
  };
35
32
  export {
36
33
  l as AllProps,
37
34
  m as Sizes,
38
35
  p as Variants,
39
- c as default
36
+ n as default
40
37
  };
@@ -1,4 +1,4 @@
1
- import { StoryObj } from '@storybook/react';
1
+ import { StoryObj } from '@storybook/react-vite';
2
2
  import { Flex } from './Flex';
3
3
  declare const meta: {
4
4
  title: string;
@@ -1,4 +1,4 @@
1
- import { StoryObj } from '@storybook/react';
1
+ import { StoryObj } from '@storybook/react-vite';
2
2
  import { Grid } from './Grid';
3
3
  declare const meta: {
4
4
  title: string;
@@ -1,33 +1,33 @@
1
1
  import { jsx as r } from "react/jsx-runtime";
2
- import { c as l } from "../../clsx-OuTLNxxd.js";
3
- import { getHideAtStyles as _ } from "../HideAt.js";
4
- import '../../assets/Icon.css';const e = {
5
- "icon-sm": "_icon-sm_flrgw_1",
6
- "icon-md": "_icon-md_flrgw_6",
7
- "icon-lg": "_icon-lg_flrgw_11"
2
+ import { c as _ } from "../../clsx-OuTLNxxd.js";
3
+ import { getHideAtStyles as e } from "../HideAt.js";
4
+ import '../../assets/Icon.css';const l = {
5
+ "icon-sm": "_icon-sm_nwr4s_1",
6
+ "icon-md": "_icon-md_nwr4s_6",
7
+ "icon-lg": "_icon-lg_nwr4s_11"
8
8
  };
9
- function d({
9
+ function a({
10
10
  iconKey: o,
11
- size: c = "md",
12
- hideAt: i,
13
- className: n,
14
- ...s
11
+ size: n = "md",
12
+ hideAt: s,
13
+ className: c,
14
+ ...i
15
15
  }) {
16
16
  const [t, m] = o.split(" ");
17
17
  return /* @__PURE__ */ r(
18
18
  "i",
19
19
  {
20
- className: l(
20
+ className: _(
21
21
  t,
22
22
  m,
23
- e[`icon-${c}`],
24
- _(i),
25
- n
23
+ l[`icon-${n}`],
24
+ e(s),
25
+ c
26
26
  ),
27
- ...s
27
+ ...i
28
28
  }
29
29
  );
30
30
  }
31
31
  export {
32
- d as Icon
32
+ a as Icon
33
33
  };
@@ -1,4 +1,4 @@
1
- import { StoryObj } from '@storybook/react';
1
+ import { StoryObj } from '@storybook/react-vite';
2
2
  import { Icon } from './Icon';
3
3
  declare const meta: {
4
4
  title: string;
@@ -1,4 +1,4 @@
1
- import { StoryObj } from '@storybook/react';
1
+ import { StoryObj } from '@storybook/react-vite';
2
2
  declare const meta: {
3
3
  title: string;
4
4
  component: import('react').ForwardRefExoticComponent<import('./Input').InputProps & import('react').RefAttributes<HTMLInputElement>>;
@@ -1,4 +1,4 @@
1
- import { StoryObj } from '@storybook/react';
1
+ import { StoryObj } from '@storybook/react-vite';
2
2
  import { Link } from './Link';
3
3
  declare const meta: {
4
4
  title: string;
@@ -1,4 +1,4 @@
1
- import { StoryObj } from '@storybook/react';
1
+ import { StoryObj } from '@storybook/react-vite';
2
2
  import { Separator } from './Separator';
3
3
  declare const meta: {
4
4
  title: string;
@@ -1,4 +1,4 @@
1
- import { StoryObj } from '@storybook/react';
1
+ import { StoryObj } from '@storybook/react-vite';
2
2
  import { Text } from './Text';
3
3
  declare const meta: {
4
4
  title: string;
@@ -1,3 +1,4 @@
1
+ import { default as React } from 'react';
1
2
  import { HideAtProps } from '../../atoms/HideAt';
2
3
  /** Base props shared by all account types */
3
4
  export interface AccountProps extends React.HTMLAttributes<HTMLDivElement>, HideAtProps {
@@ -9,5 +10,7 @@ export interface AccountProps extends React.HTMLAttributes<HTMLDivElement>, Hide
9
10
  /** The account user's initials. */
10
11
  initials: string;
11
12
  };
13
+ accountRoute: string;
14
+ onLoginClick: () => void;
12
15
  }
13
16
  export declare function Account(props: AccountProps): import("react/jsx-runtime").JSX.Element;
@@ -1,66 +1,89 @@
1
- import { jsx as i, jsxs as r } from "react/jsx-runtime";
2
- import { getHideAtStyles as d } from "../../atoms/HideAt.js";
3
- import { Icon as g } from "../../atoms/Icon/Icon.js";
4
- import { Text as n } from "../../atoms/Text/Text.js";
5
- import { Avatar as c } from "../Avatar/Avatar.js";
6
- import { Flex as t } from "../../atoms/Flex/Flex.js";
7
- import { Button as f } from "../../atoms/Button/Button.js";
8
- import { c as a } from "../../clsx-OuTLNxxd.js";
9
- import { Link as u } from "../../atoms/Link/Link.js";
10
- import '../../assets/Account.css';const h = "_loggedIn_iiyge_1", x = "_customer_iiyge_5", o = {
11
- loggedIn: h,
12
- customer: x
1
+ import { jsx as i, jsxs as n } from "react/jsx-runtime";
2
+ import { getHideAtStyles as o } from "../../atoms/HideAt.js";
3
+ import { Icon as f } from "../../atoms/Icon/Icon.js";
4
+ import { Text as m } from "../../atoms/Text/Text.js";
5
+ import { Avatar as a } from "../Avatar/Avatar.js";
6
+ import { Flex as r } from "../../atoms/Flex/Flex.js";
7
+ import { Button as h } from "../../atoms/Button/Button.js";
8
+ import { c as s } from "../../clsx-OuTLNxxd.js";
9
+ import { Link as x } from "../../atoms/Link/Link.js";
10
+ import '../../assets/Account.css';const u = "_loggedIn_1uin2_1", t = {
11
+ loggedIn: u
13
12
  };
14
13
  function A(e) {
15
14
  return e.account !== void 0;
16
15
  }
17
- function H(e) {
18
- return A(e) ? /* @__PURE__ */ i(I, { ...e }) : /* @__PURE__ */ i(p, { ...e });
16
+ function w(e) {
17
+ return A(e) ? /* @__PURE__ */ i(I, { ...e }) : /* @__PURE__ */ i(k, { ...e });
19
18
  }
20
19
  function I({
21
20
  account: e,
22
- className: m,
23
- hideAt: s,
24
- ...l
21
+ accountRoute: l,
22
+ onLoginClick: y,
23
+ className: d,
24
+ hideAt: g,
25
+ ...c
25
26
  }) {
26
- return /* @__PURE__ */ r(
27
- t,
27
+ return /* @__PURE__ */ n(
28
+ r,
28
29
  {
29
30
  flexDirection: "row",
30
31
  alignItems: "center",
31
- className: a(o.loggedIn, d(s), m),
32
- ...l,
32
+ className: s(t.loggedIn, o(g), d),
33
+ ...c,
33
34
  children: [
34
- /* @__PURE__ */ r(
35
- t,
35
+ /* @__PURE__ */ n(
36
+ r,
36
37
  {
37
38
  flexDirection: "column",
38
39
  alignItems: "flex-end",
39
40
  hideAt: ["sm", "md"],
40
- className: o.customer,
41
+ className: t.customer,
41
42
  children: [
42
- /* @__PURE__ */ r(n, { size: "xxs", children: [
43
+ /* @__PURE__ */ n(m, { size: "xxs", children: [
43
44
  "Acct: ",
44
45
  e == null ? void 0 : e.number
45
46
  ] }),
46
- /* @__PURE__ */ i(u, { href: "#", children: /* @__PURE__ */ r(n, { size: "sm", variant: "display", children: [
47
+ /* @__PURE__ */ i(x, { href: l, children: /* @__PURE__ */ n(m, { size: "sm", variant: "display", children: [
47
48
  "Hello ",
48
49
  e == null ? void 0 : e.name
49
50
  ] }) })
50
51
  ]
51
52
  }
52
53
  ),
53
- /* @__PURE__ */ i(c, { initials: e.initials })
54
+ /* @__PURE__ */ i(a, { initials: e.initials, accountRoute: l })
54
55
  ]
55
56
  }
56
57
  );
57
58
  }
58
- function p(e) {
59
- return /* @__PURE__ */ r(t, { flexDirection: "row", alignItems: "center", ...e, children: [
60
- /* @__PURE__ */ i(f, { size: "sm", variant: "primary", hideAt: ["sm", "md"], children: "Sign In / Register" }),
61
- /* @__PURE__ */ i(g, { iconKey: "fa-kit fa-user-anon", size: "lg", hideAt: "lg" })
62
- ] });
59
+ function k(e) {
60
+ return /* @__PURE__ */ n(
61
+ r,
62
+ {
63
+ flexDirection: "row",
64
+ alignItems: "center",
65
+ ...e,
66
+ className: s(
67
+ t.unauthenticated,
68
+ o(e.hideAt),
69
+ e.className
70
+ ),
71
+ children: [
72
+ /* @__PURE__ */ i(
73
+ h,
74
+ {
75
+ onClick: e.onLoginClick,
76
+ size: "sm",
77
+ variant: "primary",
78
+ hideAt: ["sm", "md"],
79
+ children: "Sign In / Register"
80
+ }
81
+ ),
82
+ /* @__PURE__ */ i(f, { iconKey: "fa-kit fa-user-anon", size: "lg", hideAt: "lg" })
83
+ ]
84
+ }
85
+ );
63
86
  }
64
87
  export {
65
- H as Account
88
+ w as Account
66
89
  };
@@ -1,4 +1,4 @@
1
- import { StoryObj } from '@storybook/react';
1
+ import { StoryObj } from '@storybook/react-vite';
2
2
  import { Account } from './Account';
3
3
  declare const meta: {
4
4
  title: string;
@@ -1,5 +1,5 @@
1
1
  import { Account as t } from "./Account.js";
2
- const a = {
2
+ const c = {
3
3
  title: "Case Parts/Molecules/Account",
4
4
  component: t,
5
5
  parameters: {
@@ -9,18 +9,25 @@ const a = {
9
9
  // This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/writing-docs/autodocs
10
10
  tags: ["autodocs"]
11
11
  }, n = {
12
- args: {}
13
- }, o = {
12
+ args: {
13
+ accountRoute: "/account",
14
+ onLoginClick: () => {
15
+ }
16
+ }
17
+ }, a = {
14
18
  args: {
15
19
  account: {
16
20
  name: "Ringo",
17
21
  initials: "RS",
18
22
  number: "123456789012"
23
+ },
24
+ accountRoute: "/account",
25
+ onLoginClick: () => {
19
26
  }
20
27
  }
21
28
  };
22
29
  export {
23
- o as Authenticated,
30
+ a as Authenticated,
24
31
  n as Unauthenticated,
25
- a as default
32
+ c as default
26
33
  };
@@ -2,5 +2,6 @@ import { HideAtProps } from '../../atoms/HideAt';
2
2
  export interface AvatarProps extends React.HTMLAttributes<HTMLDivElement>, HideAtProps {
3
3
  /** The user's initials (2 characters) */
4
4
  initials: string;
5
+ accountRoute: string;
5
6
  }
6
- export declare function Avatar({ initials, className, hideAt, ...otherProps }: AvatarProps): import("react/jsx-runtime").JSX.Element;
7
+ export declare function Avatar({ initials, accountRoute, className, hideAt, ...otherProps }: AvatarProps): import("react/jsx-runtime").JSX.Element;
@@ -1,35 +1,37 @@
1
- import { jsx as s } from "react/jsx-runtime";
2
- import { Flex as i } from "../../atoms/Flex/Flex.js";
3
- import { getHideAtStyles as m } from "../../atoms/HideAt.js";
4
- import { c as n } from "../../clsx-OuTLNxxd.js";
5
- import { t } from "../../Text.module-smM1g1J4.js";
6
- import '../../assets/Avatar.css';const c = "_avatar_1x5y3_1", l = {
7
- avatar: c
1
+ import { jsx as t } from "react/jsx-runtime";
2
+ import { Flex as m } from "../../atoms/Flex/Flex.js";
3
+ import { Link as n } from "../../atoms/Link/Link.js";
4
+ import { getHideAtStyles as c } from "../../atoms/HideAt.js";
5
+ import { c as l } from "../../clsx-OuTLNxxd.js";
6
+ import { t as r } from "../../Text.module-smM1g1J4.js";
7
+ import '../../assets/Avatar.css';const f = "_avatar_vwzwk_1", p = {
8
+ avatar: f
8
9
  };
9
- function d({
10
- initials: r,
11
- className: e,
12
- hideAt: a,
13
- ...o
10
+ function h({
11
+ initials: e,
12
+ accountRoute: a,
13
+ className: o,
14
+ hideAt: i,
15
+ ...s
14
16
  }) {
15
- return /* @__PURE__ */ s(
16
- i,
17
+ return /* @__PURE__ */ t(n, { href: a, children: /* @__PURE__ */ t(
18
+ m,
17
19
  {
18
20
  flexDirection: "row",
19
21
  alignItems: "center",
20
22
  justifyContent: "center",
21
- className: n(
22
- l.avatar,
23
- t["text-display"],
24
- t["text-md"],
25
- m(a),
26
- e
23
+ className: l(
24
+ p.avatar,
25
+ r["text-display"],
26
+ r["text-md"],
27
+ c(i),
28
+ o
27
29
  ),
28
- ...o,
29
- children: r.substring(0, 2)
30
+ ...s,
31
+ children: e.substring(0, 2)
30
32
  }
31
- );
33
+ ) });
32
34
  }
33
35
  export {
34
- d as Avatar
36
+ h as Avatar
35
37
  };
@@ -1,4 +1,4 @@
1
- import { StoryObj } from '@storybook/react';
1
+ import { StoryObj } from '@storybook/react-vite';
2
2
  import { Avatar } from './Avatar';
3
3
  declare const meta: {
4
4
  title: string;
@@ -9,7 +9,10 @@ const e = {
9
9
  // This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/writing-docs/autodocs
10
10
  tags: ["autodocs"]
11
11
  }, o = {
12
- args: { initials: "RS" }
12
+ args: {
13
+ initials: "RS",
14
+ accountRoute: "/account"
15
+ }
13
16
  };
14
17
  export {
15
18
  o as Default,
@@ -0,0 +1,7 @@
1
+ import { default as React } from 'react';
2
+ interface cartProps extends React.HtmlHTMLAttributes<HTMLButtonElement> {
3
+ onClick: () => void;
4
+ cartItemCount: number;
5
+ }
6
+ export declare function Cart({ onClick, cartItemCount, ...otherProps }: cartProps): import("react/jsx-runtime").JSX.Element;
7
+ export {};
@@ -0,0 +1,23 @@
1
+ import { jsxs as s, jsx as t } from "react/jsx-runtime";
2
+ import { Icon as i } from "../../atoms/Icon/Icon.js";
3
+ import { Text as a } from "../../atoms/Text/Text.js";
4
+ import '../../assets/Cart.css';const e = "_cart_jjkwa_1", p = "_count_jjkwa_8", o = {
5
+ cart: e,
6
+ count: p
7
+ };
8
+ function j({ onClick: r, cartItemCount: c, ...n }) {
9
+ return /* @__PURE__ */ s("button", { onClick: r, className: o.cart, ...n, children: [
10
+ /* @__PURE__ */ t(
11
+ i,
12
+ {
13
+ iconKey: "fa-kit fa-shoppingcart-empty",
14
+ title: "Shopping Cart",
15
+ size: "lg"
16
+ }
17
+ ),
18
+ c > 0 && /* @__PURE__ */ t("div", { className: o.count, children: /* @__PURE__ */ t(a, { size: "xxs", children: c }) })
19
+ ] });
20
+ }
21
+ export {
22
+ j as Cart
23
+ };
@@ -0,0 +1,14 @@
1
+ import { StoryObj } from '@storybook/react-vite';
2
+ import { Cart } from './Cart';
3
+ declare const meta: {
4
+ title: string;
5
+ component: typeof Cart;
6
+ parameters: {
7
+ layout: string;
8
+ };
9
+ tags: string[];
10
+ };
11
+ export default meta;
12
+ type Story = StoryObj<typeof meta>;
13
+ export declare const EmptyCart: Story;
14
+ export declare const CartWithItems: Story;
@@ -0,0 +1,24 @@
1
+ import { Cart as t } from "./Cart.js";
2
+ const e = {
3
+ title: "Case Parts/Molecules/Cart",
4
+ component: t,
5
+ parameters: {
6
+ layout: "centered"
7
+ },
8
+ tags: ["autodocs"]
9
+ }, r = {
10
+ args: {
11
+ cartItemCount: 0,
12
+ onClick: () => alert("Cart clicked")
13
+ }
14
+ }, o = {
15
+ args: {
16
+ cartItemCount: 15,
17
+ onClick: () => alert("Cart clicked")
18
+ }
19
+ };
20
+ export {
21
+ o as CartWithItems,
22
+ r as EmptyCart,
23
+ e as default
24
+ };
@@ -1,4 +1,4 @@
1
- import { StoryObj } from '@storybook/react';
1
+ import { StoryObj } from '@storybook/react-vite';
2
2
  import { Chip } from './Chip';
3
3
  declare const meta: {
4
4
  title: string;
@@ -0,0 +1,7 @@
1
+ import { default as React } from 'react';
2
+ import { HideAtProps } from '../../atoms/HideAt';
3
+ interface HamburgerMenuProps extends HideAtProps {
4
+ children: React.ReactNode;
5
+ }
6
+ export declare function HamburgerMenu({ hideAt, children }: HamburgerMenuProps): import("react/jsx-runtime").JSX.Element;
7
+ export {};