@sonic-equipment/ui 0.0.50 → 0.0.51
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/algolia/algolia-active-categories.d.ts +1 -0
- package/dist/algolia/algolia-categories-filters.d.ts +1 -0
- package/dist/algolia/algolia-filter-panel.d.ts +3 -2
- package/dist/algolia/algolia-insights-provider.d.ts +1 -1
- package/dist/algolia/algolia-multi-select-filter-section.d.ts +1 -1
- package/dist/{shared/types/product.d.ts → algolia/algolia-product-hit-type.d.ts} +2 -2
- package/dist/algolia/algolia-query-string-routing.d.ts +4 -1
- package/dist/algolia/filter-section.d.ts +26 -0
- package/dist/algolia/use-algolia-insights.d.ts +1 -1
- package/dist/algolia/use-algolia-product-hits.d.ts +2 -0
- package/dist/{global-search/global-search-provider → algolia}/use-algolia-search.d.ts +17 -7
- package/dist/cards/category-card/category-card.d.ts +7 -3
- package/dist/cards/product-card/product-card.d.ts +4 -4
- package/dist/cards/product-card/product-card.stories.d.ts +6 -2
- package/dist/config.d.ts +0 -1
- package/dist/global-search/categories-grid/categories-grid.d.ts +5 -0
- package/dist/global-search/plugins/products-plugin.d.ts +2 -2
- package/dist/global-search/search-section/search-list-item.d.ts +10 -0
- package/dist/global-search/search-section/search-list.d.ts +9 -0
- package/dist/global-search/search-section/search-section.d.ts +9 -0
- package/dist/global-search/types.d.ts +2 -2
- package/dist/index.d.ts +215 -155
- package/dist/index.js +568 -382
- package/dist/intl/translation-id.d.ts +1 -1
- package/dist/media/image/image.d.ts +2 -2
- package/dist/media/image/image.stories.d.ts +2 -1
- package/dist/pages/product-listing-page/product-listing-page-data-types.d.ts +11 -10
- package/dist/pages/product-listing-page/product-listing-page-provider/use-subcategories.d.ts +1 -1
- package/dist/promos/promo-card/promo-card.d.ts +3 -6
- package/dist/promos/promo-cards/promo-cards.d.ts +2 -2
- package/dist/promos/promo-cards/promo-cards.stories.d.ts +1 -1
- package/dist/shared/api/bff/model/bff.model.d.ts +6 -9
- package/dist/shared/api/shop/hooks/cart/use-add-product-to-current-cart.d.ts +1 -1
- package/dist/shared/api/shop/hooks/cart/use-fetch-current-cart-lines.d.ts +1 -1
- package/dist/shared/api/shop/hooks/cart/use-update-cart-line-by-id.d.ts +1 -1
- package/dist/shared/hooks/use-breakpoint.d.ts +2 -13
- package/dist/shared/hooks/use-is-breakpoint.d.ts +1 -1
- package/dist/shared/model/category.d.ts +6 -0
- package/dist/shared/model/image.d.ts +27 -0
- package/dist/shared/model/product-hit.d.ts +18 -0
- package/dist/shared/providers/global-state-provider.d.ts +3 -3
- package/dist/shared/utils/breakpoints.d.ts +12 -0
- package/dist/sidebar/sidebar-provider.d.ts +1 -1
- package/dist/sidebar/types.d.ts +10 -0
- package/dist/sidebar/use-sidebar.d.ts +3 -2
- package/dist/styles.css +252 -165
- package/package.json +3 -2
- package/dist/algolia/algolia-categories.d.ts +0 -1
- package/dist/global-search/search-result-panel/sections/search-content-section.d.ts +0 -3
- package/dist/shared/types/category.d.ts +0 -6
- package/dist/shared/types/image.d.ts +0 -30
- package/dist/sidebar/sidebar-context.d.ts +0 -8
- /package/dist/{global-search/global-search-provider → algolia}/algolia-search-provider.d.ts +0 -0
- /package/dist/algolia/{user-algolia-insights-provider-global-state.d.ts → use-algolia-insights-provider-global-state.d.ts} +0 -0
- /package/dist/shared/{types → model}/cart.d.ts +0 -0
- /package/dist/shared/{types → model}/price.d.ts +0 -0
package/dist/index.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ import * as algoliasearch from 'algoliasearch';
|
|
|
7
7
|
import { SearchClient } from 'algoliasearch';
|
|
8
8
|
import { RouterProps } from 'instantsearch.js/es/middlewares/createRouterMiddleware';
|
|
9
9
|
import { UiState } from 'instantsearch.js/es/types';
|
|
10
|
-
import { AutocompleteApi, AutocompleteState as AutocompleteState$1, AutocompleteCollection } from '@algolia/autocomplete-core';
|
|
10
|
+
import { AutocompleteApi, AutocompleteState as AutocompleteState$1, AutocompleteCollection, InternalAutocompleteSource, BaseItem } from '@algolia/autocomplete-core';
|
|
11
11
|
|
|
12
12
|
declare const environments = ['sandbox', 'production'] as const
|
|
13
13
|
type Environment = (typeof environments)[number]
|
|
@@ -17,13 +17,41 @@ interface Config {
|
|
|
17
17
|
ALGOLIA_APP_ID: string;
|
|
18
18
|
ALGOLIA_HOST: string;
|
|
19
19
|
ALGOLIA_PROXY_HOST: string;
|
|
20
|
-
BFF_API_URL: string;
|
|
21
20
|
PROXY_API_URL: string;
|
|
22
21
|
SHOP_API_URL: string;
|
|
23
22
|
}
|
|
24
23
|
declare const configPerEnvironment: Record<Environment, Config>;
|
|
25
24
|
declare const config: Config;
|
|
26
25
|
|
|
26
|
+
interface DPRSrcSet {
|
|
27
|
+
1: string
|
|
28
|
+
2: string
|
|
29
|
+
3: string
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
interface Image$1 extends DPRSrcSet {
|
|
33
|
+
altText: string
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
interface ImageSource {
|
|
37
|
+
className?: string
|
|
38
|
+
fallbackSrc?: string
|
|
39
|
+
fit?: 'contain' | 'cover'
|
|
40
|
+
height?: number
|
|
41
|
+
image: Image$1 | ResponsiveImage
|
|
42
|
+
loading?: 'lazy' | 'eager'
|
|
43
|
+
onError?: () => void
|
|
44
|
+
title: string
|
|
45
|
+
width?: number
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
interface ResponsiveImage {
|
|
49
|
+
altText: string
|
|
50
|
+
lg: DPRSrcSet
|
|
51
|
+
md: DPRSrcSet
|
|
52
|
+
sm: DPRSrcSet
|
|
53
|
+
}
|
|
54
|
+
|
|
27
55
|
interface Category$1 {
|
|
28
56
|
activateOn: string;
|
|
29
57
|
deactivateOn: string | null;
|
|
@@ -52,16 +80,12 @@ interface Category$1 {
|
|
|
52
80
|
uri: null;
|
|
53
81
|
urlSegment: string;
|
|
54
82
|
}
|
|
55
|
-
interface
|
|
56
|
-
alt: string;
|
|
83
|
+
interface PromoCard$1 {
|
|
57
84
|
href: string;
|
|
58
|
-
|
|
59
|
-
src: string;
|
|
60
|
-
width: number;
|
|
61
|
-
}[];
|
|
85
|
+
image: ResponsiveImage;
|
|
62
86
|
}
|
|
63
|
-
interface
|
|
64
|
-
top:
|
|
87
|
+
interface PromoCards {
|
|
88
|
+
top: PromoCard$1[];
|
|
65
89
|
}
|
|
66
90
|
interface BreadCrumb {
|
|
67
91
|
categoryId: string;
|
|
@@ -69,58 +93,35 @@ interface BreadCrumb {
|
|
|
69
93
|
url: string;
|
|
70
94
|
}
|
|
71
95
|
interface ProductListingPageDataResponse {
|
|
72
|
-
banner: Banner;
|
|
73
96
|
breadCrumb: BreadCrumb[];
|
|
74
97
|
categories: Category$1;
|
|
75
98
|
categoryPages: string;
|
|
99
|
+
promoCards: PromoCards | null;
|
|
76
100
|
}
|
|
77
101
|
|
|
78
|
-
|
|
79
|
-
{ breakpoint: 'sm'; url: string; width: number },
|
|
80
|
-
{ breakpoint: 'md'; url: string; width: number },
|
|
81
|
-
{ breakpoint: 'lg'; url: string; width: number },
|
|
82
|
-
]
|
|
83
|
-
|
|
84
|
-
interface ImageSource {
|
|
85
|
-
alt: string
|
|
86
|
-
className?: string
|
|
87
|
-
fallbackSrc?: string
|
|
88
|
-
fit?: 'contain' | 'cover'
|
|
89
|
-
height?: number
|
|
90
|
-
loading?: 'lazy' | 'eager'
|
|
91
|
-
src: string
|
|
92
|
-
srcSet?: ImageSourceSet
|
|
93
|
-
title: string
|
|
94
|
-
width?: number
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
interface Category {
|
|
102
|
+
interface PromoCard {
|
|
98
103
|
href: string
|
|
99
|
-
image:
|
|
100
|
-
title: string
|
|
104
|
+
image: ResponsiveImage
|
|
101
105
|
}
|
|
102
106
|
|
|
103
|
-
interface
|
|
104
|
-
alt: string
|
|
107
|
+
interface Link$2 {
|
|
105
108
|
href: string
|
|
106
|
-
|
|
107
|
-
src: string
|
|
108
|
-
width: number
|
|
109
|
-
}[]
|
|
109
|
+
label: string
|
|
110
110
|
}
|
|
111
111
|
|
|
112
|
-
interface
|
|
112
|
+
interface Category {
|
|
113
113
|
href: string
|
|
114
|
-
|
|
114
|
+
image: Image$1
|
|
115
|
+
title: string
|
|
115
116
|
}
|
|
116
117
|
|
|
117
118
|
interface ProductListingPageData {
|
|
118
|
-
banner: {
|
|
119
|
-
top: BannerItem[]
|
|
120
|
-
}
|
|
121
119
|
breadCrumb: Link$2[]
|
|
122
120
|
category: Category
|
|
123
121
|
categoryPages: string
|
|
122
|
+
promoCards?: {
|
|
123
|
+
top: PromoCard[]
|
|
124
|
+
}
|
|
124
125
|
subcategories: Category[] | undefined
|
|
125
126
|
}
|
|
126
127
|
|
|
@@ -3284,18 +3285,23 @@ interface UpdateCartLineParams {
|
|
|
3284
3285
|
}
|
|
3285
3286
|
declare function useUpdateCartLineById(): _tanstack_react_query.UseMutationResult<void, Error, UpdateCartLineParams, unknown>;
|
|
3286
3287
|
|
|
3287
|
-
|
|
3288
|
-
|
|
3289
|
-
|
|
3290
|
-
|
|
3291
|
-
|
|
3292
|
-
|
|
3293
|
-
|
|
3294
|
-
|
|
3295
|
-
|
|
3296
|
-
|
|
3288
|
+
/* eslint-disable sort-keys-fix/sort-keys-fix */
|
|
3289
|
+
declare const breakpoints = {
|
|
3290
|
+
sm: 0,
|
|
3291
|
+
md: 576,
|
|
3292
|
+
lg: 768,
|
|
3293
|
+
xl: 1024,
|
|
3294
|
+
xxl: 1440,
|
|
3295
|
+
} as const
|
|
3296
|
+
/* eslint-enable sort-keys-fix/sort-keys-fix */
|
|
3297
|
+
|
|
3298
|
+
type Breakpoint = keyof typeof breakpoints
|
|
3299
|
+
|
|
3300
|
+
interface BreakpointsReturnType extends Record<Breakpoint, boolean> {
|
|
3301
|
+
current: Breakpoint
|
|
3297
3302
|
}
|
|
3298
|
-
|
|
3303
|
+
|
|
3304
|
+
declare const useBreakpoint: () => BreakpointsReturnType;
|
|
3299
3305
|
|
|
3300
3306
|
declare function useDebouncedCallback<T extends (...args: any[]) => any>(func: T, delay: number): (...args: Parameters<T>) => void;
|
|
3301
3307
|
|
|
@@ -3556,10 +3562,10 @@ interface GlobalStateProviderProps {
|
|
|
3556
3562
|
}
|
|
3557
3563
|
declare function GlobalStateProvider({ children, }: GlobalStateProviderProps): ReactElement | null;
|
|
3558
3564
|
interface UpdateGlobalState$1<T> {
|
|
3559
|
-
(value: T
|
|
3560
|
-
(fn: (value: T
|
|
3565
|
+
(value: T): void;
|
|
3566
|
+
(fn: (value: T) => T): void;
|
|
3561
3567
|
}
|
|
3562
|
-
declare function useGlobalState<T>(key: string | symbol): [T | undefined, UpdateGlobalState$1<T>];
|
|
3568
|
+
declare function useGlobalState<T>(key: string | symbol): [T | undefined, UpdateGlobalState$1<T | undefined>];
|
|
3563
3569
|
declare function useGlobalState<T>(key: string | symbol, initialState: T): [T, UpdateGlobalState$1<T>];
|
|
3564
3570
|
|
|
3565
3571
|
interface NavigateOptions$1 {
|
|
@@ -3593,43 +3599,64 @@ interface RouteButtonProps extends ButtonProps$1, RefAttributes<HTMLButtonElemen
|
|
|
3593
3599
|
}
|
|
3594
3600
|
declare function RouteButton({ children, ...props }: RouteButtonProps): react_jsx_runtime.JSX.Element;
|
|
3595
3601
|
|
|
3596
|
-
interface
|
|
3597
|
-
|
|
3598
|
-
|
|
3599
|
-
|
|
3600
|
-
|
|
3601
|
-
|
|
3602
|
-
|
|
3603
|
-
|
|
3604
|
-
|
|
3605
|
-
|
|
3606
|
-
|
|
3607
|
-
|
|
3608
|
-
|
|
3609
|
-
|
|
3602
|
+
interface AlgoliaProduct$1 {
|
|
3603
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3604
|
+
[key: string]: any
|
|
3605
|
+
alternativeNumber: string
|
|
3606
|
+
categories: string[]
|
|
3607
|
+
categoryPageId: string[]
|
|
3608
|
+
consumerPrice: number
|
|
3609
|
+
discountedPrice: number
|
|
3610
|
+
drawerQuantity: string
|
|
3611
|
+
ean: string
|
|
3612
|
+
height: number
|
|
3613
|
+
hierarchicalCategories: {
|
|
3614
|
+
lvl0: string
|
|
3615
|
+
lvl1: string
|
|
3616
|
+
}
|
|
3617
|
+
id: string
|
|
3618
|
+
images:
|
|
3619
|
+
| {
|
|
3620
|
+
quality: string
|
|
3621
|
+
url: string
|
|
3622
|
+
}[]
|
|
3623
|
+
| undefined
|
|
3624
|
+
isVatIncluded: boolean
|
|
3625
|
+
labels: string[]
|
|
3626
|
+
length: number
|
|
3627
|
+
listPrice: number
|
|
3628
|
+
moreInformation: string
|
|
3629
|
+
name: string
|
|
3630
|
+
originalPrice: number
|
|
3631
|
+
price: number
|
|
3632
|
+
relatedProducts: string
|
|
3633
|
+
restrictionGroups: string[]
|
|
3634
|
+
salePrice: number
|
|
3635
|
+
slug: string
|
|
3636
|
+
storefrontId: string
|
|
3637
|
+
storefrontSlug: string
|
|
3638
|
+
weight: number
|
|
3639
|
+
width: number
|
|
3640
|
+
}
|
|
3641
|
+
|
|
3642
|
+
type AlgoliaProductHit$1 = Hit<AlgoliaProduct$1>
|
|
3643
|
+
|
|
3644
|
+
declare function transformAlgoliaProductHitToProductHit(algoliaProductHit: AlgoliaProductHit$1): ProductHit$1;
|
|
3645
|
+
interface ProductHit$1 {
|
|
3646
|
+
hit: AlgoliaProductHit$1;
|
|
3610
3647
|
id: string;
|
|
3611
|
-
|
|
3612
|
-
quality: string;
|
|
3613
|
-
url: string;
|
|
3614
|
-
}[] | undefined;
|
|
3648
|
+
image: Image$1;
|
|
3615
3649
|
isVatIncluded: boolean;
|
|
3616
3650
|
labels: string[];
|
|
3617
|
-
length: number;
|
|
3618
|
-
listPrice: number;
|
|
3619
|
-
moreInformation: string;
|
|
3620
3651
|
name: string;
|
|
3652
|
+
objectId: string;
|
|
3621
3653
|
originalPrice: number;
|
|
3654
|
+
position: number;
|
|
3622
3655
|
price: number;
|
|
3623
|
-
|
|
3624
|
-
restrictionGroups: string[];
|
|
3625
|
-
salePrice: number;
|
|
3626
|
-
slug: string;
|
|
3656
|
+
queryId: string | undefined;
|
|
3627
3657
|
storefrontId: string;
|
|
3628
3658
|
storefrontSlug: string;
|
|
3629
|
-
weight: number;
|
|
3630
|
-
width: number;
|
|
3631
3659
|
}
|
|
3632
|
-
type ProductHit$1 = Hit<Product$1>;
|
|
3633
3660
|
|
|
3634
3661
|
interface Link$1 {
|
|
3635
3662
|
href: string;
|
|
@@ -3675,8 +3702,8 @@ interface IconButtonProps {
|
|
|
3675
3702
|
declare function IconButton({ children, className, color, isDisabled, onPress, size, type, }: IconButtonProps): react_jsx_runtime.JSX.Element;
|
|
3676
3703
|
|
|
3677
3704
|
interface UpdateGlobalState<T> {
|
|
3678
|
-
(value: T
|
|
3679
|
-
(fn: (value: T
|
|
3705
|
+
(value: T): void
|
|
3706
|
+
(fn: (value: T) => T): void
|
|
3680
3707
|
}
|
|
3681
3708
|
|
|
3682
3709
|
interface NavigateOptions {
|
|
@@ -3711,6 +3738,12 @@ interface Props {
|
|
|
3711
3738
|
}
|
|
3712
3739
|
declare const ConnectedAddToCartButton: ({ onAddToCart, productId }: Props) => react_jsx_runtime.JSX.Element;
|
|
3713
3740
|
|
|
3741
|
+
interface ProductPrice$1 {
|
|
3742
|
+
isVatIncluded: boolean
|
|
3743
|
+
originalPrice: number
|
|
3744
|
+
price: number
|
|
3745
|
+
}
|
|
3746
|
+
|
|
3714
3747
|
interface AutocompleteProps {
|
|
3715
3748
|
areaSelected?: boolean
|
|
3716
3749
|
id?: string
|
|
@@ -3720,12 +3753,6 @@ interface AutocompleteProps {
|
|
|
3720
3753
|
role?: 'option'
|
|
3721
3754
|
}
|
|
3722
3755
|
|
|
3723
|
-
interface ProductPrice$1 {
|
|
3724
|
-
isVatIncluded: boolean
|
|
3725
|
-
originalPrice: number
|
|
3726
|
-
price: number
|
|
3727
|
-
}
|
|
3728
|
-
|
|
3729
3756
|
interface ProductCardProps extends AutocompleteProps {
|
|
3730
3757
|
addToCartButton: ReactElement;
|
|
3731
3758
|
favoriteButton?: ReactElement;
|
|
@@ -3735,7 +3762,7 @@ interface ProductCardProps extends AutocompleteProps {
|
|
|
3735
3762
|
price: ProductPrice$1;
|
|
3736
3763
|
sku: string;
|
|
3737
3764
|
tags?: string[];
|
|
3738
|
-
title:
|
|
3765
|
+
title: ReactNode;
|
|
3739
3766
|
}
|
|
3740
3767
|
declare function ProductCard({ addToCartButton: AddToCartButton, areaSelected, favoriteButton: FavoriteButton, href, id, image, onClick, onMouseDown, onMouseMove, onPress, price, role, sku, tags, title, }: ProductCardProps): react_jsx_runtime.JSX.Element;
|
|
3741
3768
|
|
|
@@ -3897,7 +3924,7 @@ interface TextFieldProps {
|
|
|
3897
3924
|
*/
|
|
3898
3925
|
declare function TextField({ autoFocus, autoGrow, defaultValue, isDisabled, isInvalid, isMultiline, isReadOnly, isRequired, label, maxLength, onChange, onInput, onKeyUp, placeholder, rows, showLabel, size, value, }: TextFieldProps): react_jsx_runtime.JSX.Element;
|
|
3899
3926
|
|
|
3900
|
-
type TranslationId = 'Chosen filters' | 'Clear' | 'Clear filters' | 'Excl. VAT' | 'Hide filters' | 'Incl. VAT' | 'Show' | 'Show all' | 'Show filters' | 'Show less' | 'Sort by' | 'Submit' | 'articles' | 'article' | 'of' | 'sort.relevance' | 'sort.newest' | 'sort.price_asc' | 'sort.price_desc' | 'tag.new' | 'facet.weight' | 'facet.height';
|
|
3927
|
+
type TranslationId = 'Chosen filters' | 'Clear' | 'Clear filters' | 'Excl. VAT' | 'Explore by categories' | 'Hide filters' | 'Incl. VAT' | 'Popular searches' | 'Products' | 'Recent searches' | 'Show' | 'Show all' | 'Show filters' | 'Show less' | 'Sort by' | 'Sorry, we could not find matches for' | 'Submit' | 'Suggestions' | 'articles' | 'article' | 'of' | 'sort.relevance' | 'sort.newest' | 'sort.price_asc' | 'sort.price_desc' | 'tag.new' | 'facet.categories' | 'facet.weight' | 'facet.height' | 'You could try' | 'Searching again using more general terms' | 'Double check your spelling' | 'Use fewer keywords' | 'Exploring our products by category';
|
|
3901
3928
|
|
|
3902
3929
|
interface FormattedMessageProps {
|
|
3903
3930
|
fallbackValue?: string;
|
|
@@ -3936,7 +3963,7 @@ interface ProgressCircleProps {
|
|
|
3936
3963
|
declare function ProgressCircle({ className }: ProgressCircleProps): react_jsx_runtime.JSX.Element;
|
|
3937
3964
|
|
|
3938
3965
|
type ImageProps = ImageSource;
|
|
3939
|
-
declare function Image({
|
|
3966
|
+
declare function Image({ className, fallbackSrc, fit, height, image, loading, title, width, }: ImageProps): react_jsx_runtime.JSX.Element;
|
|
3940
3967
|
|
|
3941
3968
|
declare function PageContainer({ children, className, }: {
|
|
3942
3969
|
children: ReactNode;
|
|
@@ -3979,18 +4006,21 @@ declare function Sidebar({ children }: SidebarProps): react_jsx_runtime.JSX.Elem
|
|
|
3979
4006
|
interface SidebarProviderProps {
|
|
3980
4007
|
children: ReactElement;
|
|
3981
4008
|
}
|
|
3982
|
-
declare function SidebarDetectBreakpoint():
|
|
4009
|
+
declare function SidebarDetectBreakpoint(): null;
|
|
3983
4010
|
declare function SidebarProvider({ children }: SidebarProviderProps): react_jsx_runtime.JSX.Element;
|
|
3984
4011
|
|
|
3985
4012
|
declare const userTokenEventEmitter: EventEmitter<string | undefined>;
|
|
3986
4013
|
declare let userToken: string | undefined;
|
|
3987
4014
|
|
|
3988
|
-
declare function
|
|
4015
|
+
declare function AlgoliaActiveCategories(): react_jsx_runtime.JSX.Element | null;
|
|
4016
|
+
|
|
4017
|
+
declare function AlgoliaCategoriesFilters(): react_jsx_runtime.JSX.Element | null;
|
|
3989
4018
|
|
|
3990
4019
|
interface AlgoliaFilterPanelProps {
|
|
3991
|
-
|
|
4020
|
+
showActiveCategories?: boolean;
|
|
4021
|
+
showCategoriesFilters?: boolean;
|
|
3992
4022
|
}
|
|
3993
|
-
declare function AlgoliaFilterPanel({
|
|
4023
|
+
declare function AlgoliaFilterPanel({ showActiveCategories, showCategoriesFilters, }: AlgoliaFilterPanelProps): react_jsx_runtime.JSX.Element;
|
|
3994
4024
|
|
|
3995
4025
|
interface RefinementListItem {
|
|
3996
4026
|
count: number;
|
|
@@ -3999,20 +4029,29 @@ interface RefinementListItem {
|
|
|
3999
4029
|
label: string;
|
|
4000
4030
|
value: string;
|
|
4001
4031
|
}
|
|
4002
|
-
interface
|
|
4003
|
-
|
|
4004
|
-
|
|
4005
|
-
|
|
4006
|
-
|
|
4007
|
-
|
|
4032
|
+
interface BaseFilterSectionProps {
|
|
4033
|
+
children: React.ReactNode;
|
|
4034
|
+
title: string;
|
|
4035
|
+
variant: 'default' | 'collapsible' | 'with-action';
|
|
4036
|
+
}
|
|
4037
|
+
interface CollapsibleFilterSectionProps extends BaseFilterSectionProps {
|
|
4008
4038
|
initialIsOpen?: boolean;
|
|
4039
|
+
variant: 'collapsible';
|
|
4040
|
+
}
|
|
4041
|
+
interface WithActionFilterSectionProps extends BaseFilterSectionProps {
|
|
4042
|
+
button: React.ReactNode;
|
|
4043
|
+
variant: 'with-action';
|
|
4044
|
+
}
|
|
4045
|
+
interface DefaultFilterSectionProps extends BaseFilterSectionProps {
|
|
4046
|
+
variant: 'default';
|
|
4009
4047
|
}
|
|
4010
|
-
|
|
4048
|
+
type FilterSectionProps = CollapsibleFilterSectionProps | WithActionFilterSectionProps | DefaultFilterSectionProps;
|
|
4049
|
+
declare function FilterSection({ ...props }: FilterSectionProps): react_jsx_runtime.JSX.Element;
|
|
4011
4050
|
|
|
4012
4051
|
interface AlgoliaMultiSelectFilterSectionProps {
|
|
4013
4052
|
attribute: string;
|
|
4014
4053
|
}
|
|
4015
|
-
declare function AlgoliaMultiSelectFilterSection({ attribute, }: AlgoliaMultiSelectFilterSectionProps): react_jsx_runtime.JSX.Element;
|
|
4054
|
+
declare function AlgoliaMultiSelectFilterSection({ attribute, }: AlgoliaMultiSelectFilterSectionProps): react_jsx_runtime.JSX.Element | null;
|
|
4016
4055
|
|
|
4017
4056
|
interface AlgoliaPaginationProps {
|
|
4018
4057
|
onChange: (pageNumber: number) => void;
|
|
@@ -4089,48 +4128,6 @@ declare function GlobalSearchContainer({ children, }: {
|
|
|
4089
4128
|
children: React.ReactNode;
|
|
4090
4129
|
}): react_jsx_runtime.JSX.Element;
|
|
4091
4130
|
|
|
4092
|
-
interface Product {
|
|
4093
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
4094
|
-
[key: string]: any
|
|
4095
|
-
alternativeNumber: string
|
|
4096
|
-
categories: string[]
|
|
4097
|
-
categoryPageId: string[]
|
|
4098
|
-
consumerPrice: number
|
|
4099
|
-
discountedPrice: number
|
|
4100
|
-
drawerQuantity: string
|
|
4101
|
-
ean: string
|
|
4102
|
-
height: number
|
|
4103
|
-
hierarchicalCategories: {
|
|
4104
|
-
lvl0: string
|
|
4105
|
-
lvl1: string
|
|
4106
|
-
}
|
|
4107
|
-
id: string
|
|
4108
|
-
images:
|
|
4109
|
-
| {
|
|
4110
|
-
quality: string
|
|
4111
|
-
url: string
|
|
4112
|
-
}[]
|
|
4113
|
-
| undefined
|
|
4114
|
-
isVatIncluded: boolean
|
|
4115
|
-
labels: string[]
|
|
4116
|
-
length: number
|
|
4117
|
-
listPrice: number
|
|
4118
|
-
moreInformation: string
|
|
4119
|
-
name: string
|
|
4120
|
-
originalPrice: number
|
|
4121
|
-
price: number
|
|
4122
|
-
relatedProducts: string
|
|
4123
|
-
restrictionGroups: string[]
|
|
4124
|
-
salePrice: number
|
|
4125
|
-
slug: string
|
|
4126
|
-
storefrontId: string
|
|
4127
|
-
storefrontSlug: string
|
|
4128
|
-
weight: number
|
|
4129
|
-
width: number
|
|
4130
|
-
}
|
|
4131
|
-
|
|
4132
|
-
type ProductHit = Hit<Product>
|
|
4133
|
-
|
|
4134
4131
|
type CategoryHit$1 = Hit<{
|
|
4135
4132
|
listCategories: string[];
|
|
4136
4133
|
}>;
|
|
@@ -4164,10 +4161,26 @@ type RecentSearchHit$1 = Hit<{
|
|
|
4164
4161
|
label: string;
|
|
4165
4162
|
}>;
|
|
4166
4163
|
|
|
4167
|
-
type AutocompleteItem =
|
|
4164
|
+
type AutocompleteItem = AlgoliaProductHit$1 | QuerySuggestionHit$1 | PopularCategoryHit$1 | QuickAccessHit$1 | RecentSearchHit$1 | CategoryHit$1 | PopularSearchHit$1;
|
|
4168
4165
|
type Autocomplete = AutocompleteApi<AutocompleteItem, React.BaseSyntheticEvent, React.MouseEvent, React.KeyboardEvent>;
|
|
4169
4166
|
type AutocompleteState = AutocompleteState$1<AutocompleteItem>;
|
|
4170
4167
|
|
|
4168
|
+
interface ProductHit {
|
|
4169
|
+
hit: AlgoliaProductHit$1
|
|
4170
|
+
id: string
|
|
4171
|
+
image: Image$1
|
|
4172
|
+
isVatIncluded: boolean
|
|
4173
|
+
labels: string[]
|
|
4174
|
+
name: string
|
|
4175
|
+
objectId: string
|
|
4176
|
+
originalPrice: number
|
|
4177
|
+
position: number
|
|
4178
|
+
price: number
|
|
4179
|
+
queryId: string | undefined
|
|
4180
|
+
storefrontId: string
|
|
4181
|
+
storefrontSlug: string
|
|
4182
|
+
}
|
|
4183
|
+
|
|
4171
4184
|
type CategoryHit = Hit<{
|
|
4172
4185
|
listCategories: string[]
|
|
4173
4186
|
}>
|
|
@@ -4201,15 +4214,62 @@ type RecentSearchHit = Hit<{
|
|
|
4201
4214
|
label: string
|
|
4202
4215
|
}>
|
|
4203
4216
|
|
|
4217
|
+
interface AlgoliaProduct {
|
|
4218
|
+
[key: string]: any;
|
|
4219
|
+
alternativeNumber: string;
|
|
4220
|
+
categories: string[];
|
|
4221
|
+
categoryPageId: string[];
|
|
4222
|
+
consumerPrice: number;
|
|
4223
|
+
discountedPrice: number;
|
|
4224
|
+
drawerQuantity: string;
|
|
4225
|
+
ean: string;
|
|
4226
|
+
height: number;
|
|
4227
|
+
hierarchicalCategories: {
|
|
4228
|
+
lvl0: string;
|
|
4229
|
+
lvl1: string;
|
|
4230
|
+
};
|
|
4231
|
+
id: string;
|
|
4232
|
+
images: {
|
|
4233
|
+
quality: string;
|
|
4234
|
+
url: string;
|
|
4235
|
+
}[] | undefined;
|
|
4236
|
+
isVatIncluded: boolean;
|
|
4237
|
+
labels: string[];
|
|
4238
|
+
length: number;
|
|
4239
|
+
listPrice: number;
|
|
4240
|
+
moreInformation: string;
|
|
4241
|
+
name: string;
|
|
4242
|
+
originalPrice: number;
|
|
4243
|
+
price: number;
|
|
4244
|
+
relatedProducts: string;
|
|
4245
|
+
restrictionGroups: string[];
|
|
4246
|
+
salePrice: number;
|
|
4247
|
+
slug: string;
|
|
4248
|
+
storefrontId: string;
|
|
4249
|
+
storefrontSlug: string;
|
|
4250
|
+
weight: number;
|
|
4251
|
+
width: number;
|
|
4252
|
+
}
|
|
4253
|
+
type AlgoliaProductHit = Hit<AlgoliaProduct>;
|
|
4254
|
+
|
|
4255
|
+
interface ExtendedAutoCompleteCollection<T extends BaseItem> extends AutocompleteCollection<T> {
|
|
4256
|
+
source: ExtendedInternalAutocompleteSource<T>;
|
|
4257
|
+
}
|
|
4258
|
+
interface ExtendedInternalAutocompleteSource<T extends BaseItem> extends InternalAutocompleteSource<T> {
|
|
4259
|
+
onRemove: (id: string) => void;
|
|
4260
|
+
}
|
|
4204
4261
|
declare function useAlgoliaSearch(): {
|
|
4205
4262
|
categories: AutocompleteCollection<CategoryHit> | undefined;
|
|
4206
4263
|
hasResults: boolean;
|
|
4207
4264
|
popularCategories: AutocompleteCollection<PopularCategoryHit> | undefined;
|
|
4208
4265
|
popularSearches: AutocompleteCollection<PopularSearchHit> | undefined;
|
|
4209
|
-
products:
|
|
4266
|
+
products: {
|
|
4267
|
+
items: ProductHit[];
|
|
4268
|
+
source: InternalAutocompleteSource<AlgoliaProductHit>;
|
|
4269
|
+
} | undefined;
|
|
4210
4270
|
querySuggestions: AutocompleteCollection<QuerySuggestionHit> | undefined;
|
|
4211
4271
|
quickAccess: AutocompleteCollection<QuickAccessHit> | undefined;
|
|
4212
|
-
recentSearches:
|
|
4272
|
+
recentSearches: ExtendedAutoCompleteCollection<RecentSearchHit> | undefined;
|
|
4213
4273
|
autocomplete: Autocomplete;
|
|
4214
4274
|
formRef: React.RefObject<HTMLFormElement>;
|
|
4215
4275
|
inputRef: React.RefObject<HTMLInputElement>;
|
|
@@ -4228,4 +4288,4 @@ declare const useGlobalSearchDisclosure: () => {
|
|
|
4228
4288
|
toggle: VoidFunction;
|
|
4229
4289
|
};
|
|
4230
4290
|
|
|
4231
|
-
export { Accordion, type AccountCollectionModel, type AccountModel, type AccountPaymentProfileCollectionModel, type AccountPaymentProfileModel, type AccountSettingsModel, type AccountShipToCollectionModel, type AccountShipToModel, type AccountsReceivableDto, AddProductToCurrentCartError, type AddProductToCurrentCartParams, AddToCartButton, type AddressFieldCollectionModel, type AddressFieldDisplayCollectionModel, type AddressFieldDisplayModel, type AgingBucketDto,
|
|
4291
|
+
export { Accordion, type AccountCollectionModel, type AccountModel, type AccountPaymentProfileCollectionModel, type AccountPaymentProfileModel, type AccountSettingsModel, type AccountShipToCollectionModel, type AccountShipToModel, type AccountsReceivableDto, AddProductToCurrentCartError, type AddProductToCurrentCartParams, AddToCartButton, type AddressFieldCollectionModel, type AddressFieldDisplayCollectionModel, type AddressFieldDisplayModel, type AgingBucketDto, AlgoliaActiveCategories, AlgoliaCategoriesFilters, AlgoliaFilterPanel, type AlgoliaFilterPanelProps, AlgoliaInsightInstantSearchProvider, AlgoliaInsightsProvider, AlgoliaInsightsProviderContext, type AlgoliaInsightsProviderState, AlgoliaMultiSelectFilterSection, AlgoliaPagination, AlgoliaProvider, AlgoliaResultsCount, AlgoliaSortBy, type AttributeTypeDto, type AttributeTypeFacetModel, type AttributeTypeModel, type AttributeValueDto, type AttributeValueFacetModel, type AttributeValueModel, type AutocompleteItemModel, type AutocompleteModel, type AutocompleteProductCollectionModel, type AutocompleteProductModel, type AutocompleteProps$1 as AutocompleteProps, type AvailabilityDto$2 as AvailabilityDto, AvailabilityMessageType$2 as AvailabilityMessageType, BadgeImagePlacementValues, type BadgeModel, BadgeStyleValues, BadgeTypeValues, type BaseAddressModel, type BaseModel$1 as BaseModel, type BillToCollectionModel, type BillToModel, type BrandAlphabetLetterModel, type BrandAlphabetModel, type BrandAutocompleteModel, type BrandCategoryCollectionModel, type BrandCategoryModel, type BrandCollectionModel, type BrandDto$2 as BrandDto, type BrandModel, type BrandProductLineCollectionModel, type BrandProductLineModel, type BreadCrumb, type BreadCrumbModel, Breadcrumb, type BreadcrumbProps, type BreakPriceDto$2 as BreakPriceDto, type BreakPriceRfqModel, type BudgetCalendarCollectionModel, type BudgetCalendarModel, type BudgetCollectionModel, type BudgetLineModel, type BudgetModel, Button, type ButtonProps, type CalculationMethod, type CarrierDto, type CartCollectionModel, type CartLineCollectionModel, type CartLineModel$2 as CartLineModel, type CartModel, CartProvider, type CartSettingsModel, type CatalogPageModel, type Category$1 as Category, CategoryCarousel, type CategoryCarouselProps, type CategoryCollectionModel, type CategoryFacetModel, type CategoryModel, Checkbox, type CheckboxProps$1 as CheckboxProps, type ChildTraitValueModel, ColorCheckbox, type ColorCheckboxProps, type ConfigSectionDto, type ConfigSectionModel, type ConfigSectionOptionDto, type ConfigurationModel, ConnectedAddToCartButton, type ContactUsModel, type ContentModel, type CostCodeDto, type CostCodeModel, type CountryCollectionModel, type CountryModel, type CreditCardBillingAddressDto, type CreditCardDto, type CrossSellCollectionModel, type CurrencyCollectionModel, type CurrencyModel, CurrencyPositioningType, type CustomerCostCodeDto, type CustomerOrderTaxDto, type CustomerSettingsModel, type CustomerValidationDto, type DashboardPanelCollectionModel, type DashboardPanelModel, type DealerCollectionModel, type DealerModel, DeleteCartLineByIdError, type DetailModel, type DocumentDto, type DocumentModel, type ECheckDto, type FacetModel, FavoriteButton, type FavoriteButtonProps, FavoriteProvider, FetchCurrentCartLinesError, type FetchProductListingPageDataArgs, FetchProductListingPageDataError, type FieldScoreDetailedDto, type FieldScoreDetailedModel, type FieldScoreDto, type FieldScoreModel, type FieldValidationDto, type FilterOption, FilterSection, type Filters, FormattedMessage, type FormattedMessageFunction, type FormattedMessageProps, GlobalSearch, GlobalSearchContainer, GlobalSearchDisclosureContext, GlobalStateProvider, GlobalStateProviderContext, IconButton, type IconButtonProps, Image, type ImageModel, IntlProvider, type InventoryAvailabilityDto, type InventoryWarehousesDto, type InvoiceCollectionModel, type InvoiceHistoryTaxDto, type InvoiceLineModel, type InvoiceModel, type InvoiceSettingsModel, type JobQuoteCollectionModel, type JobQuoteLineModel, type JobQuoteModel, type LanguageCollectionModel, type LanguageModel, type LegacyConfigurationDto, type Link$1 as Link, LinkButton, type LinkButtonProps, LoadingOverlay, type MessageCollectionModel, type MessageModel, type MobileAppSettingsModel, type MobileContentModel, type MobilePageDto, type MobileWidgetDto, MultiSelect, type MultiSelectProps, type NavigateFn, type NavigateOptions$1 as NavigateOptions, NumberField, type NumberFieldSize, type OrderApprovalCollectionModel, type OrderCollectionModel, type OrderHistoryTaxDto, type OrderLineModel, type OrderModel, type OrderPromotionModel, type OrderRequestModel, type OrderSettingsModel, type OrderStatusMappingCollectionModel, type OrderStatusMappingModel, Page, PageContainer, type PageProps, type PaginationModel, type PaymentMethodDto, type PaymentOptionsDto, type PersonaModel, type PoRequisitionModel, type PriceFacetModel, type PriceRangeModel, type PricingRfqModel, type ProductAutocompleteItemModel, type ProductAvailabilityModel, ProductCard, type ProductCardProps, type ProductCollectionModel, type ProductDto, type ProductHit$1 as ProductHit, type ProductImageDto, type ProductInventoryDto, type ProductLineDto, type ProductLineModel, ProductListingPage, type ProductListingPageDataResponse, type ProductListingPageProps, type ProductModel, ProductOverviewGrid, type ProductOverviewGridProps, ProductPrice, type ProductPriceDto$2 as ProductPriceDto, type ProductPriceModel, type ProductPriceProps, type ProductSettingsModel, ProductSku, type ProductSkuProps, type ProductSubscriptionDto$2 as ProductSubscriptionDto, type ProductSubscriptionModel, type ProductUnitOfMeasureDto, type ProfileTransactionRequestModel, ProgressCircle, type ProgressCircleProps, type PromoCard$1 as PromoCard, type PromoCards, type PromotionCollectionModel, type PromotionModel, type QuoteCollectionModel, type QuoteLineModel, type QuoteModel, type QuoteSettingsModel, type RealTimeCartInventoryModel, type RealTimeInventoryModel, type RealTimePricingModel, type RefinementListItem, type RelatedProductDto, type RequisitionCollectionModel, type RequisitionLineCollectionModel, type RequisitionLineModel, type RequisitionModel, type RmaLineDto, type RmaModel, RouteButton, RouteLink, RouteProvider, type RouteProviderProps, type SalespersonModel, type ScoreExplanationDto, type ScoreExplanationModel, type SectionOptionDto$2 as SectionOptionDto, type SectionOptionModel, Select, type SelectProps, type SessionModel, type SessionRequestModel, type SettingsCollectionModel, type SetupRequestModel, type ShareEntityModel, type ShareOrderModel, type ShipToCollectionModel, type ShipToModel, type ShipViaDto, type ShipmentPackageDto, type ShipmentPackageLineDto, ShowAll, type ShowAllProps, Sidebar, SidebarDetectBreakpoint, type SidebarProps, SidebarProvider, type SiteMessageCollectionModel, type SiteMessageModel, type SortOptionModel, type SpecificationDto, type SpecificationModel, type StateCollectionModel, type StateModel, type StyleTraitDto, type StyleValueDto, type StyledProductDto, type SuggestionModel, type TellAFriendModel, TextField, type TraitValueModel, type TranslationDictionaryCollectionModel, type TranslationDictionaryModel, type TranslationId, type UnitOfMeasureModel, UpdateCartLineByIdError, type UpdateCartLineParams, type UpdateGlobalState$1 as UpdateGlobalState, type UpdateWishListLineCollectionModel, VariantDisplayTypeValues, type VariantTraitModel, type VmiBinCollectionModel, type VmiBinCountModel, type VmiBinModel, type VmiCountCollectionModel, type VmiCountModel, type VmiLocationCollectionModel, type VmiLocationModel, type VmiNoteCollectionModel, type VmiNoteModel, type VmiUserImportCollectionModel, type VmiUserImportModel, type VmiUserModel, type WarehouseCollectionModel, type WarehouseDto, type WarehouseModel, type WebsiteModel, type WebsiteSettingsModel, type WishListCollectionModel, type WishListEmailScheduleModel, type WishListLineCollectionModel, type WishListLineModel, type WishListModel, type WishListSettingsModel, type WishListShareModel, config, configPerEnvironment, createSonicSearchClient, transformAlgoliaProductHitToProductHit, useAddProductToCurrentCart, useAlgolia, useAlgoliaSearch, useBreakpoint, useCartEvents, useDebouncedCallback, useDeleteCartLineById, useDisclosure, useFavorite, useFetchCurrentCartLines, useFetchProductListingPageData, useFormattedMessage, useGlobalSearchDisclosure, useGlobalState, useNavigate, useScrollLock, useUpdateCartLineById, userToken, userTokenEventEmitter };
|