合并api文档编辑页面,体验优化

This commit is contained in:
暮光:城中城
2021-12-14 22:29:07 +08:00
parent bca4ba34e1
commit ab92d6958b
58 changed files with 570 additions and 9849 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1 @@
import{u as S,ar as w,r as c,o as a,c as l,w as t,a as o,m as g,t as n,b as i,F as f,k as s,e as m,d as M}from"./vendor.f364ea47.js";import{m as B}from"./index.71e18790.js";import{_ as C}from"./main.14315fab.js";const N={setup(){const _=S(),D=w(()=>_.state.swaggerDoc),u=w(()=>_.state.swaggerDoc.info),e=w(()=>_.state.swaggerMethodStatistic);return{swaggerDoc:D,swaggerDocInfo:u,swaggerMethodStatistic:e,getDescription:I=>B.exports.markdownIt.render(I||"")}}},V=["href"],j=["href"],L=["href"],O=["innerHTML"],T={key:1,style:{"text-align":"center"}};function E(_,D,u,e,p,I){const r=c("a-form-item"),h=c("a-divider"),v=c("a-statistic"),k=c("a-card"),b=c("a-col"),y=c("a-row"),x=c("a-form");return a(),l(k,null,{default:t(()=>[e.swaggerDocInfo?(a(),l(x,{key:0,"label-col":{span:4},"wrapper-col":{span:20}},{default:t(()=>[o(r,{label:"\u6807\u9898"},{default:t(()=>[g(n(e.swaggerDocInfo.title),1)]),_:1}),o(r,{label:"\u7248\u672C"},{default:t(()=>[g(n(e.swaggerDocInfo.version),1)]),_:1}),e.swaggerDocInfo.contact?(a(),l(r,{key:0,label:"\u4F5C\u8005"},{default:t(()=>[e.swaggerDocInfo.contact.name?(a(),i(f,{key:0},[g(n(e.swaggerDocInfo.contact.name),1)],64)):s("",!0),e.swaggerDocInfo.contact.email?(a(),i(f,{key:1},[o(h,{type:"vertical"}),g(n(e.swaggerDocInfo.contact.email),1)],64)):s("",!0),e.swaggerDocInfo.contact.url?(a(),i(f,{key:2},[o(h,{type:"vertical"}),m("a",{href:e.swaggerDocInfo.contact.url,target:"_blank"},n(e.swaggerDocInfo.contact.url),9,V)],64)):s("",!0)]),_:1})):s("",!0),o(r,{label:"host"},{default:t(()=>[g(n(e.swaggerDoc.host),1)]),_:1}),e.swaggerDocInfo.license?(a(),l(r,{key:1,label:"\u8BB8\u53EF\u8BC1"},{default:t(()=>[m("a",{href:e.swaggerDocInfo.license.url,target:"_blank"},n(e.swaggerDocInfo.license.name),9,j)]),_:1})):s("",!0),e.swaggerDocInfo.termsOfService?(a(),l(r,{key:2,label:"\u670D\u52A1\u6761\u6B3E"},{default:t(()=>[m("a",{href:e.swaggerDocInfo.termsOfService,target:"_blank"},n(e.swaggerDocInfo.termsOfService),9,L)]),_:1})):s("",!0),o(r,{label:"\u6587\u6863\u8BF4\u660E"},{default:t(()=>[m("div",{class:"markdown-body",innerHTML:e.getDescription(e.swaggerDocInfo.description)},null,8,O)]),_:1}),o(r,{label:"\u63A5\u53E3\u7EDF\u8BA1"},{default:t(()=>[o(y,{gutter:[16,16]},{default:t(()=>[(a(),i(f,null,M(["get","post","put","delete","head","patch","options","trace","total"],d=>(a(),i(f,null,[e.swaggerMethodStatistic[d]?(a(),l(b,{key:0,span:6},{default:t(()=>[o(k,{size:"small"},{default:t(()=>[o(v,{title:d==="total"?"\u603B\u8BA1":d.toUpperCase()+"\u65B9\u6CD5",value:e.swaggerMethodStatistic[d],suffix:"\u4E2A"},null,8,["title","value"])]),_:2},1024)]),_:2},1024)):s("",!0)],64))),64))]),_:1})]),_:1})]),_:1})):(a(),i("div",T,"\u6682\u65E0\u6587\u6863\u4FE1\u606F\uFF0C\u8BF7\u5148\u9009\u62E9\u6587\u6863"))]),_:1})}var U=C(N,[["render",E]]);export{U as default};

View File

@@ -0,0 +1 @@
import{u as S,ar as D,r,o as t,c as l,w as o,a as n,m as s,t as c,b as p,F as f,k as i,e as m,d as w}from"./vendor.f364ea47.js";import{m as M}from"./index.71e18790.js";import{_ as B}from"./main.14315fab.js";const C={setup(){const _=S(),A=D(()=>_.state.openApiDoc),u=D(()=>_.state.openApiDoc.info),e=D(()=>_.state.openApiMethodStatistic);return{openApiDoc:A,openApiDocInfo:u,openApiMethodStatistic:e,getDescription:I=>M.exports.markdownIt.render(I||"")}}},N=["href"],V=["href"],j=["href"],L=["innerHTML"],O={key:1,style:{"text-align":"center"}};function T(_,A,u,e,v,I){const a=r("a-form-item"),h=r("a-divider"),b=r("a-statistic"),k=r("a-card"),y=r("a-col"),g=r("a-row"),x=r("a-form");return t(),l(k,null,{default:o(()=>[e.openApiDocInfo?(t(),l(x,{key:0,"label-col":{span:4},"wrapper-col":{span:20}},{default:o(()=>[n(a,{label:"\u6807\u9898"},{default:o(()=>[s(c(e.openApiDocInfo.title),1)]),_:1}),n(a,{label:"\u7248\u672C"},{default:o(()=>[s(c(e.openApiDocInfo.version),1)]),_:1}),e.openApiDocInfo.contact?(t(),l(a,{key:0,label:"\u4F5C\u8005"},{default:o(()=>[e.openApiDocInfo.contact.name?(t(),p(f,{key:0},[s(c(e.openApiDocInfo.contact.name),1)],64)):i("",!0),e.openApiDocInfo.contact.email?(t(),p(f,{key:1},[n(h,{type:"vertical"}),s(c(e.openApiDocInfo.contact.email),1)],64)):i("",!0),e.openApiDocInfo.contact.url?(t(),p(f,{key:2},[n(h,{type:"vertical"}),m("a",{href:e.openApiDocInfo.contact.url,target:"_blank"},c(e.openApiDocInfo.contact.url),9,N)],64)):i("",!0)]),_:1})):i("",!0),n(a,{label:"host"},{default:o(()=>[s(c(e.openApiDoc.host),1)]),_:1}),e.openApiDocInfo.license?(t(),l(a,{key:1,label:"\u8BB8\u53EF\u8BC1"},{default:o(()=>[m("a",{href:e.openApiDocInfo.license.url,target:"_blank"},c(e.openApiDocInfo.license.name),9,V)]),_:1})):i("",!0),e.openApiDocInfo.termsOfService?(t(),l(a,{key:2,label:"\u670D\u52A1\u6761\u6B3E"},{default:o(()=>[m("a",{href:e.openApiDocInfo.termsOfService,target:"_blank"},c(e.openApiDocInfo.termsOfService),9,j)]),_:1})):i("",!0),n(a,{label:"\u6587\u6863\u8BF4\u660E"},{default:o(()=>[m("div",{class:"markdown-body",innerHTML:e.getDescription(e.openApiDocInfo.description)},null,8,L)]),_:1}),n(a,{label:"\u63A5\u53E3\u7EDF\u8BA1"},{default:o(()=>[n(g,{gutter:[16,16]},{default:o(()=>[(t(),p(f,null,w(["get","post","put","delete","head","patch","options","trace","total"],d=>(t(),p(f,null,[e.openApiMethodStatistic[d]?(t(),l(y,{key:0,span:6},{default:o(()=>[n(k,{size:"small"},{default:o(()=>[n(b,{title:d==="total"?"\u603B\u8BA1":d.toUpperCase()+"\u65B9\u6CD5",value:e.openApiMethodStatistic[d],suffix:"\u4E2A"},null,8,["title","value"])]),_:2},1024)]),_:2},1024)):i("",!0)],64))),64))]),_:1})]),_:1})]),_:1})):(t(),p("div",O,"\u6682\u65E0\u6587\u6863\u4FE1\u606F\uFF0C\u8BF7\u5148\u9009\u62E9\u6587\u6863"))]),_:1})}var z=B(C,[["render",T]]);export{z as default};

