From 2a18f941e11b9af97980f19a74f06293c394dea4 Mon Sep 17 00:00:00 2001 From: Tushar Pandey Date: Tue, 21 Jan 2025 15:40:58 +0530 Subject: [PATCH] Release v2.3.0 --- .version | 2 +- CHANGELOG.md | 35 +++++++ docs/assets/highlight.css | 7 -- docs/assets/icons.js | 15 +++ docs/assets/icons.svg | 1 + docs/assets/main.js | 8 +- docs/assets/navigation.js | 2 +- docs/assets/search.js | 2 +- docs/assets/style.css | 62 +++++++----- docs/classes/AuthenticationError.html | 34 +++---- docs/classes/GenericError.html | 30 +++--- docs/classes/InMemoryCache.html | 6 +- docs/classes/LocalStorageCache.html | 12 +-- docs/classes/MfaRequiredError.html | 32 +++---- docs/classes/MissingRefreshTokenError.html | 34 +++---- docs/classes/OAuthError.html | 28 +++--- docs/classes/PopupCancelledError.html | 32 +++---- docs/classes/PopupTimeoutError.html | 32 +++---- docs/classes/TimeoutError.html | 30 +++--- docs/classes/User.html | 44 ++++----- docs/functions/Auth0Context.html | 10 ++ docs/functions/Auth0Provider.html | 4 +- docs/functions/useAuth0.html | 4 +- docs/functions/withAuth0.html | 4 +- .../functions/withAuthenticationRequired.html | 4 +- docs/hierarchy.html | 1 + docs/index.html | 4 +- docs/interfaces/Auth0ContextInterface.html | 78 +++++---------- docs/interfaces/Auth0ProviderOptions.html | 96 +++++++++---------- docs/interfaces/AuthorizationParams.html | 58 +++++------ docs/interfaces/GetTokenSilentlyOptions.html | 18 ++-- docs/interfaces/GetTokenWithPopupOptions.html | 10 +- docs/interfaces/ICache.html | 10 +- docs/interfaces/IdToken.html | 78 +++++++-------- docs/interfaces/LogoutOptions.html | 16 ++-- docs/interfaces/LogoutUrlOptions.html | 10 +- docs/interfaces/PopupConfigOptions.html | 10 +- docs/interfaces/PopupLoginOptions.html | 6 +- docs/interfaces/RedirectLoginOptions.html | 20 ++-- docs/interfaces/WithAuth0Props.html | 6 +- .../WithAuthenticationRequiredOptions.html | 24 ++--- docs/modules.html | 68 ++++++------- docs/types/AppState.html | 4 +- docs/types/CacheLocation.html | 4 +- docs/types/Cacheable.html | 2 +- docs/variables/Auth0Context.html | 2 - package-lock.json | 4 +- package.json | 2 +- 48 files changed, 523 insertions(+), 482 deletions(-) create mode 100644 docs/assets/icons.js create mode 100644 docs/assets/icons.svg create mode 100644 docs/functions/Auth0Context.html create mode 100644 docs/hierarchy.html delete mode 100644 docs/variables/Auth0Context.html diff --git a/.version b/.version index 15274788..a6316f06 100644 --- a/.version +++ b/.version @@ -1 +1 @@ -v2.2.4 \ No newline at end of file +v2.3.0 \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 899a2fbf..9b11d7e9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,40 @@ # Change Log +## [v2.3.0](https://github.com/auth0/auth0-react/tree/v2.3.0) (2025-01-21) +[Full Changelog](https://github.com/auth0/auth0-react/compare/v2.2.4...v2.3.0) + +**Added** +- Release v2.3.0 [\#825](https://github.com/auth0/auth0-react/pull/825) ([tusharpandey13](https://github.com/tusharpandey13)) +- Feature/react19 [\#824](https://github.com/auth0/auth0-react/pull/824) ([tusharpandey13](https://github.com/tusharpandey13)) +- Add ReversingLabs Workflow (Don't Merge) [\#782](https://github.com/auth0/auth0-react/pull/782) ([developerkunal](https://github.com/developerkunal)) + +**Changed** +- ci: changed pull_request_target to pull_request and removed the authorize step [\#796](https://github.com/auth0/auth0-react/pull/796) ([desusai7](https://github.com/desusai7)) +- Bump @testing-library/react from 14.1.2 to 14.3.1 [\#757](https://github.com/auth0/auth0-react/pull/757) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump ts-jest from 29.1.1 to 29.1.5 [\#766](https://github.com/auth0/auth0-react/pull/766) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump cypress from 13.6.1 to 13.12.0 [\#770](https://github.com/auth0/auth0-react/pull/770) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump @types/jest from 29.5.11 to 29.5.12 [\#750](https://github.com/auth0/auth0-react/pull/750) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump @types/react from 18.2.45 to 18.2.64 [\#747](https://github.com/auth0/auth0-react/pull/747) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump browserstack-cypress-cli from 1.28.0 to 1.28.1 [\#715](https://github.com/auth0/auth0-react/pull/715) ([dependabot[bot]](https://github.com/apps/dependabot)) + +**Fixed** +- fix npm release workflow [\#826](https://github.com/auth0/auth0-react/pull/826) ([tusharpandey13](https://github.com/tusharpandey13)) +- Update codeowner file with new GitHub team name [\#790](https://github.com/auth0/auth0-react/pull/790) ([stevenwong-okta](https://github.com/stevenwong-okta)) +- Workaround for failing "integration test (CRA)" [\#769](https://github.com/auth0/auth0-react/pull/769) ([nandan-bhat](https://github.com/nandan-bhat)) + +**Removed** +- Revert "Release v2.3.0" [\#827](https://github.com/auth0/auth0-react/pull/827) ([tusharpandey13](https://github.com/tusharpandey13)) + +**Security** +- Bump pretty-quick from 3.1.3 to 3.3.1 [\#736](https://github.com/auth0/auth0-react/pull/736) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump next from 13.5.6 to 14.1.1 in /examples/nextjs-app [\#761](https://github.com/auth0/auth0-react/pull/761) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump jose from 4.11.0 to 4.15.5 in /examples/users-api [\#749](https://github.com/auth0/auth0-react/pull/749) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump express from 4.18.2 to 4.19.2 in /examples/users-api [\#754](https://github.com/auth0/auth0-react/pull/754) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump follow-redirects from 1.15.3 to 1.15.6 [\#752](https://github.com/auth0/auth0-react/pull/752) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump ws from 7.5.9 to 7.5.10 [\#768](https://github.com/auth0/auth0-react/pull/768) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump braces from 3.0.2 to 3.0.3 [\#773](https://github.com/auth0/auth0-react/pull/773) ([dependabot[bot]](https://github.com/apps/dependabot)) +- Bump oidc-provider from 8.4.3 to 8.4.5 [\#720](https://github.com/auth0/auth0-react/pull/720) ([dependabot[bot]](https://github.com/apps/dependabot)) + ## [v2.2.4](https://github.com/auth0/auth0-react/tree/v2.2.4) (2023-12-11) [Full Changelog](https://github.com/auth0/auth0-react/compare/v2.2.3...v2.2.4) diff --git a/docs/assets/highlight.css b/docs/assets/highlight.css index d00268d5..7034103c 100644 --- a/docs/assets/highlight.css +++ b/docs/assets/highlight.css @@ -27,8 +27,6 @@ --dark-hl-12: #569CD6; --light-hl-13: #098658; --dark-hl-13: #B5CEA8; - --light-hl-14: #CD3131; - --dark-hl-14: #F44747; --light-code-background: #FFFFFF; --dark-code-background: #1E1E1E; } @@ -48,7 +46,6 @@ --hl-11: var(--light-hl-11); --hl-12: var(--light-hl-12); --hl-13: var(--light-hl-13); - --hl-14: var(--light-hl-14); --code-background: var(--light-code-background); } } @@ -67,7 +64,6 @@ --hl-11: var(--dark-hl-11); --hl-12: var(--dark-hl-12); --hl-13: var(--dark-hl-13); - --hl-14: var(--dark-hl-14); --code-background: var(--dark-code-background); } } @@ -86,7 +82,6 @@ --hl-11: var(--light-hl-11); --hl-12: var(--light-hl-12); --hl-13: var(--light-hl-13); - --hl-14: var(--light-hl-14); --code-background: var(--light-code-background); } @@ -105,7 +100,6 @@ --hl-11: var(--dark-hl-11); --hl-12: var(--dark-hl-12); --hl-13: var(--dark-hl-13); - --hl-14: var(--dark-hl-14); --code-background: var(--dark-code-background); } @@ -123,5 +117,4 @@ .hl-11 { color: var(--hl-11); } .hl-12 { color: var(--hl-12); } .hl-13 { color: var(--hl-13); } -.hl-14 { color: var(--hl-14); } pre, code { background: var(--code-background); } diff --git a/docs/assets/icons.js b/docs/assets/icons.js new file mode 100644 index 00000000..b79c9e89 --- /dev/null +++ b/docs/assets/icons.js @@ -0,0 +1,15 @@ +(function(svg) { + svg.innerHTML = ``; + svg.style.display = 'none'; + if (location.protocol === 'file:') { + if (document.readyState === 'loading') document.addEventListener('DOMContentLoaded', updateUseElements); + else updateUseElements() + function updateUseElements() { + document.querySelectorAll('use').forEach(el => { + if (el.getAttribute('href').includes('#icon-')) { + el.setAttribute('href', el.getAttribute('href').replace(/.*#/, '#')); + } + }); + } + } +})(document.body.appendChild(document.createElementNS('http://www.w3.org/2000/svg', 'svg'))) \ No newline at end of file diff --git a/docs/assets/icons.svg b/docs/assets/icons.svg new file mode 100644 index 00000000..7dead611 --- /dev/null +++ b/docs/assets/icons.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/assets/main.js b/docs/assets/main.js index d0aa8d5f..d6f13886 100644 --- a/docs/assets/main.js +++ b/docs/assets/main.js @@ -1,8 +1,8 @@ "use strict"; -"use strict";(()=>{var Pe=Object.create;var ne=Object.defineProperty;var Ie=Object.getOwnPropertyDescriptor;var Oe=Object.getOwnPropertyNames;var _e=Object.getPrototypeOf,Re=Object.prototype.hasOwnProperty;var Me=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Fe=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Oe(e))!Re.call(t,i)&&i!==n&&ne(t,i,{get:()=>e[i],enumerable:!(r=Ie(e,i))||r.enumerable});return t};var De=(t,e,n)=>(n=t!=null?Pe(_e(t)):{},Fe(e||!t||!t.__esModule?ne(n,"default",{value:t,enumerable:!0}):n,t));var ae=Me((se,oe)=>{(function(){var t=function(e){var n=new t.Builder;return n.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),n.searchPipeline.add(t.stemmer),e.call(n,n),n.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){return function(n){e.console&&console.warn&&console.warn(n)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var n=Object.create(null),r=Object.keys(e),i=0;i0){var d=t.utils.clone(n)||{};d.position=[a,u],d.index=s.length,s.push(new t.Token(r.slice(a,o),d))}a=o+1}}return s},t.tokenizer.separator=/[\s\-]+/;t.Pipeline=function(){this._stack=[]},t.Pipeline.registeredFunctions=Object.create(null),t.Pipeline.registerFunction=function(e,n){n in this.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+n),e.label=n,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){var n=e.label&&e.label in this.registeredFunctions;n||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index. -`,e)},t.Pipeline.load=function(e){var n=new t.Pipeline;return e.forEach(function(r){var i=t.Pipeline.registeredFunctions[r];if(i)n.add(i);else throw new Error("Cannot load unregistered function: "+r)}),n},t.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach(function(n){t.Pipeline.warnIfFunctionNotRegistered(n),this._stack.push(n)},this)},t.Pipeline.prototype.after=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");r=r+1,this._stack.splice(r,0,n)},t.Pipeline.prototype.before=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");this._stack.splice(r,0,n)},t.Pipeline.prototype.remove=function(e){var n=this._stack.indexOf(e);n!=-1&&this._stack.splice(n,1)},t.Pipeline.prototype.run=function(e){for(var n=this._stack.length,r=0;r1&&(oe&&(r=s),o!=e);)i=r-n,s=n+Math.floor(i/2),o=this.elements[s*2];if(o==e||o>e)return s*2;if(ol?d+=2:a==l&&(n+=r[u+1]*i[d+1],u+=2,d+=2);return n},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),n=1,r=0;n0){var o=s.str.charAt(0),a;o in s.node.edges?a=s.node.edges[o]:(a=new t.TokenSet,s.node.edges[o]=a),s.str.length==1&&(a.final=!0),i.push({node:a,editsRemaining:s.editsRemaining,str:s.str.slice(1)})}if(s.editsRemaining!=0){if("*"in s.node.edges)var l=s.node.edges["*"];else{var l=new t.TokenSet;s.node.edges["*"]=l}if(s.str.length==0&&(l.final=!0),i.push({node:l,editsRemaining:s.editsRemaining-1,str:s.str}),s.str.length>1&&i.push({node:s.node,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)}),s.str.length==1&&(s.node.final=!0),s.str.length>=1){if("*"in s.node.edges)var u=s.node.edges["*"];else{var u=new t.TokenSet;s.node.edges["*"]=u}s.str.length==1&&(u.final=!0),i.push({node:u,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)})}if(s.str.length>1){var d=s.str.charAt(0),v=s.str.charAt(1),f;v in s.node.edges?f=s.node.edges[v]:(f=new t.TokenSet,s.node.edges[v]=f),s.str.length==1&&(f.final=!0),i.push({node:f,editsRemaining:s.editsRemaining-1,str:d+s.str.slice(2)})}}}return r},t.TokenSet.fromString=function(e){for(var n=new t.TokenSet,r=n,i=0,s=e.length;i=e;n--){var r=this.uncheckedNodes[n],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.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(n){var r=new t.QueryParser(e,n);r.parse()})},t.Index.prototype.query=function(e){for(var n=new t.Query(this.fields),r=Object.create(null),i=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),l=0;l1?this._b=1:this._b=e},t.Builder.prototype.k1=function(e){this._k1=e},t.Builder.prototype.add=function(e,n){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=n||{},this.documentCount+=1;for(var s=0;s=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,n;do e=this.next(),n=e.charCodeAt(0);while(n>47&&n<58);e!=t.QueryLexer.EOS&&this.backup()},t.QueryLexer.prototype.more=function(){return this.pos1&&(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 n=e.next();if(n==t.QueryLexer.EOS)return t.QueryLexer.lexEOS;if(n.charCodeAt(0)==92){e.escapeCharacter();continue}if(n==":")return t.QueryLexer.lexField;if(n=="~")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexEditDistance;if(n=="^")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexBoost;if(n=="+"&&e.width()===1||n=="-"&&e.width()===1)return e.emit(t.QueryLexer.PRESENCE),t.QueryLexer.lexText;if(n.match(t.QueryLexer.termSeparator))return t.QueryLexer.lexTerm}},t.QueryParser=function(e,n){this.lexer=new t.QueryLexer(e),this.query=n,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 n=e.peekLexeme();if(n!=null)switch(n.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 r="expected either a field or a term, found "+n.type;throw n.str.length>=1&&(r+=" with value '"+n.str+"'"),new t.QueryParseError(r,n.start,n.end)}},t.QueryParser.parsePresence=function(e){var n=e.consumeLexeme();if(n!=null){switch(n.str){case"-":e.currentClause.presence=t.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=t.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator'"+n.str+"'";throw new t.QueryParseError(r,n.start,n.end)}var i=e.peekLexeme();if(i==null){var r="expecting term or field, found nothing";throw new t.QueryParseError(r,n.start,n.end)}switch(i.type){case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expecting term or field, found '"+i.type+"'";throw new t.QueryParseError(r,i.start,i.end)}}},t.QueryParser.parseField=function(e){var n=e.consumeLexeme();if(n!=null){if(e.query.allFields.indexOf(n.str)==-1){var r=e.query.allFields.map(function(o){return"'"+o+"'"}).join(", "),i="unrecognised field '"+n.str+"', possible fields: "+r;throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.fields=[n.str];var s=e.peekLexeme();if(s==null){var i="expecting term, found nothing";throw new t.QueryParseError(i,n.start,n.end)}switch(s.type){case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var i="expecting term, found '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseTerm=function(e){var n=e.consumeLexeme();if(n!=null){e.currentClause.term=n.str.toLowerCase(),n.str.indexOf("*")!=-1&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(r==null){e.nextClause();return}switch(r.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 i="Unexpected lexeme type '"+r.type+"'";throw new t.QueryParseError(i,r.start,r.end)}}},t.QueryParser.parseEditDistance=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.editDistance=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.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 i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseBoost=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="boost must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.boost=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.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 i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},function(e,n){typeof define=="function"&&define.amd?define(n):typeof se=="object"?oe.exports=n():e.lunr=n()}(this,function(){return t})})()});var re=[];function G(t,e){re.push({selector:e,constructor:t})}var U=class{constructor(){this.alwaysVisibleMember=null;this.createComponents(document.body),this.ensureActivePageVisible(),this.ensureFocusedElementVisible(),this.listenForCodeCopies(),window.addEventListener("hashchange",()=>this.ensureFocusedElementVisible())}createComponents(e){re.forEach(n=>{e.querySelectorAll(n.selector).forEach(r=>{r.dataset.hasInstance||(new n.constructor({el:r,app:this}),r.dataset.hasInstance=String(!0))})})}filterChanged(){this.ensureFocusedElementVisible()}ensureActivePageVisible(){let e=document.querySelector(".tsd-navigation .current"),n=e?.parentElement;for(;n&&!n.classList.contains(".tsd-navigation");)n instanceof HTMLDetailsElement&&(n.open=!0),n=n.parentElement;if(e){let r=e.getBoundingClientRect().top-document.documentElement.clientHeight/4;document.querySelector(".site-menu").scrollTop=r}}ensureFocusedElementVisible(){if(this.alwaysVisibleMember&&(this.alwaysVisibleMember.classList.remove("always-visible"),this.alwaysVisibleMember.firstElementChild.remove(),this.alwaysVisibleMember=null),!location.hash)return;let e=document.getElementById(location.hash.substring(1));if(!e)return;let n=e.parentElement;for(;n&&n.tagName!=="SECTION";)n=n.parentElement;if(n&&n.offsetParent==null){this.alwaysVisibleMember=n,n.classList.add("always-visible");let r=document.createElement("p");r.classList.add("warning"),r.textContent="This member is normally hidden due to your filter settings.",n.prepend(r)}}listenForCodeCopies(){document.querySelectorAll("pre > button").forEach(e=>{let n;e.addEventListener("click",()=>{e.previousElementSibling instanceof HTMLElement&&navigator.clipboard.writeText(e.previousElementSibling.innerText.trim()),e.textContent="Copied!",e.classList.add("visible"),clearTimeout(n),n=setTimeout(()=>{e.classList.remove("visible"),n=setTimeout(()=>{e.textContent="Copy"},100)},1e3)})})}};var ie=(t,e=100)=>{let n;return()=>{clearTimeout(n),n=setTimeout(()=>t(),e)}};var de=De(ae());async function le(t,e){if(!window.searchData)return;let n=await fetch(window.searchData),r=new Blob([await n.arrayBuffer()]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();t.data=i,t.index=de.Index.load(i.index),e.classList.remove("loading"),e.classList.add("ready")}function he(){let t=document.getElementById("tsd-search");if(!t)return;let e={base:t.dataset.base+"/"},n=document.getElementById("tsd-search-script");t.classList.add("loading"),n&&(n.addEventListener("error",()=>{t.classList.remove("loading"),t.classList.add("failure")}),n.addEventListener("load",()=>{le(e,t)}),le(e,t));let r=document.querySelector("#tsd-search input"),i=document.querySelector("#tsd-search .results");if(!r||!i)throw new Error("The input field or the result list wrapper was not found");let s=!1;i.addEventListener("mousedown",()=>s=!0),i.addEventListener("mouseup",()=>{s=!1,t.classList.remove("has-focus")}),r.addEventListener("focus",()=>t.classList.add("has-focus")),r.addEventListener("blur",()=>{s||(s=!1,t.classList.remove("has-focus"))}),Ae(t,i,r,e)}function Ae(t,e,n,r){n.addEventListener("input",ie(()=>{Ne(t,e,n,r)},200));let i=!1;n.addEventListener("keydown",s=>{i=!0,s.key=="Enter"?Ve(e,n):s.key=="Escape"?n.blur():s.key=="ArrowUp"?ue(e,-1):s.key==="ArrowDown"?ue(e,1):i=!1}),n.addEventListener("keypress",s=>{i&&s.preventDefault()}),document.body.addEventListener("keydown",s=>{s.altKey||s.ctrlKey||s.metaKey||!n.matches(":focus")&&s.key==="/"&&(n.focus(),s.preventDefault())})}function Ne(t,e,n,r){if(!r.index||!r.data)return;e.textContent="";let i=n.value.trim(),s;if(i){let o=i.split(" ").map(a=>a.length?`*${a}*`:"").join(" ");s=r.index.search(o)}else s=[];for(let o=0;oa.score-o.score);for(let o=0,a=Math.min(10,s.length);o`,d=ce(l.name,i);globalThis.DEBUG_SEARCH_WEIGHTS&&(d+=` (score: ${s[o].score.toFixed(2)})`),l.parent&&(d=` - ${ce(l.parent,i)}.${d}`);let v=document.createElement("li");v.classList.value=l.classes??"";let f=document.createElement("a");f.href=r.base+l.url,f.innerHTML=u+d,v.append(f),e.appendChild(v)}}function ue(t,e){let n=t.querySelector(".current");if(!n)n=t.querySelector(e==1?"li:first-child":"li:last-child"),n&&n.classList.add("current");else{let r=n;if(e===1)do r=r.nextElementSibling??void 0;while(r instanceof HTMLElement&&r.offsetParent==null);else do r=r.previousElementSibling??void 0;while(r instanceof HTMLElement&&r.offsetParent==null);r&&(n.classList.remove("current"),r.classList.add("current"))}}function Ve(t,e){let n=t.querySelector(".current");if(n||(n=t.querySelector("li:first-child")),n){let r=n.querySelector("a");r&&(window.location.href=r.href),e.blur()}}function ce(t,e){if(e==="")return t;let n=t.toLocaleLowerCase(),r=e.toLocaleLowerCase(),i=[],s=0,o=n.indexOf(r);for(;o!=-1;)i.push(K(t.substring(s,o)),`${K(t.substring(o,o+r.length))}`),s=o+r.length,o=n.indexOf(r,s);return i.push(K(t.substring(s))),i.join("")}var Be={"&":"&","<":"<",">":">","'":"'",'"':"""};function K(t){return t.replace(/[&<>"'"]/g,e=>Be[e])}var C=class{constructor(e){this.el=e.el,this.app=e.app}};var F="mousedown",pe="mousemove",B="mouseup",J={x:0,y:0},fe=!1,ee=!1,He=!1,D=!1,me=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);document.documentElement.classList.add(me?"is-mobile":"not-mobile");me&&"ontouchstart"in document.documentElement&&(He=!0,F="touchstart",pe="touchmove",B="touchend");document.addEventListener(F,t=>{ee=!0,D=!1;let e=F=="touchstart"?t.targetTouches[0]:t;J.y=e.pageY||0,J.x=e.pageX||0});document.addEventListener(pe,t=>{if(ee&&!D){let e=F=="touchstart"?t.targetTouches[0]:t,n=J.x-(e.pageX||0),r=J.y-(e.pageY||0);D=Math.sqrt(n*n+r*r)>10}});document.addEventListener(B,()=>{ee=!1});document.addEventListener("click",t=>{fe&&(t.preventDefault(),t.stopImmediatePropagation(),fe=!1)});var X=class extends C{constructor(n){super(n);this.className=this.el.dataset.toggle||"",this.el.addEventListener(B,r=>this.onPointerUp(r)),this.el.addEventListener("click",r=>r.preventDefault()),document.addEventListener(F,r=>this.onDocumentPointerDown(r)),document.addEventListener(B,r=>this.onDocumentPointerUp(r))}setActive(n){if(this.active==n)return;this.active=n,document.documentElement.classList.toggle("has-"+this.className,n),this.el.classList.toggle("active",n);let r=(this.active?"to-has-":"from-has-")+this.className;document.documentElement.classList.add(r),setTimeout(()=>document.documentElement.classList.remove(r),500)}onPointerUp(n){D||(this.setActive(!0),n.preventDefault())}onDocumentPointerDown(n){if(this.active){if(n.target.closest(".col-sidebar, .tsd-filter-group"))return;this.setActive(!1)}}onDocumentPointerUp(n){if(!D&&this.active&&n.target.closest(".col-sidebar")){let r=n.target.closest("a");if(r){let i=window.location.href;i.indexOf("#")!=-1&&(i=i.substring(0,i.indexOf("#"))),r.href.substring(0,i.length)==i&&setTimeout(()=>this.setActive(!1),250)}}}};var te;try{te=localStorage}catch{te={getItem(){return null},setItem(){}}}var Q=te;var ve=document.head.appendChild(document.createElement("style"));ve.dataset.for="filters";var Y=class extends C{constructor(n){super(n);this.key=`filter-${this.el.name}`,this.value=this.el.checked,this.el.addEventListener("change",()=>{this.setLocalStorage(this.el.checked)}),this.setLocalStorage(this.fromLocalStorage()),ve.innerHTML+=`html:not(.${this.key}) .tsd-is-${this.el.name} { display: none; } -`}fromLocalStorage(){let n=Q.getItem(this.key);return n?n==="true":this.el.checked}setLocalStorage(n){Q.setItem(this.key,n.toString()),this.value=n,this.handleValueChange()}handleValueChange(){this.el.checked=this.value,document.documentElement.classList.toggle(this.key,this.value),this.app.filterChanged(),document.querySelectorAll(".tsd-index-section").forEach(n=>{n.style.display="block";let r=Array.from(n.querySelectorAll(".tsd-index-link")).every(i=>i.offsetParent==null);n.style.display=r?"none":"block"})}};var Z=class extends C{constructor(n){super(n);this.summary=this.el.querySelector(".tsd-accordion-summary"),this.icon=this.summary.querySelector("svg"),this.key=`tsd-accordion-${this.summary.dataset.key??this.summary.textContent.trim().replace(/\s+/g,"-").toLowerCase()}`;let r=Q.getItem(this.key);this.el.open=r?r==="true":this.el.open,this.el.addEventListener("toggle",()=>this.update());let i=this.summary.querySelector("a");i&&i.addEventListener("click",()=>{location.assign(i.href)}),this.update()}update(){this.icon.style.transform=`rotate(${this.el.open?0:-90}deg)`,Q.setItem(this.key,this.el.open.toString())}};function ge(t){let e=Q.getItem("tsd-theme")||"os";t.value=e,ye(e),t.addEventListener("change",()=>{Q.setItem("tsd-theme",t.value),ye(t.value)})}function ye(t){document.documentElement.dataset.theme=t}var Le;function be(){let t=document.getElementById("tsd-nav-script");t&&(t.addEventListener("load",xe),xe())}async function xe(){let t=document.getElementById("tsd-nav-container");if(!t||!window.navigationData)return;let n=await(await fetch(window.navigationData)).arrayBuffer(),r=new Blob([n]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();Le=t.dataset.base+"/",t.innerHTML="";for(let s of i)we(s,t,[]);window.app.createComponents(t),window.app.ensureActivePageVisible()}function we(t,e,n){let r=e.appendChild(document.createElement("li"));if(t.children){let i=[...n,t.text],s=r.appendChild(document.createElement("details"));s.className=t.class?`${t.class} tsd-index-accordion`:"tsd-index-accordion",s.dataset.key=i.join("$");let o=s.appendChild(document.createElement("summary"));o.className="tsd-accordion-summary",o.innerHTML='',Ee(t,o);let a=s.appendChild(document.createElement("div"));a.className="tsd-accordion-details";let l=a.appendChild(document.createElement("ul"));l.className="tsd-nested-navigation";for(let u of t.children)we(u,l,i)}else Ee(t,r,t.class)}function Ee(t,e,n){if(t.path){let r=e.appendChild(document.createElement("a"));r.href=Le+t.path,n&&(r.className=n),location.href===r.href&&r.classList.add("current"),t.kind&&(r.innerHTML=``),r.appendChild(document.createElement("span")).textContent=t.text}else e.appendChild(document.createElement("span")).textContent=t.text}G(X,"a[data-toggle]");G(Z,".tsd-index-accordion");G(Y,".tsd-filter-item input[type=checkbox]");var Se=document.getElementById("tsd-theme");Se&&ge(Se);var je=new U;Object.defineProperty(window,"app",{value:je});he();be();})(); +"use strict";(()=>{var Ce=Object.create;var ne=Object.defineProperty;var Pe=Object.getOwnPropertyDescriptor;var Oe=Object.getOwnPropertyNames;var _e=Object.getPrototypeOf,Re=Object.prototype.hasOwnProperty;var Me=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Fe=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Oe(e))!Re.call(t,i)&&i!==n&&ne(t,i,{get:()=>e[i],enumerable:!(r=Pe(e,i))||r.enumerable});return t};var De=(t,e,n)=>(n=t!=null?Ce(_e(t)):{},Fe(e||!t||!t.__esModule?ne(n,"default",{value:t,enumerable:!0}):n,t));var ae=Me((se,oe)=>{(function(){var t=function(e){var n=new t.Builder;return n.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),n.searchPipeline.add(t.stemmer),e.call(n,n),n.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){return function(n){e.console&&console.warn&&console.warn(n)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var n=Object.create(null),r=Object.keys(e),i=0;i0){var d=t.utils.clone(n)||{};d.position=[a,u],d.index=s.length,s.push(new t.Token(r.slice(a,o),d))}a=o+1}}return s},t.tokenizer.separator=/[\s\-]+/;t.Pipeline=function(){this._stack=[]},t.Pipeline.registeredFunctions=Object.create(null),t.Pipeline.registerFunction=function(e,n){n in this.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+n),e.label=n,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){var n=e.label&&e.label in this.registeredFunctions;n||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index. +`,e)},t.Pipeline.load=function(e){var n=new t.Pipeline;return e.forEach(function(r){var i=t.Pipeline.registeredFunctions[r];if(i)n.add(i);else throw new Error("Cannot load unregistered function: "+r)}),n},t.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach(function(n){t.Pipeline.warnIfFunctionNotRegistered(n),this._stack.push(n)},this)},t.Pipeline.prototype.after=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");r=r+1,this._stack.splice(r,0,n)},t.Pipeline.prototype.before=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");this._stack.splice(r,0,n)},t.Pipeline.prototype.remove=function(e){var n=this._stack.indexOf(e);n!=-1&&this._stack.splice(n,1)},t.Pipeline.prototype.run=function(e){for(var n=this._stack.length,r=0;r1&&(oe&&(r=s),o!=e);)i=r-n,s=n+Math.floor(i/2),o=this.elements[s*2];if(o==e||o>e)return s*2;if(ol?d+=2:a==l&&(n+=r[u+1]*i[d+1],u+=2,d+=2);return n},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),n=1,r=0;n0){var o=s.str.charAt(0),a;o in s.node.edges?a=s.node.edges[o]:(a=new t.TokenSet,s.node.edges[o]=a),s.str.length==1&&(a.final=!0),i.push({node:a,editsRemaining:s.editsRemaining,str:s.str.slice(1)})}if(s.editsRemaining!=0){if("*"in s.node.edges)var l=s.node.edges["*"];else{var l=new t.TokenSet;s.node.edges["*"]=l}if(s.str.length==0&&(l.final=!0),i.push({node:l,editsRemaining:s.editsRemaining-1,str:s.str}),s.str.length>1&&i.push({node:s.node,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)}),s.str.length==1&&(s.node.final=!0),s.str.length>=1){if("*"in s.node.edges)var u=s.node.edges["*"];else{var u=new t.TokenSet;s.node.edges["*"]=u}s.str.length==1&&(u.final=!0),i.push({node:u,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)})}if(s.str.length>1){var d=s.str.charAt(0),y=s.str.charAt(1),p;y in s.node.edges?p=s.node.edges[y]:(p=new t.TokenSet,s.node.edges[y]=p),s.str.length==1&&(p.final=!0),i.push({node:p,editsRemaining:s.editsRemaining-1,str:d+s.str.slice(2)})}}}return r},t.TokenSet.fromString=function(e){for(var n=new t.TokenSet,r=n,i=0,s=e.length;i=e;n--){var r=this.uncheckedNodes[n],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.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(n){var r=new t.QueryParser(e,n);r.parse()})},t.Index.prototype.query=function(e){for(var n=new t.Query(this.fields),r=Object.create(null),i=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),l=0;l1?this._b=1:this._b=e},t.Builder.prototype.k1=function(e){this._k1=e},t.Builder.prototype.add=function(e,n){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=n||{},this.documentCount+=1;for(var s=0;s=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,n;do e=this.next(),n=e.charCodeAt(0);while(n>47&&n<58);e!=t.QueryLexer.EOS&&this.backup()},t.QueryLexer.prototype.more=function(){return this.pos1&&(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 n=e.next();if(n==t.QueryLexer.EOS)return t.QueryLexer.lexEOS;if(n.charCodeAt(0)==92){e.escapeCharacter();continue}if(n==":")return t.QueryLexer.lexField;if(n=="~")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexEditDistance;if(n=="^")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexBoost;if(n=="+"&&e.width()===1||n=="-"&&e.width()===1)return e.emit(t.QueryLexer.PRESENCE),t.QueryLexer.lexText;if(n.match(t.QueryLexer.termSeparator))return t.QueryLexer.lexTerm}},t.QueryParser=function(e,n){this.lexer=new t.QueryLexer(e),this.query=n,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 n=e.peekLexeme();if(n!=null)switch(n.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 r="expected either a field or a term, found "+n.type;throw n.str.length>=1&&(r+=" with value '"+n.str+"'"),new t.QueryParseError(r,n.start,n.end)}},t.QueryParser.parsePresence=function(e){var n=e.consumeLexeme();if(n!=null){switch(n.str){case"-":e.currentClause.presence=t.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=t.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator'"+n.str+"'";throw new t.QueryParseError(r,n.start,n.end)}var i=e.peekLexeme();if(i==null){var r="expecting term or field, found nothing";throw new t.QueryParseError(r,n.start,n.end)}switch(i.type){case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expecting term or field, found '"+i.type+"'";throw new t.QueryParseError(r,i.start,i.end)}}},t.QueryParser.parseField=function(e){var n=e.consumeLexeme();if(n!=null){if(e.query.allFields.indexOf(n.str)==-1){var r=e.query.allFields.map(function(o){return"'"+o+"'"}).join(", "),i="unrecognised field '"+n.str+"', possible fields: "+r;throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.fields=[n.str];var s=e.peekLexeme();if(s==null){var i="expecting term, found nothing";throw new t.QueryParseError(i,n.start,n.end)}switch(s.type){case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var i="expecting term, found '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseTerm=function(e){var n=e.consumeLexeme();if(n!=null){e.currentClause.term=n.str.toLowerCase(),n.str.indexOf("*")!=-1&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(r==null){e.nextClause();return}switch(r.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 i="Unexpected lexeme type '"+r.type+"'";throw new t.QueryParseError(i,r.start,r.end)}}},t.QueryParser.parseEditDistance=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.editDistance=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.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 i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseBoost=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="boost must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.boost=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.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 i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},function(e,n){typeof define=="function"&&define.amd?define(n):typeof se=="object"?oe.exports=n():e.lunr=n()}(this,function(){return t})})()});var re=[];function G(t,e){re.push({selector:e,constructor:t})}var U=class{constructor(){this.alwaysVisibleMember=null;this.createComponents(document.body),this.ensureFocusedElementVisible(),this.listenForCodeCopies(),window.addEventListener("hashchange",()=>this.ensureFocusedElementVisible()),document.body.style.display||(this.ensureFocusedElementVisible(),this.updateIndexVisibility(),this.scrollToHash())}createComponents(e){re.forEach(n=>{e.querySelectorAll(n.selector).forEach(r=>{r.dataset.hasInstance||(new n.constructor({el:r,app:this}),r.dataset.hasInstance=String(!0))})})}filterChanged(){this.ensureFocusedElementVisible()}showPage(){document.body.style.display&&(console.log("Show page"),document.body.style.removeProperty("display"),this.ensureFocusedElementVisible(),this.updateIndexVisibility(),this.scrollToHash())}scrollToHash(){if(location.hash){console.log("Scorlling");let e=document.getElementById(location.hash.substring(1));if(!e)return;e.scrollIntoView({behavior:"instant",block:"start"})}}ensureActivePageVisible(){let e=document.querySelector(".tsd-navigation .current"),n=e?.parentElement;for(;n&&!n.classList.contains(".tsd-navigation");)n instanceof HTMLDetailsElement&&(n.open=!0),n=n.parentElement;if(e&&!e.checkVisibility()){let r=e.getBoundingClientRect().top-document.documentElement.clientHeight/4;document.querySelector(".site-menu").scrollTop=r}}updateIndexVisibility(){let e=document.querySelector(".tsd-index-content"),n=e?.open;e&&(e.open=!0),document.querySelectorAll(".tsd-index-section").forEach(r=>{r.style.display="block";let i=Array.from(r.querySelectorAll(".tsd-index-link")).every(s=>s.offsetParent==null);r.style.display=i?"none":"block"}),e&&(e.open=n)}ensureFocusedElementVisible(){if(this.alwaysVisibleMember&&(this.alwaysVisibleMember.classList.remove("always-visible"),this.alwaysVisibleMember.firstElementChild.remove(),this.alwaysVisibleMember=null),!location.hash)return;let e=document.getElementById(location.hash.substring(1));if(!e)return;let n=e.parentElement;for(;n&&n.tagName!=="SECTION";)n=n.parentElement;if(n&&n.offsetParent==null){this.alwaysVisibleMember=n,n.classList.add("always-visible");let r=document.createElement("p");r.classList.add("warning"),r.textContent="This member is normally hidden due to your filter settings.",n.prepend(r)}}listenForCodeCopies(){document.querySelectorAll("pre > button").forEach(e=>{let n;e.addEventListener("click",()=>{e.previousElementSibling instanceof HTMLElement&&navigator.clipboard.writeText(e.previousElementSibling.innerText.trim()),e.textContent="Copied!",e.classList.add("visible"),clearTimeout(n),n=setTimeout(()=>{e.classList.remove("visible"),n=setTimeout(()=>{e.textContent="Copy"},100)},1e3)})})}};var ie=(t,e=100)=>{let n;return()=>{clearTimeout(n),n=setTimeout(()=>t(),e)}};var de=De(ae());async function le(t,e){if(!window.searchData)return;let n=await fetch(window.searchData),r=new Blob([await n.arrayBuffer()]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();t.data=i,t.index=de.Index.load(i.index),e.classList.remove("loading"),e.classList.add("ready")}function he(){let t=document.getElementById("tsd-search");if(!t)return;let e={base:t.dataset.base+"/"},n=document.getElementById("tsd-search-script");t.classList.add("loading"),n&&(n.addEventListener("error",()=>{t.classList.remove("loading"),t.classList.add("failure")}),n.addEventListener("load",()=>{le(e,t)}),le(e,t));let r=document.querySelector("#tsd-search input"),i=document.querySelector("#tsd-search .results");if(!r||!i)throw new Error("The input field or the result list wrapper was not found");let s=!1;i.addEventListener("mousedown",()=>s=!0),i.addEventListener("mouseup",()=>{s=!1,t.classList.remove("has-focus")}),r.addEventListener("focus",()=>t.classList.add("has-focus")),r.addEventListener("blur",()=>{s||(s=!1,t.classList.remove("has-focus"))}),Ae(t,i,r,e)}function Ae(t,e,n,r){n.addEventListener("input",ie(()=>{Ve(t,e,n,r)},200));let i=!1;n.addEventListener("keydown",s=>{i=!0,s.key=="Enter"?Ne(e,n):s.key=="Escape"?n.blur():s.key=="ArrowUp"?ue(e,-1):s.key==="ArrowDown"?ue(e,1):i=!1}),n.addEventListener("keypress",s=>{i&&s.preventDefault()}),document.body.addEventListener("keydown",s=>{s.altKey||s.ctrlKey||s.metaKey||!n.matches(":focus")&&s.key==="/"&&(n.focus(),s.preventDefault())})}function Ve(t,e,n,r){if(!r.index||!r.data)return;e.textContent="";let i=n.value.trim(),s;if(i){let o=i.split(" ").map(a=>a.length?`*${a}*`:"").join(" ");s=r.index.search(o)}else s=[];for(let o=0;oa.score-o.score);for(let o=0,a=Math.min(10,s.length);o`,d=ce(l.name,i);globalThis.DEBUG_SEARCH_WEIGHTS&&(d+=` (score: ${s[o].score.toFixed(2)})`),l.parent&&(d=` + ${ce(l.parent,i)}.${d}`);let y=document.createElement("li");y.classList.value=l.classes??"";let p=document.createElement("a");p.href=r.base+l.url,p.innerHTML=u+d,y.append(p),e.appendChild(y)}}function ue(t,e){let n=t.querySelector(".current");if(!n)n=t.querySelector(e==1?"li:first-child":"li:last-child"),n&&n.classList.add("current");else{let r=n;if(e===1)do r=r.nextElementSibling??void 0;while(r instanceof HTMLElement&&r.offsetParent==null);else do r=r.previousElementSibling??void 0;while(r instanceof HTMLElement&&r.offsetParent==null);r&&(n.classList.remove("current"),r.classList.add("current"))}}function Ne(t,e){let n=t.querySelector(".current");if(n||(n=t.querySelector("li:first-child")),n){let r=n.querySelector("a");r&&(window.location.href=r.href),e.blur()}}function ce(t,e){if(e==="")return t;let n=t.toLocaleLowerCase(),r=e.toLocaleLowerCase(),i=[],s=0,o=n.indexOf(r);for(;o!=-1;)i.push(K(t.substring(s,o)),`${K(t.substring(o,o+r.length))}`),s=o+r.length,o=n.indexOf(r,s);return i.push(K(t.substring(s))),i.join("")}var He={"&":"&","<":"<",">":">","'":"'",'"':"""};function K(t){return t.replace(/[&<>"'"]/g,e=>He[e])}var I=class{constructor(e){this.el=e.el,this.app=e.app}};var F="mousedown",fe="mousemove",H="mouseup",J={x:0,y:0},pe=!1,ee=!1,Be=!1,D=!1,me=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);document.documentElement.classList.add(me?"is-mobile":"not-mobile");me&&"ontouchstart"in document.documentElement&&(Be=!0,F="touchstart",fe="touchmove",H="touchend");document.addEventListener(F,t=>{ee=!0,D=!1;let e=F=="touchstart"?t.targetTouches[0]:t;J.y=e.pageY||0,J.x=e.pageX||0});document.addEventListener(fe,t=>{if(ee&&!D){let e=F=="touchstart"?t.targetTouches[0]:t,n=J.x-(e.pageX||0),r=J.y-(e.pageY||0);D=Math.sqrt(n*n+r*r)>10}});document.addEventListener(H,()=>{ee=!1});document.addEventListener("click",t=>{pe&&(t.preventDefault(),t.stopImmediatePropagation(),pe=!1)});var X=class extends I{constructor(e){super(e),this.className=this.el.dataset.toggle||"",this.el.addEventListener(H,n=>this.onPointerUp(n)),this.el.addEventListener("click",n=>n.preventDefault()),document.addEventListener(F,n=>this.onDocumentPointerDown(n)),document.addEventListener(H,n=>this.onDocumentPointerUp(n))}setActive(e){if(this.active==e)return;this.active=e,document.documentElement.classList.toggle("has-"+this.className,e),this.el.classList.toggle("active",e);let n=(this.active?"to-has-":"from-has-")+this.className;document.documentElement.classList.add(n),setTimeout(()=>document.documentElement.classList.remove(n),500)}onPointerUp(e){D||(this.setActive(!0),e.preventDefault())}onDocumentPointerDown(e){if(this.active){if(e.target.closest(".col-sidebar, .tsd-filter-group"))return;this.setActive(!1)}}onDocumentPointerUp(e){if(!D&&this.active&&e.target.closest(".col-sidebar")){let n=e.target.closest("a");if(n){let r=window.location.href;r.indexOf("#")!=-1&&(r=r.substring(0,r.indexOf("#"))),n.href.substring(0,r.length)==r&&setTimeout(()=>this.setActive(!1),250)}}}};var te;try{te=localStorage}catch{te={getItem(){return null},setItem(){}}}var Q=te;var ye=document.head.appendChild(document.createElement("style"));ye.dataset.for="filters";var Y=class extends I{constructor(e){super(e),this.key=`filter-${this.el.name}`,this.value=this.el.checked,this.el.addEventListener("change",()=>{this.setLocalStorage(this.el.checked)}),this.setLocalStorage(this.fromLocalStorage()),ye.innerHTML+=`html:not(.${this.key}) .tsd-is-${this.el.name} { display: none; } +`,this.app.updateIndexVisibility()}fromLocalStorage(){let e=Q.getItem(this.key);return e?e==="true":this.el.checked}setLocalStorage(e){Q.setItem(this.key,e.toString()),this.value=e,this.handleValueChange()}handleValueChange(){this.el.checked=this.value,document.documentElement.classList.toggle(this.key,this.value),this.app.filterChanged(),this.app.updateIndexVisibility()}};var Z=class extends I{constructor(e){super(e),this.summary=this.el.querySelector(".tsd-accordion-summary"),this.icon=this.summary.querySelector("svg"),this.key=`tsd-accordion-${this.summary.dataset.key??this.summary.textContent.trim().replace(/\s+/g,"-").toLowerCase()}`;let n=Q.getItem(this.key);this.el.open=n?n==="true":this.el.open,this.el.addEventListener("toggle",()=>this.update());let r=this.summary.querySelector("a");r&&r.addEventListener("click",()=>{location.assign(r.href)}),this.update()}update(){this.icon.style.transform=`rotate(${this.el.open?0:-90}deg)`,Q.setItem(this.key,this.el.open.toString())}};function ge(t){let e=Q.getItem("tsd-theme")||"os";t.value=e,ve(e),t.addEventListener("change",()=>{Q.setItem("tsd-theme",t.value),ve(t.value)})}function ve(t){document.documentElement.dataset.theme=t}var Le;function be(){let t=document.getElementById("tsd-nav-script");t&&(t.addEventListener("load",xe),xe())}async function xe(){let t=document.getElementById("tsd-nav-container");if(!t||!window.navigationData)return;let n=await(await fetch(window.navigationData)).arrayBuffer(),r=new Blob([n]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();Le=t.dataset.base+"/",t.innerHTML="";for(let s of i)we(s,t,[]);window.app.createComponents(t),window.app.showPage(),window.app.ensureActivePageVisible()}function we(t,e,n){let r=e.appendChild(document.createElement("li"));if(t.children){let i=[...n,t.text],s=r.appendChild(document.createElement("details"));s.className=t.class?`${t.class} tsd-index-accordion`:"tsd-index-accordion",s.dataset.key=i.join("$");let o=s.appendChild(document.createElement("summary"));o.className="tsd-accordion-summary",o.innerHTML='',Ee(t,o);let a=s.appendChild(document.createElement("div"));a.className="tsd-accordion-details";let l=a.appendChild(document.createElement("ul"));l.className="tsd-nested-navigation";for(let u of t.children)we(u,l,i)}else Ee(t,r,t.class)}function Ee(t,e,n){if(t.path){let r=e.appendChild(document.createElement("a"));r.href=Le+t.path,n&&(r.className=n),location.pathname===r.pathname&&r.classList.add("current"),t.kind&&(r.innerHTML=``),r.appendChild(document.createElement("span")).textContent=t.text}else e.appendChild(document.createElement("span")).textContent=t.text}G(X,"a[data-toggle]");G(Z,".tsd-index-accordion");G(Y,".tsd-filter-item input[type=checkbox]");var Se=document.getElementById("tsd-theme");Se&&ge(Se);var je=new U;Object.defineProperty(window,"app",{value:je});he();be();})(); /*! Bundled license information: lunr/lunr.js: diff --git a/docs/assets/navigation.js b/docs/assets/navigation.js index 92f42e54..91076551 100644 --- a/docs/assets/navigation.js +++ b/docs/assets/navigation.js @@ -1 +1 @@ -window.navigationData = "data:application/octet-stream;base64,H4sIAAAAAAAAE6WWXW/TMBSG/0uuO9gKG7A7VCFUadOqdhMXiAvjnDTWXDvYzqAg/jt2Qhon/kjk3lRqzuvnPbGPz8nXP5mCXyq7zT7WqgSmCEaKcPZJCC6yRVYhVeogpkhKkK89olelOlCtfCYsz26vlu8XrVqvUjK/IPJC80EwRLO/i5PbZ2AgCA7Y2NE0/prdw4GL4wrhElyDQTjN4Y5jRHeKC7SHgIsjSXO6L9AWftREQB7Yr7Ei0YdISdh+C4UAWT7yZwiVQUiZ5vtgqirg1McctkXY8KquVohhoDS4SR5RWr4N6JEcgNcq5mVL0pziJufznyR4uOZpGs8c1uWKM/N3rX9FgbB1L0j3qG0kjnJoury+GaM3gr+QHMRDZdqPDJNHwikwF+R309E2SKBDmDvSOdiZrU81N2ZHqG6l9Bh7mYD2POMvRJVNgc5xHovTrNejDmkZrT2dcTY2b3L0c9tYGviO7/XNiu3PQBGrr1b4JOg0rRelZd12OM4Kso+ZubIz7HTmhE262ao0sy3kerxhNennE8bOxxR41zMqP3IomQPrv5G6uRxLeXJVtH9V1U4hZV0udaxMv/r/fLT28sO7q+ultb65fuZLxTiNIYOglzTr8BoM+k6dJE+BdLY9SXr8CxLEcIeTZujyZhmaLz2nqBlujmA4V4agm7cWqJbQSH2MLhZZ/rOrNd/6U3AGwC2mGNFVOxbf/gHje0dNLAwAAA==" \ No newline at end of file +window.navigationData = "data:application/octet-stream;base64,H4sIAAAAAAAAE6WWXW+bMBSG/4uv062N1q7L3RRNU6RUjZJWu5h24cIBrDo2sw9b06r/fTKMBPAHyLkM5/XzOMY+5ucbQXhBsiBfKyxAIEsoMim+KSUVmZGSYkEWJOFUa9AfHaEPBe45mZFnJlKyuJrfzpo0WRDU6QXTF/CCoATl5H12tH0HAYolHk23GsdfiTvYS3VY0qQAW9ArxxnWMqF8h1LRHDwWKxJnusvoFn5XTEHqWa9hItLDtGYi30KmQBcP8hl828CXjPPem13lMZ1qFrtD2MiyKpdUJMC5d5Ecobj51qAHtgdZYcjVjcSZwpLz+Y8aHFzzNI5nXtblUgrzcyUQVEaTzrlg7aOmkVjJvnR+fTNEb5T8w1JQ96VpP9pPHgTHwFKx17qjbaiiez93kLOwE1sf1idmxzgI5IfQn/FkzxP/YFjUG3SKeRiOU68GHbIjWjk642RsWs/RzW1qceC1zGWFofXpJUL7qwk+Kj5OO4XiZt10OCkylodkduwM3VrmTIzauqk42RZSpiDBUZ8rGHo/ZoO3PaN0I/uRKbDTN1J7L4emPDoq2L/KcocUO4cLD6XpV/+fD8Zefvl8dT3vjK+Pn/lSMaYhpFd0kia9vBpDn7g1yWMhnt29SU74rBJJvXS9m6Zvufnku1+8nDYQAFUa6qiL0dYCw/+2e801/licALA3U4hopy3Fr3+FU0zaLAwAAA==" \ No newline at end of file diff --git a/docs/assets/search.js b/docs/assets/search.js index f31f0e20..e83b055d 100644 --- a/docs/assets/search.js +++ b/docs/assets/search.js @@ -1 +1 @@ -window.searchData = "data:application/octet-stream;base64,H4sIAAAAAAAAE81ayW7bSBD9F+qqKOpFlORbJphDgAAJkmDmIBgGI9E2YZrkkFQWGP736eZaRVVxkRI4FwuWql6/fq+6u9jSk5PG3zPnavfkPATRwbly9dyJvEffuXLeHPP75cc0/hYc/NSZO8c0NO/eHqN9HsRR9hp9vrjPH0MTtA+9LPMNouM8z2tQuXJp1A9JAdWAB1Hup7fe3u+gV3G9g4ilbLnv74PwkPrRJOQZyAJDzJ3EM2/mHHmGQhx98g9B6u/zt14YfvX2D9PIkPln0XJXK9UacHOT/0z8S7ksSphXehKpBTEpRr7sIUguE5BBuNzZfWyG/5FPrK0m6SwCcrldi5Vsl1GSfM69vPXRumHGr97uXSm99UDgzJoQhnrNhdEr9fNjGn2JR4yxALH9g1UFCKfVjnjM/EJPYteqP+pXqIX6HuT3HFbz2ejd7986wzidkPsejhi/43mIYz/grA6mJe6Q7JXFZAR7z8rxyf/vaNbaoUen0+DJwp1C9Jwhg0nj5T2p4cnDzAZLe3iOg0dNEN1dwLCLcznNsUfPOQTrI0iez3SBZ8zK+5d/G6c+hrpoGgzgHyg4xXQxcCCM0Z1UgDEgjO+C6OJ1PuvA/OJF2NMVjOQ31CJMoaYk7rjfdth989LA+xrWLUv18bQuvkp6V0+UbYi6geO33Ts/f7M3ONmX+MGPPgehmXv4c9pAMxakpxM7mduZ7fQURkPLigZkZjdKUFtRH+PkmFzEH6L8IZI2lEY+pwyo2s6Ql/XdoQh9G3rBI/9Ey5Lvpr+kkIhLraA7XUE8p77N3Qpcn8QT+VL5LybeCZlaPcF3KTTc6bSG9DtnIZ8kv7xyaNkK/illQLbe5Wqi4uMZhVYmvaRGhkGjzdQ9rZoAo8m9Fx1Cf/SVC82QBXkxzWhGtYabiRIy82Mk9dM0TifyrXNaVnl2eBVkr4Lo3k+DvHjAHi0gohNkoHsED+rjiJ1m/xaK72PvwDzF9pJr834DrWPmT/WxSvk1ZGDr/b5YxT1PQyhgdEdf1/T7gWctKq6/n5ebZpAPdqJ/o1VR5bxuP+pFWwkJn7iyPD3u82G4GY6llzxgN2pBc2OdLuEzRrk5+Nk+DRJ01dA7YidjePTruTH24P9wrp6cb36a2bwrRy7UYmtSbgM/PNivhkpaBjB+fLQg19Vn//hWTRtRhrw2Z/VuOVerxdJ1r6/nuzqj+KB4owgT5j9BhQkUZhqmnaTCJApT5j9FhSkUZs7KnZ4LvXC3axSmUdjK/Lei0FYozPTCO3cut4vtCqO5KGxt/ltTaGsUtuG4bVCYMWW3oQbdYnmt2ltS344PhRGkYQJbYZvXnaA9w24Iq7ogbRPYENu97ATpnMCeCKu90GQktkW4nEQCGyOsAYI0WmBvBGuOwO4I64JwSUhskFxykBIbJAuDyAKSnbUiuYKU2B9Z+LMhIbE/svCHrCOJ/ZHWBEnWkcT+SJedOfZHWhMkWXAS+yNZfyT2R1oTJL2hYH8U64/C/ihrgqQ3H+yPkixkZzezJkiy1hX2R7E7msL2qMIestYVtkex9ihsjyrsIWtdYXsUa4/C9qjCnjVVwgrbo60Jkixhjf3RhT9kCWvsj7YuKLKENTZIF+cNWZm6c+JYGxRZcBo7pK0NiqwjjR3S1gdFlofGFuk1q6fGFmlrhCLrQ5ceFX2CaRBM0/qu7BfMiV8/jD05N1UT0TQwT442f57nzqZ8EdWr2d7KV7d6rd5X1ftmLZSvVbqq4lQR99x2IPY/y9NLkqz8ErxlsW5ZrLm08tvPNqftKZ8cc0z1ZDVX9CB50ybLMclNM41QtgBF96EkzS9y2uxlm7wckxvX/T0gACRgINqfx7RpQDnJpcHWu81UsF5cPrert9um1XXEjVw14oAtqA6zrRTZmisToqkG7FeAPVefd37uFZfIub0GzZovHgAh4Jw5LMfA2C/Tk/K2DuAA+yQ3IYMTHAqMfXXLDACgkVsGoLz9SKsnwH1zuwNggDuK4xFkHr5JAPlgMWmulIMsrB/2QSZYQJqr4OJ2kCp+UBeyN5lWH5Sy4raAJj1t7qkBggIIPQSKC0iQBqpQceVTphGzVqBoNEc7LrzqLiQF+Gpu4Dj6WnzJC9zurCIBykVwVRdHfRUHhRsE6NSMAPIJrlrrXK52FFg5mtu5y99+5DFMBKVebUWC2wbtT9n6RADz4Mw4Zv7JuQeWjOAWW3mPBaYLdizNbby2zE9PWZApuBpvMpPyB1IgHZ5QQwO35ZY2P0sCUKBoBGcZD0VtIGAHEKQFpolKgsQPg8gE7a6fn/8HCQdlGHsrAAA="; \ No newline at end of file +window.searchData = "data:application/octet-stream;base64,H4sIAAAAAAAAE81ayW7bSBD9l9aVltWLqOWWCeYQIECCJJg5EIbBUG2bME1ySCoLDP/7oLlWUV1cpATOSbBZVf36vdfNYpPPLEu+52zvPbPHMD6wvascFvtPmu3Zm2PxsPqYJd/Cg86Yw45ZxPbs7hgHRZjE+TW6vnwoniLmsCDy81znbM/Yi9MUFWvXXvVDWpZqi4dxobM7P9C96nXc4CB8JTrswUMYHTIdz6q8AFlgCIelfqbjggJPQEjiT/oQZjoo3vpR9NUPHueBseafBctdr2UnwO1t8TPVl2JZVmWu1CxQS8ukCPryxzC9jECiwuXKBklc6B/FTG+1SWcBEKvdhq9Ft4zS9HPhF52ORo38uvn34EoZ9IOlzqINIaA3WAi+Ml0cs/hLMmGMJYgdHqw2IJxWN+Ix1yWfll2ruTTMUFfqe1g8ULXaa5N3v3+bjI9Zklr3PRwxfcfzEcbhgosm2E5xD+QgLTouwsA3dHzS/x3DTB8GeDoNnk3caYmBe8ho0nR6Tzw8e5jFqLXH5zh6qwnj+wsQ9utcDnPqreccgM0tSJyPdIlnTNL7l75LMo1LXTQNouAfSLgN6XLkhjCFdysDhABRch/GF6/zRa/ML16EA13BRHxjLcIsH/T6+Lc9dL02vr48r4uvk941EyUbon7g9G33XhdvgkDn+ZfkUcefw0jHRfRz3kALsshAJ3YytzPb6TmIxpaVvSAxu0mEGkd9TNJjehF+WOUPobSFNPE5ZYTVboY0re8OZejbyA+f6CdaEnw//TWJRFgaBt35DOI5DW3uhuDmTjwTry3/1cg7AdOwx+kuxV7udFpj/J2zkE+SX585tGw5/ZQyQtvgco2S++R4htGqpNfkKDl2lpq7p9UTIDh58ONDpCcfudgRkkVejTM7oobD7UwKifkRlOosS7KZeJucDlWRH67C/CqMH3QWFuUD9mQCEZwwB90jeFCfBuw0+7dAfJ/4B+IpdhBcl/cbYB1zPVfHOuXXgIGt9/tyFQ88DaGAyR194+n3I89atrjhfl5s20E+mIn+jVZFnXPdXRqstuYCPnHlRXYMivFyCxxrX/IA3aQFTY11uoTPGOX2oPMgC1N01DA4Yi9jfPQbh4XxQf9g+2f2TWe5ydszsZTLHXPYXaijg3k1VMFyWJA8PZkiN/W1f7Rh00RUIdcr5ngrR66XK9e9uXG8JqO8UP6jDOPM8bgtjKMwwRxP2MIECpPM8aQtTKIwxRxPOVwt3d0GhSkUtmaOt7ZVW6Mwlzme64jdcrfG1VwUtmGOt7FV26CwLYVti8J2zPG2tkF3mF7D9s7Kb0+HUgirYBxLYZpXj9s1w2pwwzq3ysaxIKZ78bhVOY414YZ7rqyRWBbuUhRxLAw3AnCr0Bxrw0lxOFaHGxW4ay2JBRIrqqTAAolSIKuBRG+tCMqQAusjSn221pJYH1HqY/WRwPoII4Kw+khgfYRLzhzrI4wIwmo4gfURpD4C6yOMCMK+oWB9JKmPxPpII4Kwbz5YHynIkr3dzIggrF6XWB9J7mgSyyNLeaxel1geScojsTyylMfqdYnlkaQ8EssjS3k2NgtLLI8yIgirhRXWR5X6WC2ssD7KqCCtFlZYIFXeb6zOVL07jpFBWg2nsELKyCCtPlJYIWV0kFZ7KCyR2pB8KiyRMkJIqz9UpVHZJ3zTWaEP76p+wfPah7Fndls3EW0D88wU2z+/OGxb/fD6V6zqX7f+rf8v6/9LUf/W6bKOk2XcS9eBmL8MTj9N8+oleIdi06HYUGnV288up+spnxmXQ1ntET1I3nbJYkpy20yjKjtQRQ1VSdsvcrrsVZe8mpKbNP09AAAoIEp0n8d0aYA5QaXB1rvLlNAvLp3b59vt0hofUSPXjThAC9whd1W2omxiaaoB+jVAT/nzXhd+eYhcmGPQvH3xAAAB5cR6UhnzMj2tTutAHSCfoCZ0r4vwUNYI6lNmUAAKuSMKVKcfWf0EGLSnO6AMUEdSOMLcxycJIB8sJkVZOcyj5mEfZIIFpCgHl6eDNvMDX4jBZDv7wMqS2gLa9Kw9pwYVJKgwAKA8gARpwIWSsk+VZpm1BKZRFOyk1Kq/kCTAq6iBk/hr+ZLX773mBrwDu3DKdUk85DhI3GiBnmc4oI9Tbm1yKe9IsHIUtXNX334UCUwEVq+3Ik5tg+ZTtiESwDwoMY65PrnvgSXDqcVWnWOB6YIdS1Ebr7H56V0WZHLK421mWn0gBdLhHWps4M5uWftZEigFTMMpyehStg0E7ADcKsGNw9Iw1VEYa7b3bl5e/gfBQ3fmeysAAA=="; \ No newline at end of file diff --git a/docs/assets/style.css b/docs/assets/style.css index 07a385b7..778b9492 100644 --- a/docs/assets/style.css +++ b/docs/assets/style.css @@ -29,7 +29,7 @@ --light-color-ts-constructor-signature: var(--light-color-ts-constructor); --light-color-ts-parameter: var(--light-color-ts-variable); /* type literal not included as links will never be generated to it */ - --light-color-ts-type-parameter: var(--light-color-ts-type-alias); + --light-color-ts-type-parameter: #a55c0e; --light-color-ts-accessor: var(--light-color-ts-property); --light-color-ts-get-signature: var(--light-color-ts-accessor); --light-color-ts-set-signature: var(--light-color-ts-accessor); @@ -69,7 +69,7 @@ --dark-color-ts-constructor-signature: var(--dark-color-ts-constructor); --dark-color-ts-parameter: var(--dark-color-ts-variable); /* type literal not included as links will never be generated to it */ - --dark-color-ts-type-parameter: var(--dark-color-ts-type-alias); + --dark-color-ts-type-parameter: #e07d13; --dark-color-ts-accessor: var(--dark-color-ts-property); --dark-color-ts-get-signature: var(--dark-color-ts-accessor); --dark-color-ts-set-signature: var(--dark-color-ts-accessor); @@ -266,12 +266,12 @@ h6 { line-height: 1.2; } -h1 > a, -h2 > a, -h3 > a, -h4 > a, -h5 > a, -h6 > a { +h1 > a:not(.link), +h2 > a:not(.link), +h3 > a:not(.link), +h4 > a:not(.link), +h5 > a:not(.link), +h6 > a:not(.link) { text-decoration: none; color: var(--color-text); } @@ -327,17 +327,14 @@ dd { } /* Footer */ -.tsd-generator { +footer { border-top: 1px solid var(--color-accent); padding-top: 1rem; padding-bottom: 1rem; max-height: 3.5rem; } - -.tsd-generator > p { - margin-top: 0; - margin-bottom: 0; - padding: 0 1rem; +.tsd-generator { + margin: 0 1em; } .container-main { @@ -405,7 +402,8 @@ dd { } body { background: var(--color-background); - font-family: "Segoe UI", sans-serif; + font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", + Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji"; font-size: 16px; color: var(--color-text); } @@ -649,6 +647,28 @@ input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { font-weight: bold; } +.tsd-full-hierarchy:not(:last-child) { + margin-bottom: 1em; + padding-bottom: 1em; + border-bottom: 1px solid var(--color-accent); +} +.tsd-full-hierarchy, +.tsd-full-hierarchy ul { + list-style: none; + margin: 0; + padding: 0; +} +.tsd-full-hierarchy ul { + padding-left: 1.5rem; +} +.tsd-full-hierarchy a { + padding: 0.25rem 0 !important; + font-size: 1rem; + display: inline-flex; + align-items: center; + color: var(--color-text); +} + .tsd-panel-group.tsd-index-group { margin-bottom: 0; } @@ -714,12 +734,15 @@ input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { } .tsd-navigation > a, .tsd-navigation .tsd-accordion-summary { - width: calc(100% - 0.5rem); + width: calc(100% - 0.25rem); + display: flex; + align-items: center; } .tsd-navigation a, .tsd-navigation summary > span, .tsd-page-navigation a { - display: inline-flex; + display: flex; + width: calc(100% - 0.25rem); align-items: center; padding: 0.25rem; color: var(--color-text); @@ -759,11 +782,6 @@ input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { margin-left: -1.5rem; } -.tsd-nested-navigation > li > a, -.tsd-nested-navigation > li > span { - width: calc(100% - 1.75rem - 0.5rem); -} - .tsd-page-navigation ul { padding-left: 1.75rem; } diff --git a/docs/classes/AuthenticationError.html b/docs/classes/AuthenticationError.html index f30a7909..b3d6c64c 100644 --- a/docs/classes/AuthenticationError.html +++ b/docs/classes/AuthenticationError.html @@ -1,18 +1,18 @@ -AuthenticationError | @auth0/auth0-react

