@caseparts-org/caseblocks 0.0.97 → 0.0.98
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/assets/Product.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.
|
|
1
|
+
._productCard_15dy7_1{box-sizing:border-box;border:1px solid var(--border-border-primary, #DFDFDF);background:var(--surface-surface-primary, #FFF);box-shadow:2px 4px 12px #00000026;display:flex;width:232px;height:296px;padding:var(--spacing-spacing-default, 16px) var(--spacing-spacing-sm, 20px);flex-direction:column;align-items:flex-start;gap:var(--spacing-spacing-2xs)}._productCard_15dy7_1>img{width:96px;height:96px;object-fit:contain;flex-shrink:0;margin:0 auto}._productCard_15dy7_1 ._productInformation_15dy7_22{display:flex;flex-direction:column;align-items:flex-start;gap:2px;margin-top:auto}._productCard_15dy7_1 ._purchaseInformation_15dy7_29{display:flex;flex-direction:row;align-items:flex-start;justify-content:space-between;width:100%}._productCard_15dy7_1 ._addToCart_15dy7_37,._productCard_15dy7_1 ._addToCartButton_15dy7_40{width:100%}._productInformation_15dy7_22>a{font-weight:var(--font-weight-semibold)}._partNumber_15dy7_48{display:flex;flex-direction:row;align-items:center;gap:var(--spacing-spacing-3xs)}._partNumberLabel_15dy7_55{color:var(--text-text-quaternary)}._productTile_15dy7_59{box-sizing:border-box;width:100%;max-width:1072px;display:flex;flex-direction:row;align-items:flex-start;border:1px solid var(--border-border-primary, #DFDFDF);background:var(--surface-surface-primary, #FFF);box-shadow:2px 4px 12px #00000026;padding:var(--spacing-spacing-default, 16px) var(--spacing-spacing-sm, 20px);gap:var(--spacing-spacing-1xs)}._productTile_15dy7_59>img{width:108px;height:108px;object-fit:contain}._productTile_15dy7_59 ._topRow_15dy7_80{display:grid;grid-template-columns:1fr auto;width:100%}._productTile_15dy7_59 ._topRow_15dy7_80 button{background-color:transparent;padding:0;margin:0;outline:none;border:none;height:min-content;width:min-content}._productTile_15dy7_59 ._topRow_15dy7_80 path{fill:var(--icons-icon-search)}._productTile_15dy7_59 ._topRow_15dy7_80 svg{padding:0}._productTile_15dy7_59 ._productInformation_15dy7_22{display:flex;flex-direction:column;align-items:flex-start;gap:2px}._productTile_15dy7_59 ._productData_15dy7_111{display:flex;flex-direction:column;align-items:flex-start;width:100%;gap:var(--spacing-spacing-2xs)}._productTile_15dy7_59 ._purchase_15dy7_29{display:flex;flex-direction:row;align-items:flex-end;justify-content:space-between;width:100%}@media (max-width: 480px){._productTile_15dy7_59 ._purchase_15dy7_29{flex-direction:column;align-items:flex-start;gap:var(--spacing-spacing-3xs)}}._productTile_15dy7_59 ._purchaseInformation_15dy7_29{display:flex;flex-direction:column;align-items:flex-start;gap:var(--spacing-spacing-2xs)}@media (max-width: 480px){._productTile_15dy7_59 ._purchaseInformation_15dy7_29{flex-direction:row;align-items:flex-start;justify-content:space-between;width:100%;gap:0px}}._productTile_15dy7_59 ._attributeContainer_15dy7_148{margin:0;padding:0;padding-top:var(--spacing-spacing-1xs);border-top:1px solid var(--border-border-primary);width:100%;list-style:none;display:flex;flex-direction:row;align-items:center;justify-content:flex-start;flex-wrap:wrap;column-gap:var(--spacing-spacing-lg);row-gap:var(--spacing-spacing-3xs)}@media (max-width: 640px){._productTile_15dy7_59 ._attributeContainer_15dy7_148{display:none}}._productTile_15dy7_59 ._attributeContainer_15dy7_148 li{display:flex;flex-direction:row;align-items:center;gap:var(--spacing-spacing-3xs)}._productTile_15dy7_59 ._addToCart_15dy7_37{display:flex;flex-direction:row;align-items:center;gap:var(--spacing-spacing-md)}@media (max-width: 480px){._productTile_15dy7_59 ._addToCart_15dy7_37{gap:var(--spacing-spacing-2xs);width:100%}}._productTile_15dy7_59 ._addToCartButton_15dy7_40{width:96px;font-size:var(--font-size-md);font-weight:var(--font-weight-semibold)}@media (max-width: 640px){._productTile_15dy7_59 ._addToCartButton_15dy7_40{width:100%}}
|
package/dist/main-client.d.ts
CHANGED
|
@@ -19,8 +19,9 @@ export type { AnimatedCheckMarkProps } from './molecules/StatefulButton/Animated
|
|
|
19
19
|
export { AnimatedCheckMark } from './molecules/StatefulButton/AnimatedCheckmark';
|
|
20
20
|
export type { AddToCartProps } from './molecules/AddToCart/AddToCart';
|
|
21
21
|
export { AddToCart } from './molecules/AddToCart/AddToCart';
|
|
22
|
+
export type { CategoryWithChildren as MainCategory, Category } from './molecules/CategoryNav/CategoryNav';
|
|
22
23
|
export { MainNav } from './organisms/MainNav/MainNav';
|
|
23
|
-
export type {
|
|
24
|
+
export type { MainNavProps } from './organisms/MainNav/MainNav';
|
|
24
25
|
export { ChipSelector } from './organisms/ChipSelector/ChipSelector';
|
|
25
26
|
export type { ChipSelectorProps } from './organisms/ChipSelector/ChipSelector';
|
|
26
27
|
export { Product } from './organisms/Product/Product';
|
package/dist/main.d.ts
CHANGED
|
@@ -25,6 +25,5 @@ export type { SearchBoxProps } from './molecules/SearchBox/SearchBox';
|
|
|
25
25
|
export { ToggleView } from './molecules/ToggleView/ToggleView';
|
|
26
26
|
export type { ToggleViewProps, ToggleOptionProps, ToggleOptionBaseProps, } from './molecules/ToggleView/ToggleView';
|
|
27
27
|
export { MainNav } from './organisms/MainNav/MainNav';
|
|
28
|
-
export type { MainCategory, Category } from './organisms/MainNav/MainNav';
|
|
29
28
|
export { ChipSelector } from './organisms/ChipSelector/ChipSelector';
|
|
30
29
|
export type { ChipSelectorProps } from './organisms/ChipSelector/ChipSelector';
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
export interface Category {
|
|
2
2
|
id: string | number;
|
|
3
|
-
label: string;
|
|
3
|
+
label: string | React.ReactElement;
|
|
4
4
|
route: string;
|
|
5
5
|
}
|
|
6
|
-
export interface
|
|
6
|
+
export interface CategoryWithChildren extends Category {
|
|
7
7
|
children: Category[];
|
|
8
8
|
showChevron?: boolean;
|
|
9
9
|
}
|
|
10
10
|
export declare function CategoryNav({ categories, }: {
|
|
11
|
-
categories?:
|
|
11
|
+
categories?: CategoryWithChildren[];
|
|
12
12
|
}): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -1,17 +1,9 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
import { CartPropsBase, ShoppingCart, ShoppingCartHandle } from '../../molecules/Cart/Cart';
|
|
3
3
|
import { AccountProps } from '../../molecules/Account/Account';
|
|
4
|
-
|
|
5
|
-
id: string | number;
|
|
6
|
-
label: string;
|
|
7
|
-
route: string;
|
|
8
|
-
}
|
|
9
|
-
export interface MainCategory extends Category {
|
|
10
|
-
children: Category[];
|
|
11
|
-
showChevron?: boolean;
|
|
12
|
-
}
|
|
4
|
+
import { CategoryWithChildren } from '../../molecules/CategoryNav/CategoryNav';
|
|
13
5
|
export interface MainNavProps extends CartPropsBase, React.HTMLAttributes<HTMLDivElement>, Pick<AccountProps, "account"> {
|
|
14
|
-
categories?:
|
|
6
|
+
categories?: CategoryWithChildren[];
|
|
15
7
|
homeRoute: string;
|
|
16
8
|
faqRoute: string;
|
|
17
9
|
byModelSerialRoute: string;
|
|
@@ -1,76 +1,76 @@
|
|
|
1
1
|
import { jsxs as a, jsx as t } from "react/jsx-runtime";
|
|
2
2
|
import { Image as T } from "../../atoms/Image/Image.js";
|
|
3
3
|
import { Link as g } from "../../atoms/Link/Link.js";
|
|
4
|
-
import { Text as
|
|
5
|
-
import { Availability as
|
|
6
|
-
import { Pricing as
|
|
7
|
-
import { AddToCart as
|
|
8
|
-
import { Icon as
|
|
9
|
-
import { c as
|
|
10
|
-
import '../../assets/Product.css';const P = "
|
|
11
|
-
productCard:
|
|
12
|
-
productInformation:
|
|
13
|
-
purchaseInformation:
|
|
14
|
-
addToCart:
|
|
15
|
-
addToCartButton:
|
|
16
|
-
partNumber:
|
|
17
|
-
partNumberLabel:
|
|
18
|
-
productTile:
|
|
4
|
+
import { Text as o } from "../../atoms/Text/Text.js";
|
|
5
|
+
import { Availability as y } from "../../molecules/Availability/Availability.js";
|
|
6
|
+
import { Pricing as w } from "../../molecules/Pricing/Pricing.js";
|
|
7
|
+
import { AddToCart as v } from "../../molecules/AddToCart/AddToCart.js";
|
|
8
|
+
import { Icon as B } from "../../atoms/Icon/Icon.js";
|
|
9
|
+
import { c as x } from "../../clsx-OuTLNxxd.js";
|
|
10
|
+
import '../../assets/Product.css';const L = "_productCard_15dy7_1", P = "_productInformation_15dy7_22", R = "_purchaseInformation_15dy7_29", $ = "_addToCart_15dy7_37", A = "_addToCartButton_15dy7_40", D = "_partNumber_15dy7_48", j = "_partNumberLabel_15dy7_55", k = "_productTile_15dy7_59", q = "_topRow_15dy7_80", E = "_productData_15dy7_111", F = "_purchase_15dy7_29", G = "_attributeContainer_15dy7_148", r = {
|
|
11
|
+
productCard: L,
|
|
12
|
+
productInformation: P,
|
|
13
|
+
purchaseInformation: R,
|
|
14
|
+
addToCart: $,
|
|
15
|
+
addToCartButton: A,
|
|
16
|
+
partNumber: D,
|
|
17
|
+
partNumberLabel: j,
|
|
18
|
+
productTile: k,
|
|
19
19
|
topRow: q,
|
|
20
20
|
productData: E,
|
|
21
21
|
purchase: F,
|
|
22
22
|
attributeContainer: G
|
|
23
23
|
};
|
|
24
24
|
function Z({
|
|
25
|
-
productView:
|
|
25
|
+
productView: I,
|
|
26
26
|
itemKey: s,
|
|
27
|
-
partNumber:
|
|
27
|
+
partNumber: d,
|
|
28
28
|
productDescription: l,
|
|
29
29
|
availDescription: m,
|
|
30
|
-
availId:
|
|
30
|
+
availId: e,
|
|
31
31
|
contactHref: u,
|
|
32
32
|
contactLinkBehavior: h,
|
|
33
33
|
productHref: p,
|
|
34
34
|
priceLabel: _,
|
|
35
|
-
price:
|
|
35
|
+
price: i,
|
|
36
36
|
imgSrc: N,
|
|
37
37
|
attributes: c,
|
|
38
38
|
className: b,
|
|
39
39
|
onAddToCart: f,
|
|
40
40
|
onClose: C,
|
|
41
|
-
...
|
|
41
|
+
...z
|
|
42
42
|
}) {
|
|
43
|
-
return
|
|
43
|
+
return I === "Card" ? /* @__PURE__ */ a("div", { className: x(r.productCard, b), children: [
|
|
44
44
|
/* @__PURE__ */ t(
|
|
45
45
|
T,
|
|
46
46
|
{
|
|
47
47
|
src: N,
|
|
48
|
-
alt: `${
|
|
49
|
-
height:
|
|
50
|
-
width:
|
|
48
|
+
alt: `${d} product image`,
|
|
49
|
+
height: 96,
|
|
50
|
+
width: 96
|
|
51
51
|
}
|
|
52
52
|
),
|
|
53
53
|
/* @__PURE__ */ a("div", { className: r.productInformation, children: [
|
|
54
54
|
/* @__PURE__ */ t(g, { href: p, children: l }),
|
|
55
55
|
/* @__PURE__ */ a("div", { className: r.partNumber, children: [
|
|
56
|
-
/* @__PURE__ */ t(
|
|
57
|
-
/* @__PURE__ */ t(
|
|
56
|
+
/* @__PURE__ */ t(o, { size: "sm", className: r.partNumberLabel, children: "Part #" }),
|
|
57
|
+
/* @__PURE__ */ t(o, { size: "sm", weight: "semibold", children: d })
|
|
58
58
|
] })
|
|
59
59
|
] }),
|
|
60
60
|
/* @__PURE__ */ a("div", { className: r.purchaseInformation, children: [
|
|
61
|
-
|
|
62
|
-
|
|
61
|
+
e && /* @__PURE__ */ t(
|
|
62
|
+
y,
|
|
63
63
|
{
|
|
64
|
-
availId:
|
|
64
|
+
availId: e,
|
|
65
65
|
availDescription: m,
|
|
66
66
|
contactHref: u,
|
|
67
67
|
contactLinkBehavior: h
|
|
68
68
|
}
|
|
69
69
|
),
|
|
70
|
-
|
|
70
|
+
i && /* @__PURE__ */ t(w, { pricingLabel: _, price: i })
|
|
71
71
|
] }),
|
|
72
72
|
/* @__PURE__ */ t(
|
|
73
|
-
|
|
73
|
+
v,
|
|
74
74
|
{
|
|
75
75
|
itemKey: s,
|
|
76
76
|
onAdd: f,
|
|
@@ -80,12 +80,12 @@ function Z({
|
|
|
80
80
|
buttonDoneText: ""
|
|
81
81
|
}
|
|
82
82
|
)
|
|
83
|
-
] }) : /* @__PURE__ */ a("div", { className:
|
|
83
|
+
] }) : /* @__PURE__ */ a("div", { className: x(r.productTile, b), ...z, children: [
|
|
84
84
|
/* @__PURE__ */ t(
|
|
85
85
|
T,
|
|
86
86
|
{
|
|
87
87
|
src: N,
|
|
88
|
-
alt: `${
|
|
88
|
+
alt: `${d} product image`,
|
|
89
89
|
height: 108,
|
|
90
90
|
width: 108
|
|
91
91
|
}
|
|
@@ -95,34 +95,34 @@ function Z({
|
|
|
95
95
|
/* @__PURE__ */ a("div", { className: r.productInformation, children: [
|
|
96
96
|
/* @__PURE__ */ t(g, { href: p, children: l }),
|
|
97
97
|
/* @__PURE__ */ a("div", { className: r.partNumber, children: [
|
|
98
|
-
/* @__PURE__ */ t(
|
|
99
|
-
/* @__PURE__ */ t(
|
|
98
|
+
/* @__PURE__ */ t(o, { size: "sm", className: r.partNumberLabel, children: "Part #" }),
|
|
99
|
+
/* @__PURE__ */ t(o, { size: "sm", weight: "semibold", children: d })
|
|
100
100
|
] })
|
|
101
101
|
] }),
|
|
102
|
-
C && /* @__PURE__ */ t("button", { onClick: () => C(s), children: /* @__PURE__ */ t(
|
|
102
|
+
C && /* @__PURE__ */ t("button", { onClick: () => C(s), children: /* @__PURE__ */ t(B, { size: "sm", iconKey: "fa-light fa-xmark" }) })
|
|
103
103
|
] }),
|
|
104
104
|
/* @__PURE__ */ a("div", { className: r.purchase, children: [
|
|
105
105
|
/* @__PURE__ */ a("div", { className: r.purchaseInformation, children: [
|
|
106
|
-
|
|
107
|
-
|
|
106
|
+
e && /* @__PURE__ */ t(
|
|
107
|
+
y,
|
|
108
108
|
{
|
|
109
|
-
availId:
|
|
109
|
+
availId: e,
|
|
110
110
|
availDescription: m,
|
|
111
111
|
contactHref: u,
|
|
112
112
|
contactLinkBehavior: h
|
|
113
113
|
}
|
|
114
114
|
),
|
|
115
|
-
|
|
115
|
+
i && /* @__PURE__ */ t(w, { pricingLabel: _, price: i })
|
|
116
116
|
] }),
|
|
117
|
-
/* @__PURE__ */ t(
|
|
117
|
+
/* @__PURE__ */ t(v, { itemKey: s, onAdd: f, className: r.addToCart, addButtonClassName: r.addToCartButton })
|
|
118
118
|
] }),
|
|
119
|
-
c && c.length > 0 && /* @__PURE__ */ t("ul", { className: r.attributeContainer, children: c.map((
|
|
120
|
-
/* @__PURE__ */ a(
|
|
121
|
-
|
|
119
|
+
c && c.length > 0 && /* @__PURE__ */ t("ul", { className: r.attributeContainer, children: c.map((n) => /* @__PURE__ */ a("li", { children: [
|
|
120
|
+
/* @__PURE__ */ a(o, { size: "xs", weight: "light", children: [
|
|
121
|
+
n.label,
|
|
122
122
|
":"
|
|
123
123
|
] }),
|
|
124
|
-
/* @__PURE__ */ t(
|
|
125
|
-
] }, `${
|
|
124
|
+
/* @__PURE__ */ t(o, { size: "xs", weight: "semibold", children: n.value })
|
|
125
|
+
] }, `${n.label}.${n.value}`)) })
|
|
126
126
|
] })
|
|
127
127
|
] });
|
|
128
128
|
}
|