-
Notifications
You must be signed in to change notification settings - Fork 0
/
1.99d7e4e4.js
2 lines (2 loc) · 87.2 KB
/
1.99d7e4e4.js
1
2
/*! For license information please see 1.99d7e4e4.js.LICENSE.txt */
(window.webpackJsonp=window.webpackJsonp||[]).push([[1],{200:function(e,t,n){"use strict";function r(e){var t,n,i="";if("string"==typeof e||"number"==typeof e)i+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=r(e[t]))&&(i&&(i+=" "),i+=n);else for(t in e)e[t]&&(i&&(i+=" "),i+=t);return i}t.a=function(){for(var e,t,n=0,i="";n<arguments.length;)(e=arguments[n++])&&(t=r(e))&&(i&&(i+=" "),i+=t);return i}},201:function(e,t,n){"use strict";function r(e){return!0===/^(\w*:|\/\/)/.test(e)}function i(e){return void 0!==e&&!r(e)}n.d(t,"b",(function(){return r})),n.d(t,"a",(function(){return i}))},202:function(e,t,n){"use strict";var r=n(0),i=n.n(r),a=n(11),o=n(201),s=n(12);const c=Object(r.createContext)({collectLink:()=>{}});var u=n(203),l=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n};t.a=function(e){var t,{isNavLink:n,to:d,href:h,activeClassName:f,isActive:p,"data-noBrokenLinkCheck":m}=e,v=l(e,["isNavLink","to","href","activeClassName","isActive","data-noBrokenLinkCheck"]);const{withBaseUrl:g}=Object(u.b)(),y=Object(r.useContext)(c),b=d||h,E=Object(o.a)(b),x=null==b?void 0:b.replace("pathname://",""),k=void 0!==x?(e=>e.startsWith("/"))(w=x)?g(w):w:void 0;var w;const O=Object(r.useRef)(!1),S=n?a.e:a.c,j=s.a.canUseIntersectionObserver;let P;Object(r.useEffect)((()=>(!j&&E&&window.docusaurus.prefetch(k),()=>{j&&P&&P.disconnect()})),[k,j,E]);const _=null!==(t=null==k?void 0:k.startsWith("#"))&&void 0!==t&&t,N=!k||!E||_;return k&&E&&!_&&!m&&y.collectLink(k),N?i.a.createElement("a",Object.assign({href:k},b&&!E&&{target:"_blank",rel:"noopener noreferrer"},v)):i.a.createElement(S,Object.assign({},v,{onMouseEnter:()=>{O.current||(window.docusaurus.preload(k),O.current=!0)},innerRef:e=>{var t,n;j&&e&&E&&(t=e,n=()=>{window.docusaurus.prefetch(k)},P=new window.IntersectionObserver((e=>{e.forEach((e=>{t===e.target&&(e.isIntersecting||e.intersectionRatio>0)&&(P.unobserve(t),P.disconnect(),n())}))})),P.observe(t))},to:k||""},n&&{isActive:p,activeClassName:f}))}},203:function(e,t,n){"use strict";n.d(t,"b",(function(){return a})),n.d(t,"a",(function(){return o}));var r=n(24),i=n(201);function a(){const{siteConfig:{baseUrl:e="/",url:t}={}}=Object(r.default)();return{withBaseUrl:(n,r)=>function(e,t,n,{forcePrependBaseUrl:r=!1,absolute:a=!1}={}){if(!n)return n;if(n.startsWith("#"))return n;if(Object(i.b)(n))return n;if(r)return t+n;const o=n.startsWith(t)?n:t+n.replace(/^\//,"");return a?e+o:o}(t,e,n,r)}}function o(e,t={}){const{withBaseUrl:n}=a();return n(e,t)}},204:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(214);Object.defineProperty(t,"useThemeConfig",{enumerable:!0,get:function(){return r.useThemeConfig}});var i=n(220);Object.defineProperty(t,"docVersionSearchTag",{enumerable:!0,get:function(){return i.docVersionSearchTag}}),Object.defineProperty(t,"DEFAULT_SEARCH_TAG",{enumerable:!0,get:function(){return i.DEFAULT_SEARCH_TAG}});var a=n(215);Object.defineProperty(t,"isDocsPluginEnabled",{enumerable:!0,get:function(){return a.isDocsPluginEnabled}});var o=n(224);Object.defineProperty(t,"isSamePath",{enumerable:!0,get:function(){return o.isSamePath}});var s=n(225);Object.defineProperty(t,"useDocsPreferredVersion",{enumerable:!0,get:function(){return s.useDocsPreferredVersion}}),Object.defineProperty(t,"useDocsPreferredVersionByPluginId",{enumerable:!0,get:function(){return s.useDocsPreferredVersionByPluginId}});var c=n(216);Object.defineProperty(t,"DocsPreferredVersionContextProvider",{enumerable:!0,get:function(){return c.DocsPreferredVersionContextProvider}})},205:function(e,t,n){try{e.exports=n(221)}catch(r){e.exports={}}},206:function(e,t,n){"use strict";var r=n(0),i=n(207);t.a=function(){const e=Object(r.useContext)(i.a);if(null==e)throw new Error("`useUserPreferencesContext` is used outside of `Layout` Component.");return e}},207:function(e,t,n){"use strict";var r=n(0);const i=Object(r.createContext)(void 0);t.a=i},208:function(e,t,n){"use strict";n.r(t);var r=n(11);n.d(t,"MemoryRouter",(function(){return r.d})),n.d(t,"Prompt",(function(){return r.f})),n.d(t,"Redirect",(function(){return r.g})),n.d(t,"Route",(function(){return r.h})),n.d(t,"Router",(function(){return r.i})),n.d(t,"StaticRouter",(function(){return r.j})),n.d(t,"Switch",(function(){return r.k})),n.d(t,"generatePath",(function(){return r.l})),n.d(t,"matchPath",(function(){return r.m})),n.d(t,"useHistory",(function(){return r.n})),n.d(t,"useLocation",(function(){return r.o})),n.d(t,"useParams",(function(){return r.p})),n.d(t,"useRouteMatch",(function(){return r.q})),n.d(t,"withRouter",(function(){return r.r})),n.d(t,"BrowserRouter",(function(){return r.a})),n.d(t,"HashRouter",(function(){return r.b})),n.d(t,"Link",(function(){return r.c})),n.d(t,"NavLink",(function(){return r.e}))},210:function(e,t,n){"use strict";var r=n(0),i=n.n(r),a=n(200),o=n(64),s=n.n(o);var c=function(){return i.a.createElement("nav",{"aria-label":"Skip navigation links"},i.a.createElement("button",{type:"button",tabIndex:0,className:s.a.skipToContent,onKeyDown:e=>{if(13!==e.keyCode)return;document.activeElement.blur();const t=document.querySelector("main:first-of-type");t&&t.scrollIntoView()}},"Skip to main content"))},u=n(204),l=n(206),d=n(65),h=n.n(d);var f=function(){const{isAnnouncementBarClosed:e,closeAnnouncementBar:t}=Object(l.a)(),{announcementBar:n}=Object(u.useThemeConfig)();if(!n)return null;const{content:r,backgroundColor:o,textColor:s,isCloseable:c}=n;return!r||c&&e?null:i.a.createElement("div",{className:h.a.announcementBar,style:{backgroundColor:o,color:s},role:"banner"},i.a.createElement("div",{className:Object(a.a)(h.a.announcementBarContent,{[h.a.announcementBarCloseable]:c}),dangerouslySetInnerHTML:{__html:r}}),c?i.a.createElement("button",{type:"button",className:h.a.announcementBarClose,onClick:t,"aria-label":"Close"},i.a.createElement("span",{"aria-hidden":"true"},"\xd7")):null)},p=n(3),m=n(246),v=m,g=n(247),y=n.n(g),b=n(24),E=n(208),x=n(205);n(66),n(67);function k(e){return fetch(`${e}search-index.json`).then((e=>e.json())).then((e=>({documents:e.documents,index:v.Index.load(e.index)})))}async function w(){const e=await Promise.all([n.e(120),n.e(127)]).then(n.t.bind(null,732,7));return e.noConflict(),e.default}var O=e=>{const{isSearchBarExpanded:t,handleSearchBarToggle:n}=e,o=Object(r.useRef)("empty"),s=Object(r.useRef)(null),c=Object(r.useRef)(!1),{siteConfig:{baseUrl:u}}=Object(b.default)(),l=Object(E.useHistory)(),d=Object(E.useLocation)(),h=Object(x.useVersions)(),f=Object(x.useActiveVersion)(),p=Object(x.useLatestVersion)(),m=h.length<=1?void 0:null!=f?f:p;Object(r.useEffect)((()=>{const e=function(e,t){let n=e.search;0===n.indexOf("?")&&(n=n.slice(1));const r=`${t}=`;for(const i of n.split("&"))if(i.startsWith(r))return i.substr(r.length);return null}(d,"highlight");if(!e)return;let t;if(t=function(e){return window.location.pathname.startsWith(`${e}docs`)||window.location.pathname.startsWith(`${e}blog`)}(u)?document.getElementsByTagName("article")[0]:document.getElementsByTagName("main")[0],!t)return;const n=function(e){const t=[];let n="";for(let r=0;r<e.length;r++){const i=e[r],a=r<e.length-1?e[r+1]:"",o=r>0?e[r-1]:"";"~"===i&&"~"!==a&&"~"!==o?(t.push(n),n=""):n+=i}return t.push(n),t}(e).filter((e=>e.length>0)).map((e=>e.replace(/~~/g,"~")));if(0===n.length)return;const r=new y.a(t),i={ignoreJoiners:!0};return r.mark(n,i),()=>r.unmark(i)}),[d,u]);const g=async()=>{if("empty"!==o.current)return;o.current="loading";const[{index:e,documents:t},n]=await Promise.all([k(u),w()]);n(s.current,{hint:!1,autoselect:!0,cssClasses:{root:"d-s-l-a"}},[{source:(n,r)=>{const i=function(e){return e.split(" ").map((function(e){return e.trim().toLowerCase()})).filter((function(e){return e.length>0}))}(n);r(e.query((e=>{e.term(i,{fields:["title"],boost:5}),e.term(i,{fields:["title"],boost:5,wildcard:v.Query.wildcard.TRAILING}),e.term(i,{fields:["content"],boost:1}),e.term(i,{fields:["content"],boost:1,wildcard:v.Query.wildcard.TRAILING}),m&&e.term(m.name,{fields:["version"],boost:0,presence:v.Query.presence.REQUIRED})})).filter((e=>e.score>0)).slice(0,8).map((e=>({document:t.find((t=>t.id.toString()===e.ref)),score:e.score,terms:i}))))},templates:{suggestion:function({document:e,score:t}){const r=n.escapeHighlightedString;let i=`<span class="aa-suggestion-page">${r(e.pageTitle)}</span>`;return e.pageTitle!==e.sectionTitle&&(i+=`<span class="aa-suggestion-section">${r(e.sectionTitle)}</span>`),i},empty:()=>'<span class="aa-suggestion-empty"></span>'}}]).on("autocomplete:selected",(function(e,{document:t,terms:n},r,i){const[a,o]=t.sectionRoute.split("#");let s=a;s+="?highlight="+encodeURIComponent(n.map((e=>e.replace(/~/g,"~~"))).join("~")),o&&(s+="#"+o),l.push(s)})),c.current&&s.current.focus(),o.current="done"},O=async()=>{await g(),s.current.focus(),n(!t)};let S="Search";return m&&(S+=` [${m.label}]`),i.a.createElement("div",{className:"navbar__search",key:"search-box"},i.a.createElement("span",{"aria-label":"expand searchbar",role:"button",className:Object(a.a)("search-icon",{"search-icon-hidden":t}),onClick:O,onKeyDown:O,tabIndex:0}),i.a.createElement("input",{id:"search_input_react",type:"search",placeholder:S,"aria-label":"Search",className:Object(a.a)("navbar__search-input",{"search-bar-expanded":t},{"search-bar":!t}),onMouseOver:()=>{g()},onFocus:()=>{c.current=!0,g()},onBlur:()=>{n(!t)},ref:s}))},S=n(248),j=n.n(S),P=n(68),_=n.n(P);const N=({icon:e,style:t})=>i.a.createElement("span",{className:Object(a.a)(_.a.toggle,_.a.dark),style:t},e),C=({icon:e,style:t})=>i.a.createElement("span",{className:Object(a.a)(_.a.toggle,_.a.light),style:t},e);var T=function(e){const{colorMode:{switchConfig:{darkIcon:t,darkIconStyle:n,lightIcon:r,lightIconStyle:a}}}=Object(u.useThemeConfig)(),{isClient:o}=Object(b.default)();return i.a.createElement(j.a,Object(p.a)({disabled:!o,icons:{checked:i.a.createElement(N,{icon:t,style:n}),unchecked:i.a.createElement(C,{icon:r,style:a})}},e))},I=n(218),L=n(237);var D=e=>{const t=Object(E.useLocation)(),[n,i]=Object(r.useState)(!e),a=Object(r.useRef)(!1),[o,s]=Object(r.useState)(0),[c,u]=Object(r.useState)(0),l=Object(r.useCallback)((e=>{null!==e&&u(e.getBoundingClientRect().height)}),[]);return Object(L.a)((({scrollY:t})=>{if(!e)return;if(t<c)return;if(a.current)return a.current=!1,i(!1),void s(t);o&&0===t&&i(!0);const n=document.documentElement.scrollHeight-c,r=window.innerHeight;o&&t>=o?i(!1):t+r<n&&i(!0),s(t)}),[o,c,a]),Object(r.useEffect)((()=>{e&&o&&i(!0)}),[t.pathname]),Object(r.useEffect)((()=>{e&&(a.current=!0)}),[t.hash]),{navbarRef:l,isNavbarVisible:n}},R=n(238),Q=n(239),A=n(219);const V={default:()=>A.a,docsVersion:()=>n(253).default,docsVersionDropdown:()=>n(254).default,doc:()=>n(255).default};function F({type:e,...t}){const n=((e="default")=>{const t=V[e];if(!t)throw new Error(`No NavbarItem component found for type=${e}.`);return t()})(e);return i.a.createElement(n,t)}var M=n(245),B=n(70),$=n.n(B);const W="right";var z=function(){const{navbar:{items:e,hideOnScroll:t,style:n},colorMode:{disableSwitch:o}}=Object(u.useThemeConfig)(),[s,c]=Object(r.useState)(!1),[l,d]=Object(r.useState)(!1),{isDarkTheme:h,setLightTheme:f,setDarkTheme:m}=Object(I.a)(),{navbarRef:v,isNavbarVisible:g}=D(t);Object(R.a)(s);const y=Object(r.useCallback)((()=>{c(!0)}),[c]),b=Object(r.useCallback)((()=>{c(!1)}),[c]),E=Object(r.useCallback)((e=>e.target.checked?m():f()),[f,m]),x=Object(Q.a)();Object(r.useEffect)((()=>{x===Q.b.desktop&&c(!1)}),[x]);const{leftItems:k,rightItems:w}=function(e){return{leftItems:e.filter((e=>{var t;return"left"===(null!==(t=e.position)&&void 0!==t?t:W)})),rightItems:e.filter((e=>{var t;return"right"===(null!==(t=e.position)&&void 0!==t?t:W)}))}}(e);return i.a.createElement("nav",{ref:v,className:Object(a.a)("navbar","navbar--fixed-top",{"navbar--dark":"dark"===n,"navbar--primary":"primary"===n,"navbar-sidebar--show":s,[$.a.navbarHideable]:t,[$.a.navbarHidden]:!g})},i.a.createElement("div",{className:"navbar__inner"},i.a.createElement("div",{className:"navbar__items"},null!=e&&0!==e.length&&i.a.createElement("div",{"aria-label":"Navigation bar toggle",className:"navbar__toggle",role:"button",tabIndex:0,onClick:y,onKeyDown:y},i.a.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"30",height:"30",viewBox:"0 0 30 30",role:"img",focusable:"false"},i.a.createElement("title",null,"Menu"),i.a.createElement("path",{stroke:"currentColor",strokeLinecap:"round",strokeMiterlimit:"10",strokeWidth:"2",d:"M4 7h22M4 15h22M4 23h22"}))),i.a.createElement(M.a,{className:"navbar__brand",imageClassName:"navbar__logo",titleClassName:Object(a.a)("navbar__title",{[$.a.hideLogoText]:l})}),k.map(((e,t)=>i.a.createElement(F,Object(p.a)({},e,{key:t}))))),i.a.createElement("div",{className:"navbar__items navbar__items--right"},w.map(((e,t)=>i.a.createElement(F,Object(p.a)({},e,{key:t})))),!o&&i.a.createElement(T,{className:$.a.displayOnlyInLargeViewport,"aria-label":"Dark mode toggle",checked:h,onChange:E}),i.a.createElement(O,{handleSearchBarToggle:d,isSearchBarExpanded:l}))),i.a.createElement("div",{role:"presentation",className:"navbar-sidebar__backdrop",onClick:b}),i.a.createElement("div",{className:"navbar-sidebar"},i.a.createElement("div",{className:"navbar-sidebar__brand"},i.a.createElement(M.a,{className:"navbar__brand",imageClassName:"navbar__logo",titleClassName:"navbar__title",onClick:b}),!o&&s&&i.a.createElement(T,{"aria-label":"Dark mode toggle in sidebar",checked:h,onChange:E})),i.a.createElement("div",{className:"navbar-sidebar__items"},i.a.createElement("div",{className:"menu"},i.a.createElement("ul",{className:"menu__list"},e.map(((e,t)=>i.a.createElement(F,Object(p.a)({mobile:!0},e,{onClick:b,key:t})))))))))},U=n(202),H=n(203),J=n(71),q=n.n(J);function G({to:e,href:t,label:n,prependBaseUrlToHref:r,...a}){const o=Object(H.a)(e),s=Object(H.a)(t,{forcePrependBaseUrl:!0});return i.a.createElement(U.a,Object(p.a)({className:"footer__link-item"},t?{target:"_blank",rel:"noopener noreferrer",href:r?s:t}:{to:o},a),n)}const X=({url:e,alt:t})=>i.a.createElement("img",{className:"footer__logo",alt:t,src:e});var K=function(){const{footer:e}=Object(u.useThemeConfig)(),{copyright:t,links:n=[],logo:r={}}=e||{},o=Object(H.a)(r.src);return e?i.a.createElement("footer",{className:Object(a.a)("footer",{"footer--dark":"dark"===e.style})},i.a.createElement("div",{className:"container"},n&&n.length>0&&i.a.createElement("div",{className:"row footer__links"},n.map(((e,t)=>i.a.createElement("div",{key:t,className:"col footer__col"},null!=e.title?i.a.createElement("h4",{className:"footer__title"},e.title):null,null!=e.items&&Array.isArray(e.items)&&e.items.length>0?i.a.createElement("ul",{className:"footer__items"},e.items.map(((e,t)=>e.html?i.a.createElement("li",{key:t,className:"footer__item",dangerouslySetInnerHTML:{__html:e.html}}):i.a.createElement("li",{key:e.href||e.to,className:"footer__item"},i.a.createElement(G,e))))):null)))),(r||t)&&i.a.createElement("div",{className:"text--center"},r&&r.src&&i.a.createElement("div",{className:"margin-bottom--sm"},r.href?i.a.createElement("a",{href:r.href,target:"_blank",rel:"noopener noreferrer",className:q.a.footerLogoLink},i.a.createElement(X,{alt:r.alt,url:o})):i.a.createElement(X,{alt:r.alt,url:o})),i.a.createElement("div",{dangerouslySetInnerHTML:{__html:t}})))):null},Y=n(12);const Z="light",ee="dark",te=e=>e===ee?ee:Z,ne=()=>Y.a.canUseDOM?te(document.documentElement.getAttribute("data-theme")):Z,re=e=>{try{localStorage.setItem("theme",te(e))}catch(t){console.error(t)}};var ie=()=>{const{colorMode:{disableSwitch:e=!1}}=Object(u.useThemeConfig)(),[t,n]=Object(r.useState)(ne),i=Object(r.useCallback)((()=>{n(Z),re(Z)}),[]),a=Object(r.useCallback)((()=>{n(ee),re(ee)}),[]);return Object(r.useEffect)((()=>{document.documentElement.setAttribute("data-theme",te(t))}),[t]),Object(r.useEffect)((()=>{if(!e)try{const e=localStorage.getItem("theme");null!==e&&n(te(e))}catch(t){console.error(t)}}),[n]),Object(r.useEffect)((()=>{e||window.matchMedia("(prefers-color-scheme: dark)").addListener((({matches:e})=>{n(e?ee:Z)}))}),[]),{isDarkTheme:t===ee,setLightTheme:i,setDarkTheme:a}},ae=n(236);var oe=function(e){const{isDarkTheme:t,setLightTheme:n,setDarkTheme:r}=ie();return i.a.createElement(ae.a.Provider,{value:{isDarkTheme:t,setLightTheme:n,setDarkTheme:r}},e.children)};const se="docusaurus.tab.";var ce=()=>{const[e,t]=Object(r.useState)({}),n=Object(r.useCallback)(((e,t)=>{try{localStorage.setItem(`docusaurus.tab.${e}`,t)}catch(n){console.error(n)}}),[]);return Object(r.useEffect)((()=>{try{const e={};for(let t=0;t<localStorage.length;t+=1){const n=localStorage.key(t);if(n.startsWith(se)){e[n.substring(se.length)]=localStorage.getItem(n)}}t(e)}catch(e){console.error(e)}}),[]),{tabGroupChoices:e,setTabGroupChoices:(e,r)=>{t((t=>({...t,[e]:r}))),n(e,r)}}};const ue="docusaurus.announcement.dismiss",le="docusaurus.announcement.id";var de=()=>{const{announcementBar:e}=Object(u.useThemeConfig)(),[t,n]=Object(r.useState)(!0),i=Object(r.useCallback)((()=>{localStorage.setItem(ue,"true"),n(!0)}),[]);return Object(r.useEffect)((()=>{if(!e)return;const{id:t}=e;let r=localStorage.getItem(le);"annoucement-bar"===r&&(r="announcement-bar");const i=t!==r;localStorage.setItem(le,t),i&&localStorage.setItem(ue,"false"),(i||"false"===localStorage.getItem(ue))&&n(!1)}),[]),{isAnnouncementBarClosed:t,closeAnnouncementBar:i}},he=n(207);var fe=function(e){const{tabGroupChoices:t,setTabGroupChoices:n}=ce(),{isAnnouncementBarClosed:r,closeAnnouncementBar:a}=de();return i.a.createElement(he.a.Provider,{value:{tabGroupChoices:t,setTabGroupChoices:n,isAnnouncementBarClosed:r,closeAnnouncementBar:a}},e.children)};function pe({children:e}){return i.a.createElement(oe,null,i.a.createElement(fe,null,i.a.createElement(u.DocsPreferredVersionContextProvider,null,e)))}var me=n(27);function ve({language:e,version:t,tag:n}){return i.a.createElement(me.a,null,e&&i.a.createElement("meta",{name:"docusaurus_language",content:`${e}`}),t&&i.a.createElement("meta",{name:"docusaurus_version",content:t}),n&&i.a.createElement("meta",{name:"docusaurus_tag",content:n}))}function ge(e){const{siteConfig:t}=Object(b.default)(),{favicon:n,title:r,themeConfig:{image:a,metadatas:o},url:s,titleDelimiter:c}=t,{title:l,description:d,image:h,keywords:f,permalink:m,searchMetadatas:v}=e,g=l?`${l} ${c} ${r}`:r,y=h||a,E=Object(H.a)(y,{absolute:!0}),x=Object(H.a)(n);return i.a.createElement(i.a.Fragment,null,i.a.createElement(me.a,null,i.a.createElement("html",{lang:"en"}),g&&i.a.createElement("title",null,g),g&&i.a.createElement("meta",{property:"og:title",content:g}),n&&i.a.createElement("link",{rel:"shortcut icon",href:x}),d&&i.a.createElement("meta",{name:"description",content:d}),d&&i.a.createElement("meta",{property:"og:description",content:d}),f&&f.length&&i.a.createElement("meta",{name:"keywords",content:f.join(",")}),y&&i.a.createElement("meta",{property:"og:image",content:E}),y&&i.a.createElement("meta",{property:"twitter:image",content:E}),y&&i.a.createElement("meta",{name:"twitter:image:alt",content:`Image for ${g}`}),m&&i.a.createElement("meta",{property:"og:url",content:s+m}),m&&i.a.createElement("link",{rel:"canonical",href:s+m}),i.a.createElement("meta",{name:"twitter:card",content:"summary_large_image"})),i.a.createElement(ve,Object(p.a)({tag:u.DEFAULT_SEARCH_TAG,language:"en"},v)),i.a.createElement(me.a,null,o.map(((e,t)=>i.a.createElement("meta",Object(p.a)({key:`metadata_${t}`},e))))))}n(72);var ye=function(){Object(r.useEffect)((()=>{const e="navigation-with-keyboard";function t(t){"keydown"===t.type&&"Tab"===t.key&&document.body.classList.add(e),"mousedown"===t.type&&document.body.classList.remove(e)}return document.addEventListener("keydown",t),document.addEventListener("mousedown",t),()=>{document.body.classList.remove(e),document.removeEventListener("keydown",t),document.removeEventListener("mousedown",t)}}),[])};n(73);t.a=function(e){const{children:t,noFooter:n,wrapperClassName:r}=e;return ye(),i.a.createElement(pe,null,i.a.createElement(ge,e),i.a.createElement(c,null),i.a.createElement(f,null),i.a.createElement(z,null),i.a.createElement("div",{className:Object(a.a)("main-wrapper",r)},t),!n&&i.a.createElement(K,null))}},214:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.useThemeConfig=void 0;const i=r(n(24));t.useThemeConfig=function(){return i.default().siteConfig.themeConfig}},215:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isDocsPluginEnabled=void 0;const r=n(205);t.isDocsPluginEnabled=!!r.useAllDocsData},216:function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),a=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.hasOwnProperty.call(e,n)&&r(t,e,n);return i(t,e),t},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.useDocsPreferredVersionContext=t.DocsPreferredVersionContextProvider=void 0;const s=a(n(0)),c=n(214),u=n(215),l=n(205),d=o(n(226));function h({pluginIds:e,versionPersistence:t,allDocsData:n}){const r={};return e.forEach((e=>{r[e]=function(e){const r=d.default.read(e,t);return n[e].versions.some((e=>e.name===r))?{preferredVersionName:r}:(d.default.clear(e,t),{preferredVersionName:null})}(e)})),r}function f(){const e=l.useAllDocsData(),t=c.useThemeConfig().docs.versionPersistence,n=s.useMemo((()=>Object.keys(e)),[e]),[r,i]=s.useState((()=>function(e){const t={};return e.forEach((e=>{t[e]={preferredVersionName:null}})),t}(n)));s.useEffect((()=>{i(h({allDocsData:e,versionPersistence:t,pluginIds:n}))}),[e,t,n]);return[r,s.useMemo((()=>({savePreferredVersion:function(e,n){d.default.save(e,t,n),i((t=>Object.assign(Object.assign({},t),{[e]:{preferredVersionName:n}})))}})),[i])]}const p=s.createContext(null);function m({children:e}){const t=f();return s.default.createElement(p.Provider,{value:t},e)}t.DocsPreferredVersionContextProvider=function({children:e}){return u.isDocsPluginEnabled?s.default.createElement(m,null,e):s.default.createElement(s.default.Fragment,null,e)},t.useDocsPreferredVersionContext=function(){const e=s.useContext(p);if(!e)throw new Error("Can't find docs preferred context, maybe you forgot to use the DocsPreferredVersionContextProvider ?");return e}},218:function(e,t,n){"use strict";var r=n(0),i=n(236);t.a=function(){const e=Object(r.useContext)(i.a);if(null==e)throw new Error("`useThemeContext` is used outside of `Layout` Component. See https://v2.docusaurus.io/docs/theme-classic#usethemecontext.");return e}},219:function(e,t,n){"use strict";var r=n(3),i=n(0),a=n.n(i),o=n(200),s=n(202),c=n(203),u=n(208),l=n(204);function d({activeBasePath:e,activeBaseRegex:t,to:n,href:i,label:o,activeClassName:u="navbar__link--active",prependBaseUrlToHref:l,...d}){const h=Object(c.a)(n),f=Object(c.a)(e),p=Object(c.a)(i,{forcePrependBaseUrl:!0});return a.a.createElement(s.a,Object(r.a)({},i?{target:"_blank",rel:"noopener noreferrer",href:l?p:i}:{isNavLink:!0,activeClassName:u,to:h,...e||t?{isActive:(e,n)=>t?new RegExp(t).test(n.pathname):n.pathname.startsWith(f)}:null},d),o)}function h({items:e,position:t,className:n,...s}){const c=Object(i.useRef)(null),u=Object(i.useRef)(null),[l,h]=Object(i.useState)(!1);Object(i.useEffect)((()=>{const e=e=>{c.current&&!c.current.contains(e.target)&&h(!1)};return document.addEventListener("mousedown",e),document.addEventListener("touchstart",e),()=>{document.removeEventListener("mousedown",e),document.removeEventListener("touchstart",e)}}),[c]);const f=(e,t=!1)=>Object(o.a)({"navbar__item navbar__link":!t,dropdown__link:t},e);return e?a.a.createElement("div",{ref:c,className:Object(o.a)("navbar__item","dropdown","dropdown--hoverable",{"dropdown--left":"left"===t,"dropdown--right":"right"===t,"dropdown--show":l})},a.a.createElement(d,Object(r.a)({className:f(n)},s,{onClick:s.to?void 0:e=>e.preventDefault(),onKeyDown:e=>{"Enter"===e.key&&(e.preventDefault(),h(!l))}}),s.label),a.a.createElement("ul",{ref:u,className:"dropdown__menu"},e.map((({className:t,...n},i)=>a.a.createElement("li",{key:i},a.a.createElement(d,Object(r.a)({onKeyDown:t=>{if(i===e.length-1&&"Tab"===t.key){t.preventDefault(),h(!1);const e=c.current.nextElementSibling;e&&e.focus()}},activeClassName:"dropdown__link--active",className:f(t,!0)},n))))))):a.a.createElement(d,Object(r.a)({className:f(n)},s))}function f({items:e,className:t,position:n,...s}){var c,h;const f=Object(i.useRef)(null),{pathname:p}=Object(u.useLocation)(),[m,v]=Object(i.useState)((()=>{var t;return null===(t=!(null!=e&&e.some((e=>Object(l.isSamePath)(e.to,p)))))||void 0===t||t})),g=(e,t=!1)=>Object(o.a)("menu__link",{"menu__link--sublist":t},e);if(!e)return a.a.createElement("li",{className:"menu__list-item"},a.a.createElement(d,Object(r.a)({className:g(t)},s)));const y=null!==(c=f.current)&&void 0!==c&&c.scrollHeight?`${null===(h=f.current)||void 0===h?void 0:h.scrollHeight}px`:void 0;return a.a.createElement("li",{className:Object(o.a)("menu__list-item",{"menu__list-item--collapsed":m})},a.a.createElement(d,Object(r.a)({role:"button",className:g(t,!0)},s,{onClick:()=>{v((e=>!e))}}),s.label),a.a.createElement("ul",{className:"menu__list",ref:f,style:{height:m?void 0:y}},e.map((({className:e,...t},n)=>a.a.createElement("li",{className:"menu__list-item",key:n},a.a.createElement(d,Object(r.a)({activeClassName:"menu__link--active",className:g(e)},t,{onClick:s.onClick})))))))}t.a=function({mobile:e=!1,...t}){const n=e?f:h;return a.a.createElement(n,t)}},220:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.docVersionSearchTag=t.DEFAULT_SEARCH_TAG=void 0,t.DEFAULT_SEARCH_TAG="default",t.docVersionSearchTag=function(e,t){return`docs-${e}-${t}`}},221:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useDocVersionSuggestions=t.useActiveDocContext=t.useActiveVersion=t.useLatestVersion=t.useVersions=t.useActivePluginAndVersion=t.useActivePlugin=t.useDocsData=t.useAllDocsData=void 0;const r=n(208),i=n(222),a=n(223);t.useAllDocsData=()=>i.useAllPluginInstancesData("docusaurus-plugin-content-docs"),t.useDocsData=e=>i.usePluginData("docusaurus-plugin-content-docs",e),t.useActivePlugin=(e={})=>{const n=t.useAllDocsData(),{pathname:i}=r.useLocation();return a.getActivePlugin(n,i,e)},t.useActivePluginAndVersion=(e={})=>{const n=t.useActivePlugin(e),{pathname:i}=r.useLocation();if(n){return{activePlugin:n,activeVersion:a.getActiveVersion(n.pluginData,i)}}},t.useVersions=e=>t.useDocsData(e).versions,t.useLatestVersion=e=>{const n=t.useDocsData(e);return a.getLatestVersion(n)},t.useActiveVersion=e=>{const n=t.useDocsData(e),{pathname:i}=r.useLocation();return a.getActiveVersion(n,i)},t.useActiveDocContext=e=>{const n=t.useDocsData(e),{pathname:i}=r.useLocation();return a.getActiveDocContext(n,i)},t.useDocVersionSuggestions=e=>{const n=t.useDocsData(e),{pathname:i}=r.useLocation();return a.getDocVersionSuggestions(n,i)}},222:function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return i})),n.d(t,"useAllPluginInstancesData",(function(){return a})),n.d(t,"usePluginData",(function(){return o}));var r=n(24);function i(){const{globalData:e}=Object(r.default)();if(!e)throw new Error("Docusaurus global data not found");return e}function a(e){const t=i()[e];if(!t)throw new Error(`Docusaurus plugin global data not found for pluginName=${e}`);return t}function o(e,t="default"){const n=a(e)[t];if(!n)throw new Error(`Docusaurus plugin global data not found for pluginName=${e} and pluginId=${t}`);return n}},223:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getDocVersionSuggestions=t.getActiveDocContext=t.getActiveVersion=t.getLatestVersion=t.getActivePlugin=void 0;const r=n(208);t.getActivePlugin=function(e,t,n={}){const i=Object.entries(e).find((([e,n])=>!!r.matchPath(t,{path:n.path,exact:!1,strict:!1}))),a=i?{pluginId:i[0],pluginData:i[1]}:void 0;if(!a&&n.failfast)throw new Error(`Can't find active docs plugin for pathname=${t}, while it was expected to be found. Maybe you tried to use a docs feature that can only be used on a docs-related page? Existing docs plugin paths are: ${Object.values(e).map((e=>e.path)).join(", ")}`);return a},t.getLatestVersion=e=>e.versions.find((e=>e.isLast)),t.getActiveVersion=(e,n)=>{const i=t.getLatestVersion(e);return[...e.versions.filter((e=>e!==i)),i].find((e=>!!r.matchPath(n,{path:e.path,exact:!1,strict:!1})))},t.getActiveDocContext=(e,n)=>{const i=t.getActiveVersion(e,n),a=null==i?void 0:i.docs.find((e=>!!r.matchPath(n,{path:e.path,exact:!0,strict:!1})));return{activeVersion:i,activeDoc:a,alternateDocVersions:a?function(t){const n={};return e.versions.forEach((e=>{e.docs.forEach((r=>{r.id===t&&(n[e.name]=r)}))})),n}(a.id):{}}},t.getDocVersionSuggestions=(e,n)=>{const r=t.getLatestVersion(e),i=t.getActiveDocContext(e,n),a=i.activeVersion!==r;return{latestDocSuggestion:a?null==i?void 0:i.alternateDocVersions[r.name]:void 0,latestVersionSuggestion:a?r:void 0}}},224:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isSamePath=void 0,t.isSamePath=(e,t)=>{const n=e=>!e||(null==e?void 0:e.endsWith("/"))?e:`${e}/`;return n(e)===n(t)}},225:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useDocsPreferredVersionByPluginId=t.useDocsPreferredVersion=void 0;const r=n(0),i=n(216),a=n(205),o=n(227);t.useDocsPreferredVersion=function(e=o.DEFAULT_PLUGIN_ID){const t=a.useDocsData(e),[n,s]=i.useDocsPreferredVersionContext(),{preferredVersionName:c}=n[e];return{preferredVersion:c?t.versions.find((e=>e.name===c)):null,savePreferredVersionName:r.useCallback((t=>{s.savePreferredVersion(e,t)}),[s])}},t.useDocsPreferredVersionByPluginId=function(){const e=a.useAllDocsData(),[t]=i.useDocsPreferredVersionContext(),n=Object.keys(e),r={};return n.forEach((n=>{r[n]=function(n){const r=e[n],{preferredVersionName:i}=t[n];return i?r.versions.find((e=>e.name===i)):null}(n)})),r}},226:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=e=>`docs-preferred-version-${e}`,i={save:(e,t,n)=>{"none"===t||window.localStorage.setItem(r(e),n)},read:(e,t)=>"none"===t?null:window.localStorage.getItem(r(e)),clear:(e,t)=>{"none"===t||window.localStorage.removeItem(r(e))}};t.default=i},227:function(e,t,n){"use strict";n.r(t),n.d(t,"DEFAULT_PLUGIN_ID",(function(){return r}));const r="default"},236:function(e,t,n){"use strict";var r=n(0);const i=n.n(r).a.createContext(void 0);t.a=i},237:function(e,t,n){"use strict";var r=n(0),i=n(12);const a=()=>({scrollX:i.a.canUseDOM?window.pageXOffset:0,scrollY:i.a.canUseDOM?window.pageYOffset:0});t.a=(e,t=[])=>{const[n,i]=Object(r.useState)(a()),o=()=>{const t=a();i(t),e&&e(t)};return Object(r.useEffect)((()=>{const e={passive:!0};return window.addEventListener("scroll",o,e),()=>window.removeEventListener("scroll",o,e)}),t),n}},238:function(e,t,n){"use strict";var r=n(0);t.a=function(e=!0){Object(r.useEffect)((()=>(document.body.style.overflow=e?"hidden":"visible",()=>{document.body.style.overflow="visible"})),[e])}},239:function(e,t,n){"use strict";n.d(t,"b",(function(){return i}));var r=n(0);const i={desktop:"desktop",mobile:"mobile"};t.a=function(){const e="undefined"!=typeof window;function t(){if(e)return window.innerWidth>996?i.desktop:i.mobile}const[n,a]=Object(r.useState)(t);return Object(r.useEffect)((()=>{if(e)return window.addEventListener("resize",n),()=>window.removeEventListener("resize",n);function n(){a(t())}}),[]),n}},245:function(e,t,n){"use strict";var r=n(3),i=n(0),a=n.n(i),o=n(202),s=n(200),c=n(24),u=n(218),l=n(69),d=n.n(l);var h=e=>{const{isClient:t}=Object(c.default)(),{isDarkTheme:n}=Object(u.a)(),{sources:i,className:o,alt:l="",...h}=e,f=t?n?["dark"]:["light"]:["light","dark"];return a.a.createElement(a.a.Fragment,null,f.map((e=>a.a.createElement("img",Object(r.a)({key:e,src:i[e],alt:l,className:Object(s.a)(d.a.themedImage,d.a[`themedImage--${e}`],o)},h)))))},f=n(203),p=n(204),m=n(201);t.a=e=>{const{isClient:t}=Object(c.default)(),{navbar:{title:n,logo:i={}}}=Object(p.useThemeConfig)(),{imageClassName:s,titleClassName:u,...l}=e,d=Object(f.a)(i.href||"/"),v=i.target?{target:i.target}:Object(m.a)(d)?{}:{rel:"noopener noreferrer",target:"_blank"},g={light:Object(f.a)(i.src),dark:Object(f.a)(i.srcDark||i.src)};return a.a.createElement(o.a,Object(r.a)({to:d},l,v),i.src&&a.a.createElement(h,{key:t,className:s,sources:g,alt:i.alt||n||"Logo"}),null!=n&&a.a.createElement("strong",{className:u},n))}},246:function(e,t,n){var r,i;!function(){var a,o,s,c,u,l,d,h,f,p,m,v,g,y,b,E,x,k,w,O,S,j,P,_,N,C,T=function(e){var t=new T.Builder;return t.pipeline.add(T.trimmer,T.stopWordFilter,T.stemmer),t.searchPipeline.add(T.stemmer),e.call(t,t),t.build()};T.version="2.3.9",T.utils={},T.utils.warn=(a=this,function(e){a.console&&console.warn&&console.warn(e)}),T.utils.asString=function(e){return null==e?"":e.toString()},T.utils.clone=function(e){if(null==e)return e;for(var t=Object.create(null),n=Object.keys(e),r=0;r<n.length;r++){var i=n[r],a=e[i];if(Array.isArray(a))t[i]=a.slice();else{if("string"!=typeof a&&"number"!=typeof a&&"boolean"!=typeof a)throw new TypeError("clone is not deep and does not support nested objects");t[i]=a}}return t},T.FieldRef=function(e,t,n){this.docRef=e,this.fieldName=t,this._stringValue=n},T.FieldRef.joiner="/",T.FieldRef.fromString=function(e){var t=e.indexOf(T.FieldRef.joiner);if(-1===t)throw"malformed field ref string";var n=e.slice(0,t),r=e.slice(t+1);return new T.FieldRef(r,n,e)},T.FieldRef.prototype.toString=function(){return null==this._stringValue&&(this._stringValue=this.fieldName+T.FieldRef.joiner+this.docRef),this._stringValue},T.Set=function(e){if(this.elements=Object.create(null),e){this.length=e.length;for(var t=0;t<this.length;t++)this.elements[e[t]]=!0}else this.length=0},T.Set.complete={intersect:function(e){return e},union:function(){return this},contains:function(){return!0}},T.Set.empty={intersect:function(){return this},union:function(e){return e},contains:function(){return!1}},T.Set.prototype.contains=function(e){return!!this.elements[e]},T.Set.prototype.intersect=function(e){var t,n,r,i=[];if(e===T.Set.complete)return this;if(e===T.Set.empty)return e;this.length<e.length?(t=this,n=e):(t=e,n=this),r=Object.keys(t.elements);for(var a=0;a<r.length;a++){var o=r[a];o in n.elements&&i.push(o)}return new T.Set(i)},T.Set.prototype.union=function(e){return e===T.Set.complete?T.Set.complete:e===T.Set.empty?this:new T.Set(Object.keys(this.elements).concat(Object.keys(e.elements)))},T.idf=function(e,t){var n=0;for(var r in e)"_index"!=r&&(n+=Object.keys(e[r]).length);var i=(t-n+.5)/(n+.5);return Math.log(1+Math.abs(i))},T.Token=function(e,t){this.str=e||"",this.metadata=t||{}},T.Token.prototype.toString=function(){return this.str},T.Token.prototype.update=function(e){return this.str=e(this.str,this.metadata),this},T.Token.prototype.clone=function(e){return e=e||function(e){return e},new T.Token(e(this.str,this.metadata),this.metadata)},T.tokenizer=function(e,t){if(null==e||null==e)return[];if(Array.isArray(e))return e.map((function(e){return new T.Token(T.utils.asString(e).toLowerCase(),T.utils.clone(t))}));for(var n=e.toString().toLowerCase(),r=n.length,i=[],a=0,o=0;a<=r;a++){var s=a-o;if(n.charAt(a).match(T.tokenizer.separator)||a==r){if(s>0){var c=T.utils.clone(t)||{};c.position=[o,s],c.index=i.length,i.push(new T.Token(n.slice(o,a),c))}o=a+1}}return i},T.tokenizer.separator=/[\s\-]+/,T.Pipeline=function(){this._stack=[]},T.Pipeline.registeredFunctions=Object.create(null),T.Pipeline.registerFunction=function(e,t){t in this.registeredFunctions&&T.utils.warn("Overwriting existing registered function: "+t),e.label=t,T.Pipeline.registeredFunctions[e.label]=e},T.Pipeline.warnIfFunctionNotRegistered=function(e){e.label&&e.label in this.registeredFunctions||T.utils.warn("Function is not registered with pipeline. This may cause problems when serialising the index.\n",e)},T.Pipeline.load=function(e){var t=new T.Pipeline;return e.forEach((function(e){var n=T.Pipeline.registeredFunctions[e];if(!n)throw new Error("Cannot load unregistered function: "+e);t.add(n)})),t},T.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach((function(e){T.Pipeline.warnIfFunctionNotRegistered(e),this._stack.push(e)}),this)},T.Pipeline.prototype.after=function(e,t){T.Pipeline.warnIfFunctionNotRegistered(t);var n=this._stack.indexOf(e);if(-1==n)throw new Error("Cannot find existingFn");n+=1,this._stack.splice(n,0,t)},T.Pipeline.prototype.before=function(e,t){T.Pipeline.warnIfFunctionNotRegistered(t);var n=this._stack.indexOf(e);if(-1==n)throw new Error("Cannot find existingFn");this._stack.splice(n,0,t)},T.Pipeline.prototype.remove=function(e){var t=this._stack.indexOf(e);-1!=t&&this._stack.splice(t,1)},T.Pipeline.prototype.run=function(e){for(var t=this._stack.length,n=0;n<t;n++){for(var r=this._stack[n],i=[],a=0;a<e.length;a++){var o=r(e[a],a,e);if(null!=o&&""!==o)if(Array.isArray(o))for(var s=0;s<o.length;s++)i.push(o[s]);else i.push(o)}e=i}return e},T.Pipeline.prototype.runString=function(e,t){var n=new T.Token(e,t);return this.run([n]).map((function(e){return e.toString()}))},T.Pipeline.prototype.reset=function(){this._stack=[]},T.Pipeline.prototype.toJSON=function(){return this._stack.map((function(e){return T.Pipeline.warnIfFunctionNotRegistered(e),e.label}))},T.Vector=function(e){this._magnitude=0,this.elements=e||[]},T.Vector.prototype.positionForIndex=function(e){if(0==this.elements.length)return 0;for(var t=0,n=this.elements.length/2,r=n-t,i=Math.floor(r/2),a=this.elements[2*i];r>1&&(a<e&&(t=i),a>e&&(n=i),a!=e);)r=n-t,i=t+Math.floor(r/2),a=this.elements[2*i];return a==e||a>e?2*i:a<e?2*(i+1):void 0},T.Vector.prototype.insert=function(e,t){this.upsert(e,t,(function(){throw"duplicate index"}))},T.Vector.prototype.upsert=function(e,t,n){this._magnitude=0;var r=this.positionForIndex(e);this.elements[r]==e?this.elements[r+1]=n(this.elements[r+1],t):this.elements.splice(r,0,e,t)},T.Vector.prototype.magnitude=function(){if(this._magnitude)return this._magnitude;for(var e=0,t=this.elements.length,n=1;n<t;n+=2){var r=this.elements[n];e+=r*r}return this._magnitude=Math.sqrt(e)},T.Vector.prototype.dot=function(e){for(var t=0,n=this.elements,r=e.elements,i=n.length,a=r.length,o=0,s=0,c=0,u=0;c<i&&u<a;)(o=n[c])<(s=r[u])?c+=2:o>s?u+=2:o==s&&(t+=n[c+1]*r[u+1],c+=2,u+=2);return t},T.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},T.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),t=1,n=0;t<this.elements.length;t+=2,n++)e[n]=this.elements[t];return e},T.Vector.prototype.toJSON=function(){return this.elements},T.stemmer=(o={ational:"ate",tional:"tion",enci:"ence",anci:"ance",izer:"ize",bli:"ble",alli:"al",entli:"ent",eli:"e",ousli:"ous",ization:"ize",ation:"ate",ator:"ate",alism:"al",iveness:"ive",fulness:"ful",ousness:"ous",aliti:"al",iviti:"ive",biliti:"ble",logi:"log"},s={icate:"ic",ative:"",alize:"al",iciti:"ic",ical:"ic",ful:"",ness:""},c="[aeiouy]",u="[^aeiou][^aeiouy]*",l=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*"),d=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*[aeiouy][aeiou]*[^aeiou][^aeiouy]*"),h=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*([aeiouy][aeiou]*)?$"),f=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy]"),p=/^(.+?)(ss|i)es$/,m=/^(.+?)([^s])s$/,v=/^(.+?)eed$/,g=/^(.+?)(ed|ing)$/,y=/.$/,b=/(at|bl|iz)$/,E=new RegExp("([^aeiouylsz])\\1$"),x=new RegExp("^"+u+c+"[^aeiouwxy]$"),k=/^(.+?[^aeiou])y$/,w=/^(.+?)(ational|tional|enci|anci|izer|bli|alli|entli|eli|ousli|ization|ation|ator|alism|iveness|fulness|ousness|aliti|iviti|biliti|logi)$/,O=/^(.+?)(icate|ative|alize|iciti|ical|ful|ness)$/,S=/^(.+?)(al|ance|ence|er|ic|able|ible|ant|ement|ment|ent|ou|ism|ate|iti|ous|ive|ize)$/,j=/^(.+?)(s|t)(ion)$/,P=/^(.+?)e$/,_=/ll$/,N=new RegExp("^"+u+c+"[^aeiouwxy]$"),C=function(e){var t,n,r,i,a,c,u;if(e.length<3)return e;if("y"==(r=e.substr(0,1))&&(e=r.toUpperCase()+e.substr(1)),a=m,(i=p).test(e)?e=e.replace(i,"$1$2"):a.test(e)&&(e=e.replace(a,"$1$2")),a=g,(i=v).test(e)){var C=i.exec(e);(i=l).test(C[1])&&(i=y,e=e.replace(i,""))}else a.test(e)&&(t=(C=a.exec(e))[1],(a=f).test(t)&&(c=E,u=x,(a=b).test(e=t)?e+="e":c.test(e)?(i=y,e=e.replace(i,"")):u.test(e)&&(e+="e")));return(i=k).test(e)&&(e=(t=(C=i.exec(e))[1])+"i"),(i=w).test(e)&&(t=(C=i.exec(e))[1],n=C[2],(i=l).test(t)&&(e=t+o[n])),(i=O).test(e)&&(t=(C=i.exec(e))[1],n=C[2],(i=l).test(t)&&(e=t+s[n])),a=j,(i=S).test(e)?(t=(C=i.exec(e))[1],(i=d).test(t)&&(e=t)):a.test(e)&&(t=(C=a.exec(e))[1]+C[2],(a=d).test(t)&&(e=t)),(i=P).test(e)&&(t=(C=i.exec(e))[1],a=h,c=N,((i=d).test(t)||a.test(t)&&!c.test(t))&&(e=t)),a=d,(i=_).test(e)&&a.test(e)&&(i=y,e=e.replace(i,"")),"y"==r&&(e=r.toLowerCase()+e.substr(1)),e},function(e){return e.update(C)}),T.Pipeline.registerFunction(T.stemmer,"stemmer"),T.generateStopWordFilter=function(e){var t=e.reduce((function(e,t){return e[t]=t,e}),{});return function(e){if(e&&t[e.toString()]!==e.toString())return e}},T.stopWordFilter=T.generateStopWordFilter(["a","able","about","across","after","all","almost","also","am","among","an","and","any","are","as","at","be","because","been","but","by","can","cannot","could","dear","did","do","does","either","else","ever","every","for","from","get","got","had","has","have","he","her","hers","him","his","how","however","i","if","in","into","is","it","its","just","least","let","like","likely","may","me","might","most","must","my","neither","no","nor","not","of","off","often","on","only","or","other","our","own","rather","said","say","says","she","should","since","so","some","than","that","the","their","them","then","there","these","they","this","tis","to","too","twas","us","wants","was","we","were","what","when","where","which","while","who","whom","why","will","with","would","yet","you","your"]),T.Pipeline.registerFunction(T.stopWordFilter,"stopWordFilter"),T.trimmer=function(e){return e.update((function(e){return e.replace(/^\W+/,"").replace(/\W+$/,"")}))},T.Pipeline.registerFunction(T.trimmer,"trimmer"),T.TokenSet=function(){this.final=!1,this.edges={},this.id=T.TokenSet._nextId,T.TokenSet._nextId+=1},T.TokenSet._nextId=1,T.TokenSet.fromArray=function(e){for(var t=new T.TokenSet.Builder,n=0,r=e.length;n<r;n++)t.insert(e[n]);return t.finish(),t.root},T.TokenSet.fromClause=function(e){return"editDistance"in e?T.TokenSet.fromFuzzyString(e.term,e.editDistance):T.TokenSet.fromString(e.term)},T.TokenSet.fromFuzzyString=function(e,t){for(var n=new T.TokenSet,r=[{node:n,editsRemaining:t,str:e}];r.length;){var i=r.pop();if(i.str.length>0){var a,o=i.str.charAt(0);o in i.node.edges?a=i.node.edges[o]:(a=new T.TokenSet,i.node.edges[o]=a),1==i.str.length&&(a.final=!0),r.push({node:a,editsRemaining:i.editsRemaining,str:i.str.slice(1)})}if(0!=i.editsRemaining){if("*"in i.node.edges)var s=i.node.edges["*"];else{s=new T.TokenSet;i.node.edges["*"]=s}if(0==i.str.length&&(s.final=!0),r.push({node:s,editsRemaining:i.editsRemaining-1,str:i.str}),i.str.length>1&&r.push({node:i.node,editsRemaining:i.editsRemaining-1,str:i.str.slice(1)}),1==i.str.length&&(i.node.final=!0),i.str.length>=1){if("*"in i.node.edges)var c=i.node.edges["*"];else{c=new T.TokenSet;i.node.edges["*"]=c}1==i.str.length&&(c.final=!0),r.push({node:c,editsRemaining:i.editsRemaining-1,str:i.str.slice(1)})}if(i.str.length>1){var u,l=i.str.charAt(0),d=i.str.charAt(1);d in i.node.edges?u=i.node.edges[d]:(u=new T.TokenSet,i.node.edges[d]=u),1==i.str.length&&(u.final=!0),r.push({node:u,editsRemaining:i.editsRemaining-1,str:l+i.str.slice(2)})}}}return n},T.TokenSet.fromString=function(e){for(var t=new T.TokenSet,n=t,r=0,i=e.length;r<i;r++){var a=e[r],o=r==i-1;if("*"==a)t.edges[a]=t,t.final=o;else{var s=new T.TokenSet;s.final=o,t.edges[a]=s,t=s}}return n},T.TokenSet.prototype.toArray=function(){for(var e=[],t=[{prefix:"",node:this}];t.length;){var n=t.pop(),r=Object.keys(n.node.edges),i=r.length;n.node.final&&(n.prefix.charAt(0),e.push(n.prefix));for(var a=0;a<i;a++){var o=r[a];t.push({prefix:n.prefix.concat(o),node:n.node.edges[o]})}}return e},T.TokenSet.prototype.toString=function(){if(this._str)return this._str;for(var e=this.final?"1":"0",t=Object.keys(this.edges).sort(),n=t.length,r=0;r<n;r++){var i=t[r];e=e+i+this.edges[i].id}return e},T.TokenSet.prototype.intersect=function(e){for(var t=new T.TokenSet,n=void 0,r=[{qNode:e,output:t,node:this}];r.length;){n=r.pop();for(var i=Object.keys(n.qNode.edges),a=i.length,o=Object.keys(n.node.edges),s=o.length,c=0;c<a;c++)for(var u=i[c],l=0;l<s;l++){var d=o[l];if(d==u||"*"==u){var h=n.node.edges[d],f=n.qNode.edges[u],p=h.final&&f.final,m=void 0;d in n.output.edges?(m=n.output.edges[d]).final=m.final||p:((m=new T.TokenSet).final=p,n.output.edges[d]=m),r.push({qNode:f,output:m,node:h})}}}return t},T.TokenSet.Builder=function(){this.previousWord="",this.root=new T.TokenSet,this.uncheckedNodes=[],this.minimizedNodes={}},T.TokenSet.Builder.prototype.insert=function(e){var t,n=0;if(e<this.previousWord)throw new Error("Out of order word insertion");for(var r=0;r<e.length&&r<this.previousWord.length&&e[r]==this.previousWord[r];r++)n++;this.minimize(n),t=0==this.uncheckedNodes.length?this.root:this.uncheckedNodes[this.uncheckedNodes.length-1].child;for(r=n;r<e.length;r++){var i=new T.TokenSet,a=e[r];t.edges[a]=i,this.uncheckedNodes.push({parent:t,char:a,child:i}),t=i}t.final=!0,this.previousWord=e},T.TokenSet.Builder.prototype.finish=function(){this.minimize(0)},T.TokenSet.Builder.prototype.minimize=function(e){for(var t=this.uncheckedNodes.length-1;t>=e;t--){var n=this.uncheckedNodes[t],r=n.child.toString();r in this.minimizedNodes?n.parent.edges[n.char]=this.minimizedNodes[r]:(n.child._str=r,this.minimizedNodes[r]=n.child),this.uncheckedNodes.pop()}},T.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},T.Index.prototype.search=function(e){return this.query((function(t){new T.QueryParser(e,t).parse()}))},T.Index.prototype.query=function(e){for(var t=new T.Query(this.fields),n=Object.create(null),r=Object.create(null),i=Object.create(null),a=Object.create(null),o=Object.create(null),s=0;s<this.fields.length;s++)r[this.fields[s]]=new T.Vector;e.call(t,t);for(s=0;s<t.clauses.length;s++){var c=t.clauses[s],u=null,l=T.Set.empty;u=c.usePipeline?this.pipeline.runString(c.term,{fields:c.fields}):[c.term];for(var d=0;d<u.length;d++){var h=u[d];c.term=h;var f=T.TokenSet.fromClause(c),p=this.tokenSet.intersect(f).toArray();if(0===p.length&&c.presence===T.Query.presence.REQUIRED){for(var m=0;m<c.fields.length;m++){a[I=c.fields[m]]=T.Set.empty}break}for(var v=0;v<p.length;v++){var g=p[v],y=this.invertedIndex[g],b=y._index;for(m=0;m<c.fields.length;m++){var E=y[I=c.fields[m]],x=Object.keys(E),k=g+"/"+I,w=new T.Set(x);if(c.presence==T.Query.presence.REQUIRED&&(l=l.union(w),void 0===a[I]&&(a[I]=T.Set.complete)),c.presence!=T.Query.presence.PROHIBITED){if(r[I].upsert(b,c.boost,(function(e,t){return e+t})),!i[k]){for(var O=0;O<x.length;O++){var S,j=x[O],P=new T.FieldRef(j,I),_=E[j];void 0===(S=n[P])?n[P]=new T.MatchData(g,I,_):S.add(g,I,_)}i[k]=!0}}else void 0===o[I]&&(o[I]=T.Set.empty),o[I]=o[I].union(w)}}}if(c.presence===T.Query.presence.REQUIRED)for(m=0;m<c.fields.length;m++){a[I=c.fields[m]]=a[I].intersect(l)}}var N=T.Set.complete,C=T.Set.empty;for(s=0;s<this.fields.length;s++){var I;a[I=this.fields[s]]&&(N=N.intersect(a[I])),o[I]&&(C=C.union(o[I]))}var L=Object.keys(n),D=[],R=Object.create(null);if(t.isNegated()){L=Object.keys(this.fieldVectors);for(s=0;s<L.length;s++){P=L[s];var Q=T.FieldRef.fromString(P);n[P]=new T.MatchData}}for(s=0;s<L.length;s++){var A=(Q=T.FieldRef.fromString(L[s])).docRef;if(N.contains(A)&&!C.contains(A)){var V,F=this.fieldVectors[Q],M=r[Q.fieldName].similarity(F);if(void 0!==(V=R[A]))V.score+=M,V.matchData.combine(n[Q]);else{var B={ref:A,score:M,matchData:n[Q]};R[A]=B,D.push(B)}}}return D.sort((function(e,t){return t.score-e.score}))},T.Index.prototype.toJSON=function(){var e=Object.keys(this.invertedIndex).sort().map((function(e){return[e,this.invertedIndex[e]]}),this),t=Object.keys(this.fieldVectors).map((function(e){return[e,this.fieldVectors[e].toJSON()]}),this);return{version:T.version,fields:this.fields,fieldVectors:t,invertedIndex:e,pipeline:this.pipeline.toJSON()}},T.Index.load=function(e){var t={},n={},r=e.fieldVectors,i=Object.create(null),a=e.invertedIndex,o=new T.TokenSet.Builder,s=T.Pipeline.load(e.pipeline);e.version!=T.version&&T.utils.warn("Version mismatch when loading serialised index. Current version of lunr '"+T.version+"' does not match serialized index '"+e.version+"'");for(var c=0;c<r.length;c++){var u=(d=r[c])[0],l=d[1];n[u]=new T.Vector(l)}for(c=0;c<a.length;c++){var d,h=(d=a[c])[0],f=d[1];o.insert(h),i[h]=f}return o.finish(),t.fields=e.fields,t.fieldVectors=n,t.invertedIndex=i,t.tokenSet=o.root,t.pipeline=s,new T.Index(t)},T.Builder=function(){this._ref="id",this._fields=Object.create(null),this._documents=Object.create(null),this.invertedIndex=Object.create(null),this.fieldTermFrequencies={},this.fieldLengths={},this.tokenizer=T.tokenizer,this.pipeline=new T.Pipeline,this.searchPipeline=new T.Pipeline,this.documentCount=0,this._b=.75,this._k1=1.2,this.termIndex=0,this.metadataWhitelist=[]},T.Builder.prototype.ref=function(e){this._ref=e},T.Builder.prototype.field=function(e,t){if(/\//.test(e))throw new RangeError("Field '"+e+"' contains illegal character '/'");this._fields[e]=t||{}},T.Builder.prototype.b=function(e){this._b=e<0?0:e>1?1:e},T.Builder.prototype.k1=function(e){this._k1=e},T.Builder.prototype.add=function(e,t){var n=e[this._ref],r=Object.keys(this._fields);this._documents[n]=t||{},this.documentCount+=1;for(var i=0;i<r.length;i++){var a=r[i],o=this._fields[a].extractor,s=o?o(e):e[a],c=this.tokenizer(s,{fields:[a]}),u=this.pipeline.run(c),l=new T.FieldRef(n,a),d=Object.create(null);this.fieldTermFrequencies[l]=d,this.fieldLengths[l]=0,this.fieldLengths[l]+=u.length;for(var h=0;h<u.length;h++){var f=u[h];if(null==d[f]&&(d[f]=0),d[f]+=1,null==this.invertedIndex[f]){var p=Object.create(null);p._index=this.termIndex,this.termIndex+=1;for(var m=0;m<r.length;m++)p[r[m]]=Object.create(null);this.invertedIndex[f]=p}null==this.invertedIndex[f][a][n]&&(this.invertedIndex[f][a][n]=Object.create(null));for(var v=0;v<this.metadataWhitelist.length;v++){var g=this.metadataWhitelist[v],y=f.metadata[g];null==this.invertedIndex[f][a][n][g]&&(this.invertedIndex[f][a][n][g]=[]),this.invertedIndex[f][a][n][g].push(y)}}}},T.Builder.prototype.calculateAverageFieldLengths=function(){for(var e=Object.keys(this.fieldLengths),t=e.length,n={},r={},i=0;i<t;i++){var a=T.FieldRef.fromString(e[i]),o=a.fieldName;r[o]||(r[o]=0),r[o]+=1,n[o]||(n[o]=0),n[o]+=this.fieldLengths[a]}var s=Object.keys(this._fields);for(i=0;i<s.length;i++){var c=s[i];n[c]=n[c]/r[c]}this.averageFieldLength=n},T.Builder.prototype.createFieldVectors=function(){for(var e={},t=Object.keys(this.fieldTermFrequencies),n=t.length,r=Object.create(null),i=0;i<n;i++){for(var a=T.FieldRef.fromString(t[i]),o=a.fieldName,s=this.fieldLengths[a],c=new T.Vector,u=this.fieldTermFrequencies[a],l=Object.keys(u),d=l.length,h=this._fields[o].boost||1,f=this._documents[a.docRef].boost||1,p=0;p<d;p++){var m,v,g,y=l[p],b=u[y],E=this.invertedIndex[y]._index;void 0===r[y]?(m=T.idf(this.invertedIndex[y],this.documentCount),r[y]=m):m=r[y],v=m*((this._k1+1)*b)/(this._k1*(1-this._b+this._b*(s/this.averageFieldLength[o]))+b),v*=h,v*=f,g=Math.round(1e3*v)/1e3,c.insert(E,g)}e[a]=c}this.fieldVectors=e},T.Builder.prototype.createTokenSet=function(){this.tokenSet=T.TokenSet.fromArray(Object.keys(this.invertedIndex).sort())},T.Builder.prototype.build=function(){return this.calculateAverageFieldLengths(),this.createFieldVectors(),this.createTokenSet(),new T.Index({invertedIndex:this.invertedIndex,fieldVectors:this.fieldVectors,tokenSet:this.tokenSet,fields:Object.keys(this._fields),pipeline:this.searchPipeline})},T.Builder.prototype.use=function(e){var t=Array.prototype.slice.call(arguments,1);t.unshift(this),e.apply(this,t)},T.MatchData=function(e,t,n){for(var r=Object.create(null),i=Object.keys(n||{}),a=0;a<i.length;a++){var o=i[a];r[o]=n[o].slice()}this.metadata=Object.create(null),void 0!==e&&(this.metadata[e]=Object.create(null),this.metadata[e][t]=r)},T.MatchData.prototype.combine=function(e){for(var t=Object.keys(e.metadata),n=0;n<t.length;n++){var r=t[n],i=Object.keys(e.metadata[r]);null==this.metadata[r]&&(this.metadata[r]=Object.create(null));for(var a=0;a<i.length;a++){var o=i[a],s=Object.keys(e.metadata[r][o]);null==this.metadata[r][o]&&(this.metadata[r][o]=Object.create(null));for(var c=0;c<s.length;c++){var u=s[c];null==this.metadata[r][o][u]?this.metadata[r][o][u]=e.metadata[r][o][u]:this.metadata[r][o][u]=this.metadata[r][o][u].concat(e.metadata[r][o][u])}}}},T.MatchData.prototype.add=function(e,t,n){if(!(e in this.metadata))return this.metadata[e]=Object.create(null),void(this.metadata[e][t]=n);if(t in this.metadata[e])for(var r=Object.keys(n),i=0;i<r.length;i++){var a=r[i];a in this.metadata[e][t]?this.metadata[e][t][a]=this.metadata[e][t][a].concat(n[a]):this.metadata[e][t][a]=n[a]}else this.metadata[e][t]=n},T.Query=function(e){this.clauses=[],this.allFields=e},T.Query.wildcard=new String("*"),T.Query.wildcard.NONE=0,T.Query.wildcard.LEADING=1,T.Query.wildcard.TRAILING=2,T.Query.presence={OPTIONAL:1,REQUIRED:2,PROHIBITED:3},T.Query.prototype.clause=function(e){return"fields"in e||(e.fields=this.allFields),"boost"in e||(e.boost=1),"usePipeline"in e||(e.usePipeline=!0),"wildcard"in e||(e.wildcard=T.Query.wildcard.NONE),e.wildcard&T.Query.wildcard.LEADING&&e.term.charAt(0)!=T.Query.wildcard&&(e.term="*"+e.term),e.wildcard&T.Query.wildcard.TRAILING&&e.term.slice(-1)!=T.Query.wildcard&&(e.term=e.term+"*"),"presence"in e||(e.presence=T.Query.presence.OPTIONAL),this.clauses.push(e),this},T.Query.prototype.isNegated=function(){for(var e=0;e<this.clauses.length;e++)if(this.clauses[e].presence!=T.Query.presence.PROHIBITED)return!1;return!0},T.Query.prototype.term=function(e,t){if(Array.isArray(e))return e.forEach((function(e){this.term(e,T.utils.clone(t))}),this),this;var n=t||{};return n.term=e.toString(),this.clause(n),this},T.QueryParseError=function(e,t,n){this.name="QueryParseError",this.message=e,this.start=t,this.end=n},T.QueryParseError.prototype=new Error,T.QueryLexer=function(e){this.lexemes=[],this.str=e,this.length=e.length,this.pos=0,this.start=0,this.escapeCharPositions=[]},T.QueryLexer.prototype.run=function(){for(var e=T.QueryLexer.lexText;e;)e=e(this)},T.QueryLexer.prototype.sliceString=function(){for(var e=[],t=this.start,n=this.pos,r=0;r<this.escapeCharPositions.length;r++)n=this.escapeCharPositions[r],e.push(this.str.slice(t,n)),t=n+1;return e.push(this.str.slice(t,this.pos)),this.escapeCharPositions.length=0,e.join("")},T.QueryLexer.prototype.emit=function(e){this.lexemes.push({type:e,str:this.sliceString(),start:this.start,end:this.pos}),this.start=this.pos},T.QueryLexer.prototype.escapeCharacter=function(){this.escapeCharPositions.push(this.pos-1),this.pos+=1},T.QueryLexer.prototype.next=function(){if(this.pos>=this.length)return T.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},T.QueryLexer.prototype.width=function(){return this.pos-this.start},T.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},T.QueryLexer.prototype.backup=function(){this.pos-=1},T.QueryLexer.prototype.acceptDigitRun=function(){var e,t;do{t=(e=this.next()).charCodeAt(0)}while(t>47&&t<58);e!=T.QueryLexer.EOS&&this.backup()},T.QueryLexer.prototype.more=function(){return this.pos<this.length},T.QueryLexer.EOS="EOS",T.QueryLexer.FIELD="FIELD",T.QueryLexer.TERM="TERM",T.QueryLexer.EDIT_DISTANCE="EDIT_DISTANCE",T.QueryLexer.BOOST="BOOST",T.QueryLexer.PRESENCE="PRESENCE",T.QueryLexer.lexField=function(e){return e.backup(),e.emit(T.QueryLexer.FIELD),e.ignore(),T.QueryLexer.lexText},T.QueryLexer.lexTerm=function(e){if(e.width()>1&&(e.backup(),e.emit(T.QueryLexer.TERM)),e.ignore(),e.more())return T.QueryLexer.lexText},T.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(T.QueryLexer.EDIT_DISTANCE),T.QueryLexer.lexText},T.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(T.QueryLexer.BOOST),T.QueryLexer.lexText},T.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(T.QueryLexer.TERM)},T.QueryLexer.termSeparator=T.tokenizer.separator,T.QueryLexer.lexText=function(e){for(;;){var t=e.next();if(t==T.QueryLexer.EOS)return T.QueryLexer.lexEOS;if(92!=t.charCodeAt(0)){if(":"==t)return T.QueryLexer.lexField;if("~"==t)return e.backup(),e.width()>0&&e.emit(T.QueryLexer.TERM),T.QueryLexer.lexEditDistance;if("^"==t)return e.backup(),e.width()>0&&e.emit(T.QueryLexer.TERM),T.QueryLexer.lexBoost;if("+"==t&&1===e.width())return e.emit(T.QueryLexer.PRESENCE),T.QueryLexer.lexText;if("-"==t&&1===e.width())return e.emit(T.QueryLexer.PRESENCE),T.QueryLexer.lexText;if(t.match(T.QueryLexer.termSeparator))return T.QueryLexer.lexTerm}else e.escapeCharacter()}},T.QueryParser=function(e,t){this.lexer=new T.QueryLexer(e),this.query=t,this.currentClause={},this.lexemeIdx=0},T.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=T.QueryParser.parseClause;e;)e=e(this);return this.query},T.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},T.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},T.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},T.QueryParser.parseClause=function(e){var t=e.peekLexeme();if(null!=t)switch(t.type){case T.QueryLexer.PRESENCE:return T.QueryParser.parsePresence;case T.QueryLexer.FIELD:return T.QueryParser.parseField;case T.QueryLexer.TERM:return T.QueryParser.parseTerm;default:var n="expected either a field or a term, found "+t.type;throw t.str.length>=1&&(n+=" with value '"+t.str+"'"),new T.QueryParseError(n,t.start,t.end)}},T.QueryParser.parsePresence=function(e){var t=e.consumeLexeme();if(null!=t){switch(t.str){case"-":e.currentClause.presence=T.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=T.Query.presence.REQUIRED;break;default:var n="unrecognised presence operator'"+t.str+"'";throw new T.QueryParseError(n,t.start,t.end)}var r=e.peekLexeme();if(null==r){n="expecting term or field, found nothing";throw new T.QueryParseError(n,t.start,t.end)}switch(r.type){case T.QueryLexer.FIELD:return T.QueryParser.parseField;case T.QueryLexer.TERM:return T.QueryParser.parseTerm;default:n="expecting term or field, found '"+r.type+"'";throw new T.QueryParseError(n,r.start,r.end)}}},T.QueryParser.parseField=function(e){var t=e.consumeLexeme();if(null!=t){if(-1==e.query.allFields.indexOf(t.str)){var n=e.query.allFields.map((function(e){return"'"+e+"'"})).join(", "),r="unrecognised field '"+t.str+"', possible fields: "+n;throw new T.QueryParseError(r,t.start,t.end)}e.currentClause.fields=[t.str];var i=e.peekLexeme();if(null==i){r="expecting term, found nothing";throw new T.QueryParseError(r,t.start,t.end)}switch(i.type){case T.QueryLexer.TERM:return T.QueryParser.parseTerm;default:r="expecting term, found '"+i.type+"'";throw new T.QueryParseError(r,i.start,i.end)}}},T.QueryParser.parseTerm=function(e){var t=e.consumeLexeme();if(null!=t){e.currentClause.term=t.str.toLowerCase(),-1!=t.str.indexOf("*")&&(e.currentClause.usePipeline=!1);var n=e.peekLexeme();if(null!=n)switch(n.type){case T.QueryLexer.TERM:return e.nextClause(),T.QueryParser.parseTerm;case T.QueryLexer.FIELD:return e.nextClause(),T.QueryParser.parseField;case T.QueryLexer.EDIT_DISTANCE:return T.QueryParser.parseEditDistance;case T.QueryLexer.BOOST:return T.QueryParser.parseBoost;case T.QueryLexer.PRESENCE:return e.nextClause(),T.QueryParser.parsePresence;default:var r="Unexpected lexeme type '"+n.type+"'";throw new T.QueryParseError(r,n.start,n.end)}else e.nextClause()}},T.QueryParser.parseEditDistance=function(e){var t=e.consumeLexeme();if(null!=t){var n=parseInt(t.str,10);if(isNaN(n)){var r="edit distance must be numeric";throw new T.QueryParseError(r,t.start,t.end)}e.currentClause.editDistance=n;var i=e.peekLexeme();if(null!=i)switch(i.type){case T.QueryLexer.TERM:return e.nextClause(),T.QueryParser.parseTerm;case T.QueryLexer.FIELD:return e.nextClause(),T.QueryParser.parseField;case T.QueryLexer.EDIT_DISTANCE:return T.QueryParser.parseEditDistance;case T.QueryLexer.BOOST:return T.QueryParser.parseBoost;case T.QueryLexer.PRESENCE:return e.nextClause(),T.QueryParser.parsePresence;default:r="Unexpected lexeme type '"+i.type+"'";throw new T.QueryParseError(r,i.start,i.end)}else e.nextClause()}},T.QueryParser.parseBoost=function(e){var t=e.consumeLexeme();if(null!=t){var n=parseInt(t.str,10);if(isNaN(n)){var r="boost must be numeric";throw new T.QueryParseError(r,t.start,t.end)}e.currentClause.boost=n;var i=e.peekLexeme();if(null!=i)switch(i.type){case T.QueryLexer.TERM:return e.nextClause(),T.QueryParser.parseTerm;case T.QueryLexer.FIELD:return e.nextClause(),T.QueryParser.parseField;case T.QueryLexer.EDIT_DISTANCE:return T.QueryParser.parseEditDistance;case T.QueryLexer.BOOST:return T.QueryParser.parseBoost;case T.QueryLexer.PRESENCE:return e.nextClause(),T.QueryParser.parsePresence;default:r="Unexpected lexeme type '"+i.type+"'";throw new T.QueryParseError(r,i.start,i.end)}else e.nextClause()}},void 0===(i="function"==typeof(r=function(){return T})?r.call(t,n,t,e):r)||(e.exports=i)}()},247:function(e,t,n){e.exports=function(){"use strict";var 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},t=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},n=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},i=function(){function e(n){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:5e3;t(this,e),this.ctx=n,this.iframes=r,this.exclude=i,this.iframesTimeout=a}return n(e,[{key:"getContexts",value:function(){var e=[];return(void 0!==this.ctx&&this.ctx?NodeList.prototype.isPrototypeOf(this.ctx)?Array.prototype.slice.call(this.ctx):Array.isArray(this.ctx)?this.ctx:"string"==typeof this.ctx?Array.prototype.slice.call(document.querySelectorAll(this.ctx)):[this.ctx]:[]).forEach((function(t){var n=e.filter((function(e){return e.contains(t)})).length>0;-1!==e.indexOf(t)||n||e.push(t)})),e}},{key:"getIframeContents",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){},r=void 0;try{var i=e.contentWindow;if(r=i.document,!i||!r)throw new Error("iframe inaccessible")}catch(a){n()}r&&t(r)}},{key:"isIframeBlank",value:function(e){var t="about:blank",n=e.getAttribute("src").trim();return e.contentWindow.location.href===t&&n!==t&&n}},{key:"observeIframeLoad",value:function(e,t,n){var r=this,i=!1,a=null,o=function o(){if(!i){i=!0,clearTimeout(a);try{r.isIframeBlank(e)||(e.removeEventListener("load",o),r.getIframeContents(e,t,n))}catch(s){n()}}};e.addEventListener("load",o),a=setTimeout(o,this.iframesTimeout)}},{key:"onIframeReady",value:function(e,t,n){try{"complete"===e.contentWindow.document.readyState?this.isIframeBlank(e)?this.observeIframeLoad(e,t,n):this.getIframeContents(e,t,n):this.observeIframeLoad(e,t,n)}catch(r){n()}}},{key:"waitForIframes",value:function(e,t){var n=this,r=0;this.forEachIframe(e,(function(){return!0}),(function(e){r++,n.waitForIframes(e.querySelector("html"),(function(){--r||t()}))}),(function(e){e||t()}))}},{key:"forEachIframe",value:function(t,n,r){var i=this,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:function(){},o=t.querySelectorAll("iframe"),s=o.length,c=0;o=Array.prototype.slice.call(o);var u=function(){--s<=0&&a(c)};s||u(),o.forEach((function(t){e.matches(t,i.exclude)?u():i.onIframeReady(t,(function(e){n(t)&&(c++,r(e)),u()}),u)}))}},{key:"createIterator",value:function(e,t,n){return document.createNodeIterator(e,t,n,!1)}},{key:"createInstanceOnIframe",value:function(t){return new e(t.querySelector("html"),this.iframes)}},{key:"compareNodeIframe",value:function(e,t,n){if(e.compareDocumentPosition(n)&Node.DOCUMENT_POSITION_PRECEDING){if(null===t)return!0;if(t.compareDocumentPosition(n)&Node.DOCUMENT_POSITION_FOLLOWING)return!0}return!1}},{key:"getIteratorNode",value:function(e){var t=e.previousNode();return{prevNode:t,node:(null===t||e.nextNode())&&e.nextNode()}}},{key:"checkIframeFilter",value:function(e,t,n,r){var i=!1,a=!1;return r.forEach((function(e,t){e.val===n&&(i=t,a=e.handled)})),this.compareNodeIframe(e,t,n)?(!1!==i||a?!1===i||a||(r[i].handled=!0):r.push({val:n,handled:!0}),!0):(!1===i&&r.push({val:n,handled:!1}),!1)}},{key:"handleOpenIframes",value:function(e,t,n,r){var i=this;e.forEach((function(e){e.handled||i.getIframeContents(e.val,(function(e){i.createInstanceOnIframe(e).forEachNode(t,n,r)}))}))}},{key:"iterateThroughNodes",value:function(e,t,n,r,i){for(var a=this,o=this.createIterator(t,e,r),s=[],c=[],u=void 0,l=void 0,d=function(){var e=a.getIteratorNode(o);return l=e.prevNode,u=e.node};d();)this.iframes&&this.forEachIframe(t,(function(e){return a.checkIframeFilter(u,l,e,s)}),(function(t){a.createInstanceOnIframe(t).forEachNode(e,(function(e){return c.push(e)}),r)})),c.push(u);c.forEach((function(e){n(e)})),this.iframes&&this.handleOpenIframes(s,e,n,r),i()}},{key:"forEachNode",value:function(e,t,n){var r=this,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:function(){},a=this.getContexts(),o=a.length;o||i(),a.forEach((function(a){var s=function(){r.iterateThroughNodes(e,a,t,n,(function(){--o<=0&&i()}))};r.iframes?r.waitForIframes(a,s):s()}))}}],[{key:"matches",value:function(e,t){var n="string"==typeof t?[t]:t,r=e.matches||e.matchesSelector||e.msMatchesSelector||e.mozMatchesSelector||e.oMatchesSelector||e.webkitMatchesSelector;if(r){var i=!1;return n.every((function(t){return!r.call(e,t)||(i=!0,!1)})),i}return!1}}]),e}(),a=function(){function a(e){t(this,a),this.ctx=e,this.ie=!1;var n=window.navigator.userAgent;(n.indexOf("MSIE")>-1||n.indexOf("Trident")>-1)&&(this.ie=!0)}return n(a,[{key:"log",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"debug",r=this.opt.log;this.opt.debug&&"object"===(void 0===r?"undefined":e(r))&&"function"==typeof r[n]&&r[n]("mark.js: "+t)}},{key:"escapeStr",value:function(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}},{key:"createRegExp",value:function(e){return"disabled"!==this.opt.wildcards&&(e=this.setupWildcardsRegExp(e)),e=this.escapeStr(e),Object.keys(this.opt.synonyms).length&&(e=this.createSynonymsRegExp(e)),(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(e=this.setupIgnoreJoinersRegExp(e)),this.opt.diacritics&&(e=this.createDiacriticsRegExp(e)),e=this.createMergedBlanksRegExp(e),(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(e=this.createJoinersRegExp(e)),"disabled"!==this.opt.wildcards&&(e=this.createWildcardsRegExp(e)),e=this.createAccuracyRegExp(e)}},{key:"createSynonymsRegExp",value:function(e){var t=this.opt.synonyms,n=this.opt.caseSensitive?"":"i",r=this.opt.ignoreJoiners||this.opt.ignorePunctuation.length?"\0":"";for(var i in t)if(t.hasOwnProperty(i)){var a=t[i],o="disabled"!==this.opt.wildcards?this.setupWildcardsRegExp(i):this.escapeStr(i),s="disabled"!==this.opt.wildcards?this.setupWildcardsRegExp(a):this.escapeStr(a);""!==o&&""!==s&&(e=e.replace(new RegExp("("+this.escapeStr(o)+"|"+this.escapeStr(s)+")","gm"+n),r+"("+this.processSynomyms(o)+"|"+this.processSynomyms(s)+")"+r))}return e}},{key:"processSynomyms",value:function(e){return(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(e=this.setupIgnoreJoinersRegExp(e)),e}},{key:"setupWildcardsRegExp",value:function(e){return(e=e.replace(/(?:\\)*\?/g,(function(e){return"\\"===e.charAt(0)?"?":"\x01"}))).replace(/(?:\\)*\*/g,(function(e){return"\\"===e.charAt(0)?"*":"\x02"}))}},{key:"createWildcardsRegExp",value:function(e){var t="withSpaces"===this.opt.wildcards;return e.replace(/\u0001/g,t?"[\\S\\s]?":"\\S?").replace(/\u0002/g,t?"[\\S\\s]*?":"\\S*")}},{key:"setupIgnoreJoinersRegExp",value:function(e){return e.replace(/[^(|)\\]/g,(function(e,t,n){var r=n.charAt(t+1);return/[(|)\\]/.test(r)||""===r?e:e+"\0"}))}},{key:"createJoinersRegExp",value:function(e){var t=[],n=this.opt.ignorePunctuation;return Array.isArray(n)&&n.length&&t.push(this.escapeStr(n.join(""))),this.opt.ignoreJoiners&&t.push("\\u00ad\\u200b\\u200c\\u200d"),t.length?e.split(/\u0000+/).join("["+t.join("")+"]*"):e}},{key:"createDiacriticsRegExp",value:function(e){var t=this.opt.caseSensitive?"":"i",n=this.opt.caseSensitive?["a\xe0\xe1\u1ea3\xe3\u1ea1\u0103\u1eb1\u1eaf\u1eb3\u1eb5\u1eb7\xe2\u1ea7\u1ea5\u1ea9\u1eab\u1ead\xe4\xe5\u0101\u0105","A\xc0\xc1\u1ea2\xc3\u1ea0\u0102\u1eb0\u1eae\u1eb2\u1eb4\u1eb6\xc2\u1ea6\u1ea4\u1ea8\u1eaa\u1eac\xc4\xc5\u0100\u0104","c\xe7\u0107\u010d","C\xc7\u0106\u010c","d\u0111\u010f","D\u0110\u010e","e\xe8\xe9\u1ebb\u1ebd\u1eb9\xea\u1ec1\u1ebf\u1ec3\u1ec5\u1ec7\xeb\u011b\u0113\u0119","E\xc8\xc9\u1eba\u1ebc\u1eb8\xca\u1ec0\u1ebe\u1ec2\u1ec4\u1ec6\xcb\u011a\u0112\u0118","i\xec\xed\u1ec9\u0129\u1ecb\xee\xef\u012b","I\xcc\xcd\u1ec8\u0128\u1eca\xce\xcf\u012a","l\u0142","L\u0141","n\xf1\u0148\u0144","N\xd1\u0147\u0143","o\xf2\xf3\u1ecf\xf5\u1ecd\xf4\u1ed3\u1ed1\u1ed5\u1ed7\u1ed9\u01a1\u1edf\u1ee1\u1edb\u1edd\u1ee3\xf6\xf8\u014d","O\xd2\xd3\u1ece\xd5\u1ecc\xd4\u1ed2\u1ed0\u1ed4\u1ed6\u1ed8\u01a0\u1ede\u1ee0\u1eda\u1edc\u1ee2\xd6\xd8\u014c","r\u0159","R\u0158","s\u0161\u015b\u0219\u015f","S\u0160\u015a\u0218\u015e","t\u0165\u021b\u0163","T\u0164\u021a\u0162","u\xf9\xfa\u1ee7\u0169\u1ee5\u01b0\u1eeb\u1ee9\u1eed\u1eef\u1ef1\xfb\xfc\u016f\u016b","U\xd9\xda\u1ee6\u0168\u1ee4\u01af\u1eea\u1ee8\u1eec\u1eee\u1ef0\xdb\xdc\u016e\u016a","y\xfd\u1ef3\u1ef7\u1ef9\u1ef5\xff","Y\xdd\u1ef2\u1ef6\u1ef8\u1ef4\u0178","z\u017e\u017c\u017a","Z\u017d\u017b\u0179"]:["a\xe0\xe1\u1ea3\xe3\u1ea1\u0103\u1eb1\u1eaf\u1eb3\u1eb5\u1eb7\xe2\u1ea7\u1ea5\u1ea9\u1eab\u1ead\xe4\xe5\u0101\u0105A\xc0\xc1\u1ea2\xc3\u1ea0\u0102\u1eb0\u1eae\u1eb2\u1eb4\u1eb6\xc2\u1ea6\u1ea4\u1ea8\u1eaa\u1eac\xc4\xc5\u0100\u0104","c\xe7\u0107\u010dC\xc7\u0106\u010c","d\u0111\u010fD\u0110\u010e","e\xe8\xe9\u1ebb\u1ebd\u1eb9\xea\u1ec1\u1ebf\u1ec3\u1ec5\u1ec7\xeb\u011b\u0113\u0119E\xc8\xc9\u1eba\u1ebc\u1eb8\xca\u1ec0\u1ebe\u1ec2\u1ec4\u1ec6\xcb\u011a\u0112\u0118","i\xec\xed\u1ec9\u0129\u1ecb\xee\xef\u012bI\xcc\xcd\u1ec8\u0128\u1eca\xce\xcf\u012a","l\u0142L\u0141","n\xf1\u0148\u0144N\xd1\u0147\u0143","o\xf2\xf3\u1ecf\xf5\u1ecd\xf4\u1ed3\u1ed1\u1ed5\u1ed7\u1ed9\u01a1\u1edf\u1ee1\u1edb\u1edd\u1ee3\xf6\xf8\u014dO\xd2\xd3\u1ece\xd5\u1ecc\xd4\u1ed2\u1ed0\u1ed4\u1ed6\u1ed8\u01a0\u1ede\u1ee0\u1eda\u1edc\u1ee2\xd6\xd8\u014c","r\u0159R\u0158","s\u0161\u015b\u0219\u015fS\u0160\u015a\u0218\u015e","t\u0165\u021b\u0163T\u0164\u021a\u0162","u\xf9\xfa\u1ee7\u0169\u1ee5\u01b0\u1eeb\u1ee9\u1eed\u1eef\u1ef1\xfb\xfc\u016f\u016bU\xd9\xda\u1ee6\u0168\u1ee4\u01af\u1eea\u1ee8\u1eec\u1eee\u1ef0\xdb\xdc\u016e\u016a","y\xfd\u1ef3\u1ef7\u1ef9\u1ef5\xffY\xdd\u1ef2\u1ef6\u1ef8\u1ef4\u0178","z\u017e\u017c\u017aZ\u017d\u017b\u0179"],r=[];return e.split("").forEach((function(i){n.every((function(n){if(-1!==n.indexOf(i)){if(r.indexOf(n)>-1)return!1;e=e.replace(new RegExp("["+n+"]","gm"+t),"["+n+"]"),r.push(n)}return!0}))})),e}},{key:"createMergedBlanksRegExp",value:function(e){return e.replace(/[\s]+/gim,"[\\s]+")}},{key:"createAccuracyRegExp",value:function(e){var t=this,n="!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~\xa1\xbf",r=this.opt.accuracy,i="string"==typeof r?r:r.value,a="string"==typeof r?[]:r.limiters,o="";switch(a.forEach((function(e){o+="|"+t.escapeStr(e)})),i){case"partially":default:return"()("+e+")";case"complementary":return"()([^"+(o="\\s"+(o||this.escapeStr(n)))+"]*"+e+"[^"+o+"]*)";case"exactly":return"(^|\\s"+o+")("+e+")(?=$|\\s"+o+")"}}},{key:"getSeparatedKeywords",value:function(e){var t=this,n=[];return e.forEach((function(e){t.opt.separateWordSearch?e.split(" ").forEach((function(e){e.trim()&&-1===n.indexOf(e)&&n.push(e)})):e.trim()&&-1===n.indexOf(e)&&n.push(e)})),{keywords:n.sort((function(e,t){return t.length-e.length})),length:n.length}}},{key:"isNumeric",value:function(e){return Number(parseFloat(e))==e}},{key:"checkRanges",value:function(e){var t=this;if(!Array.isArray(e)||"[object Object]"!==Object.prototype.toString.call(e[0]))return this.log("markRanges() will only accept an array of objects"),this.opt.noMatch(e),[];var n=[],r=0;return e.sort((function(e,t){return e.start-t.start})).forEach((function(e){var i=t.callNoMatchOnInvalidRanges(e,r),a=i.start,o=i.end;i.valid&&(e.start=a,e.length=o-a,n.push(e),r=o)})),n}},{key:"callNoMatchOnInvalidRanges",value:function(e,t){var n=void 0,r=void 0,i=!1;return e&&void 0!==e.start?(r=(n=parseInt(e.start,10))+parseInt(e.length,10),this.isNumeric(e.start)&&this.isNumeric(e.length)&&r-t>0&&r-n>0?i=!0:(this.log("Ignoring invalid or overlapping range: "+JSON.stringify(e)),this.opt.noMatch(e))):(this.log("Ignoring invalid range: "+JSON.stringify(e)),this.opt.noMatch(e)),{start:n,end:r,valid:i}}},{key:"checkWhitespaceRanges",value:function(e,t,n){var r=void 0,i=!0,a=n.length,o=t-a,s=parseInt(e.start,10)-o;return(r=(s=s>a?a:s)+parseInt(e.length,10))>a&&(r=a,this.log("End range automatically set to the max value of "+a)),s<0||r-s<0||s>a||r>a?(i=!1,this.log("Invalid range: "+JSON.stringify(e)),this.opt.noMatch(e)):""===n.substring(s,r).replace(/\s+/g,"")&&(i=!1,this.log("Skipping whitespace only range: "+JSON.stringify(e)),this.opt.noMatch(e)),{start:s,end:r,valid:i}}},{key:"getTextNodes",value:function(e){var t=this,n="",r=[];this.iterator.forEachNode(NodeFilter.SHOW_TEXT,(function(e){r.push({start:n.length,end:(n+=e.textContent).length,node:e})}),(function(e){return t.matchesExclude(e.parentNode)?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT}),(function(){e({value:n,nodes:r})}))}},{key:"matchesExclude",value:function(e){return i.matches(e,this.opt.exclude.concat(["script","style","title","head","html"]))}},{key:"wrapRangeInTextNode",value:function(e,t,n){var r=this.opt.element?this.opt.element:"mark",i=e.splitText(t),a=i.splitText(n-t),o=document.createElement(r);return o.setAttribute("data-markjs","true"),this.opt.className&&o.setAttribute("class",this.opt.className),o.textContent=i.textContent,i.parentNode.replaceChild(o,i),a}},{key:"wrapRangeInMappedTextNode",value:function(e,t,n,r,i){var a=this;e.nodes.every((function(o,s){var c=e.nodes[s+1];if(void 0===c||c.start>t){if(!r(o.node))return!1;var u=t-o.start,l=(n>o.end?o.end:n)-o.start,d=e.value.substr(0,o.start),h=e.value.substr(l+o.start);if(o.node=a.wrapRangeInTextNode(o.node,u,l),e.value=d+h,e.nodes.forEach((function(t,n){n>=s&&(e.nodes[n].start>0&&n!==s&&(e.nodes[n].start-=l),e.nodes[n].end-=l)})),n-=l,i(o.node.previousSibling,o.start),!(n>o.end))return!1;t=o.end}return!0}))}},{key:"wrapMatches",value:function(e,t,n,r,i){var a=this,o=0===t?0:t+1;this.getTextNodes((function(t){t.nodes.forEach((function(t){t=t.node;for(var i=void 0;null!==(i=e.exec(t.textContent))&&""!==i[o];)if(n(i[o],t)){var s=i.index;if(0!==o)for(var c=1;c<o;c++)s+=i[c].length;t=a.wrapRangeInTextNode(t,s,s+i[o].length),r(t.previousSibling),e.lastIndex=0}})),i()}))}},{key:"wrapMatchesAcrossElements",value:function(e,t,n,r,i){var a=this,o=0===t?0:t+1;this.getTextNodes((function(t){for(var s=void 0;null!==(s=e.exec(t.value))&&""!==s[o];){var c=s.index;if(0!==o)for(var u=1;u<o;u++)c+=s[u].length;var l=c+s[o].length;a.wrapRangeInMappedTextNode(t,c,l,(function(e){return n(s[o],e)}),(function(t,n){e.lastIndex=n,r(t)}))}i()}))}},{key:"wrapRangeFromIndex",value:function(e,t,n,r){var i=this;this.getTextNodes((function(a){var o=a.value.length;e.forEach((function(e,r){var s=i.checkWhitespaceRanges(e,o,a.value),c=s.start,u=s.end;s.valid&&i.wrapRangeInMappedTextNode(a,c,u,(function(n){return t(n,e,a.value.substring(c,u),r)}),(function(t){n(t,e)}))})),r()}))}},{key:"unwrapMatches",value:function(e){for(var t=e.parentNode,n=document.createDocumentFragment();e.firstChild;)n.appendChild(e.removeChild(e.firstChild));t.replaceChild(n,e),this.ie?this.normalizeTextNode(t):t.normalize()}},{key:"normalizeTextNode",value:function(e){if(e){if(3===e.nodeType)for(;e.nextSibling&&3===e.nextSibling.nodeType;)e.nodeValue+=e.nextSibling.nodeValue,e.parentNode.removeChild(e.nextSibling);else this.normalizeTextNode(e.firstChild);this.normalizeTextNode(e.nextSibling)}}},{key:"markRegExp",value:function(e,t){var n=this;this.opt=t,this.log('Searching with expression "'+e+'"');var r=0,i="wrapMatches",a=function(e){r++,n.opt.each(e)};this.opt.acrossElements&&(i="wrapMatchesAcrossElements"),this[i](e,this.opt.ignoreGroups,(function(e,t){return n.opt.filter(t,e,r)}),a,(function(){0===r&&n.opt.noMatch(e),n.opt.done(r)}))}},{key:"mark",value:function(e,t){var n=this;this.opt=t;var r=0,i="wrapMatches",a=this.getSeparatedKeywords("string"==typeof e?[e]:e),o=a.keywords,s=a.length,c=this.opt.caseSensitive?"":"i",u=function e(t){var a=new RegExp(n.createRegExp(t),"gm"+c),u=0;n.log('Searching with expression "'+a+'"'),n[i](a,1,(function(e,i){return n.opt.filter(i,t,r,u)}),(function(e){u++,r++,n.opt.each(e)}),(function(){0===u&&n.opt.noMatch(t),o[s-1]===t?n.opt.done(r):e(o[o.indexOf(t)+1])}))};this.opt.acrossElements&&(i="wrapMatchesAcrossElements"),0===s?this.opt.done(r):u(o[0])}},{key:"markRanges",value:function(e,t){var n=this;this.opt=t;var r=0,i=this.checkRanges(e);i&&i.length?(this.log("Starting to mark with the following ranges: "+JSON.stringify(i)),this.wrapRangeFromIndex(i,(function(e,t,r,i){return n.opt.filter(e,t,r,i)}),(function(e,t){r++,n.opt.each(e,t)}),(function(){n.opt.done(r)}))):this.opt.done(r)}},{key:"unmark",value:function(e){var t=this;this.opt=e;var n=this.opt.element?this.opt.element:"*";n+="[data-markjs]",this.opt.className&&(n+="."+this.opt.className),this.log('Removal selector "'+n+'"'),this.iterator.forEachNode(NodeFilter.SHOW_ELEMENT,(function(e){t.unwrapMatches(e)}),(function(e){var r=i.matches(e,n),a=t.matchesExclude(e);return!r||a?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT}),this.opt.done)}},{key:"opt",set:function(e){this._opt=r({},{element:"",className:"",exclude:[],iframes:!1,iframesTimeout:5e3,separateWordSearch:!0,diacritics:!0,synonyms:{},accuracy:"partially",acrossElements:!1,caseSensitive:!1,ignoreJoiners:!1,ignoreGroups:0,ignorePunctuation:[],wildcards:"disabled",each:function(){},noMatch:function(){},filter:function(){return!0},done:function(){},debug:!1,log:window.console},e)},get:function(){return this._opt}},{key:"iterator",get:function(){return new i(this.ctx,this.opt.iframes,this.opt.exclude,this.opt.iframesTimeout)}}]),a}();function o(e){var t=this,n=new a(e);return this.mark=function(e,r){return n.mark(e,r),t},this.markRegExp=function(e,r){return n.markRegExp(e,r),t},this.markRanges=function(e,r){return n.markRanges(e,r),t},this.unmark=function(e){return n.unmark(e),t},this}return o}()},248:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=n(0),o=h(a),s=h(n(249)),c=h(n(1)),u=h(n(250)),l=h(n(251)),d=n(252);function h(e){return e&&e.__esModule?e:{default:e}}var f=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.handleClick=n.handleClick.bind(n),n.handleTouchStart=n.handleTouchStart.bind(n),n.handleTouchMove=n.handleTouchMove.bind(n),n.handleTouchEnd=n.handleTouchEnd.bind(n),n.handleFocus=n.handleFocus.bind(n),n.handleBlur=n.handleBlur.bind(n),n.previouslyChecked=!(!e.checked&&!e.defaultChecked),n.state={checked:!(!e.checked&&!e.defaultChecked),hasFocus:!1},n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"componentDidUpdate",value:function(e){e.checked!==this.props.checked&&this.setState({checked:!!this.props.checked})}},{key:"handleClick",value:function(e){var t=this.input;if(e.target!==t&&!this.moved)return this.previouslyChecked=t.checked,e.preventDefault(),t.focus(),void t.click();var n=this.props.hasOwnProperty("checked")?this.props.checked:t.checked;this.setState({checked:n})}},{key:"handleTouchStart",value:function(e){this.startX=(0,d.pointerCoord)(e).x,this.activated=!0}},{key:"handleTouchMove",value:function(e){if(this.activated&&(this.moved=!0,this.startX)){var t=(0,d.pointerCoord)(e).x;this.state.checked&&t+15<this.startX?(this.setState({checked:!1}),this.startX=t,this.activated=!0):t-15>this.startX&&(this.setState({checked:!0}),this.startX=t,this.activated=t<this.startX+5)}}},{key:"handleTouchEnd",value:function(e){if(this.moved){var t=this.input;if(e.preventDefault(),this.startX){var n=(0,d.pointerCoord)(e).x;!0===this.previouslyChecked&&this.startX+4>n?this.previouslyChecked!==this.state.checked&&(this.setState({checked:!1}),this.previouslyChecked=this.state.checked,t.click()):this.startX-4<n&&this.previouslyChecked!==this.state.checked&&(this.setState({checked:!0}),this.previouslyChecked=this.state.checked,t.click()),this.activated=!1,this.startX=null,this.moved=!1}}}},{key:"handleFocus",value:function(e){var t=this.props.onFocus;t&&t(e),this.setState({hasFocus:!0})}},{key:"handleBlur",value:function(e){var t=this.props.onBlur;t&&t(e),this.setState({hasFocus:!1})}},{key:"getIcon",value:function(e){var n=this.props.icons;return n?void 0===n[e]?t.defaultProps.icons[e]:n[e]:null}},{key:"render",value:function(){var e=this,t=this.props,n=t.className,i=(t.icons,function(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}(t,["className","icons"])),a=(0,s.default)("react-toggle",{"react-toggle--checked":this.state.checked,"react-toggle--focus":this.state.hasFocus,"react-toggle--disabled":this.props.disabled},n);return o.default.createElement("div",{className:a,onClick:this.handleClick,onTouchStart:this.handleTouchStart,onTouchMove:this.handleTouchMove,onTouchEnd:this.handleTouchEnd},o.default.createElement("div",{className:"react-toggle-track"},o.default.createElement("div",{className:"react-toggle-track-check"},this.getIcon("checked")),o.default.createElement("div",{className:"react-toggle-track-x"},this.getIcon("unchecked"))),o.default.createElement("div",{className:"react-toggle-thumb"}),o.default.createElement("input",r({},i,{ref:function(t){e.input=t},onFocus:this.handleFocus,onBlur:this.handleBlur,className:"react-toggle-screenreader-only",type:"checkbox"})))}}]),t}(a.PureComponent);t.default=f,f.displayName="Toggle",f.defaultProps={icons:{checked:o.default.createElement(u.default,null),unchecked:o.default.createElement(l.default,null)}},f.propTypes={checked:c.default.bool,disabled:c.default.bool,defaultChecked:c.default.bool,onChange:c.default.func,onFocus:c.default.func,onBlur:c.default.func,className:c.default.string,name:c.default.string,value:c.default.string,id:c.default.string,"aria-labelledby":c.default.string,"aria-label":c.default.string,icons:c.default.oneOfType([c.default.bool,c.default.shape({checked:c.default.node,unchecked:c.default.node})])}},249:function(e,t,n){var r;!function(){"use strict";var n={}.hasOwnProperty;function i(){for(var e=[],t=0;t<arguments.length;t++){var r=arguments[t];if(r){var a=typeof r;if("string"===a||"number"===a)e.push(r);else if(Array.isArray(r)&&r.length){var o=i.apply(null,r);o&&e.push(o)}else if("object"===a)for(var s in r)n.call(r,s)&&r[s]&&e.push(s)}}return e.join(" ")}e.exports?(i.default=i,e.exports=i):void 0===(r=function(){return i}.apply(t,[]))||(e.exports=r)}()},250:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=n(0),a=(r=i)&&r.__esModule?r:{default:r};t.default=function(){return a.default.createElement("svg",{width:"14",height:"11",viewBox:"0 0 14 11"},a.default.createElement("title",null,"switch-check"),a.default.createElement("path",{d:"M11.264 0L5.26 6.004 2.103 2.847 0 4.95l5.26 5.26 8.108-8.107L11.264 0",fill:"#fff",fillRule:"evenodd"}))}},251:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=n(0),a=(r=i)&&r.__esModule?r:{default:r};t.default=function(){return a.default.createElement("svg",{width:"10",height:"10",viewBox:"0 0 10 10"},a.default.createElement("title",null,"switch-x"),a.default.createElement("path",{d:"M9.9 2.12L7.78 0 4.95 2.828 2.12 0 0 2.12l2.83 2.83L0 7.776 2.123 9.9 4.95 7.07 7.78 9.9 9.9 7.776 7.072 4.95 9.9 2.12",fill:"#fff",fillRule:"evenodd"}))}},252:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pointerCoord=function(e){if(e){var t=e.changedTouches;if(t&&t.length>0){var n=t[0];return{x:n.clientX,y:n.clientY}}var r=e.pageX;if(void 0!==r)return{x:r,y:e.pageY}}return{x:0,y:0}}},253:function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return u}));var r=n(3),i=n(0),a=n.n(i),o=n(219),s=n(205),c=n(204);function u({label:e,to:t,docsPluginId:n,...i}){var u;const l=Object(s.useActiveVersion)(n),{preferredVersion:d}=Object(c.useDocsPreferredVersion)(n),h=Object(s.useLatestVersion)(n),f=null!==(u=null!=l?l:d)&&void 0!==u?u:h,p=null!=e?e:f.label,m=null!=t?t:(e=>e.docs.find((t=>t.id===e.mainDocId)))(f).path;return a.a.createElement(o.a,Object(r.a)({},i,{label:p,to:m}))}},254:function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return l}));var r=n(3),i=n(0),a=n.n(i),o=n(219),s=n(205),c=n(204);const u=e=>e.docs.find((t=>t.id===e.mainDocId));function l({mobile:e,docsPluginId:t,dropdownActiveClassDisabled:n,dropdownItemsBefore:i,dropdownItemsAfter:l,...d}){var h,f;const p=Object(s.useActiveDocContext)(t),m=Object(s.useVersions)(t),v=Object(s.useLatestVersion)(t),{preferredVersion:g,savePreferredVersionName:y}=Object(c.useDocsPreferredVersion)(t);const b=null!==(h=null!==(f=p.activeVersion)&&void 0!==f?f:g)&&void 0!==h?h:v,E=e?"Versions":b.label,x=e?void 0:u(b).path;return a.a.createElement(o.a,Object(r.a)({},d,{mobile:e,label:E,to:x,items:function(){const e=m.map((e=>{const t=(null==p?void 0:p.alternateDocVersions[e.name])||u(e);return{isNavLink:!0,label:e.label,to:t.path,isActive:()=>e===(null==p?void 0:p.activeVersion),onClick:()=>{y(e.name)}}})),t=[...i,...e,...l];if(!(t.length<=1))return t}(),isActive:n?()=>!1:void 0}))}},255:function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return l}));var r=n(3),i=n(0),a=n.n(i),o=n(219),s=n(205),c=n(200),u=n(204);function l({docId:e,activeSidebarClassName:t,label:n,docsPluginId:i,...l}){var d;const{activeVersion:h,activeDoc:f}=Object(s.useActiveDocContext)(i),{preferredVersion:p}=Object(u.useDocsPreferredVersion)(i),m=Object(s.useLatestVersion)(i),v=null!==(d=null!=h?h:p)&&void 0!==d?d:m,g=v.docs.find((t=>t.id===e));if(!g)throw new Error(`DocNavbarItem: couldn't find any doc with id=${e} in version ${v.name}.\nAvailable docIds=\n- ${v.docs.join("\n- ")}`);return a.a.createElement(o.a,Object(r.a)({exact:!0},l,{className:Object(c.a)(l.className,{[t]:f&&f.sidebar===g.sidebar}),label:null!=n?n:g.id,to:g.path}))}}}]);