Class AuthenticationError

Thrown when handling the redirect callback fails, will be one of Auth0's +AuthenticationError | @auth0/auth0-react

Class AuthenticationError

Thrown when handling the redirect callback fails, will be one of Auth0's Authentication API's Standard Error Responses: https://auth0.com/docs/api/authentication?javascript#standard-error-responses

-

Hierarchy

Constructors

Properties

appState: any
error: string
error_description: string
message: string
name: string
stack?: string
state: string
prepareStackTrace?: ((err, stackTraces) => any)

Type declaration

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    -

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file +

Hierarchy (view full)

Constructors

Properties

appState: any
error: string
error_description: string
message: string
name: string
stack?: string
state: string
prepareStackTrace?: ((err, stackTraces) => any)

Optional override for formatting stack traces

+

Type declaration

    • (err, stackTraces): any
    • Parameters

      • err: Error
      • stackTraces: CallSite[]

      Returns any

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    +

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file diff --git a/docs/classes/GenericError.html b/docs/classes/GenericError.html index 1e4522fb..be144ba1 100644 --- a/docs/classes/GenericError.html +++ b/docs/classes/GenericError.html @@ -1,15 +1,15 @@ -GenericError | @auth0/auth0-react

Thrown when network requests to the Auth server fail.

-

Hierarchy

