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