instantsearch.js 4.76.0 → 4.77.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/connectors/frequently-bought-together/connectFrequentlyBoughtTogether.js +20 -4
- package/cjs/connectors/looking-similar/connectLookingSimilar.js +23 -6
- package/cjs/connectors/related-products/connectRelatedProducts.js +23 -6
- package/cjs/connectors/trending-items/connectTrendingItems.js +23 -6
- package/cjs/lib/version.js +1 -1
- package/cjs/templates/carousel/carousel.js +4 -1
- package/cjs/widgets/frequently-bought-together/frequently-bought-together.js +10 -5
- package/cjs/widgets/looking-similar/looking-similar.js +9 -4
- package/cjs/widgets/related-products/related-products.js +10 -5
- package/cjs/widgets/trending-items/trending-items.js +10 -5
- package/dist/instantsearch.development.d.ts +35 -9
- package/dist/instantsearch.development.js +149 -48
- package/dist/instantsearch.development.js.map +1 -1
- package/dist/instantsearch.production.d.ts +35 -9
- package/dist/instantsearch.production.min.d.ts +35 -9
- package/dist/instantsearch.production.min.js +2 -2
- package/dist/instantsearch.production.min.js.map +1 -1
- package/es/connectors/frequently-bought-together/connectFrequentlyBoughtTogether.d.ts +7 -1
- package/es/connectors/frequently-bought-together/connectFrequentlyBoughtTogether.js +21 -5
- package/es/connectors/looking-similar/connectLookingSimilar.d.ts +7 -1
- package/es/connectors/looking-similar/connectLookingSimilar.js +24 -7
- package/es/connectors/related-products/connectRelatedProducts.d.ts +7 -1
- package/es/connectors/related-products/connectRelatedProducts.js +24 -7
- package/es/connectors/trending-items/connectTrendingItems.d.ts +7 -1
- package/es/connectors/trending-items/connectTrendingItems.js +24 -7
- package/es/lib/version.d.ts +1 -1
- package/es/lib/version.js +1 -1
- package/es/templates/carousel/carousel.d.ts +3 -1
- package/es/templates/carousel/carousel.js +4 -1
- package/es/widgets/frequently-bought-together/frequently-bought-together.d.ts +2 -1
- package/es/widgets/frequently-bought-together/frequently-bought-together.js +10 -5
- package/es/widgets/looking-similar/looking-similar.d.ts +2 -1
- package/es/widgets/looking-similar/looking-similar.js +9 -4
- package/es/widgets/related-products/related-products.d.ts +2 -1
- package/es/widgets/related-products/related-products.js +10 -5
- package/es/widgets/trending-items/trending-items.d.ts +2 -1
- package/es/widgets/trending-items/trending-items.js +10 -5
- package/package.json +6 -6
|
@@ -26,7 +26,8 @@ function createRenderer(_ref) {
|
|
|
26
26
|
return function renderer(_ref2, isFirstRendering) {
|
|
27
27
|
var items = _ref2.items,
|
|
28
28
|
results = _ref2.results,
|
|
29
|
-
instantSearchInstance = _ref2.instantSearchInstance
|
|
29
|
+
instantSearchInstance = _ref2.instantSearchInstance,
|
|
30
|
+
sendEvent = _ref2.sendEvent;
|
|
30
31
|
if (isFirstRendering) {
|
|
31
32
|
renderState.templateProps = prepareTemplateProps({
|
|
32
33
|
defaultTemplates: {},
|
|
@@ -50,7 +51,8 @@ function createRenderer(_ref) {
|
|
|
50
51
|
return h(TemplateComponent, _extends({}, renderState.templateProps, {
|
|
51
52
|
templateKey: "item",
|
|
52
53
|
rootTagName: "fragment",
|
|
53
|
-
data: item
|
|
54
|
+
data: item,
|
|
55
|
+
sendEvent: sendEvent
|
|
54
56
|
}));
|
|
55
57
|
} : undefined;
|
|
56
58
|
var emptyComponent = templates.empty ? function () {
|
|
@@ -65,6 +67,7 @@ function createRenderer(_ref) {
|
|
|
65
67
|
templateKey: "layout",
|
|
66
68
|
rootTagName: "fragment",
|
|
67
69
|
data: {
|
|
70
|
+
sendEvent: sendEvent,
|
|
68
71
|
items: data.items,
|
|
69
72
|
templates: {
|
|
70
73
|
item: templates.item ? function (_ref4) {
|
|
@@ -72,7 +75,8 @@ function createRenderer(_ref) {
|
|
|
72
75
|
return h(TemplateComponent, _extends({}, renderState.templateProps, {
|
|
73
76
|
templateKey: "item",
|
|
74
77
|
rootTagName: "fragment",
|
|
75
|
-
data: item
|
|
78
|
+
data: item,
|
|
79
|
+
sendEvent: sendEvent
|
|
76
80
|
}));
|
|
77
81
|
} : undefined
|
|
78
82
|
},
|
|
@@ -80,12 +84,13 @@ function createRenderer(_ref) {
|
|
|
80
84
|
list: data.classNames.list,
|
|
81
85
|
item: data.classNames.item
|
|
82
86
|
}
|
|
83
|
-
}
|
|
87
|
+
},
|
|
88
|
+
sendEvent: sendEvent
|
|
84
89
|
}));
|
|
85
90
|
} : undefined;
|
|
86
91
|
render(h(TrendingItems, {
|
|
87
92
|
items: items,
|
|
88
|
-
sendEvent:
|
|
93
|
+
sendEvent: sendEvent,
|
|
89
94
|
classNames: cssClasses,
|
|
90
95
|
headerComponent: headerComponent,
|
|
91
96
|
itemComponent: itemComponent,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "instantsearch.js",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.77.0",
|
|
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",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"algoliasearch-helper": "3.23.0",
|
|
35
35
|
"hogan.js": "^3.0.2",
|
|
36
36
|
"htm": "^3.0.0",
|
|
37
|
-
"instantsearch-ui-components": "0.
|
|
37
|
+
"instantsearch-ui-components": "0.11.0",
|
|
38
38
|
"preact": "^10.10.0",
|
|
39
39
|
"qs": "^6.5.1 < 6.10",
|
|
40
40
|
"search-insights": "^2.17.2"
|
|
@@ -56,9 +56,9 @@
|
|
|
56
56
|
"watch:es": "yarn --silent build:es:base --watch"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
|
-
"@instantsearch/mocks": "1.
|
|
60
|
-
"@instantsearch/tests": "1.
|
|
61
|
-
"@instantsearch/testutils": "1.
|
|
59
|
+
"@instantsearch/mocks": "1.67.0",
|
|
60
|
+
"@instantsearch/tests": "1.67.0",
|
|
61
|
+
"@instantsearch/testutils": "1.56.0",
|
|
62
62
|
"@storybook/html": "5.3.9",
|
|
63
63
|
"@types/scriptjs": "0.0.2",
|
|
64
64
|
"algoliasearch": "5.1.1",
|
|
@@ -66,5 +66,5 @@
|
|
|
66
66
|
"scriptjs": "2.5.9",
|
|
67
67
|
"webpack": "4.47.0"
|
|
68
68
|
},
|
|
69
|
-
"gitHead": "
|
|
69
|
+
"gitHead": "d3e46fedc5bba4482cfc5aadaf9b9c436681e93f"
|
|
70
70
|
}
|