View File

@@ -1 +0,0 @@
import{u as S,al as D,r as i,o as t,c as l,w as o,a as n,m as s,t as c,b as p,F as f,k as r,e as m,d as w}from"./vendor.1b910c8a.js";import{m as M}from"./mavon-editor.ee685efd.js";import"./index.c860d973.js";import{_ as j}from"./main.a6c14cdf.js";const B={setup(){const _=S(),A=D(()=>_.state.openApiDoc),u=D(()=>_.state.openApiDoc.info),e=D(()=>_.state.openApiMethodStatistic);return{openApiDoc:A,openApiDocInfo:u,openApiMethodStatistic:e,getDescription:I=>M.exports.markdownIt.render(I||"")}}},C=["href"],N=["href"],V=["href"],L=["innerHTML"],O={key:1,style:{"text-align":"center"}};function T(_,A,u,e,v,I){const a=i("a-form-item"),h=i("a-divider"),b=i("a-statistic"),k=i("a-card"),y=i("a-col"),g=i("a-row"),x=i("a-form");return t(),l(k,null,{default:o(()=>[e.openApiDocInfo?(t(),l(x,{key:0,"label-col":{span:4},"wrapper-col":{span:20}},{default:o(()=>[n(a,{label:"\u6807\u9898"},{default:o(()=>[s(c(e.openApiDocInfo.title),1)]),_:1}),n(a,{label:"\u7248\u672C"},{default:o(()=>[s(c(e.openApiDocInfo.version),1)]),_:1}),e.openApiDocInfo.contact?(t(),l(a,{key:0,label:"\u4F5C\u8005"},{default:o(()=>[e.openApiDocInfo.contact.name?(t(),p(f,{key:0},[s(c(e.openApiDocInfo.contact.name),1)],64)):r("",!0),e.openApiDocInfo.contact.email?(t(),p(f,{key:1},[n(h,{type:"vertical"}),s(c(e.openApiDocInfo.contact.email),1)],64)):r("",!0),e.openApiDocInfo.contact.url?(t(),p(f,{key:2},[n(h,{type:"vertical"}),m("a",{href:e.openApiDocInfo.contact.url,target:"_blank"},c(e.openApiDocInfo.contact.url),9,C)],64)):r("",!0)]),_:1})):r("",!0),n(a,{label:"host"},{default:o(()=>[s(c(e.openApiDoc.host),1)]),_:1}),e.openApiDocInfo.license?(t(),l(a,{key:1,label:"\u8BB8\u53EF\u8BC1"},{default:o(()=>[m("a",{href:e.openApiDocInfo.license.url,target:"_blank"},c(e.openApiDocInfo.license.name),9,N)]),_:1})):r("",!0),e.openApiDocInfo.termsOfService?(t(),l(a,{key:2,label:"\u670D\u52A1\u6761\u6B3E"},{default:o(()=>[m("a",{href:e.openApiDocInfo.termsOfService,target:"_blank"},c(e.openApiDocInfo.termsOfService),9,V)]),_:1})):r("",!0),n(a,{label:"\u6587\u6863\u8BF4\u660E"},{default:o(()=>[m("div",{class:"markdown-body",innerHTML:e.getDescription(e.openApiDocInfo.description)},null,8,L)]),_:1}),n(a,{label:"\u63A5\u53E3\u7EDF\u8BA1"},{default:o(()=>[n(g,{gutter:[16,16]},{default:o(()=>[(t(),p(f,null,w(["get","post","put","delete","head","patch","options","trace","total"],d=>(t(),p(f,null,[e.openApiMethodStatistic[d]?(t(),l(y,{key:0,span:6},{default:o(()=>[n(k,{size:"small"},{default:o(()=>[n(b,{title:d==="total"?"\u603B\u8BA1":d.toUpperCase()+"\u65B9\u6CD5",value:e.openApiMethodStatistic[d],suffix:"\u4E2A"},null,8,["title","value"])]),_:2},1024)]),_:2},1024)):r("",!0)],64))),64))]),_:1})]),_:1})]),_:1})):(t(),p("div",O,"\u6682\u65E0\u6587\u6863\u4FE1\u606F\uFF0C\u8BF7\u5148\u9009\u62E9\u6587\u6863"))]),_:1})}var U=j(B,[["render",T]]);export{U as default};

View File

@@ -1 +0,0 @@
import{u as S,al as w,r as c,o as a,c as l,w as t,a as o,m as g,t as n,b as i,F as f,k as s,e as m,d as M}from"./vendor.1b910c8a.js";import{m as j}from"./mavon-editor.ee685efd.js";import"./index.c860d973.js";import{_ as B}from"./main.a6c14cdf.js";const C={setup(){const _=S(),D=w(()=>_.state.swaggerDoc),u=w(()=>_.state.swaggerDoc.info),e=w(()=>_.state.swaggerMethodStatistic);return{swaggerDoc:D,swaggerDocInfo:u,swaggerMethodStatistic:e,getDescription:I=>j.exports.markdownIt.render(I||"")}}},N=["href"],V=["href"],L=["href"],O=["innerHTML"],T={key:1,style:{"text-align":"center"}};function E(_,D,u,e,p,I){const r=c("a-form-item"),h=c("a-divider"),v=c("a-statistic"),k=c("a-card"),b=c("a-col"),y=c("a-row"),x=c("a-form");return a(),l(k,null,{default:t(()=>[e.swaggerDocInfo?(a(),l(x,{key:0,"label-col":{span:4},"wrapper-col":{span:20}},{default:t(()=>[o(r,{label:"\u6807\u9898"},{default:t(()=>[g(n(e.swaggerDocInfo.title),1)]),_:1}),o(r,{label:"\u7248\u672C"},{default:t(()=>[g(n(e.swaggerDocInfo.version),1)]),_:1}),e.swaggerDocInfo.contact?(a(),l(r,{key:0,label:"\u4F5C\u8005"},{default:t(()=>[e.swaggerDocInfo.contact.name?(a(),i(f,{key:0},[g(n(e.swaggerDocInfo.contact.name),1)],64)):s("",!0),e.swaggerDocInfo.contact.email?(a(),i(f,{key:1},[o(h,{type:"vertical"}),g(n(e.swaggerDocInfo.contact.email),1)],64)):s("",!0),e.swaggerDocInfo.contact.url?(a(),i(f,{key:2},[o(h,{type:"vertical"}),m("a",{href:e.swaggerDocInfo.contact.url,target:"_blank"},n(e.swaggerDocInfo.contact.url),9,N)],64)):s("",!0)]),_:1})):s("",!0),o(r,{label:"host"},{default:t(()=>[g(n(e.swaggerDoc.host),1)]),_:1}),e.swaggerDocInfo.license?(a(),l(r,{key:1,label:"\u8BB8\u53EF\u8BC1"},{default:t(()=>[m("a",{href:e.swaggerDocInfo.license.url,target:"_blank"},n(e.swaggerDocInfo.license.name),9,V)]),_:1})):s("",!0),e.swaggerDocInfo.termsOfService?(a(),l(r,{key:2,label:"\u670D\u52A1\u6761\u6B3E"},{default:t(()=>[m("a",{href:e.swaggerDocInfo.termsOfService,target:"_blank"},n(e.swaggerDocInfo.termsOfService),9,L)]),_:1})):s("",!0),o(r,{label:"\u6587\u6863\u8BF4\u660E"},{default:t(()=>[m("div",{class:"markdown-body",innerHTML:e.getDescription(e.swaggerDocInfo.description)},null,8,O)]),_:1}),o(r,{label:"\u63A5\u53E3\u7EDF\u8BA1"},{default:t(()=>[o(y,{gutter:[16,16]},{default:t(()=>[(a(),i(f,null,M(["get","post","put","delete","head","patch","options","trace","total"],d=>(a(),i(f,null,[e.swaggerMethodStatistic[d]?(a(),l(b,{key:0,span:6},{default:t(()=>[o(k,{size:"small"},{default:t(()=>[o(v,{title:d==="total"?"\u603B\u8BA1":d.toUpperCase()+"\u65B9\u6CD5",value:e.swaggerMethodStatistic[d],suffix:"\u4E2A"},null,8,["title","value"])]),_:2},1024)]),_:2},1024)):s("",!0)],64))),64))]),_:1})]),_:1})]),_:1})):(a(),i("div",T,"\u6682\u65E0\u6587\u6863\u4FE1\u606F\uFF0C\u8BF7\u5148\u9009\u62E9\u6587\u6863"))]),_:1})}var q=B(C,[["render",E]]);export{q as default};

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1 @@
import{v as L,u as y,y as a,H as j,r as g,o as h,c as v,w as D,B as k,e as x}from"./vendor.f364ea47.js";import{D as I,s as _}from"./DocContent.02a7a895.js";import{m as M}from"./index.71e18790.js";import{_ as q}from"./main.14315fab.js";import"./logUtil.56e8d39f.js";const S={components:{DocContent:I},setup(){const r=L(),s=y();let m=a("doc"),t=a([]),n=a([]),i=a({url:"",description:"",method:"",consumes:"",produces:""}),o=a(!1),c=0,l;const u=()=>{let P=r.query.path+"."+r.query.method;if(Object.keys(s.state.swaggerUrlMethodMap).length<=0){console.log("\u6587\u6863\u5C1A\u672A\u52A0\u8F7D\uFF0C\u7B49\u5F85\u52A0\u8F7D\u5B8C\u6210"),l||(l=setInterval(()=>{if(o.value||c++>50){clearInterval(l);return}Object.keys(s.state.swaggerUrlMethodMap).length>0&&(console.log("\u6587\u6863\u5185\u5BB9\u6539\u53D8\uFF0C\u91CD\u65B0\u52A0\u8F7D\u6587\u6863"),u())},1e3));return}let e=s.state.swaggerUrlMethodMap[P];if(!e){k.error("\u6CA1\u6709\u627E\u5230\u5BF9\u5E94\u7684\u6587\u6863");return}o.value=!0,s.commit("addTableName",{key:r.fullPath,val:e.summary});let d="",p="";e.consumes&&e.consumes.length>0&&(d=e.consumes.join(" ")),e.produces&&e.produces.length>0&&(p=e.produces.join(" "));let w=M.exports.markdownIt.render(e.description||e.summary||"");i.value={url:e.url,description:w,method:e.method||"",consumes:d,produces:p};let f=s.state.swaggerDefinitions;t.value=_.getRequestParamList(e.parameters,f),n.value=_.getResponseParamList(e.responses,f)};return j(()=>{u()}),{docInfoShow:i,activePage:m,changePage:()=>{},isLoadSuccess:o,requestParamList:t,responseParamList:n}}},C=x("div",{style:{padding:"20px 0",height:"100px"}},null,-1);function b(r,s,m,t,n,i){const o=g("DocContent"),c=g("a-spin");return t.isLoadSuccess?(h(),v(o,{key:0,docInfoShow:t.docInfoShow,requestParamList:t.requestParamList,responseParamList:t.responseParamList},null,8,["docInfoShow","requestParamList","responseParamList"])):(h(),v(c,{key:1,tip:"\u6587\u6863\u6570\u636E\u52A0\u8F7D\u4E2D..."},{default:D(()=>[C]),_:1}))}var V=q(S,[["render",b]]);export{V as default};

