@caseparts-org/caseblocks 0.0.1

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 (93) hide show
  1. package/README.md +97 -0
  2. package/dist/Text.module-ruz24ug-.js +25 -0
  3. package/dist/assets/Account.css +1 -0
  4. package/dist/assets/Avatar.css +1 -0
  5. package/dist/assets/Button.css +1 -0
  6. package/dist/assets/Chip.css +1 -0
  7. package/dist/assets/ChipSelector.css +1 -0
  8. package/dist/assets/Flex.css +1 -0
  9. package/dist/assets/Flex2.css +1 -0
  10. package/dist/assets/Grid.css +1 -0
  11. package/dist/assets/HideAt.css +1 -0
  12. package/dist/assets/Icon.css +1 -0
  13. package/dist/assets/Link.css +1 -0
  14. package/dist/assets/Logo.css +1 -0
  15. package/dist/assets/MainNav.css +1 -0
  16. package/dist/assets/Root.css +1 -0
  17. package/dist/assets/SearchBox.css +1 -0
  18. package/dist/assets/Separator.css +1 -0
  19. package/dist/assets/Text.css +1 -0
  20. package/dist/assets/ToggleView.css +1 -0
  21. package/dist/atoms/Button/Button.d.ts +7 -0
  22. package/dist/atoms/Button/Button.js +45 -0
  23. package/dist/atoms/Button/Button.stories.d.ts +15 -0
  24. package/dist/atoms/Button/Button.stories.js +40 -0
  25. package/dist/atoms/Flex/Flex.d.ts +13 -0
  26. package/dist/atoms/Flex/Flex.js +35 -0
  27. package/dist/atoms/Flex/Flex.stories.d.ts +14 -0
  28. package/dist/atoms/Flex/Flex.stories.js +131 -0
  29. package/dist/atoms/Grid/Grid.d.ts +25 -0
  30. package/dist/atoms/Grid/Grid.js +40 -0
  31. package/dist/atoms/Grid/Grid.stories.d.ts +17 -0
  32. package/dist/atoms/Grid/Grid.stories.js +58 -0
  33. package/dist/atoms/HideAt.d.ts +9 -0
  34. package/dist/atoms/HideAt.js +15 -0
  35. package/dist/atoms/Icon/Icon.d.ts +8 -0
  36. package/dist/atoms/Icon/Icon.js +33 -0
  37. package/dist/atoms/Icon/Icon.stories.d.ts +14 -0
  38. package/dist/atoms/Icon/Icon.stories.js +28 -0
  39. package/dist/atoms/Link/Link.d.ts +7 -0
  40. package/dist/atoms/Link/Link.js +35 -0
  41. package/dist/atoms/Link/Link.stories.d.ts +13 -0
  42. package/dist/atoms/Link/Link.stories.js +21 -0
  43. package/dist/atoms/ResponsiveProp.d.ts +2 -0
  44. package/dist/atoms/ResponsiveProp.js +14 -0
  45. package/dist/atoms/Root/Head.d.ts +1 -0
  46. package/dist/atoms/Root/Head.js +13 -0
  47. package/dist/atoms/Root/Root.d.ts +4 -0
  48. package/dist/atoms/Root/Root.js +10 -0
  49. package/dist/atoms/Separator/Separator.d.ts +7 -0
  50. package/dist/atoms/Separator/Separator.js +30 -0
  51. package/dist/atoms/Separator/Separator.stories.d.ts +13 -0
  52. package/dist/atoms/Separator/Separator.stories.js +33 -0
  53. package/dist/atoms/Text/Text.d.ts +15 -0
  54. package/dist/atoms/Text/Text.js +32 -0
  55. package/dist/atoms/Text/Text.stories.d.ts +17 -0
  56. package/dist/atoms/Text/Text.stories.js +89 -0
  57. package/dist/clsx-OuTLNxxd.js +16 -0
  58. package/dist/main.d.ts +29 -0
  59. package/dist/main.js +37 -0
  60. package/dist/molecules/Account/Account.d.ts +13 -0
  61. package/dist/molecules/Account/Account.js +66 -0
  62. package/dist/molecules/Account/Account.stories.d.ts +14 -0
  63. package/dist/molecules/Account/Account.stories.js +26 -0
  64. package/dist/molecules/Avatar/Avatar.d.ts +6 -0
  65. package/dist/molecules/Avatar/Avatar.js +35 -0
  66. package/dist/molecules/Avatar/Avatar.stories.d.ts +13 -0
  67. package/dist/molecules/Avatar/Avatar.stories.js +17 -0
  68. package/dist/molecules/Chip/Chip.d.ts +57 -0
  69. package/dist/molecules/Chip/Chip.js +71 -0
  70. package/dist/molecules/Chip/Chip.stories.d.ts +15 -0
  71. package/dist/molecules/Chip/Chip.stories.js +53 -0
  72. package/dist/molecules/Logo/Logo.d.ts +1 -0
  73. package/dist/molecules/Logo/Logo.js +53 -0
  74. package/dist/molecules/Logo/Logo.stories.d.ts +13 -0
  75. package/dist/molecules/Logo/Logo.stories.js +17 -0
  76. package/dist/molecules/SearchBox/SearchBox.d.ts +6 -0
  77. package/dist/molecules/SearchBox/SearchBox.js +60 -0
  78. package/dist/molecules/SearchBox/SearchBox.stories.d.ts +12 -0
  79. package/dist/molecules/SearchBox/SearchBox.stories.js +15 -0
  80. package/dist/molecules/ToggleView/ToggleView.d.ts +75 -0
  81. package/dist/molecules/ToggleView/ToggleView.js +102 -0
  82. package/dist/molecules/ToggleView/ToggleView.stories.d.ts +13 -0
  83. package/dist/molecules/ToggleView/ToggleView.stories.js +24 -0
  84. package/dist/organisms/ChipSelector/ChipSelector.d.ts +12 -0
  85. package/dist/organisms/ChipSelector/ChipSelector.js +43 -0
  86. package/dist/organisms/ChipSelector/ChipSelector.stories.d.ts +14 -0
  87. package/dist/organisms/ChipSelector/ChipSelector.stories.js +51 -0
  88. package/dist/organisms/MainNav/MainNav.d.ts +4 -0
  89. package/dist/organisms/MainNav/MainNav.js +103 -0
  90. package/dist/organisms/MainNav/MainNav.stories.d.ts +13 -0
  91. package/dist/organisms/MainNav/MainNav.stories.js +24 -0
  92. package/dist/styles/tokens.css +243 -0
  93. package/package.json +73 -0
