formica-ui-lib 1.0.130 → 1.0.135
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/componentProps/atoms/button/ButtonProps.d.ts +5 -1
- package/dist/componentProps/atoms/checkbox/CheckboxProps.d.ts +8 -2
- package/dist/componentProps/molecules/card/featureproductcard/FeaturedProductCardProps.d.ts +4 -3
- package/dist/componentProps/molecules/card/swatchcard/SwatchCardProps.d.ts +5 -1
- package/dist/componentProps/molecules/selectors/appliedoptionslist/AppliedOptionsListProps.d.ts +14 -0
- package/dist/componentProps/molecules/selectors/verticalcheckboxlist/VerticalCheckboxListProps.d.ts +13 -0
- package/dist/componentProps/organisms/carousels/featureproductcarousel/FeaturedProductsCarouselProps.d.ts +5 -7
- package/dist/componentProps/organisms/decorgrid/DecorGridProps.d.ts +4 -0
- package/dist/componentProps/organisms/navigation/TopNavActionsProps.d.ts +2 -2
- package/dist/componentProps/organisms/navigation/TopNavBarProps.d.ts +9 -2
- package/dist/componentProps/organisms/verticalcheckboxlistcollection/VerticalCheckboxListCollectionProps.d.ts +8 -0
- package/dist/componentProps/scene/category/CategorySceneProps.d.ts +10 -0
- package/dist/componentProps/scene/productdetailscene/ProductDetailSceneProps.d.ts +1 -1
- package/dist/componentProps/templates/productdetailpagetemplate/ProductDetailPageTemplateProps.d.ts +25 -36
- package/dist/index.cjs +8 -8
- package/dist/index.d.ts +0 -2
- package/dist/index.js +1322 -1296
- package/dist/stories/atoms/buttons/button/ButtonThemeStyles.d.ts +3 -2
- package/dist/stories/molecules/card/swatchcard/SwatchCardStatusConfig.d.ts +10 -0
- package/dist/stories/molecules/selectors/appliedoptionslist/AppliedOptionsList.d.ts +4 -0
- package/dist/stories/molecules/selectors/verticalcheckboxlist/VerticalCheckboxList.d.ts +4 -0
- package/dist/stories/organisms/decorgrid/DecorGrid.d.ts +4 -0
- package/dist/stories/organisms/verticalcheckboxlistcollection/VerticalCheckboxListCollection.d.ts +4 -0
- package/dist/stories/scenes/article/ArticleScene.d.ts +1 -1
- package/dist/stories/scenes/category/CategoryScene.d.ts +4 -0
- package/package.json +8 -8
- /package/dist/componentProps/scene/article/{ArticleScene.d.ts → ArticleSceneProps.d.ts} +0 -0
|
@@ -1,19 +1,23 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import type { FaTypeClass } from "../icon/IconProps";
|
|
3
|
-
export type ButtonVariant = "standard" | "nav" | "text" | "icon" | "segmented" | "small" | "grid";
|
|
3
|
+
export type ButtonVariant = "standard" | "nav" | "text" | "icon" | "segmented" | "small" | "grid" | "header";
|
|
4
4
|
export type ButtonType = "primary" | "secondary" | "accent" | "ghost" | "radio";
|
|
5
|
+
export type IconSize = "xs" | "sm" | "md" | "lg" | "xl";
|
|
5
6
|
export type IconPosition = "left" | "right";
|
|
6
7
|
export type SegmentPosition = "only" | "first" | "middle" | "last";
|
|
8
|
+
export type ButtonAlignment = "justify-start" | "justify-center" | "justify-end" | "justify-between" | "justify-around" | "justify-evenly";
|
|
7
9
|
export interface ButtonProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, "className" | "children"> {
|
|
8
10
|
label?: string;
|
|
9
11
|
children?: React.ReactNode;
|
|
10
12
|
iconType?: FaTypeClass;
|
|
11
13
|
iconName?: string;
|
|
12
14
|
iconAlt?: string;
|
|
15
|
+
iconSize?: IconSize;
|
|
13
16
|
iconPosition?: IconPosition;
|
|
14
17
|
variant?: ButtonVariant;
|
|
15
18
|
buttonType?: ButtonType;
|
|
16
19
|
segmentPosition?: SegmentPosition;
|
|
20
|
+
buttonAlignment?: ButtonAlignment;
|
|
17
21
|
active?: boolean;
|
|
18
22
|
className?: string;
|
|
19
23
|
}
|
|
@@ -1,9 +1,15 @@
|
|
|
1
|
-
|
|
1
|
+
export type CheckboxColor = "accent-primary" | "accent-secondary" | "accent-tertiary" | "accent-accent";
|
|
2
|
+
export interface CheckboxChangePayload {
|
|
3
|
+
id: string;
|
|
4
|
+
name?: string;
|
|
5
|
+
checked: boolean;
|
|
6
|
+
}
|
|
2
7
|
export interface CheckboxProps {
|
|
3
8
|
id: string;
|
|
4
9
|
name?: string;
|
|
5
10
|
label: string;
|
|
6
11
|
checked?: boolean;
|
|
7
12
|
disabled?: boolean;
|
|
8
|
-
|
|
13
|
+
checkboxColor?: CheckboxColor;
|
|
14
|
+
onChange?: (payload: CheckboxChangePayload) => void;
|
|
9
15
|
}
|
|
@@ -1,7 +1,11 @@
|
|
|
1
|
+
export type SwatchStatus = "new" | "discontinued" | "comingSoon" | "sale";
|
|
1
2
|
export interface SwatchCardProps {
|
|
2
3
|
imageSrc: string;
|
|
3
4
|
imageAlt: string;
|
|
4
5
|
title: string;
|
|
5
6
|
brand: string;
|
|
6
|
-
|
|
7
|
+
product: string;
|
|
8
|
+
decorNumber: string | number;
|
|
9
|
+
onClick?: () => void;
|
|
10
|
+
status?: SwatchStatus;
|
|
7
11
|
}
|
package/dist/componentProps/molecules/selectors/appliedoptionslist/AppliedOptionsListProps.d.ts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export interface AppliedOptionRemovePayload {
|
|
2
|
+
id: string;
|
|
3
|
+
name?: string;
|
|
4
|
+
}
|
|
5
|
+
export type AppliedOptionItem = {
|
|
6
|
+
id: string;
|
|
7
|
+
label: string;
|
|
8
|
+
};
|
|
9
|
+
export interface AppliedOptionsListProps {
|
|
10
|
+
header?: string;
|
|
11
|
+
optionsList: AppliedOptionItem[];
|
|
12
|
+
onRemoveOption: (payload: AppliedOptionRemovePayload) => void;
|
|
13
|
+
onRemoveAll: () => void;
|
|
14
|
+
}
|
package/dist/componentProps/molecules/selectors/verticalcheckboxlist/VerticalCheckboxListProps.d.ts
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { CheckboxChangePayload } from "../../../atoms/checkbox/CheckboxProps";
|
|
2
|
+
export interface VerticalCheckboxListOption {
|
|
3
|
+
id: string;
|
|
4
|
+
name: string;
|
|
5
|
+
label: string;
|
|
6
|
+
checked?: boolean;
|
|
7
|
+
disabled?: boolean;
|
|
8
|
+
onChange?: (payload: CheckboxChangePayload) => void;
|
|
9
|
+
}
|
|
10
|
+
export interface VerticalCheckboxListProps {
|
|
11
|
+
label: string;
|
|
12
|
+
options: VerticalCheckboxListOption[];
|
|
13
|
+
}
|
|
@@ -1,15 +1,13 @@
|
|
|
1
|
-
export type
|
|
1
|
+
export type FeaturedProductItem = {
|
|
2
2
|
id: string;
|
|
3
3
|
imageSrc: string;
|
|
4
|
-
imageAlt
|
|
4
|
+
imageAlt: string;
|
|
5
5
|
title: string;
|
|
6
|
-
brand
|
|
7
|
-
decorNumber
|
|
6
|
+
brand: string;
|
|
7
|
+
decorNumber: string | number;
|
|
8
8
|
href?: string;
|
|
9
|
-
rangeCode?: string;
|
|
10
9
|
};
|
|
11
10
|
export type FeaturedProductsCarouselProps = {
|
|
12
11
|
title?: string;
|
|
13
|
-
items:
|
|
14
|
-
onItemClick?: (item: FeaturedProductCarouselItem) => void;
|
|
12
|
+
items: FeaturedProductItem[];
|
|
15
13
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type { Country } from "../../molecules/selectors/countryselector/CountrySelectorProps";
|
|
2
|
-
import type {
|
|
2
|
+
import type { TopNavLogin, TopNavCartSummary } from "./TopNavBarProps";
|
|
3
3
|
export type TopNavActionsProps = {
|
|
4
4
|
Countries?: Country[];
|
|
5
|
-
Login:
|
|
5
|
+
Login: TopNavLogin;
|
|
6
6
|
Cart?: TopNavCartSummary;
|
|
7
7
|
onSearchClick?: () => void;
|
|
8
8
|
onCartClick?: () => void;
|
|
@@ -23,15 +23,22 @@ export type TopNavCartSummary = {
|
|
|
23
23
|
hasCart: boolean;
|
|
24
24
|
itemCount: number;
|
|
25
25
|
};
|
|
26
|
-
export type
|
|
26
|
+
export type TopNavLogin = {
|
|
27
27
|
label: string;
|
|
28
28
|
href: string;
|
|
29
29
|
};
|
|
30
|
+
export type TopNavLogo = {
|
|
31
|
+
src: string;
|
|
32
|
+
alt?: string;
|
|
33
|
+
href?: string;
|
|
34
|
+
};
|
|
30
35
|
export type TopNavBarProps = {
|
|
31
36
|
NavMenuWithSubItems?: NavItem[];
|
|
32
37
|
Countries?: Country[];
|
|
33
|
-
Login
|
|
38
|
+
Login?: TopNavLogin;
|
|
34
39
|
Cart?: TopNavCartSummary;
|
|
40
|
+
Logo?: TopNavLogo;
|
|
41
|
+
onLogoClick?: () => void;
|
|
35
42
|
onNavItemClick?: (item: NavItem) => void;
|
|
36
43
|
onMegaMenuLinkClick?: (link: NavLinkItem) => void;
|
|
37
44
|
onPromoClick?: (promo: NavPromo) => void;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { VerticalCheckboxListProps } from "../../molecules/selectors/verticalcheckboxlist/VerticalCheckboxListProps";
|
|
2
|
+
import { AppliedOptionsListProps } from "../../molecules/selectors/appliedoptionslist/AppliedOptionsListProps";
|
|
3
|
+
export interface VerticalCheckboxListCollectionProps {
|
|
4
|
+
header?: string;
|
|
5
|
+
headerIcon?: string;
|
|
6
|
+
appliedOptions?: AppliedOptionsListProps;
|
|
7
|
+
sections: VerticalCheckboxListProps[];
|
|
8
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { StandardCopyHeroProps } from "../../organisms/banner/standardcopyhero/StandardCopyHeroProps";
|
|
2
|
+
import type { MultiButtonBarProps } from "../../molecules/selectors/multibuttonbar/MultiButtonBarProps";
|
|
3
|
+
import type { SortAndSearchBarProps } from "../../molecules/selectors/sortandsearchbar/SortAndSearchBarProps";
|
|
4
|
+
import type { DecorGridProps } from "../../organisms/decorgrid/DecorGridProps";
|
|
5
|
+
export type CategorySceneProps = {
|
|
6
|
+
standardCopyHeroProps: StandardCopyHeroProps;
|
|
7
|
+
multiButtonBarProps: MultiButtonBarProps;
|
|
8
|
+
sortAndSearchBarProps: SortAndSearchBarProps;
|
|
9
|
+
decorGridProps: DecorGridProps;
|
|
10
|
+
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { BrandNavBarProps } from "../../organisms/navigation/BrandNavBarProps";
|
|
2
2
|
import type { TopNavBarProps } from "../../organisms/navigation/TopNavBarProps";
|
|
3
3
|
import type { FooterProps } from "../../organisms/footer/FooterProps";
|
|
4
|
-
import
|
|
4
|
+
import { ProductDetailPageTemplateProps } from "../../templates/productdetailpagetemplate/ProductDetailPageTemplateProps";
|
|
5
5
|
export type ProductDetailSceneProps = {
|
|
6
6
|
brandNavBarProps: BrandNavBarProps;
|
|
7
7
|
topNavBarProps: TopNavBarProps;
|
package/dist/componentProps/templates/productdetailpagetemplate/ProductDetailPageTemplateProps.d.ts
CHANGED
|
@@ -158,19 +158,11 @@ export type ProductDetailStandardCopyHero = {
|
|
|
158
158
|
export type ProductDetailFeaturedProduct = {
|
|
159
159
|
id: string;
|
|
160
160
|
imageSrc: string;
|
|
161
|
-
imageAlt
|
|
161
|
+
imageAlt: string;
|
|
162
162
|
title: string;
|
|
163
|
-
brand
|
|
164
|
-
decorNumber
|
|
163
|
+
brand: string;
|
|
164
|
+
decorNumber: string | number;
|
|
165
165
|
href?: string;
|
|
166
|
-
rangeCode?: string;
|
|
167
|
-
};
|
|
168
|
-
export type ProductDetailNavigationMeta = {
|
|
169
|
-
source?: "breadcrumbs" | "purchase-panel" | "hero" | "featured-products";
|
|
170
|
-
itemId?: string;
|
|
171
|
-
label?: string;
|
|
172
|
-
rangeCode?: string;
|
|
173
|
-
decorNumber?: string;
|
|
174
166
|
};
|
|
175
167
|
export type ProductDetailData = {
|
|
176
168
|
id?: string;
|
|
@@ -200,31 +192,28 @@ export type ProductDetailData = {
|
|
|
200
192
|
standardCopyHero?: ProductDetailStandardCopyHero;
|
|
201
193
|
featuredProducts?: ProductDetailFeaturedProduct[];
|
|
202
194
|
};
|
|
203
|
-
export type ProductDetailWishlistPayload = {
|
|
204
|
-
sku?: string;
|
|
205
|
-
decor?: string;
|
|
206
|
-
};
|
|
207
|
-
export type ProductDetailOrder = {
|
|
208
|
-
type: string;
|
|
209
|
-
sku?: string;
|
|
210
|
-
decor?: string;
|
|
211
|
-
product: string | null;
|
|
212
|
-
grade: string | null;
|
|
213
|
-
texture: string | null;
|
|
214
|
-
size: string | null;
|
|
215
|
-
quantity: number;
|
|
216
|
-
priceValue?: number;
|
|
217
|
-
priceLabel?: string;
|
|
218
|
-
currency?: string;
|
|
219
|
-
};
|
|
220
|
-
export type ProductDetailCartFlyoutProps = Omit<CartFlyoutProps, "isOpen" | "onClose">;
|
|
221
195
|
export type ProductDetailPageTemplateProps = {
|
|
222
196
|
breadcrumbsProps?: BreadcrumbsProps;
|
|
223
|
-
productData
|
|
224
|
-
onDownloadSwatch?: (
|
|
225
|
-
onDownloadFullSheet?: (
|
|
226
|
-
onAddToWishlist?: (payload:
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
197
|
+
productData?: ProductDetailData;
|
|
198
|
+
onDownloadSwatch?: (data: ProductDetailData) => void;
|
|
199
|
+
onDownloadFullSheet?: (data: ProductDetailData) => void;
|
|
200
|
+
onAddToWishlist?: (payload: {
|
|
201
|
+
sku?: string;
|
|
202
|
+
decor?: string;
|
|
203
|
+
}, data: ProductDetailData) => void;
|
|
204
|
+
onAddToCart?: (order: {
|
|
205
|
+
type: string;
|
|
206
|
+
sku?: string;
|
|
207
|
+
decor?: string;
|
|
208
|
+
product: string | null;
|
|
209
|
+
grade: string | null;
|
|
210
|
+
texture: string | null;
|
|
211
|
+
size: string | null;
|
|
212
|
+
quantity: number;
|
|
213
|
+
priceValue?: number;
|
|
214
|
+
priceLabel?: string;
|
|
215
|
+
currency?: string;
|
|
216
|
+
}, data: ProductDetailData) => void;
|
|
217
|
+
onNavigate?: (href: string) => void;
|
|
218
|
+
cartFlyoutProps?: Omit<CartFlyoutProps, "isOpen" | "onClose">;
|
|
230
219
|
};
|