!function(){{var t=()=>-1<navigator.platform.indexOf("Mac");let e=!1;const o=document.getElementById("search-script").dataset;var n=algoliasearch(o.appId,o.apiKey);let i=null;const a=instantsearch({indexName:o.indexName,searchClient:n});let c;const s=e=>e.replaceAll("&amp;lt;","&lt;").replaceAll("&amp;gt;","&gt;"),d=(n=instantsearch.connectors.connectInfiniteHits((e,t)=>{const{hits:n,showMore:r,widgetParams:a}=e;var l=a["container"];c=e,i=null,t?(t=document.createElement("div"),l.appendChild(document.createElement("ul")),l.appendChild(t),new IntersectionObserver(e=>{e.forEach(e=>{e.isIntersecting&&!c.isLastPage&&r()})}).observe(t)):(t=[...n],l.querySelector("#showmore")&&l.removeChild(l.querySelector("#showmore")),l.querySelector("#nomore")&&l.removeChild(l.querySelector("#nomore")),e=e.results.nbHits,0===n.length?(l.querySelector("ul").innerHTML='<li class="no-result">No result</li>',document.querySelector("#counter").style.display="none"):(document.querySelector("#counter").innerHTML=`<strong>${e}</strong> result${1<e?"s":""} found`,document.querySelector("#counter").style.display="block",l.querySelector("ul").innerHTML=t.map(n=>{let e="",t="";var r;return n.content&&(e=`<p class="hit-description">
                ${instantsearch.snippet({hit:n,attribute:"content"})}
              </p>`),n.breadcrumbs&&(t=`<div class="hit-breadcrumbs">
                ${n.breadcrumbs.map(e=>{return`<span>${e.split("|")[0]}</span>`}).join(" > ")}
              </div>`),r=Object.keys(n.hierarchy).map((e,t)=>0<t&&n?instantsearch.highlight({hit:n,attribute:"hierarchy."+e}):null).filter(e=>!!e).join(" - "),`<li>
              <a href="${n.url}" class="ais-Hits-item">
                <div class="hit-name">
                  ${s(r)}
                </div>
                ${s(t)}
                ${s(e)}
              </a>
            </li>`}).join(""),l.querySelectorAll("ul a").forEach(e=>{e.addEventListener("click",()=>{MicroModal.close("modal-1")})}),c.isLastPage?((e=document.createElement("div")).setAttribute("id","nomore"),e.innerHTML="No more result",l.appendChild(e)):(t=document.createElement("div"),e=document.createElement("a"),t.setAttribute("id","showmore"),e.addEventListener("click",()=>(r(),!1)),e.innerHTML="Show more",t.appendChild(e),l.appendChild(t))))}),e=>{var t=document.querySelectorAll("#hits>ul>li>a");t[i]&&(t[i].classList.remove("selected"),i=null),t[e]&&(t[e].classList.add("selected"),i=e),i&&t[i].scrollIntoView()});var r=instantsearch.connectors.connectSearchBox((e,t)=>{const{query:n,refine:r,isSearchStalled:a,widgetParams:l}=e;var c;t&&((e=document.createElement("input")).classList.add("ais-SearchBox-input"),e.placeholder="Search in the current documentation "+o.pageGeneration,(t=document.createElement("span")).textContent="Loading...",(c=document.createElement("button")).classList.add("ais-SearchBox-reset"),c.innerHTML='<svg class="ais-SearchBox-resetIcon" viewBox="0 0 20 20" width="10" height="10" aria-hidden="true"><path d="M8.114 10L.944 2.83 0 1.885 1.886 0l.943.943L10 8.113l7.17-7.17.944-.943L20 1.886l-.943.943-7.17 7.17 7.17 7.17.943.944L18.114 20l-.943-.943-7.17-7.17-7.17 7.17-.944.943L0 18.114l.943-.943L8.113 10z"></path></svg>',e.addEventListener("keydown",e=>{switch(e.keyCode){case 40:e.preventDefault(),null===i?d(0):d(i+1);break;case 38:e.preventDefault(),null===i&&d(0),d(Math.max(i-1,0));break;case 13:e.preventDefault(),null!==i&&(t=i,(n=document.querySelectorAll("#hits>ul>li>a"))[t])&&(n[t].click(),MicroModal.close("modal-1"));break;case 9:e.preventDefault()}var t,n}),e.addEventListener("input",e=>{r(e.target.value)}),c.addEventListener("click",()=>{MicroModal.close("modal-1")}),l.container.appendChild(e),l.container.appendChild(t),l.container.appendChild(c)),l.container.querySelector("input").value=n,l.container.querySelector("span").hidden=!a});a.addWidgets([instantsearch.widgets.configure({facetFilters:["generation:"+o.pageGeneration,"component:"+o.pageComponent],attributesToSnippet:["content"],attributesToHighlight:["hierarchy"],distinct:!0}),r({container:document.querySelector("#searchbox")}),n({container:document.querySelector("#hits")})]);const l=()=>{e||(a.start(),e=!0),d(null),MicroModal.show("modal-1",{disableScroll:!0})},u=(document.querySelectorAll(".search-button").forEach(e=>{e.addEventListener("click",()=>{l()})}),r=t()?"cmd":"ctrl",t()?"⌘":"CTRL");document.querySelectorAll(".search-key").forEach(e=>{e.innerHTML=u+" + k"}),hotkeys(r+"+k",function(e,t){e.preventDefault(),l()})}}();