Constructors

  • Parameters

    • error: string
    • error_description: string

    Returns GenericError

Properties

error: string
error_description: string
message: string
name: string
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Type declaration

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    -

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file +GenericError | @auth0/auth0-react

Thrown when network requests to the Auth server fail.

+

Hierarchy (view full)

Constructors

  • Parameters

    • error: string
    • error_description: string

    Returns GenericError

Properties

error: string
error_description: string
message: string
name: string
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Optional override for formatting stack traces

+

Type declaration

    • (err, stackTraces): any
    • Parameters

      • err: Error
      • stackTraces: CallSite[]

      Returns any

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    +

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file diff --git a/docs/classes/InMemoryCache.html b/docs/classes/InMemoryCache.html index 178eaf1b..50cfd850 100644 --- a/docs/classes/InMemoryCache.html +++ b/docs/classes/InMemoryCache.html @@ -1,3 +1,3 @@ -InMemoryCache | @auth0/auth0-react

Constructors

Properties

Constructors

Properties

enclosedCache: ICache
\ No newline at end of file +InMemoryCache | @auth0/auth0-react

Constructors

Properties

Constructors

Properties

enclosedCache: ICache
\ No newline at end of file diff --git a/docs/classes/LocalStorageCache.html b/docs/classes/LocalStorageCache.html index 20ea4e20..4c744864 100644 --- a/docs/classes/LocalStorageCache.html +++ b/docs/classes/LocalStorageCache.html @@ -1,6 +1,6 @@ -LocalStorageCache | @auth0/auth0-react

