formica-ui-lib 1.0.135 → 1.0.141

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.
@@ -0,0 +1,11 @@
1
+ export interface ArticleRecentCardProps {
2
+ imageSrc: string;
3
+ imageAlt?: string;
4
+ category: string;
5
+ title: string;
6
+ publishDate: string;
7
+ body: string;
8
+ buttonLabel: string;
9
+ href?: string;
10
+ onViewClick?: () => void;
11
+ }
@@ -1,9 +1,8 @@
1
1
  export type FeaturedProductCardProps = {
2
2
  imageSrc: string;
3
- imageAlt: string;
3
+ imageAlt?: string;
4
4
  title: string;
5
- brand: string;
6
- decorNumber: string;
5
+ brand?: string;
6
+ decorNumber?: string | number;
7
7
  onClick?: () => void;
8
- href?: string;
9
8
  };
@@ -0,0 +1,6 @@
1
+ import type { ArticleRecentCardProps } from "../../../molecules/card/articlerecentcard/ArticleRecentCardProps";
2
+ export interface ArticleRecentSectionProps {
3
+ title?: string;
4
+ items: ArticleRecentCardProps[];
5
+ className?: string;
6
+ }
@@ -1,13 +1,15 @@
1
- export type FeaturedProductItem = {
1
+ export type FeaturedProductCarouselItem = {
2
2
  id: string;
3
3
  imageSrc: string;
4
- imageAlt: string;
4
+ imageAlt?: string;
5
5
  title: string;
6
- brand: string;
7
- decorNumber: string | number;
6
+ brand?: string;
7
+ decorNumber?: string;
8
8
  href?: string;
9
+ rangeCode?: string;
9
10
  };
10
11
  export type FeaturedProductsCarouselProps = {
11
12
  title?: string;
12
- items: FeaturedProductItem[];
13
+ items: FeaturedProductCarouselItem[];
14
+ onItemClick?: (item: FeaturedProductCarouselItem) => void;
13
15
  };
@@ -1,6 +1,7 @@
1
1
  import React from "react";
2
2
  import { RadioOptionSelectorProps } from "../../selectors/radiooptionselector/RadioOptionSelectorProps";
3
3
  import { DropdownOption } from "../../../atoms/dropdown/DropdownProps";
4
+ import { CheckboxChangePayload } from "../../../atoms/checkbox/CheckboxProps";
4
5
  export interface CartPaymentPanelErrors {
5
6
  cardNumber?: string;
6
7
  expirationDate?: string;
@@ -49,7 +50,7 @@ export interface CartPaymentPanelProps {
49
50
  onCardNumberChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
50
51
  onExpirationDateChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
51
52
  onSecurityCodeChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
52
- onSameAsShippingChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
53
+ onSameAsShippingChange?: (payload: CheckboxChangePayload) => void;
53
54
  onEditBilling?: () => void;
54
55
  onCardNumberBlur?: (event: React.FocusEvent<HTMLInputElement>) => void;
55
56
  onExpirationDateBlur?: (event: React.FocusEvent<HTMLInputElement>) => void;
@@ -1,4 +1,4 @@
1
1
  import { SwatchCardProps } from "../../molecules/card/swatchcard/SwatchCardProps";
2
2
  export interface DecorGridProps {
3
- swatches: SwatchCardProps[];
3
+ swatches?: SwatchCardProps[];
4
4
  }
@@ -2,11 +2,15 @@ import type { ArticleBannerProps } from "../../organisms/banner/articlebanner/Ar
2
2
  import type { ArticleTextProps } from "../../organisms/articles/articletext/ArticleTextProps";
3
3
  import type { ArticleImageProps } from "../../organisms/articles/articleimage/ArticleImageProps";
4
4
  import type { ArticleCarouselProps } from "../../organisms/articles/articlecarousel/ArticleCarouselProps";
5
- export type ArticlePageProps = {
5
+ import { FeaturedProductsCarouselProps } from "../../organisms/carousels/featureproductcarousel/FeaturedProductsCarouselProps";
6
+ import { ArticleRecentSectionProps } from "../../organisms/articles/articlerecentsection/ArticleRecentSectionProps";
7
+ export interface ArticlePageProps {
6
8
  articleBannerProps: ArticleBannerProps;
7
9
  articleHeaderProps: ArticleTextProps;
8
10
  articleTextProps: ArticleTextProps;
9
11
  articleTextProps2: ArticleTextProps;
10
12
  articleImageProps: ArticleImageProps;
11
13
  articleCarouselProps: ArticleCarouselProps;
12
- };
14
+ featuredProductsCarouselProps: FeaturedProductsCarouselProps;
15
+ articleRecentSectionProps: ArticleRecentSectionProps;
16
+ }
@@ -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 { ProductDetailPageTemplateProps } from "../../templates/productdetailpagetemplate/ProductDetailPageTemplateProps";
4
+ import type { ProductDetailPageTemplateProps } from "../../templates/productdetailpagetemplate/ProductDetailPageTemplateProps";
5
5
  export type ProductDetailSceneProps = {
6
6
  brandNavBarProps: BrandNavBarProps;
7
7
  topNavBarProps: TopNavBarProps;
@@ -158,11 +158,19 @@ export type ProductDetailStandardCopyHero = {
158
158
  export type ProductDetailFeaturedProduct = {
159
159
  id: string;
160
160
  imageSrc: string;
161
- imageAlt: string;
161
+ imageAlt?: string;
162
162
  title: string;
163
- brand: string;
164
- decorNumber: string | number;
163
+ brand?: string;
164
+ decorNumber?: string;
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;
166
174
  };
167
175
  export type ProductDetailData = {
168
176
  id?: string;
@@ -192,28 +200,31 @@ export type ProductDetailData = {
192
200
  standardCopyHero?: ProductDetailStandardCopyHero;
193
201
  featuredProducts?: ProductDetailFeaturedProduct[];
194
202
  };
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">;
195
221
  export type ProductDetailPageTemplateProps = {
196
222
  breadcrumbsProps?: BreadcrumbsProps;
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">;
223
+ productData: ProductDetailData;
224
+ onDownloadSwatch?: (productData: ProductDetailData) => void;
225
+ onDownloadFullSheet?: (productData: ProductDetailData) => void;
226
+ onAddToWishlist?: (payload: ProductDetailWishlistPayload, productData: ProductDetailData) => void;
227
+ onAddToCart?: (order: ProductDetailOrder, productData: ProductDetailData) => void;
228
+ onNavigate?: (href: string, meta?: unknown) => void;
229
+ cartFlyoutProps?: ProductDetailCartFlyoutProps;
219
230
  };