@mjhls/mjh-framework 1.0.816-beta.1 → 1.0.817-image-crop-test
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/README.md +170 -170
- package/dist/cjs/AD.js +10 -9
- package/dist/cjs/AD300x250.js +31 -30
- package/dist/cjs/AD300x250x600.js +31 -30
- package/dist/cjs/AD728x90.js +34 -33
- package/dist/cjs/ADFloatingFooter.js +33 -32
- package/dist/cjs/ADFooter.js +15 -14
- package/dist/cjs/ADGutter.js +33 -32
- package/dist/cjs/{ADInfeed-7c4b33b3.js → ADInfeed-1ac86856.js} +15 -13
- package/dist/cjs/ADSkyscraper.js +33 -32
- package/dist/cjs/ADSponsoredResources.js +33 -32
- package/dist/cjs/ADWebcast.js +33 -32
- package/dist/cjs/ADWelcome.js +34 -33
- package/dist/cjs/{ADlgInfeed-563e0168.js → ADlgInfeed-2ee46b09.js} +11 -10
- package/dist/cjs/AccordionPanel.js +31 -29
- package/dist/cjs/AdSlot.js +36 -35
- package/dist/cjs/AdSlotsProvider.js +17 -909
- package/dist/cjs/AlgoliaSearch.js +1088 -1068
- package/dist/cjs/AlphabeticList.js +26 -25
- package/dist/cjs/ArticleCarousel.js +25 -23
- package/dist/cjs/ArticleProgramLandingPage.js +60 -58
- package/dist/cjs/ArticleSeriesLandingPage.js +41 -40
- package/dist/cjs/ArticleSeriesListing.js +62 -60
- package/dist/cjs/Auth.js +686 -662
- package/dist/cjs/AuthWrapper.js +311 -269
- package/dist/cjs/{AuthorComponent-bb831b74.js → AuthorComponent-c21aac7f.js} +14 -13
- package/dist/cjs/Beam.js +8 -8
- package/dist/cjs/{BlockContent-091a991f.js → BlockContent-36e54d77.js} +56 -55
- package/dist/cjs/Breadcrumbs.js +29 -27
- package/dist/cjs/CMEDeck.js +83 -83
- package/dist/cjs/Column1.js +14 -11
- package/dist/cjs/Column2.js +36 -33
- package/dist/cjs/Column3.js +62 -59
- package/dist/cjs/ConferenceArticleCard.js +40 -44
- package/dist/cjs/ConferenceBanner-6c9e718a.js +24 -0
- package/dist/cjs/DeckContent.js +110 -112
- package/dist/cjs/DeckQueue.js +95 -98
- package/dist/cjs/{Dfp-26baccf1.js → Dfp-93399f8c.js} +35 -34
- package/dist/cjs/EventsDeck.js +159 -152
- package/dist/cjs/ExternalResources.js +82 -80
- package/dist/cjs/Feature.js +30 -32
- package/dist/cjs/ForbesHero.js +46 -47
- package/dist/cjs/GridContent.js +194 -293
- package/dist/cjs/GridHero.js +50 -60
- package/dist/cjs/GroupDeck.js +62 -65
- package/dist/cjs/HamMagazine.js +144 -139
- package/dist/cjs/Header.js +14 -12
- package/dist/cjs/Hero.js +11 -21
- package/dist/cjs/HighlightenVideo.js +18 -17
- package/dist/cjs/HorizontalArticleListing.js +73 -71
- package/dist/cjs/HorizontalHero.js +29 -29
- package/dist/cjs/IssueContentDeck.js +83 -95
- package/dist/cjs/IssueDeck.js +85 -82
- package/dist/cjs/IssueLanding.js +96 -94
- package/dist/cjs/KMTracker.js +15 -15
- package/dist/cjs/LeftNav.js +41 -39
- package/dist/cjs/MasterDeck.js +82 -81
- package/dist/cjs/MediaSeriesLanding.js +1117 -1126
- package/dist/cjs/NavDvm.js +79 -74
- package/dist/cjs/{NavFooter-76c913e3.js → NavFooter-3dcd99a8.js} +15 -14
- package/dist/cjs/NavMagazine.js +152 -147
- package/dist/cjs/NavNative.js +147 -139
- package/dist/cjs/NavNormal.js +52 -47
- package/dist/cjs/OncliveHero.js +23 -24
- package/dist/cjs/OncliveLargeHero.js +79 -79
- package/dist/cjs/PageFilter.js +15 -14
- package/dist/cjs/PartnerDetailListing.js +112 -115
- package/dist/cjs/PdfDownload.js +9 -8
- package/dist/cjs/PopUpModal.js +21 -19
- package/dist/cjs/PubSection.js +43 -41
- package/dist/cjs/PubToc.js +16 -15
- package/dist/cjs/PublicationDeck.js +75 -72
- package/dist/cjs/PublicationLanding.js +139 -138
- package/dist/cjs/QueueDeckExpanded.js +329 -328
- package/dist/cjs/RecentNews.js +23 -25
- package/dist/cjs/RelatedContent.js +56 -58
- package/dist/cjs/RelatedTopicsDropdown.js +32 -29
- package/dist/cjs/RolesDeck.js +32 -27
- package/dist/cjs/Search.js +22 -18
- package/dist/cjs/Segment.js +6 -6
- package/dist/cjs/SeriesListingDeck.js +39 -38
- package/dist/cjs/{SeriesSlider-4abb21b4.js → SeriesSlider-4862d8c4.js} +42 -46
- package/dist/cjs/SetCookie.js +1 -1
- package/dist/cjs/SideFooter.js +39 -38
- package/dist/cjs/SocialIcons.js +10 -9
- package/dist/cjs/{SocialSearchComponent-cea213aa.js → SocialSearchComponent-ecb4f972.js} +40 -36
- package/dist/cjs/SocialShare.js +31 -29
- package/dist/cjs/TaxonomyCard.js +70 -68
- package/dist/cjs/TaxonomyDescription.js +57 -55
- package/dist/cjs/TemplateNormal.js +77 -76
- package/dist/cjs/ThumbnailCard.js +23 -25
- package/dist/cjs/Ustream.js +30 -29
- package/dist/cjs/VerticalHero.js +19 -22
- package/dist/cjs/VideoProgramLandingPage.js +78 -73
- package/dist/cjs/VideoSeriesCard.js +35 -33
- package/dist/cjs/VideoSeriesFilter.js +18 -18
- package/dist/cjs/VideoSeriesLandingPage.js +51 -49
- package/dist/cjs/VideoSeriesListing.js +79 -77
- package/dist/cjs/View.js +272 -269
- package/dist/cjs/YahooHero.js +45 -46
- package/dist/cjs/YoutubeGroup.js +69 -72
- package/dist/cjs/{_is-array-754e012d.js → _is-array-6128bd56.js} +6 -6
- package/dist/cjs/{_iter-detect-60b2f026.js → _iter-detect-55a5657a.js} +8 -8
- package/dist/cjs/{_object-pie-68c5bcbc.js → _object-pie-083f2dd6.js} +4 -4
- package/dist/cjs/{_object-sap-5e74ba08.js → _object-sap-a175b4a9.js} +1 -1
- package/dist/cjs/{_object-to-array-5762f850.js → _object-to-array-8fe5a54f.js} +2 -2
- package/dist/cjs/{_to-object-329a650b.js → _to-object-6de10e57.js} +8 -8
- package/dist/cjs/{asyncToGenerator-140e5f89.js → asyncToGenerator-58c289d9.js} +32 -32
- package/dist/cjs/{brightcove-react-player-loader.es-156bd4d6.js → brightcove-react-player-loader.es-a195642e.js} +11 -9
- package/dist/cjs/{core.get-iterator-method-f62321d4.js → core.get-iterator-method-f474eacc.js} +2 -2
- package/dist/cjs/{debounce-529c8d06.js → debounce-d4a2369b.js} +2 -2
- package/dist/cjs/{define-property-f4d12f4e.js → define-property-c88be878.js} +6 -6
- package/dist/cjs/{defineProperty-55548b25.js → defineProperty-0cb76d99.js} +1 -1
- package/dist/cjs/{entities-310b46ee.js → entities-3f9d0f2f.js} +1 -1
- package/dist/cjs/{eq-bb2843ed.js → eq-5fc26c07.js} +1 -1
- package/dist/cjs/{es6.string.iterator-cc0bbaa4.js → es6.string.iterator-c2573ffd.js} +6 -6
- package/dist/cjs/{extends-0a918631.js → extends-29bdbc6d.js} +7 -7
- package/dist/cjs/faundadb.js +7 -7
- package/dist/cjs/{get-adbb11e3.js → get-5839e5b5.js} +21 -21
- package/dist/cjs/getRelatedArticle.js +425 -12
- package/dist/cjs/getRootDocGroup.js +6 -6
- package/dist/cjs/getSerializers.js +45 -44
- package/dist/cjs/{getTargeting-021d644c.js → getTargeting-be6168ad.js} +12 -12
- package/dist/cjs/getTargeting.js +8 -8
- package/dist/cjs/iconBase-68959171.js +0 -3
- package/dist/cjs/{index-a8c4e3fd.js → index-6741b269.js} +996 -1017
- package/dist/cjs/{index-e2e62963.js → index-8041a4eb.js} +11 -1
- package/dist/cjs/index-bd6c9f56.js +211 -0
- package/dist/cjs/{index-96b3db50.js → index-eadd5035.js} +17 -15
- package/dist/cjs/{index-be0c82be.js → index-efca863c.js} +36 -30
- package/dist/cjs/{index-3294d3bc.js → index-f86bb269.js} +44 -45
- package/dist/cjs/{index-98e01cb9.js → index-fc2f1ca2.js} +13 -12
- package/dist/cjs/{index.es-9110add6.js → index.es-f3e47207.js} +31 -12
- package/dist/cjs/{index.esm-ff47db6f.js → index.esm-05850a2f.js} +5 -12
- package/dist/cjs/{index.esm-66ffa47a.js → index.esm-3b9b8952.js} +4 -9
- package/dist/cjs/{index.esm-4d410430.js → index.esm-8123cf40.js} +20 -20
- package/dist/cjs/{index.esm-90433435.js → index.esm-974f47d9.js} +6 -15
- package/dist/cjs/index.js +167 -177
- package/dist/cjs/{inherits-9953db94.js → inherits-c2065b95.js} +22 -22
- package/dist/cjs/{isSymbol-04666465.js → isSymbol-03abbdf0.js} +15 -15
- package/dist/cjs/keys-7f2c2108.js +25 -0
- package/dist/cjs/{lodash-fc2922d0.js → lodash-f0783643.js} +128 -31
- package/dist/cjs/main-025fdc78.js +973 -0
- package/dist/cjs/{md5-5039b1a6.js → md5-e1ca5797.js} +1 -1
- package/dist/cjs/{moment-575fe24c.js → moment-aca40de1.js} +11 -9
- package/dist/cjs/{react-social-icons-f7f48f71.js → react-social-icons-af932527.js} +28 -27
- package/dist/cjs/{slicedToArray-8f385299.js → slicedToArray-5d1bc3b3.js} +14 -14
- package/dist/cjs/{smoothscroll-5054361f.js → smoothscroll-99df7f93.js} +1 -1
- package/dist/cjs/stringify-c9ac1214.js +17 -0
- package/dist/cjs/timeDifferenceCalc.js +1 -1
- package/dist/cjs/{toConsumableArray-9a3476fe.js → toConsumableArray-ddb70795.js} +9 -9
- package/dist/cjs/{toNumber-36d1e7e5.js → toNumber-5e1fac58.js} +40 -5
- package/dist/cjs/{typeof-725500bc.js → typeof-88a668c5.js} +36 -36
- package/dist/cjs/urlFor.js +27 -3
- package/dist/cjs/{ustream-api-d092dc31.js → ustream-api-b2b9092f.js} +4 -4
- package/dist/cjs/{util-f2c1b65b.js → util-6f784d85.js} +1 -1
- package/dist/cjs/{visibility-sensor-ad5e3116.js → visibility-sensor-eb2c5b69.js} +7 -5
- package/dist/cjs/{web.dom.iterable-a0e279c1.js → web.dom.iterable-46657b5c.js} +3 -3
- package/dist/esm/AD.js +7 -7
- package/dist/esm/AD300x250.js +27 -27
- package/dist/esm/AD300x250x600.js +27 -27
- package/dist/esm/AD728x90.js +30 -30
- package/dist/esm/ADFloatingFooter.js +29 -29
- package/dist/esm/ADFooter.js +11 -11
- package/dist/esm/ADGutter.js +29 -29
- package/dist/esm/{ADInfeed-31055afd.js → ADInfeed-7aaa47e1.js} +11 -11
- package/dist/esm/ADSkyscraper.js +29 -29
- package/dist/esm/ADSponsoredResources.js +29 -29
- package/dist/esm/ADWebcast.js +29 -29
- package/dist/esm/ADWelcome.js +30 -30
- package/dist/esm/{ADlgInfeed-dcb27a6c.js → ADlgInfeed-78f95e78.js} +8 -8
- package/dist/esm/AccordionPanel.js +24 -24
- package/dist/esm/AdSlot.js +27 -27
- package/dist/esm/AdSlotsProvider.js +17 -909
- package/dist/esm/AlgoliaSearch.js +737 -718
- package/dist/esm/AlphabeticList.js +22 -22
- package/dist/esm/ArticleCarousel.js +21 -20
- package/dist/esm/ArticleProgramLandingPage.js +56 -55
- package/dist/esm/ArticleSeriesLandingPage.js +37 -37
- package/dist/esm/ArticleSeriesListing.js +57 -56
- package/dist/esm/Auth.js +665 -645
- package/dist/esm/AuthWrapper.js +308 -267
- package/dist/esm/{AuthorComponent-34b16174.js → AuthorComponent-5ae7409f.js} +11 -11
- package/dist/esm/Beam.js +8 -8
- package/dist/esm/{BlockContent-e9b4ddcf.js → BlockContent-52cf21c5.js} +35 -35
- package/dist/esm/Breadcrumbs.js +17 -17
- package/dist/esm/CMEDeck.js +79 -79
- package/dist/esm/Column1.js +9 -9
- package/dist/esm/Column2.js +30 -30
- package/dist/esm/Column3.js +56 -56
- package/dist/esm/ConferenceArticleCard.js +37 -42
- package/dist/esm/{ConferenceBanner-8792ebd2.js → ConferenceBanner-9162d0ca.js} +4 -4
- package/dist/esm/DeckContent.js +101 -107
- package/dist/esm/DeckQueue.js +86 -93
- package/dist/esm/{Dfp-b7236041.js → Dfp-43f121ff.js} +22 -22
- package/dist/esm/EventsDeck.js +129 -129
- package/dist/esm/ExternalResources.js +75 -74
- package/dist/esm/Feature.js +22 -26
- package/dist/esm/ForbesHero.js +38 -40
- package/dist/esm/GridContent.js +176 -279
- package/dist/esm/GridHero.js +42 -53
- package/dist/esm/GroupDeck.js +49 -53
- package/dist/esm/HamMagazine.js +115 -115
- package/dist/esm/Header.js +8 -8
- package/dist/esm/Hero.js +10 -21
- package/dist/esm/HighlightenVideo.js +14 -14
- package/dist/esm/HorizontalArticleListing.js +69 -68
- package/dist/esm/HorizontalHero.js +25 -26
- package/dist/esm/IssueContentDeck.js +68 -85
- package/dist/esm/IssueDeck.js +73 -75
- package/dist/esm/IssueLanding.js +92 -91
- package/dist/esm/KMTracker.js +15 -15
- package/dist/esm/LeftNav.js +35 -35
- package/dist/esm/MasterDeck.js +78 -78
- package/dist/esm/MediaSeriesLanding.js +841 -853
- package/dist/esm/NavDvm.js +59 -59
- package/dist/esm/{NavFooter-e27bd93b.js → NavFooter-c29526b7.js} +12 -12
- package/dist/esm/NavMagazine.js +126 -126
- package/dist/esm/NavNative.js +116 -116
- package/dist/esm/NavNormal.js +38 -38
- package/dist/esm/OncliveHero.js +20 -22
- package/dist/esm/OncliveLargeHero.js +66 -67
- package/dist/esm/PageFilter.js +12 -12
- package/dist/esm/PartnerDetailListing.js +108 -112
- package/dist/esm/PdfDownload.js +6 -6
- package/dist/esm/PopUpModal.js +14 -14
- package/dist/esm/PubSection.js +39 -38
- package/dist/esm/PubToc.js +12 -12
- package/dist/esm/PublicationDeck.js +61 -63
- package/dist/esm/PublicationLanding.js +122 -125
- package/dist/esm/QueueDeckExpanded.js +288 -287
- package/dist/esm/RecentNews.js +20 -23
- package/dist/esm/RelatedContent.js +49 -52
- package/dist/esm/RelatedTopicsDropdown.js +21 -21
- package/dist/esm/RolesDeck.js +25 -25
- package/dist/esm/Search.js +13 -13
- package/dist/esm/Segment.js +6 -6
- package/dist/esm/SeriesListingDeck.js +33 -32
- package/dist/esm/{SeriesSlider-36be7223.js → SeriesSlider-38cca5eb.js} +32 -37
- package/dist/esm/SetCookie.js +1 -1
- package/dist/esm/SideFooter.js +34 -34
- package/dist/esm/SocialIcons.js +7 -7
- package/dist/esm/{SocialSearchComponent-03c3e869.js → SocialSearchComponent-cd38ae60.js} +30 -30
- package/dist/esm/SocialShare.js +25 -25
- package/dist/esm/TaxonomyCard.js +60 -63
- package/dist/esm/TaxonomyDescription.js +51 -50
- package/dist/esm/TemplateNormal.js +72 -72
- package/dist/esm/ThumbnailCard.js +14 -18
- package/dist/esm/Ustream.js +26 -26
- package/dist/esm/VerticalHero.js +15 -19
- package/dist/esm/VideoProgramLandingPage.js +67 -66
- package/dist/esm/VideoSeriesCard.js +28 -27
- package/dist/esm/VideoSeriesFilter.js +15 -15
- package/dist/esm/VideoSeriesLandingPage.js +42 -41
- package/dist/esm/VideoSeriesListing.js +74 -73
- package/dist/esm/View.js +252 -253
- package/dist/esm/YahooHero.js +38 -40
- package/dist/esm/YoutubeGroup.js +53 -57
- package/dist/esm/{_is-array-58e95429.js → _is-array-3e99e06e.js} +6 -6
- package/dist/esm/{_iter-detect-5d49a330.js → _iter-detect-7e5e5ce2.js} +8 -8
- package/dist/esm/{_object-pie-33c40e79.js → _object-pie-133f504a.js} +4 -4
- package/dist/esm/{_object-sap-964b6feb.js → _object-sap-f353c2a9.js} +1 -1
- package/dist/esm/{_object-to-array-7e804fce.js → _object-to-array-0f197f89.js} +2 -2
- package/dist/esm/{_to-object-a4107da3.js → _to-object-b50e61c3.js} +9 -9
- package/dist/esm/{asyncToGenerator-fc1c2e29.js → asyncToGenerator-7f8f9219.js} +32 -32
- package/dist/esm/{brightcove-react-player-loader.es-83f53e4e.js → brightcove-react-player-loader.es-b43c695a.js} +7 -6
- package/dist/esm/{core.get-iterator-method-e1de7503.js → core.get-iterator-method-133dfacd.js} +2 -2
- package/dist/esm/{debounce-9207d8ee.js → debounce-533d9748.js} +2 -2
- package/dist/esm/{define-property-8af5f002.js → define-property-fe54dc9f.js} +6 -6
- package/dist/esm/{defineProperty-94fd8bfc.js → defineProperty-f5ff6f5a.js} +1 -1
- package/dist/esm/{entities-7cc3bf45.js → entities-932b50cf.js} +1 -1
- package/dist/esm/{eq-b470f743.js → eq-bdcbf886.js} +1 -1
- package/dist/esm/{es6.string.iterator-c990c18c.js → es6.string.iterator-bc33758b.js} +7 -7
- package/dist/esm/{extends-6f2fcc99.js → extends-60e0e1c6.js} +7 -7
- package/dist/esm/faundadb.js +7 -7
- package/dist/esm/{get-1e515072.js → get-3c308da4.js} +21 -21
- package/dist/esm/getRelatedArticle.js +425 -12
- package/dist/esm/getRootDocGroup.js +6 -6
- package/dist/esm/getSerializers.js +45 -44
- package/dist/esm/{getTargeting-82e86707.js → getTargeting-68291ce9.js} +11 -11
- package/dist/esm/getTargeting.js +8 -8
- package/dist/esm/{index-73819142.js → index-0dbff1d1.js} +36 -30
- package/dist/esm/{index-41a678ea.js → index-2446af28.js} +6 -6
- package/dist/esm/{index-5f7e79e7.js → index-35bdcc81.js} +10 -10
- package/dist/esm/{index-aaa2dae0.js → index-67e1773f.js} +11 -2
- package/dist/esm/{index-ef6d5dcf.js → index-79cfd25c.js} +44 -45
- package/dist/esm/{index-782e414a.js → index-c1bcae0f.js} +953 -981
- package/dist/esm/index-db3bb315.js +207 -0
- package/dist/esm/{index.es-29c1cef5.js → index.es-c6222053.js} +28 -10
- package/dist/esm/{index.esm-29e48d38.js → index.esm-3fdda599.js} +6 -15
- package/dist/esm/{index.esm-fd746768.js → index.esm-8016b507.js} +17 -18
- package/dist/esm/{index.esm-cf08bf18.js → index.esm-a8ff922c.js} +5 -12
- package/dist/esm/{index.esm-b08f4b04.js → index.esm-d6f88d94.js} +4 -9
- package/dist/esm/index.js +137 -149
- package/dist/esm/{inherits-cf8dde54.js → inherits-a41fe93f.js} +19 -19
- package/dist/esm/{isSymbol-1981418f.js → isSymbol-a7e9aafe.js} +15 -15
- package/dist/esm/{keys-8eda7a5c.js → keys-7a3adabf.js} +6 -6
- package/dist/esm/{lodash-17fdfebb.js → lodash-f97fd99a.js} +128 -31
- package/dist/esm/main-b5c5aac1.js +961 -0
- package/dist/esm/{md5-9be0e905.js → md5-4e42248e.js} +1 -1
- package/dist/esm/{moment-e2f9b20c.js → moment-bc12cb97.js} +11 -9
- package/dist/esm/{react-social-icons-a7d5c5c7.js → react-social-icons-91f9716f.js} +20 -20
- package/dist/esm/{slicedToArray-641f241f.js → slicedToArray-be2f7a22.js} +14 -14
- package/dist/esm/{smoothscroll-0cd4c7a6.js → smoothscroll-fa4e3f8c.js} +1 -1
- package/dist/esm/stringify-59c8f690.js +15 -0
- package/dist/esm/timeDifferenceCalc.js +1 -1
- package/dist/esm/{toConsumableArray-43aa614d.js → toConsumableArray-6d9a4616.js} +9 -9
- package/dist/esm/{toNumber-2f7a84cd.js → toNumber-5aeba6e7.js} +40 -5
- package/dist/esm/{typeof-6435ba1c.js → typeof-a286cf0c.js} +36 -36
- package/dist/esm/urlFor.js +27 -3
- package/dist/esm/{ustream-api-9a50644d.js → ustream-api-33a866b6.js} +4 -4
- package/dist/esm/{util-7700fc59.js → util-3ab476bf.js} +1 -1
- package/dist/esm/{visibility-sensor-72fd8f8b.js → visibility-sensor-f40c2564.js} +2 -2
- package/dist/esm/{web.dom.iterable-4439f05a.js → web.dom.iterable-4109ff68.js} +3 -3
- package/package.json +110 -110
- package/dist/cjs/ConferenceBanner-4a16fddc.js +0 -23
- package/dist/cjs/keys-a586b7a0.js +0 -25
- package/dist/cjs/main-02daeefe.js +0 -862
- package/dist/cjs/stringify-7c5aff47.js +0 -17
- package/dist/esm/main-e4a934b2.js +0 -851
- package/dist/esm/stringify-4330ccdc.js +0 -15
|
@@ -1,24 +1,25 @@
|
|
|
1
|
-
import './
|
|
2
|
-
import './
|
|
3
|
-
import './
|
|
4
|
-
import '
|
|
5
|
-
import './_object-pie-33c40e79.js';
|
|
6
|
-
import { _ as _extends$1 } from './extends-6f2fcc99.js';
|
|
7
|
-
import './_object-sap-964b6feb.js';
|
|
8
|
-
import { _ as _inherits$1, a as _classCallCheck$1, b as _possibleConstructorReturn$1, c as _Object$getPrototypeOf, d as _createClass$1 } from './inherits-cf8dde54.js';
|
|
9
|
-
import './define-property-8af5f002.js';
|
|
10
|
-
import './web.dom.iterable-4439f05a.js';
|
|
11
|
-
import { _ as _typeof$1 } from './typeof-6435ba1c.js';
|
|
12
|
-
import './_is-array-58e95429.js';
|
|
13
|
-
import React__default, { createContext, Component, Children, version as version$2 } from 'react';
|
|
14
|
-
import { E as EventEmitter } from './events-6c3a7a63.js';
|
|
1
|
+
import { _ as _extends$1 } from './extends-60e0e1c6.js';
|
|
2
|
+
import { _ as _typeof$2 } from './typeof-a286cf0c.js';
|
|
3
|
+
import { _ as _inherits$1, a as _classCallCheck$1, b as _possibleConstructorReturn$1, c as _Object$getPrototypeOf, d as _createClass$1 } from './inherits-a41fe93f.js';
|
|
4
|
+
import React, { createContext, Component, Children, version as version$2 } from 'react';
|
|
15
5
|
import PropTypes from 'prop-types';
|
|
16
|
-
import {
|
|
17
|
-
import '
|
|
18
|
-
import {
|
|
19
|
-
import { L as LazyLoad } from './index-5f7e79e7.js';
|
|
6
|
+
import { c as createCommonjsModule, u as unwrapExports } from './_commonjsHelpers-0c4b6f40.js';
|
|
7
|
+
import { _ as _objectWithoutPropertiesLoose$1, a as _setPrototypeOf, b as _extends, c as classnames } from './index-67e1773f.js';
|
|
8
|
+
import { E as EventEmitter } from './events-6c3a7a63.js';
|
|
20
9
|
import { DropdownButton } from 'react-bootstrap';
|
|
21
|
-
import
|
|
10
|
+
import urlFor from './urlFor.js';
|
|
11
|
+
import { m as moment } from './moment-bc12cb97.js';
|
|
12
|
+
import { L as LazyLoad } from './index-35bdcc81.js';
|
|
13
|
+
import './_to-object-b50e61c3.js';
|
|
14
|
+
import './_object-pie-133f504a.js';
|
|
15
|
+
import './es6.string.iterator-bc33758b.js';
|
|
16
|
+
import './web.dom.iterable-4109ff68.js';
|
|
17
|
+
import './_is-array-3e99e06e.js';
|
|
18
|
+
import './_library-528f1934.js';
|
|
19
|
+
import './_object-sap-f353c2a9.js';
|
|
20
|
+
import './define-property-fe54dc9f.js';
|
|
21
|
+
import './index-0dbff1d1.js';
|
|
22
|
+
import 'react-dom';
|
|
22
23
|
|
|
23
24
|
function _objectWithoutProperties(source, excluded) {
|
|
24
25
|
if (source == null) return {};
|
|
@@ -56,7 +57,7 @@ function _defineProperty(obj, key, value) {
|
|
|
56
57
|
|
|
57
58
|
function _objectSpread(target) {
|
|
58
59
|
for (var i = 1; i < arguments.length; i++) {
|
|
59
|
-
var source = arguments[i] != null ? arguments[i] : {};
|
|
60
|
+
var source = arguments[i] != null ? Object(arguments[i]) : {};
|
|
60
61
|
var ownKeys = Object.keys(source);
|
|
61
62
|
|
|
62
63
|
if (typeof Object.getOwnPropertySymbols === 'function') {
|
|
@@ -95,22 +96,33 @@ function _createClass(Constructor, protoProps, staticProps) {
|
|
|
95
96
|
return Constructor;
|
|
96
97
|
}
|
|
97
98
|
|
|
98
|
-
|
|
99
|
-
|
|
99
|
+
var _typeof_1 = createCommonjsModule(function (module) {
|
|
100
100
|
function _typeof(obj) {
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
101
|
+
"@babel/helpers - typeof";
|
|
102
|
+
|
|
103
|
+
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
|
104
|
+
module.exports = _typeof = function _typeof(obj) {
|
|
105
|
+
return typeof obj;
|
|
104
106
|
};
|
|
107
|
+
|
|
108
|
+
module.exports["default"] = module.exports, module.exports.__esModule = true;
|
|
105
109
|
} else {
|
|
106
|
-
_typeof = function _typeof(obj) {
|
|
107
|
-
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" :
|
|
110
|
+
module.exports = _typeof = function _typeof(obj) {
|
|
111
|
+
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
108
112
|
};
|
|
113
|
+
|
|
114
|
+
module.exports["default"] = module.exports, module.exports.__esModule = true;
|
|
109
115
|
}
|
|
110
116
|
|
|
111
117
|
return _typeof(obj);
|
|
112
118
|
}
|
|
113
119
|
|
|
120
|
+
module.exports = _typeof;
|
|
121
|
+
module.exports["default"] = module.exports, module.exports.__esModule = true;
|
|
122
|
+
});
|
|
123
|
+
|
|
124
|
+
var _typeof$1 = unwrapExports(_typeof_1);
|
|
125
|
+
|
|
114
126
|
function _assertThisInitialized(self) {
|
|
115
127
|
if (self === void 0) {
|
|
116
128
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
@@ -120,7 +132,7 @@ function _assertThisInitialized(self) {
|
|
|
120
132
|
}
|
|
121
133
|
|
|
122
134
|
function _possibleConstructorReturn(self, call) {
|
|
123
|
-
if (call && (_typeof(call) === "object" || typeof call === "function")) {
|
|
135
|
+
if (call && (_typeof$1(call) === "object" || typeof call === "function")) {
|
|
124
136
|
return call;
|
|
125
137
|
}
|
|
126
138
|
|
|
@@ -134,15 +146,6 @@ function _getPrototypeOf(o) {
|
|
|
134
146
|
return _getPrototypeOf(o);
|
|
135
147
|
}
|
|
136
148
|
|
|
137
|
-
function _setPrototypeOf(o, p) {
|
|
138
|
-
_setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
|
|
139
|
-
o.__proto__ = p;
|
|
140
|
-
return o;
|
|
141
|
-
};
|
|
142
|
-
|
|
143
|
-
return _setPrototypeOf(o, p);
|
|
144
|
-
}
|
|
145
|
-
|
|
146
149
|
function _inherits(subClass, superClass) {
|
|
147
150
|
if (typeof superClass !== "function" && superClass !== null) {
|
|
148
151
|
throw new TypeError("Super expression must either be null or a function");
|
|
@@ -293,6 +296,22 @@ var reactFastCompare = function isEqual(a, b) {
|
|
|
293
296
|
}
|
|
294
297
|
};
|
|
295
298
|
|
|
299
|
+
function _typeof(obj) {
|
|
300
|
+
"@babel/helpers - typeof";
|
|
301
|
+
|
|
302
|
+
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
|
303
|
+
_typeof = function _typeof(obj) {
|
|
304
|
+
return typeof obj;
|
|
305
|
+
};
|
|
306
|
+
} else {
|
|
307
|
+
_typeof = function _typeof(obj) {
|
|
308
|
+
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
309
|
+
};
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
return _typeof(obj);
|
|
313
|
+
}
|
|
314
|
+
|
|
296
315
|
// From https://github.com/reactjs/react-redux/blob/master/src/utils/shallowEqual.js
|
|
297
316
|
var shallowEqual = function shallowEqual(objA, objB) {
|
|
298
317
|
if (objA === objB) {
|
|
@@ -337,7 +356,7 @@ var removeEmptyKey = function removeEmptyKey(obj) {
|
|
|
337
356
|
return;
|
|
338
357
|
}
|
|
339
358
|
|
|
340
|
-
if (!objectHasKeys(value)) {
|
|
359
|
+
if (!objectHasKeys$1(value)) {
|
|
341
360
|
delete obj[key];
|
|
342
361
|
} else {
|
|
343
362
|
removeEmptyKey(value);
|
|
@@ -373,7 +392,7 @@ function addQueryID(hits, queryID) {
|
|
|
373
392
|
});
|
|
374
393
|
});
|
|
375
394
|
}
|
|
376
|
-
function find(array, comparator) {
|
|
395
|
+
function find$2(array, comparator) {
|
|
377
396
|
if (!Array.isArray(array)) {
|
|
378
397
|
return undefined;
|
|
379
398
|
}
|
|
@@ -386,11 +405,11 @@ function find(array, comparator) {
|
|
|
386
405
|
|
|
387
406
|
return undefined;
|
|
388
407
|
}
|
|
389
|
-
function objectHasKeys(object) {
|
|
408
|
+
function objectHasKeys$1(object) {
|
|
390
409
|
return object && Object.keys(object).length > 0;
|
|
391
410
|
} // https://github.com/babel/babel/blob/3aaafae053fa75febb3aa45d45b6f00646e30ba4/packages/babel-helpers/src/helpers.js#L604-L620
|
|
392
411
|
|
|
393
|
-
function omit(source, excluded) {
|
|
412
|
+
function omit$1(source, excluded) {
|
|
394
413
|
if (source === null || source === undefined) {
|
|
395
414
|
return {};
|
|
396
415
|
}
|
|
@@ -461,9 +480,9 @@ var instantSearchContext = createContext({
|
|
|
461
480
|
var InstantSearchConsumer = instantSearchContext.Consumer,
|
|
462
481
|
InstantSearchProvider = instantSearchContext.Provider;
|
|
463
482
|
|
|
464
|
-
var _createContext = createContext(undefined),
|
|
465
|
-
IndexConsumer = _createContext.Consumer,
|
|
466
|
-
IndexProvider = _createContext.Provider;
|
|
483
|
+
var _createContext$1 = createContext(undefined),
|
|
484
|
+
IndexConsumer = _createContext$1.Consumer,
|
|
485
|
+
IndexProvider = _createContext$1.Provider;
|
|
467
486
|
|
|
468
487
|
/**
|
|
469
488
|
* Connectors are the HOC used to transform React components
|
|
@@ -676,9 +695,9 @@ function createConnectorWithoutContext(connectorDesc) {
|
|
|
676
695
|
}, {
|
|
677
696
|
key: "render",
|
|
678
697
|
value: function render() {
|
|
679
|
-
var _this$props = this.props
|
|
680
|
-
|
|
681
|
-
props = _objectWithoutProperties(_this$props, ["contextValue"]);
|
|
698
|
+
var _this$props = this.props;
|
|
699
|
+
_this$props.contextValue;
|
|
700
|
+
var props = _objectWithoutProperties(_this$props, ["contextValue"]);
|
|
682
701
|
|
|
683
702
|
var providedProps = this.state.providedProps;
|
|
684
703
|
|
|
@@ -693,7 +712,7 @@ function createConnectorWithoutContext(connectorDesc) {
|
|
|
693
712
|
var searchForFacetValuesProps = typeof connectorDesc.searchForFacetValues === 'function' ? {
|
|
694
713
|
searchForItems: this.searchForFacetValues
|
|
695
714
|
} : {};
|
|
696
|
-
return
|
|
715
|
+
return React.createElement(Composed, _extends({}, props, providedProps, refineProps, searchForFacetValuesProps));
|
|
697
716
|
}
|
|
698
717
|
}]);
|
|
699
718
|
|
|
@@ -715,9 +734,9 @@ var createConnectorWithContext = function createConnectorWithContext(connectorDe
|
|
|
715
734
|
var Connector = createConnectorWithoutContext(connectorDesc)(Composed);
|
|
716
735
|
|
|
717
736
|
var ConnectorWrapper = function ConnectorWrapper(props) {
|
|
718
|
-
return
|
|
719
|
-
return
|
|
720
|
-
return
|
|
737
|
+
return React.createElement(InstantSearchConsumer, null, function (contextValue) {
|
|
738
|
+
return React.createElement(IndexConsumer, null, function (indexContextValue) {
|
|
739
|
+
return React.createElement(Connector, _extends({
|
|
721
740
|
contextValue: contextValue,
|
|
722
741
|
indexContextValue: indexContextValue
|
|
723
742
|
}, props));
|
|
@@ -829,7 +848,7 @@ function parseAlgoliaHit(_ref2) {
|
|
|
829
848
|
});
|
|
830
849
|
}
|
|
831
850
|
|
|
832
|
-
var version = '6.10.3';
|
|
851
|
+
var version$1 = '6.10.3';
|
|
833
852
|
|
|
834
853
|
var withKeysPropType = function withKeysPropType(keys) {
|
|
835
854
|
return function (props, propName, componentName) {
|
|
@@ -890,7 +909,7 @@ function translatable(defaultTranslations) {
|
|
|
890
909
|
_createClass(Translatable, [{
|
|
891
910
|
key: "render",
|
|
892
911
|
value: function render() {
|
|
893
|
-
return
|
|
912
|
+
return React.createElement(Composed, _extends({
|
|
894
913
|
translate: this.translate
|
|
895
914
|
}, this.props));
|
|
896
915
|
}
|
|
@@ -1026,7 +1045,7 @@ function hasRefinements(_ref) {
|
|
|
1026
1045
|
return Object.hasOwnProperty.call(searchState, id);
|
|
1027
1046
|
}
|
|
1028
1047
|
|
|
1029
|
-
function getRefinements(_ref2) {
|
|
1048
|
+
function getRefinements$1(_ref2) {
|
|
1030
1049
|
var multiIndex = _ref2.multiIndex,
|
|
1031
1050
|
indexId = _ref2.indexId,
|
|
1032
1051
|
namespace = _ref2.namespace,
|
|
@@ -1068,7 +1087,7 @@ function getCurrentRefinementValue(props, searchState, context, id, defaultValue
|
|
|
1068
1087
|
var hasRefinementsValue = hasRefinements(args);
|
|
1069
1088
|
|
|
1070
1089
|
if (hasRefinementsValue) {
|
|
1071
|
-
return getRefinements(args);
|
|
1090
|
+
return getRefinements$1(args);
|
|
1072
1091
|
}
|
|
1073
1092
|
|
|
1074
1093
|
if (props.defaultRefinement) {
|
|
@@ -1109,10 +1128,10 @@ function cleanUpValueWithSingleIndex(_ref3) {
|
|
|
1109
1128
|
attribute = _ref3.attribute;
|
|
1110
1129
|
|
|
1111
1130
|
if (namespace) {
|
|
1112
|
-
return _objectSpread({}, searchState, _defineProperty({}, namespace, omit(searchState[namespace], [attribute])));
|
|
1131
|
+
return _objectSpread({}, searchState, _defineProperty({}, namespace, omit$1(searchState[namespace], [attribute])));
|
|
1113
1132
|
}
|
|
1114
1133
|
|
|
1115
|
-
return omit(searchState, [id]);
|
|
1134
|
+
return omit$1(searchState, [id]);
|
|
1116
1135
|
}
|
|
1117
1136
|
|
|
1118
1137
|
function cleanUpValueWithMultiIndex(_ref4) {
|
|
@@ -1125,20 +1144,20 @@ function cleanUpValueWithMultiIndex(_ref4) {
|
|
|
1125
1144
|
|
|
1126
1145
|
if (namespace && indexSearchState) {
|
|
1127
1146
|
return _objectSpread({}, searchState, {
|
|
1128
|
-
indices: _objectSpread({}, searchState.indices, _defineProperty({}, indexId, _objectSpread({}, indexSearchState, _defineProperty({}, namespace, omit(indexSearchState[namespace], [attribute])))))
|
|
1147
|
+
indices: _objectSpread({}, searchState.indices, _defineProperty({}, indexId, _objectSpread({}, indexSearchState, _defineProperty({}, namespace, omit$1(indexSearchState[namespace], [attribute])))))
|
|
1129
1148
|
});
|
|
1130
1149
|
}
|
|
1131
1150
|
|
|
1132
1151
|
if (indexSearchState) {
|
|
1133
1152
|
return _objectSpread({}, searchState, {
|
|
1134
|
-
indices: _objectSpread({}, searchState.indices, _defineProperty({}, indexId, omit(indexSearchState, [id])))
|
|
1153
|
+
indices: _objectSpread({}, searchState.indices, _defineProperty({}, indexId, omit$1(indexSearchState, [id])))
|
|
1135
1154
|
});
|
|
1136
1155
|
}
|
|
1137
1156
|
|
|
1138
1157
|
return searchState;
|
|
1139
1158
|
}
|
|
1140
1159
|
|
|
1141
|
-
function getId() {
|
|
1160
|
+
function getId$f() {
|
|
1142
1161
|
return 'configure';
|
|
1143
1162
|
}
|
|
1144
1163
|
|
|
@@ -1148,20 +1167,20 @@ var connectConfigure = createConnectorWithContext({
|
|
|
1148
1167
|
return {};
|
|
1149
1168
|
},
|
|
1150
1169
|
getSearchParameters: function getSearchParameters(searchParameters, props) {
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
items = _objectWithoutProperties(props, ["children", "contextValue", "indexContextValue"]);
|
|
1170
|
+
props.children;
|
|
1171
|
+
props.contextValue;
|
|
1172
|
+
props.indexContextValue;
|
|
1173
|
+
var items = _objectWithoutProperties(props, ["children", "contextValue", "indexContextValue"]);
|
|
1155
1174
|
|
|
1156
1175
|
return searchParameters.setQueryParameters(items);
|
|
1157
1176
|
},
|
|
1158
1177
|
transitionState: function transitionState(props, prevSearchState, nextSearchState) {
|
|
1159
|
-
var id = getId();
|
|
1178
|
+
var id = getId$f();
|
|
1160
1179
|
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
items = _objectWithoutProperties(props, ["children", "contextValue", "indexContextValue"]);
|
|
1180
|
+
props.children;
|
|
1181
|
+
props.contextValue;
|
|
1182
|
+
props.indexContextValue;
|
|
1183
|
+
var items = _objectWithoutProperties(props, ["children", "contextValue", "indexContextValue"]);
|
|
1165
1184
|
|
|
1166
1185
|
var propKeys = Object.keys(props);
|
|
1167
1186
|
var nonPresentKeys = this._props ? Object.keys(this._props).filter(function (prop) {
|
|
@@ -1169,7 +1188,7 @@ var connectConfigure = createConnectorWithContext({
|
|
|
1169
1188
|
}) : [];
|
|
1170
1189
|
this._props = props;
|
|
1171
1190
|
|
|
1172
|
-
var nextValue = _defineProperty({}, id, _objectSpread({}, omit(nextSearchState[id], nonPresentKeys), items));
|
|
1191
|
+
var nextValue = _defineProperty({}, id, _objectSpread({}, omit$1(nextSearchState[id], nonPresentKeys), items));
|
|
1173
1192
|
|
|
1174
1193
|
return refineValue(nextSearchState, nextValue, {
|
|
1175
1194
|
ais: props.contextValue,
|
|
@@ -1177,7 +1196,7 @@ var connectConfigure = createConnectorWithContext({
|
|
|
1177
1196
|
});
|
|
1178
1197
|
},
|
|
1179
1198
|
cleanUp: function cleanUp(props, searchState) {
|
|
1180
|
-
var id = getId();
|
|
1199
|
+
var id = getId$f();
|
|
1181
1200
|
var indexId = getIndexId({
|
|
1182
1201
|
ais: props.contextValue,
|
|
1183
1202
|
multiIndexContext: props.indexContextValue
|
|
@@ -1243,26 +1262,39 @@ var Configure = connectConfigure(function Configure() {
|
|
|
1243
1262
|
return null;
|
|
1244
1263
|
});
|
|
1245
1264
|
|
|
1246
|
-
function
|
|
1247
|
-
if (
|
|
1248
|
-
for (var i = 0, arr2 = new Array(arr.length); i < arr.length; i++) {
|
|
1249
|
-
arr2[i] = arr[i];
|
|
1250
|
-
}
|
|
1265
|
+
function _arrayLikeToArray(arr, len) {
|
|
1266
|
+
if (len == null || len > arr.length) len = arr.length;
|
|
1251
1267
|
|
|
1252
|
-
|
|
1268
|
+
for (var i = 0, arr2 = new Array(len); i < len; i++) {
|
|
1269
|
+
arr2[i] = arr[i];
|
|
1253
1270
|
}
|
|
1271
|
+
|
|
1272
|
+
return arr2;
|
|
1273
|
+
}
|
|
1274
|
+
|
|
1275
|
+
function _arrayWithoutHoles(arr) {
|
|
1276
|
+
if (Array.isArray(arr)) return _arrayLikeToArray(arr);
|
|
1254
1277
|
}
|
|
1255
1278
|
|
|
1256
1279
|
function _iterableToArray(iter) {
|
|
1257
|
-
if (Symbol.iterator in Object(iter)
|
|
1280
|
+
if (typeof Symbol !== "undefined" && Symbol.iterator in Object(iter)) return Array.from(iter);
|
|
1281
|
+
}
|
|
1282
|
+
|
|
1283
|
+
function _unsupportedIterableToArray(o, minLen) {
|
|
1284
|
+
if (!o) return;
|
|
1285
|
+
if (typeof o === "string") return _arrayLikeToArray(o, minLen);
|
|
1286
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
1287
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
1288
|
+
if (n === "Map" || n === "Set") return Array.from(o);
|
|
1289
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
|
|
1258
1290
|
}
|
|
1259
1291
|
|
|
1260
1292
|
function _nonIterableSpread() {
|
|
1261
|
-
throw new TypeError("Invalid attempt to spread non-iterable instance");
|
|
1293
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
1262
1294
|
}
|
|
1263
1295
|
|
|
1264
1296
|
function _toConsumableArray(arr) {
|
|
1265
|
-
return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread();
|
|
1297
|
+
return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
|
|
1266
1298
|
}
|
|
1267
1299
|
|
|
1268
1300
|
function clone(value) {
|
|
@@ -1412,13 +1444,13 @@ function _objectWithoutPropertiesLoose(source, excluded) {
|
|
|
1412
1444
|
return target;
|
|
1413
1445
|
}
|
|
1414
1446
|
|
|
1415
|
-
var omit
|
|
1447
|
+
var omit = _objectWithoutPropertiesLoose;
|
|
1416
1448
|
|
|
1417
|
-
function objectHasKeys
|
|
1449
|
+
function objectHasKeys(obj) {
|
|
1418
1450
|
return obj && Object.keys(obj).length > 0;
|
|
1419
1451
|
}
|
|
1420
1452
|
|
|
1421
|
-
var objectHasKeys_1 = objectHasKeys
|
|
1453
|
+
var objectHasKeys_1 = objectHasKeys;
|
|
1422
1454
|
|
|
1423
1455
|
var isValidUserToken = function isValidUserToken(userToken) {
|
|
1424
1456
|
if (userToken === null) {
|
|
@@ -1526,7 +1558,7 @@ var lib = {
|
|
|
1526
1558
|
}
|
|
1527
1559
|
return {};
|
|
1528
1560
|
} else if (typeof attribute === 'string') {
|
|
1529
|
-
return omit
|
|
1561
|
+
return omit(refinementList, [attribute]);
|
|
1530
1562
|
} else if (typeof attribute === 'function') {
|
|
1531
1563
|
var hasChanged = false;
|
|
1532
1564
|
|
|
@@ -1571,7 +1603,7 @@ var lib = {
|
|
|
1571
1603
|
}
|
|
1572
1604
|
};
|
|
1573
1605
|
|
|
1574
|
-
var RefinementList = lib;
|
|
1606
|
+
var RefinementList$3 = lib;
|
|
1575
1607
|
|
|
1576
1608
|
/**
|
|
1577
1609
|
* isEqual, but only for numeric refinement values, possible values:
|
|
@@ -1940,22 +1972,22 @@ SearchParameters.prototype = {
|
|
|
1940
1972
|
clearRefinements: function clearRefinements(attribute) {
|
|
1941
1973
|
var patch = {
|
|
1942
1974
|
numericRefinements: this._clearNumericRefinements(attribute),
|
|
1943
|
-
facetsRefinements: RefinementList.clearRefinement(
|
|
1975
|
+
facetsRefinements: RefinementList$3.clearRefinement(
|
|
1944
1976
|
this.facetsRefinements,
|
|
1945
1977
|
attribute,
|
|
1946
1978
|
'conjunctiveFacet'
|
|
1947
1979
|
),
|
|
1948
|
-
facetsExcludes: RefinementList.clearRefinement(
|
|
1980
|
+
facetsExcludes: RefinementList$3.clearRefinement(
|
|
1949
1981
|
this.facetsExcludes,
|
|
1950
1982
|
attribute,
|
|
1951
1983
|
'exclude'
|
|
1952
1984
|
),
|
|
1953
|
-
disjunctiveFacetsRefinements: RefinementList.clearRefinement(
|
|
1985
|
+
disjunctiveFacetsRefinements: RefinementList$3.clearRefinement(
|
|
1954
1986
|
this.disjunctiveFacetsRefinements,
|
|
1955
1987
|
attribute,
|
|
1956
1988
|
'disjunctiveFacet'
|
|
1957
1989
|
),
|
|
1958
|
-
hierarchicalFacetsRefinements: RefinementList.clearRefinement(
|
|
1990
|
+
hierarchicalFacetsRefinements: RefinementList$3.clearRefinement(
|
|
1959
1991
|
this.hierarchicalFacetsRefinements,
|
|
1960
1992
|
attribute,
|
|
1961
1993
|
'hierarchicalFacet'
|
|
@@ -2231,7 +2263,7 @@ SearchParameters.prototype = {
|
|
|
2231
2263
|
}
|
|
2232
2264
|
return {};
|
|
2233
2265
|
} else if (typeof attribute === 'string') {
|
|
2234
|
-
return omit
|
|
2266
|
+
return omit(this.numericRefinements, [attribute]);
|
|
2235
2267
|
} else if (typeof attribute === 'function') {
|
|
2236
2268
|
var hasChanged = false;
|
|
2237
2269
|
var numericRefinements = this.numericRefinements;
|
|
@@ -2323,10 +2355,10 @@ SearchParameters.prototype = {
|
|
|
2323
2355
|
if (!this.isConjunctiveFacet(facet)) {
|
|
2324
2356
|
throw new Error(facet + ' is not defined in the facets attribute of the helper configuration');
|
|
2325
2357
|
}
|
|
2326
|
-
if (RefinementList.isRefined(this.facetsRefinements, facet, value)) return this;
|
|
2358
|
+
if (RefinementList$3.isRefined(this.facetsRefinements, facet, value)) return this;
|
|
2327
2359
|
|
|
2328
2360
|
return this.setQueryParameters({
|
|
2329
|
-
facetsRefinements: RefinementList.addRefinement(this.facetsRefinements, facet, value)
|
|
2361
|
+
facetsRefinements: RefinementList$3.addRefinement(this.facetsRefinements, facet, value)
|
|
2330
2362
|
});
|
|
2331
2363
|
},
|
|
2332
2364
|
/**
|
|
@@ -2340,10 +2372,10 @@ SearchParameters.prototype = {
|
|
|
2340
2372
|
if (!this.isConjunctiveFacet(facet)) {
|
|
2341
2373
|
throw new Error(facet + ' is not defined in the facets attribute of the helper configuration');
|
|
2342
2374
|
}
|
|
2343
|
-
if (RefinementList.isRefined(this.facetsExcludes, facet, value)) return this;
|
|
2375
|
+
if (RefinementList$3.isRefined(this.facetsExcludes, facet, value)) return this;
|
|
2344
2376
|
|
|
2345
2377
|
return this.setQueryParameters({
|
|
2346
|
-
facetsExcludes: RefinementList.addRefinement(this.facetsExcludes, facet, value)
|
|
2378
|
+
facetsExcludes: RefinementList$3.addRefinement(this.facetsExcludes, facet, value)
|
|
2347
2379
|
});
|
|
2348
2380
|
},
|
|
2349
2381
|
/**
|
|
@@ -2359,10 +2391,10 @@ SearchParameters.prototype = {
|
|
|
2359
2391
|
facet + ' is not defined in the disjunctiveFacets attribute of the helper configuration');
|
|
2360
2392
|
}
|
|
2361
2393
|
|
|
2362
|
-
if (RefinementList.isRefined(this.disjunctiveFacetsRefinements, facet, value)) return this;
|
|
2394
|
+
if (RefinementList$3.isRefined(this.disjunctiveFacetsRefinements, facet, value)) return this;
|
|
2363
2395
|
|
|
2364
2396
|
return this.setQueryParameters({
|
|
2365
|
-
disjunctiveFacetsRefinements: RefinementList.addRefinement(
|
|
2397
|
+
disjunctiveFacetsRefinements: RefinementList$3.addRefinement(
|
|
2366
2398
|
this.disjunctiveFacetsRefinements, facet, value)
|
|
2367
2399
|
});
|
|
2368
2400
|
},
|
|
@@ -2447,10 +2479,10 @@ SearchParameters.prototype = {
|
|
|
2447
2479
|
if (!this.isConjunctiveFacet(facet)) {
|
|
2448
2480
|
throw new Error(facet + ' is not defined in the facets attribute of the helper configuration');
|
|
2449
2481
|
}
|
|
2450
|
-
if (!RefinementList.isRefined(this.facetsRefinements, facet, value)) return this;
|
|
2482
|
+
if (!RefinementList$3.isRefined(this.facetsRefinements, facet, value)) return this;
|
|
2451
2483
|
|
|
2452
2484
|
return this.setQueryParameters({
|
|
2453
|
-
facetsRefinements: RefinementList.removeRefinement(this.facetsRefinements, facet, value)
|
|
2485
|
+
facetsRefinements: RefinementList$3.removeRefinement(this.facetsRefinements, facet, value)
|
|
2454
2486
|
});
|
|
2455
2487
|
},
|
|
2456
2488
|
/**
|
|
@@ -2464,10 +2496,10 @@ SearchParameters.prototype = {
|
|
|
2464
2496
|
if (!this.isConjunctiveFacet(facet)) {
|
|
2465
2497
|
throw new Error(facet + ' is not defined in the facets attribute of the helper configuration');
|
|
2466
2498
|
}
|
|
2467
|
-
if (!RefinementList.isRefined(this.facetsExcludes, facet, value)) return this;
|
|
2499
|
+
if (!RefinementList$3.isRefined(this.facetsExcludes, facet, value)) return this;
|
|
2468
2500
|
|
|
2469
2501
|
return this.setQueryParameters({
|
|
2470
|
-
facetsExcludes: RefinementList.removeRefinement(this.facetsExcludes, facet, value)
|
|
2502
|
+
facetsExcludes: RefinementList$3.removeRefinement(this.facetsExcludes, facet, value)
|
|
2471
2503
|
});
|
|
2472
2504
|
},
|
|
2473
2505
|
/**
|
|
@@ -2482,10 +2514,10 @@ SearchParameters.prototype = {
|
|
|
2482
2514
|
throw new Error(
|
|
2483
2515
|
facet + ' is not defined in the disjunctiveFacets attribute of the helper configuration');
|
|
2484
2516
|
}
|
|
2485
|
-
if (!RefinementList.isRefined(this.disjunctiveFacetsRefinements, facet, value)) return this;
|
|
2517
|
+
if (!RefinementList$3.isRefined(this.disjunctiveFacetsRefinements, facet, value)) return this;
|
|
2486
2518
|
|
|
2487
2519
|
return this.setQueryParameters({
|
|
2488
|
-
disjunctiveFacetsRefinements: RefinementList.removeRefinement(
|
|
2520
|
+
disjunctiveFacetsRefinements: RefinementList$3.removeRefinement(
|
|
2489
2521
|
this.disjunctiveFacetsRefinements, facet, value)
|
|
2490
2522
|
});
|
|
2491
2523
|
},
|
|
@@ -2551,7 +2583,7 @@ SearchParameters.prototype = {
|
|
|
2551
2583
|
}
|
|
2552
2584
|
|
|
2553
2585
|
return this.setQueryParameters({
|
|
2554
|
-
facetsRefinements: RefinementList.toggleRefinement(this.facetsRefinements, facet, value)
|
|
2586
|
+
facetsRefinements: RefinementList$3.toggleRefinement(this.facetsRefinements, facet, value)
|
|
2555
2587
|
});
|
|
2556
2588
|
},
|
|
2557
2589
|
/**
|
|
@@ -2567,7 +2599,7 @@ SearchParameters.prototype = {
|
|
|
2567
2599
|
}
|
|
2568
2600
|
|
|
2569
2601
|
return this.setQueryParameters({
|
|
2570
|
-
facetsExcludes: RefinementList.toggleRefinement(this.facetsExcludes, facet, value)
|
|
2602
|
+
facetsExcludes: RefinementList$3.toggleRefinement(this.facetsExcludes, facet, value)
|
|
2571
2603
|
});
|
|
2572
2604
|
},
|
|
2573
2605
|
/**
|
|
@@ -2584,7 +2616,7 @@ SearchParameters.prototype = {
|
|
|
2584
2616
|
}
|
|
2585
2617
|
|
|
2586
2618
|
return this.setQueryParameters({
|
|
2587
|
-
disjunctiveFacetsRefinements: RefinementList.toggleRefinement(
|
|
2619
|
+
disjunctiveFacetsRefinements: RefinementList$3.toggleRefinement(
|
|
2588
2620
|
this.disjunctiveFacetsRefinements, facet, value)
|
|
2589
2621
|
});
|
|
2590
2622
|
},
|
|
@@ -2723,7 +2755,7 @@ SearchParameters.prototype = {
|
|
|
2723
2755
|
if (!this.isConjunctiveFacet(facet)) {
|
|
2724
2756
|
return false;
|
|
2725
2757
|
}
|
|
2726
|
-
return RefinementList.isRefined(this.facetsRefinements, facet, value);
|
|
2758
|
+
return RefinementList$3.isRefined(this.facetsRefinements, facet, value);
|
|
2727
2759
|
},
|
|
2728
2760
|
/**
|
|
2729
2761
|
* Returns true if the facet contains exclusions or if a specific value is
|
|
@@ -2739,7 +2771,7 @@ SearchParameters.prototype = {
|
|
|
2739
2771
|
if (!this.isConjunctiveFacet(facet)) {
|
|
2740
2772
|
return false;
|
|
2741
2773
|
}
|
|
2742
|
-
return RefinementList.isRefined(this.facetsExcludes, facet, value);
|
|
2774
|
+
return RefinementList$3.isRefined(this.facetsExcludes, facet, value);
|
|
2743
2775
|
},
|
|
2744
2776
|
/**
|
|
2745
2777
|
* Returns true if the facet contains a refinement, or if a value passed is a
|
|
@@ -2754,7 +2786,7 @@ SearchParameters.prototype = {
|
|
|
2754
2786
|
if (!this.isDisjunctiveFacet(facet)) {
|
|
2755
2787
|
return false;
|
|
2756
2788
|
}
|
|
2757
|
-
return RefinementList.isRefined(this.disjunctiveFacetsRefinements, facet, value);
|
|
2789
|
+
return RefinementList$3.isRefined(this.disjunctiveFacetsRefinements, facet, value);
|
|
2758
2790
|
},
|
|
2759
2791
|
/**
|
|
2760
2792
|
* Returns true if the facet contains a refinement, or if a value passed is a
|
|
@@ -2940,7 +2972,7 @@ SearchParameters.prototype = {
|
|
|
2940
2972
|
var isNextValueDefined = nextWithNumbers[key] !== undefined;
|
|
2941
2973
|
|
|
2942
2974
|
if (isPreviousValueDefined && !isNextValueDefined) {
|
|
2943
|
-
return omit
|
|
2975
|
+
return omit(previous, [key]);
|
|
2944
2976
|
}
|
|
2945
2977
|
|
|
2946
2978
|
if (isNextValueDefined) {
|
|
@@ -4673,7 +4705,7 @@ var requestBuilder = {
|
|
|
4673
4705
|
|
|
4674
4706
|
var requestBuilder_1 = requestBuilder;
|
|
4675
4707
|
|
|
4676
|
-
var version
|
|
4708
|
+
var version = '3.4.4';
|
|
4677
4709
|
|
|
4678
4710
|
/**
|
|
4679
4711
|
* Event triggered when a parameter is set or updated
|
|
@@ -4780,7 +4812,7 @@ var version$1 = '3.4.4';
|
|
|
4780
4812
|
*/
|
|
4781
4813
|
function AlgoliaSearchHelper(client, index, options) {
|
|
4782
4814
|
if (typeof client.addAlgoliaAgent === 'function') {
|
|
4783
|
-
client.addAlgoliaAgent('JS Helper (' + version
|
|
4815
|
+
client.addAlgoliaAgent('JS Helper (' + version + ')');
|
|
4784
4816
|
}
|
|
4785
4817
|
|
|
4786
4818
|
this.setClient(client);
|
|
@@ -4935,7 +4967,7 @@ AlgoliaSearchHelper.prototype.findAnswers = function(options) {
|
|
|
4935
4967
|
nbHits: options.nbHits
|
|
4936
4968
|
},
|
|
4937
4969
|
{
|
|
4938
|
-
params: omit
|
|
4970
|
+
params: omit(requestBuilder_1._getHitsSearchParams(derivedState), [
|
|
4939
4971
|
'attributesToSnippet',
|
|
4940
4972
|
'hitsPerPage',
|
|
4941
4973
|
'restrictSearchableAttributes',
|
|
@@ -6049,7 +6081,7 @@ AlgoliaSearchHelper.prototype.setClient = function(newClient) {
|
|
|
6049
6081
|
if (this.client === newClient) return this;
|
|
6050
6082
|
|
|
6051
6083
|
if (typeof newClient.addAlgoliaAgent === 'function') {
|
|
6052
|
-
newClient.addAlgoliaAgent('JS Helper (' + version
|
|
6084
|
+
newClient.addAlgoliaAgent('JS Helper (' + version + ')');
|
|
6053
6085
|
}
|
|
6054
6086
|
this.client = newClient;
|
|
6055
6087
|
|
|
@@ -6168,7 +6200,7 @@ function algoliasearchHelper(client, index, opts) {
|
|
|
6168
6200
|
* @member module:algoliasearchHelper.version
|
|
6169
6201
|
* @type {number}
|
|
6170
6202
|
*/
|
|
6171
|
-
algoliasearchHelper.version = version
|
|
6203
|
+
algoliasearchHelper.version = version;
|
|
6172
6204
|
|
|
6173
6205
|
/**
|
|
6174
6206
|
* Constructor for the Helper.
|
|
@@ -6200,13 +6232,13 @@ function createOptionalFilter(_ref) {
|
|
|
6200
6232
|
return "".concat(attributeName, ":").concat(attributeValue, "<score=").concat(attributeScore || 1, ">");
|
|
6201
6233
|
}
|
|
6202
6234
|
|
|
6203
|
-
var defaultProps = {
|
|
6235
|
+
var defaultProps$1 = {
|
|
6204
6236
|
transformSearchParameters: function transformSearchParameters(x) {
|
|
6205
6237
|
return _objectSpread({}, x);
|
|
6206
6238
|
}
|
|
6207
6239
|
};
|
|
6208
6240
|
|
|
6209
|
-
function getId$
|
|
6241
|
+
function getId$e() {
|
|
6210
6242
|
// We store the search state of this widget in `configure`.
|
|
6211
6243
|
return 'configure';
|
|
6212
6244
|
}
|
|
@@ -6254,7 +6286,7 @@ function getSearchParametersFromProps(props) {
|
|
|
6254
6286
|
|
|
6255
6287
|
var connectConfigureRelatedItems = createConnectorWithContext({
|
|
6256
6288
|
displayName: 'AlgoliaConfigureRelatedItems',
|
|
6257
|
-
defaultProps: defaultProps,
|
|
6289
|
+
defaultProps: defaultProps$1,
|
|
6258
6290
|
getProvidedProps: function getProvidedProps() {
|
|
6259
6291
|
return {};
|
|
6260
6292
|
},
|
|
@@ -6262,7 +6294,7 @@ var connectConfigureRelatedItems = createConnectorWithContext({
|
|
|
6262
6294
|
return searchParameters.setQueryParameters(getSearchParametersFromProps(props));
|
|
6263
6295
|
},
|
|
6264
6296
|
transitionState: function transitionState(props, _prevSearchState, nextSearchState) {
|
|
6265
|
-
var id = getId$
|
|
6297
|
+
var id = getId$e(); // We need to transform the exhaustive search parameters back to clean
|
|
6266
6298
|
// search parameters without the empty default keys so we don't pollute the
|
|
6267
6299
|
// `configure` search state.
|
|
6268
6300
|
|
|
@@ -6273,7 +6305,7 @@ var connectConfigureRelatedItems = createConnectorWithContext({
|
|
|
6273
6305
|
}) : [];
|
|
6274
6306
|
this._searchParameters = searchParameters;
|
|
6275
6307
|
|
|
6276
|
-
var nextValue = _defineProperty({}, id, _objectSpread({}, omit(nextSearchState[id], nonPresentKeys), searchParameters));
|
|
6308
|
+
var nextValue = _defineProperty({}, id, _objectSpread({}, omit$1(nextSearchState[id], nonPresentKeys), searchParameters));
|
|
6277
6309
|
|
|
6278
6310
|
return refineValue(nextSearchState, nextValue, {
|
|
6279
6311
|
ais: props.contextValue,
|
|
@@ -6283,7 +6315,7 @@ var connectConfigureRelatedItems = createConnectorWithContext({
|
|
|
6283
6315
|
cleanUp: function cleanUp(props, searchState) {
|
|
6284
6316
|
var _this = this;
|
|
6285
6317
|
|
|
6286
|
-
var id = getId$
|
|
6318
|
+
var id = getId$e();
|
|
6287
6319
|
var indexId = getIndexId({
|
|
6288
6320
|
ais: props.contextValue,
|
|
6289
6321
|
multiIndexContext: props.indexContextValue
|
|
@@ -6356,7 +6388,7 @@ function getWidgetRefinements(attribute, widgetKey, searchState) {
|
|
|
6356
6388
|
}
|
|
6357
6389
|
}
|
|
6358
6390
|
|
|
6359
|
-
function getRefinements
|
|
6391
|
+
function getRefinements(attribute) {
|
|
6360
6392
|
var searchState = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
6361
6393
|
var refinements = Object.keys(searchState).filter(function (widgetKey) {
|
|
6362
6394
|
return searchState[widgetKey] !== undefined && searchState[widgetKey][attribute] !== undefined;
|
|
@@ -6373,7 +6405,7 @@ function getRuleContextsFromTrackedFilters(_ref) {
|
|
|
6373
6405
|
var searchState = _ref.searchState,
|
|
6374
6406
|
trackedFilters = _ref.trackedFilters;
|
|
6375
6407
|
var ruleContexts = Object.keys(trackedFilters).reduce(function (facets, facetName) {
|
|
6376
|
-
var facetRefinements = getRefinements
|
|
6408
|
+
var facetRefinements = getRefinements(facetName, searchState);
|
|
6377
6409
|
var getTrackedFacetValues = trackedFilters[facetName];
|
|
6378
6410
|
var trackedFacetValues = getTrackedFacetValues(facetRefinements);
|
|
6379
6411
|
return [].concat(_toConsumableArray(facets), _toConsumableArray(facetRefinements.filter(function (facetRefinement) {
|
|
@@ -6385,7 +6417,7 @@ function getRuleContextsFromTrackedFilters(_ref) {
|
|
|
6385
6417
|
return ruleContexts;
|
|
6386
6418
|
}
|
|
6387
6419
|
|
|
6388
|
-
var defaultProps
|
|
6420
|
+
var defaultProps = {
|
|
6389
6421
|
transformItems: function transformItems(items) {
|
|
6390
6422
|
return items;
|
|
6391
6423
|
},
|
|
@@ -6396,7 +6428,7 @@ var defaultProps$1 = {
|
|
|
6396
6428
|
};
|
|
6397
6429
|
var connectQueryRules = createConnectorWithContext({
|
|
6398
6430
|
displayName: 'AlgoliaQueryRules',
|
|
6399
|
-
defaultProps: defaultProps
|
|
6431
|
+
defaultProps: defaultProps,
|
|
6400
6432
|
getProvidedProps: function getProvidedProps(props, _1, searchResults) {
|
|
6401
6433
|
var results = getResults(searchResults, {
|
|
6402
6434
|
ais: props.contextValue,
|
|
@@ -6558,7 +6590,7 @@ function (_Component) {
|
|
|
6558
6590
|
return null;
|
|
6559
6591
|
}
|
|
6560
6592
|
|
|
6561
|
-
return
|
|
6593
|
+
return React.createElement(IndexProvider, {
|
|
6562
6594
|
value: this.state.indexContext
|
|
6563
6595
|
}, this.props.children);
|
|
6564
6596
|
}
|
|
@@ -6573,20 +6605,10 @@ _defineProperty(Index, "propTypes", {
|
|
|
6573
6605
|
children: PropTypes.node
|
|
6574
6606
|
});
|
|
6575
6607
|
|
|
6576
|
-
|
|
6577
|
-
var inferredIndexId = props.indexName;
|
|
6578
|
-
return React__default.createElement(InstantSearchConsumer, null, function (contextValue) {
|
|
6579
|
-
return React__default.createElement(Index, _extends({
|
|
6580
|
-
contextValue: contextValue,
|
|
6581
|
-
indexId: inferredIndexId
|
|
6582
|
-
}, props));
|
|
6583
|
-
});
|
|
6584
|
-
};
|
|
6585
|
-
|
|
6586
|
-
IndexWrapper.propTypes = {
|
|
6608
|
+
({
|
|
6587
6609
|
indexName: PropTypes.string.isRequired,
|
|
6588
6610
|
indexId: PropTypes.string
|
|
6589
|
-
};
|
|
6611
|
+
});
|
|
6590
6612
|
|
|
6591
6613
|
function createWidgetsManager(onWidgetsUpdate) {
|
|
6592
6614
|
var widgets = []; // Is an update scheduled?
|
|
@@ -6647,7 +6669,7 @@ function createStore(initialState) {
|
|
|
6647
6669
|
function addAlgoliaAgents(searchClient) {
|
|
6648
6670
|
if (typeof searchClient.addAlgoliaAgent === 'function') {
|
|
6649
6671
|
searchClient.addAlgoliaAgent("react (".concat(version$2, ")"));
|
|
6650
|
-
searchClient.addAlgoliaAgent("react-instantsearch (".concat(version, ")"));
|
|
6672
|
+
searchClient.addAlgoliaAgent("react-instantsearch (".concat(version$1, ")"));
|
|
6651
6673
|
}
|
|
6652
6674
|
}
|
|
6653
6675
|
|
|
@@ -6885,8 +6907,8 @@ function createInstantSearchManager(_ref) {
|
|
|
6885
6907
|
nextIsSearchStalled = false;
|
|
6886
6908
|
}
|
|
6887
6909
|
|
|
6888
|
-
|
|
6889
|
-
partialState = _objectWithoutProperties(currentState, ["resultsFacetValues"]);
|
|
6910
|
+
currentState.resultsFacetValues;
|
|
6911
|
+
var partialState = _objectWithoutProperties(currentState, ["resultsFacetValues"]);
|
|
6890
6912
|
|
|
6891
6913
|
store.setState(_objectSpread({}, partialState, {
|
|
6892
6914
|
results: results,
|
|
@@ -6907,8 +6929,8 @@ function createInstantSearchManager(_ref) {
|
|
|
6907
6929
|
nextIsSearchStalled = false;
|
|
6908
6930
|
}
|
|
6909
6931
|
|
|
6910
|
-
|
|
6911
|
-
partialState = _objectWithoutProperties(currentState, ["resultsFacetValues"]);
|
|
6932
|
+
currentState.resultsFacetValues;
|
|
6933
|
+
var partialState = _objectWithoutProperties(currentState, ["resultsFacetValues"]);
|
|
6912
6934
|
|
|
6913
6935
|
store.setState(_objectSpread({}, partialState, {
|
|
6914
6936
|
isSearchStalled: nextIsSearchStalled,
|
|
@@ -6920,9 +6942,9 @@ function createInstantSearchManager(_ref) {
|
|
|
6920
6942
|
function handleNewSearch() {
|
|
6921
6943
|
if (!stalledSearchTimer) {
|
|
6922
6944
|
stalledSearchTimer = setTimeout(function () {
|
|
6923
|
-
var _store$getState = store.getState()
|
|
6924
|
-
|
|
6925
|
-
partialState = _objectWithoutProperties(_store$getState, ["resultsFacetValues"]);
|
|
6945
|
+
var _store$getState = store.getState();
|
|
6946
|
+
_store$getState.resultsFacetValues;
|
|
6947
|
+
var partialState = _objectWithoutProperties(_store$getState, ["resultsFacetValues"]);
|
|
6926
6948
|
|
|
6927
6949
|
store.setState(_objectSpread({}, partialState, {
|
|
6928
6950
|
isSearchStalled: true
|
|
@@ -7387,7 +7409,7 @@ function (_Component) {
|
|
|
7387
7409
|
return null;
|
|
7388
7410
|
}
|
|
7389
7411
|
|
|
7390
|
-
return
|
|
7412
|
+
return React.createElement(InstantSearchProvider, {
|
|
7391
7413
|
value: this.state.contextValue
|
|
7392
7414
|
}, this.props.children);
|
|
7393
7415
|
}
|
|
@@ -7421,21 +7443,21 @@ _defineProperty(InstantSearch, "propTypes", {
|
|
|
7421
7443
|
stalledSearchDelay: PropTypes.number
|
|
7422
7444
|
});
|
|
7423
7445
|
|
|
7424
|
-
var getId$
|
|
7446
|
+
var getId$d = function getId(props) {
|
|
7425
7447
|
return props.attributes[0];
|
|
7426
7448
|
};
|
|
7427
|
-
var namespace = 'hierarchicalMenu';
|
|
7449
|
+
var namespace$6 = 'hierarchicalMenu';
|
|
7428
7450
|
|
|
7429
|
-
function _refine(props, searchState, nextRefinement, context) {
|
|
7430
|
-
var id = getId$
|
|
7451
|
+
function _refine$9(props, searchState, nextRefinement, context) {
|
|
7452
|
+
var id = getId$d(props);
|
|
7431
7453
|
|
|
7432
7454
|
var nextValue = _defineProperty({}, id, nextRefinement || '');
|
|
7433
7455
|
|
|
7434
7456
|
var resetPage = true;
|
|
7435
|
-
return refineValue(searchState, nextValue, context, resetPage, namespace);
|
|
7457
|
+
return refineValue(searchState, nextValue, context, resetPage, namespace$6);
|
|
7436
7458
|
}
|
|
7437
7459
|
|
|
7438
|
-
function transformValue(values) {
|
|
7460
|
+
function transformValue$1(values) {
|
|
7439
7461
|
return values.reduce(function (acc, item) {
|
|
7440
7462
|
if (item.isRefined) {
|
|
7441
7463
|
acc.push({
|
|
@@ -7446,7 +7468,7 @@ function transformValue(values) {
|
|
|
7446
7468
|
}); // Create a variable in order to keep the same acc for the recursion, otherwise "reduce" returns a new one
|
|
7447
7469
|
|
|
7448
7470
|
if (item.data) {
|
|
7449
|
-
acc = acc.concat(transformValue(item.data));
|
|
7471
|
+
acc = acc.concat(transformValue$1(item.data));
|
|
7450
7472
|
}
|
|
7451
7473
|
}
|
|
7452
7474
|
|
|
@@ -7508,7 +7530,7 @@ var connectBreadcrumb = createConnectorWithContext({
|
|
|
7508
7530
|
transformItems: PropTypes.func
|
|
7509
7531
|
},
|
|
7510
7532
|
getProvidedProps: function getProvidedProps(props, searchState, searchResults) {
|
|
7511
|
-
var id = getId$
|
|
7533
|
+
var id = getId$d(props);
|
|
7512
7534
|
var results = getResults(searchResults, {
|
|
7513
7535
|
ais: props.contextValue,
|
|
7514
7536
|
multiIndexContext: props.indexContextValue
|
|
@@ -7523,7 +7545,7 @@ var connectBreadcrumb = createConnectorWithContext({
|
|
|
7523
7545
|
}
|
|
7524
7546
|
|
|
7525
7547
|
var values = results.getFacetValues(id);
|
|
7526
|
-
var items = values.data ? transformValue(values.data) : [];
|
|
7548
|
+
var items = values.data ? transformValue$1(values.data) : [];
|
|
7527
7549
|
var transformedItems = props.transformItems ? props.transformItems(items) : items;
|
|
7528
7550
|
return {
|
|
7529
7551
|
canRefine: transformedItems.length > 0,
|
|
@@ -7531,7 +7553,7 @@ var connectBreadcrumb = createConnectorWithContext({
|
|
|
7531
7553
|
};
|
|
7532
7554
|
},
|
|
7533
7555
|
refine: function refine(props, searchState, nextRefinement) {
|
|
7534
|
-
return _refine(props, searchState, nextRefinement, {
|
|
7556
|
+
return _refine$9(props, searchState, nextRefinement, {
|
|
7535
7557
|
ais: props.contextValue,
|
|
7536
7558
|
multiIndexContext: props.indexContextValue
|
|
7537
7559
|
});
|
|
@@ -7594,13 +7616,13 @@ var connectCurrentRefinements = createConnectorWithContext({
|
|
|
7594
7616
|
}
|
|
7595
7617
|
});
|
|
7596
7618
|
|
|
7597
|
-
var getId$
|
|
7619
|
+
var getId$c = function getId(props) {
|
|
7598
7620
|
return props.attributes[0];
|
|
7599
7621
|
};
|
|
7600
|
-
var namespace$
|
|
7622
|
+
var namespace$5 = 'hierarchicalMenu';
|
|
7601
7623
|
|
|
7602
|
-
function getCurrentRefinement(props, searchState, context) {
|
|
7603
|
-
var currentRefinement = getCurrentRefinementValue(props, searchState, context, "".concat(namespace$
|
|
7624
|
+
function getCurrentRefinement$b(props, searchState, context) {
|
|
7625
|
+
var currentRefinement = getCurrentRefinementValue(props, searchState, context, "".concat(namespace$5, ".").concat(getId$c(props)), null);
|
|
7604
7626
|
|
|
7605
7627
|
if (currentRefinement === '') {
|
|
7606
7628
|
return null;
|
|
@@ -7609,13 +7631,13 @@ function getCurrentRefinement(props, searchState, context) {
|
|
|
7609
7631
|
return currentRefinement;
|
|
7610
7632
|
}
|
|
7611
7633
|
|
|
7612
|
-
function getValue(path, props, searchState, context) {
|
|
7634
|
+
function getValue$2(path, props, searchState, context) {
|
|
7613
7635
|
var id = props.id,
|
|
7614
7636
|
attributes = props.attributes,
|
|
7615
7637
|
separator = props.separator,
|
|
7616
7638
|
rootPath = props.rootPath,
|
|
7617
7639
|
showParentLevel = props.showParentLevel;
|
|
7618
|
-
var currentRefinement = getCurrentRefinement(props, searchState, context);
|
|
7640
|
+
var currentRefinement = getCurrentRefinement$b(props, searchState, context);
|
|
7619
7641
|
var nextRefinement;
|
|
7620
7642
|
|
|
7621
7643
|
if (currentRefinement === null) {
|
|
@@ -7636,14 +7658,14 @@ function getValue(path, props, searchState, context) {
|
|
|
7636
7658
|
return nextRefinement;
|
|
7637
7659
|
}
|
|
7638
7660
|
|
|
7639
|
-
function transformValue
|
|
7661
|
+
function transformValue(value, props, searchState, context) {
|
|
7640
7662
|
return value.map(function (v) {
|
|
7641
7663
|
return {
|
|
7642
7664
|
label: v.name,
|
|
7643
|
-
value: getValue(v.path, props, searchState, context),
|
|
7665
|
+
value: getValue$2(v.path, props, searchState, context),
|
|
7644
7666
|
count: v.count,
|
|
7645
7667
|
isRefined: v.isRefined,
|
|
7646
|
-
items: v.data && transformValue
|
|
7668
|
+
items: v.data && transformValue(v.data, props, searchState, context)
|
|
7647
7669
|
};
|
|
7648
7670
|
});
|
|
7649
7671
|
}
|
|
@@ -7659,20 +7681,20 @@ var truncate = function truncate() {
|
|
|
7659
7681
|
});
|
|
7660
7682
|
};
|
|
7661
7683
|
|
|
7662
|
-
function _refine$
|
|
7663
|
-
var id = getId$
|
|
7684
|
+
function _refine$8(props, searchState, nextRefinement, context) {
|
|
7685
|
+
var id = getId$c(props);
|
|
7664
7686
|
|
|
7665
7687
|
var nextValue = _defineProperty({}, id, nextRefinement || '');
|
|
7666
7688
|
|
|
7667
7689
|
var resetPage = true;
|
|
7668
|
-
return refineValue(searchState, nextValue, context, resetPage, namespace$
|
|
7690
|
+
return refineValue(searchState, nextValue, context, resetPage, namespace$5);
|
|
7669
7691
|
}
|
|
7670
7692
|
|
|
7671
|
-
function _cleanUp(props, searchState, context) {
|
|
7672
|
-
return cleanUpValue(searchState, context, "".concat(namespace$
|
|
7693
|
+
function _cleanUp$7(props, searchState, context) {
|
|
7694
|
+
return cleanUpValue(searchState, context, "".concat(namespace$5, ".").concat(getId$c(props)));
|
|
7673
7695
|
}
|
|
7674
7696
|
|
|
7675
|
-
var sortBy = ['name:asc'];
|
|
7697
|
+
var sortBy$1 = ['name:asc'];
|
|
7676
7698
|
/**
|
|
7677
7699
|
* connectHierarchicalMenu connector provides the logic to build a widget that will
|
|
7678
7700
|
* give the user the ability to explore a tree-like structure.
|
|
@@ -7754,7 +7776,7 @@ var connectHierarchicalMenu = createConnectorWithContext({
|
|
|
7754
7776
|
var showMore = props.showMore,
|
|
7755
7777
|
limit = props.limit,
|
|
7756
7778
|
showMoreLimit = props.showMoreLimit;
|
|
7757
|
-
var id = getId$
|
|
7779
|
+
var id = getId$c(props);
|
|
7758
7780
|
var results = getResults(searchResults, {
|
|
7759
7781
|
ais: props.contextValue,
|
|
7760
7782
|
multiIndexContext: props.indexContextValue
|
|
@@ -7764,7 +7786,7 @@ var connectHierarchicalMenu = createConnectorWithContext({
|
|
|
7764
7786
|
if (!isFacetPresent) {
|
|
7765
7787
|
return {
|
|
7766
7788
|
items: [],
|
|
7767
|
-
currentRefinement: getCurrentRefinement(props, searchState, {
|
|
7789
|
+
currentRefinement: getCurrentRefinement$b(props, searchState, {
|
|
7768
7790
|
ais: props.contextValue,
|
|
7769
7791
|
multiIndexContext: props.indexContextValue
|
|
7770
7792
|
}),
|
|
@@ -7774,16 +7796,16 @@ var connectHierarchicalMenu = createConnectorWithContext({
|
|
|
7774
7796
|
|
|
7775
7797
|
var itemsLimit = showMore ? showMoreLimit : limit;
|
|
7776
7798
|
var value = results.getFacetValues(id, {
|
|
7777
|
-
sortBy: sortBy
|
|
7799
|
+
sortBy: sortBy$1
|
|
7778
7800
|
});
|
|
7779
|
-
var items = value.data ? transformValue
|
|
7801
|
+
var items = value.data ? transformValue(value.data, props, searchState, {
|
|
7780
7802
|
ais: props.contextValue,
|
|
7781
7803
|
multiIndexContext: props.indexContextValue
|
|
7782
7804
|
}) : [];
|
|
7783
7805
|
var transformedItems = props.transformItems ? props.transformItems(items) : items;
|
|
7784
7806
|
return {
|
|
7785
7807
|
items: truncate(transformedItems, itemsLimit),
|
|
7786
|
-
currentRefinement: getCurrentRefinement(props, searchState, {
|
|
7808
|
+
currentRefinement: getCurrentRefinement$b(props, searchState, {
|
|
7787
7809
|
ais: props.contextValue,
|
|
7788
7810
|
multiIndexContext: props.indexContextValue
|
|
7789
7811
|
}),
|
|
@@ -7791,13 +7813,13 @@ var connectHierarchicalMenu = createConnectorWithContext({
|
|
|
7791
7813
|
};
|
|
7792
7814
|
},
|
|
7793
7815
|
refine: function refine(props, searchState, nextRefinement) {
|
|
7794
|
-
return _refine$
|
|
7816
|
+
return _refine$8(props, searchState, nextRefinement, {
|
|
7795
7817
|
ais: props.contextValue,
|
|
7796
7818
|
multiIndexContext: props.indexContextValue
|
|
7797
7819
|
});
|
|
7798
7820
|
},
|
|
7799
7821
|
cleanUp: function cleanUp(props, searchState) {
|
|
7800
|
-
return _cleanUp(props, searchState, {
|
|
7822
|
+
return _cleanUp$7(props, searchState, {
|
|
7801
7823
|
ais: props.contextValue,
|
|
7802
7824
|
multiIndexContext: props.indexContextValue
|
|
7803
7825
|
});
|
|
@@ -7811,7 +7833,7 @@ var connectHierarchicalMenu = createConnectorWithContext({
|
|
|
7811
7833
|
limit = props.limit,
|
|
7812
7834
|
showMoreLimit = props.showMoreLimit,
|
|
7813
7835
|
contextValue = props.contextValue;
|
|
7814
|
-
var id = getId$
|
|
7836
|
+
var id = getId$c(props);
|
|
7815
7837
|
var itemsLimit = showMore ? showMoreLimit : limit;
|
|
7816
7838
|
searchParameters = searchParameters.addHierarchicalFacet({
|
|
7817
7839
|
name: id,
|
|
@@ -7822,7 +7844,7 @@ var connectHierarchicalMenu = createConnectorWithContext({
|
|
|
7822
7844
|
}).setQueryParameters({
|
|
7823
7845
|
maxValuesPerFacet: Math.max(searchParameters.maxValuesPerFacet || 0, itemsLimit)
|
|
7824
7846
|
});
|
|
7825
|
-
var currentRefinement = getCurrentRefinement(props, searchState, {
|
|
7847
|
+
var currentRefinement = getCurrentRefinement$b(props, searchState, {
|
|
7826
7848
|
ais: contextValue,
|
|
7827
7849
|
multiIndexContext: props.indexContextValue
|
|
7828
7850
|
});
|
|
@@ -7835,8 +7857,8 @@ var connectHierarchicalMenu = createConnectorWithContext({
|
|
|
7835
7857
|
},
|
|
7836
7858
|
getMetadata: function getMetadata(props, searchState) {
|
|
7837
7859
|
var rootAttribute = props.attributes[0];
|
|
7838
|
-
var id = getId$
|
|
7839
|
-
var currentRefinement = getCurrentRefinement(props, searchState, {
|
|
7860
|
+
var id = getId$c(props);
|
|
7861
|
+
var currentRefinement = getCurrentRefinement$b(props, searchState, {
|
|
7840
7862
|
ais: props.contextValue,
|
|
7841
7863
|
multiIndexContext: props.indexContextValue
|
|
7842
7864
|
});
|
|
@@ -7844,7 +7866,7 @@ var connectHierarchicalMenu = createConnectorWithContext({
|
|
|
7844
7866
|
label: "".concat(rootAttribute, ": ").concat(currentRefinement),
|
|
7845
7867
|
attribute: rootAttribute,
|
|
7846
7868
|
value: function value(nextState) {
|
|
7847
|
-
return _refine$
|
|
7869
|
+
return _refine$8(props, nextState, '', {
|
|
7848
7870
|
ais: props.contextValue,
|
|
7849
7871
|
multiIndexContext: props.indexContextValue
|
|
7850
7872
|
});
|
|
@@ -8021,12 +8043,12 @@ var connectHits = createConnectorWithContext({
|
|
|
8021
8043
|
}
|
|
8022
8044
|
});
|
|
8023
8045
|
|
|
8024
|
-
function getId$
|
|
8046
|
+
function getId$b() {
|
|
8025
8047
|
return 'hitsPerPage';
|
|
8026
8048
|
}
|
|
8027
8049
|
|
|
8028
|
-
function getCurrentRefinement$
|
|
8029
|
-
var id = getId$
|
|
8050
|
+
function getCurrentRefinement$a(props, searchState, context) {
|
|
8051
|
+
var id = getId$b();
|
|
8030
8052
|
var currentRefinement = getCurrentRefinementValue(props, searchState, context, id, null);
|
|
8031
8053
|
|
|
8032
8054
|
if (typeof currentRefinement === 'string') {
|
|
@@ -8061,7 +8083,7 @@ var connectHitsPerPage = createConnectorWithContext({
|
|
|
8061
8083
|
transformItems: PropTypes.func
|
|
8062
8084
|
},
|
|
8063
8085
|
getProvidedProps: function getProvidedProps(props, searchState) {
|
|
8064
|
-
var currentRefinement = getCurrentRefinement$
|
|
8086
|
+
var currentRefinement = getCurrentRefinement$a(props, searchState, {
|
|
8065
8087
|
ais: props.contextValue,
|
|
8066
8088
|
multiIndexContext: props.indexContextValue
|
|
8067
8089
|
});
|
|
@@ -8078,7 +8100,7 @@ var connectHitsPerPage = createConnectorWithContext({
|
|
|
8078
8100
|
};
|
|
8079
8101
|
},
|
|
8080
8102
|
refine: function refine(props, searchState, nextRefinement) {
|
|
8081
|
-
var id = getId$
|
|
8103
|
+
var id = getId$b();
|
|
8082
8104
|
|
|
8083
8105
|
var nextValue = _defineProperty({}, id, nextRefinement);
|
|
8084
8106
|
|
|
@@ -8092,27 +8114,27 @@ var connectHitsPerPage = createConnectorWithContext({
|
|
|
8092
8114
|
return cleanUpValue(searchState, {
|
|
8093
8115
|
ais: props.contextValue,
|
|
8094
8116
|
multiIndexContext: props.indexContextValue
|
|
8095
|
-
}, getId$
|
|
8117
|
+
}, getId$b());
|
|
8096
8118
|
},
|
|
8097
8119
|
getSearchParameters: function getSearchParameters(searchParameters, props, searchState) {
|
|
8098
|
-
return searchParameters.setHitsPerPage(getCurrentRefinement$
|
|
8120
|
+
return searchParameters.setHitsPerPage(getCurrentRefinement$a(props, searchState, {
|
|
8099
8121
|
ais: props.contextValue,
|
|
8100
8122
|
multiIndexContext: props.indexContextValue
|
|
8101
8123
|
}));
|
|
8102
8124
|
},
|
|
8103
8125
|
getMetadata: function getMetadata() {
|
|
8104
8126
|
return {
|
|
8105
|
-
id: getId$
|
|
8127
|
+
id: getId$b()
|
|
8106
8128
|
};
|
|
8107
8129
|
}
|
|
8108
8130
|
});
|
|
8109
8131
|
|
|
8110
|
-
function getId$
|
|
8132
|
+
function getId$a() {
|
|
8111
8133
|
return 'page';
|
|
8112
8134
|
}
|
|
8113
8135
|
|
|
8114
|
-
function getCurrentRefinement$
|
|
8115
|
-
var id = getId$
|
|
8136
|
+
function getCurrentRefinement$9(props, searchState, context) {
|
|
8137
|
+
var id = getId$a();
|
|
8116
8138
|
var page = 1;
|
|
8117
8139
|
var currentRefinement = getCurrentRefinementValue(props, searchState, context, id, page);
|
|
8118
8140
|
|
|
@@ -8124,9 +8146,9 @@ function getCurrentRefinement$2(props, searchState, context) {
|
|
|
8124
8146
|
}
|
|
8125
8147
|
|
|
8126
8148
|
function getStateWithoutPage(state) {
|
|
8127
|
-
var _ref = state || {}
|
|
8128
|
-
|
|
8129
|
-
rest = _objectWithoutProperties(_ref, ["page"]);
|
|
8149
|
+
var _ref = state || {};
|
|
8150
|
+
_ref.page;
|
|
8151
|
+
var rest = _objectWithoutProperties(_ref, ["page"]);
|
|
8130
8152
|
|
|
8131
8153
|
return rest;
|
|
8132
8154
|
}
|
|
@@ -8235,14 +8257,14 @@ var connectInfiniteHits = createConnectorWithContext({
|
|
|
8235
8257
|
},
|
|
8236
8258
|
getSearchParameters: function getSearchParameters(searchParameters, props, searchState) {
|
|
8237
8259
|
return searchParameters.setQueryParameters({
|
|
8238
|
-
page: getCurrentRefinement$
|
|
8260
|
+
page: getCurrentRefinement$9(props, searchState, {
|
|
8239
8261
|
ais: props.contextValue,
|
|
8240
8262
|
multiIndexContext: props.indexContextValue
|
|
8241
8263
|
}) - 1
|
|
8242
8264
|
});
|
|
8243
8265
|
},
|
|
8244
8266
|
refine: function refine(props, searchState, event, index) {
|
|
8245
|
-
var id = getId$
|
|
8267
|
+
var id = getId$a();
|
|
8246
8268
|
|
|
8247
8269
|
var nextValue = _defineProperty({}, id, index + 1);
|
|
8248
8270
|
|
|
@@ -8254,14 +8276,14 @@ var connectInfiniteHits = createConnectorWithContext({
|
|
|
8254
8276
|
}
|
|
8255
8277
|
});
|
|
8256
8278
|
|
|
8257
|
-
var namespace$
|
|
8279
|
+
var namespace$4 = 'menu';
|
|
8258
8280
|
|
|
8259
|
-
function getId$
|
|
8281
|
+
function getId$9(props) {
|
|
8260
8282
|
return props.attribute;
|
|
8261
8283
|
}
|
|
8262
8284
|
|
|
8263
|
-
function getCurrentRefinement$
|
|
8264
|
-
var currentRefinement = getCurrentRefinementValue(props, searchState, context, "".concat(namespace$
|
|
8285
|
+
function getCurrentRefinement$8(props, searchState, context) {
|
|
8286
|
+
var currentRefinement = getCurrentRefinementValue(props, searchState, context, "".concat(namespace$4, ".").concat(getId$9(props)), null);
|
|
8265
8287
|
|
|
8266
8288
|
if (currentRefinement === '') {
|
|
8267
8289
|
return null;
|
|
@@ -8271,28 +8293,28 @@ function getCurrentRefinement$3(props, searchState, context) {
|
|
|
8271
8293
|
}
|
|
8272
8294
|
|
|
8273
8295
|
function getValue$1(name, props, searchState, context) {
|
|
8274
|
-
var currentRefinement = getCurrentRefinement$
|
|
8296
|
+
var currentRefinement = getCurrentRefinement$8(props, searchState, context);
|
|
8275
8297
|
return name === currentRefinement ? '' : name;
|
|
8276
8298
|
}
|
|
8277
8299
|
|
|
8278
|
-
function getLimit(_ref) {
|
|
8300
|
+
function getLimit$1(_ref) {
|
|
8279
8301
|
var showMore = _ref.showMore,
|
|
8280
8302
|
limit = _ref.limit,
|
|
8281
8303
|
showMoreLimit = _ref.showMoreLimit;
|
|
8282
8304
|
return showMore ? showMoreLimit : limit;
|
|
8283
8305
|
}
|
|
8284
8306
|
|
|
8285
|
-
function _refine$
|
|
8286
|
-
var id = getId$
|
|
8307
|
+
function _refine$7(props, searchState, nextRefinement, context) {
|
|
8308
|
+
var id = getId$9(props);
|
|
8287
8309
|
|
|
8288
8310
|
var nextValue = _defineProperty({}, id, nextRefinement ? nextRefinement : '');
|
|
8289
8311
|
|
|
8290
8312
|
var resetPage = true;
|
|
8291
|
-
return refineValue(searchState, nextValue, context, resetPage, namespace$
|
|
8313
|
+
return refineValue(searchState, nextValue, context, resetPage, namespace$4);
|
|
8292
8314
|
}
|
|
8293
8315
|
|
|
8294
|
-
function _cleanUp$
|
|
8295
|
-
return cleanUpValue(searchState, context, "".concat(namespace$
|
|
8316
|
+
function _cleanUp$6(props, searchState, context) {
|
|
8317
|
+
return cleanUpValue(searchState, context, "".concat(namespace$4, ".").concat(getId$9(props)));
|
|
8296
8318
|
}
|
|
8297
8319
|
|
|
8298
8320
|
var defaultSortBy = ['count:desc', 'name:asc'];
|
|
@@ -8351,7 +8373,7 @@ var connectMenu = createConnectorWithContext({
|
|
|
8351
8373
|
if (!canRefine) {
|
|
8352
8374
|
return {
|
|
8353
8375
|
items: [],
|
|
8354
|
-
currentRefinement: getCurrentRefinement$
|
|
8376
|
+
currentRefinement: getCurrentRefinement$8(props, searchState, {
|
|
8355
8377
|
ais: props.contextValue,
|
|
8356
8378
|
multiIndexContext: props.indexContextValue
|
|
8357
8379
|
}),
|
|
@@ -8398,8 +8420,8 @@ var connectMenu = createConnectorWithContext({
|
|
|
8398
8420
|
|
|
8399
8421
|
var transformedItems = props.transformItems ? props.transformItems(items) : items;
|
|
8400
8422
|
return {
|
|
8401
|
-
items: transformedItems.slice(0, getLimit(props)),
|
|
8402
|
-
currentRefinement: getCurrentRefinement$
|
|
8423
|
+
items: transformedItems.slice(0, getLimit$1(props)),
|
|
8424
|
+
currentRefinement: getCurrentRefinement$8(props, searchState, {
|
|
8403
8425
|
ais: props.contextValue,
|
|
8404
8426
|
multiIndexContext: props.indexContextValue
|
|
8405
8427
|
}),
|
|
@@ -8409,7 +8431,7 @@ var connectMenu = createConnectorWithContext({
|
|
|
8409
8431
|
};
|
|
8410
8432
|
},
|
|
8411
8433
|
refine: function refine(props, searchState, nextRefinement) {
|
|
8412
|
-
return _refine$
|
|
8434
|
+
return _refine$7(props, searchState, nextRefinement, {
|
|
8413
8435
|
ais: props.contextValue,
|
|
8414
8436
|
multiIndexContext: props.indexContextValue
|
|
8415
8437
|
});
|
|
@@ -8418,11 +8440,11 @@ var connectMenu = createConnectorWithContext({
|
|
|
8418
8440
|
return {
|
|
8419
8441
|
facetName: props.attribute,
|
|
8420
8442
|
query: nextRefinement,
|
|
8421
|
-
maxFacetHits: getLimit(props)
|
|
8443
|
+
maxFacetHits: getLimit$1(props)
|
|
8422
8444
|
};
|
|
8423
8445
|
},
|
|
8424
8446
|
cleanUp: function cleanUp(props, searchState) {
|
|
8425
|
-
return _cleanUp$
|
|
8447
|
+
return _cleanUp$6(props, searchState, {
|
|
8426
8448
|
ais: props.contextValue,
|
|
8427
8449
|
multiIndexContext: props.indexContextValue
|
|
8428
8450
|
});
|
|
@@ -8430,10 +8452,10 @@ var connectMenu = createConnectorWithContext({
|
|
|
8430
8452
|
getSearchParameters: function getSearchParameters(searchParameters, props, searchState) {
|
|
8431
8453
|
var attribute = props.attribute;
|
|
8432
8454
|
searchParameters = searchParameters.setQueryParameters({
|
|
8433
|
-
maxValuesPerFacet: Math.max(searchParameters.maxValuesPerFacet || 0, getLimit(props))
|
|
8455
|
+
maxValuesPerFacet: Math.max(searchParameters.maxValuesPerFacet || 0, getLimit$1(props))
|
|
8434
8456
|
});
|
|
8435
8457
|
searchParameters = searchParameters.addDisjunctiveFacet(attribute);
|
|
8436
|
-
var currentRefinement = getCurrentRefinement$
|
|
8458
|
+
var currentRefinement = getCurrentRefinement$8(props, searchState, {
|
|
8437
8459
|
ais: props.contextValue,
|
|
8438
8460
|
multiIndexContext: props.indexContextValue
|
|
8439
8461
|
});
|
|
@@ -8445,8 +8467,8 @@ var connectMenu = createConnectorWithContext({
|
|
|
8445
8467
|
return searchParameters;
|
|
8446
8468
|
},
|
|
8447
8469
|
getMetadata: function getMetadata(props, searchState) {
|
|
8448
|
-
var id = getId$
|
|
8449
|
-
var currentRefinement = getCurrentRefinement$
|
|
8470
|
+
var id = getId$9(props);
|
|
8471
|
+
var currentRefinement = getCurrentRefinement$8(props, searchState, {
|
|
8450
8472
|
ais: props.contextValue,
|
|
8451
8473
|
multiIndexContext: props.indexContextValue
|
|
8452
8474
|
});
|
|
@@ -8460,7 +8482,7 @@ var connectMenu = createConnectorWithContext({
|
|
|
8460
8482
|
label: "".concat(props.attribute, ": ").concat(currentRefinement),
|
|
8461
8483
|
attribute: props.attribute,
|
|
8462
8484
|
value: function value(nextState) {
|
|
8463
|
-
return _refine$
|
|
8485
|
+
return _refine$7(props, nextState, '', {
|
|
8464
8486
|
ais: props.contextValue,
|
|
8465
8487
|
multiIndexContext: props.indexContextValue
|
|
8466
8488
|
});
|
|
@@ -8476,10 +8498,7 @@ function _arrayWithHoles(arr) {
|
|
|
8476
8498
|
}
|
|
8477
8499
|
|
|
8478
8500
|
function _iterableToArrayLimit(arr, i) {
|
|
8479
|
-
if (!(Symbol.iterator in Object(arr)
|
|
8480
|
-
return;
|
|
8481
|
-
}
|
|
8482
|
-
|
|
8501
|
+
if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return;
|
|
8483
8502
|
var _arr = [];
|
|
8484
8503
|
var _n = true;
|
|
8485
8504
|
var _d = false;
|
|
@@ -8506,11 +8525,11 @@ function _iterableToArrayLimit(arr, i) {
|
|
|
8506
8525
|
}
|
|
8507
8526
|
|
|
8508
8527
|
function _nonIterableRest() {
|
|
8509
|
-
throw new TypeError("Invalid attempt to destructure non-iterable instance");
|
|
8528
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
8510
8529
|
}
|
|
8511
8530
|
|
|
8512
8531
|
function _slicedToArray(arr, i) {
|
|
8513
|
-
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest();
|
|
8532
|
+
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
|
|
8514
8533
|
}
|
|
8515
8534
|
|
|
8516
8535
|
function stringifyItem(item) {
|
|
@@ -8544,12 +8563,12 @@ function parseItem(value) {
|
|
|
8544
8563
|
|
|
8545
8564
|
var namespace$3 = 'multiRange';
|
|
8546
8565
|
|
|
8547
|
-
function getId$
|
|
8566
|
+
function getId$8(props) {
|
|
8548
8567
|
return props.attribute;
|
|
8549
8568
|
}
|
|
8550
8569
|
|
|
8551
|
-
function getCurrentRefinement$
|
|
8552
|
-
return getCurrentRefinementValue(props, searchState, context, "".concat(namespace$3, ".").concat(getId$
|
|
8570
|
+
function getCurrentRefinement$7(props, searchState, context) {
|
|
8571
|
+
return getCurrentRefinementValue(props, searchState, context, "".concat(namespace$3, ".").concat(getId$8(props)), '');
|
|
8553
8572
|
}
|
|
8554
8573
|
|
|
8555
8574
|
function isRefinementsRangeIncludesInsideItemRange(stats, start, end) {
|
|
@@ -8568,15 +8587,15 @@ function itemHasRefinement(attribute, results, value) {
|
|
|
8568
8587
|
return !(Boolean(stats) && (isRefinementsRangeIncludesInsideItemRange(stats, start, end) || isItemRangeIncludedInsideRefinementsRange(stats, start, end)));
|
|
8569
8588
|
}
|
|
8570
8589
|
|
|
8571
|
-
function _refine$
|
|
8572
|
-
var nextValue = _defineProperty({}, getId$
|
|
8590
|
+
function _refine$6(props, searchState, nextRefinement, context) {
|
|
8591
|
+
var nextValue = _defineProperty({}, getId$8(props), nextRefinement);
|
|
8573
8592
|
|
|
8574
8593
|
var resetPage = true;
|
|
8575
8594
|
return refineValue(searchState, nextValue, context, resetPage, namespace$3);
|
|
8576
8595
|
}
|
|
8577
8596
|
|
|
8578
|
-
function _cleanUp$
|
|
8579
|
-
return cleanUpValue(searchState, context, "".concat(namespace$3, ".").concat(getId$
|
|
8597
|
+
function _cleanUp$5(props, searchState, context) {
|
|
8598
|
+
return cleanUpValue(searchState, context, "".concat(namespace$3, ".").concat(getId$8(props)));
|
|
8580
8599
|
}
|
|
8581
8600
|
/**
|
|
8582
8601
|
* connectNumericMenu connector provides the logic to build a widget that will
|
|
@@ -8610,7 +8629,7 @@ var connectNumericMenu = createConnectorWithContext({
|
|
|
8610
8629
|
},
|
|
8611
8630
|
getProvidedProps: function getProvidedProps(props, searchState, searchResults) {
|
|
8612
8631
|
var attribute = props.attribute;
|
|
8613
|
-
var currentRefinement = getCurrentRefinement$
|
|
8632
|
+
var currentRefinement = getCurrentRefinement$7(props, searchState, {
|
|
8614
8633
|
ais: props.contextValue,
|
|
8615
8634
|
multiIndexContext: props.indexContextValue
|
|
8616
8635
|
});
|
|
@@ -8624,11 +8643,11 @@ var connectNumericMenu = createConnectorWithContext({
|
|
|
8624
8643
|
label: item.label,
|
|
8625
8644
|
value: value,
|
|
8626
8645
|
isRefined: value === currentRefinement,
|
|
8627
|
-
noRefinement: results ? itemHasRefinement(getId$
|
|
8646
|
+
noRefinement: results ? itemHasRefinement(getId$8(props), results, value) : false
|
|
8628
8647
|
};
|
|
8629
8648
|
});
|
|
8630
8649
|
var stats = results && results.getFacetByName(attribute) ? results.getFacetStats(attribute) : null;
|
|
8631
|
-
var refinedItem = find(items, function (item) {
|
|
8650
|
+
var refinedItem = find$2(items, function (item) {
|
|
8632
8651
|
return item.isRefined === true;
|
|
8633
8652
|
});
|
|
8634
8653
|
|
|
@@ -8653,13 +8672,13 @@ var connectNumericMenu = createConnectorWithContext({
|
|
|
8653
8672
|
};
|
|
8654
8673
|
},
|
|
8655
8674
|
refine: function refine(props, searchState, nextRefinement) {
|
|
8656
|
-
return _refine$
|
|
8675
|
+
return _refine$6(props, searchState, nextRefinement, {
|
|
8657
8676
|
ais: props.contextValue,
|
|
8658
8677
|
multiIndexContext: props.indexContextValue
|
|
8659
8678
|
});
|
|
8660
8679
|
},
|
|
8661
8680
|
cleanUp: function cleanUp(props, searchState) {
|
|
8662
|
-
return _cleanUp$
|
|
8681
|
+
return _cleanUp$5(props, searchState, {
|
|
8663
8682
|
ais: props.contextValue,
|
|
8664
8683
|
multiIndexContext: props.indexContextValue
|
|
8665
8684
|
});
|
|
@@ -8667,7 +8686,7 @@ var connectNumericMenu = createConnectorWithContext({
|
|
|
8667
8686
|
getSearchParameters: function getSearchParameters(searchParameters, props, searchState) {
|
|
8668
8687
|
var attribute = props.attribute;
|
|
8669
8688
|
|
|
8670
|
-
var _parseItem = parseItem(getCurrentRefinement$
|
|
8689
|
+
var _parseItem = parseItem(getCurrentRefinement$7(props, searchState, {
|
|
8671
8690
|
ais: props.contextValue,
|
|
8672
8691
|
multiIndexContext: props.indexContextValue
|
|
8673
8692
|
})),
|
|
@@ -8687,8 +8706,8 @@ var connectNumericMenu = createConnectorWithContext({
|
|
|
8687
8706
|
return searchParameters;
|
|
8688
8707
|
},
|
|
8689
8708
|
getMetadata: function getMetadata(props, searchState) {
|
|
8690
|
-
var id = getId$
|
|
8691
|
-
var value = getCurrentRefinement$
|
|
8709
|
+
var id = getId$8(props);
|
|
8710
|
+
var value = getCurrentRefinement$7(props, searchState, {
|
|
8692
8711
|
ais: props.contextValue,
|
|
8693
8712
|
multiIndexContext: props.indexContextValue
|
|
8694
8713
|
});
|
|
@@ -8699,7 +8718,7 @@ var connectNumericMenu = createConnectorWithContext({
|
|
|
8699
8718
|
});
|
|
8700
8719
|
|
|
8701
8720
|
if (value !== '') {
|
|
8702
|
-
var _find = find(props.items, function (item) {
|
|
8721
|
+
var _find = find$2(props.items, function (item) {
|
|
8703
8722
|
return stringifyItem(item) === value;
|
|
8704
8723
|
}),
|
|
8705
8724
|
label = _find.label;
|
|
@@ -8709,7 +8728,7 @@ var connectNumericMenu = createConnectorWithContext({
|
|
|
8709
8728
|
attribute: props.attribute,
|
|
8710
8729
|
currentRefinement: label,
|
|
8711
8730
|
value: function value(nextState) {
|
|
8712
|
-
return _refine$
|
|
8731
|
+
return _refine$6(props, nextState, '', {
|
|
8713
8732
|
ais: props.contextValue,
|
|
8714
8733
|
multiIndexContext: props.indexContextValue
|
|
8715
8734
|
});
|
|
@@ -8725,12 +8744,12 @@ var connectNumericMenu = createConnectorWithContext({
|
|
|
8725
8744
|
}
|
|
8726
8745
|
});
|
|
8727
8746
|
|
|
8728
|
-
function getId$
|
|
8747
|
+
function getId$7() {
|
|
8729
8748
|
return 'page';
|
|
8730
8749
|
}
|
|
8731
8750
|
|
|
8732
|
-
function getCurrentRefinement$
|
|
8733
|
-
var id = getId$
|
|
8751
|
+
function getCurrentRefinement$6(props, searchState, context) {
|
|
8752
|
+
var id = getId$7();
|
|
8734
8753
|
var page = 1;
|
|
8735
8754
|
var currentRefinement = getCurrentRefinementValue(props, searchState, context, id, page);
|
|
8736
8755
|
|
|
@@ -8741,8 +8760,8 @@ function getCurrentRefinement$5(props, searchState, context) {
|
|
|
8741
8760
|
return currentRefinement;
|
|
8742
8761
|
}
|
|
8743
8762
|
|
|
8744
|
-
function _refine$
|
|
8745
|
-
var id = getId$
|
|
8763
|
+
function _refine$5(props, searchState, nextPage, context) {
|
|
8764
|
+
var id = getId$7();
|
|
8746
8765
|
|
|
8747
8766
|
var nextValue = _defineProperty({}, id, nextPage);
|
|
8748
8767
|
|
|
@@ -8782,7 +8801,7 @@ var connectPagination = createConnectorWithContext({
|
|
|
8782
8801
|
var nbPages = results.nbPages;
|
|
8783
8802
|
return {
|
|
8784
8803
|
nbPages: nbPages,
|
|
8785
|
-
currentRefinement: getCurrentRefinement$
|
|
8804
|
+
currentRefinement: getCurrentRefinement$6(props, searchState, {
|
|
8786
8805
|
ais: props.contextValue,
|
|
8787
8806
|
multiIndexContext: props.indexContextValue
|
|
8788
8807
|
}),
|
|
@@ -8790,7 +8809,7 @@ var connectPagination = createConnectorWithContext({
|
|
|
8790
8809
|
};
|
|
8791
8810
|
},
|
|
8792
8811
|
refine: function refine(props, searchState, nextPage) {
|
|
8793
|
-
return _refine$
|
|
8812
|
+
return _refine$5(props, searchState, nextPage, {
|
|
8794
8813
|
ais: props.contextValue,
|
|
8795
8814
|
multiIndexContext: props.indexContextValue
|
|
8796
8815
|
});
|
|
@@ -8799,17 +8818,17 @@ var connectPagination = createConnectorWithContext({
|
|
|
8799
8818
|
return cleanUpValue(searchState, {
|
|
8800
8819
|
ais: props.contextValue,
|
|
8801
8820
|
multiIndexContext: props.indexContextValue
|
|
8802
|
-
}, getId$
|
|
8821
|
+
}, getId$7());
|
|
8803
8822
|
},
|
|
8804
8823
|
getSearchParameters: function getSearchParameters(searchParameters, props, searchState) {
|
|
8805
|
-
return searchParameters.setPage(getCurrentRefinement$
|
|
8824
|
+
return searchParameters.setPage(getCurrentRefinement$6(props, searchState, {
|
|
8806
8825
|
ais: props.contextValue,
|
|
8807
8826
|
multiIndexContext: props.indexContextValue
|
|
8808
8827
|
}) - 1);
|
|
8809
8828
|
},
|
|
8810
8829
|
getMetadata: function getMetadata() {
|
|
8811
8830
|
return {
|
|
8812
|
-
id: getId$
|
|
8831
|
+
id: getId$7()
|
|
8813
8832
|
};
|
|
8814
8833
|
}
|
|
8815
8834
|
});
|
|
@@ -8855,11 +8874,11 @@ var connectPoweredBy = createConnectorWithContext({
|
|
|
8855
8874
|
* @providedPropType {number} precision - Number of digits after decimal point to use.
|
|
8856
8875
|
*/
|
|
8857
8876
|
|
|
8858
|
-
function getId$
|
|
8877
|
+
function getId$6(props) {
|
|
8859
8878
|
return props.attribute;
|
|
8860
8879
|
}
|
|
8861
8880
|
|
|
8862
|
-
var namespace$
|
|
8881
|
+
var namespace$2 = 'range';
|
|
8863
8882
|
|
|
8864
8883
|
function getCurrentRange(boundaries, stats, precision) {
|
|
8865
8884
|
var pow = Math.pow(10, precision);
|
|
@@ -8889,8 +8908,8 @@ function getCurrentRange(boundaries, stats, precision) {
|
|
|
8889
8908
|
};
|
|
8890
8909
|
}
|
|
8891
8910
|
|
|
8892
|
-
function getCurrentRefinement$
|
|
8893
|
-
var _getCurrentRefinement = getCurrentRefinementValue(props, searchState, context, "".concat(namespace$
|
|
8911
|
+
function getCurrentRefinement$5(props, searchState, currentRange, context) {
|
|
8912
|
+
var _getCurrentRefinement = getCurrentRefinementValue(props, searchState, context, "".concat(namespace$2, ".").concat(getId$6(props)), {}),
|
|
8894
8913
|
min = _getCurrentRefinement.min,
|
|
8895
8914
|
max = _getCurrentRefinement.max;
|
|
8896
8915
|
|
|
@@ -8956,7 +8975,7 @@ function nextValueForRefinement(hasBound, isReset, range, value) {
|
|
|
8956
8975
|
return next;
|
|
8957
8976
|
}
|
|
8958
8977
|
|
|
8959
|
-
function _refine$
|
|
8978
|
+
function _refine$4(props, searchState, nextRefinement, currentRange, context) {
|
|
8960
8979
|
var nextMin = nextRefinement.min,
|
|
8961
8980
|
nextMax = nextRefinement.max;
|
|
8962
8981
|
var currentMinRange = currentRange.min,
|
|
@@ -8980,7 +8999,7 @@ function _refine$5(props, searchState, nextRefinement, currentRange, context) {
|
|
|
8980
8999
|
throw Error("You can't provide max value greater than range.");
|
|
8981
9000
|
}
|
|
8982
9001
|
|
|
8983
|
-
var id = getId$
|
|
9002
|
+
var id = getId$6(props);
|
|
8984
9003
|
var resetPage = true;
|
|
8985
9004
|
|
|
8986
9005
|
var nextValue = _defineProperty({}, id, {
|
|
@@ -8988,11 +9007,11 @@ function _refine$5(props, searchState, nextRefinement, currentRange, context) {
|
|
|
8988
9007
|
max: nextValueForRefinement(props.max !== undefined, isMaxReset, currentMaxRange, nextMaxAsNumber)
|
|
8989
9008
|
});
|
|
8990
9009
|
|
|
8991
|
-
return refineValue(searchState, nextValue, context, resetPage, namespace$
|
|
9010
|
+
return refineValue(searchState, nextValue, context, resetPage, namespace$2);
|
|
8992
9011
|
}
|
|
8993
9012
|
|
|
8994
|
-
function _cleanUp$
|
|
8995
|
-
return cleanUpValue(searchState, context, "".concat(namespace$
|
|
9013
|
+
function _cleanUp$4(props, searchState, context) {
|
|
9014
|
+
return cleanUpValue(searchState, context, "".concat(namespace$2, ".").concat(getId$6(props)));
|
|
8996
9015
|
}
|
|
8997
9016
|
|
|
8998
9017
|
var connectRange = createConnectorWithContext({
|
|
@@ -9047,7 +9066,7 @@ var connectRange = createConnectorWithContext({
|
|
|
9047
9066
|
min: rangeMin,
|
|
9048
9067
|
max: rangeMax
|
|
9049
9068
|
};
|
|
9050
|
-
var currentRefinement = getCurrentRefinement$
|
|
9069
|
+
var currentRefinement = getCurrentRefinement$5(props, searchState, this._currentRange, {
|
|
9051
9070
|
ais: props.contextValue,
|
|
9052
9071
|
multiIndexContext: props.indexContextValue
|
|
9053
9072
|
});
|
|
@@ -9061,13 +9080,13 @@ var connectRange = createConnectorWithContext({
|
|
|
9061
9080
|
};
|
|
9062
9081
|
},
|
|
9063
9082
|
refine: function refine(props, searchState, nextRefinement) {
|
|
9064
|
-
return _refine$
|
|
9083
|
+
return _refine$4(props, searchState, nextRefinement, this._currentRange, {
|
|
9065
9084
|
ais: props.contextValue,
|
|
9066
9085
|
multiIndexContext: props.indexContextValue
|
|
9067
9086
|
});
|
|
9068
9087
|
},
|
|
9069
9088
|
cleanUp: function cleanUp(props, searchState) {
|
|
9070
|
-
return _cleanUp$
|
|
9089
|
+
return _cleanUp$4(props, searchState, {
|
|
9071
9090
|
ais: props.contextValue,
|
|
9072
9091
|
multiIndexContext: props.indexContextValue
|
|
9073
9092
|
});
|
|
@@ -9075,7 +9094,7 @@ var connectRange = createConnectorWithContext({
|
|
|
9075
9094
|
getSearchParameters: function getSearchParameters(params, props, searchState) {
|
|
9076
9095
|
var attribute = props.attribute;
|
|
9077
9096
|
|
|
9078
|
-
var _getCurrentRefinement2 = getCurrentRefinement$
|
|
9097
|
+
var _getCurrentRefinement2 = getCurrentRefinement$5(props, searchState, this._currentRange, {
|
|
9079
9098
|
ais: props.contextValue,
|
|
9080
9099
|
multiIndexContext: props.indexContextValue
|
|
9081
9100
|
}),
|
|
@@ -9101,7 +9120,7 @@ var connectRange = createConnectorWithContext({
|
|
|
9101
9120
|
minRange = _this$_currentRange.min,
|
|
9102
9121
|
maxRange = _this$_currentRange.max;
|
|
9103
9122
|
|
|
9104
|
-
var _getCurrentRefinement3 = getCurrentRefinement$
|
|
9123
|
+
var _getCurrentRefinement3 = getCurrentRefinement$5(props, searchState, this._currentRange, {
|
|
9105
9124
|
ais: props.contextValue,
|
|
9106
9125
|
multiIndexContext: props.indexContextValue
|
|
9107
9126
|
}),
|
|
@@ -9120,7 +9139,7 @@ var connectRange = createConnectorWithContext({
|
|
|
9120
9139
|
label: fragments.join(''),
|
|
9121
9140
|
attribute: props.attribute,
|
|
9122
9141
|
value: function value(nextState) {
|
|
9123
|
-
return _refine$
|
|
9142
|
+
return _refine$4(props, nextState, {}, _this._currentRange, {
|
|
9124
9143
|
ais: props.contextValue,
|
|
9125
9144
|
multiIndexContext: props.indexContextValue
|
|
9126
9145
|
});
|
|
@@ -9136,7 +9155,7 @@ var connectRange = createConnectorWithContext({
|
|
|
9136
9155
|
}
|
|
9137
9156
|
|
|
9138
9157
|
return {
|
|
9139
|
-
id: getId$
|
|
9158
|
+
id: getId$6(props),
|
|
9140
9159
|
index: getIndexId({
|
|
9141
9160
|
ais: props.contextValue,
|
|
9142
9161
|
multiIndexContext: props.indexContextValue
|
|
@@ -9146,14 +9165,14 @@ var connectRange = createConnectorWithContext({
|
|
|
9146
9165
|
}
|
|
9147
9166
|
});
|
|
9148
9167
|
|
|
9149
|
-
var namespace$
|
|
9168
|
+
var namespace$1 = 'refinementList';
|
|
9150
9169
|
|
|
9151
|
-
function getId$
|
|
9170
|
+
function getId$5(props) {
|
|
9152
9171
|
return props.attribute;
|
|
9153
9172
|
}
|
|
9154
9173
|
|
|
9155
|
-
function getCurrentRefinement$
|
|
9156
|
-
var currentRefinement = getCurrentRefinementValue(props, searchState, context, "".concat(namespace$
|
|
9174
|
+
function getCurrentRefinement$4(props, searchState, context) {
|
|
9175
|
+
var currentRefinement = getCurrentRefinementValue(props, searchState, context, "".concat(namespace$1, ".").concat(getId$5(props)), []);
|
|
9157
9176
|
|
|
9158
9177
|
if (typeof currentRefinement !== 'string') {
|
|
9159
9178
|
return currentRefinement;
|
|
@@ -9166,8 +9185,8 @@ function getCurrentRefinement$7(props, searchState, context) {
|
|
|
9166
9185
|
return [];
|
|
9167
9186
|
}
|
|
9168
9187
|
|
|
9169
|
-
function getValue
|
|
9170
|
-
var currentRefinement = getCurrentRefinement$
|
|
9188
|
+
function getValue(name, props, searchState, context) {
|
|
9189
|
+
var currentRefinement = getCurrentRefinement$4(props, searchState, context);
|
|
9171
9190
|
var isAnewValue = currentRefinement.indexOf(name) === -1;
|
|
9172
9191
|
var nextRefinement = isAnewValue ? currentRefinement.concat([name]) // cannot use .push(), it mutates
|
|
9173
9192
|
: currentRefinement.filter(function (selectedValue) {
|
|
@@ -9177,15 +9196,15 @@ function getValue$2(name, props, searchState, context) {
|
|
|
9177
9196
|
return nextRefinement;
|
|
9178
9197
|
}
|
|
9179
9198
|
|
|
9180
|
-
function getLimit
|
|
9199
|
+
function getLimit(_ref) {
|
|
9181
9200
|
var showMore = _ref.showMore,
|
|
9182
9201
|
limit = _ref.limit,
|
|
9183
9202
|
showMoreLimit = _ref.showMoreLimit;
|
|
9184
9203
|
return showMore ? showMoreLimit : limit;
|
|
9185
9204
|
}
|
|
9186
9205
|
|
|
9187
|
-
function _refine$
|
|
9188
|
-
var id = getId$
|
|
9206
|
+
function _refine$3(props, searchState, nextRefinement, context) {
|
|
9207
|
+
var id = getId$5(props); // Setting the value to an empty string ensures that it is persisted in
|
|
9189
9208
|
// the URL as an empty value.
|
|
9190
9209
|
// This is necessary in the case where `defaultRefinement` contains one
|
|
9191
9210
|
// item and we try to deselect it. `nextSelected` would be an empty array,
|
|
@@ -9196,11 +9215,11 @@ function _refine$6(props, searchState, nextRefinement, context) {
|
|
|
9196
9215
|
var nextValue = _defineProperty({}, id, nextRefinement.length > 0 ? nextRefinement : '');
|
|
9197
9216
|
|
|
9198
9217
|
var resetPage = true;
|
|
9199
|
-
return refineValue(searchState, nextValue, context, resetPage, namespace$
|
|
9218
|
+
return refineValue(searchState, nextValue, context, resetPage, namespace$1);
|
|
9200
9219
|
}
|
|
9201
9220
|
|
|
9202
|
-
function _cleanUp$
|
|
9203
|
-
return cleanUpValue(searchState, context, "".concat(namespace$
|
|
9221
|
+
function _cleanUp$3(props, searchState, context) {
|
|
9222
|
+
return cleanUpValue(searchState, context, "".concat(namespace$1, ".").concat(getId$5(props)));
|
|
9204
9223
|
}
|
|
9205
9224
|
/**
|
|
9206
9225
|
* connectRefinementList connector provides the logic to build a widget that will
|
|
@@ -9227,7 +9246,7 @@ function _cleanUp$4(props, searchState, context) {
|
|
|
9227
9246
|
*/
|
|
9228
9247
|
|
|
9229
9248
|
|
|
9230
|
-
var sortBy
|
|
9249
|
+
var sortBy = ['isRefined', 'count:desc', 'name:asc'];
|
|
9231
9250
|
var connectRefinementList = createConnectorWithContext({
|
|
9232
9251
|
displayName: 'AlgoliaRefinementList',
|
|
9233
9252
|
propTypes: {
|
|
@@ -9265,7 +9284,7 @@ var connectRefinementList = createConnectorWithContext({
|
|
|
9265
9284
|
if (!canRefine) {
|
|
9266
9285
|
return {
|
|
9267
9286
|
items: [],
|
|
9268
|
-
currentRefinement: getCurrentRefinement$
|
|
9287
|
+
currentRefinement: getCurrentRefinement$4(props, searchState, {
|
|
9269
9288
|
ais: props.contextValue,
|
|
9270
9289
|
multiIndexContext: props.indexContextValue
|
|
9271
9290
|
}),
|
|
@@ -9278,7 +9297,7 @@ var connectRefinementList = createConnectorWithContext({
|
|
|
9278
9297
|
var items = isFromSearch ? searchForFacetValuesResults[attribute].map(function (v) {
|
|
9279
9298
|
return {
|
|
9280
9299
|
label: v.value,
|
|
9281
|
-
value: getValue
|
|
9300
|
+
value: getValue(v.value, props, searchState, {
|
|
9282
9301
|
ais: props.contextValue,
|
|
9283
9302
|
multiIndexContext: props.indexContextValue
|
|
9284
9303
|
}),
|
|
@@ -9291,11 +9310,11 @@ var connectRefinementList = createConnectorWithContext({
|
|
|
9291
9310
|
isRefined: v.isRefined
|
|
9292
9311
|
};
|
|
9293
9312
|
}) : results.getFacetValues(attribute, {
|
|
9294
|
-
sortBy: sortBy
|
|
9313
|
+
sortBy: sortBy
|
|
9295
9314
|
}).map(function (v) {
|
|
9296
9315
|
return {
|
|
9297
9316
|
label: v.name,
|
|
9298
|
-
value: getValue
|
|
9317
|
+
value: getValue(v.name, props, searchState, {
|
|
9299
9318
|
ais: props.contextValue,
|
|
9300
9319
|
multiIndexContext: props.indexContextValue
|
|
9301
9320
|
}),
|
|
@@ -9305,8 +9324,8 @@ var connectRefinementList = createConnectorWithContext({
|
|
|
9305
9324
|
});
|
|
9306
9325
|
var transformedItems = props.transformItems ? props.transformItems(items) : items;
|
|
9307
9326
|
return {
|
|
9308
|
-
items: transformedItems.slice(0, getLimit
|
|
9309
|
-
currentRefinement: getCurrentRefinement$
|
|
9327
|
+
items: transformedItems.slice(0, getLimit(props)),
|
|
9328
|
+
currentRefinement: getCurrentRefinement$4(props, searchState, {
|
|
9310
9329
|
ais: props.contextValue,
|
|
9311
9330
|
multiIndexContext: props.indexContextValue
|
|
9312
9331
|
}),
|
|
@@ -9316,7 +9335,7 @@ var connectRefinementList = createConnectorWithContext({
|
|
|
9316
9335
|
};
|
|
9317
9336
|
},
|
|
9318
9337
|
refine: function refine(props, searchState, nextRefinement) {
|
|
9319
|
-
return _refine$
|
|
9338
|
+
return _refine$3(props, searchState, nextRefinement, {
|
|
9320
9339
|
ais: props.contextValue,
|
|
9321
9340
|
multiIndexContext: props.indexContextValue
|
|
9322
9341
|
});
|
|
@@ -9325,11 +9344,11 @@ var connectRefinementList = createConnectorWithContext({
|
|
|
9325
9344
|
return {
|
|
9326
9345
|
facetName: props.attribute,
|
|
9327
9346
|
query: nextRefinement,
|
|
9328
|
-
maxFacetHits: getLimit
|
|
9347
|
+
maxFacetHits: getLimit(props)
|
|
9329
9348
|
};
|
|
9330
9349
|
},
|
|
9331
9350
|
cleanUp: function cleanUp(props, searchState) {
|
|
9332
|
-
return _cleanUp$
|
|
9351
|
+
return _cleanUp$3(props, searchState, {
|
|
9333
9352
|
ais: props.contextValue,
|
|
9334
9353
|
multiIndexContext: props.indexContextValue
|
|
9335
9354
|
});
|
|
@@ -9340,10 +9359,10 @@ var connectRefinementList = createConnectorWithContext({
|
|
|
9340
9359
|
var addKey = operator === 'and' ? 'addFacet' : 'addDisjunctiveFacet';
|
|
9341
9360
|
var addRefinementKey = "".concat(addKey, "Refinement");
|
|
9342
9361
|
searchParameters = searchParameters.setQueryParameters({
|
|
9343
|
-
maxValuesPerFacet: Math.max(searchParameters.maxValuesPerFacet || 0, getLimit
|
|
9362
|
+
maxValuesPerFacet: Math.max(searchParameters.maxValuesPerFacet || 0, getLimit(props))
|
|
9344
9363
|
});
|
|
9345
9364
|
searchParameters = searchParameters[addKey](attribute);
|
|
9346
|
-
return getCurrentRefinement$
|
|
9365
|
+
return getCurrentRefinement$4(props, searchState, {
|
|
9347
9366
|
ais: props.contextValue,
|
|
9348
9367
|
multiIndexContext: props.indexContextValue
|
|
9349
9368
|
}).reduce(function (res, val) {
|
|
@@ -9351,7 +9370,7 @@ var connectRefinementList = createConnectorWithContext({
|
|
|
9351
9370
|
}, searchParameters);
|
|
9352
9371
|
},
|
|
9353
9372
|
getMetadata: function getMetadata(props, searchState) {
|
|
9354
|
-
var id = getId$
|
|
9373
|
+
var id = getId$5(props);
|
|
9355
9374
|
var context = {
|
|
9356
9375
|
ais: props.contextValue,
|
|
9357
9376
|
multiIndexContext: props.indexContextValue
|
|
@@ -9359,21 +9378,21 @@ var connectRefinementList = createConnectorWithContext({
|
|
|
9359
9378
|
return {
|
|
9360
9379
|
id: id,
|
|
9361
9380
|
index: getIndexId(context),
|
|
9362
|
-
items: getCurrentRefinement$
|
|
9381
|
+
items: getCurrentRefinement$4(props, searchState, context).length > 0 ? [{
|
|
9363
9382
|
attribute: props.attribute,
|
|
9364
9383
|
label: "".concat(props.attribute, ": "),
|
|
9365
|
-
currentRefinement: getCurrentRefinement$
|
|
9384
|
+
currentRefinement: getCurrentRefinement$4(props, searchState, context),
|
|
9366
9385
|
value: function value(nextState) {
|
|
9367
|
-
return _refine$
|
|
9386
|
+
return _refine$3(props, nextState, [], context);
|
|
9368
9387
|
},
|
|
9369
|
-
items: getCurrentRefinement$
|
|
9388
|
+
items: getCurrentRefinement$4(props, searchState, context).map(function (item) {
|
|
9370
9389
|
return {
|
|
9371
9390
|
label: "".concat(item),
|
|
9372
9391
|
value: function value(nextState) {
|
|
9373
|
-
var nextSelectedItems = getCurrentRefinement$
|
|
9392
|
+
var nextSelectedItems = getCurrentRefinement$4(props, nextState, context).filter(function (other) {
|
|
9374
9393
|
return other !== item;
|
|
9375
9394
|
});
|
|
9376
|
-
return _refine$
|
|
9395
|
+
return _refine$3(props, searchState, nextSelectedItems, context);
|
|
9377
9396
|
}
|
|
9378
9397
|
};
|
|
9379
9398
|
})
|
|
@@ -9432,7 +9451,7 @@ var connectScrollTo = createConnectorWithContext({
|
|
|
9432
9451
|
// See: https://github.com/algolia/react-instantsearch/issues/164
|
|
9433
9452
|
|
|
9434
9453
|
|
|
9435
|
-
var cleanedSearchState = omit(searchState, ['configure', id]);
|
|
9454
|
+
var cleanedSearchState = omit$1(searchState, ['configure', id]);
|
|
9436
9455
|
var hasNotChanged = shallowEqual(this._prevSearchState, cleanedSearchState);
|
|
9437
9456
|
this._prevSearchState = cleanedSearchState;
|
|
9438
9457
|
return {
|
|
@@ -9442,12 +9461,12 @@ var connectScrollTo = createConnectorWithContext({
|
|
|
9442
9461
|
}
|
|
9443
9462
|
});
|
|
9444
9463
|
|
|
9445
|
-
function getId$
|
|
9464
|
+
function getId$4() {
|
|
9446
9465
|
return 'query';
|
|
9447
9466
|
}
|
|
9448
9467
|
|
|
9449
|
-
function getCurrentRefinement$
|
|
9450
|
-
var id = getId$
|
|
9468
|
+
function getCurrentRefinement$3(props, searchState, context) {
|
|
9469
|
+
var id = getId$4();
|
|
9451
9470
|
var currentRefinement = getCurrentRefinementValue(props, searchState, context, id, '');
|
|
9452
9471
|
|
|
9453
9472
|
if (currentRefinement) {
|
|
@@ -9457,8 +9476,8 @@ function getCurrentRefinement$8(props, searchState, context) {
|
|
|
9457
9476
|
return '';
|
|
9458
9477
|
}
|
|
9459
9478
|
|
|
9460
|
-
function _refine$
|
|
9461
|
-
var id = getId$
|
|
9479
|
+
function _refine$2(props, searchState, nextRefinement, context) {
|
|
9480
|
+
var id = getId$4();
|
|
9462
9481
|
|
|
9463
9482
|
var nextValue = _defineProperty({}, id, nextRefinement);
|
|
9464
9483
|
|
|
@@ -9466,8 +9485,8 @@ function _refine$7(props, searchState, nextRefinement, context) {
|
|
|
9466
9485
|
return refineValue(searchState, nextValue, context, resetPage);
|
|
9467
9486
|
}
|
|
9468
9487
|
|
|
9469
|
-
function _cleanUp$
|
|
9470
|
-
return cleanUpValue(searchState, context, getId$
|
|
9488
|
+
function _cleanUp$2(props, searchState, context) {
|
|
9489
|
+
return cleanUpValue(searchState, context, getId$4());
|
|
9471
9490
|
}
|
|
9472
9491
|
/**
|
|
9473
9492
|
* connectSearchBox connector provides the logic to build a widget that will
|
|
@@ -9488,7 +9507,7 @@ var connectSearchBox = createConnectorWithContext({
|
|
|
9488
9507
|
},
|
|
9489
9508
|
getProvidedProps: function getProvidedProps(props, searchState, searchResults) {
|
|
9490
9509
|
return {
|
|
9491
|
-
currentRefinement: getCurrentRefinement$
|
|
9510
|
+
currentRefinement: getCurrentRefinement$3(props, searchState, {
|
|
9492
9511
|
ais: props.contextValue,
|
|
9493
9512
|
multiIndexContext: props.indexContextValue
|
|
9494
9513
|
}),
|
|
@@ -9496,26 +9515,26 @@ var connectSearchBox = createConnectorWithContext({
|
|
|
9496
9515
|
};
|
|
9497
9516
|
},
|
|
9498
9517
|
refine: function refine(props, searchState, nextRefinement) {
|
|
9499
|
-
return _refine$
|
|
9518
|
+
return _refine$2(props, searchState, nextRefinement, {
|
|
9500
9519
|
ais: props.contextValue,
|
|
9501
9520
|
multiIndexContext: props.indexContextValue
|
|
9502
9521
|
});
|
|
9503
9522
|
},
|
|
9504
9523
|
cleanUp: function cleanUp(props, searchState) {
|
|
9505
|
-
return _cleanUp$
|
|
9524
|
+
return _cleanUp$2(props, searchState, {
|
|
9506
9525
|
ais: props.contextValue,
|
|
9507
9526
|
multiIndexContext: props.indexContextValue
|
|
9508
9527
|
});
|
|
9509
9528
|
},
|
|
9510
9529
|
getSearchParameters: function getSearchParameters(searchParameters, props, searchState) {
|
|
9511
|
-
return searchParameters.setQuery(getCurrentRefinement$
|
|
9530
|
+
return searchParameters.setQuery(getCurrentRefinement$3(props, searchState, {
|
|
9512
9531
|
ais: props.contextValue,
|
|
9513
9532
|
multiIndexContext: props.indexContextValue
|
|
9514
9533
|
}));
|
|
9515
9534
|
},
|
|
9516
9535
|
getMetadata: function getMetadata(props, searchState) {
|
|
9517
|
-
var id = getId$
|
|
9518
|
-
var currentRefinement = getCurrentRefinement$
|
|
9536
|
+
var id = getId$4();
|
|
9537
|
+
var currentRefinement = getCurrentRefinement$3(props, searchState, {
|
|
9519
9538
|
ais: props.contextValue,
|
|
9520
9539
|
multiIndexContext: props.indexContextValue
|
|
9521
9540
|
});
|
|
@@ -9528,7 +9547,7 @@ var connectSearchBox = createConnectorWithContext({
|
|
|
9528
9547
|
items: currentRefinement === null ? [] : [{
|
|
9529
9548
|
label: "".concat(id, ": ").concat(currentRefinement),
|
|
9530
9549
|
value: function value(nextState) {
|
|
9531
|
-
return _refine$
|
|
9550
|
+
return _refine$2(props, nextState, '', {
|
|
9532
9551
|
ais: props.contextValue,
|
|
9533
9552
|
multiIndexContext: props.indexContextValue
|
|
9534
9553
|
});
|
|
@@ -9539,12 +9558,12 @@ var connectSearchBox = createConnectorWithContext({
|
|
|
9539
9558
|
}
|
|
9540
9559
|
});
|
|
9541
9560
|
|
|
9542
|
-
function getId$
|
|
9561
|
+
function getId$3() {
|
|
9543
9562
|
return 'relevancyStrictness';
|
|
9544
9563
|
}
|
|
9545
9564
|
|
|
9546
|
-
function getCurrentRefinement$
|
|
9547
|
-
var id = getId$
|
|
9565
|
+
function getCurrentRefinement$2(props, searchState, context) {
|
|
9566
|
+
var id = getId$3();
|
|
9548
9567
|
var currentRefinement = getCurrentRefinementValue(props, searchState, context, id);
|
|
9549
9568
|
return currentRefinement;
|
|
9550
9569
|
}
|
|
@@ -9570,13 +9589,13 @@ var connectRelevantSort = createConnectorWithContext({
|
|
|
9570
9589
|
};
|
|
9571
9590
|
},
|
|
9572
9591
|
getSearchParameters: function getSearchParameters(searchParameters, props, searchState) {
|
|
9573
|
-
return searchParameters.setQueryParameter('relevancyStrictness', getCurrentRefinement$
|
|
9592
|
+
return searchParameters.setQueryParameter('relevancyStrictness', getCurrentRefinement$2(props, searchState, {
|
|
9574
9593
|
ais: props.contextValue,
|
|
9575
9594
|
multiIndexContext: props.indexContextValue
|
|
9576
9595
|
}));
|
|
9577
9596
|
},
|
|
9578
9597
|
refine: function refine(props, searchState, nextRefinement) {
|
|
9579
|
-
var nextValue = _defineProperty({}, getId$
|
|
9598
|
+
var nextValue = _defineProperty({}, getId$3(), nextRefinement);
|
|
9580
9599
|
|
|
9581
9600
|
var resetPage = true;
|
|
9582
9601
|
return refineValue(searchState, nextValue, {
|
|
@@ -9586,12 +9605,12 @@ var connectRelevantSort = createConnectorWithContext({
|
|
|
9586
9605
|
}
|
|
9587
9606
|
});
|
|
9588
9607
|
|
|
9589
|
-
function getId$
|
|
9608
|
+
function getId$2() {
|
|
9590
9609
|
return 'sortBy';
|
|
9591
9610
|
}
|
|
9592
9611
|
|
|
9593
|
-
function getCurrentRefinement$
|
|
9594
|
-
var id = getId$
|
|
9612
|
+
function getCurrentRefinement$1(props, searchState, context) {
|
|
9613
|
+
var id = getId$2();
|
|
9595
9614
|
var currentRefinement = getCurrentRefinementValue(props, searchState, context, id, null);
|
|
9596
9615
|
|
|
9597
9616
|
if (currentRefinement) {
|
|
@@ -9628,7 +9647,7 @@ var connectSortBy = createConnectorWithContext({
|
|
|
9628
9647
|
transformItems: PropTypes.func
|
|
9629
9648
|
},
|
|
9630
9649
|
getProvidedProps: function getProvidedProps(props, searchState) {
|
|
9631
|
-
var currentRefinement = getCurrentRefinement$
|
|
9650
|
+
var currentRefinement = getCurrentRefinement$1(props, searchState, {
|
|
9632
9651
|
ais: props.contextValue,
|
|
9633
9652
|
multiIndexContext: props.indexContextValue
|
|
9634
9653
|
});
|
|
@@ -9645,7 +9664,7 @@ var connectSortBy = createConnectorWithContext({
|
|
|
9645
9664
|
};
|
|
9646
9665
|
},
|
|
9647
9666
|
refine: function refine(props, searchState, nextRefinement) {
|
|
9648
|
-
var id = getId$
|
|
9667
|
+
var id = getId$2();
|
|
9649
9668
|
|
|
9650
9669
|
var nextValue = _defineProperty({}, id, nextRefinement);
|
|
9651
9670
|
|
|
@@ -9659,10 +9678,10 @@ var connectSortBy = createConnectorWithContext({
|
|
|
9659
9678
|
return cleanUpValue(searchState, {
|
|
9660
9679
|
ais: props.contextValue,
|
|
9661
9680
|
multiIndexContext: props.indexContextValue
|
|
9662
|
-
}, getId$
|
|
9681
|
+
}, getId$2());
|
|
9663
9682
|
},
|
|
9664
9683
|
getSearchParameters: function getSearchParameters(searchParameters, props, searchState) {
|
|
9665
|
-
var selectedIndex = getCurrentRefinement$
|
|
9684
|
+
var selectedIndex = getCurrentRefinement$1(props, searchState, {
|
|
9666
9685
|
ais: props.contextValue,
|
|
9667
9686
|
multiIndexContext: props.indexContextValue
|
|
9668
9687
|
});
|
|
@@ -9670,7 +9689,7 @@ var connectSortBy = createConnectorWithContext({
|
|
|
9670
9689
|
},
|
|
9671
9690
|
getMetadata: function getMetadata() {
|
|
9672
9691
|
return {
|
|
9673
|
-
id: getId$
|
|
9692
|
+
id: getId$2()
|
|
9674
9693
|
};
|
|
9675
9694
|
}
|
|
9676
9695
|
});
|
|
@@ -9706,15 +9725,15 @@ var connectStats = createConnectorWithContext({
|
|
|
9706
9725
|
}
|
|
9707
9726
|
});
|
|
9708
9727
|
|
|
9709
|
-
function getId$
|
|
9728
|
+
function getId$1(props) {
|
|
9710
9729
|
return props.attribute;
|
|
9711
9730
|
}
|
|
9712
9731
|
|
|
9713
|
-
var namespace
|
|
9732
|
+
var namespace = 'toggle';
|
|
9714
9733
|
var falsyStrings = ['0', 'false', 'null', 'undefined'];
|
|
9715
9734
|
|
|
9716
|
-
function getCurrentRefinement
|
|
9717
|
-
var currentRefinement = getCurrentRefinementValue(props, searchState, context, "".concat(namespace
|
|
9735
|
+
function getCurrentRefinement(props, searchState, context) {
|
|
9736
|
+
var currentRefinement = getCurrentRefinementValue(props, searchState, context, "".concat(namespace, ".").concat(getId$1(props)), false);
|
|
9718
9737
|
|
|
9719
9738
|
if (falsyStrings.indexOf(currentRefinement) !== -1) {
|
|
9720
9739
|
return false;
|
|
@@ -9723,17 +9742,17 @@ function getCurrentRefinement$b(props, searchState, context) {
|
|
|
9723
9742
|
return Boolean(currentRefinement);
|
|
9724
9743
|
}
|
|
9725
9744
|
|
|
9726
|
-
function _refine$
|
|
9727
|
-
var id = getId$
|
|
9745
|
+
function _refine$1(props, searchState, nextRefinement, context) {
|
|
9746
|
+
var id = getId$1(props);
|
|
9728
9747
|
|
|
9729
9748
|
var nextValue = _defineProperty({}, id, nextRefinement ? nextRefinement : false);
|
|
9730
9749
|
|
|
9731
9750
|
var resetPage = true;
|
|
9732
|
-
return refineValue(searchState, nextValue, context, resetPage, namespace
|
|
9751
|
+
return refineValue(searchState, nextValue, context, resetPage, namespace);
|
|
9733
9752
|
}
|
|
9734
9753
|
|
|
9735
|
-
function _cleanUp$
|
|
9736
|
-
return cleanUpValue(searchState, context, "".concat(namespace
|
|
9754
|
+
function _cleanUp$1(props, searchState, context) {
|
|
9755
|
+
return cleanUpValue(searchState, context, "".concat(namespace, ".").concat(getId$1(props)));
|
|
9737
9756
|
}
|
|
9738
9757
|
/**
|
|
9739
9758
|
* connectToggleRefinement connector provides the logic to build a widget that will
|
|
@@ -9772,14 +9791,14 @@ var connectToggleRefinement = createConnectorWithContext({
|
|
|
9772
9791
|
ais: props.contextValue,
|
|
9773
9792
|
multiIndexContext: props.indexContextValue
|
|
9774
9793
|
});
|
|
9775
|
-
var currentRefinement = getCurrentRefinement
|
|
9794
|
+
var currentRefinement = getCurrentRefinement(props, searchState, {
|
|
9776
9795
|
ais: props.contextValue,
|
|
9777
9796
|
multiIndexContext: props.indexContextValue
|
|
9778
9797
|
});
|
|
9779
9798
|
var allFacetValues = results && results.getFacetByName(attribute) ? results.getFacetValues(attribute) : null;
|
|
9780
9799
|
var facetValue = // Use null to always be consistent with type of the value
|
|
9781
9800
|
// count: number | null
|
|
9782
|
-
allFacetValues && allFacetValues.length ? find(allFacetValues, function (item) {
|
|
9801
|
+
allFacetValues && allFacetValues.length ? find$2(allFacetValues, function (item) {
|
|
9783
9802
|
return item.name === value.toString();
|
|
9784
9803
|
}) : null;
|
|
9785
9804
|
var facetValueCount = facetValue && facetValue.count;
|
|
@@ -9800,13 +9819,13 @@ var connectToggleRefinement = createConnectorWithContext({
|
|
|
9800
9819
|
};
|
|
9801
9820
|
},
|
|
9802
9821
|
refine: function refine(props, searchState, nextRefinement) {
|
|
9803
|
-
return _refine$
|
|
9822
|
+
return _refine$1(props, searchState, nextRefinement, {
|
|
9804
9823
|
ais: props.contextValue,
|
|
9805
9824
|
multiIndexContext: props.indexContextValue
|
|
9806
9825
|
});
|
|
9807
9826
|
},
|
|
9808
9827
|
cleanUp: function cleanUp(props, searchState) {
|
|
9809
|
-
return _cleanUp$
|
|
9828
|
+
return _cleanUp$1(props, searchState, {
|
|
9810
9829
|
ais: props.contextValue,
|
|
9811
9830
|
multiIndexContext: props.indexContextValue
|
|
9812
9831
|
});
|
|
@@ -9815,7 +9834,7 @@ var connectToggleRefinement = createConnectorWithContext({
|
|
|
9815
9834
|
var attribute = props.attribute,
|
|
9816
9835
|
value = props.value,
|
|
9817
9836
|
filter = props.filter;
|
|
9818
|
-
var checked = getCurrentRefinement
|
|
9837
|
+
var checked = getCurrentRefinement(props, searchState, {
|
|
9819
9838
|
ais: props.contextValue,
|
|
9820
9839
|
multiIndexContext: props.indexContextValue
|
|
9821
9840
|
});
|
|
@@ -9832,8 +9851,8 @@ var connectToggleRefinement = createConnectorWithContext({
|
|
|
9832
9851
|
return nextSearchParameters;
|
|
9833
9852
|
},
|
|
9834
9853
|
getMetadata: function getMetadata(props, searchState) {
|
|
9835
|
-
var id = getId$
|
|
9836
|
-
var checked = getCurrentRefinement
|
|
9854
|
+
var id = getId$1(props);
|
|
9855
|
+
var checked = getCurrentRefinement(props, searchState, {
|
|
9837
9856
|
ais: props.contextValue,
|
|
9838
9857
|
multiIndexContext: props.indexContextValue
|
|
9839
9858
|
});
|
|
@@ -9849,7 +9868,7 @@ var connectToggleRefinement = createConnectorWithContext({
|
|
|
9849
9868
|
currentRefinement: checked,
|
|
9850
9869
|
attribute: props.attribute,
|
|
9851
9870
|
value: function value(nextState) {
|
|
9852
|
-
return _refine$
|
|
9871
|
+
return _refine$1(props, nextState, false, {
|
|
9853
9872
|
ais: props.contextValue,
|
|
9854
9873
|
multiIndexContext: props.indexContextValue
|
|
9855
9874
|
});
|
|
@@ -9865,7 +9884,7 @@ var connectToggleRefinement = createConnectorWithContext({
|
|
|
9865
9884
|
}
|
|
9866
9885
|
});
|
|
9867
9886
|
|
|
9868
|
-
function getId
|
|
9887
|
+
function getId() {
|
|
9869
9888
|
return 'query';
|
|
9870
9889
|
}
|
|
9871
9890
|
|
|
@@ -9874,7 +9893,7 @@ function getAdditionalId() {
|
|
|
9874
9893
|
}
|
|
9875
9894
|
|
|
9876
9895
|
function getCurrentRefinementQuery(props, searchState, context) {
|
|
9877
|
-
var id = getId
|
|
9896
|
+
var id = getId();
|
|
9878
9897
|
var currentRefinement = getCurrentRefinementValue(props, searchState, context, id, '');
|
|
9879
9898
|
|
|
9880
9899
|
if (currentRefinement) {
|
|
@@ -9895,10 +9914,10 @@ function getCurrentRefinementAdditional(props, searchState, context) {
|
|
|
9895
9914
|
return {};
|
|
9896
9915
|
}
|
|
9897
9916
|
|
|
9898
|
-
function _refine
|
|
9917
|
+
function _refine(props, searchState, nextRefinement, context) {
|
|
9899
9918
|
var _nextValue;
|
|
9900
9919
|
|
|
9901
|
-
var id = getId
|
|
9920
|
+
var id = getId();
|
|
9902
9921
|
var voiceParams = getAdditionalId();
|
|
9903
9922
|
var queryLanguages = props.language ? {
|
|
9904
9923
|
queryLanguages: [props.language.split('-')[0]]
|
|
@@ -9915,8 +9934,8 @@ function _refine$9(props, searchState, nextRefinement, context) {
|
|
|
9915
9934
|
return refineValue(searchState, nextValue, context, resetPage);
|
|
9916
9935
|
}
|
|
9917
9936
|
|
|
9918
|
-
function _cleanUp
|
|
9919
|
-
var interimState = cleanUpValue(searchState, context, getId
|
|
9937
|
+
function _cleanUp(props, searchState, context) {
|
|
9938
|
+
var interimState = cleanUpValue(searchState, context, getId());
|
|
9920
9939
|
return cleanUpValue(interimState, context, getAdditionalId());
|
|
9921
9940
|
}
|
|
9922
9941
|
|
|
@@ -9935,13 +9954,13 @@ var connectVoiceSearch = createConnectorWithContext({
|
|
|
9935
9954
|
};
|
|
9936
9955
|
},
|
|
9937
9956
|
refine: function refine(props, searchState, nextRefinement) {
|
|
9938
|
-
return _refine
|
|
9957
|
+
return _refine(props, searchState, nextRefinement, {
|
|
9939
9958
|
ais: props.contextValue,
|
|
9940
9959
|
multiIndexContext: props.indexContextValue
|
|
9941
9960
|
});
|
|
9942
9961
|
},
|
|
9943
9962
|
cleanUp: function cleanUp(props, searchState) {
|
|
9944
|
-
return _cleanUp
|
|
9963
|
+
return _cleanUp(props, searchState, {
|
|
9945
9964
|
ais: props.contextValue,
|
|
9946
9965
|
multiIndexContext: props.indexContextValue
|
|
9947
9966
|
});
|
|
@@ -9958,7 +9977,7 @@ var connectVoiceSearch = createConnectorWithContext({
|
|
|
9958
9977
|
return searchParameters.setQuery(query).setQueryParameters(additionalParams);
|
|
9959
9978
|
},
|
|
9960
9979
|
getMetadata: function getMetadata(props, searchState) {
|
|
9961
|
-
var id = getId
|
|
9980
|
+
var id = getId();
|
|
9962
9981
|
var currentRefinement = getCurrentRefinementQuery(props, searchState, {
|
|
9963
9982
|
ais: props.contextValue,
|
|
9964
9983
|
multiIndexContext: props.indexContextValue
|
|
@@ -9972,7 +9991,7 @@ var connectVoiceSearch = createConnectorWithContext({
|
|
|
9972
9991
|
items: currentRefinement === null ? [] : [{
|
|
9973
9992
|
label: "".concat(id, ": ").concat(currentRefinement),
|
|
9974
9993
|
value: function value(nextState) {
|
|
9975
|
-
return _refine
|
|
9994
|
+
return _refine(props, nextState, '', {
|
|
9976
9995
|
ais: props.contextValue,
|
|
9977
9996
|
multiIndexContext: props.indexContextValue
|
|
9978
9997
|
});
|
|
@@ -10025,7 +10044,7 @@ function range(_ref) {
|
|
|
10025
10044
|
return (start + current) * limitStep;
|
|
10026
10045
|
});
|
|
10027
10046
|
}
|
|
10028
|
-
function find
|
|
10047
|
+
function find(array, comparator) {
|
|
10029
10048
|
if (!Array.isArray(array)) {
|
|
10030
10049
|
return undefined;
|
|
10031
10050
|
}
|
|
@@ -10039,11 +10058,11 @@ function find$2(array, comparator) {
|
|
|
10039
10058
|
return undefined;
|
|
10040
10059
|
}
|
|
10041
10060
|
|
|
10042
|
-
var cx = createClassNames('Panel');
|
|
10061
|
+
var cx$p = createClassNames('Panel');
|
|
10043
10062
|
|
|
10044
|
-
var _createContext
|
|
10045
|
-
PanelConsumer = _createContext
|
|
10046
|
-
PanelProvider = _createContext
|
|
10063
|
+
var _createContext = createContext(function setCanRefine() {}),
|
|
10064
|
+
PanelConsumer = _createContext.Consumer,
|
|
10065
|
+
PanelProvider = _createContext.Provider;
|
|
10047
10066
|
|
|
10048
10067
|
var Panel =
|
|
10049
10068
|
/*#__PURE__*/
|
|
@@ -10085,16 +10104,16 @@ function (_Component) {
|
|
|
10085
10104
|
header = _this$props.header,
|
|
10086
10105
|
footer = _this$props.footer;
|
|
10087
10106
|
var canRefine = this.state.canRefine;
|
|
10088
|
-
return
|
|
10089
|
-
className: classnames(cx('', !canRefine && '-noRefinement'), className)
|
|
10090
|
-
}, header &&
|
|
10091
|
-
className: cx('header')
|
|
10092
|
-
}, header),
|
|
10093
|
-
className: cx('body')
|
|
10094
|
-
},
|
|
10107
|
+
return React.createElement("div", {
|
|
10108
|
+
className: classnames(cx$p('', !canRefine && '-noRefinement'), className)
|
|
10109
|
+
}, header && React.createElement("div", {
|
|
10110
|
+
className: cx$p('header')
|
|
10111
|
+
}, header), React.createElement("div", {
|
|
10112
|
+
className: cx$p('body')
|
|
10113
|
+
}, React.createElement(PanelProvider, {
|
|
10095
10114
|
value: this.setCanRefine
|
|
10096
|
-
}, children)), footer &&
|
|
10097
|
-
className: cx('footer')
|
|
10115
|
+
}, children)), footer && React.createElement("div", {
|
|
10116
|
+
className: cx$p('footer')
|
|
10098
10117
|
}, footer));
|
|
10099
10118
|
}
|
|
10100
10119
|
}]);
|
|
@@ -10157,8 +10176,8 @@ _defineProperty(PanelCallbackHandler, "propTypes", {
|
|
|
10157
10176
|
var PanelWrapper = function PanelWrapper(_ref) {
|
|
10158
10177
|
var canRefine = _ref.canRefine,
|
|
10159
10178
|
children = _ref.children;
|
|
10160
|
-
return
|
|
10161
|
-
return
|
|
10179
|
+
return React.createElement(PanelConsumer, null, function (setCanRefine) {
|
|
10180
|
+
return React.createElement(PanelCallbackHandler, {
|
|
10162
10181
|
setCanRefine: setCanRefine,
|
|
10163
10182
|
canRefine: canRefine
|
|
10164
10183
|
}, children);
|
|
@@ -10204,7 +10223,7 @@ function (_Component) {
|
|
|
10204
10223
|
_createClass(Link, [{
|
|
10205
10224
|
key: "render",
|
|
10206
10225
|
value: function render() {
|
|
10207
|
-
return
|
|
10226
|
+
return React.createElement("a", _extends({}, this.props, {
|
|
10208
10227
|
onClick: this.onClick
|
|
10209
10228
|
}));
|
|
10210
10229
|
}
|
|
@@ -10217,8 +10236,8 @@ _defineProperty(Link, "propTypes", {
|
|
|
10217
10236
|
onClick: PropTypes.func.isRequired
|
|
10218
10237
|
});
|
|
10219
10238
|
|
|
10220
|
-
var cx$
|
|
10221
|
-
var itemsPropType = PropTypes.arrayOf(PropTypes.shape({
|
|
10239
|
+
var cx$o = createClassNames('Breadcrumb');
|
|
10240
|
+
var itemsPropType$2 = PropTypes.arrayOf(PropTypes.shape({
|
|
10222
10241
|
label: PropTypes.string.isRequired,
|
|
10223
10242
|
value: PropTypes.string.isRequired
|
|
10224
10243
|
}));
|
|
@@ -10246,10 +10265,10 @@ function (_Component) {
|
|
|
10246
10265
|
separator = _this$props.separator,
|
|
10247
10266
|
translate = _this$props.translate,
|
|
10248
10267
|
className = _this$props.className;
|
|
10249
|
-
var rootPath = canRefine ?
|
|
10250
|
-
className: cx$
|
|
10251
|
-
},
|
|
10252
|
-
className: cx$
|
|
10268
|
+
var rootPath = canRefine ? React.createElement("li", {
|
|
10269
|
+
className: cx$o('item')
|
|
10270
|
+
}, React.createElement(Link, {
|
|
10271
|
+
className: cx$o('link'),
|
|
10253
10272
|
onClick: function onClick() {
|
|
10254
10273
|
return !rootURL ? refine() : null;
|
|
10255
10274
|
},
|
|
@@ -10257,23 +10276,23 @@ function (_Component) {
|
|
|
10257
10276
|
}, translate('rootLabel'))) : null;
|
|
10258
10277
|
var breadcrumb = items.map(function (item, idx) {
|
|
10259
10278
|
var isLast = idx === items.length - 1;
|
|
10260
|
-
return
|
|
10261
|
-
className: cx$
|
|
10279
|
+
return React.createElement("li", {
|
|
10280
|
+
className: cx$o('item', isLast && 'item--selected'),
|
|
10262
10281
|
key: idx
|
|
10263
|
-
},
|
|
10264
|
-
className: cx$
|
|
10265
|
-
}, separator), !isLast ?
|
|
10266
|
-
className: cx$
|
|
10282
|
+
}, React.createElement("span", {
|
|
10283
|
+
className: cx$o('separator')
|
|
10284
|
+
}, separator), !isLast ? React.createElement(Link, {
|
|
10285
|
+
className: cx$o('link'),
|
|
10267
10286
|
onClick: function onClick() {
|
|
10268
10287
|
return refine(item.value);
|
|
10269
10288
|
},
|
|
10270
10289
|
href: createURL(item.value)
|
|
10271
10290
|
}, item.label) : item.label);
|
|
10272
10291
|
});
|
|
10273
|
-
return
|
|
10274
|
-
className: classnames(cx$
|
|
10275
|
-
},
|
|
10276
|
-
className: cx$
|
|
10292
|
+
return React.createElement("div", {
|
|
10293
|
+
className: classnames(cx$o('', !canRefine && '-noRefinement'), className)
|
|
10294
|
+
}, React.createElement("ul", {
|
|
10295
|
+
className: cx$o('list')
|
|
10277
10296
|
}, rootPath, breadcrumb));
|
|
10278
10297
|
}
|
|
10279
10298
|
}]);
|
|
@@ -10284,7 +10303,7 @@ function (_Component) {
|
|
|
10284
10303
|
_defineProperty(Breadcrumb, "propTypes", {
|
|
10285
10304
|
canRefine: PropTypes.bool.isRequired,
|
|
10286
10305
|
createURL: PropTypes.func.isRequired,
|
|
10287
|
-
items: itemsPropType,
|
|
10306
|
+
items: itemsPropType$2,
|
|
10288
10307
|
refine: PropTypes.func.isRequired,
|
|
10289
10308
|
rootURL: PropTypes.string,
|
|
10290
10309
|
separator: PropTypes.node,
|
|
@@ -10391,12 +10410,12 @@ var Breadcrumb$1 = translatable({
|
|
|
10391
10410
|
*/
|
|
10392
10411
|
|
|
10393
10412
|
var BreadcrumbWidget = function BreadcrumbWidget(props) {
|
|
10394
|
-
return
|
|
10413
|
+
return React.createElement(PanelWrapper, props, React.createElement(Breadcrumb$1, props));
|
|
10395
10414
|
};
|
|
10396
10415
|
|
|
10397
10416
|
connectBreadcrumb(BreadcrumbWidget);
|
|
10398
10417
|
|
|
10399
|
-
var cx$
|
|
10418
|
+
var cx$n = createClassNames('ClearRefinements');
|
|
10400
10419
|
|
|
10401
10420
|
var ClearRefinements =
|
|
10402
10421
|
/*#__PURE__*/
|
|
@@ -10418,10 +10437,10 @@ function (_Component) {
|
|
|
10418
10437
|
refine = _this$props.refine,
|
|
10419
10438
|
translate = _this$props.translate,
|
|
10420
10439
|
className = _this$props.className;
|
|
10421
|
-
return
|
|
10422
|
-
className: classnames(cx$
|
|
10423
|
-
},
|
|
10424
|
-
className: cx$
|
|
10440
|
+
return React.createElement("div", {
|
|
10441
|
+
className: classnames(cx$n(''), className)
|
|
10442
|
+
}, React.createElement("button", {
|
|
10443
|
+
className: cx$n('button', !canRefine && 'button--disabled'),
|
|
10425
10444
|
onClick: function onClick() {
|
|
10426
10445
|
return refine(items);
|
|
10427
10446
|
},
|
|
@@ -10484,44 +10503,44 @@ var ClearRefinements$1 = translatable({
|
|
|
10484
10503
|
*/
|
|
10485
10504
|
|
|
10486
10505
|
var ClearRefinementsWidget = function ClearRefinementsWidget(props) {
|
|
10487
|
-
return
|
|
10506
|
+
return React.createElement(PanelWrapper, props, React.createElement(ClearRefinements$1, props));
|
|
10488
10507
|
};
|
|
10489
10508
|
|
|
10490
10509
|
connectCurrentRefinements(ClearRefinementsWidget);
|
|
10491
10510
|
|
|
10492
|
-
var cx$
|
|
10511
|
+
var cx$m = createClassNames('CurrentRefinements');
|
|
10493
10512
|
var CurrentRefinements = function CurrentRefinements(_ref) {
|
|
10494
10513
|
var items = _ref.items,
|
|
10495
10514
|
canRefine = _ref.canRefine,
|
|
10496
10515
|
refine = _ref.refine,
|
|
10497
10516
|
translate = _ref.translate,
|
|
10498
10517
|
className = _ref.className;
|
|
10499
|
-
return
|
|
10500
|
-
className: classnames(cx$
|
|
10501
|
-
},
|
|
10502
|
-
className: cx$
|
|
10518
|
+
return React.createElement("div", {
|
|
10519
|
+
className: classnames(cx$m('', !canRefine && '-noRefinement'), className)
|
|
10520
|
+
}, React.createElement("ul", {
|
|
10521
|
+
className: cx$m('list', !canRefine && 'list--noRefinement')
|
|
10503
10522
|
}, items.map(function (item) {
|
|
10504
|
-
return
|
|
10523
|
+
return React.createElement("li", {
|
|
10505
10524
|
key: item.label,
|
|
10506
|
-
className: cx$
|
|
10507
|
-
},
|
|
10508
|
-
className: cx$
|
|
10525
|
+
className: cx$m('item')
|
|
10526
|
+
}, React.createElement("span", {
|
|
10527
|
+
className: cx$m('label')
|
|
10509
10528
|
}, item.label), item.items ? item.items.map(function (nest) {
|
|
10510
|
-
return
|
|
10529
|
+
return React.createElement("span", {
|
|
10511
10530
|
key: nest.label,
|
|
10512
|
-
className: cx$
|
|
10513
|
-
},
|
|
10514
|
-
className: cx$
|
|
10515
|
-
}, nest.label),
|
|
10516
|
-
className: cx$
|
|
10531
|
+
className: cx$m('category')
|
|
10532
|
+
}, React.createElement("span", {
|
|
10533
|
+
className: cx$m('categoryLabel')
|
|
10534
|
+
}, nest.label), React.createElement("button", {
|
|
10535
|
+
className: cx$m('delete'),
|
|
10517
10536
|
onClick: function onClick() {
|
|
10518
10537
|
return refine(nest.value);
|
|
10519
10538
|
}
|
|
10520
10539
|
}, translate('clearFilter', nest)));
|
|
10521
|
-
}) :
|
|
10522
|
-
className: cx$
|
|
10523
|
-
},
|
|
10524
|
-
className: cx$
|
|
10540
|
+
}) : React.createElement("span", {
|
|
10541
|
+
className: cx$m('category')
|
|
10542
|
+
}, React.createElement("button", {
|
|
10543
|
+
className: cx$m('delete'),
|
|
10525
10544
|
onClick: function onClick() {
|
|
10526
10545
|
return refine(item.value);
|
|
10527
10546
|
}
|
|
@@ -10592,33 +10611,33 @@ var CurrentRefinements$1 = translatable({
|
|
|
10592
10611
|
*/
|
|
10593
10612
|
|
|
10594
10613
|
var CurrentRefinementsWidget = function CurrentRefinementsWidget(props) {
|
|
10595
|
-
return
|
|
10614
|
+
return React.createElement(PanelWrapper, props, React.createElement(CurrentRefinements$1, props));
|
|
10596
10615
|
};
|
|
10597
10616
|
|
|
10598
10617
|
connectCurrentRefinements(CurrentRefinementsWidget);
|
|
10599
10618
|
|
|
10600
|
-
var cx$
|
|
10601
|
-
var defaultLoadingIndicator =
|
|
10619
|
+
var cx$l = createClassNames('SearchBox');
|
|
10620
|
+
var defaultLoadingIndicator = React.createElement("svg", {
|
|
10602
10621
|
width: "18",
|
|
10603
10622
|
height: "18",
|
|
10604
10623
|
viewBox: "0 0 38 38",
|
|
10605
10624
|
xmlns: "http://www.w3.org/2000/svg",
|
|
10606
10625
|
stroke: "#444",
|
|
10607
|
-
className: cx$
|
|
10608
|
-
},
|
|
10626
|
+
className: cx$l('loadingIcon')
|
|
10627
|
+
}, React.createElement("g", {
|
|
10609
10628
|
fill: "none",
|
|
10610
10629
|
fillRule: "evenodd"
|
|
10611
|
-
},
|
|
10630
|
+
}, React.createElement("g", {
|
|
10612
10631
|
transform: "translate(1 1)",
|
|
10613
10632
|
strokeWidth: "2"
|
|
10614
|
-
},
|
|
10633
|
+
}, React.createElement("circle", {
|
|
10615
10634
|
strokeOpacity: ".5",
|
|
10616
10635
|
cx: "18",
|
|
10617
10636
|
cy: "18",
|
|
10618
10637
|
r: "18"
|
|
10619
|
-
}),
|
|
10638
|
+
}), React.createElement("path", {
|
|
10620
10639
|
d: "M36 18c0-9.94-8.06-18-18-18"
|
|
10621
|
-
},
|
|
10640
|
+
}, React.createElement("animateTransform", {
|
|
10622
10641
|
attributeName: "transform",
|
|
10623
10642
|
type: "rotate",
|
|
10624
10643
|
from: "0 18 18",
|
|
@@ -10626,26 +10645,26 @@ var defaultLoadingIndicator = React__default.createElement("svg", {
|
|
|
10626
10645
|
dur: "1s",
|
|
10627
10646
|
repeatCount: "indefinite"
|
|
10628
10647
|
})))));
|
|
10629
|
-
var defaultReset =
|
|
10630
|
-
className: cx$
|
|
10648
|
+
var defaultReset = React.createElement("svg", {
|
|
10649
|
+
className: cx$l('resetIcon'),
|
|
10631
10650
|
xmlns: "http://www.w3.org/2000/svg",
|
|
10632
10651
|
viewBox: "0 0 20 20",
|
|
10633
10652
|
width: "10",
|
|
10634
10653
|
height: "10"
|
|
10635
|
-
},
|
|
10654
|
+
}, React.createElement("path", {
|
|
10636
10655
|
d: "M8.114 10L.944 2.83 0 1.885 1.886 0l.943.943L10 8.113l7.17-7.17.944-.943L20 1.886l-.943.943-7.17 7.17 7.17 7.17.943.944L18.114 20l-.943-.943-7.17-7.17-7.17 7.17-.944.943L0 18.114l.943-.943L8.113 10z"
|
|
10637
10656
|
}));
|
|
10638
|
-
var defaultSubmit =
|
|
10639
|
-
className: cx$
|
|
10657
|
+
var defaultSubmit = React.createElement("svg", {
|
|
10658
|
+
className: cx$l('submitIcon'),
|
|
10640
10659
|
xmlns: "http://www.w3.org/2000/svg",
|
|
10641
10660
|
width: "10",
|
|
10642
10661
|
height: "10",
|
|
10643
10662
|
viewBox: "0 0 40 40"
|
|
10644
|
-
},
|
|
10663
|
+
}, React.createElement("path", {
|
|
10645
10664
|
d: "M26.804 29.01c-2.832 2.34-6.465 3.746-10.426 3.746C7.333 32.756 0 25.424 0 16.378 0 7.333 7.333 0 16.378 0c9.046 0 16.378 7.333 16.378 16.378 0 3.96-1.406 7.594-3.746 10.426l10.534 10.534c.607.607.61 1.59-.004 2.202-.61.61-1.597.61-2.202.004L26.804 29.01zm-10.426.627c7.323 0 13.26-5.936 13.26-13.26 0-7.32-5.937-13.257-13.26-13.257C9.056 3.12 3.12 9.056 3.12 16.378c0 7.323 5.936 13.26 13.258 13.26z"
|
|
10646
10665
|
}));
|
|
10647
10666
|
|
|
10648
|
-
var SearchBox =
|
|
10667
|
+
var SearchBox$1 =
|
|
10649
10668
|
/*#__PURE__*/
|
|
10650
10669
|
function (_Component) {
|
|
10651
10670
|
_inherits(SearchBox, _Component);
|
|
@@ -10807,16 +10826,16 @@ function (_Component) {
|
|
|
10807
10826
|
var isSearchStalled = this.props.showLoadingIndicator && this.props.isSearchStalled;
|
|
10808
10827
|
/* eslint-disable max-len */
|
|
10809
10828
|
|
|
10810
|
-
return
|
|
10811
|
-
className: classnames(cx$
|
|
10812
|
-
},
|
|
10829
|
+
return React.createElement("div", {
|
|
10830
|
+
className: classnames(cx$l(''), className)
|
|
10831
|
+
}, React.createElement("form", {
|
|
10813
10832
|
noValidate: true,
|
|
10814
10833
|
onSubmit: this.props.onSubmit ? this.props.onSubmit : this.onSubmit,
|
|
10815
10834
|
onReset: this.onReset,
|
|
10816
|
-
className: cx$
|
|
10835
|
+
className: cx$l('form', isSearchStalled && 'form--stalledSearch'),
|
|
10817
10836
|
action: "",
|
|
10818
10837
|
role: "search"
|
|
10819
|
-
},
|
|
10838
|
+
}, React.createElement("input", _extends({
|
|
10820
10839
|
ref: this.onInputMount,
|
|
10821
10840
|
type: "search",
|
|
10822
10841
|
placeholder: translate('placeholder'),
|
|
@@ -10830,19 +10849,19 @@ function (_Component) {
|
|
|
10830
10849
|
value: query,
|
|
10831
10850
|
onChange: this.onChange
|
|
10832
10851
|
}, searchInputEvents, {
|
|
10833
|
-
className: cx$
|
|
10834
|
-
})),
|
|
10852
|
+
className: cx$l('input')
|
|
10853
|
+
})), React.createElement("button", {
|
|
10835
10854
|
type: "submit",
|
|
10836
10855
|
title: translate('submitTitle'),
|
|
10837
|
-
className: cx$
|
|
10838
|
-
}, submit),
|
|
10856
|
+
className: cx$l('submit')
|
|
10857
|
+
}, submit), React.createElement("button", {
|
|
10839
10858
|
type: "reset",
|
|
10840
10859
|
title: translate('resetTitle'),
|
|
10841
|
-
className: cx$
|
|
10860
|
+
className: cx$l('reset'),
|
|
10842
10861
|
hidden: !query || isSearchStalled
|
|
10843
|
-
}, reset), this.props.showLoadingIndicator &&
|
|
10862
|
+
}, reset), this.props.showLoadingIndicator && React.createElement("span", {
|
|
10844
10863
|
hidden: !isSearchStalled,
|
|
10845
|
-
className: cx$
|
|
10864
|
+
className: cx$l('loadingIndicator')
|
|
10846
10865
|
}, loadingIndicator)));
|
|
10847
10866
|
/* eslint-enable */
|
|
10848
10867
|
}
|
|
@@ -10851,7 +10870,7 @@ function (_Component) {
|
|
|
10851
10870
|
return SearchBox;
|
|
10852
10871
|
}(Component);
|
|
10853
10872
|
|
|
10854
|
-
_defineProperty(SearchBox, "propTypes", {
|
|
10873
|
+
_defineProperty(SearchBox$1, "propTypes", {
|
|
10855
10874
|
currentRefinement: PropTypes.string,
|
|
10856
10875
|
className: PropTypes.string,
|
|
10857
10876
|
refine: PropTypes.func.isRequired,
|
|
@@ -10872,7 +10891,7 @@ _defineProperty(SearchBox, "propTypes", {
|
|
|
10872
10891
|
})])
|
|
10873
10892
|
});
|
|
10874
10893
|
|
|
10875
|
-
_defineProperty(SearchBox, "defaultProps", {
|
|
10894
|
+
_defineProperty(SearchBox$1, "defaultProps", {
|
|
10876
10895
|
currentRefinement: '',
|
|
10877
10896
|
className: '',
|
|
10878
10897
|
focusShortcuts: ['s', '/'],
|
|
@@ -10885,11 +10904,11 @@ _defineProperty(SearchBox, "defaultProps", {
|
|
|
10885
10904
|
submit: defaultSubmit
|
|
10886
10905
|
});
|
|
10887
10906
|
|
|
10888
|
-
var SearchBox$
|
|
10907
|
+
var SearchBox$2 = translatable({
|
|
10889
10908
|
resetTitle: 'Clear the search query.',
|
|
10890
10909
|
submitTitle: 'Submit your search query.',
|
|
10891
10910
|
placeholder: 'Search here…'
|
|
10892
|
-
})(SearchBox);
|
|
10911
|
+
})(SearchBox$1);
|
|
10893
10912
|
|
|
10894
10913
|
var itemsPropType$1 = PropTypes.arrayOf(PropTypes.shape({
|
|
10895
10914
|
value: PropTypes.any,
|
|
@@ -10935,10 +10954,10 @@ function (_Component) {
|
|
|
10935
10954
|
|
|
10936
10955
|
_defineProperty(_assertThisInitialized(_this), "renderItem", function (item, resetQuery) {
|
|
10937
10956
|
var itemHasChildren = item.items && Boolean(item.items.length);
|
|
10938
|
-
return
|
|
10957
|
+
return React.createElement("li", {
|
|
10939
10958
|
key: item.key || item.label,
|
|
10940
10959
|
className: _this.props.cx('item', item.isRefined && 'item--selected', item.noRefinement && 'item--noRefinement', itemHasChildren && 'item--parent')
|
|
10941
|
-
}, _this.props.renderItem(item, resetQuery), itemHasChildren &&
|
|
10960
|
+
}, _this.props.renderItem(item, resetQuery), itemHasChildren && React.createElement("ul", {
|
|
10942
10961
|
className: _this.props.cx('list', 'list--child')
|
|
10943
10962
|
}, item.items.slice(0, _this.getLimit()).map(function (child) {
|
|
10944
10963
|
return _this.renderItem(child, item);
|
|
@@ -10966,7 +10985,7 @@ function (_Component) {
|
|
|
10966
10985
|
return null;
|
|
10967
10986
|
}
|
|
10968
10987
|
|
|
10969
|
-
return
|
|
10988
|
+
return React.createElement("button", {
|
|
10970
10989
|
disabled: disabled,
|
|
10971
10990
|
className: cx('showMore', disabled && 'showMore--disabled'),
|
|
10972
10991
|
onClick: this.onShowMoreClick
|
|
@@ -10984,12 +11003,12 @@ function (_Component) {
|
|
|
10984
11003
|
translate = _this$props3.translate,
|
|
10985
11004
|
items = _this$props3.items,
|
|
10986
11005
|
selectItem = _this$props3.selectItem;
|
|
10987
|
-
var noResults = items.length === 0 && this.state.query !== '' ?
|
|
11006
|
+
var noResults = items.length === 0 && this.state.query !== '' ? React.createElement("div", {
|
|
10988
11007
|
className: cx('noResults')
|
|
10989
11008
|
}, translate('noResults')) : null;
|
|
10990
|
-
return
|
|
11009
|
+
return React.createElement("div", {
|
|
10991
11010
|
className: cx('searchBox')
|
|
10992
|
-
},
|
|
11011
|
+
}, React.createElement(SearchBox$2, {
|
|
10993
11012
|
currentRefinement: this.state.query,
|
|
10994
11013
|
refine: function refine(value) {
|
|
10995
11014
|
_this2.setState({
|
|
@@ -11025,7 +11044,7 @@ function (_Component) {
|
|
|
11025
11044
|
var rootClassName = classnames(cx('', !canRefine && '-noRefinement'), className);
|
|
11026
11045
|
|
|
11027
11046
|
if (items.length === 0) {
|
|
11028
|
-
return
|
|
11047
|
+
return React.createElement("div", {
|
|
11029
11048
|
className: rootClassName
|
|
11030
11049
|
}, searchBox);
|
|
11031
11050
|
} // Always limit the number of items we show on screen, since the actual
|
|
@@ -11033,9 +11052,9 @@ function (_Component) {
|
|
|
11033
11052
|
// option.
|
|
11034
11053
|
|
|
11035
11054
|
|
|
11036
|
-
return
|
|
11055
|
+
return React.createElement("div", {
|
|
11037
11056
|
className: rootClassName
|
|
11038
|
-
}, searchBox,
|
|
11057
|
+
}, searchBox, React.createElement("ul", {
|
|
11039
11058
|
className: cx('list', !canRefine && 'list--noRefinement')
|
|
11040
11059
|
}, items.slice(0, this.getLimit()).map(function (item) {
|
|
11041
11060
|
return _this3.renderItem(item, _this3.resetQuery);
|
|
@@ -11069,13 +11088,13 @@ _defineProperty(List, "defaultProps", {
|
|
|
11069
11088
|
isFromSearch: false
|
|
11070
11089
|
});
|
|
11071
11090
|
|
|
11072
|
-
var cx$
|
|
11073
|
-
var itemsPropType
|
|
11091
|
+
var cx$k = createClassNames('HierarchicalMenu');
|
|
11092
|
+
var itemsPropType = PropTypes.arrayOf(PropTypes.shape({
|
|
11074
11093
|
label: PropTypes.string.isRequired,
|
|
11075
11094
|
value: PropTypes.string,
|
|
11076
11095
|
count: PropTypes.number.isRequired,
|
|
11077
11096
|
items: function items() {
|
|
11078
|
-
return itemsPropType
|
|
11097
|
+
return itemsPropType.apply(void 0, arguments);
|
|
11079
11098
|
}
|
|
11080
11099
|
}));
|
|
11081
11100
|
|
|
@@ -11101,16 +11120,16 @@ function (_Component) {
|
|
|
11101
11120
|
var _this$props = _this.props,
|
|
11102
11121
|
createURL = _this$props.createURL,
|
|
11103
11122
|
refine = _this$props.refine;
|
|
11104
|
-
return
|
|
11105
|
-
className: cx$
|
|
11123
|
+
return React.createElement(Link, {
|
|
11124
|
+
className: cx$k('link'),
|
|
11106
11125
|
onClick: function onClick() {
|
|
11107
11126
|
return refine(item.value);
|
|
11108
11127
|
},
|
|
11109
11128
|
href: createURL(item.value)
|
|
11110
|
-
},
|
|
11111
|
-
className: cx$
|
|
11112
|
-
}, item.label), ' ',
|
|
11113
|
-
className: cx$
|
|
11129
|
+
}, React.createElement("span", {
|
|
11130
|
+
className: cx$k('label')
|
|
11131
|
+
}, item.label), ' ', React.createElement("span", {
|
|
11132
|
+
className: cx$k('count')
|
|
11114
11133
|
}, item.count));
|
|
11115
11134
|
});
|
|
11116
11135
|
|
|
@@ -11128,9 +11147,9 @@ function (_Component) {
|
|
|
11128
11147
|
showMoreLimit = _this$props2.showMoreLimit,
|
|
11129
11148
|
canRefine = _this$props2.canRefine,
|
|
11130
11149
|
className = _this$props2.className;
|
|
11131
|
-
return
|
|
11150
|
+
return React.createElement(List, {
|
|
11132
11151
|
renderItem: this.renderItem,
|
|
11133
|
-
cx: cx$
|
|
11152
|
+
cx: cx$k,
|
|
11134
11153
|
translate: translate,
|
|
11135
11154
|
items: items,
|
|
11136
11155
|
showMore: showMore,
|
|
@@ -11150,7 +11169,7 @@ _defineProperty(HierarchicalMenu, "propTypes", {
|
|
|
11150
11169
|
refine: PropTypes.func.isRequired,
|
|
11151
11170
|
createURL: PropTypes.func.isRequired,
|
|
11152
11171
|
canRefine: PropTypes.bool.isRequired,
|
|
11153
|
-
items: itemsPropType
|
|
11172
|
+
items: itemsPropType,
|
|
11154
11173
|
showMore: PropTypes.bool,
|
|
11155
11174
|
className: PropTypes.string,
|
|
11156
11175
|
limit: PropTypes.number,
|
|
@@ -11259,12 +11278,12 @@ var HierarchicalMenu$1 = translatable({
|
|
|
11259
11278
|
*/
|
|
11260
11279
|
|
|
11261
11280
|
var HierarchicalMenuWidget = function HierarchicalMenuWidget(props) {
|
|
11262
|
-
return
|
|
11281
|
+
return React.createElement(PanelWrapper, props, React.createElement(HierarchicalMenu$1, props));
|
|
11263
11282
|
};
|
|
11264
11283
|
|
|
11265
11284
|
connectHierarchicalMenu(HierarchicalMenuWidget);
|
|
11266
11285
|
|
|
11267
|
-
var Highlight = function Highlight(_ref) {
|
|
11286
|
+
var Highlight$2 = function Highlight(_ref) {
|
|
11268
11287
|
var cx = _ref.cx,
|
|
11269
11288
|
value = _ref.value,
|
|
11270
11289
|
highlightedTagName = _ref.highlightedTagName,
|
|
@@ -11272,11 +11291,11 @@ var Highlight = function Highlight(_ref) {
|
|
|
11272
11291
|
nonHighlightedTagName = _ref.nonHighlightedTagName;
|
|
11273
11292
|
var TagName = isHighlighted ? highlightedTagName : nonHighlightedTagName;
|
|
11274
11293
|
var className = isHighlighted ? 'highlighted' : 'nonHighlighted';
|
|
11275
|
-
return
|
|
11294
|
+
return React.createElement(TagName, {
|
|
11276
11295
|
className: cx(className)
|
|
11277
11296
|
}, value);
|
|
11278
11297
|
};
|
|
11279
|
-
Highlight.propTypes = {
|
|
11298
|
+
Highlight$2.propTypes = {
|
|
11280
11299
|
cx: PropTypes.func.isRequired,
|
|
11281
11300
|
value: PropTypes.string.isRequired,
|
|
11282
11301
|
isHighlighted: PropTypes.bool.isRequired,
|
|
@@ -11299,15 +11318,15 @@ var Highlighter = function Highlighter(_ref2) {
|
|
|
11299
11318
|
attribute: attribute,
|
|
11300
11319
|
highlightProperty: highlightProperty
|
|
11301
11320
|
});
|
|
11302
|
-
return
|
|
11321
|
+
return React.createElement("span", {
|
|
11303
11322
|
className: classnames(cx(''), className)
|
|
11304
11323
|
}, parsedHighlightedValue.map(function (item, i) {
|
|
11305
11324
|
if (Array.isArray(item)) {
|
|
11306
11325
|
var isLast = i === parsedHighlightedValue.length - 1;
|
|
11307
|
-
return
|
|
11326
|
+
return React.createElement("span", {
|
|
11308
11327
|
key: i
|
|
11309
11328
|
}, item.map(function (element, index) {
|
|
11310
|
-
return
|
|
11329
|
+
return React.createElement(Highlight$2, {
|
|
11311
11330
|
cx: cx,
|
|
11312
11331
|
key: index,
|
|
11313
11332
|
value: element.value,
|
|
@@ -11315,12 +11334,12 @@ var Highlighter = function Highlighter(_ref2) {
|
|
|
11315
11334
|
nonHighlightedTagName: nonHighlightedTagName,
|
|
11316
11335
|
isHighlighted: element.isHighlighted
|
|
11317
11336
|
});
|
|
11318
|
-
}), !isLast &&
|
|
11337
|
+
}), !isLast && React.createElement("span", {
|
|
11319
11338
|
className: cx('separator')
|
|
11320
11339
|
}, separator));
|
|
11321
11340
|
}
|
|
11322
11341
|
|
|
11323
|
-
return
|
|
11342
|
+
return React.createElement(Highlight$2, {
|
|
11324
11343
|
cx: cx,
|
|
11325
11344
|
key: i,
|
|
11326
11345
|
value: item.value,
|
|
@@ -11349,12 +11368,12 @@ Highlighter.defaultProps = {
|
|
|
11349
11368
|
separator: ', '
|
|
11350
11369
|
};
|
|
11351
11370
|
|
|
11352
|
-
var cx$
|
|
11371
|
+
var cx$j = createClassNames('Highlight');
|
|
11353
11372
|
|
|
11354
11373
|
var Highlight$1 = function Highlight(props) {
|
|
11355
|
-
return
|
|
11374
|
+
return React.createElement(Highlighter, _extends({}, props, {
|
|
11356
11375
|
highlightProperty: "_highlightResult",
|
|
11357
|
-
cx: cx$
|
|
11376
|
+
cx: cx$j
|
|
11358
11377
|
}));
|
|
11359
11378
|
};
|
|
11360
11379
|
|
|
@@ -11399,12 +11418,12 @@ var Highlight$1 = function Highlight(props) {
|
|
|
11399
11418
|
* );
|
|
11400
11419
|
*/
|
|
11401
11420
|
|
|
11402
|
-
var Highlight
|
|
11421
|
+
var Highlight = connectHighlight(Highlight$1);
|
|
11403
11422
|
|
|
11404
|
-
var cx$
|
|
11423
|
+
var cx$i = createClassNames('Hits');
|
|
11405
11424
|
|
|
11406
11425
|
var DefaultHitComponent = function DefaultHitComponent(props) {
|
|
11407
|
-
return
|
|
11426
|
+
return React.createElement("div", {
|
|
11408
11427
|
style: {
|
|
11409
11428
|
borderBottom: '1px solid #bbb',
|
|
11410
11429
|
paddingBottom: '5px',
|
|
@@ -11414,21 +11433,21 @@ var DefaultHitComponent = function DefaultHitComponent(props) {
|
|
|
11414
11433
|
}, JSON.stringify(props).slice(0, 100), "...");
|
|
11415
11434
|
};
|
|
11416
11435
|
|
|
11417
|
-
var Hits = function Hits(_ref) {
|
|
11436
|
+
var Hits$1 = function Hits(_ref) {
|
|
11418
11437
|
var hits = _ref.hits,
|
|
11419
11438
|
_ref$className = _ref.className,
|
|
11420
11439
|
className = _ref$className === void 0 ? '' : _ref$className,
|
|
11421
11440
|
_ref$hitComponent = _ref.hitComponent,
|
|
11422
11441
|
HitComponent = _ref$hitComponent === void 0 ? DefaultHitComponent : _ref$hitComponent;
|
|
11423
|
-
return
|
|
11424
|
-
className: classnames(cx$
|
|
11425
|
-
},
|
|
11426
|
-
className: cx$
|
|
11442
|
+
return React.createElement("div", {
|
|
11443
|
+
className: classnames(cx$i(''), className)
|
|
11444
|
+
}, React.createElement("ul", {
|
|
11445
|
+
className: cx$i('list')
|
|
11427
11446
|
}, hits.map(function (hit) {
|
|
11428
|
-
return
|
|
11429
|
-
className: cx$
|
|
11447
|
+
return React.createElement("li", {
|
|
11448
|
+
className: cx$i('item'),
|
|
11430
11449
|
key: hit.objectID
|
|
11431
|
-
},
|
|
11450
|
+
}, React.createElement(HitComponent, {
|
|
11432
11451
|
hit: hit
|
|
11433
11452
|
}));
|
|
11434
11453
|
})));
|
|
@@ -11437,7 +11456,7 @@ var Hits = function Hits(_ref) {
|
|
|
11437
11456
|
var HitPropTypes = PropTypes.shape({
|
|
11438
11457
|
objectID: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).isRequired
|
|
11439
11458
|
});
|
|
11440
|
-
Hits.propTypes = {
|
|
11459
|
+
Hits$1.propTypes = {
|
|
11441
11460
|
hits: PropTypes.arrayOf(HitPropTypes.isRequired).isRequired,
|
|
11442
11461
|
className: PropTypes.string,
|
|
11443
11462
|
hitComponent: PropTypes.func
|
|
@@ -11476,7 +11495,7 @@ Hits.propTypes = {
|
|
|
11476
11495
|
* );
|
|
11477
11496
|
*/
|
|
11478
11497
|
|
|
11479
|
-
var Hits
|
|
11498
|
+
var Hits = connectHits(Hits$1);
|
|
11480
11499
|
|
|
11481
11500
|
var Select =
|
|
11482
11501
|
/*#__PURE__*/
|
|
@@ -11510,12 +11529,12 @@ function (_Component) {
|
|
|
11510
11529
|
cx = _this$props.cx,
|
|
11511
11530
|
items = _this$props.items,
|
|
11512
11531
|
selectedItem = _this$props.selectedItem;
|
|
11513
|
-
return
|
|
11532
|
+
return React.createElement("select", {
|
|
11514
11533
|
className: cx('select'),
|
|
11515
11534
|
value: selectedItem,
|
|
11516
11535
|
onChange: this.onChange
|
|
11517
11536
|
}, items.map(function (item) {
|
|
11518
|
-
return
|
|
11537
|
+
return React.createElement("option", {
|
|
11519
11538
|
className: cx('option'),
|
|
11520
11539
|
key: item.key === undefined ? item.value : item.key,
|
|
11521
11540
|
disabled: item.disabled,
|
|
@@ -11540,7 +11559,7 @@ _defineProperty(Select, "propTypes", {
|
|
|
11540
11559
|
selectedItem: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).isRequired
|
|
11541
11560
|
});
|
|
11542
11561
|
|
|
11543
|
-
var cx$
|
|
11562
|
+
var cx$h = createClassNames('HitsPerPage');
|
|
11544
11563
|
|
|
11545
11564
|
var HitsPerPage =
|
|
11546
11565
|
/*#__PURE__*/
|
|
@@ -11561,13 +11580,13 @@ function (_Component) {
|
|
|
11561
11580
|
currentRefinement = _this$props.currentRefinement,
|
|
11562
11581
|
refine = _this$props.refine,
|
|
11563
11582
|
className = _this$props.className;
|
|
11564
|
-
return
|
|
11565
|
-
className: classnames(cx$
|
|
11566
|
-
},
|
|
11583
|
+
return React.createElement("div", {
|
|
11584
|
+
className: classnames(cx$h(''), className)
|
|
11585
|
+
}, React.createElement(Select, {
|
|
11567
11586
|
onSelect: refine,
|
|
11568
11587
|
selectedItem: currentRefinement,
|
|
11569
11588
|
items: items,
|
|
11570
|
-
cx: cx$
|
|
11589
|
+
cx: cx$h
|
|
11571
11590
|
}));
|
|
11572
11591
|
}
|
|
11573
11592
|
}]);
|
|
@@ -11633,7 +11652,7 @@ _defineProperty(HitsPerPage, "defaultProps", {
|
|
|
11633
11652
|
|
|
11634
11653
|
connectHitsPerPage(HitsPerPage);
|
|
11635
11654
|
|
|
11636
|
-
var cx$
|
|
11655
|
+
var cx$g = createClassNames('InfiniteHits');
|
|
11637
11656
|
|
|
11638
11657
|
var InfiniteHits =
|
|
11639
11658
|
/*#__PURE__*/
|
|
@@ -11659,25 +11678,25 @@ function (_Component) {
|
|
|
11659
11678
|
refineNext = _this$props.refineNext,
|
|
11660
11679
|
translate = _this$props.translate,
|
|
11661
11680
|
className = _this$props.className;
|
|
11662
|
-
return
|
|
11663
|
-
className: classnames(cx$
|
|
11664
|
-
}, showPrevious &&
|
|
11665
|
-
className: cx$
|
|
11681
|
+
return React.createElement("div", {
|
|
11682
|
+
className: classnames(cx$g(''), className)
|
|
11683
|
+
}, showPrevious && React.createElement("button", {
|
|
11684
|
+
className: cx$g('loadPrevious', !hasPrevious && 'loadPrevious--disabled'),
|
|
11666
11685
|
onClick: function onClick() {
|
|
11667
11686
|
return refinePrevious();
|
|
11668
11687
|
},
|
|
11669
11688
|
disabled: !hasPrevious
|
|
11670
|
-
}, translate('loadPrevious')),
|
|
11671
|
-
className: cx$
|
|
11689
|
+
}, translate('loadPrevious')), React.createElement("ul", {
|
|
11690
|
+
className: cx$g('list')
|
|
11672
11691
|
}, hits.map(function (hit) {
|
|
11673
|
-
return
|
|
11692
|
+
return React.createElement("li", {
|
|
11674
11693
|
key: hit.objectID,
|
|
11675
|
-
className: cx$
|
|
11676
|
-
},
|
|
11694
|
+
className: cx$g('item')
|
|
11695
|
+
}, React.createElement(HitComponent, {
|
|
11677
11696
|
hit: hit
|
|
11678
11697
|
}));
|
|
11679
|
-
})),
|
|
11680
|
-
className: cx$
|
|
11698
|
+
})), React.createElement("button", {
|
|
11699
|
+
className: cx$g('loadMore', !hasMore && 'loadMore--disabled'),
|
|
11681
11700
|
onClick: function onClick() {
|
|
11682
11701
|
return refineNext();
|
|
11683
11702
|
},
|
|
@@ -11704,7 +11723,7 @@ InfiniteHits.defaultProps = {
|
|
|
11704
11723
|
className: '',
|
|
11705
11724
|
showPrevious: false,
|
|
11706
11725
|
hitComponent: function hitComponent(hit) {
|
|
11707
|
-
return
|
|
11726
|
+
return React.createElement("div", {
|
|
11708
11727
|
style: {
|
|
11709
11728
|
borderBottom: '1px solid #bbb',
|
|
11710
11729
|
paddingBottom: '5px',
|
|
@@ -11758,7 +11777,7 @@ var InfiniteHits$1 = translatable({
|
|
|
11758
11777
|
|
|
11759
11778
|
connectInfiniteHits(InfiniteHits$1);
|
|
11760
11779
|
|
|
11761
|
-
var cx$
|
|
11780
|
+
var cx$f = createClassNames('Menu');
|
|
11762
11781
|
|
|
11763
11782
|
var Menu =
|
|
11764
11783
|
/*#__PURE__*/
|
|
@@ -11780,20 +11799,20 @@ function (_Component) {
|
|
|
11780
11799
|
|
|
11781
11800
|
_defineProperty(_assertThisInitialized(_this), "renderItem", function (item, resetQuery) {
|
|
11782
11801
|
var createURL = _this.props.createURL;
|
|
11783
|
-
var label = _this.props.isFromSearch ?
|
|
11802
|
+
var label = _this.props.isFromSearch ? React.createElement(Highlight, {
|
|
11784
11803
|
attribute: "label",
|
|
11785
11804
|
hit: item
|
|
11786
11805
|
}) : item.label;
|
|
11787
|
-
return
|
|
11788
|
-
className: cx$
|
|
11806
|
+
return React.createElement(Link, {
|
|
11807
|
+
className: cx$f('link'),
|
|
11789
11808
|
onClick: function onClick() {
|
|
11790
11809
|
return _this.selectItem(item, resetQuery);
|
|
11791
11810
|
},
|
|
11792
11811
|
href: createURL(item.value)
|
|
11793
|
-
},
|
|
11794
|
-
className: cx$
|
|
11795
|
-
}, label), ' ',
|
|
11796
|
-
className: cx$
|
|
11812
|
+
}, React.createElement("span", {
|
|
11813
|
+
className: cx$f('label')
|
|
11814
|
+
}, label), ' ', React.createElement("span", {
|
|
11815
|
+
className: cx$f('count')
|
|
11797
11816
|
}, item.count));
|
|
11798
11817
|
});
|
|
11799
11818
|
|
|
@@ -11820,10 +11839,10 @@ function (_Component) {
|
|
|
11820
11839
|
searchable = _this$props.searchable,
|
|
11821
11840
|
canRefine = _this$props.canRefine,
|
|
11822
11841
|
className = _this$props.className;
|
|
11823
|
-
return
|
|
11842
|
+
return React.createElement(List, {
|
|
11824
11843
|
renderItem: this.renderItem,
|
|
11825
11844
|
selectItem: this.selectItem,
|
|
11826
|
-
cx: cx$
|
|
11845
|
+
cx: cx$f,
|
|
11827
11846
|
translate: translate,
|
|
11828
11847
|
items: items,
|
|
11829
11848
|
showMore: showMore,
|
|
@@ -11928,12 +11947,12 @@ var Menu$1 = translatable({
|
|
|
11928
11947
|
*/
|
|
11929
11948
|
|
|
11930
11949
|
var MenuWidget = function MenuWidget(props) {
|
|
11931
|
-
return
|
|
11950
|
+
return React.createElement(PanelWrapper, props, React.createElement(Menu$1, props));
|
|
11932
11951
|
};
|
|
11933
11952
|
|
|
11934
11953
|
connectMenu(MenuWidget);
|
|
11935
11954
|
|
|
11936
|
-
var cx$
|
|
11955
|
+
var cx$e = createClassNames('MenuSelect');
|
|
11937
11956
|
|
|
11938
11957
|
var MenuSelect =
|
|
11939
11958
|
/*#__PURE__*/
|
|
@@ -11970,27 +11989,27 @@ function (_Component) {
|
|
|
11970
11989
|
canRefine = _this$props.canRefine,
|
|
11971
11990
|
translate = _this$props.translate,
|
|
11972
11991
|
className = _this$props.className;
|
|
11973
|
-
return
|
|
11974
|
-
className: classnames(cx$
|
|
11975
|
-
},
|
|
11992
|
+
return React.createElement("div", {
|
|
11993
|
+
className: classnames(cx$e('', !canRefine && '-noRefinement'), className)
|
|
11994
|
+
}, React.createElement("select", {
|
|
11976
11995
|
value: this.selectedValue,
|
|
11977
11996
|
onChange: this.handleSelectChange,
|
|
11978
|
-
className: cx$
|
|
11979
|
-
},
|
|
11997
|
+
className: cx$e('select')
|
|
11998
|
+
}, React.createElement("option", {
|
|
11980
11999
|
value: "ais__see__all__option",
|
|
11981
|
-
className: cx$
|
|
12000
|
+
className: cx$e('option')
|
|
11982
12001
|
}, translate('seeAllOption')), items.map(function (item) {
|
|
11983
|
-
return
|
|
12002
|
+
return React.createElement("option", {
|
|
11984
12003
|
key: item.value,
|
|
11985
12004
|
value: item.value,
|
|
11986
|
-
className: cx$
|
|
12005
|
+
className: cx$e('option')
|
|
11987
12006
|
}, item.label, " (", item.count, ")");
|
|
11988
12007
|
})));
|
|
11989
12008
|
}
|
|
11990
12009
|
}, {
|
|
11991
12010
|
key: "selectedValue",
|
|
11992
12011
|
get: function get() {
|
|
11993
|
-
var _ref2 = find
|
|
12012
|
+
var _ref2 = find(this.props.items, function (item) {
|
|
11994
12013
|
return item.isRefined === true;
|
|
11995
12014
|
}) || {
|
|
11996
12015
|
value: 'ais__see__all__option'
|
|
@@ -12062,12 +12081,12 @@ var MenuSelect$1 = translatable({
|
|
|
12062
12081
|
*/
|
|
12063
12082
|
|
|
12064
12083
|
var MenuSelectWidget = function MenuSelectWidget(props) {
|
|
12065
|
-
return
|
|
12084
|
+
return React.createElement(PanelWrapper, props, React.createElement(MenuSelect$1, props));
|
|
12066
12085
|
};
|
|
12067
12086
|
|
|
12068
12087
|
connectMenu(MenuSelectWidget);
|
|
12069
12088
|
|
|
12070
|
-
var cx$
|
|
12089
|
+
var cx$d = createClassNames('NumericMenu');
|
|
12071
12090
|
|
|
12072
12091
|
var NumericMenu =
|
|
12073
12092
|
/*#__PURE__*/
|
|
@@ -12091,18 +12110,18 @@ function (_Component) {
|
|
|
12091
12110
|
var _this$props = _this.props,
|
|
12092
12111
|
refine = _this$props.refine,
|
|
12093
12112
|
translate = _this$props.translate;
|
|
12094
|
-
return
|
|
12095
|
-
className: cx$
|
|
12096
|
-
},
|
|
12097
|
-
className: cx$
|
|
12113
|
+
return React.createElement("label", {
|
|
12114
|
+
className: cx$d('label')
|
|
12115
|
+
}, React.createElement("input", {
|
|
12116
|
+
className: cx$d('radio'),
|
|
12098
12117
|
type: "radio",
|
|
12099
12118
|
checked: item.isRefined,
|
|
12100
12119
|
disabled: item.noRefinement,
|
|
12101
12120
|
onChange: function onChange() {
|
|
12102
12121
|
return refine(item.value);
|
|
12103
12122
|
}
|
|
12104
|
-
}),
|
|
12105
|
-
className: cx$
|
|
12123
|
+
}), React.createElement("span", {
|
|
12124
|
+
className: cx$d('labelText')
|
|
12106
12125
|
}, item.value === '' ? translate('all') : item.label));
|
|
12107
12126
|
});
|
|
12108
12127
|
|
|
@@ -12116,11 +12135,11 @@ function (_Component) {
|
|
|
12116
12135
|
items = _this$props2.items,
|
|
12117
12136
|
canRefine = _this$props2.canRefine,
|
|
12118
12137
|
className = _this$props2.className;
|
|
12119
|
-
return
|
|
12138
|
+
return React.createElement(List, {
|
|
12120
12139
|
renderItem: this.renderItem,
|
|
12121
12140
|
showMore: false,
|
|
12122
12141
|
canRefine: canRefine,
|
|
12123
|
-
cx: cx$
|
|
12142
|
+
cx: cx$d,
|
|
12124
12143
|
items: items.map(function (item) {
|
|
12125
12144
|
return _objectSpread({}, item, {
|
|
12126
12145
|
key: item.value
|
|
@@ -12202,7 +12221,7 @@ var NumericMenu$1 = translatable({
|
|
|
12202
12221
|
*/
|
|
12203
12222
|
|
|
12204
12223
|
var NumericMenuWidget = function NumericMenuWidget(props) {
|
|
12205
|
-
return
|
|
12224
|
+
return React.createElement(PanelWrapper, props, React.createElement(NumericMenu$1, props));
|
|
12206
12225
|
};
|
|
12207
12226
|
|
|
12208
12227
|
connectNumericMenu(NumericMenuWidget);
|
|
@@ -12227,15 +12246,15 @@ function (_Component) {
|
|
|
12227
12246
|
items = _this$props.items,
|
|
12228
12247
|
onSelect = _this$props.onSelect,
|
|
12229
12248
|
canRefine = _this$props.canRefine;
|
|
12230
|
-
return
|
|
12249
|
+
return React.createElement("ul", {
|
|
12231
12250
|
className: cx('list', !canRefine && 'list--noRefinement')
|
|
12232
12251
|
}, items.map(function (item) {
|
|
12233
|
-
return
|
|
12252
|
+
return React.createElement("li", {
|
|
12234
12253
|
key: item.key === undefined ? item.value : item.key,
|
|
12235
12254
|
className: cx('item', item.selected && !item.disabled && 'item--selected', item.disabled && 'item--disabled', item.modifier)
|
|
12236
|
-
}, item.disabled ?
|
|
12255
|
+
}, item.disabled ? React.createElement("span", {
|
|
12237
12256
|
className: cx('link')
|
|
12238
|
-
}, item.label === undefined ? item.value : item.label) :
|
|
12257
|
+
}, item.label === undefined ? item.value : item.label) : React.createElement(Link, {
|
|
12239
12258
|
className: cx('link', item.selected && 'link--selected'),
|
|
12240
12259
|
"aria-label": item.ariaLabel,
|
|
12241
12260
|
href: createURL(item.value),
|
|
@@ -12265,7 +12284,7 @@ _defineProperty(LinkList, "propTypes", {
|
|
|
12265
12284
|
canRefine: PropTypes.bool.isRequired
|
|
12266
12285
|
});
|
|
12267
12286
|
|
|
12268
|
-
var cx$
|
|
12287
|
+
var cx$c = createClassNames('Pagination'); // Determines the size of the widget (the number of pages displayed - that the user can directly click on)
|
|
12269
12288
|
|
|
12270
12289
|
function calculateSize(padding, maxPages) {
|
|
12271
12290
|
return Math.min(2 * padding + 1, maxPages);
|
|
@@ -12301,7 +12320,7 @@ function getPages(currentPage, maxPages, padding) {
|
|
|
12301
12320
|
});
|
|
12302
12321
|
}
|
|
12303
12322
|
|
|
12304
|
-
var Pagination =
|
|
12323
|
+
var Pagination$1 =
|
|
12305
12324
|
/*#__PURE__*/
|
|
12306
12325
|
function (_Component) {
|
|
12307
12326
|
_inherits(Pagination, _Component);
|
|
@@ -12407,10 +12426,10 @@ function (_Component) {
|
|
|
12407
12426
|
});
|
|
12408
12427
|
}
|
|
12409
12428
|
|
|
12410
|
-
return
|
|
12411
|
-
className: classnames(cx$
|
|
12412
|
-
},
|
|
12413
|
-
cx: cx$
|
|
12429
|
+
return React.createElement("div", {
|
|
12430
|
+
className: classnames(cx$c('', !canRefine && '-noRefinement'), className)
|
|
12431
|
+
}, React.createElement(ListComponent, _extends({}, otherProps, {
|
|
12432
|
+
cx: cx$c,
|
|
12414
12433
|
items: items,
|
|
12415
12434
|
onSelect: refine,
|
|
12416
12435
|
createURL: createURL,
|
|
@@ -12422,7 +12441,7 @@ function (_Component) {
|
|
|
12422
12441
|
return Pagination;
|
|
12423
12442
|
}(Component);
|
|
12424
12443
|
|
|
12425
|
-
_defineProperty(Pagination, "propTypes", {
|
|
12444
|
+
_defineProperty(Pagination$1, "propTypes", {
|
|
12426
12445
|
nbPages: PropTypes.number.isRequired,
|
|
12427
12446
|
currentRefinement: PropTypes.number.isRequired,
|
|
12428
12447
|
refine: PropTypes.func.isRequired,
|
|
@@ -12439,7 +12458,7 @@ _defineProperty(Pagination, "propTypes", {
|
|
|
12439
12458
|
className: PropTypes.string
|
|
12440
12459
|
});
|
|
12441
12460
|
|
|
12442
|
-
_defineProperty(Pagination, "defaultProps", {
|
|
12461
|
+
_defineProperty(Pagination$1, "defaultProps", {
|
|
12443
12462
|
listComponent: LinkList,
|
|
12444
12463
|
showFirst: true,
|
|
12445
12464
|
showPrevious: true,
|
|
@@ -12450,7 +12469,7 @@ _defineProperty(Pagination, "defaultProps", {
|
|
|
12450
12469
|
className: ''
|
|
12451
12470
|
});
|
|
12452
12471
|
|
|
12453
|
-
var Pagination$
|
|
12472
|
+
var Pagination$2 = translatable({
|
|
12454
12473
|
previous: '‹',
|
|
12455
12474
|
next: '›',
|
|
12456
12475
|
first: '«',
|
|
@@ -12465,7 +12484,7 @@ var Pagination$1 = translatable({
|
|
|
12465
12484
|
ariaPage: function ariaPage(currentRefinement) {
|
|
12466
12485
|
return "Page ".concat(currentRefinement.toString());
|
|
12467
12486
|
}
|
|
12468
|
-
})(Pagination);
|
|
12487
|
+
})(Pagination$1);
|
|
12469
12488
|
|
|
12470
12489
|
/**
|
|
12471
12490
|
* The Pagination widget displays a simple pagination system allowing the user to
|
|
@@ -12522,23 +12541,23 @@ var Pagination$1 = translatable({
|
|
|
12522
12541
|
*/
|
|
12523
12542
|
|
|
12524
12543
|
var PaginationWidget = function PaginationWidget(props) {
|
|
12525
|
-
return
|
|
12544
|
+
return React.createElement(PanelWrapper, props, React.createElement(Pagination$2, props));
|
|
12526
12545
|
};
|
|
12527
12546
|
|
|
12528
|
-
var Pagination
|
|
12547
|
+
var Pagination = connectPagination(PaginationWidget);
|
|
12529
12548
|
|
|
12530
|
-
var cx$
|
|
12549
|
+
var cx$b = createClassNames('PoweredBy');
|
|
12531
12550
|
/* eslint-disable max-len */
|
|
12532
12551
|
|
|
12533
12552
|
var AlgoliaLogo = function AlgoliaLogo() {
|
|
12534
|
-
return
|
|
12553
|
+
return React.createElement("svg", {
|
|
12535
12554
|
xmlns: "http://www.w3.org/2000/svg",
|
|
12536
12555
|
baseProfile: "basic",
|
|
12537
12556
|
viewBox: "0 0 1366 362",
|
|
12538
12557
|
width: "100",
|
|
12539
12558
|
height: "27",
|
|
12540
|
-
className: cx$
|
|
12541
|
-
},
|
|
12559
|
+
className: cx$b('logo')
|
|
12560
|
+
}, React.createElement("linearGradient", {
|
|
12542
12561
|
id: "g",
|
|
12543
12562
|
x1: "428.258",
|
|
12544
12563
|
x2: "434.145",
|
|
@@ -12546,19 +12565,19 @@ var AlgoliaLogo = function AlgoliaLogo() {
|
|
|
12546
12565
|
y2: "409.85",
|
|
12547
12566
|
gradientUnits: "userSpaceOnUse",
|
|
12548
12567
|
gradientTransform: "matrix(94.045 0 0 -94.072 -40381.527 38479.52)"
|
|
12549
|
-
},
|
|
12568
|
+
}, React.createElement("stop", {
|
|
12550
12569
|
offset: "0",
|
|
12551
12570
|
stopColor: "#00AEFF"
|
|
12552
|
-
}),
|
|
12571
|
+
}), React.createElement("stop", {
|
|
12553
12572
|
offset: "1",
|
|
12554
12573
|
stopColor: "#3369E7"
|
|
12555
|
-
})),
|
|
12574
|
+
})), React.createElement("path", {
|
|
12556
12575
|
d: "M61.8 15.4h242.8c23.9 0 43.4 19.4 43.4 43.4v242.9c0 23.9-19.4 43.4-43.4 43.4H61.8c-23.9 0-43.4-19.4-43.4-43.4v-243c0-23.9 19.4-43.3 43.4-43.3z",
|
|
12557
12576
|
fill: "url(#g)"
|
|
12558
|
-
}),
|
|
12577
|
+
}), React.createElement("path", {
|
|
12559
12578
|
d: "M187 98.7c-51.4 0-93.1 41.7-93.1 93.2S135.6 285 187 285s93.1-41.7 93.1-93.2-41.6-93.1-93.1-93.1zm0 158.8c-36.2 0-65.6-29.4-65.6-65.6s29.4-65.6 65.6-65.6 65.6 29.4 65.6 65.6-29.3 65.6-65.6 65.6zm0-117.8v48.9c0 1.4 1.5 2.4 2.8 1.7l43.4-22.5c1-.5 1.3-1.7.8-2.7-9-15.8-25.7-26.6-45-27.3-1 0-2 .8-2 1.9zm-60.8-35.9l-5.7-5.7c-5.6-5.6-14.6-5.6-20.2 0l-6.8 6.8c-5.6 5.6-5.6 14.6 0 20.2l5.6 5.6c.9.9 2.2.7 3-.2 3.3-4.5 6.9-8.8 10.9-12.8 4.1-4.1 8.3-7.7 12.9-11 1-.6 1.1-2 .3-2.9zM217.5 89V77.7c0-7.9-6.4-14.3-14.3-14.3h-33.3c-7.9 0-14.3 6.4-14.3 14.3v11.6c0 1.3 1.2 2.2 2.5 1.9 9.3-2.7 19.1-4.1 29-4.1 9.5 0 18.9 1.3 28 3.8 1.2.3 2.4-.6 2.4-1.9z",
|
|
12560
12579
|
fill: "#FFFFFF"
|
|
12561
|
-
}),
|
|
12580
|
+
}), React.createElement("path", {
|
|
12562
12581
|
d: "M842.5 267.6c0 26.7-6.8 46.2-20.5 58.6-13.7 12.4-34.6 18.6-62.8 18.6-10.3 0-31.7-2-48.8-5.8l6.3-31c14.3 3 33.2 3.8 43.1 3.8 15.7 0 26.9-3.2 33.6-9.6s10-15.9 10-28.5v-6.4c-3.9 1.9-9 3.8-15.3 5.8-6.3 1.9-13.6 2.9-21.8 2.9-10.8 0-20.6-1.7-29.5-5.1-8.9-3.4-16.6-8.4-22.9-15-6.3-6.6-11.3-14.9-14.8-24.8s-5.3-27.6-5.3-40.6c0-12.2 1.9-27.5 5.6-37.7 3.8-10.2 9.2-19 16.5-26.3 7.2-7.3 16-12.9 26.3-17s22.4-6.7 35.5-6.7c12.7 0 24.4 1.6 35.8 3.5 11.4 1.9 21.1 3.9 29 6.1v155.2zm-108.7-77.2c0 16.4 3.6 34.6 10.8 42.2 7.2 7.6 16.5 11.4 27.9 11.4 6.2 0 12.1-.9 17.6-2.6 5.5-1.7 9.9-3.7 13.4-6.1v-97.1c-2.8-.6-14.5-3-25.8-3.3-14.2-.4-25 5.4-32.6 14.7-7.5 9.3-11.3 25.6-11.3 40.8zm294.3 0c0 13.2-1.9 23.2-5.8 34.1s-9.4 20.2-16.5 27.9c-7.1 7.7-15.6 13.7-25.6 17.9s-25.4 6.6-33.1 6.6c-7.7-.1-23-2.3-32.9-6.6-9.9-4.3-18.4-10.2-25.5-17.9-7.1-7.7-12.6-17-16.6-27.9s-6-20.9-6-34.1c0-13.2 1.8-25.9 5.8-36.7 4-10.8 9.6-20 16.8-27.7s15.8-13.6 25.6-17.8c9.9-4.2 20.8-6.2 32.6-6.2s22.7 2.1 32.7 6.2c10 4.2 18.6 10.1 25.6 17.8 7.1 7.7 12.6 16.9 16.6 27.7 4.2 10.8 6.3 23.5 6.3 36.7zm-40 .1c0-16.9-3.7-31-10.9-40.8-7.2-9.9-17.3-14.8-30.2-14.8-12.9 0-23 4.9-30.2 14.8-7.2 9.9-10.7 23.9-10.7 40.8 0 17.1 3.6 28.6 10.8 38.5 7.2 10 17.3 14.9 30.2 14.9 12.9 0 23-5 30.2-14.9 7.2-10 10.8-21.4 10.8-38.5zm127.1 86.4c-64.1.3-64.1-51.8-64.1-60.1L1051 32l39.1-6.2v183.6c0 4.7 0 34.5 25.1 34.6v32.9zm68.9 0h-39.3V108.1l39.3-6.2v175zm-19.7-193.5c13.1 0 23.8-10.6 23.8-23.7S1177.6 36 1164.4 36s-23.8 10.6-23.8 23.7 10.7 23.7 23.8 23.7zm117.4 18.6c12.9 0 23.8 1.6 32.6 4.8 8.8 3.2 15.9 7.7 21.1 13.4s8.9 13.5 11.1 21.7c2.3 8.2 3.4 17.2 3.4 27.1v100.6c-6 1.3-15.1 2.8-27.3 4.6s-25.9 2.7-41.1 2.7c-10.1 0-19.4-1-27.7-2.9-8.4-1.9-15.5-5-21.5-9.3-5.9-4.3-10.5-9.8-13.9-16.6-3.3-6.8-5-16.4-5-26.4 0-9.6 1.9-15.7 5.6-22.3 3.8-6.6 8.9-12 15.3-16.2 6.5-4.2 13.9-7.2 22.4-9s17.4-2.7 26.6-2.7c4.3 0 8.8.3 13.6.8s9.8 1.4 15.2 2.7v-6.4c0-4.5-.5-8.8-1.6-12.8-1.1-4.1-3-7.6-5.6-10.7-2.7-3.1-6.2-5.5-10.6-7.2s-10-3-16.7-3c-9 0-17.2 1.1-24.7 2.4-7.5 1.3-13.7 2.8-18.4 4.5l-4.7-32.1c4.9-1.7 12.2-3.4 21.6-5.1s19.5-2.6 30.3-2.6zm3.3 141.9c12 0 20.9-.7 27.1-1.9v-39.8c-2.2-.6-5.3-1.3-9.4-1.9-4.1-.6-8.6-1-13.6-1-4.3 0-8.7.3-13.1 1-4.4.6-8.4 1.8-11.9 3.5s-6.4 4.1-8.5 7.2c-2.2 3.1-3.2 4.9-3.2 9.6 0 9.2 3.2 14.5 9 18 5.9 3.6 13.7 5.3 23.6 5.3zM512.9 103c12.9 0 23.8 1.6 32.6 4.8 8.8 3.2 15.9 7.7 21.1 13.4 5.3 5.8 8.9 13.5 11.1 21.7 2.3 8.2 3.4 17.2 3.4 27.1v100.6c-6 1.3-15.1 2.8-27.3 4.6-12.2 1.8-25.9 2.7-41.1 2.7-10.1 0-19.4-1-27.7-2.9-8.4-1.9-15.5-5-21.5-9.3-5.9-4.3-10.5-9.8-13.9-16.6-3.3-6.8-5-16.4-5-26.4 0-9.6 1.9-15.7 5.6-22.3 3.8-6.6 8.9-12 15.3-16.2 6.5-4.2 13.9-7.2 22.4-9s17.4-2.7 26.6-2.7c4.3 0 8.8.3 13.6.8 4.7.5 9.8 1.4 15.2 2.7v-6.4c0-4.5-.5-8.8-1.6-12.8-1.1-4.1-3-7.6-5.6-10.7-2.7-3.1-6.2-5.5-10.6-7.2-4.4-1.7-10-3-16.7-3-9 0-17.2 1.1-24.7 2.4-7.5 1.3-13.7 2.8-18.4 4.5l-4.7-32.1c4.9-1.7 12.2-3.4 21.6-5.1 9.4-1.8 19.5-2.6 30.3-2.6zm3.4 142c12 0 20.9-.7 27.1-1.9v-39.8c-2.2-.6-5.3-1.3-9.4-1.9-4.1-.6-8.6-1-13.6-1-4.3 0-8.7.3-13.1 1-4.4.6-8.4 1.8-11.9 3.5s-6.4 4.1-8.5 7.2c-2.2 3.1-3.2 4.9-3.2 9.6 0 9.2 3.2 14.5 9 18s13.7 5.3 23.6 5.3zm158.5 31.9c-64.1.3-64.1-51.8-64.1-60.1L610.6 32l39.1-6.2v183.6c0 4.7 0 34.5 25.1 34.6v32.9z",
|
|
12563
12582
|
fill: "#182359"
|
|
12564
12583
|
}));
|
|
@@ -12584,17 +12603,17 @@ function (_Component) {
|
|
|
12584
12603
|
url = _this$props.url,
|
|
12585
12604
|
translate = _this$props.translate,
|
|
12586
12605
|
className = _this$props.className;
|
|
12587
|
-
return
|
|
12588
|
-
className: classnames(cx$
|
|
12589
|
-
},
|
|
12590
|
-
className: cx$
|
|
12591
|
-
}, translate('searchBy')), ' ',
|
|
12606
|
+
return React.createElement("div", {
|
|
12607
|
+
className: classnames(cx$b(''), className)
|
|
12608
|
+
}, React.createElement("span", {
|
|
12609
|
+
className: cx$b('text')
|
|
12610
|
+
}, translate('searchBy')), ' ', React.createElement("a", {
|
|
12592
12611
|
href: url,
|
|
12593
12612
|
target: "_blank",
|
|
12594
|
-
className: cx$
|
|
12613
|
+
className: cx$b('link'),
|
|
12595
12614
|
"aria-label": "Algolia",
|
|
12596
12615
|
rel: "noopener noreferrer"
|
|
12597
|
-
},
|
|
12616
|
+
}, React.createElement(AlgoliaLogo, null)));
|
|
12598
12617
|
}
|
|
12599
12618
|
}]);
|
|
12600
12619
|
|
|
@@ -12644,7 +12663,7 @@ var PoweredBy$1 = translatable({
|
|
|
12644
12663
|
|
|
12645
12664
|
connectPoweredBy(PoweredBy$1);
|
|
12646
12665
|
|
|
12647
|
-
var cx$
|
|
12666
|
+
var cx$a = createClassNames('RangeInput');
|
|
12648
12667
|
var RawRangeInput =
|
|
12649
12668
|
/*#__PURE__*/
|
|
12650
12669
|
function (_Component) {
|
|
@@ -12723,13 +12742,13 @@ function (_Component) {
|
|
|
12723
12742
|
max = _this$normalizeRangeF.max;
|
|
12724
12743
|
|
|
12725
12744
|
var step = 1 / Math.pow(10, precision);
|
|
12726
|
-
return
|
|
12727
|
-
className: classnames(cx$
|
|
12728
|
-
},
|
|
12729
|
-
className: cx$
|
|
12745
|
+
return React.createElement("div", {
|
|
12746
|
+
className: classnames(cx$a('', !canRefine && '-noRefinement'), className)
|
|
12747
|
+
}, React.createElement("form", {
|
|
12748
|
+
className: cx$a('form'),
|
|
12730
12749
|
onSubmit: this.onSubmit
|
|
12731
|
-
},
|
|
12732
|
-
className: cx$
|
|
12750
|
+
}, React.createElement("input", {
|
|
12751
|
+
className: cx$a('input', 'input--min'),
|
|
12733
12752
|
type: "number",
|
|
12734
12753
|
min: min,
|
|
12735
12754
|
max: max,
|
|
@@ -12742,10 +12761,10 @@ function (_Component) {
|
|
|
12742
12761
|
from: e.currentTarget.value
|
|
12743
12762
|
});
|
|
12744
12763
|
}
|
|
12745
|
-
}),
|
|
12746
|
-
className: cx$
|
|
12747
|
-
}, translate('separator')),
|
|
12748
|
-
className: cx$
|
|
12764
|
+
}), React.createElement("span", {
|
|
12765
|
+
className: cx$a('separator')
|
|
12766
|
+
}, translate('separator')), React.createElement("input", {
|
|
12767
|
+
className: cx$a('input', 'input--max'),
|
|
12749
12768
|
type: "number",
|
|
12750
12769
|
min: min,
|
|
12751
12770
|
max: max,
|
|
@@ -12758,8 +12777,8 @@ function (_Component) {
|
|
|
12758
12777
|
to: e.currentTarget.value
|
|
12759
12778
|
});
|
|
12760
12779
|
}
|
|
12761
|
-
}),
|
|
12762
|
-
className: cx$
|
|
12780
|
+
}), React.createElement("button", {
|
|
12781
|
+
className: cx$a('submit'),
|
|
12763
12782
|
type: "submit"
|
|
12764
12783
|
}, translate('submit'))));
|
|
12765
12784
|
}
|
|
@@ -12835,12 +12854,12 @@ var RangeInput = translatable({
|
|
|
12835
12854
|
*/
|
|
12836
12855
|
|
|
12837
12856
|
var RangeInputWidget = function RangeInputWidget(props) {
|
|
12838
|
-
return
|
|
12857
|
+
return React.createElement(PanelWrapper, props, React.createElement(RangeInput, props));
|
|
12839
12858
|
};
|
|
12840
12859
|
|
|
12841
12860
|
connectRange(RangeInputWidget);
|
|
12842
12861
|
|
|
12843
|
-
var cx$
|
|
12862
|
+
var cx$9 = createClassNames('RatingMenu');
|
|
12844
12863
|
|
|
12845
12864
|
var RatingMenu =
|
|
12846
12865
|
/*#__PURE__*/
|
|
@@ -12891,14 +12910,14 @@ function (_Component) {
|
|
|
12891
12910
|
rating++;
|
|
12892
12911
|
}
|
|
12893
12912
|
|
|
12894
|
-
icons.push([
|
|
12913
|
+
icons.push([React.createElement("svg", {
|
|
12895
12914
|
key: icon,
|
|
12896
|
-
className: cx$
|
|
12915
|
+
className: cx$9('starIcon', icon >= lowerBound ? 'starIcon--empty' : 'starIcon--full'),
|
|
12897
12916
|
"aria-hidden": "true",
|
|
12898
12917
|
width: "24",
|
|
12899
12918
|
height: "24"
|
|
12900
|
-
},
|
|
12901
|
-
xlinkHref: "#".concat(cx$
|
|
12919
|
+
}, React.createElement("use", {
|
|
12920
|
+
xlinkHref: "#".concat(cx$9(icon >= lowerBound ? 'starEmptySymbol' : 'starSymbol'))
|
|
12902
12921
|
})), ' ']);
|
|
12903
12922
|
} // The last item of the list (the default item), should not
|
|
12904
12923
|
// be clickable if it is selected.
|
|
@@ -12912,17 +12931,17 @@ function (_Component) {
|
|
|
12912
12931
|
}),
|
|
12913
12932
|
onClick: this.onClick.bind(this, lowerBound, max)
|
|
12914
12933
|
};
|
|
12915
|
-
return
|
|
12934
|
+
return React.createElement("li", {
|
|
12916
12935
|
key: lowerBound,
|
|
12917
|
-
className: cx$
|
|
12918
|
-
},
|
|
12919
|
-
className: cx$
|
|
12936
|
+
className: cx$9('item', selected && 'item--selected', disabled && 'item--disabled')
|
|
12937
|
+
}, React.createElement("a", _extends({
|
|
12938
|
+
className: cx$9('link'),
|
|
12920
12939
|
"aria-label": "".concat(rating).concat(translate('ratingLabel'))
|
|
12921
|
-
}, onClickHandler), icons,
|
|
12922
|
-
className: cx$
|
|
12940
|
+
}, onClickHandler), icons, React.createElement("span", {
|
|
12941
|
+
className: cx$9('label'),
|
|
12923
12942
|
"aria-hidden": "true"
|
|
12924
|
-
}, translate('ratingLabel')), ' ',
|
|
12925
|
-
className: cx$
|
|
12943
|
+
}, translate('ratingLabel')), ' ', React.createElement("span", {
|
|
12944
|
+
className: cx$9('count')
|
|
12926
12945
|
}, count)));
|
|
12927
12946
|
}
|
|
12928
12947
|
}, {
|
|
@@ -12954,7 +12973,7 @@ function (_Component) {
|
|
|
12954
12973
|
start: 0,
|
|
12955
12974
|
end: Math.max(inclusiveLength, 0)
|
|
12956
12975
|
}).map(function (index) {
|
|
12957
|
-
var element = find
|
|
12976
|
+
var element = find(values, function (item) {
|
|
12958
12977
|
return item.value === limitMax - index;
|
|
12959
12978
|
});
|
|
12960
12979
|
var placeholder = {
|
|
@@ -12977,25 +12996,25 @@ function (_Component) {
|
|
|
12977
12996
|
createURL: createURL
|
|
12978
12997
|
});
|
|
12979
12998
|
});
|
|
12980
|
-
return
|
|
12981
|
-
className: classnames(cx$
|
|
12982
|
-
},
|
|
12999
|
+
return React.createElement("div", {
|
|
13000
|
+
className: classnames(cx$9('', !canRefine && '-noRefinement'), className)
|
|
13001
|
+
}, React.createElement("svg", {
|
|
12983
13002
|
xmlns: "http://www.w3.org/2000/svg",
|
|
12984
13003
|
style: {
|
|
12985
13004
|
display: 'none'
|
|
12986
13005
|
}
|
|
12987
|
-
},
|
|
12988
|
-
id: cx$
|
|
13006
|
+
}, React.createElement("symbol", {
|
|
13007
|
+
id: cx$9('starSymbol'),
|
|
12989
13008
|
viewBox: "0 0 24 24"
|
|
12990
|
-
},
|
|
13009
|
+
}, React.createElement("path", {
|
|
12991
13010
|
d: "M12 .288l2.833 8.718h9.167l-7.417 5.389 2.833 8.718-7.416-5.388-7.417 5.388 2.833-8.718-7.416-5.389h9.167z"
|
|
12992
|
-
})),
|
|
12993
|
-
id: cx$
|
|
13011
|
+
})), React.createElement("symbol", {
|
|
13012
|
+
id: cx$9('starEmptySymbol'),
|
|
12994
13013
|
viewBox: "0 0 24 24"
|
|
12995
|
-
},
|
|
13014
|
+
}, React.createElement("path", {
|
|
12996
13015
|
d: "M12 6.76l1.379 4.246h4.465l-3.612 2.625 1.379 4.246-3.611-2.625-3.612 2.625 1.379-4.246-3.612-2.625h4.465l1.38-4.246zm0-6.472l-2.833 8.718h-9.167l7.416 5.389-2.833 8.718 7.417-5.388 7.416 5.388-2.833-8.718 7.417-5.389h-9.167l-2.833-8.718z"
|
|
12997
|
-
}))),
|
|
12998
|
-
className: cx$
|
|
13016
|
+
}))), React.createElement("ul", {
|
|
13017
|
+
className: cx$9('list', !canRefine && 'list--noRefinement')
|
|
12999
13018
|
}, items));
|
|
13000
13019
|
}
|
|
13001
13020
|
}]);
|
|
@@ -13078,12 +13097,12 @@ var RatingMenu$1 = translatable({
|
|
|
13078
13097
|
*/
|
|
13079
13098
|
|
|
13080
13099
|
var RatingMenuWidget = function RatingMenuWidget(props) {
|
|
13081
|
-
return
|
|
13100
|
+
return React.createElement(PanelWrapper, props, React.createElement(RatingMenu$1, props));
|
|
13082
13101
|
};
|
|
13083
13102
|
|
|
13084
13103
|
connectRange(RatingMenuWidget);
|
|
13085
13104
|
|
|
13086
|
-
var cx$
|
|
13105
|
+
var cx$8 = createClassNames('RefinementList');
|
|
13087
13106
|
|
|
13088
13107
|
var RefinementList$1 =
|
|
13089
13108
|
/*#__PURE__*/
|
|
@@ -13114,23 +13133,23 @@ function (_Component) {
|
|
|
13114
13133
|
});
|
|
13115
13134
|
|
|
13116
13135
|
_defineProperty(_assertThisInitialized(_this), "renderItem", function (item, resetQuery) {
|
|
13117
|
-
var label = _this.props.isFromSearch ?
|
|
13136
|
+
var label = _this.props.isFromSearch ? React.createElement(Highlight, {
|
|
13118
13137
|
attribute: "label",
|
|
13119
13138
|
hit: item
|
|
13120
13139
|
}) : item.label;
|
|
13121
|
-
return
|
|
13122
|
-
className: cx$
|
|
13123
|
-
},
|
|
13124
|
-
className: cx$
|
|
13140
|
+
return React.createElement("label", {
|
|
13141
|
+
className: cx$8('label')
|
|
13142
|
+
}, React.createElement("input", {
|
|
13143
|
+
className: cx$8('checkbox'),
|
|
13125
13144
|
type: "checkbox",
|
|
13126
13145
|
checked: item.isRefined,
|
|
13127
13146
|
onChange: function onChange() {
|
|
13128
13147
|
return _this.selectItem(item, resetQuery);
|
|
13129
13148
|
}
|
|
13130
|
-
}),
|
|
13131
|
-
className: cx$
|
|
13132
|
-
}, label), ' ',
|
|
13133
|
-
className: cx$
|
|
13149
|
+
}), React.createElement("span", {
|
|
13150
|
+
className: cx$8('labelText')
|
|
13151
|
+
}, label), ' ', React.createElement("span", {
|
|
13152
|
+
className: cx$8('count')
|
|
13134
13153
|
}, item.count.toLocaleString()));
|
|
13135
13154
|
});
|
|
13136
13155
|
|
|
@@ -13151,10 +13170,10 @@ function (_Component) {
|
|
|
13151
13170
|
searchable = _this$props.searchable,
|
|
13152
13171
|
canRefine = _this$props.canRefine,
|
|
13153
13172
|
className = _this$props.className;
|
|
13154
|
-
return
|
|
13173
|
+
return React.createElement(List, {
|
|
13155
13174
|
renderItem: this.renderItem,
|
|
13156
13175
|
selectItem: this.selectItem,
|
|
13157
|
-
cx: cx$
|
|
13176
|
+
cx: cx$8,
|
|
13158
13177
|
translate: translate,
|
|
13159
13178
|
items: items,
|
|
13160
13179
|
showMore: showMore,
|
|
@@ -13263,12 +13282,12 @@ var RefinementList$2 = translatable({
|
|
|
13263
13282
|
*/
|
|
13264
13283
|
|
|
13265
13284
|
var RefinementListWidget = function RefinementListWidget(props) {
|
|
13266
|
-
return
|
|
13285
|
+
return React.createElement(PanelWrapper, props, React.createElement(RefinementList$2, props));
|
|
13267
13286
|
};
|
|
13268
13287
|
|
|
13269
|
-
var RefinementList
|
|
13288
|
+
var RefinementList = connectRefinementList(RefinementListWidget);
|
|
13270
13289
|
|
|
13271
|
-
var cx$
|
|
13290
|
+
var cx$7 = createClassNames('ScrollTo');
|
|
13272
13291
|
|
|
13273
13292
|
var ScrollTo =
|
|
13274
13293
|
/*#__PURE__*/
|
|
@@ -13297,11 +13316,11 @@ function (_Component) {
|
|
|
13297
13316
|
value: function render() {
|
|
13298
13317
|
var _this = this;
|
|
13299
13318
|
|
|
13300
|
-
return
|
|
13319
|
+
return React.createElement("div", {
|
|
13301
13320
|
ref: function ref(_ref) {
|
|
13302
13321
|
return _this.el = _ref;
|
|
13303
13322
|
},
|
|
13304
|
-
className: cx$
|
|
13323
|
+
className: cx$7('')
|
|
13305
13324
|
}, this.props.children);
|
|
13306
13325
|
}
|
|
13307
13326
|
}]);
|
|
@@ -13395,14 +13414,14 @@ connectScrollTo(ScrollTo);
|
|
|
13395
13414
|
* );
|
|
13396
13415
|
*/
|
|
13397
13416
|
|
|
13398
|
-
var SearchBox
|
|
13417
|
+
var SearchBox = connectSearchBox(SearchBox$2);
|
|
13399
13418
|
|
|
13400
|
-
var cx$
|
|
13419
|
+
var cx$6 = createClassNames('Snippet');
|
|
13401
13420
|
|
|
13402
13421
|
var Snippet = function Snippet(props) {
|
|
13403
|
-
return
|
|
13422
|
+
return React.createElement(Highlighter, _extends({}, props, {
|
|
13404
13423
|
highlightProperty: "_snippetResult",
|
|
13405
|
-
cx: cx$
|
|
13424
|
+
cx: cx$6
|
|
13406
13425
|
}));
|
|
13407
13426
|
};
|
|
13408
13427
|
|
|
@@ -13452,11 +13471,11 @@ var Snippet = function Snippet(props) {
|
|
|
13452
13471
|
|
|
13453
13472
|
connectHighlight(Snippet);
|
|
13454
13473
|
|
|
13455
|
-
var cx$
|
|
13474
|
+
var cx$5 = createClassNames('RelevantSort');
|
|
13456
13475
|
|
|
13457
13476
|
var DefaultButtonTextComponent = function DefaultButtonTextComponent(_ref) {
|
|
13458
13477
|
var isRelevantSorted = _ref.isRelevantSorted;
|
|
13459
|
-
return
|
|
13478
|
+
return React.createElement("span", null, isRelevantSorted ? 'See all results' : 'See relevant results');
|
|
13460
13479
|
};
|
|
13461
13480
|
|
|
13462
13481
|
var RelevantSort = function RelevantSort(_ref2) {
|
|
@@ -13468,18 +13487,18 @@ var RelevantSort = function RelevantSort(_ref2) {
|
|
|
13468
13487
|
ButtonTextComponent = _ref2$buttonTextCompo === void 0 ? DefaultButtonTextComponent : _ref2$buttonTextCompo,
|
|
13469
13488
|
TextComponent = _ref2.textComponent,
|
|
13470
13489
|
refine = _ref2.refine;
|
|
13471
|
-
return !isVirtualReplica ? null :
|
|
13472
|
-
className: classnames(cx$
|
|
13473
|
-
},
|
|
13474
|
-
className: cx$
|
|
13475
|
-
}, TextComponent &&
|
|
13490
|
+
return !isVirtualReplica ? null : React.createElement("div", {
|
|
13491
|
+
className: classnames(cx$5(''), className)
|
|
13492
|
+
}, React.createElement("div", {
|
|
13493
|
+
className: cx$5('text')
|
|
13494
|
+
}, TextComponent && React.createElement(TextComponent, {
|
|
13476
13495
|
isRelevantSorted: isRelevantSorted
|
|
13477
|
-
})),
|
|
13478
|
-
className: cx$
|
|
13496
|
+
})), React.createElement("button", {
|
|
13497
|
+
className: cx$5('button'),
|
|
13479
13498
|
onClick: function onClick() {
|
|
13480
13499
|
return refine(isRelevantSorted ? 0 : undefined);
|
|
13481
13500
|
}
|
|
13482
|
-
},
|
|
13501
|
+
}, React.createElement(ButtonTextComponent, {
|
|
13483
13502
|
isRelevantSorted: isRelevantSorted
|
|
13484
13503
|
})));
|
|
13485
13504
|
};
|
|
@@ -13495,7 +13514,7 @@ RelevantSort.propTypes = {
|
|
|
13495
13514
|
|
|
13496
13515
|
connectRelevantSort(RelevantSort);
|
|
13497
13516
|
|
|
13498
|
-
var cx$
|
|
13517
|
+
var cx$4 = createClassNames('SortBy');
|
|
13499
13518
|
|
|
13500
13519
|
var SortBy =
|
|
13501
13520
|
/*#__PURE__*/
|
|
@@ -13516,10 +13535,10 @@ function (_Component) {
|
|
|
13516
13535
|
currentRefinement = _this$props.currentRefinement,
|
|
13517
13536
|
refine = _this$props.refine,
|
|
13518
13537
|
className = _this$props.className;
|
|
13519
|
-
return
|
|
13520
|
-
className: classnames(cx$
|
|
13521
|
-
},
|
|
13522
|
-
cx: cx$
|
|
13538
|
+
return React.createElement("div", {
|
|
13539
|
+
className: classnames(cx$4(''), className)
|
|
13540
|
+
}, React.createElement(Select, {
|
|
13541
|
+
cx: cx$4,
|
|
13523
13542
|
items: items,
|
|
13524
13543
|
selectedItem: currentRefinement,
|
|
13525
13544
|
onSelect: refine
|
|
@@ -13585,7 +13604,7 @@ _defineProperty(SortBy, "defaultProps", {
|
|
|
13585
13604
|
|
|
13586
13605
|
connectSortBy(SortBy);
|
|
13587
13606
|
|
|
13588
|
-
var cx$
|
|
13607
|
+
var cx$3 = createClassNames('Stats');
|
|
13589
13608
|
|
|
13590
13609
|
var Stats = function Stats(_ref) {
|
|
13591
13610
|
var _ref$className = _ref.className,
|
|
@@ -13595,10 +13614,10 @@ var Stats = function Stats(_ref) {
|
|
|
13595
13614
|
nbSortedHits = _ref.nbSortedHits,
|
|
13596
13615
|
processingTimeMS = _ref.processingTimeMS,
|
|
13597
13616
|
translate = _ref.translate;
|
|
13598
|
-
return
|
|
13599
|
-
className: classnames(cx$
|
|
13600
|
-
},
|
|
13601
|
-
className: cx$
|
|
13617
|
+
return React.createElement("div", {
|
|
13618
|
+
className: classnames(cx$3(''), className)
|
|
13619
|
+
}, React.createElement("span", {
|
|
13620
|
+
className: cx$3('text')
|
|
13602
13621
|
}, translate('stats', nbHits, processingTimeMS, nbSortedHits, areHitsSorted)));
|
|
13603
13622
|
};
|
|
13604
13623
|
|
|
@@ -13646,7 +13665,7 @@ var Stats$1 = translatable({
|
|
|
13646
13665
|
|
|
13647
13666
|
connectStats(Stats$1);
|
|
13648
13667
|
|
|
13649
|
-
var cx$
|
|
13668
|
+
var cx$2 = createClassNames('ToggleRefinement');
|
|
13650
13669
|
|
|
13651
13670
|
var ToggleRefinement = function ToggleRefinement(_ref) {
|
|
13652
13671
|
var currentRefinement = _ref.currentRefinement,
|
|
@@ -13654,19 +13673,19 @@ var ToggleRefinement = function ToggleRefinement(_ref) {
|
|
|
13654
13673
|
canRefine = _ref.canRefine,
|
|
13655
13674
|
refine = _ref.refine,
|
|
13656
13675
|
className = _ref.className;
|
|
13657
|
-
return
|
|
13658
|
-
className: classnames(cx$
|
|
13659
|
-
},
|
|
13660
|
-
className: cx$
|
|
13661
|
-
},
|
|
13662
|
-
className: cx$
|
|
13676
|
+
return React.createElement("div", {
|
|
13677
|
+
className: classnames(cx$2('', !canRefine && '-noRefinement'), className)
|
|
13678
|
+
}, React.createElement("label", {
|
|
13679
|
+
className: cx$2('label')
|
|
13680
|
+
}, React.createElement("input", {
|
|
13681
|
+
className: cx$2('checkbox'),
|
|
13663
13682
|
type: "checkbox",
|
|
13664
13683
|
checked: currentRefinement,
|
|
13665
13684
|
onChange: function onChange(event) {
|
|
13666
13685
|
return refine(event.target.checked);
|
|
13667
13686
|
}
|
|
13668
|
-
}),
|
|
13669
|
-
className: cx$
|
|
13687
|
+
}), React.createElement("span", {
|
|
13688
|
+
className: cx$2('labelText')
|
|
13670
13689
|
}, label)));
|
|
13671
13690
|
};
|
|
13672
13691
|
|
|
@@ -13875,11 +13894,11 @@ function createVoiceSearchHelper(_ref) {
|
|
|
13875
13894
|
};
|
|
13876
13895
|
}
|
|
13877
13896
|
|
|
13878
|
-
var cx$
|
|
13897
|
+
var cx$1 = createClassNames('VoiceSearch');
|
|
13879
13898
|
|
|
13880
13899
|
var ButtonSvg = function ButtonSvg(_ref) {
|
|
13881
13900
|
var children = _ref.children;
|
|
13882
|
-
return
|
|
13901
|
+
return React.createElement("svg", {
|
|
13883
13902
|
xmlns: "http://www.w3.org/2000/svg",
|
|
13884
13903
|
width: "16",
|
|
13885
13904
|
height: "16",
|
|
@@ -13896,36 +13915,36 @@ var DefaultButtonText = function DefaultButtonText(_ref2) {
|
|
|
13896
13915
|
var status = _ref2.status,
|
|
13897
13916
|
errorCode = _ref2.errorCode,
|
|
13898
13917
|
isListening = _ref2.isListening;
|
|
13899
|
-
return status === 'error' && errorCode === 'not-allowed' ?
|
|
13918
|
+
return status === 'error' && errorCode === 'not-allowed' ? React.createElement(ButtonSvg, null, React.createElement("line", {
|
|
13900
13919
|
x1: "1",
|
|
13901
13920
|
y1: "1",
|
|
13902
13921
|
x2: "23",
|
|
13903
13922
|
y2: "23"
|
|
13904
|
-
}),
|
|
13923
|
+
}), React.createElement("path", {
|
|
13905
13924
|
d: "M9 9v3a3 3 0 0 0 5.12 2.12M15 9.34V4a3 3 0 0 0-5.94-.6"
|
|
13906
|
-
}),
|
|
13925
|
+
}), React.createElement("path", {
|
|
13907
13926
|
d: "M17 16.95A7 7 0 0 1 5 12v-2m14 0v2a7 7 0 0 1-.11 1.23"
|
|
13908
|
-
}),
|
|
13927
|
+
}), React.createElement("line", {
|
|
13909
13928
|
x1: "12",
|
|
13910
13929
|
y1: "19",
|
|
13911
13930
|
x2: "12",
|
|
13912
13931
|
y2: "23"
|
|
13913
|
-
}),
|
|
13932
|
+
}), React.createElement("line", {
|
|
13914
13933
|
x1: "8",
|
|
13915
13934
|
y1: "23",
|
|
13916
13935
|
x2: "16",
|
|
13917
13936
|
y2: "23"
|
|
13918
|
-
})) :
|
|
13937
|
+
})) : React.createElement(ButtonSvg, null, React.createElement("path", {
|
|
13919
13938
|
d: "M12 1a3 3 0 0 0-3 3v8a3 3 0 0 0 6 0V4a3 3 0 0 0-3-3z",
|
|
13920
13939
|
fill: isListening ? 'currentColor' : ''
|
|
13921
|
-
}),
|
|
13940
|
+
}), React.createElement("path", {
|
|
13922
13941
|
d: "M19 10v2a7 7 0 0 1-14 0v-2"
|
|
13923
|
-
}),
|
|
13942
|
+
}), React.createElement("line", {
|
|
13924
13943
|
x1: "12",
|
|
13925
13944
|
y1: "19",
|
|
13926
13945
|
x2: "12",
|
|
13927
13946
|
y2: "23"
|
|
13928
|
-
}),
|
|
13947
|
+
}), React.createElement("line", {
|
|
13929
13948
|
x1: "8",
|
|
13930
13949
|
y1: "23",
|
|
13931
13950
|
x2: "16",
|
|
@@ -13935,7 +13954,7 @@ var DefaultButtonText = function DefaultButtonText(_ref2) {
|
|
|
13935
13954
|
|
|
13936
13955
|
var DefaultStatus = function DefaultStatus(_ref3) {
|
|
13937
13956
|
var transcript = _ref3.transcript;
|
|
13938
|
-
return
|
|
13957
|
+
return React.createElement("p", null, transcript);
|
|
13939
13958
|
};
|
|
13940
13959
|
|
|
13941
13960
|
var VoiceSearch =
|
|
@@ -14020,17 +14039,17 @@ function (_Component) {
|
|
|
14020
14039
|
isSpeechFinal: isSpeechFinal,
|
|
14021
14040
|
isBrowserSupported: isBrowserSupported()
|
|
14022
14041
|
};
|
|
14023
|
-
return
|
|
14024
|
-
className: cx$
|
|
14025
|
-
},
|
|
14026
|
-
className: cx$
|
|
14042
|
+
return React.createElement("div", {
|
|
14043
|
+
className: cx$1('')
|
|
14044
|
+
}, React.createElement("button", {
|
|
14045
|
+
className: cx$1('button'),
|
|
14027
14046
|
type: "button",
|
|
14028
14047
|
title: isBrowserSupported() ? translate('buttonTitle') : translate('disabledButtonTitle'),
|
|
14029
14048
|
onClick: this.onClick,
|
|
14030
14049
|
disabled: !isBrowserSupported()
|
|
14031
|
-
},
|
|
14032
|
-
className: cx$
|
|
14033
|
-
},
|
|
14050
|
+
}, React.createElement(ButtonTextComponent, innerProps)), React.createElement("div", {
|
|
14051
|
+
className: cx$1('status')
|
|
14052
|
+
}, React.createElement(StatusComponent, innerProps)));
|
|
14034
14053
|
}
|
|
14035
14054
|
}, {
|
|
14036
14055
|
key: "componentWillUnmount",
|
|
@@ -14057,14 +14076,14 @@ var VoiceSearch$1 = translatable({
|
|
|
14057
14076
|
|
|
14058
14077
|
connectVoiceSearch(VoiceSearch$1);
|
|
14059
14078
|
|
|
14060
|
-
var cx
|
|
14079
|
+
var cx = createClassNames('QueryRuleCustomData');
|
|
14061
14080
|
|
|
14062
14081
|
var QueryRuleCustomData = function QueryRuleCustomData(_ref) {
|
|
14063
14082
|
var items = _ref.items,
|
|
14064
14083
|
className = _ref.className,
|
|
14065
14084
|
children = _ref.children;
|
|
14066
|
-
return
|
|
14067
|
-
className: classnames(cx
|
|
14085
|
+
return React.createElement("div", {
|
|
14086
|
+
className: classnames(cx(''), className)
|
|
14068
14087
|
}, children({
|
|
14069
14088
|
items: items
|
|
14070
14089
|
}));
|
|
@@ -14077,7 +14096,7 @@ QueryRuleCustomData.propTypes = {
|
|
|
14077
14096
|
};
|
|
14078
14097
|
|
|
14079
14098
|
var QueryRuleCustomDataWidget = function QueryRuleCustomDataWidget(props) {
|
|
14080
|
-
return
|
|
14099
|
+
return React.createElement(PanelWrapper, props, React.createElement(QueryRuleCustomData, props));
|
|
14081
14100
|
};
|
|
14082
14101
|
|
|
14083
14102
|
connectQueryRules(QueryRuleCustomDataWidget);
|
|
@@ -14098,54 +14117,54 @@ var AlgoliaSearch = function (_React$Component) {
|
|
|
14098
14117
|
styles = _props$propsObj.styles,
|
|
14099
14118
|
client = _props$propsObj.client;
|
|
14100
14119
|
|
|
14101
|
-
|
|
14120
|
+
|
|
14102
14121
|
var hit = props.hit;
|
|
14103
|
-
return
|
|
14122
|
+
return React.createElement(
|
|
14104
14123
|
'div',
|
|
14105
14124
|
{ key: hit.url, className: styles.article },
|
|
14106
|
-
|
|
14125
|
+
React.createElement(
|
|
14107
14126
|
'a',
|
|
14108
14127
|
{ href: '/view/' + hit.url, style: this.props.variant === 'right' ? { flexDirection: 'row-reverse' } : {} },
|
|
14109
|
-
|
|
14128
|
+
React.createElement(
|
|
14110
14129
|
'div',
|
|
14111
14130
|
{ className: styles.thumb },
|
|
14112
|
-
|
|
14131
|
+
React.createElement(
|
|
14113
14132
|
'figure',
|
|
14114
14133
|
null,
|
|
14115
|
-
|
|
14134
|
+
React.createElement(
|
|
14116
14135
|
LazyLoad,
|
|
14117
14136
|
null,
|
|
14118
|
-
|
|
14119
|
-
src: hit.thumbnail && hit.thumbnail.asset ?
|
|
14137
|
+
React.createElement('img', {
|
|
14138
|
+
src: hit.thumbnail && hit.thumbnail.asset ? urlFor({ client: client, source: hit.thumbnail }) : hit.thumbnail && _typeof$2(hit.thumbnail === 'string') ? hit.thumbnail : this.props.defaultImage
|
|
14120
14139
|
})
|
|
14121
14140
|
)
|
|
14122
14141
|
)
|
|
14123
14142
|
),
|
|
14124
|
-
|
|
14143
|
+
React.createElement(
|
|
14125
14144
|
'div',
|
|
14126
14145
|
{ className: styles.info, style: this.props.variant === 'right' ? { padding: '0 1rem 0 0' } : { padding: ' 0 0 0 1rem' } },
|
|
14127
|
-
|
|
14146
|
+
React.createElement(
|
|
14128
14147
|
'h2',
|
|
14129
14148
|
null,
|
|
14130
14149
|
hit.title
|
|
14131
14150
|
),
|
|
14132
|
-
hit.pubDateSort &&
|
|
14151
|
+
hit.pubDateSort && React.createElement(
|
|
14133
14152
|
'p',
|
|
14134
14153
|
{ className: styles.published },
|
|
14135
14154
|
moment(hit.pubDateSort).format('MMMM Do YYYY')
|
|
14136
14155
|
),
|
|
14137
|
-
hit.authorMapping && hit.authorMapping.length > 0 &&
|
|
14156
|
+
hit.authorMapping && hit.authorMapping.length > 0 && React.createElement(
|
|
14138
14157
|
'p',
|
|
14139
14158
|
{ className: styles.author },
|
|
14140
14159
|
hit.authorMapping.map(function (author) {
|
|
14141
|
-
return
|
|
14160
|
+
return React.createElement(
|
|
14142
14161
|
'span',
|
|
14143
14162
|
null,
|
|
14144
14163
|
author.displayName
|
|
14145
14164
|
);
|
|
14146
14165
|
})
|
|
14147
14166
|
),
|
|
14148
|
-
hit.summary &&
|
|
14167
|
+
hit.summary && React.createElement('p', { dangerouslySetInnerHTML: { __html: hit.summary }, className: styles.summary })
|
|
14149
14168
|
)
|
|
14150
14169
|
)
|
|
14151
14170
|
);
|
|
@@ -14159,10 +14178,10 @@ var AlgoliaSearch = function (_React$Component) {
|
|
|
14159
14178
|
styles: this.props.deckStyles,
|
|
14160
14179
|
client: this.props.sanityClient
|
|
14161
14180
|
};
|
|
14162
|
-
return
|
|
14163
|
-
|
|
14181
|
+
return React.createElement(
|
|
14182
|
+
React.Fragment,
|
|
14164
14183
|
null,
|
|
14165
|
-
|
|
14184
|
+
React.createElement(
|
|
14166
14185
|
InstantSearch,
|
|
14167
14186
|
_extends$1({
|
|
14168
14187
|
searchClient: this.props.searchClient,
|
|
@@ -14173,29 +14192,29 @@ var AlgoliaSearch = function (_React$Component) {
|
|
|
14173
14192
|
indexName: this.props.indexName,
|
|
14174
14193
|
onSearchParameters: this.props.onSearchParameters
|
|
14175
14194
|
}, this.props),
|
|
14176
|
-
|
|
14177
|
-
|
|
14178
|
-
this.props.refinementAttributes &&
|
|
14195
|
+
React.createElement(Configure, { hitsPerPage: this.props.hitsPerPage || 20 }),
|
|
14196
|
+
React.createElement(SearchBox, null),
|
|
14197
|
+
this.props.refinementAttributes && React.createElement(
|
|
14179
14198
|
'div',
|
|
14180
14199
|
{ className: 'search_refinement' },
|
|
14181
14200
|
this.props.refinementAttributes.map(function (item, index) {
|
|
14182
|
-
return
|
|
14201
|
+
return React.createElement(
|
|
14183
14202
|
DropdownButton,
|
|
14184
14203
|
{ title: item.title },
|
|
14185
|
-
|
|
14204
|
+
React.createElement(RefinementList, { showMore: item.showMore, limit: item.limit, showMoreLimit: item.showMoreLimit, attribute: item.attribute })
|
|
14186
14205
|
);
|
|
14187
14206
|
})
|
|
14188
14207
|
),
|
|
14189
|
-
|
|
14208
|
+
React.createElement(
|
|
14190
14209
|
'div',
|
|
14191
14210
|
{ className: 'AlgoliaResults' },
|
|
14192
|
-
|
|
14211
|
+
React.createElement(Hits, { hitComponent: function hitComponent(hit) {
|
|
14193
14212
|
return _this2.Deck(_extends$1({}, hit, { propsObj: propsObj }));
|
|
14194
14213
|
} })
|
|
14195
14214
|
),
|
|
14196
|
-
|
|
14215
|
+
React.createElement(Pagination, null)
|
|
14197
14216
|
),
|
|
14198
|
-
|
|
14217
|
+
React.createElement(
|
|
14199
14218
|
'style',
|
|
14200
14219
|
{ jsx: 'true' },
|
|
14201
14220
|
'\n .AlgoliaResults {\n padding-left: 15px;\n margin-top: 3rem;\n }\n\n .search_refinement {\n display: flex;\n margin: 2rem 0;\n }\n\n .search_refinement > div {\n padding-right: 1rem;\n max-height: 500px;\n }\n\n .ais-Hits-list {\n margin: 0;\n list-style: none;\n padding-inline-start: 0;\n }\n .ais-Pagination-list {\n list-style: none;\n }\n .ais-Pagination-list {\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n }\n .ais-Pagination-item + .ais-Pagination-item {\n margin-left: 0.3rem;\n }\n .ais-Pagination-link {\n padding: 0.3rem 0.6rem;\n display: block;\n border: 1px solid var(--search-primary);\n border-radius: 5px;\n transition: background-color 0.2s ease-out;\n }\n .ais-Pagination-link:focus,\n .ais-Pagination-link:hover {\n background-color: var(--search-secondary);\n color: #fff;\n }\n .ais-Pagination-item--disabled .ais-Pagination-link {\n opacity: 0.6;\n cursor: not-allowed;\n color: var(--search-secondary);\n }\n .ais-Pagination-item--disabled .ais-Pagination-link:focus,\n .ais-Pagination-item--disabled .ais-Pagination-link:hover {\n color: #fff;\n background-color: var(--search-secondary);\n }\n .ais-Pagination-item--selected .ais-Pagination-link {\n color: #fff;\n background-color: var(--search-primary);\n border-color: var(--search-primary);\n }\n .ais-Pagination-item--selected .ais-Pagination-link:focus,\n .ais-Pagination-item--selected .ais-Pagination-link:hover {\n color: #fff;\n }\n .ais-Pagination-list,\n .ais-Results-list {\n margin: 0;\n padding: 0;\n list-style: none;\n }\n .ais-Pagination-list,\n .ais-PoweredBy,\n .ais-RangeInput-form,\n .ais-RatingMenu-link {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n }\n\n .ais-RefinementList-item {\n list-style: none;\n margin: 0;\n padding: 0;\n }\n .ais-RefinementList-list {\n margin: 0;\n padding: 0 1rem;\n width: max-content;\n }\n .ais-SearchBox-form {\n width: 100%;\n border-radius: 5px;\n height: 48px;\n }\n .ais-SearchBox-input {\n padding: 0.5rem;\n border-radius: 5px;\n width: calc(100% - 150px);\n height: 48px;\n border: 0;\n border: 0.5px solid var(--search-secondary);\n }\n\n .ais-SearchBox-submit {\n width: 78px;\n border-radius: 5px;\n padding: 7px;\n margin-left: 5px;\n height: 48px;\n background-color: var(--search-primary);\n border: 0.5px solid var(--search-secondary);\n }\n\n .ais-SearchBox-submit > svg {\n fill: #fff;\n }\n .search_refinement > .dropdown > button {\n background-color: var(--search-primary);\n border-color: var(--search-primary);\n }\n\n .ais-SearchBox-reset {\n height: 48px;\n width: 48px;\n color: #fff;\n background-color: var(--search-primary);\n border: 0;\n margin-left: 5px;\n border-radius: 5px;\n border: 0.5px solid var(--search-secondary);\n }\n\n .ais-SearchBox-reset > svg {\n fill: #fff;\n }\n .ais-RefinementList-checkbox {\n margin-right: 5px;\n }\n\n .ais-RefinementList-showMore {\n padding: 0.5rem;\n border: 0;\n background-color: var(--search-primary);\n border-color: var(--search-primary);\n color: #fff;\n border: 1px solid;\n border-radius: 5px;\n margin-left: 1rem;\n }\n '
|
|
@@ -14205,7 +14224,7 @@ var AlgoliaSearch = function (_React$Component) {
|
|
|
14205
14224
|
}]);
|
|
14206
14225
|
|
|
14207
14226
|
return AlgoliaSearch;
|
|
14208
|
-
}(
|
|
14227
|
+
}(React.Component);
|
|
14209
14228
|
|
|
14210
14229
|
AlgoliaSearch.propTypes = {
|
|
14211
14230
|
searchState: PropTypes.object,
|