Implements

Constructors

Methods

Constructors

Methods

  • Returns string[]

  • Type Parameters

    Parameters

    • key: string

    Returns MaybePromise<undefined | T>

  • Parameters

    • key: string

    Returns void

  • Type Parameters

    Parameters

    • key: string
    • entry: T

    Returns void

\ No newline at end of file +LocalStorageCache | @auth0/auth0-react

Implements

Constructors

Methods

Constructors

Methods

  • Returns string[]

  • Type Parameters

    Parameters

    • key: string

    Returns MaybePromise<undefined | T>

  • Parameters

    • key: string

    Returns void

  • Type Parameters

    Parameters

    • key: string
    • entry: T

    Returns void

\ No newline at end of file diff --git a/docs/classes/MfaRequiredError.html b/docs/classes/MfaRequiredError.html index 99391b97..b117f034 100644 --- a/docs/classes/MfaRequiredError.html +++ b/docs/classes/MfaRequiredError.html @@ -1,16 +1,16 @@ -MfaRequiredError | @auth0/auth0-react

Error thrown when the token exchange results in a mfa_required error

-

Hierarchy

Constructors

Properties

error: string
error_description: string
message: string
mfa_token: string
name: string
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Type declaration

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    -

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file +MfaRequiredError | @auth0/auth0-react

