@soma-vertical-web/multi-lib 0.0.65 → 0.0.66

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 (63) hide show
  1. package/contexts/contexts/plp/PLPConstants.d.ts +6 -0
  2. package/contexts/contexts/plp/PLPInfiniteContext.tsx.d.ts +1 -1
  3. package/contexts/contexts/search/Constants.d.ts +6 -0
  4. package/contexts/contexts/search/Facets.d.ts +1 -1
  5. package/contexts/contexts/search/Products.d.ts +1 -1
  6. package/contexts/contexts/search/Search.d.ts +1 -1
  7. package/contexts/hooks/useScrollRestoration.d.ts +1 -1
  8. package/contexts/index.d.ts +4 -4
  9. package/data/helpers/search/search.d.ts +2 -0
  10. package/index-BBxYNFkz.mjs +416 -0
  11. package/index-CiMxj6Pg.mjs +412 -0
  12. package/index-CwBIv223.js +1 -0
  13. package/index-DKnolQoT.mjs +412 -0
  14. package/index.js +21 -21
  15. package/index.mjs +8264 -7197
  16. package/index2.js +1 -1
  17. package/index2.mjs +97 -94
  18. package/layout/index.d.ts +54 -8
  19. package/layout/team-component/PLPNavigation/Composite/BreadCrumb.d.ts +1 -3
  20. package/layout/team-component/PLPNavigation/Composite/Content.d.ts +1 -1
  21. package/layout/team-component/PLPNavigation/Composite/Filters.d.ts +1 -3
  22. package/layout/team-component/PLPNavigation/Composite/Root.d.ts +2 -2
  23. package/layout/team-component/PLPNavigation/Composite/Selected/Item.d.ts +1 -1
  24. package/layout/team-component/PLPNavigation/Composite/Selected/Selected.d.ts +1 -1
  25. package/layout/team-component/PLPNavigation/Composite/Selected/interfaces.d.ts +1 -7
  26. package/layout/team-component/PLPNavigation/PLPNavigation.d.ts +6 -6
  27. package/layout/team-component/Sort/Sort.d.ts +1 -1
  28. package/layout/template/PDC/Composite/Empty/Empty.d.ts +1 -1
  29. package/layout/template/PDC/Composite/Filters/Filters.d.ts +3 -5
  30. package/layout/template/PDC/Composite/Grid/Banners.d.ts +1 -1
  31. package/layout/template/PDC/Composite/Grid/Grid.d.ts +1 -1
  32. package/layout/template/PDC/Composite/Grid/NavigationTotal.d.ts +2 -3
  33. package/layout/template/PDC/Composite/InfiniteScroller/Banners/Banners.d.ts +1 -1
  34. package/layout/template/PDC/Composite/InfiniteScroller/InfiniteScroller.d.ts +1 -3
  35. package/layout/template/PDC/Composite/InfiniteScroller/Page/Composite/Card.d.ts +1 -1
  36. package/layout/template/PDC/Composite/InfiniteScroller/Page/Page.d.ts +1 -1
  37. package/layout/template/PDC/Composite/InfiniteScroller/Page/index.d.ts +1 -1
  38. package/layout/template/PDC/Composite/Navigation/Navigation.d.ts +1 -3
  39. package/layout/template/PDC/Composite/Notification/Notification.d.ts +1 -1
  40. package/layout/template/PDC/Composite/Pagination/Pagination.d.ts +1 -1
  41. package/layout/template/PDC/Composite/Pagination/helpers.d.ts +1 -2
  42. package/layout/template/PDC/Composite/Products/Products.d.ts +1 -1
  43. package/layout/template/PDC/PDC.d.ts +1 -1
  44. package/layout/template/PDC/index.d.ts +8 -8
  45. package/layout/template/SearchResult/Composite/Empty.d.ts +7 -0
  46. package/layout/template/SearchResult/Composite/Grid.d.ts +7 -0
  47. package/layout/template/SearchResult/Composite/GridHeader.d.ts +3 -0
  48. package/layout/template/SearchResult/Composite/Loading.d.ts +7 -0
  49. package/layout/template/SearchResult/Composite/Sort.d.ts +4 -0
  50. package/layout/template/SearchResult/SearchContent.d.ts +4 -0
  51. package/layout/template/SearchResult/SearchResult.d.ts +7 -0
  52. package/layout/template/SearchResult/index.d.ts +1 -0
  53. package/package.json +1 -1
  54. package/style.css +1 -1
  55. package/types/cms/ContentTypes/Search/index.d.ts +2 -2
  56. package/types/constants.d.ts +41 -1
  57. package/types/contexts/contexts/plp.d.ts +38 -7
  58. package/types/contexts/contexts/search.d.ts +18 -16
  59. package/types/contexts/hooks/index.d.ts +12 -0
  60. package/types/layout/team-components/PLPNavigation/index.d.ts +3 -14
  61. package/types/layout/team-components/Sort/index.d.ts +2 -5
  62. package/types/layout/templates/PLP/index.d.ts +122 -3
  63. package/types/layout/templates/SearchResult/index.d.ts +44 -0