View File

@@ -0,0 +1 @@
import{v as y,u as j,y as n,H as D,r as h,o as g,c as v,w as k,B as w,e as x}from"./vendor.f364ea47.js";import{D as I,o as _}from"./DocContent.922a925e.js";import{m as M}from"./index.71e18790.js";import{_ as q}from"./main.14315fab.js";import"./logUtil.56e8d39f.js";const S={components:{DocContent:I},setup(){const a=y(),t=j();let p=n("doc"),o=n([]),r=n([]),i=n({url:"",description:"",method:"",consumes:"",produces:""}),s=n(!1),c=0,l;const m=()=>{let P=a.query.path+"."+a.query.method;if(Object.keys(t.state.openApiUrlMethodMap).length<=0){console.log("\u6587\u6863\u5C1A\u672A\u52A0\u8F7D\uFF0C\u7B49\u5F85\u52A0\u8F7D\u5B8C\u6210"),l||(l=setInterval(()=>{if(s.value||c++>50){clearInterval(l);return}Object.keys(t.state.openApiUrlMethodMap).length>0&&(console.log("\u6587\u6863\u5185\u5BB9\u6539\u53D8\uFF0C\u91CD\u65B0\u52A0\u8F7D\u6587\u6863"),m())},1e3));return}let e=t.state.openApiUrlMethodMap[P];if(!e){w.error("\u6CA1\u6709\u627E\u5230\u5BF9\u5E94\u7684\u6587\u6863");return}s.value=!0,t.commit("addTableName",{key:a.fullPath,val:e.summary});let u="",d="";e.consumes&&e.consumes.length>0&&(u=e.consumes.join(" ")),e.produces&&e.produces.length>0&&(d=e.produces.join(" "));let L=M.exports.markdownIt.render(e.description||e.summary||"");i.value={url:e.url,description:L,method:e.method||"",consumes:u,produces:d};let f=t.state.openApiDefinitions;o.value=_.getRequestParamList(e.parameters,f),r.value=_.getResponseParamList(e.responses,f)};return D(()=>{m()}),{docInfoShow:i,activePage:p,changePage:()=>{},isLoadSuccess:s,requestParamList:o,responseParamList:r}}},A=x("div",{style:{padding:"20px 0",height:"100px"}},null,-1);function C(a,t,p,o,r,i){const s=h("DocContent"),c=h("a-spin");return o.isLoadSuccess?(g(),v(s,{key:0,docInfoShow:o.docInfoShow,requestParamList:o.requestParamList,responseParamList:o.responseParamList},null,8,["docInfoShow","requestParamList","responseParamList"])):(g(),v(c,{key:1,tip:"\u6587\u6863\u6570\u636E\u52A0\u8F7D\u4E2D..."},{default:k(()=>[A]),_:1}))}var T=q(S,[["render",C]]);export{T as default};

View File

@@ -1 +0,0 @@
import{v as L,u as y,y as a,H as j,r as g,o as h,c as v,w as D,B as k,e as x}from"./vendor.1b910c8a.js";import{D as I,s as _}from"./DocContent.75fb82ce.js";import{m as M}from"./mavon-editor.ee685efd.js";import"./index.c860d973.js";import{_ as q}from"./main.a6c14cdf.js";import"./logUtil.3161557e.js";const S={components:{DocContent:I},setup(){const r=L(),s=y();let m=a("doc"),t=a([]),n=a([]),c=a({url:"",description:"",method:"",consumes:"",produces:""}),o=a(!1),i=0,l;const d=()=>{let P=r.query.path+"."+r.query.method;if(Object.keys(s.state.swaggerUrlMethodMap).length<=0){console.log("\u6587\u6863\u5C1A\u672A\u52A0\u8F7D\uFF0C\u7B49\u5F85\u52A0\u8F7D\u5B8C\u6210"),l||(l=setInterval(()=>{if(o.value||i++>50){clearInterval(l);return}Object.keys(s.state.swaggerUrlMethodMap).length>0&&(console.log("\u6587\u6863\u5185\u5BB9\u6539\u53D8\uFF0C\u91CD\u65B0\u52A0\u8F7D\u6587\u6863"),d())},1e3));return}let e=s.state.swaggerUrlMethodMap[P];if(!e){k.error("\u6CA1\u6709\u627E\u5230\u5BF9\u5E94\u7684\u6587\u6863");return}o.value=!0,s.commit("addTableName",{key:r.fullPath,val:e.summary});let u="",p="";e.consumes&&e.consumes.length>0&&(u=e.consumes.join(" ")),e.produces&&e.produces.length>0&&(p=e.produces.join(" "));let w=M.exports.markdownIt.render(e.description||e.summary||"");c.value={url:e.url,description:w,method:e.method||"",consumes:u,produces:p};let f=s.state.swaggerDefinitions;t.value=_.getRequestParamList(e.parameters,f),n.value=_.getResponseParamList(e.responses,f)};return j(()=>{d()}),{docInfoShow:c,activePage:m,changePage:()=>{},isLoadSuccess:o,requestParamList:t,responseParamList:n}}},C=x("div",{style:{padding:"20px 0",height:"100px"}},null,-1);function b(r,s,m,t,n,c){const o=g("DocContent"),i=g("a-spin");return t.isLoadSuccess?(h(),v(o,{key:0,docInfoShow:t.docInfoShow,requestParamList:t.requestParamList,responseParamList:t.responseParamList},null,8,["docInfoShow","requestParamList","responseParamList"])):(h(),v(i,{key:1,tip:"\u6587\u6863\u6570\u636E\u52A0\u8F7D\u4E2D..."},{default:D(()=>[C]),_:1}))}var A=q(S,[["render",b]]);export{A as default};