Error thrown when the token exchange results in a mfa_required error

+

Hierarchy (view full)

Constructors

Properties

error: string
error_description: string
message: string
mfa_token: string
name: string
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Optional override for formatting stack traces

+

Type declaration

    • (err, stackTraces): any
    • Parameters

      • err: Error
      • stackTraces: CallSite[]

      Returns any

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    +

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file diff --git a/docs/classes/MissingRefreshTokenError.html b/docs/classes/MissingRefreshTokenError.html index 93b09f90..2bfb657b 100644 --- a/docs/classes/MissingRefreshTokenError.html +++ b/docs/classes/MissingRefreshTokenError.html @@ -1,17 +1,17 @@ -MissingRefreshTokenError | @auth0/auth0-react

Class MissingRefreshTokenError

Error thrown when there is no refresh token to use

-

Hierarchy

Constructors

Properties

audience: string
error: string
error_description: string
message: string
name: string
scope: string
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Type declaration

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    -

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file +MissingRefreshTokenError | @auth0/auth0-react

Class MissingRefreshTokenError

Error thrown when there is no refresh token to use

+

Hierarchy (view full)

Constructors

Properties

audience: string
error: string
error_description: string
message: string
name: string
scope: string
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Optional override for formatting stack traces

+

Type declaration

    • (err, stackTraces): any
    • Parameters

      • err: Error
      • stackTraces: CallSite[]

      Returns any

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    +

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file diff --git a/docs/classes/OAuthError.html b/docs/classes/OAuthError.html index 6858c146..65428ac9 100644 --- a/docs/classes/OAuthError.html +++ b/docs/classes/OAuthError.html @@ -1,16 +1,16 @@ -OAuthError | @auth0/auth0-react

An OAuth2 error will come from the authorization server and will have at least an error property which will +OAuthError | @auth0/auth0-react

An OAuth2 error will come from the authorization server and will have at least an error property which will be the error code. And possibly an error_description property

See: https://openid.net/specs/openid-connect-core-1_0.html#rfc.section.3.1.2.6

-

Hierarchy

  • Error
    • OAuthError

Constructors

  • Parameters

    • error: string
    • Optional error_description: string

    Returns OAuthError

Properties

error: string
error_description?: string
message: string
name: string
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Type declaration

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    -

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

\ No newline at end of file +

Hierarchy

  • Error
    • OAuthError

Constructors

  • Parameters

    • error: string
    • Optional error_description: string

    Returns OAuthError

Properties

error: string
error_description?: string
message: string
name: string
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Optional override for formatting stack traces

+

Type declaration

    • (err, stackTraces): any
    • Parameters

      • err: Error
      • stackTraces: CallSite[]

      Returns any

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    +

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

\ No newline at end of file diff --git a/docs/classes/PopupCancelledError.html b/docs/classes/PopupCancelledError.html index a215ea6d..6908a252 100644 --- a/docs/classes/PopupCancelledError.html +++ b/docs/classes/PopupCancelledError.html @@ -1,16 +1,16 @@ -PopupCancelledError | @auth0/auth0-react

Class PopupCancelledError

Thrown when network requests to the Auth server fail.

-

Hierarchy

Constructors

Properties

error: string
error_description: string
message: string
name: string
popup: Window
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Type declaration

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    -

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file +PopupCancelledError | @auth0/auth0-react

Class PopupCancelledError

Thrown when network requests to the Auth server fail.

+

Hierarchy (view full)

Constructors

Properties

error: string
error_description: string
message: string
name: string
popup: Window
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Optional override for formatting stack traces

+

Type declaration

    • (err, stackTraces): any
    • Parameters

      • err: Error
      • stackTraces: CallSite[]

      Returns any

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    +

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file diff --git a/docs/classes/PopupTimeoutError.html b/docs/classes/PopupTimeoutError.html index 87e3e33d..5b47d226 100644 --- a/docs/classes/PopupTimeoutError.html +++ b/docs/classes/PopupTimeoutError.html @@ -1,16 +1,16 @@ -PopupTimeoutError | @auth0/auth0-react

Error thrown when the login popup times out (if the user does not complete auth)

-

Hierarchy

Constructors

Properties

error: string
error_description: string
message: string
name: string
popup: Window
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Type declaration

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    -

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file +PopupTimeoutError | @auth0/auth0-react

Error thrown when the login popup times out (if the user does not complete auth)

+

Hierarchy (view full)

Constructors

Properties

error: string
error_description: string
message: string
name: string
popup: Window
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Optional override for formatting stack traces

+

Type declaration

    • (err, stackTraces): any
    • Parameters

      • err: Error
      • stackTraces: CallSite[]

      Returns any

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    +

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file diff --git a/docs/classes/TimeoutError.html b/docs/classes/TimeoutError.html index 5da03f2d..9d580bf4 100644 --- a/docs/classes/TimeoutError.html +++ b/docs/classes/TimeoutError.html @@ -1,16 +1,16 @@ -TimeoutError | @auth0/auth0-react

Thrown when silent auth times out (usually due to a configuration issue) or +TimeoutError | @auth0/auth0-react

Thrown when silent auth times out (usually due to a configuration issue) or when network requests to the Auth server timeout.

-

Hierarchy

Constructors

Properties

error: string
error_description: string
message: string
name: string
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Type declaration

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    -

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file +

Hierarchy (view full)

Constructors

Properties

error: string
error_description: string
message: string
name: string
stack?: string
prepareStackTrace?: ((err, stackTraces) => any)

Optional override for formatting stack traces

+

Type declaration

    • (err, stackTraces): any
    • Parameters

      • err: Error
      • stackTraces: CallSite[]

      Returns any

stackTraceLimit: number

Methods

  • Create .stack property on a target object

    +

    Parameters

    • targetObject: object
    • Optional constructorOpt: Function

    Returns void

  • Parameters

    • __namedParameters: {
          error: string;
          error_description: string;
      }
      • error: string
      • error_description: string

    Returns GenericError

\ No newline at end of file diff --git a/docs/classes/User.html b/docs/classes/User.html index c02fd2c2..77ef93b6 100644 --- a/docs/classes/User.html +++ b/docs/classes/User.html @@ -1,22 +1,22 @@ -User | @auth0/auth0-react

Indexable

[key: string]: any

Constructors

Properties

address?: string
birthdate?: string
email?: string
email_verified?: boolean
family_name?: string
gender?: string
given_name?: string
locale?: string
middle_name?: string
name?: string
nickname?: string
phone_number?: string
phone_number_verified?: boolean
picture?: string
preferred_username?: string
profile?: string
sub?: string
updated_at?: string
website?: string
zoneinfo?: string
\ No newline at end of file +User | @auth0/auth0-react

Indexable

[key: string]: any

Constructors

Properties

address?: string
birthdate?: string
email?: string
email_verified?: boolean
family_name?: string
gender?: string
given_name?: string
locale?: string
middle_name?: string
name?: string
nickname?: string
phone_number?: string
phone_number_verified?: boolean
picture?: string
preferred_username?: string
profile?: string
sub?: string
updated_at?: string
website?: string
zoneinfo?: string
\ No newline at end of file diff --git a/docs/functions/Auth0Context.html b/docs/functions/Auth0Context.html new file mode 100644 index 00000000..ead7730d --- /dev/null +++ b/docs/functions/Auth0Context.html @@ -0,0 +1,10 @@ +Auth0Context | @auth0/auth0-react

Function Auth0Context

  • The Auth0 Context

    +

    Parameters

    Returns null | ReactElement<unknown, string | JSXElementConstructor<any>>

Properties

$$typeof: symbol
Consumer: Consumer<Auth0ContextInterface<User>>
Provider: Provider<Auth0ContextInterface<User>>
displayName?: string

Used in debugging messages. You might want to set it +explicitly if you want to display a different name for +debugging purposes.

+
\ No newline at end of file diff --git a/docs/functions/Auth0Provider.html b/docs/functions/Auth0Provider.html index b0110d39..da95bd92 100644 --- a/docs/functions/Auth0Provider.html +++ b/docs/functions/Auth0Provider.html @@ -1,4 +1,4 @@ -Auth0Provider | @auth0/auth0-react

Function Auth0Provider

\ No newline at end of file diff --git a/docs/functions/useAuth0.html b/docs/functions/useAuth0.html index e09d9358..b2f8c253 100644 --- a/docs/functions/useAuth0.html +++ b/docs/functions/useAuth0.html @@ -1,5 +1,5 @@ -useAuth0 | @auth0/auth0-react
\ No newline at end of file diff --git a/docs/functions/withAuth0.html b/docs/functions/withAuth0.html index 546451a2..e15ca4be 100644 --- a/docs/functions/withAuth0.html +++ b/docs/functions/withAuth0.html @@ -1,6 +1,6 @@ -withAuth0 | @auth0/auth0-react

Function withAuth0

\ No newline at end of file diff --git a/docs/functions/withAuthenticationRequired.html b/docs/functions/withAuthenticationRequired.html index ede10dc7..24947433 100644 --- a/docs/functions/withAuthenticationRequired.html +++ b/docs/functions/withAuthenticationRequired.html @@ -1,5 +1,5 @@ -withAuthenticationRequired | @auth0/auth0-react

Function withAuthenticationRequired

\ No newline at end of file diff --git a/docs/hierarchy.html b/docs/hierarchy.html new file mode 100644 index 00000000..65c1c06a --- /dev/null +++ b/docs/hierarchy.html @@ -0,0 +1 @@ +@auth0/auth0-react
\ No newline at end of file diff --git a/docs/index.html b/docs/index.html index b549e4d6..a5304100 100644 --- a/docs/index.html +++ b/docs/index.html @@ -1,4 +1,4 @@ -@auth0/auth0-react

@auth0/auth0-react

Auth0 SDK for React Single Page Applications

+@auth0/auth0-react
\ No newline at end of file +This project is licensed under the MIT license. See the LICENSE file for more info.

\ No newline at end of file diff --git a/docs/interfaces/Auth0ContextInterface.html b/docs/interfaces/Auth0ContextInterface.html index 57b1aadf..e1a5f275 100644 --- a/docs/interfaces/Auth0ContextInterface.html +++ b/docs/interfaces/Auth0ContextInterface.html @@ -1,16 +1,16 @@ -Auth0ContextInterface | @auth0/auth0-react

Interface Auth0ContextInterface<TUser>

Contains the authenticated state and authentication methods provided by the useAuth0 hook.

-
interface Auth0ContextInterface {
    error?: Error;
    getAccessTokenSilently: {
        (options): Promise<GetTokenSilentlyVerboseResponse>;
        (options?): Promise<string>;
        (options): Promise<string | GetTokenSilentlyVerboseResponse>;
    };
    getAccessTokenWithPopup: ((options?, config?) => Promise<undefined | string>);
    getIdTokenClaims: (() => Promise<undefined | IdToken>);
    handleRedirectCallback: ((url?) => Promise<RedirectLoginResult<any>>);
    isAuthenticated: boolean;
    isLoading: boolean;
    loginWithPopup: ((options?, config?) => Promise<void>);
    loginWithRedirect: ((options?) => Promise<void>);
    logout: ((options?) => Promise<void>);
    user?: TUser;
}

Type Parameters

Hierarchy

  • AuthState<TUser>
    • Auth0ContextInterface

Properties

error?: Error
getAccessTokenSilently: {
    (options): Promise<GetTokenSilentlyVerboseResponse>;
    (options?): Promise<string>;
    (options): Promise<string | GetTokenSilentlyVerboseResponse>;
}