@@ -0,0 +1,71 @@
1
+ import { jsxs as o, jsx as i } from "react/jsx-runtime";
2
+ import { c as u } from "../../clsx-OuTLNxxd.js";
3
+ import { getHideAtStyles as f } from "../../atoms/HideAt.js";
4
+ import { Icon as x } from "../../atoms/Icon/Icon.js";
5
+ import { Text as c } from "../../atoms/Text/Text.js";
6
+ import { Flex as h } from "../../atoms/Flex/Flex.js";
7
+ import '../../assets/Chip.css';const k = "_chip_mklpn_1", y = "_disabled_mklpn_10", g = "_selected_mklpn_16", B = "_unselected_mklpn_21", C = "_dismissable_mklpn_27", j = "_dismissButton_mklpn_31", w = "_pill_mklpn_47", s = {
8
+ chip: k,
9
+ disabled: y,
10
+ selected: g,
11
+ unselected: B,
12
+ dismissable: C,
13
+ dismissButton: j,
14
+ pill: w
15
+ };
16
+ function H({
17
+ selected: m,
18
+ text: n,
19
+ hideAt: d,
20
+ className: r,
21
+ disabled: l = !1,
22
+ count: t = void 0,
23
+ variant: e = "selectable",
24
+ styleVariant: p = "primary",
25
+ // Default style variant
26
+ onDismiss: a,
27
+ onSelect: _,
28
+ ...b
29
+ }) {
30
+ return /* @__PURE__ */ o(
31
+ h,
32
+ {
33
+ flexDirection: "row",
34
+ alignItems: "center",
35
+ justifyContent: "center",
36
+ className: u(
37
+ s.chip,
38
+ l && s.disabled,
39
+ e === "selectable" && (m ? s.selected : s.unselected),
40
+ e === "dismissable" && s.dismissable,
41
+ e === "pill" && s.pill,
42
+ e === "dismissable" && s[p],
43
+ // Apply style variant
44
+ f(d),
45
+ r
46
+ ),
47
+ onClick: e === "selectable" && !l ? _ : void 0,
48
+ ...b,
49
+ children: [
50
+ /* @__PURE__ */ i(c, { size: "xxs", variant: "body", weight: "regular", children: n }),
51
+ typeof t == "number" && /* @__PURE__ */ o(c, { size: "xxs", variant: "body", weight: "regular", children: [
52
+ "(",
53
+ t,
54
+ ")"
55
+ ] }),
56
+ e === "dismissable" && /* @__PURE__ */ i(
57
+ "button",
58
+ {
59
+ className: s.dismissButton,
60
+ onClick: a,
61
+ "aria-label": "Dismiss",
62
+ children: /* @__PURE__ */ i(x, { iconKey: "fa-solid fa-xmark", size: "sm", title: "close" })
63
+ }
64
+ )
65
+ ]
66
+ }
67
+ );
68
+ }
69
+ export {
70
+ H as Chip
71
+ };
@@ -0,0 +1,15 @@
1
+ import { StoryObj } from '@storybook/react';
2
+ import { Chip } from './Chip';
3
+ declare const meta: {
4
+ title: string;
5
+ component: typeof Chip;
6
+ parameters: {
7
+ layout: string;
8
+ };
9
+ tags: string[];
10
+ };
11
+ export default meta;
12
+ type Story = StoryObj<typeof meta>;
13
+ export declare const AllProps: Story;
14
+ export declare const Variants: StoryObj<typeof Chip>;
15
+ export declare const States: StoryObj<typeof Chip>;
@@ -0,0 +1,53 @@
1
+ import { jsxs as a, jsx as t, Fragment as l } from "react/jsx-runtime";
2
+ import { Chip as e } from "./Chip.js";
3
+ const r = {
4
+ title: "Case Parts/Molecules/Chip",
5
+ component: e,
6
+ parameters: {
7
+ // Optional parameter to center the component in the Canvas. More info: https://storybook.js.org/docs/configure/story-layout
8
+ layout: "centered"
9
+ },
10
+ // This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/writing-docs/autodocs
11
+ tags: ["autodocs"]
12
+ }, n = {
13
+ args: {
14
+ text: "Selected",
15
+ variant: "selectable",
16
+ count: 5,
17
+ selected: !0
18
+ }
19
+ }, i = {
20
+ render: () => /* @__PURE__ */ a("div", { style: { display: "flex", flexDirection: "column", gap: "10px" }, children: [
21
+ /* @__PURE__ */ t(
22
+ e,
23
+ {
24
+ variant: "selectable",
25
+ selected: !0,
26
+ count: 5,
27
+ text: "Selected Chip"
28
+ }
29
+ ),
30
+ /* @__PURE__ */ t(
31
+ e,
32
+ {
33
+ variant: "selectable",
34
+ selected: !1,
35
+ count: 5,
36
+ text: "Unselected Chip"
37
+ }
38
+ ),
39
+ /* @__PURE__ */ t(e, { variant: "dismissable", text: "Dismissable Chip" }),
40
+ /* @__PURE__ */ t(e, { variant: "pill", text: "Pill Variant" })
41
+ ] })
42
+ }, o = {
43
+ render: () => /* @__PURE__ */ a(l, { children: [
44
+ /* @__PURE__ */ t(e, { variant: "selectable", selected: !0, count: 5, text: "Selected" }),
45
+ /* @__PURE__ */ t(e, { variant: "selectable", selected: !1, count: 5, text: "Unselected" })
46
+ ] })
47
+ };
48
+ export {
49
+ n as AllProps,
50
+ o as States,
51
+ i as Variants,
52
+ r as default
53
+ };
@@ -0,0 +1 @@
1
+ export declare function Logo(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,53 @@
1
+ import { jsxs as e, jsx as C } from "react/jsx-runtime";
2
+ import { Text as n } from "../../atoms/Text/Text.js";
3
+ import { Flex as i } from "../../atoms/Flex/Flex.js";
4
+ import '../../assets/Logo.css';const r = "_container_16m6g_1", a = "_wordmark_16m6g_11", o = "_tagline_16m6g_19", t = {
5
+ container: r,
6
+ wordmark: a,
7
+ tagline: o
8
+ }, s = "data:image/svg+xml,%3csvg%20width='36'%20height='36'%20viewBox='0%200%2036%2036'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20id='icon'%20d='M4.6%206.0663C7.9%202.38674%2012.7%200%2018.1%200C23%200%2027.4%201.98895%2030.7%205.07182H8.4C7%205.07182%205.7%205.46961%204.6%206.0663ZM6.4%2013.0276C6.4%2014.1215%207.3%2015.0166%208.4%2015.0166H33.4C34.3%2015.0166%2035.2%2015.2155%2036%2015.4144C35.8%2013.8232%2035.4%2012.4309%2034.8%2011.0387H8.4C7.3%2011.0387%206.4%2011.9337%206.4%2013.0276ZM11.4%2030.9282V34.7072C13.5%2035.5028%2015.7%2036%2018.1%2036C23%2036%2027.4%2034.011%2030.7%2030.9282H11.4ZM5.4%2027.9448C5.4%2026.2541%206.7%2024.9613%208.4%2024.9613H33.4C34.5%2024.9613%2035.4%2024.0663%2035.4%2022.9724C35.4%2021.8785%2034.5%2020.9834%2033.4%2020.9834H8.4C4.3%2020.9834%200.9%2017.9006%200.5%2013.9227C0.2%2015.2155%200%2016.6077%200%2018C0%2023.0718%202.1%2027.547%205.4%2030.8287V27.9448Z'%20fill='%231380B1'%20/%3e%3c/svg%3e", l = "data:image/svg+xml,%3csvg%20width='140'%20height='22'%20viewBox='0%200%20140%2022'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20id='wordmark'%20d='M14.925%201.86855C16.325%203.26855%2017.125%205.16855%2017.325%207.66855V7.76855H12.525C12.425%206.36855%2012.125%205.36855%2011.625%204.66855C11.125%203.96855%2010.125%203.66855%208.825%203.66855C7.725%203.66855%206.825%204.16855%206.125%205.06855C5.425%205.96855%205.125%207.16855%205.125%208.66855V13.1685C5.125%2014.6685%205.525%2015.8685%206.225%2016.7685C6.925%2017.6685%207.925%2018.1685%209.125%2018.1685C10.325%2018.1685%2011.125%2017.8685%2011.625%2017.1685C12.125%2016.4685%2012.425%2015.5685%2012.425%2014.1685H17.225V14.2685C17.125%2016.7685%2016.425%2018.6685%2015.025%2019.9685C13.625%2021.2685%2011.625%2021.9685%209.025%2021.9685C6.425%2021.9685%204.225%2021.1685%202.625%2019.5685C1.025%2017.9685%200.125%2015.8685%200.125%2013.2685V8.76855C0.125%206.16855%200.924998%204.06855%202.525%202.46855C4.125%200.868548%206.225%200.0685483%208.725%200.0685483C11.425%20-0.231452%2013.425%200.468548%2014.925%201.86855ZM33.425%2019.2685C33.525%2019.9685%2033.825%2020.6685%2034.025%2021.4685H29.125C29.025%2021.1685%2028.825%2020.9685%2028.725%2020.6685C28.625%2020.3685%2028.525%2020.0685%2028.425%2019.6685C27.925%2020.3685%2027.425%2020.8685%2026.725%2021.2685C26.025%2021.6685%2025.225%2021.8685%2024.325%2021.8685C22.825%2021.8685%2021.625%2021.4685%2020.625%2020.5685C19.625%2019.6685%2019.225%2018.5685%2019.225%2017.0685C19.225%2015.4685%2019.825%2014.2685%2021.025%2013.4685C22.225%2012.6685%2024.025%2012.1685%2026.425%2012.1685H28.325V11.0685C28.325%2010.3685%2028.125%209.86855%2027.825%209.46855C27.525%209.06855%2027.025%208.96855%2026.325%208.96855C25.725%208.96855%2025.325%209.06855%2025.025%209.36855C24.725%209.66855%2024.625%2010.0685%2024.625%2010.6685H19.825V10.5685C19.725%209.16855%2020.325%207.86855%2021.625%206.96855C22.925%206.06855%2024.525%205.46855%2026.625%205.46855C28.625%205.46855%2030.125%205.96855%2031.425%206.96855C32.725%207.96855%2033.225%209.36855%2033.225%2011.1685V17.1685C33.225%2017.7685%2033.325%2018.5685%2033.425%2019.2685ZM28.325%2014.6685H26.525C25.725%2014.6685%2025.225%2014.8685%2024.825%2015.2685C24.425%2015.6685%2024.325%2016.0685%2024.325%2016.6685C24.325%2017.0685%2024.525%2017.4685%2024.825%2017.7685C25.125%2018.0685%2025.525%2018.1685%2026.025%2018.1685C26.525%2018.1685%2026.925%2018.0685%2027.325%2017.8685C27.725%2017.6685%2028.025%2017.4685%2028.325%2017.0685V14.6685ZM43.825%2011.8685C42.625%2011.6685%2041.825%2011.3685%2041.325%2011.0685C40.925%2010.7685%2040.725%2010.4685%2040.725%209.96855C40.725%209.56855%2040.925%209.16855%2041.225%208.86855C41.525%208.56855%2042.025%208.46855%2042.525%208.46855C43.225%208.46855%2043.725%208.66855%2044.025%208.96855C44.325%209.26855%2044.525%209.76855%2044.525%2010.3685H49.325V10.2685C49.425%208.76855%2048.825%207.56855%2047.525%206.56855C46.225%205.56855%2044.625%205.16855%2042.525%205.16855C40.525%205.16855%2038.925%205.66855%2037.725%206.66855C36.525%207.66855%2035.925%208.86855%2035.925%2010.2685C35.925%2011.5685%2036.425%2012.6685%2037.325%2013.3685C38.225%2014.0685%2039.625%2014.6685%2041.525%2015.0685C42.725%2015.2685%2043.525%2015.5685%2043.925%2015.8685C44.325%2016.1685%2044.625%2016.5685%2044.625%2016.8685C44.625%2017.3685%2044.425%2017.6685%2044.125%2017.9685C43.825%2018.2685%2043.325%2018.3685%2042.625%2018.3685C41.825%2018.3685%2041.225%2018.1685%2040.725%2017.8685C40.325%2017.5685%2040.025%2016.9685%2040.025%2016.2685H35.525V16.3685C35.425%2017.6685%2036.025%2018.9685%2037.325%2020.0685C38.625%2021.1685%2040.325%2021.6685%2042.425%2021.6685C44.525%2021.6685%2046.225%2021.1685%2047.425%2020.2685C48.725%2019.3685%2049.325%2018.1685%2049.325%2016.7685C49.325%2015.3685%2048.825%2014.2685%2047.925%2013.5685C47.125%2012.8685%2045.725%2012.2685%2043.825%2011.8685ZM64.025%207.16855C65.225%208.46855%2065.825%2010.1685%2065.825%2012.3685V14.9685H56.725V15.0685C56.825%2015.8685%2057.125%2016.5685%2057.725%2017.0685C58.325%2017.5685%2059.025%2017.8685%2059.925%2017.8685C60.825%2017.8685%2061.625%2017.7685%2062.125%2017.6685C62.625%2017.5685%2063.425%2017.2685%2064.225%2016.8685L65.425%2019.8685C64.725%2020.3685%2063.825%2020.7685%2062.725%2021.1685C61.625%2021.5685%2060.425%2021.6685%2059.225%2021.6685C56.925%2021.6685%2055.025%2020.9685%2053.625%2019.4685C52.225%2017.9685%2051.525%2016.1685%2051.525%2013.9685V13.3685C51.525%2010.9685%2052.125%208.96855%2053.425%207.46855C54.725%205.96855%2056.525%205.16855%2058.825%205.16855C61.125%205.26855%2062.825%205.96855%2064.025%207.16855ZM61.025%2011.5685C61.025%2010.7685%2060.825%2010.1685%2060.525%209.76855C60.225%209.36855%2059.725%209.16855%2058.925%209.16855C58.225%209.16855%2057.725%209.46855%2057.325%209.96855C56.925%2010.4685%2056.725%2011.1685%2056.625%2011.9685V12.0685H60.925V11.5685H61.025ZM85.925%207.06855C85.925%209.16855%2085.225%2010.8685%2083.725%2012.1685C82.225%2013.4685%2080.225%2014.0685%2077.725%2014.0685H74.025V21.3685H69.025V0.0685483H77.725C80.225%200.0685483%2082.225%200.668548%2083.725%201.96855C85.225%203.26855%2085.925%204.96855%2085.925%207.06855ZM80.925%207.16855C80.925%206.26855%2080.625%205.46855%2080.125%204.86855C79.625%204.26855%2078.725%203.96855%2077.625%203.96855H73.925V10.3685H77.625C78.725%2010.3685%2079.525%2010.0685%2080.125%209.46855C80.725%208.86855%2080.925%208.06855%2080.925%207.16855ZM100.725%2019.2685C100.825%2019.9685%20101.125%2020.6685%20101.325%2021.4685H96.425C96.325%2021.1685%2096.125%2020.9685%2096.025%2020.6685C95.925%2020.3685%2095.825%2020.0685%2095.725%2019.6685C95.225%2020.3685%2094.725%2020.8685%2094.025%2021.2685C93.325%2021.6685%2092.525%2021.8685%2091.625%2021.8685C90.125%2021.8685%2088.925%2021.4685%2087.925%2020.5685C87.025%2019.6685%2086.525%2018.5685%2086.525%2017.0685C86.525%2015.4685%2087.125%2014.2685%2088.325%2013.4685C89.525%2012.5685%2091.325%2012.1685%2093.725%2012.1685H95.525V11.0685C95.525%2010.3685%2095.325%209.86855%2095.025%209.46855C94.725%209.06855%2094.225%208.96855%2093.525%208.96855C92.925%208.96855%2092.525%209.06855%2092.225%209.36855C91.925%209.66855%2091.825%2010.0685%2091.825%2010.6685H87.025V10.5685C86.925%209.16855%2087.525%207.86855%2088.825%206.96855C90.125%206.06855%2091.725%205.46855%2093.825%205.46855C95.825%205.46855%2097.325%205.96855%2098.625%206.96855C99.825%207.96855%20100.425%209.36855%20100.425%2011.1685V17.1685C100.525%2017.7685%20100.625%2018.5685%20100.725%2019.2685ZM95.525%2014.6685H93.725C92.925%2014.6685%2092.425%2014.8685%2092.025%2015.2685C91.625%2015.6685%2091.525%2016.1685%2091.525%2016.7685C91.525%2017.1685%2091.725%2017.5685%2092.025%2017.8685C92.325%2018.1685%2092.725%2018.2685%2093.225%2018.2685C93.725%2018.2685%2094.125%2018.1685%2094.525%2017.9685C94.925%2017.7685%2095.225%2017.5685%2095.525%2017.1685V14.6685ZM111.625%205.26855C110.925%205.26855%20110.225%205.46855%20109.725%205.96855C109.225%206.46855%20108.725%207.06855%20108.425%207.86855L108.225%205.56855H103.525V21.3685H108.525V11.0685C108.725%2010.6685%20108.925%2010.4685%20109.325%2010.2685C109.725%2010.0685%20110.125%209.96855%20110.725%209.96855H112.525L113.025%205.46855C112.825%205.46855%20112.625%205.36855%20112.425%205.36855C112.225%205.36855%20111.825%205.26855%20111.625%205.26855ZM123.725%2017.8685C123.525%2017.8685%20123.325%2017.8685%20123.025%2017.8685C122.625%2017.8685%20122.325%2017.7685%20122.125%2017.4685C121.925%2017.2685%20121.825%2016.7685%20121.825%2016.2685V8.96855H124.525V5.56855H121.825V1.66855H116.925V5.56855H114.725V8.96855H116.925V16.2685C116.925%2018.1685%20117.325%2019.5685%20118.225%2020.3685C119.125%2021.1685%20120.325%2021.6685%20121.925%2021.6685C122.525%2021.6685%20123.025%2021.6685%20123.525%2021.5685C124.025%2021.4685%20124.425%2021.4685%20125.025%2021.2685L124.625%2017.5685C124.125%2017.7685%20123.925%2017.7685%20123.725%2017.8685ZM138.625%2013.5685C137.725%2012.7685%20136.225%2012.2685%20134.325%2011.8685C133.125%2011.6685%20132.325%2011.3685%20131.825%2011.0685C131.325%2010.7685%20131.225%2010.4685%20131.225%209.96855C131.225%209.56855%20131.425%209.16855%20131.725%208.86855C132.025%208.56855%20132.525%208.46855%20133.025%208.46855C133.725%208.46855%20134.225%208.66855%20134.525%208.96855C134.825%209.26855%20135.025%209.76855%20135.025%2010.3685H139.825V10.2685C139.925%208.76855%20139.325%207.56855%20138.025%206.56855C136.725%205.56855%20135.125%205.16855%20133.025%205.16855C131.025%205.16855%20129.425%205.66855%20128.225%206.66855C127.025%207.66855%20126.425%208.86855%20126.425%2010.2685C126.425%2011.5685%20126.925%2012.6685%20127.825%2013.3685C128.725%2014.0685%20130.125%2014.6685%20132.025%2015.0685C133.225%2015.2685%20134.025%2015.5685%20134.425%2015.8685C134.825%2016.1685%20135.125%2016.5685%20135.125%2016.8685C135.125%2017.3685%20134.925%2017.6685%20134.625%2017.9685C134.325%2018.2685%20133.825%2018.3685%20133.125%2018.3685C132.325%2018.3685%20131.725%2018.1685%20131.225%2017.8685C130.725%2017.5685%20130.525%2016.9685%20130.525%2016.2685H126.025V16.3685C125.925%2017.6685%20126.525%2018.9685%20127.825%2020.0685C129.125%2021.1685%20130.825%2021.6685%20132.925%2021.6685C135.025%2021.6685%20136.725%2021.1685%20137.925%2020.2685C139.125%2019.3685%20139.825%2018.1685%20139.825%2016.7685C140.025%2015.4685%20139.625%2014.3685%20138.625%2013.5685Z'%20fill='black'%20/%3e%3c/svg%3e";
9
+ function m() {
10
+ return /* @__PURE__ */ e(
11
+ i,
12
+ {
13
+ flexDirection: "row",
14
+ justifyContent: "flex-start",
15
+ alignItems: "center",
16
+ className: t.container,
17
+ children: [
18
+ /* @__PURE__ */ C("img", { src: s, alt: "CaseParts icon" }),
19
+ /* @__PURE__ */ e(
20
+ i,
21
+ {
22
+ flexDirection: "column",
23
+ justifyContent: "flex-start",
24
+ alignItems: "center",
25
+ children: [
26
+ /* @__PURE__ */ C(
27
+ "img",
28
+ {
29
+ src: l,
30
+ alt: "CaseParts wordmark",
31
+ className: t.wordmark
32
+ }
33
+ ),
34
+ /* @__PURE__ */ C(
35
+ n,
36
+ {
37
+ size: "xxs",
38
+ variant: "display",
39
+ weight: "thin",
40
+ className: t.tagline,
41
+ children: "Commercial Refrigeration Specialists"
42
+ }
43
+ )
44
+ ]
45
+ }
46
+ )
47
+ ]
48
+ }
49
+ );
50
+ }
51
+ export {
52
+ m as Logo
53
+ };
@@ -0,0 +1,13 @@
1
+ import { StoryObj } from '@storybook/react';
2
+ import { Logo } from './Logo';
3
+ declare const meta: {
4
+ title: string;
5
+ component: typeof Logo;
6
+ parameters: {
7
+ layout: string;
8
+ };
9
+ tags: string[];
10
+ };
11
+ export default meta;
12
+ type Story = StoryObj<typeof meta>;
13
+ export declare const Default: Story;
@@ -0,0 +1,17 @@
1
+ import { Logo as t } from "./Logo.js";
2
+ const e = {
3
+ title: "Case Parts/Molecules/Logo",
4
+ component: t,
5
+ parameters: {
6
+ // Optional parameter to center the component in the Canvas. More info: https://storybook.js.org/docs/configure/story-layout
7
+ layout: "centered"
8
+ },
9
+ // This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/writing-docs/autodocs
10
+ tags: ["autodocs"]
11
+ }, a = {
12
+ args: {}
13
+ };
14
+ export {
15
+ a as Default,
16
+ e as default
17
+ };
@@ -0,0 +1,6 @@
1
+ import { HideAtProps } from '../../atoms/HideAt';
2
+ /** A search box. */
3
+ export interface SearchBoxProps extends React.HTMLAttributes<HTMLDivElement>, HideAtProps {
4
+ action: string;
5
+ }
6
+ export declare function SearchBox({ action, hideAt, className, ...otherProps }: SearchBoxProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,60 @@
1
+ import { jsx as e, jsxs as i } from "react/jsx-runtime";
2
+ import { c as a } from "../../clsx-OuTLNxxd.js";
3
+ import { Flex as r } from "../../atoms/Flex/Flex.js";
4
+ import { getHideAtStyles as l } from "../../atoms/HideAt.js";
5
+ import { Icon as m } from "../../atoms/Icon/Icon.js";
6
+ import '../../assets/SearchBox.css';const u = "_button_1ql5u_1", h = "_text_1ql5u_31", p = "_input_1ql5u_61", x = "_inputSearch_1ql5u_69", _ = "_searchfield_1ql5u_77", f = "_searchBox_1ql5u_91", t = {
7
+ button: u,
8
+ text: h,
9
+ input: p,
10
+ inputSearch: x,
11
+ searchfield: _,
12
+ searchBox: f
13
+ };
14
+ function S({
15
+ action: c,
16
+ hideAt: n,
17
+ className: s,
18
+ ...o
19
+ }) {
20
+ return /* @__PURE__ */ e(
21
+ r,
22
+ {
23
+ flexDirection: "row",
24
+ alignItems: "center",
25
+ className: a(t.searchBox, l(n), s),
26
+ ...o,
27
+ children: /* @__PURE__ */ e(
28
+ r,
29
+ {
30
+ flexDirection: "row",
31
+ alignItems: "center",
32
+ className: t.searchfield,
33
+ children: /* @__PURE__ */ e("div", { className: t.inputSearch, children: /* @__PURE__ */ e("form", { action: c, method: "get", children: /* @__PURE__ */ i(
34
+ r,
35
+ {
36
+ className: t.input,
37
+ flexDirection: "row",
38
+ alignItems: "center",
39
+ children: [
40
+ /* @__PURE__ */ e("button", { className: t.button, type: "submit", children: /* @__PURE__ */ e(m, { iconKey: "fa-regular fa-magnifying-glass", size: "sm" }) }),
41
+ /* @__PURE__ */ e(
42
+ "input",
43
+ {
44
+ type: "text",
45
+ className: t.text,
46
+ placeholder: "Search by keyword(s) or Part #....",
47
+ name: "query"
48
+ }
49
+ )
50
+ ]
51
+ }
52
+ ) }) })
53
+ }
54
+ )
55
+ }
56
+ );
57
+ }
58
+ export {
59
+ S as SearchBox
60
+ };
@@ -0,0 +1,12 @@
1
+ import { StoryObj } from '@storybook/react';
2
+ import { SearchBox } from './SearchBox';
3
+ declare const meta: {
4
+ title: string;
5
+ component: typeof SearchBox;
6
+ parameters: {
7
+ layout: string;
8
+ };
9
+ };
10
+ export default meta;
11
+ type Story = StoryObj<typeof meta>;
12
+ export declare const Default: Story;
@@ -0,0 +1,15 @@
1
+ import { SearchBox as e } from "./SearchBox.js";
2
+ const a = {
3
+ title: "Case Parts/Molecules/SearchBox",
4
+ component: e,
5
+ parameters: {
6
+ // Optional parameter to center the component in the Canvas. More info: https://storybook.js.org/docs/configure/story-layout
7
+ layout: "centered"
8
+ }
9
+ }, o = {
10
+ args: { action: "/search" }
11
+ };
12
+ export {
13
+ o as Default,
14
+ a as default
15
+ };
@@ -0,0 +1,75 @@
1
+ import { default as React } from 'react';
2
+ import { HideAtProps } from '../../atoms/HideAt';
3
+ export interface ToggleViewProps extends React.HTMLAttributes<HTMLDivElement>, HideAtProps {
4
+ selectedId: string | number;
5
+ onToggle: (id: string | number) => void;
6
+ className?: string;
7
+ children?: React.ReactNode;
8
+ }
9
+ export interface ToggleOptionBaseProps {
10
+ id: string | number;
11
+ label: string;
12
+ icon: React.ReactNode;
13
+ isSelected?: boolean;
14
+ onClick?: () => void;
15
+ className?: string;
16
+ }
17
+ export interface ToggleOptionProps {
18
+ variant: keyof typeof toggleOptionTitleMap;
19
+ id: string | number;
20
+ isSelected?: boolean;
21
+ onClick?: () => void;
22
+ className?: string;
23
+ }
24
+ declare const toggleOptionTitleMap: Record<string, string>;
25
+ /**
26
+ * A `ToggleView` component that allows users to toggle between multiple options, such as "grid", "list", and "table".
27
+ *
28
+ * This component is designed to be flexible and accessible, with built-in support for ARIA attributes and customizable options.
29
+ *
30
+ * ### Features
31
+ * - **Built-in Variants**: Includes predefined options for "grid", "list", and "table" with corresponding icons.
32
+ * - **Customizable**: Supports custom options via `ToggleView.OptionBase`.
33
+ * - **Accessibility**: Uses `role="button"` and `aria-selected` for better screen reader support.
34
+ * - **Responsive**: Integrates with `HideAtProps` for responsive visibility.
35
+ *
36
+ * ### Usage
37
+ *
38
+ * #### Basic Example
39
+ * ```tsx
40
+ * <ToggleView
41
+ * selectedId="grid"
42
+ * onToggle={(id) => console.log("Selected:", id)}
43
+ * >
44
+ * <ToggleView.Option id="grid" variant="grid" />
45
+ * <ToggleView.Option id="list" variant="list" />
46
+ * <ToggleView.Option id="table" variant="table" />
47
+ * </ToggleView>
48
+ * ```
49
+ *
50
+ * #### Custom Options Example
51
+ * ```tsx
52
+ * <ToggleView
53
+ * selectedId="custom"
54
+ * onToggle={(id) => console.log("Selected:", id)}
55
+ * >
56
+ * <ToggleView.OptionBase
57
+ * id="custom"
58
+ * label="Custom"
59
+ * icon={<Icon iconKey="fa-regular fa-star" size="sm" />}
60
+ * />
61
+ * </ToggleView>
62
+ * ```
63
+ */
64
+ export declare function ToggleView({ selectedId, onToggle, className, children, hideAt, ...otherProps }: ToggleViewProps): import("react/jsx-runtime").JSX.Element;
65
+ export declare namespace ToggleView {
66
+ var OptionBase: typeof ToggleOptionBase;
67
+ var Option: typeof ToggleOption;
68
+ var GridIcon: import("react/jsx-runtime").JSX.Element;
69
+ var ListIcon: import("react/jsx-runtime").JSX.Element;
70
+ var TableIcon: import("react/jsx-runtime").JSX.Element;
71
+ }
72
+ declare function ToggleOption({ id, variant, // Specify variant on built-in option
73
+ isSelected, onClick, className, ...otherProps }: ToggleOptionProps): import("react/jsx-runtime").JSX.Element;
74
+ declare function ToggleOptionBase({ id, label, icon, isSelected, onClick, className, ...otherProps }: ToggleOptionBaseProps): import("react/jsx-runtime").JSX.Element;
75
+ export {};
@@ -0,0 +1,102 @@
1
+ import { jsx as e, jsxs as d } from "react/jsx-runtime";
2
+ import g from "react";
3
+ import { Flex as f } from "../../atoms/Flex/Flex.js";
4
+ import { Icon as l } from "../../atoms/Icon/Icon.js";
5
+ import { Text as b } from "../../atoms/Text/Text.js";
6
+ import { getHideAtStyles as x } from "../../atoms/HideAt.js";
7
+ import { c as p } from "../../clsx-OuTLNxxd.js";
8
+ import '../../assets/ToggleView.css';const O = "_toggleView_1qbhe_1", y = "_toggleOption_1qbhe_5", I = "_selected_1qbhe_13", m = {
9
+ toggleView: O,
10
+ toggleOption: y,
11
+ selected: I
12
+ }, _ = {
13
+ grid: "GRID",
14
+ list: "LIST",
15
+ table: "TABLE"
16
+ }, T = {
17
+ grid: /* @__PURE__ */ e(l, { iconKey: "fa-regular fa-grid-2", size: "sm" }),
18
+ list: /* @__PURE__ */ e(l, { iconKey: "fa-regular fa-list-ul", size: "sm" }),
19
+ table: /* @__PURE__ */ e(l, { iconKey: "fa-regular fa-table-cells", size: "sm" })
20
+ };
21
+ function s({
22
+ selectedId: c,
23
+ onToggle: t,
24
+ className: n,
25
+ children: o,
26
+ hideAt: a,
27
+ ...r
28
+ }) {
29
+ return /* @__PURE__ */ e(
30
+ f,
31
+ {
32
+ flexDirection: "row",
33
+ alignItems: "center",
34
+ className: p(m.toggleView, x(a), n),
35
+ ...r,
36
+ children: g.Children.map(o, (i) => g.isValidElement(i) ? g.cloneElement(i, {
37
+ isSelected: i.props.id === c,
38
+ onClick: () => t(i.props.id)
39
+ }) : null)
40
+ }
41
+ );
42
+ }
43
+ function w({
44
+ id: c,
45
+ variant: t,
46
+ // Specify variant on built-in option
47
+ isSelected: n,
48
+ onClick: o,
49
+ className: a,
50
+ ...r
51
+ }) {
52
+ return /* @__PURE__ */ e(
53
+ u,
54
+ {
55
+ id: c,
56
+ label: _[t],
57
+ icon: T[t],
58
+ isSelected: n,
59
+ onClick: o,
60
+ ...r
61
+ }
62
+ );
63
+ }
64
+ function u({
65
+ id: c,
66
+ label: t,
67
+ icon: n,
68
+ isSelected: o,
69
+ onClick: a,
70
+ className: r,
71
+ ...i
72
+ }) {
73
+ return /* @__PURE__ */ d(
74
+ f,
75
+ {
76
+ flexDirection: "row",
77
+ alignItems: "center",
78
+ justifyContent: "center",
79
+ className: p(
80
+ m.toggleOption,
81
+ o && m.selected,
82
+ r
83
+ ),
84
+ role: "button",
85
+ "aria-selected": o,
86
+ onClick: a,
87
+ ...i,
88
+ children: [
89
+ n,
90
+ /* @__PURE__ */ e(b, { size: "xxs", children: t })
91
+ ]
92
+ }
93
+ );
94
+ }
95
+ s.OptionBase = u;
96
+ s.Option = w;
97
+ s.GridIcon = /* @__PURE__ */ e(l, { iconKey: "fa-regular fa-grid-2", size: "sm" });
98
+ s.ListIcon = /* @__PURE__ */ e(l, { iconKey: "fa-regular fa-list-ul", size: "sm" });
99
+ s.TableIcon = /* @__PURE__ */ e(l, { iconKey: "fa-regular fa-table-cells", size: "sm" });
100
+ export {
101
+ s as ToggleView
102
+ };
@@ -0,0 +1,13 @@
1
+ import { ToggleView } from './ToggleView';
2
+ import { StoryObj } from '@storybook/react';
3
+ declare const meta: {
4
+ title: string;
5
+ component: typeof ToggleView;
6
+ parameters: {
7
+ layout: string;
8
+ };
9
+ tags: string[];
10
+ };
11
+ export default meta;
12
+ type Story = StoryObj<typeof meta>;
13
+ export declare const Default: Story;
@@ -0,0 +1,24 @@
1
+ import { jsx as e } from "react/jsx-runtime";
2
+ import { ToggleView as t } from "./ToggleView.js";
3
+ const l = {
4
+ title: "Case Parts/Molecules/ToggleView",
5
+ component: t,
6
+ parameters: {
7
+ layout: "centered"
8
+ },
9
+ tags: ["autodocs"]
10
+ }, r = {
11
+ args: {
12
+ selectedId: "table",
13
+ onToggle: (o) => console.log(`Option ${o} selected`),
14
+ children: [
15
+ /* @__PURE__ */ e(t.Option, { id: "grid", variant: "grid" }, "grid"),
16
+ /* @__PURE__ */ e(t.Option, { id: "list", variant: "list" }, "list"),
17
+ /* @__PURE__ */ e(t.Option, { id: "table", variant: "table" }, "table")
18
+ ]
19
+ }
20
+ };
21
+ export {
22
+ r as Default,
23
+ l as default
24
+ };
@@ -0,0 +1,12 @@
1
+ import { HideAtProps } from '../../atoms/HideAt';
2
+ import { ChipProps } from '../../molecules/Chip/Chip';
3
+ export interface ChipSelectorChip extends Omit<ChipProps, "id"> {
4
+ id: string | number;
5
+ }
6
+ export interface ChipSelectorProps extends HideAtProps {
7
+ chips: ChipSelectorChip[];
8
+ onChipSelect?: (id: string | number) => void;
9
+ onChipDismiss?: (id: string | number) => void;
10
+ className?: string;
11
+ }
12
+ export declare function ChipSelector({ chips, onChipSelect, onChipDismiss, className, hideAt, ...otherProps }: ChipSelectorProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,43 @@
1
+ import { jsx as l } from "react/jsx-runtime";
2
+ import { c as m } from "../../clsx-OuTLNxxd.js";
3
+ import { getHideAtStyles as n } from "../../atoms/HideAt.js";
4
+ import { Flex as s } from "../../atoms/Flex/Flex.js";
5
+ import { Chip as f } from "../../molecules/Chip/Chip.js";
6
+ import '../../assets/ChipSelector.css';const x = "_chipSelector_1k7dl_1", i = {
7
+ chipSelector: x
8
+ };
9
+ function g({
10
+ chips: o,
11
+ onChipSelect: e,
12
+ onChipDismiss: r,
13
+ className: a,
14
+ hideAt: d,
15
+ ...c
16
+ }) {
17
+ return /* @__PURE__ */ l(
18
+ s,
19
+ {
20
+ flexDirection: "row",
21
+ alignItems: "center",
22
+ className: m(i.chipSelector, n(d), a),
23
+ ...c,
24
+ children: o.map((t) => /* @__PURE__ */ l(
25
+ f,
26
+ {
27
+ text: t.text,
28
+ selected: t.selected,
29
+ disabled: t.disabled,
30
+ variant: t.variant,
31
+ styleVariant: t.styleVariant,
32
+ count: t.count,
33
+ onSelect: () => e == null ? void 0 : e(t.id),
34
+ onDismiss: () => r == null ? void 0 : r(t.id)
35
+ },
36
+ t.id
37
+ ))
38
+ }
39
+ );
40
+ }
41
+ export {
42
+ g as ChipSelector
43
+ };
@@ -0,0 +1,14 @@
1
+ import { ChipSelector } from './ChipSelector';
2
+ import { StoryObj } from '@storybook/react';
3
+ declare const meta: {
4
+ title: string;
5
+ component: typeof ChipSelector;
6
+ parameters: {
7
+ layout: string;
8
+ };
9
+ tags: string[];
10
+ };
11
+ export default meta;
12
+ type Story = StoryObj<typeof meta>;
13
+ export declare const AllProps: Story;
14
+ export declare const Variants: StoryObj<typeof ChipSelector>;