instantsearch.js 4.67.0 → 4.68.0
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/cjs/components/Template/Template.js +11 -2
- package/cjs/connectors/hits/connectHits.js +4 -0
- package/cjs/lib/version.js +1 -1
- package/cjs/widgets/hits/hits.js +14 -3
- package/cjs/widgets/index/index.js +12 -3
- package/dist/instantsearch.development.d.ts +13 -0
- package/dist/instantsearch.development.js +86 -19
- package/dist/instantsearch.development.js.map +1 -1
- package/dist/instantsearch.production.d.ts +13 -0
- package/dist/instantsearch.production.min.d.ts +13 -0
- package/dist/instantsearch.production.min.js +2 -2
- package/dist/instantsearch.production.min.js.map +1 -1
- package/es/components/Template/Template.js +11 -2
- package/es/connectors/hits/connectHits.d.ts +5 -0
- package/es/connectors/hits/connectHits.js +4 -0
- package/es/lib/version.d.ts +1 -1
- package/es/lib/version.js +1 -1
- package/es/widgets/hits/defaultTemplates.d.ts +1 -1
- package/es/widgets/hits/hits.d.ts +8 -1
- package/es/widgets/hits/hits.js +14 -3
- package/es/widgets/index/index.js +12 -3
- package/package.json +7 -7
|
@@ -303,6 +303,8 @@ declare type AutocompleteWidgetDescription = {
|
|
|
303
303
|
};
|
|
304
304
|
};
|
|
305
305
|
|
|
306
|
+
declare type Banner = NonNullable<NonNullable<Required<SearchResults<Hit>['renderingContent']>>['widgets']['banners']>[number];
|
|
307
|
+
|
|
306
308
|
declare type BaseHit = Record<string, unknown>;
|
|
307
309
|
|
|
308
310
|
declare type BindEventForHits = BuiltInBindEventForHits & CustomBindEventForHits;
|
|
@@ -1994,6 +1996,10 @@ declare type HitsRenderState<THit extends BaseHit = BaseHit> = {
|
|
|
1994
1996
|
* The response from the Algolia API.
|
|
1995
1997
|
*/
|
|
1996
1998
|
results?: SearchResults<Hit<THit>>;
|
|
1999
|
+
/**
|
|
2000
|
+
* The banner to display above the hits.
|
|
2001
|
+
*/
|
|
2002
|
+
banner?: Banner;
|
|
1997
2003
|
/**
|
|
1998
2004
|
* Sends an event to the Insights middleware.
|
|
1999
2005
|
*/
|
|
@@ -2020,6 +2026,13 @@ declare type HitsTemplates = Partial<{
|
|
|
2020
2026
|
/** @deprecated the index in the hits array, use __position instead, which is the absolute position */
|
|
2021
2027
|
__hitIndex: number;
|
|
2022
2028
|
}>;
|
|
2029
|
+
/**
|
|
2030
|
+
* Template to use for the banner.
|
|
2031
|
+
*/
|
|
2032
|
+
banner: Template<{
|
|
2033
|
+
banner: Required<HitsRenderState['banner']>;
|
|
2034
|
+
className: string;
|
|
2035
|
+
}>;
|
|
2023
2036
|
}>;
|
|
2024
2037
|
|
|
2025
2038
|
declare type HitsWidget = WidgetFactory<HitsWidgetDescription & {
|
|
@@ -303,6 +303,8 @@ declare type AutocompleteWidgetDescription = {
|
|
|
303
303
|
};
|
|
304
304
|
};
|
|
305
305
|
|
|
306
|
+
declare type Banner = NonNullable<NonNullable<Required<SearchResults<Hit>['renderingContent']>>['widgets']['banners']>[number];
|
|
307
|
+
|
|
306
308
|
declare type BaseHit = Record<string, unknown>;
|
|
307
309
|
|
|
308
310
|
declare type BindEventForHits = BuiltInBindEventForHits & CustomBindEventForHits;
|
|
@@ -1994,6 +1996,10 @@ declare type HitsRenderState<THit extends BaseHit = BaseHit> = {
|
|
|
1994
1996
|
* The response from the Algolia API.
|
|
1995
1997
|
*/
|
|
1996
1998
|
results?: SearchResults<Hit<THit>>;
|
|
1999
|
+
/**
|
|
2000
|
+
* The banner to display above the hits.
|
|
2001
|
+
*/
|
|
2002
|
+
banner?: Banner;
|
|
1997
2003
|
/**
|
|
1998
2004
|
* Sends an event to the Insights middleware.
|
|
1999
2005
|
*/
|
|
@@ -2020,6 +2026,13 @@ declare type HitsTemplates = Partial<{
|
|
|
2020
2026
|
/** @deprecated the index in the hits array, use __position instead, which is the absolute position */
|
|
2021
2027
|
__hitIndex: number;
|
|
2022
2028
|
}>;
|
|
2029
|
+
/**
|
|
2030
|
+
* Template to use for the banner.
|
|
2031
|
+
*/
|
|
2032
|
+
banner: Template<{
|
|
2033
|
+
banner: Required<HitsRenderState['banner']>;
|
|
2034
|
+
className: string;
|
|
2035
|
+
}>;
|
|
2023
2036
|
}>;
|
|
2024
2037
|
|
|
2025
2038
|
declare type HitsWidget = WidgetFactory<HitsWidgetDescription & {
|