Type declaration

    • (options): Promise<GetTokenSilentlyVerboseResponse>
    • const token = await getAccessTokenSilently(options);
      +Auth0ContextInterface | @auth0/auth0-react

      Interface Auth0ContextInterface<TUser>

      Contains the authenticated state and authentication methods provided by the useAuth0 hook.

      +
      interface Auth0ContextInterface<TUser> {
          error?: Error;
          getAccessTokenSilently: {
              (options): Promise<GetTokenSilentlyVerboseResponse>;
              (options?): Promise<string>;
              (options): Promise<string | GetTokenSilentlyVerboseResponse>;
          };
          getAccessTokenWithPopup: ((options?, config?) => Promise<undefined | string>);
          getIdTokenClaims: (() => Promise<undefined | IdToken>);
          handleRedirectCallback: ((url?) => Promise<RedirectLoginResult<any>>);
          isAuthenticated: boolean;
          isLoading: boolean;
          loginWithPopup: ((options?, config?) => Promise<void>);
          loginWithRedirect: ((options?) => Promise<void>);
          logout: ((options?) => Promise<void>);
          user?: TUser;
      }

      Type Parameters

      Hierarchy

      • AuthState<TUser>
        • Auth0ContextInterface

      Properties

      error?: Error
      getAccessTokenSilently: {
          (options): Promise<GetTokenSilentlyVerboseResponse>;
          (options?): Promise<string>;
          (options): Promise<string | GetTokenSilentlyVerboseResponse>;
      }
      const token = await getAccessTokenSilently(options);
       

      If there's a valid token stored, return it. Otherwise, opens an iframe with the /authorize URL using the parameters provided @@ -19,61 +19,31 @@ will be valid according to their expiration times.

      If refresh tokens are used, the token endpoint is called directly with the 'refresh_token' grant. If no refresh token is available to make this call, -the SDK falls back to using an iframe to the '/authorize' URL.

      +the SDK will only fall back to using an iframe to the '/authorize' URL if +the useRefreshTokensFallback setting has been set to true. By default this +setting is false.

      This method may use a web worker to perform the token call if the in-memory cache is used.

      If an audience value is given to this function, the SDK always falls back to using an iframe to make the token exchange.

      Note that in all cases, falling back to an iframe requires access to the auth0 cookie.

      -

      Parameters

      Returns Promise<GetTokenSilentlyVerboseResponse>

    • (options?): Promise<string>
    • const token = await getAccessTokenSilently(options);
      -
      -

      If there's a valid token stored, return it. Otherwise, opens an -iframe with the /authorize URL using the parameters provided -as arguments. Random and secure state and nonce parameters -will be auto-generated. If the response is successful, results -will be valid according to their expiration times.

      -

      If refresh tokens are used, the token endpoint is called directly with the -'refresh_token' grant. If no refresh token is available to make this call, -the SDK falls back to using an iframe to the '/authorize' URL.

      -

      This method may use a web worker to perform the token call if the in-memory -cache is used.

      -

      If an audience value is given to this function, the SDK always falls -back to using an iframe to make the token exchange.

      -

      Note that in all cases, falling back to an iframe requires access to -the auth0 cookie.

      -

      Parameters

      Returns Promise<string>

    • (options): Promise<string | GetTokenSilentlyVerboseResponse>
    • const token = await getAccessTokenSilently(options);
      -
      -

      If there's a valid token stored, return it. Otherwise, opens an -iframe with the /authorize URL using the parameters provided -as arguments. Random and secure state and nonce parameters -will be auto-generated. If the response is successful, results -will be valid according to their expiration times.

      -

      If refresh tokens are used, the token endpoint is called directly with the -'refresh_token' grant. If no refresh token is available to make this call, -the SDK falls back to using an iframe to the '/authorize' URL.

      -

      This method may use a web worker to perform the token call if the in-memory -cache is used.

      -

      If an audience value is given to this function, the SDK always falls -back to using an iframe to make the token exchange.

      -

      Note that in all cases, falling back to an iframe requires access to -the auth0 cookie.

      -

      Parameters

      Returns Promise<string | GetTokenSilentlyVerboseResponse>

getAccessTokenWithPopup: ((options?, config?) => Promise<undefined | string>)

Type declaration

    • (options?, config?): Promise<undefined | string>
    • const token = await getTokenWithPopup(options, config);
      +

      Type declaration

        • (options): Promise<GetTokenSilentlyVerboseResponse>
        • Parameters

          Returns Promise<GetTokenSilentlyVerboseResponse>

        • (options?): Promise<string>
        • Parameters

          Returns Promise<string>

        • (options): Promise<string | GetTokenSilentlyVerboseResponse>
        • Parameters

          Returns Promise<string | GetTokenSilentlyVerboseResponse>

getAccessTokenWithPopup: ((options?, config?) => Promise<undefined | string>)
const token = await getTokenWithPopup(options, config);
 

Get an access token interactively.

Opens a popup with the /authorize URL using the parameters provided as arguments. Random and secure state and nonce parameters will be auto-generated. If the response is successful, results will be valid according to their expiration times.

-

Parameters

Returns Promise<undefined | string>

getIdTokenClaims: (() => Promise<undefined | IdToken>)

Type declaration

getIdTokenClaims: (() => Promise<undefined | IdToken>)
const claims = await getIdTokenClaims();
 

Returns all claims from the id_token if available.

-

Returns Promise<undefined | IdToken>

handleRedirectCallback: ((url?) => Promise<RedirectLoginResult<any>>)

Type declaration

    • (url?): Promise<RedirectLoginResult<any>>
    • After the browser redirects back to the callback page, +

      Type declaration

handleRedirectCallback: ((url?) => Promise<RedirectLoginResult<any>>)

After the browser redirects back to the callback page, call handleRedirectCallback to handle success and error responses from Auth0. If the response is successful, results will be valid according to their expiration times.

-

Parameters

  • Optional url: string

    The URL to that should be used to retrieve the state and code values. Defaults to window.location.href if not given.

    -

Returns Promise<RedirectLoginResult<any>>

isAuthenticated: boolean
isLoading: boolean
loginWithPopup: ((options?, config?) => Promise<void>)

Type declaration

    • (options?, config?): Promise<void>
    • await loginWithPopup(options, config);
      +

      Type declaration

        • (url?): Promise<RedirectLoginResult<any>>
        • Parameters

          • Optional url: string

            The URL to that should be used to retrieve the state and code values. Defaults to window.location.href if not given.

            +

          Returns Promise<RedirectLoginResult<any>>

isAuthenticated: boolean
isLoading: boolean
loginWithPopup: ((options?, config?) => Promise<void>)
await loginWithPopup(options, config);
 

Opens a popup with the /authorize URL using the parameters provided as arguments. Random and secure state and nonce @@ -82,15 +52,15 @@

IMPORTANT: This method has to be called from an event handler that was started by the user like a button click, for example, otherwise the popup will be blocked in most browsers.

-

Parameters

Returns Promise<void>

loginWithRedirect: ((options?) => Promise<void>)

Type declaration

loginWithRedirect: ((options?) => Promise<void>)
await loginWithRedirect(options);
 

Performs a redirect to /authorize using the parameters provided as arguments. Random and secure state and nonce parameters will be auto-generated.

-

Parameters

Returns Promise<void>

logout: ((options?) => Promise<void>)

Type declaration

logout: ((options?) => Promise<void>)
auth0.logout({ logoutParams: { returnTo: window.location.origin } });
 

Clears the application session and performs a redirect to /v2/logout, using the parameters provided as arguments, to clear the Auth0 session. If the logoutParams.federated option is specified, it also clears the Identity Provider session. Read more about how Logout works at Auth0.

-

Parameters

Returns Promise<void>

user?: TUser
\ No newline at end of file +

Type declaration

    • (options?): Promise<void>
    • Parameters

      Returns Promise<void>

user?: TUser
\ No newline at end of file diff --git a/docs/interfaces/Auth0ProviderOptions.html b/docs/interfaces/Auth0ProviderOptions.html index 137bb196..83fc491d 100644 --- a/docs/interfaces/Auth0ProviderOptions.html +++ b/docs/interfaces/Auth0ProviderOptions.html @@ -1,39 +1,39 @@ -Auth0ProviderOptions | @auth0/auth0-react

Interface Auth0ProviderOptions

The main configuration to instantiate the Auth0Provider.

-
interface Auth0ProviderOptions {
    auth0Client?: {
        env?: {
            [key: string]: string;
        };
        name: string;
        version: string;
    };
    authorizationParams?: AuthorizationParams;
    authorizeTimeoutInSeconds?: number;
    cache?: ICache;
    cacheLocation?: CacheLocation;
    children?: ReactNode;
    clientId: string;
    context?: Context<Auth0ContextInterface<User>>;
    cookieDomain?: string;
    domain: string;
    httpTimeoutInSeconds?: number;
    issuer?: string;
    leeway?: number;
    legacySameSiteCookie?: boolean;
    nowProvider?: (() => number | Promise<number>);
    onRedirectCallback?: ((appState?, user?) => void);
    sessionCheckExpiryDays?: number;
    skipRedirectCallback?: boolean;
    useCookiesForTransactions?: boolean;
    useFormData?: boolean;
    useRefreshTokens?: boolean;
    useRefreshTokensFallback?: boolean;
    workerUrl?: string;
}

Hierarchy

  • Auth0ClientOptions
    • Auth0ProviderOptions

Properties

auth0Client?: {
    env?: {
        [key: string]: string;
    };
    name: string;
    version: string;
}

Internal property to send information about the client to the authorization server.

-

Type declaration

  • Optional env?: {
        [key: string]: string;
    }
    • [key: string]: string
  • name: string
  • version: string
authorizationParams?: AuthorizationParams

URL parameters that will be sent back to the Authorization Server. This can be known parameters +Auth0ProviderOptions | @auth0/auth0-react

Interface Auth0ProviderOptions

The main configuration to instantiate the Auth0Provider.

+
interface Auth0ProviderOptions {
    auth0Client?: {
        env?: {
            [key: string]: string;
        };
        name: string;
        version: string;
    };
    authorizationParams?: AuthorizationParams;
    authorizeTimeoutInSeconds?: number;
    cache?: ICache;
    cacheLocation?: CacheLocation;
    children?: ReactNode;
    clientId: string;
    context?: Context<Auth0ContextInterface<User>>;
    cookieDomain?: string;
    domain: string;
    httpTimeoutInSeconds?: number;
    issuer?: string;
    leeway?: number;
    legacySameSiteCookie?: boolean;
    nowProvider?: (() => number | Promise<number>);
    onRedirectCallback?: ((appState?, user?) => void);
    sessionCheckExpiryDays?: number;
    skipRedirectCallback?: boolean;
    useCookiesForTransactions?: boolean;
    useFormData?: boolean;
    useRefreshTokens?: boolean;
    useRefreshTokensFallback?: boolean;
    workerUrl?: string;
}

Hierarchy

  • Auth0ClientOptions
    • Auth0ProviderOptions

Properties

auth0Client?: {
    env?: {
        [key: string]: string;
    };
    name: string;
    version: string;
}

Internal property to send information about the client to the authorization server.

+

Type declaration

  • Optional env?: {
        [key: string]: string;
    }
    • [key: string]: string
  • name: string
  • version: string
authorizationParams?: AuthorizationParams

URL parameters that will be sent back to the Authorization Server. This can be known parameters defined by Auth0 or custom parameters that you define.

-
authorizeTimeoutInSeconds?: number

A maximum number of seconds to wait before declaring background calls to /authorize as failed for timeout +

authorizeTimeoutInSeconds?: number

A maximum number of seconds to wait before declaring background calls to /authorize as failed for timeout Defaults to 60s.

-
cache?: ICache

Specify a custom cache implementation to use for token storage and retrieval. This setting takes precedence over cacheLocation if they are both specified.

-
cacheLocation?: CacheLocation

The location to use when storing cache data. Valid values are memory or localstorage. +

cache?: ICache

Specify a custom cache implementation to use for token storage and retrieval. This setting takes precedence over cacheLocation if they are both specified.

+
cacheLocation?: CacheLocation

The location to use when storing cache data. Valid values are memory or localstorage. The default setting is memory.

Read more about changing storage options in the Auth0 docs

-
children?: ReactNode

The child nodes your Provider has wrapped

-
clientId: string

The Client ID found on your Application settings page

-
context?: Context<Auth0ContextInterface<User>>

Context to be used when creating the Auth0Provider, defaults to the internally created context.

+
children?: ReactNode

The child nodes your Provider has wrapped

+
clientId: string

The Client ID found on your Application settings page

+
context?: Context<Auth0ContextInterface<User>>

Context to be used when creating the Auth0Provider, defaults to the internally created context.

This allows multiple Auth0Providers to be nested within the same application, the context value can then be passed to useAuth0, withAuth0, or withAuthenticationRequired to use that specific Auth0Provider to access auth state and methods specifically tied to the provider that the context belongs to.

@@ -46,50 +46,50 @@ used to store data is different

For a sample on using multiple Auth0Providers review the React Account Linking Sample

-
cookieDomain?: string

The domain the cookie is accessible from. If not set, the cookie is scoped to +

cookieDomain?: string

The domain the cookie is accessible from. If not set, the cookie is scoped to the current domain, including the subdomain.

Note: setting this incorrectly may cause silent authentication to stop working on page load.

To keep a user logged in across multiple subdomains set this to your top-level domain and prefixed with a . (eg: .example.com).

-
domain: string

Your Auth0 account domain such as 'example.auth0.com', +

domain: string

Your Auth0 account domain such as 'example.auth0.com', 'example.eu.auth0.com' or , 'example.mycompany.com' (when using custom domains)

-
httpTimeoutInSeconds?: number

Specify the timeout for HTTP calls using fetch. The default is 10 seconds.

-
issuer?: string

The issuer to be used for validation of JWTs, optionally defaults to the domain above

-
leeway?: number

The value in seconds used to account for clock skew in JWT expirations. +

httpTimeoutInSeconds?: number

Specify the timeout for HTTP calls using fetch. The default is 10 seconds.

+
issuer?: string

The issuer to be used for validation of JWTs, optionally defaults to the domain above

+
leeway?: number

The value in seconds used to account for clock skew in JWT expirations. Typically, this value is no more than a minute or two at maximum. Defaults to 60s.

-
legacySameSiteCookie?: boolean

Sets an additional cookie with no SameSite attribute to support legacy browsers +

legacySameSiteCookie?: boolean

Sets an additional cookie with no SameSite attribute to support legacy browsers that are not compatible with the latest SameSite changes. This will log a warning on modern browsers, you can disable the warning by setting this to false but be aware that some older useragents will not work, See https://www.chromium.org/updates/same-site/incompatible-clients Defaults to true

-
nowProvider?: (() => number | Promise<number>)

Type declaration

    • (): number | Promise<number>
    • Modify the value used as the current time during the token validation.

      +
nowProvider?: (() => number | Promise<number>)

Modify the value used as the current time during the token validation.

Note: Using this improperly can potentially compromise the token validation.

-

Returns number | Promise<number>

onRedirectCallback?: ((appState?, user?) => void)

Type declaration

    • (appState?, user?): void
    • By default this removes the code and state parameters from the url when you are redirected from the authorize page. +

      Type declaration

        • (): number | Promise<number>
        • Returns number | Promise<number>

onRedirectCallback?: ((appState?, user?) => void)

By default this removes the code and state parameters from the url when you are redirected from the authorize page. It uses window.history but you might want to overwrite this if you are using a custom router, like react-router-dom See the EXAMPLES.md for more info.

-

Parameters

Returns void

sessionCheckExpiryDays?: number

Number of days until the cookie auth0.is.authenticated will expire +

Type declaration

    • (appState?, user?): void
    • Parameters

      Returns void

sessionCheckExpiryDays?: number

Number of days until the cookie auth0.is.authenticated will expire Defaults to 1.

-
skipRedirectCallback?: boolean

By default, if the page url has code/state params, the SDK will treat them as Auth0's and attempt to exchange the +

skipRedirectCallback?: boolean

By default, if the page url has code/state params, the SDK will treat them as Auth0's and attempt to exchange the code for a token. In some cases the code might be for something else (another OAuth SDK perhaps). In these instances you can instruct the client to ignore them eg

<Auth0Provider
clientId={clientId}
domain={domain}
skipRedirectCallback={window.location.pathname === '/stripe-oauth-callback'}
>
-
useCookiesForTransactions?: boolean

If true, the SDK will use a cookie when storing information about the auth transaction while +

useCookiesForTransactions?: boolean

If true, the SDK will use a cookie when storing information about the auth transaction while the user is going through the authentication flow on the authorization server.

The default is false, in which case the SDK will use session storage.

Notes

You might want to enable this if you rely on your users being able to authenticate using flows that may end up spanning across multiple tabs (e.g. magic links) or you cannot otherwise rely on session storage being available.

-
useFormData?: boolean

If true, data to the token endpoint is transmitted as x-www-form-urlencoded data, if false it will be transmitted as JSON. The default setting is true.

+
useFormData?: boolean

If true, data to the token endpoint is transmitted as x-www-form-urlencoded data, if false it will be transmitted as JSON. The default setting is true.

Note: Setting this to false may affect you if you use Auth0 Rules and are sending custom, non-primitive data. If you disable this, please verify that your Auth0 Rules continue to work as intended.

-
useRefreshTokens?: boolean

If true, refresh tokens are used to fetch new access tokens from the Auth0 server. If false, the legacy technique of using a hidden iframe and the authorization_code grant with prompt=none is used. +

useRefreshTokens?: boolean