View File

@@ -1 +0,0 @@
import{v as y,u as j,y as n,H as D,r as h,o as v,c as g,w as k,B as w,e as x}from"./vendor.1b910c8a.js";import{D as I,o as _}from"./DocContent.9bbd9b50.js";import{m as M}from"./mavon-editor.ee685efd.js";import"./index.c860d973.js";import{_ as b}from"./main.a6c14cdf.js";import"./logUtil.3161557e.js";const q={components:{DocContent:I},setup(){const a=y(),t=j();let p=n("doc"),o=n([]),r=n([]),i=n({url:"",description:"",method:"",consumes:"",produces:""}),s=n(!1),c=0,l;const d=()=>{let P=a.query.path+"."+a.query.method;if(Object.keys(t.state.openApiUrlMethodMap).length<=0){console.log("\u6587\u6863\u5C1A\u672A\u52A0\u8F7D\uFF0C\u7B49\u5F85\u52A0\u8F7D\u5B8C\u6210"),l||(l=setInterval(()=>{if(s.value||c++>50){clearInterval(l);return}Object.keys(t.state.openApiUrlMethodMap).length>0&&(console.log("\u6587\u6863\u5185\u5BB9\u6539\u53D8\uFF0C\u91CD\u65B0\u52A0\u8F7D\u6587\u6863"),d())},1e3));return}let e=t.state.openApiUrlMethodMap[P];if(!e){w.error("\u6CA1\u6709\u627E\u5230\u5BF9\u5E94\u7684\u6587\u6863");return}s.value=!0,t.commit("addTableName",{key:a.fullPath,val:e.summary});let m="",u="";e.consumes&&e.consumes.length>0&&(m=e.consumes.join(" ")),e.produces&&e.produces.length>0&&(u=e.produces.join(" "));let L=M.exports.markdownIt.render(e.description||e.summary||"");i.value={url:e.url,description:L,method:e.method||"",consumes:m,produces:u};let f=t.state.openApiDefinitions;o.value=_.getRequestParamList(e.parameters,f),r.value=_.getResponseParamList(e.responses,f)};return D(()=>{d()}),{docInfoShow:i,activePage:p,changePage:()=>{},isLoadSuccess:s,requestParamList:o,responseParamList:r}}},S=x("div",{style:{padding:"20px 0",height:"100px"}},null,-1);function A(a,t,p,o,r,i){const s=h("DocContent"),c=h("a-spin");return o.isLoadSuccess?(v(),g(s,{key:0,docInfoShow:o.docInfoShow,requestParamList:o.requestParamList,responseParamList:o.responseParamList},null,8,["docInfoShow","requestParamList","responseParamList"])):(v(),g(c,{key:1,tip:"\u6587\u6863\u6570\u636E\u52A0\u8F7D\u4E2D..."},{default:k(()=>[S]),_:1}))}var V=b(q,[["render",A]]);export{V as default};

View File

@@ -0,0 +1 @@
var K=Object.defineProperty;var I=Object.getOwnPropertySymbols;var N=Object.prototype.hasOwnProperty,S=Object.prototype.propertyIsEnumerable;var B=(c,e,a)=>e in c?K(c,e,{enumerable:!0,configurable:!0,writable:!0,value:a}):c[e]=a,x=(c,e)=>{for(var a in e||(e={}))N.call(e,a)&&B(c,a,e[a]);if(I)for(var a of I(e))S.call(e,a)&&B(c,a,e[a]);return c};import{z as V}from"./custom.0432982f.js";import{P as U,Z as j,a3 as A,u as F,y as L,H as O,r as m,o as l,b as u,e as z,a as d,w as n,F as f,c as k,t as G,k as b,B as H,m as s}from"./vendor.f364ea47.js";import{_ as R}from"./main.14315fab.js";const q={components:{PlusOutlined:U,SearchOutlined:j,ReloadOutlined:A},props:{dynamicParam:{type:Object,required:!0}},setup(c){const e=F();let a=L([]),t=L(!1);const h=async()=>{i.value={},t.value=!0,V.docApiGlobalParamList(c.dynamicParam).then(o=>{setTimeout(()=>t.value=!1,500),a.value=o.data||[],e.commit("setGlobalParam",a.value)})};let i=L({}),D=L();const p=()=>{i.value.isEdit&&v(i.value);let o={isEdit:!0,paramType:1};a.value.unshift(o),i.value=o,setTimeout(()=>{let r=document.getElementsByClassName("ant-table-body")[0];r.scrollTop=0},0)},P=o=>{i.value.isEdit&&v(i.value),o.isEdit=!0,i.value=x({},o)},v=o=>{o.isEdit=!1,o.id?a.value.forEach(r=>r.isEdit=!1):a.value=a.value.filter(r=>r!==o),i.value={}},E=o=>{if(!i.value.paramKey||!i.value.paramValue){H.error("\u53C2\u6570\u540D\u6216\u53C2\u6570\u503C\u4E0D\u80FD\u4E3A\u7A7A");return}let r=x(x({},c.dynamicParam),i.value);V.docApiGlobalParamUpdate(r).then(w=>{o.isEdit=!1,h()})},T=async o=>{V.docApiGlobalParamUpdate({id:o.id,yn:0}).then(r=>{h()})};return O(()=>{h()}),{docList:a,docListLoading:t,docEdit:i,tableRef:D,searchDocList:h,deleteDoc:T,editDoc:P,saveEditDoc:E,cancelEditDoc:v,addDocLine:p,docListColumns:[{title:"\u53C2\u6570\u540D\u79F0",dataIndex:"paramKey",width:250},{title:"\u53C2\u6570\u503C",dataIndex:"paramValue"},{title:"\u53C2\u6570\u4F4D\u7F6E",dataIndex:"paramType",width:120},{title:"\u64CD\u4F5C",dataIndex:"operation",fixed:"right",width:170}]}}},M={style:{"margin-bottom":"10px","text-align":"right"}},Z=s(" \u5237\u65B0"),J=s(" \u65B0\u5EFA"),Q={key:1},W={key:1},X=s("Form"),Y=s("Header"),$=s("Cookie"),ee=s("Form"),ae=s("Header"),te=s("Cookie"),oe=s("\u53D6\u6D88"),ne=s("\u4FDD\u5B58"),le=s("\u7F16\u8F91"),ie=s("\u5220\u9664");function de(c,e,a,t,h,i){const D=m("reload-outlined"),p=m("a-button"),P=m("plus-outlined"),v=m("a-input"),E=m("a-select-option"),T=m("a-select"),o=m("a-tag"),r=m("a-popconfirm"),w=m("a-table");return l(),u(f,null,[z("div",M,[d(p,{onClick:t.searchDocList,type:"primary"},{icon:n(()=>[d(D)]),default:n(()=>[Z]),_:1},8,["onClick"]),d(p,{onClick:t.addDocLine},{icon:n(()=>[d(P)]),default:n(()=>[J]),_:1},8,["onClick"])]),d(w,{dataSource:t.docList,columns:t.docListColumns,size:"middle",id:"paramTable",loading:t.docListLoading,pagination:!1,scroll:{x:1e3,y:"calc(100vh - 240px)"}},{bodyCell:n(({column:g,text:C,record:y})=>[g.dataIndex==="paramKey"?(l(),u(f,{key:0},[y.isEdit?(l(),k(v,{key:0,placeholder:"\u8BF7\u8F93\u5165\u53C2\u6570\u540D\u79F0",value:t.docEdit.paramKey,"onUpdate:value":e[0]||(e[0]=_=>t.docEdit.paramKey=_)},null,8,["value"])):(l(),u("span",Q,G(C),1))],64)):b("",!0),g.dataIndex==="paramValue"?(l(),u(f,{key:1},[y.isEdit?(l(),k(v,{key:0,rows:1,placeholder:"\u8BF7\u8F93\u5165\u53C2\u6570\u503C",value:t.docEdit.paramValue,"onUpdate:value":e[1]||(e[1]=_=>t.docEdit.paramValue=_)},null,8,["value"])):(l(),u("span",W,G(C),1))],64)):b("",!0),g.dataIndex==="paramType"?(l(),u(f,{key:2},[y.isEdit?(l(),k(T,{key:0,placeholder:"\u53C2\u6570\u4F4D\u7F6E",value:t.docEdit.paramType,"onUpdate:value":e[2]||(e[2]=_=>t.docEdit.paramType=_),style:{width:"110px"}},{default:n(()=>[d(E,{value:1},{default:n(()=>[X]),_:1}),d(E,{value:2},{default:n(()=>[Y]),_:1}),d(E,{value:3},{default:n(()=>[$]),_:1})]),_:1},8,["value"])):(l(),u(f,{key:1},[C===1?(l(),k(o,{key:0,color:"green"},{default:n(()=>[ee]),_:1})):C===2?(l(),k(o,{key:1,color:"pink"},{default:n(()=>[ae]),_:1})):C===3?(l(),k(o,{key:2,color:"pink"},{default:n(()=>[te]),_:1})):b("",!0)],64))],64)):b("",!0),g.dataIndex==="operation"?(l(),u(f,{key:3},[y.isEdit?(l(),u(f,{key:0},[d(p,{type:"link",onClick:_=>t.cancelEditDoc(y)},{default:n(()=>[oe]),_:2},1032,["onClick"]),d(p,{type:"link",onClick:_=>t.saveEditDoc(y)},{default:n(()=>[ne]),_:2},1032,["onClick"])],64)):(l(),u(f,{key:1},[d(p,{type:"link",onClick:_=>t.editDoc(y)},{default:n(()=>[le]),_:2},1032,["onClick"]),d(r,{title:"\u786E\u5B9A\u8981\u5220\u9664\u5417\uFF1F",onConfirm:_=>t.deleteDoc(y)},{default:n(()=>[d(p,{type:"link",danger:""},{default:n(()=>[ie]),_:1})]),_:2},1032,["onConfirm"])],64))],64)):b("",!0)]),_:1},8,["dataSource","columns","loading","scroll"])],64)}var _e=R(q,[["render",de]]);export{_e as E};

