instantsearch.js 4.50.0 → 4.50.1

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 (153) hide show
  1. package/cjs/lib/templating/prepareTemplateProps.js +1 -2
  2. package/cjs/lib/version.js +1 -1
  3. package/cjs/widgets/hits/hits.js +3 -4
  4. package/cjs/widgets/infinite-hits/infinite-hits.js +3 -4
  5. package/dist/instantsearch.development.d.ts +1 -1
  6. package/dist/instantsearch.development.js +25 -18
  7. package/dist/instantsearch.development.js.map +1 -1
  8. package/dist/instantsearch.production.d.ts +1 -1
  9. package/dist/instantsearch.production.min.d.ts +1 -1
  10. package/dist/instantsearch.production.min.js +2 -2
  11. package/dist/instantsearch.production.min.js.map +1 -1
  12. package/es/components/Answers/Answers.d.ts +3 -3
  13. package/es/components/Breadcrumb/Breadcrumb.d.ts +3 -3
  14. package/es/components/ClearRefinements/ClearRefinements.d.ts +3 -3
  15. package/es/components/CurrentRefinements/CurrentRefinements.d.ts +2 -2
  16. package/es/components/GeoSearchControls/GeoSearchButton.d.ts +1 -1
  17. package/es/components/GeoSearchControls/GeoSearchControls.d.ts +1 -1
  18. package/es/components/GeoSearchControls/GeoSearchToggle.d.ts +1 -1
  19. package/es/components/Highlight/Highlight.d.ts +2 -2
  20. package/es/components/Hits/Hits.d.ts +3 -3
  21. package/es/components/InfiniteHits/InfiniteHits.d.ts +3 -3
  22. package/es/components/MenuSelect/MenuSelect.d.ts +4 -4
  23. package/es/components/Pagination/Pagination.d.ts +3 -3
  24. package/es/components/Panel/Panel.d.ts +3 -3
  25. package/es/components/PoweredBy/PoweredBy.d.ts +2 -2
  26. package/es/components/QueryRuleCustomData/QueryRuleCustomData.d.ts +3 -3
  27. package/es/components/RangeInput/RangeInput.d.ts +3 -3
  28. package/es/components/RefinementList/RefinementList.d.ts +7 -7
  29. package/es/components/RefinementList/RefinementListItem.d.ts +1 -1
  30. package/es/components/RelevantSort/RelevantSort.d.ts +3 -3
  31. package/es/components/ReverseHighlight/ReverseHighlight.d.ts +2 -2
  32. package/es/components/ReverseSnippet/ReverseSnippet.d.ts +2 -2
  33. package/es/components/SearchBox/SearchBox.d.ts +5 -5
  34. package/es/components/Selector/Selector.d.ts +3 -3
  35. package/es/components/Slider/Rheostat.d.ts +6 -6
  36. package/es/components/Slider/Slider.d.ts +2 -2
  37. package/es/components/Snippet/Snippet.d.ts +2 -2
  38. package/es/components/Stats/Stats.d.ts +3 -3
  39. package/es/components/Template/Template.d.ts +1 -1
  40. package/es/components/ToggleRefinement/ToggleRefinement.d.ts +3 -3
  41. package/es/components/VoiceSearch/VoiceSearch.d.ts +3 -3
  42. package/es/connectors/answers/connectAnswers.d.ts +4 -4
  43. package/es/connectors/autocomplete/connectAutocomplete.d.ts +4 -4
  44. package/es/connectors/breadcrumb/connectBreadcrumb.d.ts +5 -5
  45. package/es/connectors/clear-refinements/connectClearRefinements.d.ts +4 -4
  46. package/es/connectors/configure/connectConfigure.d.ts +5 -5
  47. package/es/connectors/configure-related-items/connectConfigureRelatedItems.d.ts +5 -5
  48. package/es/connectors/current-refinements/connectCurrentRefinements.d.ts +6 -6
  49. package/es/connectors/dynamic-widgets/connectDynamicWidgets.d.ts +4 -4
  50. package/es/connectors/geo-search/connectGeoSearch.d.ts +6 -6
  51. package/es/connectors/hierarchical-menu/connectHierarchicalMenu.d.ts +5 -5
  52. package/es/connectors/hits/connectHits.d.ts +4 -4
  53. package/es/connectors/hits-per-page/connectHitsPerPage.d.ts +6 -6
  54. package/es/connectors/infinite-hits/connectInfiniteHits.d.ts +8 -8
  55. package/es/connectors/menu/connectMenu.d.ts +5 -5
  56. package/es/connectors/numeric-menu/connectNumericMenu.d.ts +6 -6
  57. package/es/connectors/pagination/connectPagination.d.ts +4 -4
  58. package/es/connectors/powered-by/connectPoweredBy.d.ts +4 -4
  59. package/es/connectors/query-rules/connectQueryRules.d.ts +7 -7
  60. package/es/connectors/range/connectRange.d.ts +8 -8
  61. package/es/connectors/rating-menu/connectRatingMenu.d.ts +6 -6
  62. package/es/connectors/refinement-list/connectRefinementList.d.ts +5 -5
  63. package/es/connectors/relevant-sort/connectRelevantSort.d.ts +5 -5
  64. package/es/connectors/search-box/connectSearchBox.d.ts +4 -4
  65. package/es/connectors/sort-by/connectSortBy.d.ts +5 -5
  66. package/es/connectors/stats/connectStats.d.ts +4 -4
  67. package/es/connectors/toggle-refinement/connectToggleRefinement.d.ts +9 -9
  68. package/es/connectors/toggle-refinement/types.d.ts +5 -5
  69. package/es/connectors/voice-search/connectVoiceSearch.d.ts +4 -4
  70. package/es/helpers/components/Highlight.d.ts +1 -1
  71. package/es/helpers/components/ReverseHighlight.d.ts +1 -1
  72. package/es/helpers/components/ReverseSnippet.d.ts +1 -1
  73. package/es/helpers/components/Snippet.d.ts +1 -1
  74. package/es/helpers/highlight.d.ts +1 -1
  75. package/es/helpers/reverseHighlight.d.ts +1 -1
  76. package/es/helpers/reverseSnippet.d.ts +1 -1
  77. package/es/helpers/snippet.d.ts +1 -1
  78. package/es/index.d.ts +1 -1
  79. package/es/lib/InstantSearch.d.ts +3 -3
  80. package/es/lib/createHelpers.d.ts +1 -1
  81. package/es/lib/insights/listener.d.ts +1 -1
  82. package/es/lib/routers/history.d.ts +3 -3
  83. package/es/lib/suit.d.ts +2 -2
  84. package/es/lib/templating/prepareTemplateProps.d.ts +2 -2
  85. package/es/lib/templating/prepareTemplateProps.js +1 -2
  86. package/es/lib/utils/checkIndexUiState.d.ts +1 -1
  87. package/es/lib/utils/createConcurrentSafePromise.d.ts +2 -2
  88. package/es/lib/utils/createSendEventForFacet.d.ts +4 -4
  89. package/es/lib/utils/createSendEventForHits.d.ts +6 -6
  90. package/es/lib/utils/debounce.d.ts +2 -2
  91. package/es/lib/utils/defer.d.ts +2 -2
  92. package/es/lib/utils/documentation.d.ts +2 -2
  93. package/es/lib/utils/escapeFacetValue.d.ts +1 -1
  94. package/es/lib/utils/geo-search.d.ts +1 -1
  95. package/es/lib/utils/getRefinements.d.ts +6 -6
  96. package/es/lib/utils/logger.d.ts +2 -2
  97. package/es/lib/utils/range.d.ts +1 -1
  98. package/es/lib/utils/safelyRunOnBrowser.d.ts +2 -2
  99. package/es/lib/utils/toArray.d.ts +1 -1
  100. package/es/lib/version.d.ts +1 -1
  101. package/es/lib/version.js +1 -1
  102. package/es/lib/voiceSearchHelper/types.d.ts +5 -5
  103. package/es/middlewares/createInsightsMiddleware.d.ts +3 -3
  104. package/es/middlewares/createRouterMiddleware.d.ts +1 -1
  105. package/es/types/component.d.ts +1 -1
  106. package/es/types/connector.d.ts +4 -4
  107. package/es/types/insights.d.ts +5 -5
  108. package/es/types/middleware.d.ts +4 -4
  109. package/es/types/render-state.d.ts +5 -5
  110. package/es/types/results.d.ts +16 -16
  111. package/es/types/router.d.ts +2 -2
  112. package/es/types/templates.d.ts +5 -5
  113. package/es/types/ui-state.d.ts +4 -4
  114. package/es/types/utils.d.ts +6 -6
  115. package/es/types/widget-factory.d.ts +2 -2
  116. package/es/types/widget.d.ts +23 -23
  117. package/es/widgets/analytics/analytics.d.ts +4 -4
  118. package/es/widgets/answers/answers.d.ts +4 -4
  119. package/es/widgets/breadcrumb/breadcrumb.d.ts +4 -4
  120. package/es/widgets/clear-refinements/clear-refinements.d.ts +4 -4
  121. package/es/widgets/configure/configure.d.ts +2 -2
  122. package/es/widgets/configure-related-items/configure-related-items.d.ts +2 -2
  123. package/es/widgets/current-refinements/current-refinements.d.ts +3 -3
  124. package/es/widgets/dynamic-widgets/dynamic-widgets.d.ts +2 -2
  125. package/es/widgets/geo-search/createHTMLMarker.d.ts +1 -1
  126. package/es/widgets/geo-search/geo-search.d.ts +7 -7
  127. package/es/widgets/hierarchical-menu/hierarchical-menu.d.ts +6 -6
  128. package/es/widgets/hits/hits.d.ts +4 -4
  129. package/es/widgets/hits/hits.js +3 -4
  130. package/es/widgets/hits-per-page/hits-per-page.d.ts +3 -3
  131. package/es/widgets/index/index.d.ts +5 -5
  132. package/es/widgets/infinite-hits/infinite-hits.d.ts +4 -4
  133. package/es/widgets/infinite-hits/infinite-hits.js +3 -4
  134. package/es/widgets/menu/menu.d.ts +6 -6
  135. package/es/widgets/menu-select/menu-select.d.ts +4 -4
  136. package/es/widgets/numeric-menu/numeric-menu.d.ts +6 -6
  137. package/es/widgets/pagination/pagination.d.ts +4 -4
  138. package/es/widgets/panel/panel.d.ts +9 -9
  139. package/es/widgets/places/places.d.ts +6 -6
  140. package/es/widgets/powered-by/powered-by.d.ts +3 -3
  141. package/es/widgets/query-rule-context/query-rule-context.d.ts +2 -2
  142. package/es/widgets/query-rule-custom-data/query-rule-custom-data.d.ts +4 -4
  143. package/es/widgets/range-input/range-input.d.ts +4 -4
  144. package/es/widgets/range-slider/range-slider.d.ts +4 -4
  145. package/es/widgets/rating-menu/rating-menu.d.ts +6 -6
  146. package/es/widgets/refinement-list/refinement-list.d.ts +10 -10
  147. package/es/widgets/relevant-sort/relevant-sort.d.ts +4 -4
  148. package/es/widgets/search-box/search-box.d.ts +4 -4
  149. package/es/widgets/sort-by/sort-by.d.ts +4 -4
  150. package/es/widgets/stats/stats.d.ts +5 -5
  151. package/es/widgets/toggle-refinement/toggle-refinement.d.ts +4 -4
  152. package/es/widgets/voice-search/voice-search.d.ts +5 -5
  153. package/package.json +6 -5