If true, refresh tokens are used to fetch new access tokens from the Auth0 server. If false, the legacy technique of using a hidden iframe and the authorization_code grant with prompt=none is used. The default setting is false.

Note: Use of refresh tokens must be enabled by an administrator on your Auth0 client application.

-
useRefreshTokensFallback?: boolean

If true, fallback to the technique of using a hidden iframe and the authorization_code grant with prompt=none when unable to use refresh tokens. If false, the iframe fallback is not used and +

useRefreshTokensFallback?: boolean

If true, fallback to the technique of using a hidden iframe and the authorization_code grant with prompt=none when unable to use refresh tokens. If false, the iframe fallback is not used and errors relating to a failed refresh_token grant should be handled appropriately. The default setting is false.

Note: There might be situations where doing silent auth with a Web Message response from an iframe is not possible, like when you're serving your application from the file system or a custom protocol (like in a Desktop or Native app). @@ -97,9 +97,9 @@

E.g. Using the file: protocol in an Electron application does not support that legacy technique.

Example

let token: string;
try {
token = await auth0.getTokenSilently();
} catch (e) {
if (e.error === 'missing_refresh_token' || e.error === 'invalid_grant') {
auth0.loginWithRedirect();
}
}
-
workerUrl?: string

If provided, the SDK will load the token worker from this URL instead of the integrated blob. An example of when this is useful is if you have strict +

workerUrl?: string

If provided, the SDK will load the token worker from this URL instead of the integrated blob. An example of when this is useful is if you have strict Content-Security-Policy (CSP) and wish to avoid needing to set worker-src: blob:. We recommend either serving the worker, which you can find in the module at <module_path>/dist/auth0-spa-js.worker.production.js, from the same host as your application or using the Auth0 CDN https://cdn.auth0.com/js/auth0-spa-js/<version>/auth0-spa-js.worker.production.js.

Note: The worker is only used when useRefreshTokens: true, cacheLocation: 'memory', and the cache is not custom.

-
\ No newline at end of file +
\ No newline at end of file diff --git a/docs/interfaces/AuthorizationParams.html b/docs/interfaces/AuthorizationParams.html index 15a719f8..0d6d9fe1 100644 --- a/docs/interfaces/AuthorizationParams.html +++ b/docs/interfaces/AuthorizationParams.html @@ -1,63 +1,63 @@ -AuthorizationParams | @auth0/auth0-react

Interface AuthorizationParams

interface AuthorizationParams {
    acr_values?: string;
    audience?: string;
    connection?: string;
    display?: "page" | "popup" | "touch" | "wap";
    id_token_hint?: string;
    invitation?: string;
    login_hint?: string;
    max_age?: string | number;
    organization?: string;
    prompt?: "none" | "login" | "consent" | "select_account";
    redirect_uri?: string;
    scope?: string;
    screen_hint?: string;
    ui_locales?: string;
    [key: string]: any;
}

Indexable

[key: string]: any

If you need to send custom parameters to the Authorization Server, +AuthorizationParams | @auth0/auth0-react

Interface AuthorizationParams

interface AuthorizationParams {
    acr_values?: string;
    audience?: string;
    connection?: string;
    display?: "page" | "popup" | "touch" | "wap";
    id_token_hint?: string;
    invitation?: string;
    login_hint?: string;
    max_age?: string | number;
    organization?: string;
    prompt?: "none" | "login" | "consent" | "select_account";
    redirect_uri?: string;
    scope?: string;
    screen_hint?: string;
    ui_locales?: string;
    [key: string]: any;
}

Indexable

[key: string]: any

If you need to send custom parameters to the Authorization Server, make sure to use the original parameter name.

-

Properties

acr_values?: string
audience?: string

The default audience to be used for requesting API access.

-
connection?: string

The name of the connection configured for your application. +

Properties

acr_values?: string
audience?: string

The default audience to be used for requesting API access.

+
connection?: string

The name of the connection configured for your application. If null, it will redirect to the Auth0 Login Page and show the Login Widget.

-
display?: "page" | "popup" | "touch" | "wap"
    +
display?: "page" | "popup" | "touch" | "wap"
  • 'page': displays the UI with a full page view
  • 'popup': displays the UI with a popup window
  • 'touch': displays the UI in a way that leverages a touch interface
  • 'wap': displays the UI with a "feature phone" type interface
-
id_token_hint?: string

Previously issued ID Token.

-
invitation?: string

The Id of an invitation to accept. This is available from the user invitation URL that is given when participating in a user invitation flow.

-
login_hint?: string

The user's email address or other identifier. When your app knows +

id_token_hint?: string

Previously issued ID Token.

+
invitation?: string

The Id of an invitation to accept. This is available from the user invitation URL that is given when participating in a user invitation flow.

+
login_hint?: string

The user's email address or other identifier. When your app knows which user is trying to authenticate, you can provide this parameter to pre-fill the email box or select the right session for sign-in.

This currently only affects the classic Lock experience.

-
max_age?: string | number

Maximum allowable elapsed time (in seconds) since authentication. +

max_age?: string | number

Maximum allowable elapsed time (in seconds) since authentication. If the last time the user authenticated is greater than this value, the user must be reauthenticated.

-
organization?: string

The organization to log in to.

+
organization?: string

The organization to log in to.

This will specify an organization parameter in your user's login request.

  • If you provide an Organization ID (a string with the prefix org_), it will be validated against the org_id claim of your user's ID Token. The validation is case-sensitive.
  • If you provide an Organization Name (a string without the prefix org_), it will be validated against the org_name claim of your user's ID Token. The validation is case-insensitive.
-
prompt?: "none" | "login" | "consent" | "select_account"
    +
prompt?: "none" | "login" | "consent" | "select_account"
  • 'none': do not prompt user for login or consent on reauthentication
  • 'login': prompt user for reauthentication
  • 'consent': prompt user for consent before processing request
  • 'select_account': prompt user to select an account
-
redirect_uri?: string

The default URL where Auth0 will redirect your browser to with +

redirect_uri?: string

The default URL where Auth0 will redirect your browser to with the authentication result. It must be whitelisted in the "Allowed Callback URLs" field in your Auth0 Application's settings. If not provided here, it should be provided in the other methods that provide authentication.

-
scope?: string

The default scope to be used on authentication requests.

+
scope?: string

The default scope to be used on authentication requests.

This defaults to profile email if not set. If you are setting extra scopes and require profile and email to be included then you must include them in the provided scope.

Note: The openid scope is always applied regardless of this setting.

-
screen_hint?: string

Provides a hint to Auth0 as to what flow should be displayed. +

screen_hint?: string

Provides a hint to Auth0 as to what flow should be displayed. The default behavior is to show a login page but you can override this by passing 'signup' to show the signup page instead.

This only affects the New Universal Login Experience.

-
ui_locales?: string

The space-separated list of language tags, ordered by preference. +

ui_locales?: string

The space-separated list of language tags, ordered by preference. For example: 'fr-CA fr en'.

-
\ No newline at end of file +
\ No newline at end of file diff --git a/docs/interfaces/GetTokenSilentlyOptions.html b/docs/interfaces/GetTokenSilentlyOptions.html index e00922c6..48e87363 100644 --- a/docs/interfaces/GetTokenSilentlyOptions.html +++ b/docs/interfaces/GetTokenSilentlyOptions.html @@ -1,8 +1,8 @@ -GetTokenSilentlyOptions | @auth0/auth0-react

Interface GetTokenSilentlyOptions

interface GetTokenSilentlyOptions {
    authorizationParams?: {
        audience?: string;
        redirect_uri?: string;
        scope?: string;
        [key: string]: any;
    };
    cacheMode?: "on" | "off" | "cache-only";
    detailedResponse?: boolean;
    timeoutInSeconds?: number;
}

Properties

authorizationParams?: {
    audience?: string;
    redirect_uri?: string;
    scope?: string;
    [key: string]: any;
}

Parameters that will be sent back to Auth0 as part of a request.

+GetTokenSilentlyOptions | @auth0/auth0-react

Interface GetTokenSilentlyOptions

interface GetTokenSilentlyOptions {
    authorizationParams?: {
        audience?: string;
        redirect_uri?: string;
        scope?: string;
        [key: string]: any;
    };
    cacheMode?: "on" | "off" | "cache-only";
    detailedResponse?: boolean;
    timeoutInSeconds?: number;
}

Properties

authorizationParams?: {
    audience?: string;
    redirect_uri?: string;
    scope?: string;
    [key: string]: any;
}

Parameters that will be sent back to Auth0 as part of a request.

Type declaration

  • [key: string]: any

    If you need to send custom parameters to the Authorization Server, make sure to use the original parameter name.

  • Optional audience?: string

    The audience that was used in the authentication request

    @@ -13,13 +13,13 @@ It must be whitelisted in the "Allowed Web Origins" in your Auth0 Application's settings.

  • Optional scope?: string

    The scope that was used in the authentication request

    -
cacheMode?: "on" | "off" | "cache-only"

When off, ignores the cache and always sends a +

cacheMode?: "on" | "off" | "cache-only"

When off, ignores the cache and always sends a request to Auth0. When cache-only, only reads from the cache and never sends a request to Auth0. Defaults to on, where it both reads from the cache and sends a request to Auth0 as needed.

-
detailedResponse?: boolean

If true, the full response from the /oauth/token endpoint (or the cache, if the cache was used) is returned +

detailedResponse?: boolean

If true, the full response from the /oauth/token endpoint (or the cache, if the cache was used) is returned (minus refresh_token if one was issued). Otherwise, just the access token is returned.

The default is false.

-
timeoutInSeconds?: number

A maximum number of seconds to wait before declaring the background /authorize call as failed for timeout +

timeoutInSeconds?: number

A maximum number of seconds to wait before declaring the background /authorize call as failed for timeout Defaults to 60s.

-
\ No newline at end of file +
\ No newline at end of file diff --git a/docs/interfaces/GetTokenWithPopupOptions.html b/docs/interfaces/GetTokenWithPopupOptions.html index 9c88eaaa..826f153b 100644 --- a/docs/interfaces/GetTokenWithPopupOptions.html +++ b/docs/interfaces/GetTokenWithPopupOptions.html @@ -1,8 +1,8 @@ -GetTokenWithPopupOptions | @auth0/auth0-react

Interface GetTokenWithPopupOptions

interface GetTokenWithPopupOptions {
    authorizationParams?: AuthorizationParams;
    cacheMode?: "on" | "off" | "cache-only";
}

Hierarchy

Properties

authorizationParams?: AuthorizationParams

URL parameters that will be sent back to the Authorization Server. This can be known parameters +GetTokenWithPopupOptions | @auth0/auth0-react

Interface GetTokenWithPopupOptions

interface GetTokenWithPopupOptions {
    authorizationParams?: AuthorizationParams;
    cacheMode?: "on" | "off" | "cache-only";
}

Hierarchy (view full)

Properties

authorizationParams?: AuthorizationParams

URL parameters that will be sent back to the Authorization Server. This can be known parameters defined by Auth0 or custom parameters that you define.

-
cacheMode?: "on" | "off" | "cache-only"

When off, ignores the cache and always sends a request to Auth0. +

cacheMode?: "on" | "off" | "cache-only"

When off, ignores the cache and always sends a request to Auth0. When cache-only, only reads from the cache and never sends a request to Auth0. Defaults to on, where it both reads from the cache and sends a request to Auth0 as needed.

-
\ No newline at end of file +
\ No newline at end of file diff --git a/docs/interfaces/ICache.html b/docs/interfaces/ICache.html index 31e3be05..6257bcb7 100644 --- a/docs/interfaces/ICache.html +++ b/docs/interfaces/ICache.html @@ -1,5 +1,5 @@ -ICache | @auth0/auth0-react

Interface ICache

interface ICache {
    allKeys?(): MaybePromise<string[]>;
    get<T>(key): MaybePromise<undefined | T>;
    remove(key): MaybePromise<void>;
    set<T>(key, entry): MaybePromise<void>;
}

Implemented by

Methods

Methods

  • Returns MaybePromise<string[]>

  • Type Parameters

    Parameters

    • key: string

    Returns MaybePromise<undefined | T>

  • Parameters

    • key: string

    Returns MaybePromise<void>

  • Type Parameters

    Parameters

    • key: string
    • entry: T

    Returns MaybePromise<void>

\ No newline at end of file +ICache | @auth0/auth0-react

Interface ICache

interface ICache {
    allKeys?(): MaybePromise<string[]>;
    get<T>(key): MaybePromise<undefined | T>;
    remove(key): MaybePromise<void>;
    set<T>(key, entry): MaybePromise<void>;
}

Implemented by

Methods

Methods

  • Returns MaybePromise<string[]>

  • Type Parameters

    Parameters

    • key: string

    Returns MaybePromise<undefined | T>

  • Parameters

    • key: string

    Returns MaybePromise<void>

  • Type Parameters

    Parameters

    • key: string
    • entry: T

    Returns MaybePromise<void>

\ No newline at end of file diff --git a/docs/interfaces/IdToken.html b/docs/interfaces/IdToken.html index dd6defcf..edaf31c9 100644 --- a/docs/interfaces/IdToken.html +++ b/docs/interfaces/IdToken.html @@ -1,39 +1,39 @@ -IdToken | @auth0/auth0-react

Interface IdToken

interface IdToken {
    __raw: string;
    acr?: string;
    address?: string;
    amr?: string[];
    at_hash?: string;
    aud?: string;
    auth_time?: string;
    azp?: string;
    birthdate?: string;
    c_hash?: string;
    cnf?: string;
    email?: string;
    email_verified?: boolean;
    exp?: number;
    family_name?: string;
    gender?: string;
    given_name?: string;
    iat?: number;
    iss?: string;
    jti?: string;
    locale?: string;
    middle_name?: string;
    name?: string;
    nbf?: number;
    nickname?: string;
    nonce?: string;
    org_id?: string;
    org_name?: string;
    phone_number?: string;
    phone_number_verified?: boolean;
    picture?: string;
    preferred_username?: string;
    profile?: string;
    sid?: string;
    sub_jwk?: string;
    updated_at?: string;
    website?: string;
    zoneinfo?: string;
    [key: string]: any;
}

Indexable

[key: string]: any

Properties

__raw: string
acr?: string
address?: string
amr?: string[]
at_hash?: string
aud?: string
auth_time?: string
azp?: string
birthdate?: string
c_hash?: string
cnf?: string
email?: string
email_verified?: boolean
exp?: number
family_name?: string
gender?: string
given_name?: string
iat?: number
iss?: string
jti?: string
locale?: string
middle_name?: string
name?: string
nbf?: number
nickname?: string
nonce?: string
org_id?: string
org_name?: string
phone_number?: string
phone_number_verified?: boolean
picture?: string
preferred_username?: string
profile?: string
sid?: string
sub_jwk?: string
updated_at?: string
website?: string
zoneinfo?: string
\ No newline at end of file +IdToken | @auth0/auth0-react

Interface IdToken

interface IdToken {
    __raw: string;
    acr?: string;
    address?: string;
    amr?: string[];
    at_hash?: string;
    aud?: string;
    auth_time?: string;
    azp?: string;
    birthdate?: string;
    c_hash?: string;
    cnf?: string;
    email?: string;
    email_verified?: boolean;
    exp?: number;
    family_name?: string;
    gender?: string;
    given_name?: string;
    iat?: number;
    iss?: string;
    jti?: string;
    locale?: string;
    middle_name?: string;
    name?: string;
    nbf?: number;
    nickname?: string;
    nonce?: string;
    org_id?: string;
    org_name?: string;
    phone_number?: string;
    phone_number_verified?: boolean;
    picture?: string;
    preferred_username?: string;
    profile?: string;
    sid?: string;
    sub_jwk?: string;
    updated_at?: string;
    website?: string;
    zoneinfo?: string;
    [key: string]: any;
}

Indexable

[key: string]: any

Properties

__raw: string
acr?: string
address?: string
amr?: string[]
at_hash?: string
aud?: string
auth_time?: string
azp?: string
birthdate?: string
c_hash?: string
cnf?: string
email?: string
email_verified?: boolean
exp?: number
family_name?: string
gender?: string
given_name?: string
iat?: number
iss?: string
jti?: string
locale?: string
middle_name?: string
name?: string
nbf?: number
nickname?: string
nonce?: string
org_id?: string
org_name?: string
phone_number?: string
phone_number_verified?: boolean
picture?: string
preferred_username?: string
profile?: string
sid?: string
sub_jwk?: string
updated_at?: string
website?: string
zoneinfo?: string
\ No newline at end of file diff --git a/docs/interfaces/LogoutOptions.html b/docs/interfaces/LogoutOptions.html index 7f6e0f2b..39d6b947 100644 --- a/docs/interfaces/LogoutOptions.html +++ b/docs/interfaces/LogoutOptions.html @@ -1,11 +1,11 @@ -LogoutOptions | @auth0/auth0-react