View File

@@ -1,4 +1,4 @@
import{z as zyplayerApi,g as getZyplayerApiBaseUrl}from"./custom.f7427cee.js";import{_ as _export_sfc}from"./main.a6c14cdf.js";import{r as resolveComponent,o as openBlock,c as createBlock,w as withCtx,e as createBaseVNode,t as toDisplayString,a as createVNode,k as createCommentVNode,m as createTextVNode,D as DownOutlined,U as UserOutlined,b as createElementBlock,n as withModifiers,F as Fragment,S as StarOutlined,p as SettingOutlined,C as CarryOutOutlined,q as FileTextOutlined,s as DashboardOutlined,I as InfoCircleOutlined,d as renderList,u as useStore,v as useRoute,x as useRouter,y as ref,B as message,E as nextTick,G as watch,H as onMounted,J as withDirectives,L as vShow,M as BarChartOutlined,N as MenuFoldOutlined,O as MenuUnfoldOutlined,P as pushScopeId,Q as popScopeId}from"./vendor.1b910c8a.js";import{a as analysisSwaggerData,g as getTreeDataForTag,b as analysisOpenApiData,c as getTreeDataForTag$1,L as LeftResize,_ as _imports_0}from"./api-logo.01dcd617.js";const _sfc_main$7={data(){return{aboutDialogVisible:!1,upgradeInfo:{}}},mounted(){this.checkSystemUpgrade()},methods:{show(){this.aboutDialogVisible=!0},checkSystemUpgrade(){zyplayerApi.systemUpgradeInfo({}).then(l=>{l.data&&(this.upgradeInfo=l.data,this.upgradeInfo.upgradeContent&&(this.upgradeInfo.upgradeContent=this.upgradeInfo.upgradeContent.replaceAll("\uFF1B",`
import{z as zyplayerApi,g as getZyplayerApiBaseUrl}from"./custom.0432982f.js";import{_ as _export_sfc}from"./main.14315fab.js";import{r as resolveComponent,o as openBlock,c as createBlock,w as withCtx,e as createBaseVNode,t as toDisplayString,a as createVNode,k as createCommentVNode,m as createTextVNode,D as DownOutlined,U as UserOutlined,b as createElementBlock,n as withModifiers,F as Fragment,S as StarOutlined,p as SettingOutlined,C as CarryOutOutlined,q as FileTextOutlined,s as DashboardOutlined,I as InfoCircleOutlined,d as renderList,u as useStore,v as useRoute,x as useRouter,y as ref,B as message,E as nextTick,G as watch,H as onMounted,J as withDirectives,L as vShow,M as BarChartOutlined,N as MenuFoldOutlined,O as MenuUnfoldOutlined,Q as pushScopeId,R as popScopeId}from"./vendor.f364ea47.js";import{a as analysisSwaggerData,g as getTreeDataForTag,b as analysisOpenApiData,c as getTreeDataForTag$1,L as LeftResize,_ as _imports_0}from"./api-logo.bf795a89.js";const _sfc_main$7={data(){return{aboutDialogVisible:!1,upgradeInfo:{}}},mounted(){this.checkSystemUpgrade()},methods:{show(){this.aboutDialogVisible=!0},checkSystemUpgrade(){zyplayerApi.systemUpgradeInfo({}).then(l=>{l.data&&(this.upgradeInfo=l.data,this.upgradeInfo.upgradeContent&&(this.upgradeInfo.upgradeContent=this.upgradeInfo.upgradeContent.replaceAll("\uFF1B",`
`),console.log(`zyplayer-doc\u53D1\u73B0\u65B0\u7248\u672C\uFF1A
\u5347\u7EA7\u5730\u5740\uFF1A`+l.data.upgradeUrl+`
\u5F53\u524D\u7248\u672C\uFF1A`+l.data.nowVersion+`

View File

@@ -0,0 +1 @@
import"./custom.0432982f.js";import{E as o}from"./EditGlobalParam.49e3de73.js";import{_ as r}from"./main.14315fab.js";import{r as t,o as e,c as s}from"./vendor.f364ea47.js";const m={components:{EditGlobalParam:o},setup(){return{}}};function n(c,p,l,d,i,f){const a=t("EditGlobalParam");return e(),s(a,{"dynamic-param":{docId:0}})}var G=r(m,[["render",n]]);export{G as default};

View File

@@ -1 +0,0 @@
var G=Object.defineProperty;var V=Object.getOwnPropertySymbols;var K=Object.prototype.hasOwnProperty,N=Object.prototype.propertyIsEnumerable;var w=(c,e,l)=>e in c?G(c,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):c[e]=l,I=(c,e)=>{for(var l in e||(e={}))K.call(e,l)&&w(c,l,e[l]);if(V)for(var l of V(e))N.call(e,l)&&w(c,l,e[l]);return c};import{z as D}from"./custom.f7427cee.js";import{u as P,y as x,H as U,r as v,o,b as r,e as A,a as s,w as n,F as f,B as F,c as k,t as B,k as C,m as d}from"./vendor.1b910c8a.js";import{_ as S}from"./main.a6c14cdf.js";const j={setup(){const c=P();let e=x([]),l=x(!1);const a=async()=>{i.value={},l.value=!0,D.docApiGlobalParamList().then(t=>{setTimeout(()=>l.value=!1,500),e.value=t.data||[],c.commit("setGlobalParam",e.value)})};let i=x({}),T=x();const p=()=>{i.value.isEdit&&y(i.value);let t={isEdit:!0};e.value.unshift(t),i.value=t,setTimeout(()=>{let _=document.getElementsByClassName("ant-table-body")[0];_.scrollTop=0},0)},b=t=>{i.value.isEdit&&y(i.value),t.isEdit=!0,i.value=I({},t)},y=t=>{t.isEdit=!1,t.id?e.value.forEach(_=>_.isEdit=!1):e.value=e.value.filter(_=>_!==t),i.value={}},L=t=>{if(!i.value.paramKey||!i.value.paramValue){F.error("\u53C2\u6570\u540D\u6216\u53C2\u6570\u503C\u4E0D\u80FD\u4E3A\u7A7A");return}D.docApiGlobalParamUpdate(i.value).then(_=>{t.isEdit=!1,a()})},h=async t=>{D.docApiGlobalParamUpdate({id:t.id,yn:0}).then(_=>{a()})};return U(()=>{a()}),{docList:e,docListLoading:l,docEdit:i,tableRef:T,searchDocList:a,deleteDoc:h,editDoc:b,saveEditDoc:L,cancelEditDoc:y,addDocLine:p,docListColumns:[{title:"\u53C2\u6570\u540D\u79F0",dataIndex:"paramKey",width:250},{title:"\u53C2\u6570\u503C",dataIndex:"paramValue"},{title:"\u53C2\u6570\u4F4D\u7F6E",dataIndex:"paramType",width:120},{title:"\u64CD\u4F5C",dataIndex:"operation",fixed:"right",width:170}]}}},z={style:{"margin-bottom":"10px","text-align":"right"}},H=d("\u5237\u65B0"),M=d("\u65B0\u5EFA"),R={key:1},q={key:1},J=d("Form"),O=d("Header"),Q=d("Cookie"),W=d("Form"),X=d("Header"),Y=d("Cookie"),Z=d("\u53D6\u6D88"),$=d("\u4FDD\u5B58"),ee=d("\u7F16\u8F91"),ae=d("\u5220\u9664");function te(c,e,l,a,i,T){const p=v("a-button"),b=v("a-input"),y=v("a-select-option"),L=v("a-select"),h=v("a-tag"),t=v("a-popconfirm"),_=v("a-table");return o(),r(f,null,[A("div",z,[s(p,{onClick:a.searchDocList,type:"primary"},{default:n(()=>[H]),_:1},8,["onClick"]),s(p,{onClick:a.addDocLine},{default:n(()=>[M]),_:1},8,["onClick"])]),s(_,{dataSource:a.docList,columns:a.docListColumns,size:"middle",id:"paramTable",loading:a.docListLoading,pagination:!1,scroll:{x:1e3,y:"calc(100vh - 240px)"}},{bodyCell:n(({column:g,text:E,record:m})=>[g.dataIndex==="paramKey"?(o(),r(f,{key:0},[m.isEdit?(o(),k(b,{key:0,placeholder:"\u8BF7\u8F93\u5165\u53C2\u6570\u540D\u79F0",value:a.docEdit.paramKey,"onUpdate:value":e[0]||(e[0]=u=>a.docEdit.paramKey=u)},null,8,["value"])):(o(),r("span",R,B(E),1))],64)):C("",!0),g.dataIndex==="paramValue"?(o(),r(f,{key:1},[m.isEdit?(o(),k(b,{key:0,rows:1,placeholder:"\u8BF7\u8F93\u5165\u53C2\u6570\u503C",value:a.docEdit.paramValue,"onUpdate:value":e[1]||(e[1]=u=>a.docEdit.paramValue=u)},null,8,["value"])):(o(),r("span",q,B(E),1))],64)):C("",!0),g.dataIndex==="paramType"?(o(),r(f,{key:2},[m.isEdit?(o(),k(L,{key:0,placeholder:"\u53C2\u6570\u4F4D\u7F6E",value:a.docEdit.paramType,"onUpdate:value":e[2]||(e[2]=u=>a.docEdit.paramType=u),style:{width:"110px"}},{default:n(()=>[s(y,{value:1},{default:n(()=>[J]),_:1}),s(y,{value:2},{default:n(()=>[O]),_:1}),s(y,{value:3},{default:n(()=>[Q]),_:1})]),_:1},8,["value"])):(o(),r(f,{key:1},[E===1?(o(),k(h,{key:0,color:"green"},{default:n(()=>[W]),_:1})):E===2?(o(),k(h,{key:1,color:"pink"},{default:n(()=>[X]),_:1})):E===3?(o(),k(h,{key:2,color:"pink"},{default:n(()=>[Y]),_:1})):C("",!0)],64))],64)):C("",!0),g.dataIndex==="operation"?(o(),r(f,{key:3},[m.isEdit?(o(),r(f,{key:0},[s(p,{type:"link",onClick:u=>a.cancelEditDoc(m)},{default:n(()=>[Z]),_:2},1032,["onClick"]),s(p,{type:"link",onClick:u=>a.saveEditDoc(m)},{default:n(()=>[$]),_:2},1032,["onClick"])],64)):(o(),r(f,{key:1},[s(p,{type:"link",onClick:u=>a.editDoc(m)},{default:n(()=>[ee]),_:2},1032,["onClick"]),s(t,{title:"\u786E\u5B9A\u8981\u5220\u9664\u5417\uFF1F",onConfirm:u=>a.deleteDoc(m)},{default:n(()=>[s(p,{type:"link",danger:""},{default:n(()=>[ae]),_:1})]),_:2},1032,["onConfirm"])],64))],64)):C("",!0)]),_:1},8,["dataSource","columns","loading","scroll"])],64)}var de=S(j,[["render",te]]);export{de as default};

View File

@@ -1 +0,0 @@
import{_ as e}from"./main.a6c14cdf.js";import{o as t,b as o}from"./vendor.1b910c8a.js";const n={name:"SettingView",components:{},data(){return{}},computed:{},mounted(){},methods:{}};function r(a,c,s,m,d,i){return t(),o("div",null," \u5C55\u793A\u914D\u7F6E\u9875\u9762 ")}var f=e(n,[["render",r]]);export{f as default};

View File

@@ -0,0 +1 @@
import{_ as e}from"./main.14315fab.js";import{o as t,b as o}from"./vendor.f364ea47.js";const n={name:"SettingView",components:{},data(){return{}},computed:{},mounted(){},methods:{}};function r(a,s,c,m,i,p){return t(),o("div",null," \u5C55\u793A\u914D\u7F6E\u9875\u9762 ")}var _=e(n,[["render",r]]);export{_ as default};

View File

@@ -0,0 +1 @@
import{u as p,y as g,H as f,G as x,o as i,b as l,e as _,F as w,d as L,ax as N,ay as C,t as H,ar as I,r as m,a as v,w as u,c as S,k as A}from"./vendor.f364ea47.js";import{m as T}from"./index.71e18790.js";import{_ as y}from"./main.14315fab.js";const b={props:{heading:{type:Array,default:[]}},setup(r){const s=p();let a=g("100px");f(()=>{window.onresize=()=>{n()},setTimeout(()=>{n()},100)}),x(s.getters.getLeftAsideWidth,()=>{n()});let e=g();const n=()=>{a.value=window.getComputedStyle(e.value,null).width};return{navigationRef:e,navigationWidth:a,headingItemClick:t=>{t.node.scrollIntoView({behavior:"smooth",block:"start",inline:"nearest"})}}}},D={class:"navigation"},B={ref:"navigationRef",style:{display:"inline-block",width:"100%",height:"1px"}},M=["onClick"];function R(r,s,a,e,n,c){return i(),l("div",D,[_("div",B,null,512),_("div",{class:"navigation-heading",style:N({width:e.navigationWidth})},[(i(!0),l(w,null,L(a.heading,t=>(i(),l("div",{class:C("heading-item heading-"+t.level),onClick:o=>e.headingItemClick(t)},H(t.text),11,M))),256))],4)])}var V=y(b,[["render",R]]);const W={components:{Navigation:V},setup(){const r=p(),s=I(()=>r.state.apiDoc);let a=g();x(r.getters.getApiDoc,()=>{setTimeout(()=>{c(".share-instruction")},100)});const e=t=>T.exports.markdownIt.render(t||"");let n=g([]);const c=t=>{if(!document.querySelector(t))return[];let o=document.querySelector(t).querySelectorAll("h1,h2,h3,h4,h5,h6");if(o.length<=0)return[];let d=[];o.forEach(h=>{let k=h.innerHTML.replace(/^\s+/g,"").replace(/\s+$/g,"").replace(/<\/?[^>]+(>|$)/g,"");d.push({node:h,level:parseInt(h.tagName.replace(/[h]/i,""),10),text:k})}),n.value=d};return f(()=>{}),{apiDoc:s,navigationRef:a,navigationList:n,markdownToHtml:e}}},$={key:0},j=["innerHTML"],q={key:1,style:{"text-align":"center"}};function z(r,s,a,e,n,c){const t=m("Navigation"),o=m("a-col"),d=m("a-row");return e.apiDoc.shareInstruction?(i(),l("div",$,[v(d,null,{default:u(()=>[e.navigationList.length>0?(i(),S(o,{key:0,xs:0,sm:4,md:4,lg:6,xl:6},{default:u(()=>[v(t,{ref:"navigationRef",heading:e.navigationList},null,8,["heading"])]),_:1})):A("",!0),v(o,{xs:24,sm:e.navigationList.length>0?20:24,md:e.navigationList.length>0?20:24,lg:e.navigationList.length>0?18:24,xl:e.navigationList.length>0?18:24},{default:u(()=>[_("div",{class:"markdown-body share-instruction",innerHTML:e.markdownToHtml(e.apiDoc.shareInstruction),style:{margin:"0 auto","max-width":"1000px"}},null,8,j)]),_:1},8,["sm","md","lg","xl"])]),_:1})])):(i(),l("div",q,"\u6B22\u8FCE\u8BBF\u95EE\u5F00\u653EAPI\u6587\u6863"))}var P=y(W,[["render",z]]);export{P as default};

View File

@@ -1 +0,0 @@
import{u as p,y as g,H as f,G as x,o as i,b as l,e as _,F as w,d as L,ar as N,as as C,t as H,al as I,r as m,a as v,w as u,c as S,k as A}from"./vendor.1b910c8a.js";import{m as T}from"./mavon-editor.ee685efd.js";import"./index.c860d973.js";import{_ as y}from"./main.a6c14cdf.js";const b={props:{heading:{type:Array,default:[]}},setup(r){const s=p();let a=g("100px");f(()=>{window.onresize=()=>{n()},setTimeout(()=>{n()},100)}),x(s.getters.getLeftAsideWidth,()=>{n()});let e=g();const n=()=>{a.value=window.getComputedStyle(e.value,null).width};return{navigationRef:e,navigationWidth:a,headingItemClick:t=>{t.node.scrollIntoView({behavior:"smooth",block:"start",inline:"nearest"})}}}},D={class:"navigation"},j={ref:"navigationRef",style:{display:"inline-block",width:"100%",height:"1px"}},B=["onClick"];function M(r,s,a,e,n,c){return i(),l("div",D,[_("div",j,null,512),_("div",{class:"navigation-heading",style:N({width:e.navigationWidth})},[(i(!0),l(w,null,L(a.heading,t=>(i(),l("div",{class:C("heading-item heading-"+t.level),onClick:o=>e.headingItemClick(t)},H(t.text),11,B))),256))],4)])}var R=y(b,[["render",M]]);const V={components:{Navigation:R},setup(){const r=p(),s=I(()=>r.state.apiDoc);let a=g();x(r.getters.getApiDoc,()=>{setTimeout(()=>{c(".share-instruction")},100)});const e=t=>T.exports.markdownIt.render(t||"");let n=g([]);const c=t=>{if(!document.querySelector(t))return[];let o=document.querySelector(t).querySelectorAll("h1,h2,h3,h4,h5,h6");if(o.length<=0)return[];let d=[];o.forEach(h=>{let k=h.innerHTML.replace(/^\s+/g,"").replace(/\s+$/g,"").replace(/<\/?[^>]+(>|$)/g,"");d.push({node:h,level:parseInt(h.tagName.replace(/[h]/i,""),10),text:k})}),n.value=d};return f(()=>{}),{apiDoc:s,navigationRef:a,navigationList:n,markdownToHtml:e}}},W={key:0},$=["innerHTML"],q={key:1,style:{"text-align":"center"}};function z(r,s,a,e,n,c){const t=m("Navigation"),o=m("a-col"),d=m("a-row");return e.apiDoc.shareInstruction?(i(),l("div",W,[v(d,null,{default:u(()=>[e.navigationList.length>0?(i(),S(o,{key:0,xs:0,sm:4,md:4,lg:6,xl:6},{default:u(()=>[v(t,{ref:"navigationRef",heading:e.navigationList},null,8,["heading"])]),_:1})):A("",!0),v(o,{xs:24,sm:e.navigationList.length>0?20:24,md:e.navigationList.length>0?20:24,lg:e.navigationList.length>0?18:24,xl:e.navigationList.length>0?18:24},{default:u(()=>[_("div",{class:"markdown-body share-instruction",innerHTML:e.markdownToHtml(e.apiDoc.shareInstruction),style:{margin:"0 auto","max-width":"1000px"}},null,8,$)]),_:1},8,["sm","md","lg","xl"])]),_:1})])):(i(),l("div",q,"\u6B22\u8FCE\u8BBF\u95EE\u5F00\u653EAPI\u6587\u6863"))}var J=y(V,[["render",z]]);export{J as default};

View File

@@ -1 +1 @@
var x=Object.defineProperty,O=Object.defineProperties;var E=Object.getOwnPropertyDescriptors;var L=Object.getOwnPropertySymbols;var k=Object.prototype.hasOwnProperty,M=Object.prototype.propertyIsEnumerable;var b=(r,e,t)=>e in r?x(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,y=(r,e)=>{for(var t in e||(e={}))k.call(e,t)&&b(r,t,e[t]);if(L)for(var t of L(e))M.call(e,t)&&b(r,t,e[t]);return r},v=(r,e)=>O(r,E(e));import{_ as R}from"./main.a6c14cdf.js";import{H as j,y as T,o as z,b as C,e as D}from"./vendor.1b910c8a.js";const w=["get","head","post","put","patch","delete","options","trace"];function W(r){let e={},t={},o={},h=r.paths;return h?(Object.keys(h).forEach(n=>{let s=h[n];for(let a of w){if(!s[a]||!s[a].tags)continue;let p=a.toLowerCase();o[p]=(o[p]||0)+1,o.total=(o.total||0)+1,s[a].tags.forEach(c=>{let i=e[c];i||(i=e[c]={});let l=i[n];l||(l=i[n]={});let f=n+"."+a;l[a]=s[a],l[a].path=f,l[a].url=n,l[a].method=a,t[f]=s[a]})}}),{urlMethodMap:t,tagPathMap:e,methodStatistic:o}):{urlMethodMap:t,tagPathMap:e,methodStatistic:o}}function H(r,e,t,o){let h=[],n=1,s=r.tags||[];return s.length<=0&&Object.keys(e).forEach(a=>s.push({name:a})),s.forEach(a=>{let p=1,c=[],i=e[a.name];!i||(Object.keys(i).forEach(l=>{let f=1,d=i[l];Object.keys(d).forEach(g=>{let m=n+"_"+p+"_"+f,u=d[g];if(!I(l,u,t))return;u.treeId=m;let _=u.summary||u.path;c.push({title:_,key:m,isLeaf:!0,method:u.method,query:v(y({},o),{path:u.url,method:u.method})}),f++}),p++}),c.length>0&&h.push({title:a.name,key:n,children:c}),n++)}),[{key:"main",title:r.info.title||"Swagger\u63A5\u53E3\u6587\u6863",children:h}]}function I(r,e,t){if(!t||!r||(r=r.toLowerCase(),t=t.toLowerCase(),r.indexOf(t)>=0))return!0;let o=e.path+e.method+e.summary+e.description+e.tags;return o&&o.toLowerCase().indexOf(t)>=0}const $=["get","head","post","put","patch","delete","options","trace"];function V(r){let e={},t={},o={},h=r.paths;return h?(Object.keys(h).forEach(n=>{let s=h[n];for(let a of $){if(!s[a]||!s[a].tags)continue;let p=a.toLowerCase();o[p]=(o[p]||0)+1,o.total=(o.total||0)+1,s[a].tags.forEach(c=>{let i=e[c];i||(i=e[c]={});let l=i[n];l||(l=i[n]={});let f=n+"."+a;l[a]=s[a],l[a].path=f,l[a].url=n,l[a].method=a,t[f]=s[a]})}}),{urlMethodMap:t,tagPathMap:e,methodStatistic:o}):{urlMethodMap:t,tagPathMap:e,methodStatistic:o}}function G(r,e,t,o){let h=[],n=1,s=r.tags||[];return s.length<=0&&Object.keys(e).forEach(a=>s.push({name:a})),s.forEach(a=>{let p=1,c=[],i=e[a.name];!i||(Object.keys(i).forEach(l=>{let f=1,d=i[l];Object.keys(d).forEach(g=>{let m=n+"_"+p+"_"+f,u=d[g];if(!A(l,u,t))return;u.treeId=m;let _=u.summary||u.path;c.push({title:_,key:m,isLeaf:!0,method:u.method,query:v(y({},o),{path:u.url,method:u.method})}),f++}),p++}),c.length>0&&h.push({title:a.name,key:n,children:c}),n++)}),[{key:"main",title:r.info.title||"OpenApi\u63A5\u53E3\u6587\u6863",children:h}]}function A(r,e,t){if(!t||!r||(r=r.toLowerCase(),t=t.toLowerCase(),r.indexOf(t)>=0))return!0;let o=e.path+e.method+e.summary+e.description+e.tags;return o&&o.toLowerCase().indexOf(t)>=0}const B={emits:["update:value","change"],setup(r,{emit:e}){j(()=>{n()});let t=T(300),o=T(),h=T();const n=()=>{let s=o.value,a=h.value;s.onmousedown=p=>{let c=p.clientX;return s.style.background="#ccc",a.style.background="#aaa",s.left=s.offsetLeft,document.onmousemove=i=>{let l=i.clientX,f=c-l;(f<0&&t.value<600||f>0&&t.value>300)&&(c=l,t.value-=f,t.value<300&&(t.value=300),e("update:value",t.value),e("change",t.value))},document.onmouseup=()=>{s.style.background="#fafafa",a.style.background="#ccc",document.onmousemove=null,document.onmouseup=null},!1}};return{leftAsideWidth:t,leftResizeRef:o,leftResizeBarRef:h}}},P={ref:"leftResizeRef",class:"left-resize"},U={ref:"leftResizeBarRef"};function S(r,e,t,o,h,n){return z(),C("div",P,[D("i",U,"...",512)],512)}var J=R(B,[["render",S],["__scopeId","data-v-33303c20"]]),K="assets/api-logo.952f0c92.png";export{J as L,K as _,W as a,V as b,G as c,H as g};
var x=Object.defineProperty,O=Object.defineProperties;var E=Object.getOwnPropertyDescriptors;var L=Object.getOwnPropertySymbols;var k=Object.prototype.hasOwnProperty,M=Object.prototype.propertyIsEnumerable;var b=(r,e,t)=>e in r?x(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,y=(r,e)=>{for(var t in e||(e={}))k.call(e,t)&&b(r,t,e[t]);if(L)for(var t of L(e))M.call(e,t)&&b(r,t,e[t]);return r},v=(r,e)=>O(r,E(e));import{_ as R}from"./main.14315fab.js";import{H as j,y as T,o as z,b as C,e as D}from"./vendor.f364ea47.js";const w=["get","head","post","put","patch","delete","options","trace"];function W(r){let e={},t={},o={},h=r.paths;return h?(Object.keys(h).forEach(n=>{let s=h[n];for(let a of w){if(!s[a]||!s[a].tags)continue;let p=a.toLowerCase();o[p]=(o[p]||0)+1,o.total=(o.total||0)+1,s[a].tags.forEach(c=>{let i=e[c];i||(i=e[c]={});let l=i[n];l||(l=i[n]={});let f=n+"."+a;l[a]=s[a],l[a].path=f,l[a].url=n,l[a].method=a,t[f]=s[a]})}}),{urlMethodMap:t,tagPathMap:e,methodStatistic:o}):{urlMethodMap:t,tagPathMap:e,methodStatistic:o}}function H(r,e,t,o){let h=[],n=1,s=r.tags||[];return s.length<=0&&Object.keys(e).forEach(a=>s.push({name:a})),s.forEach(a=>{let p=1,c=[],i=e[a.name];!i||(Object.keys(i).forEach(l=>{let f=1,d=i[l];Object.keys(d).forEach(g=>{let m=n+"_"+p+"_"+f,u=d[g];if(!I(l,u,t))return;u.treeId=m;let _=u.summary||u.path;c.push({title:_,key:m,isLeaf:!0,method:u.method,query:v(y({},o),{path:u.url,method:u.method})}),f++}),p++}),c.length>0&&h.push({title:a.name,key:n,children:c}),n++)}),[{key:"main",title:r.info.title||"Swagger\u63A5\u53E3\u6587\u6863",children:h}]}function I(r,e,t){if(!t||!r||(r=r.toLowerCase(),t=t.toLowerCase(),r.indexOf(t)>=0))return!0;let o=e.path+e.method+e.summary+e.description+e.tags;return o&&o.toLowerCase().indexOf(t)>=0}const $=["get","head","post","put","patch","delete","options","trace"];function V(r){let e={},t={},o={},h=r.paths;return h?(Object.keys(h).forEach(n=>{let s=h[n];for(let a of $){if(!s[a]||!s[a].tags)continue;let p=a.toLowerCase();o[p]=(o[p]||0)+1,o.total=(o.total||0)+1,s[a].tags.forEach(c=>{let i=e[c];i||(i=e[c]={});let l=i[n];l||(l=i[n]={});let f=n+"."+a;l[a]=s[a],l[a].path=f,l[a].url=n,l[a].method=a,t[f]=s[a]})}}),{urlMethodMap:t,tagPathMap:e,methodStatistic:o}):{urlMethodMap:t,tagPathMap:e,methodStatistic:o}}function G(r,e,t,o){let h=[],n=1,s=r.tags||[];return s.length<=0&&Object.keys(e).forEach(a=>s.push({name:a})),s.forEach(a=>{let p=1,c=[],i=e[a.name];!i||(Object.keys(i).forEach(l=>{let f=1,d=i[l];Object.keys(d).forEach(g=>{let m=n+"_"+p+"_"+f,u=d[g];if(!A(l,u,t))return;u.treeId=m;let _=u.summary||u.path;c.push({title:_,key:m,isLeaf:!0,method:u.method,query:v(y({},o),{path:u.url,method:u.method})}),f++}),p++}),c.length>0&&h.push({title:a.name,key:n,children:c}),n++)}),[{key:"main",title:r.info.title||"OpenApi\u63A5\u53E3\u6587\u6863",children:h}]}function A(r,e,t){if(!t||!r||(r=r.toLowerCase(),t=t.toLowerCase(),r.indexOf(t)>=0))return!0;let o=e.path+e.method+e.summary+e.description+e.tags;return o&&o.toLowerCase().indexOf(t)>=0}const B={emits:["update:value","change"],setup(r,{emit:e}){j(()=>{n()});let t=T(300),o=T(),h=T();const n=()=>{let s=o.value,a=h.value;s.onmousedown=p=>{let c=p.clientX;return s.style.background="#ccc",a.style.background="#aaa",s.left=s.offsetLeft,document.onmousemove=i=>{let l=i.clientX,f=c-l;(f<0&&t.value<600||f>0&&t.value>300)&&(c=l,t.value-=f,t.value<300&&(t.value=300),e("update:value",t.value),e("change",t.value))},document.onmouseup=()=>{s.style.background="#fafafa",a.style.background="#ccc",document.onmousemove=null,document.onmouseup=null},!1}};return{leftAsideWidth:t,leftResizeRef:o,leftResizeBarRef:h}}},P={ref:"leftResizeRef",class:"left-resize"},U={ref:"leftResizeBarRef"};function S(r,e,t,o,h,n){return z(),C("div",P,[D("i",U,"...",512)],512)}var J=R(B,[["render",S],["__scopeId","data-v-33303c20"]]),K="assets/api-logo.952f0c92.png";export{J as L,K as _,W as a,V as b,G as c,H as g};

View File

@@ -1 +1 @@
import{B as r}from"./vendor.1b910c8a.js";var g={log(o,l,s){console.log(o+"-\u9047\u5230\u672A\u5904\u7406\u7684\u7C7B\u578B\uFF0C\u8BF7\u8054\u7CFB\u5F00\u53D1\u4EBA\u5458\u4FEE\u6539\uFF1A"+l,s)},logMessage(o,l,s){console.log(o+"-\u9047\u5230\u672A\u5904\u7406\u7684\u7C7B\u578B\uFF0C\u8BF7\u8054\u7CFB\u5F00\u53D1\u4EBA\u5458\u4FEE\u6539\uFF1A"+l,s),r.error(o+"-\u9047\u5230\u672A\u5904\u7406\u7684\u7C7B\u578B\uFF0C\u8BF7\u8054\u7CFB\u5F00\u53D1\u4EBA\u5458\u4FEE\u6539\uFF1A"+l)}};export{g as l};
import{B as e}from"./vendor.f364ea47.js";var g={log(o,l,s){console.log(o+"-\u9047\u5230\u672A\u5904\u7406\u7684\u7C7B\u578B\uFF0C\u8BF7\u8054\u7CFB\u5F00\u53D1\u4EBA\u5458\u4FEE\u6539\uFF1A"+l,s)},logMessage(o,l,s){console.log(o+"-\u9047\u5230\u672A\u5904\u7406\u7684\u7C7B\u578B\uFF0C\u8BF7\u8054\u7CFB\u5F00\u53D1\u4EBA\u5458\u4FEE\u6539\uFF1A"+l,s),e.error(o+"-\u9047\u5230\u672A\u5904\u7406\u7684\u7C7B\u578B\uFF0C\u8BF7\u8054\u7CFB\u5F00\u53D1\u4EBA\u5458\u4FEE\u6539\uFF1A"+l)}};export{g as l};

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long