diff --git a/assets/main.bundle.js b/assets/main.bundle.js index a4e88dc..35d5c7e 100644 --- a/assets/main.bundle.js +++ b/assets/main.bundle.js @@ -507,7 +507,10 @@ function print() { __p += __j.call(arguments, '') } }, ] }`,type:"json"}]},error:{fields:{"400: Bad Request":[{group:"400: Bad Request",type:"String",optional:!1,field:"InvalidInput",isArray:!1,description:"

Invalid value passed in for limit (negative or zero).

"}],"500: Internal Error":[{group:"500: Internal Error",type:"String",optional:!1,field:"InternalError",isArray:!1,description:"

Database operation failed.

"}]},examples:[{title:"Example Error Response:",content:`HTTP/1.1 400 Bad Request -{"error": "InvalidInput"}`,type:"json"}]},version:"0.0.0",filename:"src/services/profile/profile-router.ts",groupTitle:"Profile",name:"GetProfileLeaderboard"},{type:"get",url:"/profile/userid/:USERID",title:"GET /profile/userid/:USERID",group:"Profile",description:"

Retrieve the user's profile based on the provided ID as a path parameter.

",parameter:{fields:{Parameter:[{group:"Parameter",type:"String",optional:!1,field:"USERID",isArray:!1,description:"

User's unique ID.

"}]}},success:{fields:{"200: Success":[{group:"200: Success",type:"string",optional:!1,field:"userID",isArray:!1,description:"

ID of the user

"},{group:"200: Success",type:"string",optional:!1,field:"displayName",isArray:!1,description:"

Publicly-visible display name for the user

"},{group:"200: Success",type:"string",optional:!1,field:"discordTag",isArray:!1,description:"

Discord tag for the user

"},{group:"200: Success",type:"string",optional:!1,field:"avatarUrl",isArray:!1,description:"

URL that contains the user's selected avatar

"},{group:"200: Success",type:"number",optional:!1,field:"points",isArray:!1,description:"

Points that the user has

"},{group:"200: Success",type:"number",optional:!1,field:"coins",isArray:!1,description:"

Coins that the user has

"}]},examples:[{title:"Example Success Response:",content:`HTTP/1.1 200 OK +{"error": "InvalidInput"}`,type:"json"}]},version:"0.0.0",filename:"src/services/profile/profile-router.ts",groupTitle:"Profile",name:"GetProfileLeaderboard"},{type:"get",url:"/profile/ranking/",title:"GET /profile/ranking/",group:"Profile",description:"

Get the ranking of a user based on their authentication. If users are tied in points, ranking is assigned in alphabetical order.

",success:{fields:{"200: Success":[{group:"200: Success",type:"number",optional:!1,field:"ranking",isArray:!1,description:"

Ranking of the user

"}]},examples:[{title:"Example Success Response:",content:`HTTP/1.1 200 OK +{ + "ranking": 1 +}`,type:"json"}]},error:{fields:{"404: Not Found":[{group:"404: Not Found",type:"String",optional:!1,field:"UserNotFound",isArray:!1,description:"

The user's profile was not found.

"}],"500: Internal":[{group:"500: Internal",type:"String",optional:!1,field:"InternalError",isArray:!1,description:"

An internal server error occured.

"}]}},version:"0.0.0",filename:"src/services/profile/profile-router.ts",groupTitle:"Profile",name:"GetProfileRanking"},{type:"get",url:"/profile/userid/:USERID",title:"GET /profile/userid/:USERID",group:"Profile",description:"

Retrieve the user's profile based on the provided ID as a path parameter.

",parameter:{fields:{Parameter:[{group:"Parameter",type:"String",optional:!1,field:"USERID",isArray:!1,description:"

User's unique ID.

"}]}},success:{fields:{"200: Success":[{group:"200: Success",type:"string",optional:!1,field:"userID",isArray:!1,description:"

ID of the user

"},{group:"200: Success",type:"string",optional:!1,field:"displayName",isArray:!1,description:"

Publicly-visible display name for the user

"},{group:"200: Success",type:"string",optional:!1,field:"discordTag",isArray:!1,description:"

Discord tag for the user

"},{group:"200: Success",type:"string",optional:!1,field:"avatarUrl",isArray:!1,description:"

URL that contains the user's selected avatar

"},{group:"200: Success",type:"number",optional:!1,field:"points",isArray:!1,description:"

Points that the user has

"},{group:"200: Success",type:"number",optional:!1,field:"coins",isArray:!1,description:"

Coins that the user has

"}]},examples:[{title:"Example Success Response:",content:`HTTP/1.1 200 OK { "_id": "12345", "userId": "google12345", @@ -744,4 +747,4 @@ function print() { __p += __j.call(arguments, '') } {"error": "Forbidden"}`,type:"json"}]},version:"0.0.0",filename:"src/services/s3/s3-router.ts",groupTitle:"s3",name:"GetS3DownloadUserid"},{type:"get",url:"/s3/upload",title:"GET /s3/upload",group:"s3",description:"

Gets a presigned upload url to the resume s3 bucket for the currently authenticated user, valid for 60s.

",success:{fields:{"200: Success":[{group:"200: Success",type:"String",optional:!1,field:"url",isArray:!1,description:"

presigned URL

"}]},examples:[{title:"Example Success Response:",content:`HTTP/1.1 200 OK { "url": "https://resume-bucket-dev.s3.us-east-2.amazonaws.com/randomuser?randomstuffs", - }`,type:"json"}]},version:"0.0.0",filename:"src/services/s3/s3-router.ts",groupTitle:"s3",name:"GetS3Upload"}];const de={name:"Adonix Endpoint Documentation",version:"0.1.0",description:"Intended for API users",title:"Adonix Endpoint Documentation",url:"https://adonix.hackillinois.org",sampleUrl:!1,defaultVersion:"0.0.0",apidoc:"0.3.0",generator:{name:"apidoc",time:"Wed Jan 24 2024 04:04:54 GMT+0000 (Coordinated Universal Time)",url:"https://apidocjs.com",version:"1.2.0"}};ht();const Ne=u().compile(g()("#template-header").html()),be=u().compile(g()("#template-footer").html()),Z=u().compile(g()("#template-article").html()),ve=u().compile(g()("#template-compare-article").html()),he=u().compile(g()("#template-generator").html()),me=u().compile(g()("#template-project").html()),Oe=u().compile(g()("#template-sections").html()),We=u().compile(g()("#template-sidenav").html()),$e={aloneDisplay:!1,showRequiredLabels:!1,withGenerator:!0,withCompare:!0};de.template=Object.assign($e,(Ge=de.template)!=null?Ge:{}),de.template.forceLanguage&&At(de.template.forceLanguage);const Ve=(0,s.groupBy)(Le,re=>re.group),et={};g().each(Ve,(re,ne)=>{et[re]=(0,s.groupBy)(ne,le=>le.name)});const at=[];g().each(et,(re,ne)=>{let le=[];g().each(ne,(ae,Pe)=>{const Me=Pe[0].title;Me&&le.push(Me.toLowerCase()+"#~#"+ae)}),le.sort(),de.order&&(le=Ce(le,de.order,"#~#")),le.forEach(ae=>{const Me=ae.split("#~#")[1];ne[Me].forEach(_e=>{at.push(_e)})})}),Le=at;let gt={};const Bt={};let Ft={};Ft[de.version]=1,g().each(Le,(re,ne)=>{gt[ne.group]=1,Bt[ne.group]=ne.groupTitle||ne.group,Ft[ne.version]=1}),gt=Object.keys(gt),gt.sort(),de.order&&(gt=Ie(Bt,de.order)),Ft=Object.keys(Ft),Ft.sort(r().compare),Ft.reverse();const bt=[];gt.forEach(re=>{bt.push({group:re,isHeader:!0,title:Bt[re]});let ne="";Le.forEach(le=>{le.group===re&&(ne!==le.name?bt.push({title:le.title,group:re,name:le.name,type:le.type,version:le.version,url:le.url}):bt.push({title:le.title,group:re,hidden:!0,name:le.name,type:le.type,version:le.version,url:le.url}),ne=le.name)})});function cn(re,ne,le){let ae=!1;if(!ne)return ae;const Pe=ne.match(/(.+?)<\/h(1|2)>/gi);return Pe&&Pe.forEach(function(Me){const _e=Me.substring(2,3),lt=Me.replace(/<.+?>/g,""),Tt=Me.match(/id="api-([^-]+)(?:-(.+))?"/),Nt=Tt?Tt[1]:null,mt=Tt?Tt[2]:null;_e==="1"&<&&Nt&&(re.splice(le,0,{group:Nt,isHeader:!0,title:lt,isFixed:!0}),le++,ae=!0),_e==="2"&<&&Nt&&mt&&(re.splice(le,0,{group:Nt,name:mt,isHeader:!1,title:lt,isFixed:!1,version:"1.0"}),le++)}),ae}let dn;if(de.header&&(dn=cn(bt,de.header.content,0),dn||bt.unshift({group:"_header",isHeader:!0,title:de.header.title==null?Et("General"):de.header.title,isFixed:!0})),de.footer){const re=bt.length;dn=cn(bt,de.footer.content,bt.length),!dn&&de.footer.title!=null&&bt.splice(re,0,{group:"_footer",isHeader:!0,title:de.footer.title,isFixed:!0})}const bn=de.title?de.title:"apiDoc: "+de.name+" - "+de.version;g()(document).attr("title",bn),g()("#loader").remove();const On={nav:bt};g()("#sidenav").append(We(On)),g()("#generator").append(he(de)),(0,s.extend)(de,{versions:Ft}),g()("#project").append(me(de)),de.header&&g()("#header").append(Ne(de.header)),de.footer&&(g()("#footer").append(be(de.footer)),de.template.aloneDisplay&&document.getElementById("api-_footer").classList.add("hide"));const Mt={};let Bn="";gt.forEach(function(re){const ne=[];let le="",ae={},Pe=re,Me="";Mt[re]={},Le.forEach(function(_e){re===_e.group&&(le!==_e.name?(Le.forEach(function(lt){re===lt.group&&_e.name===lt.name&&(Object.prototype.hasOwnProperty.call(Mt[_e.group],_e.name)||(Mt[_e.group][_e.name]=[]),Mt[_e.group][_e.name].push(lt.version))}),ae={article:_e,versions:Mt[_e.group][_e.name]}):ae={article:_e,hidden:!0,versions:Mt[_e.group][_e.name]},de.sampleUrl&&de.sampleUrl===!0&&(de.sampleUrl=window.location.origin),de.url&&ae.article.url.substr(0,4).toLowerCase()!=="http"&&(ae.article.url=de.url+ae.article.url),se(ae,_e),_e.groupTitle&&(Pe=_e.groupTitle),_e.groupDescription&&(Me=_e.groupDescription),ne.push({article:Z(ae),group:_e.group,name:_e.name,aloneDisplay:de.template.aloneDisplay}),le=_e.name)}),ae={group:re,title:Pe,description:Me,articles:ne,aloneDisplay:de.template.aloneDisplay},Bn+=Oe(ae)}),g()("#sections").append(Bn),de.template.aloneDisplay||(document.body.dataset.spy="scroll",g()("body").scrollspy({target:"#scrollingNav"})),g()(".form-control").on("focus change",function(){g()(this).removeClass("border-danger")}),g()(".sidenav").find("a").on("click",function(re){re.preventDefault();const ne=this.getAttribute("href");if(de.template.aloneDisplay){const le=document.querySelector(".sidenav > li.active");le&&le.classList.remove("active"),this.parentNode.classList.add("active")}else{const le=document.querySelector(ne);le&&g()("html,body").animate({scrollTop:le.offsetTop},400)}window.location.hash=ne});function St(re){let ne=!1;return g().each(re,le=>{ne=ne||(0,s.some)(re[le],ae=>ae.type)}),ne}function Mn(){g()('button[data-toggle="popover"]').popover().click(function(ne){ne.preventDefault()});const re=g()("#version strong").html();if(g()("#sidenav li").removeClass("is-new"),de.template.withCompare&&g()("#sidenav li[data-version='"+re+"']").each(function(){const ne=g()(this).data("group"),le=g()(this).data("name"),ae=g()("#sidenav li[data-group='"+ne+"'][data-name='"+le+"']").length,Pe=g()("#sidenav li[data-group='"+ne+"'][data-name='"+le+"']").index(g()(this));(ae===1||Pe===ae-1)&&g()(this).addClass("is-new")}),g()(".nav-tabs-examples a").click(function(ne){ne.preventDefault(),g()(this).tab("show")}),g()(".nav-tabs-examples").find("a:first").tab("show"),g()(".sample-request-content-type-switch").change(function(){g()(this).val()==="body-form-data"?(g()("#sample-request-body-json-input-"+g()(this).data("id")).hide(),g()("#sample-request-body-form-input-"+g()(this).data("id")).show()):(g()("#sample-request-body-form-input-"+g()(this).data("id")).hide(),g()("#sample-request-body-json-input-"+g()(this).data("id")).show())}),de.template.aloneDisplay&&(g()(".show-group").click(function(){const ne="."+g()(this).attr("data-group")+"-group",le="."+g()(this).attr("data-group")+"-article";g()(".show-api-group").addClass("hide"),g()(ne).removeClass("hide"),g()(".show-api-article").addClass("hide"),g()(le).removeClass("hide")}),g()(".show-api").click(function(){const ne=this.getAttribute("href").substring(1),le=document.getElementById("version").textContent.trim(),ae=`.${this.dataset.name}-article`,Pe=`[id="${ne}-${le}"]`,Me=`.${this.dataset.group}-group`;g()(".show-api-group").addClass("hide"),g()(Me).removeClass("hide"),g()(".show-api-article").addClass("hide");let _e=g()(ae);g()(Pe).length&&(_e=g()(Pe).parent()),_e.removeClass("hide"),ne.match(/_(header|footer)/)&&document.getElementById(ne).classList.remove("hide")})),de.template.aloneDisplay||g()("body").scrollspy("refresh"),de.template.aloneDisplay){const ne=decodeURI(window.location.hash);if(ne!=null&&ne.length!==0){const le=document.getElementById("version").textContent.trim(),ae=document.querySelector(`li .${ne.slice(1)}-init`),Pe=document.querySelector(`li[data-version="${le}"] .show-api.${ne.slice(1)}-init`);let Me=ae;Pe&&(Me=Pe),Me.click()}}}function $(re){typeof re=="undefined"?re=g()("#version strong").html():g()("#version strong").html(re),g()("article").addClass("hide"),g()("#sidenav li:not(.nav-fixed)").addClass("hide");const ne={};document.querySelectorAll("article[data-version]").forEach(le=>{const ae=le.dataset.group,Pe=le.dataset.name,Me=le.dataset.version,_e=ae+Pe;!ne[_e]&&r().lte(Me,re)&&(ne[_e]=!0,document.querySelector(`article[data-group="${ae}"][data-name="${Pe}"][data-version="${Me}"]`).classList.remove("hide"),document.querySelector(`#sidenav li[data-group="${ae}"][data-name="${Pe}"][data-version="${Me}"]`).classList.remove("hide"),document.querySelector(`#sidenav li.nav-header[data-group="${ae}"]`).classList.remove("hide"))}),g()("article[data-version]").each(function(le){const ae=g()(this).data("group");g()("section#api-"+ae).removeClass("hide"),g()("section#api-"+ae+" article:visible").length===0?g()("section#api-"+ae).addClass("hide"):g()("section#api-"+ae).removeClass("hide")})}if($(),g()("#versions li.version a").on("click",function(re){re.preventDefault(),$(g()(this).html())}),g()("#compareAllWithPredecessor").on("click",ee),g()("article .versions li.version a").on("click",Q),g().urlParam=function(re){const ne=new RegExp("[\\?&]"+re+"=([^&#]*)").exec(window.location.href);return ne&&ne[1]?ne[1]:null},g().urlParam("compare")&&g()("#compareAllWithPredecessor").trigger("click"),window.location.hash){const re=decodeURI(window.location.hash);g()(re).length>0&&g()("html,body").animate({scrollTop:parseInt(g()(re).offset().top)},0)}document.querySelector('[data-toggle="offcanvas"]').addEventListener("click",function(){const re=document.querySelector(".row-offcanvas");re&&re.classList.toggle("active")}),g()("#scrollingNav .sidenav-search input.search").focus(),g()('[data-action="filter-search"]').on("keyup",q(re=>{const ne=re.currentTarget.value.toLowerCase();g()(".sidenav a.nav-list-item").filter((le,ae)=>g()(ae).toggle(g()(ae).text().toLowerCase().indexOf(ne)>-1))},200)),g()("span.search-reset").on("click",function(){g()("#scrollingNav .sidenav-search input.search").val("").focus(),g()(".sidenav").find("a.nav-list-item").show()});function q(re,ne){let le=null;return(...ae)=>{clearTimeout(le),le=setTimeout(re.bind(this,...ae),ne||0)}}function Q(re){re.preventDefault();const ne=g()(this).parents("article"),le=g()(this).html(),ae=ne.find(".version"),Pe=ae.find("strong").html();ae.find("strong").html(le);const Me=ne.data("group"),_e=ne.data("name"),lt=ne.data("version"),Tt=ne.data("compare-version");if(Tt!==le&&!(!Tt&<===le)){if(Tt&&Mt[Me][_e][0]===le||lt===le)xe(Me,_e,lt);else{let Nt={},mt={};g().each(et[Me][_e],function(ar,qn){qn.version===lt&&(Nt=qn),qn.version===le&&(mt=qn)});const st={article:Nt,compare:mt,versions:Mt[Me][_e]};st.article.id=st.article.group+"-"+st.article.name+"-"+st.article.version,st.article.id=st.article.id.replace(/\./g,"_"),st.compare.id=st.compare.group+"-"+st.compare.name+"-"+st.compare.version,st.compare.id=st.compare.id.replace(/\./g,"_");let nt=Nt;nt.header&&nt.header.fields&&(st._hasTypeInHeaderFields=St(nt.header.fields)),nt.parameter&&nt.parameter.fields&&(st._hasTypeInParameterFields=St(nt.parameter.fields)),nt.error&&nt.error.fields&&(st._hasTypeInErrorFields=St(nt.error.fields)),nt.success&&nt.success.fields&&(st._hasTypeInSuccessFields=St(nt.success.fields)),nt.info&&nt.info.fields&&(st._hasTypeInInfoFields=St(nt.info.fields)),nt=mt,st._hasTypeInHeaderFields!==!0&&nt.header&&nt.header.fields&&(st._hasTypeInHeaderFields=St(nt.header.fields)),st._hasTypeInParameterFields!==!0&&nt.parameter&&nt.parameter.fields&&(st._hasTypeInParameterFields=St(nt.parameter.fields)),st._hasTypeInErrorFields!==!0&&nt.error&&nt.error.fields&&(st._hasTypeInErrorFields=St(nt.error.fields)),st._hasTypeInSuccessFields!==!0&&nt.success&&nt.success.fields&&(st._hasTypeInSuccessFields=St(nt.success.fields)),st._hasTypeInInfoFields!==!0&&nt.info&&nt.info.fields&&(st._hasTypeInInfoFields=St(nt.info.fields));const ci=ve(st);ne.after(ci),ne.next().find(".versions li.version a").on("click",Q),g()("#sidenav li[data-group='"+Me+"'][data-name='"+_e+"'][data-version='"+Pe+"']").addClass("has-modifications"),ne.remove()}Mn(),v().highlightAll()}}function ee(re){re.preventDefault(),g()("article:visible .versions").each(function(){const le=g()(this).parents("article").data("version");let ae=null;g()(this).find("li.version a").each(function(){g()(this).html(){Object.keys(re).forEach(Pe=>{re[Pe].replace(/_/g," ")===ae&&le.push(Pe)})}),Object.keys(re).forEach(ae=>{le.indexOf(ae)===-1&&le.push(ae)}),le}Mn()}})()})(); + }`,type:"json"}]},version:"0.0.0",filename:"src/services/s3/s3-router.ts",groupTitle:"s3",name:"GetS3Upload"}];const de={name:"Adonix Endpoint Documentation",version:"0.1.0",description:"Intended for API users",title:"Adonix Endpoint Documentation",url:"https://adonix.hackillinois.org",sampleUrl:!1,defaultVersion:"0.0.0",apidoc:"0.3.0",generator:{name:"apidoc",time:"Wed Jan 24 2024 16:08:02 GMT+0000 (Coordinated Universal Time)",url:"https://apidocjs.com",version:"1.2.0"}};ht();const Ne=u().compile(g()("#template-header").html()),be=u().compile(g()("#template-footer").html()),Z=u().compile(g()("#template-article").html()),ve=u().compile(g()("#template-compare-article").html()),he=u().compile(g()("#template-generator").html()),me=u().compile(g()("#template-project").html()),Oe=u().compile(g()("#template-sections").html()),We=u().compile(g()("#template-sidenav").html()),$e={aloneDisplay:!1,showRequiredLabels:!1,withGenerator:!0,withCompare:!0};de.template=Object.assign($e,(Ge=de.template)!=null?Ge:{}),de.template.forceLanguage&&At(de.template.forceLanguage);const Ve=(0,s.groupBy)(Le,re=>re.group),et={};g().each(Ve,(re,ne)=>{et[re]=(0,s.groupBy)(ne,le=>le.name)});const at=[];g().each(et,(re,ne)=>{let le=[];g().each(ne,(ae,Pe)=>{const Me=Pe[0].title;Me&&le.push(Me.toLowerCase()+"#~#"+ae)}),le.sort(),de.order&&(le=Ce(le,de.order,"#~#")),le.forEach(ae=>{const Me=ae.split("#~#")[1];ne[Me].forEach(_e=>{at.push(_e)})})}),Le=at;let gt={};const Bt={};let Ft={};Ft[de.version]=1,g().each(Le,(re,ne)=>{gt[ne.group]=1,Bt[ne.group]=ne.groupTitle||ne.group,Ft[ne.version]=1}),gt=Object.keys(gt),gt.sort(),de.order&&(gt=Ie(Bt,de.order)),Ft=Object.keys(Ft),Ft.sort(r().compare),Ft.reverse();const bt=[];gt.forEach(re=>{bt.push({group:re,isHeader:!0,title:Bt[re]});let ne="";Le.forEach(le=>{le.group===re&&(ne!==le.name?bt.push({title:le.title,group:re,name:le.name,type:le.type,version:le.version,url:le.url}):bt.push({title:le.title,group:re,hidden:!0,name:le.name,type:le.type,version:le.version,url:le.url}),ne=le.name)})});function cn(re,ne,le){let ae=!1;if(!ne)return ae;const Pe=ne.match(/(.+?)<\/h(1|2)>/gi);return Pe&&Pe.forEach(function(Me){const _e=Me.substring(2,3),lt=Me.replace(/<.+?>/g,""),Tt=Me.match(/id="api-([^-]+)(?:-(.+))?"/),Nt=Tt?Tt[1]:null,mt=Tt?Tt[2]:null;_e==="1"&<&&Nt&&(re.splice(le,0,{group:Nt,isHeader:!0,title:lt,isFixed:!0}),le++,ae=!0),_e==="2"&<&&Nt&&mt&&(re.splice(le,0,{group:Nt,name:mt,isHeader:!1,title:lt,isFixed:!1,version:"1.0"}),le++)}),ae}let dn;if(de.header&&(dn=cn(bt,de.header.content,0),dn||bt.unshift({group:"_header",isHeader:!0,title:de.header.title==null?Et("General"):de.header.title,isFixed:!0})),de.footer){const re=bt.length;dn=cn(bt,de.footer.content,bt.length),!dn&&de.footer.title!=null&&bt.splice(re,0,{group:"_footer",isHeader:!0,title:de.footer.title,isFixed:!0})}const bn=de.title?de.title:"apiDoc: "+de.name+" - "+de.version;g()(document).attr("title",bn),g()("#loader").remove();const On={nav:bt};g()("#sidenav").append(We(On)),g()("#generator").append(he(de)),(0,s.extend)(de,{versions:Ft}),g()("#project").append(me(de)),de.header&&g()("#header").append(Ne(de.header)),de.footer&&(g()("#footer").append(be(de.footer)),de.template.aloneDisplay&&document.getElementById("api-_footer").classList.add("hide"));const Mt={};let Bn="";gt.forEach(function(re){const ne=[];let le="",ae={},Pe=re,Me="";Mt[re]={},Le.forEach(function(_e){re===_e.group&&(le!==_e.name?(Le.forEach(function(lt){re===lt.group&&_e.name===lt.name&&(Object.prototype.hasOwnProperty.call(Mt[_e.group],_e.name)||(Mt[_e.group][_e.name]=[]),Mt[_e.group][_e.name].push(lt.version))}),ae={article:_e,versions:Mt[_e.group][_e.name]}):ae={article:_e,hidden:!0,versions:Mt[_e.group][_e.name]},de.sampleUrl&&de.sampleUrl===!0&&(de.sampleUrl=window.location.origin),de.url&&ae.article.url.substr(0,4).toLowerCase()!=="http"&&(ae.article.url=de.url+ae.article.url),se(ae,_e),_e.groupTitle&&(Pe=_e.groupTitle),_e.groupDescription&&(Me=_e.groupDescription),ne.push({article:Z(ae),group:_e.group,name:_e.name,aloneDisplay:de.template.aloneDisplay}),le=_e.name)}),ae={group:re,title:Pe,description:Me,articles:ne,aloneDisplay:de.template.aloneDisplay},Bn+=Oe(ae)}),g()("#sections").append(Bn),de.template.aloneDisplay||(document.body.dataset.spy="scroll",g()("body").scrollspy({target:"#scrollingNav"})),g()(".form-control").on("focus change",function(){g()(this).removeClass("border-danger")}),g()(".sidenav").find("a").on("click",function(re){re.preventDefault();const ne=this.getAttribute("href");if(de.template.aloneDisplay){const le=document.querySelector(".sidenav > li.active");le&&le.classList.remove("active"),this.parentNode.classList.add("active")}else{const le=document.querySelector(ne);le&&g()("html,body").animate({scrollTop:le.offsetTop},400)}window.location.hash=ne});function St(re){let ne=!1;return g().each(re,le=>{ne=ne||(0,s.some)(re[le],ae=>ae.type)}),ne}function Mn(){g()('button[data-toggle="popover"]').popover().click(function(ne){ne.preventDefault()});const re=g()("#version strong").html();if(g()("#sidenav li").removeClass("is-new"),de.template.withCompare&&g()("#sidenav li[data-version='"+re+"']").each(function(){const ne=g()(this).data("group"),le=g()(this).data("name"),ae=g()("#sidenav li[data-group='"+ne+"'][data-name='"+le+"']").length,Pe=g()("#sidenav li[data-group='"+ne+"'][data-name='"+le+"']").index(g()(this));(ae===1||Pe===ae-1)&&g()(this).addClass("is-new")}),g()(".nav-tabs-examples a").click(function(ne){ne.preventDefault(),g()(this).tab("show")}),g()(".nav-tabs-examples").find("a:first").tab("show"),g()(".sample-request-content-type-switch").change(function(){g()(this).val()==="body-form-data"?(g()("#sample-request-body-json-input-"+g()(this).data("id")).hide(),g()("#sample-request-body-form-input-"+g()(this).data("id")).show()):(g()("#sample-request-body-form-input-"+g()(this).data("id")).hide(),g()("#sample-request-body-json-input-"+g()(this).data("id")).show())}),de.template.aloneDisplay&&(g()(".show-group").click(function(){const ne="."+g()(this).attr("data-group")+"-group",le="."+g()(this).attr("data-group")+"-article";g()(".show-api-group").addClass("hide"),g()(ne).removeClass("hide"),g()(".show-api-article").addClass("hide"),g()(le).removeClass("hide")}),g()(".show-api").click(function(){const ne=this.getAttribute("href").substring(1),le=document.getElementById("version").textContent.trim(),ae=`.${this.dataset.name}-article`,Pe=`[id="${ne}-${le}"]`,Me=`.${this.dataset.group}-group`;g()(".show-api-group").addClass("hide"),g()(Me).removeClass("hide"),g()(".show-api-article").addClass("hide");let _e=g()(ae);g()(Pe).length&&(_e=g()(Pe).parent()),_e.removeClass("hide"),ne.match(/_(header|footer)/)&&document.getElementById(ne).classList.remove("hide")})),de.template.aloneDisplay||g()("body").scrollspy("refresh"),de.template.aloneDisplay){const ne=decodeURI(window.location.hash);if(ne!=null&&ne.length!==0){const le=document.getElementById("version").textContent.trim(),ae=document.querySelector(`li .${ne.slice(1)}-init`),Pe=document.querySelector(`li[data-version="${le}"] .show-api.${ne.slice(1)}-init`);let Me=ae;Pe&&(Me=Pe),Me.click()}}}function $(re){typeof re=="undefined"?re=g()("#version strong").html():g()("#version strong").html(re),g()("article").addClass("hide"),g()("#sidenav li:not(.nav-fixed)").addClass("hide");const ne={};document.querySelectorAll("article[data-version]").forEach(le=>{const ae=le.dataset.group,Pe=le.dataset.name,Me=le.dataset.version,_e=ae+Pe;!ne[_e]&&r().lte(Me,re)&&(ne[_e]=!0,document.querySelector(`article[data-group="${ae}"][data-name="${Pe}"][data-version="${Me}"]`).classList.remove("hide"),document.querySelector(`#sidenav li[data-group="${ae}"][data-name="${Pe}"][data-version="${Me}"]`).classList.remove("hide"),document.querySelector(`#sidenav li.nav-header[data-group="${ae}"]`).classList.remove("hide"))}),g()("article[data-version]").each(function(le){const ae=g()(this).data("group");g()("section#api-"+ae).removeClass("hide"),g()("section#api-"+ae+" article:visible").length===0?g()("section#api-"+ae).addClass("hide"):g()("section#api-"+ae).removeClass("hide")})}if($(),g()("#versions li.version a").on("click",function(re){re.preventDefault(),$(g()(this).html())}),g()("#compareAllWithPredecessor").on("click",ee),g()("article .versions li.version a").on("click",Q),g().urlParam=function(re){const ne=new RegExp("[\\?&]"+re+"=([^&#]*)").exec(window.location.href);return ne&&ne[1]?ne[1]:null},g().urlParam("compare")&&g()("#compareAllWithPredecessor").trigger("click"),window.location.hash){const re=decodeURI(window.location.hash);g()(re).length>0&&g()("html,body").animate({scrollTop:parseInt(g()(re).offset().top)},0)}document.querySelector('[data-toggle="offcanvas"]').addEventListener("click",function(){const re=document.querySelector(".row-offcanvas");re&&re.classList.toggle("active")}),g()("#scrollingNav .sidenav-search input.search").focus(),g()('[data-action="filter-search"]').on("keyup",q(re=>{const ne=re.currentTarget.value.toLowerCase();g()(".sidenav a.nav-list-item").filter((le,ae)=>g()(ae).toggle(g()(ae).text().toLowerCase().indexOf(ne)>-1))},200)),g()("span.search-reset").on("click",function(){g()("#scrollingNav .sidenav-search input.search").val("").focus(),g()(".sidenav").find("a.nav-list-item").show()});function q(re,ne){let le=null;return(...ae)=>{clearTimeout(le),le=setTimeout(re.bind(this,...ae),ne||0)}}function Q(re){re.preventDefault();const ne=g()(this).parents("article"),le=g()(this).html(),ae=ne.find(".version"),Pe=ae.find("strong").html();ae.find("strong").html(le);const Me=ne.data("group"),_e=ne.data("name"),lt=ne.data("version"),Tt=ne.data("compare-version");if(Tt!==le&&!(!Tt&<===le)){if(Tt&&Mt[Me][_e][0]===le||lt===le)xe(Me,_e,lt);else{let Nt={},mt={};g().each(et[Me][_e],function(ar,qn){qn.version===lt&&(Nt=qn),qn.version===le&&(mt=qn)});const st={article:Nt,compare:mt,versions:Mt[Me][_e]};st.article.id=st.article.group+"-"+st.article.name+"-"+st.article.version,st.article.id=st.article.id.replace(/\./g,"_"),st.compare.id=st.compare.group+"-"+st.compare.name+"-"+st.compare.version,st.compare.id=st.compare.id.replace(/\./g,"_");let nt=Nt;nt.header&&nt.header.fields&&(st._hasTypeInHeaderFields=St(nt.header.fields)),nt.parameter&&nt.parameter.fields&&(st._hasTypeInParameterFields=St(nt.parameter.fields)),nt.error&&nt.error.fields&&(st._hasTypeInErrorFields=St(nt.error.fields)),nt.success&&nt.success.fields&&(st._hasTypeInSuccessFields=St(nt.success.fields)),nt.info&&nt.info.fields&&(st._hasTypeInInfoFields=St(nt.info.fields)),nt=mt,st._hasTypeInHeaderFields!==!0&&nt.header&&nt.header.fields&&(st._hasTypeInHeaderFields=St(nt.header.fields)),st._hasTypeInParameterFields!==!0&&nt.parameter&&nt.parameter.fields&&(st._hasTypeInParameterFields=St(nt.parameter.fields)),st._hasTypeInErrorFields!==!0&&nt.error&&nt.error.fields&&(st._hasTypeInErrorFields=St(nt.error.fields)),st._hasTypeInSuccessFields!==!0&&nt.success&&nt.success.fields&&(st._hasTypeInSuccessFields=St(nt.success.fields)),st._hasTypeInInfoFields!==!0&&nt.info&&nt.info.fields&&(st._hasTypeInInfoFields=St(nt.info.fields));const ci=ve(st);ne.after(ci),ne.next().find(".versions li.version a").on("click",Q),g()("#sidenav li[data-group='"+Me+"'][data-name='"+_e+"'][data-version='"+Pe+"']").addClass("has-modifications"),ne.remove()}Mn(),v().highlightAll()}}function ee(re){re.preventDefault(),g()("article:visible .versions").each(function(){const le=g()(this).parents("article").data("version");let ae=null;g()(this).find("li.version a").each(function(){g()(this).html(){Object.keys(re).forEach(Pe=>{re[Pe].replace(/_/g," ")===ae&&le.push(Pe)})}),Object.keys(re).forEach(ae=>{le.indexOf(ae)===-1&&le.push(ae)}),le}Mn()}})()})(); diff --git a/index.html b/index.html index 7ab61f5..1547fac 100644 --- a/index.html +++ b/index.html @@ -5,15 +5,15 @@ - - - - - - - - - + + + + + + + + + @@ -1042,6 +1042,6 @@

{{__ "Request Body"}}

- +