Interface LogoutOptions

interface LogoutOptions {
    clientId?: null | string;
    logoutParams?: {
        federated?: boolean;
        returnTo?: string;
        [key: string]: any;
    };
    openUrl?: false | ((url) => void | Promise<void>);
}

Hierarchy

  • Omit<SPALogoutOptions, "onRedirect">
    • LogoutOptions

Properties

clientId?: null | string

The clientId of your application.

+LogoutOptions | @auth0/auth0-react

Interface LogoutOptions

interface LogoutOptions {
    clientId?: null | string;
    logoutParams?: {
        federated?: boolean;
        returnTo?: string;
        [key: string]: any;
    };
    openUrl?: false | ((url) => void | Promise<void>);
}

Hierarchy

  • Omit<SPALogoutOptions, "onRedirect">
    • LogoutOptions

Properties

clientId?: null | string

The clientId of your application.

If this property is not set, then the clientId that was used during initialization of the SDK is sent to the logout endpoint.

If this property is set to null, then no client ID value is sent to the logout endpoint.

Read more about how redirecting after logout works

-
logoutParams?: {
    federated?: boolean;
    returnTo?: string;
    [key: string]: any;
}

Parameters to pass to the logout endpoint. This can be known parameters defined by Auth0 or custom parameters +

logoutParams?: {
    federated?: boolean;
    returnTo?: string;
    [key: string]: any;
}

Parameters to pass to the logout endpoint. This can be known parameters defined by Auth0 or custom parameters you wish to provide.

Type declaration

  • [key: string]: any

    If you need to send custom parameters to the logout endpoint, make sure to use the original parameter name.

  • Optional federated?: boolean

    When supported by the upstream identity provider, @@ -20,10 +20,10 @@ returnTo URL must be listed in the "Allowed Logout URLs" at the account level in the Auth0 dashboard.

    Read more about how redirecting after logout works

    -
openUrl?: false | ((url) => void | Promise<void>)

Used to control the redirect and not rely on the SDK to do the actual redirect.

+
openUrl?: false | ((url) => void | Promise<void>)

Used to control the redirect and not rely on the SDK to do the actual redirect.

Set to false to disable the redirect, or provide a function to handle the actual redirect yourself.

-

Type declaration

    • (url): void | Promise<void>
    • Parameters

      • url: string

      Returns void | Promise<void>

Example

await auth0.logout({
openUrl(url) {
window.location.replace(url);
}
}); +

Type declaration

    • (url): void | Promise<void>
    • Parameters

      • url: string

      Returns void | Promise<void>

Example

await auth0.logout({
openUrl(url) {
window.location.replace(url);
}
});

Example

import { Browser } from '@capacitor/browser';

await auth0.logout({
async openUrl(url) {
await Browser.open({ url });
}
});
-
\ No newline at end of file +
\ No newline at end of file diff --git a/docs/interfaces/LogoutUrlOptions.html b/docs/interfaces/LogoutUrlOptions.html index 480e9b83..f82b6a3f 100644 --- a/docs/interfaces/LogoutUrlOptions.html +++ b/docs/interfaces/LogoutUrlOptions.html @@ -1,10 +1,10 @@ -LogoutUrlOptions | @auth0/auth0-react

Interface LogoutUrlOptions

interface LogoutUrlOptions {
    clientId?: null | string;
    logoutParams?: {
        federated?: boolean;
        returnTo?: string;
        [key: string]: any;
    };
}

Properties

clientId?: null | string

The clientId of your application.

+LogoutUrlOptions | @auth0/auth0-react

Interface LogoutUrlOptions

interface LogoutUrlOptions {
    clientId?: null | string;
    logoutParams?: {
        federated?: boolean;
        returnTo?: string;
        [key: string]: any;
    };
}

Properties

clientId?: null | string

The clientId of your application.

If this property is not set, then the clientId that was used during initialization of the SDK is sent to the logout endpoint.

If this property is set to null, then no client ID value is sent to the logout endpoint.

Read more about how redirecting after logout works

-
logoutParams?: {
    federated?: boolean;
    returnTo?: string;
    [key: string]: any;
}

Parameters to pass to the logout endpoint. This can be known parameters defined by Auth0 or custom parameters +

logoutParams?: {
    federated?: boolean;
    returnTo?: string;
    [key: string]: any;
}

Parameters to pass to the logout endpoint. This can be known parameters defined by Auth0 or custom parameters you wish to provide.

Type declaration

  • [key: string]: any

    If you need to send custom parameters to the logout endpoint, make sure to use the original parameter name.

  • Optional federated?: boolean

    When supported by the upstream identity provider, @@ -19,4 +19,4 @@ returnTo URL must be listed in the "Allowed Logout URLs" at the account level in the Auth0 dashboard.

    Read more about how redirecting after logout works

    -
\ No newline at end of file +
\ No newline at end of file diff --git a/docs/interfaces/PopupConfigOptions.html b/docs/interfaces/PopupConfigOptions.html index 35197f57..c0fed0d2 100644 --- a/docs/interfaces/PopupConfigOptions.html +++ b/docs/interfaces/PopupConfigOptions.html @@ -1,8 +1,8 @@ -PopupConfigOptions | @auth0/auth0-react

Interface PopupConfigOptions

interface PopupConfigOptions {
    popup?: any;
    timeoutInSeconds?: number;
}

Properties

popup?: any

Accepts an already-created popup window to use. If not specified, the SDK +PopupConfigOptions | @auth0/auth0-react

Interface PopupConfigOptions

interface PopupConfigOptions {
    popup?: any;
    timeoutInSeconds?: number;
}

Properties

popup?: any

Accepts an already-created popup window to use. If not specified, the SDK will create its own. This may be useful for platforms like iOS that have security restrictions around when popups can be invoked (e.g. from a user click event)

-
timeoutInSeconds?: number

The number of seconds to wait for a popup response before +

timeoutInSeconds?: number

The number of seconds to wait for a popup response before throwing a timeout error. Defaults to 60s

-
\ No newline at end of file +
\ No newline at end of file diff --git a/docs/interfaces/PopupLoginOptions.html b/docs/interfaces/PopupLoginOptions.html index 9e06f6eb..e906f668 100644 --- a/docs/interfaces/PopupLoginOptions.html +++ b/docs/interfaces/PopupLoginOptions.html @@ -1,4 +1,4 @@ -PopupLoginOptions | @auth0/auth0-react

Interface PopupLoginOptions

interface PopupLoginOptions {
    authorizationParams?: AuthorizationParams;
}

Hierarchy

Properties

authorizationParams?: AuthorizationParams

URL parameters that will be sent back to the Authorization Server. This can be known parameters +PopupLoginOptions | @auth0/auth0-react

Interface PopupLoginOptions

interface PopupLoginOptions {
    authorizationParams?: AuthorizationParams;
}

Hierarchy (view full)

Properties

authorizationParams?: AuthorizationParams

URL parameters that will be sent back to the Authorization Server. This can be known parameters defined by Auth0 or custom parameters that you define.

-
\ No newline at end of file +
\ No newline at end of file diff --git a/docs/interfaces/RedirectLoginOptions.html b/docs/interfaces/RedirectLoginOptions.html index 2465aef7..7acedc83 100644 --- a/docs/interfaces/RedirectLoginOptions.html +++ b/docs/interfaces/RedirectLoginOptions.html @@ -1,14 +1,14 @@ -RedirectLoginOptions | @auth0/auth0-react

Interface RedirectLoginOptions<TAppState>

interface RedirectLoginOptions {
    appState?: TAppState;
    authorizationParams?: AuthorizationParams;
    fragment?: string;
    openUrl?: ((url) => void | Promise<void>);
}

Type Parameters

Hierarchy

  • Omit<SPARedirectLoginOptions<TAppState>, "onRedirect">
    • RedirectLoginOptions

Properties

appState?: TAppState

Used to store state before doing the redirect

-
authorizationParams?: AuthorizationParams

URL parameters that will be sent back to the Authorization Server. This can be known parameters +RedirectLoginOptions | @auth0/auth0-react

Interface RedirectLoginOptions<TAppState>

interface RedirectLoginOptions<TAppState> {
    appState?: TAppState;
    authorizationParams?: AuthorizationParams;
    fragment?: string;
    openUrl?: ((url) => void | Promise<void>);
}

Type Parameters

Hierarchy

  • Omit<SPARedirectLoginOptions<TAppState>, "onRedirect">
    • RedirectLoginOptions

Properties

appState?: TAppState

Used to store state before doing the redirect

+
authorizationParams?: AuthorizationParams

URL parameters that will be sent back to the Authorization Server. This can be known parameters defined by Auth0 or custom parameters that you define.

-
fragment?: string

Used to add to the URL fragment before redirecting

-
openUrl?: ((url) => void | Promise<void>)

Type declaration

    • (url): void | Promise<void>
    • Used to control the redirect and not rely on the SDK to do the actual redirect.

      -

      Parameters

      • url: string

      Returns void | Promise<void>

      Example

      const client = new Auth0Client({
      openUrl(url) {
      window.location.replace(url);
      }
      }); +
fragment?: string

Used to add to the URL fragment before redirecting

+
openUrl?: ((url) => void | Promise<void>)

Used to control the redirect and not rely on the SDK to do the actual redirect.

+

Type declaration

    • (url): void | Promise<void>
    • Parameters

      • url: string

      Returns void | Promise<void>

Example

const client = new Auth0Client({
openUrl(url) {
window.location.replace(url);
}
});

Example

import { Browser } from '@capacitor/browser';

const client = new Auth0Client({
async openUrl(url) {
await Browser.open({ url });
}
});
-
\ No newline at end of file +
\ No newline at end of file diff --git a/docs/interfaces/WithAuth0Props.html b/docs/interfaces/WithAuth0Props.html index f9f9e2d9..3e427980 100644 --- a/docs/interfaces/WithAuth0Props.html +++ b/docs/interfaces/WithAuth0Props.html @@ -1,3 +1,3 @@ -WithAuth0Props | @auth0/auth0-react
\ No newline at end of file +WithAuth0Props | @auth0/auth0-react

Interface WithAuth0Props

Components wrapped in withAuth0 will have an additional auth0 prop

+
interface WithAuth0Props {
    auth0: Auth0ContextInterface<User>;
}

Properties

Properties

\ No newline at end of file diff --git a/docs/interfaces/WithAuthenticationRequiredOptions.html b/docs/interfaces/WithAuthenticationRequiredOptions.html index 27c6e806..52a909d9 100644 --- a/docs/interfaces/WithAuthenticationRequiredOptions.html +++ b/docs/interfaces/WithAuthenticationRequiredOptions.html @@ -1,26 +1,26 @@ -WithAuthenticationRequiredOptions | @auth0/auth0-react

Interface WithAuthenticationRequiredOptions

Options for the withAuthenticationRequired Higher Order Component

-
interface WithAuthenticationRequiredOptions {
    context?: Context<Auth0ContextInterface<User>>;
    loginOptions?: RedirectLoginOptions<AppState>;
    onBeforeAuthentication?: (() => Promise<void>);
    onRedirecting?: (() => Element);
    returnTo?: string | (() => string);
}

Properties

context?: Context<Auth0ContextInterface<User>>

The context to be used when calling useAuth0, this should only be provided if you are using multiple Auth0Providers +WithAuthenticationRequiredOptions | @auth0/auth0-react

Interface WithAuthenticationRequiredOptions

Options for the withAuthenticationRequired Higher Order Component

+
interface WithAuthenticationRequiredOptions {
    context?: Context<Auth0ContextInterface<User>>;
    loginOptions?: RedirectLoginOptions<AppState>;
    onBeforeAuthentication?: (() => Promise<void>);
    onRedirecting?: (() => Element);
    returnTo?: string | (() => string);
}

Properties

context?: Context<Auth0ContextInterface<User>>

The context to be used when calling useAuth0, this should only be provided if you are using multiple Auth0Providers within your application and you wish to tie a specific component to a Auth0Provider other than the Auth0Provider associated with the default Auth0Context.

-
withAuthenticationRequired(Profile, {
loginOptions: {
appState: {
customProp: 'foo'
}
}
}) +
withAuthenticationRequired(Profile, {
loginOptions: {
appState: {
customProp: 'foo'
}
}
})

Pass additional login options, like extra appState to the login page. This will be merged with the returnTo option used by the onRedirectCallback handler.

-
onBeforeAuthentication?: (() => Promise<void>)

Type declaration

onBeforeAuthentication?: (() => Promise<void>)
withAuthenticationRequired(Profile, {
onBeforeAuthentication: () => { analyticsLibrary.track('login_triggered'); }
})

Allows executing logic before the user is redirected to the login page.

-

Returns Promise<void>

onRedirecting?: (() => Element)

Type declaration

    • (): Element
    • withAuthenticationRequired(Profile, {
      onRedirecting: () => <div>Redirecting you to the login...</div>
      }) +

      Type declaration

        • (): Promise<void>
        • Returns Promise<void>

onRedirecting?: (() => Element)
withAuthenticationRequired(Profile, {
onRedirecting: () => <div>Redirecting you to the login...</div>
})

Render a message to show that the user is being redirected to the login.

-

Returns Element

returnTo?: string | (() => string)
withAuthenticationRequired(Profile, {
returnTo: '/profile'
}) +

Type declaration

    • (): Element
    • Returns Element

returnTo?: string | (() => string)
withAuthenticationRequired(Profile, {
returnTo: '/profile'
})

or

withAuthenticationRequired(Profile, {
returnTo: () => window.location.hash.substr(1)
})

Add a path for the onRedirectCallback handler to return the user to after login.

-

Type declaration

    • (): string
    • Returns string

\ No newline at end of file +

Type declaration

    • (): string
    • Returns string

\ No newline at end of file diff --git a/docs/modules.html b/docs/modules.html index 9f8063ba..44914ebe 100644 --- a/docs/modules.html +++ b/docs/modules.html @@ -1,34 +1,34 @@ -@auth0/auth0-react
\ No newline at end of file +@auth0/auth0-react
\ No newline at end of file diff --git a/docs/types/AppState.html b/docs/types/AppState.html index 8983038d..9df19f14 100644 --- a/docs/types/AppState.html +++ b/docs/types/AppState.html @@ -1,2 +1,2 @@ -AppState | @auth0/auth0-react

Type alias AppState

AppState: {
    returnTo?: string;
    [key: string]: any;
}

The state of the application before the user was redirected to the login page.

-

Type declaration

  • [key: string]: any
  • Optional returnTo?: string
\ No newline at end of file +AppState | @auth0/auth0-react

Type alias AppState

AppState: {
    returnTo?: string;
    [key: string]: any;
}

The state of the application before the user was redirected to the login page.

+

Type declaration

  • [key: string]: any
  • Optional returnTo?: string
\ No newline at end of file diff --git a/docs/types/CacheLocation.html b/docs/types/CacheLocation.html index e09585fd..1ffcd4b9 100644 --- a/docs/types/CacheLocation.html +++ b/docs/types/CacheLocation.html @@ -1,2 +1,2 @@ -CacheLocation | @auth0/auth0-react

Type alias CacheLocation

CacheLocation: "memory" | "localstorage"

The possible locations where tokens can be stored

-
\ No newline at end of file +CacheLocation | @auth0/auth0-react

Type alias CacheLocation

CacheLocation: "memory" | "localstorage"

The possible locations where tokens can be stored

+
\ No newline at end of file diff --git a/docs/types/Cacheable.html b/docs/types/Cacheable.html index 87d491c8..7cff2b3a 100644 --- a/docs/types/Cacheable.html +++ b/docs/types/Cacheable.html @@ -1 +1 @@ -Cacheable | @auth0/auth0-react
\ No newline at end of file +Cacheable | @auth0/auth0-react

Type alias Cacheable

Cacheable: WrappedCacheEntry | KeyManifestEntry
\ No newline at end of file diff --git a/docs/variables/Auth0Context.html b/docs/variables/Auth0Context.html deleted file mode 100644 index c02da29c..00000000 --- a/docs/variables/Auth0Context.html +++ /dev/null @@ -1,2 +0,0 @@ -Auth0Context | @auth0/auth0-react
\ No newline at end of file diff --git a/package-lock.json b/package-lock.json index d7951d59..f8ad46fa 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@auth0/auth0-react", - "version": "2.2.4", + "version": "2.3.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@auth0/auth0-react", - "version": "2.2.4", + "version": "2.3.0", "license": "MIT", "dependencies": { "@auth0/auth0-spa-js": "^2.1.3" diff --git a/package.json b/package.json index cb2f655e..e9f0f6e5 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "author": "Auth0", "name": "@auth0/auth0-react", - "version": "2.2.4", + "version": "2.3.0", "description": "Auth0 SDK for React Single Page Applications (SPA)", "keywords": [ "auth0",