@@ -2,20 +2,20 @@
2
2
  import type { WidgetFactory, Template } from '../../types';
3
3
  import type { QueryRulesConnectorParams, QueryRulesWidgetDescription } from '../../connectors/query-rules/connectQueryRules';
4
4
  import type { QueryRuleCustomDataComponentTemplates } from '../../components/QueryRuleCustomData/QueryRuleCustomData';
5
- export declare type QueryRuleCustomDataCSSClasses = Partial<{
5
+ export type QueryRuleCustomDataCSSClasses = Partial<{
6
6
  root: string | string[];
7
7
  }>;
8
- export declare type QueryRuleCustomDataTemplates = Partial<{
8
+ export type QueryRuleCustomDataTemplates = Partial<{
9
9
  default: Template<{
10
10
  items: any[];
11
11
  }>;
12
12
  }>;
13
- export declare type QueryRuleCustomDataWidgetParams = {
13
+ export type QueryRuleCustomDataWidgetParams = {
14
14
  container: string | HTMLElement;
15
15
  cssClasses?: QueryRuleCustomDataCSSClasses;
16
16
  templates?: QueryRuleCustomDataTemplates;
17
17
  };
18
- export declare type QueryRuleCustomDataWidget = WidgetFactory<QueryRulesWidgetDescription & {
18
+ export type QueryRuleCustomDataWidget = WidgetFactory<QueryRulesWidgetDescription & {
19
19
  $$widgetType: 'ais.queryRuleCustomData';
20
20
  }, QueryRulesConnectorParams, QueryRuleCustomDataWidgetParams>;
21
21
  export declare const defaultTemplates: QueryRuleCustomDataComponentTemplates;
@@ -1,7 +1,7 @@
1
1
 
2
2
  import type { RangeConnectorParams, RangeWidgetDescription } from '../../connectors/range/connectRange';
3
3
  import type { Template, WidgetFactory } from '../../types';
4
- export declare type RangeInputTemplates = Partial<{
4
+ export type RangeInputTemplates = Partial<{
5
5
  /**
6
6
  * The label of the separator, between min and max.
7
7
  * @default "to"
@@ -13,7 +13,7 @@ export declare type RangeInputTemplates = Partial<{
13
13
  */
14
14
  submitText: Template;
15
15
  }>;
16
- export declare type RangeInputCSSClasses = Partial<{
16
+ export type RangeInputCSSClasses = Partial<{
17
17
  /**
18
18
  * CSS class to add to the root element.
19
19
  */
@@ -51,7 +51,7 @@ export declare type RangeInputCSSClasses = Partial<{
51
51
  */
52
52
  submit: string | string[];
53
53
  }>;
54
- export declare type RangeInputWidgetParams = {
54
+ export type RangeInputWidgetParams = {
55
55
  /**
56
56
  * Valid CSS Selector as a string or DOMElement.
57
57
  */
@@ -82,7 +82,7 @@ export declare type RangeInputWidgetParams = {
82
82
  */
83
83
  cssClasses?: RangeInputCSSClasses;
84
84
  };
85
- export declare type RangeInputWidget = WidgetFactory<Omit<RangeWidgetDescription, '$$type'> & {
85
+ export type RangeInputWidget = WidgetFactory<Omit<RangeWidgetDescription, '$$type'> & {
86
86
  $$widgetType: 'ais.rangeInput';
87
87
  $$type: 'ais.rangeInput';
88
88
  }, RangeConnectorParams, RangeInputWidgetParams>;
@@ -1,7 +1,7 @@
1
1
 
2
2
  import type { RangeConnectorParams, RangeWidgetDescription } from '../../connectors/range/connectRange';
3
3
  import type { WidgetFactory } from '../../types';
4
- export declare type RangeSliderCssClasses = Partial<{
4
+ export type RangeSliderCssClasses = Partial<{
5
5
  /**
6
6
  * CSS class to add to the root element.
7
7
  */
@@ -11,7 +11,7 @@ export declare type RangeSliderCssClasses = Partial<{
11
11
  */
12
12
  disabledRoot: string | string[];
13
13
  }>;
14
- declare type RangeSliderTooltipOptions = {
14
+ type RangeSliderTooltipOptions = {
15
15
  /**
16
16
  * The function takes the raw value as input, and should return
17
17
  * a string for the label that should be used for this value.
@@ -20,7 +20,7 @@ declare type RangeSliderTooltipOptions = {
20
20
  */
21
21
  format(value: number): string;
22
22
  };
23
- export declare type RangeSliderWidgetParams = {
23
+ export type RangeSliderWidgetParams = {
24
24
  /**
25
25
  * CSS Selector or DOMElement to insert the widget.
26
26
  */
@@ -64,7 +64,7 @@ export declare type RangeSliderWidgetParams = {
64
64
  */
65
65
  max?: number;
66
66
  };
67
- export declare type RangeSliderWidget = WidgetFactory<Omit<RangeWidgetDescription, '$$type'> & {
67
+ export type RangeSliderWidget = WidgetFactory<Omit<RangeWidgetDescription, '$$type'> & {
68
68
  $$widgetType: 'ais.rangeSlider';
69
69
  $$type: 'ais.rangeSlider';
70
70
  }, RangeConnectorParams, RangeSliderWidgetParams>;
@@ -1,7 +1,7 @@
1
1
 
2
2
  import type { RatingMenuWidgetDescription, RatingMenuConnectorParams } from '../../connectors/rating-menu/connectRatingMenu';
3
3
  import type { ComponentCSSClasses, Template, WidgetFactory } from '../../types';
4
- export declare type RatingMenuTemplates = Partial<{
4
+ export type RatingMenuTemplates = Partial<{
5
5
  /**
6
6
  * Item template, provided with `name`, `count`, `isRefined`, `url` data properties.
7
7
  */
@@ -18,7 +18,7 @@ export declare type RatingMenuTemplates = Partial<{
18
18
  isFromSearch?: boolean;
19
19
  }>;
20
20
  }>;
21
- export declare type RatingMenuCSSClasses = Partial<{
21
+ export type RatingMenuCSSClasses = Partial<{
22
22
  /**
23
23
  * CSS class to add to the root element.
24
24
  */
@@ -68,9 +68,9 @@ export declare type RatingMenuCSSClasses = Partial<{
68
68
  */
69
69
  count: string | string[];
70
70
  }>;
71
- export declare type RatingMenuComponentCSSClasses = ComponentCSSClasses<RatingMenuCSSClasses>;
72
- export declare type RatingMenuComponentTemplates = Required<RatingMenuTemplates>;
73
- export declare type RatingMenuWidgetParams = {
71
+ export type RatingMenuComponentCSSClasses = ComponentCSSClasses<RatingMenuCSSClasses>;
72
+ export type RatingMenuComponentTemplates = Required<RatingMenuTemplates>;
73
+ export type RatingMenuWidgetParams = {
74
74
  /**
75
75
  * Place where to insert the widget in your webpage.
76
76
  */
@@ -118,7 +118,7 @@ export declare type RatingMenuWidgetParams = {
118
118
  * })
119
119
  * ]);
120
120
  */
121
- export declare type RatingMenuWidget = WidgetFactory<RatingMenuWidgetDescription & {
121
+ export type RatingMenuWidget = WidgetFactory<RatingMenuWidgetDescription & {
122
122
  $$widgetType: 'ais.ratingMenu';
123
123
  }, RatingMenuConnectorParams, RatingMenuWidgetParams>;
124
124
  declare const ratingMenu: RatingMenuWidget;
@@ -2,7 +2,7 @@
2
2
  import type { RefinementListConnectorParams, RefinementListWidgetDescription } from '../../connectors/refinement-list/connectRefinementList';
3
3
  import type { Template, WidgetFactory } from '../../types';
4
4
  import type { SearchBoxTemplates } from '../search-box/search-box';
5
- export declare type RefinementListOwnCSSClasses = Partial<{
5
+ export type RefinementListOwnCSSClasses = Partial<{
6
6
  /**
7
7
  * CSS class to add to the root element.
8
8
  */
@@ -56,7 +56,7 @@ export declare type RefinementListOwnCSSClasses = Partial<{
56
56
  */
57
57
  searchBox: string | string[];
58
58
  }>;
59
- declare type RefinementListSearchableCSSClasses = Partial<{
59
+ type RefinementListSearchableCSSClasses = Partial<{
60
60
  searchableRoot: string | string[];
61
61
  searchableForm: string | string[];
62
62
  searchableInput: string | string[];
@@ -67,8 +67,8 @@ declare type RefinementListSearchableCSSClasses = Partial<{
67
67
  searchableLoadingIndicator: string | string[];
68
68
  searchableLoadingIcon: string | string[];
69
69
  }>;
70
- export declare type RefinementListCSSClasses = RefinementListOwnCSSClasses & RefinementListSearchableCSSClasses;
71
- export declare type RefinementListItemData = {
70
+ export type RefinementListCSSClasses = RefinementListOwnCSSClasses & RefinementListSearchableCSSClasses;
71
+ export type RefinementListItemData = {
72
72
  /**
73
73
  * The number of occurrences of the facet in the result set.
74
74
  */
@@ -102,7 +102,7 @@ export declare type RefinementListItemData = {
102
102
  */
103
103
  isFromSearch: boolean;
104
104
  };
105
- export declare type RefinementListOwnTemplates = Partial<{
105
+ export type RefinementListOwnTemplates = Partial<{
106
106
  /**
107
107
  * Item template, provided with `label`, `highlighted`, `value`, `count`, `isRefined`, `url` data properties.
108
108
  */
@@ -118,7 +118,7 @@ export declare type RefinementListOwnTemplates = Partial<{
118
118
  */
119
119
  searchableNoResults: Template;
120
120
  }>;
121
- declare type RefinementListSearchableTemplates = Partial<{
121
+ type RefinementListSearchableTemplates = Partial<{
122
122
  /**
123
123
  * Templates to use for search for facet values submit button.
124
124
  */
@@ -132,9 +132,9 @@ declare type RefinementListSearchableTemplates = Partial<{
132
132
  */
133
133
  searchableLoadingIndicator: SearchBoxTemplates['loadingIndicator'];
134
134
  }>;
135
- export declare type RefinementListTemplates = RefinementListOwnTemplates & RefinementListSearchableTemplates;
136
- export declare type RefinementListComponentTemplates = Required<RefinementListOwnTemplates>;
137
- export declare type RefinementListWidgetParams = {
135
+ export type RefinementListTemplates = RefinementListOwnTemplates & RefinementListSearchableTemplates;
136
+ export type RefinementListComponentTemplates = Required<RefinementListOwnTemplates>;
137
+ export type RefinementListWidgetParams = {
138
138
  /**
139
139
  * CSS Selector or HTMLElement to insert the widget.
140
140
  */
@@ -169,7 +169,7 @@ export declare type RefinementListWidgetParams = {
169
169
  */
170
170
  cssClasses?: RefinementListCSSClasses;
171
171
  };
172
- export declare type RefinementListWidget = WidgetFactory<RefinementListWidgetDescription & {
172
+ export type RefinementListWidget = WidgetFactory<RefinementListWidgetDescription & {
173
173
  $$widgetType: 'ais.refinementList';
174
174
  }, RefinementListConnectorParams, RefinementListWidgetParams>;
175
175
  /**
@@ -1,12 +1,12 @@
1
1
 
2
2
  import type { WidgetFactory, Template } from '../../types';
3
3
  import type { RelevantSortConnectorParams, RelevantSortWidgetDescription } from '../../connectors/relevant-sort/connectRelevantSort';
4
- export declare type RelevantSortCSSClasses = Partial<{
4
+ export type RelevantSortCSSClasses = Partial<{
5
5
  root: string;
6
6
  text: string;
7
7
  button: string;
8
8
  }>;
9
- export declare type RelevantSortTemplates = Partial<{
9
+ export type RelevantSortTemplates = Partial<{
10
10
  text: Template<{
11
11
  isRelevantSorted: boolean;
12
12
  }>;
@@ -14,12 +14,12 @@ export declare type RelevantSortTemplates = Partial<{
14
14
  isRelevantSorted: boolean;
15
15
  }>;
16
16
  }>;
17
- export declare type RelevantSortWidgetParams = {
17
+ export type RelevantSortWidgetParams = {
18
18
  container: string | HTMLElement;
19
19
  cssClasses?: RelevantSortCSSClasses;
20
20
  templates?: RelevantSortTemplates;
21
21
  };
22
- export declare type RelevantSortWidget = WidgetFactory<RelevantSortWidgetDescription & {
22
+ export type RelevantSortWidget = WidgetFactory<RelevantSortWidgetDescription & {
23
23
  $$widgetType: 'ais.relevantSort';
24
24
  }, RelevantSortConnectorParams, RelevantSortWidgetParams>;
25
25
  declare const relevantSort: RelevantSortWidget;
@@ -2,7 +2,7 @@
2
2
  import type { WidgetFactory, Template } from '../../types';
3
3
  import type { SearchBoxConnectorParams, SearchBoxWidgetDescription } from '../../connectors/search-box/connectSearchBox';
4
4
  import type { SearchBoxComponentCSSClasses } from '../../components/SearchBox/SearchBox';
5
- export declare type SearchBoxTemplates = Partial<{
5
+ export type SearchBoxTemplates = Partial<{
6
6
  /**
7
7
  * Template used for displaying the submit button. Can accept a function or a Hogan string.
8
8
  */
@@ -22,7 +22,7 @@ export declare type SearchBoxTemplates = Partial<{
22
22
  cssClasses: SearchBoxComponentCSSClasses;
23
23
  }>;
24
24
  }>;
25
- export declare type SearchBoxCSSClasses = Partial<{
25
+ export type SearchBoxCSSClasses = Partial<{
26
26
  /**
27
27
  * CSS class to add to the wrapping `<div>`
28
28
  */
@@ -60,7 +60,7 @@ export declare type SearchBoxCSSClasses = Partial<{
60
60
  */
61
61
  loadingIcon: string | string[];
62
62
  }>;
63
- export declare type SearchBoxWidgetParams = {
63
+ export type SearchBoxWidgetParams = {
64
64
  /**
65
65
  * CSS Selector or HTMLElement to insert the widget
66
66
  */
@@ -114,7 +114,7 @@ export declare type SearchBoxWidgetParams = {
114
114
  * away.
115
115
  *
116
116
  */
117
- export declare type SearchBoxWidget = WidgetFactory<SearchBoxWidgetDescription & {
117
+ export type SearchBoxWidget = WidgetFactory<SearchBoxWidgetDescription & {
118
118
  $$widgetType: 'ais.searchBox';
119
119
  }, SearchBoxConnectorParams, SearchBoxWidgetParams>;
120
120
  declare const searchBox: SearchBoxWidget;
@@ -1,7 +1,7 @@
1
1
 
2
2
  import type { SortByConnectorParams, SortByItem, SortByWidgetDescription } from '../../connectors/sort-by/connectSortBy';
3
3
  import type { TransformItems, WidgetFactory } from '../../types';
4
- export declare type SortByWidgetCssClasses = Partial<{
4
+ export type SortByWidgetCssClasses = Partial<{
5
5
  /**
6
6
  * CSS classes added to the outer `<div>`.
7
7
  */
@@ -15,7 +15,7 @@ export declare type SortByWidgetCssClasses = Partial<{
15
15
  */
16
16
  option: string | string[];
17
17
  }>;
18
- export declare type SortByIndexDefinition = {
18
+ export type SortByIndexDefinition = {
19
19
  /**
20
20
  * The name of the index to target.
21
21
  */
@@ -25,7 +25,7 @@ export declare type SortByIndexDefinition = {
25
25
  */
26
26
  label: string;
27
27
  };
28
- export declare type SortByWidgetParams = {
28
+ export type SortByWidgetParams = {
29
29
  /**
30
30
  * CSS Selector or HTMLElement to insert the widget.
31
31
  */
@@ -43,7 +43,7 @@ export declare type SortByWidgetParams = {
43
43
  */
44
44
  transformItems?: TransformItems<SortByItem>;
45
45
  };
46
- export declare type SortByWidget = WidgetFactory<SortByWidgetDescription & {
46
+ export type SortByWidget = WidgetFactory<SortByWidgetDescription & {
47
47
  $$widgetType: 'ais.sortBy';
48
48
  }, SortByConnectorParams, SortByWidgetParams>;
49
49
  /**
@@ -2,7 +2,7 @@
2
2
  import type { StatsComponentTemplates } from '../../components/Stats/Stats';
3
3
  import type { StatsConnectorParams, StatsRenderState, StatsWidgetDescription } from '../../connectors/stats/connectStats';
4
4
  import type { Template, WidgetFactory } from '../../types';
5
- declare type TextTemplateProps = {
5
+ type TextTemplateProps = {
6
6
  hasManyResults: boolean;
7
7
  hasNoResults: boolean;
8
8
  hasOneResult: boolean;
@@ -10,7 +10,7 @@ declare type TextTemplateProps = {
10
10
  hasOneSortedResults: boolean;
11
11
  hasManySortedResults: boolean;
12
12
  };
13
- export declare type StatsCSSClasses = Partial<{
13
+ export type StatsCSSClasses = Partial<{
14
14
  /**
15
15
  * CSS class to add to the root element.
16
16
  */
@@ -20,13 +20,13 @@ export declare type StatsCSSClasses = Partial<{
20
20
  */
21
21
  text: string | string[];
22
22
  }>;
23
- export declare type StatsTemplates = Partial<{
23
+ export type StatsTemplates = Partial<{
24
24
  /**
25
25
  * Text template, provided with `hasManyResults`, `hasNoResults`, `hasOneResult`, `hasNoSortedResults`, `hasOneSortedResults`, `hasManySortedResults`, `hitsPerPage`, `nbHits`, `nbSortedHits`, `nbPages`, `areHitsSorted`, `page`, `processingTimeMS`, `query`.
26
26
  */
27
27
  text: Template<TextTemplateProps & StatsRenderState>;
28
28
  }>;
29
- export declare type StatsWidgetParams = {
29
+ export type StatsWidgetParams = {
30
30
  /**
31
31
  * CSS Selector or HTMLElement to insert the widget.
32
32
  */
@@ -40,7 +40,7 @@ export declare type StatsWidgetParams = {
40
40
  */
41
41
  cssClasses?: StatsCSSClasses;
42
42
  };
43
- export declare type StatsWidget = WidgetFactory<StatsWidgetDescription & {
43
+ export type StatsWidget = WidgetFactory<StatsWidgetDescription & {
44
44
  $$widgetType: 'ais.stats';
45
45
  }, StatsConnectorParams, StatsWidgetParams>;
46
46
  export declare const defaultTemplates: StatsComponentTemplates;
@@ -1,7 +1,7 @@
1
1
 
2
2
  import type { ToggleRefinementConnectorParams, ToggleRefinementWidgetDescription, ToggleRefinementValue } from '../../connectors/toggle-refinement/connectToggleRefinement';
3
3
  import type { Template, WidgetFactory } from '../../types';
4
- export declare type ToggleRefinementCSSClasses = Partial<{
4
+ export type ToggleRefinementCSSClasses = Partial<{
5
5
  /**
6
6
  * CSS class to add to the root element.
7
7
  */
@@ -19,7 +19,7 @@ export declare type ToggleRefinementCSSClasses = Partial<{
19
19
  */
20
20
  labelText: string | string[];
21
21
  }>;
22
- export declare type ToggleRefinementTemplates = Partial<{
22
+ export type ToggleRefinementTemplates = Partial<{
23
23
  /**
24
24
  * the text that describes the toggle action
25
25
  */
@@ -27,7 +27,7 @@ export declare type ToggleRefinementTemplates = Partial<{
27
27
  name: string;
28
28
  }>;
29
29
  }>;
30
- export declare type ToggleRefinementWidgetParams = {
30
+ export type ToggleRefinementWidgetParams = {
31
31
  /**
32
32
  * CSS Selector or HTMLElement to insert the widget.
33
33
  */
@@ -41,7 +41,7 @@ export declare type ToggleRefinementWidgetParams = {
41
41
  */
42
42
  cssClasses?: ToggleRefinementCSSClasses;
43
43
  };
44
- export declare type ToggleRefinementWidget = WidgetFactory<ToggleRefinementWidgetDescription & {
44
+ export type ToggleRefinementWidget = WidgetFactory<ToggleRefinementWidgetDescription & {
45
45
  $$widgetType: 'ais.toggleRefinement';
46
46
  }, ToggleRefinementConnectorParams, ToggleRefinementWidgetParams>;
47
47
  /**
@@ -3,12 +3,12 @@ import type { PlainSearchParameters } from 'algoliasearch-helper';
3
3
  import type { VoiceSearchConnectorParams, VoiceSearchWidgetDescription } from '../../connectors/voice-search/connectVoiceSearch';
4
4
  import type { WidgetFactory, Template } from '../../types';
5
5
  import type { CreateVoiceSearchHelper } from '../../lib/voiceSearchHelper/types';
6
- export declare type VoiceSearchCSSClasses = Partial<{
6
+ export type VoiceSearchCSSClasses = Partial<{
7
7
  root: string | string[];
8
8
  button: string | string[];
9
9
  status: string | string[];
10
10
  }>;
11
- declare type VoiceSearchTemplateProps = {
11
+ type VoiceSearchTemplateProps = {
12
12
  status: string;
13
13
  errorCode: string;
14
14
  isListening: boolean;
@@ -16,11 +16,11 @@ declare type VoiceSearchTemplateProps = {
16
16
  isSpeechFinal: boolean;
17
17
  isBrowserSupported: boolean;
18
18
  };
19
- export declare type VoiceSearchTemplates = Partial<{
19
+ export type VoiceSearchTemplates = Partial<{
20
20
  buttonText: Template<VoiceSearchTemplateProps>;
21
21
  status: Template<VoiceSearchTemplateProps>;
22
22
  }>;
23
- export declare type VoiceSearchWidgetParams = {
23
+ export type VoiceSearchWidgetParams = {
24
24
  container: string | HTMLElement;
25
25
  cssClasses?: VoiceSearchCSSClasses;
26
26
  templates?: VoiceSearchTemplates;
@@ -31,7 +31,7 @@ export declare type VoiceSearchWidgetParams = {
31
31
  }) => PlainSearchParameters | void;
32
32
  createVoiceSearchHelper?: CreateVoiceSearchHelper;
33
33
  };
34
- export declare type VoiceSearchWidget = WidgetFactory<VoiceSearchWidgetDescription & {
34
+ export type VoiceSearchWidget = WidgetFactory<VoiceSearchWidgetDescription & {
35
35
  $$type: 'ais.voiceSearch';
36
36
  }, VoiceSearchConnectorParams, VoiceSearchWidgetParams>;
37
37
  declare const voiceSearch: VoiceSearchWidget;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "instantsearch.js",
3
- "version": "4.50.0",
3
+ "version": "4.50.1",
4
4
  "description": "InstantSearch.js is a JavaScript library for building performant and instant search experiences with Algolia.",
5
5
  "homepage": "https://www.algolia.com/doc/guides/building-search-ui/what-is-instantsearch/js/",
6
6
  "types": "es/index.d.ts",
@@ -29,6 +29,7 @@
29
29
  "@algolia/events": "^4.0.1",
30
30
  "@algolia/ui-components-highlight-vdom": "^1.2.1",
31
31
  "@algolia/ui-components-shared": "^1.2.1",
32
+ "@types/dom-speech-recognition": "^0.0.1",
32
33
  "@types/google.maps": "^3.45.3",
33
34
  "@types/hogan.js": "^3.0.0",
34
35
  "@types/qs": "^6.5.3",
@@ -54,9 +55,9 @@
54
55
  "version": "./scripts/version/update-version.js"
55
56
  },
56
57
  "devDependencies": {
57
- "@instantsearch/mocks": "1.1.0",
58
- "@instantsearch/tests": "1.1.0",
59
- "@instantsearch/testutils": "1.0.4",
58
+ "@instantsearch/mocks": "1.2.0",
59
+ "@instantsearch/tests": "1.2.0",
60
+ "@instantsearch/testutils": "1.0.5",
60
61
  "@storybook/html": "5.3.9",
61
62
  "@types/scriptjs": "0.0.2",
62
63
  "algoliasearch": "4.14.3",
@@ -64,5 +65,5 @@
64
65
  "scriptjs": "2.5.9",
65
66
  "webpack": "4.41.5"
66
67
  },
67
- "gitHead": "15adccb907fec9528ab169ee3d7d905ceab5a860"
68
+ "gitHead": "9c696ab3244d701c05d314bb765f086a50ff481b"
68
69
  }