instantsearch.js 4.53.0 → 4.54.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.
- package/cjs/components/Pagination/Pagination.js +35 -17
- package/cjs/components/Template/Template.js +6 -3
- package/cjs/connectors/hierarchical-menu/connectHierarchicalMenu.js +4 -0
- package/cjs/connectors/menu/connectMenu.js +4 -0
- package/cjs/connectors/refinement-list/connectRefinementList.js +8 -0
- package/cjs/connectors/toggle-refinement/connectToggleRefinement.js +4 -0
- package/cjs/helpers/highlight.js +5 -0
- package/cjs/helpers/reverseHighlight.js +5 -0
- package/cjs/helpers/reverseSnippet.js +5 -0
- package/cjs/helpers/snippet.js +5 -0
- package/cjs/lib/server.js +60 -0
- package/cjs/lib/utils/index.js +11 -0
- package/cjs/lib/utils/walkIndex.js +18 -0
- package/cjs/lib/version.js +1 -1
- package/cjs/widgets/pagination/pagination.js +51 -39
- package/cjs/widgets/panel/panel.js +0 -2
- package/cjs/widgets/places/places.js +1 -0
- package/dist/instantsearch.development.d.ts +27 -4
- package/dist/instantsearch.development.js +133 -63
- package/dist/instantsearch.development.js.map +1 -1
- package/dist/instantsearch.production.d.ts +27 -4
- package/dist/instantsearch.production.min.d.ts +27 -4
- package/dist/instantsearch.production.min.js +2 -2
- package/dist/instantsearch.production.min.js.map +1 -1
- package/es/components/Pagination/Pagination.js +34 -17
- package/es/components/Panel/Panel.d.ts +1 -1
- package/es/components/Template/Template.js +6 -3
- package/es/connectors/hierarchical-menu/connectHierarchicalMenu.js +4 -0
- package/es/connectors/menu/connectMenu.js +5 -1
- package/es/connectors/refinement-list/connectRefinementList.js +9 -1
- package/es/connectors/toggle-refinement/connectToggleRefinement.js +5 -1
- package/es/helpers/highlight.d.ts +3 -0
- package/es/helpers/highlight.js +5 -0
- package/es/helpers/reverseHighlight.d.ts +3 -0
- package/es/helpers/reverseHighlight.js +5 -0
- package/es/helpers/reverseSnippet.d.ts +3 -0
- package/es/helpers/reverseSnippet.js +5 -0
- package/es/helpers/snippet.d.ts +3 -0
- package/es/helpers/snippet.js +5 -0
- package/es/lib/server.d.ts +10 -0
- package/es/lib/server.js +53 -0
- package/es/lib/utils/index.d.ts +1 -0
- package/es/lib/utils/index.js +1 -0
- package/es/lib/utils/walkIndex.d.ts +5 -0
- package/es/lib/utils/walkIndex.js +12 -0
- package/es/lib/version.d.ts +1 -1
- package/es/lib/version.js +1 -1
- package/es/widgets/pagination/pagination.d.ts +12 -5
- package/es/widgets/pagination/pagination.js +51 -39
- package/es/widgets/panel/panel.js +0 -2
- package/es/widgets/places/places.d.ts +1 -1
- package/es/widgets/places/places.js +1 -0
- package/package.json +5 -5
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! InstantSearch.js 4.
|
|
1
|
+
/*! InstantSearch.js 4.54.1 | © Algolia, Inc. and contributors; MIT License | https://github.com/algolia/instantsearch.js */
|
|
2
2
|
(function (global, factory) {
|
|
3
3
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
4
4
|
typeof define === 'function' && define.amd ? define(factory) :
|
|
@@ -2432,6 +2432,10 @@
|
|
|
2432
2432
|
getWidgetSearchParameters: function getWidgetSearchParameters(searchParameters, _ref6) {
|
|
2433
2433
|
var uiState = _ref6.uiState;
|
|
2434
2434
|
var values = uiState.hierarchicalMenu && uiState.hierarchicalMenu[hierarchicalFacetName];
|
|
2435
|
+
if (searchParameters.isConjunctiveFacet(hierarchicalFacetName) || searchParameters.isDisjunctiveFacet(hierarchicalFacetName)) {
|
|
2436
|
+
_warning(false, "HierarchicalMenu: Attribute \"".concat(hierarchicalFacetName, "\" is already used by another widget applying conjunctive or disjunctive faceting.\nAs this is not supported, please make sure to remove this other widget or this HierarchicalMenu widget will not work at all.")) ;
|
|
2437
|
+
return searchParameters;
|
|
2438
|
+
}
|
|
2435
2439
|
if (searchParameters.isHierarchicalFacet(hierarchicalFacetName)) {
|
|
2436
2440
|
var facet = searchParameters.getHierarchicalFacetByName(hierarchicalFacetName);
|
|
2437
2441
|
_warning(isEqual(facet.attributes, attributes) && facet.separator === separator && facet.rootPath === rootPath, 'Using Breadcrumb and HierarchicalMenu on the same facet with different options overrides the configuration of the HierarchicalMenu.') ;
|
|
@@ -3277,6 +3281,10 @@
|
|
|
3277
3281
|
getWidgetSearchParameters: function getWidgetSearchParameters(searchParameters, _ref5) {
|
|
3278
3282
|
var uiState = _ref5.uiState;
|
|
3279
3283
|
var value = uiState.menu && uiState.menu[attribute];
|
|
3284
|
+
if (searchParameters.isConjunctiveFacet(attribute) || searchParameters.isDisjunctiveFacet(attribute)) {
|
|
3285
|
+
_warning(false, "Menu: Attribute \"".concat(attribute, "\" is already used by another widget applying conjunctive or disjunctive faceting.\nAs this is not supported, please make sure to remove this other widget or this Menu widget will not work at all.")) ;
|
|
3286
|
+
return searchParameters;
|
|
3287
|
+
}
|
|
3280
3288
|
var withFacetConfiguration = searchParameters.removeHierarchicalFacet(attribute).addHierarchicalFacet({
|
|
3281
3289
|
name: attribute,
|
|
3282
3290
|
attributes: [attribute]
|
|
@@ -4223,6 +4231,14 @@
|
|
|
4223
4231
|
getWidgetSearchParameters: function getWidgetSearchParameters(searchParameters, _ref6) {
|
|
4224
4232
|
var uiState = _ref6.uiState;
|
|
4225
4233
|
var isDisjunctive = operator === 'or';
|
|
4234
|
+
if (searchParameters.isHierarchicalFacet(attribute)) {
|
|
4235
|
+
_warning(false, "RefinementList: Attribute \"".concat(attribute, "\" is already used by another widget applying hierarchical faceting.\nAs this is not supported, please make sure to remove this other widget or this RefinementList widget will not work at all.")) ;
|
|
4236
|
+
return searchParameters;
|
|
4237
|
+
}
|
|
4238
|
+
if (isDisjunctive && searchParameters.isConjunctiveFacet(attribute) || !isDisjunctive && searchParameters.isDisjunctiveFacet(attribute)) {
|
|
4239
|
+
_warning(false, "RefinementList: Attribute \"".concat(attribute, "\" is used by another refinement list with a different operator.\nAs this is not supported, please make sure to only use this attribute with one of the two operators.")) ;
|
|
4240
|
+
return searchParameters;
|
|
4241
|
+
}
|
|
4226
4242
|
var values = uiState.refinementList && uiState.refinementList[attribute];
|
|
4227
4243
|
var withoutRefinements = searchParameters.clearRefinements(attribute);
|
|
4228
4244
|
var withFacetConfiguration = isDisjunctive ? withoutRefinements.addDisjunctiveFacet(attribute) : withoutRefinements.addFacet(attribute);
|
|
@@ -4988,6 +5004,10 @@
|
|
|
4988
5004
|
},
|
|
4989
5005
|
getWidgetSearchParameters: function getWidgetSearchParameters(searchParameters, _ref11) {
|
|
4990
5006
|
var uiState = _ref11.uiState;
|
|
5007
|
+
if (searchParameters.isHierarchicalFacet(attribute) || searchParameters.isConjunctiveFacet(attribute)) {
|
|
5008
|
+
_warning(false, "ToggleRefinement: Attribute \"".concat(attribute, "\" is already used by another widget of a different type.\nAs this is not supported, please make sure to remove this other widget or this ToggleRefinement widget will not work at all.")) ;
|
|
5009
|
+
return searchParameters;
|
|
5010
|
+
}
|
|
4991
5011
|
var withFacetConfiguration = searchParameters.clearRefinements(attribute).addDisjunctiveFacet(attribute);
|
|
4992
5012
|
var isRefined = Boolean(uiState.toggle && uiState.toggle[attribute]);
|
|
4993
5013
|
if (isRefined) {
|
|
@@ -11687,6 +11707,10 @@
|
|
|
11687
11707
|
};
|
|
11688
11708
|
|
|
11689
11709
|
var suit = component('Highlight');
|
|
11710
|
+
|
|
11711
|
+
/**
|
|
11712
|
+
* @deprecated use html tagged templates and the Highlight component instead
|
|
11713
|
+
*/
|
|
11690
11714
|
function highlight(_ref) {
|
|
11691
11715
|
var attribute = _ref.attribute,
|
|
11692
11716
|
_ref$highlightedTagNa = _ref.highlightedTagName,
|
|
@@ -11694,6 +11718,7 @@
|
|
|
11694
11718
|
hit = _ref.hit,
|
|
11695
11719
|
_ref$cssClasses = _ref.cssClasses,
|
|
11696
11720
|
cssClasses = _ref$cssClasses === void 0 ? {} : _ref$cssClasses;
|
|
11721
|
+
_warning(false, "`instantsearch.highlight` function has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `Highlight` component.\n\nFor more information, visit https://www.algolia.com/doc/guides/building-search-ui/upgrade-guides/js/?client=html+tagged+templates#upgrade-templates") ;
|
|
11697
11722
|
var highlightAttributeResult = getPropertyByPath(hit._highlightResult, attribute);
|
|
11698
11723
|
|
|
11699
11724
|
// @MAJOR fallback to attribute value if highlight is not found
|
|
@@ -11710,6 +11735,10 @@
|
|
|
11710
11735
|
}
|
|
11711
11736
|
|
|
11712
11737
|
var suit$1 = component('ReverseHighlight');
|
|
11738
|
+
|
|
11739
|
+
/**
|
|
11740
|
+
* @deprecated use html tagged templates and the ReverseHighlight component instead
|
|
11741
|
+
*/
|
|
11713
11742
|
function reverseHighlight(_ref) {
|
|
11714
11743
|
var attribute = _ref.attribute,
|
|
11715
11744
|
_ref$highlightedTagNa = _ref.highlightedTagName,
|
|
@@ -11717,6 +11746,7 @@
|
|
|
11717
11746
|
hit = _ref.hit,
|
|
11718
11747
|
_ref$cssClasses = _ref.cssClasses,
|
|
11719
11748
|
cssClasses = _ref$cssClasses === void 0 ? {} : _ref$cssClasses;
|
|
11749
|
+
_warning(false, "`instantsearch.reverseHighlight` function has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `ReverseHighlight` component.\n\nFor more information, visit https://www.algolia.com/doc/guides/building-search-ui/upgrade-guides/js/?client=html+tagged+templates#upgrade-templates") ;
|
|
11720
11750
|
var highlightAttributeResult = getPropertyByPath(hit._highlightResult, attribute);
|
|
11721
11751
|
|
|
11722
11752
|
// @MAJOR fallback to attribute value if highlight is not found
|
|
@@ -11734,6 +11764,10 @@
|
|
|
11734
11764
|
}
|
|
11735
11765
|
|
|
11736
11766
|
var suit$2 = component('Snippet');
|
|
11767
|
+
|
|
11768
|
+
/**
|
|
11769
|
+
* @deprecated use html tagged templates and the Snippet component instead
|
|
11770
|
+
*/
|
|
11737
11771
|
function snippet(_ref) {
|
|
11738
11772
|
var attribute = _ref.attribute,
|
|
11739
11773
|
_ref$highlightedTagNa = _ref.highlightedTagName,
|
|
@@ -11741,6 +11775,7 @@
|
|
|
11741
11775
|
hit = _ref.hit,
|
|
11742
11776
|
_ref$cssClasses = _ref.cssClasses,
|
|
11743
11777
|
cssClasses = _ref$cssClasses === void 0 ? {} : _ref$cssClasses;
|
|
11778
|
+
_warning(false, "`instantsearch.snippet` function has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `Snippet` component.\n\nFor more information, visit https://www.algolia.com/doc/guides/building-search-ui/upgrade-guides/js/?client=html+tagged+templates#upgrade-templates") ;
|
|
11744
11779
|
var snippetAttributeResult = getPropertyByPath(hit._snippetResult, attribute);
|
|
11745
11780
|
|
|
11746
11781
|
// @MAJOR fallback to attribute value if snippet is not found
|
|
@@ -11757,6 +11792,10 @@
|
|
|
11757
11792
|
}
|
|
11758
11793
|
|
|
11759
11794
|
var suit$3 = component('ReverseSnippet');
|
|
11795
|
+
|
|
11796
|
+
/**
|
|
11797
|
+
* @deprecated use html tagged templates and the ReverseSnippet component instead
|
|
11798
|
+
*/
|
|
11760
11799
|
function reverseSnippet(_ref) {
|
|
11761
11800
|
var attribute = _ref.attribute,
|
|
11762
11801
|
_ref$highlightedTagNa = _ref.highlightedTagName,
|
|
@@ -11764,6 +11803,7 @@
|
|
|
11764
11803
|
hit = _ref.hit,
|
|
11765
11804
|
_ref$cssClasses = _ref.cssClasses,
|
|
11766
11805
|
cssClasses = _ref$cssClasses === void 0 ? {} : _ref$cssClasses;
|
|
11806
|
+
_warning(false, "`instantsearch.reverseSnippet` function has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `ReverseSnippet` component.\n\nFor more information, visit https://www.algolia.com/doc/guides/building-search-ui/upgrade-guides/js/?client=html+tagged+templates#upgrade-templates") ;
|
|
11767
11807
|
var snippetAttributeResult = getPropertyByPath(hit._snippetResult, attribute);
|
|
11768
11808
|
|
|
11769
11809
|
// @MAJOR fallback to attribute value if snippet is not found
|
|
@@ -13620,7 +13660,7 @@
|
|
|
13620
13660
|
};
|
|
13621
13661
|
}
|
|
13622
13662
|
|
|
13623
|
-
var version$1 = '4.
|
|
13663
|
+
var version$1 = '4.54.1';
|
|
13624
13664
|
|
|
13625
13665
|
var withUsage$r = createDocumentationMessageGenerator({
|
|
13626
13666
|
name: 'instantsearch'
|
|
@@ -15515,9 +15555,12 @@
|
|
|
15515
15555
|
key: "render",
|
|
15516
15556
|
value: function render() {
|
|
15517
15557
|
var _this = this;
|
|
15518
|
-
|
|
15519
|
-
|
|
15520
|
-
|
|
15558
|
+
{
|
|
15559
|
+
var nonFunctionTemplates = Object.keys(this.props.templates).filter(function (key) {
|
|
15560
|
+
return typeof _this.props.templates[key] !== 'function';
|
|
15561
|
+
});
|
|
15562
|
+
_warning(nonFunctionTemplates.length === 0, "Hogan.js and string-based templates are deprecated and will not be supported in InstantSearch.js 5.x.\n\nYou can replace them with function-form templates and use either the provided `html` function or JSX templates.\n\nString-based templates: ".concat(nonFunctionTemplates.join(', '), ".\n\nSee: https://www.algolia.com/doc/guides/building-search-ui/upgrade-guides/js/#upgrade-templates")) ;
|
|
15563
|
+
}
|
|
15521
15564
|
var RootTagName = this.props.rootTagName;
|
|
15522
15565
|
var useCustomCompileOptions = this.props.useCustomCompileOptions[this.props.templateKey];
|
|
15523
15566
|
var compileOptions = useCustomCompileOptions ? this.props.templatesConfig.compileOptions : {};
|
|
@@ -18236,7 +18279,8 @@
|
|
|
18236
18279
|
ariaLabel: "First",
|
|
18237
18280
|
className: props.cssClasses.firstPageItem,
|
|
18238
18281
|
isDisabled: props.isFirstPage,
|
|
18239
|
-
|
|
18282
|
+
templates: props.templates,
|
|
18283
|
+
templateKey: "first",
|
|
18240
18284
|
pageNumber: 0,
|
|
18241
18285
|
createURL: props.createURL,
|
|
18242
18286
|
cssClasses: props.cssClasses,
|
|
@@ -18245,7 +18289,8 @@
|
|
|
18245
18289
|
ariaLabel: "Previous",
|
|
18246
18290
|
className: props.cssClasses.previousPageItem,
|
|
18247
18291
|
isDisabled: props.isFirstPage,
|
|
18248
|
-
|
|
18292
|
+
templates: props.templates,
|
|
18293
|
+
templateKey: "previous",
|
|
18249
18294
|
pageNumber: props.currentPage - 1,
|
|
18250
18295
|
createURL: props.createURL,
|
|
18251
18296
|
cssClasses: props.cssClasses,
|
|
@@ -18256,7 +18301,8 @@
|
|
|
18256
18301
|
ariaLabel: "Page ".concat(pageNumber + 1),
|
|
18257
18302
|
className: props.cssClasses.pageItem,
|
|
18258
18303
|
isSelected: pageNumber === props.currentPage,
|
|
18259
|
-
|
|
18304
|
+
templates: props.templates,
|
|
18305
|
+
templateKey: "page",
|
|
18260
18306
|
pageNumber: pageNumber,
|
|
18261
18307
|
createURL: props.createURL,
|
|
18262
18308
|
cssClasses: props.cssClasses,
|
|
@@ -18266,7 +18312,8 @@
|
|
|
18266
18312
|
ariaLabel: "Next",
|
|
18267
18313
|
className: props.cssClasses.nextPageItem,
|
|
18268
18314
|
isDisabled: props.isLastPage,
|
|
18269
|
-
|
|
18315
|
+
templates: props.templates,
|
|
18316
|
+
templateKey: "next",
|
|
18270
18317
|
pageNumber: props.currentPage + 1,
|
|
18271
18318
|
createURL: props.createURL,
|
|
18272
18319
|
cssClasses: props.cssClasses,
|
|
@@ -18275,7 +18322,8 @@
|
|
|
18275
18322
|
ariaLabel: "Last",
|
|
18276
18323
|
className: props.cssClasses.lastPageItem,
|
|
18277
18324
|
isDisabled: props.isLastPage,
|
|
18278
|
-
|
|
18325
|
+
templates: props.templates,
|
|
18326
|
+
templateKey: "last",
|
|
18279
18327
|
pageNumber: props.nbPages - 1,
|
|
18280
18328
|
createURL: props.createURL,
|
|
18281
18329
|
cssClasses: props.cssClasses,
|
|
@@ -18283,7 +18331,8 @@
|
|
|
18283
18331
|
})));
|
|
18284
18332
|
}
|
|
18285
18333
|
function PaginationLink(_ref) {
|
|
18286
|
-
var
|
|
18334
|
+
var templates = _ref.templates,
|
|
18335
|
+
templateKey = _ref.templateKey,
|
|
18287
18336
|
ariaLabel = _ref.ariaLabel,
|
|
18288
18337
|
pageNumber = _ref.pageNumber,
|
|
18289
18338
|
className = _ref.className,
|
|
@@ -18296,18 +18345,28 @@
|
|
|
18296
18345
|
createClickHandler = _ref.createClickHandler;
|
|
18297
18346
|
return h("li", {
|
|
18298
18347
|
className: cx(cssClasses.item, className, isDisabled && cssClasses.disabledItem, isSelected && cssClasses.selectedItem)
|
|
18299
|
-
}, isDisabled ? h(
|
|
18300
|
-
|
|
18301
|
-
|
|
18302
|
-
|
|
18348
|
+
}, isDisabled ? h(Template, {
|
|
18349
|
+
rootTagName: "span",
|
|
18350
|
+
rootProps: {
|
|
18351
|
+
className: cssClasses.link
|
|
18352
|
+
},
|
|
18353
|
+
templateKey: templateKey,
|
|
18354
|
+
templates: templates,
|
|
18355
|
+
data: {
|
|
18356
|
+
page: pageNumber + 1
|
|
18303
18357
|
}
|
|
18304
|
-
}) : h(
|
|
18305
|
-
|
|
18306
|
-
|
|
18307
|
-
|
|
18308
|
-
|
|
18309
|
-
|
|
18310
|
-
|
|
18358
|
+
}) : h(Template, {
|
|
18359
|
+
rootTagName: "a",
|
|
18360
|
+
rootProps: {
|
|
18361
|
+
className: cssClasses.link,
|
|
18362
|
+
'aria-label': ariaLabel,
|
|
18363
|
+
href: createURL(pageNumber),
|
|
18364
|
+
onClick: createClickHandler(pageNumber)
|
|
18365
|
+
},
|
|
18366
|
+
templateKey: templateKey,
|
|
18367
|
+
templates: templates,
|
|
18368
|
+
data: {
|
|
18369
|
+
page: pageNumber + 1
|
|
18311
18370
|
}
|
|
18312
18371
|
}));
|
|
18313
18372
|
}
|
|
@@ -18317,28 +18376,40 @@
|
|
|
18317
18376
|
name: 'pagination'
|
|
18318
18377
|
});
|
|
18319
18378
|
var defaultTemplates$a = {
|
|
18320
|
-
previous:
|
|
18321
|
-
|
|
18322
|
-
|
|
18323
|
-
|
|
18379
|
+
previous: function previous() {
|
|
18380
|
+
return '‹';
|
|
18381
|
+
},
|
|
18382
|
+
next: function next() {
|
|
18383
|
+
return '›';
|
|
18384
|
+
},
|
|
18385
|
+
page: function page(_ref) {
|
|
18386
|
+
var _page = _ref.page;
|
|
18387
|
+
return "".concat(_page);
|
|
18388
|
+
},
|
|
18389
|
+
first: function first() {
|
|
18390
|
+
return '«';
|
|
18391
|
+
},
|
|
18392
|
+
last: function last() {
|
|
18393
|
+
return '»';
|
|
18394
|
+
}
|
|
18324
18395
|
};
|
|
18325
|
-
var renderer$c = function renderer(
|
|
18326
|
-
var containerNode =
|
|
18327
|
-
cssClasses =
|
|
18328
|
-
templates =
|
|
18329
|
-
showFirst =
|
|
18330
|
-
showLast =
|
|
18331
|
-
showPrevious =
|
|
18332
|
-
showNext =
|
|
18333
|
-
scrollToNode =
|
|
18334
|
-
return function (
|
|
18335
|
-
var createURL =
|
|
18336
|
-
currentRefinement =
|
|
18337
|
-
nbPages =
|
|
18338
|
-
pages =
|
|
18339
|
-
isFirstPage =
|
|
18340
|
-
isLastPage =
|
|
18341
|
-
refine =
|
|
18396
|
+
var renderer$c = function renderer(_ref2) {
|
|
18397
|
+
var containerNode = _ref2.containerNode,
|
|
18398
|
+
cssClasses = _ref2.cssClasses,
|
|
18399
|
+
templates = _ref2.templates,
|
|
18400
|
+
showFirst = _ref2.showFirst,
|
|
18401
|
+
showLast = _ref2.showLast,
|
|
18402
|
+
showPrevious = _ref2.showPrevious,
|
|
18403
|
+
showNext = _ref2.showNext,
|
|
18404
|
+
scrollToNode = _ref2.scrollToNode;
|
|
18405
|
+
return function (_ref3, isFirstRendering) {
|
|
18406
|
+
var createURL = _ref3.createURL,
|
|
18407
|
+
currentRefinement = _ref3.currentRefinement,
|
|
18408
|
+
nbPages = _ref3.nbPages,
|
|
18409
|
+
pages = _ref3.pages,
|
|
18410
|
+
isFirstPage = _ref3.isFirstPage,
|
|
18411
|
+
isLastPage = _ref3.isLastPage,
|
|
18412
|
+
refine = _ref3.refine;
|
|
18342
18413
|
if (isFirstRendering) return;
|
|
18343
18414
|
var setCurrentPage = function setCurrentPage(pageNumber) {
|
|
18344
18415
|
refine(pageNumber);
|
|
@@ -18364,24 +18435,24 @@
|
|
|
18364
18435
|
};
|
|
18365
18436
|
};
|
|
18366
18437
|
var pagination = function pagination(widgetParams) {
|
|
18367
|
-
var
|
|
18368
|
-
container =
|
|
18369
|
-
|
|
18370
|
-
userTemplates =
|
|
18371
|
-
|
|
18372
|
-
userCssClasses =
|
|
18373
|
-
totalPages =
|
|
18374
|
-
padding =
|
|
18375
|
-
|
|
18376
|
-
showFirst =
|
|
18377
|
-
|
|
18378
|
-
showLast =
|
|
18379
|
-
|
|
18380
|
-
showPrevious =
|
|
18381
|
-
|
|
18382
|
-
showNext =
|
|
18383
|
-
|
|
18384
|
-
userScrollTo =
|
|
18438
|
+
var _ref4 = widgetParams || {},
|
|
18439
|
+
container = _ref4.container,
|
|
18440
|
+
_ref4$templates = _ref4.templates,
|
|
18441
|
+
userTemplates = _ref4$templates === void 0 ? {} : _ref4$templates,
|
|
18442
|
+
_ref4$cssClasses = _ref4.cssClasses,
|
|
18443
|
+
userCssClasses = _ref4$cssClasses === void 0 ? {} : _ref4$cssClasses,
|
|
18444
|
+
totalPages = _ref4.totalPages,
|
|
18445
|
+
padding = _ref4.padding,
|
|
18446
|
+
_ref4$showFirst = _ref4.showFirst,
|
|
18447
|
+
showFirst = _ref4$showFirst === void 0 ? true : _ref4$showFirst,
|
|
18448
|
+
_ref4$showLast = _ref4.showLast,
|
|
18449
|
+
showLast = _ref4$showLast === void 0 ? true : _ref4$showLast,
|
|
18450
|
+
_ref4$showPrevious = _ref4.showPrevious,
|
|
18451
|
+
showPrevious = _ref4$showPrevious === void 0 ? true : _ref4$showPrevious,
|
|
18452
|
+
_ref4$showNext = _ref4.showNext,
|
|
18453
|
+
showNext = _ref4$showNext === void 0 ? true : _ref4$showNext,
|
|
18454
|
+
_ref4$scrollTo = _ref4.scrollTo,
|
|
18455
|
+
userScrollTo = _ref4$scrollTo === void 0 ? 'body' : _ref4$scrollTo;
|
|
18385
18456
|
if (!container) {
|
|
18386
18457
|
throw new Error(withUsage$G('The `container` option is required.'));
|
|
18387
18458
|
}
|
|
@@ -18599,8 +18670,6 @@
|
|
|
18599
18670
|
}
|
|
18600
18671
|
var containerNode = getContainerNode(widgetParams.container);
|
|
18601
18672
|
var defaultTemplates = {
|
|
18602
|
-
header: '',
|
|
18603
|
-
footer: '',
|
|
18604
18673
|
collapseButtonText: function collapseButtonText(_ref4) {
|
|
18605
18674
|
var isCollapsed = _ref4.collapsed;
|
|
18606
18675
|
return "<svg\n class=\"".concat(cssClasses.collapseIcon, "\"\n style=\"width: 1em; height: 1em;\"\n viewBox=\"0 0 500 500\"\n >\n <path d=\"").concat(isCollapsed ? 'M100 250l300-150v300z' : 'M250 400l150-300H100z', "\" fill=\"currentColor\" />\n </svg>");
|
|
@@ -18673,6 +18742,7 @@
|
|
|
18673
18742
|
|
|
18674
18743
|
var _excluded$l = ["placesReference", "defaultPosition"],
|
|
18675
18744
|
_excluded2$4 = ["places"];
|
|
18745
|
+
/* Places.js is an optional dependency, no error should be reported if the package is missing */
|
|
18676
18746
|
/** @ts-ignore */
|
|
18677
18747
|
|
|
18678
18748
|
// using the type like this requires only one ts-ignore
|