@@ -3,9 +3,7 @@ import { ProductSearchResultPage } from '../../data/api/search/product';
3
3
  import { State } from '../../data/api/search';
4
4
  import { BannerType } from '../../cms/Sections/Banner';
5
5
  import { HasVariant, ProductType_PDC } from '../../global/product';
6
- import { ReadonlyURLSearchParams } from 'next/navigation';
7
- import { PLPSearchParamsType } from '../../layout/templates/PLP';
8
- import { PLP_SORT_DEFAULTType } from '../../constants';
6
+ import { BUY_BUTTON_LABELSType, ICONSType, ITEMS_DEFAULT_SORTType, ITEMS_PER_PAGEType, ITEMS_PER_SECTIONType, MAIN_IMAGEType, NEWSLETTER_CONFIGSType, NOTIFY_INFOType, PDC_NAVIGATIONType, PLP_FILTERS_COLORSType, PLP_FILTERS_EMPTYType, PLP_FILTERS_TITLEType, PLP_FILTERSType, PLP_GRID_SCROLL_BACKType, PLP_INFINITE_SCROLLType, PLP_NOT_RESULTType, PLP_PRODUCT_SIMILAR_DELAYType, PLP_SHOW_VIDEO_ON_PRODUCT_CARDType, PLP_SIZE_ORDERType, PLP_SORT_DEFAULTType, PRODUCT_CARD_IMAGE_ASPECT_RATIOType, PRODUCT_CARD_TEXTSType, PRODUCT_CARD_TOP_WISHLIST_TOGGLEType, PRODUCT_IMAGE_DIMENSIONSType, SEARCH_PAGE_ITEM_THRESHOLDType, SEARCH_TOTAL_PORTAL_IDType, SECOND_IMAGEType, StoreConfigType, TEXTURE_IMAGEType, VARIANT_PAGINATIONType, Z_INDEX_WARType } from '../../constants';
9
7
 
