<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
	<!-- 2026 -->
	<meta charset="utf-8" />
	<meta name="csrf-token" content="U0NwIN1b3gNn49mAf2BsGgcgC9qYhbkX1Mnr377a" />
	<meta name="viewport" content="width=device-width, initial-scale=1" />
	<link rel="icon" type="image/x-icon" href="https://camlovin.com/favicon.ico" sizes="48x48" />
<link rel="icon" type="image/svg+xml" href="https://camlovin.com/favicon.svg" sizes="any" />
<link rel="apple-touch-icon"  href="https://camlovin.com/apple-touch-icon.png" />
<link rel="manifest" href="https://camlovin.com/site.webmanifest" />
	<link rel="canonical" href="https://camlovin.com" />
<meta property="og:locale" content="en" />
<meta property="og:site_name" content="CamLovin" />
<meta property="og:type" content="website" />
<meta property="og:url" content="https://camlovin.com" />
<link href="https://camlovin.com" rel="alternate" hreflang="x-default" />
<title>Free Live Sex Cams and Chat - All Cams in one Place - CamLovin</title>
<meta property="og:title" content="Free Live Sex Cams and Chat - All Cams in one Place - CamLovin" />
<meta name="twitter:title" content="Free Live Sex Cams and Chat - All Cams in one Place - CamLovin" />
<meta name="embedx:title" content="Free Live Sex Cams and Chat - All Cams in one Place - CamLovin" />
<meta name="description" content="CamLovin is the #1 free sex cam site. ☝️ Enjoy cams and sex chat from all providers in one place. Filter by age, language, and much more. ❤️" />
<meta property="og:description" content="CamLovin is the #1 free sex cam site. ☝️ Enjoy cams and sex chat from all providers in one place. Filter by age, language, and much more. ❤️" />
<meta name="twitter:description" content="CamLovin is the #1 free sex cam site. ☝️ Enjoy cams and sex chat from all providers in one place. Filter by age, language, and much more. ❤️" />
<meta name="embedx:description" content="CamLovin is the #1 free sex cam site. ☝️ Enjoy cams and sex chat from all providers in one place. Filter by age, language, and much more. ❤️" />
<script type="application/ld+json">{"@context":"https://schema.org","@graph":[{"@type":"Organization","name":"CamLovin","url":"https://camlovin.com","logo":"https://camlovin.com/logo.svg","alternateName":"CamLovin.com","contactPoint":{"@type":"ContactPoint","telephone":"+1 (408) 915-7294","email":"hello@camlovin.com","contactType":"customer service","availableLanguage":["en","es","German","Danish","Arabic","Portuguese","fr","Italian","Korean","Japanese"],"sameAs":["https://www.facebook.com/camlovin/","https://twitter.com/CamLovinLLC","https://www.instagram.com/camlovin_official/","https://www.youtube.com/@CamLovin_Official","https://www.linkedin.com/company/camlovin/"]},"@id":"https://camlovin.com#organization"},{"@type":"WebSite","url":"https://camlovin.com","name":"CamLovin","description":"The #1 free sex cam site in 2026 and beyond.","publisher":{"@id":"https://camlovin.com#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://camlovin.com?q={search_term_string}"},"query-input":"required name=search_term_string"},"inLanguage":"en","@id":"https://camlovin.com#website"}]}</script>
	<link
            href="https://camlovin.com/css/awcodes-sticky-header/awcodes-sticky-header.css?v=3.3.45.0"
            rel="stylesheet"
            data-navigate-track
        />
                    <link
            href="https://camlovin.com/css/awcodes/filament-badgeable-column/filament-badgeable-column.css?v=2.3.4.0"
            rel="stylesheet"
            data-navigate-track
        />
                    <link
            href="https://camlovin.com/css/bezhansalleh/filament-google-analytics/filament-google-analytics.css?v=2.1.2.0"
            rel="stylesheet"
            data-navigate-track
        />
                <link
            href="https://camlovin.com/css/filament/forms/forms.css?v=3.3.45.0"
            rel="stylesheet"
            data-navigate-track
        />
                <link
            href="https://camlovin.com/css/filament/support/support.css?v=3.3.45.0"
            rel="stylesheet"
            data-navigate-track
        />
                <link
            href="https://camlovin.com/css/guava/filament-clusters/stylesheet.css?v=1.5.0.0"
            rel="stylesheet"
            data-navigate-track
        />
                <link
            href="https://camlovin.com/css/guava/filament-icon-picker/filament-icon-picker-stylesheet.css?v=2.3.1.0"
            rel="stylesheet"
            data-navigate-track
        />
    
<style>
    :root {
         --danger-50:254, 242, 242;  --danger-100:254, 226, 226;  --danger-200:254, 202, 202;  --danger-300:252, 165, 165;  --danger-400:248, 113, 113;  --danger-500:239, 68, 68;  --danger-600:220, 38, 38;  --danger-700:185, 28, 28;  --danger-800:153, 27, 27;  --danger-900:127, 29, 29;  --danger-950:69, 10, 10;  --gray-50:248, 250, 252;  --gray-100:241, 245, 249;  --gray-200:226, 232, 240;  --gray-300:203, 213, 225;  --gray-400:148, 163, 184;  --gray-500:100, 116, 139;  --gray-600:71, 85, 105;  --gray-700:51, 65, 85;  --gray-800:30, 41, 59;  --gray-900:15, 23, 42;  --gray-950:2, 6, 23;  --info-50:239, 246, 255;  --info-100:219, 234, 254;  --info-200:191, 219, 254;  --info-300:147, 197, 253;  --info-400:96, 165, 250;  --info-500:59, 130, 246;  --info-600:37, 99, 235;  --info-700:29, 78, 216;  --info-800:30, 64, 175;  --info-900:30, 58, 138;  --info-950:23, 37, 84;  --primary-50:240, 249, 255;  --primary-100:224, 242, 254;  --primary-200:186, 230, 253;  --primary-300:125, 211, 252;  --primary-400:56, 189, 248;  --primary-500:14, 165, 233;  --primary-600:2, 132, 199;  --primary-700:3, 105, 161;  --primary-800:7, 89, 133;  --primary-900:12, 74, 110;  --primary-950:8, 47, 73;  --success-50:240, 253, 244;  --success-100:220, 252, 231;  --success-200:187, 247, 208;  --success-300:134, 239, 172;  --success-400:74, 222, 128;  --success-500:34, 197, 94;  --success-600:22, 163, 74;  --success-700:21, 128, 61;  --success-800:22, 101, 52;  --success-900:20, 83, 45;  --success-950:5, 46, 22;  --warning-50:255, 251, 235;  --warning-100:254, 243, 199;  --warning-200:253, 230, 138;  --warning-300:252, 211, 77;  --warning-400:251, 191, 36;  --warning-500:245, 158, 11;  --warning-600:217, 119, 6;  --warning-700:180, 83, 9;  --warning-800:146, 64, 14;  --warning-900:120, 53, 15;  --warning-950:69, 26, 3;     }
</style>
	<link rel="preload" as="style" href="https://camlovin.com/build/assets/app-CQrxRDVf.css" /><link rel="modulepreload" href="https://camlovin.com/build/assets/app-DggXgl0z.js" /><link rel="stylesheet" href="https://camlovin.com/build/assets/app-CQrxRDVf.css" data-navigate-track="reload" /><script type="module" src="https://camlovin.com/build/assets/app-DggXgl0z.js" data-navigate-track="reload"></script>	<link rel="preconnect" href="https://fonts.bunny.net" crossorigin />
<link rel="preload" as="style" href="https://fonts.bunny.net/css?family=inter:100,200,300,400,500,600,700,800,900&display=swap" />
<link rel="stylesheet" media="print" onload="this.onload=null;this.removeAttribute('media');" href="https://fonts.bunny.net/css?family=inter:100,200,300,400,500,600,700,800,900&display=swap" />
<noscript><link rel="stylesheet" href="https://fonts.bunny.net/css?family=inter:100,200,300,400,500,600,700,800,900&display=swap" /></noscript>
				<script src="https://cdn.usefathom.com/script.js" data-site="KIBLYGKK" defer></script>
		<script>(function (w, d, s, l, i) { w[l] = w[l] || []; w[l].push({ "gtm.start": new Date().getTime(), event: "gtm.js", }); var f = d.getElementsByTagName(s)[0], j = d.createElement(s), dl = l != "dataLayer" ? "&l=" + l : ""; j.async = true; j.src = "https://www.googletagmanager.com/gtm.js?id=" + i + dl; f.parentNode.insertBefore(j, f); })(window, document, "script", "dataLayer", "GTM-K6S7RRT3");</script>
	<!-- Livewire Styles --><style >[wire\:loading][wire\:loading], [wire\:loading\.delay][wire\:loading\.delay], [wire\:loading\.inline-block][wire\:loading\.inline-block], [wire\:loading\.inline][wire\:loading\.inline], [wire\:loading\.block][wire\:loading\.block], [wire\:loading\.flex][wire\:loading\.flex], [wire\:loading\.table][wire\:loading\.table], [wire\:loading\.grid][wire\:loading\.grid], [wire\:loading\.inline-flex][wire\:loading\.inline-flex] {display: none;}[wire\:loading\.delay\.none][wire\:loading\.delay\.none], [wire\:loading\.delay\.shortest][wire\:loading\.delay\.shortest], [wire\:loading\.delay\.shorter][wire\:loading\.delay\.shorter], [wire\:loading\.delay\.short][wire\:loading\.delay\.short], [wire\:loading\.delay\.default][wire\:loading\.delay\.default], [wire\:loading\.delay\.long][wire\:loading\.delay\.long], [wire\:loading\.delay\.longer][wire\:loading\.delay\.longer], [wire\:loading\.delay\.longest][wire\:loading\.delay\.longest] {display: none;}[wire\:offline][wire\:offline] {display: none;}[wire\:dirty]:not(textarea):not(input):not(select) {display: none;}:root {--livewire-progress-bar-color: #2299dd;}[x-cloak] {display: none !important;}[wire\:cloak] {display: none !important;}dialog#livewire-error::backdrop {background-color: rgba(0, 0, 0, .6);}</style>
</head>
<body class="flex flex-col min-h-screen bg-gray-50 font-normal text-gray-950 antialiased dark:bg-gray-950 dark:text-white">
	<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-K6S7RRT3" height="0" width="0" style="display: none; visibility: hidden"></iframe></noscript>
<nav wire:snapshot="{&quot;data&quot;:[],&quot;memo&quot;:{&quot;id&quot;:&quot;dXoPYnDqzC60n1QELk8t&quot;,&quot;name&quot;:&quot;navigations.navbar&quot;,&quot;path&quot;:&quot;\/&quot;,&quot;method&quot;:&quot;GET&quot;,&quot;release&quot;:&quot;a-a-a&quot;,&quot;children&quot;:[],&quot;scripts&quot;:[],&quot;assets&quot;:[],&quot;errors&quot;:[],&quot;locale&quot;:&quot;en&quot;},&quot;checksum&quot;:&quot;61e2a25663b9ac371d940c37aa2c399d58a2e96167d442a289c61825860ce2ba&quot;}" wire:effects="[]" wire:id="dXoPYnDqzC60n1QELk8t"
        x-data="{ open: false }"
        class="sticky top-0 z-20 w-full bg-white dark:bg-gray-900 shadow ring-1 ring-gray-950/5 dark:ring-white/10"
    >
        <div class="w-full max-w-full mx-auto px-4 md:px-6 lg:px-8">
            <div class="flex items-center justify-between h-14">
                <div class="flex items-center space-x-8">
                    <div>
                        <a href="https://camlovin.com" wire:navigate class="font-black text-2xl text-primary-500">
	CamLovin
</a>
                    </div>

                    <ul class="items-center hidden space-x-2 text-sm font-medium text-gray-600 md:flex">
                        <!--[if BLOCK]><![endif]-->			<li>
    <a
         aria-current="page"         class="px-3 py-2 transition rounded-lg focus:outline-none text-primary-600 bg-primary-50 dark:bg-gray-900 ring-2 ring-primary-500 ring-inset flex items-center space-x-1" href="https://camlovin.com" wire:navigate=""
    >
        <svg class="w-5 h-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M166,104a38,38,0,1,0-38,38A38,38,0,0,0,166,104Zm-64,0a26,26,0,1,1,26,26A26,26,0,0,1,102,104Zm122,98H134V181.75a78,78,0,1,0-12,0V202H32a6,6,0,0,0,0,12H224a6,6,0,0,0,0-12ZM62,104a66,66,0,1,1,66,66A66.08,66.08,0,0,1,62,104Z"/></svg>				<span>Cams</span>
    </a>
</li>
					<li>
    <a
                class="px-3 py-2 transition rounded-lg focus:outline-none hover:text-primary-600 dark:hover:text-primary-400 focus:text-primary-600 hover:bg-primary-500/10 focus:bg-primary-500/10 dark:text-gray-300 focus:ring-2 focus:ring-primary-500 focus:ring-inset flex items-center space-x-1" href="https://camlovin.com/sites" wire:navigate=""
    >
        <svg class="w-5 h-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M216,42H72A14,14,0,0,0,58,56V74H40A14,14,0,0,0,26,88V200a14,14,0,0,0,14,14H184a14,14,0,0,0,14-14V182h18a14,14,0,0,0,14-14V56A14,14,0,0,0,216,42ZM40,86H184a2,2,0,0,1,2,2v18H38V88A2,2,0,0,1,40,86ZM186,200a2,2,0,0,1-2,2H40a2,2,0,0,1-2-2V118H186Zm32-32a2,2,0,0,1-2,2H198V88a14,14,0,0,0-14-14H70V56a2,2,0,0,1,2-2H216a2,2,0,0,1,2,2Z"/></svg>				<span>Sites</span>
    </a>
</li>
					<li>
    <a
                class="px-3 py-2 transition rounded-lg focus:outline-none hover:text-primary-600 dark:hover:text-primary-400 focus:text-primary-600 hover:bg-primary-500/10 focus:bg-primary-500/10 dark:text-gray-300 focus:ring-2 focus:ring-primary-500 focus:ring-inset flex items-center space-x-1" href="https://camlovin.com/bookmarks" wire:navigate=""
    >
        <svg class="w-5 h-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M192,26H96A14,14,0,0,0,82,40V58H64A14,14,0,0,0,50,72V224a6,6,0,0,0,9.49,4.88L112,191.37l52.52,37.51A6,6,0,0,0,174,224V180.8l22.51,16.08A6,6,0,0,0,206,192V40A14,14,0,0,0,192,26ZM162,212.34l-46.52-33.22a6,6,0,0,0-7,0L62,212.34V72a2,2,0,0,1,2-2h96a2,2,0,0,1,2,2Zm32-32-20-14.28V72a14,14,0,0,0-14-14H94V40a2,2,0,0,1,2-2h96a2,2,0,0,1,2,2Z"/></svg>				<span>Bookmarks</span>
    </a>
</li>
					<li>
    <a
                class="px-3 py-2 transition rounded-lg focus:outline-none hover:text-primary-600 dark:hover:text-primary-400 focus:text-primary-600 hover:bg-primary-500/10 focus:bg-primary-500/10 dark:text-gray-300 focus:ring-2 focus:ring-primary-500 focus:ring-inset flex items-center space-x-1" href="https://camlovin.com/random" wire:navigate=""
    >
        <svg class="w-5 h-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M236.24,179.76a6,6,0,0,1,0,8.48l-24,24a6,6,0,0,1-8.48-8.48L217.52,190H200.94a70.16,70.16,0,0,1-57-29.31l-41.71-58.4A58.11,58.11,0,0,0,55.06,78H32a6,6,0,0,1,0-12H55.06a70.16,70.16,0,0,1,57,29.31l41.71,58.4A58.11,58.11,0,0,0,200.94,178h16.58l-13.76-13.76a6,6,0,0,1,8.48-8.48Zm-92.06-74.41a5.91,5.91,0,0,0,3.48,1.12,6,6,0,0,0,4.89-2.51l1.19-1.67A58.11,58.11,0,0,1,200.94,78h16.58L203.76,91.76a6,6,0,1,0,8.48,8.48l24-24a6,6,0,0,0,0-8.48l-24-24a6,6,0,0,0-8.48,8.48L217.52,66H200.94a70.16,70.16,0,0,0-57,29.31L142.78,97A6,6,0,0,0,144.18,105.35Zm-32.36,45.3a6,6,0,0,0-8.37,1.39l-1.19,1.67A58.11,58.11,0,0,1,55.06,178H32a6,6,0,0,0,0,12H55.06a70.16,70.16,0,0,0,57-29.31l1.19-1.67A6,6,0,0,0,111.82,150.65Z"/></svg>				<span>Random</span>
    </a>
</li>
					<li>
    <a
                class="px-3 py-2 transition rounded-lg focus:outline-none hover:text-primary-600 dark:hover:text-primary-400 focus:text-primary-600 hover:bg-primary-500/10 focus:bg-primary-500/10 dark:text-gray-300 focus:ring-2 focus:ring-primary-500 focus:ring-inset flex items-center space-x-1" href="https://camlovin.com/insights" wire:navigate=""
    >
        <svg class="w-5 h-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M225.9,74.78,181.21,30.09a14,14,0,0,0-19.8,0L38.1,153.41a13.94,13.94,0,0,0-4.1,9.9V208a14,14,0,0,0,14,14H92.69a13.94,13.94,0,0,0,9.9-4.1L225.9,94.58a14,14,0,0,0,0-19.8ZM48.49,160,136,72.48,155.51,92,68,179.51ZM46,208V174.48L81.51,210H48A2,2,0,0,1,46,208Zm50-.49L76.49,188,164,100.48,183.51,120ZM217.41,86.1,192,111.51,144.49,64,169.9,38.58a2,2,0,0,1,2.83,0l44.68,44.69a2,2,0,0,1,0,2.83Z"/></svg>				<span>Insights</span>
    </a>
</li>
		<!--[if ENDBLOCK]><![endif]-->
                    </ul>
                </div>

                <div class="flex items-center">
                    <div class="hidden md:flex items-center space-x-2">
                        <!--[if BLOCK]><![endif]-->
			<div
    x-data="{
        toggle: function (event) {
            $refs.panel?.toggle(event)
        },

        open: function (event) {
            $refs.panel?.open(event)
        },

        close: function (event) {
            $refs.panel?.close(event)
        },
    }"
    class="fi-dropdown"
>
    <div
        x-on:click="toggle"
        class="fi-dropdown-trigger flex cursor-pointer"
    >
        <!--[if BLOCK]><![endif]-->    <button
                                style="--c-300:var(--black-300);--c-400:var(--black-400);--c-500:var(--black-500);--c-600:var(--black-600);" class="fi-icon-btn relative flex items-center justify-center rounded-lg outline-none transition duration-75 focus-visible:ring-2 -m-2 h-10 w-10 fi-color-custom text-custom-500 hover:text-custom-600 focus-visible:ring-custom-600 dark:text-custom-400 dark:hover:text-custom-300 dark:focus-visible:ring-custom-500 fi-color-black" title="Settings" type="button" wire:loading.attr="disabled"
    >
        <!--[if BLOCK]><![endif]-->            <span class="sr-only">
                Settings
            </span>
        <!--[if ENDBLOCK]><![endif]-->
        <!--[if BLOCK]><![endif]-->    <svg class="fi-icon-btn-icon h-6 w-6" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M112,60a16,16,0,1,1,16,16A16,16,0,0,1,112,60Zm16,52a16,16,0,1,0,16,16A16,16,0,0,0,128,112Zm0,68a16,16,0,1,0,16,16A16,16,0,0,0,128,180Z"/></svg><!--[if ENDBLOCK]><![endif]-->
        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->
        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->    </button>
<!--[if ENDBLOCK]><![endif]-->
    </div>

    <!--[if BLOCK]><![endif]-->        <div
            x-cloak
            x-float.placement.bottom-end.flip.offset="{ offset: 8,  }"
            x-ref="panel"
            x-transition:enter-start="opacity-0"
            x-transition:leave-end="opacity-0"
                        class="fi-dropdown-panel absolute z-10 w-screen divide-y divide-gray-100 rounded-lg bg-white shadow-lg ring-1 ring-gray-950/5 transition dark:divide-white/5 dark:bg-gray-900 dark:ring-white/10 !max-w-[14rem]"
            style=""
        >
            <div class="fi-dropdown-list p-1">
    <!--[if BLOCK]><![endif]-->    <a
        href="https://camlovin.com/bookmarks"
                                style=";" class="fi-dropdown-list-item flex w-full items-center gap-2 whitespace-nowrap rounded-md p-2 text-sm transition-colors duration-75 outline-none disabled:pointer-events-none disabled:opacity-70 hover:bg-gray-50 focus-visible:bg-gray-50 dark:hover:bg-white/5 dark:focus-visible:bg-white/5 fi-dropdown-list-item-color-gray fi-color-gray" wire:navigate=""
    >
        <!--[if BLOCK]><![endif]-->            <!--[if BLOCK]><![endif]-->    <svg class="fi-dropdown-list-item-icon h-5 w-5 text-gray-400 dark:text-gray-500" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M192,24H96A16,16,0,0,0,80,40V56H64A16,16,0,0,0,48,72V224a8,8,0,0,0,12.65,6.51L112,193.83l51.36,36.68A8,8,0,0,0,176,224V184.69l19.35,13.82A8,8,0,0,0,208,192V40A16,16,0,0,0,192,24ZM160,208.46l-43.36-31a8,8,0,0,0-9.3,0L64,208.45V72h96Zm32-32L176,165V72a16,16,0,0,0-16-16H96V40h96Z"/></svg><!--[if ENDBLOCK]><![endif]-->        <!--[if ENDBLOCK]><![endif]-->
        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->
        <span class="fi-dropdown-list-item-label flex-1 truncate text-start text-gray-700 dark:text-gray-200" style="">
            Bookmarks
        </span>

        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->    </a>
<!--[if ENDBLOCK]><![endif]-->
					<!--[if BLOCK]><![endif]-->    <a
        href="https://camlovin.com/history"
                                style=";" class="fi-dropdown-list-item flex w-full items-center gap-2 whitespace-nowrap rounded-md p-2 text-sm transition-colors duration-75 outline-none disabled:pointer-events-none disabled:opacity-70 hover:bg-gray-50 focus-visible:bg-gray-50 dark:hover:bg-white/5 dark:focus-visible:bg-white/5 fi-dropdown-list-item-color-gray fi-color-gray" wire:navigate=""
    >
        <!--[if BLOCK]><![endif]-->            <!--[if BLOCK]><![endif]-->    <svg class="fi-dropdown-list-item-icon h-5 w-5 text-gray-400 dark:text-gray-500" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M136,80v43.47l36.12,21.67a8,8,0,0,1-8.24,13.72l-40-24A8,8,0,0,1,120,128V80a8,8,0,0,1,16,0Zm-8-48A95.44,95.44,0,0,0,60.08,60.15C52.81,67.51,46.35,74.59,40,82V64a8,8,0,0,0-16,0v40a8,8,0,0,0,8,8H72a8,8,0,0,0,0-16H49c7.15-8.42,14.27-16.35,22.39-24.57a80,80,0,1,1,1.66,114.75,8,8,0,1,0-11,11.64A96,96,0,1,0,128,32Z"/></svg><!--[if ENDBLOCK]><![endif]-->        <!--[if ENDBLOCK]><![endif]-->
        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->
        <span class="fi-dropdown-list-item-label flex-1 truncate text-start text-gray-700 dark:text-gray-200" style="">
            History
        </span>

        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->    </a>
<!--[if ENDBLOCK]><![endif]-->
</div>

				<div class="fi-dropdown-list p-1">
    <!--[if BLOCK]><![endif]-->    <a
        href="https://camlovin.com/contact"
                                style=";" class="fi-dropdown-list-item flex w-full items-center gap-2 whitespace-nowrap rounded-md p-2 text-sm transition-colors duration-75 outline-none disabled:pointer-events-none disabled:opacity-70 hover:bg-gray-50 focus-visible:bg-gray-50 dark:hover:bg-white/5 dark:focus-visible:bg-white/5 fi-dropdown-list-item-color-gray fi-color-gray" wire:navigate=""
    >
        <!--[if BLOCK]><![endif]-->            <!--[if BLOCK]><![endif]-->    <svg class="fi-dropdown-list-item-icon h-5 w-5 text-gray-400 dark:text-gray-500" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M140,128a12,12,0,1,1-12-12A12,12,0,0,1,140,128ZM84,116a12,12,0,1,0,12,12A12,12,0,0,0,84,116Zm88,0a12,12,0,1,0,12,12A12,12,0,0,0,172,116Zm60,12A104,104,0,0,1,79.12,219.82L45.07,231.17a16,16,0,0,1-20.24-20.24l11.35-34.05A104,104,0,1,1,232,128Zm-16,0A88,88,0,1,0,51.81,172.06a8,8,0,0,1,.66,6.54L40,216,77.4,203.53a7.85,7.85,0,0,1,2.53-.42,8,8,0,0,1,4,1.08A88,88,0,0,0,216,128Z"/></svg><!--[if ENDBLOCK]><![endif]-->        <!--[if ENDBLOCK]><![endif]-->
        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->
        <span class="fi-dropdown-list-item-label flex-1 truncate text-start text-gray-700 dark:text-gray-200" style="">
            Send feedback
        </span>

        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->    </a>
<!--[if ENDBLOCK]><![endif]-->
</div>

				<div class="fi-dropdown-list p-1">
    <div
    x-data="{ theme: null }"
    x-init="
        $watch('theme', () => {
            $dispatch('theme-changed', theme)
        })

        theme = localStorage.getItem('theme') || 'system'    "
    class="fi-theme-switcher grid grid-flow-col gap-x-1"
>
    <button
    aria-label="Enable light theme"
    type="button"
    x-on:click="(theme = 'light') && close()"
    x-tooltip="{
        content: 'Enable light theme',
        theme: $store.theme,
    }"
    class="fi-theme-switcher-btn flex justify-center rounded-md p-2 outline-none transition duration-75 hover:bg-gray-50 focus-visible:bg-gray-50 dark:hover:bg-white/5 dark:focus-visible:bg-white/5"
    x-bind:class="
        theme === 'light'            ? 'fi-active bg-gray-50 text-primary-500 dark:bg-white/5 dark:text-primary-400'
            : 'text-gray-400 hover:text-gray-500 focus-visible:text-gray-500 dark:text-gray-500 dark:hover:text-gray-400 dark:focus-visible:text-gray-400'
    "
>
    <!--[if BLOCK]><![endif]-->    <svg class="h-5 w-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" fill="currentColor" aria-hidden="true" data-slot="icon">
  <path d="M10 2a.75.75 0 0 1 .75.75v1.5a.75.75 0 0 1-1.5 0v-1.5A.75.75 0 0 1 10 2ZM10 15a.75.75 0 0 1 .75.75v1.5a.75.75 0 0 1-1.5 0v-1.5A.75.75 0 0 1 10 15ZM10 7a3 3 0 1 0 0 6 3 3 0 0 0 0-6ZM15.657 5.404a.75.75 0 1 0-1.06-1.06l-1.061 1.06a.75.75 0 0 0 1.06 1.06l1.06-1.06ZM6.464 14.596a.75.75 0 1 0-1.06-1.06l-1.06 1.06a.75.75 0 0 0 1.06 1.06l1.06-1.06ZM18 10a.75.75 0 0 1-.75.75h-1.5a.75.75 0 0 1 0-1.5h1.5A.75.75 0 0 1 18 10ZM5 10a.75.75 0 0 1-.75.75h-1.5a.75.75 0 0 1 0-1.5h1.5A.75.75 0 0 1 5 10ZM14.596 15.657a.75.75 0 0 0 1.06-1.06l-1.06-1.061a.75.75 0 1 0-1.06 1.06l1.06 1.06ZM5.404 6.464a.75.75 0 0 0 1.06-1.06l-1.06-1.06a.75.75 0 1 0-1.061 1.06l1.06 1.06Z"/>
</svg><!--[if ENDBLOCK]><![endif]--></button>

    <button
    aria-label="Enable dark theme"
    type="button"
    x-on:click="(theme = 'dark') && close()"
    x-tooltip="{
        content: 'Enable dark theme',
        theme: $store.theme,
    }"
    class="fi-theme-switcher-btn flex justify-center rounded-md p-2 outline-none transition duration-75 hover:bg-gray-50 focus-visible:bg-gray-50 dark:hover:bg-white/5 dark:focus-visible:bg-white/5"
    x-bind:class="
        theme === 'dark'            ? 'fi-active bg-gray-50 text-primary-500 dark:bg-white/5 dark:text-primary-400'
            : 'text-gray-400 hover:text-gray-500 focus-visible:text-gray-500 dark:text-gray-500 dark:hover:text-gray-400 dark:focus-visible:text-gray-400'
    "
>
    <!--[if BLOCK]><![endif]-->    <svg class="h-5 w-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" fill="currentColor" aria-hidden="true" data-slot="icon">
  <path fill-rule="evenodd" d="M7.455 2.004a.75.75 0 0 1 .26.77 7 7 0 0 0 9.958 7.967.75.75 0 0 1 1.067.853A8.5 8.5 0 1 1 6.647 1.921a.75.75 0 0 1 .808.083Z" clip-rule="evenodd"/>
</svg><!--[if ENDBLOCK]><![endif]--></button>

    <button
    aria-label="Enable system theme"
    type="button"
    x-on:click="(theme = 'system') && close()"
    x-tooltip="{
        content: 'Enable system theme',
        theme: $store.theme,
    }"
    class="fi-theme-switcher-btn flex justify-center rounded-md p-2 outline-none transition duration-75 hover:bg-gray-50 focus-visible:bg-gray-50 dark:hover:bg-white/5 dark:focus-visible:bg-white/5"
    x-bind:class="
        theme === 'system'            ? 'fi-active bg-gray-50 text-primary-500 dark:bg-white/5 dark:text-primary-400'
            : 'text-gray-400 hover:text-gray-500 focus-visible:text-gray-500 dark:text-gray-500 dark:hover:text-gray-400 dark:focus-visible:text-gray-400'
    "
>
    <!--[if BLOCK]><![endif]-->    <svg class="h-5 w-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" fill="currentColor" aria-hidden="true" data-slot="icon">
  <path fill-rule="evenodd" d="M2 4.25A2.25 2.25 0 0 1 4.25 2h11.5A2.25 2.25 0 0 1 18 4.25v8.5A2.25 2.25 0 0 1 15.75 15h-3.105a3.501 3.501 0 0 0 1.1 1.677A.75.75 0 0 1 13.26 18H6.74a.75.75 0 0 1-.484-1.323A3.501 3.501 0 0 0 7.355 15H4.25A2.25 2.25 0 0 1 2 12.75v-8.5Zm1.5 0a.75.75 0 0 1 .75-.75h11.5a.75.75 0 0 1 .75.75v7.5a.75.75 0 0 1-.75.75H4.25a.75.75 0 0 1-.75-.75v-7.5Z" clip-rule="evenodd"/>
</svg><!--[if ENDBLOCK]><![endif]--></button>
</div>
</div>
        </div>
    <!--[if ENDBLOCK]><![endif]--></div>

			<!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->
<a
            href="https://camlovin.com/login"
                        style="--c-400:var(--primary-400);--c-500:var(--primary-500);--c-600:var(--primary-600);" class="fi-btn relative grid-flow-col items-center justify-center font-semibold outline-none transition duration-75 focus-visible:ring-2 rounded-lg fi-color-custom fi-btn-color-primary fi-color-primary fi-size-sm fi-btn-size-sm gap-1 px-2.5 py-1.5 text-sm inline-grid fi-btn-outlined ring-1 text-custom-600 ring-custom-600 hover:bg-custom-400/10 dark:text-custom-400 dark:ring-custom-500" wire:navigate=""
>
    <!--[if BLOCK]><![endif]-->        <!--[if BLOCK]><![endif]-->            <!--[if BLOCK]><![endif]-->    <svg class="fi-btn-icon transition duration-75 h-4 w-4" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M230.92,212c-15.23-26.33-38.7-45.21-66.09-54.16a72,72,0,1,0-73.66,0C63.78,166.78,40.31,185.66,25.08,212a8,8,0,1,0,13.85,8c18.84-32.56,52.14-52,89.07-52s70.23,19.44,89.07,52a8,8,0,1,0,13.85-8ZM72,96a56,56,0,1,1,56,56A56.06,56.06,0,0,1,72,96Z"/></svg><!--[if ENDBLOCK]><![endif]-->        <!--[if ENDBLOCK]><![endif]-->
        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->
        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->    <!--[if ENDBLOCK]><![endif]-->
    <span
                class="fi-btn-label"
    >
        Login
    </span>

    <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->
    <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->
    <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]--></a>
		<!--[if ENDBLOCK]><![endif]-->
                    </div>

                    <div class="md:hidden">
                        <!--[if BLOCK]><![endif]-->    <button
                                style="--c-300:var(--primary-300);--c-400:var(--primary-400);--c-500:var(--primary-500);--c-600:var(--primary-600);" class="fi-icon-btn relative flex items-center justify-center rounded-lg outline-none transition duration-75 focus-visible:ring-2 -m-2 h-10 w-10 fi-color-custom text-custom-500 hover:text-custom-600 focus-visible:ring-custom-600 dark:text-custom-400 dark:hover:text-custom-300 dark:focus-visible:ring-custom-500 fi-color-primary" type="button" wire:loading.attr="disabled" x-bind:aria-expanded="open" x-on:click="open = ! open"
    >
        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->
        <!--[if BLOCK]><![endif]-->    <svg class="fi-icon-btn-icon h-6 w-6" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M224,128a8,8,0,0,1-8,8H40a8,8,0,0,1,0-16H216A8,8,0,0,1,224,128ZM40,72H216a8,8,0,0,0,0-16H40a8,8,0,0,0,0,16ZM216,184H40a8,8,0,0,0,0,16H216a8,8,0,0,0,0-16Z"/></svg><!--[if ENDBLOCK]><![endif]-->
        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->
        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->    </button>
<!--[if ENDBLOCK]><![endif]-->                    </div>
                </div>
            </div>

            <div
                x-show="open"
                x-cloak
                id="mobile-menu"
                class="px-2 md:hidden"
            >
                <div aria-hidden="true" class="border-t dark:border-t-gray-600"></div>

                <ul class="flex flex-col py-2 space-y-1 text-sm font-medium text-gray-600">
                    <!--[if BLOCK]><![endif]-->			<li>
    <a
         aria-current="page"         class="block p-2 transition rounded-lg focus:outline-none text-primary-600 bg-primary-50 dark:bg-gray-900 ring-2 ring-primary-500 ring-inset flex items-center space-x-1" href="https://camlovin.com" wire:navigate=""
    >
        <svg class="w-5 h-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M166,104a38,38,0,1,0-38,38A38,38,0,0,0,166,104Zm-64,0a26,26,0,1,1,26,26A26,26,0,0,1,102,104Zm122,98H134V181.75a78,78,0,1,0-12,0V202H32a6,6,0,0,0,0,12H224a6,6,0,0,0,0-12ZM62,104a66,66,0,1,1,66,66A66.08,66.08,0,0,1,62,104Z"/></svg>				<span>Cams</span>
    </a>
</li>
					<li>
    <a
                class="block p-2 transition rounded-lg focus:outline-none hover:text-primary-600 dark:hover:text-primary-400 focus:text-primary-600 hover:bg-primary-500/10 focus:bg-primary-500/10 dark:text-gray-300 focus:ring-2 focus:ring-primary-500 focus:ring-inset flex items-center space-x-1" href="https://camlovin.com/sites" wire:navigate=""
    >
        <svg class="w-5 h-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M216,42H72A14,14,0,0,0,58,56V74H40A14,14,0,0,0,26,88V200a14,14,0,0,0,14,14H184a14,14,0,0,0,14-14V182h18a14,14,0,0,0,14-14V56A14,14,0,0,0,216,42ZM40,86H184a2,2,0,0,1,2,2v18H38V88A2,2,0,0,1,40,86ZM186,200a2,2,0,0,1-2,2H40a2,2,0,0,1-2-2V118H186Zm32-32a2,2,0,0,1-2,2H198V88a14,14,0,0,0-14-14H70V56a2,2,0,0,1,2-2H216a2,2,0,0,1,2,2Z"/></svg>				<span>Sites</span>
    </a>
</li>
					<li>
    <a
                class="block p-2 transition rounded-lg focus:outline-none hover:text-primary-600 dark:hover:text-primary-400 focus:text-primary-600 hover:bg-primary-500/10 focus:bg-primary-500/10 dark:text-gray-300 focus:ring-2 focus:ring-primary-500 focus:ring-inset flex items-center space-x-1" href="https://camlovin.com/bookmarks" wire:navigate=""
    >
        <svg class="w-5 h-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M192,26H96A14,14,0,0,0,82,40V58H64A14,14,0,0,0,50,72V224a6,6,0,0,0,9.49,4.88L112,191.37l52.52,37.51A6,6,0,0,0,174,224V180.8l22.51,16.08A6,6,0,0,0,206,192V40A14,14,0,0,0,192,26ZM162,212.34l-46.52-33.22a6,6,0,0,0-7,0L62,212.34V72a2,2,0,0,1,2-2h96a2,2,0,0,1,2,2Zm32-32-20-14.28V72a14,14,0,0,0-14-14H94V40a2,2,0,0,1,2-2h96a2,2,0,0,1,2,2Z"/></svg>				<span>Bookmarks</span>
    </a>
</li>
					<li>
    <a
                class="block p-2 transition rounded-lg focus:outline-none hover:text-primary-600 dark:hover:text-primary-400 focus:text-primary-600 hover:bg-primary-500/10 focus:bg-primary-500/10 dark:text-gray-300 focus:ring-2 focus:ring-primary-500 focus:ring-inset flex items-center space-x-1" href="https://camlovin.com/random" wire:navigate=""
    >
        <svg class="w-5 h-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M236.24,179.76a6,6,0,0,1,0,8.48l-24,24a6,6,0,0,1-8.48-8.48L217.52,190H200.94a70.16,70.16,0,0,1-57-29.31l-41.71-58.4A58.11,58.11,0,0,0,55.06,78H32a6,6,0,0,1,0-12H55.06a70.16,70.16,0,0,1,57,29.31l41.71,58.4A58.11,58.11,0,0,0,200.94,178h16.58l-13.76-13.76a6,6,0,0,1,8.48-8.48Zm-92.06-74.41a5.91,5.91,0,0,0,3.48,1.12,6,6,0,0,0,4.89-2.51l1.19-1.67A58.11,58.11,0,0,1,200.94,78h16.58L203.76,91.76a6,6,0,1,0,8.48,8.48l24-24a6,6,0,0,0,0-8.48l-24-24a6,6,0,0,0-8.48,8.48L217.52,66H200.94a70.16,70.16,0,0,0-57,29.31L142.78,97A6,6,0,0,0,144.18,105.35Zm-32.36,45.3a6,6,0,0,0-8.37,1.39l-1.19,1.67A58.11,58.11,0,0,1,55.06,178H32a6,6,0,0,0,0,12H55.06a70.16,70.16,0,0,0,57-29.31l1.19-1.67A6,6,0,0,0,111.82,150.65Z"/></svg>				<span>Random</span>
    </a>
</li>
					<li>
    <a
                class="block p-2 transition rounded-lg focus:outline-none hover:text-primary-600 dark:hover:text-primary-400 focus:text-primary-600 hover:bg-primary-500/10 focus:bg-primary-500/10 dark:text-gray-300 focus:ring-2 focus:ring-primary-500 focus:ring-inset flex items-center space-x-1" href="https://camlovin.com/insights" wire:navigate=""
    >
        <svg class="w-5 h-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M225.9,74.78,181.21,30.09a14,14,0,0,0-19.8,0L38.1,153.41a13.94,13.94,0,0,0-4.1,9.9V208a14,14,0,0,0,14,14H92.69a13.94,13.94,0,0,0,9.9-4.1L225.9,94.58a14,14,0,0,0,0-19.8ZM48.49,160,136,72.48,155.51,92,68,179.51ZM46,208V174.48L81.51,210H48A2,2,0,0,1,46,208Zm50-.49L76.49,188,164,100.48,183.51,120ZM217.41,86.1,192,111.51,144.49,64,169.9,38.58a2,2,0,0,1,2.83,0l44.68,44.69a2,2,0,0,1,0,2.83Z"/></svg>				<span>Insights</span>
    </a>
</li>
		<!--[if ENDBLOCK]><![endif]-->
                </ul>
            </div>
        </div>
    </nav>
		<div class="flex-grow">
			<div class="">
		<div class="mx-auto h-full w-full px-4 md:px-6 lg:px-8 py-12 pb-24 max-w-full">
			<div class="lg:flex lg:items-center lg:justify-between pb-8">
	<div class="min-w-0 flex-1">
					<nav class="flex" aria-label="Breadcrumb">
				<nav class="fi-breadcrumbs">
	<ol class="fi-breadcrumbs-list flex flex-wrap items-center gap-x-2">
					<li class="fi-breadcrumbs-item flex gap-x-2">
				
				<a
						href="https://camlovin.com"
						wire:navigate
						class="fi-breadcrumbs-item-label text-sm font-medium text-gray-500 transition duration-75 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200"
				>
					Live Sex Cams
				</a>
			</li>
			</ol>
</nav>
			</nav>
		
				<h1 class="mt-2 text-2xl font-bold leading-7 text-gray-900 dark:text-gray-100 sm:truncate sm:text-3xl sm:tracking-tight">
			All Live Sex Cams
		</h1>

					<div class="pt-2 flex flex-col sm:mt-0 sm:flex-row sm:flex-wrap sm:space-x-6">
				<p class="prose dark:prose-invert">CamLovin is the #1 free sex cam site in 2025 and beyond. Enjoy cams and sex chat from all providers in one place. Filter by age, language, and much more.</p>
			</div>
			</div>

	</div>

	<div x-data class="py-10">
	<div x-data="BladeInstantSearch($el, JSON.parse('{\u0022host\u0022:\u0022https:\\\/\\\/camlovin.com\\\/_meili\u0022,\u0022publicKey\u0022:\u00228ff31c09cede3cc50c97b7525bb222eb895178ea88d8ad6c1dab356b948a0d94\u0022,\u0022indexName\u0022:\u0022production_cams\u0022}'))">
	<div x-data="BladeInstantSearch.widget($el, 'Configure', JSON.parse('{\u0022searchParameters\u0022:{\u0022hitsPerPage\u0022:36,\u0022distinct\u0022:true}}'), {})">
	
</div>

		<div
    x-data="{ open: false }"
            x-on:close-slide-over.window="if ($event.detail.id === 'mobile-filters') open = false"
        x-on:open-slide-over.window="if ($event.detail.id === 'mobile-filters') open = true"
                aria-labelledby="mobile-filters.heading"
        role="dialog"
    aria-modal="true"
    class="inline-block"
>
    

    <div
        x-show="open"
        x-transition:enter="transition ease duration-300"
        x-transition:enter-start="opacity-0"
        x-transition:enter-end="opacity-100"
        x-transition:leave="transition ease duration-300"
        x-transition:leave-start="opacity-100"
        x-transition:leave-end="opacity-0"
        x-cloak
        class="fixed inset-0 z-40 flex items-center h-screen"
    >
        <button
            x-on:click="open = false"
            type="button"
            aria-hidden="true"
            class="fixed inset-0 w-full h-full bg-black/50 focus:outline-none"
        ></button>

        <div
            x-show="open"
            x-transition:enter="transition ease duration-300"
            x-transition:enter-start="translate-x-full"
            x-transition:enter-end="translate-x-0"
            x-transition:leave="transition ease duration-300"
            x-transition:leave-start="translate-x-0"
            x-transition:leave-end="translate-x-full"
            x-cloak
            class="relative flex flex-col w-full h-screen ml-auto bg-white dark:bg-gray-900 max-w-sm"
        >
            <div class="flex items-center justify-between flex-shrink-0 px-4 border-b h-14 dark:border-b-gray-700">
                                    <p id="mobile-filters.heading" class="font-semibold tracking-tight">Filters</p>
                
                <button
                    x-on:click="open = false"
                    type="button"
                    class="flex items-center justify-center w-10 h-10 -mr-2 text-gray-500 transition rounded-full focus:text-primary-500 hover:bg-gray-500/5 focus:bg-primary-500/10 focus:outline-none"
                >
                    <span class="sr-only">
    Close panel
</span>
                                            <svg class="w-7 h-7" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24">
                            <path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M17.25 6.75L6.75 17.25"/>
                            <path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" d="M6.75 6.75L17.25 17.25"/>
                        </svg>
                                    </button>
            </div>

            <div class="flex-1 p-6 space-y-6 overflow-y-auto">
                <div>
	<ul role="list" class="space-y-2">

		<li class="pb-3">
			<div x-data="BladeInstantSearch.widget($el, 'ToggleRefinement', JSON.parse('{\u0022attribute\u0022:\u0022Online\u0022,\u0022label\u0022:\u0022Only online\u0022}'), { value: {}, canRefine: false, refine: null, sendEvent: null, createURL: null, widgetParams: {} })">
	<div
			x-data="{
				on: false,
				get isOn() { return value.isRefined },
				toggle() { this.on = ! this.on; refine(value); }
			}"
			class="flex items-center justify-between"
			x-id="['online-toggle']"
			x-cloak=""
	>
		<input type="hidden" name="online-toggle" :value="isOn">

		<label
				@click="$refs.toggle.click(); $refs.toggle.focus()"
				:id="$id('online-toggle')"
				class="text-base font-medium text-gray-700 dark:text-gray-200"
		>
			Only online
		</label>

		<button
				x-ref="toggle"
				@click.prevent="toggle()"
				type="button"
				role="switch"
				:class="isOn ? 'bg-primary-500 dark:bg-primary-400' : 'bg-gray-200 dark:bg-gray-700'"
				class="relative ml-4 inline-flex flex-shrink-0 h-6 w-11 border-2 border-transparent disabled:cursor-not-allowed disabled:opacity-50 focus:outline-none rounded-full focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900"
		>
			<span
					:class="isOn ? 'translate-x-5 rtl:-translate-x-5' : 'translate-x-0 rtl:-translate-x-0'"
					class="pointer-events-none relative inline-block h-5 w-5 rounded-full bg-white dark:bg-gray-900 shadow transform ring-0 transition ease-in-out duration-200"
					aria-hidden="true"
			></span>
		</button>
	</div>
</div>


























		</li>

		<li>
			<div x-data="{ open: true }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Site
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Site\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'7qdHY44dHm9YBQXp' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'7qdHY44dHm9YBQXp' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Gender
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Gender\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'aeGBbGnHNmDL7C2s' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'aeGBbGnHNmDL7C2s' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Age
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'Range', JSON.parse('{\u0022attribute\u0022:\u0022Age\u0022}'), { start: [], range: {}, canRefine: false, refine: null, sendEvent: null, widgetParams: {} })">
	<template x-if="config.legend">
		<legend x-text="config.legend" class="block text-sm font-medium text-gray-900"></legend>
	</template>

	<div x-data="{
		values: function () {
			const [minValue, maxValue] = this.start;
		  	const { min: minRange, max: maxRange } = this.range;
		  	return {
				min: minValue !== -Infinity && minValue !== minRange ? minValue : undefined,
				max: maxValue !== Infinity && maxValue !== maxRange ? maxValue : undefined
		  	};
		},
		init() {
			this.$watch('start', (newValue) => {
				this.setSliderValues(newValue[0], newValue[1]);
			});
		},
		setSliderValues(minValue, maxValue) {
			const event = new CustomEvent('range-set', {
				detail: {
					sliderId: 'range-slider',
					minValue: (minValue === undefined || minValue === -Infinity) ? 18 : minValue,
            		maxValue: (maxValue === undefined || maxValue === Infinity) ? 99 : maxValue
				}
			});
			document.dispatchEvent(event);
		},
		handleProcessChange(event) {
			refine([event.detail.minRangeValue, event.detail.maxRangeValue]);
		}
	}"
		 class="font-semibold text-gray-700 dark:text-gray-100 mx-1"
	>
        <range-selector
                id="range-slider"
                :min-range="18"
                :max-range="99"
                :preset-min="values()['min']"
                :preset-max="values()['max']"
                event-name-to-emit-on-change="process-change"
                slider-color="#e2e8f0"
                label-font-weight="inherit"
                label-font-size="16px"
                number-of-legend-items-to-show="0"
                label-before=""
                label-after=""
                :hide-label="false"
                :hide-legend="true"
                circle-size="18px"
                circle-color="#0ea5e9"
                circle-border="0px"
                circle-focus-border="0px"
                @process-change="handleProcessChange($event)"
        />
	</div>
</div>
				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Ethnicity
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Ethnicity\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'RDrBouKwKOfJDKNN' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'RDrBouKwKOfJDKNN' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Languages
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Languages\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:8,\u0022showMore\u0022:true,\u0022showMoreLimit\u0022:20,\u0022searchable\u0022:true,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
					<div class="relative mt-2 mb-4">
				<input
						name="q"
						type="text"
						placeholder="Search…"
						class="relative block w-full disabled:cursor-not-allowed disabled:opacity-75 focus:outline-none border-0 form-input rounded-md placeholder-gray-400 dark:placeholder-gray-500 text-xs px-2.5 py-1.5 shadow-sm bg-white dark:bg-gray-900 text-gray-900 dark:text-white ring-1 ring-inset ring-gray-300 dark:ring-gray-700 focus:ring-2 focus:ring-primary-500 dark:focus:ring-primary-400 pe-8"
						autocomplete="off"
						x-model="q"
						@input="searchForItems($event.currentTarget.value)"
				>

				<template x-if="isFromSearch">
					<span class="absolute inset-y-0 end-0 flex items-center px-2.5">
						<button
								type="button"
								class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-sm gap-x-1.5 text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-200 underline-offset-4 hover:underline focus-visible:ring-inset focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center"
								x-cloak=""
								@click="q = ''; searchForItems('')"
						>
							<svg class="flex-shrink-0 h-3 w-3" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M208.49,191.51a12,12,0,0,1-17,17L128,145,64.49,208.49a12,12,0,0,1-17-17L111,128,47.51,64.49a12,12,0,0,1,17-17L128,111l63.51-63.52a12,12,0,0,1,17,17L145,128Z"/></svg>						</button>
					</span>
				</template>
			</div>
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'1X3oclO9ZJPQhyNr' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'1X3oclO9ZJPQhyNr' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

					<template x-if="canToggleShowMore">
				<div>
					<a class="transition focus:outline-none focus:underline text-primary-600 hover:text-primary-500 font-medium" size="sm" x-text="isShowingMore ? 'show less' : 'show more'" @click.prevent="toggleShowMore()" href="">
        
    </a>
				</div>
			</template>
			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Tags
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Tags\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022showMore\u0022:true,\u0022showMoreLimit\u0022:35,\u0022searchable\u0022:true,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
					<div class="relative mt-2 mb-4">
				<input
						name="q"
						type="text"
						placeholder="Search…"
						class="relative block w-full disabled:cursor-not-allowed disabled:opacity-75 focus:outline-none border-0 form-input rounded-md placeholder-gray-400 dark:placeholder-gray-500 text-xs px-2.5 py-1.5 shadow-sm bg-white dark:bg-gray-900 text-gray-900 dark:text-white ring-1 ring-inset ring-gray-300 dark:ring-gray-700 focus:ring-2 focus:ring-primary-500 dark:focus:ring-primary-400 pe-8"
						autocomplete="off"
						x-model="q"
						@input="searchForItems($event.currentTarget.value)"
				>

				<template x-if="isFromSearch">
					<span class="absolute inset-y-0 end-0 flex items-center px-2.5">
						<button
								type="button"
								class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-sm gap-x-1.5 text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-200 underline-offset-4 hover:underline focus-visible:ring-inset focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center"
								x-cloak=""
								@click="q = ''; searchForItems('')"
						>
							<svg class="flex-shrink-0 h-3 w-3" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M208.49,191.51a12,12,0,0,1-17,17L128,145,64.49,208.49a12,12,0,0,1-17-17L111,128,47.51,64.49a12,12,0,0,1,17-17L128,111l63.51-63.52a12,12,0,0,1,17,17L145,128Z"/></svg>						</button>
					</span>
				</template>
			</div>
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'6oK3DkPwAlTGriwh' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'6oK3DkPwAlTGriwh' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

					<template x-if="canToggleShowMore">
				<div>
					<a class="transition focus:outline-none focus:underline text-primary-600 hover:text-primary-500 font-medium" size="sm" x-text="isShowingMore ? 'show less' : 'show more'" @click.prevent="toggleShowMore()" href="">
        
    </a>
				</div>
			</template>
			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Body
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Body\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'leKX00HKTt4tW3dd' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'leKX00HKTt4tW3dd' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Breast
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Breast\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'0zNXNZSrrfCFql8w' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'0zNXNZSrrfCFql8w' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Hair
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Hair\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'BR5lL8ZvukaM5Ml9' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'BR5lL8ZvukaM5Ml9' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

	</ul>
</div>
            </div>
        </div>
    </div>
</div>

		<div class="flex flex-col items-center sm:flex-row space-y-4 sm:space-y-0 justify-between border-b border-gray-200 dark:border-gray-700 pb-6">
			<div class="w-full flex-grow col-span-full">
				<div x-data="BladeInstantSearch.widget($el, 'SearchBox', JSON.parse('{\u0022searchAsYouType\u0022:true,\u0022showIcon\u0022:true,\u0022showReset\u0022:true,\u0022submitTitle\u0022:\u0022Search\\u2026\u0022,\u0022showLoadingIndicator\u0022:true}'), { query: '', refine: null, clear: null, isSearchStalled: false, widgetParams: {} })">

	<div
        class="fi-input-wrp flex rounded-lg shadow-sm ring-1 transition duration-75 bg-white dark:bg-white/5 [&amp;:not(:has(.fi-ac-action:focus))]:focus-within:ring-2 ring-gray-950/10 dark:ring-white/20 [&amp;:not(:has(.fi-ac-action:focus))]:focus-within:ring-primary-600 dark:[&amp;:not(:has(.fi-ac-action:focus))]:focus-within:ring-primary-500"
>
            <div
                        class="fi-input-wrp-prefix items-center gap-x-3 ps-3 flex pe-2"
        >
            
                            <svg style=";" class="fi-input-wrp-icon h-5 w-5 text-gray-400 dark:text-gray-500" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M229.66,218.34l-50.07-50.06a88.11,88.11,0,1,0-11.31,11.31l50.06,50.07a8,8,0,0,0,11.32-11.32ZM40,112a72,72,0,1,1,72,72A72.08,72.08,0,0,1,40,112Z"/></svg>            
            
                    </div>
    
    <div
                class="fi-input-wrp-input min-w-0 flex-1"
    >
        <input
    class="fi-input block w-full border-none py-1.5 text-base text-gray-950 transition duration-75 placeholder:text-gray-400 focus:ring-0 disabled:text-gray-500 disabled:[-webkit-text-fill-color:theme(colors.gray.500)] disabled:placeholder:[-webkit-text-fill-color:theme(colors.gray.400)] dark:text-white dark:placeholder:text-gray-500 dark:disabled:text-gray-400 dark:disabled:[-webkit-text-fill-color:theme(colors.gray.400)] dark:disabled:placeholder:[-webkit-text-fill-color:theme(colors.gray.500)] sm:text-sm sm:leading-6 bg-white/0 ps-3 pe-3" type="search" name="search" x-model="query" x-on:input="config.searchAsYouType ? refine(query) : null" x-on:keyoup.enter="refine(query)" placeholder="Search…"
/>
    </div>

    </div>
</div>
			</div>

			<div class="flex w-full justify-between sm:justify-end items-center space-x-2">
				<div x-data="BladeInstantSearch.widget($el, 'SortBy', JSON.parse('{\u0022items\u0022:[{\u0022label\u0022:\u0022Default\u0022,\u0022value\u0022:\u0022production_cams\u0022},{\u0022label\u0022:\u0022Rating\u0022,\u0022value\u0022:\u0022production_cams:Rank:asc\u0022},{\u0022label\u0022:\u0022Newest\u0022,\u0022value\u0022:\u0022production_cams:created_at:desc\u0022},{\u0022label\u0022:\u0022Oldest\u0022,\u0022value\u0022:\u0022production_cams:created_at:asc\u0022}]}'), { options: [], currentRefinement: '', hasNoResults: false, refine: null, widgetParams: {} })">
	<div
        class="fi-input-wrp flex rounded-lg shadow-sm ring-1 transition duration-75 bg-white dark:bg-white/5 [&amp;:not(:has(.fi-ac-action:focus))]:focus-within:ring-2 ring-gray-950/10 dark:ring-white/20 [&amp;:not(:has(.fi-ac-action:focus))]:focus-within:ring-primary-600 dark:[&amp;:not(:has(.fi-ac-action:focus))]:focus-within:ring-primary-500" x-cloak=""
>
    
    <div
                class="fi-input-wrp-input min-w-0 flex-1"
    >
        <select
    class="fi-select-input block w-full border-none bg-transparent py-1.5 pe-8 text-base text-gray-950 transition duration-75 focus:ring-0 disabled:text-gray-500 disabled:[-webkit-text-fill-color:theme(colors.gray.500)] dark:text-white dark:disabled:text-gray-400 dark:disabled:[-webkit-text-fill-color:theme(colors.gray.400)] sm:text-sm sm:leading-6 [&amp;_optgroup]:bg-white [&amp;_optgroup]:dark:bg-gray-900 [&amp;_option]:bg-white [&amp;_option]:dark:bg-gray-900 ps-3" @change="refine($event.currentTarget.value)"
>
    <template x-for="item in options" :key="item.value">
				<option
						x-bind:value="item.value"
						x-text="item.label"
						:selected="item.value === currentRefinement"
				></option>
			</template>
</select>
    </div>

    </div>
</div>

				<div class="flex items-center">
					<button
                                style="--c-300:var(--gray-300);--c-400:var(--gray-400);--c-500:var(--gray-500);--c-600:var(--gray-600);" class="fi-icon-btn relative flex items-center justify-center rounded-lg outline-none transition duration-75 focus-visible:ring-2 -m-2.5 h-11 w-11 text-gray-400 hover:text-gray-500 focus-visible:ring-primary-600 dark:text-gray-500 dark:hover:text-gray-400 dark:focus-visible:ring-primary-500 fi-color-gray block md:hidden" type="button" wire:loading.attr="disabled" x-on:click.prevent="$dispatch('open-slide-over', {id: 'mobile-filters'})"
    >
        
        <svg class="fi-icon-btn-icon h-6 w-6" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M227.81,66.76l-.08.09L160,139.17v55.49A16,16,0,0,1,152.87,208l-32,21.34A16,16,0,0,1,96,216V139.17L28.27,66.85l-.08-.09A16,16,0,0,1,40,40H216a16,16,0,0,1,11.84,26.76Z"/></svg>
        
            </button>
				</div>
			</div>
		</div>

		<div class="bg-gray-100 dark:bg-gray-900">
			<div class="px-2 py-3 sm:flex sm:items-center sm:px-4 lg:px-6">

				<h3 class="text-sm font-medium text-gray-500 dark:text-gray-400">
					Filters
					<span class="sr-only">, active</span>
				</h3>

				<div aria-hidden="true" class="hidden h-5 w-px bg-gray-300 dark:bg-gray-600 sm:ml-4 sm:block"></div>

				<div class="flex flex-col md:flex-row items-center justify-between w-full gap-x-4 ">
					<div class="mt-2 sm:ml-4 sm:mt-0">
						<div class="-m-1 flex flex-wrap items-center h-10">
							<div x-data="BladeInstantSearch.widget($el, 'CurrentRefinements', JSON.parse('{\u0022includedAttributes\u0022:[\u0022query\u0022,\u0022Site\u0022,\u0022Gender\u0022,\u0022Ethnicity\u0022,\u0022Languages\u0022,\u0022Tags\u0022,\u0022Body\u0022,\u0022Breast\u0022,\u0022Hair\u0022,\u0022Online\u0022,\u0022Age\u0022]}'), { items: [], canRefine: false, refine: null, createURL: null, widgetParams: {} })">
	<div x-data="{
            createItemKey({ attribute, value, type, operator }) {
                return [attribute, type, value, operator].join(':');
            }
        }"
		 class="space-x-1 space-y-1"
	>
		<template x-for="(item, index) in items" :key="`${item.indexName}-${item.attribute}-${index}`">
			<span class="inline-flex items-baseline font-medium rounded-full text-xs px-2 py-1 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400">
				<span x-text="item.label + ':'" class="font-bold"></span>
				<template x-for="refinement in item.refinements" :key="createItemKey(refinement)">
					<span class="ml-2">
						<span x-text="refinement.label"></span>
						<button @click="item.refine(refinement)" type="button" class="flex-shrink-0 h-4 w-4 rounded-full inline-flex items-center justify-center text-primary-400 hover:bg-primary-200 hover:text-primary-500 focus:outline-none focus:bg-primary-500 focus:text-white">
							<span class="sr-only">Remove filter</span>
							<svg class="h-2 w-2" stroke="currentColor" fill="none" viewBox="0 0 8 8">
								<path stroke-linecap="round" stroke-width="1.5" d="M1 1l6 6m0-6L1 7" />
							</svg>
						</button>
					</span>
				</template>
			</span>
		</template>
	</div>
</div>
						</div>
					</div>
					<div class="mt-8 md:mt-0 flex-shrink-0">
						<div x-data="BladeInstantSearch.widget($el, 'ClearRefinements', JSON.parse('{\u0022includedAttributes\u0022:[\u0022query\u0022,\u0022Site\u0022,\u0022Gender\u0022,\u0022Ethnicity\u0022,\u0022Languages\u0022,\u0022Tags\u0022,\u0022Body\u0022,\u0022Breast\u0022,\u0022Hair\u0022,\u0022Online\u0022,\u0022Age\u0022],\u0022label\u0022:\u0022Clear all\u0022}'), { canRefine: false, refine: null, createURL: null, widgetParams: {} })">
	<button
                        style="--c-400:var(--primary-400);--c-500:var(--primary-500);--c-600:var(--primary-600);" class="fi-btn relative grid-flow-col items-center justify-center font-semibold outline-none transition duration-75 focus-visible:ring-2 rounded-lg fi-color-custom fi-btn-color-primary fi-color-primary fi-size-sm fi-btn-size-sm gap-1 px-2.5 py-1.5 text-sm inline-grid fi-btn-outlined ring-1 text-custom-600 ring-custom-600 hover:bg-custom-400/10 dark:text-custom-400 dark:ring-custom-500" type="button" wire:loading.attr="disabled" x-bind:disabled="!canRefine" x-show="canRefine" @click.prevent="refine" x-cloak=""
>
                        <svg class="fi-btn-icon transition duration-75 h-4 w-4" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M165.66,101.66,139.31,128l26.35,26.34a8,8,0,0,1-11.32,11.32L128,139.31l-26.34,26.35a8,8,0,0,1-11.32-11.32L116.69,128,90.34,101.66a8,8,0,0,1,11.32-11.32L128,116.69l26.34-26.35a8,8,0,0,1,11.32,11.32ZM232,128A104,104,0,1,1,128,24,104.11,104.11,0,0,1,232,128Zm-16,0a88,88,0,1,0-88,88A88.1,88.1,0,0,0,216,128Z"/></svg>        
        
            
    <span
                class="fi-btn-label"
    >
        <span x-text="config.label"></span>
    </span>

    
    
    </button>
</div>
					</div>
				</div>
			</div>
		</div>

		<div class="flex gap-x-6 pb-24 pt-6">
			<aside class="hidden md:block w-56">
				<div>
	<ul role="list" class="space-y-2">

		<li class="pb-3">
			<div x-data="BladeInstantSearch.widget($el, 'ToggleRefinement', JSON.parse('{\u0022attribute\u0022:\u0022Online\u0022,\u0022label\u0022:\u0022Only online\u0022}'), { value: {}, canRefine: false, refine: null, sendEvent: null, createURL: null, widgetParams: {} })">
	<div
			x-data="{
				on: false,
				get isOn() { return value.isRefined },
				toggle() { this.on = ! this.on; refine(value); }
			}"
			class="flex items-center justify-between"
			x-id="['online-toggle']"
			x-cloak=""
	>
		<input type="hidden" name="online-toggle" :value="isOn">

		<label
				@click="$refs.toggle.click(); $refs.toggle.focus()"
				:id="$id('online-toggle')"
				class="text-base font-medium text-gray-700 dark:text-gray-200"
		>
			Only online
		</label>

		<button
				x-ref="toggle"
				@click.prevent="toggle()"
				type="button"
				role="switch"
				:class="isOn ? 'bg-primary-500 dark:bg-primary-400' : 'bg-gray-200 dark:bg-gray-700'"
				class="relative ml-4 inline-flex flex-shrink-0 h-6 w-11 border-2 border-transparent disabled:cursor-not-allowed disabled:opacity-50 focus:outline-none rounded-full focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900"
		>
			<span
					:class="isOn ? 'translate-x-5 rtl:-translate-x-5' : 'translate-x-0 rtl:-translate-x-0'"
					class="pointer-events-none relative inline-block h-5 w-5 rounded-full bg-white dark:bg-gray-900 shadow transform ring-0 transition ease-in-out duration-200"
					aria-hidden="true"
			></span>
		</button>
	</div>
</div>


























		</li>

		<li>
			<div x-data="{ open: true }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Site
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Site\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'72sxtVgoH7eXA50c' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'72sxtVgoH7eXA50c' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Gender
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Gender\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'cCUjDIsan8fYnL6t' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'cCUjDIsan8fYnL6t' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Age
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'Range', JSON.parse('{\u0022attribute\u0022:\u0022Age\u0022}'), { start: [], range: {}, canRefine: false, refine: null, sendEvent: null, widgetParams: {} })">
	<template x-if="config.legend">
		<legend x-text="config.legend" class="block text-sm font-medium text-gray-900"></legend>
	</template>

	<div x-data="{
		values: function () {
			const [minValue, maxValue] = this.start;
		  	const { min: minRange, max: maxRange } = this.range;
		  	return {
				min: minValue !== -Infinity && minValue !== minRange ? minValue : undefined,
				max: maxValue !== Infinity && maxValue !== maxRange ? maxValue : undefined
		  	};
		},
		init() {
			this.$watch('start', (newValue) => {
				this.setSliderValues(newValue[0], newValue[1]);
			});
		},
		setSliderValues(minValue, maxValue) {
			const event = new CustomEvent('range-set', {
				detail: {
					sliderId: 'range-slider',
					minValue: (minValue === undefined || minValue === -Infinity) ? 18 : minValue,
            		maxValue: (maxValue === undefined || maxValue === Infinity) ? 99 : maxValue
				}
			});
			document.dispatchEvent(event);
		},
		handleProcessChange(event) {
			refine([event.detail.minRangeValue, event.detail.maxRangeValue]);
		}
	}"
		 class="font-semibold text-gray-700 dark:text-gray-100 mx-1"
	>
        <range-selector
                id="range-slider"
                :min-range="18"
                :max-range="99"
                :preset-min="values()['min']"
                :preset-max="values()['max']"
                event-name-to-emit-on-change="process-change"
                slider-color="#e2e8f0"
                label-font-weight="inherit"
                label-font-size="16px"
                number-of-legend-items-to-show="0"
                label-before=""
                label-after=""
                :hide-label="false"
                :hide-legend="true"
                circle-size="18px"
                circle-color="#0ea5e9"
                circle-border="0px"
                circle-focus-border="0px"
                @process-change="handleProcessChange($event)"
        />
	</div>
</div>
				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Ethnicity
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Ethnicity\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'XNgxETE2dgv78t2H' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'XNgxETE2dgv78t2H' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Languages
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Languages\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:8,\u0022showMore\u0022:true,\u0022showMoreLimit\u0022:20,\u0022searchable\u0022:true,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
					<div class="relative mt-2 mb-4">
				<input
						name="q"
						type="text"
						placeholder="Search…"
						class="relative block w-full disabled:cursor-not-allowed disabled:opacity-75 focus:outline-none border-0 form-input rounded-md placeholder-gray-400 dark:placeholder-gray-500 text-xs px-2.5 py-1.5 shadow-sm bg-white dark:bg-gray-900 text-gray-900 dark:text-white ring-1 ring-inset ring-gray-300 dark:ring-gray-700 focus:ring-2 focus:ring-primary-500 dark:focus:ring-primary-400 pe-8"
						autocomplete="off"
						x-model="q"
						@input="searchForItems($event.currentTarget.value)"
				>

				<template x-if="isFromSearch">
					<span class="absolute inset-y-0 end-0 flex items-center px-2.5">
						<button
								type="button"
								class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-sm gap-x-1.5 text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-200 underline-offset-4 hover:underline focus-visible:ring-inset focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center"
								x-cloak=""
								@click="q = ''; searchForItems('')"
						>
							<svg class="flex-shrink-0 h-3 w-3" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M208.49,191.51a12,12,0,0,1-17,17L128,145,64.49,208.49a12,12,0,0,1-17-17L111,128,47.51,64.49a12,12,0,0,1,17-17L128,111l63.51-63.52a12,12,0,0,1,17,17L145,128Z"/></svg>						</button>
					</span>
				</template>
			</div>
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'WQtDAdltW5OTqRVU' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'WQtDAdltW5OTqRVU' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

					<template x-if="canToggleShowMore">
				<div>
					<a class="transition focus:outline-none focus:underline text-primary-600 hover:text-primary-500 font-medium" size="sm" x-text="isShowingMore ? 'show less' : 'show more'" @click.prevent="toggleShowMore()" href="">
        
    </a>
				</div>
			</template>
			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Tags
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Tags\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022showMore\u0022:true,\u0022showMoreLimit\u0022:35,\u0022searchable\u0022:true,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
					<div class="relative mt-2 mb-4">
				<input
						name="q"
						type="text"
						placeholder="Search…"
						class="relative block w-full disabled:cursor-not-allowed disabled:opacity-75 focus:outline-none border-0 form-input rounded-md placeholder-gray-400 dark:placeholder-gray-500 text-xs px-2.5 py-1.5 shadow-sm bg-white dark:bg-gray-900 text-gray-900 dark:text-white ring-1 ring-inset ring-gray-300 dark:ring-gray-700 focus:ring-2 focus:ring-primary-500 dark:focus:ring-primary-400 pe-8"
						autocomplete="off"
						x-model="q"
						@input="searchForItems($event.currentTarget.value)"
				>

				<template x-if="isFromSearch">
					<span class="absolute inset-y-0 end-0 flex items-center px-2.5">
						<button
								type="button"
								class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-sm gap-x-1.5 text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-200 underline-offset-4 hover:underline focus-visible:ring-inset focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center"
								x-cloak=""
								@click="q = ''; searchForItems('')"
						>
							<svg class="flex-shrink-0 h-3 w-3" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M208.49,191.51a12,12,0,0,1-17,17L128,145,64.49,208.49a12,12,0,0,1-17-17L111,128,47.51,64.49a12,12,0,0,1,17-17L128,111l63.51-63.52a12,12,0,0,1,17,17L145,128Z"/></svg>						</button>
					</span>
				</template>
			</div>
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'1v8vpHuKyGRSnueF' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'1v8vpHuKyGRSnueF' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

					<template x-if="canToggleShowMore">
				<div>
					<a class="transition focus:outline-none focus:underline text-primary-600 hover:text-primary-500 font-medium" size="sm" x-text="isShowingMore ? 'show less' : 'show more'" @click.prevent="toggleShowMore()" href="">
        
    </a>
				</div>
			</template>
			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Body
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Body\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'b8iPWPs05r2QTiqh' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'b8iPWPs05r2QTiqh' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Breast
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Breast\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'Yzy6SvaeO8B82EKw' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'Yzy6SvaeO8B82EKw' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

		<li>
			<div x-data="{ open: false }">
				<button type="button"
						class="focus:outline-none focus-visible:outline-0 disabled:cursor-not-allowed disabled:opacity-75 flex-shrink-0 font-medium rounded-md text-base gap-x-2.5 px-3.5 py-2.5 shadow-sm ring-1 ring-inset ring-gray-300 dark:ring-gray-700 text-gray-700 dark:text-gray-200 bg-gray-100 hover:bg-gray-100 disabled:bg-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700/50 dark:disabled:bg-gray-800 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 inline-flex items-center mb-1.5 w-full"
						aria-controls="sub-menu-1" @click="open = !open" aria-expanded="false"
						x-bind:aria-expanded="open.toString()">
					Hair
					<svg class="ml-auto h-5 w-5 shrink-0 text-gray-400"
						 :class="{ 'rotate-90 text-gray-500': open, 'text-gray-400': !(open) }" viewBox="0 0 20 20"
						 fill="currentColor" aria-hidden="true">
						<path fill-rule="evenodd"
							  d="M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z"
							  clip-rule="evenodd"></path>
					</svg>
				</button>
				<div class="mt-6 mb-4 px-2" id="sub-menu-1" x-show="open" x-cloak="">
					<div class="border-b pb-6 dark:border-b-gray-500" x-data="BladeInstantSearch.widget($el, 'RefinementList', JSON.parse('{\u0022attribute\u0022:\u0022Hair\u0022,\u0022operator\u0022:\u0022or\u0022,\u0022limit\u0022:10,\u0022searchablePlaceholder\u0022:\u0022Search\\u2026\u0022,\u0022searchableIsAlwaysActive\u0022:true,\u0022searchableEscapeFacetValues\u0022:true}'), { items: [], canRefine: false, refine: null, sendEvent: null, createURL: null, isFromSearch: false, searchForItems: null, isShowingMore: false, canToggleShowMore: false, toggleShowMore: null, widgetParams: {} })">
	<div class="space-y-3" x-data="{ q: ''}">
		
		<template x-for="item in items" :key="item.value">
			<div class="flex items-center justify-between">
				<div class="relative flex items-start">
					<div class="flex items-center h-5">
						<input
								:id="'yMQY48CRxqYyuIe4' + '_' + item.value"
								:value="item.isRefined"
								@change.prevent="refine(item.value); q = ''; searchForItems('')"
								type="checkbox"
								class="h-4 w-4 dark:checked:bg-current dark:checked:border-transparent dark:indeterminate:bg-current dark:indeterminate:border-transparent disabled:opacity-50 disabled:cursor-not-allowed focus:ring-0 focus:ring-transparent focus:ring-offset-transparent form-checkbox rounded bg-white dark:bg-gray-900 border border-gray-300 dark:border-gray-700 focus-visible:ring-2 focus-visible:ring-primary-500 dark:focus-visible:ring-primary-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:focus-visible:ring-offset-gray-900 text-primary-500 dark:text-primary-400"
						>
					</div>

					<div class="ms-3 flex flex-col">
						<label
								class="text-sm font-medium text-gray-700 dark:text-gray-200"
								:for="'yMQY48CRxqYyuIe4' + '_' + item.value"
								x-text="item.label"
						>
						</label>
					</div>
				</div>
				<span x-text="item.count" class="inline-flex items-center font-medium rounded-md text-xs px-1.5 py-0.5 bg-primary-50 dark:bg-primary-400 dark:bg-opacity-10 text-primary-500 dark:text-primary-400 ring-1 ring-inset ring-primary-500 dark:ring-primary-400 ring-opacity-25 dark:ring-opacity-25"></span>
			</div>
		</template>

			</div>
</div>








































				</div>
			</div>
		</li>

	</ul>
</div>
			</aside>

			<main class="flex-1">
				<div class="grid gap-x-3 gap-y-6 grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 3xl:grid-cols-5 4xl:grid-cols-6" x-data="BladeInstantSearch.widget($el, 'InfiniteHits', JSON.parse('{\u0022showPrevious\u0022:true,\u0022autoLoadMore\u0022:true}'), { hits: [], results: {}, isFirstPage: true, isLastPage: false, sendEvent: null, widgetParams: null })">

			<template x-if="!isFirstPage">
			<div class="col-span-full flex justify-center py-8">
								<button
										type="button"
										:disabled="isFirstPage"
										@click.prevent="showPrevious()"
										class="rounded-md bg-primary-600 px-3 py-2 text-sm font-semibold text-white shadow-sm hover:bg-primary-500 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-primary-600"
								>
									Show previous
								</button>
							</div>
		</template>
	
	<template x-for="(hit, index) in hits" :key="hit.id + '-' + index">
		<div x-cloak="">
						 
						<div x-data="{
							name: hit.display_name,
							slug: hit.slug,
							site: hit.Site,
							image: hit.Online ? hit.live_image_url : hit.image_url,
							streamUrl: hit.stream_url,
							isOnline: hit.Online
						}">
	<div class="flex flex-col space-y-1">
		<div class="relative"
			 x-data="{
			 	isHovering: false,
			 	isRounded: true,
			 	hoverTimeout: null,
			 	canStream: function () {
			 		if (site === 'amateur.tv' || site === 'ImLive') {
			 			return false;
			 		}

			 		if(! streamUrl) {
			 			return false;
			 		}

			 		return true;
			 	},
			 	mouseEnter: function () {
			 		if (this.canStream()) {
			 			this.isRounded = false;
			 		}
			 		this.hoverTimeout = setTimeout(() => {
			 			this.isHovering = true;
			 		}, 500);
			 	},
			 	mouseLeave: function () {
			 		clearTimeout(this.hoverTimeout);
			 		this.isHovering = false;
			 		this.isRounded = true;
			 	}
			}"
			 x-on:mouseenter="mouseEnter"
			 x-on:mouseleave="mouseLeave"
			 x-on:touchstart="mouseEnter"
			 x-on:touchend="mouseLeave"
		>
			<a :href="isMobile() ? '/cams/go/' + slug : '/cams/' + slug"
			   :target="isMobile() ? '_blank' : ''"
			   :rel="isMobile() ? 'nofollow' : 'follow'"
			   class="cursor-pointer"
			>
				<div class="relative aspect-[3/2] w-full overflow-hidden bg-gray-200 dark:bg-gray-800 transition-all duration-300 group"
					 :class="[isRounded ? 'rounded-xl' : 'rounded-none', canStream() ? '' : 'rounded-xl']"
				>
					<img :src="image + (image.includes('?') ? '&' : '?') + 't=' + Date.now()"
						 class="object-cover object-center w-full h-full"
						 x-show="! isHovering || ! canStream()"
						 loading="lazy"
					>

					<template x-if="isHovering && isOnline && (site === 'BongaCams' || site === 'StripChat')">
						<div
		x-data="{
			isBuffering: false,
			hasError: false,
			hlsRef: null,
			videoElement: $refs.video,
			hasNativeHlsSupport: function () {
				return this.videoElement.canPlayType('application/vnd.apple.mpegURL') === 'probably' ||
            	this.videoElement.canPlayType('application/vnd.apple.mpegURL') === 'maybe';
			},
			startStreaming: function () {
				if(isHovering && streamUrl && this.videoElement) {
					this.isBuffering = true;

					if(this.hasNativeHlsSupport()) {
						console.log('native-hls-support');
						this.videoElement.src = streamUrl;
					    this.videoElement.addEventListener('canplay', () => {
							this.isBuffering = false;
					    });

					    this.videoElement.addEventListener('error', () => {
							this.hasError = true;
							this.isBuffering = false;
					  	});
					} else {
						console.log('no-native-hls-support');
						this.hlsRef = new Hls({ debug: true });
						this.hlsRef.loadSource(streamUrl);
						this.hlsRef.attachMedia(this.videoElement);
						this.hlsRef.on(Hls.Events.BUFFER_APPENDED, () => this.isBuffering = false);
						this.hlsRef.on(Hls.Events.MEDIA_ATTACHED, () => {
					    	this.videoElement.autoplay = true;
					    	this.videoElement.muted = true;
					    	this.videoElement.play();
					    });
						this.hlsRef.on(Hls.Events.ERROR, (event, data) => {
							if(data.fatal) {
								this.hasError = true;
								this.isBuffering = false;
							}
						});
					}
				}
			},
			stopStreaming: function () {
				if(this.hlsRef) {
					this.hlsRef.destroy();
					this.hlsRef = null;
				}

				if(this.videoElement && this.hasNativeHlsSupport()) {
					this.videoElement.removeAttribute('src');
					this.videoElement.load();
				}

				this.isBuffering = false;

				if(! isHovering) {
					this.hasError = false;
				}
			}
		}"
		x-init="
			$watch('isHovering', (value) => {
				if(! value) {
					stopStreaming();
				}
			});

			startStreaming();
		"
>
	<div class="relative">

		<video
				x-show="isHovering"
				x-ref="video"
				class="aspect-[3/2] h-full w-full object-cover object-center"
				autoplay
				muted
				playsinline
				:poster="image"
		></video>

		<template x-if="isBuffering" >
	<div class="absolute inset-0 flex justify-center items-center">
		<svg class="animate-spin h-8 w-8 text-white" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24">
			<circle class="opacity-25" cx="12" cy="12" r="10" stroke="currentColor" stroke-width="4"></circle>
			<path class="opacity-100" fill="currentColor" d="M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"></path>
		</svg>
	</div>
</template>

<template x-if="hasError">
	<div class="absolute inset-0 flex justify-center items-center">
		<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor" class="text-white w-8 h-8">
			<path fill-rule="evenodd" d="M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003ZM12 8.25a.75.75 0 0 1 .75.75v3.75a.75.75 0 0 1-1.5 0V9a.75.75 0 0 1 .75-.75Zm0 8.25a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Z" clip-rule="evenodd" />
		</svg>
	</div>
</template>

	</div>
</div>

					</template>

					<template x-if="isHovering && isOnline && site === 'Chaturbate'">
						<div
		x-data="{
			timestamp: (Date.now() - 30000),
			isBuffering: false,
			hasError: false,
			isStreaming: false,
			imageUpdateInterval: null,
			imageUrl: function() {
				return image.replace('ri', 'minifap') + '?t=' + this.timestamp;
			},
			toBase64: async function(url) {
				const response = await fetch(url);
				const blob = await response.blob();
				return new Promise((resolve, reject) => {
					const reader = new FileReader();
					reader.onloadend = () => resolve(reader.result);
					reader.onerror = reject;
					reader.readAsDataURL(blob);
				});
			},
			compareImages: async function() {
				this.hasError = false;
				this.isBuffering = true;

				const firstImageBase64 = await this.toBase64(this.imageUrl());

				// Delay to simulate processing and give time to cancel if hover ends
				// await new Promise(resolve => setTimeout(resolve, 1000));

				this.timestamp = Date.now();
				const secondImageBase64 = await this.toBase64(this.imageUrl());

				return firstImageBase64 === secondImageBase64;
			},
			startUpdatingImage: function() {
				this.imageUpdateInterval = setInterval(() => {
					this.timestamp = Date.now();
				}, 700);
			},
			stopUpdatingImage: function() {
				clearInterval(this.imageUpdateInterval);
				this.imageUpdateInterval = null;
			}
    	}"

		x-init="
			$watch('isHovering', (value) => {
				if (!value) {
					stopUpdatingImage();
				}
			});

			compareImages().then(imagesAreTheSame => {
				if (imagesAreTheSame) {
					isBuffering = false;
					hasError = true;
				} else {
					isBuffering = false;
					isStreaming = true;
					startUpdatingImage();
				}
			});"
>
	<div class="relative">
		<img x-bind:src="isStreaming ? imageUrl() : image"
			 class="aspect-[3/2] object-cover object-center w-full h-full"
		>
		<template x-if="isBuffering" >
	<div class="absolute inset-0 flex justify-center items-center">
		<svg class="animate-spin h-8 w-8 text-white" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24">
			<circle class="opacity-25" cx="12" cy="12" r="10" stroke="currentColor" stroke-width="4"></circle>
			<path class="opacity-100" fill="currentColor" d="M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"></path>
		</svg>
	</div>
</template>

<template x-if="hasError">
	<div class="absolute inset-0 flex justify-center items-center">
		<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor" class="text-white w-8 h-8">
			<path fill-rule="evenodd" d="M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003ZM12 8.25a.75.75 0 0 1 .75.75v3.75a.75.75 0 0 1-1.5 0V9a.75.75 0 0 1 .75-.75Zm0 8.25a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Z" clip-rule="evenodd" />
		</svg>
	</div>
</template>
	</div>
</div>
					</template>

					<template x-if="isHovering && isOnline && site === 'Cherry TV'">
						<div
		x-data="{ isBuffering: false }"
		x-init="
			const iframeElement = $refs.iframe;

			$watch('isHovering', (value) => {
				if(! value) {
					iframeElement.src = '';
    				isBuffering = false;
				}
			});

			isBuffering = true;
			iframeElement.src = streamUrl;

			iframeElement.addEventListener('load', () => {
				setTimeout(() => {
                	isBuffering = false;
            	}, 800);
			});
		"
		class="relative"
>
	<img
			:src="image"
		 	class="aspect-[3/2] w-full h-full object-cover object-center"
		 	x-show="isBuffering"
	>

	<iframe
			x-show="! isBuffering"
			x-ref="iframe"
			class="aspect-[3/2] w-full"
	></iframe>

	<a :href="'/cams/'+ slug">
		<span aria-hidden="true" class="absolute inset-0"></span>
	</a>

	<template x-if="isBuffering" >
	<div class="absolute inset-0 flex justify-center items-center">
		<svg class="animate-spin h-8 w-8 text-white" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24">
			<circle class="opacity-25" cx="12" cy="12" r="10" stroke="currentColor" stroke-width="4"></circle>
			<path class="opacity-100" fill="currentColor" d="M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"></path>
		</svg>
	</div>
</template>

<template x-if="hasError">
	<div class="absolute inset-0 flex justify-center items-center">
		<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor" class="text-white w-8 h-8">
			<path fill-rule="evenodd" d="M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003ZM12 8.25a.75.75 0 0 1 .75.75v3.75a.75.75 0 0 1-1.5 0V9a.75.75 0 0 1 .75-.75Zm0 8.25a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Z" clip-rule="evenodd" />
		</svg>
	</div>
</template>
</div>
					</template>

					<template x-if="isHovering && isOnline && site === 'Streamate'">
						<div
		x-data="{ isBuffering: false }"
		x-init="
			const iframeElement = $refs.iframe;

			$watch('isHovering', (value) => {
				if(! value) {
					iframeElement.src = '';
    				isBuffering = false;
				}
			});

			isBuffering = true;
			iframeElement.src = streamUrl + '&widescreen=true&volumeLevel=0&muted=true&color=%23FFFFFF';

			iframeElement.addEventListener('load', () => {
				setTimeout(() => {
                	isBuffering = false;
            	}, 800);
			});
		"
		class="relative"
>
	<img
			:src="image"
		 	class="aspect-[3/2] w-full h-full object-cover object-center"
		 	x-show="isBuffering"
	>

	<iframe
			x-show="! isBuffering"
			x-ref="iframe"
			class="aspect-[3/2] w-full"
	></iframe>

	<a :href="'/cams/'+ slug">
		<span aria-hidden="true" class="absolute inset-0"></span>
	</a>

	<template x-if="isBuffering" >
	<div class="absolute inset-0 flex justify-center items-center">
		<svg class="animate-spin h-8 w-8 text-white" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24">
			<circle class="opacity-25" cx="12" cy="12" r="10" stroke="currentColor" stroke-width="4"></circle>
			<path class="opacity-100" fill="currentColor" d="M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"></path>
		</svg>
	</div>
</template>

<template x-if="hasError">
	<div class="absolute inset-0 flex justify-center items-center">
		<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor" class="text-white w-8 h-8">
			<path fill-rule="evenodd" d="M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003ZM12 8.25a.75.75 0 0 1 .75.75v3.75a.75.75 0 0 1-1.5 0V9a.75.75 0 0 1 .75-.75Zm0 8.25a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Z" clip-rule="evenodd" />
		</svg>
	</div>
</template>
</div>
					</template>

					<template x-if="isHovering && isOnline && streamUrl && (site === 'LiveJasmin' || site === 'CamSoda' || site === 'Visit-X')">
						<div
		x-data="{
			isBuffering: false,
			hasError: false
		}"
		x-init="
			const videoElement = $refs.video;

			$watch('isHovering', (value) => {
				if(! value) {
					videoElement.pause();
					videoElement.removeAttribute('src');
    				videoElement.load();

    				isBuffering = false;
    				hasError = false;
				}
			});

			isBuffering = true;
			videoElement.src = streamUrl;
			videoElement.muted = true;
			videoElement.load();

			videoElement.addEventListener('canpaly', () => {
				isBuffering = false;
			});

			videoElement.addEventListener('playing', () => {
				isBuffering = false;
			});

			videoElement.addEventListener('error', () => {
				hasError = true;
				isBuffering = false;
			});
		"
>
	<video
			autoplay
			muted
			playsinline
			x-ref="video"
			class="aspect-[3/2] h-full w-full object-cover object-center"
			:poster="image"
			x-show="isHovering"
	></video>

	<template x-if="isBuffering" >
	<div class="absolute inset-0 flex justify-center items-center">
		<svg class="animate-spin h-8 w-8 text-white" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24">
			<circle class="opacity-25" cx="12" cy="12" r="10" stroke="currentColor" stroke-width="4"></circle>
			<path class="opacity-100" fill="currentColor" d="M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"></path>
		</svg>
	</div>
</template>

<template x-if="hasError">
	<div class="absolute inset-0 flex justify-center items-center">
		<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor" class="text-white w-8 h-8">
			<path fill-rule="evenodd" d="M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003ZM12 8.25a.75.75 0 0 1 .75.75v3.75a.75.75 0 0 1-1.5 0V9a.75.75 0 0 1 .75-.75Zm0 8.25a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Z" clip-rule="evenodd" />
		</svg>
	</div>
</template>
</div>
					</template>

					<div class="absolute top-0.5 right-0.5 z-10" :class="[canStream() ? 'group-hover:hidden' : '']">
						<span class="block h-3 w-3 rounded-full m-1" :class="isOnline ? 'bg-green-500' : 'bg-red-500'"></span>
					</div>

					<div class="absolute bottom-0 right-0 z-10" :class="[canStream() ? 'group-hover:hidden' : '']">
						<div class="text-[0.80em] leading-4 font-medium bg-black/60 text-white m-1.5 rounded px-1 py-0.5" x-text="site"></div>
					</div>
				</div>
			</a>

					</div>

		<div class="flex items-center justify-between space-x-8 text-base font-medium text-gray-900 dark:text-gray-200">
			<h3>
				<a :href="isMobile() ? '/cams/go/' + slug : '/cams/' + slug"
				   :target="isMobile() ? '_blank' : ''"
				   :rel="isMobile() ? 'nofollow' : 'follow'"
				>
					<span aria-hidden="true" class=""></span>
					<span x-text="name"></span>
				</a>
			</h3>

			
		</div>
	</div>
</div>

						 
						 					</div>
	</template>

	<template x-if="isFirstRender">
					<div class="col-span-full">
								<div class="flex justify-center py-12">
									<div class="flex items-center space-x-1">
										<svg class="animate-spin -ml-1 mr-3 h-8 w-8 text-primary-500"
											 xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24">
											<circle class="opacity-25" cx="12" cy="12" r="10" stroke="currentColor"
													stroke-width="4"></circle>
											<path class="opacity-75" fill="currentColor"
												  d="M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"></path>
										</svg>
										<span class="text-sm text-gray-700 dark:text-gray-100">Loading cams...</span>
									</div>
								</div>
							</div>
			</template>

			<template x-if="!isFirstRender && hits.length > 0 && !isLastPage">
			<div class="col-span-full flex justify-center py-8">
								<button type="button"
										@click.prevent="showMore()"
										class="rounded-md bg-primary-600 px-3 py-2 text-sm font-semibold text-white shadow-sm hover:bg-primary-500 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-primary-600"
								>
									Show more
								</button>
							</div>
		</template>

		<template x-if="isLastPage && !isFirstRender">
			<div class="col-span-full flex justify-center py-8 font-medium dark:text-gray-100">
				End of search results
			</div>
		</template>
	
	<template x-if="config.autoLoadMore">
		<span
				class="w-full h-10 col-span-full"
				x-show="hits.length > 0 && !isFirstRender"
				x-intersect="showMore()"
		></span>
	</template>

</div>

			</main>
		</div>
</div>

	<script>var BladeInstantSearch=function(){var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function t(e){var t={exports:{}};return e(t,t.exports),t.exports}t(function(t){!function(e){!function(t){var r="URLSearchParams"in e,n="Symbol"in e&&"iterator"in Symbol,i="FileReader"in e&&"Blob"in e&&function(){try{return new Blob,!0}catch(e){return!1}}(),a="FormData"in e,o="ArrayBuffer"in e;if(o)var s=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],c=ArrayBuffer.isView||function(e){return e&&s.indexOf(Object.prototype.toString.call(e))>-1};function u(e){if("string"!=typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(e))throw new TypeError("Invalid character in header field name");return e.toLowerCase()}function f(e){return"string"!=typeof e&&(e=String(e)),e}function l(e){var t={next:function(){var t=e.shift();return{done:void 0===t,value:t}}};return n&&(t[Symbol.iterator]=function(){return t}),t}function h(e){this.map={},e instanceof h?e.forEach(function(e,t){this.append(t,e)},this):Array.isArray(e)?e.forEach(function(e){this.append(e[0],e[1])},this):e&&Object.getOwnPropertyNames(e).forEach(function(t){this.append(t,e[t])},this)}function d(e){if(e.bodyUsed)return Promise.reject(new TypeError("Already read"));e.bodyUsed=!0}function p(e){return new Promise(function(t,r){e.onload=function(){t(e.result)},e.onerror=function(){r(e.error)}})}function v(e){var t=new FileReader,r=p(t);return t.readAsArrayBuffer(e),r}function m(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function g(){return this.bodyUsed=!1,this._initBody=function(e){var t;this._bodyInit=e,e?"string"==typeof e?this._bodyText=e:i&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:a&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:r&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():o&&i&&(t=e)&&DataView.prototype.isPrototypeOf(t)?(this._bodyArrayBuffer=m(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):o&&(ArrayBuffer.prototype.isPrototypeOf(e)||c(e))?this._bodyArrayBuffer=m(e):this._bodyText=e=Object.prototype.toString.call(e):this._bodyText="",this.headers.get("content-type")||("string"==typeof e?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):r&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},i&&(this.blob=function(){var e=d(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?d(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(v)}),this.text=function(){var e,t,r,n=d(this);if(n)return n;if(this._bodyBlob)return e=this._bodyBlob,r=p(t=new FileReader),t.readAsText(e),r;if(this._bodyArrayBuffer)return Promise.resolve(function(e){for(var t=new Uint8Array(e),r=new Array(t.length),n=0;n<t.length;n++)r[n]=String.fromCharCode(t[n]);return r.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},a&&(this.formData=function(){return this.text().then(w)}),this.json=function(){return this.text().then(JSON.parse)},this}h.prototype.append=function(e,t){e=u(e),t=f(t);var r=this.map[e];this.map[e]=r?r+", "+t:t},h.prototype.delete=function(e){delete this.map[u(e)]},h.prototype.get=function(e){return e=u(e),this.has(e)?this.map[e]:null},h.prototype.has=function(e){return this.map.hasOwnProperty(u(e))},h.prototype.set=function(e,t){this.map[u(e)]=f(t)},h.prototype.forEach=function(e,t){for(var r in this.map)this.map.hasOwnProperty(r)&&e.call(t,this.map[r],r,this)},h.prototype.keys=function(){var e=[];return this.forEach(function(t,r){e.push(r)}),l(e)},h.prototype.values=function(){var e=[];return this.forEach(function(t){e.push(t)}),l(e)},h.prototype.entries=function(){var e=[];return this.forEach(function(t,r){e.push([r,t])}),l(e)},n&&(h.prototype[Symbol.iterator]=h.prototype.entries);var y=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function b(e,t){var r,n,i=(t=t||{}).body;if(e instanceof b){if(e.bodyUsed)throw new TypeError("Already read");this.url=e.url,this.credentials=e.credentials,t.headers||(this.headers=new h(e.headers)),this.method=e.method,this.mode=e.mode,this.signal=e.signal,i||null==e._bodyInit||(i=e._bodyInit,e.bodyUsed=!0)}else this.url=String(e);if(this.credentials=t.credentials||this.credentials||"same-origin",!t.headers&&this.headers||(this.headers=new h(t.headers)),this.method=(n=(r=t.method||this.method||"GET").toUpperCase(),y.indexOf(n)>-1?n:r),this.mode=t.mode||this.mode||null,this.signal=t.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&i)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(i)}function w(e){var t=new FormData;return e.trim().split("&").forEach(function(e){if(e){var r=e.split("="),n=r.shift().replace(/\+/g," "),i=r.join("=").replace(/\+/g," ");t.append(decodeURIComponent(n),decodeURIComponent(i))}}),t}function S(e,t){t||(t={}),this.type="default",this.status=void 0===t.status?200:t.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in t?t.statusText:"OK",this.headers=new h(t.headers),this.url=t.url||"",this._initBody(e)}b.prototype.clone=function(){return new b(this,{body:this._bodyInit})},g.call(b.prototype),g.call(S.prototype),S.prototype.clone=function(){return new S(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new h(this.headers),url:this.url})},S.error=function(){var e=new S(null,{status:0,statusText:""});return e.type="error",e};var O=[301,302,303,307,308];S.redirect=function(e,t){if(-1===O.indexOf(t))throw new RangeError("Invalid status code");return new S(null,{status:t,headers:{location:e}})},t.DOMException=e.DOMException;try{new t.DOMException}catch(e){t.DOMException=function(e,t){this.message=e,this.name=t;var r=Error(e);this.stack=r.stack},t.DOMException.prototype=Object.create(Error.prototype),t.DOMException.prototype.constructor=t.DOMException}function j(e,r){return new Promise(function(n,a){var o=new b(e,r);if(o.signal&&o.signal.aborted)return a(new t.DOMException("Aborted","AbortError"));var s=new XMLHttpRequest;function c(){s.abort()}s.onload=function(){var e,t,r={status:s.status,statusText:s.statusText,headers:(e=s.getAllResponseHeaders()||"",t=new h,e.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach(function(e){var r=e.split(":"),n=r.shift().trim();if(n){var i=r.join(":").trim();t.append(n,i)}}),t)};r.url="responseURL"in s?s.responseURL:r.headers.get("X-Request-URL"),n(new S("response"in s?s.response:s.responseText,r))},s.onerror=function(){a(new TypeError("Network request failed"))},s.ontimeout=function(){a(new TypeError("Network request failed"))},s.onabort=function(){a(new t.DOMException("Aborted","AbortError"))},s.open(o.method,o.url,!0),"include"===o.credentials?s.withCredentials=!0:"omit"===o.credentials&&(s.withCredentials=!1),"responseType"in s&&i&&(s.responseType="blob"),o.headers.forEach(function(e,t){s.setRequestHeader(t,e)}),o.signal&&(o.signal.addEventListener("abort",c),s.onreadystatechange=function(){4===s.readyState&&o.signal.removeEventListener("abort",c)}),s.send(void 0===o._bodyInit?null:o._bodyInit)})}j.polyfill=!0,e.fetch||(e.fetch=j,e.Headers=h,e.Request=b,e.Response=S),t.Headers=h,t.Request=b,t.Response=S,t.fetch=j,Object.defineProperty(t,"__esModule",{value:!0})}({})}("undefined"!=typeof self?self:e)});var r=t(function(t,r){!function(t){var r=function(){return r=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},r.apply(this,arguments)};function n(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r(function(e){e(t)})).then(o,s)}c((n=n.apply(e,t||[])).next())})}function i(e,t){var r,n,i,a,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return a={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(c){return function(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(r=1,n&&(i=2&s[0]?n.return:s[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,s[1])).done)return i;switch(n=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,n=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((i=(i=o.trys).length>0&&i[i.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){o.label=s[1];break}if(6===s[0]&&o.label<i[1]){o.label=i[1],i=s;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(s);break}i[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],n=0}finally{r=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,c])}}}"function"==typeof SuppressedError&&SuppressedError,"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==e||"undefined"!=typeof self&&self;var a=function(e){var t={exports:{}};return function(e,t){!function(e){var t={TASK_SUCCEEDED:"succeeded",TASK_PROCESSING:"processing",TASK_FAILED:"failed",TASK_ENQUEUED:"enqueued",TASK_CANCELED:"canceled"},r={INDEX_CREATION_FAILED:"index_creation_failed",MISSING_INDEX_UID:"missing_index_uid",INDEX_ALREADY_EXISTS:"index_already_exists",INDEX_NOT_FOUND:"index_not_found",INVALID_INDEX_UID:"invalid_index_uid",INDEX_NOT_ACCESSIBLE:"index_not_accessible",INVALID_INDEX_OFFSET:"invalid_index_offset",INVALID_INDEX_LIMIT:"invalid_index_limit",INVALID_STATE:"invalid_state",PRIMARY_KEY_INFERENCE_FAILED:"primary_key_inference_failed",INDEX_PRIMARY_KEY_ALREADY_EXISTS:"index_primary_key_already_exists",INVALID_INDEX_PRIMARY_KEY:"invalid_index_primary_key",DOCUMENTS_FIELDS_LIMIT_REACHED:"document_fields_limit_reached",MISSING_DOCUMENT_ID:"missing_document_id",INVALID_DOCUMENT_ID:"invalid_document_id",INVALID_CONTENT_TYPE:"invalid_content_type",MISSING_CONTENT_TYPE:"missing_content_type",INVALID_DOCUMENT_FIELDS:"invalid_document_fields",INVALID_DOCUMENT_LIMIT:"invalid_document_limit",INVALID_DOCUMENT_OFFSET:"invalid_document_offset",INVALID_DOCUMENT_FILTER:"invalid_document_filter",MISSING_DOCUMENT_FILTER:"missing_document_filter",INVALID_DOCUMENT_VECTORS_FIELD:"invalid_document_vectors_field",PAYLOAD_TOO_LARGE:"payload_too_large",MISSING_PAYLOAD:"missing_payload",MALFORMED_PAYLOAD:"malformed_payload",NO_SPACE_LEFT_ON_DEVICE:"no_space_left_on_device",INVALID_STORE_FILE:"invalid_store_file",INVALID_RANKING_RULES:"missing_document_id",INVALID_REQUEST:"invalid_request",INVALID_DOCUMENT_GEO_FIELD:"invalid_document_geo_field",INVALID_SEARCH_Q:"invalid_search_q",INVALID_SEARCH_OFFSET:"invalid_search_offset",INVALID_SEARCH_LIMIT:"invalid_search_limit",INVALID_SEARCH_PAGE:"invalid_search_page",INVALID_SEARCH_HITS_PER_PAGE:"invalid_search_hits_per_page",INVALID_SEARCH_ATTRIBUTES_TO_RETRIEVE:"invalid_search_attributes_to_retrieve",INVALID_SEARCH_ATTRIBUTES_TO_CROP:"invalid_search_attributes_to_crop",INVALID_SEARCH_CROP_LENGTH:"invalid_search_crop_length",INVALID_SEARCH_ATTRIBUTES_TO_HIGHLIGHT:"invalid_search_attributes_to_highlight",INVALID_SEARCH_SHOW_MATCHES_POSITION:"invalid_search_show_matches_position",INVALID_SEARCH_FILTER:"invalid_search_filter",INVALID_SEARCH_SORT:"invalid_search_sort",INVALID_SEARCH_FACETS:"invalid_search_facets",INVALID_SEARCH_HIGHLIGHT_PRE_TAG:"invalid_search_highlight_pre_tag",INVALID_SEARCH_HIGHLIGHT_POST_TAG:"invalid_search_highlight_post_tag",INVALID_SEARCH_CROP_MARKER:"invalid_search_crop_marker",INVALID_SEARCH_MATCHING_STRATEGY:"invalid_search_matching_strategy",INVALID_SEARCH_VECTOR:"invalid_search_vector",INVALID_SEARCH_ATTRIBUTES_TO_SEARCH_ON:"invalid_search_attributes_to_search_on",BAD_REQUEST:"bad_request",DOCUMENT_NOT_FOUND:"document_not_found",INTERNAL:"internal",INVALID_API_KEY:"invalid_api_key",INVALID_API_KEY_DESCRIPTION:"invalid_api_key_description",INVALID_API_KEY_ACTIONS:"invalid_api_key_actions",INVALID_API_KEY_INDEXES:"invalid_api_key_indexes",INVALID_API_KEY_EXPIRES_AT:"invalid_api_key_expires_at",API_KEY_NOT_FOUND:"api_key_not_found",IMMUTABLE_API_KEY_UID:"immutable_api_key_uid",IMMUTABLE_API_KEY_ACTIONS:"immutable_api_key_actions",IMMUTABLE_API_KEY_INDEXES:"immutable_api_key_indexes",IMMUTABLE_API_KEY_EXPIRES_AT:"immutable_api_key_expires_at",IMMUTABLE_API_KEY_CREATED_AT:"immutable_api_key_created_at",IMMUTABLE_API_KEY_UPDATED_AT:"immutable_api_key_updated_at",MISSING_AUTHORIZATION_HEADER:"missing_authorization_header",UNRETRIEVABLE_DOCUMENT:"unretrievable_document",MAX_DATABASE_SIZE_LIMIT_REACHED:"database_size_limit_reached",TASK_NOT_FOUND:"task_not_found",DUMP_PROCESS_FAILED:"dump_process_failed",DUMP_NOT_FOUND:"dump_not_found",INVALID_SWAP_DUPLICATE_INDEX_FOUND:"invalid_swap_duplicate_index_found",INVALID_SWAP_INDEXES:"invalid_swap_indexes",MISSING_SWAP_INDEXES:"missing_swap_indexes",MISSING_MASTER_KEY:"missing_master_key",INVALID_TASK_TYPES:"invalid_task_types",INVALID_TASK_UIDS:"invalid_task_uids",INVALID_TASK_STATUSES:"invalid_task_statuses",INVALID_TASK_LIMIT:"invalid_task_limit",INVALID_TASK_FROM:"invalid_task_from",INVALID_TASK_CANCELED_BY:"invalid_task_canceled_by",MISSING_TASK_FILTERS:"missing_task_filters",TOO_MANY_OPEN_FILES:"too_many_open_files",IO_ERROR:"io_error",INVALID_TASK_INDEX_UIDS:"invalid_task_index_uids",IMMUTABLE_INDEX_UID:"immutable_index_uid",IMMUTABLE_INDEX_CREATED_AT:"immutable_index_created_at",IMMUTABLE_INDEX_UPDATED_AT:"immutable_index_updated_at",INVALID_SETTINGS_DISPLAYED_ATTRIBUTES:"invalid_settings_displayed_attributes",INVALID_SETTINGS_SEARCHABLE_ATTRIBUTES:"invalid_settings_searchable_attributes",INVALID_SETTINGS_FILTERABLE_ATTRIBUTES:"invalid_settings_filterable_attributes",INVALID_SETTINGS_SORTABLE_ATTRIBUTES:"invalid_settings_sortable_attributes",INVALID_SETTINGS_RANKING_RULES:"invalid_settings_ranking_rules",INVALID_SETTINGS_STOP_WORDS:"invalid_settings_stop_words",INVALID_SETTINGS_SYNONYMS:"invalid_settings_synonyms",INVALID_SETTINGS_DISTINCT_ATTRIBUTE:"invalid_settings_distinct_attribute",INVALID_SETTINGS_TYPO_TOLERANCE:"invalid_settings_typo_tolerance",INVALID_SETTINGS_FACETING:"invalid_settings_faceting",INVALID_SETTINGS_PAGINATION:"invalid_settings_pagination",INVALID_TASK_BEFORE_ENQUEUED_AT:"invalid_task_before_enqueued_at",INVALID_TASK_AFTER_ENQUEUED_AT:"invalid_task_after_enqueued_at",INVALID_TASK_BEFORE_STARTED_AT:"invalid_task_before_started_at",INVALID_TASK_AFTER_STARTED_AT:"invalid_task_after_started_at",INVALID_TASK_BEFORE_FINISHED_AT:"invalid_task_before_finished_at",INVALID_TASK_AFTER_FINISHED_AT:"invalid_task_after_finished_at",MISSING_API_KEY_ACTIONS:"missing_api_key_actions",MISSING_API_KEY_INDEXES:"missing_api_key_indexes",MISSING_API_KEY_EXPIRES_AT:"missing_api_key_expires_at",INVALID_API_KEY_LIMIT:"invalid_api_key_limit",INVALID_API_KEY_OFFSET:"invalid_api_key_offset",INVALID_FACET_SEARCH_FACET_NAME:"invalid_facet_search_facet_name",MISSING_FACET_SEARCH_FACET_NAME:"missing_facet_search_facet_name",INVALID_FACET_SEARCH_FACET_QUERY:"invalid_facet_search_facet_query"};function n(){n=function(){return e};var e={},t=Object.prototype,r=t.hasOwnProperty,i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",o=i.asyncIterator||"@@asyncIterator",s=i.toStringTag||"@@toStringTag";function c(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,r){return e[t]=r}}function u(e,t,r,n){var i=Object.create((t&&t.prototype instanceof h?t:h).prototype),a=new P(n||[]);return i._invoke=function(e,t,r){var n="suspendedStart";return function(i,a){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===i)throw a;return{value:void 0,done:!0}}for(r.method=i,r.arg=a;;){var o=r.delegate;if(o){var s=S(o,r);if(s){if(s===l)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var c=f(e,t,r);if("normal"===c.type){if(n=r.done?"completed":"suspendedYield",c.arg===l)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(n="completed",r.method="throw",r.arg=c.arg)}}}(e,r,a),i}function f(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}e.wrap=u;var l={};function h(){}function d(){}function p(){}var v={};c(v,a,function(){return this});var m=Object.getPrototypeOf,g=m&&m(m(R([])));g&&g!==t&&r.call(g,a)&&(v=g);var y=p.prototype=h.prototype=Object.create(v);function b(e){["next","throw","return"].forEach(function(t){c(e,t,function(e){return this._invoke(t,e)})})}function w(e,t){function n(i,a,o,s){var c=f(e[i],e,a);if("throw"!==c.type){var u=c.arg,l=u.value;return l&&"object"==typeof l&&r.call(l,"__await")?t.resolve(l.__await).then(function(e){n("next",e,o,s)},function(e){n("throw",e,o,s)}):t.resolve(l).then(function(e){u.value=e,o(u)},function(e){return n("throw",e,o,s)})}s(c.arg)}var i;this._invoke=function(e,r){function a(){return new t(function(t,i){n(e,r,t,i)})}return i=i?i.then(a,a):a()}}function S(e,t){var r=e.iterator[t.method];if(void 0===r){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=void 0,S(e,t),"throw"===t.method))return l;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return l}var n=f(r,e.iterator,t.arg);if("throw"===n.type)return t.method="throw",t.arg=n.arg,t.delegate=null,l;var i=n.arg;return i?i.done?(t[e.resultName]=i.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,l):i:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,l)}function O(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function j(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function P(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(O,this),this.reset(!0)}function R(e){if(e){var t=e[a];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var n=-1,i=function t(){for(;++n<e.length;)if(r.call(e,n))return t.value=e[n],t.done=!1,t;return t.value=void 0,t.done=!0,t};return i.next=i}}return{next:_}}function _(){return{value:void 0,done:!0}}return d.prototype=p,c(y,"constructor",p),c(p,"constructor",d),d.displayName=c(p,s,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===d||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,p):(e.__proto__=p,c(e,s,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(w.prototype),c(w.prototype,o,function(){return this}),e.AsyncIterator=w,e.async=function(t,r,n,i,a){void 0===a&&(a=Promise);var o=new w(u(t,r,n,i),a);return e.isGeneratorFunction(r)?o:o.next().then(function(e){return e.done?e.value:o.next()})},b(y),c(y,s,"Generator"),c(y,a,function(){return this}),c(y,"toString",function(){return"[object Generator]"}),e.keys=function(e){var t=[];for(var r in e)t.push(r);return t.reverse(),function r(){for(;t.length;){var n=t.pop();if(n in e)return r.value=n,r.done=!1,r}return r.done=!0,r}},e.values=R,P.prototype={constructor:P,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(j),!e)for(var t in this)"t"===t.charAt(0)&&r.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function n(r,n){return o.type="throw",o.arg=e,t.next=r,n&&(t.method="next",t.arg=void 0),!!n}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],o=a.completion;if("root"===a.tryLoc)return n("end");if(a.tryLoc<=this.prev){var s=r.call(a,"catchLoc"),c=r.call(a,"finallyLoc");if(s&&c){if(this.prev<a.catchLoc)return n(a.catchLoc,!0);if(this.prev<a.finallyLoc)return n(a.finallyLoc)}else if(s){if(this.prev<a.catchLoc)return n(a.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return n(a.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var a=i;break}}a&&("break"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc&&(a=null);var o=a?a.completion:{};return o.type=e,o.arg=t,a?(this.method="next",this.next=a.finallyLoc,l):this.complete(o)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),l},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),j(r),l}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var i=n.arg;j(r)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,r){return this.delegate={iterator:R(e),resultName:t,nextLoc:r},"next"===this.method&&(this.arg=void 0),l}},e}function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function s(e,t,r){return t&&o(e.prototype,t),r&&o(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function c(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&l(e,t)}function f(e){return f=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},f(e)}function l(e,t){return l=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},l(e,t)}function h(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function d(e,t,r){return d=h()?Reflect.construct.bind():function(e,t,r){var n=[null];n.push.apply(n,t);var i=new(Function.bind.apply(e,n));return r&&l(i,r.prototype),i},d.apply(null,arguments)}function p(e){var t="function"==typeof Map?new Map:void 0;return p=function(e){if(null===e||!function(e){return-1!==Function.toString.call(e).indexOf("[native code]")}(e))return e;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,r)}function r(){return d(e,arguments,f(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),l(r,e)},p(e)}function v(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function m(e){var t=h();return function(){var r,n=f(e);if(t){var i=f(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return function(e,t){if(t&&("object"==typeof t||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return v(e)}(this,r)}}function g(e,t){if(e){if("string"==typeof e)return y(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?y(e,t):void 0}}function y(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function b(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=g(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return o=e.done,e},e:function(e){s=!0,a=e},f:function(){try{o||null==r.return||r.return()}finally{if(s)throw a}}}}function w(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r(function(e){e(t)})).then(o,s)}c((n=n.apply(e,t||[])).next())})}var S=/*#__PURE__*/function(e){u(r,e);var t=m(r);function r(e,n,i,o){var s,c,u,f;return a(this,r),s=t.call(this,e),Object.setPrototypeOf(v(s),r.prototype),s.name="MeiliSearchCommunicationError",n instanceof Response&&(s.message=n.statusText,s.statusCode=n.status),n instanceof Error&&(s.errno=n.errno,s.code=n.code),o?(s.stack=o,s.stack=null===(c=s.stack)||void 0===c?void 0:c.replace(/(TypeError|FetchError)/,s.name),s.stack=null===(u=s.stack)||void 0===u?void 0:u.replace("Failed to fetch","request to ".concat(i," failed, reason: connect ECONNREFUSED")),s.stack=null===(f=s.stack)||void 0===f?void 0:f.replace("Not Found","Not Found: ".concat(i))):Error.captureStackTrace&&Error.captureStackTrace(v(s),r),s}return s(r)}(/*#__PURE__*/p(Error)),O=/*#__PURE__*/function(e){u(r,e);var t=m(r);function r(e,n){var i;return a(this,r),i=t.call(this,e.message),Object.setPrototypeOf(v(i),r.prototype),i.name="MeiliSearchApiError",i.code=e.code,i.type=e.type,i.link=e.link,i.message=e.message,i.httpStatus=n,Error.captureStackTrace&&Error.captureStackTrace(v(i),r),i}return s(r)}(/*#__PURE__*/p(Error));function j(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:if(e.ok){t.next=11;break}return t.prev=1,t.next=4,e.json();case 4:r=t.sent,t.next=10;break;case 7:throw t.prev=7,t.t0=t.catch(1),new S(e.statusText,e,e.url);case 10:throw new O(r,e.status);case 11:return t.abrupt("return",e);case 12:case"end":return t.stop()}},t,null,[[1,7]])}))}function P(e,t,r){if("MeiliSearchApiError"!==e.name)throw new S(e.message,e,r,t);throw e}var R=/*#__PURE__*/function(e){u(r,e);var t=m(r);function r(e){var n;return a(this,r),n=t.call(this,e),Object.setPrototypeOf(v(n),r.prototype),n.name="MeiliSearchError",Error.captureStackTrace&&Error.captureStackTrace(v(n),r),n}return s(r)}(/*#__PURE__*/p(Error)),_=/*#__PURE__*/function(e){u(r,e);var t=m(r);function r(e){var n;return a(this,r),n=t.call(this,e),Object.setPrototypeOf(v(n),r.prototype),n.name="MeiliSearchTimeOutError",Error.captureStackTrace&&Error.captureStackTrace(v(n),r),n}return s(r)}(/*#__PURE__*/p(Error));function E(e,t){return"".concat(e,"\nHint: It might not be working because maybe you're not up to date with the Meilisearch version that ").concat(t," call requires.")}function x(e){return Object.entries(e).reduce(function(e,t){var r,n=function(e){if(Array.isArray(e))return e}(r=t)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a=[],o=!0,s=!1;try{for(r=r.call(e);!(o=(n=r.next()).done)&&(a.push(n.value),2!==a.length);o=!0);}catch(e){s=!0,i=e}finally{try{o||null==r.return||r.return()}finally{if(s)throw i}}return a}}(r)||g(r,2)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=n[1];return void 0!==i&&(e[n[0]]=i),e},{})}function I(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,new Promise(function(t){return setTimeout(t,e)});case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t)}))}function A(e){return Object.keys(e).reduce(function(t,r){var n=e[r];return void 0===n?t:Array.isArray(n)?Object.assign(Object.assign({},t),c({},r,n.join(","))):n instanceof Date?Object.assign(Object.assign({},t),c({},r,n.toISOString())):Object.assign(Object.assign({},t),c({},r,n))},{})}var T=/*#__PURE__*/function(){function e(t){a(this,e),this.headers=function(e){var t,r,n="X-Meilisearch-Client",i="Meilisearch JavaScript (v".concat("0.36.0",")"),a="Authorization",o=function(e){if(Array.isArray(e))return e.reduce(function(e,t){return e[t[0]]=t[1],e},{});if("has"in e){var t={};return e.forEach(function(e,r){return t[r]=e}),t}return Object.assign({},e)}(null!==(r=null===(t=e.requestConfig)||void 0===t?void 0:t.headers)&&void 0!==r?r:{});if(e.apiKey&&!o[a]&&(o[a]="Bearer ".concat(e.apiKey)),o["Content-Type"]||(o["Content-Type"]="application/json"),e.clientAgents&&Array.isArray(e.clientAgents)){var s=e.clientAgents.concat(i);o[n]=s.join(" ; ")}else{if(e.clientAgents&&!Array.isArray(e.clientAgents))throw new R('Meilisearch: The header "'.concat(n,'" should be an array of string(s).\n'));o[n]=i}return o}(t),this.requestConfig=t.requestConfig,this.httpClient=t.httpClient,this.requestTimeout=t.timeout;try{var r=function(e){try{return(t=e=function(e){return e.startsWith("https://")||e.startsWith("http://")?e:"http://".concat(e)}(e)).endsWith("/")||(t+="/"),t}catch(e){throw new R("The provided host is not valid.")}var t}(t.host);this.url=new URL(r)}catch(e){throw new R("The provided host is not valid.")}}return s(e,[{key:"request",value:function(e){var t,r=e.method,i=e.url,a=e.params,o=e.body,s=e.config,c=void 0===s?{}:s;return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var s,u,f,l,h;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(s=new URL(i,this.url),a&&(u=new URLSearchParams,Object.keys(a).filter(function(e){return null!==a[e]}).map(function(e){return u.set(e,a[e])}),s.search=u.toString()),(null===(t=c.headers)||void 0===t?void 0:t["Content-Type"])||(o=JSON.stringify(o)),f=Object.assign(Object.assign({},this.headers),c.headers),e.prev=5,l=this.fetchWithTimeout(s.toString(),Object.assign(Object.assign(Object.assign({},c),this.requestConfig),{method:r,body:o,headers:f}),this.requestTimeout),!this.httpClient){e.next=11;break}return e.next=10,l;case 10:return e.abrupt("return",e.sent);case 11:return e.next=13,l.then(function(e){return j(e)});case 13:return h=e.sent,e.next=16,h.json().catch(function(){});case 16:return e.abrupt("return",e.sent);case 20:e.prev=20,e.t0=e.catch(5),P(e.t0,e.t0.stack,s.toString());case 24:case"end":return e.stop()}},e,this,[[5,20]])}))}},{key:"fetchWithTimeout",value:function(e,t,r){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function i(){var a=this;return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",new Promise(function(n,i){var o,s=[(a.httpClient?a.httpClient:fetch)(e,t)];if(r){var c=new Promise(function(e,t){o=setTimeout(function(){t(new Error("Error: Request Timed Out"))},r)});s.push(c)}Promise.race(s).then(n).catch(i).finally(function(){clearTimeout(o)})}));case 1:case"end":return n.stop()}},i)}))}},{key:"get",value:function(e,t,r){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function i(){return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,this.request({method:"GET",url:e,params:t,config:r});case 2:return n.abrupt("return",n.sent);case 3:case"end":return n.stop()}},i,this)}))}},{key:"post",value:function(e,t,r,i){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function a(){return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,this.request({method:"POST",url:e,body:t,params:r,config:i});case 2:return n.abrupt("return",n.sent);case 3:case"end":return n.stop()}},a,this)}))}},{key:"put",value:function(e,t,r,i){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function a(){return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,this.request({method:"PUT",url:e,body:t,params:r,config:i});case 2:return n.abrupt("return",n.sent);case 3:case"end":return n.stop()}},a,this)}))}},{key:"patch",value:function(e,t,r,i){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function a(){return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,this.request({method:"PATCH",url:e,body:t,params:r,config:i});case 2:return n.abrupt("return",n.sent);case 3:case"end":return n.stop()}},a,this)}))}},{key:"delete",value:function(e,t,r,i){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function a(){return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,this.request({method:"DELETE",url:e,body:t,params:r,config:i});case 2:return n.abrupt("return",n.sent);case 3:case"end":return n.stop()}},a,this)}))}}]),e}(),k=/*#__PURE__*/s(function e(t){a(this,e),this.taskUid=t.taskUid,this.indexUid=t.indexUid,this.status=t.status,this.type=t.type,this.enqueuedAt=new Date(t.enqueuedAt)}),D=/*#__PURE__*/s(function e(t){a(this,e),this.indexUid=t.indexUid,this.status=t.status,this.type=t.type,this.uid=t.uid,this.details=t.details,this.canceledBy=t.canceledBy,this.error=t.error,this.duration=t.duration,this.startedAt=new Date(t.startedAt),this.enqueuedAt=new Date(t.enqueuedAt),this.finishedAt=new Date(t.finishedAt)}),F=/*#__PURE__*/function(){function e(t){a(this,e),this.httpRequest=new T(t)}return s(e,[{key:"getTask",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="tasks/".concat(e),t.next=3,this.httpRequest.get(r);case 3:return t.abrupt("return",new D(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"getTasks",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=3,this.httpRequest.get("tasks",A(e));case 3:return r=t.sent,t.abrupt("return",Object.assign(Object.assign({},r),{results:r.results.map(function(e){return new D(e)})}));case 5:case"end":return t.stop()}},t,this)}))}},{key:"waitForTask",value:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=r.timeOutMs,a=void 0===i?5e3:i,o=r.intervalMs,s=void 0===o?50:o;return w(this,void 0,void 0,/*#__PURE__*/n().mark(function r(){var i,o;return n().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:i=Date.now();case 1:if(!(Date.now()-i<a)){r.next=11;break}return r.next=4,this.getTask(e);case 4:if([t.TASK_ENQUEUED,t.TASK_PROCESSING].includes((o=r.sent).status)){r.next=7;break}return r.abrupt("return",o);case 7:return r.next=9,I(s);case 9:r.next=1;break;case 11:throw new _("timeout of ".concat(a,"ms has exceeded on process ").concat(e," when waiting a task to be resolved."));case 12:case"end":return r.stop()}},r,this)}))}},{key:"waitForTasks",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.timeOutMs,i=void 0===r?5e3:r,a=t.intervalMs,o=void 0===a?50:a;return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r,a,s,c;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:r=[],a=b(e),t.prev=2,a.s();case 4:if((s=a.n()).done){t.next=12;break}return c=s.value,t.next=8,this.waitForTask(c,{timeOutMs:i,intervalMs:o});case 8:r.push(t.sent);case 10:t.next=4;break;case 12:t.next=17;break;case 14:t.prev=14,t.t0=t.catch(2),a.e(t.t0);case 17:return t.prev=17,a.f(),t.finish(17);case 20:return t.abrupt("return",r);case 21:case"end":return t.stop()}},t,this,[[2,14,17,20]])}))}},{key:"cancelTasks",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=3,this.httpRequest.post("tasks/cancel",{},A(e));case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"deleteTasks",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=3,this.httpRequest.delete("tasks",{},A(e));case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}}]),e}(),N=/*#__PURE__*/function(){function e(t,r,n){a(this,e),this.uid=r,this.primaryKey=n,this.httpRequest=new T(t),this.tasks=new F(t)}return s(e,[{key:"search",value:function(e,t,r){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function i(){var a;return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return a="indexes/".concat(this.uid,"/search"),n.next=3,this.httpRequest.post(a,x(Object.assign({q:e},t)),void 0,r);case 3:return n.abrupt("return",n.sent);case 4:case"end":return n.stop()}},i,this)}))}},{key:"searchGet",value:function(e,t,r){var i,a,o,s,c,u,f;return w(this,void 0,void 0,/*#__PURE__*/n().mark(function l(){var h,d,p;return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return h="indexes/".concat(this.uid,"/search"),d=function(e){if("string"==typeof e)return e;if(Array.isArray(e))throw new R("The filter query parameter should be in string format when using searchGet")},p=Object.assign(Object.assign({q:e},t),{filter:d(null==t?void 0:t.filter),sort:null===(i=null==t?void 0:t.sort)||void 0===i?void 0:i.join(","),facets:null===(a=null==t?void 0:t.facets)||void 0===a?void 0:a.join(","),attributesToRetrieve:null===(o=null==t?void 0:t.attributesToRetrieve)||void 0===o?void 0:o.join(","),attributesToCrop:null===(s=null==t?void 0:t.attributesToCrop)||void 0===s?void 0:s.join(","),attributesToHighlight:null===(c=null==t?void 0:t.attributesToHighlight)||void 0===c?void 0:c.join(","),vector:null===(u=null==t?void 0:t.vector)||void 0===u?void 0:u.join(","),attributesToSearchOn:null===(f=null==t?void 0:t.attributesToSearchOn)||void 0===f?void 0:f.join(",")}),n.next=5,this.httpRequest.get(h,x(p),r);case 5:return n.abrupt("return",n.sent);case 6:case"end":return n.stop()}},l,this)}))}},{key:"searchForFacetValues",value:function(e,t){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function r(){var i;return n().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return i="indexes/".concat(this.uid,"/facet-search"),r.next=3,this.httpRequest.post(i,x(e),void 0,t);case 3:return r.abrupt("return",r.sent);case 4:case"end":return r.stop()}},r,this)}))}},{key:"getRawInfo",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid),e.next=3,this.httpRequest.get(t);case 3:return this.primaryKey=(r=e.sent).primaryKey,this.updatedAt=new Date(r.updatedAt),this.createdAt=new Date(r.createdAt),e.abrupt("return",r);case 8:case"end":return e.stop()}},e,this)}))}},{key:"fetchInfo",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.getRawInfo();case 2:return e.abrupt("return",this);case 3:case"end":return e.stop()}},e,this)}))}},{key:"fetchPrimaryKey",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.getRawInfo();case 2:return this.primaryKey=e.sent.primaryKey,e.abrupt("return",this.primaryKey);case 4:case"end":return e.stop()}},e,this)}))}},{key:"update",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r,i;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid),t.next=3,this.httpRequest.patch(r,e);case 3:return(i=t.sent).enqueuedAt=new Date(i.enqueuedAt),t.abrupt("return",i);case 6:case"end":return t.stop()}},t,this)}))}},{key:"delete",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid),e.next=3,this.httpRequest.delete(t);case 3:return e.abrupt("return",new k(e.sent));case 5:case"end":return e.stop()}},e,this)}))}},{key:"getTasks",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.tasks.getTasks(Object.assign(Object.assign({},e),{indexUids:[this.uid]}));case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t,this)}))}},{key:"getTask",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.tasks.getTask(e);case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t,this)}))}},{key:"waitForTasks",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.timeOutMs,i=void 0===r?5e3:r,a=t.intervalMs,o=void 0===a?50:a;return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.tasks.waitForTasks(e,{timeOutMs:i,intervalMs:o});case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t,this)}))}},{key:"waitForTask",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.timeOutMs,i=void 0===r?5e3:r,a=t.intervalMs,o=void 0===a?50:a;return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.tasks.waitForTask(e,{timeOutMs:i,intervalMs:o});case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t,this)}))}},{key:"getStats",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/stats"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"getDocuments",value:function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function r(){var i,a,o;return n().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:if(void 0===(t=x(t)).filter){r.next=15;break}return r.prev=2,i="indexes/".concat(this.uid,"/documents/fetch"),r.next=6,this.httpRequest.post(i,t);case 6:case 19:return r.abrupt("return",r.sent);case 9:throw r.prev=9,r.t0=r.catch(2),(r.t0 instanceof S||r.t0 instanceof O)&&(r.t0.message=E(r.t0.message,"getDocuments")),r.t0;case 13:r.next=20;break;case 15:return a="indexes/".concat(this.uid,"/documents"),o=Array.isArray(null==t?void 0:t.fields)?{fields:null===(e=null==t?void 0:t.fields)||void 0===e?void 0:e.join(",")}:{},r.next=19,this.httpRequest.get(a,Object.assign(Object.assign({},t),o));case 20:case"end":return r.stop()}},r,this,[[2,9]])}))}},{key:"getDocument",value:function(e,t){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function r(){var i,a;return n().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return i="indexes/".concat(this.uid,"/documents/").concat(e),a=function(){var e;if(Array.isArray(null==t?void 0:t.fields))return null===(e=null==t?void 0:t.fields)||void 0===e?void 0:e.join(",")}(),r.next=4,this.httpRequest.get(i,x(Object.assign(Object.assign({},t),{fields:a})));case 4:return r.abrupt("return",r.sent);case 5:case"end":return r.stop()}},r,this)}))}},{key:"addDocuments",value:function(e,t){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function r(){var i;return n().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return i="indexes/".concat(this.uid,"/documents"),r.next=3,this.httpRequest.post(i,e,t);case 3:return r.abrupt("return",new k(r.sent));case 5:case"end":return r.stop()}},r,this)}))}},{key:"addDocumentsFromString",value:function(e,t,r){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function i(){var a;return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return a="indexes/".concat(this.uid,"/documents"),n.next=3,this.httpRequest.post(a,e,r,{headers:{"Content-Type":t}});case 3:return n.abrupt("return",new k(n.sent));case 5:case"end":return n.stop()}},i,this)}))}},{key:"addDocumentsInBatches",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e3,r=arguments.length>2?arguments[2]:void 0;return w(this,void 0,void 0,/*#__PURE__*/n().mark(function i(){var a,o;return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:a=[],o=0;case 2:if(!(o<e.length)){n.next=11;break}return n.t0=a,n.next=6,this.addDocuments(e.slice(o,o+t),r);case 6:n.t1=n.sent,n.t0.push.call(n.t0,n.t1);case 8:o+=t,n.next=2;break;case 11:return n.abrupt("return",a);case 12:case"end":return n.stop()}},i,this)}))}},{key:"updateDocuments",value:function(e,t){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function r(){var i;return n().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return i="indexes/".concat(this.uid,"/documents"),r.next=3,this.httpRequest.put(i,e,t);case 3:return r.abrupt("return",new k(r.sent));case 5:case"end":return r.stop()}},r,this)}))}},{key:"updateDocumentsInBatches",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e3,r=arguments.length>2?arguments[2]:void 0;return w(this,void 0,void 0,/*#__PURE__*/n().mark(function i(){var a,o;return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:a=[],o=0;case 2:if(!(o<e.length)){n.next=11;break}return n.t0=a,n.next=6,this.updateDocuments(e.slice(o,o+t),r);case 6:n.t1=n.sent,n.t0.push.call(n.t0,n.t1);case 8:o+=t,n.next=2;break;case 11:return n.abrupt("return",a);case 12:case"end":return n.stop()}},i,this)}))}},{key:"updateDocumentsFromString",value:function(e,t,r){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function i(){var a;return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return a="indexes/".concat(this.uid,"/documents"),n.next=3,this.httpRequest.put(a,e,r,{headers:{"Content-Type":t}});case 3:return n.abrupt("return",new k(n.sent));case 5:case"end":return n.stop()}},i,this)}))}},{key:"deleteDocument",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r,i;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/documents/").concat(e),t.next=3,this.httpRequest.delete(r);case 3:return(i=t.sent).enqueuedAt=new Date(i.enqueuedAt),t.abrupt("return",i);case 6:case"end":return t.stop()}},t,this)}))}},{key:"deleteDocuments",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r,a,o;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r=!Array.isArray(e)&&"object"===i(e),a=r?"documents/delete":"documents/delete-batch",o="indexes/".concat(this.uid,"/").concat(a),t.prev=3,t.next=6,this.httpRequest.post(o,e);case 6:return t.abrupt("return",new k(t.sent));case 10:throw t.prev=10,t.t0=t.catch(3),(t.t0 instanceof S&&r||t.t0 instanceof O)&&(t.t0.message=E(t.t0.message,"deleteDocuments")),t.t0;case 14:case"end":return t.stop()}},t,this,[[3,10]])}))}},{key:"deleteAllDocuments",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/documents"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getSettings",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateSettings",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r,i;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings"),t.next=3,this.httpRequest.patch(r,e);case 3:return(i=t.sent).enqueued=new Date(i.enqueuedAt),t.abrupt("return",i);case 6:case"end":return t.stop()}},t,this)}))}},{key:"resetSettings",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getPagination",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/pagination"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updatePagination",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/pagination"),t.next=3,this.httpRequest.patch(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetPagination",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/pagination"),e.next=3,this.httpRequest.delete(t);case 3:return e.abrupt("return",new k(e.sent));case 5:case"end":return e.stop()}},e,this)}))}},{key:"getSynonyms",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/synonyms"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateSynonyms",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/synonyms"),t.next=3,this.httpRequest.put(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetSynonyms",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/synonyms"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getStopWords",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/stop-words"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateStopWords",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/stop-words"),t.next=3,this.httpRequest.put(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetStopWords",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/stop-words"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getRankingRules",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/ranking-rules"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateRankingRules",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/ranking-rules"),t.next=3,this.httpRequest.put(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetRankingRules",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/ranking-rules"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getDistinctAttribute",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/distinct-attribute"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateDistinctAttribute",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/distinct-attribute"),t.next=3,this.httpRequest.put(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetDistinctAttribute",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/distinct-attribute"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getFilterableAttributes",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/filterable-attributes"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateFilterableAttributes",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/filterable-attributes"),t.next=3,this.httpRequest.put(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetFilterableAttributes",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/filterable-attributes"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getSortableAttributes",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/sortable-attributes"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateSortableAttributes",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/sortable-attributes"),t.next=3,this.httpRequest.put(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetSortableAttributes",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/sortable-attributes"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getSearchableAttributes",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/searchable-attributes"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateSearchableAttributes",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/searchable-attributes"),t.next=3,this.httpRequest.put(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetSearchableAttributes",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/searchable-attributes"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getDisplayedAttributes",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/displayed-attributes"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateDisplayedAttributes",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/displayed-attributes"),t.next=3,this.httpRequest.put(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetDisplayedAttributes",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/displayed-attributes"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getTypoTolerance",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/typo-tolerance"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateTypoTolerance",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r,i;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/typo-tolerance"),t.next=3,this.httpRequest.patch(r,e);case 3:return(i=t.sent).enqueuedAt=new Date(i.enqueuedAt),t.abrupt("return",i);case 6:case"end":return t.stop()}},t,this)}))}},{key:"resetTypoTolerance",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/typo-tolerance"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getFaceting",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/faceting"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateFaceting",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/faceting"),t.next=3,this.httpRequest.patch(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetFaceting",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/faceting"),e.next=3,this.httpRequest.delete(t);case 3:return e.abrupt("return",new k(e.sent));case 5:case"end":return e.stop()}},e,this)}))}},{key:"getSeparatorTokens",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/separator-tokens"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateSeparatorTokens",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/separator-tokens"),t.next=3,this.httpRequest.put(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetSeparatorTokens",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/separator-tokens"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getNonSeparatorTokens",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/non-separator-tokens"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateNonSeparatorTokens",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/non-separator-tokens"),t.next=3,this.httpRequest.put(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetNonSeparatorTokens",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/non-separator-tokens"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}},{key:"getDictionary",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/dictionary"),e.next=3,this.httpRequest.get(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"updateDictionary",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="indexes/".concat(this.uid,"/settings/dictionary"),t.next=3,this.httpRequest.put(r,e);case 3:return t.abrupt("return",new k(t.sent));case 5:case"end":return t.stop()}},t,this)}))}},{key:"resetDictionary",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){var t,r;return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="indexes/".concat(this.uid,"/settings/dictionary"),e.next=3,this.httpRequest.delete(t);case 3:return(r=e.sent).enqueuedAt=new Date(r.enqueuedAt),e.abrupt("return",r);case 6:case"end":return e.stop()}},e,this)}))}}],[{key:"create",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0;return w(this,void 0,void 0,/*#__PURE__*/n().mark(function i(){var a;return n().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return a=new T(r),n.next=4,a.post("indexes",Object.assign(Object.assign({},t),{uid:e}));case 4:return n.abrupt("return",new k(n.sent));case 6:case"end":return n.stop()}},i)}))}}]),e}(),L=/*#__PURE__*/function(){function e(t){a(this,e),this.config=t,this.httpRequest=new T(t),this.tasks=new F(t)}return s(e,[{key:"index",value:function(e){return new N(this.config,e)}},{key:"getIndex",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",new N(this.config,e).fetchInfo());case 1:case"end":return t.stop()}},t,this)}))}},{key:"getRawIndex",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",new N(this.config,e).getRawInfo());case 1:case"end":return t.stop()}},t,this)}))}},{key:"getIndexes",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r,i,a=this;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getRawIndexes(e);case 2:return i=(r=t.sent).results.map(function(e){return new N(a.config,e.uid,e.primaryKey)}),t.abrupt("return",Object.assign(Object.assign({},r),{results:i}));case 5:case"end":return t.stop()}},t,this)}))}},{key:"getRawIndexes",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=3,this.httpRequest.get("indexes",e);case 3:return t.abrupt("return",t.sent);case 4:case"end":return t.stop()}},t,this)}))}},{key:"createIndex",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function r(){return n().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,N.create(e,t,this.config);case 2:return r.abrupt("return",r.sent);case 3:case"end":return r.stop()}},r,this)}))}},{key:"updateIndex",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function r(){return n().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,new N(this.config,e).update(t);case 2:return r.abrupt("return",r.sent);case 3:case"end":return r.stop()}},r,this)}))}},{key:"deleteIndex",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,new N(this.config,e).delete();case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t,this)}))}},{key:"deleteIndexIfExists",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,this.deleteIndex(e);case 3:return t.abrupt("return",!0);case 6:if(t.prev=6,t.t0=t.catch(0),t.t0.code!==r.INDEX_NOT_FOUND){t.next=10;break}return t.abrupt("return",!1);case 10:throw t.t0;case 11:case"end":return t.stop()}},t,this,[[0,6]])}))}},{key:"swapIndexes",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=3,this.httpRequest.post("/swap-indexes",e);case 3:return t.abrupt("return",t.sent);case 4:case"end":return t.stop()}},t,this)}))}},{key:"multiSearch",value:function(e,t){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function r(){return n().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=3,this.httpRequest.post("multi-search",e,void 0,t);case 3:return r.abrupt("return",r.sent);case 4:case"end":return r.stop()}},r,this)}))}},{key:"getTasks",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.tasks.getTasks(e);case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t,this)}))}},{key:"getTask",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.tasks.getTask(e);case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t,this)}))}},{key:"waitForTasks",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.timeOutMs,i=void 0===r?5e3:r,a=t.intervalMs,o=void 0===a?50:a;return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.tasks.waitForTasks(e,{timeOutMs:i,intervalMs:o});case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t,this)}))}},{key:"waitForTask",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.timeOutMs,i=void 0===r?5e3:r,a=t.intervalMs,o=void 0===a?50:a;return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.tasks.waitForTask(e,{timeOutMs:i,intervalMs:o});case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t,this)}))}},{key:"cancelTasks",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.tasks.cancelTasks(e);case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t,this)}))}},{key:"deleteTasks",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.tasks.deleteTasks(e);case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}},t,this)}))}},{key:"getKeys",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=3,this.httpRequest.get("keys",e);case 3:return(r=t.sent).results=r.results.map(function(e){return Object.assign(Object.assign({},e),{createdAt:new Date(e.createdAt),updatedAt:new Date(e.updatedAt)})}),t.abrupt("return",r);case 6:case"end":return t.stop()}},t,this)}))}},{key:"getKey",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="keys/".concat(e),t.next=3,this.httpRequest.get(r);case 3:return t.abrupt("return",t.sent);case 4:case"end":return t.stop()}},t,this)}))}},{key:"createKey",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=3,this.httpRequest.post("keys",e);case 3:return t.abrupt("return",t.sent);case 4:case"end":return t.stop()}},t,this)}))}},{key:"updateKey",value:function(e,t){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function r(){var i;return n().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return i="keys/".concat(e),r.next=3,this.httpRequest.patch(i,t);case 3:return r.abrupt("return",r.sent);case 4:case"end":return r.stop()}},r,this)}))}},{key:"deleteKey",value:function(e){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function t(){var r;return n().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return r="keys/".concat(e),t.next=3,this.httpRequest.delete(r);case 3:return t.abrupt("return",t.sent);case 4:case"end":return t.stop()}},t,this)}))}},{key:"health",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=3,this.httpRequest.get("health");case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"isHealthy",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=4,this.httpRequest.get("health");case 4:return e.abrupt("return",!0);case 7:return e.prev=7,e.t0=e.catch(0),e.abrupt("return",!1);case 10:case"end":return e.stop()}},e,this,[[0,7]])}))}},{key:"getStats",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=3,this.httpRequest.get("stats");case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"getVersion",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=3,this.httpRequest.get("version");case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}))}},{key:"createDump",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=3,this.httpRequest.post("dumps");case 3:return e.abrupt("return",new k(e.sent));case 5:case"end":return e.stop()}},e,this)}))}},{key:"createSnapshot",value:function(){return w(this,void 0,void 0,/*#__PURE__*/n().mark(function e(){return n().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=3,this.httpRequest.post("snapshots");case 3:return e.abrupt("return",new k(e.sent));case 5:case"end":return e.stop()}},e,this)}))}},{key:"generateTenantToken",value:function(e,t,r){var n=new Error;throw new Error("Meilisearch: failed to generate a tenant token. Generation of a token only works in a node environment \n ".concat(n.stack,"."))}}]),e}(),M=/*#__PURE__*/function(e){u(r,e);var t=m(r);function r(e){return a(this,r),t.call(this,e)}return s(r)}(L);e.ContentTypeEnum={JSON:"application/json",CSV:"text/csv",NDJSON:"application/x-ndjson"},e.ErrorStatusCode=r,e.Index=N,e.MatchingStrategies={ALL:"all",LAST:"last"},e.MeiliSearch=M,e.MeiliSearchApiError=O,e.MeiliSearchCommunicationError=S,e.MeiliSearchError=R,e.MeiliSearchTimeOutError=_,e.Meilisearch=M,e.TaskStatus=t,e.TaskTypes={DOCUMENTS_ADDITION_OR_UPDATE:"documentAdditionOrUpdate",DOCUMENT_DELETION:"documentDeletion",DUMP_CREATION:"dumpCreation",INDEX_CREATION:"indexCreation",INDEX_DELETION:"indexDeletion",INDEXES_SWAP:"indexSwap",INDEX_UPDATE:"indexUpdate",SETTINGS_UPDATE:"settingsUpdate",SNAPSHOT_CREATION:"snapshotCreation",TASK_CANCELATION:"taskCancelation",TASK_DELETION:"taskDeletion"},e.default=M,e.httpErrorHandler=P,e.httpResponseErrorHandler=j,e.versionErrorHintMessage=E,Object.defineProperty(e,"__esModule",{value:!0})}(t)}(0,t.exports),t.exports}();function o(e){return"object"==typeof e&&!Array.isArray(e)&&null!==e}function s(e){if("function"==typeof e){var t=e();if("string"!=typeof t)throw new TypeError("Provided apiKey function (2nd parameter) did not return a string, expected string");return t}return e}var c=/([\\"])/g;function u(e){return e.replace(c,"\\$1")}function f(e){var t=u(e),r=t.indexOf(":"),n=t.slice(0,r),i=t.slice(r+1);return'"'.concat(n,'"="').concat(i,'"')}var l=/(?<!(?:[<!>]?=|<|>|:).*)([<!>]?=|<|>|:)/;function h(e){var t=e.split(l),r=t[1],n=t[2],i=u(t[0]);return'"'.concat(i.trim(),'"').concat(":"===r?" ":r).concat(n.trim())}function d(e,t){return"string"==typeof t?e(t):t.map(function(t){return"string"==typeof t?e(t):t.map(function(t){return e(t)})})}function p(e){return"string"==typeof e?[e]:e}function v(e){var t,r,n,i,a,o,s,c,u=e.query,l=e.facets,v=e.attributesToSnippet,m=e.snippetEllipsisText,g=e.attributesToRetrieve,y=e.attributesToHighlight,b=e.highlightPreTag,w=e.highlightPostTag,S=e.placeholderSearch,O=e.pagination,j=e.sort,P=e.restrictSearchableAttributes,R=e.meiliSearchParams,_={indexUid:e.indexUid},E=(r=e.facetFilters,n=e.filters,i=void 0!==(t=e.numericFilters)?d(h,t):t,a=void 0!==r?d(f,r):r,o=p(i),s=p(a),c=[],void 0!==n&&c.push(n),void 0!==o&&c.push.apply(c,o),void 0!==s&&c.push.apply(c,s),c);return{getParams:function(){return _},addQuery:function(){_.q=u},addFacets:function(){void 0!==l&&(_.facets="string"==typeof l?[l]:l)},addAttributesToCrop:function(){var e,t=null!==(e=null==R?void 0:R.attributesToCrop)&&void 0!==e?e:v;void 0!==t&&(_.attributesToCrop=t)},addCropLength:function(){var e=null==R?void 0:R.cropLength;void 0!==e&&(_.cropLength=e)},addCropMarker:function(){var e,t=null!==(e=null==R?void 0:R.cropMarker)&&void 0!==e?e:m;void 0!==t&&(_.cropMarker=t)},addFilters:function(){E.length&&(_.filter=E)},addAttributesToRetrieve:function(){var e,t=null!==(e=null==R?void 0:R.attributesToRetrieve)&&void 0!==e?e:g;void 0!==t&&(_.attributesToRetrieve=t)},addAttributesToHighlight:function(){var e,t;_.attributesToHighlight=null!==(t=null!==(e=null==R?void 0:R.attributesToHighlight)&&void 0!==e?e:y)&&void 0!==t?t:["*"]},addPreTag:function(){var e,t;_.highlightPreTag=null!==(t=null!==(e=null==R?void 0:R.highlightPreTag)&&void 0!==e?e:b)&&void 0!==t?t:"__ais-highlight__"},addPostTag:function(){var e,t;_.highlightPostTag=null!==(t=null!==(e=null==R?void 0:R.highlightPostTag)&&void 0!==e?e:w)&&void 0!==t?t:"__/ais-highlight__"},addPagination:function(){var e=function(e,t,r){return!!(r||t||e&&0!==e.length)}(E,u,S);if(O.finite){var t=function(e,t){var r=e.page;return t?{hitsPerPage:e.hitsPerPage,page:r+1}:{hitsPerPage:0,page:r+1}}(O,e),r=t.page;_.hitsPerPage=t.hitsPerPage,_.page=r}else{var n=function(e,t){var r=e.hitsPerPage;return t?{limit:r+1,offset:e.page*r}:{limit:0,offset:0}}(O,e),i=n.offset;_.limit=n.limit,_.offset=i}},addSort:function(){(null==j?void 0:j.length)&&(_.sort=Array.isArray(j)?j:[j])},addGeoSearchFilter:function(){var t=function(e){var t,r,n,i=e.insideBoundingBox,a=e.aroundLatLng,o=e.aroundRadius,s=e.minimumAroundRadius;if(a){var c=a.split(",").map(function(e){return Number.parseFloat(e).toFixed(5)});t=[c[0],d=c[1]]}if(null==o&&null==s||("all"===o?console.warn("instant-meilisearch is not compatible with the `all` value on the aroundRadius parameter"):r=null!=o?o:s),i&&"string"==typeof i){var u=i.split(",").map(function(e){return parseFloat(e)}),f=u[1],l=u[2],h=u[3];n="_geoBoundingBox([".concat(u[0],", ").concat(f,"], [").concat(l,", ").concat(h,"])")}else if(null!=t&&null!=r){var d=t[1];n="_geoRadius(".concat(t[0],", ").concat(d,", ").concat(r,")")}return n}({insideBoundingBox:e.insideBoundingBox,aroundLatLng:e.aroundLatLng,aroundRadius:e.aroundRadius,minimumAroundRadius:e.minimumAroundRadius});void 0!==t&&(Array.isArray(_.filter)?_.filter.unshift(t):_.filter=[t])},addShowMatchesPosition:function(){var e=null==R?void 0:R.showMatchesPosition;void 0!==e&&(_.showMatchesPosition=e)},addMatchingStrategy:function(){var e=null==R?void 0:R.matchingStrategy;void 0!==e&&(_.matchingStrategy=e)},addShowRankingScore:function(){var e=null==R?void 0:R.showRankingScore;void 0!==e&&(_.showRankingScore=e)},addAttributesToSearchOn:function(){var e=void 0!==(null==R?void 0:R.attributesToSearchOn)?R.attributesToSearchOn:P;void 0!==e&&(_.attributesToSearchOn=e)}}}function m(e){var t=v(e);return t.addQuery(),t.addFacets(),t.addAttributesToCrop(),t.addCropLength(),t.addCropMarker(),t.addFilters(),t.addAttributesToRetrieve(),t.addAttributesToHighlight(),t.addPreTag(),t.addPostTag(),t.addPagination(),t.addSort(),t.addGeoSearchFilter(),t.addShowMatchesPosition(),t.addMatchingStrategy(),t.addShowRankingScore(),t.addAttributesToSearchOn(),t.getParams()}function g(e){return"string"==typeof e?e:void 0===e?JSON.stringify(null):JSON.stringify(e)}function y(e){return Array.isArray(e)?e.map(function(e){return y(e)}):o(e)?Object.keys(e).reduce(function(t,r){return t[r]=y(e[r]),t},{}):{value:g(e)}}function b(e){if(!e)return{};var t=y(e);return{_highlightResult:t,_snippetResult:t}}function w(e,t){if(null!=e.totalPages)return e.totalPages;if(0===t)return 0;var r=e.limit,n=e.offset;return(void 0===n?0:n)/t+1+(e.hits.length>=(void 0===r?20:r)?1:0)}function S(e,t,r,n){return e?function(e,t,r){for(var n={},i=0,a=function(e){return e?"string"==typeof e?[e]:e:[]}(e);i<a.length;i++){var o=a[i];for(var s in t[o])n[o]||(n[o]=r[o]||{}),n[o][s]=n[o][s]?r[o][s]:0}return n}(t,r,n=n||{}):n}function O(e,t,n){return{results:e.map(function(e){return function(e,t,n){var i,a=e.processingTimeMs,o=e.query,s=e.indexUid,c=e.facetDistribution,u=void 0===c?{}:c,f=e.facetStats,l=void 0===f?{}:f,h=Object.keys(u),d=function(e,t){var r=t.hitsPerPage;return{page:t.page,nbPages:w(e,r),hitsPerPage:r}}(e,e.pagination),p=d.hitsPerPage,v=d.page,m=d.nbPages,g=function(e,t){var r=e.hits,n=t.primaryKey;return!t.finitePagination&&r.length>e.pagination.hitsPerPage&&r.splice(r.length-1,1),function(e){for(var t,r=0;r<e.length;r++){var n="".concat(r+1e6*Math.random());e[r]._geo&&(e[r]._geoloc=e[r]._geo,e[r].objectID=n),(null===(t=e[r]._formatted)||void 0===t?void 0:t._geo)&&(e[r]._formatted._geoloc=e[r]._formatted._geo,e[r]._formatted.objectID=n)}return e}(r.map(function(e){if(Object.keys(e).length>0){var t=e._formatted,r=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]])}return r}(e,["_formatted","_matchesPosition"]),i=Object.assign(r,b(t));return n&&(i.objectID=e[n]),i}return e}))}(e,n),y=function(e){var t=e.hitsPerPage,r=e.totalPages,n=e.estimatedTotalHits,i=e.totalHits;return null!=n?n:null!=i?i:(void 0===t?0:t)*(void 0===r?0:r)}(e);return{index:s,hitsPerPage:p,page:v,facets:S(n.keepZeroFacets,h,t,u),nbPages:m,nbHits:y,processingTimeMS:a,query:o,hits:g,params:"",exhaustiveNbHits:!1,facets_stats:(i=l,Object.keys(i).reduce(function(e,t){return e[t]=r(r({},i[t]),{avg:0,sum:0}),e},{}))}}(e,t[e.indexUid],n)})}}function j(e){return e?e.split(/,(?=\w+:(?:asc|desc))/):[]}function P(e,t,r){return{hitsPerPage:void 0===t?20:t,page:r||0,finite:!!e}}function R(e){var t=e.indexOf(":");return-1===t?{indexUid:e,sortBy:""}:{indexUid:e.substring(0,t),sortBy:e.substring(t+1)}}function _(e,t){var n=e.query,i=e.params,a=R(e.indexName),o=a.indexUid,s=a.sortBy,c=P(t.finitePagination,null==i?void 0:i.hitsPerPage,null==i?void 0:i.page);return r(r(r(r({},t),{query:n}),i),{sort:j(s),indexUid:o,pagination:c,placeholderSearch:!1!==t.placeholderSearch,keepZeroFacets:!!t.keepZeroFacets})}function E(e){var t=v(r(r({},e),{placeholderSearch:!0,query:""}));return t.addFacets(),t.addPagination(),t.getParams()}function x(e,t,r){return n(this,void 0,void 0,function(){var n,a,o,s,c;return i(this,function(i){switch(i.label){case 0:return u="indexUid",f=[],n=t.filter(function(e){return!f.includes(e[u])&&(f.push(e[u]),!0)}).filter(function(e){var t=e.indexUid;return!Object.keys(r).includes(t)}),0===n.length?[2,r]:[4,e.multiSearch(n,[])];case 1:for(a=i.sent(),o=0,s=a;o<s.length;o++)r[(c=s[o]).indexUid]=c.facetDistribution||{};return[2,r]}var u,f})})}var I=function(e){void 0===e&&(e=[]);var t="Meilisearch instant-meilisearch (v".concat("0.14.0",")");return e.concat(t)};t.instantMeiliSearch=function(e,t,c){void 0===t&&(t=""),void 0===c&&(c={}),function(e,t,r){var n=r.requestConfig,i=r.httpClient;if("string"!=typeof e)throw new TypeError("Provided hostUrl value (1st parameter) is not a string, expected string");if("string"!=typeof t&&"function"!=typeof t)throw new TypeError("Provided apiKey value (2nd parameter) is not a string or a function, expected string or function");if(void 0!==n&&!o(n))throw new TypeError("Provided requestConfig should be an object");if(i&&"function"!=typeof i)throw new TypeError("Provided custom httpClient should be a function")}(e,t,c);var u={host:e,apiKey:t=s(t),clientAgents:I(c.clientAgents)};void 0!==c.httpClient&&(u.httpClient=c.httpClient),void 0!==c.requestConfig&&(u.requestConfig=c.requestConfig);var f,l,h,d=new a.MeiliSearch(u),p=function(e){void 0===e&&(e={});var t=e;return{getEntry:function(e){if(t[e])try{return JSON.parse(t[e])}catch(e){return}},formatKey:function(e){return e.reduce(function(e,t){return e+JSON.stringify(t)},"")},setEntry:function(e,r){t[e]=JSON.stringify(r)},clearCache:function(){t={}}}}(),v=(l=d,h=p,{multiSearch:function(e,t){return n(this,void 0,void 0,function(){var n,a,o,s;return i(this,function(i){switch(i.label){case 0:return n=h.formatKey([e]),(a=h.getEntry(n))?[2,a]:[4,l.multiSearch({queries:e})];case 1:return o=i.sent(),s=o.results.map(function(e,n){return r(r({},e),{pagination:t[n]||{}})}),h.setEntry(n,s),[2,s]}})})}}),g={},y=(f=c,r(r({},{placeholderSearch:!0,keepZeroFacets:!1,clientAgents:[],finitePagination:!1}),f));return{setMeiliSearchParams:function(e){var t=c.meiliSearchParams;c.meiliSearchParams=void 0===t?e:r(r({},t),e)},searchClient:{clearCache:function(){return p.clearCache()},search:function(e){return n(this,void 0,void 0,function(){var t,n,a,o,s,u,f,l,h,d;return i(this,function(i){switch(i.label){case 0:for(i.trys.push([0,3,,4]),t=[],n=[],a=[],o=0,s=e;o<s.length;o++)u=_(s[o],c),f=m(u),t.push(f),l=E(u),a.push(l),n.push(u.pagination);return[4,x(v,a,g)];case 1:return g=i.sent(),[4,v.multiSearch(t,n)];case 2:return h=i.sent(),g=function(e,t){for(var n=0,i=t;n<i.length;n++){var a=i[n];e[a.indexUid]=r(r({},a.facetDistribution||{}),e[a.indexUid]||{})}return e}(g,h),[2,O(h,g,y)];case 3:throw d=i.sent(),console.error(d),new Error(d);case 4:return[2]}})})},searchForFacetValues:function(e){return n(this,void 0,void 0,function(){var t,n,a,o,s,u,f,l,h;return i(this,function(i){switch(i.label){case 0:t=[],n=0,a=e,i.label=1;case 1:return n<a.length?(s=function(e,t){var n=R(e.indexName),i=n.indexUid,a=n.sortBy,o=e.params,s=P(t.finitePagination,null==o?void 0:o.hitsPerPage,null==o?void 0:o.page);return r(r(r({},t),o),{sort:j(a),indexUid:i,pagination:s,placeholderSearch:!1!==t.placeholderSearch,keepZeroFacets:!!t.keepZeroFacets})}(o=a[n],c),u=m(s),delete(f=r(r({},u),{facetQuery:o.params.facetQuery,facetName:o.params.facetName})).indexUid,[4,d.index(s.indexUid).searchForFacetValues(f)]):[3,4];case 2:l=i.sent(),h=l.facetHits.map(function(e){return r(r({},e),{highlighted:e.value})}),t.push({facetHits:h,exhaustiveFacetsCount:!1,processingTimeMS:l.processingTimeMs}),i.label=3;case 3:return n++,[3,1];case 4:return[2,t]}})})}}}},Object.defineProperty(t,"__esModule",{value:!0})}(r)}),n=function(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=t.descendantName,n=t.modifierName,i=r?"-".concat(r):"",a=n?"--".concat(n):"";return"".concat("ais","-").concat(e).concat(i).concat(a)}};function i(e){return e.toString().charAt(0).toUpperCase()+e.toString().slice(1)}function a(){}var o=function(e,t){return e},s=a,c=a;"development"==="production".NODE_ENV&&(s=function(e){console.warn("[InstantSearch.js]: ".concat(e.trim()))},o=function(e,t){var r=!1;return function(){return r||(r=!0,"development"==="production".NODE_ENV&&s(t)),e.apply(void 0,arguments)}},(c=function(e,t){e||c.cache[t]||(c.cache[t]=!0,"development"==="production".NODE_ENV&&s(t))}).cache={});var u=Object.keys;function f(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{if(a=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;c=!1}else for(;!(c=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(e,t)||l(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function l(e,t){if(e){if("string"==typeof e)return h(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?h(e,t):void 0}}function h(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var d={query:{connectors:["connectSearchBox"],widgets:["ais.searchBox","ais.autocomplete","ais.voiceSearch"]},refinementList:{connectors:["connectRefinementList"],widgets:["ais.refinementList"]},menu:{connectors:["connectMenu"],widgets:["ais.menu"]},hierarchicalMenu:{connectors:["connectHierarchicalMenu"],widgets:["ais.hierarchicalMenu"]},numericMenu:{connectors:["connectNumericMenu"],widgets:["ais.numericMenu"]},ratingMenu:{connectors:["connectRatingMenu"],widgets:["ais.ratingMenu"]},range:{connectors:["connectRange"],widgets:["ais.rangeInput","ais.rangeSlider","ais.range"]},toggle:{connectors:["connectToggleRefinement"],widgets:["ais.toggleRefinement"]},geoSearch:{connectors:["connectGeoSearch"],widgets:["ais.geoSearch"]},sortBy:{connectors:["connectSortBy"],widgets:["ais.sortBy"]},page:{connectors:["connectPagination"],widgets:["ais.pagination","ais.infiniteHits"]},hitsPerPage:{connectors:["connectHitsPerPage"],widgets:["ais.hitsPerPage"]},configure:{connectors:["connectConfigure"],widgets:["ais.configure"]},places:{connectors:[],widgets:["ais.places"]}};function p(e){var t=e.index,r=e.indexUiState,n=t.getWidgets().map(function(e){return e.$$type}).filter(Boolean),a=u(r).reduce(function(e,t){var r=d[t];if(!r)return e;var i=r.widgets;return i&&!i.some(function(e){return n.includes(e)})&&e.push([t,{connectors:r.connectors,widgets:r.widgets.map(function(e){return e.split("ais.")[1]})}]),e},[]);"development"==="production".NODE_ENV&&c(0===a.length,'The UI state for the index "'.concat(t.getIndexId(),'" is not consistent with the widgets mounted.\n\nThis can happen when the UI state is specified via `initialUiState`, `routing` or `setUiState` but that the widgets responsible for this state were not added. This results in those query parameters not being sent to the API.\n\nTo fully reflect the state, some widgets need to be added to the index "').concat(t.getIndexId(),'":\n\n').concat(a.map(function(e){var t,r,n=f(e,2),i=n[1].widgets;return"- `".concat(n[0],"` needs one of these widgets: ").concat((t=[]).concat.apply(t,(r=i.map(function(e){return function(e){switch(e){case"range":return[];case"menu":return["menu","menuSelect"];default:return[e]}}(e)}),function(e){if(Array.isArray(e))return h(e)}(r)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||l(r)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())).map(function(e){return'"'.concat(e,'"')}).join(", "))}).join("\n"),'\n\nIf you do not wish to display widgets but still want to support their search parameters, you can mount "virtual widgets" that don\'t render anything:\n\n```\n').concat(a.filter(function(e){return f(e,2)[1].connectors.length>0}).map(function(e){var t=f(e,2)[1],r=t.connectors,n=i(t.widgets[0]),a=r[0];return"const virtual".concat(n," = ").concat(a,"(() => null);")}).join("\n"),"\n\nsearch.addWidgets([\n  ").concat(a.filter(function(e){return f(e,2)[1].connectors.length>0}).map(function(e){var t=i(f(e,2)[1].widgets[0]);return"virtual".concat(t,"({ /* ... */ })")}).join(",\n  "),"\n]);\n```\n\nIf you're using custom widgets that do set these query parameters, we recommend using connectors instead.\n\nSee https://www.algolia.com/doc/guides/building-search-ui/widgets/customize-an-existing-widget/js/#customize-the-complete-ui-of-the-widgets"))}function v(e){return Object.prototype.toString.call(e).slice(8,-1)}function m(e,t){if(void 0===e||"function"!=typeof e)throw new Error("The render function is not valid (received type ".concat(v(e),").\n\n").concat(t))}function g(e){var t=e.attributesToClear,r=void 0===t?[]:t,n=e.helper.state.setPage(0);return n=r.reduce(function(e,t){return n.isNumericRefined(t)?e.removeNumericRefinement(t):n.isHierarchicalFacet(t)?e.removeHierarchicalFacetRefinement(t):n.isDisjunctiveFacet(t)?e.removeDisjunctiveFacetRefinement(t):n.isConjunctiveFacet(t)?e.removeFacetRefinement(t):e},n),-1!==r.indexOf("query")&&(n=n.setQuery("")),n}var y={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},b=/[&<>"']/g,w=RegExp(b.source),S={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},O=/&(amp|quot|lt|gt|#39);/g,j=RegExp(O.source);function P(e){return P="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},P(e)}function R(e){if(!function(e){return"object"===P(e)&&null!==e}(e)||"[object Object]"!==function(e){return null===e?void 0===e?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}(e))return!1;if(null===Object.getPrototypeOf(e))return!0;for(var t=e;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function _(e){return _="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_(e)}function E(){return E=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},E.apply(this,arguments)}function x(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function I(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?x(Object(r),!0).forEach(function(t){A(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):x(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function A(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==_(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==_(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===_(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var T={highlightPreTag:"__ais-highlight__",highlightPostTag:"__/ais-highlight__"},k={highlightPreTag:"<mark>",highlightPostTag:"</mark>"};function D(e){return function(e){return e&&w.test(e)?e.replace(b,function(e){return y[e]}):e}(e).replace(new RegExp(T.highlightPreTag,"g"),k.highlightPreTag).replace(new RegExp(T.highlightPostTag,"g"),k.highlightPostTag)}function F(e){return R(e)&&"string"!=typeof e.value?Object.keys(e).reduce(function(t,r){return I(I({},t),{},A({},r,F(e[r])))},{}):Array.isArray(e)?e.map(F):I(I({},e),{},{value:D(e.value)})}function N(e){return void 0===e.__escaped&&((e=e.map(function(e){var t=E({},(function(e){if(null==e)throw new TypeError("Cannot destructure "+e)}(e),e));return t._highlightResult&&(t._highlightResult=F(t._highlightResult)),t._snippetResult&&(t._snippetResult=F(t._snippetResult)),t})).__escaped=!0),e}function L(e){var t=k.highlightPreTag,r=k.highlightPostTag;return e.map(function(e){return e.isHighlighted?t+e.value+r:e.value}).join("")}function M(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function C(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?M(Object(r),!0).forEach(function(t){U(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):M(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function U(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==H(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==H(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===H(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function H(e){return H="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},H(e)}function q(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function W(e){var t=e.instantSearchInstance,r=e.helper,n=e.attribute,i=e.widgetType;return function(){for(var e=arguments.length,a=new Array(e),o=0;o<e;o++)a[o]=arguments[o];var s,c=a[1],u=a[2],f=void 0===u?"Filter Applied":u,l=a[3],h=void 0===l?{}:l,d=function(e){if(Array.isArray(e))return e}(s=a[0].split(":"))||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{for(a=(r=r.call(e)).next;!(c=(n=a.call(r)).done)&&(s.push(n.value),2!==s.length);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(s)||function(e,t){if(e){if("string"==typeof e)return q(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?q(e,2):void 0}}(s)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),p=d[0],v=d[1],m="string"==typeof n?n:n(c);if(1===a.length&&"object"===H(a[0]))t.sendEventToInsights(a[0]);else if("click"===p&&a.length>=2&&a.length<=4)(function(e,t,r){return e.state.isHierarchicalFacet(t)?e.state.isHierarchicalFacetRefined(t,r):e.state.isConjunctiveFacet(t)?e.state.isFacetRefined(t,r):e.state.isDisjunctiveFacetRefined(t,r)})(r,m,c)||t.sendEventToInsights({insightsMethod:"clickedFilters",widgetType:i,eventType:p,eventModifier:v,payload:C({eventName:f,index:r.getIndex(),filters:["".concat(m,":").concat(c)]},h),attribute:m});else if("development"==="production".NODE_ENV)throw new Error("You need to pass between two and four arguments like:\n  sendEvent('click', facetValue, eventName?, additionalData?);\n\nIf you want to send a custom payload, you can pass one object: sendEvent(customPayload);\n")}}function B(e){return btoa(encodeURIComponent(JSON.stringify(e)))}function V(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Q(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?V(Object(r),!0).forEach(function(t){$(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):V(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function $(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==K(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==K(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===K(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function G(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function K(e){return K="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},K(e)}function Y(e){var t=e.getIndex,r=e.widgetType,n=e.methodName,i=e.args,a=e.instantSearchInstance;if(1===i.length&&"object"===K(i[0]))return[i[0]];var o,s=function(e){if(Array.isArray(e))return e}(o=i[0].split(":"))||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{for(a=(r=r.call(e)).next;!(c=(n=a.call(r)).done)&&(s.push(n.value),2!==s.length);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(o)||function(e,t){if(e){if("string"==typeof e)return G(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?G(e,2):void 0}}(o)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),c=s[0],u=s[1],f=i[1],l=i[2],h=i[3]||{};if(!f){if("development"==="production".NODE_ENV)throw new Error("You need to pass hit or hits as the second argument like:\n  ".concat(n,"(eventType, hit);\n  "));return[]}if(("click"===c||"conversion"===c)&&!l){if("development"==="production".NODE_ENV)throw new Error("You need to pass eventName as the third argument for 'click' or 'conversion' events like:\n  ".concat(n,"('click', hit, 'Product Purchased');\n\n  To learn more about event naming: https://www.algolia.com/doc/guides/getting-insights-and-analytics/search-analytics/click-through-and-conversions/in-depth/clicks-conversions-best-practices/\n  "));return[]}var d=Array.isArray(f)?f:[f];if(0===d.length)return[];var p=d[0].__queryID,v=function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:20,r=[],n=0;n<Math.ceil(e.length/t);n++)r.push(e.slice(n*t,(n+1)*t));return r}(d),m=v.map(function(e){return e.map(function(e){return e.objectID})}),g=v.map(function(e){return e.map(function(e){return e.__position})});if("view"===c)return"idle"!==a.status?[]:v.map(function(e,n){return{insightsMethod:"viewedObjectIDs",widgetType:r,eventType:c,payload:Q({eventName:l||"Hits Viewed",index:t(),objectIDs:m[n]},h),hits:e,eventModifier:u}});if("click"===c)return v.map(function(e,n){return{insightsMethod:"clickedObjectIDsAfterSearch",widgetType:r,eventType:c,payload:Q({eventName:l||"Hit Clicked",index:t(),queryID:p,objectIDs:m[n],positions:g[n]},h),hits:e,eventModifier:u}});if("conversion"===c)return v.map(function(e,n){return{insightsMethod:"convertedObjectIDsAfterSearch",widgetType:r,eventType:c,payload:Q({eventName:l||"Hit Converted",index:t(),queryID:p,objectIDs:m[n]},h),hits:e,eventModifier:u}});if("development"==="production".NODE_ENV)throw new Error('eventType("'.concat(c,'") is not supported.\n    If you want to send a custom payload, you can pass one object: ').concat(n,"(customPayload);\n    "));return[]}function X(e){var t=e.instantSearchInstance,r=e.getIndex,n=e.widgetType,i={},a=void 0;return function(){for(var e=arguments.length,o=new Array(e),s=0;s<e;s++)o[s]=arguments[s];Y({widgetType:n,getIndex:r,methodName:"sendEvent",args:o,instantSearchInstance:t}).forEach(function(e){"click"===e.eventType&&"internal"===e.eventModifier&&i[e.eventType]||(i[e.eventType]=!0,t.sendEventToInsights(e))}),clearTimeout(a),a=setTimeout(function(){i={}},0)}}function J(e){var t=e.getIndex,r=e.widgetType,n=e.instantSearchInstance;return function(){for(var e=arguments.length,i=new Array(e),a=0;a<e;a++)i[a]=arguments[a];var o=Y({widgetType:r,getIndex:t,methodName:"bindEvent",args:i,instantSearchInstance:n});return o.length?"data-insights-event=".concat(B(o)):""}}function z(e){return"ais.index"===e.$$type}function Z(e,t){var r=e[t.getIndexId()]||{};"development"==="production".NODE_ENV&&p({index:t,indexUiState:r}),t.getHelper().setState(t.getWidgetSearchParameters(t.getHelper().state,{uiState:r})),t.getWidgets().filter(z).forEach(function(t){return Z(e,t)})}function ee(e,t){var r=null;return function(){for(var n=arguments.length,i=new Array(n),a=0;a<n;a++)i[a]=arguments[a];return new Promise(function(n,a){r&&clearTimeout(r),r=setTimeout(function(){r=null,Promise.resolve(e.apply(void 0,i)).then(n).catch(a)},t)})}}var te=Promise.resolve();function re(e){var t=null,r=!1,n=function(){for(var n=arguments.length,i=new Array(n),a=0;a<n;a++)i[a]=arguments[a];null===t&&(t=te.then(function(){t=null,r?r=!1:e.apply(void 0,i)}))};return n.wait=function(){if(null===t)throw new Error("The deferred function should be called before calling `wait()`");return t},n.cancel=function(){null!==t&&(r=!0)},n}function ne(e){var t=e.connector;return["https://www.algolia.com/doc/api-reference/widgets/",e.name,"/js/",void 0!==t&&t?"#connector":""].join("")}function ie(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];var n=t.map(function(e){return ne(e)}).join(", ");return function(e){return[e,"See documentation: ".concat(n)].filter(Boolean).join("\n\n")}}function ae(e){return"number"==typeof e&&e<0||"string"==typeof e?String(e).replace(/^-/,"\\-"):e}function oe(e,t){for(var r,n=0;n<e.length;n++)if(t(r=e[n],n,e))return r}function se(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{if(a=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;c=!1}else for(;!(c=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return ce(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?ce(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ce(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var ue=/^(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)$/;function fe(e){var t=k.highlightPostTag,r=e.split(k.highlightPreTag),n=r.shift(),i=n?[{value:n,isHighlighted:!1}]:[];return r.forEach(function(e){var r=e.split(t);i.push({value:r[0],isHighlighted:!0}),""!==r[1]&&i.push({value:r[1],isHighlighted:!1})}),i}var le=new RegExp(/\w/i);function he(e,t){var r,n,i,a=e[t],o=(null===(r=e[t+1])||void 0===r?void 0:r.isHighlighted)||!0,s=(null===(n=e[t-1])||void 0===n?void 0:n.isHighlighted)||!0;return le.test((i=a.value)&&j.test(i)?i.replace(O,function(e){return S[e]}):i)||s!==o?a.isHighlighted:s}function de(e,t){return(Array.isArray(t)?t:t.split(".")).reduce(function(e,t){return e&&e[t]},e)}function pe(e,t,r,n){var i,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:[],o={type:t,attribute:r,name:n,escapedValue:ae(n)},s=oe(a,function(e){return e.name===r});if("hierarchical"===t){for(var c=e.getHierarchicalFacetByName(r),u=n.split(c.separator),f=function(e){var t;s=s&&s.data&&oe(Object.keys(s.data).map((t=s.data,function(e){return t[e]})),function(t){return t.name===u[e]})},l=0;void 0!==s&&l<u.length;++l)f(l);i=s&&s.count}else i=s&&s.data&&s.data[o.name];return void 0!==i&&(o.count=i),s&&void 0!==s.exhaustive&&(o.exhaustive=s.exhaustive),o}function ve(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=[],i=t.facetsRefinements,a=void 0===i?{}:i,o=t.facetsExcludes,s=void 0===o?{}:o,c=t.disjunctiveFacetsRefinements,u=void 0===c?{}:c,f=t.hierarchicalFacetsRefinements,l=void 0===f?{}:f,h=t.numericRefinements,d=void 0===h?{}:h,p=t.tagRefinements,v=void 0===p?[]:p;return Object.keys(a).forEach(function(r){a[r].forEach(function(i){n.push(pe(t,"facet",r,i,e.facets))})}),Object.keys(s).forEach(function(e){s[e].forEach(function(t){n.push({type:"exclude",attribute:e,name:t,exclude:!0})})}),Object.keys(u).forEach(function(r){u[r].forEach(function(i){var a;n.push(pe(t,"disjunctive",r,"string"==typeof(a=i)?a.replace(/^\\-/,"-"):a,e.disjunctiveFacets))})}),Object.keys(l).forEach(function(r){l[r].forEach(function(i){n.push(pe(t,"hierarchical",r,i,e.hierarchicalFacets))})}),Object.keys(d).forEach(function(e){var t=d[e];Object.keys(t).forEach(function(r){var i=r,a=t[i];(Array.isArray(a)?a:[a]).forEach(function(t){n.push({type:"numeric",attribute:e,name:"".concat(t),numericValue:t,operator:i})})})}),v.forEach(function(e){n.push({type:"tag",attribute:"_tags",name:e})}),r&&t.query&&t.query.trim()&&n.push({attribute:"query",type:"query",name:t.query,query:t.query}),n}function me(e){return me="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},me(e)}function ge(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function ye(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ge(Object(r),!0).forEach(function(t){be(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ge(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function be(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==me(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==me(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===me(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function we(e,t,r){return e.map(function(e,n){return ye(ye({},e),{},{__position:r*t+n+1})})}function Se(e){return Se="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Se(e)}function Oe(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function je(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Oe(Object(r),!0).forEach(function(t){Pe(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Oe(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Pe(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Se(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Se(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Se(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Re(e,t){return t?e.map(function(e){return je(je({},e),{},{__queryID:t})}):e}function _e(e){return _e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_e(e)}function Ee(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function xe(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Ie(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?xe(Object(r),!0).forEach(function(t){Ae(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):xe(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Ae(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==_e(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==_e(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===_e(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Te(e){return Object.keys(e).map(function(t){return function(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];var i=0;return e.replace(/%s/g,function(){return encodeURIComponent(r[i++])})}("%s=%s",t,(r=e[t],"[object Object]"===Object.prototype.toString.call(r)||"[object Array]"===Object.prototype.toString.call(r)?JSON.stringify(e[t]):e[t]));var r}).join("&")}function ke(e){return e!==Object(e)}function De(e,t){if(e===t)return!0;if(ke(e)||ke(t)||"function"==typeof e||"function"==typeof t)return e===t;if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var r=0,n=Object.keys(e);r<n.length;r++){var i=n[r];if(!(i in t))return!1;if(!De(e[i],t[i]))return!1}return!0}function Fe(e){return"number"==typeof e&&isFinite(e)}function Ne(e,t){t(e),e.getWidgets().forEach(function(e){z(e)&&Ne(e,t)})}function Le(e){return e.filter(function(e,t,r){return r.indexOf(e)===t})}function Me(e){return Me="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Me(e)}var Ce=["facets","disjunctiveFacets","facetsRefinements","facetsExcludes","disjunctiveFacetsRefinements","numericRefinements","tagRefinements","hierarchicalFacets","hierarchicalFacetsRefinements","ruleContexts"];function Ue(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function He(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Ue(Object(r),!0).forEach(function(t){qe(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ue(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function qe(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Me(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Me(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Me(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var We=function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return t.reduce(function(e,t){var r=function(e,t){return e.setQueryParameters({hierarchicalFacetsRefinements:He(He({},e.hierarchicalFacetsRefinements),t.hierarchicalFacetsRefinements)})}(e,t),n=function(e,t){return t.tagRefinements.reduce(function(e,t){return e.addTagRefinement(t)},e)}(function(e,t){return e.setQueryParameters({hierarchicalFacets:t.hierarchicalFacets.reduce(function(e,t){var r=function(e,r){if(!Array.isArray(e))return-1;for(var n=0;n<e.length;n++)if(e[n].name===t.name)return n;return-1}(e);if(-1===r)return e.concat(t);var n=e.slice();return n.splice(r,1,t),n},e.hierarchicalFacets)})}(r,t),t),i=function(e,t){return e.setQueryParameters({numericRefinements:He(He({},e.numericRefinements),t.numericRefinements)})}(n,t),a=function(e,t){return e.setQueryParameters({disjunctiveFacetsRefinements:He(He({},e.disjunctiveFacetsRefinements),t.disjunctiveFacetsRefinements)})}(i,t),o=function(e,t){return e.setQueryParameters({facetsExcludes:He(He({},e.facetsExcludes),t.facetsExcludes)})}(a,t),s=function(e,t){return e.setQueryParameters({facetsRefinements:He(He({},e.facetsRefinements),t.facetsRefinements)})}(o,t),c=function(e,t){return t.disjunctiveFacets.reduce(function(e,t){return e.addDisjunctiveFacet(t)},e)}(s,t),u=function(e,t){var r=Le([].concat(e.ruleContexts).concat(t.ruleContexts).filter(Boolean));return r.length>0?e.setQueryParameters({ruleContexts:r}):e}(c,t),f=function(e,t){return t.facets.reduce(function(e,t){return e.addFacet(t)},e)}(u,t);return function(e,t){var r=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},a=Object.keys(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(t,Ce);return e.setQueryParameters(r)}(f,t)})};function Be(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Ve(e){var t,r=e.start,n=void 0===r?0:r,i=e.step,a=void 0===i?1:i,o=0===a?1:a,s=Math.round((e.end-n)/o);return(t=Array(s),function(e){if(Array.isArray(e))return Be(e)}(t)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||function(e,t){if(e){if("string"==typeof e)return Be(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Be(e,t):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).map(function(e,t){return n+t*o})}function Qe(e,t,r){var n=t.getHelper();return{uiState:r,helper:n,parent:t,instantSearchInstance:e,state:n.state,renderState:e.renderState,templatesConfig:e.templatesConfig,createURL:t.createURL,scopedResults:[],searchMetadata:{isSearchStalled:"stalled"===e.status},status:e.status,error:e.error}}function $e(e,t){var r=t.getResults(),n=t.getHelper();return{helper:n,parent:t,instantSearchInstance:e,results:r,scopedResults:t.getScopedResults(),state:r?r._state:n.state,renderState:e.renderState,templatesConfig:e.templatesConfig,createURL:t.createURL,searchMetadata:{isSearchStalled:"stalled"===e.status},status:e.status,error:e.error}}function Ge(e){return Ge="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ge(e)}function Ke(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Ye(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Ke(Object(r),!0).forEach(function(t){Xe(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ke(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Xe(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Ge(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Ge(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Ge(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Je(e){return e.some(function(e){return e.isHighlighted})?e.map(function(t,r){return Ye(Ye({},t),{},{isHighlighted:!he(e,r)})}):e.map(function(e){return Ye(Ye({},e),{},{isHighlighted:!1})})}function ze(e){return"undefined"==typeof window?(0,(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{fallback:function(){}}).fallback)():e({window:window})}function Ze(e){return Array.isArray(e)?e:[e]}var et=n("Highlight");function tt(e){var t=e.attribute,r=e.highlightedTagName,n=void 0===r?"mark":r,i=e.hit,a=e.cssClasses,o=void 0===a?{}:a;"development"==="production".NODE_ENV&&c(!1,"`instantsearch.highlight` function has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `Highlight` component.\n\nFor more information, visit https://www.algolia.com/doc/guides/building-search-ui/upgrade-guides/js/?client=html+tagged+templates#upgrade-templates");var s=de(i._highlightResult,t);"development"==="production".NODE_ENV&&c(s,'Could not enable highlight for "'.concat(t,'", will display an empty string.\nPlease check whether this attribute exists and is either searchable or specified in `attributesToHighlight`.\n\nSee: https://alg.li/highlighting\n'));var u=(s||{}).value,f=void 0===u?"":u,l=et({descendantName:"highlighted"})+(o.highlighted?" ".concat(o.highlighted):"");return f.replace(new RegExp(k.highlightPreTag,"g"),"<".concat(n,' class="').concat(l,'">')).replace(new RegExp(k.highlightPostTag,"g"),"</".concat(n,">"))}var rt=n("ReverseHighlight");function nt(e){var t=e.attribute,r=e.highlightedTagName,n=void 0===r?"mark":r,i=e.hit,a=e.cssClasses,o=void 0===a?{}:a;"development"==="production".NODE_ENV&&c(!1,"`instantsearch.reverseHighlight` function has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `ReverseHighlight` component.\n\nFor more information, visit https://www.algolia.com/doc/guides/building-search-ui/upgrade-guides/js/?client=html+tagged+templates#upgrade-templates");var s=de(i._highlightResult,t);"development"==="production".NODE_ENV&&c(s,'Could not enable reverse highlight for "'.concat(t,'", will display an empty string.\nPlease check whether this attribute exists and is either searchable or specified in `attributesToHighlight`.\n\nSee: https://alg.li/highlighting\n'));var u=(s||{}).value,f=void 0===u?"":u,l=rt({descendantName:"highlighted"})+(o.highlighted?" ".concat(o.highlighted):"");return L(Je(fe(f))).replace(new RegExp(k.highlightPreTag,"g"),"<".concat(n,' class="').concat(l,'">')).replace(new RegExp(k.highlightPostTag,"g"),"</".concat(n,">"))}var it=n("Snippet");function at(e){var t=e.attribute,r=e.highlightedTagName,n=void 0===r?"mark":r,i=e.hit,a=e.cssClasses,o=void 0===a?{}:a;"development"==="production".NODE_ENV&&c(!1,"`instantsearch.snippet` function has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `Snippet` component.\n\nFor more information, visit https://www.algolia.com/doc/guides/building-search-ui/upgrade-guides/js/?client=html+tagged+templates#upgrade-templates");var s=de(i._snippetResult,t);"development"==="production".NODE_ENV&&c(s,'Could not enable snippet for "'.concat(t,'", will display an empty string.\nPlease check whether this attribute exists and is specified in `attributesToSnippet`.\n\nSee: https://alg.li/highlighting\n'));var u=(s||{}).value,f=void 0===u?"":u,l=it({descendantName:"highlighted"})+(o.highlighted?" ".concat(o.highlighted):"");return f.replace(new RegExp(k.highlightPreTag,"g"),"<".concat(n,' class="').concat(l,'">')).replace(new RegExp(k.highlightPostTag,"g"),"</".concat(n,">"))}var ot=n("ReverseSnippet");function st(e){var t=e.attribute,r=e.highlightedTagName,n=void 0===r?"mark":r,i=e.hit,a=e.cssClasses,o=void 0===a?{}:a;"development"==="production".NODE_ENV&&c(!1,"`instantsearch.reverseSnippet` function has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `ReverseSnippet` component.\n\nFor more information, visit https://www.algolia.com/doc/guides/building-search-ui/upgrade-guides/js/?client=html+tagged+templates#upgrade-templates");var s=de(i._snippetResult,t);"development"==="production".NODE_ENV&&c(s,'Could not enable reverse snippet for "'.concat(t,'", will display an empty string.\nPlease check whether this attribute exists and is specified in `attributesToSnippet`.\n\nSee: https://alg.li/highlighting\n'));var u=(s||{}).value,f=void 0===u?"":u,l=ot({descendantName:"highlighted"})+(o.highlighted?" ".concat(o.highlighted):"");return L(Je(fe(f))).replace(new RegExp(k.highlightPreTag,"g"),"<".concat(n,' class="').concat(l,'">')).replace(new RegExp(k.highlightPostTag,"g"),"</".concat(n,">"))}function ct(e){return ct="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ct(e)}function ut(e,t){return"development"==="production".NODE_ENV&&c(!1,"`insights` function has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `insights` middleware.\n\nFor more information, visit https://www.algolia.com/doc/guides/getting-insights-and-analytics/search-analytics/click-through-and-conversions/how-to/send-click-and-conversion-events-with-instantsearch/js/"),function(e){var t,r=e.method,n=e.payload;if("object"!==ct(n))throw new Error("The insights helper expects the payload to be an object.");try{t=B(n)}catch(e){throw new Error("Could not JSON serialize the payload object.")}return'data-insights-method="'.concat(r,'" data-insights-payload="').concat(t,'"')}({method:e,payload:t})}function ft(e){return ft="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ft(e)}var lt="_ALGOLIA";function ht(){return function(e){if("object"===("undefined"==typeof document?"undefined":ft(document))&&"string"==typeof document.cookie)for(var t="".concat(e,"="),r=document.cookie.split(";"),n=0;n<r.length;n++){for(var i=r[n];" "===i.charAt(0);)i=i.substring(1);if(0===i.indexOf(t))return i.substring(t.length,i.length)}}(lt)}var dt=["page"];function pt(e){return function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},a=Object.keys(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e||{},dt)}var vt="ais.infiniteHits";function mt(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0}var gt=mt;function yt(e){return"function"==typeof e}function bt(e){return"object"==typeof e&&null!==e}function wt(e){return void 0===e}mt.prototype._events=void 0,mt.prototype._maxListeners=void 0,mt.defaultMaxListeners=10,mt.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||isNaN(e))throw TypeError("n must be a positive number");return this._maxListeners=e,this},mt.prototype.emit=function(e){var t,r,n,i,a,o;if(this._events||(this._events={}),"error"===e&&(!this._events.error||bt(this._events.error)&&!this._events.error.length)){if((t=arguments[1])instanceof Error)throw t;var s=new Error('Uncaught, unspecified "error" event. ('+t+")");throw s.context=t,s}if(wt(r=this._events[e]))return!1;if(yt(r))switch(arguments.length){case 1:r.call(this);break;case 2:r.call(this,arguments[1]);break;case 3:r.call(this,arguments[1],arguments[2]);break;default:i=Array.prototype.slice.call(arguments,1),r.apply(this,i)}else if(bt(r))for(i=Array.prototype.slice.call(arguments,1),n=(o=r.slice()).length,a=0;a<n;a++)o[a].apply(this,i);return!0},mt.prototype.on=mt.prototype.addListener=function(e,t){var r;if(!yt(t))throw TypeError("listener must be a function");return this._events||(this._events={}),this._events.newListener&&this.emit("newListener",e,yt(t.listener)?t.listener:t),this._events[e]?bt(this._events[e])?this._events[e].push(t):this._events[e]=[this._events[e],t]:this._events[e]=t,bt(this._events[e])&&!this._events[e].warned&&(r=wt(this._maxListeners)?mt.defaultMaxListeners:this._maxListeners)&&r>0&&this._events[e].length>r&&(this._events[e].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[e].length),"function"==typeof console.trace&&console.trace()),this},mt.prototype.once=function(e,t){if(!yt(t))throw TypeError("listener must be a function");var r=!1;function n(){this.removeListener(e,n),r||(r=!0,t.apply(this,arguments))}return n.listener=t,this.on(e,n),this},mt.prototype.removeListener=function(e,t){var r,n,i,a;if(!yt(t))throw TypeError("listener must be a function");if(!this._events||!this._events[e])return this;if(i=(r=this._events[e]).length,n=-1,r===t||yt(r.listener)&&r.listener===t)delete this._events[e],this._events.removeListener&&this.emit("removeListener",e,t);else if(bt(r)){for(a=i;a-- >0;)if(r[a]===t||r[a].listener&&r[a].listener===t){n=a;break}if(n<0)return this;1===r.length?(r.length=0,delete this._events[e]):r.splice(n,1),this._events.removeListener&&this.emit("removeListener",e,t)}return this},mt.prototype.removeAllListeners=function(e){var t,r;if(!this._events)return this;if(!this._events.removeListener)return 0===arguments.length?this._events={}:this._events[e]&&delete this._events[e],this;if(0===arguments.length){for(t in this._events)"removeListener"!==t&&this.removeAllListeners(t);return this.removeAllListeners("removeListener"),this._events={},this}if(yt(r=this._events[e]))this.removeListener(e,r);else if(r)for(;r.length;)this.removeListener(e,r[r.length-1]);return delete this._events[e],this},mt.prototype.listeners=function(e){return this._events&&this._events[e]?yt(this._events[e])?[this._events[e]]:this._events[e].slice():[]},mt.prototype.listenerCount=function(e){if(this._events){var t=this._events[e];if(yt(t))return 1;if(t)return t.length}return 0},mt.listenerCount=function(e,t){return e.listenerCount(t)};var St=function(e,t){e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})};function Ot(e,t){this.main=e,this.fn=t,this.lastResults=null}St(Ot,gt),Ot.prototype.detach=function(){this.removeAllListeners(),this.main.detachDerivedHelper(this)},Ot.prototype.getModifiedState=function(e){return this.fn(e)};var jt=Ot,Pt=function(e){return"string"!=typeof e?e:String(e).replace(/^-/,"\\-")},Rt=function(e){return"string"!=typeof e?e:e.replace(/^\\-/,"-")};function _t(e){return"function"==typeof e||Array.isArray(e)||"[object Object]"===Object.prototype.toString.call(e)}function Et(e,t){if(e===t)return e;for(var r in t)if(Object.prototype.hasOwnProperty.call(t,r)&&"__proto__"!==r&&"constructor"!==r){var n=t[r],i=e[r];void 0!==i&&void 0===n||(e[r]=_t(i)&&_t(n)?Et(i,n):"object"==typeof(a=n)&&null!==a?Et(Array.isArray(a)?[]:{},a):a)}var a;return e}var xt=function(e){_t(e)||(e={});for(var t=1,r=arguments.length;t<r;t++){var n=arguments[t];_t(n)&&Et(e,n)}return e},It=function(e){return e&&Object.keys(e).length>0},At=function(e,t){if(null===e)return{};var r,n,i={},a=Object.keys(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||(i[r]=e[r]);return i};function Tt(e){return Object.keys(e).sort().reduce(function(t,r){return t[r]=e[r],t},{})}var kt={_getQueries:function(e,t){var r=[];return r.push({indexName:e,params:kt._getHitsSearchParams(t)}),t.getRefinedDisjunctiveFacets().forEach(function(n){r.push({indexName:e,params:kt._getDisjunctiveFacetSearchParams(t,n)})}),t.getRefinedHierarchicalFacets().forEach(function(n){var i=t.getHierarchicalFacetByName(n),a=t.getHierarchicalRefinement(n),o=t._getHierarchicalFacetSeparator(i);if(a.length>0&&a[0].split(o).length>1){var s=a[0].split(o).slice(0,-1).reduce(function(e,t,r){return e.concat({attribute:i.attributes[r],value:0===r?t:[e[e.length-1].value,t].join(o)})},[]);s.forEach(function(n,a){var o=kt._getDisjunctiveFacetSearchParams(t,n.attribute,0===a);function c(e){return i.attributes.some(function(t){return t===e.split(":")[0]})}var u=(o.facetFilters||[]).reduce(function(e,t){if(Array.isArray(t)){var r=t.filter(function(e){return!c(e)});r.length>0&&e.push(r)}return"string"!=typeof t||c(t)||e.push(t),e},[]),f=s[a-1];o.facetFilters=a>0?u.concat(f.attribute+":"+f.value):u.length>0?u:void 0,r.push({indexName:e,params:o})})}}),r},_getHitsSearchParams:function(e){var t=e.facets.concat(e.disjunctiveFacets).concat(kt._getHitsHierarchicalFacetsAttributes(e)).sort(),r=kt._getFacetFilters(e),n=kt._getNumericFilters(e),i=kt._getTagFilters(e),a={facets:t.indexOf("*")>-1?["*"]:t,tagFilters:i};return r.length>0&&(a.facetFilters=r),n.length>0&&(a.numericFilters=n),Tt(xt({},e.getQueryParams(),a))},_getDisjunctiveFacetSearchParams:function(e,t,r){var n=kt._getFacetFilters(e,t,r),i=kt._getNumericFilters(e,t),a=kt._getTagFilters(e),o={hitsPerPage:0,page:0,analytics:!1,clickAnalytics:!1};a.length>0&&(o.tagFilters=a);var s=e.getHierarchicalFacetByName(t);return o.facets=s?kt._getDisjunctiveHierarchicalFacetAttribute(e,s,r):t,i.length>0&&(o.numericFilters=i),n.length>0&&(o.facetFilters=n),Tt(xt({},e.getQueryParams(),o))},_getNumericFilters:function(e,t){if(e.numericFilters)return e.numericFilters;var r=[];return Object.keys(e.numericRefinements).forEach(function(n){var i=e.numericRefinements[n]||{};Object.keys(i).forEach(function(e){t!==n&&(i[e]||[]).forEach(function(t){if(Array.isArray(t)){var i=t.map(function(t){return n+e+t});r.push(i)}else r.push(n+e+t)})})}),r},_getTagFilters:function(e){return e.tagFilters?e.tagFilters:e.tagRefinements.join(",")},_getFacetFilters:function(e,t,r){var n=[],i=e.facetsRefinements||{};Object.keys(i).sort().forEach(function(e){(i[e]||[]).slice().sort().forEach(function(t){n.push(e+":"+t)})});var a=e.facetsExcludes||{};Object.keys(a).sort().forEach(function(e){(a[e]||[]).sort().forEach(function(t){n.push(e+":-"+t)})});var o=e.disjunctiveFacetsRefinements||{};Object.keys(o).sort().forEach(function(e){var r=o[e]||[];if(e!==t&&r&&0!==r.length){var i=[];r.slice().sort().forEach(function(t){i.push(e+":"+t)}),n.push(i)}});var s=e.hierarchicalFacetsRefinements||{};return Object.keys(s).sort().forEach(function(i){var a=(s[i]||[])[0];if(void 0!==a){var o,c,u=e.getHierarchicalFacetByName(i),f=e._getHierarchicalFacetSeparator(u),l=e._getHierarchicalRootPath(u);if(t===i){if(-1===a.indexOf(f)||!l&&!0===r||l&&l.split(f).length===a.split(f).length)return;l?(c=l.split(f).length-1,a=l):(c=a.split(f).length-2,a=a.slice(0,a.lastIndexOf(f))),o=u.attributes[c]}else c=a.split(f).length-1,o=u.attributes[c];o&&n.push([o+":"+a])}}),n},_getHitsHierarchicalFacetsAttributes:function(e){return e.hierarchicalFacets.reduce(function(t,r){var n=e.getHierarchicalRefinement(r.name)[0];if(!n)return t.push(r.attributes[0]),t;var i=e._getHierarchicalFacetSeparator(r),a=n.split(i).length,o=r.attributes.slice(0,a+1);return t.concat(o)},[])},_getDisjunctiveHierarchicalFacetAttribute:function(e,t,r){var n=e._getHierarchicalFacetSeparator(t);if(!0===r){var i=e._getHierarchicalRootPath(t),a=0;return i&&(a=i.split(n).length),[t.attributes[a]]}var o=(e.getHierarchicalRefinement(t.name)[0]||"").split(n).length-1;return t.attributes.slice(0,o+1)},getSearchForFacetQuery:function(e,t,r,n){var i=n.isDisjunctiveFacet(e)?n.clearRefinements(e):n,a={facetQuery:t,facetName:e};return"number"==typeof r&&(a.maxFacetHits=r),Tt(xt({},kt._getHitsSearchParams(i),a))}},Dt=kt,Ft=function(){return Array.prototype.slice.call(arguments).reduceRight(function(e,t){return Object.keys(Object(t)).forEach(function(r){void 0!==t[r]&&(void 0!==e[r]&&delete e[r],e[r]=t[r])}),e},{})},Nt=function(e,t){if(Array.isArray(e))for(var r=0;r<e.length;r++)if(t(e[r]))return e[r]},Lt=function(e,t){return e.filter(function(r,n){return t.indexOf(r)>-1&&e.indexOf(r)===n})},Mt=function e(t){if("number"==typeof t)return t;if("string"==typeof t)return parseFloat(t);if(Array.isArray(t))return t.map(e);throw new Error("The value should be a number, a parsable string or an array of those.")},Ct={addRefinement:function(e,t,r){if(Ct.isRefined(e,t,r))return e;var n=""+r,i=e[t]?e[t].concat(n):[n],a={};return a[t]=i,Ft({},a,e)},removeRefinement:function(e,t,r){if(void 0===r)return Ct.clearRefinement(e,function(e,r){return t===r});var n=""+r;return Ct.clearRefinement(e,function(e,r){return t===r&&n===e})},toggleRefinement:function(e,t,r){if(void 0===r)throw new Error("toggleRefinement should be used with a value");return Ct.isRefined(e,t,r)?Ct.removeRefinement(e,t,r):Ct.addRefinement(e,t,r)},clearRefinement:function(e,t,r){if(void 0===t)return It(e)?{}:e;if("string"==typeof t)return At(e,[t]);if("function"==typeof t){var n=!1,i=Object.keys(e).reduce(function(i,a){var o=e[a]||[],s=o.filter(function(e){return!t(e,a,r)});return s.length!==o.length&&(n=!0),i[a]=s,i},{});return n?i:e}},isRefined:function(e,t,r){var n=Boolean(e[t])&&e[t].length>0;return void 0!==r&&n?-1!==e[t].indexOf(""+r):n}},Ut=Ct;function Ht(e,t){return Array.isArray(e)&&Array.isArray(t)?e.length===t.length&&e.every(function(e,r){return Ht(t[r],e)}):e===t}function qt(e){var t,r=e?qt._parseNumbers(e):{};void 0===r.userToken||null!==(t=r.userToken)&&/^[a-zA-Z0-9_-]{1,64}$/.test(t)||console.warn("[algoliasearch-helper] The `userToken` parameter is invalid. This can lead to wrong analytics.\n  - Format: [a-zA-Z0-9_-]{1,64}"),this.facets=r.facets||[],this.disjunctiveFacets=r.disjunctiveFacets||[],this.hierarchicalFacets=r.hierarchicalFacets||[],this.facetsRefinements=r.facetsRefinements||{},this.facetsExcludes=r.facetsExcludes||{},this.disjunctiveFacetsRefinements=r.disjunctiveFacetsRefinements||{},this.numericRefinements=r.numericRefinements||{},this.tagRefinements=r.tagRefinements||[],this.hierarchicalFacetsRefinements=r.hierarchicalFacetsRefinements||{};var n=this;Object.keys(r).forEach(function(e){-1===qt.PARAMETERS.indexOf(e)&&void 0!==r[e]&&(n[e]=r[e])})}qt.PARAMETERS=Object.keys(new qt),qt._parseNumbers=function(e){if(e instanceof qt)return e;var t={};if(["aroundPrecision","aroundRadius","getRankingInfo","minWordSizefor2Typos","minWordSizefor1Typo","page","maxValuesPerFacet","distinct","minimumAroundRadius","hitsPerPage","minProximity"].forEach(function(r){var n=e[r];if("string"==typeof n){var i=parseFloat(n);t[r]=isNaN(i)?n:i}}),Array.isArray(e.insideBoundingBox)&&(t.insideBoundingBox=e.insideBoundingBox.map(function(e){return Array.isArray(e)?e.map(function(e){return parseFloat(e)}):e})),e.numericRefinements){var r={};Object.keys(e.numericRefinements).forEach(function(t){var n=e.numericRefinements[t]||{};r[t]={},Object.keys(n).forEach(function(e){var i=n[e].map(function(e){return Array.isArray(e)?e.map(function(e){return"string"==typeof e?parseFloat(e):e}):"string"==typeof e?parseFloat(e):e});r[t][e]=i})}),t.numericRefinements=r}return xt(e,t)},qt.make=function(e){var t=new qt(e);return(e.hierarchicalFacets||[]).forEach(function(e){if(e.rootPath){var r=t.getHierarchicalRefinement(e.name);r.length>0&&0!==r[0].indexOf(e.rootPath)&&(t=t.clearRefinements(e.name)),0===(r=t.getHierarchicalRefinement(e.name)).length&&(t=t.toggleHierarchicalFacetRefinement(e.name,e.rootPath))}}),t},qt.validate=function(e,t){var r=t||{};return e.tagFilters&&r.tagRefinements&&r.tagRefinements.length>0?new Error("[Tags] Cannot switch from the managed tag API to the advanced API. It is probably an error, if it is really what you want, you should first clear the tags with clearTags method."):e.tagRefinements.length>0&&r.tagFilters?new Error("[Tags] Cannot switch from the advanced tag API to the managed API. It is probably an error, if it is not, you should first clear the tags with clearTags method."):e.numericFilters&&r.numericRefinements&&It(r.numericRefinements)?new Error("[Numeric filters] Can't switch from the advanced to the managed API. It is probably an error, if this is really what you want, you have to first clear the numeric filters."):It(e.numericRefinements)&&r.numericFilters?new Error("[Numeric filters] Can't switch from the managed API to the advanced. It is probably an error, if this is really what you want, you have to first clear the numeric filters."):null},qt.prototype={constructor:qt,clearRefinements:function(e){var t={numericRefinements:this._clearNumericRefinements(e),facetsRefinements:Ut.clearRefinement(this.facetsRefinements,e,"conjunctiveFacet"),facetsExcludes:Ut.clearRefinement(this.facetsExcludes,e,"exclude"),disjunctiveFacetsRefinements:Ut.clearRefinement(this.disjunctiveFacetsRefinements,e,"disjunctiveFacet"),hierarchicalFacetsRefinements:Ut.clearRefinement(this.hierarchicalFacetsRefinements,e,"hierarchicalFacet")};return t.numericRefinements===this.numericRefinements&&t.facetsRefinements===this.facetsRefinements&&t.facetsExcludes===this.facetsExcludes&&t.disjunctiveFacetsRefinements===this.disjunctiveFacetsRefinements&&t.hierarchicalFacetsRefinements===this.hierarchicalFacetsRefinements?this:this.setQueryParameters(t)},clearTags:function(){return void 0===this.tagFilters&&0===this.tagRefinements.length?this:this.setQueryParameters({tagFilters:void 0,tagRefinements:[]})},setIndex:function(e){return e===this.index?this:this.setQueryParameters({index:e})},setQuery:function(e){return e===this.query?this:this.setQueryParameters({query:e})},setPage:function(e){return e===this.page?this:this.setQueryParameters({page:e})},setFacets:function(e){return this.setQueryParameters({facets:e})},setDisjunctiveFacets:function(e){return this.setQueryParameters({disjunctiveFacets:e})},setHitsPerPage:function(e){return this.hitsPerPage===e?this:this.setQueryParameters({hitsPerPage:e})},setTypoTolerance:function(e){return this.typoTolerance===e?this:this.setQueryParameters({typoTolerance:e})},addNumericRefinement:function(e,t,r){var n=Mt(r);if(this.isNumericRefined(e,t,n))return this;var i=xt({},this.numericRefinements);return i[e]=xt({},i[e]),i[e][t]?(i[e][t]=i[e][t].slice(),i[e][t].push(n)):i[e][t]=[n],this.setQueryParameters({numericRefinements:i})},getConjunctiveRefinements:function(e){return this.isConjunctiveFacet(e)&&this.facetsRefinements[e]||[]},getDisjunctiveRefinements:function(e){return this.isDisjunctiveFacet(e)&&this.disjunctiveFacetsRefinements[e]||[]},getHierarchicalRefinement:function(e){return this.hierarchicalFacetsRefinements[e]||[]},getExcludeRefinements:function(e){return this.isConjunctiveFacet(e)&&this.facetsExcludes[e]||[]},removeNumericRefinement:function(e,t,r){var n=r;return void 0!==n?this.isNumericRefined(e,t,n)?this.setQueryParameters({numericRefinements:this._clearNumericRefinements(function(r,i){return i===e&&r.op===t&&Ht(r.val,Mt(n))})}):this:void 0!==t?this.isNumericRefined(e,t)?this.setQueryParameters({numericRefinements:this._clearNumericRefinements(function(r,n){return n===e&&r.op===t})}):this:this.isNumericRefined(e)?this.setQueryParameters({numericRefinements:this._clearNumericRefinements(function(t,r){return r===e})}):this},getNumericRefinements:function(e){return this.numericRefinements[e]||{}},getNumericRefinement:function(e,t){return this.numericRefinements[e]&&this.numericRefinements[e][t]},_clearNumericRefinements:function(e){if(void 0===e)return It(this.numericRefinements)?{}:this.numericRefinements;if("string"==typeof e)return At(this.numericRefinements,[e]);if("function"==typeof e){var t=!1,r=this.numericRefinements,n=Object.keys(r).reduce(function(n,i){var a=r[i],o={};return a=a||{},Object.keys(a).forEach(function(r){var n=a[r]||[],s=[];n.forEach(function(t){e({val:t,op:r},i,"numeric")||s.push(t)}),s.length!==n.length&&(t=!0),o[r]=s}),n[i]=o,n},{});return t?n:this.numericRefinements}},addFacet:function(e){return this.isConjunctiveFacet(e)?this:this.setQueryParameters({facets:this.facets.concat([e])})},addDisjunctiveFacet:function(e){return this.isDisjunctiveFacet(e)?this:this.setQueryParameters({disjunctiveFacets:this.disjunctiveFacets.concat([e])})},addHierarchicalFacet:function(e){if(this.isHierarchicalFacet(e.name))throw new Error("Cannot declare two hierarchical facets with the same name: `"+e.name+"`");return this.setQueryParameters({hierarchicalFacets:this.hierarchicalFacets.concat([e])})},addFacetRefinement:function(e,t){if(!this.isConjunctiveFacet(e))throw new Error(e+" is not defined in the facets attribute of the helper configuration");return Ut.isRefined(this.facetsRefinements,e,t)?this:this.setQueryParameters({facetsRefinements:Ut.addRefinement(this.facetsRefinements,e,t)})},addExcludeRefinement:function(e,t){if(!this.isConjunctiveFacet(e))throw new Error(e+" is not defined in the facets attribute of the helper configuration");return Ut.isRefined(this.facetsExcludes,e,t)?this:this.setQueryParameters({facetsExcludes:Ut.addRefinement(this.facetsExcludes,e,t)})},addDisjunctiveFacetRefinement:function(e,t){if(!this.isDisjunctiveFacet(e))throw new Error(e+" is not defined in the disjunctiveFacets attribute of the helper configuration");return Ut.isRefined(this.disjunctiveFacetsRefinements,e,t)?this:this.setQueryParameters({disjunctiveFacetsRefinements:Ut.addRefinement(this.disjunctiveFacetsRefinements,e,t)})},addTagRefinement:function(e){if(this.isTagRefined(e))return this;var t={tagRefinements:this.tagRefinements.concat(e)};return this.setQueryParameters(t)},removeFacet:function(e){return this.isConjunctiveFacet(e)?this.clearRefinements(e).setQueryParameters({facets:this.facets.filter(function(t){return t!==e})}):this},removeDisjunctiveFacet:function(e){return this.isDisjunctiveFacet(e)?this.clearRefinements(e).setQueryParameters({disjunctiveFacets:this.disjunctiveFacets.filter(function(t){return t!==e})}):this},removeHierarchicalFacet:function(e){return this.isHierarchicalFacet(e)?this.clearRefinements(e).setQueryParameters({hierarchicalFacets:this.hierarchicalFacets.filter(function(t){return t.name!==e})}):this},removeFacetRefinement:function(e,t){if(!this.isConjunctiveFacet(e))throw new Error(e+" is not defined in the facets attribute of the helper configuration");return Ut.isRefined(this.facetsRefinements,e,t)?this.setQueryParameters({facetsRefinements:Ut.removeRefinement(this.facetsRefinements,e,t)}):this},removeExcludeRefinement:function(e,t){if(!this.isConjunctiveFacet(e))throw new Error(e+" is not defined in the facets attribute of the helper configuration");return Ut.isRefined(this.facetsExcludes,e,t)?this.setQueryParameters({facetsExcludes:Ut.removeRefinement(this.facetsExcludes,e,t)}):this},removeDisjunctiveFacetRefinement:function(e,t){if(!this.isDisjunctiveFacet(e))throw new Error(e+" is not defined in the disjunctiveFacets attribute of the helper configuration");return Ut.isRefined(this.disjunctiveFacetsRefinements,e,t)?this.setQueryParameters({disjunctiveFacetsRefinements:Ut.removeRefinement(this.disjunctiveFacetsRefinements,e,t)}):this},removeTagRefinement:function(e){if(!this.isTagRefined(e))return this;var t={tagRefinements:this.tagRefinements.filter(function(t){return t!==e})};return this.setQueryParameters(t)},toggleRefinement:function(e,t){return this.toggleFacetRefinement(e,t)},toggleFacetRefinement:function(e,t){if(this.isHierarchicalFacet(e))return this.toggleHierarchicalFacetRefinement(e,t);if(this.isConjunctiveFacet(e))return this.toggleConjunctiveFacetRefinement(e,t);if(this.isDisjunctiveFacet(e))return this.toggleDisjunctiveFacetRefinement(e,t);throw new Error("Cannot refine the undeclared facet "+e+"; it should be added to the helper options facets, disjunctiveFacets or hierarchicalFacets")},toggleConjunctiveFacetRefinement:function(e,t){if(!this.isConjunctiveFacet(e))throw new Error(e+" is not defined in the facets attribute of the helper configuration");return this.setQueryParameters({facetsRefinements:Ut.toggleRefinement(this.facetsRefinements,e,t)})},toggleExcludeFacetRefinement:function(e,t){if(!this.isConjunctiveFacet(e))throw new Error(e+" is not defined in the facets attribute of the helper configuration");return this.setQueryParameters({facetsExcludes:Ut.toggleRefinement(this.facetsExcludes,e,t)})},toggleDisjunctiveFacetRefinement:function(e,t){if(!this.isDisjunctiveFacet(e))throw new Error(e+" is not defined in the disjunctiveFacets attribute of the helper configuration");return this.setQueryParameters({disjunctiveFacetsRefinements:Ut.toggleRefinement(this.disjunctiveFacetsRefinements,e,t)})},toggleHierarchicalFacetRefinement:function(e,t){if(!this.isHierarchicalFacet(e))throw new Error(e+" is not defined in the hierarchicalFacets attribute of the helper configuration");var r=this._getHierarchicalFacetSeparator(this.getHierarchicalFacetByName(e)),n={},i=void 0!==this.hierarchicalFacetsRefinements[e]&&this.hierarchicalFacetsRefinements[e].length>0&&(this.hierarchicalFacetsRefinements[e][0]===t||0===this.hierarchicalFacetsRefinements[e][0].indexOf(t+r));return n[e]=i?-1===t.indexOf(r)?[]:[t.slice(0,t.lastIndexOf(r))]:[t],this.setQueryParameters({hierarchicalFacetsRefinements:Ft({},n,this.hierarchicalFacetsRefinements)})},addHierarchicalFacetRefinement:function(e,t){if(this.isHierarchicalFacetRefined(e))throw new Error(e+" is already refined.");if(!this.isHierarchicalFacet(e))throw new Error(e+" is not defined in the hierarchicalFacets attribute of the helper configuration.");var r={};return r[e]=[t],this.setQueryParameters({hierarchicalFacetsRefinements:Ft({},r,this.hierarchicalFacetsRefinements)})},removeHierarchicalFacetRefinement:function(e){if(!this.isHierarchicalFacetRefined(e))return this;var t={};return t[e]=[],this.setQueryParameters({hierarchicalFacetsRefinements:Ft({},t,this.hierarchicalFacetsRefinements)})},toggleTagRefinement:function(e){return this.isTagRefined(e)?this.removeTagRefinement(e):this.addTagRefinement(e)},isDisjunctiveFacet:function(e){return this.disjunctiveFacets.indexOf(e)>-1},isHierarchicalFacet:function(e){return void 0!==this.getHierarchicalFacetByName(e)},isConjunctiveFacet:function(e){return this.facets.indexOf(e)>-1},isFacetRefined:function(e,t){return!!this.isConjunctiveFacet(e)&&Ut.isRefined(this.facetsRefinements,e,t)},isExcludeRefined:function(e,t){return!!this.isConjunctiveFacet(e)&&Ut.isRefined(this.facetsExcludes,e,t)},isDisjunctiveFacetRefined:function(e,t){return!!this.isDisjunctiveFacet(e)&&Ut.isRefined(this.disjunctiveFacetsRefinements,e,t)},isHierarchicalFacetRefined:function(e,t){if(!this.isHierarchicalFacet(e))return!1;var r=this.getHierarchicalRefinement(e);return t?-1!==r.indexOf(t):r.length>0},isNumericRefined:function(e,t,r){if(void 0===r&&void 0===t)return Boolean(this.numericRefinements[e]);var n=this.numericRefinements[e]&&void 0!==this.numericRefinements[e][t];if(void 0===r||!n)return n;var i,a=Mt(r),o=void 0!==(i=a,Nt(this.numericRefinements[e][t],function(e){return Ht(e,i)}));return n&&o},isTagRefined:function(e){return-1!==this.tagRefinements.indexOf(e)},getRefinedDisjunctiveFacets:function(){var e=this,t=Lt(Object.keys(this.numericRefinements).filter(function(t){return Object.keys(e.numericRefinements[t]).length>0}),this.disjunctiveFacets);return Object.keys(this.disjunctiveFacetsRefinements).filter(function(t){return e.disjunctiveFacetsRefinements[t].length>0}).concat(t).concat(this.getRefinedHierarchicalFacets()).sort()},getRefinedHierarchicalFacets:function(){var e=this;return Lt(this.hierarchicalFacets.map(function(e){return e.name}),Object.keys(this.hierarchicalFacetsRefinements).filter(function(t){return e.hierarchicalFacetsRefinements[t].length>0})).sort()},getUnrefinedDisjunctiveFacets:function(){var e=this.getRefinedDisjunctiveFacets();return this.disjunctiveFacets.filter(function(t){return-1===e.indexOf(t)})},managedParameters:["index","facets","disjunctiveFacets","facetsRefinements","hierarchicalFacets","facetsExcludes","disjunctiveFacetsRefinements","numericRefinements","tagRefinements","hierarchicalFacetsRefinements"],getQueryParams:function(){var e=this.managedParameters,t={},r=this;return Object.keys(this).forEach(function(n){var i=r[n];-1===e.indexOf(n)&&void 0!==i&&(t[n]=i)}),t},setQueryParameter:function(e,t){if(this[e]===t)return this;var r={};return r[e]=t,this.setQueryParameters(r)},setQueryParameters:function(e){if(!e)return this;var t=qt.validate(this,e);if(t)throw t;var r=this,n=qt._parseNumbers(e),i=Object.keys(this).reduce(function(e,t){return e[t]=r[t],e},{}),a=Object.keys(n).reduce(function(e,t){var r=void 0!==n[t];return void 0===e[t]||r?(r&&(e[t]=n[t]),e):At(e,[t])},i);return new this.constructor(a)},resetPage:function(){return void 0===this.page?this:this.setPage(0)},_getHierarchicalFacetSortBy:function(e){return e.sortBy||["isRefined:desc","name:asc"]},_getHierarchicalFacetSeparator:function(e){return e.separator||" > "},_getHierarchicalRootPath:function(e){return e.rootPath||null},_getHierarchicalShowParentLevel:function(e){return"boolean"!=typeof e.showParentLevel||e.showParentLevel},getHierarchicalFacetByName:function(e){return Nt(this.hierarchicalFacets,function(t){return t.name===e})},getHierarchicalFacetBreadcrumb:function(e){if(!this.isHierarchicalFacet(e))return[];var t=this.getHierarchicalRefinement(e)[0];if(!t)return[];var r=this._getHierarchicalFacetSeparator(this.getHierarchicalFacetByName(e));return t.split(r).map(function(e){return e.trim()})},toString:function(){return JSON.stringify(this,null,2)}};var Wt=qt,Bt=function(e){return Array.isArray(e)?e.filter(Boolean):[]},Vt=function(e,t){if(!Array.isArray(e))return-1;for(var r=0;r<e.length;r++)if(t(e[r]))return r;return-1},Qt=function(e,t){var r=(t||[]).map(function(e){return e.split(":")});return e.reduce(function(e,t){var n=t.split(":"),i=Nt(r,function(e){return e[0]===n[0]});return n.length>1||!i?(e[0].push(n[0]),e[1].push(n[1]),e):(e[0].push(i[0]),e[1].push(i[1]),e)},[[],[]])};function $t(e,t){if(e!==t){var r=void 0!==e,n=null===e,i=void 0!==t,a=null===t;if(!a&&e>t||n&&i||!r)return 1;if(!n&&e<t||a&&r||!i)return-1}return 0}var Gt=function(e,t,r){if(!Array.isArray(e))return[];Array.isArray(r)||(r=[]);var n=e.map(function(e,r){return{criteria:t.map(function(t){return e[t]}),index:r,value:e}});return n.sort(function(e,t){for(var n=-1;++n<e.criteria.length;){var i=$t(e.criteria[n],t.criteria[n]);if(i)return n>=r.length?i:"desc"===r[n]?-i:i}return e.index-t.index}),n.map(function(e){return e.value})},Kt=Pt,Yt=Rt,Xt=Pt,Jt=Rt;function zt(e){var t={};return e.forEach(function(e,r){t[e]=r}),t}function Zt(e,t,r){t&&t[r]&&(e.stats=t[r])}function er(e,t,r){var n=t[0];this._rawResults=t;var i=this;Object.keys(n).forEach(function(e){i[e]=n[e]});var a=xt({persistHierarchicalRootCount:!1},r);Object.keys(a).forEach(function(e){i[e]=a[e]}),this.processingTimeMS=t.reduce(function(e,t){return void 0===t.processingTimeMS?e:e+t.processingTimeMS},0),this.disjunctiveFacets=[],this.hierarchicalFacets=e.hierarchicalFacets.map(function(){return[]}),this.facets=[];var o=e.getRefinedDisjunctiveFacets(),s=zt(e.facets),c=zt(e.disjunctiveFacets),u=1,f=n.facets||{};Object.keys(f).forEach(function(t){var r,a=f[t],o=(r=t,Nt(e.hierarchicalFacets,function(e){return(e.attributes||[]).indexOf(r)>-1}));if(o){var u=o.attributes.indexOf(t),l=Vt(e.hierarchicalFacets,function(e){return e.name===o.name});i.hierarchicalFacets[l][u]={attribute:t,data:a,exhaustive:n.exhaustiveFacetsCount}}else{var h,d=-1!==e.disjunctiveFacets.indexOf(t),p=-1!==e.facets.indexOf(t);d&&(i.disjunctiveFacets[h=c[t]]={name:t,data:a,exhaustive:n.exhaustiveFacetsCount},Zt(i.disjunctiveFacets[h],n.facets_stats,t)),p&&(i.facets[h=s[t]]={name:t,data:a,exhaustive:n.exhaustiveFacetsCount},Zt(i.facets[h],n.facets_stats,t))}}),this.hierarchicalFacets=Bt(this.hierarchicalFacets),o.forEach(function(r){var a=t[u],o=a&&a.facets?a.facets:{},s=e.getHierarchicalFacetByName(r);Object.keys(o).forEach(function(t){var r,u=o[t];if(s){r=Vt(e.hierarchicalFacets,function(e){return e.name===s.name});var f=Vt(i.hierarchicalFacets[r],function(e){return e.attribute===t});if(-1===f)return;i.hierarchicalFacets[r][f].data=xt({},i.hierarchicalFacets[r][f].data,u)}else i.disjunctiveFacets[r=c[t]]={name:t,data:Ft({},u,n.facets&&n.facets[t]||{}),exhaustive:a.exhaustiveFacetsCount},Zt(i.disjunctiveFacets[r],a.facets_stats,t),e.disjunctiveFacetsRefinements[t]&&e.disjunctiveFacetsRefinements[t].forEach(function(n){!i.disjunctiveFacets[r].data[n]&&e.disjunctiveFacetsRefinements[t].indexOf(Jt(n))>-1&&(i.disjunctiveFacets[r].data[n]=0)})}),u++}),e.getRefinedHierarchicalFacets().forEach(function(r){var n=e.getHierarchicalFacetByName(r),a=e._getHierarchicalFacetSeparator(n),o=e.getHierarchicalRefinement(r);0===o.length||o[0].split(a).length<2||t.slice(u).forEach(function(t){var r=t&&t.facets?t.facets:{};Object.keys(r).forEach(function(t){var s=r[t],c=Vt(e.hierarchicalFacets,function(e){return e.name===n.name}),u=Vt(i.hierarchicalFacets[c],function(e){return e.attribute===t});if(-1!==u){var f={};if(o.length>0&&!i.persistHierarchicalRootCount){var l=o[0].split(a)[0];f[l]=i.hierarchicalFacets[c][u].data[l]}i.hierarchicalFacets[c][u].data=Ft(f,s,i.hierarchicalFacets[c][u].data)}}),u++})}),Object.keys(e.facetsExcludes).forEach(function(t){var r=e.facetsExcludes[t],a=s[t];i.facets[a]={name:t,data:f[t],exhaustive:n.exhaustiveFacetsCount},r.forEach(function(e){i.facets[a]=i.facets[a]||{name:t},i.facets[a].data=i.facets[a].data||{},i.facets[a].data[e]=0})}),this.hierarchicalFacets=this.hierarchicalFacets.map(function(e){return function(t,r){var n=e.hierarchicalFacets[r],i=e.hierarchicalFacetsRefinements[n.name]&&e.hierarchicalFacetsRefinements[n.name][0]||"",a=e._getHierarchicalFacetSeparator(n),o=e._getHierarchicalRootPath(n),s=e._getHierarchicalShowParentLevel(n),c=Qt(e._getHierarchicalFacetSortBy(n)),u=t.every(function(e){return e.exhaustive}),f=function(e,t,r,n,i){return function(a,o,s){var c=a;if(s>0){var u=0;for(c=a;u<s;){var f=c&&Array.isArray(c.data)?c.data:[];c=Nt(f,function(e){return e.isRefined}),u++}}if(c){var l=Object.keys(o.data).map(function(e){return[e,o.data[e]]}).filter(function(e){return function(e,t,r,n,i,a){return(!i||0===e.indexOf(i)&&i!==e)&&(!i&&-1===e.indexOf(n)||i&&e.split(n).length-i.split(n).length==1||-1===e.indexOf(n)&&-1===r.indexOf(n)||0===r.indexOf(e)||0===e.indexOf(t+n)&&(a||0===e.indexOf(r)))}(e[0],c.path||r,i,t,r,n)});c.data=Gt(l.map(function(e){return function(e,t,r,n,i){var a=t.split(r);return{name:a[a.length-1].trim(),path:t,escapedValue:Kt(t),count:e,isRefined:n===t||0===n.indexOf(t+r),exhaustive:i,data:null}}(e[1],e[0],t,Yt(i),o.exhaustive)}),e[0],e[1])}return a}}(c,a,o,s,i),l=t;return o&&(l=t.slice(o.split(a).length)),l.reduce(f,{name:e.hierarchicalFacets[r].name,count:null,isRefined:!0,path:null,escapedValue:null,exhaustive:u,data:null})}}(e)),this.facets=Bt(this.facets),this.disjunctiveFacets=Bt(this.disjunctiveFacets),this._state=e}function tr(e,t){function r(e){return e.name===t}if(e._state.isConjunctiveFacet(t)){var n=Nt(e.facets,r);return n?Object.keys(n.data).map(function(r){var i=Xt(r);return{name:r,escapedValue:i,count:n.data[r],isRefined:e._state.isFacetRefined(t,i),isExcluded:e._state.isExcludeRefined(t,r)}}):[]}if(e._state.isDisjunctiveFacet(t)){var i=Nt(e.disjunctiveFacets,r);return i?Object.keys(i.data).map(function(r){var n=Xt(r);return{name:r,escapedValue:n,count:i.data[r],isRefined:e._state.isDisjunctiveFacetRefined(t,n)}}):[]}if(e._state.isHierarchicalFacet(t)){var a=Nt(e.hierarchicalFacets,r);if(!a)return a;var o=e._state.getHierarchicalFacetByName(t),s=e._state._getHierarchicalFacetSeparator(o),c=Jt(e._state.getHierarchicalRefinement(t)[0]||"");0===c.indexOf(o.rootPath)&&(c=c.replace(o.rootPath+s,""));var u=c.split(s);return u.unshift(t),rr(a,u,0),a}}function rr(e,t,r){e.isRefined=e.name===t[r],e.data&&e.data.forEach(function(e){rr(e,t,r+1)})}function nr(e,t,r,n){if(n=n||0,Array.isArray(t))return e(t,r[n]);if(!t.data||0===t.data.length)return t;var i=t.data.map(function(t){return nr(e,t,r,n+1)}),a=e(i,r[n]);return Ft({data:a},t)}function ir(e,t){var r=Nt(e,function(e){return e.name===t});return r&&r.stats}function ar(e,t,r,n,i){var a=Nt(i,function(e){return e.name===r});return{type:t,attributeName:r,name:n,count:a&&a.data&&a.data[n]?a.data[n]:0,exhaustive:a&&a.exhaustive||!1}}er.prototype.getFacetByName=function(e){function t(t){return t.name===e}return Nt(this.facets,t)||Nt(this.disjunctiveFacets,t)||Nt(this.hierarchicalFacets,t)},er.DEFAULT_SORT=["isRefined:desc","count:desc","name:asc"],er.prototype.getFacetValues=function(e,t){var r=tr(this,e);if(r){var n=Ft({},t,{sortBy:er.DEFAULT_SORT,facetOrdering:!(t&&t.sortBy)}),i=this;return nr(function(e,t){if(n.facetOrdering){var r=function(e,t){return e.renderingContent&&e.renderingContent.facetOrdering&&e.renderingContent.facetOrdering.values&&e.renderingContent.facetOrdering.values[t]}(i,t);if(r)return function(e,t){var r=[],n=[],i=(t.order||[]).reduce(function(e,t,r){return e[t]=r,e},{});e.forEach(function(e){var t=e.path||e.name;void 0!==i[t]?r[i[t]]=e:n.push(e)}),r=r.filter(function(e){return e});var a,o=t.sortRemainingBy;return"hidden"===o?r:r.concat(Gt(n,(a="alpha"===o?[["path","name"],["asc","asc"]]:[["count"],["desc"]])[0],a[1]))}(e,r)}if(Array.isArray(n.sortBy)){var a=Qt(n.sortBy,er.DEFAULT_SORT);return Gt(e,a[0],a[1])}if("function"==typeof n.sortBy)return function(e,t){return t.sort(e)}(n.sortBy,e);throw new Error("options.sortBy is optional but if defined it must be either an array of string (predicates) or a sorting function")},r,Array.isArray(r)?[e]:i._state.getHierarchicalFacetByName(r.name).attributes)}},er.prototype.getFacetStats=function(e){return this._state.isConjunctiveFacet(e)?ir(this.facets,e):this._state.isDisjunctiveFacet(e)?ir(this.disjunctiveFacets,e):void 0},er.prototype.getRefinements=function(){var e=this._state,t=this,r=[];return Object.keys(e.facetsRefinements).forEach(function(n){e.facetsRefinements[n].forEach(function(e){r.push(ar(0,"facet",n,e,t.facets))})}),Object.keys(e.facetsExcludes).forEach(function(n){e.facetsExcludes[n].forEach(function(e){r.push(ar(0,"exclude",n,e,t.facets))})}),Object.keys(e.disjunctiveFacetsRefinements).forEach(function(n){e.disjunctiveFacetsRefinements[n].forEach(function(e){r.push(ar(0,"disjunctive",n,e,t.disjunctiveFacets))})}),Object.keys(e.hierarchicalFacetsRefinements).forEach(function(n){e.hierarchicalFacetsRefinements[n].forEach(function(i){r.push(function(e,t,r,n){var i=e.getHierarchicalFacetByName(t),a=e._getHierarchicalFacetSeparator(i),o=r.split(a),s=Nt(n,function(e){return e.name===t}),c=o.reduce(function(e,t){var r=e&&Nt(e.data,function(e){return e.name===t});return void 0!==r?r:e},s);return{type:"hierarchical",attributeName:t,name:c&&c.path||"",count:c&&c.count||0,exhaustive:c&&c.exhaustive||!1}}(e,n,i,t.hierarchicalFacets))})}),Object.keys(e.numericRefinements).forEach(function(t){var n=e.numericRefinements[t];Object.keys(n).forEach(function(e){n[e].forEach(function(n){r.push({type:"numeric",attributeName:t,name:n,numericValue:n,operator:e})})})}),e.tagRefinements.forEach(function(e){r.push({type:"tag",attributeName:"_tags",name:e})}),r};var or=er,sr="3.16.2",cr=Pt;function ur(e,t,r,n){"function"==typeof e.addAlgoliaAgent&&e.addAlgoliaAgent("JS Helper ("+sr+")"),this.setClient(e);var i=r||{};i.index=t,this.state=Wt.make(i),this.lastResults=null,this._queryId=0,this._lastQueryIdReceived=-1,this.derivedHelpers=[],this._currentNbQueries=0,this._searchResultsOptions=n}function fr(e){if(e<0)throw new Error("Page requested below 0.");return this._change({state:this.state.setPage(e),isPageReset:!1}),this}function lr(){return this.state.page}St(ur,gt),ur.prototype.search=function(){return this._search({onlyWithDerivedHelpers:!1}),this},ur.prototype.searchOnlyWithDerivedHelpers=function(){return this._search({onlyWithDerivedHelpers:!0}),this},ur.prototype.getQuery=function(){return Dt._getHitsSearchParams(this.state)},ur.prototype.searchOnce=function(e,t){var r=e?this.state.setQueryParameters(e):this.state,n=Dt._getQueries(r.index,r),i=this;if(this._currentNbQueries++,this.emit("searchOnce",{state:r}),!t)return this.client.search(n).then(function(e){return i._currentNbQueries--,0===i._currentNbQueries&&i.emit("searchQueueEmpty"),{content:new or(r,e.results),state:r,_originalResponse:e}},function(e){throw i._currentNbQueries--,0===i._currentNbQueries&&i.emit("searchQueueEmpty"),e});this.client.search(n).then(function(e){i._currentNbQueries--,0===i._currentNbQueries&&i.emit("searchQueueEmpty"),t(null,new or(r,e.results),r)}).catch(function(e){i._currentNbQueries--,0===i._currentNbQueries&&i.emit("searchQueueEmpty"),t(e,null,r)})},ur.prototype.findAnswers=function(e){console.warn("[algoliasearch-helper] answers is no longer supported");var t=this.state,r=this.derivedHelpers[0];if(!r)return Promise.resolve([]);var n=r.getModifiedState(t),i=xt({attributesForPrediction:e.attributesForPrediction,nbHits:e.nbHits},{params:At(Dt._getHitsSearchParams(n),["attributesToSnippet","hitsPerPage","restrictSearchableAttributes","snippetEllipsisText"])}),a="search for answers was called, but this client does not have a function client.initIndex(index).findAnswers";if("function"!=typeof this.client.initIndex)throw new Error(a);var o=this.client.initIndex(n.index);if("function"!=typeof o.findAnswers)throw new Error(a);return o.findAnswers(n.query,e.queryLanguages,i)},ur.prototype.searchForFacetValues=function(e,t,r,n){var i="function"==typeof this.client.searchForFacetValues,a="function"==typeof this.client.initIndex;if(!i&&!a&&"function"!=typeof this.client.search)throw new Error("search for facet values (searchable) was called, but this client does not have a function client.searchForFacetValues or client.initIndex(index).searchForFacetValues");var o=this.state.setQueryParameters(n||{}),s=o.isDisjunctiveFacet(e),c=Dt.getSearchForFacetQuery(e,t,r,o);this._currentNbQueries++;var u,f=this;return i?u=this.client.searchForFacetValues([{indexName:o.index,params:c}]):a?u=this.client.initIndex(o.index).searchForFacetValues(c):(delete c.facetName,u=this.client.search([{type:"facet",facet:e,indexName:o.index,params:c}]).then(function(e){return e.results[0]})),this.emit("searchForFacetValues",{state:o,facet:e,query:t}),u.then(function(t){return f._currentNbQueries--,0===f._currentNbQueries&&f.emit("searchQueueEmpty"),(t=Array.isArray(t)?t[0]:t).facetHits.forEach(function(t){t.escapedValue=cr(t.value),t.isRefined=s?o.isDisjunctiveFacetRefined(e,t.escapedValue):o.isFacetRefined(e,t.escapedValue)}),t},function(e){throw f._currentNbQueries--,0===f._currentNbQueries&&f.emit("searchQueueEmpty"),e})},ur.prototype.setQuery=function(e){return this._change({state:this.state.resetPage().setQuery(e),isPageReset:!0}),this},ur.prototype.clearRefinements=function(e){return this._change({state:this.state.resetPage().clearRefinements(e),isPageReset:!0}),this},ur.prototype.clearTags=function(){return this._change({state:this.state.resetPage().clearTags(),isPageReset:!0}),this},ur.prototype.addDisjunctiveFacetRefinement=function(e,t){return this._change({state:this.state.resetPage().addDisjunctiveFacetRefinement(e,t),isPageReset:!0}),this},ur.prototype.addDisjunctiveRefine=function(){return this.addDisjunctiveFacetRefinement.apply(this,arguments)},ur.prototype.addHierarchicalFacetRefinement=function(e,t){return this._change({state:this.state.resetPage().addHierarchicalFacetRefinement(e,t),isPageReset:!0}),this},ur.prototype.addNumericRefinement=function(e,t,r){return this._change({state:this.state.resetPage().addNumericRefinement(e,t,r),isPageReset:!0}),this},ur.prototype.addFacetRefinement=function(e,t){return this._change({state:this.state.resetPage().addFacetRefinement(e,t),isPageReset:!0}),this},ur.prototype.addRefine=function(){return this.addFacetRefinement.apply(this,arguments)},ur.prototype.addFacetExclusion=function(e,t){return this._change({state:this.state.resetPage().addExcludeRefinement(e,t),isPageReset:!0}),this},ur.prototype.addExclude=function(){return this.addFacetExclusion.apply(this,arguments)},ur.prototype.addTag=function(e){return this._change({state:this.state.resetPage().addTagRefinement(e),isPageReset:!0}),this},ur.prototype.removeNumericRefinement=function(e,t,r){return this._change({state:this.state.resetPage().removeNumericRefinement(e,t,r),isPageReset:!0}),this},ur.prototype.removeDisjunctiveFacetRefinement=function(e,t){return this._change({state:this.state.resetPage().removeDisjunctiveFacetRefinement(e,t),isPageReset:!0}),this},ur.prototype.removeDisjunctiveRefine=function(){return this.removeDisjunctiveFacetRefinement.apply(this,arguments)},ur.prototype.removeHierarchicalFacetRefinement=function(e){return this._change({state:this.state.resetPage().removeHierarchicalFacetRefinement(e),isPageReset:!0}),this},ur.prototype.removeFacetRefinement=function(e,t){return this._change({state:this.state.resetPage().removeFacetRefinement(e,t),isPageReset:!0}),this},ur.prototype.removeRefine=function(){return this.removeFacetRefinement.apply(this,arguments)},ur.prototype.removeFacetExclusion=function(e,t){return this._change({state:this.state.resetPage().removeExcludeRefinement(e,t),isPageReset:!0}),this},ur.prototype.removeExclude=function(){return this.removeFacetExclusion.apply(this,arguments)},ur.prototype.removeTag=function(e){return this._change({state:this.state.resetPage().removeTagRefinement(e),isPageReset:!0}),this},ur.prototype.toggleFacetExclusion=function(e,t){return this._change({state:this.state.resetPage().toggleExcludeFacetRefinement(e,t),isPageReset:!0}),this},ur.prototype.toggleExclude=function(){return this.toggleFacetExclusion.apply(this,arguments)},ur.prototype.toggleRefinement=function(e,t){return this.toggleFacetRefinement(e,t)},ur.prototype.toggleFacetRefinement=function(e,t){return this._change({state:this.state.resetPage().toggleFacetRefinement(e,t),isPageReset:!0}),this},ur.prototype.toggleRefine=function(){return this.toggleFacetRefinement.apply(this,arguments)},ur.prototype.toggleTag=function(e){return this._change({state:this.state.resetPage().toggleTagRefinement(e),isPageReset:!0}),this},ur.prototype.nextPage=function(){return this.setPage((this.state.page||0)+1)},ur.prototype.previousPage=function(){return this.setPage((this.state.page||0)-1)},ur.prototype.setCurrentPage=fr,ur.prototype.setPage=fr,ur.prototype.setIndex=function(e){return this._change({state:this.state.resetPage().setIndex(e),isPageReset:!0}),this},ur.prototype.setQueryParameter=function(e,t){return this._change({state:this.state.resetPage().setQueryParameter(e,t),isPageReset:!0}),this},ur.prototype.setState=function(e){return this._change({state:Wt.make(e),isPageReset:!1}),this},ur.prototype.overrideStateWithoutTriggeringChangeEvent=function(e){return this.state=new Wt(e),this},ur.prototype.hasRefinements=function(e){return!!It(this.state.getNumericRefinements(e))||(this.state.isConjunctiveFacet(e)?this.state.isFacetRefined(e):this.state.isDisjunctiveFacet(e)?this.state.isDisjunctiveFacetRefined(e):!!this.state.isHierarchicalFacet(e)&&this.state.isHierarchicalFacetRefined(e))},ur.prototype.isExcluded=function(e,t){return this.state.isExcludeRefined(e,t)},ur.prototype.isDisjunctiveRefined=function(e,t){return this.state.isDisjunctiveFacetRefined(e,t)},ur.prototype.hasTag=function(e){return this.state.isTagRefined(e)},ur.prototype.isTagRefined=function(){return this.hasTagRefinements.apply(this,arguments)},ur.prototype.getIndex=function(){return this.state.index},ur.prototype.getCurrentPage=lr,ur.prototype.getPage=lr,ur.prototype.getTags=function(){return this.state.tagRefinements},ur.prototype.getRefinements=function(e){var t=[];this.state.isConjunctiveFacet(e)?(this.state.getConjunctiveRefinements(e).forEach(function(e){t.push({value:e,type:"conjunctive"})}),this.state.getExcludeRefinements(e).forEach(function(e){t.push({value:e,type:"exclude"})})):this.state.isDisjunctiveFacet(e)&&this.state.getDisjunctiveRefinements(e).forEach(function(e){t.push({value:e,type:"disjunctive"})});var r=this.state.getNumericRefinements(e);return Object.keys(r).forEach(function(e){t.push({value:r[e],operator:e,type:"numeric"})}),t},ur.prototype.getNumericRefinement=function(e,t){return this.state.getNumericRefinement(e,t)},ur.prototype.getHierarchicalFacetBreadcrumb=function(e){return this.state.getHierarchicalFacetBreadcrumb(e)},ur.prototype._search=function(e){var t=this.state,r=[],n=[];e.onlyWithDerivedHelpers||(n=Dt._getQueries(t.index,t),r.push({state:t,queriesCount:n.length,helper:this}),this.emit("search",{state:t,results:this.lastResults}));var i=this.derivedHelpers.map(function(e){var n=e.getModifiedState(t),i=n.index?Dt._getQueries(n.index,n):[];return r.push({state:n,queriesCount:i.length,helper:e}),e.emit("search",{state:n,results:e.lastResults}),i}),a=Array.prototype.concat.apply(n,i),o=this._queryId++;if(this._currentNbQueries++,!a.length)return Promise.resolve({results:[]}).then(this._dispatchAlgoliaResponse.bind(this,r,o));try{this.client.search(a).then(this._dispatchAlgoliaResponse.bind(this,r,o)).catch(this._dispatchAlgoliaError.bind(this,o))}catch(e){this.emit("error",{error:e})}},ur.prototype._dispatchAlgoliaResponse=function(e,t,r){var n=this;if(!(t<this._lastQueryIdReceived)){this._currentNbQueries-=t-this._lastQueryIdReceived,this._lastQueryIdReceived=t,0===this._currentNbQueries&&this.emit("searchQueueEmpty");var i=r.results.slice();e.forEach(function(e){var t=e.state,r=e.helper,a=i.splice(0,e.queriesCount);t.index?(r.lastResults=new or(t,a,n._searchResultsOptions),r.emit("result",{results:r.lastResults,state:t})):r.emit("result",{results:null,state:t})})}},ur.prototype._dispatchAlgoliaError=function(e,t){e<this._lastQueryIdReceived||(this._currentNbQueries-=e-this._lastQueryIdReceived,this._lastQueryIdReceived=e,this.emit("error",{error:t}),0===this._currentNbQueries&&this.emit("searchQueueEmpty"))},ur.prototype.containsRefinement=function(e,t,r,n){return e||0!==t.length||0!==r.length||0!==n.length},ur.prototype._hasDisjunctiveRefinements=function(e){return this.state.disjunctiveRefinements[e]&&this.state.disjunctiveRefinements[e].length>0},ur.prototype._change=function(e){var t=e.state,r=e.isPageReset;t!==this.state&&(this.state=t,this.emit("change",{state:this.state,results:this.lastResults,isPageReset:r}))},ur.prototype.clearCache=function(){return this.client.clearCache&&this.client.clearCache(),this},ur.prototype.setClient=function(e){return this.client===e||("function"==typeof e.addAlgoliaAgent&&e.addAlgoliaAgent("JS Helper ("+sr+")"),this.client=e),this},ur.prototype.getClient=function(){return this.client},ur.prototype.derive=function(e){var t=new jt(this,e);return this.derivedHelpers.push(t),t},ur.prototype.detachDerivedHelper=function(e){var t=this.derivedHelpers.indexOf(e);if(-1===t)throw new Error("Derived helper already detached");this.derivedHelpers.splice(t,1)},ur.prototype.hasPendingRequests=function(){return this._currentNbQueries>0};var hr=ur;function dr(e,t,r,n){return new hr(e,t,r,n)}dr.version=sr,dr.AlgoliaSearchHelper=hr,dr.SearchParameters=Wt,dr.SearchResults=or;var pr=dr;function vr(e){return vr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},vr(e)}function mr(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function gr(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?mr(Object(r),!0).forEach(function(t){yr(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):mr(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function yr(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==vr(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==vr(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===vr(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function br(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{if(a=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;c=!1}else for(;!(c=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(e,t)||wr(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function wr(e,t){if(e){if("string"==typeof e)return Sr(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Sr(e,t):void 0}}function Sr(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var Or="2.13.0",jr="https://cdn.jsdelivr.net/npm/search-insights@".concat(Or,"/dist/search-insights.min.js");function Pr(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.insightsClient,r=e.insightsInitParams,n=e.onEvent,i=e.$$internal,o=void 0!==i&&i,s=e.$$automatic,u=void 0!==s&&s,f=t;t||null===t||ze(function(e){var t=e.window,r=t.AlgoliaAnalyticsObject||"aa";"string"==typeof r&&(f=t[r]),f||(t.AlgoliaAnalyticsObject=r,t[r]||(t[r]=function(){t[r].queue||(t[r].queue=[]);for(var e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];t[r].queue.push(n)},t[r].version=Or,t[r].shouldAddScript=!0),f=t[r])});var l=f||a;return function(e){var t,i=e.instantSearchInstance,s=i.middleware.filter(function(e){return"ais.insights"===e.instance.$$type&&e.instance.$$internal}).map(function(e){return e.creator});i.unuse.apply(i,function(e){if(Array.isArray(e))return Sr(e)}(t=s)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||wr(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}());var f=br(function(e){if(e.transporter){var t=e.transporter,r=t.headers,n=t.queryParameters,i="x-algolia-application-id",a="x-algolia-api-key";return[r[i]||n[i],r[a]||n[a]]}return[e.applicationID,e.apiKey]}(i.client),2),h=f[0],d=f[1];"development"==="production".NODE_ENV&&c(Boolean(h&&d),"could not extract Algolia credentials from searchClient in insights middleware.");var p,v,m=void 0,g=void 0,y=void 0,b=void 0,w=l.queue;if(Array.isArray(w)){var S=["setUserToken","setAuthenticatedUserToken"].map(function(e){var t=oe(w.slice().reverse(),function(t){return br(t,1)[0]===e})||[];return br(t,2)[1]}),O=br(S,2);m=O[0],g=O[1]}return l("getUserToken",null,function(e,t){y=_r(t)}),l("getAuthenticatedUserToken",null,function(e,t){b=_r(t)}),!r&&Rr(l)||l("init",gr({appId:h,apiKey:d,partial:!0},r)),{$$type:"ais.insights",$$internal:o,$$automatic:u,onStateChange:function(){},subscribe:function(){if(l.shouldAddScript){var e="[insights middleware]: could not load search-insights.js. Please load it manually following https://alg.li/insights-init";try{var t=document.createElement("script");t.async=!0,t.src=jr,t.onerror=function(){i.emit("error",new Error(e))},document.body.appendChild(t),l.shouldAddScript=!1}catch(t){l.shouldAddScript=!1,i.emit("error",new Error(e))}}},started:function(){l("addAlgoliaAgent","insights-middleware"),p={userToken:(v=i.mainHelper).state.userToken,clickAnalytics:v.state.clickAnalytics},u||v.overrideStateWithoutTriggeringChangeEvent(gr(gr({},v.state),{},{clickAnalytics:!0})),o||i.scheduleSearch();var e=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=_r(e);if(r){var n=v.state.userToken;t?a():setTimeout(a,0)}function a(){v.overrideStateWithoutTriggeringChangeEvent(gr(gr({},v.state),{},{userToken:r})),n&&n!==e&&i.scheduleSearch()}},t=ht();function r(t,r,n){e(t,!0),r&&l("setUserToken",r),n&&l("setAuthenticatedUserToken",n)}t&&e(t,!0);var a=b||y,s=g||m;a?r(a,y,b):s&&r(s,m,g),l("onUserTokenChange",e,{immediate:!0}),l("onAuthenticatedUserTokenChange",function(t){t||l("getUserToken",null,function(t,r){e(r)}),e(t)},{immediate:!0});var f=l;Rr(l)&&(f=function(e,t){return l(e,t,{headers:{"X-Algolia-Application-Id":h,"X-Algolia-API-Key":d}})}),i.sendEventToInsights=function(e){n?n(e,f):e.insightsMethod?(e.payload.algoliaSource=["instantsearch"],u&&e.payload.algoliaSource.push("instantsearch-automatic"),"internal"===e.eventModifier&&e.payload.algoliaSource.push("instantsearch-internal"),f(e.insightsMethod,e.payload),"development"==="production".NODE_ENV&&c(Boolean(v.state.userToken),"\nCannot send event to Algolia Insights because `userToken` is not set.\n\nSee documentation: https://www.algolia.com/doc/guides/building-search-ui/going-further/send-insights-events/js/#setting-the-usertoken\n")):"development"==="production".NODE_ENV&&c(!1,"Cannot send event to Algolia Insights because `insightsMethod` option is missing.")}},unsubscribe:function(){l("onUserTokenChange",void 0),l("onAuthenticatedUserTokenChange",void 0),i.sendEventToInsights=a,v&&p&&(v.overrideStateWithoutTriggeringChangeEvent(gr(gr({},v.state),p)),i.scheduleSearch())}}}}function Rr(e){var t=br((e.version||"").split(".").map(Number),2),r=t[0],n=t[1];return r>=3||2===r&&n>=6||1===r&&n>=10}function _r(e){if(e)return"number"==typeof e?e.toString():e}function Er(e,t,r){var n=Qe(t,t.mainIndex,t._initialUiState);e.forEach(function(e){var i={};if(e.getWidgetRenderState){var a=e.getWidgetRenderState(n);a&&a.widgetParams&&(i=a.widgetParams)}var o=Object.keys(i).filter(function(e){return void 0!==i[e]});r.widgets.push({type:e.$$type,widgetType:e.$$widgetType,params:o}),"ais.index"===e.$$type&&Er(e.getWidgets(),t,r)})}function xr(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).$$internal,t=void 0!==e&&e;return function(e){var r=e.instantSearchInstance,n={widgets:[]},i=document.createElement("meta"),a=document.querySelector("head");return i.name="instantsearch:widgets",{$$type:"ais.metadata",$$internal:t,onStateChange:function(){},subscribe:function(){setTimeout(function(){var e=r.client;n.ua=e.transporter&&e.transporter.userAgent?e.transporter.userAgent.value:e._ua,Er(r.mainIndex.getWidgets(),r,n),r.middleware.forEach(function(e){return n.widgets.push({middleware:!0,type:e.instance.$$type,internal:e.instance.$$internal})}),i.content=JSON.stringify(n),a.appendChild(i)},0)},started:function(){},unsubscribe:function(){i.remove()}}}}var Ir=String.prototype.replace,Ar=/%20/g,Tr="RFC3986",kr={default:Tr,formatters:{RFC1738:function(e){return Ir.call(e,Ar,"+")},RFC3986:function(e){return String(e)}},RFC1738:"RFC1738",RFC3986:Tr},Dr=Object.prototype.hasOwnProperty,Fr=Array.isArray,Nr=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),Lr=function(e,t){for(var r=t&&t.plainObjects?Object.create(null):{},n=0;n<e.length;++n)void 0!==e[n]&&(r[n]=e[n]);return r},Mr={arrayToObject:Lr,assign:function(e,t){return Object.keys(t).reduce(function(e,r){return e[r]=t[r],e},e)},combine:function(e,t){return[].concat(e,t)},compact:function(e){for(var t=[{obj:{o:e},prop:"o"}],r=[],n=0;n<t.length;++n)for(var i=t[n],a=i.obj[i.prop],o=Object.keys(a),s=0;s<o.length;++s){var c=o[s],u=a[c];"object"==typeof u&&null!==u&&-1===r.indexOf(u)&&(t.push({obj:a,prop:c}),r.push(u))}return function(e){for(;e.length>1;){var t=e.pop(),r=t.obj[t.prop];if(Fr(r)){for(var n=[],i=0;i<r.length;++i)void 0!==r[i]&&n.push(r[i]);t.obj[t.prop]=n}}}(t),e},decode:function(e,t,r){var n=e.replace(/\+/g," ");if("iso-8859-1"===r)return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch(e){return n}},encode:function(e,t,r,n,i){if(0===e.length)return e;var a=e;if("symbol"==typeof e?a=Symbol.prototype.toString.call(e):"string"!=typeof e&&(a=String(e)),"iso-8859-1"===r)return escape(a).replace(/%u[0-9a-f]{4}/gi,function(e){return"%26%23"+parseInt(e.slice(2),16)+"%3B"});for(var o="",s=0;s<a.length;++s){var c=a.charCodeAt(s);45===c||46===c||95===c||126===c||c>=48&&c<=57||c>=65&&c<=90||c>=97&&c<=122||i===kr.RFC1738&&(40===c||41===c)?o+=a.charAt(s):c<128?o+=Nr[c]:c<2048?o+=Nr[192|c>>6]+Nr[128|63&c]:c<55296||c>=57344?o+=Nr[224|c>>12]+Nr[128|c>>6&63]+Nr[128|63&c]:(c=65536+((1023&c)<<10|1023&a.charCodeAt(s+=1)),o+=Nr[240|c>>18]+Nr[128|c>>12&63]+Nr[128|c>>6&63]+Nr[128|63&c])}return o},isBuffer:function(e){return!(!e||"object"!=typeof e||!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e)))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(Fr(e)){for(var r=[],n=0;n<e.length;n+=1)r.push(t(e[n]));return r}return t(e)},merge:function e(t,r,n){if(!r)return t;if("object"!=typeof r){if(Fr(t))t.push(r);else{if(!t||"object"!=typeof t)return[t,r];(n&&(n.plainObjects||n.allowPrototypes)||!Dr.call(Object.prototype,r))&&(t[r]=!0)}return t}if(!t||"object"!=typeof t)return[t].concat(r);var i=t;return Fr(t)&&!Fr(r)&&(i=Lr(t,n)),Fr(t)&&Fr(r)?(r.forEach(function(r,i){if(Dr.call(t,i)){var a=t[i];a&&"object"==typeof a&&r&&"object"==typeof r?t[i]=e(a,r,n):t.push(r)}else t[i]=r}),t):Object.keys(r).reduce(function(t,i){var a=r[i];return t[i]=Dr.call(t,i)?e(t[i],a,n):a,t},i)}},Cr=Object.prototype.hasOwnProperty,Ur={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},Hr=Array.isArray,qr=String.prototype.split,Wr=Array.prototype.push,Br=function(e,t){Wr.apply(e,Hr(t)?t:[t])},Vr=Date.prototype.toISOString,Qr=kr.default,$r={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:Mr.encode,encodeValuesOnly:!1,format:Qr,formatter:kr.formatters[Qr],indices:!1,serializeDate:function(e){return Vr.call(e)},skipNulls:!1,strictNullHandling:!1},Gr=function e(t,r,n,i,a,o,s,c,u,f,l,h,d,p){var v,m=t;if("function"==typeof s?m=s(r,m):m instanceof Date?m=f(m):"comma"===n&&Hr(m)&&(m=Mr.maybeMap(m,function(e){return e instanceof Date?f(e):e})),null===m){if(i)return o&&!d?o(r,$r.encoder,p,"key",l):r;m=""}if("string"==typeof(v=m)||"number"==typeof v||"boolean"==typeof v||"symbol"==typeof v||"bigint"==typeof v||Mr.isBuffer(m)){if(o){var g=d?r:o(r,$r.encoder,p,"key",l);if("comma"===n&&d){for(var y=qr.call(String(m),","),b="",w=0;w<y.length;++w)b+=(0===w?"":",")+h(o(y[w],$r.encoder,p,"value",l));return[h(g)+"="+b]}return[h(g)+"="+h(o(m,$r.encoder,p,"value",l))]}return[h(r)+"="+h(String(m))]}var S,O=[];if(void 0===m)return O;if("comma"===n&&Hr(m))S=[{value:m.length>0?m.join(",")||null:void 0}];else if(Hr(s))S=s;else{var j=Object.keys(m);S=c?j.sort(c):j}for(var P=0;P<S.length;++P){var R=S[P],_="object"==typeof R&&void 0!==R.value?R.value:m[R];if(!a||null!==_){var E=Hr(m)?"function"==typeof n?n(r,R):r:r+(u?"."+R:"["+R+"]");Br(O,e(_,E,n,i,a,o,s,c,u,f,l,h,d,p))}}return O},Kr=Object.prototype.hasOwnProperty,Yr=Array.isArray,Xr={allowDots:!1,allowPrototypes:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:Mr.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},Jr=function(e){return e.replace(/&#(\d+);/g,function(e,t){return String.fromCharCode(parseInt(t,10))})},zr=function(e,t){return e&&"string"==typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},Zr=function(e,t,r,n){if(e){var i=r.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,a=/(\[[^[\]]*])/g,o=r.depth>0&&/(\[[^[\]]*])/.exec(i),s=o?i.slice(0,o.index):i,c=[];if(s){if(!r.plainObjects&&Kr.call(Object.prototype,s)&&!r.allowPrototypes)return;c.push(s)}for(var u=0;r.depth>0&&null!==(o=a.exec(i))&&u<r.depth;){if(u+=1,!r.plainObjects&&Kr.call(Object.prototype,o[1].slice(1,-1))&&!r.allowPrototypes)return;c.push(o[1])}return o&&c.push("["+i.slice(o.index)+"]"),function(e,t,r,n){for(var i=n?t:zr(t,r),a=e.length-1;a>=0;--a){var o,s=e[a];if("[]"===s&&r.parseArrays)o=[].concat(i);else{o=r.plainObjects?Object.create(null):{};var c="["===s.charAt(0)&&"]"===s.charAt(s.length-1)?s.slice(1,-1):s,u=parseInt(c,10);r.parseArrays||""!==c?!isNaN(u)&&s!==c&&String(u)===c&&u>=0&&r.parseArrays&&u<=r.arrayLimit?(o=[])[u]=i:"__proto__"!==c&&(o[c]=i):o={0:i}}i=o}return i}(c,t,r,n)}},en={formats:kr,parse:function(e,t){var r=function(e){if(!e)return Xr;if(null!=e.decoder&&"function"!=typeof e.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");return{allowDots:void 0===e.allowDots?Xr.allowDots:!!e.allowDots,allowPrototypes:"boolean"==typeof e.allowPrototypes?e.allowPrototypes:Xr.allowPrototypes,arrayLimit:"number"==typeof e.arrayLimit?e.arrayLimit:Xr.arrayLimit,charset:void 0===e.charset?Xr.charset:e.charset,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:Xr.charsetSentinel,comma:"boolean"==typeof e.comma?e.comma:Xr.comma,decoder:"function"==typeof e.decoder?e.decoder:Xr.decoder,delimiter:"string"==typeof e.delimiter||Mr.isRegExp(e.delimiter)?e.delimiter:Xr.delimiter,depth:"number"==typeof e.depth||!1===e.depth?+e.depth:Xr.depth,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof e.interpretNumericEntities?e.interpretNumericEntities:Xr.interpretNumericEntities,parameterLimit:"number"==typeof e.parameterLimit?e.parameterLimit:Xr.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"==typeof e.plainObjects?e.plainObjects:Xr.plainObjects,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:Xr.strictNullHandling}}(t);if(""===e||null==e)return r.plainObjects?Object.create(null):{};for(var n="string"==typeof e?function(e,t){var r,n={},i=(t.ignoreQueryPrefix?e.replace(/^\?/,""):e).split(t.delimiter,Infinity===t.parameterLimit?void 0:t.parameterLimit),a=-1,o=t.charset;if(t.charsetSentinel)for(r=0;r<i.length;++r)0===i[r].indexOf("utf8=")&&("utf8=%E2%9C%93"===i[r]?o="utf-8":"utf8=%26%2310003%3B"===i[r]&&(o="iso-8859-1"),a=r,r=i.length);for(r=0;r<i.length;++r)if(r!==a){var s,c,u=i[r],f=u.indexOf("]="),l=-1===f?u.indexOf("="):f+1;-1===l?(s=t.decoder(u,Xr.decoder,o,"key"),c=t.strictNullHandling?null:""):(s=t.decoder(u.slice(0,l),Xr.decoder,o,"key"),c=Mr.maybeMap(zr(u.slice(l+1),t),function(e){return t.decoder(e,Xr.decoder,o,"value")})),c&&t.interpretNumericEntities&&"iso-8859-1"===o&&(c=Jr(c)),u.indexOf("[]=")>-1&&(c=Yr(c)?[c]:c),n[s]=Kr.call(n,s)?Mr.combine(n[s],c):c}return n}(e,r):e,i=r.plainObjects?Object.create(null):{},a=Object.keys(n),o=0;o<a.length;++o){var s=a[o],c=Zr(s,n[s],r,"string"==typeof e);i=Mr.merge(i,c,r)}return Mr.compact(i)},stringify:function(e,t){var r,n=e,i=function(e){if(!e)return $r;if(null!=e.encoder&&"function"!=typeof e.encoder)throw new TypeError("Encoder has to be a function.");var t=e.charset||$r.charset;if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var r=kr.default;if(void 0!==e.format){if(!Cr.call(kr.formatters,e.format))throw new TypeError("Unknown format option provided.");r=e.format}var n=kr.formatters[r],i=$r.filter;return("function"==typeof e.filter||Hr(e.filter))&&(i=e.filter),{addQueryPrefix:"boolean"==typeof e.addQueryPrefix?e.addQueryPrefix:$r.addQueryPrefix,allowDots:void 0===e.allowDots?$r.allowDots:!!e.allowDots,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:$r.charsetSentinel,delimiter:void 0===e.delimiter?$r.delimiter:e.delimiter,encode:"boolean"==typeof e.encode?e.encode:$r.encode,encoder:"function"==typeof e.encoder?e.encoder:$r.encoder,encodeValuesOnly:"boolean"==typeof e.encodeValuesOnly?e.encodeValuesOnly:$r.encodeValuesOnly,filter:i,format:r,formatter:n,serializeDate:"function"==typeof e.serializeDate?e.serializeDate:$r.serializeDate,skipNulls:"boolean"==typeof e.skipNulls?e.skipNulls:$r.skipNulls,sort:"function"==typeof e.sort?e.sort:null,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:$r.strictNullHandling}}(t);"function"==typeof i.filter?n=(0,i.filter)("",n):Hr(i.filter)&&(r=i.filter);var a=[];if("object"!=typeof n||null===n)return"";var o=Ur[t&&t.arrayFormat in Ur?t.arrayFormat:t&&"indices"in t?t.indices?"indices":"repeat":"indices"];r||(r=Object.keys(n)),i.sort&&r.sort(i.sort);for(var s=0;s<r.length;++s){var c=r[s];i.skipNulls&&null===n[c]||Br(a,Gr(n[c],c,o,i.strictNullHandling,i.skipNulls,i.encode?i.encoder:null,i.filter,i.sort,i.allowDots,i.serializeDate,i.format,i.formatter,i.encodeValuesOnly,i.charset))}var u=a.join(i.delimiter),f=!0===i.addQueryPrefix?"?":"";return i.charsetSentinel&&(f+="iso-8859-1"===i.charset?"utf8=%26%2310003%3B&":"utf8=%E2%9C%93&"),u.length>0?f+u:""}};function tn(e){return tn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},tn(e)}function rn(e,t,r){return(t=nn(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function nn(e){var t=function(e,t){if("object"!==tn(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==tn(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===tn(t)?t:String(t)}var an=function(e){e&&(window.document.title=e)},on=/*#__PURE__*/function(){function e(t){var r=this,n=t.windowTitle,i=t.writeDelay,a=void 0===i?400:i,o=t.createURL,s=t.parseURL,c=t.getLocation,u=t.start,f=t.dispose,l=t.push,h=t.cleanUrlOnDispose;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),rn(this,"$$type","ais.browser"),rn(this,"windowTitle",void 0),rn(this,"writeDelay",void 0),rn(this,"_createURL",void 0),rn(this,"parseURL",void 0),rn(this,"getLocation",void 0),rn(this,"writeTimer",void 0),rn(this,"_onPopState",void 0),rn(this,"inPopState",!1),rn(this,"isDisposed",!1),rn(this,"latestAcknowledgedHistory",0),rn(this,"_start",void 0),rn(this,"_dispose",void 0),rn(this,"_push",void 0),rn(this,"_cleanUrlOnDispose",void 0),this.windowTitle=n,this.writeTimer=void 0,this.writeDelay=a,this._createURL=o,this.parseURL=s,this.getLocation=c,this._start=u,this._dispose=f,this._push=l,this._cleanUrlOnDispose=void 0===h||h,"development"==="production".NODE_ENV&&void 0===h&&console.info("Starting from the next major version, InstantSearch will not clean up the URL from active refinements when it is disposed.\n\nWe recommend setting `cleanUrlOnDispose` to false to adopt this change today.\nTo stay with the current behaviour and remove this warning, set the option to true.\n\nSee documentation: ".concat(ne({name:"history-router"}),"#widget-param-cleanurlondispose")),ze(function(e){var t=e.window,n=r.windowTitle&&r.windowTitle(r.read());an(n),r.latestAcknowledgedHistory=t.history.length})}var t,r;return t=e,(r=[{key:"read",value:function(){return this.parseURL({qsModule:en,location:this.getLocation()})}},{key:"write",value:function(e){var t=this;ze(function(r){var n=r.window,i=t.createURL(e),a=t.windowTitle&&t.windowTitle(e);t.writeTimer&&clearTimeout(t.writeTimer),t.writeTimer=setTimeout(function(){an(a),t.shouldWrite(i)&&(t._push?t._push(i):n.history.pushState(e,a||"",i),t.latestAcknowledgedHistory=n.history.length),t.inPopState=!1,t.writeTimer=void 0},t.writeDelay)})}},{key:"onUpdate",value:function(e){var t=this;this._start&&this._start(function(){e(t.read())}),this._onPopState=function(){t.writeTimer&&(clearTimeout(t.writeTimer),t.writeTimer=void 0),t.inPopState=!0,e(t.read())},ze(function(e){e.window.addEventListener("popstate",t._onPopState)})}},{key:"createURL",value:function(e){var t=this._createURL({qsModule:en,routeState:e,location:this.getLocation()});if("development"==="production".NODE_ENV)try{new URL(t)}catch(e){"development"==="production".NODE_ENV&&c(!1,"The URL returned by the `createURL` function is invalid.\nPlease make sure it returns an absolute URL to avoid issues, e.g: `https://algolia.com/search?query=iphone`.")}return t}},{key:"dispose",value:function(){var e=this;this._dispose&&this._dispose(),this.isDisposed=!0,ze(function(t){e._onPopState&&t.window.removeEventListener("popstate",e._onPopState)}),this.writeTimer&&clearTimeout(this.writeTimer),this._cleanUrlOnDispose&&this.write({})}},{key:"start",value:function(){this.isDisposed=!1}},{key:"shouldWrite",value:function(e){var t=this;return ze(function(r){var n=r.window;return!(t.inPopState||t.isDisposed&&t.latestAcknowledgedHistory!==n.history.length||e===n.location.href)})}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,nn(n.key),n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),e}();function sn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.createURL,r=e.parseURL,n=e.writeDelay,i=e.getLocation;return new on({createURL:void 0===t?function(e){var t=e.location,r=t.protocol,n=t.hostname,i=t.port,a=void 0===i?"":i,o=t.pathname,s=t.hash,c=e.qsModule.stringify(e.routeState),u=""===a?"":":".concat(a);return c?"".concat(r,"//").concat(n).concat(u).concat(o,"?").concat(c).concat(s):"".concat(r,"//").concat(n).concat(u).concat(o).concat(s)}:t,parseURL:void 0===r?function(e){return e.qsModule.parse(e.location.search.slice(1),{arrayLimit:99})}:r,writeDelay:void 0===n?400:n,windowTitle:e.windowTitle,getLocation:void 0===i?function(){return ze(function(e){return e.window.location},{fallback:function(){throw new Error("You need to provide `getLocation` to the `history` router in environments where `window` does not exist.")}})}:i,start:e.start,dispose:e.dispose,push:e.push,cleanUrlOnDispose:e.cleanUrlOnDispose})}function cn(e){return cn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},cn(e)}var un=["configure"];function fn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function ln(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?fn(Object(r),!0).forEach(function(t){hn(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):fn(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function hn(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==cn(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==cn(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===cn(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function dn(e){return function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},a=Object.keys(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,un)}function pn(e){return pn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},pn(e)}function vn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function mn(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?vn(Object(r),!0).forEach(function(t){gn(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):vn(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function gn(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==pn(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==pn(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===pn(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function yn(e){return yn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},yn(e)}var bn=["initialSearchParameters"];function wn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Sn(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?wn(Object(r),!0).forEach(function(t){On(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):wn(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function On(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==yn(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==yn(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===yn(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function jn(e){return function(e){if(Array.isArray(e))return Pn(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Pn(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Pn(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Pn(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var Rn=ie({name:"index-widget"});function _n(e,t){var r=t.state,n=t.isPageReset,i=t._uiState;r!==e.state&&(e.state=r,e.emit("change",{state:e.state,results:e.lastResults,isPageReset:n,_uiState:i}))}function En(e,t){return e.reduce(function(e,r){return z(r)?e:r.getWidgetUiState||r.getWidgetState?r.getWidgetUiState?r.getWidgetUiState(e,t):r.getWidgetState(e,t):e},arguments.length>2&&void 0!==arguments[2]?arguments[2]:{})}function xn(e,t){var r=t.initialSearchParameters,n=function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},a=Object.keys(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(t,bn);return e.filter(function(e){return!z(e)}).reduce(function(e,t){return t.getWidgetSearchParameters?t.getWidgetSearchParameters(e,n):e},r)}function In(e){var t=e.filter(z);0!==t.length&&t.forEach(function(e){var t=e.getHelper();_n(t,{state:t.state.resetPage(),isPageReset:!0}),In(e.getWidgets())})}function An(e){return e.filter(z).reduce(function(e,t){return e.concat.apply(e,[{indexId:t.getIndexId(),results:t.getResults(),helper:t.getHelper()}].concat(jn(An(t.getWidgets()))))},[])}var Tn=function(e){if(void 0===e||void 0===e.indexName)throw new Error(Rn("The `indexName` option is required."));var t=e.indexName,r=e.indexId,n=void 0===r?t:r,i=[],a={},o=null,s=null,u=null,f=null,l=null;return{$$type:"ais.index",$$widgetType:"ais.index",getIndexName:function(){return t},getIndexId:function(){return n},getHelper:function(){return u},getResults:function(){var e;return null!==(e=f)&&void 0!==e&&e.lastResults?(f.lastResults._state=u.state,f.lastResults):null},getPreviousState:function(){return l},getScopedResults:function(){var e=this.getParent();return An(e?e.getWidgets():[this])},getParent:function(){return s},createURL:function(e){return o._createURL(On({},n,"function"==typeof e?e(a):En(i,{searchParameters:e,helper:u})))},getWidgets:function(){return i},addWidgets:function(e){var t=this;if(!Array.isArray(e))throw new Error(Rn("The `addWidgets` method expects an array of widgets."));if(e.some(function(e){return"function"!=typeof e.init&&"function"!=typeof e.render}))throw new Error(Rn("The widget definition expects a `render` and/or an `init` method."));return i=i.concat(e),o&&Boolean(e.length)&&(_n(u,{state:xn(i,{uiState:a,initialSearchParameters:u.state}),_uiState:a}),e.forEach(function(e){e.getRenderState&&kn({renderState:e.getRenderState(o.renderState[t.getIndexId()]||{},Qe(o,t,o._initialUiState)),instantSearchInstance:o,parent:t})}),e.forEach(function(e){e.init&&e.init(Qe(o,t,o._initialUiState))}),o.scheduleSearch()),this},removeWidgets:function(e){var t=this;if(!Array.isArray(e))throw new Error(Rn("The `removeWidgets` method expects an array of widgets."));if(e.some(function(e){return"function"!=typeof e.dispose}))throw new Error(Rn("The widget definition expects a `dispose` method."));if(i=i.filter(function(t){return-1===e.indexOf(t)}),o&&Boolean(e.length)){var r=e.reduce(function(e,r){return r.dispose({helper:u,state:e,parent:t})||e},u.state),n=xn(i,o.future.preserveSharedStateOnUnmount?{uiState:a,initialSearchParameters:new pr.SearchParameters({index:this.getIndexName()})}:{uiState:En(i,{searchParameters:r,helper:u}),initialSearchParameters:r});a=En(i,{searchParameters:n,helper:u}),u.setState(n),i.length&&o.scheduleSearch()}return this},init:function(e){var r,h=this,d=e.instantSearchInstance,v=e.uiState;if(null===u){o=d,s=e.parent;var m=d.mainHelper,g=xn(i,{uiState:a=v[n]||{},initialSearchParameters:new pr.SearchParameters({index:t})});(u=pr({},g.index,g)).search=function(){return d.onStateChange?(d.onStateChange({uiState:d.mainIndex.getWidgetUiState({}),setUiState:function(e){return d.setUiState(e,!1)}}),m):m.search()},u.searchWithoutTriggeringOnStateChange=function(){return m.search()},u.searchForFacetValues=function(e,t,r,n){var i=u.state.setQueryParameters(n);return m.searchForFacetValues(e,t,r,i)},f=m.derive(function(){return We.apply(void 0,[m.state].concat(jn(function(e){for(var t=e.getParent(),r=[e.getHelper().state];null!==t;)r=[t.getHelper().state].concat(r),t=t.getParent();return r}(h))))});var y=null===(r=d._initialResults)||void 0===r?void 0:r[this.getIndexId()];if(y){var b=new pr.SearchResults(new pr.SearchParameters(y.state),y.results);f.lastResults=b,u.lastResults=b}u.on("change",function(e){e.isPageReset&&In(i)}),f.on("search",function(){d.scheduleStalledRender(),"development"==="production".NODE_ENV&&p({index:h,indexUiState:a})}),f.on("result",function(e){var t=e.results;d.scheduleRender(),u.lastResults=t,l=null==t?void 0:t._state}),i.forEach(function(e){e.getRenderState&&kn({renderState:e.getRenderState(d.renderState[h.getIndexId()]||{},Qe(d,h,v)),instantSearchInstance:d,parent:h})}),i.forEach(function(e){"development"==="production".NODE_ENV&&c(!e.getWidgetState||Boolean(e.getWidgetUiState),"The `getWidgetState` method is renamed `getWidgetUiState` and will no longer exist under that name in InstantSearch.js 5.x. Please use `getWidgetUiState` instead."),e.init&&e.init(Qe(d,h,v))}),u.on("change",function(e){a=En(i,{searchParameters:e.state,helper:u},e._uiState||{}),d.onStateChange||d.onInternalStateChange()}),y&&d.scheduleRender()}},render:function(e){var t=this,r=e.instantSearchInstance;"error"===r.status&&!r.mainHelper.hasPendingRequests()&&l&&u.setState(l);var n=this.getResults()?i:i.filter(z);n.forEach(function(e){e.getRenderState&&kn({renderState:e.getRenderState(r.renderState[t.getIndexId()]||{},$e(r,t)),instantSearchInstance:r,parent:t})}),n.forEach(function(e){e.render&&e.render($e(r,t))})},dispose:function(){var e,t,r=this;i.forEach(function(e){e.dispose&&e.dispose({helper:u,state:u.state,parent:r})}),o=null,s=null,null===(e=u)||void 0===e||e.removeAllListeners(),u=null,null===(t=f)||void 0===t||t.detach(),f=null},getWidgetUiState:function(e){return i.filter(z).reduce(function(e,t){return t.getWidgetUiState(e)},Sn(Sn({},e),{},On({},n,Sn(Sn({},e[n]),a))))},getWidgetState:function(e){return"development"==="production".NODE_ENV&&c(!1,"The `getWidgetState` method is renamed `getWidgetUiState` and will no longer exist under that name in InstantSearch.js 5.x. Please use `getWidgetUiState` instead."),this.getWidgetUiState(e)},getWidgetSearchParameters:function(e,t){return xn(i,{uiState:t.uiState,initialSearchParameters:e})},refreshUiState:function(){a=En(i,{searchParameters:this.getHelper().state,helper:this.getHelper()},a)},setIndexUiState:function(e){var t="function"==typeof e?e(a):e;o.setUiState(function(e){return Sn(Sn({},e),{},On({},n,t))})}}};function kn(e){var t=e.renderState,r=e.instantSearchInstance,n=e.parent,i=n?n.getIndexId():r.mainIndex.getIndexId();r.renderState=Sn(Sn({},r.renderState),{},On({},i,Sn(Sn({},r.renderState[i]),t)))}function Dn(e){return Dn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Dn(e)}function Fn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Nn(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Fn(Object(r),!0).forEach(function(t){Ln(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Fn(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Ln(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Dn(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Dn(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Dn(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Mn(e){var t=e.numberLocale;return{formatNumber:function(e,r){return function(e,t){return e.toLocaleString(t)}(Number(r(e)),t)},highlight:function(e,t){try{return t(tt(Nn(Nn({},JSON.parse(e)),{},{hit:this})))}catch(e){throw new Error('\nThe highlight helper expects a JSON object of the format:\n{ "attribute": "name", "highlightedTagName": "mark" }')}},reverseHighlight:function(e,t){try{return t(nt(Nn(Nn({},JSON.parse(e)),{},{hit:this})))}catch(e){throw new Error('\n  The reverseHighlight helper expects a JSON object of the format:\n  { "attribute": "name", "highlightedTagName": "mark" }')}},snippet:function(e,t){try{return t(at(Nn(Nn({},JSON.parse(e)),{},{hit:this})))}catch(e){throw new Error('\nThe snippet helper expects a JSON object of the format:\n{ "attribute": "name", "highlightedTagName": "mark" }')}},reverseSnippet:function(e,t){try{return t(st(Nn(Nn({},JSON.parse(e)),{},{hit:this})))}catch(e){throw new Error('\n  The reverseSnippet helper expects a JSON object of the format:\n  { "attribute": "name", "highlightedTagName": "mark" }')}},insights:function(e,t){try{var r=JSON.parse(e);return t(ut(r.method,Nn({objectIDs:[this.objectID]},r.payload)))}catch(e){throw new Error('\nThe insights helper expects a JSON object of the format:\n{ "method": "method-name", "payload": { "eventName": "name of the event" } }')}}}}var Cn="4.65.0";function Un(e){return Un="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Un(e)}function Hn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function qn(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Hn(Object(r),!0).forEach(function(t){Qn(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Hn(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Wn(e,t){return Wn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Wn(e,t)}function Bn(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Vn(e){return Vn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Vn(e)}function Qn(e,t,r){return(t=$n(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function $n(e){var t=function(e,t){if("object"!==Un(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Un(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Un(t)?t:String(t)}var Gn=ie({name:"instantsearch"});function Kn(){return"#"}var Yn={preserveSharedStateOnUnmount:!1,persistHierarchicalRootCount:!1},Xn=/*#__PURE__*/function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Wn(e,t)}(s,e);var t,r,n,i,o=(n=s,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}(),function(){var e,t=Vn(n);if(i){var r=Vn(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Un(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Bn(e)}(this,e)});function s(e){var t,r;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),Qn(Bn(r=o.call(this)),"client",void 0),Qn(Bn(r),"indexName",void 0),Qn(Bn(r),"insightsClient",void 0),Qn(Bn(r),"onStateChange",null),Qn(Bn(r),"future",void 0),Qn(Bn(r),"helper",void 0),Qn(Bn(r),"mainHelper",void 0),Qn(Bn(r),"mainIndex",void 0),Qn(Bn(r),"started",void 0),Qn(Bn(r),"templatesConfig",void 0),Qn(Bn(r),"renderState",{}),Qn(Bn(r),"_stalledSearchDelay",void 0),Qn(Bn(r),"_searchStalledTimer",void 0),Qn(Bn(r),"_initialUiState",void 0),Qn(Bn(r),"_initialResults",void 0),Qn(Bn(r),"_createURL",void 0),Qn(Bn(r),"_searchFunction",void 0),Qn(Bn(r),"_mainHelperSearch",void 0),Qn(Bn(r),"_insights",void 0),Qn(Bn(r),"middleware",[]),Qn(Bn(r),"sendEventToInsights",void 0),Qn(Bn(r),"status","idle"),Qn(Bn(r),"error",void 0),Qn(Bn(r),"scheduleSearch",re(function(){r.started&&r.mainHelper.search()})),Qn(Bn(r),"scheduleRender",re(function(){var e,t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];null!==(e=r.mainHelper)&&void 0!==e&&e.hasPendingRequests()||(clearTimeout(r._searchStalledTimer),r._searchStalledTimer=null,t&&(r.status="idle",r.error=void 0)),r.mainIndex.render({instantSearchInstance:Bn(r)}),r.emit("render")})),Qn(Bn(r),"onInternalStateChange",re(function(){var e=r.mainIndex.getWidgetUiState({});r.middleware.forEach(function(t){t.instance.onStateChange({uiState:e})})})),r.setMaxListeners(100);var n=e.indexName,i=void 0===n?"":n,u=e.numberLocale,f=e.initialUiState,l=void 0===f?{}:f,h=e.routing,d=void 0===h?null:h,p=e.insights,v=void 0===p?void 0:p,m=e.searchFunction,g=e.stalledSearchDelay,y=void 0===g?200:g,b=e.searchClient,w=void 0===b?null:b,S=e.insightsClient,O=void 0===S?null:S,j=e.onStateChange,P=void 0===j?null:j,R=e.future,_=void 0===R?qn(qn({},Yn),e.future||{}):R;if(null===w)throw new Error(Gn("The `searchClient` option is required."));if("function"!=typeof w.search)throw new Error("The `searchClient` must implement a `search` method.\n\nSee: https://www.algolia.com/doc/guides/building-search-ui/going-further/backend-search/in-depth/backend-instantsearch/js/");if("function"==typeof w.addAlgoliaAgent&&w.addAlgoliaAgent("instantsearch.js (".concat(Cn,")")),"development"==="production".NODE_ENV&&c(null===O,"`insightsClient` property has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `insights` middleware.\n\nFor more information, visit https://www.algolia.com/doc/guides/getting-insights-and-analytics/search-analytics/click-through-and-conversions/how-to/send-click-and-conversion-events-with-instantsearch/js/"),O&&"function"!=typeof O)throw new Error(Gn("The `insightsClient` option should be a function."));if("development"==="production".NODE_ENV&&c(!e.searchParameters,"The `searchParameters` option is deprecated and will not be supported in InstantSearch.js 4.x.\n\nYou can replace it with the `configure` widget:\n\n```\nsearch.addWidgets([\n  configure(".concat(JSON.stringify(e.searchParameters,null,2),")\n]);\n```\n\nSee ").concat(ne({name:"configure"}))),"development"==="production".NODE_ENV&&void 0===(null===(t=e.future)||void 0===t?void 0:t.preserveSharedStateOnUnmount)&&console.info("Starting from the next major version, InstantSearch will change how widgets state is preserved when they are removed. InstantSearch will keep the state of unmounted widgets to be usable by other widgets with the same attribute.\n\nWe recommend setting `future.preserveSharedStateOnUnmount` to true to adopt this change today.\nTo stay with the current behaviour and remove this warning, set the option to false.\n\nSee documentation: ".concat(ne({name:"instantsearch"}),"#widget-param-future\n          ")),r.client=w,r.future=_,r.insightsClient=O,r.indexName=i,r.helper=null,r.mainHelper=null,r.mainIndex=Tn({indexName:i}),r.onStateChange=P,r.started=!1,r.templatesConfig={helpers:Mn({numberLocale:u}),compileOptions:{}},r._stalledSearchDelay=y,r._searchStalledTimer=null,r._createURL=Kn,r._initialUiState=l,r._initialResults=null,r._insights=v,m&&("development"==="production".NODE_ENV&&c(!1,"The `searchFunction` option is deprecated. Use `onStateChange` instead."),r._searchFunction=m),r.sendEventToInsights=a,d){var E="boolean"==typeof d?{}:d;E.$$internal=!0,r.use(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.router,r=void 0===t?sn():t,n=e.stateMapping,i=void 0===n?{$$type:"ais.simple",stateToRoute:function(e){return Object.keys(e).reduce(function(t,r){return ln(ln({},t),{},hn({},r,dn(e[r])))},{})},routeToState:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.keys(e).reduce(function(t,r){return ln(ln({},t),{},hn({},r,dn(e[r])))},{})}}:n,a=e.$$internal,o=void 0!==a&&a;return function(e){var t=e.instantSearchInstance;t._createURL=function(e){var n=0===t.mainIndex.getWidgets().length?t._initialUiState:t.mainIndex.getWidgetUiState({}),a=Object.keys(e).reduce(function(t,r){return mn(mn({},t),{},gn({},r,e[r]))},n),o=i.stateToRoute(a);return r.createURL(o)};var n=void 0,a=t._initialUiState;return{$$type:"ais.router({router:".concat(r.$$type||"__unknown__",", stateMapping:").concat(i.$$type||"__unknown__","})"),$$internal:o,onStateChange:function(e){var t=i.stateToRoute(e.uiState);void 0!==n&&De(n,t)||(r.write(t),n=t)},subscribe:function(){t._initialUiState=mn(mn({},a),i.routeToState(r.read())),r.onUpdate(function(e){t.mainIndex.getWidgets().length>0&&t.setUiState(i.routeToState(e))})},started:function(){var e;null===(e=r.start)||void 0===e||e.call(r)},unsubscribe:function(){r.dispose()}}}}(E))}if(v){var x="boolean"==typeof v?{}:v;x.$$internal=!0,r.use(Pr(x))}return ze(function(e){var t,r;return(null===(t=e.window.navigator)||void 0===t||null===(r=t.userAgent)||void 0===r?void 0:r.indexOf("Algolia Crawler"))>-1},{fallback:function(){return!1}})&&r.use(xr({$$internal:!0})),r}return t=s,r=[{key:"_isSearchStalled",get:function(){return"development"==="production".NODE_ENV&&c(!1,'`InstantSearch._isSearchStalled` is deprecated and will be removed in InstantSearch.js 5.0.\n\nUse `InstantSearch.status === "stalled"` instead.'),"stalled"===this.status}},{key:"use",value:function(){for(var e=this,t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];var i=r.map(function(t){var r=qn({$$type:"__unknown__",$$internal:!1,subscribe:a,started:a,unsubscribe:a,onStateChange:a},t({instantSearchInstance:e}));return e.middleware.push({creator:t,instance:r}),r});return this.started&&i.forEach(function(e){e.subscribe(),e.started()}),this}},{key:"unuse",value:function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return this.middleware.filter(function(e){return t.includes(e.creator)}).forEach(function(e){return e.instance.unsubscribe()}),this.middleware=this.middleware.filter(function(e){return!t.includes(e.creator)}),this}},{key:"EXPERIMENTAL_use",value:function(){return"development"==="production".NODE_ENV&&c(!1,"The middleware API is now considered stable, so we recommend replacing `EXPERIMENTAL_use` with `use` before upgrading to the next major version."),this.use.apply(this,arguments)}},{key:"addWidget",value:function(e){return"development"==="production".NODE_ENV&&c(!1,"addWidget will still be supported in 4.x releases, but not further. It is replaced by `addWidgets([widget])`"),this.addWidgets([e])}},{key:"addWidgets",value:function(e){if(!Array.isArray(e))throw new Error(Gn("The `addWidgets` method expects an array of widgets. Please use `addWidget`."));if(e.some(function(e){return"function"!=typeof e.init&&"function"!=typeof e.render}))throw new Error(Gn("The widget definition expects a `render` and/or an `init` method."));return this.mainIndex.addWidgets(e),this}},{key:"removeWidget",value:function(e){return"development"==="production".NODE_ENV&&c(!1,"removeWidget will still be supported in 4.x releases, but not further. It is replaced by `removeWidgets([widget])`"),this.removeWidgets([e])}},{key:"removeWidgets",value:function(e){if(!Array.isArray(e))throw new Error(Gn("The `removeWidgets` method expects an array of widgets. Please use `removeWidget`."));if(e.some(function(e){return"function"!=typeof e.dispose}))throw new Error(Gn("The widget definition expects a `dispose` method."));return this.mainIndex.removeWidgets(e),this}},{key:"start",value:function(){var e=this;if(this.started)throw new Error(Gn("The `start` method has already been called once."));var t=this.mainHelper||pr(this.client,this.indexName,void 0,{persistHierarchicalRootCount:this.future.persistHierarchicalRootCount});if(t.search=function(){return e.status="loading",e.scheduleRender(!1),"development"==="production".NODE_ENV&&c(Boolean(e.indexName)||e.mainIndex.getWidgets().some(z),"No indexName provided, nor an explicit index widget in the widgets tree. This is required to be able to display results."),t.searchOnlyWithDerivedHelpers()},this._searchFunction){var r={search:function(){return new Promise(a)}};this._mainHelperSearch=t.search.bind(t),t.search=function(){var n=e.mainIndex.getHelper(),i=pr(r,n.state.index,n.state);return i.once("search",function(t){n.overrideStateWithoutTriggeringChangeEvent(t.state),e._mainHelperSearch()}),i.on("change",function(e){n.setState(e.state)}),e._searchFunction(i),t}}if(t.on("error",function(t){var r=t.error;if(!(r instanceof Error)){var n=r;r=Object.keys(n).reduce(function(e,t){return e[t]=n[t],e},new Error(n.message))}r.error=r,e.error=r,e.status="error",e.scheduleRender(!1),e.emit("error",r)}),this.mainHelper=t,this.middleware.forEach(function(e){e.instance.subscribe()}),this.mainIndex.init({instantSearchInstance:this,parent:null,uiState:this._initialUiState}),this._initialResults){!function(e,t){if(t&&("transporter"in e&&!e._cacheHydrated||e._useCache&&"function"==typeof e.addAlgoliaAgent)){var r=Object.keys(t).map(function(e){var r=t[e],n=r.state,i=r.requestParams;return r.results.map(function(e){return Ie({indexName:n.index||e.index},i||e.params?{params:Te(i||(t=e.params,t.split("&").reduce(function(e,t){var r,n=function(e){if(Array.isArray(e))return e}(r=t.split("="))||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{for(a=(r=r.call(e)).next;!(c=(n=a.call(r)).done)&&(s.push(n.value),2!==s.length);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(r)||function(e,t){if(e){if("string"==typeof e)return Ee(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Ee(e,2):void 0}}(r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=n[1];return e[n[0]]=i?decodeURIComponent(i):"",e},{})))}:{});var t})}),n=Object.keys(t).reduce(function(e,r){return e.concat(t[r].results)},[]);if("transporter"in e&&!e._cacheHydrated){e._cacheHydrated=!0;var i=e.search;e.search=function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),a=1;a<r;a++)n[a-1]=arguments[a];var o=t.map(function(e){return Ie(Ie({},e),{},{params:Te(e.params)})});return e.transporter.responsesCache.get({method:"search",args:[o].concat(n)},function(){return i.apply(void 0,[t].concat(n))})},e.transporter.responsesCache.set({method:"search",args:r},{results:n})}if(!("transporter"in e)){var a="/1/indexes/*/queries_body_".concat(JSON.stringify({requests:r}));e.cache=Ie(Ie({},e.cache),{},Ae({},a,JSON.stringify({results:Object.keys(t).map(function(e){return t[e].results})})))}}}(this.client,this._initialResults);var n=this.scheduleSearch;this.scheduleSearch=re(a),re(function(){e.scheduleSearch=n})()}else this.mainIndex.getWidgets().length>0&&this.scheduleSearch();this.helper=this.mainIndex.getHelper(),this.started=!0,this.middleware.forEach(function(e){e.instance.started()}),void 0===this._insights&&t.derivedHelpers[0].once("result",function(){e.mainIndex.getScopedResults().some(function(e){var t=e.results;return null==t?void 0:t._automaticInsights})&&e.use(Pr({$$internal:!0,$$automatic:!0}))})}},{key:"dispose",value:function(){var e;this.scheduleSearch.cancel(),this.scheduleRender.cancel(),clearTimeout(this._searchStalledTimer),this.removeWidgets(this.mainIndex.getWidgets()),this.mainIndex.dispose(),this.started=!1,this.removeAllListeners(),null===(e=this.mainHelper)||void 0===e||e.removeAllListeners(),this.mainHelper=null,this.helper=null,this.middleware.forEach(function(e){e.instance.unsubscribe()})}},{key:"scheduleStalledRender",value:function(){var e=this;this._searchStalledTimer||(this._searchStalledTimer=setTimeout(function(){e.status="stalled",e.scheduleRender()},this._stalledSearchDelay))}},{key:"setUiState",value:function(e){var t=this,r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(!this.mainHelper)throw new Error(Gn("The `start` method needs to be called before `setUiState`."));this.mainIndex.refreshUiState();var n="function"==typeof e?e(this.mainIndex.getWidgetUiState({})):e;this.onStateChange&&r?this.onStateChange({uiState:n,setUiState:function(e){Z("function"==typeof e?e(n):e,t.mainIndex),t.scheduleSearch(),t.onInternalStateChange()}}):(Z(n,this.mainIndex),this.scheduleSearch(),this.onInternalStateChange())}},{key:"getUiState",value:function(){return this.started&&this.mainIndex.refreshUiState(),this.mainIndex.getWidgetUiState({})}},{key:"createURL",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!this.started)throw new Error(Gn("The `start` method needs to be called before `createURL`."));return this._createURL(e)}},{key:"refresh",value:function(){if(!this.mainHelper)throw new Error(Gn("The `start` method needs to be called before `refresh`."));this.mainHelper.clearCache().search()}}],r&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,$n(n.key),n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),s}(gt),Jn=Xn,zn=function(e){return new Jn(e)};zn.version=Cn,zn.createInfiniteHitsSessionStorageCache=o(function(){return{read:function(e){var t=e.state,r=ze(function(e){return e.window.sessionStorage});if(!r)return null;try{var n=JSON.parse(r.getItem(vt));return n&&De(n.state,pt(t))?n.hits:null}catch(e){if(e instanceof SyntaxError)try{r.removeItem(vt)}catch(e){}return null}},write:function(e){var t=e.state,r=e.hits,n=ze(function(e){return e.window.sessionStorage});if(n)try{n.setItem(vt,JSON.stringify({state:pt(t),hits:r}))}catch(e){}}}},"import { createInfiniteHitsSessionStorageCache } from 'instantsearch.js/es/lib/infiniteHitsCache'"),zn.highlight=o(tt,"import { highlight } from 'instantsearch.js/es/helpers'"),zn.reverseHighlight=o(nt,"import { reverseHighlight } from 'instantsearch.js/es/helpers'"),zn.snippet=o(at,"import { snippet } from 'instantsearch.js/es/helpers'"),zn.reverseSnippet=o(st,"import { reverseSnippet } from 'instantsearch.js/es/helpers'"),zn.insights=ut,zn.getInsightsAnonymousUserToken=function(){return"development"==="production".NODE_ENV&&c(!1,"`getInsightsAnonymousUserToken` function has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `insights` middleware.\n\nFor more information, visit https://www.algolia.com/doc/guides/getting-insights-and-analytics/search-analytics/click-through-and-conversions/how-to/send-click-and-conversion-events-with-instantsearch/js/"),ht()},Object.defineProperty(zn,"widgets",{get:function(){throw new ReferenceError("\"instantsearch.widgets\" are not available from the ES build.\n\nTo import the widgets:\n\nimport { searchBox } from 'instantsearch.js/es/widgets'")}}),Object.defineProperty(zn,"connectors",{get:function(){throw new ReferenceError("\"instantsearch.connectors\" are not available from the ES build.\n\nTo import the connectors:\n\nimport { connectSearchBox } from 'instantsearch.js/es/connectors'")}});var Zn=zn;function ei(e){return ei="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ei(e)}function ti(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function ri(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ti(Object(r),!0).forEach(function(t){ni(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ti(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function ni(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==ei(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==ei(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===ei(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var ii=ie({name:"answers",connector:!0});function ai(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function oi(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ai(Object(r),!0).forEach(function(t){si(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ai(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function si(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==ci(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==ci(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===ci(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ci(e){return ci="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ci(e)}var ui=ie({name:"dynamic-widgets",connector:!0}),fi=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,ui()),function(r){var n=r.widgets,i=r.maxValuesPerFacet,a=void 0===i?20:i,o=r.facets,s=void 0===o?["*"]:o,u=r.transformItems,f=void 0===u?function(e){return e}:u,l=r.fallbackWidget;if(!(n&&Array.isArray(n)&&n.every(function(e){return"object"===ci(e)})))throw new Error(ui("The `widgets` option expects an array of widgets."));if(!Array.isArray(s))throw new Error(ui("The `facets` option only accepts an array of facets, you passed ".concat(JSON.stringify(s))));var h=new Map;return{$$type:"ais.dynamicWidgets",init:function(t){n.forEach(function(e){var r=function(e,t){var r,n=null===(r=e.getWidgetRenderState)||void 0===r?void 0:r.call(e,t),i=null;if(n&&n.widgetParams){var a=n.widgetParams;a.attribute?i=a.attribute:Array.isArray(a.attributes)&&(i=a.attributes[0])}if("string"!=typeof i)throw new Error("Could not find the attribute of the widget:\n\n".concat(JSON.stringify(e),"\n\nPlease check whether the widget's getWidgetRenderState returns widgetParams.attribute correctly."));return i}(e,t);h.set(r,{widget:e,isMounted:!1})}),e(oi(oi({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!0)},render:function(t){var r=t.parent,n=this.getWidgetRenderState(t),i=[],a=[];l&&n.attributesToRender.forEach(function(e){if(!h.has(e)){var t=l({attribute:e});h.set(e,{widget:t,isMounted:!1})}}),h.forEach(function(e,t){var r=e.widget,o=e.isMounted,s=n.attributesToRender.indexOf(t)>-1;!o&&s?(a.push(r),h.set(t,{widget:r,isMounted:!0})):o&&!s&&(i.push(r),h.set(t,{widget:r,isMounted:!1}))}),r.addWidgets(a),setTimeout(function(){return r.removeWidgets(i)},0),e(oi(oi({},n),{},{instantSearchInstance:t.instantSearchInstance}),!1)},dispose:function(e){var r=e.parent,n=[];h.forEach(function(e){e.isMounted&&n.push(e.widget)}),r.removeWidgets(n),t()},getWidgetSearchParameters:function(e){return s.reduce(function(e,t){return e.addFacet(t)},e.setQueryParameters({maxValuesPerFacet:Math.max(a||0,e.maxValuesPerFacet||0)}))},getRenderState:function(e,t){return oi(oi({},e),{},{dynamicWidgets:this.getWidgetRenderState(t)})},getWidgetRenderState:function(e){var t,n,i,o,s=e.results,u=e.state;if(!s)return{attributesToRender:[],widgetParams:r};var l=f(null!==(t=null===(n=s.renderingContent)||void 0===n||null===(i=n.facetOrdering)||void 0===i||null===(o=i.facets)||void 0===o?void 0:o.order)&&void 0!==t?t:[],{results:s});if(!Array.isArray(l))throw new Error(ui("The `transformItems` option expects a function that returns an Array."));return"development"==="production".NODE_ENV&&c(a>=(u.maxValuesPerFacet||0),"The maxValuesPerFacet set by dynamic widgets (".concat(a,") is smaller than one of the limits set by a widget (").concat(u.maxValuesPerFacet,"). This causes a mismatch in query parameters and thus an extra network request when that widget is mounted.")),"development"==="production".NODE_ENV&&c(l.length<=20||void 0!==r.facets,"More than ".concat(20," facets are requested to be displayed without explicitly setting which facets to retrieve. This could have a performance impact. Set \"facets\" to [] to do two smaller network requests, or explicitly to ['*'] to avoid this warning.")),{attributesToRender:l,widgetParams:r}}}}};function li(e){return li="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},li(e)}function hi(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function di(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function pi(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?di(Object(r),!0).forEach(function(t){vi(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):di(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function vi(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==li(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==li(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===li(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var mi=ie({name:"clear-refinements",connector:!0});function gi(e){return gi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},gi(e)}function yi(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function bi(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function wi(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?bi(Object(r),!0).forEach(function(t){Si(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):bi(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Si(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==gi(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==gi(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===gi(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Oi=ie({name:"current-refinements",connector:!0});function ji(e){var t=e.results,r=e.helper,n=e.indexId,i=e.includedAttributes,a=e.excludedAttributes,o=-1!==(i||[]).indexOf("query")||-1===(a||[]).indexOf("query"),s=i?function(e){return-1!==i.indexOf(e.attribute)}:function(e){return-1===a.indexOf(e.attribute)},c=ve(t,r.state,o).map(_i).filter(s);return c.reduce(function(e,t){return[].concat(function(e){if(Array.isArray(e))return yi(e)}(i=e.filter(function(e){return e.attribute!==t.attribute}))||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(i)||function(e,t){if(e){if("string"==typeof e)return yi(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?yi(e,t):void 0}}(i)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),[{indexName:r.state.index,indexId:n,attribute:t.attribute,label:t.attribute,refinements:c.filter(function(e){return e.attribute===t.attribute}).sort(function(e,t){return"numeric"===e.type?e.value-t.value:0}),refine:function(e){return Ri(r,e)}}]);var i},[])}function Pi(e,t){switch(e=e.resetPage(),t.type){case"facet":return e.removeFacetRefinement(t.attribute,String(t.value));case"disjunctive":return e.removeDisjunctiveFacetRefinement(t.attribute,String(t.value));case"hierarchical":return e.removeHierarchicalFacetRefinement(t.attribute);case"exclude":return e.removeExcludeRefinement(t.attribute,String(t.value));case"numeric":return e.removeNumericRefinement(t.attribute,t.operator,String(t.value));case"tag":return e.removeTagRefinement(String(t.value));case"query":return e.setQueryParameter("query","");default:return"development"==="production".NODE_ENV&&c(!1,'The refinement type "'.concat(t.type,'" does not exist and cannot be cleared from the current refinements.')),e}}function Ri(e,t){e.setState(Pi(e.state,t)).search()}function _i(e){var t=function(e){return"numeric"===e.type?Number(e.name):"escapedValue"in e?e.escapedValue:e.name}(e),r=e.operator?"".concat(function(e){switch(e){case">=":return"≥";case"<=":return"≤";default:return e}}(e.operator)," ").concat(e.name):e.name,n={attribute:e.attribute,type:e.type,value:t,label:r};return void 0!==e.operator&&(n.operator=e.operator),void 0!==e.count&&(n.count=e.count),void 0!==e.exhaustive&&(n.exhaustive=e.exhaustive),n}function Ei(e){return Ei="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ei(e)}var xi=["name","escapedValue","data","path"];function Ii(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Ai(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Ii(Object(r),!0).forEach(function(t){Ti(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ii(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Ti(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Ei(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Ei(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Ei(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ki(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var Di=ie({name:"hierarchical-menu",connector:!0}),Fi=["name:asc"];function Ni(e){return Ni="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ni(e)}function Li(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Mi(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Li(Object(r),!0).forEach(function(t){Ci(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Li(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Ci(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Ni(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Ni(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Ni(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ui=ie({name:"hits",connector:!0}),Hi=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,Ui()),function(r){var n,i,a=r||{},o=a.escapeHTML,s=void 0===o||o,c=a.transformItems,u=void 0===c?function(e){return e}:c;return{$$type:"ais.hits",init:function(t){e(Mi(Mi({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!0)},render:function(t){var r=this.getWidgetRenderState(t);e(Mi(Mi({},r),{},{instantSearchInstance:t.instantSearchInstance}),!1),r.sendEvent("view:internal",r.hits)},getRenderState:function(e,t){return Mi(Mi({},e),{},{hits:this.getWidgetRenderState(t)})},getWidgetRenderState:function(e){var t=e.results,a=e.helper,o=e.instantSearchInstance;if(n||(n=X({instantSearchInstance:o,getIndex:function(){return a.getIndex()},widgetType:this.$$type})),i||(i=J({getIndex:function(){return a.getIndex()},widgetType:this.$$type,instantSearchInstance:o})),!t)return{hits:[],results:void 0,sendEvent:n,bindEvent:i,widgetParams:r};s&&t.hits.length>0&&(t.hits=N(t.hits));var c=Re(we(t.hits,t.page,t.hitsPerPage),t.queryID);return{hits:u(c,{results:t}),results:t,sendEvent:n,bindEvent:i,widgetParams:r}},dispose:function(e){var r=e.state;return t(),s?r.setQueryParameters(Object.keys(T).reduce(function(e,t){return Mi(Mi({},e),{},Ci({},t,void 0))},{})):r},getWidgetSearchParameters:function(e){return s?e.setQueryParameters(T):e}}}};function qi(e){return qi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},qi(e)}function Wi(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Bi(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Wi(Object(r),!0).forEach(function(t){Vi(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Wi(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Vi(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==qi(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==qi(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===qi(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Qi(e){return function(t,r){return e(function(e,r){var n=e.results,i=e.hits,a=e.instantSearchInstance;if(n&&i&&a){var o=function(e,t,r){return function(n){for(var i=arguments.length,a=new Array(i>1?i-1:0),o=1;o<i;o++)a[o-1]=arguments[o];var s=a[0];if("development"==="production".NODE_ENV&&c(!1,"`insights` function has been deprecated. It is still supported in 4.x releases, but not further. It is replaced by the `insights` middleware.\n\nFor more information, visit https://www.algolia.com/doc/guides/getting-insights-and-analytics/search-analytics/click-through-and-conversions/how-to/send-click-and-conversion-events-with-instantsearch/js/"),!e){var u=ie({name:"instantsearch"});throw new Error(u("The `insightsClient` option has not been provided to `instantsearch`."))}if(!Array.isArray(s.objectIDs))throw new TypeError("Expected `objectIDs` to be an array.");var f=function(e){var t,r=e.method,n=e.objectIDs,i=e.results.index,a=(t=e.hits,n.map(function(e){var r=oe(t,function(t){return t.objectID===e});if(void 0===r)throw new Error('Could not find objectID "'.concat(e,'" passed to `clickedObjectIDsAfterSearch` in the returned hits. This is necessary to infer the absolute position and the query ID.'));return r})),o=function(e){var t=Le(e.map(function(e){return e.__queryID}));if(t.length>1)throw new Error("Insights currently allows a single `queryID`. The `objectIDs` provided map to multiple `queryID`s.");var r=t[0];if("string"!=typeof r)throw new Error("Could not infer `queryID`. Ensure InstantSearch `clickAnalytics: true` was added with the Configure widget.\n\nSee: https://alg.li/lNiZZ7");return r}(a);switch(r){case"clickedObjectIDsAfterSearch":var s=function(e){return e.map(function(e){return e.__position})}(a);return{index:i,queryID:o,objectIDs:n,positions:s};case"convertedObjectIDsAfterSearch":return{index:i,queryID:o,objectIDs:n};default:throw new Error('Unsupported method passed to insights: "'.concat(r,'".'))}}({method:n,results:t,hits:r,objectIDs:s.objectIDs});e(n,Bi(Bi({},f),s))}}(a.insightsClient,n,i);return t(Bi(Bi({},e),{},{insights:o}),r)}return t(e,r)},r)}}var $i=Qi(Hi);function Gi(e){return Gi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Gi(e)}function Ki(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Yi(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Xi(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Yi(Object(r),!0).forEach(function(t){Ji(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Yi(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Ji(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Gi(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Gi(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Gi(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var zi=ie({name:"hits-per-page",connector:!0});function Zi(e){return Zi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Zi(e)}var ea=["page"],ta=["clickAnalytics","userToken"];function ra(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function na(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ra(Object(r),!0).forEach(function(t){ia(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ra(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function ia(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Zi(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Zi(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Zi(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function aa(e){return function(e){if(Array.isArray(e))return oa(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return oa(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?oa(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function oa(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function sa(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},a=Object.keys(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}var ca=ie({name:"infinite-hits",connector:!0});function ua(e){return sa(e||{},ea)}function fa(e){return sa(e||{},ta)}var la=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,ca()),function(r){var n,i,a,o,s,c,u=r||{},f=u.escapeHTML,l=void 0===f||f,h=u.transformItems,d=void 0===h?function(e){return e}:h,p=u.cache,v=void 0===p?(n=null,i=null,{read:function(e){return De(i,ua(e.state))?n:null},write:function(e){var t=e.hits;i=ua(e.state),n=t}}):p,m=function(e,t){var r=e.page,n=void 0===r?0:r,i=Object.keys(t).map(Number);return 0===i.length?n:Math.min.apply(Math,[n].concat(aa(i)))},g=function(e,t){var r=e.page,n=void 0===r?0:r,i=Object.keys(t).map(Number);return 0===i.length?n:Math.max.apply(Math,[n].concat(aa(i)))};return{$$type:"ais.infiniteHits",init:function(t){e(na(na({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!0)},render:function(t){var r=t.instantSearchInstance,n=this.getWidgetRenderState(t);e(na(na({},n),{},{instantSearchInstance:r}),!1),s("view:internal",n.currentPageHits)},getRenderState:function(e,t){return na(na({},e),{},{infiniteHits:this.getWidgetRenderState(t)})},getWidgetRenderState:function(e){var t,n=e.results,i=e.helper,u=e.state,f=e.instantSearchInstance,h=[],p=e.parent.getPreviousState()||u,y=v.read({state:fa(p)})||{};if(n){var b,w,S=p.page,O=void 0===S?0:S;l&&n.hits.length>0&&(n.hits=N(n.hits));var j=Re(we(n.hits,n.page,n.hitsPerPage),n.queryID),P=d(j,{results:n}),R=!1;Ne(f.mainIndex,function(e){!R&&e.getWidgets().some(function(e){return"ais.dynamicWidgets"===e.$$type})&&(R=!0)});var _=!(null!==(b=p.disjunctiveFacets)&&void 0!==b&&b.length||(p.facets||[]).filter(function(e){return"*"!==e}).length||null!==(w=p.hierarchicalFacets)&&void 0!==w&&w.length);void 0!==y[O]||n.__isArtificial||"idle"!==f.status||R&&_||(y[O]=P,v.write({state:fa(p),hits:y})),h=P,t=0===m(p,y)}else a=function(e){return function(){e.overrideStateWithoutTriggeringChangeEvent(na(na({},e.state),{},{page:m(e.state,v.read({state:fa(e.state)})||{})-1})).searchWithoutTriggeringOnStateChange()}}(i),o=function(e){return function(){e.setPage(g(e.state,v.read({state:fa(e.state)})||{})+1).search()}}(i),s=X({instantSearchInstance:f,getIndex:function(){return i.getIndex()},widgetType:this.$$type}),c=J({getIndex:function(){return i.getIndex()},widgetType:this.$$type,instantSearchInstance:f}),t=void 0===p.page||0===m(p,y);var E=function(e){return Object.keys(e).map(Number).sort(function(e,t){return e-t}).reduce(function(t,r){return t.concat(e[r])},[])}(y),x=!n||n.nbPages<=g(p,y)+1;return{hits:E,currentPageHits:h,sendEvent:s,bindEvent:c,results:n,showPrevious:a,showMore:o,isFirstPage:t,isLastPage:x,widgetParams:r}},dispose:function(e){var r=e.state;t();var n=r.setQueryParameter("page",void 0);return l?n.setQueryParameters(Object.keys(T).reduce(function(e,t){return na(na({},e),{},ia({},t,void 0))},{})):n},getWidgetUiState:function(e,t){var r=t.searchParameters.page||0;return r?na(na({},e),{},{page:r+1}):e},getWidgetSearchParameters:function(e,t){var r=t.uiState,n=e;return l&&(n=e.setQueryParameters(T)),n.setQueryParameter("page",r.page?r.page-1:0)}}}},ha=Qi(la),da=["name","escapedValue","path"];function pa(e){return pa="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},pa(e)}function va(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{if(a=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;c=!1}else for(;!(c=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return ma(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?ma(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ma(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function ga(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function ya(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ga(Object(r),!0).forEach(function(t){ba(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ga(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function ba(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==pa(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==pa(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===pa(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var wa=ie({name:"menu",connector:!0}),Sa=["isRefined","name:asc"];function Oa(e){return Oa="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Oa(e)}function ja(e,t){if(e){if("string"==typeof e)return Pa(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Pa(e,t):void 0}}function Pa(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Ra(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function _a(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Ra(Object(r),!0).forEach(function(t){Ea(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ra(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Ea(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Oa(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Oa(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Oa(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var xa=ie({name:"numeric-menu",connector:!0});function Ia(e,t,r){var n=e.getNumericRefinements(t);return void 0!==r.start&&void 0!==r.end?r.start===r.end?Ta(n,"=",r.start):Ta(n,">=",r.start)&&Ta(n,"<=",r.end):void 0!==r.start?Ta(n,">=",r.start):void 0!==r.end?Ta(n,"<=",r.end):void 0===r.start&&void 0===r.end&&Object.keys(n).every(function(e){return 0===(n[e]||[]).length})}function Aa(e,t,r){var n=e,i=JSON.parse(decodeURI(r)),a=n.getNumericRefinements(t);if(void 0===i.start&&void 0===i.end)return n.removeNumericRefinement(t);if(Ia(n,t,i)||(n=n.removeNumericRefinement(t)),void 0!==i.start&&void 0!==i.end){if(i.start>i.end)throw new Error("option.start should be > to option.end");if(i.start===i.end)return Ta(a,"=",i.start)?n.removeNumericRefinement(t,"=",i.start):n.addNumericRefinement(t,"=",i.start)}return void 0!==i.start&&(Ta(a,">=",i.start)&&(n=n.removeNumericRefinement(t,">=",i.start)),n=n.addNumericRefinement(t,">=",i.start)),void 0!==i.end&&(Ta(a,"<=",i.end)&&(n=n.removeNumericRefinement(t,"<=",i.end)),n=n.addNumericRefinement(t,"<=",i.end)),"number"==typeof n.page&&(n.page=0),n}function Ta(e,t,r){return void 0!==e[t]&&e[t].includes(r)}function ka(e){return ka="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ka(e)}function Da(e,t,r){return(t=Fa(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Fa(e){var t=function(e,t){if("object"!==ka(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==ka(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===ka(t)?t:String(t)}var Na=/*#__PURE__*/function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),Da(this,"currentPage",void 0),Da(this,"total",void 0),Da(this,"padding",void 0),this.currentPage=t.currentPage,this.total=t.total,this.padding=t.padding}var t,r;return t=e,(r=[{key:"pages",value:function(){var e=this.total,t=this.currentPage,r=this.padding;if(0===e)return[0];var n=this.nbPagesDisplayed(r,e);if(n===e)return Ve({end:e});var i=this.calculatePaddingLeft(t,r,e,n);return Ve({start:t-i,end:t+(n-i)})}},{key:"nbPagesDisplayed",value:function(e,t){return Math.min(2*e+1,t)}},{key:"calculatePaddingLeft",value:function(e,t,r,n){return e<=t?e:e>=r-t?n-(r-e):t}},{key:"isLastPage",value:function(){return this.currentPage===this.total-1||0===this.total}},{key:"isFirstPage",value:function(){return 0===this.currentPage}}])&&function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,Fa(n.key),n)}}(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),e}();function La(e){return La="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},La(e)}function Ma(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Ca(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Ma(Object(r),!0).forEach(function(t){Ua(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ma(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Ua(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==La(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==La(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===La(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ha=ie({name:"pagination",connector:!0});function qa(e){return qa="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},qa(e)}function Wa(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Ba(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Wa(Object(r),!0).forEach(function(t){Va(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Wa(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Va(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==qa(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==qa(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===qa(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Qa(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{if(a=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;c=!1}else for(;!(c=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return $a(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?$a(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function $a(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var Ga=ie({name:"range-input",connector:!0},{name:"range-slider",connector:!0});function Ka(e){var t=e.min,r=e.max,n=Math.pow(10,e.precision);return{min:t?Math.floor(t*n)/n:t,max:r?Math.ceil(r*n)/n:r}}function Ya(e){return Ya="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ya(e)}var Xa=["name","escapedValue"],Ja=["escapedValue","value"];function za(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Za(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?za(Object(r),!0).forEach(function(t){eo(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):za(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function eo(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Ya(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Ya(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Ya(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function to(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},a=Object.keys(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}var ro=ie({name:"refinement-list",connector:!0}),no=["isRefined","count:desc","name:asc"];function io(e){return io="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},io(e)}function ao(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function oo(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ao(Object(r),!0).forEach(function(t){so(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ao(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function so(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==io(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==io(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===io(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var co=ie({name:"search-box",connector:!0}),uo=function(e,t){return t(e)};function fo(e){return fo="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},fo(e)}function lo(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function ho(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?lo(Object(r),!0).forEach(function(t){po(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):lo(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function po(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==fo(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==fo(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===fo(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var vo=ie({name:"sort-by",connector:!0});function mo(e){return mo="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},mo(e)}function go(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function yo(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?go(Object(r),!0).forEach(function(t){bo(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):go(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function bo(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==mo(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==mo(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===mo(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function wo(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{if(a=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;c=!1}else for(;!(c=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(e,t)||So(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function So(e,t){if(e){if("string"==typeof e)return Oo(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Oo(e,t):void 0}}function Oo(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var jo=ie({name:"rating-menu",connector:!0}),Po="ais.ratingMenu",Ro=1e3;function _o(e){return _o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_o(e)}function Eo(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function xo(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Eo(Object(r),!0).forEach(function(t){Io(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Eo(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Io(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==_o(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==_o(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===_o(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ao=ie({name:"stats",connector:!0});function To(e){return To="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},To(e)}function ko(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Do(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ko(Object(r),!0).forEach(function(t){Fo(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ko(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Fo(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==To(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==To(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===To(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function No(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var Lo=ie({name:"toggle-refinement",connector:!0}),Mo="ais.toggleRefinement";function Co(e){return Co="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Co(e)}function Uo(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Ho(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Uo(Object(r),!0).forEach(function(t){qo(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Uo(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function qo(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Co(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Co(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Co(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Wo(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{if(a=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;c=!1}else for(;!(c=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Bo(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Bo(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Bo(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var Vo=ie({name:"breadcrumb",connector:!0});function Qo(e){return e.reduce(function(e,t){return t.isRefined&&(e.push({label:t.name,value:t.escapedValue}),Array.isArray(t.data)&&(e=e.concat(Qo(t.data)))),e},[])}function $o(e){return $o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},$o(e)}function Go(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Ko(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Go(Object(r),!0).forEach(function(t){Yo(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Go(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Yo(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==$o(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==$o(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===$o(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Xo=ie({name:"geo-search",connector:!0});function Jo(e){return e.insideBoundingBox||""}function zo(e,t){return e.setQueryParameter("insideBoundingBox",t)}var Zo="ais.geoSearch";function es(e){return es="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},es(e)}function ts(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function rs(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ts(Object(r),!0).forEach(function(t){ns(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ts(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function ns(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==es(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==es(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===es(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var is=ie({name:"powered-by",connector:!0});function as(e){return as="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},as(e)}function os(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function ss(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?os(Object(r),!0).forEach(function(t){cs(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):os(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function cs(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==as(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==as(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===as(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var us=ie({name:"configure",connector:!0});function fs(e,t){return e.setQueryParameters(Object.keys(t.searchParameters).reduce(function(e,t){return ss(ss({},e),{},cs({},t,void 0))},{}))}var ls=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:a,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return function(r){if(!r||!R(r.searchParameters))throw new Error(us("The `searchParameters` option expects an object."));var n={};return{$$type:"ais.configure",init:function(t){var r=t.instantSearchInstance;e(ss(ss({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(ss(ss({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(e){var n=e.state;return t(),fs(n,r)},getRenderState:function(e,t){var r,n=this.getWidgetRenderState(t);return ss(ss({},e),{},{configure:ss(ss({},n),{},{widgetParams:ss(ss({},n.widgetParams),{},{searchParameters:We(new pr.SearchParameters(null===(r=e.configure)||void 0===r?void 0:r.widgetParams.searchParameters),new pr.SearchParameters(n.widgetParams.searchParameters)).getQueryParams()})})})},getWidgetRenderState:function(e){return n.refine||(n.refine=(t=e.helper,function(e){var n=fs(t.state,r),i=We(n,new pr.SearchParameters(e));r.searchParameters=e,t.setState(i).search()})),{refine:n.refine,widgetParams:r};var t},getWidgetSearchParameters:function(e,t){return We(e,new pr.SearchParameters(ss(ss({},t.uiState.configure),r.searchParameters)))},getWidgetUiState:function(e){return ss(ss({},e),{},{configure:ss(ss({},e.configure),r.searchParameters)})}}}};function hs(e){return hs="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},hs(e)}function ds(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function ps(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ds(Object(r),!0).forEach(function(t){vs(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ds(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function vs(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==hs(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==hs(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===hs(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ms(e){return function(e){if(Array.isArray(e))return gs(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return gs(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?gs(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function gs(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var ys=ie({name:"configure-related-items",connector:!0});function bs(e){var t=e.attributeValue,r=e.attributeScore;return"".concat(e.attributeName,":").concat(t,"<score=").concat(r||1,">")}function ws(e){return ws="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ws(e)}function Ss(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Os(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Ss(Object(r),!0).forEach(function(t){js(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ss(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function js(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==ws(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==ws(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===ws(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ps=ie({name:"autocomplete",connector:!0});function Rs(e){return Rs="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Rs(e)}function _s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Es(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?_s(Object(r),!0).forEach(function(t){xs(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):_s(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function xs(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Rs(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Rs(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Rs(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Is(e){return function(e){if(Array.isArray(e))return As(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return As(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?As(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function As(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var Ts=ie({name:"query-rules",connector:!0});function ks(e){var t=this.helper,r=this.initialRuleContexts,n=this.transformRuleContexts,i=e.state,a=i.ruleContexts||[],o=function(e){var t=e.helper,r=e.sharedHelperState,n=e.trackedFilters;return Object.keys(n).reduce(function(e,i){var a=ve(t.lastResults||{},r,!0).filter(function(e){return e.attribute===i}).map(function(e){return e.numericValue||e.name}),o=(0,n[i])(a);return[].concat(Is(e),Is(a.filter(function(e){return o.includes(e)}).map(function(e){return"ais-".concat(i,"-").concat(e).replace(/[^a-z0-9-_]+/gi,"_")})))},[])}({helper:t,sharedHelperState:i,trackedFilters:this.trackedFilters}),s=[].concat(Is(r),Is(o));"development"==="production".NODE_ENV&&c(s.length<=10,"\nThe maximum number of `ruleContexts` is 10. They have been sliced to that limit.\nConsider using `transformRuleContexts` to minimize the number of rules sent to Algolia.\n");var u=n(s).slice(0,10);De(a,u)||t.overrideStateWithoutTriggeringChangeEvent(Es(Es({},i),{},{ruleContexts:u}))}function Ds(e){return Ds="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ds(e)}function Fs(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Ns(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Fs(Object(r),!0).forEach(function(t){Ls(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Fs(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function Ls(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Ds(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Ds(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Ds(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ms=function(e){var t,r=e.searchAsYouSpeak,n=e.language,i=e.onQueryChange,a=e.onStateChange,o=window.webkitSpeechRecognition||window.SpeechRecognition,s=function(e){return{status:e,transcript:"",isSpeechFinal:!1,errorCode:void 0}},c=s("initial"),u=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};c=Ns(Ns({},c),e),a()},f=function(){u(s(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"initial"))},l=function(){u({status:"waiting"})},h=function(e){u({status:"error",errorCode:e.error})},d=function(e){u({status:"recognizing",transcript:e.results[0]&&e.results[0][0]&&e.results[0][0].transcript||"",isSpeechFinal:e.results[0]&&e.results[0].isFinal}),r&&c.transcript&&i(c.transcript)},p=function(){c.errorCode||!c.transcript||r||i(c.transcript),"error"!==c.status&&u({status:"finished"})},v=function(){t&&(t.stop(),t.removeEventListener("start",l),t.removeEventListener("error",h),t.removeEventListener("result",d),t.removeEventListener("end",p),t=void 0)};return{getState:function(){return c},isBrowserSupported:function(){return Boolean(o)},isListening:function(){return"askingPermission"===c.status||"waiting"===c.status||"recognizing"===c.status},startListening:function(){(t=new o)&&(f("askingPermission"),t.interimResults=!0,n&&(t.lang=n),t.addEventListener("start",l),t.addEventListener("error",h),t.addEventListener("result",d),t.addEventListener("end",p),t.start())},stopListening:function(){v(),f("finished")},dispose:v}};function Cs(e){return Cs="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Cs(e)}function Us(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Hs(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Us(Object(r),!0).forEach(function(t){qs(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Us(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function qs(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Cs(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Cs(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Cs(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Ws=ie({name:"voice-search",connector:!0});function Bs(e){return Bs="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Bs(e)}function Vs(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Qs(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Vs(Object(r),!0).forEach(function(t){$s(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Vs(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function $s(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==Bs(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!==Bs(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Bs(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Gs=o(function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,ii()),function(r){var n=r||{},i=n.queryLanguages,a=n.attributesForPrediction,o=n.nbHits,s=void 0===o?1:o,c=n.renderDebounceTime,u=void 0===c?100:c,f=n.searchDebounceTime,l=void 0===f?100:f,h=n.escapeHTML,d=void 0===h||h,p=n.extraParameters,v=void 0===p?{}:p;if(!i||0===i.length)throw new Error(ii("The `queryLanguages` expects an array of strings."));var m,g,y,b,w=(m=-1,g=-1,y=void 0,function(e){var t=++m;return Promise.resolve(e).then(function(e){return y&&t<g?y:(g=t,y=e,e)})}),S=[],O=!1,j=ee(e,u);return{$$type:"ais.answers",init:function(t){var r=t.instantSearchInstance.client.initIndex(t.state.index);if(!function(e){return"function"==typeof e.findAnswers}(r))throw new Error(ii("`algoliasearch` >= 4.8.0 required."));b=ee(r.findAnswers,l),e(ri(ri({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!0)},render:function(t){var r=this,n=t.state.query;if(!n)return S=[],O=!1,void e(ri(ri({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!1);S=[],O=!0,e(ri(ri({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!1),w(b(n,i,ri(ri({},v),{},{nbHits:s,attributesForPrediction:a}))).then(function(e){if(e){d&&e.hits.length>0&&(e.hits=N(e.hits));var n=Re(we(e.hits,0,s),e.queryID);S=n,O=!1,j(ri(ri({},r.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!1)}})},getRenderState:function(e,t){return ri(ri({},e),{},{answers:this.getWidgetRenderState(t)})},getWidgetRenderState:function(){return{hits:S,isLoading:O,widgetParams:r}},dispose:function(e){var r=e.state;return t(),r},getWidgetSearchParameters:function(e){return e}}}},"answers is no longer supported"),Ks=o(fi,"use connectDynamicWidgets");function Ys(){return Ys=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Ys.apply(this,arguments)}var Xs=["host","publicKey"],Js=function(e,t,r){var n=function(n,i){var a=i.host,o=i.publicKey,s=function(e,t){if(null==e)return{};var r,n,i={},a=Object.keys(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||(i[r]=e[r]);return i}(i,Xs),c=s.indexName,u={router:sn({cleanUrlOnDispose:!0,getLocation:function(){return window.location},createURL:function(e){var t=e.qsModule,r=e.routeState,n=e.location,i=""+n.origin+n.pathname,a={};return r.q&&(a.q=r.q.split(" ").map(encodeURIComponent).join("+")),r.Online&&(a.online=!0),r.Age&&(a.age=r.Age),1!==r.page&&(a.page=r.page),r.Site&&(a.site=r.Site.map(encodeURIComponent)),r.Gender&&(a.gender=r.Gender.map(encodeURIComponent)),r.Ethnicity&&(a.ethnicity=r.Ethnicity.map(encodeURIComponent)),r.Languages&&(a.language=r.Languages.map(encodeURIComponent)),r.Tags&&(a.tag=r.Tags.map(encodeURIComponent)),r.Body&&(a.body=r.Body.map(encodeURIComponent)),r.Breast&&(a.breast=r.Breast.map(encodeURIComponent)),r.Hair&&(a.hair=r.Hair.map(encodeURIComponent)),""+i+t.stringify(a,{addQueryPrefix:!0,arrayFormat:"repeat"})},parseURL:function(e){var t=e.qsModule,r=e.location;r.pathname.match(/(.*?)\/?$/);var n=t.parse(r.search.slice(1)),i=n.q,a=void 0===i?"":i,o=n.page,s=n.site,c=void 0===s?[]:s,u=n.gender,f=void 0===u?[]:u,l=n.ethnicity,h=void 0===l?[]:l,d=n.language,p=void 0===d?[]:d,v=n.tag,m=void 0===v?[]:v,g=n.body,y=void 0===g?[]:g,b=n.breast,w=void 0===b?[]:b,S=n.hair,O=void 0===S?[]:S,j=n.online,P=void 0!==j&&j,R=n.age,_=void 0===R?"":R,E=Array.isArray(c)?c:[c].filter(Boolean),x=Array.isArray(f)?f:[f].filter(Boolean),I=Array.isArray(h)?h:[h].filter(Boolean),A=Array.isArray(p)?p:[p].filter(Boolean),T=Array.isArray(m)?m:[m].filter(Boolean),k=Array.isArray(y)?y:[y].filter(Boolean),D=Array.isArray(w)?w:[w].filter(Boolean),F=Array.isArray(O)?O:[O].filter(Boolean),N="true"===P;return{q:a.split("+").map(decodeURIComponent).join(" "),online:N,page:o,site:E.map(decodeURIComponent),gender:x.map(decodeURIComponent),ethnicity:I.map(decodeURIComponent),language:A.map(decodeURIComponent),tag:T.map(decodeURIComponent),body:k.map(decodeURIComponent),breast:D.map(decodeURIComponent),hair:F.map(decodeURIComponent),age:_}}}),stateMapping:{stateToRoute:function(e){var t=e[c]||{};return{q:t.query,page:t.page,Site:t.refinementList&&t.refinementList.Site,Gender:t.refinementList&&t.refinementList.Gender,Ethnicity:t.refinementList&&t.refinementList.Ethnicity,Languages:t.refinementList&&t.refinementList.Languages,Tags:t.refinementList&&t.refinementList.Tags,Body:t.refinementList&&t.refinementList.Body,Breast:t.refinementList&&t.refinementList.Breast,Hair:t.refinementList&&t.refinementList.Hair,Online:t.toggle&&t.toggle.Online,Age:t.range&&t.range.Age}},routeToState:function(e){var t,r,n,i,a,o,u,f,l,h,d,p,v=s.initialUiState||{},m=v[c]||{};return v[c]?Ys({},v,((d={})[c]={query:e.q||m.query,page:e.page||m.page,refinementList:{Site:e.Site||(null==(t=m.refinementList)?void 0:t.Site),Gender:e.Gender||(null==(r=m.refinementList)?void 0:r.Gender),Ethnicity:e.Ethnicity||(null==(n=m.refinementList)?void 0:n.Ethnicity),Languages:e.Languages||(null==(i=m.refinementList)?void 0:i.Languages),Tags:e.Tags||(null==(a=m.refinementList)?void 0:a.Tags),Body:e.Body||(null==(o=m.refinementList)?void 0:o.Body),Breast:e.Breast||(null==(u=m.refinementList)?void 0:u.Breast),Hair:e.Hair||(null==(f=m.refinementList)?void 0:f.Hair)},toggle:{Online:e.Online||(null==(l=m.toggle)?void 0:l.Online)},range:{Age:e.Age||(null==(h=m.range)?void 0:h.Age)}},d)):((p={})[c]={query:e.q,page:e.page,refinementList:{Site:e.site,Gender:e.gender,Ethnicity:e.ethnicity,Languages:e.language,Tags:e.tag,Body:e.body,Breast:e.breast,Hair:e.hair},toggle:{Online:e.online},range:{Age:e.age}},p)}}},f=!0,l=t(Ys({searchClient:e(a,o).searchClient,routing:u},s,{searchFunction:function(e){var t=JSON.stringify(e.state);if(this.previousSearchState!==t){var r=document.querySelector("[x-data]"),n=new CustomEvent("searchStateUpdated",{detail:{payload:{searchState:e.state,isFirstRender:f}},bubbles:!0});r.dispatchEvent(n),f=!1}this.previousSearchState=t,this.isFirstRender=!1,e.search()}}));return{widgets:[],instantsearch:t,addWidget:function(e,t,n){var i=r["connect"+e](n);this.widgets.push(i(t))},init:function(){var e=this;setTimeout(function(){l.addWidgets(e.widgets),l.start()},1)}}};return n.widget=function(e,t,r,n){return Ys({},n,{name:t,config:r,isFirstRender:!0,init:function(){var e=this;this.addWidget(t,r,function(t,r){e.isFirstRender=r,Object.entries(t).forEach(function(t){e[t[0]]=t[1]})})}})},n}(r.instantMeiliSearch,Zn,{__proto__:null,EXPERIMENTAL_connectAnswers:Gs,EXPERIMENTAL_connectDynamicWidgets:Ks,connectDynamicWidgets:fi,connectClearRefinements:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,mi()),function(r){var n=r||{},i=n.includedAttributes,o=void 0===i?[]:i,s=n.excludedAttributes,c=void 0===s?["query"]:s,u=n.transformItems,f=void 0===u?function(e){return e}:u;if(r&&r.includedAttributes&&r.excludedAttributes)throw new Error(mi("The options `includedAttributes` and `excludedAttributes` cannot be used together."));var l={refine:a,createURL:function(){return""},attributesToClear:[]},h=function(){return l.refine()},d=function(){return l.createURL()};return{$$type:"ais.clearRefinements",init:function(t){var r=t.instantSearchInstance;e(pi(pi({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(pi(pi({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(){t()},getRenderState:function(e,t){return pi(pi({},e),{},{clearRefinements:this.getWidgetRenderState(t)})},getWidgetRenderState:function(e){var t=e.createURL,n=e.results;l.attributesToClear=e.scopedResults.reduce(function(e,t){return e.concat(function(e){var t=e.scopedResult,r=e.includedAttributes,n=e.excludedAttributes,i=e.transformItems,a=e.results,o=-1!==r.indexOf("query")||-1===n.indexOf("query");return{helper:t.helper,items:i(Le(ve(t.results,t.helper.state,o).map(function(e){return e.attribute}).filter(function(e){return 0===r.length||-1!==r.indexOf(e)}).filter(function(e){return"query"===e&&o||-1===n.indexOf(e)})),{results:a})}}({scopedResult:t,includedAttributes:o,excludedAttributes:c,transformItems:f,results:n}))},[]),l.refine=function(){l.attributesToClear.forEach(function(e){var t=e.helper;t.setState(g({helper:t,attributesToClear:e.items})).search()})},l.createURL=function(){return t(We.apply(void 0,function(e){if(Array.isArray(e))return hi(e)}(e=l.attributesToClear.map(function(e){return g({helper:e.helper,attributesToClear:e.items})}))||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return hi(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?hi(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()));var e};var i=l.attributesToClear.some(function(e){return e.items.length>0});return{canRefine:i,hasRefinements:i,refine:h,createURL:d,widgetParams:r}}}}},connectCurrentRefinements:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,Oi()),function(r){if((r||{}).includedAttributes&&(r||{}).excludedAttributes)throw new Error(Oi("The options `includedAttributes` and `excludedAttributes` cannot be used together."));var n=r||{},i=n.includedAttributes,a=n.excludedAttributes,o=void 0===a?["query"]:a,s=n.transformItems,c=void 0===s?function(e){return e}:s;return{$$type:"ais.currentRefinements",init:function(t){var r=t.instantSearchInstance;e(wi(wi({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(wi(wi({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(){t()},getRenderState:function(e,t){return wi(wi({},e),{},{currentRefinements:this.getWidgetRenderState(t)})},getWidgetRenderState:function(e){var t=e.results,n=e.createURL,a=e.helper,s=t?e.scopedResults.reduce(function(e,r){return e.concat(c(ji({results:r.results,helper:r.helper,indexId:r.indexId,includedAttributes:i,excludedAttributes:o}),{results:t}))},[]):c(ji({results:{},helper:a,indexId:a.state.index,includedAttributes:i,excludedAttributes:o}),{results:t});return{items:s,canRefine:s.length>0,refine:function(e){return Ri(a,e)},createURL:function(e){return n(Pi(a.state,e))},widgetParams:r}}}}},connectHierarchicalMenu:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,Di()),function(r){var n=r||{},i=n.attributes,a=n.separator,o=void 0===a?" > ":a,s=n.rootPath,u=void 0===s?null:s,f=n.showParentLevel,l=void 0===f||f,h=n.limit,d=void 0===h?10:h,p=n.showMore,v=void 0!==p&&p,m=n.showMoreLimit,g=void 0===m?20:m,y=n.sortBy,b=void 0===y?Fi:y,w=n.transformItems,S=void 0===w?function(e){return e}:w;if(!i||!Array.isArray(i)||0===i.length)throw new Error(Di("The `attributes` option expects an array of strings."));if(!0===v&&g<=d)throw new Error(Di("The `showMoreLimit` option must be greater than `limit`."));var O,j,P,R=(P=i,function(e){if(Array.isArray(e))return e}(P)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{for(a=(r=r.call(e)).next;!(c=(n=a.call(r)).done)&&(s.push(n.value),1!==s.length);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(P)||function(e,t){if(e){if("string"==typeof e)return ki(e,1);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?ki(e,1):void 0}}(P)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0],_=function(){};function E(){_()}var x=!1;function I(){return x?g:d}function A(e){return e.slice(0,I()).map(function(e){var t=e.name,r=e.escapedValue,n=e.data,i=Ai(Ai({},function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},a=Object.keys(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,xi)),{},{value:r,label:t,data:null});return Array.isArray(n)&&(i.data=A(n)),i})}return{$$type:"ais.hierarchicalMenu",init:function(t){var r=t.instantSearchInstance;e(Ai(Ai({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;_=function(e,t){return function(){x=!x,t.render(e)}}(t,this),e(Ai(Ai({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(e){var r=e.state;return t(),r.removeHierarchicalFacet(R).setQueryParameter("maxValuesPerFacet",void 0)},getRenderState:function(e,t){return Ai(Ai({},e),{},{hierarchicalMenu:Ai(Ai({},e.hierarchicalMenu),{},Ti({},R,this.getWidgetRenderState(t)))})},getWidgetRenderState:function(e){var t=this,n=e.results,a=e.state,s=e.createURL,c=e.helper,u=[],f=!1;if(O||(O=W({instantSearchInstance:e.instantSearchInstance,helper:c,attribute:function(e){var t=e.split(o).length-1;return i[t]},widgetType:this.$$type})),j||(j=function(e){O("click:internal",e),c.toggleFacetRefinement(R,e).search()}),n){var l=n.getFacetValues(R,{sortBy:b,facetOrdering:b===Fi}),h=l&&!Array.isArray(l)&&l.data?l.data:[],d=(a.maxValuesPerFacet||0)>I()?h.length<=I():h.length<I();f=v&&(x||!d),u=S(A(h),{results:n})}return{items:u,refine:j,canRefine:u.length>0,createURL:function(e){return s(function(r){return t.getWidgetUiState(r,{searchParameters:a.resetPage().toggleFacetRefinement(R,e),helper:c})})},sendEvent:O,widgetParams:r,isShowingMore:x,toggleShowMore:E,canToggleShowMore:f}},getWidgetUiState:function(e,t){var r,n,i=t.searchParameters.getHierarchicalFacetBreadcrumb(R);return r=Ai(Ai({},e),{},{hierarchicalMenu:Ai(Ai({},e.hierarchicalMenu),{},Ti({},R,i))}),n=R,r.hierarchicalMenu?(r.hierarchicalMenu[n]&&0!==r.hierarchicalMenu[n].length||delete r.hierarchicalMenu[n],0===Object.keys(r.hierarchicalMenu).length&&delete r.hierarchicalMenu,r):r},getWidgetSearchParameters:function(e,t){var r=t.uiState,n=r.hierarchicalMenu&&r.hierarchicalMenu[R];if(e.isConjunctiveFacet(R)||e.isDisjunctiveFacet(R))return"development"==="production".NODE_ENV&&c(!1,'HierarchicalMenu: Attribute "'.concat(R,'" is already used by another widget applying conjunctive or disjunctive faceting.\nAs this is not supported, please make sure to remove this other widget or this HierarchicalMenu widget will not work at all.')),e;if(e.isHierarchicalFacet(R)){var a=e.getHierarchicalFacetByName(R);"development"==="production".NODE_ENV&&c(De(a.attributes,i)&&a.separator===o&&a.rootPath===u,"Using Breadcrumb and HierarchicalMenu on the same facet with different options overrides the configuration of the HierarchicalMenu.")}var s=e.removeHierarchicalFacet(R).addHierarchicalFacet({name:R,attributes:i,separator:o,rootPath:u,showParentLevel:l}),f=Math.max(s.maxValuesPerFacet||0,v?g:d),h=s.setQueryParameter("maxValuesPerFacet",f);return n?h.addHierarchicalFacetRefinement(R,n.join(o)):h.setQueryParameters({hierarchicalFacetsRefinements:Ai(Ai({},h.hierarchicalFacetsRefinements),{},Ti({},R,[]))})}}}},connectHits:Hi,connectHitsWithInsights:$i,connectHitsPerPage:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,zi()),function(r){var n=r||{},i=n.items,a=n.transformItems,o=void 0===a?function(e){return e}:a;if(!Array.isArray(i))throw new Error(zi("The `items` option expects an array of objects."));var s=i,u=s.filter(function(e){return!0===e.default});if(0===u.length)throw new Error(zi("A default value must be specified in `items`."));if(u.length>1)throw new Error(zi("More than one default value is specified in `items`."));var f=u[0],l=function(e){return function(t){return t||0===t?e.setQueryParameter("hitsPerPage",t).search():e.setQueryParameter("hitsPerPage",void 0).search()}},h=function(e){var t=e.state,r=e.createURL,n=e.getWidgetUiState,i=e.helper;return function(e){return r(function(r){return n(r,{searchParameters:t.resetPage().setQueryParameter("hitsPerPage",e||0===e?e:void 0),helper:i})})}};return{$$type:"ais.hitsPerPage",init:function(t){var r,n=t.state,i=t.instantSearchInstance;s.some(function(e){return Number(n.hitsPerPage)===Number(e.value)})||("development"==="production".NODE_ENV&&c(void 0!==n.hitsPerPage,"\n`hitsPerPage` is not defined.\nThe option `hitsPerPage` needs to be set using the `configure` widget.\n\nLearn more: https://www.algolia.com/doc/api-reference/widgets/hits-per-page/js/\n            "),"development"==="production".NODE_ENV&&c(!1,'\nThe `items` option of `hitsPerPage` does not contain the "hits per page" value coming from the state: '.concat(n.hitsPerPage,".\n\nYou may want to add another entry to the `items` option with this value.")),s=[{value:"",label:""}].concat(function(e){if(Array.isArray(e))return Ki(e)}(r=s)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||function(e,t){if(e){if("string"==typeof e)return Ki(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Ki(e,t):void 0}}(r)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())),e(Xi(Xi({},this.getWidgetRenderState(t)),{},{instantSearchInstance:i}),!0)},render:function(t){var r=t.instantSearchInstance;e(Xi(Xi({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(e){var r=e.state;return t(),r.setQueryParameter("hitsPerPage",void 0)},getRenderState:function(e,t){return Xi(Xi({},e),{},{hitsPerPage:this.getWidgetRenderState(t)})},getWidgetRenderState:function(e){var t,n,i=e.state,a=e.results,c=e.createURL,u=e.helper,f=!!a&&a.nbHits>0;return{items:o((t=i,n=t.hitsPerPage,s.map(function(e){return Xi(Xi({},e),{},{isRefined:Number(e.value)===Number(n)})})),{results:a}),refine:l(u),createURL:h({state:i,createURL:c,getWidgetUiState:this.getWidgetUiState,helper:u}),hasNoResults:!f,canRefine:f,widgetParams:r}},getWidgetUiState:function(e,t){var r=t.searchParameters.hitsPerPage;return void 0===r||r===f.value?e:Xi(Xi({},e),{},{hitsPerPage:r})},getWidgetSearchParameters:function(e,t){return e.setQueryParameters({hitsPerPage:t.uiState.hitsPerPage||f.value})}}}},connectInfiniteHits:la,connectInfiniteHitsWithInsights:ha,connectMenu:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,wa()),function(r){var n,i,a,o=r||{},s=o.attribute,u=o.limit,f=void 0===u?10:u,l=o.showMore,h=void 0!==l&&l,d=o.showMoreLimit,p=void 0===d?20:d,v=o.sortBy,m=void 0===v?Sa:v,g=o.transformItems,y=void 0===g?function(e){return e}:g;if(!s)throw new Error(wa("The `attribute` option is required."));if(!0===h&&p<=f)throw new Error(wa("The `showMoreLimit` option must be greater than `limit`."));var b=!1,w=function(){};function S(){w()}function O(){return b?p:f}return{$$type:"ais.menu",init:function(t){var r=t.instantSearchInstance;e(ya(ya({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(ya(ya({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(e){var r=e.state;return t(),r.removeHierarchicalFacet(s).setQueryParameter("maxValuesPerFacet",void 0)},getRenderState:function(e,t){return ya(ya({},e),{},{menu:ya(ya({},e.menu),{},ba({},s,this.getWidgetRenderState(t)))})},getWidgetRenderState:function(e){var t=this,o=e.results,c=e.createURL,u=e.helper,f=[],l=!1;if(n||(n=W({instantSearchInstance:e.instantSearchInstance,helper:u,attribute:s,widgetType:this.$$type})),i||(i=function(e){return c(function(r){return t.getWidgetUiState(r,{searchParameters:u.state.resetPage().toggleFacetRefinement(s,e),helper:u})})}),a||(a=function(e){var t=va(u.getHierarchicalFacetBreadcrumb(s),1)[0];n("click:internal",e||t),u.toggleFacetRefinement(s,e||t).search()}),e.results&&(w=function(e,t){return function(){b=!b,t.render(e)}}(e,this)),o){var d=o.getFacetValues(s,{sortBy:m,facetOrdering:m===Sa}),p=d&&!Array.isArray(d)&&d.data?d.data:[];l=h&&(b||p.length>O()),f=y(p.slice(0,O()).map(function(e){var t=e.name,r=e.escapedValue;return ya(ya({},function(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},a=Object.keys(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n<a.length;n++)t.indexOf(r=a[n])>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}(e,da)),{},{label:t,value:r})}),{results:o})}return{items:f,createURL:i,refine:a,sendEvent:n,canRefine:f.length>0,widgetParams:r,isShowingMore:b,toggleShowMore:S,canToggleShowMore:l}},getWidgetUiState:function(e,t){var r=va(t.searchParameters.getHierarchicalFacetBreadcrumb(s),1)[0];return function(e,t){return e.menu?(void 0===e.menu[t]&&delete e.menu[t],0===Object.keys(e.menu).length&&delete e.menu,e):e}(ya(ya({},e),{},{menu:ya(ya({},e.menu),{},ba({},s,r))}),s)},getWidgetSearchParameters:function(e,t){var r=t.uiState,n=r.menu&&r.menu[s];if(e.isConjunctiveFacet(s)||e.isDisjunctiveFacet(s))return"development"==="production".NODE_ENV&&c(!1,'Menu: Attribute "'.concat(s,'" is already used by another widget applying conjunctive or disjunctive faceting.\nAs this is not supported, please make sure to remove this other widget or this Menu widget will not work at all.')),e;var i=e.removeHierarchicalFacet(s).addHierarchicalFacet({name:s,attributes:[s]}),a=Math.max(i.maxValuesPerFacet||0,h?p:f),o=i.setQueryParameter("maxValuesPerFacet",a);return n?o.addHierarchicalFacetRefinement(s,n):o.setQueryParameters({hierarchicalFacetsRefinements:ya(ya({},o.hierarchicalFacetsRefinements),{},ba({},s,[]))})}}}},connectNumericMenu:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,xa()),function(r){var n=r||{},i=n.attribute,a=void 0===i?"":i,o=n.items,s=void 0===o?[]:o,c=n.transformItems,u=void 0===c?function(e){return e}:c;if(""===a)throw new Error(xa("The `attribute` option is required."));if(!s||0===s.length)throw new Error(xa("The `items` option expects an array of objects."));var f={};return{$$type:"ais.numericMenu",init:function(t){var r=t.instantSearchInstance;e(_a(_a({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(_a(_a({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(e){var r=e.state;return t(),r.removeNumericRefinement(a)},getWidgetUiState:function(e,t){var r=t.searchParameters.getNumericRefinements(a),n=r["="]&&r["="][0];if(n||0===n)return _a(_a({},e),{},{numericMenu:_a(_a({},e.numericMenu),{},Ea({},a,"".concat(r["="])))});var i=r[">="]&&r[">="][0]||"",o=r["<="]&&r["<="][0]||"";return function(e,t){return e.numericMenu?(":"===e.numericMenu[t]&&delete e.numericMenu[t],0===Object.keys(e.numericMenu).length&&delete e.numericMenu,e):e}(_a(_a({},e),{},{numericMenu:_a(_a({},e.numericMenu),{},Ea({},a,"".concat(i,":").concat(o)))}),a)},getWidgetSearchParameters:function(e,t){var r=t.uiState,n=r.numericMenu&&r.numericMenu[a],i=e.setQueryParameters({numericRefinements:_a(_a({},e.numericRefinements),{},Ea({},a,{}))});if(!n)return i;if(-1===n.indexOf(":"))return i.addNumericRefinement(a,"=",Number(n));var o,s=function(e){if(Array.isArray(e))return e}(o=n.split(":").map(parseFloat))||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{for(a=(r=r.call(e)).next;!(c=(n=a.call(r)).done)&&(s.push(n.value),2!==s.length);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(o)||ja(o,2)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),c=s[0],u=s[1],f=Fe(c)?i.addNumericRefinement(a,">=",c):i;return Fe(u)?f.addNumericRefinement(a,"<=",u):f},getRenderState:function(e,t){return _a(_a({},e),{},{numericMenu:_a(_a({},e.numericMenu),{},Ea({},a,this.getWidgetRenderState(t)))})},getWidgetRenderState:function(e){var t=this,n=e.results,i=e.state,o=e.instantSearchInstance,c=e.helper,l=e.createURL;f.refine||(f.refine=function(e){var t=Aa(c.state,a,e);f.sendEvent("click:internal",e),c.setState(t).search()}),f.createURL||(f.createURL=function(e){return function(r){return l(function(n){return t.getWidgetUiState(n,{searchParameters:Aa(e,a,r),helper:c})})}}),f.sendEvent||(f.sendEvent=function(e){var t=e.instantSearchInstance;return function(){1!==arguments.length||t.sendEventToInsights(arguments.length<=0?void 0:arguments[0])}}({instantSearchInstance:o}));var h,d=!n||0===n.nbHits,p=function(e){return s.map(function(t){var r=t.start,n=t.end,i=t.label;return{label:i,value:encodeURI(JSON.stringify({start:r,end:n})),isRefined:Ia(e,a,{start:r,end:n,label:i})}})}(i),v=!0,m=function(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=ja(e))){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return o=e.done,e},e:function(e){s=!0,a=e},f:function(){try{o||null==r.return||r.return()}finally{if(s)throw a}}}}(p);try{for(m.s();!(h=m.n()).done;){var g=h.value;if(g.isRefined&&"{}"!==decodeURI(g.value)){v=!1;break}}}catch(e){m.e(e)}finally{m.f()}return{createURL:f.createURL(i),items:u(p,{results:n}),hasNoResults:d,canRefine:!(d&&v),refine:f.refine,sendEvent:f.sendEvent,widgetParams:r}}}}},connectPagination:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,Ha()),function(r){var n=r||{},i=n.totalPages,a=n.padding,o=new Na({currentPage:0,total:0,padding:void 0===a?3:a}),s={};return{$$type:"ais.pagination",init:function(t){var r=t.instantSearchInstance;e(Ca(Ca({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(Ca(Ca({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(e){var r=e.state;return t(),r.setQueryParameter("page",void 0)},getWidgetUiState:function(e,t){var r=t.searchParameters.page||0;return r?Ca(Ca({},e),{},{page:r+1}):e},getWidgetSearchParameters:function(e,t){var r=t.uiState;return e.setQueryParameter("page",r.page?r.page-1:0)},getWidgetRenderState:function(e){var t=e.results,n=e.helper,a=e.state,c=e.createURL;s.refine||(s.refine=function(e){n.setPage(e),n.search()}),s.createURL||(s.createURL=function(e){return c(function(t){return Ca(Ca({},t),{},{page:e+1})})});var u=a.page||0,f=function(e){var t=e.nbPages;return void 0!==i?Math.min(i,t):t}(t||{nbPages:0});return o.currentPage=u,o.total=f,{createURL:s.createURL,refine:s.refine,canRefine:f>1,currentRefinement:u,nbHits:(null==t?void 0:t.nbHits)||0,nbPages:f,pages:t?o.pages():[],isFirstPage:o.isFirstPage(),isLastPage:o.isLastPage(),widgetParams:r}},getRenderState:function(e,t){return Ca(Ca({},e),{},{pagination:this.getWidgetRenderState(t)})}}}},connectRange:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,Ga()),function(r){var n=r||{},i=n.attribute,a=void 0===i?"":i,o=n.min,s=n.max,c=n.precision,u=void 0===c?0:c;if(!a)throw new Error(Ga("The `attribute` option is required."));if(Fe(o)&&Fe(s)&&o>s)throw new Error(Ga("The `max` option can't be lower than `min`."));var f={from:function(e){return e.toLocaleString()},to:function(e){return function(e){return Number(Number(e).toFixed(u))}(e).toLocaleString()}},l=function(e){return function(){1!==arguments.length||e.sendEventToInsights(arguments.length<=0?void 0:arguments[0])}};function h(e,t){return function(){var r=Qa(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[void 0,void 0],2),n=function(e,t,r,n){var i,c,f=e.state,l=t.min,h=t.max,d=Qa(f.getNumericRefinement(a,">=")||[],1)[0],p=Qa(f.getNumericRefinement(a,"<=")||[],1)[0],v=void 0===r||""===r,m=void 0===n||""===n,g=Ka({min:v?void 0:parseFloat(r),max:m?void 0:parseFloat(n),precision:u}),y=g.min,b=g.max;i=Fe(o)||l!==y?Fe(o)&&v?o:y:void 0,c=Fe(s)||h!==b?Fe(s)&&m?s:b:void 0;var w=void 0===i,S=Fe(l)&&l<=i,O=w||Fe(i)&&(!Fe(l)||S),j=void 0===c,P=Fe(c)&&h>=c,R=j||Fe(c)&&(!Fe(h)||P);return(d!==i||p!==c)&&O&&R?(f=f.removeNumericRefinement(a),Fe(i)&&(f=f.addNumericRefinement(a,">=",i)),Fe(c)&&(f=f.addNumericRefinement(a,"<=",c)),f.resetPage()):null}(e,t,r[0],r[1]);n&&e.setState(n).search()}}return{$$type:"ais.range",init:function(t){e(Ba(Ba({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!0)},render:function(t){e(Ba(Ba({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!1)},getRenderState:function(e,t){return Ba(Ba({},e),{},{range:Ba(Ba({},e.range),{},Va({},a,this.getWidgetRenderState(t)))})},getWidgetRenderState:function(e){var t,n=e.results,i=e.helper,c=e.instantSearchInstance,d=oe(n&&n.disjunctiveFacets||[],function(e){return e.name===a}),p=(t=d&&d.stats||{min:void 0,max:void 0},Ka({min:Fe(o)?o:Fe(t.min)?t.min:0,max:Fe(s)?s:Fe(t.max)?t.max:0,precision:u})),v=function(e){var t=Qa(e.getNumericRefinement(a,">=")||[],1)[0],r=Qa(e.getNumericRefinement(a,"<=")||[],1)[0];return[Fe(t)?t:-Infinity,Fe(r)?r:Infinity]}(i);return{refine:h(i,n?p:{min:void 0,max:void 0}),canRefine:p.min!==p.max,format:f,range:p,sendEvent:l(c),widgetParams:Ba(Ba({},r),{},{precision:u}),start:v}},dispose:function(e){var r=e.state;return t(),r.removeDisjunctiveFacet(a).removeNumericRefinement(a)},getWidgetUiState:function(e,t){var r=t.searchParameters.getNumericRefinements(a),n=r[">="],i=void 0===n?[]:n,o=r["<="],s=void 0===o?[]:o;return 0===i.length&&0===s.length?e:Ba(Ba({},e),{},{range:Ba(Ba({},e.range),{},Va({},a,"".concat(i,":").concat(s)))})},getWidgetSearchParameters:function(e,t){var r=t.uiState,n=e.addDisjunctiveFacet(a).setQueryParameters({numericRefinements:Ba(Ba({},e.numericRefinements),{},Va({},a,{}))});Fe(o)&&(n=n.addNumericRefinement(a,">=",o)),Fe(s)&&(n=n.addNumericRefinement(a,"<=",s));var i=r.range&&r.range[a];if(!i||-1===i.indexOf(":"))return n;var c=Qa(i.split(":").map(parseFloat),2),u=c[0],f=c[1];return Fe(u)&&(!Fe(o)||o<u)&&(n=(n=n.removeNumericRefinement(a,">=")).addNumericRefinement(a,">=",u)),Fe(f)&&(!Fe(s)||f<s)&&(n=(n=n.removeNumericRefinement(a,"<=")).addNumericRefinement(a,"<=",f)),n}}}},connectRefinementList:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,ro()),function(r){var n=r||{},i=n.attribute,a=n.operator,o=void 0===a?"or":a,s=n.limit,u=void 0===s?10:s,f=n.showMore,l=void 0!==f&&f,h=n.showMoreLimit,d=void 0===h?20:h,p=n.sortBy,v=void 0===p?no:p,m=n.escapeFacetValues,g=void 0===m||m,y=n.transformItems,b=void 0===y?function(e){return e}:y;if(!i)throw new Error(ro("The `attribute` option is required."));if(!/^(and|or)$/.test(o))throw new Error(ro('The `operator` must one of: `"and"`, `"or"` (got "'.concat(o,'").')));if(!0===l&&d<=u)throw new Error(ro("`showMoreLimit` should be greater than `limit`."));var w,S,O,j=function(e){var t=e.name,r=e.escapedValue;return Za(Za({},to(e,Xa)),{},{value:r,label:t,highlighted:t})},P=[],R=!0,_=!1,E=function(){};function x(){E()}function A(){return _?d:u}var F=function(){return function(){}};return{$$type:"ais.refinementList",init:function(t){e(Za(Za({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!0)},render:function(t){e(Za(Za({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!1)},getRenderState:function(e,t){return Za(Za({},e),{},{refinementList:Za(Za({},e.refinementList),{},eo({},i,this.getWidgetRenderState(t)))})},getWidgetRenderState:function(t){var n=this,a=t.results,o=t.state,s=t.createURL,c=t.helper,f=[],h=[];if(O&&S&&F||(O=W({instantSearchInstance:t.instantSearchInstance,helper:c,attribute:i,widgetType:this.$$type}),S=function(e){O("click:internal",e),c.toggleFacetRefinement(i,e).search()},F=function(t,r){return function(n){return function(a){var o=n.instantSearchInstance,s=n.results;if(""===a&&P)e(Za(Za({},r.getWidgetRenderState(Za(Za({},n),{},{results:w}))),{},{instantSearchInstance:o}),!1);else{var c={highlightPreTag:g?T.highlightPreTag:k.highlightPreTag,highlightPostTag:g?T.highlightPostTag:k.highlightPostTag};t.searchForFacetValues(i,a,Math.min(A(),100),c).then(function(t){var i=g?t.facetHits.map(function(e){return I(I({},e),{},{highlighted:D(e.highlighted)})}):t.facetHits,a=b(i.map(function(e){var t=e.escapedValue,r=e.value;return Za(Za({},to(e,Ja)),{},{value:t,label:r})}),{results:s});e(Za(Za({},r.getWidgetRenderState(Za(Za({},n),{},{results:w}))),{},{items:a,canToggleShowMore:!1,canRefine:!0,isFromSearch:!0,instantSearchInstance:o}),!1)})}}}}(c,this)),a){var d=a.getFacetValues(i,{sortBy:v,facetOrdering:v===no});h=d&&Array.isArray(d)?d:[],f=b(h.slice(0,A()).map(j),{results:a});var p=o.maxValuesPerFacet,m=A();R=p>m?h.length<=m:h.length<m,w=a,P=f,t.results&&(E=function(e,t){return function(){_=!_,t.render(e)}}(t,this))}var y=F&&F(t);return{createURL:function(e){return s(function(t){return n.getWidgetUiState(t,{searchParameters:o.resetPage().toggleFacetRefinement(i,e),helper:c})})},items:f,refine:S,searchForItems:y,isFromSearch:!1,canRefine:f.length>0,widgetParams:r,isShowingMore:_,canToggleShowMore:_&&P.length>u||l&&!R,toggleShowMore:x,sendEvent:O,hasExhaustiveItems:R}},dispose:function(e){var r=e.state;t();var n=r.setQueryParameter("maxValuesPerFacet",void 0);return"and"===o?n.removeFacet(i):n.removeDisjunctiveFacet(i)},getWidgetUiState:function(e,t){var r=t.searchParameters,n="or"===o?r.getDisjunctiveRefinements(i):r.getConjunctiveRefinements(i);return function(e,t){return e.refinementList?(e.refinementList[t]&&0!==e.refinementList[t].length||delete e.refinementList[t],0===Object.keys(e.refinementList).length&&delete e.refinementList,e):e}(Za(Za({},e),{},{refinementList:Za(Za({},e.refinementList),{},eo({},i,n))}),i)},getWidgetSearchParameters:function(e,t){var r=t.uiState,n="or"===o;if(e.isHierarchicalFacet(i))return"development"==="production".NODE_ENV&&c(!1,'RefinementList: Attribute "'.concat(i,'" is already used by another widget applying hierarchical faceting.\nAs this is not supported, please make sure to remove this other widget or this RefinementList widget will not work at all.')),e;if(n&&e.isConjunctiveFacet(i)||!n&&e.isDisjunctiveFacet(i))return"development"==="production".NODE_ENV&&c(!1,'RefinementList: Attribute "'.concat(i,'" is used by another refinement list with a different operator.\nAs this is not supported, please make sure to only use this attribute with one of the two operators.')),e;var a=r.refinementList&&r.refinementList[i],s=n?e.addDisjunctiveFacet(i).removeDisjunctiveFacetRefinement(i):e.addFacet(i).removeFacetRefinement(i),f=Math.max(s.maxValuesPerFacet||0,l?d:u),h=s.setQueryParameter("maxValuesPerFacet",f);if(!a){var p=n?"disjunctiveFacetsRefinements":"facetsRefinements";return h.setQueryParameters(eo({},p,Za(Za({},h[p]),{},eo({},i,[]))))}return a.reduce(function(e,t){return n?e.addDisjunctiveFacetRefinement(i,t):e.addFacetRefinement(i,t)},h)}}}},connectSearchBox:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,co()),function(r){var n,i,a=(r||{}).queryHook,o=void 0===a?uo:a;return{$$type:"ais.searchBox",init:function(t){var r=t.instantSearchInstance;e(oo(oo({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(oo(oo({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(e){var r=e.state;return t(),r.setQueryParameter("query",void 0)},getRenderState:function(e,t){return oo(oo({},e),{},{searchBox:this.getWidgetRenderState(t)})},getWidgetRenderState:function(e){var t=e.helper;return n||(n=function(e){o(e,function(e){return t.setQuery(e).search()})},i=function(){t.setQuery("").search()}),{query:e.state.query||"",refine:n,clear:i,widgetParams:r,isSearchStalled:"stalled"===e.instantSearchInstance.status}},getWidgetUiState:function(e,t){var r=t.searchParameters.query||"";return""===r||e&&e.query===r?e:oo(oo({},e),{},{query:r})},getWidgetSearchParameters:function(e,t){return e.setQueryParameter("query",t.uiState.query||"")}}}},connectSortBy:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;m(e,vo());var r={};return function(n){var i=n||{},a=i.items,o=i.transformItems,s=void 0===o?function(e){return e}:o;if(!Array.isArray(a))throw new Error(vo("The `items` option expects an array of objects."));return{$$type:"ais.sortBy",init:function(t){var r=t.instantSearchInstance,n=this.getWidgetRenderState(t),i=n.currentRefinement,o=oe(a,function(e){return e.value===i});"development"==="production".NODE_ENV&&c(void 0!==o,'The index named "'.concat(i,'" is not listed in the `items` of `sortBy`.')),e(ho(ho({},n),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(ho(ho({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(e){var n=e.state;return t(),r.initialIndex?n.setIndex(r.initialIndex):n},getRenderState:function(e,t){return ho(ho({},e),{},{sortBy:this.getWidgetRenderState(t)})},getWidgetRenderState:function(e){var t=e.results,i=e.helper,o=e.state,c=e.parent;!r.initialIndex&&c&&(r.initialIndex=c.getIndexName()),r.setIndex||(r.setIndex=function(e){i.setIndex(e).search()});var u=!t||0===t.nbHits;return{currentRefinement:o.index,options:s(a,{results:t}),refine:r.setIndex,hasNoResults:u,canRefine:!u&&a.length>0,widgetParams:n}},getWidgetUiState:function(e,t){var n=t.searchParameters.index;return ho(ho({},e),{},{sortBy:n!==r.initialIndex?n:void 0})},getWidgetSearchParameters:function(e,t){return e.setQueryParameter("index",t.uiState.sortBy||r.initialIndex||e.index)}}}},connectRatingMenu:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,jo()),function(r){var n,i=r||{},a=i.attribute,o=i.max,s=void 0===o?5:o;if(!a)throw new Error(jo("The `attribute` option is required."));var u=function(e){var t,r=e.getNumericRefinements(a);if(null!==(t=r[">="])&&void 0!==t&&t.length)return r[">="][0]};function f(e,t){var r=u(e)===Number(t),n=e.resetPage().removeNumericRefinement(a);return r?n:n.addNumericRefinement(a,"<=",s).addNumericRefinement(a,">=",Number(t))}var l=function(e,t){n("click:internal",t),e.setState(f(e.state,t)).search()},h=function(e){return l.bind(null,e)},d=function(e){var t=e.state,r=e.createURL,n=e.getWidgetUiState,i=e.helper;return function(e){return r(function(r){return n(r,{searchParameters:f(t,e),helper:i})})}};return{$$type:Po,init:function(t){var r=t.instantSearchInstance;e(yo(yo({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(yo(yo({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},getRenderState:function(e,t){return yo(yo({},e),{},{ratingMenu:yo(yo({},e.ratingMenu),{},bo({},a,this.getWidgetRenderState(t)))})},getWidgetRenderState:function(e){var t=e.helper,i=e.results,o=e.state,f=e.createURL,l=[];n||(n=function(e){var t=e.instantSearchInstance,r=e.helper,n=e.getRefinedStar,i=e.attribute;return function(){for(var e=arguments.length,a=new Array(e),o=0;o<e;o++)a[o]=arguments[o];if(1!==a.length){var s=a[1],c=a[2],u=void 0===c?"Filter Applied":c,f=wo(a[0].split(":"),2),l=f[0],h=f[1];"click"===l&&(n()===Number(s)||t.sendEventToInsights({insightsMethod:"clickedFilters",widgetType:Po,eventType:l,eventModifier:h,payload:{eventName:u,index:r.getIndex(),filters:["".concat(i,">=").concat(s)]},attribute:i}))}else t.sendEventToInsights(a[0])}}({instantSearchInstance:e.instantSearchInstance,helper:t,getRefinedStar:function(){return u(t.state)},attribute:a}));var p=!1,v=0,m=null==i?void 0:i.getFacetValues(a,{});if(i&&m){var g=m.length,y=function(e){var t=0;return e.forEach(function(e){var r=wo(e.name.split("."),2)[1];t=Math.max(t,(void 0===r?"":r).length)}),t}(m),b=Math.pow(10,y)*s;"development"==="production".NODE_ENV&&c(b<=g||Boolean(i.__isArtificial),function(e){var t=e.maxDecimalPlaces,r=e.maxFacets,n=e.maxValuesPerFacet,i=Math.max(0,Math.floor(Math.log10(Ro/s))),o=Math.min(Ro,Math.pow(10,i)*s),c=[];return r>Ro&&c.push('- Update your records to lower the precision of the values in the "'.concat(a,'" attribute (for example: ').concat(5.123456789.toPrecision(t+1)," to ").concat(5.123456789.toPrecision(i+1),")")),n<o&&c.push("- Increase the maximum number of facet values to ".concat(o,' using the "configure" widget ').concat(ne({name:"configure"}),' and the "maxValuesPerFacet" parameter https://www.algolia.com/doc/api-reference/api-parameters/maxValuesPerFacet/')),"The ".concat(a," attribute can have ").concat(r," different values (0 to ").concat(s," with a maximum of ").concat(t," decimals = ").concat(r,") but you retrieved only ").concat(n," facet values. Therefore the number of results that match the refinements can be incorrect.\n    ").concat(c.length?"To resolve this problem you can:\n".concat(c.join("\n")):"")}({maxDecimalPlaces:y,maxFacets:b,maxValuesPerFacet:g}));for(var w=u(o),S=function(e){var t=w===e;p=p||t;var r=m.filter(function(t){return Number(t.name)>=e&&Number(t.name)<=s}).map(function(e){return e.count}).reduce(function(e,t){return e+t},0);if(v+=r,w&&!t&&0===r)return"continue";var n,i=(n=new Array(Math.floor(s/1)),function(e){if(Array.isArray(e))return Oo(e)}(n)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(n)||So(n)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).map(function(t,r){return 1*r<e});l.push({stars:i,name:String(e),label:String(e),value:String(e),count:r,isRefined:t})},O=1;O<s;O+=1)S(O)}l=l.reverse();var j=!i||0===i.nbHits;return{items:l,hasNoResults:j,canRefine:(!j||p)&&v>0,refine:h(t),sendEvent:n,createURL:d({state:o,createURL:f,helper:t,getWidgetUiState:this.getWidgetUiState}),widgetParams:r}},dispose:function(e){var r=e.state;return t(),r.removeNumericRefinement(a)},getWidgetUiState:function(e,t){var r=u(t.searchParameters);return function(e,t){return e.ratingMenu?("number"!=typeof e.ratingMenu[t]&&delete e.ratingMenu[t],0===Object.keys(e.ratingMenu).length&&delete e.ratingMenu,e):e}(yo(yo({},e),{},{ratingMenu:yo(yo({},e.ratingMenu),{},bo({},a,"number"==typeof r?r:void 0))}),a)},getWidgetSearchParameters:function(e,t){var r=t.uiState,n=r.ratingMenu&&r.ratingMenu[a],i=e.addDisjunctiveFacet(a).removeNumericRefinement(a).removeDisjunctiveFacetRefinement(a);return n?i.addNumericRefinement(a,"<=",s).addNumericRefinement(a,">=",n):i.setQueryParameters({numericRefinements:yo(yo({},i.numericRefinements),{},bo({},a,{}))})}}}},connectStats:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,Ao()),function(r){return{$$type:"ais.stats",init:function(t){var r=t.instantSearchInstance;e(xo(xo({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(xo(xo({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(){t()},getRenderState:function(e,t){return xo(xo({},e),{},{stats:this.getWidgetRenderState(t)})},getWidgetRenderState:function(e){var t=e.results,n=e.state;return t?{hitsPerPage:t.hitsPerPage,nbHits:t.nbHits,nbSortedHits:t.nbSortedHits,areHitsSorted:void 0!==t.appliedRelevancyStrictness&&t.appliedRelevancyStrictness>0&&t.nbSortedHits!==t.nbHits,nbPages:t.nbPages,page:t.page,processingTimeMS:t.processingTimeMS,query:t.query,widgetParams:r}:{hitsPerPage:n.hitsPerPage,nbHits:0,nbSortedHits:void 0,areHitsSorted:!1,nbPages:0,page:n.page||0,processingTimeMS:-1,query:n.query||"",widgetParams:r}}}}},connectToggleRefinement:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,Lo()),function(r){var n=r||{},i=n.attribute,a=n.on,o=void 0===a||a,s=n.off;if(!i)throw new Error(Lo("The `attribute` option is required."));var u,f=void 0!==s,l=Ze(o).map(ae),h=f?Ze(s).map(ae):void 0,d=function(e){return function(){var t=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{isRefined:!1}).isRefined;t?(l.forEach(function(t){return e.removeDisjunctiveFacetRefinement(i,t)}),f&&h.forEach(function(t){return e.addDisjunctiveFacetRefinement(i,t)})):(u("click:internal",t),f&&h.forEach(function(t){return e.removeDisjunctiveFacetRefinement(i,t)}),l.forEach(function(t){return e.addDisjunctiveFacetRefinement(i,t)})),e.search()}},p=function(e,t){var r=t.state,n=t.createURL,a=t.getWidgetUiState,o=t.helper;return function(){r=r.resetPage();var t=e?l:h;t&&t.forEach(function(e){r=r.removeDisjunctiveFacetRefinement(i,e)});var s=e?h:l;return s&&s.forEach(function(e){r=r.addDisjunctiveFacetRefinement(i,e)}),n(function(e){return a(e,{searchParameters:r,helper:o})})}};return{$$type:Mo,init:function(t){var r=t.instantSearchInstance;e(Do(Do({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(Do(Do({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(e){var r=e.state;return t(),r.removeDisjunctiveFacet(i)},getRenderState:function(e,t){return Do(Do({},e),{},{toggleRefinement:Do(Do({},e.toggleRefinement),{},Fo({},i,this.getWidgetRenderState(t)))})},getWidgetRenderState:function(e){var t=e.state,n=e.helper,a=e.results,o=e.createURL,s=e.instantSearchInstance,c=l.every(function(e){return t.isDisjunctiveFacetRefined(i,e)}),v={isRefined:c,count:0},m={isRefined:f&&!c,count:0};if(a){var g=Ze(h||!1),y=a.getFacetValues(i,{})||[],b=l.map(function(e){return oe(y,function(t){return t.escapedValue===ae(String(e))})}).filter(function(e){return void 0!==e}),w=f?g.map(function(e){return oe(y,function(t){return t.escapedValue===ae(String(e))})}).filter(function(e){return void 0!==e}):[];v={isRefined:!!b.length&&b.every(function(e){return e.isRefined}),count:b.reduce(function(e,t){return e+t.count},0)||null},m={isRefined:!!w.length&&w.every(function(e){return e.isRefined}),count:w.reduce(function(e,t){return e+t.count},0)||y.reduce(function(e,t){return e+t.count},0)}}u||(u=function(e){var t=e.instantSearchInstance,r=e.helper,n=e.attribute,i=e.on;return function(){for(var e=arguments.length,a=new Array(e),o=0;o<e;o++)a[o]=arguments[o];if(1!==a.length){var s=a[1],c=a[2],u=void 0===c?"Filter Applied":c,f=function(e){if(Array.isArray(e))return e}(h=a[0].split(":"))||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,a,o,s=[],c=!0,u=!1;try{for(a=(r=r.call(e)).next;!(c=(n=a.call(r)).done)&&(s.push(n.value),2!==s.length);c=!0);}catch(e){u=!0,i=e}finally{try{if(!c&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}(h)||function(e,t){if(e){if("string"==typeof e)return No(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?No(e,2):void 0}}(h)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),l=f[0];"click"===l&&void 0!==i&&(s||t.sendEventToInsights({insightsMethod:"clickedFilters",widgetType:Mo,eventType:l,eventModifier:f[1],payload:{eventName:u,index:r.getIndex(),filters:i.map(function(e){return"".concat(n,":").concat(e)})},attribute:n}))}else t.sendEventToInsights(a[0]);var h}}({instantSearchInstance:s,attribute:i,on:l,helper:n}));var S=c?m:v;return{value:{name:i,isRefined:c,count:a?S.count:null,onFacetValue:v,offFacetValue:m},createURL:p(c,{state:t,createURL:o,helper:n,getWidgetUiState:this.getWidgetUiState}),sendEvent:u,canRefine:Boolean(a?S.count:null),refine:d(n),widgetParams:r}},getWidgetUiState:function(e,t){var r,n=t.searchParameters,a=l&&l.every(function(e){return n.isDisjunctiveFacetRefined(i,e)});return a?Do(Do({},e),{},{toggle:Do(Do({},e.toggle),{},Fo({},i,a))}):(null===(r=e.toggle)||void 0===r||delete r[i],e)},getWidgetSearchParameters:function(e,t){var r=t.uiState;if(e.isHierarchicalFacet(i)||e.isConjunctiveFacet(i))return"development"==="production".NODE_ENV&&c(!1,'ToggleRefinement: Attribute "'.concat(i,'" is already used by another widget of a different type.\nAs this is not supported, please make sure to remove this other widget or this ToggleRefinement widget will not work at all.')),e;var n=e.addDisjunctiveFacet(i).removeDisjunctiveFacetRefinement(i);return Boolean(r.toggle&&r.toggle[i])?(l&&l.forEach(function(e){n=n.addDisjunctiveFacetRefinement(i,e)}),n):f?(h&&h.forEach(function(e){n=n.addDisjunctiveFacetRefinement(i,e)}),n):n.setQueryParameters({disjunctiveFacetsRefinements:Do(Do({},e.disjunctiveFacetsRefinements),{},Fo({},i,[]))})}}}},connectBreadcrumb:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;m(e,Vo());var r={};return function(n){var i=n||{},a=i.attributes,o=i.separator,s=void 0===o?" > ":o,u=i.rootPath,f=void 0===u?null:u,l=i.transformItems,h=void 0===l?function(e){return e}:l;if(!a||!Array.isArray(a)||0===a.length)throw new Error(Vo("The `attributes` option expects an array of strings."));var d=Wo(a,1)[0];function p(e,t){if(!t){var r=e.getHierarchicalFacetBreadcrumb(d);return 0===r.length?e:e.resetPage().toggleFacetRefinement(d,r[0])}return e.resetPage().toggleFacetRefinement(d,t)}return{$$type:"ais.breadcrumb",init:function(t){e(Ho(Ho({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!0)},render:function(t){e(Ho(Ho({},this.getWidgetRenderState(t)),{},{instantSearchInstance:t.instantSearchInstance}),!1)},dispose:function(){t()},getRenderState:function(e,t){return Ho(Ho({},e),{},{breadcrumb:Ho(Ho({},e.breadcrumb),{},qo({},d,this.getWidgetRenderState(t)))})},getWidgetRenderState:function(e){var t=this,i=e.helper,a=e.createURL,o=e.results,s=e.state,c=function(){if(!o||0===s.hierarchicalFacets.length)return[];var e,t=Wo(s.hierarchicalFacets,1),r=o.getFacetValues(t[0].name,{}),n=r&&!Array.isArray(r)&&r.data?r.data:[];return h((e=Qo(n)).map(function(t,r){return{label:t.label,value:r+1===e.length?null:e[r+1].value}}),{results:o})}();return r.createURL||(r.createURL=function(e){return a(function(r){return t.getWidgetUiState(r,{searchParameters:p(i.state,e),helper:i})})}),r.refine||(r.refine=function(e){i.setState(p(i.state,e)).search()}),{canRefine:c.length>0,createURL:r.createURL,items:c,refine:r.refine,widgetParams:n}},getWidgetUiState:function(e,t){var r,n,i=t.searchParameters.getHierarchicalFacetBreadcrumb(d);return r=Ho(Ho({},e),{},{hierarchicalMenu:Ho(Ho({},e.hierarchicalMenu),{},qo({},d,i))}),n=d,r.hierarchicalMenu?(r.hierarchicalMenu[n]&&r.hierarchicalMenu[n].length||delete r.hierarchicalMenu[n],0===Object.keys(r.hierarchicalMenu).length&&delete r.hierarchicalMenu,r):r},getWidgetSearchParameters:function(e,t){var r=t.uiState,n=r.hierarchicalMenu&&r.hierarchicalMenu[d];if(e.isConjunctiveFacet(d)||e.isDisjunctiveFacet(d))return"development"==="production".NODE_ENV&&c(!1,'HierarchicalMenu: Attribute "'.concat(d,'" is already used by another widget applying conjunctive or disjunctive faceting.\nAs this is not supported, please make sure to remove this other widget or this HierarchicalMenu widget will not work at all.')),e;if(e.isHierarchicalFacet(d)){var i=e.getHierarchicalFacetByName(d);"development"==="production".NODE_ENV&&c(De(i.attributes,a)&&i.separator===s&&i.rootPath===f,"Using Breadcrumb and HierarchicalMenu on the same facet with different options overrides the configuration of the HierarchicalMenu.")}var o=e.removeHierarchicalFacet(d).addHierarchicalFacet({name:d,attributes:a,separator:s,rootPath:f});return n?o.addHierarchicalFacetRefinement(d,n.join(s)):o.setQueryParameters({hierarchicalFacetsRefinements:Ho(Ho({},o.hierarchicalFacetsRefinements),{},qo({},d,[]))})}}}},connectGeoSearch:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,Xo()),function(r){var n,i=r||{},o=i.enableRefineOnMapMove,s=i.transformItems,c=void 0===s?function(e){return e}:s,u={isRefineOnMapMove:void 0===o||o,hasMapMoveSinceLastRefine:!1,lastRefinePosition:"",lastRefineBoundingBox:"",internalToggleRefineOnMapMove:a,internalSetMapMoveSinceLastRefine:a},f=function(e){return e.aroundLatLng?function(e){var t=e.match(ue);if(!t)throw new Error('Invalid value for "aroundLatLng" parameter: "'.concat(e,'"'));return{lat:parseFloat(t[1]),lng:parseFloat(t[2])}}(e.aroundLatLng):void 0},l=function(e){return e.insideBoundingBox&&(t=e.insideBoundingBox,Array.isArray(t)?function(e){var t=se(e,1)[0],r=se(void 0===t?[void 0,void 0,void 0,void 0]:t,4),n=r[0],i=r[1],a=r[2],o=r[3];if(!(n&&i&&a&&o))throw new Error('Invalid value for "insideBoundingBox" parameter: ['.concat(e,"]"));return{northEast:{lat:n,lng:i},southWest:{lat:a,lng:o}}}(t):function(e){var t=se(e.split(",").map(parseFloat),4),r=t[0],n=t[1],i=t[2],a=t[3];if(!(r&&n&&i&&a))throw new Error('Invalid value for "insideBoundingBox" parameter: "'.concat(e,'"'));return{northEast:{lat:r,lng:n},southWest:{lat:i,lng:a}}}(t));var t},h=function(e){return function(t){var r=t.northEast,n=t.southWest,i=[r.lat,r.lng,n.lat,n.lng].join();e.setState(zo(e.state,i).resetPage()).search(),u.hasMapMoveSinceLastRefine=!1,u.lastRefineBoundingBox=i}},d=function(e){return function(){e.setQueryParameter("insideBoundingBox",void 0).search()}},p=function(e){return function(){return Boolean(e.insideBoundingBox)}},v=function(){return u.internalToggleRefineOnMapMove()},m=function(e,t){return function(){u.isRefineOnMapMove=!u.isRefineOnMapMove,t(e)}},g=function(){return u.isRefineOnMapMove},y=function(){return u.internalSetMapMoveSinceLastRefine()},b=function(e,t){return function(){var r=!0!==u.hasMapMoveSinceLastRefine;u.hasMapMoveSinceLastRefine=!0,r&&t(e)}},w=function(){return u.hasMapMoveSinceLastRefine};return{$$type:Zo,init:function(t){var r=t.instantSearchInstance;u.internalToggleRefineOnMapMove=m(t,a),u.internalSetMapMoveSinceLastRefine=b(t,a),e(Ko(Ko({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance,i=t.helper.state,a=Boolean(i.aroundLatLng)&&Boolean(u.lastRefinePosition)&&i.aroundLatLng!==u.lastRefinePosition,o=!i.insideBoundingBox&&Boolean(u.lastRefineBoundingBox)&&i.insideBoundingBox!==u.lastRefineBoundingBox;(a||o)&&(u.hasMapMoveSinceLastRefine=!1),u.lastRefinePosition=i.aroundLatLng||"",u.lastRefineBoundingBox=Jo(i),u.internalToggleRefineOnMapMove=m(t,this.render.bind(this)),u.internalSetMapMoveSinceLastRefine=b(t,this.render.bind(this));var s=this.getWidgetRenderState(t);n("view:internal",s.items),e(Ko(Ko({},s),{},{instantSearchInstance:r}),!1)},getWidgetRenderState:function(e){var t=e.helper,i=e.results,a=e.instantSearchInstance,o=t.state,s=i?c(i.hits.filter(function(e){return e._geoloc}),{results:i}):[];return n||(n=X({instantSearchInstance:a,getIndex:function(){return t.getIndex()},widgetType:Zo})),{items:s,position:f(o),currentRefinement:l(o),refine:h(t),sendEvent:n,clearMapRefinement:d(t),isRefinedWithMap:p(o),toggleRefineOnMapMove:v,isRefineOnMapMove:g,setMapMoveSinceLastRefine:y,hasMapMoveSinceLastRefine:w,widgetParams:r}},getRenderState:function(e,t){return Ko(Ko({},e),{},{geoSearch:this.getWidgetRenderState(t)})},dispose:function(e){var r=e.state;return t(),r.setQueryParameter("insideBoundingBox",void 0)},getWidgetUiState:function(e,t){var r=Jo(t.searchParameters);return!r||e&&e.geoSearch&&e.geoSearch.boundingBox===r?e:Ko(Ko({},e),{},{geoSearch:{boundingBox:r}})},getWidgetSearchParameters:function(e,t){var r=t.uiState;return r&&r.geoSearch?zo(e,r.geoSearch.boundingBox):e.setQueryParameter("insideBoundingBox",void 0)}}}},connectPoweredBy:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;m(e,is());var r="https://www.algolia.com/?utm_source=instantsearch.js&utm_medium=website&"+"utm_content=".concat(ze(function(e){var t;return(null===(t=e.window.location)||void 0===t?void 0:t.hostname)||""},{fallback:function(){return""}}),"&")+"utm_campaign=poweredby";return function(n){var i=(n||{}).url,a=void 0===i?r:i;return{$$type:"ais.poweredBy",init:function(t){var r=t.instantSearchInstance;e(rs(rs({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(rs(rs({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},getRenderState:function(e,t){return rs(rs({},e),{},{poweredBy:this.getWidgetRenderState(t)})},getWidgetRenderState:function(){return{url:a,widgetParams:n}},dispose:function(){t()}}}},connectConfigure:ls,EXPERIMENTAL_connectConfigureRelatedItems:function(e,t){return function(r){var n=r||{},i=n.hit,a=n.matchingPatterns,o=n.transformSearchParameters,s=void 0===o?function(e){return e}:o;if(!i)throw new Error(ys("The `hit` option is required."));if(!a)throw new Error(ys("The `matchingPatterns` option is required."));var u=Object.keys(a).reduce(function(e,t){var r=a[t],n=de(i,t),o=r.score;return Array.isArray(n)?[].concat(ms(e),[n.map(function(e){return bs({attributeName:t,attributeValue:e,attributeScore:o})})]):"string"==typeof n?[].concat(ms(e),[bs({attributeName:t,attributeValue:n,attributeScore:o})]):("development"==="production".NODE_ENV&&c(!1,"\nThe `matchingPatterns` option returned a value of type ".concat(v(n),' for the "').concat(t,'" key. This value was not sent to Algolia because `optionalFilters` only supports strings and array of strings.\n\nYou can remove the "').concat(t,'" key from the `matchingPatterns` option.\n\nSee https://www.algolia.com/doc/api-reference/api-parameters/optionalFilters/\n            ')),e)},[]),f=ps({},s(new pr.SearchParameters({sumOrFiltersScores:!0,facetFilters:["objectID:-".concat(i.objectID)],optionalFilters:u})));return ps(ps({},ls(e,t)({searchParameters:f})),{},{$$type:"ais.configureRelatedItems"})}},connectAutocomplete:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,Ps()),function(r){var n=(r||{}).escapeHTML,i=void 0===n||n;"development"==="production".NODE_ENV&&c(!r.indices,"\nThe option `indices` has been removed from the Autocomplete connector.\n\nThe indices to target are now inferred from the widgets tree.\n".concat(Array.isArray(r.indices)?"\nAn alternative would be:\n\nconst autocomplete = connectAutocomplete(renderer);\n\nsearch.addWidgets([\n  ".concat(r.indices.map(function(e){return"index({ indexName: '".concat(e.value,"' }),")}).join("\n  "),"\n  autocomplete()\n]);\n"):"","\n      "));var a={};return{$$type:"ais.autocomplete",init:function(t){var r=t.instantSearchInstance;e(Os(Os({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance,n=this.getWidgetRenderState(t);n.indices.forEach(function(e){(0,e.sendEvent)("view:internal",e.hits)}),e(Os(Os({},n),{},{instantSearchInstance:r}),!1)},getRenderState:function(e,t){return Os(Os({},e),{},{autocomplete:this.getWidgetRenderState(t)})},getWidgetRenderState:function(e){var t=this,n=e.helper,o=e.state,s=e.scopedResults,c=e.instantSearchInstance;a.refine||(a.refine=function(e){n.setQuery(e).search()});var u=s.map(function(e){e.results.hits=i?N(e.results.hits):e.results.hits;var r=X({instantSearchInstance:c,getIndex:function(){return e.results.index},widgetType:t.$$type});return{indexId:e.indexId,indexName:e.results.index,hits:e.results.hits,results:e.results,sendEvent:r}});return{currentRefinement:o.query||"",indices:u,refine:a.refine,widgetParams:r}},getWidgetUiState:function(e,t){var r=t.searchParameters.query||"";return""===r||e&&e.query===r?e:Os(Os({},e),{},{query:r})},getWidgetSearchParameters:function(e,t){var r={query:t.uiState.query||""};return e.setQueryParameters(i?Os(Os({},r),T):r)},dispose:function(e){var r=e.state;t();var n=r.setQueryParameter("query",void 0);return i?n.setQueryParameters(Object.keys(T).reduce(function(e,t){return Os(Os({},e),{},js({},t,void 0))},{})):n}}}},connectQueryRules:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,Ts()),function(r){var n=r||{},i=n.trackedFilters,a=void 0===i?{}:i,o=n.transformRuleContexts,s=void 0===o?function(e){return e}:o,c=n.transformItems,u=void 0===c?function(e){return e}:c;Object.keys(a).forEach(function(e){if("function"!=typeof a[e])throw new Error(Ts("'The \"".concat(e,'" filter value in the `trackedFilters` option expects a function.')))});var f,l=Object.keys(a).length>0,h=[];return{$$type:"ais.queryRules",init:function(t){var n=t.helper,i=t.state,o=t.instantSearchInstance;f=ks.bind({helper:n,initialRuleContexts:h=i.ruleContexts||[],trackedFilters:a,transformRuleContexts:s}),l&&((function(e){return[e.disjunctiveFacetsRefinements,e.facetsRefinements,e.hierarchicalFacetsRefinements,e.numericRefinements].some(function(e){return Boolean(e&&Object.keys(e).length>0)})}(i)||Boolean(r.transformRuleContexts))&&f({state:i}),n.on("change",f)),e(Es(Es({},this.getWidgetRenderState(t)),{},{instantSearchInstance:o}),!0)},render:function(t){var r=t.instantSearchInstance;e(Es(Es({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},getWidgetRenderState:function(e){var t=e.results,n=(t||{}).userData;return{items:u(void 0===n?[]:n,{results:t}),widgetParams:r}},getRenderState:function(e,t){return Es(Es({},e),{},{queryRules:this.getWidgetRenderState(t)})},dispose:function(e){var r=e.helper,n=e.state;return t(),l?(r.removeListener("change",f),n.setQueryParameter("ruleContexts",h)):n}}}},connectVoiceSearch:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return m(e,Ws()),function(r){var n=r.searchAsYouSpeak,i=void 0!==n&&n,a=r.language,o=r.additionalQueryParameters,s=r.createVoiceSearchHelper,c=void 0===s?Ms:s;return{$$type:"ais.voiceSearch",init:function(t){var r=t.instantSearchInstance;e(Hs(Hs({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(Hs(Hs({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},getRenderState:function(e,t){return Hs(Hs({},e),{},{voiceSearch:this.getWidgetRenderState(t)})},getWidgetRenderState:function(t){var n=this,s=t.helper,u=t.instantSearchInstance;this._refine||(this._refine=function(e){if(e!==s.state.query){var t=a?[a.split("-")[0]]:void 0;s.setQueryParameter("queryLanguages",t),"function"==typeof o&&s.setState(s.state.setQueryParameters(Hs({ignorePlurals:!0,removeStopWords:!0,optionalWords:e},o({query:e})))),s.setQuery(e).search()}}),this._voiceSearchHelper||(this._voiceSearchHelper=c({searchAsYouSpeak:i,language:a,onQueryChange:function(e){return n._refine(e)},onStateChange:function(){e(Hs(Hs({},n.getWidgetRenderState(t)),{},{instantSearchInstance:u}),!1)}}));var f=this._voiceSearchHelper,l=f.isBrowserSupported,h=f.isListening,d=f.startListening,p=f.stopListening,v=f.getState;return{isBrowserSupported:l(),isListening:h(),toggleListening:function(){l()&&(h()?p():d())},voiceListeningState:v(),widgetParams:r}},dispose:function(e){var r=e.state;this._voiceSearchHelper.dispose(),t();var n=r;if("function"==typeof o){var i=o({query:""}),a=i?Object.keys(i).reduce(function(e,t){return e[t]=void 0,e},{}):{};n=r.setQueryParameters(Hs({queryLanguages:void 0,ignorePlurals:void 0,removeStopWords:void 0,optionalWords:void 0},a))}return n.setQueryParameter("query",void 0)},getWidgetUiState:function(e,t){var r=t.searchParameters.query||"";return r?Hs(Hs({},e),{},{query:r}):e},getWidgetSearchParameters:function(e,t){return e.setQueryParameter("query",t.uiState.query||"")}}}},connectRelevantSort:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:a,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a;return function(r){var n={};return{$$type:"ais.relevantSort",init:function(t){var r=t.instantSearchInstance;e(Qs(Qs({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!0)},render:function(t){var r=t.instantSearchInstance;e(Qs(Qs({},this.getWidgetRenderState(t)),{},{instantSearchInstance:r}),!1)},dispose:function(e){var r=e.state;return t(),r.setQueryParameter("relevancyStrictness",void 0)},getRenderState:function(e,t){return Qs(Qs({},e),{},{relevantSort:this.getWidgetRenderState(t)})},getWidgetRenderState:function(e){var t=e.results,i=e.helper;n.refine||(n.refine=function(e){i.setQueryParameter("relevancyStrictness",e).search()});var a=(t||{}).appliedRelevancyStrictness,o=void 0!==a;return{isRelevantSorted:void 0!==a&&a>0,isVirtualReplica:o,canRefine:o,refine:n.refine,widgetParams:r}},getWidgetSearchParameters:function(e,t){var r;return e.setQueryParameter("relevancyStrictness",null!==(r=t.uiState.relevantSort)&&void 0!==r?r:e.relevancyStrictness)},getWidgetUiState:function(e,t){var r=t.searchParameters;return Qs(Qs({},e),{},{relevantSort:r.relevancyStrictness||e.relevantSort})}}}}});return Js}();
</script>
</div>
		</div>
	</div>

	<div x-data="{ showButton: false }"
	 x-init="window.addEventListener('scroll', () => { showButton = window.scrollY > 100; })"
	 @scroll.window="showButton = window.scrollY > 100"
	 x-cloak=""
>
	<button x-show="showButton"
			@click="window.scrollTo({top: 0, behavior: 'smooth'})"
			class="z-50 fixed bottom-5 md:bottom-10 right-5 md:right-10 cursor-pointer bg-primary-500/90 hover:bg-primary-500 shadow-md rounded-xl p-1"
	>
		<svg class="h-8 w-8 text-white" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M213.66,165.66a8,8,0,0,1-11.32,0L128,91.31,53.66,165.66a8,8,0,0,1-11.32-11.32l80-80a8,8,0,0,1,11.32,0l80,80A8,8,0,0,1,213.66,165.66Z"/></svg>	</button>
</div>
		</div>
	<footer wire:snapshot="{&quot;data&quot;:[],&quot;memo&quot;:{&quot;id&quot;:&quot;IdfP1RcVwr2eHrtHvurQ&quot;,&quot;name&quot;:&quot;navigations.footer&quot;,&quot;path&quot;:&quot;\/&quot;,&quot;method&quot;:&quot;GET&quot;,&quot;release&quot;:&quot;a-a-a&quot;,&quot;children&quot;:[],&quot;scripts&quot;:[],&quot;assets&quot;:[],&quot;errors&quot;:[],&quot;locale&quot;:&quot;en&quot;},&quot;checksum&quot;:&quot;1da85c67fb472638b4865ae69c83ad3744e474cb6e58d97cb904f8f5c613d38e&quot;}" wire:effects="[]" wire:id="IdfP1RcVwr2eHrtHvurQ" class="bg-white ring-1 ring-gray-200 dark:ring-gray-800 dark:bg-gray-900" aria-labelledby="footer-heading">
	<h2 id="footer-heading" class="sr-only">Footer</h2>
	<div class="mx-auto max-w-full pb-8 pt-8 sm:pt-12 lg:pt-16 px-4 md:px-6 lg:px-8">
		<div class="xl:grid xl:grid-cols-3 xl:gap-8">
			<div class="space-y-8">
				<a href="https://camlovin.com" wire:navigate class="font-black text-2xl text-primary-500">
	CamLovin
</a>
				<p class="text-sm leading-6 text-gray-600 dark:text-gray-300">The #1 free sex cam site in 2026 and beyond.</p>
				<div class="flex space-x-6">
					<!--[if BLOCK]><![endif]-->						<a href="https://www.facebook.com/camlovin/" class="text-gray-400 hover:text-gray-500" target="_blank">
							<span class="sr-only">Facebook</span>
							<svg class="h-6 w-6" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm8,191.63V152h24a8,8,0,0,0,0-16H136V112a16,16,0,0,1,16-16h16a8,8,0,0,0,0-16H152a32,32,0,0,0-32,32v24H96a8,8,0,0,0,0,16h24v63.63a88,88,0,1,1,16,0Z"/></svg>						</a>
											<a href="https://www.instagram.com/camlovin_official/" class="text-gray-400 hover:text-gray-500" target="_blank">
							<span class="sr-only">Instagram</span>
							<svg class="h-6 w-6" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M128,80a48,48,0,1,0,48,48A48.05,48.05,0,0,0,128,80Zm0,80a32,32,0,1,1,32-32A32,32,0,0,1,128,160ZM176,24H80A56.06,56.06,0,0,0,24,80v96a56.06,56.06,0,0,0,56,56h96a56.06,56.06,0,0,0,56-56V80A56.06,56.06,0,0,0,176,24Zm40,152a40,40,0,0,1-40,40H80a40,40,0,0,1-40-40V80A40,40,0,0,1,80,40h96a40,40,0,0,1,40,40ZM192,76a12,12,0,1,1-12-12A12,12,0,0,1,192,76Z"/></svg>						</a>
											<a href="https://twitter.com/CamLovinLLC" class="text-gray-400 hover:text-gray-500" target="_blank">
							<span class="sr-only">X</span>
							<svg class="h-6 w-6" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M247.39,68.94A8,8,0,0,0,240,64H209.57A48.66,48.66,0,0,0,168.1,40a46.91,46.91,0,0,0-33.75,13.7A47.9,47.9,0,0,0,120,88v6.09C79.74,83.47,46.81,50.72,46.46,50.37a8,8,0,0,0-13.65,4.92c-4.31,47.79,9.57,79.77,22,98.18a110.93,110.93,0,0,0,21.88,24.2c-15.23,17.53-39.21,26.74-39.47,26.84a8,8,0,0,0-3.85,11.93c.75,1.12,3.75,5.05,11.08,8.72C53.51,229.7,65.48,232,80,232c70.67,0,129.72-54.42,135.75-124.44l29.91-29.9A8,8,0,0,0,247.39,68.94Zm-45,29.41a8,8,0,0,0-2.32,5.14C196,166.58,143.28,216,80,216c-10.56,0-18-1.4-23.22-3.08,11.51-6.25,27.56-17,37.88-32.48A8,8,0,0,0,92,169.08c-.47-.27-43.91-26.34-44-96,16,13,45.25,33.17,78.67,38.79A8,8,0,0,0,136,104V88a32,32,0,0,1,9.6-22.92A30.94,30.94,0,0,1,167.9,56c12.66.16,24.49,7.88,29.44,19.21A8,8,0,0,0,204.67,80h16Z"/></svg>						</a>
											<a href="https://www.reddit.com/r/CamLovin/" class="text-gray-400 hover:text-gray-500" target="_blank">
							<span class="sr-only">Reddit</span>
							<svg class="h-6 w-6" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M248,104a32,32,0,0,0-52.94-24.19c-16.75-8.9-36.76-14.28-57.66-15.53l5.19-31.17,17.72,2.72a24,24,0,1,0,2.87-15.74l-26-4a8,8,0,0,0-9.11,6.59L121.2,64.16c-21.84.94-42.82,6.38-60.26,15.65a32,32,0,0,0-42.59,47.74A59,59,0,0,0,16,144c0,21.93,12,42.35,33.91,57.49C70.88,216,98.61,224,128,224s57.12-8,78.09-22.51C228,186.35,240,165.93,240,144a59,59,0,0,0-2.35-16.45A32.16,32.16,0,0,0,248,104ZM184,24a8,8,0,1,1-8,8A8,8,0,0,1,184,24Zm40.13,93.78a8,8,0,0,0-3.29,10A43.58,43.58,0,0,1,224,144c0,16.53-9.59,32.27-27,44.33C178.67,201,154.17,208,128,208s-50.67-7-69-19.67C41.59,176.27,32,160.53,32,144a43.75,43.75,0,0,1,3.14-16.17,8,8,0,0,0-3.27-10A16,16,0,1,1,52.94,94.59a8,8,0,0,0,10.45,2.23l.36-.22C81.45,85.9,104.25,80,128,80h0c23.73,0,46.53,5.9,64.23,16.6l.42.25a8,8,0,0,0,10.39-2.26,16,16,0,1,1,21.07,23.19ZM88,144a16,16,0,1,1,16-16A16,16,0,0,1,88,144Zm96-16a16,16,0,1,1-16-16A16,16,0,0,1,184,128Zm-16.93,44.25a8,8,0,0,1-3.32,10.82,76.18,76.18,0,0,1-71.5,0,8,8,0,1,1,7.5-14.14,60.18,60.18,0,0,0,56.5,0A8,8,0,0,1,167.07,172.25Z"/></svg>						</a>
											<a href="https://www.linkedin.com/company/camlovin/" class="text-gray-400 hover:text-gray-500" target="_blank">
							<span class="sr-only">Linkedin</span>
							<svg class="h-6 w-6" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M216,24H40A16,16,0,0,0,24,40V216a16,16,0,0,0,16,16H216a16,16,0,0,0,16-16V40A16,16,0,0,0,216,24Zm0,192H40V40H216V216ZM96,112v64a8,8,0,0,1-16,0V112a8,8,0,0,1,16,0Zm88,28v36a8,8,0,0,1-16,0V140a20,20,0,0,0-40,0v36a8,8,0,0,1-16,0V112a8,8,0,0,1,15.79-1.78A36,36,0,0,1,184,140ZM100,84A12,12,0,1,1,88,72,12,12,0,0,1,100,84Z"/></svg>						</a>
											<a href="https://www.youtube.com/@CamLovin_Official" class="text-gray-400 hover:text-gray-500" target="_blank">
							<span class="sr-only">YouTube</span>
							<svg class="h-6 w-6" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256" fill="currentColor"><path d="M164.44,121.34l-48-32A8,8,0,0,0,104,96v64a8,8,0,0,0,12.44,6.66l48-32a8,8,0,0,0,0-13.32ZM120,145.05V111l25.58,17ZM234.33,69.52a24,24,0,0,0-14.49-16.4C185.56,39.88,131,40,128,40s-57.56-.12-91.84,13.12a24,24,0,0,0-14.49,16.4C19.08,79.5,16,97.74,16,128s3.08,48.5,5.67,58.48a24,24,0,0,0,14.49,16.41C69,215.56,120.4,216,127.34,216h1.32c6.94,0,58.37-.44,91.18-13.11a24,24,0,0,0,14.49-16.41c2.59-10,5.67-28.22,5.67-58.48S236.92,79.5,234.33,69.52Zm-15.49,113a8,8,0,0,1-4.77,5.49c-31.65,12.22-85.48,12-86,12H128c-.54,0-54.33.2-86-12a8,8,0,0,1-4.77-5.49C34.8,173.39,32,156.57,32,128s2.8-45.39,5.16-54.47A8,8,0,0,1,41.93,68c30.52-11.79,81.66-12,85.85-12h.27c.54,0,54.38-.18,86,12a8,8,0,0,1,4.77,5.49C221.2,82.61,224,99.43,224,128S221.2,173.39,218.84,182.47Z"/></svg>						</a>
					<!--[if ENDBLOCK]><![endif]-->				</div>
			</div>
			<div class="mt-16 grid grid-cols-2 gap-8 xl:col-span-2 xl:mt-0">
				<div class="md:grid md:grid-cols-2 md:gap-8">
					<div>
						<h3 class="text-sm font-semibold leading-6 text-gray-900 dark:text-gray-200">Pages</h3>
						<ul role="list" class="mt-6 space-y-4">
							<!--[if BLOCK]><![endif]-->								<li>
									<a href="https://camlovin.com" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Cams
									</a>
								</li>
															<li>
									<a href="https://camlovin.com/sites" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Sites
									</a>
								</li>
															<li>
									<a href="https://camlovin.com/random" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Random Cam
									</a>
								</li>
															<li>
									<a href="https://camlovin.com/sitemap" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Sitemap
									</a>
								</li>
							<!--[if ENDBLOCK]><![endif]-->						</ul>
					</div>
					<div class="mt-10 md:mt-0">
						<h3 class="text-sm font-semibold leading-6 text-gray-900 dark:text-gray-200">Help</h3>
						<ul role="list" class="mt-6 space-y-4">
							<!--[if BLOCK]><![endif]-->								<li>
									<a href="https://camlovin.com/insights/how-to-become-a-cam-girl" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Become a Cam Model
									</a>
								</li>
															<li>
									<a href="https://camlovin.com/contact" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Contact
									</a>
								</li>
							<!--[if ENDBLOCK]><![endif]-->						</ul>
					</div>
				</div>
				<div class="md:grid md:grid-cols-2 md:gap-8">
					<div>
						<h3 class="text-sm font-semibold leading-6 text-gray-900 dark:text-gray-200">Company</h3>
						<ul role="list" class="mt-6 space-y-4">
							<!--[if BLOCK]><![endif]-->								<li>
									<a href="https://camlovin.com/about" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										About us
									</a>
								</li>
															<li>
									<a href="https://camlovin.com/insights" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Insights
									</a>
								</li>
															<li>
									<a href="https://camlovin.com/insights" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Press
									</a>
								</li>
															<li>
									<a href="https://camlovin.com/sites" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Partners
									</a>
								</li>
							<!--[if ENDBLOCK]><![endif]-->						</ul>
					</div>
					<div class="mt-10 md:mt-0">
						<h3 class="text-sm font-semibold leading-6 text-gray-900 dark:text-gray-200">Legal</h3>
						<ul role="list" class="mt-6 space-y-4">
							<!--[if BLOCK]><![endif]-->								<li>
									<a href="https://camlovin.com/compliance" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Compliance
									</a>
								</li>
															<li>
									<a href="https://camlovin.com/privacy" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Privacy
									</a>
								</li>
															<li>
									<a href="https://camlovin.com/terms" wire:navigate class="text-sm leading-6 text-gray-600 hover:text-gray-900 dark:text-gray-400">
										Terms
									</a>
								</li>
							<!--[if ENDBLOCK]><![endif]-->						</ul>
					</div>
				</div>
			</div>
		</div>
		<div class="mt-8 border-t border-gray-900/10 pt-8 sm:mt-10 lg:mt-12">
			<p class="text-xs leading-5 text-gray-500 dark:text-gray-400">&copy; 2026 CamLovin &dash; All rights reserved.</p>
		</div>
	</div>
</footer>
<div wire:snapshot="{&quot;data&quot;:{&quot;isFilamentNotificationsComponent&quot;:true,&quot;notifications&quot;:[[],{&quot;class&quot;:&quot;Filament\\Notifications\\Collection&quot;,&quot;s&quot;:&quot;wrbl&quot;}]},&quot;memo&quot;:{&quot;id&quot;:&quot;sGc1DZcNh8nphGjref17&quot;,&quot;name&quot;:&quot;notifications&quot;,&quot;path&quot;:&quot;\/&quot;,&quot;method&quot;:&quot;GET&quot;,&quot;release&quot;:&quot;a-a-a&quot;,&quot;children&quot;:[],&quot;scripts&quot;:[],&quot;assets&quot;:[],&quot;errors&quot;:[],&quot;locale&quot;:&quot;en&quot;},&quot;checksum&quot;:&quot;1e1c10217f011b20fd4c9949549e056e4d0aecdbdd7509dbdd8fbd792690cb47&quot;}" wire:effects="{&quot;listeners&quot;:[&quot;notificationsSent&quot;,&quot;notificationSent&quot;,&quot;notificationClosed&quot;]}" wire:id="sGc1DZcNh8nphGjref17">
    <div
        class="fi-no pointer-events-none fixed inset-4 z-50 mx-auto flex gap-3 items-end flex-col-reverse justify-end"
        role="status"
    >
        <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]-->    </div>

    <!--[if BLOCK]><![endif]--><!--[if ENDBLOCK]><![endif]--></div>
<script>
        window.filamentData = []    </script>

            
            <script
                src="https://camlovin.com/js/awcodes-sticky-header/awcodes-sticky-header.js?v=3.3.45.0"
                
                
                
                
                
                
            ></script>
        
                
            <script
                src="https://camlovin.com/js/awcodes/scribble/scribble-modal.js?v=0.8.1.0-alpha"
                
                
                
                
                
                
            ></script>
        
                
            <script
                src="https://camlovin.com/js/filament/notifications/notifications.js?v=3.3.45.0"
                
                
                
                
                
                
            ></script>
        
                
            <script
                src="https://camlovin.com/js/filament/support/support.js?v=3.3.45.0"
                
                
                
                
                
                
            ></script>
        
    
<style>
    :root {
            }
</style>
	<script>
        const cssHelpers = Object.freeze({
            sliderBackgroundColor: 'tomato',
            sliderBorderColor: '#8b8b8b',
            sliderBorderRadius: '4px',
            sliderCircleSize: 20,
            sliderCircleBackgroundColor: '#ffffff',
            sliderCircleFocusColor: '#0074cc',
            sliderCommonSize: '0.5em',
        });

        const constants = Object.freeze({
            MIN: 'min',
            MAX: 'max',
            SLIDER_ID: 'minMaxSlider',
            MIN_LABEL_ID: `minLabel`,
            MAX_LABEL_ID: `maxLabel`,
            RANGE_STOPPED_EVENTS: ['mouseup', 'touchend', 'keyup'],
            CUSTOM_EVENT_TO_EMIT_NAME: 'range-changed',
            RANGE_INPUT_DATA_LABEL_MIN: 'data-range-input-label-min',
            RANGE_INPUT_DATA_LABEL_MAX: 'data-range-input-label-max',
        });

        const template = document.createElement('template');
        template.innerHTML = `
    <style>
      .min-max-slider {
        position: relative;
        width: 100%;
        text-align: center;
      }

      .min-max-slider > label {
        position: absolute;
        left: -10000px;
        top: auto;
        width: 1px;
        height: 1px;
        overflow: hidden;
      }

      .min-max-slider > .legend {
        display: flex;
        justify-content: space-between;
      }

      .min-max-slider > .range-input {
        --sliderCircleSize: ${cssHelpers.sliderCircleSize}px;
        --sliderColor: ${cssHelpers.sliderCircleBackgroundColor};
        --sliderBorderColor: ${cssHelpers.sliderBorderColor};
        --sliderFocusBorderColor: ${cssHelpers.sliderCircleFocusColor};
        --sliderCircleBorder: 1px solid var(--sliderBorderColor);
        --sliderCircleFocusBorder: 2px solid var(--sliderFocusBorderColor);
        cursor: pointer;
        position: absolute;
        -webkit-appearance: none;
        appearance: none;
        outline: none !important;
        background: transparent;
        background-image: linear-gradient(to bottom, transparent 0%, transparent 30%, ${cssHelpers.sliderBackgroundColor} 30%, ${cssHelpers.sliderBackgroundColor} 60%, transparent 60%, transparent 100%);
      }

      .min-max-slider > .range-input::-webkit-slider-thumb {
        -webkit-appearance: none;
        appearance: none;
        width: var(--sliderCircleSize);
        height: var(--sliderCircleSize);
        background-color: var(--sliderColor);
        cursor: pointer;
        border: var(--sliderCircleBorder);
        border-radius: 100%;
      }

      .min-max-slider > .range-input::-moz-range-thumb {
        width: var(--sliderCircleSize);
        height: var(--sliderCircleSize);
        background-color: var(--sliderColor);
        cursor: pointer;
        border: var(--sliderCircleBorder);
        border-radius: 100%;
      }

      .min-max-slider > .range-input::-webkit-slider-runnable-track,
      .min-max-slider > .range-input::-moz-range-track {
        cursor: pointer;
      }

      .min-max-slider > .range-input:focus::-webkit-slider-thumb {
        /* Accessible border on focus */
        border: var(--sliderCircleFocusBorder);
      }

      .min-max-slider > .range-input:focus::-moz-range-thumb {
          /* Accessible border on focus */
          border: var(--sliderCircleFocusBorder);
      }

      span.value {
        --labelBeforeContent: '';
        --labelAfterContent: '';
        --labelFontSize: 16px;
        --labelFontWeight: bold;
        font-size: var(--labelFontSize);
        font-weight: var(--labelFontWeight);
        height: auto;
        display: inline-block;
      }

      span.value::before {
        content: var(--labelBeforeContent);
      }

      span.value::after {
        content: var(--labelAfterContent);
      }

      .range-input-dash-icon {
        padding: 0 ${cssHelpers.sliderCommonSize};
      }

      .range-input-label {
          border: 1px solid ${cssHelpers.sliderBorderColor};
          border-radius: ${cssHelpers.sliderBorderRadius};
          padding: ${cssHelpers.sliderCommonSize};
      }
    </style>

    <div id="${constants.SLIDER_ID}" class="min-max-slider"></div>
`;

        class SimpleRange extends HTMLElement {
            constructor() {
                super();

                // Setting these variables so that we can clean up the event listeners
                // on the disconnectedCallback, you can't just remove an anonymous function
                // otherwise
                this.emitRangeSelection = () => this.emitRange();
                this.onRangeInput = (el) => this.update(el.target);

                // Setting up the shadow DOM
                this.attachShadow({ mode: 'open' });
                this.shadowRoot.appendChild(template.content.cloneNode(true));
            }

            get sliderId() {
                return this.getAttribute('id');
            }

            get minRange() {
                return (
                    parseInt(this.getAttribute('min-range')) ||
                    parseInt(this.getAttribute('min')) ||
                    0
                );
            }
            set minRange(minimumRange) {
                this.setAttribute('min-range', minimumRange);
                this.setAttribute('min', minimumRange);
            }

            get maxRange() {
                return (
                    parseInt(this.getAttribute('max-range')) ||
                    parseInt(this.getAttribute('max')) ||
                    1
                );
            }
            set maxRange(maximumRange) {
                this.setAttribute('max-range', maximumRange);
                this.setAttribute('max', maximumRange);
            }

            get presetMin() {
                return parseInt(this.getAttribute('preset-min'));
            }
            set presetMin(presetMinVal) {
                this.setAttribute('preset-min', presetMinVal);
            }

            get presetMax() {
                return parseInt(this.getAttribute('preset-max'));
            }
            set presetMax(presetMaxVal) {
                this.setAttribute('preset-max', presetMaxVal);
            }

            get numberOfLegendItemsToShow() {
                // If the consumer has specified the number of items to show and the number is at least 2
                // then we return that number, else we return 2 as there always needs to be at least 2
                const numOfLegendItems = parseInt(
                    this.getAttribute('number-of-legend-items-to-show')
                );
                return numOfLegendItems && numOfLegendItems > 1 ? numOfLegendItems : 2;
            }

            get hideLegend() {
                return this.hasAttribute('hide-legend');
            }

            get hideLabel() {
                return this.hasAttribute('hide-label');
            }

            get inputsForLabels() {
                return this.hasAttribute('inputs-for-labels');
            }

            get sliderColor() {
                return this.getAttribute('slider-color');
            }

            get circleColor() {
                return this.getAttribute('circle-color');
            }

            get circleBorderColor() {
                // Altering the circle border color only
                return this.getAttribute('circle-border-color');
            }

            get circleFocusBorderColor() {
                // Altering the circle focus border color only
                return this.getAttribute('circle-focus-border-color');
            }

            get circleBorder() {
                // Altering the whole border
                return this.getAttribute('circle-border');
            }

            get circleFocusBorder() {
                // Altering the whole focus border
                return this.getAttribute('circle-focus-border');
            }

            get circleSize() {
                return this.getAttribute('circle-size');
            }

            get labelAfterContent() {
                // CSS ::after
                return this.getAttribute('label-after');
            }

            get labelBeforeContent() {
                // CSS ::before
                return this.getAttribute('label-before');
            }

            get labelFontWeight() {
                return this.getAttribute('label-font-weight');
            }

            get labelFontSize() {
                return this.getAttribute('label-font-size');
            }

            get eventNameToEmitOnChange() {
                return (
                    this.getAttribute('event-name-to-emit-on-change') ||
                    constants.CUSTOM_EVENT_TO_EMIT_NAME
                );
            }

            get numberLocale() {
                return this.getAttribute('number-locale');
            }

            static get observedAttributes() {
                return [
                    'min-label',
                    'max-label',
                    'min-range',
                    'max-range',
                    'min',
                    'max',
                    'preset-min',
                    'preset-max',
                ];
            }

            attributeChangedCallback(name, oldValue, newValue) {
                // this.init() cannot be called outside of the switch or else if
                // there are multiple sliders on the same page then you will fire
                // that init event for all of them as well causing weird bugs
                switch (name) {
                    case 'min-label':
                        if (!newValue) {
                            return;
                        }

                        const minLabel = this.getEl(constants.MIN_LABEL_ID);
                        if (!minLabel) {
                            return;
                        }

                        minLabel.innerText = newValue;
                        this.init();
                        break;
                    case 'max-label':
                        if (!newValue) {
                            return;
                        }

                        const maxLabel = this.getEl(constants.MAX_LABEL_ID);
                        if (!maxLabel) {
                            return;
                        }

                        maxLabel.innerText = newValue;
                        this.init();
                        break;
                    case 'min-range':
                    case 'min':
                        if (isNaN(newValue) || oldValue === newValue) {
                            return;
                        }

                        this.minRange = newValue;
                        this.init();
                        break;
                    case 'max-range':
                    case 'max':
                        if (isNaN(newValue) || oldValue === newValue) {
                            return;
                        }

                        this.maxRange = newValue;
                        this.init();
                        break;
                    case 'preset-min':
                        if (isNaN(newValue) || oldValue === newValue) {
                            return;
                        }

                        this.presetMin = newValue;
                        this.init();
                        break;
                    case 'preset-max':
                        if (isNaN(newValue) || oldValue === newValue) {
                            return;
                        }

                        this.presetMax = newValue;
                        this.init();
                        break;
                }
            }

            connectedCallback() {
                this.init();

                const resizeObserver = new ResizeObserver(this.onResize(this));
                resizeObserver.observe(this.shadowRoot.querySelector('.min-max-slider'));
            }

            disconnectedCallback() {
                // Removing event listeners
                const slider = this.getEl(constants.SLIDER_ID);

                const min = slider.querySelector(`#${constants.MIN}`);
                this.removeEventListeners(
                    min,
                    constants.RANGE_STOPPED_EVENTS,
                    this.emitRangeSelection,
                    false
                );
                this.removeEventListeners(min, ['input'], this.onRangeInput, false);

                const max = slider.querySelector(`#${constants.MAX}`);
                this.removeEventListeners(
                    max,
                    constants.RANGE_STOPPED_EVENTS,
                    this.emitRangeSelection,
                    false
                );
                this.removeEventListeners(max, ['input'], this.onRangeInput, false);

                if (this.inputsForLabels) {
                    const lower = slider.querySelector(
                        `[${constants.RANGE_INPUT_DATA_LABEL_MIN}]`
                    );
                    const upper = slider.querySelector(
                        `[${constants.RANGE_INPUT_DATA_LABEL_MAX}]`
                    );

                    this.removeEventListeners(lower, ['input'], this.onRangeInput, false);

                    this.removeEventListeners(upper, ['input'], this.onRangeInput, false);

                    this.removeEventListeners(
                        lower,
                        ['blur'],
                        this.emitRangeSelection,
                        false
                    );

                    this.removeEventListeners(
                        upper,
                        ['blur'],
                        this.emitRangeSelection,
                        false
                    );

                    // TODO Max P: reset-range event
                }
            }

            dispatchCustomEvent(el, event) {
                const objToDispatchFrom = el ? el : window;
                objToDispatchFrom.dispatchEvent(event);
            }

            // Helper method to add event listeners for multiple events
            addMultipleEventListeners(element, events, handler) {
                events.forEach((e) => element.addEventListener(e, handler));
            }

            // Helper method to remove listeners for multiple events
            removeEventListeners(element, events, callBack, useCapture) {
                events.forEach((event) => {
                    element.removeEventListener(event, callBack, useCapture);
                });
            }

            getAverage(min, max) {
                return Math.floor((min + max) / 2);
            }

            getEl(id) {
                return this.shadowRoot.getElementById(id);
            }

            // Setting the initial state of the application
            init() {
                const slider = this.getEl(constants.SLIDER_ID);

                this.setInitialSliderState(slider);
                this.setupStyles();

                const min = slider.querySelector(`#${constants.MIN}`);
                const max = slider.querySelector(`#${constants.MAX}`);

                this.setupPresetValues(min, max);

                this.createLabels(slider, min);
                this.createLegend(slider);

                this.draw(
                    slider,
                    this.getAverage(
                        this.presetMin || this.minRange,
                        this.presetMax || this.maxRange
                    )
                );

                // Adding update event that updates the range selector
                min.addEventListener('input', this.onRangeInput);
                max.addEventListener('input', this.onRangeInput);

                // Adding events when the user stops selecting a range
                // this is then used to emit the events to whoever is
                // consuming this component. If you did it in the `update`
                // function it would be called hundreds of times, this allows
                // us to only call it when the input has stopped.
                this.addMultipleEventListeners(
                    min,
                    constants.RANGE_STOPPED_EVENTS,
                    this.emitRangeSelection
                );
                this.addMultipleEventListeners(
                    max,
                    constants.RANGE_STOPPED_EVENTS,
                    this.emitRangeSelection
                );

                this.setupResetFunctionality();
                this.setupRangeSetFunctionality();
            }

            // We are using currying because the `ResizeObserver` will call whatever
            // function you pass into it passing an `entries` object and if you need
            // to access `this` then you need to pass that into the function as well
            onResize(localThis) {
                return function (entries) {
                    const slider = entries[0].target;
                    localThis.update(slider.querySelector('.range-input'));
                };
            }

            // Sets the initial inner HTML of the slider. This is necessary because the init()
            // function appends other elements downstream and if we don't reset it then things
            // will end up getting duplicated
            setInitialSliderState(slider) {
                slider.innerHTML = `
      <label id="${constants.MIN_LABEL_ID}" for="${constants.MIN}">Minimum</label>
      <input id="${constants.MIN}" class="range-input" name="${constants.MIN}" type="range" step="1" />
      <label id="${constants.MAX_LABEL_ID}" for="${constants.MAX}">Maximum</label>
      <input id="${constants.MAX}" class="range-input" name="${constants.MAX}" type="range" step="1" />
    `;
            }

            // If presetMin or presetMax are set then we use those preset values
            // else we use the min & max ranges
            setupPresetValues(min, max) {
                const minValue =
                    this.presetMin && this.presetMin < this.presetMax
                        ? this.presetMin
                        : this.minRange;

                const maxValue =
                    this.presetMax && this.presetMax > this.presetMin
                        ? this.presetMax
                        : this.maxRange;

                min.setAttribute('data-value', minValue);
                max.setAttribute('data-value', maxValue);

                min.value = minValue;
                max.value = maxValue;
            }

            // Adding event listener to reset the slider to it's initial state
            // whenever the `range-reset` event is emitted. If the user provides a
            // sliderId then it will only reset that specific slider, else it will
            // reset *all* sliders
            setupResetFunctionality() {
                document.addEventListener('range-reset', (event) => {
                    if (
                        !event.detail ||
                        !event.detail.sliderId ||
                        event.detail.sliderId === this.sliderId
                    ) {
                        // The user has not provided a sliderId so we reset *every* slider
                        // on the page, OR they *have* provided a sliderId so we are only
                        // resetting that specific slider
                        this.presetMin = this.minRange;
                        this.presetMax = this.maxRange;
                        this.init();
                    }
                });
            }

            // Adding event listener to update range values
            setupRangeSetFunctionality() {
                document.addEventListener('range-set', (event) => {
                    if (
                        !event.detail ||
                        !event.detail.minValue ||
                        !event.detail.maxValue ||
                        !event.detail.sliderId
                    ) {
                        console.error(
                            `Simple Range Error: range-set was called without providing all of the
           required values. The event must contain the minValue, maxValue, and the
           sliderId. Additionally, the slider must have an id attribute on the
           component itself.`
                        );

                        return;
                    }

                    if (event.detail.sliderId === this.sliderId) {
                        this.presetMin = event.detail.minValue;
                        this.presetMax = event.detail.maxValue;
                    }
                });
            }

            // Emits new custom event for min-range-changed or max-range-changed so
            // that the consumer of this component can do whatever they need when
            // the values are changed
            emitRange() {
                const slider = this.getEl(constants.SLIDER_ID);
                const min = slider.querySelector(`#${constants.MIN}`);
                const max = slider.querySelector(`#${constants.MAX}`);

                this.dispatchCustomEvent(
                    slider,
                    new CustomEvent(this.eventNameToEmitOnChange, {
                        bubbles: true,
                        composed: true,
                        detail: {
                            sliderId: this.sliderId,
                            minRangeValue: Math.floor(min.getAttribute('data-value')),
                            maxRangeValue: Math.floor(max.getAttribute('data-value')),
                        },
                    })
                );
            }

            draw(slider, splitValue) {
                const min = slider.querySelector(`#${constants.MIN}`);
                min.setAttribute(constants.MIN, this.minRange);
                min.setAttribute(constants.MAX, splitValue);

                const max = slider.querySelector(`#${constants.MAX}`);
                max.setAttribute(constants.MIN, splitValue);
                max.setAttribute(constants.MAX, this.maxRange);

                const rangeWidth = slider.offsetWidth;
                const thumbSize = cssHelpers.sliderCircleSize;

                min.style.width = `${parseInt(
                    thumbSize +
                    ((splitValue - this.minRange) / (this.maxRange - this.minRange)) *
                    (rangeWidth - 2 * thumbSize)
                )}px`;
                max.style.width = `${parseInt(
                    thumbSize +
                    ((this.maxRange - splitValue) / (this.maxRange - this.minRange)) *
                    (rangeWidth - 2 * thumbSize)
                )}px`;
                min.style.left = '0px';
                max.style.left = `${parseInt(min.style.width)}px`;

                const lower = slider.querySelector('.lower');

                let sliderHeight = min.offsetHeight;
                if (!this.hideLabel) {
                    const offsetHeight = this.inputsForLabels
                        ? lower.offsetHeight + 5
                        : lower.offsetHeight;
                    min.style.top = `${offsetHeight}px`;
                    max.style.top = `${offsetHeight}px`;

                    sliderHeight += offsetHeight;
                }

                if (!this.hideLegend) {
                    const legend = slider.querySelector('.legend');
                    const offsetHeight = this.inputsForLabels
                        ? min.offsetHeight + 5
                        : min.offsetHeight;
                    legend.style.paddingTop = `${offsetHeight}px`;

                    sliderHeight += +legend.offsetHeight;
                }

                slider.style.height = `${sliderHeight}px`;

                max.value = max.getAttribute('data-value');
                min.value = min.getAttribute('data-value');

                if (!this.hideLabel) {
                    const upper = slider.querySelector('.upper');

                    if (this.inputsForLabels) {
                        lower.value = min.getAttribute('data-value');
                        upper.value = max.getAttribute('data-value');
                    } else {
                        if (this.numberLocale) {
                            lower.innerHTML = parseInt(
                                min.getAttribute('data-value')
                            ).toLocaleString(this.numberLocale);
                            upper.innerHTML = parseInt(
                                max.getAttribute('data-value')
                            ).toLocaleString(this.numberLocale);
                        } else {
                            lower.innerHTML = min.getAttribute('data-value');
                            upper.innerHTML = max.getAttribute('data-value');
                        }
                    }
                }
            }

            update(el) {
                const slider = el.parentElement;

                if (!slider) {
                    return;
                }

                let minQuerySelector;
                let maxQuerySelector;
                if (
                    el.hasAttribute(constants.RANGE_INPUT_DATA_LABEL_MIN) ||
                    el.hasAttribute(constants.RANGE_INPUT_DATA_LABEL_MAX)
                ) {
                    minQuerySelector = `[${constants.RANGE_INPUT_DATA_LABEL_MIN}]`;
                    maxQuerySelector = `[${constants.RANGE_INPUT_DATA_LABEL_MAX}]`;
                } else {
                    minQuerySelector = `#${constants.MIN}`;
                    maxQuerySelector = `#${constants.MAX}`;
                }

                let min = slider.querySelector(minQuerySelector);
                let max = slider.querySelector(maxQuerySelector);

                let minValue = Math.floor(parseInt(min.value));
                let maxValue = Math.floor(parseInt(max.value));

                if (!this.isValidRangeSelection(el, minValue, maxValue)) {
                    return;
                }

                // Setting the inactive values before drawing
                let minSliderInput = slider.querySelector(`#${constants.MIN}`);
                minSliderInput.setAttribute('data-value', minValue);

                let maxSliderInput = slider.querySelector(`#${constants.MAX}`);
                maxSliderInput.setAttribute('data-value', maxValue);

                this.draw(slider, this.getAverage(minValue, maxValue));
            }

            isValidRangeSelection(el, minValue, maxValue) {
                // Checking if the values are within the acceptable range
                // since the min value should never be more than the maxvalue
                // and the maxValue never less than the minValue.
                // This could occur if the user has inputs enabled and manually
                // types a wrong number into the input. In those cases we ignore
                // it and return until the user has adjusted the params to be valid
                if (this.inputsForLabels) {
                    const isMinEl =
                        el.hasAttribute(constants.RANGE_INPUT_DATA_LABEL_MIN) ||
                        el.getAttribute('id') === constants.MIN;

                    if (isMinEl) {
                        return (minValue) =>
                            this.minRange && minValue < this.maxRange && minValue < maxValue;
                    } else {
                        return (
                            maxValue > this.minRange &&
                            maxValue <= this.maxRange &&
                            maxValue > minValue
                        );
                    }
                }

                // They are using the non-input version, the only way to make the values
                // not valid would be if someone is trying doing something naughty in
                // which case oh well if this component breaks
                return minValue !== maxValue;
            }

            setupStyles() {
                // TODO: Max P - this logic should be revisited and made more dynamic
                // TODO: without all of the conditioals for each styleable attribute
                const rangeInputEls = this.shadowRoot.querySelectorAll(
                    '.min-max-slider > .range-input'
                );

                rangeInputEls.forEach((el) => {
                    if (this.sliderColor) {
                        el.style.backgroundImage = `linear-gradient(to bottom, transparent 0%, transparent 30%, ${this.sliderColor} 30%, ${this.sliderColor} 60%, transparent 60%, transparent 100%)`;
                    }

                    if (this.circleColor) {
                        el.style.setProperty('--sliderColor', this.circleColor);
                    }

                    if (this.circleBorderColor) {
                        el.style.setProperty('--sliderBorderColor', this.circleBorderColor);
                    }

                    if (this.circleFocusBorderColor) {
                        el.style.setProperty(
                            '--sliderFocusBorderColor',
                            this.circleFocusBorderColor
                        );
                    }

                    if (this.circleBorder) {
                        el.style.setProperty('--sliderCircleBorder', this.circleBorder);
                    }

                    if (this.circleFocusBorder) {
                        el.style.setProperty(
                            '--sliderCircleFocusBorder',
                            this.circleFocusBorder
                        );
                    }

                    if (this.circleSize) {
                        el.style.setProperty('--sliderCircleSize', this.circleSize);
                    }
                });
            }

            createLegend(slider) {
                if (this.hideLegend) {
                    return;
                }

                // Sets the legend values (the numbers below the slider bar
                // this is dynamic and can handle any number of items in the
                // legend, that's why there is a loop in the event you have
                // more than 2 values in the legend
                let legend = document.createElement('div');
                legend.classList.add('legend');
                let legendvalues = [];

                for (let i = 0; i < this.numberOfLegendItemsToShow; i++) {
                    legendvalues[i] = document.createElement('div');
                    const val = Math.round(
                        this.minRange +
                        (i / (this.numberOfLegendItemsToShow - 1)) *
                        (this.maxRange - this.minRange)
                    );
                    const valString = this.numberLocale
                        ? val.toLocaleString(this.numberLocale)
                        : val.toString();
                    legendvalues[i].appendChild(document.createTextNode(valString));
                    legend.appendChild(legendvalues[i]);
                }

                slider.appendChild(legend);
            }

            setupLabelStyles(lower, upper) {
                // Setting up custom CSS styles for labels
                const setPropertyForLabels = (property, value) => {
                    lower.style.setProperty(property, value);
                    upper.style.setProperty(property, value);
                };

                if (this.labelAfterContent) {
                    setPropertyForLabels(
                        '--labelAfterContent',
                        `'${this.labelAfterContent}'`
                    );
                }

                if (this.labelBeforeContent) {
                    setPropertyForLabels(
                        '--labelBeforeContent',
                        `'${this.labelBeforeContent}'`
                    );
                }

                if (this.labelFontWeight) {
                    setPropertyForLabels('--labelFontWeight', this.labelFontWeight);
                }

                if (this.labelFontSize) {
                    setPropertyForLabels('--labelFontSize', this.labelFontSize);
                }
            }

            createLabels(slider, min) {
                if (this.hideLabel) {
                    return;
                }

                const labelType = this.inputsForLabels ? 'input' : 'span';
                let lower = document.createElement(labelType);
                let upper = document.createElement(labelType);

                // range-input-label & range-span-label's are created here:
                lower.classList.add(`range-${labelType}-label`, 'lower', 'value');
                upper.classList.add(`range-${labelType}-label`, 'upper', 'value');

                this.setupLabelStyles(lower, upper);

                if (this.inputsForLabels) {
                    lower.value = this.minRange;
                    upper.value = this.maxRange;

                    lower.setAttribute('type', 'number');
                    lower.setAttribute(constants.MAX, this.minRange);
                    lower.setAttribute(constants.MAX, this.maxRange);
                    lower.setAttribute(constants.RANGE_INPUT_DATA_LABEL_MIN, '');

                    upper.setAttribute('type', 'number');
                    upper.setAttribute(constants.MIN, this.minRange);
                    upper.setAttribute(constants.MAX, this.maxRange);
                    upper.setAttribute(constants.RANGE_INPUT_DATA_LABEL_MAX, '');

                    lower.addEventListener('input', this.onRangeInput);
                    upper.addEventListener('input', this.onRangeInput);

                    lower.addEventListener('blur', this.emitRangeSelection);
                    upper.addEventListener('blur', this.emitRangeSelection);
                } else {
                    lower.appendChild(document.createTextNode(this.minRange));
                    upper.appendChild(document.createTextNode(this.maxRange));
                }

                slider.insertBefore(lower, min.previousElementSibling);
                slider.insertBefore(upper, min.previousElementSibling);

                // Adding a "-" symbol beyween the range inputs and labels since you cannot do
                // this via CSS pseudo (before/after) selectors on an input element and
                // we already use the pseudo selectors as a customization option for the labels
                let dashIcon = document.createElement('i');
                dashIcon.classList.add('range-input-dash-icon');
                dashIcon.setAttribute('aria-hidden', true);
                dashIcon.innerHTML = '&#65123';
                slider.insertBefore(
                    dashIcon,
                    min.previousElementSibling.previousElementSibling
                );
            }
        }

        window.customElements.define('range-selector', SimpleRange);
	</script>
	<script src="https://cdnjs.cloudflare.com/ajax/libs/hls.js/1.5.7/hls.min.js"></script>
	<script defer src="https://cdn.jsdelivr.net/npm/@alpinejs/intersect@3.x.x/dist/cdn.min.js"></script>
<script src="/livewire/livewire.min.js?id=0f6341c0"   data-csrf="U0NwIN1b3gNn49mAf2BsGgcgC9qYhbkX1Mnr377a" data-update-uri="/wire/up" data-navigate-once="true"></script>
</body>
</html>

