From 6b550344e59c2d007be0a1bc6ccb4889280fdd74 Mon Sep 17 00:00:00 2001 From: "Simen A. W. Olsen" Date: Sun, 30 Jul 2023 14:40:58 +0200 Subject: [PATCH 1/3] chore: use branch for link references --- .github/workflows/weekly-scheduled-jobs.yml | 2 +- package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/weekly-scheduled-jobs.yml b/.github/workflows/weekly-scheduled-jobs.yml index 35de2e2..9cc2b19 100644 --- a/.github/workflows/weekly-scheduled-jobs.yml +++ b/.github/workflows/weekly-scheduled-jobs.yml @@ -19,7 +19,7 @@ jobs: - run: yarn install - - name: Run typegen + - name: Run generate docs run: yarn run generate:docs - name: Create Pull Request diff --git a/package.json b/package.json index 3845f7a..73d1a80 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "scripts": { "build": "tsc", "lint": "eslint '**/*.ts' --fix", - "generate:docs": "typedoc --readme none --out docs src", + "generate:docs": "typedoc --gitRevision branch --readme none --out docs src", "test": "jest --coverage src", "prepare": "husky install" }, From 0f18ed1ba8dac8316d43e7042adec57658471500 Mon Sep 17 00:00:00 2001 From: "Simen A. W. Olsen" Date: Sun, 30 Jul 2023 14:41:07 +0200 Subject: [PATCH 2/3] update docs --- docs/assets/main.js | 6 +- docs/assets/style.css | 87 +++++++++----- docs/classes/PubSubHandlerResponse.html | 56 ++++----- .../functions/createPubSubCloudFunctions.html | 44 +++---- docs/functions/handlePubSubMessage.html | 44 +++---- docs/functions/makePubSubConfig.html | 44 +++---- docs/functions/pubSubFastifyPlugin.html | 51 ++++---- docs/index.html | 68 +++++------ docs/interfaces/HandlePubSubMessageArgs.html | 92 +++++++-------- .../PubSubCloudFunctionsConfig.html | 109 +++++++++--------- docs/interfaces/PubSubConfig.html | 101 ++++++++-------- .../PubSubHandlerFastifyConfig.html | 109 +++++++++--------- docs/types/CloudFunctionFun.html | 38 +++--- docs/types/OnErrorHandler.html | 42 +++---- docs/types/PubSubHandler.html | 42 +++---- docs/types/PubSubMessage.html | 38 +++--- docs/types/PubSubRequest.html | 38 +++--- docs/variables/pubSubMessageSchema.html | 50 ++++---- docs/variables/pubSubRequestSchema.html | 48 ++++---- package.json | 2 +- 20 files changed, 581 insertions(+), 528 deletions(-) diff --git a/docs/assets/main.js b/docs/assets/main.js index 932e185..4c8fa61 100644 --- a/docs/assets/main.js +++ b/docs/assets/main.js @@ -1,7 +1,7 @@ "use strict"; -"use strict";(()=>{var be=Object.create;var re=Object.defineProperty;var Se=Object.getOwnPropertyDescriptor;var we=Object.getOwnPropertyNames;var Te=Object.getPrototypeOf,ke=Object.prototype.hasOwnProperty;var Qe=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Pe=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of we(e))!ke.call(t,i)&&i!==r&&re(t,i,{get:()=>e[i],enumerable:!(n=Se(e,i))||n.enumerable});return t};var Ie=(t,e,r)=>(r=t!=null?be(Te(t)):{},Pe(e||!t||!t.__esModule?re(r,"default",{value:t,enumerable:!0}):r,t));var ae=Qe((se,oe)=>{(function(){var t=function(e){var r=new t.Builder;return r.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),r.searchPipeline.add(t.stemmer),e.call(r,r),r.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){return function(r){e.console&&console.warn&&console.warn(r)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var r=Object.create(null),n=Object.keys(e),i=0;i0){var d=t.utils.clone(r)||{};d.position=[a,u],d.index=s.length,s.push(new t.Token(n.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,r){r in this.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+r),e.label=r,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){var r=e.label&&e.label in this.registeredFunctions;r||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index. -`,e)},t.Pipeline.load=function(e){var r=new t.Pipeline;return e.forEach(function(n){var i=t.Pipeline.registeredFunctions[n];if(i)r.add(i);else throw new Error("Cannot load unregistered function: "+n)}),r},t.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach(function(r){t.Pipeline.warnIfFunctionNotRegistered(r),this._stack.push(r)},this)},t.Pipeline.prototype.after=function(e,r){t.Pipeline.warnIfFunctionNotRegistered(r);var n=this._stack.indexOf(e);if(n==-1)throw new Error("Cannot find existingFn");n=n+1,this._stack.splice(n,0,r)},t.Pipeline.prototype.before=function(e,r){t.Pipeline.warnIfFunctionNotRegistered(r);var n=this._stack.indexOf(e);if(n==-1)throw new Error("Cannot find existingFn");this._stack.splice(n,0,r)},t.Pipeline.prototype.remove=function(e){var r=this._stack.indexOf(e);r!=-1&&this._stack.splice(r,1)},t.Pipeline.prototype.run=function(e){for(var r=this._stack.length,n=0;n1&&(oe&&(n=s),o!=e);)i=n-r,s=r+Math.floor(i/2),o=this.elements[s*2];if(o==e||o>e)return s*2;if(ol?d+=2:a==l&&(r+=n[u+1]*i[d+1],u+=2,d+=2);return r},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),r=1,n=0;r0){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),m=s.str.charAt(1),y;m in s.node.edges?y=s.node.edges[m]:(y=new t.TokenSet,s.node.edges[m]=y),s.str.length==1&&(y.final=!0),i.push({node:y,editsRemaining:s.editsRemaining-1,str:d+s.str.slice(2)})}}}return n},t.TokenSet.fromString=function(e){for(var r=new t.TokenSet,n=r,i=0,s=e.length;i=e;r--){var n=this.uncheckedNodes[r],i=n.child.toString();i in this.minimizedNodes?n.parent.edges[n.char]=this.minimizedNodes[i]:(n.child._str=i,this.minimizedNodes[i]=n.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(r){var n=new t.QueryParser(e,r);n.parse()})},t.Index.prototype.query=function(e){for(var r=new t.Query(this.fields),n=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,r){var n=e[this._ref],i=Object.keys(this._fields);this._documents[n]=r||{},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,r;do e=this.next(),r=e.charCodeAt(0);while(r>47&&r<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 r=e.next();if(r==t.QueryLexer.EOS)return t.QueryLexer.lexEOS;if(r.charCodeAt(0)==92){e.escapeCharacter();continue}if(r==":")return t.QueryLexer.lexField;if(r=="~")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexEditDistance;if(r=="^")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexBoost;if(r=="+"&&e.width()===1||r=="-"&&e.width()===1)return e.emit(t.QueryLexer.PRESENCE),t.QueryLexer.lexText;if(r.match(t.QueryLexer.termSeparator))return t.QueryLexer.lexTerm}},t.QueryParser=function(e,r){this.lexer=new t.QueryLexer(e),this.query=r,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 r=e.peekLexeme();if(r!=null)switch(r.type){case t.QueryLexer.PRESENCE:return t.QueryParser.parsePresence;case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var n="expected either a field or a term, found "+r.type;throw r.str.length>=1&&(n+=" with value '"+r.str+"'"),new t.QueryParseError(n,r.start,r.end)}},t.QueryParser.parsePresence=function(e){var r=e.consumeLexeme();if(r!=null){switch(r.str){case"-":e.currentClause.presence=t.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=t.Query.presence.REQUIRED;break;default:var n="unrecognised presence operator'"+r.str+"'";throw new t.QueryParseError(n,r.start,r.end)}var i=e.peekLexeme();if(i==null){var n="expecting term or field, found nothing";throw new t.QueryParseError(n,r.start,r.end)}switch(i.type){case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var n="expecting term or field, found '"+i.type+"'";throw new t.QueryParseError(n,i.start,i.end)}}},t.QueryParser.parseField=function(e){var r=e.consumeLexeme();if(r!=null){if(e.query.allFields.indexOf(r.str)==-1){var n=e.query.allFields.map(function(o){return"'"+o+"'"}).join(", "),i="unrecognised field '"+r.str+"', possible fields: "+n;throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.fields=[r.str];var s=e.peekLexeme();if(s==null){var i="expecting term, found nothing";throw new t.QueryParseError(i,r.start,r.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 r=e.consumeLexeme();if(r!=null){e.currentClause.term=r.str.toLowerCase(),r.str.indexOf("*")!=-1&&(e.currentClause.usePipeline=!1);var n=e.peekLexeme();if(n==null){e.nextClause();return}switch(n.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+n.type+"'";throw new t.QueryParseError(i,n.start,n.end)}}},t.QueryParser.parseEditDistance=function(e){var r=e.consumeLexeme();if(r!=null){var n=parseInt(r.str,10);if(isNaN(n)){var i="edit distance must be numeric";throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.editDistance=n;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 r=e.consumeLexeme();if(r!=null){var n=parseInt(r.str,10);if(isNaN(n)){var i="boost must be numeric";throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.boost=n;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,r){typeof define=="function"&&define.amd?define(r):typeof se=="object"?oe.exports=r():e.lunr=r()}(this,function(){return t})})()});var ne=[];function G(t,e){ne.push({selector:e,constructor:t})}var U=class{constructor(){this.alwaysVisibleMember=null;this.createComponents(document.body),this.ensureActivePageVisible(),this.ensureFocusedElementVisible(),window.addEventListener("hashchange",()=>this.ensureFocusedElementVisible())}createComponents(e){ne.forEach(r=>{e.querySelectorAll(r.selector).forEach(n=>{n.dataset.hasInstance||(new r.constructor({el:n,app:this}),n.dataset.hasInstance=String(!0))})})}filterChanged(){this.ensureFocusedElementVisible()}ensureActivePageVisible(){let e=document.querySelector(".tsd-navigation .current"),r=e?.parentElement;for(;r&&!r.classList.contains(".tsd-navigation");)r instanceof HTMLDetailsElement&&e?.parentElement?.parentElement!==r&&(r.open=!0),r=r.parentElement;if(e){let n=e.getBoundingClientRect().top-document.documentElement.clientHeight/4;document.querySelector(".site-menu").scrollTop=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 r=e.parentElement;for(;r&&r.tagName!=="SECTION";)r=r.parentElement;if(r&&r.offsetParent==null){this.alwaysVisibleMember=r,r.classList.add("always-visible");let n=document.createElement("p");n.classList.add("warning"),n.textContent="This member is normally hidden due to your filter settings.",r.prepend(n)}}};var ie=(t,e=100)=>{let r;return()=>{clearTimeout(r),r=setTimeout(()=>t(),e)}};var ce=Ie(ae());function de(){let t=document.getElementById("tsd-search");if(!t)return;let e=document.getElementById("tsd-search-script");t.classList.add("loading"),e&&(e.addEventListener("error",()=>{t.classList.remove("loading"),t.classList.add("failure")}),e.addEventListener("load",()=>{t.classList.remove("loading"),t.classList.add("ready")}),window.searchData&&t.classList.remove("loading"));let r=document.querySelector("#tsd-search input"),n=document.querySelector("#tsd-search .results");if(!r||!n)throw new Error("The input field or the result list wrapper was not found");let i=!1;n.addEventListener("mousedown",()=>i=!0),n.addEventListener("mouseup",()=>{i=!1,t.classList.remove("has-focus")}),r.addEventListener("focus",()=>t.classList.add("has-focus")),r.addEventListener("blur",()=>{i||(i=!1,t.classList.remove("has-focus"))});let s={base:t.dataset.base+"/"};Ce(t,n,r,s)}function Ce(t,e,r,n){r.addEventListener("input",ie(()=>{_e(t,e,r,n)},200));let i=!1;r.addEventListener("keydown",s=>{i=!0,s.key=="Enter"?Re(e,r):s.key=="Escape"?r.blur():s.key=="ArrowUp"?ue(e,-1):s.key==="ArrowDown"?ue(e,1):i=!1}),r.addEventListener("keypress",s=>{i&&s.preventDefault()}),document.body.addEventListener("keydown",s=>{s.altKey||s.ctrlKey||s.metaKey||!r.matches(":focus")&&s.key==="/"&&(r.focus(),s.preventDefault())})}function Oe(t,e){t.index||window.searchData&&(e.classList.remove("loading"),e.classList.add("ready"),t.data=window.searchData,t.index=ce.Index.load(window.searchData.index))}function _e(t,e,r,n){if(Oe(n,t),!n.index||!n.data)return;e.textContent="";let i=r.value.trim(),s=i?n.index.search(`*${i}*`):[];for(let o=0;oa.score-o.score);for(let o=0,a=Math.min(10,s.length);o${le(l.parent,i)}.${u}`);let d=document.createElement("li");d.classList.value=l.classes??"";let m=document.createElement("a");m.href=n.base+l.url,m.innerHTML=u,d.append(m),e.appendChild(d)}}function ue(t,e){let r=t.querySelector(".current");if(!r)r=t.querySelector(e==1?"li:first-child":"li:last-child"),r&&r.classList.add("current");else{let n=r;if(e===1)do n=n.nextElementSibling??void 0;while(n instanceof HTMLElement&&n.offsetParent==null);else do n=n.previousElementSibling??void 0;while(n instanceof HTMLElement&&n.offsetParent==null);n&&(r.classList.remove("current"),n.classList.add("current"))}}function Re(t,e){let r=t.querySelector(".current");if(r||(r=t.querySelector("li:first-child")),r){let n=r.querySelector("a");n&&(window.location.href=n.href),e.blur()}}function le(t,e){if(e==="")return t;let r=t.toLocaleLowerCase(),n=e.toLocaleLowerCase(),i=[],s=0,o=r.indexOf(n);for(;o!=-1;)i.push(K(t.substring(s,o)),`${K(t.substring(o,o+n.length))}`),s=o+n.length,o=r.indexOf(n,s);return i.push(K(t.substring(s))),i.join("")}var Fe={"&":"&","<":"<",">":">","'":"'",'"':"""};function K(t){return t.replace(/[&<>"'"]/g,e=>Fe[e])}var P=class{constructor(e){this.el=e.el,this.app=e.app}};var M="mousedown",fe="mousemove",N="mouseup",J={x:0,y:0},he=!1,ee=!1,Me=!1,D=!1,pe=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);document.documentElement.classList.add(pe?"is-mobile":"not-mobile");pe&&"ontouchstart"in document.documentElement&&(Me=!0,M="touchstart",fe="touchmove",N="touchend");document.addEventListener(M,t=>{ee=!0,D=!1;let e=M=="touchstart"?t.targetTouches[0]:t;J.y=e.pageY||0,J.x=e.pageX||0});document.addEventListener(fe,t=>{if(ee&&!D){let e=M=="touchstart"?t.targetTouches[0]:t,r=J.x-(e.pageX||0),n=J.y-(e.pageY||0);D=Math.sqrt(r*r+n*n)>10}});document.addEventListener(N,()=>{ee=!1});document.addEventListener("click",t=>{he&&(t.preventDefault(),t.stopImmediatePropagation(),he=!1)});var X=class extends P{constructor(r){super(r);this.className=this.el.dataset.toggle||"",this.el.addEventListener(N,n=>this.onPointerUp(n)),this.el.addEventListener("click",n=>n.preventDefault()),document.addEventListener(M,n=>this.onDocumentPointerDown(n)),document.addEventListener(N,n=>this.onDocumentPointerUp(n))}setActive(r){if(this.active==r)return;this.active=r,document.documentElement.classList.toggle("has-"+this.className,r),this.el.classList.toggle("active",r);let n=(this.active?"to-has-":"from-has-")+this.className;document.documentElement.classList.add(n),setTimeout(()=>document.documentElement.classList.remove(n),500)}onPointerUp(r){D||(this.setActive(!0),r.preventDefault())}onDocumentPointerDown(r){if(this.active){if(r.target.closest(".col-sidebar, .tsd-filter-group"))return;this.setActive(!1)}}onDocumentPointerUp(r){if(!D&&this.active&&r.target.closest(".col-sidebar")){let n=r.target.closest("a");if(n){let i=window.location.href;i.indexOf("#")!=-1&&(i=i.substring(0,i.indexOf("#"))),n.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 me=document.head.appendChild(document.createElement("style"));me.dataset.for="filters";var Y=class extends P{constructor(r){super(r);this.key=`filter-${this.el.name}`,this.value=this.el.checked,this.el.addEventListener("change",()=>{this.setLocalStorage(this.el.checked)}),this.setLocalStorage(this.fromLocalStorage()),me.innerHTML+=`html:not(.${this.key}) .tsd-is-${this.el.name} { display: none; } -`}fromLocalStorage(){let r=Q.getItem(this.key);return r?r==="true":this.el.checked}setLocalStorage(r){Q.setItem(this.key,r.toString()),this.value=r,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(r=>{r.style.display="block";let n=Array.from(r.querySelectorAll(".tsd-index-link")).every(i=>i.offsetParent==null);r.style.display=n?"none":"block"})}};var Z=class extends P{constructor(r){super(r);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()),this.update()}update(){this.icon.style.transform=`rotate(${this.el.open?0:-90}deg)`,Q.setItem(this.key,this.el.open.toString())}};function ve(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}addEventListener("load",()=>{de(),G(X,"a[data-toggle]"),G(Z,".tsd-index-accordion"),G(Y,".tsd-filter-item input[type=checkbox]");let t=document.getElementById("tsd-theme");t&&ve(t);let e=new U;Object.defineProperty(window,"app",{value:e})});})(); +"use strict";(()=>{var Se=Object.create;var re=Object.defineProperty;var we=Object.getOwnPropertyDescriptor;var Te=Object.getOwnPropertyNames;var ke=Object.getPrototypeOf,Qe=Object.prototype.hasOwnProperty;var Pe=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Ie=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Te(e))!Qe.call(t,i)&&i!==r&&re(t,i,{get:()=>e[i],enumerable:!(n=we(e,i))||n.enumerable});return t};var Ce=(t,e,r)=>(r=t!=null?Se(ke(t)):{},Ie(e||!t||!t.__esModule?re(r,"default",{value:t,enumerable:!0}):r,t));var ae=Pe((se,oe)=>{(function(){var t=function(e){var r=new t.Builder;return r.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),r.searchPipeline.add(t.stemmer),e.call(r,r),r.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){return function(r){e.console&&console.warn&&console.warn(r)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var r=Object.create(null),n=Object.keys(e),i=0;i0){var d=t.utils.clone(r)||{};d.position=[a,u],d.index=s.length,s.push(new t.Token(n.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,r){r in this.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+r),e.label=r,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){var r=e.label&&e.label in this.registeredFunctions;r||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index. +`,e)},t.Pipeline.load=function(e){var r=new t.Pipeline;return e.forEach(function(n){var i=t.Pipeline.registeredFunctions[n];if(i)r.add(i);else throw new Error("Cannot load unregistered function: "+n)}),r},t.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach(function(r){t.Pipeline.warnIfFunctionNotRegistered(r),this._stack.push(r)},this)},t.Pipeline.prototype.after=function(e,r){t.Pipeline.warnIfFunctionNotRegistered(r);var n=this._stack.indexOf(e);if(n==-1)throw new Error("Cannot find existingFn");n=n+1,this._stack.splice(n,0,r)},t.Pipeline.prototype.before=function(e,r){t.Pipeline.warnIfFunctionNotRegistered(r);var n=this._stack.indexOf(e);if(n==-1)throw new Error("Cannot find existingFn");this._stack.splice(n,0,r)},t.Pipeline.prototype.remove=function(e){var r=this._stack.indexOf(e);r!=-1&&this._stack.splice(r,1)},t.Pipeline.prototype.run=function(e){for(var r=this._stack.length,n=0;n1&&(oe&&(n=s),o!=e);)i=n-r,s=r+Math.floor(i/2),o=this.elements[s*2];if(o==e||o>e)return s*2;if(ol?d+=2:a==l&&(r+=n[u+1]*i[d+1],u+=2,d+=2);return r},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),r=1,n=0;r0){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),m=s.str.charAt(1),y;m in s.node.edges?y=s.node.edges[m]:(y=new t.TokenSet,s.node.edges[m]=y),s.str.length==1&&(y.final=!0),i.push({node:y,editsRemaining:s.editsRemaining-1,str:d+s.str.slice(2)})}}}return n},t.TokenSet.fromString=function(e){for(var r=new t.TokenSet,n=r,i=0,s=e.length;i=e;r--){var n=this.uncheckedNodes[r],i=n.child.toString();i in this.minimizedNodes?n.parent.edges[n.char]=this.minimizedNodes[i]:(n.child._str=i,this.minimizedNodes[i]=n.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(r){var n=new t.QueryParser(e,r);n.parse()})},t.Index.prototype.query=function(e){for(var r=new t.Query(this.fields),n=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,r){var n=e[this._ref],i=Object.keys(this._fields);this._documents[n]=r||{},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,r;do e=this.next(),r=e.charCodeAt(0);while(r>47&&r<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 r=e.next();if(r==t.QueryLexer.EOS)return t.QueryLexer.lexEOS;if(r.charCodeAt(0)==92){e.escapeCharacter();continue}if(r==":")return t.QueryLexer.lexField;if(r=="~")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexEditDistance;if(r=="^")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexBoost;if(r=="+"&&e.width()===1||r=="-"&&e.width()===1)return e.emit(t.QueryLexer.PRESENCE),t.QueryLexer.lexText;if(r.match(t.QueryLexer.termSeparator))return t.QueryLexer.lexTerm}},t.QueryParser=function(e,r){this.lexer=new t.QueryLexer(e),this.query=r,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 r=e.peekLexeme();if(r!=null)switch(r.type){case t.QueryLexer.PRESENCE:return t.QueryParser.parsePresence;case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var n="expected either a field or a term, found "+r.type;throw r.str.length>=1&&(n+=" with value '"+r.str+"'"),new t.QueryParseError(n,r.start,r.end)}},t.QueryParser.parsePresence=function(e){var r=e.consumeLexeme();if(r!=null){switch(r.str){case"-":e.currentClause.presence=t.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=t.Query.presence.REQUIRED;break;default:var n="unrecognised presence operator'"+r.str+"'";throw new t.QueryParseError(n,r.start,r.end)}var i=e.peekLexeme();if(i==null){var n="expecting term or field, found nothing";throw new t.QueryParseError(n,r.start,r.end)}switch(i.type){case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var n="expecting term or field, found '"+i.type+"'";throw new t.QueryParseError(n,i.start,i.end)}}},t.QueryParser.parseField=function(e){var r=e.consumeLexeme();if(r!=null){if(e.query.allFields.indexOf(r.str)==-1){var n=e.query.allFields.map(function(o){return"'"+o+"'"}).join(", "),i="unrecognised field '"+r.str+"', possible fields: "+n;throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.fields=[r.str];var s=e.peekLexeme();if(s==null){var i="expecting term, found nothing";throw new t.QueryParseError(i,r.start,r.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 r=e.consumeLexeme();if(r!=null){e.currentClause.term=r.str.toLowerCase(),r.str.indexOf("*")!=-1&&(e.currentClause.usePipeline=!1);var n=e.peekLexeme();if(n==null){e.nextClause();return}switch(n.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+n.type+"'";throw new t.QueryParseError(i,n.start,n.end)}}},t.QueryParser.parseEditDistance=function(e){var r=e.consumeLexeme();if(r!=null){var n=parseInt(r.str,10);if(isNaN(n)){var i="edit distance must be numeric";throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.editDistance=n;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 r=e.consumeLexeme();if(r!=null){var n=parseInt(r.str,10);if(isNaN(n)){var i="boost must be numeric";throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.boost=n;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,r){typeof define=="function"&&define.amd?define(r):typeof se=="object"?oe.exports=r():e.lunr=r()}(this,function(){return t})})()});var ne=[];function G(t,e){ne.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){ne.forEach(r=>{e.querySelectorAll(r.selector).forEach(n=>{n.dataset.hasInstance||(new r.constructor({el:n,app:this}),n.dataset.hasInstance=String(!0))})})}filterChanged(){this.ensureFocusedElementVisible()}ensureActivePageVisible(){let e=document.querySelector(".tsd-navigation .current"),r=e?.parentElement;for(;r&&!r.classList.contains(".tsd-navigation");)r instanceof HTMLDetailsElement&&(r.open=!0),r=r.parentElement;if(e){let n=e.getBoundingClientRect().top-document.documentElement.clientHeight/4;document.querySelector(".site-menu").scrollTop=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 r=e.parentElement;for(;r&&r.tagName!=="SECTION";)r=r.parentElement;if(r&&r.offsetParent==null){this.alwaysVisibleMember=r,r.classList.add("always-visible");let n=document.createElement("p");n.classList.add("warning"),n.textContent="This member is normally hidden due to your filter settings.",r.prepend(n)}}listenForCodeCopies(){document.querySelectorAll("pre > button").forEach(e=>{let r;e.addEventListener("click",()=>{e.previousElementSibling instanceof HTMLElement&&navigator.clipboard.writeText(e.previousElementSibling.innerText.trim()),e.textContent="Copied!",e.classList.add("visible"),clearTimeout(r),r=setTimeout(()=>{e.classList.remove("visible"),r=setTimeout(()=>{e.textContent="Copy"},100)},1e3)})})}};var ie=(t,e=100)=>{let r;return()=>{clearTimeout(r),r=setTimeout(()=>t(),e)}};var ce=Ce(ae());function de(){let t=document.getElementById("tsd-search");if(!t)return;let e=document.getElementById("tsd-search-script");t.classList.add("loading"),e&&(e.addEventListener("error",()=>{t.classList.remove("loading"),t.classList.add("failure")}),e.addEventListener("load",()=>{t.classList.remove("loading"),t.classList.add("ready")}),window.searchData&&t.classList.remove("loading"));let r=document.querySelector("#tsd-search input"),n=document.querySelector("#tsd-search .results");if(!r||!n)throw new Error("The input field or the result list wrapper was not found");let i=!1;n.addEventListener("mousedown",()=>i=!0),n.addEventListener("mouseup",()=>{i=!1,t.classList.remove("has-focus")}),r.addEventListener("focus",()=>t.classList.add("has-focus")),r.addEventListener("blur",()=>{i||(i=!1,t.classList.remove("has-focus"))});let s={base:t.dataset.base+"/"};Oe(t,n,r,s)}function Oe(t,e,r,n){r.addEventListener("input",ie(()=>{Re(t,e,r,n)},200));let i=!1;r.addEventListener("keydown",s=>{i=!0,s.key=="Enter"?Fe(e,r):s.key=="Escape"?r.blur():s.key=="ArrowUp"?ue(e,-1):s.key==="ArrowDown"?ue(e,1):i=!1}),r.addEventListener("keypress",s=>{i&&s.preventDefault()}),document.body.addEventListener("keydown",s=>{s.altKey||s.ctrlKey||s.metaKey||!r.matches(":focus")&&s.key==="/"&&(r.focus(),s.preventDefault())})}function _e(t,e){t.index||window.searchData&&(e.classList.remove("loading"),e.classList.add("ready"),t.data=window.searchData,t.index=ce.Index.load(window.searchData.index))}function Re(t,e,r,n){if(_e(n,t),!n.index||!n.data)return;e.textContent="";let i=r.value.trim(),s=i?n.index.search(`*${i}*`):[];for(let o=0;oa.score-o.score);for(let o=0,a=Math.min(10,s.length);o${le(l.parent,i)}.${u}`);let d=document.createElement("li");d.classList.value=l.classes??"";let m=document.createElement("a");m.href=n.base+l.url,m.innerHTML=u,d.append(m),e.appendChild(d)}}function ue(t,e){let r=t.querySelector(".current");if(!r)r=t.querySelector(e==1?"li:first-child":"li:last-child"),r&&r.classList.add("current");else{let n=r;if(e===1)do n=n.nextElementSibling??void 0;while(n instanceof HTMLElement&&n.offsetParent==null);else do n=n.previousElementSibling??void 0;while(n instanceof HTMLElement&&n.offsetParent==null);n&&(r.classList.remove("current"),n.classList.add("current"))}}function Fe(t,e){let r=t.querySelector(".current");if(r||(r=t.querySelector("li:first-child")),r){let n=r.querySelector("a");n&&(window.location.href=n.href),e.blur()}}function le(t,e){if(e==="")return t;let r=t.toLocaleLowerCase(),n=e.toLocaleLowerCase(),i=[],s=0,o=r.indexOf(n);for(;o!=-1;)i.push(K(t.substring(s,o)),`${K(t.substring(o,o+n.length))}`),s=o+n.length,o=r.indexOf(n,s);return i.push(K(t.substring(s))),i.join("")}var Me={"&":"&","<":"<",">":">","'":"'",'"':"""};function K(t){return t.replace(/[&<>"'"]/g,e=>Me[e])}var P=class{constructor(e){this.el=e.el,this.app=e.app}};var M="mousedown",fe="mousemove",N="mouseup",J={x:0,y:0},he=!1,ee=!1,De=!1,D=!1,pe=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);document.documentElement.classList.add(pe?"is-mobile":"not-mobile");pe&&"ontouchstart"in document.documentElement&&(De=!0,M="touchstart",fe="touchmove",N="touchend");document.addEventListener(M,t=>{ee=!0,D=!1;let e=M=="touchstart"?t.targetTouches[0]:t;J.y=e.pageY||0,J.x=e.pageX||0});document.addEventListener(fe,t=>{if(ee&&!D){let e=M=="touchstart"?t.targetTouches[0]:t,r=J.x-(e.pageX||0),n=J.y-(e.pageY||0);D=Math.sqrt(r*r+n*n)>10}});document.addEventListener(N,()=>{ee=!1});document.addEventListener("click",t=>{he&&(t.preventDefault(),t.stopImmediatePropagation(),he=!1)});var X=class extends P{constructor(r){super(r);this.className=this.el.dataset.toggle||"",this.el.addEventListener(N,n=>this.onPointerUp(n)),this.el.addEventListener("click",n=>n.preventDefault()),document.addEventListener(M,n=>this.onDocumentPointerDown(n)),document.addEventListener(N,n=>this.onDocumentPointerUp(n))}setActive(r){if(this.active==r)return;this.active=r,document.documentElement.classList.toggle("has-"+this.className,r),this.el.classList.toggle("active",r);let n=(this.active?"to-has-":"from-has-")+this.className;document.documentElement.classList.add(n),setTimeout(()=>document.documentElement.classList.remove(n),500)}onPointerUp(r){D||(this.setActive(!0),r.preventDefault())}onDocumentPointerDown(r){if(this.active){if(r.target.closest(".col-sidebar, .tsd-filter-group"))return;this.setActive(!1)}}onDocumentPointerUp(r){if(!D&&this.active&&r.target.closest(".col-sidebar")){let n=r.target.closest("a");if(n){let i=window.location.href;i.indexOf("#")!=-1&&(i=i.substring(0,i.indexOf("#"))),n.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 me=document.head.appendChild(document.createElement("style"));me.dataset.for="filters";var Y=class extends P{constructor(r){super(r);this.key=`filter-${this.el.name}`,this.value=this.el.checked,this.el.addEventListener("change",()=>{this.setLocalStorage(this.el.checked)}),this.setLocalStorage(this.fromLocalStorage()),me.innerHTML+=`html:not(.${this.key}) .tsd-is-${this.el.name} { display: none; } +`}fromLocalStorage(){let r=Q.getItem(this.key);return r?r==="true":this.el.checked}setLocalStorage(r){Q.setItem(this.key,r.toString()),this.value=r,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(r=>{r.style.display="block";let n=Array.from(r.querySelectorAll(".tsd-index-link")).every(i=>i.offsetParent==null);r.style.display=n?"none":"block"})}};var Z=class extends P{constructor(r){super(r);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()),this.update()}update(){this.icon.style.transform=`rotate(${this.el.open?0:-90}deg)`,Q.setItem(this.key,this.el.open.toString())}};function ve(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}de();G(X,"a[data-toggle]");G(Z,".tsd-index-accordion");G(Y,".tsd-filter-item input[type=checkbox]");var ge=document.getElementById("tsd-theme");ge&&ve(ge);var Ae=new U;Object.defineProperty(window,"app",{value:Ae});document.querySelectorAll("summary a").forEach(t=>{t.addEventListener("click",()=>{location.assign(t.href)})});})(); /*! Bundled license information: lunr/lunr.js: diff --git a/docs/assets/style.css b/docs/assets/style.css index da6c789..18b4f8f 100644 --- a/docs/assets/style.css +++ b/docs/assets/style.css @@ -51,13 +51,13 @@ --dark-color-text-aside: #dddddd; --dark-color-link: #00aff4; - --dark-color-ts-project: #e14dff; + --dark-color-ts-project: #e358ff; --dark-color-ts-module: var(--dark-color-ts-project); --dark-color-ts-namespace: var(--dark-color-ts-project); --dark-color-ts-enum: #f4d93e; --dark-color-ts-enum-member: var(--dark-color-ts-enum); --dark-color-ts-variable: #798dff; - --dark-color-ts-function: #9772ff; + --dark-color-ts-function: #a280ff; --dark-color-ts-class: #8ac4ff; --dark-color-ts-interface: #6cff87; --dark-color-ts-constructor: var(--dark-color-ts-class); @@ -262,6 +262,16 @@ h6 { line-height: 1.2; } +h1 > a, +h2 > a, +h3 > a, +h4 > a, +h5 > a, +h6 > a { + text-decoration: none; + color: var(--color-text); +} + h1 { font-size: 1.875rem; margin: 0.67rem 0; @@ -296,12 +306,6 @@ h6 { text-transform: uppercase; } -pre { - white-space: pre; - white-space: pre-wrap; - word-wrap: break-word; -} - dl, menu, ol, @@ -426,13 +430,29 @@ pre { } pre { + position: relative; + white-space: pre; + white-space: pre-wrap; + word-wrap: break-word; padding: 10px; - border: 0.1em solid var(--color-accent); + border: 1px solid var(--color-accent); } pre code { padding: 0; font-size: 100%; } +pre > button { + position: absolute; + top: 10px; + right: 10px; + opacity: 0; + transition: opacity 0.1s; + box-sizing: border-box; +} +pre:hover > button, +pre > button.visible { + opacity: 1; +} blockquote { margin: 1em 0; @@ -676,7 +696,12 @@ input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { .tsd-navigation.settings { margin: 1rem 0; } +.tsd-navigation > a, +.tsd-navigation .tsd-accordion-summary { + width: calc(100% - 0.5rem); +} .tsd-navigation a, +.tsd-navigation summary > span, .tsd-page-navigation a { display: inline-flex; align-items: center; @@ -685,14 +710,6 @@ input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { text-decoration: none; box-sizing: border-box; } -.tsd-navigation a { - /* why 3rem? No idea, but it seems to work. */ - width: calc(100% - 3rem); -} -.tsd-page-navigation a { - /* why is this different? */ - width: 100%; -} .tsd-navigation a.current, .tsd-page-navigation a.current { background: var(--color-active-menu-item); @@ -703,7 +720,8 @@ input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { } .tsd-navigation ul, .tsd-page-navigation ul { - margin: 0; + margin-top: 0; + margin-bottom: 0; padding: 0; list-style: none; } @@ -712,18 +730,24 @@ input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { padding: 0; max-width: 100%; } -.tsd-nested-navigation > li > a { +.tsd-nested-navigation { margin-left: 3rem; } .tsd-nested-navigation > li > details { - margin-left: 1.5rem; + margin-left: -1.5rem; } -.tsd-small-nested-navigation > li > a { +.tsd-small-nested-navigation { margin-left: 1.5rem; } .tsd-small-nested-navigation > li > details { - margin-left: 0; + 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; } @@ -745,6 +769,13 @@ a.tsd-index-link { align-items: center; color: var(--color-text); } +.tsd-accordion-summary { + list-style-type: none; /* hide marker on non-safari */ + outline: none; /* broken on safari, so just hide it */ +} +.tsd-accordion-summary::-webkit-details-marker { + display: none; /* hide marker on safari */ +} .tsd-accordion-summary, .tsd-accordion-summary a { user-select: none; @@ -752,21 +783,19 @@ a.tsd-index-link { -webkit-user-select: none; -ms-user-select: none; - display: flex; - align-items: center; cursor: pointer; } +.tsd-accordion-summary a { + width: calc(100% - 1.5rem); +} .tsd-accordion-summary > * { margin-top: 0; margin-bottom: 0; padding-top: 0; padding-bottom: 0; } -.tsd-accordion-summary::-webkit-details-marker { - display: none; -} -.tsd-index-accordion .tsd-accordion-summary svg { - margin-right: 0.25rem; +.tsd-index-accordion .tsd-accordion-summary > svg { + margin-left: 0.25rem; } .tsd-index-content > :not(:first-child) { margin-top: 0.75rem; diff --git a/docs/classes/PubSubHandlerResponse.html b/docs/classes/PubSubHandlerResponse.html index 42315b3..30256cf 100644 --- a/docs/classes/PubSubHandlerResponse.html +++ b/docs/classes/PubSubHandlerResponse.html @@ -20,7 +20,7 @@

Hierarchy

  • PubSubHandlerResponse
+
  • Defined in src/types.ts:35
  • @@ -28,32 +28,32 @@

    Constructors

    - +

    Properties

    - +
    statusCode?: number
    +
  • Defined in src/types.ts:36
  • +
  • constructor
  • +
  • statusCode
  • +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/functions/createPubSubCloudFunctions.html b/docs/functions/createPubSubCloudFunctions.html index 2788cd7..676cba9 100644 --- a/docs/functions/createPubSubCloudFunctions.html +++ b/docs/functions/createPubSubCloudFunctions.html @@ -17,11 +17,11 @@

    Function createPubSubCloudFunctions

    +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/functions/handlePubSubMessage.html b/docs/functions/handlePubSubMessage.html index a62e55b..663a84c 100644 --- a/docs/functions/handlePubSubMessage.html +++ b/docs/functions/handlePubSubMessage.html @@ -17,11 +17,11 @@

    Function handlePubSubMessage

    +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/functions/makePubSubConfig.html b/docs/functions/makePubSubConfig.html index cd04ddc..417770d 100644 --- a/docs/functions/makePubSubConfig.html +++ b/docs/functions/makePubSubConfig.html @@ -17,11 +17,11 @@

    Function makePubSubConfig

    +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/functions/pubSubFastifyPlugin.html b/docs/functions/pubSubFastifyPlugin.html index 299994f..94be5c1 100644 --- a/docs/functions/pubSubFastifyPlugin.html +++ b/docs/functions/pubSubFastifyPlugin.html @@ -17,14 +17,11 @@

    Function pubSubFastifyPlugin

      - +
    • -

      FastifyPluginAsync

      -

      Fastify allows the user to extend its functionalities with plugins. A plugin can be a set of routes, a server decorator or whatever. To activate plugins, use the fastify.register() method.

      -
      -
      +

      Type Parameters

      -
        +
        • Data

        • @@ -33,17 +30,17 @@

          Context

      Parameters
      • -
        instance: FastifyInstance<RawServerDefault, IncomingMessage, ServerResponse<IncomingMessage>, FastifyBaseLogger, FastifyTypeProviderDefault>
      • +
        fastify: FastifyInstance<RawServerDefault, IncomingMessage, ServerResponse<IncomingMessage>, FastifyBaseLogger, FastifyTypeProviderDefault>
      • -
        opts: PubSubHandlerFastifyConfig<Data, Context>
      +
      options: PubSubHandlerFastifyConfig<Data, Context>

    Returns Promise<void>

    +
  • Defined in src/fastify-plugin.ts:14
  • +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/index.html b/docs/index.html index 3c09ba6..fe6486d 100644 --- a/docs/index.html +++ b/docs/index.html @@ -17,40 +17,40 @@

    pubsub-http-handler

    Index

    Classes

    -

    Interfaces

    -

    Type Aliases

    -

    Variables

    -

    Functions

    -
    +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/interfaces/HandlePubSubMessageArgs.html b/docs/interfaces/HandlePubSubMessageArgs.html index 9ac5cd2..9104ac2 100644 --- a/docs/interfaces/HandlePubSubMessageArgs.html +++ b/docs/interfaces/HandlePubSubMessageArgs.html @@ -15,9 +15,9 @@
  • pubsub-http-handler
  • HandlePubSubMessageArgs
  • Interface HandlePubSubMessageArgs<Data, Context, Logger>

    -
    +

    Type Parameters

    -
      +
      • Data

      • @@ -29,7 +29,7 @@

        Hierarchy

        • HandlePubSubMessageArgs
    +
  • Defined in src/common.ts:3
  • @@ -37,32 +37,32 @@

    Properties

    - +
    context: Context
    +
  • Defined in src/common.ts:8
  • - +
    handler: PubSubHandler<Data, Context, Logger>
    +
  • Defined in src/common.ts:5
  • - +
    log: Logger
    +
  • Defined in src/common.ts:9
  • - +
    message: {
        attributes?: Record<string, string>;
        data: string;
        messageId?: string;
    }

    Type declaration

    @@ -74,14 +74,14 @@
    data
    Optional messageId?: string
    +
  • Defined in src/common.ts:4
  • - +
    parseJson?: boolean
    +
  • Defined in src/common.ts:6
  • - +
    parser?: ((data) => Data | Promise<Data>)

    Type declaration

    @@ -97,12 +97,12 @@

    Parameters

    data: unknown

    Returns Data | Promise<Data>

    +
  • Defined in src/common.ts:7
  • +
  • context
  • +
  • handler
  • +
  • log
  • +
  • message
  • +
  • parseJson
  • +
  • parser
  • +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/interfaces/PubSubCloudFunctionsConfig.html b/docs/interfaces/PubSubCloudFunctionsConfig.html index e2cd5a0..89e39f8 100644 --- a/docs/interfaces/PubSubCloudFunctionsConfig.html +++ b/docs/interfaces/PubSubCloudFunctionsConfig.html @@ -15,9 +15,9 @@
  • pubsub-http-handler
  • PubSubCloudFunctionsConfig
  • Interface PubSubCloudFunctionsConfig<Data, Context>

    -
    +

    Type Parameters

    -
      +
      • Data

      • @@ -29,7 +29,7 @@

        Hierarchy

        • PubSubCloudFunctionsConfig
    +
  • Defined in src/cloud-functions.ts:7
  • @@ -37,17 +37,17 @@

    Properties

    - +
    context?: ((req?) => Context | Promise<Context>)

    Type declaration

    @@ -64,36 +64,38 @@
    Optional Returns Context | Promise<Context>
    +
  • Defined in src/cloud-functions.ts:11
  • - +
    logger?: LoggerOptions
    +
  • Defined in src/cloud-functions.ts:9
  • - +
    onError?: OnErrorHandler<Context>

    OnError Handler

    When this is set, errors will not be thrown.

    -
    +
  • Defined in src/types.ts:53
  • - +
    parseJson?: boolean

    This will run JSON.parse on request data

    Tip: false when sending strings

    - -

    Default

    true
    -
    +
    +
    +

    Default

    true
    +
    +
  • Defined in src/types.ts:65
  • - +
    parser?: ((data) => Data | Promise<Data>)

    Type declaration

    @@ -110,23 +112,24 @@
    data: Returns Data | Promise<Data>
    +
  • Defined in src/types.ts:55
  • - +
    path?: string

    Use this to set a different path

    - -

    Default

    /
    -
    +
    +
    +

    Default

    /
    +
    +
  • Defined in src/types.ts:71
  • +
  • context
  • +
  • logger
  • +
  • onError
  • +
  • parseJson
  • +
  • parser
  • +
  • path
  • +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/interfaces/PubSubConfig.html b/docs/interfaces/PubSubConfig.html index 6240f84..c9e6f2d 100644 --- a/docs/interfaces/PubSubConfig.html +++ b/docs/interfaces/PubSubConfig.html @@ -15,9 +15,9 @@
  • pubsub-http-handler
  • PubSubConfig
  • Interface PubSubConfig<Data, Context>

    -
    +

    Type Parameters

    -
    +
  • Defined in src/types.ts:46
  • @@ -38,16 +38,16 @@

    Properties

    - +
    context?: (() => Context | Promise<Context>)

    Type declaration

    @@ -58,29 +58,31 @@

    Type declaration

  • Returns Context | Promise<Context>

  • +
  • Defined in src/types.ts:57
  • - +
    onError?: OnErrorHandler<Context>

    OnError Handler

    When this is set, errors will not be thrown.

    -
    +
  • Defined in src/types.ts:53
  • - +
    parseJson?: boolean

    This will run JSON.parse on request data

    Tip: false when sending strings

    - -

    Default

    true
    -
    +
    +
    +

    Default

    true
    +
    +
  • Defined in src/types.ts:65
  • - +
    parser?: ((data) => Data | Promise<Data>)

    Type declaration

    @@ -96,22 +98,23 @@

    Parameters

    data: unknown

    Returns Data | Promise<Data>

    +
  • Defined in src/types.ts:55
  • - +
    path?: string

    Use this to set a different path

    - -

    Default

    /
    -
    +
    +
    +

    Default

    /
    +
    +
  • Defined in src/types.ts:71
  • +
  • context
  • +
  • onError
  • +
  • parseJson
  • +
  • parser
  • +
  • path
  • +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/interfaces/PubSubHandlerFastifyConfig.html b/docs/interfaces/PubSubHandlerFastifyConfig.html index 79b835e..3151f70 100644 --- a/docs/interfaces/PubSubHandlerFastifyConfig.html +++ b/docs/interfaces/PubSubHandlerFastifyConfig.html @@ -15,9 +15,9 @@
  • pubsub-http-handler
  • PubSubHandlerFastifyConfig
  • Interface PubSubHandlerFastifyConfig<Data, Context>

    -
    +

    Type Parameters

    -
      +
      • Data

      • @@ -29,7 +29,7 @@

        Hierarchy

        • PubSubHandlerFastifyConfig
    +
  • Defined in src/fastify-plugin.ts:7
  • @@ -37,17 +37,17 @@

    Properties

    - +
    context?: ((req?) => Context | Promise<Context>)

    Type declaration

    @@ -64,36 +64,38 @@
    Optional Returns Context | Promise<Context>
    +
  • Defined in src/fastify-plugin.ts:11
  • - +
    handler: PubSubHandler<Data, Context, FastifyBaseLogger>
    +
  • Defined in src/fastify-plugin.ts:9
  • - +
    onError?: OnErrorHandler<Context>

    OnError Handler

    When this is set, errors will not be thrown.

    -
    +
  • Defined in src/types.ts:53
  • - +
    parseJson?: boolean

    This will run JSON.parse on request data

    Tip: false when sending strings

    - -

    Default

    true
    -
    +
    +
    +

    Default

    true
    +
    +
  • Defined in src/types.ts:65
  • - +
    parser?: ((data) => Data | Promise<Data>)

    Type declaration

    @@ -110,23 +112,24 @@
    data: Returns Data | Promise<Data>
    +
  • Defined in src/types.ts:55
  • - +
    path?: string

    Use this to set a different path

    - -

    Default

    /
    -
    +
    +
    +

    Default

    /
    +
    +
  • Defined in src/types.ts:71
  • +
  • context
  • +
  • handler
  • +
  • onError
  • +
  • parseJson
  • +
  • parser
  • +
  • path
  • +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/types/CloudFunctionFun.html b/docs/types/CloudFunctionFun.html index d06f21f..73fcf67 100644 --- a/docs/types/CloudFunctionFun.html +++ b/docs/types/CloudFunctionFun.html @@ -32,12 +32,12 @@
    req: res: express.Response

    Returns Promise<void>

    +
  • Defined in src/cloud-functions.ts:14
  • +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/types/OnErrorHandler.html b/docs/types/OnErrorHandler.html index be55a9d..2cd4d56 100644 --- a/docs/types/OnErrorHandler.html +++ b/docs/types/OnErrorHandler.html @@ -16,9 +16,9 @@
  • OnErrorHandler
  • Type alias OnErrorHandler<Context>

    OnErrorHandler<Context>: ((error, context) => void | Promise<void>)
    -
    +

    Type Parameters

    -
      +
      • Context

    @@ -37,12 +37,12 @@
    error: context: Context

    Returns void | Promise<void>

    +
  • Defined in src/types.ts:30
  • +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/types/PubSubHandler.html b/docs/types/PubSubHandler.html index 9092f0b..cd499d6 100644 --- a/docs/types/PubSubHandler.html +++ b/docs/types/PubSubHandler.html @@ -16,9 +16,9 @@
  • PubSubHandler
  • Type alias PubSubHandler<Data, Context, Logger>

    PubSubHandler<Data, Context, Logger>: ((args) => Promise<PubSubHandlerResponse | void> | PubSubHandlerResponse | void)
    -
    +

    Type Parameters

    -

    Returns Promise<PubSubHandlerResponse | void> | PubSubHandlerResponse | void

    +
  • Defined in src/types.ts:39
  • +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/types/PubSubMessage.html b/docs/types/PubSubMessage.html index 6f8ce07..af1ffaa 100644 --- a/docs/types/PubSubMessage.html +++ b/docs/types/PubSubMessage.html @@ -17,12 +17,12 @@

    Type alias PubSubMessage

    PubSubMessage: Static<typeof pubSubMessageSchema>
    +
  • Defined in src/types.ts:15
  • +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/types/PubSubRequest.html b/docs/types/PubSubRequest.html index 6275d28..6b87213 100644 --- a/docs/types/PubSubRequest.html +++ b/docs/types/PubSubRequest.html @@ -17,12 +17,12 @@

    Type alias PubSubRequest

    PubSubRequest: Static<typeof pubSubRequestSchema>
    +
  • Defined in src/types.ts:28
  • +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/variables/pubSubMessageSchema.html b/docs/variables/pubSubMessageSchema.html index 520ff3c..3444fb6 100644 --- a/docs/variables/pubSubMessageSchema.html +++ b/docs/variables/pubSubMessageSchema.html @@ -19,14 +19,24 @@

    Variable pubSubMessageSchemaConst

    PubSub Message Type

    This describes the message object that is sent to the handler from Google PubSub.

    -
    +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/docs/variables/pubSubRequestSchema.html b/docs/variables/pubSubRequestSchema.html index 6b1f237..a4fa92e 100644 --- a/docs/variables/pubSubRequestSchema.html +++ b/docs/variables/pubSubRequestSchema.html @@ -19,14 +19,22 @@

    Variable pubSubRequestSchemaConst

    PubSub Request Type

    This describes the request object that is sent to the handler from Google PubSub.

    -
    +
  • PubSubHandlerResponse
  • +
  • HandlePubSubMessageArgs
  • +
  • PubSubCloudFunctionsConfig
  • +
  • PubSubConfig
  • +
  • PubSubHandlerFastifyConfig
  • +
  • CloudFunctionFun
  • +
  • OnErrorHandler
  • +
  • PubSubHandler
  • +
  • PubSubMessage
  • +
  • PubSubRequest
  • +
  • pubSubMessageSchema
  • +
  • pubSubRequestSchema
  • +
  • createPubSubCloudFunctions
  • +
  • handlePubSubMessage
  • +
  • makePubSubConfig
  • +
  • pubSubFastifyPlugin
  • Generated using TypeDoc

    \ No newline at end of file diff --git a/package.json b/package.json index 73d1a80..b57ffe8 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "scripts": { "build": "tsc", "lint": "eslint '**/*.ts' --fix", - "generate:docs": "typedoc --gitRevision branch --readme none --out docs src", + "generate:docs": "typedoc --gitRevision main --readme none --out docs src", "test": "jest --coverage src", "prepare": "husky install" }, From 0a351287b2d75c579cb69aea4b9551fa58e8773a Mon Sep 17 00:00:00 2001 From: "Simen A. W. Olsen" Date: Sun, 30 Jul 2023 14:41:22 +0200 Subject: [PATCH 3/3] use markdown for docs --- docs/README.md | 289 ++++ docs/assets/highlight.css | 36 - docs/assets/main.js | 58 - docs/assets/search.js | 1 - docs/assets/style.css | 1367 ----------------- docs/classes/PubSubHandlerResponse.html | 94 -- docs/classes/PubSubHandlerResponse.md | 29 + .../functions/createPubSubCloudFunctions.html | 75 - docs/functions/handlePubSubMessage.html | 75 - docs/functions/makePubSubConfig.html | 73 - docs/functions/pubSubFastifyPlugin.html | 75 - docs/index.html | 85 - docs/interfaces/HandlePubSubMessageArgs.html | 147 -- docs/interfaces/HandlePubSubMessageArgs.md | 104 ++ .../PubSubCloudFunctionsConfig.html | 174 --- docs/interfaces/PubSubCloudFunctionsConfig.md | 158 ++ docs/interfaces/PubSubConfig.html | 158 -- docs/interfaces/PubSubConfig.md | 123 ++ .../PubSubHandlerFastifyConfig.html | 174 --- docs/interfaces/PubSubHandlerFastifyConfig.md | 158 ++ docs/types/CloudFunctionFun.html | 72 - docs/types/OnErrorHandler.html | 77 - docs/types/PubSubHandler.html | 88 -- docs/types/PubSubMessage.html | 57 - docs/types/PubSubRequest.html | 57 - docs/variables/pubSubMessageSchema.html | 71 - docs/variables/pubSubRequestSchema.html | 69 - package.json | 2 +- 28 files changed, 862 insertions(+), 3084 deletions(-) create mode 100644 docs/README.md delete mode 100644 docs/assets/highlight.css delete mode 100644 docs/assets/main.js delete mode 100644 docs/assets/search.js delete mode 100644 docs/assets/style.css delete mode 100644 docs/classes/PubSubHandlerResponse.html create mode 100644 docs/classes/PubSubHandlerResponse.md delete mode 100644 docs/functions/createPubSubCloudFunctions.html delete mode 100644 docs/functions/handlePubSubMessage.html delete mode 100644 docs/functions/makePubSubConfig.html delete mode 100644 docs/functions/pubSubFastifyPlugin.html delete mode 100644 docs/index.html delete mode 100644 docs/interfaces/HandlePubSubMessageArgs.html create mode 100644 docs/interfaces/HandlePubSubMessageArgs.md delete mode 100644 docs/interfaces/PubSubCloudFunctionsConfig.html create mode 100644 docs/interfaces/PubSubCloudFunctionsConfig.md delete mode 100644 docs/interfaces/PubSubConfig.html create mode 100644 docs/interfaces/PubSubConfig.md delete mode 100644 docs/interfaces/PubSubHandlerFastifyConfig.html create mode 100644 docs/interfaces/PubSubHandlerFastifyConfig.md delete mode 100644 docs/types/CloudFunctionFun.html delete mode 100644 docs/types/OnErrorHandler.html delete mode 100644 docs/types/PubSubHandler.html delete mode 100644 docs/types/PubSubMessage.html delete mode 100644 docs/types/PubSubRequest.html delete mode 100644 docs/variables/pubSubMessageSchema.html delete mode 100644 docs/variables/pubSubRequestSchema.html diff --git a/docs/README.md b/docs/README.md new file mode 100644 index 0000000..d7d262c --- /dev/null +++ b/docs/README.md @@ -0,0 +1,289 @@ +pubsub-http-handler + +# pubsub-http-handler + +## Table of contents + +### Classes + +- [PubSubHandlerResponse](classes/PubSubHandlerResponse.md) + +### Interfaces + +- [HandlePubSubMessageArgs](interfaces/HandlePubSubMessageArgs.md) +- [PubSubCloudFunctionsConfig](interfaces/PubSubCloudFunctionsConfig.md) +- [PubSubConfig](interfaces/PubSubConfig.md) +- [PubSubHandlerFastifyConfig](interfaces/PubSubHandlerFastifyConfig.md) + +### Type Aliases + +- [CloudFunctionFun](README.md#cloudfunctionfun) +- [OnErrorHandler](README.md#onerrorhandler) +- [PubSubHandler](README.md#pubsubhandler) +- [PubSubMessage](README.md#pubsubmessage) +- [PubSubRequest](README.md#pubsubrequest) + +### Variables + +- [pubSubMessageSchema](README.md#pubsubmessageschema) +- [pubSubRequestSchema](README.md#pubsubrequestschema) + +### Functions + +- [createPubSubCloudFunctions](README.md#createpubsubcloudfunctions) +- [handlePubSubMessage](README.md#handlepubsubmessage) +- [makePubSubConfig](README.md#makepubsubconfig) +- [pubSubFastifyPlugin](README.md#pubsubfastifyplugin) + +## Type Aliases + +### CloudFunctionFun + +Ƭ **CloudFunctionFun**: (`req`: `express.Request`, `res`: `express.Response`) => `Promise`<`void`\> + +#### Type declaration + +▸ (`req`, `res`): `Promise`<`void`\> + +##### Parameters + +| Name | Type | +| :------ | :------ | +| `req` | `express.Request` | +| `res` | `express.Response` | + +##### Returns + +`Promise`<`void`\> + +#### Defined in + +[src/cloud-functions.ts:14](https://github.com/simenandre/pubsub-http-handler/blob/main/src/cloud-functions.ts#L14) + +___ + +### OnErrorHandler + +Ƭ **OnErrorHandler**<`Context`\>: (`error`: `unknown`, `context`: `Context`) => `void` \| `Promise`<`void`\> + +#### Type parameters + +| Name | +| :------ | +| `Context` | + +#### Type declaration + +▸ (`error`, `context`): `void` \| `Promise`<`void`\> + +##### Parameters + +| Name | Type | +| :------ | :------ | +| `error` | `unknown` | +| `context` | `Context` | + +##### Returns + +`void` \| `Promise`<`void`\> + +#### Defined in + +[src/types.ts:30](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L30) + +___ + +### PubSubHandler + +Ƭ **PubSubHandler**<`Data`, `Context`, `Logger`\>: (`args`: { `context`: `Context` ; `data`: `Data` ; `log`: `Logger` ; `message`: [`PubSubMessage`](README.md#pubsubmessage) }) => `Promise`<[`PubSubHandlerResponse`](classes/PubSubHandlerResponse.md) \| `void`\> \| [`PubSubHandlerResponse`](classes/PubSubHandlerResponse.md) \| `void` + +#### Type parameters + +| Name | +| :------ | +| `Data` | +| `Context` | +| `Logger` | + +#### Type declaration + +▸ (`args`): `Promise`<[`PubSubHandlerResponse`](classes/PubSubHandlerResponse.md) \| `void`\> \| [`PubSubHandlerResponse`](classes/PubSubHandlerResponse.md) \| `void` + +##### Parameters + +| Name | Type | +| :------ | :------ | +| `args` | `Object` | +| `args.context` | `Context` | +| `args.data` | `Data` | +| `args.log` | `Logger` | +| `args.message` | [`PubSubMessage`](README.md#pubsubmessage) | + +##### Returns + +`Promise`<[`PubSubHandlerResponse`](classes/PubSubHandlerResponse.md) \| `void`\> \| [`PubSubHandlerResponse`](classes/PubSubHandlerResponse.md) \| `void` + +#### Defined in + +[src/types.ts:39](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L39) + +___ + +### PubSubMessage + +Ƭ **PubSubMessage**: `Static` + +#### Defined in + +[src/types.ts:15](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L15) + +___ + +### PubSubRequest + +Ƭ **PubSubRequest**: `Static` + +#### Defined in + +[src/types.ts:28](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L28) + +## Variables + +### pubSubMessageSchema + +• `Const` **pubSubMessageSchema**: `TObject`<{ `attributes`: `TOptional`<`TRecord`<`TString`, `TString`\>\> ; `data`: `TString` ; `messageId`: `TOptional`<`TString`\> }\> + +PubSub Message Type + +This describes the message object that is sent to the handler +from Google PubSub. + +#### Defined in + +[src/types.ts:9](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L9) + +___ + +### pubSubRequestSchema + +• `Const` **pubSubRequestSchema**: `TObject`<{ `message`: `TObject`<{ `attributes`: `TOptional`<`TRecord`<`TString`, `TString`\>\> ; `data`: `TString` ; `messageId`: `TOptional`<`TString`\> }\> = pubSubMessageSchema; `subscription`: `TString` }\> + +PubSub Request Type + +This describes the request object that is sent to the handler +from Google PubSub. + +#### Defined in + +[src/types.ts:23](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L23) + +## Functions + +### createPubSubCloudFunctions + +▸ **createPubSubCloudFunctions**<`Data`, `Context`\>(`handler`, `options?`): [`CloudFunctionFun`](README.md#cloudfunctionfun) + +#### Type parameters + +| Name | Type | +| :------ | :------ | +| `Data` | `unknown` | +| `Context` | `unknown` | + +#### Parameters + +| Name | Type | +| :------ | :------ | +| `handler` | [`PubSubHandler`](README.md#pubsubhandler)<`Data`, `Context`, `Logger`<`LoggerOptions`\>\> | +| `options` | [`PubSubCloudFunctionsConfig`](interfaces/PubSubCloudFunctionsConfig.md)<`Data`, `Context`\> | + +#### Returns + +[`CloudFunctionFun`](README.md#cloudfunctionfun) + +#### Defined in + +[src/cloud-functions.ts:19](https://github.com/simenandre/pubsub-http-handler/blob/main/src/cloud-functions.ts#L19) + +___ + +### handlePubSubMessage + +▸ **handlePubSubMessage**<`Data`, `Context`, `Logger`\>(`args`): `Promise`<[`PubSubHandlerResponse`](classes/PubSubHandlerResponse.md) \| `void`\> + +#### Type parameters + +| Name | +| :------ | +| `Data` | +| `Context` | +| `Logger` | + +#### Parameters + +| Name | Type | +| :------ | :------ | +| `args` | [`HandlePubSubMessageArgs`](interfaces/HandlePubSubMessageArgs.md)<`Data`, `Context`, `Logger`\> | + +#### Returns + +`Promise`<[`PubSubHandlerResponse`](classes/PubSubHandlerResponse.md) \| `void`\> + +#### Defined in + +[src/common.ts:12](https://github.com/simenandre/pubsub-http-handler/blob/main/src/common.ts#L12) + +___ + +### makePubSubConfig + +▸ **makePubSubConfig**<`Data`, `Context`\>(`data`): [`PubSubHandlerFastifyConfig`](interfaces/PubSubHandlerFastifyConfig.md)<`Data`, `Context`\> + +#### Type parameters + +| Name | +| :------ | +| `Data` | +| `Context` | + +#### Parameters + +| Name | Type | +| :------ | :------ | +| `data` | [`PubSubHandlerFastifyConfig`](interfaces/PubSubHandlerFastifyConfig.md)<`Data`, `Context`\> | + +#### Returns + +[`PubSubHandlerFastifyConfig`](interfaces/PubSubHandlerFastifyConfig.md)<`Data`, `Context`\> + +#### Defined in + +[src/utils.ts:3](https://github.com/simenandre/pubsub-http-handler/blob/main/src/utils.ts#L3) + +___ + +### pubSubFastifyPlugin + +▸ **pubSubFastifyPlugin**<`Data`, `Context`\>(`fastify`, `options`): `Promise`<`void`\> + +#### Type parameters + +| Name | +| :------ | +| `Data` | +| `Context` | + +#### Parameters + +| Name | Type | +| :------ | :------ | +| `fastify` | `FastifyInstance`<`RawServerDefault`, `IncomingMessage`, `ServerResponse`<`IncomingMessage`\>, `FastifyBaseLogger`, `FastifyTypeProviderDefault`\> | +| `options` | [`PubSubHandlerFastifyConfig`](interfaces/PubSubHandlerFastifyConfig.md)<`Data`, `Context`\> | + +#### Returns + +`Promise`<`void`\> + +#### Defined in + +[src/fastify-plugin.ts:14](https://github.com/simenandre/pubsub-http-handler/blob/main/src/fastify-plugin.ts#L14) diff --git a/docs/assets/highlight.css b/docs/assets/highlight.css deleted file mode 100644 index 1797828..0000000 --- a/docs/assets/highlight.css +++ /dev/null @@ -1,36 +0,0 @@ -:root { - --light-hl-0: #0000FF; - --dark-hl-0: #569CD6; - --light-hl-1: #000000; - --dark-hl-1: #D4D4D4; - --light-code-background: #FFFFFF; - --dark-code-background: #1E1E1E; -} - -@media (prefers-color-scheme: light) { :root { - --hl-0: var(--light-hl-0); - --hl-1: var(--light-hl-1); - --code-background: var(--light-code-background); -} } - -@media (prefers-color-scheme: dark) { :root { - --hl-0: var(--dark-hl-0); - --hl-1: var(--dark-hl-1); - --code-background: var(--dark-code-background); -} } - -:root[data-theme='light'] { - --hl-0: var(--light-hl-0); - --hl-1: var(--light-hl-1); - --code-background: var(--light-code-background); -} - -:root[data-theme='dark'] { - --hl-0: var(--dark-hl-0); - --hl-1: var(--dark-hl-1); - --code-background: var(--dark-code-background); -} - -.hl-0 { color: var(--hl-0); } -.hl-1 { color: var(--hl-1); } -pre, code { background: var(--code-background); } diff --git a/docs/assets/main.js b/docs/assets/main.js deleted file mode 100644 index 4c8fa61..0000000 --- a/docs/assets/main.js +++ /dev/null @@ -1,58 +0,0 @@ -"use strict"; -"use strict";(()=>{var Se=Object.create;var re=Object.defineProperty;var we=Object.getOwnPropertyDescriptor;var Te=Object.getOwnPropertyNames;var ke=Object.getPrototypeOf,Qe=Object.prototype.hasOwnProperty;var Pe=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Ie=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Te(e))!Qe.call(t,i)&&i!==r&&re(t,i,{get:()=>e[i],enumerable:!(n=we(e,i))||n.enumerable});return t};var Ce=(t,e,r)=>(r=t!=null?Se(ke(t)):{},Ie(e||!t||!t.__esModule?re(r,"default",{value:t,enumerable:!0}):r,t));var ae=Pe((se,oe)=>{(function(){var t=function(e){var r=new t.Builder;return r.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),r.searchPipeline.add(t.stemmer),e.call(r,r),r.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){return function(r){e.console&&console.warn&&console.warn(r)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var r=Object.create(null),n=Object.keys(e),i=0;i0){var d=t.utils.clone(r)||{};d.position=[a,u],d.index=s.length,s.push(new t.Token(n.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,r){r in this.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+r),e.label=r,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){var r=e.label&&e.label in this.registeredFunctions;r||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index. -`,e)},t.Pipeline.load=function(e){var r=new t.Pipeline;return e.forEach(function(n){var i=t.Pipeline.registeredFunctions[n];if(i)r.add(i);else throw new Error("Cannot load unregistered function: "+n)}),r},t.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach(function(r){t.Pipeline.warnIfFunctionNotRegistered(r),this._stack.push(r)},this)},t.Pipeline.prototype.after=function(e,r){t.Pipeline.warnIfFunctionNotRegistered(r);var n=this._stack.indexOf(e);if(n==-1)throw new Error("Cannot find existingFn");n=n+1,this._stack.splice(n,0,r)},t.Pipeline.prototype.before=function(e,r){t.Pipeline.warnIfFunctionNotRegistered(r);var n=this._stack.indexOf(e);if(n==-1)throw new Error("Cannot find existingFn");this._stack.splice(n,0,r)},t.Pipeline.prototype.remove=function(e){var r=this._stack.indexOf(e);r!=-1&&this._stack.splice(r,1)},t.Pipeline.prototype.run=function(e){for(var r=this._stack.length,n=0;n1&&(oe&&(n=s),o!=e);)i=n-r,s=r+Math.floor(i/2),o=this.elements[s*2];if(o==e||o>e)return s*2;if(ol?d+=2:a==l&&(r+=n[u+1]*i[d+1],u+=2,d+=2);return r},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),r=1,n=0;r0){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),m=s.str.charAt(1),y;m in s.node.edges?y=s.node.edges[m]:(y=new t.TokenSet,s.node.edges[m]=y),s.str.length==1&&(y.final=!0),i.push({node:y,editsRemaining:s.editsRemaining-1,str:d+s.str.slice(2)})}}}return n},t.TokenSet.fromString=function(e){for(var r=new t.TokenSet,n=r,i=0,s=e.length;i=e;r--){var n=this.uncheckedNodes[r],i=n.child.toString();i in this.minimizedNodes?n.parent.edges[n.char]=this.minimizedNodes[i]:(n.child._str=i,this.minimizedNodes[i]=n.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(r){var n=new t.QueryParser(e,r);n.parse()})},t.Index.prototype.query=function(e){for(var r=new t.Query(this.fields),n=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,r){var n=e[this._ref],i=Object.keys(this._fields);this._documents[n]=r||{},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,r;do e=this.next(),r=e.charCodeAt(0);while(r>47&&r<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 r=e.next();if(r==t.QueryLexer.EOS)return t.QueryLexer.lexEOS;if(r.charCodeAt(0)==92){e.escapeCharacter();continue}if(r==":")return t.QueryLexer.lexField;if(r=="~")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexEditDistance;if(r=="^")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexBoost;if(r=="+"&&e.width()===1||r=="-"&&e.width()===1)return e.emit(t.QueryLexer.PRESENCE),t.QueryLexer.lexText;if(r.match(t.QueryLexer.termSeparator))return t.QueryLexer.lexTerm}},t.QueryParser=function(e,r){this.lexer=new t.QueryLexer(e),this.query=r,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 r=e.peekLexeme();if(r!=null)switch(r.type){case t.QueryLexer.PRESENCE:return t.QueryParser.parsePresence;case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var n="expected either a field or a term, found "+r.type;throw r.str.length>=1&&(n+=" with value '"+r.str+"'"),new t.QueryParseError(n,r.start,r.end)}},t.QueryParser.parsePresence=function(e){var r=e.consumeLexeme();if(r!=null){switch(r.str){case"-":e.currentClause.presence=t.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=t.Query.presence.REQUIRED;break;default:var n="unrecognised presence operator'"+r.str+"'";throw new t.QueryParseError(n,r.start,r.end)}var i=e.peekLexeme();if(i==null){var n="expecting term or field, found nothing";throw new t.QueryParseError(n,r.start,r.end)}switch(i.type){case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var n="expecting term or field, found '"+i.type+"'";throw new t.QueryParseError(n,i.start,i.end)}}},t.QueryParser.parseField=function(e){var r=e.consumeLexeme();if(r!=null){if(e.query.allFields.indexOf(r.str)==-1){var n=e.query.allFields.map(function(o){return"'"+o+"'"}).join(", "),i="unrecognised field '"+r.str+"', possible fields: "+n;throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.fields=[r.str];var s=e.peekLexeme();if(s==null){var i="expecting term, found nothing";throw new t.QueryParseError(i,r.start,r.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 r=e.consumeLexeme();if(r!=null){e.currentClause.term=r.str.toLowerCase(),r.str.indexOf("*")!=-1&&(e.currentClause.usePipeline=!1);var n=e.peekLexeme();if(n==null){e.nextClause();return}switch(n.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+n.type+"'";throw new t.QueryParseError(i,n.start,n.end)}}},t.QueryParser.parseEditDistance=function(e){var r=e.consumeLexeme();if(r!=null){var n=parseInt(r.str,10);if(isNaN(n)){var i="edit distance must be numeric";throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.editDistance=n;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 r=e.consumeLexeme();if(r!=null){var n=parseInt(r.str,10);if(isNaN(n)){var i="boost must be numeric";throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.boost=n;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,r){typeof define=="function"&&define.amd?define(r):typeof se=="object"?oe.exports=r():e.lunr=r()}(this,function(){return t})})()});var ne=[];function G(t,e){ne.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){ne.forEach(r=>{e.querySelectorAll(r.selector).forEach(n=>{n.dataset.hasInstance||(new r.constructor({el:n,app:this}),n.dataset.hasInstance=String(!0))})})}filterChanged(){this.ensureFocusedElementVisible()}ensureActivePageVisible(){let e=document.querySelector(".tsd-navigation .current"),r=e?.parentElement;for(;r&&!r.classList.contains(".tsd-navigation");)r instanceof HTMLDetailsElement&&(r.open=!0),r=r.parentElement;if(e){let n=e.getBoundingClientRect().top-document.documentElement.clientHeight/4;document.querySelector(".site-menu").scrollTop=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 r=e.parentElement;for(;r&&r.tagName!=="SECTION";)r=r.parentElement;if(r&&r.offsetParent==null){this.alwaysVisibleMember=r,r.classList.add("always-visible");let n=document.createElement("p");n.classList.add("warning"),n.textContent="This member is normally hidden due to your filter settings.",r.prepend(n)}}listenForCodeCopies(){document.querySelectorAll("pre > button").forEach(e=>{let r;e.addEventListener("click",()=>{e.previousElementSibling instanceof HTMLElement&&navigator.clipboard.writeText(e.previousElementSibling.innerText.trim()),e.textContent="Copied!",e.classList.add("visible"),clearTimeout(r),r=setTimeout(()=>{e.classList.remove("visible"),r=setTimeout(()=>{e.textContent="Copy"},100)},1e3)})})}};var ie=(t,e=100)=>{let r;return()=>{clearTimeout(r),r=setTimeout(()=>t(),e)}};var ce=Ce(ae());function de(){let t=document.getElementById("tsd-search");if(!t)return;let e=document.getElementById("tsd-search-script");t.classList.add("loading"),e&&(e.addEventListener("error",()=>{t.classList.remove("loading"),t.classList.add("failure")}),e.addEventListener("load",()=>{t.classList.remove("loading"),t.classList.add("ready")}),window.searchData&&t.classList.remove("loading"));let r=document.querySelector("#tsd-search input"),n=document.querySelector("#tsd-search .results");if(!r||!n)throw new Error("The input field or the result list wrapper was not found");let i=!1;n.addEventListener("mousedown",()=>i=!0),n.addEventListener("mouseup",()=>{i=!1,t.classList.remove("has-focus")}),r.addEventListener("focus",()=>t.classList.add("has-focus")),r.addEventListener("blur",()=>{i||(i=!1,t.classList.remove("has-focus"))});let s={base:t.dataset.base+"/"};Oe(t,n,r,s)}function Oe(t,e,r,n){r.addEventListener("input",ie(()=>{Re(t,e,r,n)},200));let i=!1;r.addEventListener("keydown",s=>{i=!0,s.key=="Enter"?Fe(e,r):s.key=="Escape"?r.blur():s.key=="ArrowUp"?ue(e,-1):s.key==="ArrowDown"?ue(e,1):i=!1}),r.addEventListener("keypress",s=>{i&&s.preventDefault()}),document.body.addEventListener("keydown",s=>{s.altKey||s.ctrlKey||s.metaKey||!r.matches(":focus")&&s.key==="/"&&(r.focus(),s.preventDefault())})}function _e(t,e){t.index||window.searchData&&(e.classList.remove("loading"),e.classList.add("ready"),t.data=window.searchData,t.index=ce.Index.load(window.searchData.index))}function Re(t,e,r,n){if(_e(n,t),!n.index||!n.data)return;e.textContent="";let i=r.value.trim(),s=i?n.index.search(`*${i}*`):[];for(let o=0;oa.score-o.score);for(let o=0,a=Math.min(10,s.length);o${le(l.parent,i)}.${u}`);let d=document.createElement("li");d.classList.value=l.classes??"";let m=document.createElement("a");m.href=n.base+l.url,m.innerHTML=u,d.append(m),e.appendChild(d)}}function ue(t,e){let r=t.querySelector(".current");if(!r)r=t.querySelector(e==1?"li:first-child":"li:last-child"),r&&r.classList.add("current");else{let n=r;if(e===1)do n=n.nextElementSibling??void 0;while(n instanceof HTMLElement&&n.offsetParent==null);else do n=n.previousElementSibling??void 0;while(n instanceof HTMLElement&&n.offsetParent==null);n&&(r.classList.remove("current"),n.classList.add("current"))}}function Fe(t,e){let r=t.querySelector(".current");if(r||(r=t.querySelector("li:first-child")),r){let n=r.querySelector("a");n&&(window.location.href=n.href),e.blur()}}function le(t,e){if(e==="")return t;let r=t.toLocaleLowerCase(),n=e.toLocaleLowerCase(),i=[],s=0,o=r.indexOf(n);for(;o!=-1;)i.push(K(t.substring(s,o)),`${K(t.substring(o,o+n.length))}`),s=o+n.length,o=r.indexOf(n,s);return i.push(K(t.substring(s))),i.join("")}var Me={"&":"&","<":"<",">":">","'":"'",'"':"""};function K(t){return t.replace(/[&<>"'"]/g,e=>Me[e])}var P=class{constructor(e){this.el=e.el,this.app=e.app}};var M="mousedown",fe="mousemove",N="mouseup",J={x:0,y:0},he=!1,ee=!1,De=!1,D=!1,pe=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);document.documentElement.classList.add(pe?"is-mobile":"not-mobile");pe&&"ontouchstart"in document.documentElement&&(De=!0,M="touchstart",fe="touchmove",N="touchend");document.addEventListener(M,t=>{ee=!0,D=!1;let e=M=="touchstart"?t.targetTouches[0]:t;J.y=e.pageY||0,J.x=e.pageX||0});document.addEventListener(fe,t=>{if(ee&&!D){let e=M=="touchstart"?t.targetTouches[0]:t,r=J.x-(e.pageX||0),n=J.y-(e.pageY||0);D=Math.sqrt(r*r+n*n)>10}});document.addEventListener(N,()=>{ee=!1});document.addEventListener("click",t=>{he&&(t.preventDefault(),t.stopImmediatePropagation(),he=!1)});var X=class extends P{constructor(r){super(r);this.className=this.el.dataset.toggle||"",this.el.addEventListener(N,n=>this.onPointerUp(n)),this.el.addEventListener("click",n=>n.preventDefault()),document.addEventListener(M,n=>this.onDocumentPointerDown(n)),document.addEventListener(N,n=>this.onDocumentPointerUp(n))}setActive(r){if(this.active==r)return;this.active=r,document.documentElement.classList.toggle("has-"+this.className,r),this.el.classList.toggle("active",r);let n=(this.active?"to-has-":"from-has-")+this.className;document.documentElement.classList.add(n),setTimeout(()=>document.documentElement.classList.remove(n),500)}onPointerUp(r){D||(this.setActive(!0),r.preventDefault())}onDocumentPointerDown(r){if(this.active){if(r.target.closest(".col-sidebar, .tsd-filter-group"))return;this.setActive(!1)}}onDocumentPointerUp(r){if(!D&&this.active&&r.target.closest(".col-sidebar")){let n=r.target.closest("a");if(n){let i=window.location.href;i.indexOf("#")!=-1&&(i=i.substring(0,i.indexOf("#"))),n.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 me=document.head.appendChild(document.createElement("style"));me.dataset.for="filters";var Y=class extends P{constructor(r){super(r);this.key=`filter-${this.el.name}`,this.value=this.el.checked,this.el.addEventListener("change",()=>{this.setLocalStorage(this.el.checked)}),this.setLocalStorage(this.fromLocalStorage()),me.innerHTML+=`html:not(.${this.key}) .tsd-is-${this.el.name} { display: none; } -`}fromLocalStorage(){let r=Q.getItem(this.key);return r?r==="true":this.el.checked}setLocalStorage(r){Q.setItem(this.key,r.toString()),this.value=r,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(r=>{r.style.display="block";let n=Array.from(r.querySelectorAll(".tsd-index-link")).every(i=>i.offsetParent==null);r.style.display=n?"none":"block"})}};var Z=class extends P{constructor(r){super(r);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()),this.update()}update(){this.icon.style.transform=`rotate(${this.el.open?0:-90}deg)`,Q.setItem(this.key,this.el.open.toString())}};function ve(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}de();G(X,"a[data-toggle]");G(Z,".tsd-index-accordion");G(Y,".tsd-filter-item input[type=checkbox]");var ge=document.getElementById("tsd-theme");ge&&ve(ge);var Ae=new U;Object.defineProperty(window,"app",{value:Ae});document.querySelectorAll("summary a").forEach(t=>{t.addEventListener("click",()=>{location.assign(t.href)})});})(); -/*! Bundled license information: - -lunr/lunr.js: - (** - * lunr - http://lunrjs.com - A bit like Solr, but much smaller and not as bright - 2.3.9 - * Copyright (C) 2020 Oliver Nightingale - * @license MIT - *) - (*! - * lunr.utils - * Copyright (C) 2020 Oliver Nightingale - *) - (*! - * lunr.Set - * Copyright (C) 2020 Oliver Nightingale - *) - (*! - * lunr.tokenizer - * Copyright (C) 2020 Oliver Nightingale - *) - (*! - * lunr.Pipeline - * Copyright (C) 2020 Oliver Nightingale - *) - (*! - * lunr.Vector - * Copyright (C) 2020 Oliver Nightingale - *) - (*! - * lunr.stemmer - * Copyright (C) 2020 Oliver Nightingale - * Includes code from - http://tartarus.org/~martin/PorterStemmer/js.txt - *) - (*! - * lunr.stopWordFilter - * Copyright (C) 2020 Oliver Nightingale - *) - (*! - * lunr.trimmer - * Copyright (C) 2020 Oliver Nightingale - *) - (*! - * lunr.TokenSet - * Copyright (C) 2020 Oliver Nightingale - *) - (*! - * lunr.Index - * Copyright (C) 2020 Oliver Nightingale - *) - (*! - * lunr.Builder - * Copyright (C) 2020 Oliver Nightingale - *) -*/ diff --git a/docs/assets/search.js b/docs/assets/search.js deleted file mode 100644 index 6ed35c9..0000000 --- a/docs/assets/search.js +++ /dev/null @@ -1 +0,0 @@ -window.searchData = JSON.parse("{\"rows\":[{\"kind\":64,\"name\":\"createPubSubCloudFunctions\",\"url\":\"functions/createPubSubCloudFunctions.html\",\"classes\":\"\"},{\"kind\":256,\"name\":\"PubSubCloudFunctionsConfig\",\"url\":\"interfaces/PubSubCloudFunctionsConfig.html\",\"classes\":\"\"},{\"kind\":1024,\"name\":\"logger\",\"url\":\"interfaces/PubSubCloudFunctionsConfig.html#logger\",\"classes\":\"\",\"parent\":\"PubSubCloudFunctionsConfig\"},{\"kind\":1024,\"name\":\"context\",\"url\":\"interfaces/PubSubCloudFunctionsConfig.html#context\",\"classes\":\"\",\"parent\":\"PubSubCloudFunctionsConfig\"},{\"kind\":65536,\"name\":\"__type\",\"url\":\"interfaces/PubSubCloudFunctionsConfig.html#context.__type\",\"classes\":\"\",\"parent\":\"PubSubCloudFunctionsConfig.context\"},{\"kind\":1024,\"name\":\"onError\",\"url\":\"interfaces/PubSubCloudFunctionsConfig.html#onError\",\"classes\":\"tsd-is-inherited\",\"parent\":\"PubSubCloudFunctionsConfig\"},{\"kind\":1024,\"name\":\"parser\",\"url\":\"interfaces/PubSubCloudFunctionsConfig.html#parser\",\"classes\":\"tsd-is-inherited\",\"parent\":\"PubSubCloudFunctionsConfig\"},{\"kind\":65536,\"name\":\"__type\",\"url\":\"interfaces/PubSubCloudFunctionsConfig.html#parser.__type-2\",\"classes\":\"\",\"parent\":\"PubSubCloudFunctionsConfig.parser\"},{\"kind\":1024,\"name\":\"parseJson\",\"url\":\"interfaces/PubSubCloudFunctionsConfig.html#parseJson\",\"classes\":\"tsd-is-inherited\",\"parent\":\"PubSubCloudFunctionsConfig\"},{\"kind\":1024,\"name\":\"path\",\"url\":\"interfaces/PubSubCloudFunctionsConfig.html#path\",\"classes\":\"tsd-is-inherited\",\"parent\":\"PubSubCloudFunctionsConfig\"},{\"kind\":4194304,\"name\":\"CloudFunctionFun\",\"url\":\"types/CloudFunctionFun.html\",\"classes\":\"\"},{\"kind\":65536,\"name\":\"__type\",\"url\":\"types/CloudFunctionFun.html#__type\",\"classes\":\"\",\"parent\":\"CloudFunctionFun\"},{\"kind\":256,\"name\":\"PubSubHandlerFastifyConfig\",\"url\":\"interfaces/PubSubHandlerFastifyConfig.html\",\"classes\":\"\"},{\"kind\":1024,\"name\":\"handler\",\"url\":\"interfaces/PubSubHandlerFastifyConfig.html#handler\",\"classes\":\"\",\"parent\":\"PubSubHandlerFastifyConfig\"},{\"kind\":1024,\"name\":\"context\",\"url\":\"interfaces/PubSubHandlerFastifyConfig.html#context\",\"classes\":\"\",\"parent\":\"PubSubHandlerFastifyConfig\"},{\"kind\":65536,\"name\":\"__type\",\"url\":\"interfaces/PubSubHandlerFastifyConfig.html#context.__type\",\"classes\":\"\",\"parent\":\"PubSubHandlerFastifyConfig.context\"},{\"kind\":1024,\"name\":\"onError\",\"url\":\"interfaces/PubSubHandlerFastifyConfig.html#onError\",\"classes\":\"tsd-is-inherited\",\"parent\":\"PubSubHandlerFastifyConfig\"},{\"kind\":1024,\"name\":\"parser\",\"url\":\"interfaces/PubSubHandlerFastifyConfig.html#parser\",\"classes\":\"tsd-is-inherited\",\"parent\":\"PubSubHandlerFastifyConfig\"},{\"kind\":65536,\"name\":\"__type\",\"url\":\"interfaces/PubSubHandlerFastifyConfig.html#parser.__type-2\",\"classes\":\"\",\"parent\":\"PubSubHandlerFastifyConfig.parser\"},{\"kind\":1024,\"name\":\"parseJson\",\"url\":\"interfaces/PubSubHandlerFastifyConfig.html#parseJson\",\"classes\":\"tsd-is-inherited\",\"parent\":\"PubSubHandlerFastifyConfig\"},{\"kind\":1024,\"name\":\"path\",\"url\":\"interfaces/PubSubHandlerFastifyConfig.html#path\",\"classes\":\"tsd-is-inherited\",\"parent\":\"PubSubHandlerFastifyConfig\"},{\"kind\":64,\"name\":\"pubSubFastifyPlugin\",\"url\":\"functions/pubSubFastifyPlugin.html\",\"classes\":\"\"},{\"kind\":64,\"name\":\"handlePubSubMessage\",\"url\":\"functions/handlePubSubMessage.html\",\"classes\":\"\"},{\"kind\":256,\"name\":\"HandlePubSubMessageArgs\",\"url\":\"interfaces/HandlePubSubMessageArgs.html\",\"classes\":\"\"},{\"kind\":1024,\"name\":\"message\",\"url\":\"interfaces/HandlePubSubMessageArgs.html#message\",\"classes\":\"\",\"parent\":\"HandlePubSubMessageArgs\"},{\"kind\":65536,\"name\":\"__type\",\"url\":\"interfaces/HandlePubSubMessageArgs.html#message.__type\",\"classes\":\"\",\"parent\":\"HandlePubSubMessageArgs.message\"},{\"kind\":1024,\"name\":\"attributes\",\"url\":\"interfaces/HandlePubSubMessageArgs.html#message.__type.attributes\",\"classes\":\"\",\"parent\":\"HandlePubSubMessageArgs.message.__type\"},{\"kind\":1024,\"name\":\"messageId\",\"url\":\"interfaces/HandlePubSubMessageArgs.html#message.__type.messageId\",\"classes\":\"\",\"parent\":\"HandlePubSubMessageArgs.message.__type\"},{\"kind\":1024,\"name\":\"data\",\"url\":\"interfaces/HandlePubSubMessageArgs.html#message.__type.data\",\"classes\":\"\",\"parent\":\"HandlePubSubMessageArgs.message.__type\"},{\"kind\":1024,\"name\":\"handler\",\"url\":\"interfaces/HandlePubSubMessageArgs.html#handler\",\"classes\":\"\",\"parent\":\"HandlePubSubMessageArgs\"},{\"kind\":1024,\"name\":\"parseJson\",\"url\":\"interfaces/HandlePubSubMessageArgs.html#parseJson\",\"classes\":\"\",\"parent\":\"HandlePubSubMessageArgs\"},{\"kind\":1024,\"name\":\"parser\",\"url\":\"interfaces/HandlePubSubMessageArgs.html#parser\",\"classes\":\"\",\"parent\":\"HandlePubSubMessageArgs\"},{\"kind\":65536,\"name\":\"__type\",\"url\":\"interfaces/HandlePubSubMessageArgs.html#parser.__type-1\",\"classes\":\"\",\"parent\":\"HandlePubSubMessageArgs.parser\"},{\"kind\":1024,\"name\":\"context\",\"url\":\"interfaces/HandlePubSubMessageArgs.html#context\",\"classes\":\"\",\"parent\":\"HandlePubSubMessageArgs\"},{\"kind\":1024,\"name\":\"log\",\"url\":\"interfaces/HandlePubSubMessageArgs.html#log\",\"classes\":\"\",\"parent\":\"HandlePubSubMessageArgs\"},{\"kind\":32,\"name\":\"pubSubMessageSchema\",\"url\":\"variables/pubSubMessageSchema.html\",\"classes\":\"\"},{\"kind\":4194304,\"name\":\"PubSubMessage\",\"url\":\"types/PubSubMessage.html\",\"classes\":\"\"},{\"kind\":32,\"name\":\"pubSubRequestSchema\",\"url\":\"variables/pubSubRequestSchema.html\",\"classes\":\"\"},{\"kind\":4194304,\"name\":\"PubSubRequest\",\"url\":\"types/PubSubRequest.html\",\"classes\":\"\"},{\"kind\":4194304,\"name\":\"OnErrorHandler\",\"url\":\"types/OnErrorHandler.html\",\"classes\":\"\"},{\"kind\":65536,\"name\":\"__type\",\"url\":\"types/OnErrorHandler.html#__type\",\"classes\":\"\",\"parent\":\"OnErrorHandler\"},{\"kind\":128,\"name\":\"PubSubHandlerResponse\",\"url\":\"classes/PubSubHandlerResponse.html\",\"classes\":\"\"},{\"kind\":512,\"name\":\"constructor\",\"url\":\"classes/PubSubHandlerResponse.html#constructor\",\"classes\":\"\",\"parent\":\"PubSubHandlerResponse\"},{\"kind\":1024,\"name\":\"statusCode\",\"url\":\"classes/PubSubHandlerResponse.html#statusCode\",\"classes\":\"\",\"parent\":\"PubSubHandlerResponse\"},{\"kind\":4194304,\"name\":\"PubSubHandler\",\"url\":\"types/PubSubHandler.html\",\"classes\":\"\"},{\"kind\":65536,\"name\":\"__type\",\"url\":\"types/PubSubHandler.html#__type\",\"classes\":\"\",\"parent\":\"PubSubHandler\"},{\"kind\":256,\"name\":\"PubSubConfig\",\"url\":\"interfaces/PubSubConfig.html\",\"classes\":\"\"},{\"kind\":1024,\"name\":\"onError\",\"url\":\"interfaces/PubSubConfig.html#onError\",\"classes\":\"\",\"parent\":\"PubSubConfig\"},{\"kind\":1024,\"name\":\"parser\",\"url\":\"interfaces/PubSubConfig.html#parser\",\"classes\":\"\",\"parent\":\"PubSubConfig\"},{\"kind\":65536,\"name\":\"__type\",\"url\":\"interfaces/PubSubConfig.html#parser.__type-2\",\"classes\":\"\",\"parent\":\"PubSubConfig.parser\"},{\"kind\":1024,\"name\":\"context\",\"url\":\"interfaces/PubSubConfig.html#context\",\"classes\":\"\",\"parent\":\"PubSubConfig\"},{\"kind\":65536,\"name\":\"__type\",\"url\":\"interfaces/PubSubConfig.html#context.__type\",\"classes\":\"\",\"parent\":\"PubSubConfig.context\"},{\"kind\":1024,\"name\":\"parseJson\",\"url\":\"interfaces/PubSubConfig.html#parseJson\",\"classes\":\"\",\"parent\":\"PubSubConfig\"},{\"kind\":1024,\"name\":\"path\",\"url\":\"interfaces/PubSubConfig.html#path\",\"classes\":\"\",\"parent\":\"PubSubConfig\"},{\"kind\":64,\"name\":\"makePubSubConfig\",\"url\":\"functions/makePubSubConfig.html\",\"classes\":\"\"}],\"index\":{\"version\":\"2.3.9\",\"fields\":[\"name\",\"comment\"],\"fieldVectors\":[[\"name/0\",[0,36.199]],[\"comment/0\",[]],[\"name/1\",[1,36.199]],[\"comment/1\",[]],[\"name/2\",[2,36.199]],[\"comment/2\",[]],[\"name/3\",[3,25.213]],[\"comment/3\",[]],[\"name/4\",[4,15.83]],[\"comment/4\",[]],[\"name/5\",[5,27.726]],[\"comment/5\",[]],[\"name/6\",[6,25.213]],[\"comment/6\",[]],[\"name/7\",[4,15.83]],[\"comment/7\",[]],[\"name/8\",[7,25.213]],[\"comment/8\",[]],[\"name/9\",[8,27.726]],[\"comment/9\",[]],[\"name/10\",[9,36.199]],[\"comment/10\",[]],[\"name/11\",[4,15.83]],[\"comment/11\",[]],[\"name/12\",[10,36.199]],[\"comment/12\",[]],[\"name/13\",[11,31.091]],[\"comment/13\",[]],[\"name/14\",[3,25.213]],[\"comment/14\",[]],[\"name/15\",[4,15.83]],[\"comment/15\",[]],[\"name/16\",[5,27.726]],[\"comment/16\",[]],[\"name/17\",[6,25.213]],[\"comment/17\",[]],[\"name/18\",[4,15.83]],[\"comment/18\",[]],[\"name/19\",[7,25.213]],[\"comment/19\",[]],[\"name/20\",[8,27.726]],[\"comment/20\",[]],[\"name/21\",[12,36.199]],[\"comment/21\",[]],[\"name/22\",[13,36.199]],[\"comment/22\",[]],[\"name/23\",[14,36.199]],[\"comment/23\",[]],[\"name/24\",[15,36.199]],[\"comment/24\",[]],[\"name/25\",[4,15.83]],[\"comment/25\",[]],[\"name/26\",[16,36.199]],[\"comment/26\",[]],[\"name/27\",[17,36.199]],[\"comment/27\",[]],[\"name/28\",[18,36.199]],[\"comment/28\",[]],[\"name/29\",[11,31.091]],[\"comment/29\",[]],[\"name/30\",[7,25.213]],[\"comment/30\",[]],[\"name/31\",[6,25.213]],[\"comment/31\",[]],[\"name/32\",[4,15.83]],[\"comment/32\",[]],[\"name/33\",[3,25.213]],[\"comment/33\",[]],[\"name/34\",[19,36.199]],[\"comment/34\",[]],[\"name/35\",[20,36.199]],[\"comment/35\",[]],[\"name/36\",[21,36.199]],[\"comment/36\",[]],[\"name/37\",[22,36.199]],[\"comment/37\",[]],[\"name/38\",[23,36.199]],[\"comment/38\",[]],[\"name/39\",[24,36.199]],[\"comment/39\",[]],[\"name/40\",[4,15.83]],[\"comment/40\",[]],[\"name/41\",[25,36.199]],[\"comment/41\",[]],[\"name/42\",[26,36.199]],[\"comment/42\",[]],[\"name/43\",[27,36.199]],[\"comment/43\",[]],[\"name/44\",[28,36.199]],[\"comment/44\",[]],[\"name/45\",[4,15.83]],[\"comment/45\",[]],[\"name/46\",[29,36.199]],[\"comment/46\",[]],[\"name/47\",[5,27.726]],[\"comment/47\",[]],[\"name/48\",[6,25.213]],[\"comment/48\",[]],[\"name/49\",[4,15.83]],[\"comment/49\",[]],[\"name/50\",[3,25.213]],[\"comment/50\",[]],[\"name/51\",[4,15.83]],[\"comment/51\",[]],[\"name/52\",[7,25.213]],[\"comment/52\",[]],[\"name/53\",[8,27.726]],[\"comment/53\",[]],[\"name/54\",[30,36.199]],[\"comment/54\",[]]],\"invertedIndex\":[[\"__type\",{\"_index\":4,\"name\":{\"4\":{},\"7\":{},\"11\":{},\"15\":{},\"18\":{},\"25\":{},\"32\":{},\"40\":{},\"45\":{},\"49\":{},\"51\":{}},\"comment\":{}}],[\"attributes\",{\"_index\":16,\"name\":{\"26\":{}},\"comment\":{}}],[\"cloudfunctionfun\",{\"_index\":9,\"name\":{\"10\":{}},\"comment\":{}}],[\"constructor\",{\"_index\":26,\"name\":{\"42\":{}},\"comment\":{}}],[\"context\",{\"_index\":3,\"name\":{\"3\":{},\"14\":{},\"33\":{},\"50\":{}},\"comment\":{}}],[\"createpubsubcloudfunctions\",{\"_index\":0,\"name\":{\"0\":{}},\"comment\":{}}],[\"data\",{\"_index\":18,\"name\":{\"28\":{}},\"comment\":{}}],[\"handlepubsubmessage\",{\"_index\":13,\"name\":{\"22\":{}},\"comment\":{}}],[\"handlepubsubmessageargs\",{\"_index\":14,\"name\":{\"23\":{}},\"comment\":{}}],[\"handler\",{\"_index\":11,\"name\":{\"13\":{},\"29\":{}},\"comment\":{}}],[\"log\",{\"_index\":19,\"name\":{\"34\":{}},\"comment\":{}}],[\"logger\",{\"_index\":2,\"name\":{\"2\":{}},\"comment\":{}}],[\"makepubsubconfig\",{\"_index\":30,\"name\":{\"54\":{}},\"comment\":{}}],[\"message\",{\"_index\":15,\"name\":{\"24\":{}},\"comment\":{}}],[\"messageid\",{\"_index\":17,\"name\":{\"27\":{}},\"comment\":{}}],[\"onerror\",{\"_index\":5,\"name\":{\"5\":{},\"16\":{},\"47\":{}},\"comment\":{}}],[\"onerrorhandler\",{\"_index\":24,\"name\":{\"39\":{}},\"comment\":{}}],[\"parsejson\",{\"_index\":7,\"name\":{\"8\":{},\"19\":{},\"30\":{},\"52\":{}},\"comment\":{}}],[\"parser\",{\"_index\":6,\"name\":{\"6\":{},\"17\":{},\"31\":{},\"48\":{}},\"comment\":{}}],[\"path\",{\"_index\":8,\"name\":{\"9\":{},\"20\":{},\"53\":{}},\"comment\":{}}],[\"pubsubcloudfunctionsconfig\",{\"_index\":1,\"name\":{\"1\":{}},\"comment\":{}}],[\"pubsubconfig\",{\"_index\":29,\"name\":{\"46\":{}},\"comment\":{}}],[\"pubsubfastifyplugin\",{\"_index\":12,\"name\":{\"21\":{}},\"comment\":{}}],[\"pubsubhandler\",{\"_index\":28,\"name\":{\"44\":{}},\"comment\":{}}],[\"pubsubhandlerfastifyconfig\",{\"_index\":10,\"name\":{\"12\":{}},\"comment\":{}}],[\"pubsubhandlerresponse\",{\"_index\":25,\"name\":{\"41\":{}},\"comment\":{}}],[\"pubsubmessage\",{\"_index\":21,\"name\":{\"36\":{}},\"comment\":{}}],[\"pubsubmessageschema\",{\"_index\":20,\"name\":{\"35\":{}},\"comment\":{}}],[\"pubsubrequest\",{\"_index\":23,\"name\":{\"38\":{}},\"comment\":{}}],[\"pubsubrequestschema\",{\"_index\":22,\"name\":{\"37\":{}},\"comment\":{}}],[\"statuscode\",{\"_index\":27,\"name\":{\"43\":{}},\"comment\":{}}]],\"pipeline\":[]}}"); \ No newline at end of file diff --git a/docs/assets/style.css b/docs/assets/style.css deleted file mode 100644 index 18b4f8f..0000000 --- a/docs/assets/style.css +++ /dev/null @@ -1,1367 +0,0 @@ -:root { - /* Light */ - --light-color-background: #f2f4f8; - --light-color-background-secondary: #eff0f1; - --light-color-warning-text: #222; - --light-color-background-warning: #e6e600; - --light-color-icon-background: var(--light-color-background); - --light-color-accent: #c5c7c9; - --light-color-active-menu-item: var(--light-color-accent); - --light-color-text: #222; - --light-color-text-aside: #6e6e6e; - --light-color-link: #1f70c2; - - --light-color-ts-project: #b111c9; - --light-color-ts-module: var(--light-color-ts-project); - --light-color-ts-namespace: var(--light-color-ts-project); - --light-color-ts-enum: #7e6f15; - --light-color-ts-enum-member: var(--light-color-ts-enum); - --light-color-ts-variable: #4760ec; - --light-color-ts-function: #572be7; - --light-color-ts-class: #1f70c2; - --light-color-ts-interface: #108024; - --light-color-ts-constructor: var(--light-color-ts-class); - --light-color-ts-property: var(--light-color-ts-variable); - --light-color-ts-method: var(--light-color-ts-function); - --light-color-ts-call-signature: var(--light-color-ts-method); - --light-color-ts-index-signature: var(--light-color-ts-property); - --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-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); - /* object literal not included as it is not used and will be removed in 0.25 */ - --light-color-ts-type-alias: #d51270; - /* reference not included as links will be colored with the kind that it points to */ - - --light-external-icon: url("data:image/svg+xml;utf8,"); - --light-color-scheme: light; - - /* Dark */ - --dark-color-background: #2b2e33; - --dark-color-background-secondary: #1e2024; - --dark-color-background-warning: #bebe00; - --dark-color-warning-text: #222; - --dark-color-icon-background: var(--dark-color-background-secondary); - --dark-color-accent: #9096a2; - --dark-color-active-menu-item: #5d5d6a; - --dark-color-text: #f5f5f5; - --dark-color-text-aside: #dddddd; - --dark-color-link: #00aff4; - - --dark-color-ts-project: #e358ff; - --dark-color-ts-module: var(--dark-color-ts-project); - --dark-color-ts-namespace: var(--dark-color-ts-project); - --dark-color-ts-enum: #f4d93e; - --dark-color-ts-enum-member: var(--dark-color-ts-enum); - --dark-color-ts-variable: #798dff; - --dark-color-ts-function: #a280ff; - --dark-color-ts-class: #8ac4ff; - --dark-color-ts-interface: #6cff87; - --dark-color-ts-constructor: var(--dark-color-ts-class); - --dark-color-ts-property: var(--dark-color-ts-variable); - --dark-color-ts-method: var(--dark-color-ts-function); - --dark-color-ts-call-signature: var(--dark-color-ts-method); - --dark-color-ts-index-signature: var(--dark-color-ts-property); - --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-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); - /* object literal not included as it is not used and will be removed in 0.25 */ - --dark-color-ts-type-alias: #ff6492; - /* reference not included as links will be colored with the kind that it points to */ - - --dark-external-icon: url("data:image/svg+xml;utf8,"); - --dark-color-scheme: dark; -} - -@media (prefers-color-scheme: light) { - :root { - --color-background: var(--light-color-background); - --color-background-secondary: var(--light-color-background-secondary); - --color-background-warning: var(--light-color-background-warning); - --color-warning-text: var(--light-color-warning-text); - --color-icon-background: var(--light-color-icon-background); - --color-accent: var(--light-color-accent); - --color-active-menu-item: var(--light-color-active-menu-item); - --color-text: var(--light-color-text); - --color-text-aside: var(--light-color-text-aside); - --color-link: var(--light-color-link); - - --color-ts-module: var(--light-color-ts-module); - --color-ts-namespace: var(--light-color-ts-namespace); - --color-ts-enum: var(--light-color-ts-enum); - --color-ts-enum-member: var(--light-color-ts-enum-member); - --color-ts-variable: var(--light-color-ts-variable); - --color-ts-function: var(--light-color-ts-function); - --color-ts-class: var(--light-color-ts-class); - --color-ts-interface: var(--light-color-ts-interface); - --color-ts-constructor: var(--light-color-ts-constructor); - --color-ts-property: var(--light-color-ts-property); - --color-ts-method: var(--light-color-ts-method); - --color-ts-call-signature: var(--light-color-ts-call-signature); - --color-ts-index-signature: var(--light-color-ts-index-signature); - --color-ts-constructor-signature: var( - --light-color-ts-constructor-signature - ); - --color-ts-parameter: var(--light-color-ts-parameter); - --color-ts-type-parameter: var(--light-color-ts-type-parameter); - --color-ts-accessor: var(--light-color-ts-accessor); - --color-ts-get-signature: var(--light-color-ts-get-signature); - --color-ts-set-signature: var(--light-color-ts-set-signature); - --color-ts-type-alias: var(--light-color-ts-type-alias); - - --external-icon: var(--light-external-icon); - --color-scheme: var(--light-color-scheme); - } -} - -@media (prefers-color-scheme: dark) { - :root { - --color-background: var(--dark-color-background); - --color-background-secondary: var(--dark-color-background-secondary); - --color-background-warning: var(--dark-color-background-warning); - --color-warning-text: var(--dark-color-warning-text); - --color-icon-background: var(--dark-color-icon-background); - --color-accent: var(--dark-color-accent); - --color-active-menu-item: var(--dark-color-active-menu-item); - --color-text: var(--dark-color-text); - --color-text-aside: var(--dark-color-text-aside); - --color-link: var(--dark-color-link); - - --color-ts-module: var(--dark-color-ts-module); - --color-ts-namespace: var(--dark-color-ts-namespace); - --color-ts-enum: var(--dark-color-ts-enum); - --color-ts-enum-member: var(--dark-color-ts-enum-member); - --color-ts-variable: var(--dark-color-ts-variable); - --color-ts-function: var(--dark-color-ts-function); - --color-ts-class: var(--dark-color-ts-class); - --color-ts-interface: var(--dark-color-ts-interface); - --color-ts-constructor: var(--dark-color-ts-constructor); - --color-ts-property: var(--dark-color-ts-property); - --color-ts-method: var(--dark-color-ts-method); - --color-ts-call-signature: var(--dark-color-ts-call-signature); - --color-ts-index-signature: var(--dark-color-ts-index-signature); - --color-ts-constructor-signature: var( - --dark-color-ts-constructor-signature - ); - --color-ts-parameter: var(--dark-color-ts-parameter); - --color-ts-type-parameter: var(--dark-color-ts-type-parameter); - --color-ts-accessor: var(--dark-color-ts-accessor); - --color-ts-get-signature: var(--dark-color-ts-get-signature); - --color-ts-set-signature: var(--dark-color-ts-set-signature); - --color-ts-type-alias: var(--dark-color-ts-type-alias); - - --external-icon: var(--dark-external-icon); - --color-scheme: var(--dark-color-scheme); - } -} - -html { - color-scheme: var(--color-scheme); -} - -body { - margin: 0; -} - -:root[data-theme="light"] { - --color-background: var(--light-color-background); - --color-background-secondary: var(--light-color-background-secondary); - --color-background-warning: var(--light-color-background-warning); - --color-warning-text: var(--light-color-warning-text); - --color-icon-background: var(--light-color-icon-background); - --color-accent: var(--light-color-accent); - --color-active-menu-item: var(--light-color-active-menu-item); - --color-text: var(--light-color-text); - --color-text-aside: var(--light-color-text-aside); - --color-link: var(--light-color-link); - - --color-ts-module: var(--light-color-ts-module); - --color-ts-namespace: var(--light-color-ts-namespace); - --color-ts-enum: var(--light-color-ts-enum); - --color-ts-enum-member: var(--light-color-ts-enum-member); - --color-ts-variable: var(--light-color-ts-variable); - --color-ts-function: var(--light-color-ts-function); - --color-ts-class: var(--light-color-ts-class); - --color-ts-interface: var(--light-color-ts-interface); - --color-ts-constructor: var(--light-color-ts-constructor); - --color-ts-property: var(--light-color-ts-property); - --color-ts-method: var(--light-color-ts-method); - --color-ts-call-signature: var(--light-color-ts-call-signature); - --color-ts-index-signature: var(--light-color-ts-index-signature); - --color-ts-constructor-signature: var( - --light-color-ts-constructor-signature - ); - --color-ts-parameter: var(--light-color-ts-parameter); - --color-ts-type-parameter: var(--light-color-ts-type-parameter); - --color-ts-accessor: var(--light-color-ts-accessor); - --color-ts-get-signature: var(--light-color-ts-get-signature); - --color-ts-set-signature: var(--light-color-ts-set-signature); - --color-ts-type-alias: var(--light-color-ts-type-alias); - - --external-icon: var(--light-external-icon); - --color-scheme: var(--light-color-scheme); -} - -:root[data-theme="dark"] { - --color-background: var(--dark-color-background); - --color-background-secondary: var(--dark-color-background-secondary); - --color-background-warning: var(--dark-color-background-warning); - --color-warning-text: var(--dark-color-warning-text); - --color-icon-background: var(--dark-color-icon-background); - --color-accent: var(--dark-color-accent); - --color-active-menu-item: var(--dark-color-active-menu-item); - --color-text: var(--dark-color-text); - --color-text-aside: var(--dark-color-text-aside); - --color-link: var(--dark-color-link); - - --color-ts-module: var(--dark-color-ts-module); - --color-ts-namespace: var(--dark-color-ts-namespace); - --color-ts-enum: var(--dark-color-ts-enum); - --color-ts-enum-member: var(--dark-color-ts-enum-member); - --color-ts-variable: var(--dark-color-ts-variable); - --color-ts-function: var(--dark-color-ts-function); - --color-ts-class: var(--dark-color-ts-class); - --color-ts-interface: var(--dark-color-ts-interface); - --color-ts-constructor: var(--dark-color-ts-constructor); - --color-ts-property: var(--dark-color-ts-property); - --color-ts-method: var(--dark-color-ts-method); - --color-ts-call-signature: var(--dark-color-ts-call-signature); - --color-ts-index-signature: var(--dark-color-ts-index-signature); - --color-ts-constructor-signature: var( - --dark-color-ts-constructor-signature - ); - --color-ts-parameter: var(--dark-color-ts-parameter); - --color-ts-type-parameter: var(--dark-color-ts-type-parameter); - --color-ts-accessor: var(--dark-color-ts-accessor); - --color-ts-get-signature: var(--dark-color-ts-get-signature); - --color-ts-set-signature: var(--dark-color-ts-set-signature); - --color-ts-type-alias: var(--dark-color-ts-type-alias); - - --external-icon: var(--dark-external-icon); - --color-scheme: var(--dark-color-scheme); -} - -.always-visible, -.always-visible .tsd-signatures { - display: inherit !important; -} - -h1, -h2, -h3, -h4, -h5, -h6 { - line-height: 1.2; -} - -h1 > a, -h2 > a, -h3 > a, -h4 > a, -h5 > a, -h6 > a { - text-decoration: none; - color: var(--color-text); -} - -h1 { - font-size: 1.875rem; - margin: 0.67rem 0; -} - -h2 { - font-size: 1.5rem; - margin: 0.83rem 0; -} - -h3 { - font-size: 1.25rem; - margin: 1rem 0; -} - -h4 { - font-size: 1.05rem; - margin: 1.33rem 0; -} - -h5 { - font-size: 1rem; - margin: 1.5rem 0; -} - -h6 { - font-size: 0.875rem; - margin: 2.33rem 0; -} - -.uppercase { - text-transform: uppercase; -} - -dl, -menu, -ol, -ul { - margin: 1em 0; -} - -dd { - margin: 0 0 0 40px; -} - -.container { - max-width: 1700px; - padding: 0 2rem; -} - -/* Footer */ -.tsd-generator { - 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; -} - -.container-main { - margin: 0 auto; - /* toolbar, footer, margin */ - min-height: calc(100vh - 41px - 56px - 4rem); -} - -@keyframes fade-in { - from { - opacity: 0; - } - to { - opacity: 1; - } -} -@keyframes fade-out { - from { - opacity: 1; - visibility: visible; - } - to { - opacity: 0; - } -} -@keyframes fade-in-delayed { - 0% { - opacity: 0; - } - 33% { - opacity: 0; - } - 100% { - opacity: 1; - } -} -@keyframes fade-out-delayed { - 0% { - opacity: 1; - visibility: visible; - } - 66% { - opacity: 0; - } - 100% { - opacity: 0; - } -} -@keyframes pop-in-from-right { - from { - transform: translate(100%, 0); - } - to { - transform: translate(0, 0); - } -} -@keyframes pop-out-to-right { - from { - transform: translate(0, 0); - visibility: visible; - } - to { - transform: translate(100%, 0); - } -} -body { - background: var(--color-background); - font-family: "Segoe UI", sans-serif; - font-size: 16px; - color: var(--color-text); -} - -a { - color: var(--color-link); - text-decoration: none; -} -a:hover { - text-decoration: underline; -} -a.external[target="_blank"] { - background-image: var(--external-icon); - background-position: top 3px right; - background-repeat: no-repeat; - padding-right: 13px; -} - -code, -pre { - font-family: Menlo, Monaco, Consolas, "Courier New", monospace; - padding: 0.2em; - margin: 0; - font-size: 0.875rem; - border-radius: 0.8em; -} - -pre { - position: relative; - white-space: pre; - white-space: pre-wrap; - word-wrap: break-word; - padding: 10px; - border: 1px solid var(--color-accent); -} -pre code { - padding: 0; - font-size: 100%; -} -pre > button { - position: absolute; - top: 10px; - right: 10px; - opacity: 0; - transition: opacity 0.1s; - box-sizing: border-box; -} -pre:hover > button, -pre > button.visible { - opacity: 1; -} - -blockquote { - margin: 1em 0; - padding-left: 1em; - border-left: 4px solid gray; -} - -.tsd-typography { - line-height: 1.333em; -} -.tsd-typography ul { - list-style: square; - padding: 0 0 0 20px; - margin: 0; -} -.tsd-typography h4, -.tsd-typography .tsd-index-panel h3, -.tsd-index-panel .tsd-typography h3, -.tsd-typography h5, -.tsd-typography h6 { - font-size: 1em; - margin: 0; -} -.tsd-typography h5, -.tsd-typography h6 { - font-weight: normal; -} -.tsd-typography p, -.tsd-typography ul, -.tsd-typography ol { - margin: 1em 0; -} - -.tsd-breadcrumb { - margin: 0; - padding: 0; - color: var(--color-text-aside); -} -.tsd-breadcrumb a { - color: var(--color-text-aside); - text-decoration: none; -} -.tsd-breadcrumb a:hover { - text-decoration: underline; -} -.tsd-breadcrumb li { - display: inline; -} -.tsd-breadcrumb li:after { - content: " / "; -} - -.tsd-comment-tags { - display: flex; - flex-direction: column; -} -dl.tsd-comment-tag-group { - display: flex; - align-items: center; - overflow: hidden; - margin: 0.5em 0; -} -dl.tsd-comment-tag-group dt { - display: flex; - margin-right: 0.5em; - font-size: 0.875em; - font-weight: normal; -} -dl.tsd-comment-tag-group dd { - margin: 0; -} -code.tsd-tag { - padding: 0.25em 0.4em; - border: 0.1em solid var(--color-accent); - margin-right: 0.25em; - font-size: 70%; -} -h1 code.tsd-tag:first-of-type { - margin-left: 0.25em; -} - -dl.tsd-comment-tag-group dd:before, -dl.tsd-comment-tag-group dd:after { - content: " "; -} -dl.tsd-comment-tag-group dd pre, -dl.tsd-comment-tag-group dd:after { - clear: both; -} -dl.tsd-comment-tag-group p { - margin: 0; -} - -.tsd-panel.tsd-comment .lead { - font-size: 1.1em; - line-height: 1.333em; - margin-bottom: 2em; -} -.tsd-panel.tsd-comment .lead:last-child { - margin-bottom: 0; -} - -.tsd-filter-visibility h4 { - font-size: 1rem; - padding-top: 0.75rem; - padding-bottom: 0.5rem; - margin: 0; -} -.tsd-filter-item:not(:last-child) { - margin-bottom: 0.5rem; -} -.tsd-filter-input { - display: flex; - width: fit-content; - width: -moz-fit-content; - align-items: center; - user-select: none; - -webkit-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - cursor: pointer; -} -.tsd-filter-input input[type="checkbox"] { - cursor: pointer; - position: absolute; - width: 1.5em; - height: 1.5em; - opacity: 0; -} -.tsd-filter-input input[type="checkbox"]:disabled { - pointer-events: none; -} -.tsd-filter-input svg { - cursor: pointer; - width: 1.5em; - height: 1.5em; - margin-right: 0.5em; - border-radius: 0.33em; - /* Leaving this at full opacity breaks event listeners on Firefox. - Don't remove unless you know what you're doing. */ - opacity: 0.99; -} -.tsd-filter-input input[type="checkbox"]:focus + svg { - transform: scale(0.95); -} -.tsd-filter-input input[type="checkbox"]:focus:not(:focus-visible) + svg { - transform: scale(1); -} -.tsd-checkbox-background { - fill: var(--color-accent); -} -input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { - stroke: var(--color-text); -} -.tsd-filter-input input:disabled ~ svg > .tsd-checkbox-background { - fill: var(--color-background); - stroke: var(--color-accent); - stroke-width: 0.25rem; -} -.tsd-filter-input input:disabled ~ svg > .tsd-checkbox-checkmark { - stroke: var(--color-accent); -} - -.tsd-theme-toggle { - padding-top: 0.75rem; -} -.tsd-theme-toggle > h4 { - display: inline; - vertical-align: middle; - margin-right: 0.75rem; -} - -.tsd-hierarchy { - list-style: square; - margin: 0; -} -.tsd-hierarchy .target { - font-weight: bold; -} - -.tsd-panel-group.tsd-index-group { - margin-bottom: 0; -} -.tsd-index-panel .tsd-index-list { - list-style: none; - line-height: 1.333em; - margin: 0; - padding: 0.25rem 0 0 0; - overflow: hidden; - display: grid; - grid-template-columns: repeat(3, 1fr); - column-gap: 1rem; - grid-template-rows: auto; -} -@media (max-width: 1024px) { - .tsd-index-panel .tsd-index-list { - grid-template-columns: repeat(2, 1fr); - } -} -@media (max-width: 768px) { - .tsd-index-panel .tsd-index-list { - grid-template-columns: repeat(1, 1fr); - } -} -.tsd-index-panel .tsd-index-list li { - -webkit-page-break-inside: avoid; - -moz-page-break-inside: avoid; - -ms-page-break-inside: avoid; - -o-page-break-inside: avoid; - page-break-inside: avoid; -} - -.tsd-flag { - display: inline-block; - padding: 0.25em 0.4em; - border-radius: 4px; - color: var(--color-comment-tag-text); - background-color: var(--color-comment-tag); - text-indent: 0; - font-size: 75%; - line-height: 1; - font-weight: normal; -} - -.tsd-anchor { - position: relative; - top: -100px; -} - -.tsd-member { - position: relative; -} -.tsd-member .tsd-anchor + h3 { - display: flex; - align-items: center; - margin-top: 0; - margin-bottom: 0; - border-bottom: none; -} - -.tsd-navigation.settings { - margin: 1rem 0; -} -.tsd-navigation > a, -.tsd-navigation .tsd-accordion-summary { - width: calc(100% - 0.5rem); -} -.tsd-navigation a, -.tsd-navigation summary > span, -.tsd-page-navigation a { - display: inline-flex; - align-items: center; - padding: 0.25rem; - color: var(--color-text); - text-decoration: none; - box-sizing: border-box; -} -.tsd-navigation a.current, -.tsd-page-navigation a.current { - background: var(--color-active-menu-item); -} -.tsd-navigation a:hover, -.tsd-page-navigation a:hover { - text-decoration: underline; -} -.tsd-navigation ul, -.tsd-page-navigation ul { - margin-top: 0; - margin-bottom: 0; - padding: 0; - list-style: none; -} -.tsd-navigation li, -.tsd-page-navigation li { - padding: 0; - max-width: 100%; -} -.tsd-nested-navigation { - margin-left: 3rem; -} -.tsd-nested-navigation > li > details { - margin-left: -1.5rem; -} -.tsd-small-nested-navigation { - margin-left: 1.5rem; -} -.tsd-small-nested-navigation > li > details { - 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; -} - -#tsd-sidebar-links a { - margin-top: 0; - margin-bottom: 0.5rem; - line-height: 1.25rem; -} -#tsd-sidebar-links a:last-of-type { - margin-bottom: 0; -} - -a.tsd-index-link { - padding: 0.25rem 0 !important; - font-size: 1rem; - line-height: 1.25rem; - display: inline-flex; - align-items: center; - color: var(--color-text); -} -.tsd-accordion-summary { - list-style-type: none; /* hide marker on non-safari */ - outline: none; /* broken on safari, so just hide it */ -} -.tsd-accordion-summary::-webkit-details-marker { - display: none; /* hide marker on safari */ -} -.tsd-accordion-summary, -.tsd-accordion-summary a { - user-select: none; - -moz-user-select: none; - -webkit-user-select: none; - -ms-user-select: none; - - cursor: pointer; -} -.tsd-accordion-summary a { - width: calc(100% - 1.5rem); -} -.tsd-accordion-summary > * { - margin-top: 0; - margin-bottom: 0; - padding-top: 0; - padding-bottom: 0; -} -.tsd-index-accordion .tsd-accordion-summary > svg { - margin-left: 0.25rem; -} -.tsd-index-content > :not(:first-child) { - margin-top: 0.75rem; -} -.tsd-index-heading { - margin-top: 1.5rem; - margin-bottom: 0.75rem; -} - -.tsd-kind-icon { - margin-right: 0.5rem; - width: 1.25rem; - height: 1.25rem; - min-width: 1.25rem; - min-height: 1.25rem; -} -.tsd-kind-icon path { - transform-origin: center; - transform: scale(1.1); -} -.tsd-signature > .tsd-kind-icon { - margin-right: 0.8rem; -} - -.tsd-panel { - margin-bottom: 2.5rem; -} -.tsd-panel.tsd-member { - margin-bottom: 4rem; -} -.tsd-panel:empty { - display: none; -} -.tsd-panel > h1, -.tsd-panel > h2, -.tsd-panel > h3 { - margin: 1.5rem -1.5rem 0.75rem -1.5rem; - padding: 0 1.5rem 0.75rem 1.5rem; -} -.tsd-panel > h1.tsd-before-signature, -.tsd-panel > h2.tsd-before-signature, -.tsd-panel > h3.tsd-before-signature { - margin-bottom: 0; - border-bottom: none; -} - -.tsd-panel-group { - margin: 4rem 0; -} -.tsd-panel-group.tsd-index-group { - margin: 2rem 0; -} -.tsd-panel-group.tsd-index-group details { - margin: 2rem 0; -} - -#tsd-search { - transition: background-color 0.2s; -} -#tsd-search .title { - position: relative; - z-index: 2; -} -#tsd-search .field { - position: absolute; - left: 0; - top: 0; - right: 2.5rem; - height: 100%; -} -#tsd-search .field input { - box-sizing: border-box; - position: relative; - top: -50px; - z-index: 1; - width: 100%; - padding: 0 10px; - opacity: 0; - outline: 0; - border: 0; - background: transparent; - color: var(--color-text); -} -#tsd-search .field label { - position: absolute; - overflow: hidden; - right: -40px; -} -#tsd-search .field input, -#tsd-search .title, -#tsd-toolbar-links a { - transition: opacity 0.2s; -} -#tsd-search .results { - position: absolute; - visibility: hidden; - top: 40px; - width: 100%; - margin: 0; - padding: 0; - list-style: none; - box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); -} -#tsd-search .results li { - padding: 0 10px; - background-color: var(--color-background); -} -#tsd-search .results li:nth-child(even) { - background-color: var(--color-background-secondary); -} -#tsd-search .results li.state { - display: none; -} -#tsd-search .results li.current, -#tsd-search .results li:hover { - background-color: var(--color-accent); -} -#tsd-search .results a { - display: block; -} -#tsd-search .results a:before { - top: 10px; -} -#tsd-search .results span.parent { - color: var(--color-text-aside); - font-weight: normal; -} -#tsd-search.has-focus { - background-color: var(--color-accent); -} -#tsd-search.has-focus .field input { - top: 0; - opacity: 1; -} -#tsd-search.has-focus .title, -#tsd-search.has-focus #tsd-toolbar-links a { - z-index: 0; - opacity: 0; -} -#tsd-search.has-focus .results { - visibility: visible; -} -#tsd-search.loading .results li.state.loading { - display: block; -} -#tsd-search.failure .results li.state.failure { - display: block; -} - -#tsd-toolbar-links { - position: absolute; - top: 0; - right: 2rem; - height: 100%; - display: flex; - align-items: center; - justify-content: flex-end; -} -#tsd-toolbar-links a { - margin-left: 1.5rem; -} -#tsd-toolbar-links a:hover { - text-decoration: underline; -} - -.tsd-signature { - margin: 0 0 1rem 0; - padding: 1rem 0.5rem; - border: 1px solid var(--color-accent); - font-family: Menlo, Monaco, Consolas, "Courier New", monospace; - font-size: 14px; - overflow-x: auto; -} - -.tsd-signature-symbol { - color: var(--color-text-aside); - font-weight: normal; -} - -.tsd-signature-type { - font-style: italic; - font-weight: normal; -} - -.tsd-signatures { - padding: 0; - margin: 0 0 1em 0; - list-style-type: none; -} -.tsd-signatures .tsd-signature { - margin: 0; - border-color: var(--color-accent); - border-width: 1px 0; - transition: background-color 0.1s; -} -.tsd-description .tsd-signatures .tsd-signature { - border-width: 1px; -} - -ul.tsd-parameter-list, -ul.tsd-type-parameter-list { - list-style: square; - margin: 0; - padding-left: 20px; -} -ul.tsd-parameter-list > li.tsd-parameter-signature, -ul.tsd-type-parameter-list > li.tsd-parameter-signature { - list-style: none; - margin-left: -20px; -} -ul.tsd-parameter-list h5, -ul.tsd-type-parameter-list h5 { - font-size: 16px; - margin: 1em 0 0.5em 0; -} -.tsd-sources { - margin-top: 1rem; - font-size: 0.875em; -} -.tsd-sources a { - color: var(--color-text-aside); - text-decoration: underline; -} -.tsd-sources ul { - list-style: none; - padding: 0; -} - -.tsd-page-toolbar { - position: sticky; - z-index: 1; - top: 0; - left: 0; - width: 100%; - color: var(--color-text); - background: var(--color-background-secondary); - border-bottom: 1px var(--color-accent) solid; - transition: transform 0.3s ease-in-out; -} -.tsd-page-toolbar a { - color: var(--color-text); - text-decoration: none; -} -.tsd-page-toolbar a.title { - font-weight: bold; -} -.tsd-page-toolbar a.title:hover { - text-decoration: underline; -} -.tsd-page-toolbar .tsd-toolbar-contents { - display: flex; - justify-content: space-between; - height: 2.5rem; - margin: 0 auto; -} -.tsd-page-toolbar .table-cell { - position: relative; - white-space: nowrap; - line-height: 40px; -} -.tsd-page-toolbar .table-cell:first-child { - width: 100%; -} -.tsd-page-toolbar .tsd-toolbar-icon { - box-sizing: border-box; - line-height: 0; - padding: 12px 0; -} - -.tsd-widget { - display: inline-block; - overflow: hidden; - opacity: 0.8; - height: 40px; - transition: opacity 0.1s, background-color 0.2s; - vertical-align: bottom; - cursor: pointer; -} -.tsd-widget:hover { - opacity: 0.9; -} -.tsd-widget.active { - opacity: 1; - background-color: var(--color-accent); -} -.tsd-widget.no-caption { - width: 40px; -} -.tsd-widget.no-caption:before { - margin: 0; -} - -.tsd-widget.options, -.tsd-widget.menu { - display: none; -} -input[type="checkbox"] + .tsd-widget:before { - background-position: -120px 0; -} -input[type="checkbox"]:checked + .tsd-widget:before { - background-position: -160px 0; -} - -img { - max-width: 100%; -} - -.tsd-anchor-icon { - display: inline-flex; - align-items: center; - margin-left: 0.5rem; - vertical-align: middle; - color: var(--color-text); -} - -.tsd-anchor-icon svg { - width: 1em; - height: 1em; - visibility: hidden; -} - -.tsd-anchor-link:hover > .tsd-anchor-icon svg { - visibility: visible; -} - -.deprecated { - text-decoration: line-through; -} - -.warning { - padding: 1rem; - color: var(--color-warning-text); - background: var(--color-background-warning); -} - -.tsd-kind-project { - color: var(--color-ts-project); -} -.tsd-kind-module { - color: var(--color-ts-module); -} -.tsd-kind-namespace { - color: var(--color-ts-namespace); -} -.tsd-kind-enum { - color: var(--color-ts-enum); -} -.tsd-kind-enum-member { - color: var(--color-ts-enum-member); -} -.tsd-kind-variable { - color: var(--color-ts-variable); -} -.tsd-kind-function { - color: var(--color-ts-function); -} -.tsd-kind-class { - color: var(--color-ts-class); -} -.tsd-kind-interface { - color: var(--color-ts-interface); -} -.tsd-kind-constructor { - color: var(--color-ts-constructor); -} -.tsd-kind-property { - color: var(--color-ts-property); -} -.tsd-kind-method { - color: var(--color-ts-method); -} -.tsd-kind-call-signature { - color: var(--color-ts-call-signature); -} -.tsd-kind-index-signature { - color: var(--color-ts-index-signature); -} -.tsd-kind-constructor-signature { - color: var(--color-ts-constructor-signature); -} -.tsd-kind-parameter { - color: var(--color-ts-parameter); -} -.tsd-kind-type-literal { - color: var(--color-ts-type-literal); -} -.tsd-kind-type-parameter { - color: var(--color-ts-type-parameter); -} -.tsd-kind-accessor { - color: var(--color-ts-accessor); -} -.tsd-kind-get-signature { - color: var(--color-ts-get-signature); -} -.tsd-kind-set-signature { - color: var(--color-ts-set-signature); -} -.tsd-kind-type-alias { - color: var(--color-ts-type-alias); -} - -/* if we have a kind icon, don't color the text by kind */ -.tsd-kind-icon ~ span { - color: var(--color-text); -} - -* { - scrollbar-width: thin; - scrollbar-color: var(--color-accent) var(--color-icon-background); -} - -*::-webkit-scrollbar { - width: 0.75rem; -} - -*::-webkit-scrollbar-track { - background: var(--color-icon-background); -} - -*::-webkit-scrollbar-thumb { - background-color: var(--color-accent); - border-radius: 999rem; - border: 0.25rem solid var(--color-icon-background); -} - -/* mobile */ -@media (max-width: 769px) { - .tsd-widget.options, - .tsd-widget.menu { - display: inline-block; - } - - .container-main { - display: flex; - } - html .col-content { - float: none; - max-width: 100%; - width: 100%; - } - html .col-sidebar { - position: fixed !important; - overflow-y: auto; - -webkit-overflow-scrolling: touch; - z-index: 1024; - top: 0 !important; - bottom: 0 !important; - left: auto !important; - right: 0 !important; - padding: 1.5rem 1.5rem 0 0; - width: 75vw; - visibility: hidden; - background-color: var(--color-background); - transform: translate(100%, 0); - } - html .col-sidebar > *:last-child { - padding-bottom: 20px; - } - html .overlay { - content: ""; - display: block; - position: fixed; - z-index: 1023; - top: 0; - left: 0; - right: 0; - bottom: 0; - background-color: rgba(0, 0, 0, 0.75); - visibility: hidden; - } - - .to-has-menu .overlay { - animation: fade-in 0.4s; - } - - .to-has-menu .col-sidebar { - animation: pop-in-from-right 0.4s; - } - - .from-has-menu .overlay { - animation: fade-out 0.4s; - } - - .from-has-menu .col-sidebar { - animation: pop-out-to-right 0.4s; - } - - .has-menu body { - overflow: hidden; - } - .has-menu .overlay { - visibility: visible; - } - .has-menu .col-sidebar { - visibility: visible; - transform: translate(0, 0); - display: flex; - flex-direction: column; - gap: 1.5rem; - max-height: 100vh; - padding: 1rem 2rem; - } - .has-menu .tsd-navigation { - max-height: 100%; - } -} - -/* one sidebar */ -@media (min-width: 770px) { - .container-main { - display: grid; - grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); - grid-template-areas: "sidebar content"; - margin: 2rem auto; - } - - .col-sidebar { - grid-area: sidebar; - } - .col-content { - grid-area: content; - padding: 0 1rem; - } -} -@media (min-width: 770px) and (max-width: 1399px) { - .col-sidebar { - max-height: calc(100vh - 2rem - 42px); - overflow: auto; - position: sticky; - top: 42px; - padding-top: 1rem; - } - .site-menu { - margin-top: 1rem; - } -} - -/* two sidebars */ -@media (min-width: 1200px) { - .container-main { - grid-template-columns: minmax(0, 1fr) minmax(0, 2.5fr) minmax(0, 20rem); - grid-template-areas: "sidebar content toc"; - } - - .col-sidebar { - display: contents; - } - - .page-menu { - grid-area: toc; - padding-left: 1rem; - } - .site-menu { - grid-area: sidebar; - } - - .site-menu { - margin-top: 1rem 0; - } - - .page-menu, - .site-menu { - max-height: calc(100vh - 2rem - 42px); - overflow: auto; - position: sticky; - top: 42px; - } -} diff --git a/docs/classes/PubSubHandlerResponse.html b/docs/classes/PubSubHandlerResponse.html deleted file mode 100644 index 30256cf..0000000 --- a/docs/classes/PubSubHandlerResponse.html +++ /dev/null @@ -1,94 +0,0 @@ -PubSubHandlerResponse | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Class PubSubHandlerResponse

    -
    -

    Hierarchy

    -
      -
    • PubSubHandlerResponse
    -
    -
    -
    - -
    -
    -

    Constructors

    -
    -
    -

    Properties

    -
    -
    -

    Constructors

    -
    - -
    -
    -

    Properties

    -
    - -
    statusCode?: number
    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/classes/PubSubHandlerResponse.md b/docs/classes/PubSubHandlerResponse.md new file mode 100644 index 0000000..b00a5c2 --- /dev/null +++ b/docs/classes/PubSubHandlerResponse.md @@ -0,0 +1,29 @@ +[pubsub-http-handler](../README.md) / PubSubHandlerResponse + +# Class: PubSubHandlerResponse + +## Table of contents + +### Constructors + +- [constructor](PubSubHandlerResponse.md#constructor) + +### Properties + +- [statusCode](PubSubHandlerResponse.md#statuscode) + +## Constructors + +### constructor + +• **new PubSubHandlerResponse**() + +## Properties + +### statusCode + +• `Optional` **statusCode**: `number` + +#### Defined in + +[src/types.ts:36](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L36) diff --git a/docs/functions/createPubSubCloudFunctions.html b/docs/functions/createPubSubCloudFunctions.html deleted file mode 100644 index 676cba9..0000000 --- a/docs/functions/createPubSubCloudFunctions.html +++ /dev/null @@ -1,75 +0,0 @@ -createPubSubCloudFunctions | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Function createPubSubCloudFunctions

    -
    -
    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/functions/handlePubSubMessage.html b/docs/functions/handlePubSubMessage.html deleted file mode 100644 index 663a84c..0000000 --- a/docs/functions/handlePubSubMessage.html +++ /dev/null @@ -1,75 +0,0 @@ -handlePubSubMessage | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Function handlePubSubMessage

    -
    -
    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/functions/makePubSubConfig.html b/docs/functions/makePubSubConfig.html deleted file mode 100644 index 417770d..0000000 --- a/docs/functions/makePubSubConfig.html +++ /dev/null @@ -1,73 +0,0 @@ -makePubSubConfig | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Function makePubSubConfig

    -
    -
    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/functions/pubSubFastifyPlugin.html b/docs/functions/pubSubFastifyPlugin.html deleted file mode 100644 index 94be5c1..0000000 --- a/docs/functions/pubSubFastifyPlugin.html +++ /dev/null @@ -1,75 +0,0 @@ -pubSubFastifyPlugin | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Function pubSubFastifyPlugin

    -
    -
      - -
    • -
      -

      Type Parameters

      -
        -
      • -

        Data

      • -
      • -

        Context

      -
      -

      Parameters

      -
        -
      • -
        fastify: FastifyInstance<RawServerDefault, IncomingMessage, ServerResponse<IncomingMessage>, FastifyBaseLogger, FastifyTypeProviderDefault>
      • -
      • -
        options: PubSubHandlerFastifyConfig<Data, Context>
      -

      Returns Promise<void>

    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/index.html b/docs/index.html deleted file mode 100644 index fe6486d..0000000 --- a/docs/index.html +++ /dev/null @@ -1,85 +0,0 @@ -pubsub-http-handler
    -
    - -
    - -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/interfaces/HandlePubSubMessageArgs.html b/docs/interfaces/HandlePubSubMessageArgs.html deleted file mode 100644 index 9104ac2..0000000 --- a/docs/interfaces/HandlePubSubMessageArgs.html +++ /dev/null @@ -1,147 +0,0 @@ -HandlePubSubMessageArgs | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Interface HandlePubSubMessageArgs<Data, Context, Logger>

    -
    -

    Type Parameters

    -
      -
    • -

      Data

    • -
    • -

      Context

    • -
    • -

      Logger

    -
    -

    Hierarchy

    -
      -
    • HandlePubSubMessageArgs
    -
    -
    -
    - -
    -
    -

    Properties

    -
    -
    -

    Properties

    -
    - -
    context: Context
    -
    - -
    handler: PubSubHandler<Data, Context, Logger>
    -
    - -
    log: Logger
    -
    - -
    message: {
        attributes?: Record<string, string>;
        data: string;
        messageId?: string;
    }
    -
    -

    Type declaration

    -
      -
    • -
      Optional attributes?: Record<string, string>
    • -
    • -
      data: string
    • -
    • -
      Optional messageId?: string
    -
    - -
    parseJson?: boolean
    -
    - -
    parser?: ((data) => Data | Promise<Data>)
    -
    -

    Type declaration

    -
      -
    • -
        -
      • (data): Data | Promise<Data>
      • -
      • -
        -

        Parameters

        -
          -
        • -
          data: unknown
        -

        Returns Data | Promise<Data>

    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/interfaces/HandlePubSubMessageArgs.md b/docs/interfaces/HandlePubSubMessageArgs.md new file mode 100644 index 0000000..b1783fb --- /dev/null +++ b/docs/interfaces/HandlePubSubMessageArgs.md @@ -0,0 +1,104 @@ +[pubsub-http-handler](../README.md) / HandlePubSubMessageArgs + +# Interface: HandlePubSubMessageArgs + +## Type parameters + +| Name | +| :------ | +| `Data` | +| `Context` | +| `Logger` | + +## Table of contents + +### Properties + +- [context](HandlePubSubMessageArgs.md#context) +- [handler](HandlePubSubMessageArgs.md#handler) +- [log](HandlePubSubMessageArgs.md#log) +- [message](HandlePubSubMessageArgs.md#message) +- [parseJson](HandlePubSubMessageArgs.md#parsejson) +- [parser](HandlePubSubMessageArgs.md#parser) + +## Properties + +### context + +• **context**: `Context` + +#### Defined in + +[src/common.ts:8](https://github.com/simenandre/pubsub-http-handler/blob/main/src/common.ts#L8) + +___ + +### handler + +• **handler**: [`PubSubHandler`](../README.md#pubsubhandler)<`Data`, `Context`, `Logger`\> + +#### Defined in + +[src/common.ts:5](https://github.com/simenandre/pubsub-http-handler/blob/main/src/common.ts#L5) + +___ + +### log + +• **log**: `Logger` + +#### Defined in + +[src/common.ts:9](https://github.com/simenandre/pubsub-http-handler/blob/main/src/common.ts#L9) + +___ + +### message + +• **message**: `Object` + +#### Type declaration + +| Name | Type | +| :------ | :------ | +| `attributes?` | `Record`<`string`, `string`\> | +| `data` | `string` | +| `messageId?` | `string` | + +#### Defined in + +[src/common.ts:4](https://github.com/simenandre/pubsub-http-handler/blob/main/src/common.ts#L4) + +___ + +### parseJson + +• `Optional` **parseJson**: `boolean` + +#### Defined in + +[src/common.ts:6](https://github.com/simenandre/pubsub-http-handler/blob/main/src/common.ts#L6) + +___ + +### parser + +• `Optional` **parser**: (`data`: `unknown`) => `Data` \| `Promise`<`Data`\> + +#### Type declaration + +▸ (`data`): `Data` \| `Promise`<`Data`\> + +##### Parameters + +| Name | Type | +| :------ | :------ | +| `data` | `unknown` | + +##### Returns + +`Data` \| `Promise`<`Data`\> + +#### Defined in + +[src/common.ts:7](https://github.com/simenandre/pubsub-http-handler/blob/main/src/common.ts#L7) diff --git a/docs/interfaces/PubSubCloudFunctionsConfig.html b/docs/interfaces/PubSubCloudFunctionsConfig.html deleted file mode 100644 index 89e39f8..0000000 --- a/docs/interfaces/PubSubCloudFunctionsConfig.html +++ /dev/null @@ -1,174 +0,0 @@ -PubSubCloudFunctionsConfig | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Interface PubSubCloudFunctionsConfig<Data, Context>

    -
    -

    Type Parameters

    -
      -
    • -

      Data

    • -
    • -

      Context

    -
    -

    Hierarchy

    -
    -
    -
    -
    - -
    -
    -

    Properties

    -
    - -
    context?: ((req?) => Context | Promise<Context>)
    -
    -

    Type declaration

    -
      -
    • -
        -
      • (req?): Context | Promise<Context>
      • -
      • -
        -

        Parameters

        -
          -
        • -
          Optional req: Request<ParamsDictionary, any, any, ParsedQs, Record<string, any>>
        -

        Returns Context | Promise<Context>

    -
    - -
    logger?: LoggerOptions
    -
    - -
    onError?: OnErrorHandler<Context>
    -

    OnError Handler

    -

    When this is set, errors will not be -thrown.

    -
    -
    -
    - -
    parseJson?: boolean
    -

    This will run JSON.parse on request data

    -

    Tip: false when sending strings

    -
    -
    -

    Default

    true
    -
    -
    -
    - -
    parser?: ((data) => Data | Promise<Data>)
    -
    -

    Type declaration

    -
      -
    • -
        -
      • (data): Data | Promise<Data>
      • -
      • -
        -

        Parameters

        -
          -
        • -
          data: unknown
        -

        Returns Data | Promise<Data>

    -
    - -
    path?: string
    -

    Use this to set a different path

    -
    -
    -

    Default

    /
    -
    -
    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/interfaces/PubSubCloudFunctionsConfig.md b/docs/interfaces/PubSubCloudFunctionsConfig.md new file mode 100644 index 0000000..d0b988b --- /dev/null +++ b/docs/interfaces/PubSubCloudFunctionsConfig.md @@ -0,0 +1,158 @@ +[pubsub-http-handler](../README.md) / PubSubCloudFunctionsConfig + +# Interface: PubSubCloudFunctionsConfig + +## Type parameters + +| Name | +| :------ | +| `Data` | +| `Context` | + +## Hierarchy + +- [`PubSubConfig`](PubSubConfig.md)<`Data`, `Context`\> + + ↳ **`PubSubCloudFunctionsConfig`** + +## Table of contents + +### Properties + +- [context](PubSubCloudFunctionsConfig.md#context) +- [logger](PubSubCloudFunctionsConfig.md#logger) +- [onError](PubSubCloudFunctionsConfig.md#onerror) +- [parseJson](PubSubCloudFunctionsConfig.md#parsejson) +- [parser](PubSubCloudFunctionsConfig.md#parser) +- [path](PubSubCloudFunctionsConfig.md#path) + +## Properties + +### context + +• `Optional` **context**: (`req?`: `Request`<`ParamsDictionary`, `any`, `any`, `ParsedQs`, `Record`<`string`, `any`\>\>) => `Context` \| `Promise`<`Context`\> + +#### Type declaration + +▸ (`req?`): `Context` \| `Promise`<`Context`\> + +##### Parameters + +| Name | Type | +| :------ | :------ | +| `req?` | `Request`<`ParamsDictionary`, `any`, `any`, `ParsedQs`, `Record`<`string`, `any`\>\> | + +##### Returns + +`Context` \| `Promise`<`Context`\> + +#### Overrides + +[PubSubConfig](PubSubConfig.md).[context](PubSubConfig.md#context) + +#### Defined in + +[src/cloud-functions.ts:11](https://github.com/simenandre/pubsub-http-handler/blob/main/src/cloud-functions.ts#L11) + +___ + +### logger + +• `Optional` **logger**: `LoggerOptions` + +#### Defined in + +[src/cloud-functions.ts:9](https://github.com/simenandre/pubsub-http-handler/blob/main/src/cloud-functions.ts#L9) + +___ + +### onError + +• `Optional` **onError**: [`OnErrorHandler`](../README.md#onerrorhandler)<`Context`\> + +OnError Handler + +When this is set, errors will not be +thrown. + +#### Inherited from + +[PubSubConfig](PubSubConfig.md).[onError](PubSubConfig.md#onerror) + +#### Defined in + +[src/types.ts:53](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L53) + +___ + +### parseJson + +• `Optional` **parseJson**: `boolean` + +This will run JSON.parse on request data + +**Tip**: `false` when sending strings + +**`Default`** + +```ts +true +``` + +#### Inherited from + +[PubSubConfig](PubSubConfig.md).[parseJson](PubSubConfig.md#parsejson) + +#### Defined in + +[src/types.ts:65](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L65) + +___ + +### parser + +• `Optional` **parser**: (`data`: `unknown`) => `Data` \| `Promise`<`Data`\> + +#### Type declaration + +▸ (`data`): `Data` \| `Promise`<`Data`\> + +##### Parameters + +| Name | Type | +| :------ | :------ | +| `data` | `unknown` | + +##### Returns + +`Data` \| `Promise`<`Data`\> + +#### Inherited from + +[PubSubConfig](PubSubConfig.md).[parser](PubSubConfig.md#parser) + +#### Defined in + +[src/types.ts:55](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L55) + +___ + +### path + +• `Optional` **path**: `string` + +Use this to set a different path + +**`Default`** + +```ts +/ +``` + +#### Inherited from + +[PubSubConfig](PubSubConfig.md).[path](PubSubConfig.md#path) + +#### Defined in + +[src/types.ts:71](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L71) diff --git a/docs/interfaces/PubSubConfig.html b/docs/interfaces/PubSubConfig.html deleted file mode 100644 index c9e6f2d..0000000 --- a/docs/interfaces/PubSubConfig.html +++ /dev/null @@ -1,158 +0,0 @@ -PubSubConfig | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Interface PubSubConfig<Data, Context>

    -
    -

    Type Parameters

    -
      -
    • -

      Data

    • -
    • -

      Context

    -
    -

    Hierarchy

    -
    -
    -
    -
    - -
    -
    -

    Properties

    -
    -
    -

    Properties

    -
    - -
    context?: (() => Context | Promise<Context>)
    -
    -

    Type declaration

    -
      -
    • -
        -
      • (): Context | Promise<Context>
      • -
      • -

        Returns Context | Promise<Context>

    -
    - -
    onError?: OnErrorHandler<Context>
    -

    OnError Handler

    -

    When this is set, errors will not be -thrown.

    -
    -
    -
    - -
    parseJson?: boolean
    -

    This will run JSON.parse on request data

    -

    Tip: false when sending strings

    -
    -
    -

    Default

    true
    -
    -
    -
    - -
    parser?: ((data) => Data | Promise<Data>)
    -
    -

    Type declaration

    -
      -
    • -
        -
      • (data): Data | Promise<Data>
      • -
      • -
        -

        Parameters

        -
          -
        • -
          data: unknown
        -

        Returns Data | Promise<Data>

    -
    - -
    path?: string
    -

    Use this to set a different path

    -
    -
    -

    Default

    /
    -
    -
    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/interfaces/PubSubConfig.md b/docs/interfaces/PubSubConfig.md new file mode 100644 index 0000000..f324014 --- /dev/null +++ b/docs/interfaces/PubSubConfig.md @@ -0,0 +1,123 @@ +[pubsub-http-handler](../README.md) / PubSubConfig + +# Interface: PubSubConfig + +## Type parameters + +| Name | +| :------ | +| `Data` | +| `Context` | + +## Hierarchy + +- **`PubSubConfig`** + + ↳ [`PubSubCloudFunctionsConfig`](PubSubCloudFunctionsConfig.md) + + ↳ [`PubSubHandlerFastifyConfig`](PubSubHandlerFastifyConfig.md) + +## Table of contents + +### Properties + +- [context](PubSubConfig.md#context) +- [onError](PubSubConfig.md#onerror) +- [parseJson](PubSubConfig.md#parsejson) +- [parser](PubSubConfig.md#parser) +- [path](PubSubConfig.md#path) + +## Properties + +### context + +• `Optional` **context**: () => `Context` \| `Promise`<`Context`\> + +#### Type declaration + +▸ (): `Context` \| `Promise`<`Context`\> + +##### Returns + +`Context` \| `Promise`<`Context`\> + +#### Defined in + +[src/types.ts:57](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L57) + +___ + +### onError + +• `Optional` **onError**: [`OnErrorHandler`](../README.md#onerrorhandler)<`Context`\> + +OnError Handler + +When this is set, errors will not be +thrown. + +#### Defined in + +[src/types.ts:53](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L53) + +___ + +### parseJson + +• `Optional` **parseJson**: `boolean` + +This will run JSON.parse on request data + +**Tip**: `false` when sending strings + +**`Default`** + +```ts +true +``` + +#### Defined in + +[src/types.ts:65](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L65) + +___ + +### parser + +• `Optional` **parser**: (`data`: `unknown`) => `Data` \| `Promise`<`Data`\> + +#### Type declaration + +▸ (`data`): `Data` \| `Promise`<`Data`\> + +##### Parameters + +| Name | Type | +| :------ | :------ | +| `data` | `unknown` | + +##### Returns + +`Data` \| `Promise`<`Data`\> + +#### Defined in + +[src/types.ts:55](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L55) + +___ + +### path + +• `Optional` **path**: `string` + +Use this to set a different path + +**`Default`** + +```ts +/ +``` + +#### Defined in + +[src/types.ts:71](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L71) diff --git a/docs/interfaces/PubSubHandlerFastifyConfig.html b/docs/interfaces/PubSubHandlerFastifyConfig.html deleted file mode 100644 index 3151f70..0000000 --- a/docs/interfaces/PubSubHandlerFastifyConfig.html +++ /dev/null @@ -1,174 +0,0 @@ -PubSubHandlerFastifyConfig | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Interface PubSubHandlerFastifyConfig<Data, Context>

    -
    -

    Type Parameters

    -
      -
    • -

      Data

    • -
    • -

      Context

    -
    -

    Hierarchy

    -
    -
    -
    -
    - -
    -
    -

    Properties

    -
    - -
    context?: ((req?) => Context | Promise<Context>)
    -
    -

    Type declaration

    -
      -
    • -
        -
      • (req?): Context | Promise<Context>
      • -
      • -
        -

        Parameters

        -
          -
        • -
          Optional req: FastifyRequest<RouteGenericInterface, RawServerDefault, IncomingMessage, FastifySchema, FastifyTypeProviderDefault, unknown, FastifyBaseLogger, ResolveFastifyRequestType<FastifyTypeProviderDefault, FastifySchema, RouteGenericInterface>>
        -

        Returns Context | Promise<Context>

    -
    - -
    handler: PubSubHandler<Data, Context, FastifyBaseLogger>
    -
    - -
    onError?: OnErrorHandler<Context>
    -

    OnError Handler

    -

    When this is set, errors will not be -thrown.

    -
    -
    -
    - -
    parseJson?: boolean
    -

    This will run JSON.parse on request data

    -

    Tip: false when sending strings

    -
    -
    -

    Default

    true
    -
    -
    -
    - -
    parser?: ((data) => Data | Promise<Data>)
    -
    -

    Type declaration

    -
      -
    • -
        -
      • (data): Data | Promise<Data>
      • -
      • -
        -

        Parameters

        -
          -
        • -
          data: unknown
        -

        Returns Data | Promise<Data>

    -
    - -
    path?: string
    -

    Use this to set a different path

    -
    -
    -

    Default

    /
    -
    -
    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/interfaces/PubSubHandlerFastifyConfig.md b/docs/interfaces/PubSubHandlerFastifyConfig.md new file mode 100644 index 0000000..abb7145 --- /dev/null +++ b/docs/interfaces/PubSubHandlerFastifyConfig.md @@ -0,0 +1,158 @@ +[pubsub-http-handler](../README.md) / PubSubHandlerFastifyConfig + +# Interface: PubSubHandlerFastifyConfig + +## Type parameters + +| Name | +| :------ | +| `Data` | +| `Context` | + +## Hierarchy + +- [`PubSubConfig`](PubSubConfig.md)<`Data`, `Context`\> + + ↳ **`PubSubHandlerFastifyConfig`** + +## Table of contents + +### Properties + +- [context](PubSubHandlerFastifyConfig.md#context) +- [handler](PubSubHandlerFastifyConfig.md#handler) +- [onError](PubSubHandlerFastifyConfig.md#onerror) +- [parseJson](PubSubHandlerFastifyConfig.md#parsejson) +- [parser](PubSubHandlerFastifyConfig.md#parser) +- [path](PubSubHandlerFastifyConfig.md#path) + +## Properties + +### context + +• `Optional` **context**: (`req?`: `FastifyRequest`<`RouteGenericInterface`, `RawServerDefault`, `IncomingMessage`, `FastifySchema`, `FastifyTypeProviderDefault`, `unknown`, `FastifyBaseLogger`, `ResolveFastifyRequestType`<`FastifyTypeProviderDefault`, `FastifySchema`, `RouteGenericInterface`\>\>) => `Context` \| `Promise`<`Context`\> + +#### Type declaration + +▸ (`req?`): `Context` \| `Promise`<`Context`\> + +##### Parameters + +| Name | Type | +| :------ | :------ | +| `req?` | `FastifyRequest`<`RouteGenericInterface`, `RawServerDefault`, `IncomingMessage`, `FastifySchema`, `FastifyTypeProviderDefault`, `unknown`, `FastifyBaseLogger`, `ResolveFastifyRequestType`<`FastifyTypeProviderDefault`, `FastifySchema`, `RouteGenericInterface`\>\> | + +##### Returns + +`Context` \| `Promise`<`Context`\> + +#### Overrides + +[PubSubConfig](PubSubConfig.md).[context](PubSubConfig.md#context) + +#### Defined in + +[src/fastify-plugin.ts:11](https://github.com/simenandre/pubsub-http-handler/blob/main/src/fastify-plugin.ts#L11) + +___ + +### handler + +• **handler**: [`PubSubHandler`](../README.md#pubsubhandler)<`Data`, `Context`, `FastifyBaseLogger`\> + +#### Defined in + +[src/fastify-plugin.ts:9](https://github.com/simenandre/pubsub-http-handler/blob/main/src/fastify-plugin.ts#L9) + +___ + +### onError + +• `Optional` **onError**: [`OnErrorHandler`](../README.md#onerrorhandler)<`Context`\> + +OnError Handler + +When this is set, errors will not be +thrown. + +#### Inherited from + +[PubSubConfig](PubSubConfig.md).[onError](PubSubConfig.md#onerror) + +#### Defined in + +[src/types.ts:53](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L53) + +___ + +### parseJson + +• `Optional` **parseJson**: `boolean` + +This will run JSON.parse on request data + +**Tip**: `false` when sending strings + +**`Default`** + +```ts +true +``` + +#### Inherited from + +[PubSubConfig](PubSubConfig.md).[parseJson](PubSubConfig.md#parsejson) + +#### Defined in + +[src/types.ts:65](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L65) + +___ + +### parser + +• `Optional` **parser**: (`data`: `unknown`) => `Data` \| `Promise`<`Data`\> + +#### Type declaration + +▸ (`data`): `Data` \| `Promise`<`Data`\> + +##### Parameters + +| Name | Type | +| :------ | :------ | +| `data` | `unknown` | + +##### Returns + +`Data` \| `Promise`<`Data`\> + +#### Inherited from + +[PubSubConfig](PubSubConfig.md).[parser](PubSubConfig.md#parser) + +#### Defined in + +[src/types.ts:55](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L55) + +___ + +### path + +• `Optional` **path**: `string` + +Use this to set a different path + +**`Default`** + +```ts +/ +``` + +#### Inherited from + +[PubSubConfig](PubSubConfig.md).[path](PubSubConfig.md#path) + +#### Defined in + +[src/types.ts:71](https://github.com/simenandre/pubsub-http-handler/blob/main/src/types.ts#L71) diff --git a/docs/types/CloudFunctionFun.html b/docs/types/CloudFunctionFun.html deleted file mode 100644 index 73fcf67..0000000 --- a/docs/types/CloudFunctionFun.html +++ /dev/null @@ -1,72 +0,0 @@ -CloudFunctionFun | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Type alias CloudFunctionFun

    -
    CloudFunctionFun: ((req, res) => Promise<void>)
    -
    -

    Type declaration

    -
      -
    • -
        -
      • (req, res): Promise<void>
      • -
      • -
        -

        Parameters

        -
          -
        • -
          req: express.Request
        • -
        • -
          res: express.Response
        -

        Returns Promise<void>

    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/types/OnErrorHandler.html b/docs/types/OnErrorHandler.html deleted file mode 100644 index 2cd4d56..0000000 --- a/docs/types/OnErrorHandler.html +++ /dev/null @@ -1,77 +0,0 @@ -OnErrorHandler | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Type alias OnErrorHandler<Context>

    -
    OnErrorHandler<Context>: ((error, context) => void | Promise<void>)
    -
    -

    Type Parameters

    -
      -
    • -

      Context

    -
    -

    Type declaration

    -
      -
    • -
        -
      • (error, context): void | Promise<void>
      • -
      • -
        -

        Parameters

        -
          -
        • -
          error: unknown
        • -
        • -
          context: Context
        -

        Returns void | Promise<void>

    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/types/PubSubHandler.html b/docs/types/PubSubHandler.html deleted file mode 100644 index cd499d6..0000000 --- a/docs/types/PubSubHandler.html +++ /dev/null @@ -1,88 +0,0 @@ -PubSubHandler | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Type alias PubSubHandler<Data, Context, Logger>

    -
    PubSubHandler<Data, Context, Logger>: ((args) => Promise<PubSubHandlerResponse | void> | PubSubHandlerResponse | void)
    -
    -

    Type Parameters

    -
      -
    • -

      Data

    • -
    • -

      Context

    • -
    • -

      Logger

    -
    -

    Type declaration

    -
    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/types/PubSubMessage.html b/docs/types/PubSubMessage.html deleted file mode 100644 index af1ffaa..0000000 --- a/docs/types/PubSubMessage.html +++ /dev/null @@ -1,57 +0,0 @@ -PubSubMessage | pubsub-http-handler
    -
    - -
    - -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/types/PubSubRequest.html b/docs/types/PubSubRequest.html deleted file mode 100644 index 6b87213..0000000 --- a/docs/types/PubSubRequest.html +++ /dev/null @@ -1,57 +0,0 @@ -PubSubRequest | pubsub-http-handler
    -
    - -
    - -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/variables/pubSubMessageSchema.html b/docs/variables/pubSubMessageSchema.html deleted file mode 100644 index 3444fb6..0000000 --- a/docs/variables/pubSubMessageSchema.html +++ /dev/null @@ -1,71 +0,0 @@ -pubSubMessageSchema | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Variable pubSubMessageSchemaConst

    -
    pubSubMessageSchema: TObject<{
        attributes: TOptional<TRecord<TString, TString>>;
        data: TString;
        messageId: TOptional<TString>;
    }> = ...
    -

    PubSub Message Type

    -

    This describes the message object that is sent to the handler -from Google PubSub.

    -
    -
    -

    Type declaration

    -
      -
    • -
      attributes: TOptional<TRecord<TString, TString>>
    • -
    • -
      data: TString
    • -
    • -
      messageId: TOptional<TString>
    -
    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/docs/variables/pubSubRequestSchema.html b/docs/variables/pubSubRequestSchema.html deleted file mode 100644 index a4fa92e..0000000 --- a/docs/variables/pubSubRequestSchema.html +++ /dev/null @@ -1,69 +0,0 @@ -pubSubRequestSchema | pubsub-http-handler
    -
    - -
    -
    -
    -
    - -

    Variable pubSubRequestSchemaConst

    -
    pubSubRequestSchema: TObject<{
        message: TObject<{
            attributes: TOptional<TRecord<TString, TString>>;
            data: TString;
            messageId: TOptional<TString>;
        }>;
        subscription: TString;
    }> = ...
    -

    PubSub Request Type

    -

    This describes the request object that is sent to the handler -from Google PubSub.

    -
    -
    -

    Type declaration

    -
      -
    • -
      message: TObject<{
          attributes: TOptional<TRecord<TString, TString>>;
          data: TString;
          messageId: TOptional<TString>;
      }>
    • -
    • -
      subscription: TString
    -
    -
    -
    -

    Generated using TypeDoc

    -
    \ No newline at end of file diff --git a/package.json b/package.json index b57ffe8..201fb33 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "scripts": { "build": "tsc", "lint": "eslint '**/*.ts' --fix", - "generate:docs": "typedoc --gitRevision main --readme none --out docs src", + "generate:docs": "typedoc --gitRevision main --plugin typedoc-plugin-markdown --readme none --out docs src", "test": "jest --coverage src", "prepare": "husky install" },