10
8
  export type PLPBanners = ({
11
9
  columns: number;
@@ -49,9 +47,6 @@ export interface PLPInfiniteContextProps extends PropsWithChildren<Omit<PageStat
49
47
  }
50
48
  export interface PLPInfiniteProviderProps extends PropsWithChildren {
51
49
  banners: PLPBanners;
52
- itemsPerPage?: number;
53
- searchParams?: ReadonlyURLSearchParams;
54
- Notification: React.ComponentType<any>;
55
50
  }
56
51
  export interface PLPContextProps {
57
52
  openFilters: boolean;
@@ -60,8 +55,44 @@ export interface PLPContextProps {
60
55
  export interface PLPProviderProps extends PropsWithChildren {
61
56
  slug: string[] | string;
62
57
  PLP_SORT_DEFAULT: PLP_SORT_DEFAULTType;
63
- searchParams?: PLPSearchParamsType;
58
+ searchParams?: URLSearchParams;
64
59
  collectionId?: number | null;
65
60
  itemsPerPage?: number;
66
61
  brand?: string | null;
67
62
  }
63
+ export interface PLPConstantsProviderProps extends PropsWithChildren {
64
+ BUY_BUTTON_LABELS: BUY_BUTTON_LABELSType;
65
+ ICONS: ICONSType;
66
+ ITEMS_DEFAULT_SORT: ITEMS_DEFAULT_SORTType;
67
+ ITEMS_PER_PAGE: ITEMS_PER_PAGEType;
68
+ ITEMS_PER_SECTION: ITEMS_PER_SECTIONType;
69
+ MAIN_IMAGE: MAIN_IMAGEType;
70
+ NEWSLETTER_CONFIGS: NEWSLETTER_CONFIGSType;
71
+ NOTIFY_INFO: NOTIFY_INFOType;
72
+ PDC_NAVIGATION: PDC_NAVIGATIONType;
73
+ PLP_FILTERS: PLP_FILTERSType;
74
+ PLP_FILTERS_COLORS: PLP_FILTERS_COLORSType;
75
+ PLP_FILTERS_EMPTY: PLP_FILTERS_EMPTYType;
76
+ PLP_FILTERS_TITLE: PLP_FILTERS_TITLEType;
77
+ PLP_GRID_SCROLL_BACK: PLP_GRID_SCROLL_BACKType;
78
+ PLP_INFINITE_SCROLL: PLP_INFINITE_SCROLLType;
79
+ PLP_NOT_RESULT: PLP_NOT_RESULTType;
80
+ PLP_PRODUCT_SIMILAR_DELAY: PLP_PRODUCT_SIMILAR_DELAYType;
81
+ PLP_SHOW_VIDEO_ON_PRODUCT_CARD: PLP_SHOW_VIDEO_ON_PRODUCT_CARDType;
82
+ PLP_SIZE_ORDER: PLP_SIZE_ORDERType;
83
+ PLP_SORT_DEFAULT: PLP_SORT_DEFAULTType;
84
+ PRODUCT_CARD_IMAGE_ASPECT_RATIO: PRODUCT_CARD_IMAGE_ASPECT_RATIOType;
85
+ PRODUCT_CARD_TEXTS: PRODUCT_CARD_TEXTSType;
86
+ PRODUCT_CARD_TOP_WISHLIST_TOGGLE: PRODUCT_CARD_TOP_WISHLIST_TOGGLEType;
87
+ PRODUCT_IMAGE_DIMENSIONS: PRODUCT_IMAGE_DIMENSIONSType;
88
+ SEARCH_PAGE_ITEM_THRESHOLD: SEARCH_PAGE_ITEM_THRESHOLDType;
89
+ SEARCH_TOTAL_PORTAL_ID: SEARCH_TOTAL_PORTAL_IDType;
90
+ SECOND_IMAGE: SECOND_IMAGEType;
91
+ TEXTURE_IMAGE: TEXTURE_IMAGEType;
92
+ VARIANT_PAGINATION: VARIANT_PAGINATIONType;
93
+ Z_INDEX_WAR: Z_INDEX_WARType;
94
+ StoreConfig_MainSellerId: StoreConfigType['mainSeller']['id'];
95
+ WishListToggle: React.ComponentType<any>;
96
+ searchParams: URLSearchParams;
97
+ }
98
+ export type PLPConstantsContextProps = Omit<PLPConstantsProviderProps, 'children'>;
@@ -2,8 +2,9 @@ import { Dispatch, PropsWithChildren, SetStateAction } from 'react';
2
2
  import { ProductSearchResultPage } from '../../data/api/search/product';
3
3
  import { State, Suggestion } from '../../data/api/search';
4
4
  import { Facet, SelectedFacet } from '../../data/api/search/facets';
5
- import { ITEMS_PER_PAGEType, PLP_FILTERS_SORT_OPTIONtype, PLP_SORT_DEFAULTType } from '../../constants';
5
+ import { ITEMS_DEFAULT_SORTType, ITEMS_PER_PAGEType, ITEMS_PER_SECTIONType, PLP_FILTERS_SORT_OPTIONtype, SEARCH_PAGE_ITEM_THRESHOLDType, SEARCH_RESULTType, VARIANT_PAGINATIONType } from '../../constants';
6
6
  import { BreadCrumbItemLinkProps } from '../../layout/team-components/PLPNavigation';
7
+ import { ProductsProps } from '../../layout/templates/PLP';
7
8
 
8
9
  export interface FacetsContextProps {
9
10
  breadcrumb: BreadCrumbItemLinkProps[];
@@ -11,19 +12,14 @@ export interface FacetsContextProps {
11
12
  facets: Facet[];
12
13
  isLoading: boolean;
13
14
  selectedFacets: SelectedFacet[];
14
- searchParams: FacetsProviderProps['searchParams'];
15
15
  onToggleFacet(value: SelectedFacet): void;
16
16
  onSort(sort: PLP_FILTERS_SORT_OPTIONtype): void;
17
17
  }
18
- export interface FacetsProviderProps extends PropsWithChildren, Pick<ProductsProviderProps, 'state' | 'forceUpdate'> {
19
- searchParams: {
20
- [key: string]: string | string[] | undefined;
21
- };
22
- PLP_SORT_DEFAULT: PLP_SORT_DEFAULTType;
18
+ export interface FacetsProviderProps extends PropsWithChildren {
19
+ forceUpdate?: boolean;
23
20
  }
24
- export interface FacetsProviderContentProps extends FacetsProviderProps {
21
+ export interface FacetsProviderContentProps extends Omit<FacetsProviderProps, 'forceUpdate'> {
25
22
  selectedFacets: SelectedFacet[];
26
- PLP_SORT_DEFAULT: PLP_SORT_DEFAULTType;
27
23
  }
28
24
  export interface ProductsContextProps extends ProductSearchResultPage {
29
25
  isLoading: boolean;
@@ -38,24 +34,21 @@ export interface SuggestedTermsProviderProps extends PropsWithChildren {
38
34
  term?: string;
39
35
  }
40
36
  export interface ProductsProviderProps extends PropsWithChildren {
41
- state?: State;
42
37
  query?: string;
43
- selectedFacets?: SelectedFacet[];
44
38
  forceUpdate?: boolean;
45
39
  }
46
- export interface SearchContextProps extends Pick<SearchProviderProps, 'sort'> {
40
+ export interface SearchContextProps extends Pick<SearchProviderProps, 'sort' | 'searchParams'> {
47
41
  count: number;
48
42
  state: State;
49
43
  }
50
44
  export interface SearchProviderProps extends PropsWithChildren {
51
- sort?: string;
45
+ searchParams: URLSearchParams;
52
46
  state: State;
47
+ sort?: string;
53
48
  collectionId?: number | null;
54
49
  brand?: string | null;
55
50
  count?: number;
56
- CONSTANTS: {
57
- ITEMS_PER_PAGE: ITEMS_PER_PAGEType;
58
- };
51
+ ITEMS_PER_PAGE: ITEMS_PER_PAGEType;
59
52
  }
60
53
  export interface SearchItem {
61
54
  term: string;
@@ -80,3 +73,12 @@ export interface SearchStore extends Pick<RootContextProps, 'data'> {
80
73
  isError?: boolean;
81
74
  fetchData: (fetcher: () => Promise<Response>) => Promise<void>;
82
75
  }
76
+ export interface SearchConstantsProviderProps extends PropsWithChildren, Omit<ProductsProps, 'items' | 'isMobile'> {
77
+ ITEMS_PER_PAGE: ITEMS_PER_PAGEType;
78
+ ITEMS_DEFAULT_SORT: ITEMS_DEFAULT_SORTType;
79
+ ITEMS_PER_SECTION: ITEMS_PER_SECTIONType;
80
+ SEARCH_PAGE_ITEM_THRESHOLD: SEARCH_PAGE_ITEM_THRESHOLDType;
81
+ SEARCH_RESULT: SEARCH_RESULTType;
82
+ VARIANT_PAGINATION: VARIANT_PAGINATIONType;
83
+ }
84
+ export type SearchConstantsContextProps = Omit<SearchConstantsProviderProps, 'children'>;
@@ -1,3 +1,6 @@
1
+ import { PLP_GRID_SCROLL_BACKType } from '../../constants';
2
+ import { Page } from '../contexts/plp';
3
+
1
4
  export interface UseBackPDCProps {
2
5
  gridScrollBack?: {
3
6
  refer: string;
@@ -5,3 +8,12 @@ export interface UseBackPDCProps {
5
8
  };
6
9
  }
7
10
  export type FetchPriority = 'auto' | 'high' | 'low';
11
+ export type UseScrollRestorationProps = {
12
+ productCount: number;
13
+ PLP_GRID_SCROLL_BACK: PLP_GRID_SCROLL_BACKType;
14
+ };
15
+ export type UseScrollRestorationInfiniteProps = {
16
+ pages: Page[];
17
+ load: boolean;
18
+ PLP_GRID_SCROLL_BACK: PLP_GRID_SCROLL_BACKType;
19
+ };
@@ -1,8 +1,7 @@
1
1
  import { Dispatch, HTMLAttributes, SetStateAction } from 'react';
2
2
  import { SearchSort } from '../../../data/api/search';
3
3
  import { FacetsContextProps } from '../../../contexts/contexts/search';
4
- import { ICONSType, PDC_NAVIGATIONType } from '../../../constants';
5
- import { ReadonlyURLSearchParams } from 'next/navigation';
4
+ import { ICONSType } from '../../../constants';
6
5
 
7
6
  export interface BreadCrumbItemLinkProps extends HTMLAttributes<HTMLDivElement> {
8
7
  isLast?: boolean;
@@ -24,15 +23,5 @@ export interface PDCNavigationContextProps extends PDCNavigationProviderProps {
24
23
  openOrderBy: boolean;
25
24
  setOpenOrderBy: Dispatch<SetStateAction<boolean>>;
26
25
  }
27
- export type PLPNavigationFiltersProps = {
28
- PDC_NAVIGATION: PDC_NAVIGATIONType;
29
- ICONS: ICONSType;
30
- searchParams: ReadonlyURLSearchParams;
31
- };
32
- export interface PLPContentProps extends HTMLAttributes<HTMLDivElement>, PLPNavigationFiltersProps {
33
- }
34
- export interface PLPBreadcrumbProps extends HTMLAttributes<HTMLDivElement> {
35
- ICONS: ICONSType;
36
- }
37
- export interface PLPRootProps extends PDCNavigationProviderProps, PLPNavigationFiltersProps {
38
- }
26
+ export type PLPContentProps = HTMLAttributes<HTMLDivElement>;
27
+ export type PLPNavigationRootProps = PDCNavigationProviderProps;
@@ -2,7 +2,6 @@ import { ButtonProps } from '@soma-vertical-web/core-components/src/lib/Button/i
2
2
  import { Dispatch, HTMLAttributes, ReactNode, SetStateAction } from 'react';
3
3
  import { ICONSType, PLP_FILTERS_SORT_OPTIONtype } from '../../../constants';
4
4
  import { PLP_FILTERS_SORT } from '../../../../constants';
5
- import { ReadonlyURLSearchParams } from 'next/navigation';
6
5
 
7
6
  export type RootProps = HTMLAttributes<HTMLDivElement>;
8
7
  export interface SortButtonProps extends Omit<ButtonProps, 'adornment' | 'iconNameStart' | 'iconNameEnd'> {
@@ -16,9 +15,7 @@ export interface SortProps extends RootProps {
16
15
  handleSelectValue?: (value?: PLP_FILTERS_SORT_OPTIONtype) => void;
17
16
  sortListOpen: boolean;
18
17
  setSortListOpen: Dispatch<SetStateAction<boolean>>;
19
- searchParams: ReadonlyURLSearchParams;
20
- CONSTANTS: {
21
- ICONS: ICONSType;
22
- };
18
+ searchParams: URLSearchParams;
19
+ ICONS: ICONSType;
23
20
  }
24
21
  export type PLPFilterOption = keyof typeof PLP_FILTERS_SORT.options;
@@ -1,9 +1,128 @@
1
+ import { HTMLAttributes, PropsWithChildren } from 'react';
2
+ import { BannerType } from '../../../cms/Sections/Banner';
3
+ import { Page, PLPConstantsContextProps } from '../../../contexts/contexts/plp';
4
+ import { ProductCardProps } from '../../team-components/ProductCard';
5
+ import { AvailabilityNotifyProps } from '../../../../types/layout/team-components/Notify';
6
+ import { ProductType_PDC } from '../../../global/product';
7
+ import { BUY_BUTTON_LABELSType, ICONSType, ITEMS_DEFAULT_SORTType, ITEMS_PER_PAGEType, ITEMS_PER_SECTIONType, MAIN_IMAGEType, NEWSLETTER_CONFIGSType, NOTIFY_INFOType, PLP_GRID_SCROLL_BACKType, PLP_INFINITE_SCROLLType, PLP_PRODUCT_SIMILAR_DELAYType, PLP_SHOW_VIDEO_ON_PRODUCT_CARDType, PRODUCT_CARD_IMAGE_ASPECT_RATIOType, PRODUCT_CARD_TEXTSType, PRODUCT_CARD_TOP_WISHLIST_TOGGLEType, PRODUCT_IMAGE_DIMENSIONSType, SEARCH_PAGE_ITEM_THRESHOLDType, SECOND_IMAGEType, StoreConfigType, TEXTURE_IMAGEType, VARIANT_PAGINATIONType, Z_INDEX_WARType } from '../../../constants';
8
+
9
+ export type PLPNavigationRootProps = {
10
+ searchParams: {
11
+ [key: string]: string | string[] | undefined;
12
+ };
13
+ className?: string;
14
+ };
1
15
  export type PLPProps = {
2
16
  slug: string[] | string;
3
- searchParams: PLPSearchParamsType;
17
+ searchParams: URLSearchParams;
4
18
  collectionId?: number | null;
5
19
  brand?: string | null;
6
20
  };
7
- export type PLPSearchParamsType = {
8
- [key: string]: string | string[] | undefined;
21
+ export interface BannerPropsExtended extends BannerType {
22
+ columns: number;
23
+ position_grid: number;
24
+ }
25
+ export interface BannersProps {
26
+ gap: number;
27
+ isMobile: boolean;
28
+ }
29
+ export interface InfiniteBannersProps {
30
+ columns: number;
31
+ count: number;
32
+ gap: number;
33
+ }
34
+ export interface GridProps extends HTMLAttributes<HTMLDivElement> {
35
+ infinite?: boolean;
36
+ }
37
+ export interface PageSentinelProps extends HTMLAttributes<HTMLDivElement> {
38
+ page: Page;
39
+ }
40
+ export interface PageCardProps {
41
+ first?: boolean;
42
+ last?: boolean;
43
+ gap: number;
44
+ index: number;
45
+ isMobile?: boolean;
46
+ item: ProductCardProps;
47
+ order: number;
48
+ page?: Page;
49
+ showVideo?: boolean;
50
+ }
51
+ export interface PageProps {
52
+ count: number;
53
+ gap: number;
54
+ page: Page;
55
+ }
56
+ export interface NotificationProps extends Pick<AvailabilityNotifyProps, 'open' | 'sku' | 'setSku' | 'setVisible'> {
57
+ skus: ProductType_PDC['isVariantOf']['hasVariant'];
58
+ ICONS: ICONSType;
59
+ NEWSLETTER_CONFIGS: NEWSLETTER_CONFIGSType;
60
+ NOTIFY_INFO: NOTIFY_INFOType;
61
+ PRODUCT_CARD_TEXTS: PRODUCT_CARD_TEXTSType;
62
+ Z_INDEX_WAR: Z_INDEX_WARType;
63
+ }
64
+ export interface LayoutProps extends PropsWithChildren {
65
+ endPage: number;
66
+ page: number;
67
+ total: number;
68
+ selectedPage(page: number): void;
69
+ ITEMS_PER_SECTION: ITEMS_PER_SECTIONType;
70
+ }
71
+ export interface PagesProps {
72
+ currentPage: number;
73
+ searchParams: URLSearchParams;
74
+ pages: number[];
75
+ VARIANT_PAGINATION: VARIANT_PAGINATIONType;
76
+ }
77
+ export type PaginantionOptionsProps = {
78
+ currentPage: number;
79
+ total: number;
80
+ maxVisiblePages: number;
81
+ SEARCH_PAGE_ITEM_THRESHOLD: SEARCH_PAGE_ITEM_THRESHOLDType;
82
+ };
83
+ export interface PaginationProps extends HTMLAttributes<HTMLDivElement> {
84
+ query?: string;
85
+ type?: 'search' | 'default';
86
+ searchParams: URLSearchParams;
87
+ ITEMS_DEFAULT_SORT: ITEMS_DEFAULT_SORTType;
88
+ ITEMS_PER_SECTION: ITEMS_PER_SECTIONType;
89
+ ITEMS_PER_PAGE: ITEMS_PER_PAGEType;
90
+ SEARCH_PAGE_ITEM_THRESHOLD: SEARCH_PAGE_ITEM_THRESHOLDType;
91
+ VARIANT_PAGINATION: VARIANT_PAGINATIONType;
92
+ }
93
+ export interface ProductsProps {
94
+ items: {
95
+ node: ProductCardProps;
96
+ }[];
97
+ isMobile?: boolean;
98
+ BUY_BUTTON_LABELS: BUY_BUTTON_LABELSType;
99
+ ICONS: ICONSType;
100
+ MAIN_IMAGE: MAIN_IMAGEType;
101
+ NEWSLETTER_CONFIGS: NEWSLETTER_CONFIGSType;
102
+ NOTIFY_INFO: NOTIFY_INFOType;
103
+ PLP_GRID_SCROLL_BACK: PLP_GRID_SCROLL_BACKType;
104
+ PLP_INFINITE_SCROLL: PLP_INFINITE_SCROLLType;
105
+ PLP_PRODUCT_SIMILAR_DELAY: PLP_PRODUCT_SIMILAR_DELAYType;
106
+ PLP_SHOW_VIDEO_ON_PRODUCT_CARD: PLP_SHOW_VIDEO_ON_PRODUCT_CARDType;
107
+ PRODUCT_CARD_IMAGE_ASPECT_RATIO: PRODUCT_CARD_IMAGE_ASPECT_RATIOType;
108
+ PRODUCT_CARD_TEXTS: PRODUCT_CARD_TEXTSType;
109
+ PRODUCT_CARD_TOP_WISHLIST_TOGGLE: PRODUCT_CARD_TOP_WISHLIST_TOGGLEType;
110
+ PRODUCT_IMAGE_DIMENSIONS: PRODUCT_IMAGE_DIMENSIONSType;
111
+ SECOND_IMAGE: SECOND_IMAGEType;
112
+ StoreConfig_MainSellerId: StoreConfigType['mainSeller']['id'];
113
+ TEXTURE_IMAGE: TEXTURE_IMAGEType;
114
+ Z_INDEX_WAR: Z_INDEX_WARType;
115
+ WishListToggle: React.ComponentType<any>;
116
+ }
117
+ export interface PLPRootProps extends PLPConstantsContextProps {
118
+ className?: string;
119
+ }
120
+ export type EmptyProps = {
121
+ className?: string;
122
+ content?: {
123
+ link: string;
124
+ text: string;
125
+ title: string;
126
+ subtitle: string;
127
+ };
9
128
  };
@@ -0,0 +1,44 @@
1
+ import { HTMLAttributes } from 'react';
2
+ import { SearchSort } from '../../../data/api/search';
3
+ import { SearchConstantsContextProps } from '../../../contexts/contexts/search';
4
+
5
+ export interface ISearchEmpty {
6
+ term?: string;
7
+ }
8
+ export interface ISearchSort {
9
+ term?: string;
10
+ }
11
+ export interface ISearchLoading {
12
+ isLoading: boolean;
13
+ quantity: number;
14
+ term?: string;
15
+ }
16
+ export interface SearchResultContentProps extends HTMLAttributes<HTMLDivElement> {
17
+ isMobile?: boolean;
18
+ banners?: any[];
19
+ sort?: SearchSort;
20
+ query?: string;
21
+ currentPage: number;
22
+ className?: string;
23
+ }
24
+ export interface IPaginationProps {
25
+ currentPage: number;
26
+ firstPageSpread: boolean;
27
+ lastPageSpread: boolean;
28
+ totalPages: number;
29
+ onPageChange: (page: number) => void;
30
+ hasNextPage: boolean;
31
+ hasPreviousPage: boolean;
32
+ slices: {
33
+ start: number;
34
+ end: number;
35
+ };
36
+ }
37
+ export interface SearchProps {
38
+ className?: string;
39
+ searchParams: URLSearchParams;
40
+ CONSTANTS: SearchConstantsContextProps;
41
+ }
42
+ export type SearchContentProps = {
43
+ className?: string;
44
+ };